41 lines
215 KiB
JavaScript
41 lines
215 KiB
JavaScript
(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))r(o);new MutationObserver(o=>{for(const i of o)if(i.type==="childList")for(const l of i.addedNodes)l.tagName==="LINK"&&l.rel==="modulepreload"&&r(l)}).observe(document,{childList:!0,subtree:!0});function n(o){const i={};return o.integrity&&(i.integrity=o.integrity),o.referrerPolicy&&(i.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?i.credentials="include":o.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function r(o){if(o.ep)return;o.ep=!0;const i=n(o);fetch(o.href,i)}})();function mf(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Va={exports:{}},Mo={},Wa={exports:{}},D={};/**
|
||
* @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 gr=Symbol.for("react.element"),yf=Symbol.for("react.portal"),gf=Symbol.for("react.fragment"),vf=Symbol.for("react.strict_mode"),kf=Symbol.for("react.profiler"),Sf=Symbol.for("react.provider"),wf=Symbol.for("react.context"),Cf=Symbol.for("react.forward_ref"),_f=Symbol.for("react.suspense"),Ef=Symbol.for("react.memo"),Nf=Symbol.for("react.lazy"),Cs=Symbol.iterator;function Pf(e){return e===null||typeof e!="object"?null:(e=Cs&&e[Cs]||e["@@iterator"],typeof e=="function"?e:null)}var Ha={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Qa=Object.assign,Ga={};function Nn(e,t,n){this.props=e,this.context=t,this.refs=Ga,this.updater=n||Ha}Nn.prototype.isReactComponent={};Nn.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=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,e,t,"setState")};Nn.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Ka(){}Ka.prototype=Nn.prototype;function _l(e,t,n){this.props=e,this.context=t,this.refs=Ga,this.updater=n||Ha}var El=_l.prototype=new Ka;El.constructor=_l;Qa(El,Nn.prototype);El.isPureReactComponent=!0;var _s=Array.isArray,Ya=Object.prototype.hasOwnProperty,Nl={current:null},ba={key:!0,ref:!0,__self:!0,__source:!0};function qa(e,t,n){var r,o={},i=null,l=null;if(t!=null)for(r in t.ref!==void 0&&(l=t.ref),t.key!==void 0&&(i=""+t.key),t)Ya.call(t,r)&&!ba.hasOwnProperty(r)&&(o[r]=t[r]);var a=arguments.length-2;if(a===1)o.children=n;else if(1<a){for(var s=Array(a),u=0;u<a;u++)s[u]=arguments[u+2];o.children=s}if(e&&e.defaultProps)for(r in a=e.defaultProps,a)o[r]===void 0&&(o[r]=a[r]);return{$$typeof:gr,type:e,key:i,ref:l,props:o,_owner:Nl.current}}function Tf(e,t){return{$$typeof:gr,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function Pl(e){return typeof e=="object"&&e!==null&&e.$$typeof===gr}function Lf(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var Es=/\/+/g;function bo(e,t){return typeof e=="object"&&e!==null&&e.key!=null?Lf(""+e.key):t.toString(36)}function Wr(e,t,n,r,o){var i=typeof e;(i==="undefined"||i==="boolean")&&(e=null);var l=!1;if(e===null)l=!0;else switch(i){case"string":case"number":l=!0;break;case"object":switch(e.$$typeof){case gr:case yf:l=!0}}if(l)return l=e,o=o(l),e=r===""?"."+bo(l,0):r,_s(o)?(n="",e!=null&&(n=e.replace(Es,"$&/")+"/"),Wr(o,t,n,"",function(u){return u})):o!=null&&(Pl(o)&&(o=Tf(o,n+(!o.key||l&&l.key===o.key?"":(""+o.key).replace(Es,"$&/")+"/")+e)),t.push(o)),1;if(l=0,r=r===""?".":r+":",_s(e))for(var a=0;a<e.length;a++){i=e[a];var s=r+bo(i,a);l+=Wr(i,t,n,s,o)}else if(s=Pf(e),typeof s=="function")for(e=s.call(e),a=0;!(i=e.next()).done;)i=i.value,s=r+bo(i,a++),l+=Wr(i,t,n,s,o);else if(i==="object")throw t=String(e),Error("Objects are not valid as a React child (found: "+(t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.");return l}function _r(e,t,n){if(e==null)return e;var r=[],o=0;return Wr(e,r,"","",function(i){return t.call(n,i,o++)}),r}function Of(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(n){(e._status===0||e._status===-1)&&(e._status=1,e._result=n)},function(n){(e._status===0||e._status===-1)&&(e._status=2,e._result=n)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var ye={current:null},Hr={transition:null},Mf={ReactCurrentDispatcher:ye,ReactCurrentBatchConfig:Hr,ReactCurrentOwner:Nl};function Xa(){throw Error("act(...) is not supported in production builds of React.")}D.Children={map:_r,forEach:function(e,t,n){_r(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return _r(e,function(){t++}),t},toArray:function(e){return _r(e,function(t){return t})||[]},only:function(e){if(!Pl(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};D.Component=Nn;D.Fragment=gf;D.Profiler=kf;D.PureComponent=_l;D.StrictMode=vf;D.Suspense=_f;D.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Mf;D.act=Xa;D.cloneElement=function(e,t,n){if(e==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+e+".");var r=Qa({},e.props),o=e.key,i=e.ref,l=e._owner;if(t!=null){if(t.ref!==void 0&&(i=t.ref,l=Nl.current),t.key!==void 0&&(o=""+t.key),e.type&&e.type.defaultProps)var a=e.type.defaultProps;for(s in t)Ya.call(t,s)&&!ba.hasOwnProperty(s)&&(r[s]=t[s]===void 0&&a!==void 0?a[s]:t[s])}var s=arguments.length-2;if(s===1)r.children=n;else if(1<s){a=Array(s);for(var u=0;u<s;u++)a[u]=arguments[u+2];r.children=a}return{$$typeof:gr,type:e.type,key:o,ref:i,props:r,_owner:l}};D.createContext=function(e){return e={$$typeof:wf,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:Sf,_context:e},e.Consumer=e};D.createElement=qa;D.createFactory=function(e){var t=qa.bind(null,e);return t.type=e,t};D.createRef=function(){return{current:null}};D.forwardRef=function(e){return{$$typeof:Cf,render:e}};D.isValidElement=Pl;D.lazy=function(e){return{$$typeof:Nf,_payload:{_status:-1,_result:e},_init:Of}};D.memo=function(e,t){return{$$typeof:Ef,type:e,compare:t===void 0?null:t}};D.startTransition=function(e){var t=Hr.transition;Hr.transition={};try{e()}finally{Hr.transition=t}};D.unstable_act=Xa;D.useCallback=function(e,t){return ye.current.useCallback(e,t)};D.useContext=function(e){return ye.current.useContext(e)};D.useDebugValue=function(){};D.useDeferredValue=function(e){return ye.current.useDeferredValue(e)};D.useEffect=function(e,t){return ye.current.useEffect(e,t)};D.useId=function(){return ye.current.useId()};D.useImperativeHandle=function(e,t,n){return ye.current.useImperativeHandle(e,t,n)};D.useInsertionEffect=function(e,t){return ye.current.useInsertionEffect(e,t)};D.useLayoutEffect=function(e,t){return ye.current.useLayoutEffect(e,t)};D.useMemo=function(e,t){return ye.current.useMemo(e,t)};D.useReducer=function(e,t,n){return ye.current.useReducer(e,t,n)};D.useRef=function(e){return ye.current.useRef(e)};D.useState=function(e){return ye.current.useState(e)};D.useSyncExternalStore=function(e,t,n){return ye.current.useSyncExternalStore(e,t,n)};D.useTransition=function(){return ye.current.useTransition()};D.version="18.3.1";Wa.exports=D;var z=Wa.exports;const Af=mf(z);/**
|
||
* @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 jf=z,zf=Symbol.for("react.element"),If=Symbol.for("react.fragment"),Df=Object.prototype.hasOwnProperty,xf=jf.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,Bf={key:!0,ref:!0,__self:!0,__source:!0};function Ja(e,t,n){var r,o={},i=null,l=null;n!==void 0&&(i=""+n),t.key!==void 0&&(i=""+t.key),t.ref!==void 0&&(l=t.ref);for(r in t)Df.call(t,r)&&!Bf.hasOwnProperty(r)&&(o[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)o[r]===void 0&&(o[r]=t[r]);return{$$typeof:zf,type:e,key:i,ref:l,props:o,_owner:xf.current}}Mo.Fragment=If;Mo.jsx=Ja;Mo.jsxs=Ja;Va.exports=Mo;var S=Va.exports,Ei={},Za={exports:{}},Le={},eu={exports:{}},tu={};/**
|
||
* @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.
|
||
*/(function(e){function t(L,j){var I=L.length;L.push(j);e:for(;0<I;){var W=I-1>>>1,X=L[W];if(0<o(X,j))L[W]=j,L[I]=X,I=W;else break e}}function n(L){return L.length===0?null:L[0]}function r(L){if(L.length===0)return null;var j=L[0],I=L.pop();if(I!==j){L[0]=I;e:for(var W=0,X=L.length,xt=X>>>1;W<xt;){var Qe=2*(W+1)-1,T=L[Qe],M=Qe+1,re=L[M];if(0>o(T,I))M<X&&0>o(re,T)?(L[W]=re,L[M]=I,W=M):(L[W]=T,L[Qe]=I,W=Qe);else if(M<X&&0>o(re,I))L[W]=re,L[M]=I,W=M;else break e}}return j}function o(L,j){var I=L.sortIndex-j.sortIndex;return I!==0?I:L.id-j.id}if(typeof performance=="object"&&typeof performance.now=="function"){var i=performance;e.unstable_now=function(){return i.now()}}else{var l=Date,a=l.now();e.unstable_now=function(){return l.now()-a}}var s=[],u=[],m=1,c=null,f=3,v=!1,y=!1,g=!1,N=typeof setTimeout=="function"?setTimeout:null,p=typeof clearTimeout=="function"?clearTimeout:null,d=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function h(L){for(var j=n(u);j!==null;){if(j.callback===null)r(u);else if(j.startTime<=L)r(u),j.sortIndex=j.expirationTime,t(s,j);else break;j=n(u)}}function k(L){if(g=!1,h(L),!y)if(n(s)!==null)y=!0,On(C);else{var j=n(u);j!==null&&Mn(k,j.startTime-L)}}function C(L,j){y=!1,g&&(g=!1,p(_),_=-1),v=!0;var I=f;try{for(h(j),c=n(s);c!==null&&(!(c.expirationTime>j)||L&&!ue());){var W=c.callback;if(typeof W=="function"){c.callback=null,f=c.priorityLevel;var X=W(c.expirationTime<=j);j=e.unstable_now(),typeof X=="function"?c.callback=X:c===n(s)&&r(s),h(j)}else r(s);c=n(s)}if(c!==null)var xt=!0;else{var Qe=n(u);Qe!==null&&Mn(k,Qe.startTime-j),xt=!1}return xt}finally{c=null,f=I,v=!1}}var P=!1,E=null,_=-1,F=5,A=-1;function ue(){return!(e.unstable_now()-A<F)}function ct(){if(E!==null){var L=e.unstable_now();A=L;var j=!0;try{j=E(!0,L)}finally{j?ft():(P=!1,E=null)}}else P=!1}var ft;if(typeof d=="function")ft=function(){d(ct)};else if(typeof MessageChannel<"u"){var Cr=new MessageChannel,Yo=Cr.port2;Cr.port1.onmessage=ct,ft=function(){Yo.postMessage(null)}}else ft=function(){N(ct,0)};function On(L){E=L,P||(P=!0,ft())}function Mn(L,j){_=N(function(){L(e.unstable_now())},j)}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(L){L.callback=null},e.unstable_continueExecution=function(){y||v||(y=!0,On(C))},e.unstable_forceFrameRate=function(L){0>L||125<L?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):F=0<L?Math.floor(1e3/L):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_getFirstCallbackNode=function(){return n(s)},e.unstable_next=function(L){switch(f){case 1:case 2:case 3:var j=3;break;default:j=f}var I=f;f=j;try{return L()}finally{f=I}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(L,j){switch(L){case 1:case 2:case 3:case 4:case 5:break;default:L=3}var I=f;f=L;try{return j()}finally{f=I}},e.unstable_scheduleCallback=function(L,j,I){var W=e.unstable_now();switch(typeof I=="object"&&I!==null?(I=I.delay,I=typeof I=="number"&&0<I?W+I:W):I=W,L){case 1:var X=-1;break;case 2:X=250;break;case 5:X=1073741823;break;case 4:X=1e4;break;default:X=5e3}return X=I+X,L={id:m++,callback:j,priorityLevel:L,startTime:I,expirationTime:X,sortIndex:-1},I>W?(L.sortIndex=I,t(u,L),n(s)===null&&L===n(u)&&(g?(p(_),_=-1):g=!0,Mn(k,I-W))):(L.sortIndex=X,t(s,L),y||v||(y=!0,On(C))),L},e.unstable_shouldYield=ue,e.unstable_wrapCallback=function(L){var j=f;return function(){var I=f;f=j;try{return L.apply(this,arguments)}finally{f=I}}}})(tu);eu.exports=tu;var Ff=eu.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 $f=z,Te=Ff;function w(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var nu=new Set,er={};function bt(e,t){vn(e,t),vn(e+"Capture",t)}function vn(e,t){for(er[e]=t,e=0;e<t.length;e++)nu.add(t[e])}var it=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Ni=Object.prototype.hasOwnProperty,Uf=/^[: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]*$/,Ns={},Ps={};function Rf(e){return Ni.call(Ps,e)?!0:Ni.call(Ns,e)?!1:Uf.test(e)?Ps[e]=!0:(Ns[e]=!0,!1)}function Vf(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function Wf(e,t,n,r){if(t===null||typeof t>"u"||Vf(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function ge(e,t,n,r,o,i,l){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=o,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=i,this.removeEmptyString=l}var ae={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){ae[e]=new ge(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];ae[t]=new ge(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){ae[e]=new ge(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){ae[e]=new ge(e,2,!1,e,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(e){ae[e]=new ge(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){ae[e]=new ge(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){ae[e]=new ge(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){ae[e]=new ge(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){ae[e]=new ge(e,5,!1,e.toLowerCase(),null,!1,!1)});var Tl=/[\-:]([a-z])/g;function Ll(e){return e[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(e){var t=e.replace(Tl,Ll);ae[t]=new ge(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(Tl,Ll);ae[t]=new ge(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(Tl,Ll);ae[t]=new ge(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){ae[e]=new ge(e,1,!1,e.toLowerCase(),null,!1,!1)});ae.xlinkHref=new ge("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){ae[e]=new ge(e,1,!1,e.toLowerCase(),null,!0,!0)});function Ol(e,t,n,r){var o=ae.hasOwnProperty(t)?ae[t]:null;(o!==null?o.type!==0:r||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(Wf(t,n,o,r)&&(n=null),r||o===null?Rf(t)&&(n===null?e.removeAttribute(t):e.setAttribute(t,""+n)):o.mustUseProperty?e[o.propertyName]=n===null?o.type===3?!1:"":n:(t=o.attributeName,r=o.attributeNamespace,n===null?e.removeAttribute(t):(o=o.type,n=o===3||o===4&&n===!0?"":""+n,r?e.setAttributeNS(r,t,n):e.setAttribute(t,n))))}var ut=$f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,Er=Symbol.for("react.element"),Zt=Symbol.for("react.portal"),en=Symbol.for("react.fragment"),Ml=Symbol.for("react.strict_mode"),Pi=Symbol.for("react.profiler"),ru=Symbol.for("react.provider"),ou=Symbol.for("react.context"),Al=Symbol.for("react.forward_ref"),Ti=Symbol.for("react.suspense"),Li=Symbol.for("react.suspense_list"),jl=Symbol.for("react.memo"),yt=Symbol.for("react.lazy"),iu=Symbol.for("react.offscreen"),Ts=Symbol.iterator;function An(e){return e===null||typeof e!="object"?null:(e=Ts&&e[Ts]||e["@@iterator"],typeof e=="function"?e:null)}var b=Object.assign,qo;function Un(e){if(qo===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);qo=t&&t[1]||""}return`
|
||
`+qo+e}var Xo=!1;function Jo(e,t){if(!e||Xo)return"";Xo=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(u){var r=u}Reflect.construct(e,[],t)}else{try{t.call()}catch(u){r=u}e.call(t.prototype)}else{try{throw Error()}catch(u){r=u}e()}}catch(u){if(u&&r&&typeof u.stack=="string"){for(var o=u.stack.split(`
|
||
`),i=r.stack.split(`
|
||
`),l=o.length-1,a=i.length-1;1<=l&&0<=a&&o[l]!==i[a];)a--;for(;1<=l&&0<=a;l--,a--)if(o[l]!==i[a]){if(l!==1||a!==1)do if(l--,a--,0>a||o[l]!==i[a]){var s=`
|
||
`+o[l].replace(" at new "," at ");return e.displayName&&s.includes("<anonymous>")&&(s=s.replace("<anonymous>",e.displayName)),s}while(1<=l&&0<=a);break}}}finally{Xo=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?Un(e):""}function Hf(e){switch(e.tag){case 5:return Un(e.type);case 16:return Un("Lazy");case 13:return Un("Suspense");case 19:return Un("SuspenseList");case 0:case 2:case 15:return e=Jo(e.type,!1),e;case 11:return e=Jo(e.type.render,!1),e;case 1:return e=Jo(e.type,!0),e;default:return""}}function Oi(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case en:return"Fragment";case Zt:return"Portal";case Pi:return"Profiler";case Ml:return"StrictMode";case Ti:return"Suspense";case Li:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case ou:return(e.displayName||"Context")+".Consumer";case ru:return(e._context.displayName||"Context")+".Provider";case Al:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case jl:return t=e.displayName||null,t!==null?t:Oi(e.type)||"Memo";case yt:t=e._payload,e=e._init;try{return Oi(e(t))}catch{}}return null}function Qf(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Oi(t);case 8:return t===Ml?"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 t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function At(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function lu(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Gf(e){var t=lu(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var o=n.get,i=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return o.call(this)},set:function(l){r=""+l,i.call(this,l)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(l){r=""+l},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Nr(e){e._valueTracker||(e._valueTracker=Gf(e))}function su(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=lu(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function io(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function Mi(e,t){var n=t.checked;return b({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Ls(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=At(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function au(e,t){t=t.checked,t!=null&&Ol(e,"checked",t,!1)}function Ai(e,t){au(e,t);var n=At(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?ji(e,t.type,n):t.hasOwnProperty("defaultValue")&&ji(e,t.type,At(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Os(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function ji(e,t,n){(t!=="number"||io(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var Rn=Array.isArray;function dn(e,t,n,r){if(e=e.options,t){t={};for(var o=0;o<n.length;o++)t["$"+n[o]]=!0;for(n=0;n<e.length;n++)o=t.hasOwnProperty("$"+e[n].value),e[n].selected!==o&&(e[n].selected=o),o&&r&&(e[n].defaultSelected=!0)}else{for(n=""+At(n),t=null,o=0;o<e.length;o++){if(e[o].value===n){e[o].selected=!0,r&&(e[o].defaultSelected=!0);return}t!==null||e[o].disabled||(t=e[o])}t!==null&&(t.selected=!0)}}function zi(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(w(91));return b({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function Ms(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error(w(92));if(Rn(n)){if(1<n.length)throw Error(w(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:At(n)}}function uu(e,t){var n=At(t.value),r=At(t.defaultValue);n!=null&&(n=""+n,n!==e.value&&(e.value=n),t.defaultValue==null&&e.defaultValue!==n&&(e.defaultValue=n)),r!=null&&(e.defaultValue=""+r)}function As(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function cu(e){switch(e){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 Ii(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?cu(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var Pr,fu=function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,n,r,o){MSApp.execUnsafeLocalFunction(function(){return e(t,n,r,o)})}:e}(function(e,t){if(e.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in e)e.innerHTML=t;else{for(Pr=Pr||document.createElement("div"),Pr.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=Pr.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function tr(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Qn={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},Kf=["Webkit","ms","Moz","O"];Object.keys(Qn).forEach(function(e){Kf.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Qn[t]=Qn[e]})});function du(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Qn.hasOwnProperty(e)&&Qn[e]?(""+t).trim():t+"px"}function pu(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,o=du(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,o):e[n]=o}}var Yf=b({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 Di(e,t){if(t){if(Yf[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(w(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(w(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(w(61))}if(t.style!=null&&typeof t.style!="object")throw Error(w(62))}}function xi(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){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 Bi=null;function zl(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Fi=null,pn=null,hn=null;function js(e){if(e=Sr(e)){if(typeof Fi!="function")throw Error(w(280));var t=e.stateNode;t&&(t=Do(t),Fi(e.stateNode,e.type,t))}}function hu(e){pn?hn?hn.push(e):hn=[e]:pn=e}function mu(){if(pn){var e=pn,t=hn;if(hn=pn=null,js(e),t)for(e=0;e<t.length;e++)js(t[e])}}function yu(e,t){return e(t)}function gu(){}var Zo=!1;function vu(e,t,n){if(Zo)return e(t,n);Zo=!0;try{return yu(e,t,n)}finally{Zo=!1,(pn!==null||hn!==null)&&(gu(),mu())}}function nr(e,t){var n=e.stateNode;if(n===null)return null;var r=Do(n);if(r===null)return null;n=r[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(e=e.type,r=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!r;break e;default:e=!1}if(e)return null;if(n&&typeof n!="function")throw Error(w(231,t,typeof n));return n}var $i=!1;if(it)try{var jn={};Object.defineProperty(jn,"passive",{get:function(){$i=!0}}),window.addEventListener("test",jn,jn),window.removeEventListener("test",jn,jn)}catch{$i=!1}function bf(e,t,n,r,o,i,l,a,s){var u=Array.prototype.slice.call(arguments,3);try{t.apply(n,u)}catch(m){this.onError(m)}}var Gn=!1,lo=null,so=!1,Ui=null,qf={onError:function(e){Gn=!0,lo=e}};function Xf(e,t,n,r,o,i,l,a,s){Gn=!1,lo=null,bf.apply(qf,arguments)}function Jf(e,t,n,r,o,i,l,a,s){if(Xf.apply(this,arguments),Gn){if(Gn){var u=lo;Gn=!1,lo=null}else throw Error(w(198));so||(so=!0,Ui=u)}}function qt(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function ku(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function zs(e){if(qt(e)!==e)throw Error(w(188))}function Zf(e){var t=e.alternate;if(!t){if(t=qt(e),t===null)throw Error(w(188));return t!==e?null:e}for(var n=e,r=t;;){var o=n.return;if(o===null)break;var i=o.alternate;if(i===null){if(r=o.return,r!==null){n=r;continue}break}if(o.child===i.child){for(i=o.child;i;){if(i===n)return zs(o),e;if(i===r)return zs(o),t;i=i.sibling}throw Error(w(188))}if(n.return!==r.return)n=o,r=i;else{for(var l=!1,a=o.child;a;){if(a===n){l=!0,n=o,r=i;break}if(a===r){l=!0,r=o,n=i;break}a=a.sibling}if(!l){for(a=i.child;a;){if(a===n){l=!0,n=i,r=o;break}if(a===r){l=!0,r=i,n=o;break}a=a.sibling}if(!l)throw Error(w(189))}}if(n.alternate!==r)throw Error(w(190))}if(n.tag!==3)throw Error(w(188));return n.stateNode.current===n?e:t}function Su(e){return e=Zf(e),e!==null?wu(e):null}function wu(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=wu(e);if(t!==null)return t;e=e.sibling}return null}var Cu=Te.unstable_scheduleCallback,Is=Te.unstable_cancelCallback,ed=Te.unstable_shouldYield,td=Te.unstable_requestPaint,J=Te.unstable_now,nd=Te.unstable_getCurrentPriorityLevel,Il=Te.unstable_ImmediatePriority,_u=Te.unstable_UserBlockingPriority,ao=Te.unstable_NormalPriority,rd=Te.unstable_LowPriority,Eu=Te.unstable_IdlePriority,Ao=null,qe=null;function od(e){if(qe&&typeof qe.onCommitFiberRoot=="function")try{qe.onCommitFiberRoot(Ao,e,void 0,(e.current.flags&128)===128)}catch{}}var Ve=Math.clz32?Math.clz32:sd,id=Math.log,ld=Math.LN2;function sd(e){return e>>>=0,e===0?32:31-(id(e)/ld|0)|0}var Tr=64,Lr=4194304;function Vn(e){switch(e&-e){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 e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function uo(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,o=e.suspendedLanes,i=e.pingedLanes,l=n&268435455;if(l!==0){var a=l&~o;a!==0?r=Vn(a):(i&=l,i!==0&&(r=Vn(i)))}else l=n&~o,l!==0?r=Vn(l):i!==0&&(r=Vn(i));if(r===0)return 0;if(t!==0&&t!==r&&!(t&o)&&(o=r&-r,i=t&-t,o>=i||o===16&&(i&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0<t;)n=31-Ve(t),o=1<<n,r|=e[n],t&=~o;return r}function ad(e,t){switch(e){case 1:case 2:case 4:return t+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 t+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 ud(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,o=e.expirationTimes,i=e.pendingLanes;0<i;){var l=31-Ve(i),a=1<<l,s=o[l];s===-1?(!(a&n)||a&r)&&(o[l]=ad(a,t)):s<=t&&(e.expiredLanes|=a),i&=~a}}function Ri(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function Nu(){var e=Tr;return Tr<<=1,!(Tr&4194240)&&(Tr=64),e}function ei(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function vr(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Ve(t),e[t]=n}function cd(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0<n;){var o=31-Ve(n),i=1<<o;t[o]=0,r[o]=-1,e[o]=-1,n&=~i}}function Dl(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-Ve(n),o=1<<r;o&t|e[r]&t&&(e[r]|=t),n&=~o}}var U=0;function Pu(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var Tu,xl,Lu,Ou,Mu,Vi=!1,Or=[],Ct=null,_t=null,Et=null,rr=new Map,or=new Map,vt=[],fd="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 Ds(e,t){switch(e){case"focusin":case"focusout":Ct=null;break;case"dragenter":case"dragleave":_t=null;break;case"mouseover":case"mouseout":Et=null;break;case"pointerover":case"pointerout":rr.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":or.delete(t.pointerId)}}function zn(e,t,n,r,o,i){return e===null||e.nativeEvent!==i?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:i,targetContainers:[o]},t!==null&&(t=Sr(t),t!==null&&xl(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,o!==null&&t.indexOf(o)===-1&&t.push(o),e)}function dd(e,t,n,r,o){switch(t){case"focusin":return Ct=zn(Ct,e,t,n,r,o),!0;case"dragenter":return _t=zn(_t,e,t,n,r,o),!0;case"mouseover":return Et=zn(Et,e,t,n,r,o),!0;case"pointerover":var i=o.pointerId;return rr.set(i,zn(rr.get(i)||null,e,t,n,r,o)),!0;case"gotpointercapture":return i=o.pointerId,or.set(i,zn(or.get(i)||null,e,t,n,r,o)),!0}return!1}function Au(e){var t=$t(e.target);if(t!==null){var n=qt(t);if(n!==null){if(t=n.tag,t===13){if(t=ku(n),t!==null){e.blockedOn=t,Mu(e.priority,function(){Lu(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Qr(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=Wi(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);Bi=r,n.target.dispatchEvent(r),Bi=null}else return t=Sr(n),t!==null&&xl(t),e.blockedOn=n,!1;t.shift()}return!0}function xs(e,t,n){Qr(e)&&n.delete(t)}function pd(){Vi=!1,Ct!==null&&Qr(Ct)&&(Ct=null),_t!==null&&Qr(_t)&&(_t=null),Et!==null&&Qr(Et)&&(Et=null),rr.forEach(xs),or.forEach(xs)}function In(e,t){e.blockedOn===t&&(e.blockedOn=null,Vi||(Vi=!0,Te.unstable_scheduleCallback(Te.unstable_NormalPriority,pd)))}function ir(e){function t(o){return In(o,e)}if(0<Or.length){In(Or[0],e);for(var n=1;n<Or.length;n++){var r=Or[n];r.blockedOn===e&&(r.blockedOn=null)}}for(Ct!==null&&In(Ct,e),_t!==null&&In(_t,e),Et!==null&&In(Et,e),rr.forEach(t),or.forEach(t),n=0;n<vt.length;n++)r=vt[n],r.blockedOn===e&&(r.blockedOn=null);for(;0<vt.length&&(n=vt[0],n.blockedOn===null);)Au(n),n.blockedOn===null&&vt.shift()}var mn=ut.ReactCurrentBatchConfig,co=!0;function hd(e,t,n,r){var o=U,i=mn.transition;mn.transition=null;try{U=1,Bl(e,t,n,r)}finally{U=o,mn.transition=i}}function md(e,t,n,r){var o=U,i=mn.transition;mn.transition=null;try{U=4,Bl(e,t,n,r)}finally{U=o,mn.transition=i}}function Bl(e,t,n,r){if(co){var o=Wi(e,t,n,r);if(o===null)ci(e,t,r,fo,n),Ds(e,r);else if(dd(o,e,t,n,r))r.stopPropagation();else if(Ds(e,r),t&4&&-1<fd.indexOf(e)){for(;o!==null;){var i=Sr(o);if(i!==null&&Tu(i),i=Wi(e,t,n,r),i===null&&ci(e,t,r,fo,n),i===o)break;o=i}o!==null&&r.stopPropagation()}else ci(e,t,r,null,n)}}var fo=null;function Wi(e,t,n,r){if(fo=null,e=zl(r),e=$t(e),e!==null)if(t=qt(e),t===null)e=null;else if(n=t.tag,n===13){if(e=ku(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null);return fo=e,null}function ju(e){switch(e){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(nd()){case Il:return 1;case _u:return 4;case ao:case rd:return 16;case Eu:return 536870912;default:return 16}default:return 16}}var St=null,Fl=null,Gr=null;function zu(){if(Gr)return Gr;var e,t=Fl,n=t.length,r,o="value"in St?St.value:St.textContent,i=o.length;for(e=0;e<n&&t[e]===o[e];e++);var l=n-e;for(r=1;r<=l&&t[n-r]===o[i-r];r++);return Gr=o.slice(e,1<r?1-r:void 0)}function Kr(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function Mr(){return!0}function Bs(){return!1}function Oe(e){function t(n,r,o,i,l){this._reactName=n,this._targetInst=o,this.type=r,this.nativeEvent=i,this.target=l,this.currentTarget=null;for(var a in e)e.hasOwnProperty(a)&&(n=e[a],this[a]=n?n(i):i[a]);return this.isDefaultPrevented=(i.defaultPrevented!=null?i.defaultPrevented:i.returnValue===!1)?Mr:Bs,this.isPropagationStopped=Bs,this}return b(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=Mr)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=Mr)},persist:function(){},isPersistent:Mr}),t}var Pn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},$l=Oe(Pn),kr=b({},Pn,{view:0,detail:0}),yd=Oe(kr),ti,ni,Dn,jo=b({},kr,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Ul,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==Dn&&(Dn&&e.type==="mousemove"?(ti=e.screenX-Dn.screenX,ni=e.screenY-Dn.screenY):ni=ti=0,Dn=e),ti)},movementY:function(e){return"movementY"in e?e.movementY:ni}}),Fs=Oe(jo),gd=b({},jo,{dataTransfer:0}),vd=Oe(gd),kd=b({},kr,{relatedTarget:0}),ri=Oe(kd),Sd=b({},Pn,{animationName:0,elapsedTime:0,pseudoElement:0}),wd=Oe(Sd),Cd=b({},Pn,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),_d=Oe(Cd),Ed=b({},Pn,{data:0}),$s=Oe(Ed),Nd={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Pd={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"},Td={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Ld(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Td[e])?!!t[e]:!1}function Ul(){return Ld}var Od=b({},kr,{key:function(e){if(e.key){var t=Nd[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Kr(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?Pd[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Ul,charCode:function(e){return e.type==="keypress"?Kr(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Kr(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),Md=Oe(Od),Ad=b({},jo,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Us=Oe(Ad),jd=b({},kr,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Ul}),zd=Oe(jd),Id=b({},Pn,{propertyName:0,elapsedTime:0,pseudoElement:0}),Dd=Oe(Id),xd=b({},jo,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),Bd=Oe(xd),Fd=[9,13,27,32],Rl=it&&"CompositionEvent"in window,Kn=null;it&&"documentMode"in document&&(Kn=document.documentMode);var $d=it&&"TextEvent"in window&&!Kn,Iu=it&&(!Rl||Kn&&8<Kn&&11>=Kn),Rs=" ",Vs=!1;function Du(e,t){switch(e){case"keyup":return Fd.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function xu(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var tn=!1;function Ud(e,t){switch(e){case"compositionend":return xu(t);case"keypress":return t.which!==32?null:(Vs=!0,Rs);case"textInput":return e=t.data,e===Rs&&Vs?null:e;default:return null}}function Rd(e,t){if(tn)return e==="compositionend"||!Rl&&Du(e,t)?(e=zu(),Gr=Fl=St=null,tn=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return Iu&&t.locale!=="ko"?null:t.data;default:return null}}var Vd={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 Ws(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!Vd[e.type]:t==="textarea"}function Bu(e,t,n,r){hu(r),t=po(t,"onChange"),0<t.length&&(n=new $l("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Yn=null,lr=null;function Wd(e){Yu(e,0)}function zo(e){var t=on(e);if(su(t))return e}function Hd(e,t){if(e==="change")return t}var Fu=!1;if(it){var oi;if(it){var ii="oninput"in document;if(!ii){var Hs=document.createElement("div");Hs.setAttribute("oninput","return;"),ii=typeof Hs.oninput=="function"}oi=ii}else oi=!1;Fu=oi&&(!document.documentMode||9<document.documentMode)}function Qs(){Yn&&(Yn.detachEvent("onpropertychange",$u),lr=Yn=null)}function $u(e){if(e.propertyName==="value"&&zo(lr)){var t=[];Bu(t,lr,e,zl(e)),vu(Wd,t)}}function Qd(e,t,n){e==="focusin"?(Qs(),Yn=t,lr=n,Yn.attachEvent("onpropertychange",$u)):e==="focusout"&&Qs()}function Gd(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return zo(lr)}function Kd(e,t){if(e==="click")return zo(t)}function Yd(e,t){if(e==="input"||e==="change")return zo(t)}function bd(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var He=typeof Object.is=="function"?Object.is:bd;function sr(e,t){if(He(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var o=n[r];if(!Ni.call(t,o)||!He(e[o],t[o]))return!1}return!0}function Gs(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Ks(e,t){var n=Gs(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=Gs(n)}}function Uu(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Uu(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Ru(){for(var e=window,t=io();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=io(e.document)}return t}function Vl(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function qd(e){var t=Ru(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&Uu(n.ownerDocument.documentElement,n)){if(r!==null&&Vl(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var o=n.textContent.length,i=Math.min(r.start,o);r=r.end===void 0?i:Math.min(r.end,o),!e.extend&&i>r&&(o=r,r=i,i=o),o=Ks(n,i);var l=Ks(n,r);o&&l&&(e.rangeCount!==1||e.anchorNode!==o.node||e.anchorOffset!==o.offset||e.focusNode!==l.node||e.focusOffset!==l.offset)&&(t=t.createRange(),t.setStart(o.node,o.offset),e.removeAllRanges(),i>r?(e.addRange(t),e.extend(l.node,l.offset)):(t.setEnd(l.node,l.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n<t.length;n++)e=t[n],e.element.scrollLeft=e.left,e.element.scrollTop=e.top}}var Xd=it&&"documentMode"in document&&11>=document.documentMode,nn=null,Hi=null,bn=null,Qi=!1;function Ys(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Qi||nn==null||nn!==io(r)||(r=nn,"selectionStart"in r&&Vl(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),bn&&sr(bn,r)||(bn=r,r=po(Hi,"onSelect"),0<r.length&&(t=new $l("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=nn)))}function Ar(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var rn={animationend:Ar("Animation","AnimationEnd"),animationiteration:Ar("Animation","AnimationIteration"),animationstart:Ar("Animation","AnimationStart"),transitionend:Ar("Transition","TransitionEnd")},li={},Vu={};it&&(Vu=document.createElement("div").style,"AnimationEvent"in window||(delete rn.animationend.animation,delete rn.animationiteration.animation,delete rn.animationstart.animation),"TransitionEvent"in window||delete rn.transitionend.transition);function Io(e){if(li[e])return li[e];if(!rn[e])return e;var t=rn[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Vu)return li[e]=t[n];return e}var Wu=Io("animationend"),Hu=Io("animationiteration"),Qu=Io("animationstart"),Gu=Io("transitionend"),Ku=new Map,bs="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 zt(e,t){Ku.set(e,t),bt(t,[e])}for(var si=0;si<bs.length;si++){var ai=bs[si],Jd=ai.toLowerCase(),Zd=ai[0].toUpperCase()+ai.slice(1);zt(Jd,"on"+Zd)}zt(Wu,"onAnimationEnd");zt(Hu,"onAnimationIteration");zt(Qu,"onAnimationStart");zt("dblclick","onDoubleClick");zt("focusin","onFocus");zt("focusout","onBlur");zt(Gu,"onTransitionEnd");vn("onMouseEnter",["mouseout","mouseover"]);vn("onMouseLeave",["mouseout","mouseover"]);vn("onPointerEnter",["pointerout","pointerover"]);vn("onPointerLeave",["pointerout","pointerover"]);bt("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));bt("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));bt("onBeforeInput",["compositionend","keypress","textInput","paste"]);bt("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));bt("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));bt("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Wn="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(" "),ep=new Set("cancel close invalid load scroll toggle".split(" ").concat(Wn));function qs(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,Jf(r,t,void 0,e),e.currentTarget=null}function Yu(e,t){t=(t&4)!==0;for(var n=0;n<e.length;n++){var r=e[n],o=r.event;r=r.listeners;e:{var i=void 0;if(t)for(var l=r.length-1;0<=l;l--){var a=r[l],s=a.instance,u=a.currentTarget;if(a=a.listener,s!==i&&o.isPropagationStopped())break e;qs(o,a,u),i=s}else for(l=0;l<r.length;l++){if(a=r[l],s=a.instance,u=a.currentTarget,a=a.listener,s!==i&&o.isPropagationStopped())break e;qs(o,a,u),i=s}}}if(so)throw e=Ui,so=!1,Ui=null,e}function H(e,t){var n=t[qi];n===void 0&&(n=t[qi]=new Set);var r=e+"__bubble";n.has(r)||(bu(t,e,2,!1),n.add(r))}function ui(e,t,n){var r=0;t&&(r|=4),bu(n,e,r,t)}var jr="_reactListening"+Math.random().toString(36).slice(2);function ar(e){if(!e[jr]){e[jr]=!0,nu.forEach(function(n){n!=="selectionchange"&&(ep.has(n)||ui(n,!1,e),ui(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[jr]||(t[jr]=!0,ui("selectionchange",!1,t))}}function bu(e,t,n,r){switch(ju(t)){case 1:var o=hd;break;case 4:o=md;break;default:o=Bl}n=o.bind(null,t,n,e),o=void 0,!$i||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(o=!0),r?o!==void 0?e.addEventListener(t,n,{capture:!0,passive:o}):e.addEventListener(t,n,!0):o!==void 0?e.addEventListener(t,n,{passive:o}):e.addEventListener(t,n,!1)}function ci(e,t,n,r,o){var i=r;if(!(t&1)&&!(t&2)&&r!==null)e:for(;;){if(r===null)return;var l=r.tag;if(l===3||l===4){var a=r.stateNode.containerInfo;if(a===o||a.nodeType===8&&a.parentNode===o)break;if(l===4)for(l=r.return;l!==null;){var s=l.tag;if((s===3||s===4)&&(s=l.stateNode.containerInfo,s===o||s.nodeType===8&&s.parentNode===o))return;l=l.return}for(;a!==null;){if(l=$t(a),l===null)return;if(s=l.tag,s===5||s===6){r=i=l;continue e}a=a.parentNode}}r=r.return}vu(function(){var u=i,m=zl(n),c=[];e:{var f=Ku.get(e);if(f!==void 0){var v=$l,y=e;switch(e){case"keypress":if(Kr(n)===0)break e;case"keydown":case"keyup":v=Md;break;case"focusin":y="focus",v=ri;break;case"focusout":y="blur",v=ri;break;case"beforeblur":case"afterblur":v=ri;break;case"click":if(n.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":v=Fs;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":v=vd;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":v=zd;break;case Wu:case Hu:case Qu:v=wd;break;case Gu:v=Dd;break;case"scroll":v=yd;break;case"wheel":v=Bd;break;case"copy":case"cut":case"paste":v=_d;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":v=Us}var g=(t&4)!==0,N=!g&&e==="scroll",p=g?f!==null?f+"Capture":null:f;g=[];for(var d=u,h;d!==null;){h=d;var k=h.stateNode;if(h.tag===5&&k!==null&&(h=k,p!==null&&(k=nr(d,p),k!=null&&g.push(ur(d,k,h)))),N)break;d=d.return}0<g.length&&(f=new v(f,y,null,n,m),c.push({event:f,listeners:g}))}}if(!(t&7)){e:{if(f=e==="mouseover"||e==="pointerover",v=e==="mouseout"||e==="pointerout",f&&n!==Bi&&(y=n.relatedTarget||n.fromElement)&&($t(y)||y[lt]))break e;if((v||f)&&(f=m.window===m?m:(f=m.ownerDocument)?f.defaultView||f.parentWindow:window,v?(y=n.relatedTarget||n.toElement,v=u,y=y?$t(y):null,y!==null&&(N=qt(y),y!==N||y.tag!==5&&y.tag!==6)&&(y=null)):(v=null,y=u),v!==y)){if(g=Fs,k="onMouseLeave",p="onMouseEnter",d="mouse",(e==="pointerout"||e==="pointerover")&&(g=Us,k="onPointerLeave",p="onPointerEnter",d="pointer"),N=v==null?f:on(v),h=y==null?f:on(y),f=new g(k,d+"leave",v,n,m),f.target=N,f.relatedTarget=h,k=null,$t(m)===u&&(g=new g(p,d+"enter",y,n,m),g.target=h,g.relatedTarget=N,k=g),N=k,v&&y)t:{for(g=v,p=y,d=0,h=g;h;h=Jt(h))d++;for(h=0,k=p;k;k=Jt(k))h++;for(;0<d-h;)g=Jt(g),d--;for(;0<h-d;)p=Jt(p),h--;for(;d--;){if(g===p||p!==null&&g===p.alternate)break t;g=Jt(g),p=Jt(p)}g=null}else g=null;v!==null&&Xs(c,f,v,g,!1),y!==null&&N!==null&&Xs(c,N,y,g,!0)}}e:{if(f=u?on(u):window,v=f.nodeName&&f.nodeName.toLowerCase(),v==="select"||v==="input"&&f.type==="file")var C=Hd;else if(Ws(f))if(Fu)C=Yd;else{C=Gd;var P=Qd}else(v=f.nodeName)&&v.toLowerCase()==="input"&&(f.type==="checkbox"||f.type==="radio")&&(C=Kd);if(C&&(C=C(e,u))){Bu(c,C,n,m);break e}P&&P(e,f,u),e==="focusout"&&(P=f._wrapperState)&&P.controlled&&f.type==="number"&&ji(f,"number",f.value)}switch(P=u?on(u):window,e){case"focusin":(Ws(P)||P.contentEditable==="true")&&(nn=P,Hi=u,bn=null);break;case"focusout":bn=Hi=nn=null;break;case"mousedown":Qi=!0;break;case"contextmenu":case"mouseup":case"dragend":Qi=!1,Ys(c,n,m);break;case"selectionchange":if(Xd)break;case"keydown":case"keyup":Ys(c,n,m)}var E;if(Rl)e:{switch(e){case"compositionstart":var _="onCompositionStart";break e;case"compositionend":_="onCompositionEnd";break e;case"compositionupdate":_="onCompositionUpdate";break e}_=void 0}else tn?Du(e,n)&&(_="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(_="onCompositionStart");_&&(Iu&&n.locale!=="ko"&&(tn||_!=="onCompositionStart"?_==="onCompositionEnd"&&tn&&(E=zu()):(St=m,Fl="value"in St?St.value:St.textContent,tn=!0)),P=po(u,_),0<P.length&&(_=new $s(_,e,null,n,m),c.push({event:_,listeners:P}),E?_.data=E:(E=xu(n),E!==null&&(_.data=E)))),(E=$d?Ud(e,n):Rd(e,n))&&(u=po(u,"onBeforeInput"),0<u.length&&(m=new $s("onBeforeInput","beforeinput",null,n,m),c.push({event:m,listeners:u}),m.data=E))}Yu(c,t)})}function ur(e,t,n){return{instance:e,listener:t,currentTarget:n}}function po(e,t){for(var n=t+"Capture",r=[];e!==null;){var o=e,i=o.stateNode;o.tag===5&&i!==null&&(o=i,i=nr(e,n),i!=null&&r.unshift(ur(e,i,o)),i=nr(e,t),i!=null&&r.push(ur(e,i,o))),e=e.return}return r}function Jt(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function Xs(e,t,n,r,o){for(var i=t._reactName,l=[];n!==null&&n!==r;){var a=n,s=a.alternate,u=a.stateNode;if(s!==null&&s===r)break;a.tag===5&&u!==null&&(a=u,o?(s=nr(n,i),s!=null&&l.unshift(ur(n,s,a))):o||(s=nr(n,i),s!=null&&l.push(ur(n,s,a)))),n=n.return}l.length!==0&&e.push({event:t,listeners:l})}var tp=/\r\n?/g,np=/\u0000|\uFFFD/g;function Js(e){return(typeof e=="string"?e:""+e).replace(tp,`
|
||
`).replace(np,"")}function zr(e,t,n){if(t=Js(t),Js(e)!==t&&n)throw Error(w(425))}function ho(){}var Gi=null,Ki=null;function Yi(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var bi=typeof setTimeout=="function"?setTimeout:void 0,rp=typeof clearTimeout=="function"?clearTimeout:void 0,Zs=typeof Promise=="function"?Promise:void 0,op=typeof queueMicrotask=="function"?queueMicrotask:typeof Zs<"u"?function(e){return Zs.resolve(null).then(e).catch(ip)}:bi;function ip(e){setTimeout(function(){throw e})}function fi(e,t){var n=t,r=0;do{var o=n.nextSibling;if(e.removeChild(n),o&&o.nodeType===8)if(n=o.data,n==="/$"){if(r===0){e.removeChild(o),ir(t);return}r--}else n!=="$"&&n!=="$?"&&n!=="$!"||r++;n=o}while(n);ir(t)}function Nt(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?")break;if(t==="/$")return null}}return e}function ea(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="$"||n==="$!"||n==="$?"){if(t===0)return e;t--}else n==="/$"&&t++}e=e.previousSibling}return null}var Tn=Math.random().toString(36).slice(2),be="__reactFiber$"+Tn,cr="__reactProps$"+Tn,lt="__reactContainer$"+Tn,qi="__reactEvents$"+Tn,lp="__reactListeners$"+Tn,sp="__reactHandles$"+Tn;function $t(e){var t=e[be];if(t)return t;for(var n=e.parentNode;n;){if(t=n[lt]||n[be]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=ea(e);e!==null;){if(n=e[be])return n;e=ea(e)}return t}e=n,n=e.parentNode}return null}function Sr(e){return e=e[be]||e[lt],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function on(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(w(33))}function Do(e){return e[cr]||null}var Xi=[],ln=-1;function It(e){return{current:e}}function Q(e){0>ln||(e.current=Xi[ln],Xi[ln]=null,ln--)}function V(e,t){ln++,Xi[ln]=e.current,e.current=t}var jt={},pe=It(jt),Se=It(!1),Ht=jt;function kn(e,t){var n=e.type.contextTypes;if(!n)return jt;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var o={},i;for(i in n)o[i]=t[i];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=o),o}function we(e){return e=e.childContextTypes,e!=null}function mo(){Q(Se),Q(pe)}function ta(e,t,n){if(pe.current!==jt)throw Error(w(168));V(pe,t),V(Se,n)}function qu(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var o in r)if(!(o in t))throw Error(w(108,Qf(e)||"Unknown",o));return b({},n,r)}function yo(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||jt,Ht=pe.current,V(pe,e),V(Se,Se.current),!0}function na(e,t,n){var r=e.stateNode;if(!r)throw Error(w(169));n?(e=qu(e,t,Ht),r.__reactInternalMemoizedMergedChildContext=e,Q(Se),Q(pe),V(pe,e)):Q(Se),V(Se,n)}var tt=null,xo=!1,di=!1;function Xu(e){tt===null?tt=[e]:tt.push(e)}function ap(e){xo=!0,Xu(e)}function Dt(){if(!di&&tt!==null){di=!0;var e=0,t=U;try{var n=tt;for(U=1;e<n.length;e++){var r=n[e];do r=r(!0);while(r!==null)}tt=null,xo=!1}catch(o){throw tt!==null&&(tt=tt.slice(e+1)),Cu(Il,Dt),o}finally{U=t,di=!1}}return null}var sn=[],an=0,go=null,vo=0,Me=[],Ae=0,Qt=null,nt=1,rt="";function Bt(e,t){sn[an++]=vo,sn[an++]=go,go=e,vo=t}function Ju(e,t,n){Me[Ae++]=nt,Me[Ae++]=rt,Me[Ae++]=Qt,Qt=e;var r=nt;e=rt;var o=32-Ve(r)-1;r&=~(1<<o),n+=1;var i=32-Ve(t)+o;if(30<i){var l=o-o%5;i=(r&(1<<l)-1).toString(32),r>>=l,o-=l,nt=1<<32-Ve(t)+o|n<<o|r,rt=i+e}else nt=1<<i|n<<o|r,rt=e}function Wl(e){e.return!==null&&(Bt(e,1),Ju(e,1,0))}function Hl(e){for(;e===go;)go=sn[--an],sn[an]=null,vo=sn[--an],sn[an]=null;for(;e===Qt;)Qt=Me[--Ae],Me[Ae]=null,rt=Me[--Ae],Me[Ae]=null,nt=Me[--Ae],Me[Ae]=null}var Pe=null,Ne=null,G=!1,Re=null;function Zu(e,t){var n=ze(5,null,null,0);n.elementType="DELETED",n.stateNode=t,n.return=e,t=e.deletions,t===null?(e.deletions=[n],e.flags|=16):t.push(n)}function ra(e,t){switch(e.tag){case 5:var n=e.type;return t=t.nodeType!==1||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,Pe=e,Ne=Nt(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,Pe=e,Ne=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(n=Qt!==null?{id:nt,overflow:rt}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},n=ze(18,null,null,0),n.stateNode=t,n.return=e,e.child=n,Pe=e,Ne=null,!0):!1;default:return!1}}function Ji(e){return(e.mode&1)!==0&&(e.flags&128)===0}function Zi(e){if(G){var t=Ne;if(t){var n=t;if(!ra(e,t)){if(Ji(e))throw Error(w(418));t=Nt(n.nextSibling);var r=Pe;t&&ra(e,t)?Zu(r,n):(e.flags=e.flags&-4097|2,G=!1,Pe=e)}}else{if(Ji(e))throw Error(w(418));e.flags=e.flags&-4097|2,G=!1,Pe=e}}}function oa(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;Pe=e}function Ir(e){if(e!==Pe)return!1;if(!G)return oa(e),G=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!Yi(e.type,e.memoizedProps)),t&&(t=Ne)){if(Ji(e))throw ec(),Error(w(418));for(;t;)Zu(e,t),t=Nt(t.nextSibling)}if(oa(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(w(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){Ne=Nt(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}Ne=null}}else Ne=Pe?Nt(e.stateNode.nextSibling):null;return!0}function ec(){for(var e=Ne;e;)e=Nt(e.nextSibling)}function Sn(){Ne=Pe=null,G=!1}function Ql(e){Re===null?Re=[e]:Re.push(e)}var up=ut.ReactCurrentBatchConfig;function xn(e,t,n){if(e=n.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(n._owner){if(n=n._owner,n){if(n.tag!==1)throw Error(w(309));var r=n.stateNode}if(!r)throw Error(w(147,e));var o=r,i=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===i?t.ref:(t=function(l){var a=o.refs;l===null?delete a[i]:a[i]=l},t._stringRef=i,t)}if(typeof e!="string")throw Error(w(284));if(!n._owner)throw Error(w(290,e))}return e}function Dr(e,t){throw e=Object.prototype.toString.call(t),Error(w(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function ia(e){var t=e._init;return t(e._payload)}function tc(e){function t(p,d){if(e){var h=p.deletions;h===null?(p.deletions=[d],p.flags|=16):h.push(d)}}function n(p,d){if(!e)return null;for(;d!==null;)t(p,d),d=d.sibling;return null}function r(p,d){for(p=new Map;d!==null;)d.key!==null?p.set(d.key,d):p.set(d.index,d),d=d.sibling;return p}function o(p,d){return p=Ot(p,d),p.index=0,p.sibling=null,p}function i(p,d,h){return p.index=h,e?(h=p.alternate,h!==null?(h=h.index,h<d?(p.flags|=2,d):h):(p.flags|=2,d)):(p.flags|=1048576,d)}function l(p){return e&&p.alternate===null&&(p.flags|=2),p}function a(p,d,h,k){return d===null||d.tag!==6?(d=ki(h,p.mode,k),d.return=p,d):(d=o(d,h),d.return=p,d)}function s(p,d,h,k){var C=h.type;return C===en?m(p,d,h.props.children,k,h.key):d!==null&&(d.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===yt&&ia(C)===d.type)?(k=o(d,h.props),k.ref=xn(p,d,h),k.return=p,k):(k=eo(h.type,h.key,h.props,null,p.mode,k),k.ref=xn(p,d,h),k.return=p,k)}function u(p,d,h,k){return d===null||d.tag!==4||d.stateNode.containerInfo!==h.containerInfo||d.stateNode.implementation!==h.implementation?(d=Si(h,p.mode,k),d.return=p,d):(d=o(d,h.children||[]),d.return=p,d)}function m(p,d,h,k,C){return d===null||d.tag!==7?(d=Wt(h,p.mode,k,C),d.return=p,d):(d=o(d,h),d.return=p,d)}function c(p,d,h){if(typeof d=="string"&&d!==""||typeof d=="number")return d=ki(""+d,p.mode,h),d.return=p,d;if(typeof d=="object"&&d!==null){switch(d.$$typeof){case Er:return h=eo(d.type,d.key,d.props,null,p.mode,h),h.ref=xn(p,null,d),h.return=p,h;case Zt:return d=Si(d,p.mode,h),d.return=p,d;case yt:var k=d._init;return c(p,k(d._payload),h)}if(Rn(d)||An(d))return d=Wt(d,p.mode,h,null),d.return=p,d;Dr(p,d)}return null}function f(p,d,h,k){var C=d!==null?d.key:null;if(typeof h=="string"&&h!==""||typeof h=="number")return C!==null?null:a(p,d,""+h,k);if(typeof h=="object"&&h!==null){switch(h.$$typeof){case Er:return h.key===C?s(p,d,h,k):null;case Zt:return h.key===C?u(p,d,h,k):null;case yt:return C=h._init,f(p,d,C(h._payload),k)}if(Rn(h)||An(h))return C!==null?null:m(p,d,h,k,null);Dr(p,h)}return null}function v(p,d,h,k,C){if(typeof k=="string"&&k!==""||typeof k=="number")return p=p.get(h)||null,a(d,p,""+k,C);if(typeof k=="object"&&k!==null){switch(k.$$typeof){case Er:return p=p.get(k.key===null?h:k.key)||null,s(d,p,k,C);case Zt:return p=p.get(k.key===null?h:k.key)||null,u(d,p,k,C);case yt:var P=k._init;return v(p,d,h,P(k._payload),C)}if(Rn(k)||An(k))return p=p.get(h)||null,m(d,p,k,C,null);Dr(d,k)}return null}function y(p,d,h,k){for(var C=null,P=null,E=d,_=d=0,F=null;E!==null&&_<h.length;_++){E.index>_?(F=E,E=null):F=E.sibling;var A=f(p,E,h[_],k);if(A===null){E===null&&(E=F);break}e&&E&&A.alternate===null&&t(p,E),d=i(A,d,_),P===null?C=A:P.sibling=A,P=A,E=F}if(_===h.length)return n(p,E),G&&Bt(p,_),C;if(E===null){for(;_<h.length;_++)E=c(p,h[_],k),E!==null&&(d=i(E,d,_),P===null?C=E:P.sibling=E,P=E);return G&&Bt(p,_),C}for(E=r(p,E);_<h.length;_++)F=v(E,p,_,h[_],k),F!==null&&(e&&F.alternate!==null&&E.delete(F.key===null?_:F.key),d=i(F,d,_),P===null?C=F:P.sibling=F,P=F);return e&&E.forEach(function(ue){return t(p,ue)}),G&&Bt(p,_),C}function g(p,d,h,k){var C=An(h);if(typeof C!="function")throw Error(w(150));if(h=C.call(h),h==null)throw Error(w(151));for(var P=C=null,E=d,_=d=0,F=null,A=h.next();E!==null&&!A.done;_++,A=h.next()){E.index>_?(F=E,E=null):F=E.sibling;var ue=f(p,E,A.value,k);if(ue===null){E===null&&(E=F);break}e&&E&&ue.alternate===null&&t(p,E),d=i(ue,d,_),P===null?C=ue:P.sibling=ue,P=ue,E=F}if(A.done)return n(p,E),G&&Bt(p,_),C;if(E===null){for(;!A.done;_++,A=h.next())A=c(p,A.value,k),A!==null&&(d=i(A,d,_),P===null?C=A:P.sibling=A,P=A);return G&&Bt(p,_),C}for(E=r(p,E);!A.done;_++,A=h.next())A=v(E,p,_,A.value,k),A!==null&&(e&&A.alternate!==null&&E.delete(A.key===null?_:A.key),d=i(A,d,_),P===null?C=A:P.sibling=A,P=A);return e&&E.forEach(function(ct){return t(p,ct)}),G&&Bt(p,_),C}function N(p,d,h,k){if(typeof h=="object"&&h!==null&&h.type===en&&h.key===null&&(h=h.props.children),typeof h=="object"&&h!==null){switch(h.$$typeof){case Er:e:{for(var C=h.key,P=d;P!==null;){if(P.key===C){if(C=h.type,C===en){if(P.tag===7){n(p,P.sibling),d=o(P,h.props.children),d.return=p,p=d;break e}}else if(P.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===yt&&ia(C)===P.type){n(p,P.sibling),d=o(P,h.props),d.ref=xn(p,P,h),d.return=p,p=d;break e}n(p,P);break}else t(p,P);P=P.sibling}h.type===en?(d=Wt(h.props.children,p.mode,k,h.key),d.return=p,p=d):(k=eo(h.type,h.key,h.props,null,p.mode,k),k.ref=xn(p,d,h),k.return=p,p=k)}return l(p);case Zt:e:{for(P=h.key;d!==null;){if(d.key===P)if(d.tag===4&&d.stateNode.containerInfo===h.containerInfo&&d.stateNode.implementation===h.implementation){n(p,d.sibling),d=o(d,h.children||[]),d.return=p,p=d;break e}else{n(p,d);break}else t(p,d);d=d.sibling}d=Si(h,p.mode,k),d.return=p,p=d}return l(p);case yt:return P=h._init,N(p,d,P(h._payload),k)}if(Rn(h))return y(p,d,h,k);if(An(h))return g(p,d,h,k);Dr(p,h)}return typeof h=="string"&&h!==""||typeof h=="number"?(h=""+h,d!==null&&d.tag===6?(n(p,d.sibling),d=o(d,h),d.return=p,p=d):(n(p,d),d=ki(h,p.mode,k),d.return=p,p=d),l(p)):n(p,d)}return N}var wn=tc(!0),nc=tc(!1),ko=It(null),So=null,un=null,Gl=null;function Kl(){Gl=un=So=null}function Yl(e){var t=ko.current;Q(ko),e._currentValue=t}function el(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function yn(e,t){So=e,Gl=un=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(ke=!0),e.firstContext=null)}function De(e){var t=e._currentValue;if(Gl!==e)if(e={context:e,memoizedValue:t,next:null},un===null){if(So===null)throw Error(w(308));un=e,So.dependencies={lanes:0,firstContext:e}}else un=un.next=e;return t}var Ut=null;function bl(e){Ut===null?Ut=[e]:Ut.push(e)}function rc(e,t,n,r){var o=t.interleaved;return o===null?(n.next=n,bl(t)):(n.next=o.next,o.next=n),t.interleaved=n,st(e,r)}function st(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var gt=!1;function ql(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function oc(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function ot(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function Pt(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,B&2){var o=r.pending;return o===null?t.next=t:(t.next=o.next,o.next=t),r.pending=t,st(e,n)}return o=r.interleaved,o===null?(t.next=t,bl(r)):(t.next=o.next,o.next=t),r.interleaved=t,st(e,n)}function Yr(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Dl(e,n)}}function la(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var o=null,i=null;if(n=n.firstBaseUpdate,n!==null){do{var l={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};i===null?o=i=l:i=i.next=l,n=n.next}while(n!==null);i===null?o=i=t:i=i.next=t}else o=i=t;n={baseState:r.baseState,firstBaseUpdate:o,lastBaseUpdate:i,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function wo(e,t,n,r){var o=e.updateQueue;gt=!1;var i=o.firstBaseUpdate,l=o.lastBaseUpdate,a=o.shared.pending;if(a!==null){o.shared.pending=null;var s=a,u=s.next;s.next=null,l===null?i=u:l.next=u,l=s;var m=e.alternate;m!==null&&(m=m.updateQueue,a=m.lastBaseUpdate,a!==l&&(a===null?m.firstBaseUpdate=u:a.next=u,m.lastBaseUpdate=s))}if(i!==null){var c=o.baseState;l=0,m=u=s=null,a=i;do{var f=a.lane,v=a.eventTime;if((r&f)===f){m!==null&&(m=m.next={eventTime:v,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var y=e,g=a;switch(f=t,v=n,g.tag){case 1:if(y=g.payload,typeof y=="function"){c=y.call(v,c,f);break e}c=y;break e;case 3:y.flags=y.flags&-65537|128;case 0:if(y=g.payload,f=typeof y=="function"?y.call(v,c,f):y,f==null)break e;c=b({},c,f);break e;case 2:gt=!0}}a.callback!==null&&a.lane!==0&&(e.flags|=64,f=o.effects,f===null?o.effects=[a]:f.push(a))}else v={eventTime:v,lane:f,tag:a.tag,payload:a.payload,callback:a.callback,next:null},m===null?(u=m=v,s=c):m=m.next=v,l|=f;if(a=a.next,a===null){if(a=o.shared.pending,a===null)break;f=a,a=f.next,f.next=null,o.lastBaseUpdate=f,o.shared.pending=null}}while(!0);if(m===null&&(s=c),o.baseState=s,o.firstBaseUpdate=u,o.lastBaseUpdate=m,t=o.shared.interleaved,t!==null){o=t;do l|=o.lane,o=o.next;while(o!==t)}else i===null&&(o.shared.lanes=0);Kt|=l,e.lanes=l,e.memoizedState=c}}function sa(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var r=e[t],o=r.callback;if(o!==null){if(r.callback=null,r=n,typeof o!="function")throw Error(w(191,o));o.call(r)}}}var wr={},Xe=It(wr),fr=It(wr),dr=It(wr);function Rt(e){if(e===wr)throw Error(w(174));return e}function Xl(e,t){switch(V(dr,t),V(fr,e),V(Xe,wr),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:Ii(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=Ii(t,e)}Q(Xe),V(Xe,t)}function Cn(){Q(Xe),Q(fr),Q(dr)}function ic(e){Rt(dr.current);var t=Rt(Xe.current),n=Ii(t,e.type);t!==n&&(V(fr,e),V(Xe,n))}function Jl(e){fr.current===e&&(Q(Xe),Q(fr))}var K=It(0);function Co(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var pi=[];function Zl(){for(var e=0;e<pi.length;e++)pi[e]._workInProgressVersionPrimary=null;pi.length=0}var br=ut.ReactCurrentDispatcher,hi=ut.ReactCurrentBatchConfig,Gt=0,Y=null,te=null,oe=null,_o=!1,qn=!1,pr=0,cp=0;function ce(){throw Error(w(321))}function es(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!He(e[n],t[n]))return!1;return!0}function ts(e,t,n,r,o,i){if(Gt=i,Y=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,br.current=e===null||e.memoizedState===null?hp:mp,e=n(r,o),qn){i=0;do{if(qn=!1,pr=0,25<=i)throw Error(w(301));i+=1,oe=te=null,t.updateQueue=null,br.current=yp,e=n(r,o)}while(qn)}if(br.current=Eo,t=te!==null&&te.next!==null,Gt=0,oe=te=Y=null,_o=!1,t)throw Error(w(300));return e}function ns(){var e=pr!==0;return pr=0,e}function Ye(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return oe===null?Y.memoizedState=oe=e:oe=oe.next=e,oe}function xe(){if(te===null){var e=Y.alternate;e=e!==null?e.memoizedState:null}else e=te.next;var t=oe===null?Y.memoizedState:oe.next;if(t!==null)oe=t,te=e;else{if(e===null)throw Error(w(310));te=e,e={memoizedState:te.memoizedState,baseState:te.baseState,baseQueue:te.baseQueue,queue:te.queue,next:null},oe===null?Y.memoizedState=oe=e:oe=oe.next=e}return oe}function hr(e,t){return typeof t=="function"?t(e):t}function mi(e){var t=xe(),n=t.queue;if(n===null)throw Error(w(311));n.lastRenderedReducer=e;var r=te,o=r.baseQueue,i=n.pending;if(i!==null){if(o!==null){var l=o.next;o.next=i.next,i.next=l}r.baseQueue=o=i,n.pending=null}if(o!==null){i=o.next,r=r.baseState;var a=l=null,s=null,u=i;do{var m=u.lane;if((Gt&m)===m)s!==null&&(s=s.next={lane:0,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),r=u.hasEagerState?u.eagerState:e(r,u.action);else{var c={lane:m,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null};s===null?(a=s=c,l=r):s=s.next=c,Y.lanes|=m,Kt|=m}u=u.next}while(u!==null&&u!==i);s===null?l=r:s.next=a,He(r,t.memoizedState)||(ke=!0),t.memoizedState=r,t.baseState=l,t.baseQueue=s,n.lastRenderedState=r}if(e=n.interleaved,e!==null){o=e;do i=o.lane,Y.lanes|=i,Kt|=i,o=o.next;while(o!==e)}else o===null&&(n.lanes=0);return[t.memoizedState,n.dispatch]}function yi(e){var t=xe(),n=t.queue;if(n===null)throw Error(w(311));n.lastRenderedReducer=e;var r=n.dispatch,o=n.pending,i=t.memoizedState;if(o!==null){n.pending=null;var l=o=o.next;do i=e(i,l.action),l=l.next;while(l!==o);He(i,t.memoizedState)||(ke=!0),t.memoizedState=i,t.baseQueue===null&&(t.baseState=i),n.lastRenderedState=i}return[i,r]}function lc(){}function sc(e,t){var n=Y,r=xe(),o=t(),i=!He(r.memoizedState,o);if(i&&(r.memoizedState=o,ke=!0),r=r.queue,rs(cc.bind(null,n,r,e),[e]),r.getSnapshot!==t||i||oe!==null&&oe.memoizedState.tag&1){if(n.flags|=2048,mr(9,uc.bind(null,n,r,o,t),void 0,null),ie===null)throw Error(w(349));Gt&30||ac(n,t,o)}return o}function ac(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=Y.updateQueue,t===null?(t={lastEffect:null,stores:null},Y.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function uc(e,t,n,r){t.value=n,t.getSnapshot=r,fc(t)&&dc(e)}function cc(e,t,n){return n(function(){fc(t)&&dc(e)})}function fc(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!He(e,n)}catch{return!0}}function dc(e){var t=st(e,1);t!==null&&We(t,e,1,-1)}function aa(e){var t=Ye();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:hr,lastRenderedState:e},t.queue=e,e=e.dispatch=pp.bind(null,Y,e),[t.memoizedState,e]}function mr(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},t=Y.updateQueue,t===null?(t={lastEffect:null,stores:null},Y.updateQueue=t,t.lastEffect=e.next=e):(n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e)),e}function pc(){return xe().memoizedState}function qr(e,t,n,r){var o=Ye();Y.flags|=e,o.memoizedState=mr(1|t,n,void 0,r===void 0?null:r)}function Bo(e,t,n,r){var o=xe();r=r===void 0?null:r;var i=void 0;if(te!==null){var l=te.memoizedState;if(i=l.destroy,r!==null&&es(r,l.deps)){o.memoizedState=mr(t,n,i,r);return}}Y.flags|=e,o.memoizedState=mr(1|t,n,i,r)}function ua(e,t){return qr(8390656,8,e,t)}function rs(e,t){return Bo(2048,8,e,t)}function hc(e,t){return Bo(4,2,e,t)}function mc(e,t){return Bo(4,4,e,t)}function yc(e,t){if(typeof t=="function")return e=e(),t(e),function(){t(null)};if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function gc(e,t,n){return n=n!=null?n.concat([e]):null,Bo(4,4,yc.bind(null,t,e),n)}function os(){}function vc(e,t){var n=xe();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&es(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function kc(e,t){var n=xe();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&es(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function Sc(e,t,n){return Gt&21?(He(n,t)||(n=Nu(),Y.lanes|=n,Kt|=n,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,ke=!0),e.memoizedState=n)}function fp(e,t){var n=U;U=n!==0&&4>n?n:4,e(!0);var r=hi.transition;hi.transition={};try{e(!1),t()}finally{U=n,hi.transition=r}}function wc(){return xe().memoizedState}function dp(e,t,n){var r=Lt(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},Cc(e))_c(t,n);else if(n=rc(e,t,n,r),n!==null){var o=me();We(n,e,r,o),Ec(n,t,r)}}function pp(e,t,n){var r=Lt(e),o={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(Cc(e))_c(t,o);else{var i=e.alternate;if(e.lanes===0&&(i===null||i.lanes===0)&&(i=t.lastRenderedReducer,i!==null))try{var l=t.lastRenderedState,a=i(l,n);if(o.hasEagerState=!0,o.eagerState=a,He(a,l)){var s=t.interleaved;s===null?(o.next=o,bl(t)):(o.next=s.next,s.next=o),t.interleaved=o;return}}catch{}finally{}n=rc(e,t,o,r),n!==null&&(o=me(),We(n,e,r,o),Ec(n,t,r))}}function Cc(e){var t=e.alternate;return e===Y||t!==null&&t===Y}function _c(e,t){qn=_o=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Ec(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Dl(e,n)}}var Eo={readContext:De,useCallback:ce,useContext:ce,useEffect:ce,useImperativeHandle:ce,useInsertionEffect:ce,useLayoutEffect:ce,useMemo:ce,useReducer:ce,useRef:ce,useState:ce,useDebugValue:ce,useDeferredValue:ce,useTransition:ce,useMutableSource:ce,useSyncExternalStore:ce,useId:ce,unstable_isNewReconciler:!1},hp={readContext:De,useCallback:function(e,t){return Ye().memoizedState=[e,t===void 0?null:t],e},useContext:De,useEffect:ua,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,qr(4194308,4,yc.bind(null,t,e),n)},useLayoutEffect:function(e,t){return qr(4194308,4,e,t)},useInsertionEffect:function(e,t){return qr(4,2,e,t)},useMemo:function(e,t){var n=Ye();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=Ye();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=dp.bind(null,Y,e),[r.memoizedState,e]},useRef:function(e){var t=Ye();return e={current:e},t.memoizedState=e},useState:aa,useDebugValue:os,useDeferredValue:function(e){return Ye().memoizedState=e},useTransition:function(){var e=aa(!1),t=e[0];return e=fp.bind(null,e[1]),Ye().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=Y,o=Ye();if(G){if(n===void 0)throw Error(w(407));n=n()}else{if(n=t(),ie===null)throw Error(w(349));Gt&30||ac(r,t,n)}o.memoizedState=n;var i={value:n,getSnapshot:t};return o.queue=i,ua(cc.bind(null,r,i,e),[e]),r.flags|=2048,mr(9,uc.bind(null,r,i,n,t),void 0,null),n},useId:function(){var e=Ye(),t=ie.identifierPrefix;if(G){var n=rt,r=nt;n=(r&~(1<<32-Ve(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=pr++,0<n&&(t+="H"+n.toString(32)),t+=":"}else n=cp++,t=":"+t+"r"+n.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},mp={readContext:De,useCallback:vc,useContext:De,useEffect:rs,useImperativeHandle:gc,useInsertionEffect:hc,useLayoutEffect:mc,useMemo:kc,useReducer:mi,useRef:pc,useState:function(){return mi(hr)},useDebugValue:os,useDeferredValue:function(e){var t=xe();return Sc(t,te.memoizedState,e)},useTransition:function(){var e=mi(hr)[0],t=xe().memoizedState;return[e,t]},useMutableSource:lc,useSyncExternalStore:sc,useId:wc,unstable_isNewReconciler:!1},yp={readContext:De,useCallback:vc,useContext:De,useEffect:rs,useImperativeHandle:gc,useInsertionEffect:hc,useLayoutEffect:mc,useMemo:kc,useReducer:yi,useRef:pc,useState:function(){return yi(hr)},useDebugValue:os,useDeferredValue:function(e){var t=xe();return te===null?t.memoizedState=e:Sc(t,te.memoizedState,e)},useTransition:function(){var e=yi(hr)[0],t=xe().memoizedState;return[e,t]},useMutableSource:lc,useSyncExternalStore:sc,useId:wc,unstable_isNewReconciler:!1};function Fe(e,t){if(e&&e.defaultProps){t=b({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}function tl(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:b({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Fo={isMounted:function(e){return(e=e._reactInternals)?qt(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=me(),o=Lt(e),i=ot(r,o);i.payload=t,n!=null&&(i.callback=n),t=Pt(e,i,o),t!==null&&(We(t,e,o,r),Yr(t,e,o))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=me(),o=Lt(e),i=ot(r,o);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=Pt(e,i,o),t!==null&&(We(t,e,o,r),Yr(t,e,o))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=me(),r=Lt(e),o=ot(n,r);o.tag=2,t!=null&&(o.callback=t),t=Pt(e,o,r),t!==null&&(We(t,e,r,n),Yr(t,e,r))}};function ca(e,t,n,r,o,i,l){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(r,i,l):t.prototype&&t.prototype.isPureReactComponent?!sr(n,r)||!sr(o,i):!0}function Nc(e,t,n){var r=!1,o=jt,i=t.contextType;return typeof i=="object"&&i!==null?i=De(i):(o=we(t)?Ht:pe.current,r=t.contextTypes,i=(r=r!=null)?kn(e,o):jt),t=new t(n,i),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=Fo,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=o,e.__reactInternalMemoizedMaskedChildContext=i),t}function fa(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&Fo.enqueueReplaceState(t,t.state,null)}function nl(e,t,n,r){var o=e.stateNode;o.props=n,o.state=e.memoizedState,o.refs={},ql(e);var i=t.contextType;typeof i=="object"&&i!==null?o.context=De(i):(i=we(t)?Ht:pe.current,o.context=kn(e,i)),o.state=e.memoizedState,i=t.getDerivedStateFromProps,typeof i=="function"&&(tl(e,t,i,n),o.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof o.getSnapshotBeforeUpdate=="function"||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(t=o.state,typeof o.componentWillMount=="function"&&o.componentWillMount(),typeof o.UNSAFE_componentWillMount=="function"&&o.UNSAFE_componentWillMount(),t!==o.state&&Fo.enqueueReplaceState(o,o.state,null),wo(e,n,o,r),o.state=e.memoizedState),typeof o.componentDidMount=="function"&&(e.flags|=4194308)}function _n(e,t){try{var n="",r=t;do n+=Hf(r),r=r.return;while(r);var o=n}catch(i){o=`
|
||
Error generating stack: `+i.message+`
|
||
`+i.stack}return{value:e,source:t,stack:o,digest:null}}function gi(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function rl(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var gp=typeof WeakMap=="function"?WeakMap:Map;function Pc(e,t,n){n=ot(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){Po||(Po=!0,pl=r),rl(e,t)},n}function Tc(e,t,n){n=ot(-1,n),n.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var o=t.value;n.payload=function(){return r(o)},n.callback=function(){rl(e,t)}}var i=e.stateNode;return i!==null&&typeof i.componentDidCatch=="function"&&(n.callback=function(){rl(e,t),typeof r!="function"&&(Tt===null?Tt=new Set([this]):Tt.add(this));var l=t.stack;this.componentDidCatch(t.value,{componentStack:l!==null?l:""})}),n}function da(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new gp;var o=new Set;r.set(t,o)}else o=r.get(t),o===void 0&&(o=new Set,r.set(t,o));o.has(n)||(o.add(n),e=Ap.bind(null,e,t,n),t.then(e,e))}function pa(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function ha(e,t,n,r,o){return e.mode&1?(e.flags|=65536,e.lanes=o,e):(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(t=ot(-1,1),t.tag=2,Pt(n,t,1))),n.lanes|=1),e)}var vp=ut.ReactCurrentOwner,ke=!1;function he(e,t,n,r){t.child=e===null?nc(t,null,n,r):wn(t,e.child,n,r)}function ma(e,t,n,r,o){n=n.render;var i=t.ref;return yn(t,o),r=ts(e,t,n,r,i,o),n=ns(),e!==null&&!ke?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~o,at(e,t,o)):(G&&n&&Wl(t),t.flags|=1,he(e,t,r,o),t.child)}function ya(e,t,n,r,o){if(e===null){var i=n.type;return typeof i=="function"&&!ds(i)&&i.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=i,Lc(e,t,i,r,o)):(e=eo(n.type,null,r,t,t.mode,o),e.ref=t.ref,e.return=t,t.child=e)}if(i=e.child,!(e.lanes&o)){var l=i.memoizedProps;if(n=n.compare,n=n!==null?n:sr,n(l,r)&&e.ref===t.ref)return at(e,t,o)}return t.flags|=1,e=Ot(i,r),e.ref=t.ref,e.return=t,t.child=e}function Lc(e,t,n,r,o){if(e!==null){var i=e.memoizedProps;if(sr(i,r)&&e.ref===t.ref)if(ke=!1,t.pendingProps=r=i,(e.lanes&o)!==0)e.flags&131072&&(ke=!0);else return t.lanes=e.lanes,at(e,t,o)}return ol(e,t,n,r,o)}function Oc(e,t,n){var r=t.pendingProps,o=r.children,i=e!==null?e.memoizedState:null;if(r.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},V(fn,Ee),Ee|=n;else{if(!(n&1073741824))return e=i!==null?i.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,V(fn,Ee),Ee|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=i!==null?i.baseLanes:n,V(fn,Ee),Ee|=r}else i!==null?(r=i.baseLanes|n,t.memoizedState=null):r=n,V(fn,Ee),Ee|=r;return he(e,t,o,n),t.child}function Mc(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function ol(e,t,n,r,o){var i=we(n)?Ht:pe.current;return i=kn(t,i),yn(t,o),n=ts(e,t,n,r,i,o),r=ns(),e!==null&&!ke?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~o,at(e,t,o)):(G&&r&&Wl(t),t.flags|=1,he(e,t,n,o),t.child)}function ga(e,t,n,r,o){if(we(n)){var i=!0;yo(t)}else i=!1;if(yn(t,o),t.stateNode===null)Xr(e,t),Nc(t,n,r),nl(t,n,r,o),r=!0;else if(e===null){var l=t.stateNode,a=t.memoizedProps;l.props=a;var s=l.context,u=n.contextType;typeof u=="object"&&u!==null?u=De(u):(u=we(n)?Ht:pe.current,u=kn(t,u));var m=n.getDerivedStateFromProps,c=typeof m=="function"||typeof l.getSnapshotBeforeUpdate=="function";c||typeof l.UNSAFE_componentWillReceiveProps!="function"&&typeof l.componentWillReceiveProps!="function"||(a!==r||s!==u)&&fa(t,l,r,u),gt=!1;var f=t.memoizedState;l.state=f,wo(t,r,l,o),s=t.memoizedState,a!==r||f!==s||Se.current||gt?(typeof m=="function"&&(tl(t,n,m,r),s=t.memoizedState),(a=gt||ca(t,n,a,r,f,s,u))?(c||typeof l.UNSAFE_componentWillMount!="function"&&typeof l.componentWillMount!="function"||(typeof l.componentWillMount=="function"&&l.componentWillMount(),typeof l.UNSAFE_componentWillMount=="function"&&l.UNSAFE_componentWillMount()),typeof l.componentDidMount=="function"&&(t.flags|=4194308)):(typeof l.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=s),l.props=r,l.state=s,l.context=u,r=a):(typeof l.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{l=t.stateNode,oc(e,t),a=t.memoizedProps,u=t.type===t.elementType?a:Fe(t.type,a),l.props=u,c=t.pendingProps,f=l.context,s=n.contextType,typeof s=="object"&&s!==null?s=De(s):(s=we(n)?Ht:pe.current,s=kn(t,s));var v=n.getDerivedStateFromProps;(m=typeof v=="function"||typeof l.getSnapshotBeforeUpdate=="function")||typeof l.UNSAFE_componentWillReceiveProps!="function"&&typeof l.componentWillReceiveProps!="function"||(a!==c||f!==s)&&fa(t,l,r,s),gt=!1,f=t.memoizedState,l.state=f,wo(t,r,l,o);var y=t.memoizedState;a!==c||f!==y||Se.current||gt?(typeof v=="function"&&(tl(t,n,v,r),y=t.memoizedState),(u=gt||ca(t,n,u,r,f,y,s)||!1)?(m||typeof l.UNSAFE_componentWillUpdate!="function"&&typeof l.componentWillUpdate!="function"||(typeof l.componentWillUpdate=="function"&&l.componentWillUpdate(r,y,s),typeof l.UNSAFE_componentWillUpdate=="function"&&l.UNSAFE_componentWillUpdate(r,y,s)),typeof l.componentDidUpdate=="function"&&(t.flags|=4),typeof l.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof l.componentDidUpdate!="function"||a===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof l.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=y),l.props=r,l.state=y,l.context=s,r=u):(typeof l.componentDidUpdate!="function"||a===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof l.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return il(e,t,n,r,i,o)}function il(e,t,n,r,o,i){Mc(e,t);var l=(t.flags&128)!==0;if(!r&&!l)return o&&na(t,n,!1),at(e,t,i);r=t.stateNode,vp.current=t;var a=l&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&l?(t.child=wn(t,e.child,null,i),t.child=wn(t,null,a,i)):he(e,t,a,i),t.memoizedState=r.state,o&&na(t,n,!0),t.child}function Ac(e){var t=e.stateNode;t.pendingContext?ta(e,t.pendingContext,t.pendingContext!==t.context):t.context&&ta(e,t.context,!1),Xl(e,t.containerInfo)}function va(e,t,n,r,o){return Sn(),Ql(o),t.flags|=256,he(e,t,n,r),t.child}var ll={dehydrated:null,treeContext:null,retryLane:0};function sl(e){return{baseLanes:e,cachePool:null,transitions:null}}function jc(e,t,n){var r=t.pendingProps,o=K.current,i=!1,l=(t.flags&128)!==0,a;if((a=l)||(a=e!==null&&e.memoizedState===null?!1:(o&2)!==0),a?(i=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(o|=1),V(K,o&1),e===null)return Zi(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(t.mode&1?e.data==="$!"?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(l=r.children,e=r.fallback,i?(r=t.mode,i=t.child,l={mode:"hidden",children:l},!(r&1)&&i!==null?(i.childLanes=0,i.pendingProps=l):i=Ro(l,r,0,null),e=Wt(e,r,n,null),i.return=t,e.return=t,i.sibling=e,t.child=i,t.child.memoizedState=sl(n),t.memoizedState=ll,e):is(t,l));if(o=e.memoizedState,o!==null&&(a=o.dehydrated,a!==null))return kp(e,t,l,r,a,o,n);if(i){i=r.fallback,l=t.mode,o=e.child,a=o.sibling;var s={mode:"hidden",children:r.children};return!(l&1)&&t.child!==o?(r=t.child,r.childLanes=0,r.pendingProps=s,t.deletions=null):(r=Ot(o,s),r.subtreeFlags=o.subtreeFlags&14680064),a!==null?i=Ot(a,i):(i=Wt(i,l,n,null),i.flags|=2),i.return=t,r.return=t,r.sibling=i,t.child=r,r=i,i=t.child,l=e.child.memoizedState,l=l===null?sl(n):{baseLanes:l.baseLanes|n,cachePool:null,transitions:l.transitions},i.memoizedState=l,i.childLanes=e.childLanes&~n,t.memoizedState=ll,r}return i=e.child,e=i.sibling,r=Ot(i,{mode:"visible",children:r.children}),!(t.mode&1)&&(r.lanes=n),r.return=t,r.sibling=null,e!==null&&(n=t.deletions,n===null?(t.deletions=[e],t.flags|=16):n.push(e)),t.child=r,t.memoizedState=null,r}function is(e,t){return t=Ro({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function xr(e,t,n,r){return r!==null&&Ql(r),wn(t,e.child,null,n),e=is(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function kp(e,t,n,r,o,i,l){if(n)return t.flags&256?(t.flags&=-257,r=gi(Error(w(422))),xr(e,t,l,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(i=r.fallback,o=t.mode,r=Ro({mode:"visible",children:r.children},o,0,null),i=Wt(i,o,l,null),i.flags|=2,r.return=t,i.return=t,r.sibling=i,t.child=r,t.mode&1&&wn(t,e.child,null,l),t.child.memoizedState=sl(l),t.memoizedState=ll,i);if(!(t.mode&1))return xr(e,t,l,null);if(o.data==="$!"){if(r=o.nextSibling&&o.nextSibling.dataset,r)var a=r.dgst;return r=a,i=Error(w(419)),r=gi(i,r,void 0),xr(e,t,l,r)}if(a=(l&e.childLanes)!==0,ke||a){if(r=ie,r!==null){switch(l&-l){case 4:o=2;break;case 16:o=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:o=32;break;case 536870912:o=268435456;break;default:o=0}o=o&(r.suspendedLanes|l)?0:o,o!==0&&o!==i.retryLane&&(i.retryLane=o,st(e,o),We(r,e,o,-1))}return fs(),r=gi(Error(w(421))),xr(e,t,l,r)}return o.data==="$?"?(t.flags|=128,t.child=e.child,t=jp.bind(null,e),o._reactRetry=t,null):(e=i.treeContext,Ne=Nt(o.nextSibling),Pe=t,G=!0,Re=null,e!==null&&(Me[Ae++]=nt,Me[Ae++]=rt,Me[Ae++]=Qt,nt=e.id,rt=e.overflow,Qt=t),t=is(t,r.children),t.flags|=4096,t)}function ka(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),el(e.return,t,n)}function vi(e,t,n,r,o){var i=e.memoizedState;i===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:o}:(i.isBackwards=t,i.rendering=null,i.renderingStartTime=0,i.last=r,i.tail=n,i.tailMode=o)}function zc(e,t,n){var r=t.pendingProps,o=r.revealOrder,i=r.tail;if(he(e,t,r.children,n),r=K.current,r&2)r=r&1|2,t.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&ka(e,n,t);else if(e.tag===19)ka(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(V(K,r),!(t.mode&1))t.memoizedState=null;else switch(o){case"forwards":for(n=t.child,o=null;n!==null;)e=n.alternate,e!==null&&Co(e)===null&&(o=n),n=n.sibling;n=o,n===null?(o=t.child,t.child=null):(o=n.sibling,n.sibling=null),vi(t,!1,o,n,i);break;case"backwards":for(n=null,o=t.child,t.child=null;o!==null;){if(e=o.alternate,e!==null&&Co(e)===null){t.child=o;break}e=o.sibling,o.sibling=n,n=o,o=e}vi(t,!0,n,null,i);break;case"together":vi(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function Xr(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function at(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Kt|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(w(153));if(t.child!==null){for(e=t.child,n=Ot(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=Ot(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function Sp(e,t,n){switch(t.tag){case 3:Ac(t),Sn();break;case 5:ic(t);break;case 1:we(t.type)&&yo(t);break;case 4:Xl(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,o=t.memoizedProps.value;V(ko,r._currentValue),r._currentValue=o;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(V(K,K.current&1),t.flags|=128,null):n&t.child.childLanes?jc(e,t,n):(V(K,K.current&1),e=at(e,t,n),e!==null?e.sibling:null);V(K,K.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return zc(e,t,n);t.flags|=128}if(o=t.memoizedState,o!==null&&(o.rendering=null,o.tail=null,o.lastEffect=null),V(K,K.current),r)break;return null;case 22:case 23:return t.lanes=0,Oc(e,t,n)}return at(e,t,n)}var Ic,al,Dc,xc;Ic=function(e,t){for(var n=t.child;n!==null;){if(n.tag===5||n.tag===6)e.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}};al=function(){};Dc=function(e,t,n,r){var o=e.memoizedProps;if(o!==r){e=t.stateNode,Rt(Xe.current);var i=null;switch(n){case"input":o=Mi(e,o),r=Mi(e,r),i=[];break;case"select":o=b({},o,{value:void 0}),r=b({},r,{value:void 0}),i=[];break;case"textarea":o=zi(e,o),r=zi(e,r),i=[];break;default:typeof o.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=ho)}Di(n,r);var l;n=null;for(u in o)if(!r.hasOwnProperty(u)&&o.hasOwnProperty(u)&&o[u]!=null)if(u==="style"){var a=o[u];for(l in a)a.hasOwnProperty(l)&&(n||(n={}),n[l]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(er.hasOwnProperty(u)?i||(i=[]):(i=i||[]).push(u,null));for(u in r){var s=r[u];if(a=o!=null?o[u]:void 0,r.hasOwnProperty(u)&&s!==a&&(s!=null||a!=null))if(u==="style")if(a){for(l in a)!a.hasOwnProperty(l)||s&&s.hasOwnProperty(l)||(n||(n={}),n[l]="");for(l in s)s.hasOwnProperty(l)&&a[l]!==s[l]&&(n||(n={}),n[l]=s[l])}else n||(i||(i=[]),i.push(u,n)),n=s;else u==="dangerouslySetInnerHTML"?(s=s?s.__html:void 0,a=a?a.__html:void 0,s!=null&&a!==s&&(i=i||[]).push(u,s)):u==="children"?typeof s!="string"&&typeof s!="number"||(i=i||[]).push(u,""+s):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(er.hasOwnProperty(u)?(s!=null&&u==="onScroll"&&H("scroll",e),i||a===s||(i=[])):(i=i||[]).push(u,s))}n&&(i=i||[]).push("style",n);var u=i;(t.updateQueue=u)&&(t.flags|=4)}};xc=function(e,t,n,r){n!==r&&(t.flags|=4)};function Bn(e,t){if(!G)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function fe(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var o=e.child;o!==null;)n|=o.lanes|o.childLanes,r|=o.subtreeFlags&14680064,r|=o.flags&14680064,o.return=e,o=o.sibling;else for(o=e.child;o!==null;)n|=o.lanes|o.childLanes,r|=o.subtreeFlags,r|=o.flags,o.return=e,o=o.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function wp(e,t,n){var r=t.pendingProps;switch(Hl(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return fe(t),null;case 1:return we(t.type)&&mo(),fe(t),null;case 3:return r=t.stateNode,Cn(),Q(Se),Q(pe),Zl(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(Ir(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Re!==null&&(yl(Re),Re=null))),al(e,t),fe(t),null;case 5:Jl(t);var o=Rt(dr.current);if(n=t.type,e!==null&&t.stateNode!=null)Dc(e,t,n,r,o),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(w(166));return fe(t),null}if(e=Rt(Xe.current),Ir(t)){r=t.stateNode,n=t.type;var i=t.memoizedProps;switch(r[be]=t,r[cr]=i,e=(t.mode&1)!==0,n){case"dialog":H("cancel",r),H("close",r);break;case"iframe":case"object":case"embed":H("load",r);break;case"video":case"audio":for(o=0;o<Wn.length;o++)H(Wn[o],r);break;case"source":H("error",r);break;case"img":case"image":case"link":H("error",r),H("load",r);break;case"details":H("toggle",r);break;case"input":Ls(r,i),H("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!i.multiple},H("invalid",r);break;case"textarea":Ms(r,i),H("invalid",r)}Di(n,i),o=null;for(var l in i)if(i.hasOwnProperty(l)){var a=i[l];l==="children"?typeof a=="string"?r.textContent!==a&&(i.suppressHydrationWarning!==!0&&zr(r.textContent,a,e),o=["children",a]):typeof a=="number"&&r.textContent!==""+a&&(i.suppressHydrationWarning!==!0&&zr(r.textContent,a,e),o=["children",""+a]):er.hasOwnProperty(l)&&a!=null&&l==="onScroll"&&H("scroll",r)}switch(n){case"input":Nr(r),Os(r,i,!0);break;case"textarea":Nr(r),As(r);break;case"select":case"option":break;default:typeof i.onClick=="function"&&(r.onclick=ho)}r=o,t.updateQueue=r,r!==null&&(t.flags|=4)}else{l=o.nodeType===9?o:o.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=cu(n)),e==="http://www.w3.org/1999/xhtml"?n==="script"?(e=l.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=l.createElement(n,{is:r.is}):(e=l.createElement(n),n==="select"&&(l=e,r.multiple?l.multiple=!0:r.size&&(l.size=r.size))):e=l.createElementNS(e,n),e[be]=t,e[cr]=r,Ic(e,t,!1,!1),t.stateNode=e;e:{switch(l=xi(n,r),n){case"dialog":H("cancel",e),H("close",e),o=r;break;case"iframe":case"object":case"embed":H("load",e),o=r;break;case"video":case"audio":for(o=0;o<Wn.length;o++)H(Wn[o],e);o=r;break;case"source":H("error",e),o=r;break;case"img":case"image":case"link":H("error",e),H("load",e),o=r;break;case"details":H("toggle",e),o=r;break;case"input":Ls(e,r),o=Mi(e,r),H("invalid",e);break;case"option":o=r;break;case"select":e._wrapperState={wasMultiple:!!r.multiple},o=b({},r,{value:void 0}),H("invalid",e);break;case"textarea":Ms(e,r),o=zi(e,r),H("invalid",e);break;default:o=r}Di(n,o),a=o;for(i in a)if(a.hasOwnProperty(i)){var s=a[i];i==="style"?pu(e,s):i==="dangerouslySetInnerHTML"?(s=s?s.__html:void 0,s!=null&&fu(e,s)):i==="children"?typeof s=="string"?(n!=="textarea"||s!=="")&&tr(e,s):typeof s=="number"&&tr(e,""+s):i!=="suppressContentEditableWarning"&&i!=="suppressHydrationWarning"&&i!=="autoFocus"&&(er.hasOwnProperty(i)?s!=null&&i==="onScroll"&&H("scroll",e):s!=null&&Ol(e,i,s,l))}switch(n){case"input":Nr(e),Os(e,r,!1);break;case"textarea":Nr(e),As(e);break;case"option":r.value!=null&&e.setAttribute("value",""+At(r.value));break;case"select":e.multiple=!!r.multiple,i=r.value,i!=null?dn(e,!!r.multiple,i,!1):r.defaultValue!=null&&dn(e,!!r.multiple,r.defaultValue,!0);break;default:typeof o.onClick=="function"&&(e.onclick=ho)}switch(n){case"button":case"input":case"select":case"textarea":r=!!r.autoFocus;break e;case"img":r=!0;break e;default:r=!1}}r&&(t.flags|=4)}t.ref!==null&&(t.flags|=512,t.flags|=2097152)}return fe(t),null;case 6:if(e&&t.stateNode!=null)xc(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(w(166));if(n=Rt(dr.current),Rt(Xe.current),Ir(t)){if(r=t.stateNode,n=t.memoizedProps,r[be]=t,(i=r.nodeValue!==n)&&(e=Pe,e!==null))switch(e.tag){case 3:zr(r.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&zr(r.nodeValue,n,(e.mode&1)!==0)}i&&(t.flags|=4)}else r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[be]=t,t.stateNode=r}return fe(t),null;case 13:if(Q(K),r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(G&&Ne!==null&&t.mode&1&&!(t.flags&128))ec(),Sn(),t.flags|=98560,i=!1;else if(i=Ir(t),r!==null&&r.dehydrated!==null){if(e===null){if(!i)throw Error(w(318));if(i=t.memoizedState,i=i!==null?i.dehydrated:null,!i)throw Error(w(317));i[be]=t}else Sn(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;fe(t),i=!1}else Re!==null&&(yl(Re),Re=null),i=!0;if(!i)return t.flags&65536?t:null}return t.flags&128?(t.lanes=n,t):(r=r!==null,r!==(e!==null&&e.memoizedState!==null)&&r&&(t.child.flags|=8192,t.mode&1&&(e===null||K.current&1?ne===0&&(ne=3):fs())),t.updateQueue!==null&&(t.flags|=4),fe(t),null);case 4:return Cn(),al(e,t),e===null&&ar(t.stateNode.containerInfo),fe(t),null;case 10:return Yl(t.type._context),fe(t),null;case 17:return we(t.type)&&mo(),fe(t),null;case 19:if(Q(K),i=t.memoizedState,i===null)return fe(t),null;if(r=(t.flags&128)!==0,l=i.rendering,l===null)if(r)Bn(i,!1);else{if(ne!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(l=Co(e),l!==null){for(t.flags|=128,Bn(i,!1),r=l.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),t.subtreeFlags=0,r=n,n=t.child;n!==null;)i=n,e=r,i.flags&=14680066,l=i.alternate,l===null?(i.childLanes=0,i.lanes=e,i.child=null,i.subtreeFlags=0,i.memoizedProps=null,i.memoizedState=null,i.updateQueue=null,i.dependencies=null,i.stateNode=null):(i.childLanes=l.childLanes,i.lanes=l.lanes,i.child=l.child,i.subtreeFlags=0,i.deletions=null,i.memoizedProps=l.memoizedProps,i.memoizedState=l.memoizedState,i.updateQueue=l.updateQueue,i.type=l.type,e=l.dependencies,i.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return V(K,K.current&1|2),t.child}e=e.sibling}i.tail!==null&&J()>En&&(t.flags|=128,r=!0,Bn(i,!1),t.lanes=4194304)}else{if(!r)if(e=Co(l),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),Bn(i,!0),i.tail===null&&i.tailMode==="hidden"&&!l.alternate&&!G)return fe(t),null}else 2*J()-i.renderingStartTime>En&&n!==1073741824&&(t.flags|=128,r=!0,Bn(i,!1),t.lanes=4194304);i.isBackwards?(l.sibling=t.child,t.child=l):(n=i.last,n!==null?n.sibling=l:t.child=l,i.last=l)}return i.tail!==null?(t=i.tail,i.rendering=t,i.tail=t.sibling,i.renderingStartTime=J(),t.sibling=null,n=K.current,V(K,r?n&1|2:n&1),t):(fe(t),null);case 22:case 23:return cs(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?Ee&1073741824&&(fe(t),t.subtreeFlags&6&&(t.flags|=8192)):fe(t),null;case 24:return null;case 25:return null}throw Error(w(156,t.tag))}function Cp(e,t){switch(Hl(t),t.tag){case 1:return we(t.type)&&mo(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Cn(),Q(Se),Q(pe),Zl(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Jl(t),null;case 13:if(Q(K),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(w(340));Sn()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Q(K),null;case 4:return Cn(),null;case 10:return Yl(t.type._context),null;case 22:case 23:return cs(),null;case 24:return null;default:return null}}var Br=!1,de=!1,_p=typeof WeakSet=="function"?WeakSet:Set,O=null;function cn(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){q(e,t,r)}else n.current=null}function ul(e,t,n){try{n()}catch(r){q(e,t,r)}}var Sa=!1;function Ep(e,t){if(Gi=co,e=Ru(),Vl(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var o=r.anchorOffset,i=r.focusNode;r=r.focusOffset;try{n.nodeType,i.nodeType}catch{n=null;break e}var l=0,a=-1,s=-1,u=0,m=0,c=e,f=null;t:for(;;){for(var v;c!==n||o!==0&&c.nodeType!==3||(a=l+o),c!==i||r!==0&&c.nodeType!==3||(s=l+r),c.nodeType===3&&(l+=c.nodeValue.length),(v=c.firstChild)!==null;)f=c,c=v;for(;;){if(c===e)break t;if(f===n&&++u===o&&(a=l),f===i&&++m===r&&(s=l),(v=c.nextSibling)!==null)break;c=f,f=c.parentNode}c=v}n=a===-1||s===-1?null:{start:a,end:s}}else n=null}n=n||{start:0,end:0}}else n=null;for(Ki={focusedElem:e,selectionRange:n},co=!1,O=t;O!==null;)if(t=O,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,O=e;else for(;O!==null;){t=O;try{var y=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(y!==null){var g=y.memoizedProps,N=y.memoizedState,p=t.stateNode,d=p.getSnapshotBeforeUpdate(t.elementType===t.type?g:Fe(t.type,g),N);p.__reactInternalSnapshotBeforeUpdate=d}break;case 3:var h=t.stateNode.containerInfo;h.nodeType===1?h.textContent="":h.nodeType===9&&h.documentElement&&h.removeChild(h.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(w(163))}}catch(k){q(t,t.return,k)}if(e=t.sibling,e!==null){e.return=t.return,O=e;break}O=t.return}return y=Sa,Sa=!1,y}function Xn(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var o=r=r.next;do{if((o.tag&e)===e){var i=o.destroy;o.destroy=void 0,i!==void 0&&ul(t,n,i)}o=o.next}while(o!==r)}}function $o(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function cl(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function Bc(e){var t=e.alternate;t!==null&&(e.alternate=null,Bc(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[be],delete t[cr],delete t[qi],delete t[lp],delete t[sp])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function Fc(e){return e.tag===5||e.tag===3||e.tag===4}function wa(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Fc(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function fl(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=ho));else if(r!==4&&(e=e.child,e!==null))for(fl(e,t,n),e=e.sibling;e!==null;)fl(e,t,n),e=e.sibling}function dl(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(dl(e,t,n),e=e.sibling;e!==null;)dl(e,t,n),e=e.sibling}var le=null,$e=!1;function ht(e,t,n){for(n=n.child;n!==null;)$c(e,t,n),n=n.sibling}function $c(e,t,n){if(qe&&typeof qe.onCommitFiberUnmount=="function")try{qe.onCommitFiberUnmount(Ao,n)}catch{}switch(n.tag){case 5:de||cn(n,t);case 6:var r=le,o=$e;le=null,ht(e,t,n),le=r,$e=o,le!==null&&($e?(e=le,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):le.removeChild(n.stateNode));break;case 18:le!==null&&($e?(e=le,n=n.stateNode,e.nodeType===8?fi(e.parentNode,n):e.nodeType===1&&fi(e,n),ir(e)):fi(le,n.stateNode));break;case 4:r=le,o=$e,le=n.stateNode.containerInfo,$e=!0,ht(e,t,n),le=r,$e=o;break;case 0:case 11:case 14:case 15:if(!de&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){o=r=r.next;do{var i=o,l=i.destroy;i=i.tag,l!==void 0&&(i&2||i&4)&&ul(n,t,l),o=o.next}while(o!==r)}ht(e,t,n);break;case 1:if(!de&&(cn(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){q(n,t,a)}ht(e,t,n);break;case 21:ht(e,t,n);break;case 22:n.mode&1?(de=(r=de)||n.memoizedState!==null,ht(e,t,n),de=r):ht(e,t,n);break;default:ht(e,t,n)}}function Ca(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new _p),t.forEach(function(r){var o=zp.bind(null,e,r);n.has(r)||(n.add(r),r.then(o,o))})}}function Be(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var o=n[r];try{var i=e,l=t,a=l;e:for(;a!==null;){switch(a.tag){case 5:le=a.stateNode,$e=!1;break e;case 3:le=a.stateNode.containerInfo,$e=!0;break e;case 4:le=a.stateNode.containerInfo,$e=!0;break e}a=a.return}if(le===null)throw Error(w(160));$c(i,l,o),le=null,$e=!1;var s=o.alternate;s!==null&&(s.return=null),o.return=null}catch(u){q(o,t,u)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)Uc(t,e),t=t.sibling}function Uc(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(Be(t,e),Ke(e),r&4){try{Xn(3,e,e.return),$o(3,e)}catch(g){q(e,e.return,g)}try{Xn(5,e,e.return)}catch(g){q(e,e.return,g)}}break;case 1:Be(t,e),Ke(e),r&512&&n!==null&&cn(n,n.return);break;case 5:if(Be(t,e),Ke(e),r&512&&n!==null&&cn(n,n.return),e.flags&32){var o=e.stateNode;try{tr(o,"")}catch(g){q(e,e.return,g)}}if(r&4&&(o=e.stateNode,o!=null)){var i=e.memoizedProps,l=n!==null?n.memoizedProps:i,a=e.type,s=e.updateQueue;if(e.updateQueue=null,s!==null)try{a==="input"&&i.type==="radio"&&i.name!=null&&au(o,i),xi(a,l);var u=xi(a,i);for(l=0;l<s.length;l+=2){var m=s[l],c=s[l+1];m==="style"?pu(o,c):m==="dangerouslySetInnerHTML"?fu(o,c):m==="children"?tr(o,c):Ol(o,m,c,u)}switch(a){case"input":Ai(o,i);break;case"textarea":uu(o,i);break;case"select":var f=o._wrapperState.wasMultiple;o._wrapperState.wasMultiple=!!i.multiple;var v=i.value;v!=null?dn(o,!!i.multiple,v,!1):f!==!!i.multiple&&(i.defaultValue!=null?dn(o,!!i.multiple,i.defaultValue,!0):dn(o,!!i.multiple,i.multiple?[]:"",!1))}o[cr]=i}catch(g){q(e,e.return,g)}}break;case 6:if(Be(t,e),Ke(e),r&4){if(e.stateNode===null)throw Error(w(162));o=e.stateNode,i=e.memoizedProps;try{o.nodeValue=i}catch(g){q(e,e.return,g)}}break;case 3:if(Be(t,e),Ke(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{ir(t.containerInfo)}catch(g){q(e,e.return,g)}break;case 4:Be(t,e),Ke(e);break;case 13:Be(t,e),Ke(e),o=e.child,o.flags&8192&&(i=o.memoizedState!==null,o.stateNode.isHidden=i,!i||o.alternate!==null&&o.alternate.memoizedState!==null||(as=J())),r&4&&Ca(e);break;case 22:if(m=n!==null&&n.memoizedState!==null,e.mode&1?(de=(u=de)||m,Be(t,e),de=u):Be(t,e),Ke(e),r&8192){if(u=e.memoizedState!==null,(e.stateNode.isHidden=u)&&!m&&e.mode&1)for(O=e,m=e.child;m!==null;){for(c=O=m;O!==null;){switch(f=O,v=f.child,f.tag){case 0:case 11:case 14:case 15:Xn(4,f,f.return);break;case 1:cn(f,f.return);var y=f.stateNode;if(typeof y.componentWillUnmount=="function"){r=f,n=f.return;try{t=r,y.props=t.memoizedProps,y.state=t.memoizedState,y.componentWillUnmount()}catch(g){q(r,n,g)}}break;case 5:cn(f,f.return);break;case 22:if(f.memoizedState!==null){Ea(c);continue}}v!==null?(v.return=f,O=v):Ea(c)}m=m.sibling}e:for(m=null,c=e;;){if(c.tag===5){if(m===null){m=c;try{o=c.stateNode,u?(i=o.style,typeof i.setProperty=="function"?i.setProperty("display","none","important"):i.display="none"):(a=c.stateNode,s=c.memoizedProps.style,l=s!=null&&s.hasOwnProperty("display")?s.display:null,a.style.display=du("display",l))}catch(g){q(e,e.return,g)}}}else if(c.tag===6){if(m===null)try{c.stateNode.nodeValue=u?"":c.memoizedProps}catch(g){q(e,e.return,g)}}else if((c.tag!==22&&c.tag!==23||c.memoizedState===null||c===e)&&c.child!==null){c.child.return=c,c=c.child;continue}if(c===e)break e;for(;c.sibling===null;){if(c.return===null||c.return===e)break e;m===c&&(m=null),c=c.return}m===c&&(m=null),c.sibling.return=c.return,c=c.sibling}}break;case 19:Be(t,e),Ke(e),r&4&&Ca(e);break;case 21:break;default:Be(t,e),Ke(e)}}function Ke(e){var t=e.flags;if(t&2){try{e:{for(var n=e.return;n!==null;){if(Fc(n)){var r=n;break e}n=n.return}throw Error(w(160))}switch(r.tag){case 5:var o=r.stateNode;r.flags&32&&(tr(o,""),r.flags&=-33);var i=wa(e);dl(e,i,o);break;case 3:case 4:var l=r.stateNode.containerInfo,a=wa(e);fl(e,a,l);break;default:throw Error(w(161))}}catch(s){q(e,e.return,s)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Np(e,t,n){O=e,Rc(e)}function Rc(e,t,n){for(var r=(e.mode&1)!==0;O!==null;){var o=O,i=o.child;if(o.tag===22&&r){var l=o.memoizedState!==null||Br;if(!l){var a=o.alternate,s=a!==null&&a.memoizedState!==null||de;a=Br;var u=de;if(Br=l,(de=s)&&!u)for(O=o;O!==null;)l=O,s=l.child,l.tag===22&&l.memoizedState!==null?Na(o):s!==null?(s.return=l,O=s):Na(o);for(;i!==null;)O=i,Rc(i),i=i.sibling;O=o,Br=a,de=u}_a(e)}else o.subtreeFlags&8772&&i!==null?(i.return=o,O=i):_a(e)}}function _a(e){for(;O!==null;){var t=O;if(t.flags&8772){var n=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:de||$o(5,t);break;case 1:var r=t.stateNode;if(t.flags&4&&!de)if(n===null)r.componentDidMount();else{var o=t.elementType===t.type?n.memoizedProps:Fe(t.type,n.memoizedProps);r.componentDidUpdate(o,n.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var i=t.updateQueue;i!==null&&sa(t,i,r);break;case 3:var l=t.updateQueue;if(l!==null){if(n=null,t.child!==null)switch(t.child.tag){case 5:n=t.child.stateNode;break;case 1:n=t.child.stateNode}sa(t,l,n)}break;case 5:var a=t.stateNode;if(n===null&&t.flags&4){n=a;var s=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":s.autoFocus&&n.focus();break;case"img":s.src&&(n.src=s.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(t.memoizedState===null){var u=t.alternate;if(u!==null){var m=u.memoizedState;if(m!==null){var c=m.dehydrated;c!==null&&ir(c)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(w(163))}de||t.flags&512&&cl(t)}catch(f){q(t,t.return,f)}}if(t===e){O=null;break}if(n=t.sibling,n!==null){n.return=t.return,O=n;break}O=t.return}}function Ea(e){for(;O!==null;){var t=O;if(t===e){O=null;break}var n=t.sibling;if(n!==null){n.return=t.return,O=n;break}O=t.return}}function Na(e){for(;O!==null;){var t=O;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{$o(4,t)}catch(s){q(t,n,s)}break;case 1:var r=t.stateNode;if(typeof r.componentDidMount=="function"){var o=t.return;try{r.componentDidMount()}catch(s){q(t,o,s)}}var i=t.return;try{cl(t)}catch(s){q(t,i,s)}break;case 5:var l=t.return;try{cl(t)}catch(s){q(t,l,s)}}}catch(s){q(t,t.return,s)}if(t===e){O=null;break}var a=t.sibling;if(a!==null){a.return=t.return,O=a;break}O=t.return}}var Pp=Math.ceil,No=ut.ReactCurrentDispatcher,ls=ut.ReactCurrentOwner,Ie=ut.ReactCurrentBatchConfig,B=0,ie=null,Z=null,se=0,Ee=0,fn=It(0),ne=0,yr=null,Kt=0,Uo=0,ss=0,Jn=null,ve=null,as=0,En=1/0,et=null,Po=!1,pl=null,Tt=null,Fr=!1,wt=null,To=0,Zn=0,hl=null,Jr=-1,Zr=0;function me(){return B&6?J():Jr!==-1?Jr:Jr=J()}function Lt(e){return e.mode&1?B&2&&se!==0?se&-se:up.transition!==null?(Zr===0&&(Zr=Nu()),Zr):(e=U,e!==0||(e=window.event,e=e===void 0?16:ju(e.type)),e):1}function We(e,t,n,r){if(50<Zn)throw Zn=0,hl=null,Error(w(185));vr(e,n,r),(!(B&2)||e!==ie)&&(e===ie&&(!(B&2)&&(Uo|=n),ne===4&&kt(e,se)),Ce(e,r),n===1&&B===0&&!(t.mode&1)&&(En=J()+500,xo&&Dt()))}function Ce(e,t){var n=e.callbackNode;ud(e,t);var r=uo(e,e===ie?se:0);if(r===0)n!==null&&Is(n),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(n!=null&&Is(n),t===1)e.tag===0?ap(Pa.bind(null,e)):Xu(Pa.bind(null,e)),op(function(){!(B&6)&&Dt()}),n=null;else{switch(Pu(r)){case 1:n=Il;break;case 4:n=_u;break;case 16:n=ao;break;case 536870912:n=Eu;break;default:n=ao}n=bc(n,Vc.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function Vc(e,t){if(Jr=-1,Zr=0,B&6)throw Error(w(327));var n=e.callbackNode;if(gn()&&e.callbackNode!==n)return null;var r=uo(e,e===ie?se:0);if(r===0)return null;if(r&30||r&e.expiredLanes||t)t=Lo(e,r);else{t=r;var o=B;B|=2;var i=Hc();(ie!==e||se!==t)&&(et=null,En=J()+500,Vt(e,t));do try{Op();break}catch(a){Wc(e,a)}while(!0);Kl(),No.current=i,B=o,Z!==null?t=0:(ie=null,se=0,t=ne)}if(t!==0){if(t===2&&(o=Ri(e),o!==0&&(r=o,t=ml(e,o))),t===1)throw n=yr,Vt(e,0),kt(e,r),Ce(e,J()),n;if(t===6)kt(e,r);else{if(o=e.current.alternate,!(r&30)&&!Tp(o)&&(t=Lo(e,r),t===2&&(i=Ri(e),i!==0&&(r=i,t=ml(e,i))),t===1))throw n=yr,Vt(e,0),kt(e,r),Ce(e,J()),n;switch(e.finishedWork=o,e.finishedLanes=r,t){case 0:case 1:throw Error(w(345));case 2:Ft(e,ve,et);break;case 3:if(kt(e,r),(r&130023424)===r&&(t=as+500-J(),10<t)){if(uo(e,0)!==0)break;if(o=e.suspendedLanes,(o&r)!==r){me(),e.pingedLanes|=e.suspendedLanes&o;break}e.timeoutHandle=bi(Ft.bind(null,e,ve,et),t);break}Ft(e,ve,et);break;case 4:if(kt(e,r),(r&4194240)===r)break;for(t=e.eventTimes,o=-1;0<r;){var l=31-Ve(r);i=1<<l,l=t[l],l>o&&(o=l),r&=~i}if(r=o,r=J()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*Pp(r/1960))-r,10<r){e.timeoutHandle=bi(Ft.bind(null,e,ve,et),r);break}Ft(e,ve,et);break;case 5:Ft(e,ve,et);break;default:throw Error(w(329))}}}return Ce(e,J()),e.callbackNode===n?Vc.bind(null,e):null}function ml(e,t){var n=Jn;return e.current.memoizedState.isDehydrated&&(Vt(e,t).flags|=256),e=Lo(e,t),e!==2&&(t=ve,ve=n,t!==null&&yl(t)),e}function yl(e){ve===null?ve=e:ve.push.apply(ve,e)}function Tp(e){for(var t=e;;){if(t.flags&16384){var n=t.updateQueue;if(n!==null&&(n=n.stores,n!==null))for(var r=0;r<n.length;r++){var o=n[r],i=o.getSnapshot;o=o.value;try{if(!He(i(),o))return!1}catch{return!1}}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function kt(e,t){for(t&=~ss,t&=~Uo,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-Ve(t),r=1<<n;e[n]=-1,t&=~r}}function Pa(e){if(B&6)throw Error(w(327));gn();var t=uo(e,0);if(!(t&1))return Ce(e,J()),null;var n=Lo(e,t);if(e.tag!==0&&n===2){var r=Ri(e);r!==0&&(t=r,n=ml(e,r))}if(n===1)throw n=yr,Vt(e,0),kt(e,t),Ce(e,J()),n;if(n===6)throw Error(w(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,Ft(e,ve,et),Ce(e,J()),null}function us(e,t){var n=B;B|=1;try{return e(t)}finally{B=n,B===0&&(En=J()+500,xo&&Dt())}}function Yt(e){wt!==null&&wt.tag===0&&!(B&6)&&gn();var t=B;B|=1;var n=Ie.transition,r=U;try{if(Ie.transition=null,U=1,e)return e()}finally{U=r,Ie.transition=n,B=t,!(B&6)&&Dt()}}function cs(){Ee=fn.current,Q(fn)}function Vt(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,rp(n)),Z!==null)for(n=Z.return;n!==null;){var r=n;switch(Hl(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&mo();break;case 3:Cn(),Q(Se),Q(pe),Zl();break;case 5:Jl(r);break;case 4:Cn();break;case 13:Q(K);break;case 19:Q(K);break;case 10:Yl(r.type._context);break;case 22:case 23:cs()}n=n.return}if(ie=e,Z=e=Ot(e.current,null),se=Ee=t,ne=0,yr=null,ss=Uo=Kt=0,ve=Jn=null,Ut!==null){for(t=0;t<Ut.length;t++)if(n=Ut[t],r=n.interleaved,r!==null){n.interleaved=null;var o=r.next,i=n.pending;if(i!==null){var l=i.next;i.next=o,r.next=l}n.pending=r}Ut=null}return e}function Wc(e,t){do{var n=Z;try{if(Kl(),br.current=Eo,_o){for(var r=Y.memoizedState;r!==null;){var o=r.queue;o!==null&&(o.pending=null),r=r.next}_o=!1}if(Gt=0,oe=te=Y=null,qn=!1,pr=0,ls.current=null,n===null||n.return===null){ne=1,yr=t,Z=null;break}e:{var i=e,l=n.return,a=n,s=t;if(t=se,a.flags|=32768,s!==null&&typeof s=="object"&&typeof s.then=="function"){var u=s,m=a,c=m.tag;if(!(m.mode&1)&&(c===0||c===11||c===15)){var f=m.alternate;f?(m.updateQueue=f.updateQueue,m.memoizedState=f.memoizedState,m.lanes=f.lanes):(m.updateQueue=null,m.memoizedState=null)}var v=pa(l);if(v!==null){v.flags&=-257,ha(v,l,a,i,t),v.mode&1&&da(i,u,t),t=v,s=u;var y=t.updateQueue;if(y===null){var g=new Set;g.add(s),t.updateQueue=g}else y.add(s);break e}else{if(!(t&1)){da(i,u,t),fs();break e}s=Error(w(426))}}else if(G&&a.mode&1){var N=pa(l);if(N!==null){!(N.flags&65536)&&(N.flags|=256),ha(N,l,a,i,t),Ql(_n(s,a));break e}}i=s=_n(s,a),ne!==4&&(ne=2),Jn===null?Jn=[i]:Jn.push(i),i=l;do{switch(i.tag){case 3:i.flags|=65536,t&=-t,i.lanes|=t;var p=Pc(i,s,t);la(i,p);break e;case 1:a=s;var d=i.type,h=i.stateNode;if(!(i.flags&128)&&(typeof d.getDerivedStateFromError=="function"||h!==null&&typeof h.componentDidCatch=="function"&&(Tt===null||!Tt.has(h)))){i.flags|=65536,t&=-t,i.lanes|=t;var k=Tc(i,a,t);la(i,k);break e}}i=i.return}while(i!==null)}Gc(n)}catch(C){t=C,Z===n&&n!==null&&(Z=n=n.return);continue}break}while(!0)}function Hc(){var e=No.current;return No.current=Eo,e===null?Eo:e}function fs(){(ne===0||ne===3||ne===2)&&(ne=4),ie===null||!(Kt&268435455)&&!(Uo&268435455)||kt(ie,se)}function Lo(e,t){var n=B;B|=2;var r=Hc();(ie!==e||se!==t)&&(et=null,Vt(e,t));do try{Lp();break}catch(o){Wc(e,o)}while(!0);if(Kl(),B=n,No.current=r,Z!==null)throw Error(w(261));return ie=null,se=0,ne}function Lp(){for(;Z!==null;)Qc(Z)}function Op(){for(;Z!==null&&!ed();)Qc(Z)}function Qc(e){var t=Yc(e.alternate,e,Ee);e.memoizedProps=e.pendingProps,t===null?Gc(e):Z=t,ls.current=null}function Gc(e){var t=e;do{var n=t.alternate;if(e=t.return,t.flags&32768){if(n=Cp(n,t),n!==null){n.flags&=32767,Z=n;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{ne=6,Z=null;return}}else if(n=wp(n,t,Ee),n!==null){Z=n;return}if(t=t.sibling,t!==null){Z=t;return}Z=t=e}while(t!==null);ne===0&&(ne=5)}function Ft(e,t,n){var r=U,o=Ie.transition;try{Ie.transition=null,U=1,Mp(e,t,n,r)}finally{Ie.transition=o,U=r}return null}function Mp(e,t,n,r){do gn();while(wt!==null);if(B&6)throw Error(w(327));n=e.finishedWork;var o=e.finishedLanes;if(n===null)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(w(177));e.callbackNode=null,e.callbackPriority=0;var i=n.lanes|n.childLanes;if(cd(e,i),e===ie&&(Z=ie=null,se=0),!(n.subtreeFlags&2064)&&!(n.flags&2064)||Fr||(Fr=!0,bc(ao,function(){return gn(),null})),i=(n.flags&15990)!==0,n.subtreeFlags&15990||i){i=Ie.transition,Ie.transition=null;var l=U;U=1;var a=B;B|=4,ls.current=null,Ep(e,n),Uc(n,e),qd(Ki),co=!!Gi,Ki=Gi=null,e.current=n,Np(n),td(),B=a,U=l,Ie.transition=i}else e.current=n;if(Fr&&(Fr=!1,wt=e,To=o),i=e.pendingLanes,i===0&&(Tt=null),od(n.stateNode),Ce(e,J()),t!==null)for(r=e.onRecoverableError,n=0;n<t.length;n++)o=t[n],r(o.value,{componentStack:o.stack,digest:o.digest});if(Po)throw Po=!1,e=pl,pl=null,e;return To&1&&e.tag!==0&&gn(),i=e.pendingLanes,i&1?e===hl?Zn++:(Zn=0,hl=e):Zn=0,Dt(),null}function gn(){if(wt!==null){var e=Pu(To),t=Ie.transition,n=U;try{if(Ie.transition=null,U=16>e?16:e,wt===null)var r=!1;else{if(e=wt,wt=null,To=0,B&6)throw Error(w(331));var o=B;for(B|=4,O=e.current;O!==null;){var i=O,l=i.child;if(O.flags&16){var a=i.deletions;if(a!==null){for(var s=0;s<a.length;s++){var u=a[s];for(O=u;O!==null;){var m=O;switch(m.tag){case 0:case 11:case 15:Xn(8,m,i)}var c=m.child;if(c!==null)c.return=m,O=c;else for(;O!==null;){m=O;var f=m.sibling,v=m.return;if(Bc(m),m===u){O=null;break}if(f!==null){f.return=v,O=f;break}O=v}}}var y=i.alternate;if(y!==null){var g=y.child;if(g!==null){y.child=null;do{var N=g.sibling;g.sibling=null,g=N}while(g!==null)}}O=i}}if(i.subtreeFlags&2064&&l!==null)l.return=i,O=l;else e:for(;O!==null;){if(i=O,i.flags&2048)switch(i.tag){case 0:case 11:case 15:Xn(9,i,i.return)}var p=i.sibling;if(p!==null){p.return=i.return,O=p;break e}O=i.return}}var d=e.current;for(O=d;O!==null;){l=O;var h=l.child;if(l.subtreeFlags&2064&&h!==null)h.return=l,O=h;else e:for(l=d;O!==null;){if(a=O,a.flags&2048)try{switch(a.tag){case 0:case 11:case 15:$o(9,a)}}catch(C){q(a,a.return,C)}if(a===l){O=null;break e}var k=a.sibling;if(k!==null){k.return=a.return,O=k;break e}O=a.return}}if(B=o,Dt(),qe&&typeof qe.onPostCommitFiberRoot=="function")try{qe.onPostCommitFiberRoot(Ao,e)}catch{}r=!0}return r}finally{U=n,Ie.transition=t}}return!1}function Ta(e,t,n){t=_n(n,t),t=Pc(e,t,1),e=Pt(e,t,1),t=me(),e!==null&&(vr(e,1,t),Ce(e,t))}function q(e,t,n){if(e.tag===3)Ta(e,e,n);else for(;t!==null;){if(t.tag===3){Ta(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(Tt===null||!Tt.has(r))){e=_n(n,e),e=Tc(t,e,1),t=Pt(t,e,1),e=me(),t!==null&&(vr(t,1,e),Ce(t,e));break}}t=t.return}}function Ap(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),t=me(),e.pingedLanes|=e.suspendedLanes&n,ie===e&&(se&n)===n&&(ne===4||ne===3&&(se&130023424)===se&&500>J()-as?Vt(e,0):ss|=n),Ce(e,t)}function Kc(e,t){t===0&&(e.mode&1?(t=Lr,Lr<<=1,!(Lr&130023424)&&(Lr=4194304)):t=1);var n=me();e=st(e,t),e!==null&&(vr(e,t,n),Ce(e,n))}function jp(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Kc(e,n)}function zp(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,o=e.memoizedState;o!==null&&(n=o.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(w(314))}r!==null&&r.delete(t),Kc(e,n)}var Yc;Yc=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||Se.current)ke=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return ke=!1,Sp(e,t,n);ke=!!(e.flags&131072)}else ke=!1,G&&t.flags&1048576&&Ju(t,vo,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;Xr(e,t),e=t.pendingProps;var o=kn(t,pe.current);yn(t,n),o=ts(null,t,r,e,o,n);var i=ns();return t.flags|=1,typeof o=="object"&&o!==null&&typeof o.render=="function"&&o.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,we(r)?(i=!0,yo(t)):i=!1,t.memoizedState=o.state!==null&&o.state!==void 0?o.state:null,ql(t),o.updater=Fo,t.stateNode=o,o._reactInternals=t,nl(t,r,e,n),t=il(null,t,r,!0,i,n)):(t.tag=0,G&&i&&Wl(t),he(null,t,o,n),t=t.child),t;case 16:r=t.elementType;e:{switch(Xr(e,t),e=t.pendingProps,o=r._init,r=o(r._payload),t.type=r,o=t.tag=Dp(r),e=Fe(r,e),o){case 0:t=ol(null,t,r,e,n);break e;case 1:t=ga(null,t,r,e,n);break e;case 11:t=ma(null,t,r,e,n);break e;case 14:t=ya(null,t,r,Fe(r.type,e),n);break e}throw Error(w(306,r,""))}return t;case 0:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:Fe(r,o),ol(e,t,r,o,n);case 1:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:Fe(r,o),ga(e,t,r,o,n);case 3:e:{if(Ac(t),e===null)throw Error(w(387));r=t.pendingProps,i=t.memoizedState,o=i.element,oc(e,t),wo(t,r,null,n);var l=t.memoizedState;if(r=l.element,i.isDehydrated)if(i={element:r,isDehydrated:!1,cache:l.cache,pendingSuspenseBoundaries:l.pendingSuspenseBoundaries,transitions:l.transitions},t.updateQueue.baseState=i,t.memoizedState=i,t.flags&256){o=_n(Error(w(423)),t),t=va(e,t,r,n,o);break e}else if(r!==o){o=_n(Error(w(424)),t),t=va(e,t,r,n,o);break e}else for(Ne=Nt(t.stateNode.containerInfo.firstChild),Pe=t,G=!0,Re=null,n=nc(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Sn(),r===o){t=at(e,t,n);break e}he(e,t,r,n)}t=t.child}return t;case 5:return ic(t),e===null&&Zi(t),r=t.type,o=t.pendingProps,i=e!==null?e.memoizedProps:null,l=o.children,Yi(r,o)?l=null:i!==null&&Yi(r,i)&&(t.flags|=32),Mc(e,t),he(e,t,l,n),t.child;case 6:return e===null&&Zi(t),null;case 13:return jc(e,t,n);case 4:return Xl(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=wn(t,null,r,n):he(e,t,r,n),t.child;case 11:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:Fe(r,o),ma(e,t,r,o,n);case 7:return he(e,t,t.pendingProps,n),t.child;case 8:return he(e,t,t.pendingProps.children,n),t.child;case 12:return he(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,o=t.pendingProps,i=t.memoizedProps,l=o.value,V(ko,r._currentValue),r._currentValue=l,i!==null)if(He(i.value,l)){if(i.children===o.children&&!Se.current){t=at(e,t,n);break e}}else for(i=t.child,i!==null&&(i.return=t);i!==null;){var a=i.dependencies;if(a!==null){l=i.child;for(var s=a.firstContext;s!==null;){if(s.context===r){if(i.tag===1){s=ot(-1,n&-n),s.tag=2;var u=i.updateQueue;if(u!==null){u=u.shared;var m=u.pending;m===null?s.next=s:(s.next=m.next,m.next=s),u.pending=s}}i.lanes|=n,s=i.alternate,s!==null&&(s.lanes|=n),el(i.return,n,t),a.lanes|=n;break}s=s.next}}else if(i.tag===10)l=i.type===t.type?null:i.child;else if(i.tag===18){if(l=i.return,l===null)throw Error(w(341));l.lanes|=n,a=l.alternate,a!==null&&(a.lanes|=n),el(l,n,t),l=i.sibling}else l=i.child;if(l!==null)l.return=i;else for(l=i;l!==null;){if(l===t){l=null;break}if(i=l.sibling,i!==null){i.return=l.return,l=i;break}l=l.return}i=l}he(e,t,o.children,n),t=t.child}return t;case 9:return o=t.type,r=t.pendingProps.children,yn(t,n),o=De(o),r=r(o),t.flags|=1,he(e,t,r,n),t.child;case 14:return r=t.type,o=Fe(r,t.pendingProps),o=Fe(r.type,o),ya(e,t,r,o,n);case 15:return Lc(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:Fe(r,o),Xr(e,t),t.tag=1,we(r)?(e=!0,yo(t)):e=!1,yn(t,n),Nc(t,r,o),nl(t,r,o,n),il(null,t,r,!0,e,n);case 19:return zc(e,t,n);case 22:return Oc(e,t,n)}throw Error(w(156,t.tag))};function bc(e,t){return Cu(e,t)}function Ip(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function ze(e,t,n,r){return new Ip(e,t,n,r)}function ds(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Dp(e){if(typeof e=="function")return ds(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Al)return 11;if(e===jl)return 14}return 2}function Ot(e,t){var n=e.alternate;return n===null?(n=ze(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function eo(e,t,n,r,o,i){var l=2;if(r=e,typeof e=="function")ds(e)&&(l=1);else if(typeof e=="string")l=5;else e:switch(e){case en:return Wt(n.children,o,i,t);case Ml:l=8,o|=8;break;case Pi:return e=ze(12,n,t,o|2),e.elementType=Pi,e.lanes=i,e;case Ti:return e=ze(13,n,t,o),e.elementType=Ti,e.lanes=i,e;case Li:return e=ze(19,n,t,o),e.elementType=Li,e.lanes=i,e;case iu:return Ro(n,o,i,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case ru:l=10;break e;case ou:l=9;break e;case Al:l=11;break e;case jl:l=14;break e;case yt:l=16,r=null;break e}throw Error(w(130,e==null?e:typeof e,""))}return t=ze(l,n,t,o),t.elementType=e,t.type=r,t.lanes=i,t}function Wt(e,t,n,r){return e=ze(7,e,r,t),e.lanes=n,e}function Ro(e,t,n,r){return e=ze(22,e,r,t),e.elementType=iu,e.lanes=n,e.stateNode={isHidden:!1},e}function ki(e,t,n){return e=ze(6,e,null,t),e.lanes=n,e}function Si(e,t,n){return t=ze(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function xp(e,t,n,r,o){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=ei(0),this.expirationTimes=ei(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=ei(0),this.identifierPrefix=r,this.onRecoverableError=o,this.mutableSourceEagerHydrationData=null}function ps(e,t,n,r,o,i,l,a,s){return e=new xp(e,t,n,a,s),t===1?(t=1,i===!0&&(t|=8)):t=0,i=ze(3,null,null,t),e.current=i,i.stateNode=e,i.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},ql(i),e}function Bp(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Zt,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}function qc(e){if(!e)return jt;e=e._reactInternals;e:{if(qt(e)!==e||e.tag!==1)throw Error(w(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(we(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(w(171))}if(e.tag===1){var n=e.type;if(we(n))return qu(e,n,t)}return t}function Xc(e,t,n,r,o,i,l,a,s){return e=ps(n,r,!0,e,o,i,l,a,s),e.context=qc(null),n=e.current,r=me(),o=Lt(n),i=ot(r,o),i.callback=t??null,Pt(n,i,o),e.current.lanes=o,vr(e,o,r),Ce(e,r),e}function Vo(e,t,n,r){var o=t.current,i=me(),l=Lt(o);return n=qc(n),t.context===null?t.context=n:t.pendingContext=n,t=ot(i,l),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),e=Pt(o,t,l),e!==null&&(We(e,o,l,i),Yr(e,o,l)),l}function Oo(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function La(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function hs(e,t){La(e,t),(e=e.alternate)&&La(e,t)}function Fp(){return null}var Jc=typeof reportError=="function"?reportError:function(e){console.error(e)};function ms(e){this._internalRoot=e}Wo.prototype.render=ms.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(w(409));Vo(e,t,null,null)};Wo.prototype.unmount=ms.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;Yt(function(){Vo(null,e,null,null)}),t[lt]=null}};function Wo(e){this._internalRoot=e}Wo.prototype.unstable_scheduleHydration=function(e){if(e){var t=Ou();e={blockedOn:null,target:e,priority:t};for(var n=0;n<vt.length&&t!==0&&t<vt[n].priority;n++);vt.splice(n,0,e),n===0&&Au(e)}};function ys(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function Ho(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function Oa(){}function $p(e,t,n,r,o){if(o){if(typeof r=="function"){var i=r;r=function(){var u=Oo(l);i.call(u)}}var l=Xc(t,r,e,0,null,!1,!1,"",Oa);return e._reactRootContainer=l,e[lt]=l.current,ar(e.nodeType===8?e.parentNode:e),Yt(),l}for(;o=e.lastChild;)e.removeChild(o);if(typeof r=="function"){var a=r;r=function(){var u=Oo(s);a.call(u)}}var s=ps(e,0,!1,null,null,!1,!1,"",Oa);return e._reactRootContainer=s,e[lt]=s.current,ar(e.nodeType===8?e.parentNode:e),Yt(function(){Vo(t,s,n,r)}),s}function Qo(e,t,n,r,o){var i=n._reactRootContainer;if(i){var l=i;if(typeof o=="function"){var a=o;o=function(){var s=Oo(l);a.call(s)}}Vo(t,l,e,o)}else l=$p(n,t,e,o,r);return Oo(l)}Tu=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=Vn(t.pendingLanes);n!==0&&(Dl(t,n|1),Ce(t,J()),!(B&6)&&(En=J()+500,Dt()))}break;case 13:Yt(function(){var r=st(e,1);if(r!==null){var o=me();We(r,e,1,o)}}),hs(e,1)}};xl=function(e){if(e.tag===13){var t=st(e,134217728);if(t!==null){var n=me();We(t,e,134217728,n)}hs(e,134217728)}};Lu=function(e){if(e.tag===13){var t=Lt(e),n=st(e,t);if(n!==null){var r=me();We(n,e,t,r)}hs(e,t)}};Ou=function(){return U};Mu=function(e,t){var n=U;try{return U=e,t()}finally{U=n}};Fi=function(e,t,n){switch(t){case"input":if(Ai(e,n),t=n.name,n.type==="radio"&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var o=Do(r);if(!o)throw Error(w(90));su(r),Ai(r,o)}}}break;case"textarea":uu(e,n);break;case"select":t=n.value,t!=null&&dn(e,!!n.multiple,t,!1)}};yu=us;gu=Yt;var Up={usingClientEntryPoint:!1,Events:[Sr,on,Do,hu,mu,us]},Fn={findFiberByHostInstance:$t,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},Rp={bundleType:Fn.bundleType,version:Fn.version,rendererPackageName:Fn.rendererPackageName,rendererConfig:Fn.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:ut.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=Su(e),e===null?null:e.stateNode},findFiberByHostInstance:Fn.findFiberByHostInstance||Fp,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 $r=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!$r.isDisabled&&$r.supportsFiber)try{Ao=$r.inject(Rp),qe=$r}catch{}}Le.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Up;Le.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!ys(t))throw Error(w(200));return Bp(e,t,null,n)};Le.createRoot=function(e,t){if(!ys(e))throw Error(w(299));var n=!1,r="",o=Jc;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onRecoverableError!==void 0&&(o=t.onRecoverableError)),t=ps(e,1,!1,null,null,n,!1,r,o),e[lt]=t.current,ar(e.nodeType===8?e.parentNode:e),new ms(t)};Le.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(w(188)):(e=Object.keys(e).join(","),Error(w(268,e)));return e=Su(t),e=e===null?null:e.stateNode,e};Le.flushSync=function(e){return Yt(e)};Le.hydrate=function(e,t,n){if(!Ho(t))throw Error(w(200));return Qo(null,e,t,!0,n)};Le.hydrateRoot=function(e,t,n){if(!ys(e))throw Error(w(405));var r=n!=null&&n.hydratedSources||null,o=!1,i="",l=Jc;if(n!=null&&(n.unstable_strictMode===!0&&(o=!0),n.identifierPrefix!==void 0&&(i=n.identifierPrefix),n.onRecoverableError!==void 0&&(l=n.onRecoverableError)),t=Xc(t,null,e,1,n??null,o,!1,i,l),e[lt]=t.current,ar(e),r)for(e=0;e<r.length;e++)n=r[e],o=n._getVersion,o=o(n._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[n,o]:t.mutableSourceEagerHydrationData.push(n,o);return new Wo(t)};Le.render=function(e,t,n){if(!Ho(t))throw Error(w(200));return Qo(null,e,t,!1,n)};Le.unmountComponentAtNode=function(e){if(!Ho(e))throw Error(w(40));return e._reactRootContainer?(Yt(function(){Qo(null,null,e,!1,function(){e._reactRootContainer=null,e[lt]=null})}),!0):!1};Le.unstable_batchedUpdates=us;Le.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!Ho(n))throw Error(w(200));if(e==null||e._reactInternals===void 0)throw Error(w(38));return Qo(e,t,n,!1,r)};Le.version="18.3.1-next-f1338f8080-20240426";function Zc(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Zc)}catch(e){console.error(e)}}Zc(),Za.exports=Le;var Vp=Za.exports,Ma=Vp;Ei.createRoot=Ma.createRoot,Ei.hydrateRoot=Ma.hydrateRoot;const Ze=Object.create(null);Ze.open="0";Ze.close="1";Ze.ping="2";Ze.pong="3";Ze.message="4";Ze.upgrade="5";Ze.noop="6";const to=Object.create(null);Object.keys(Ze).forEach(e=>{to[Ze[e]]=e});const gl={type:"error",data:"parser error"},ef=typeof Blob=="function"||typeof Blob<"u"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",tf=typeof ArrayBuffer=="function",nf=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,gs=({type:e,data:t},n,r)=>ef&&t instanceof Blob?n?r(t):Aa(t,r):tf&&(t instanceof ArrayBuffer||nf(t))?n?r(t):Aa(new Blob([t]),r):r(Ze[e]+(t||"")),Aa=(e,t)=>{const n=new FileReader;return n.onload=function(){const r=n.result.split(",")[1];t("b"+(r||""))},n.readAsDataURL(e)};function ja(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}let wi;function Wp(e,t){if(ef&&e.data instanceof Blob)return e.data.arrayBuffer().then(ja).then(t);if(tf&&(e.data instanceof ArrayBuffer||nf(e.data)))return t(ja(e.data));gs(e,!1,n=>{wi||(wi=new TextEncoder),t(wi.encode(n))})}const za="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Hn=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(let e=0;e<za.length;e++)Hn[za.charCodeAt(e)]=e;const Hp=e=>{let t=e.length*.75,n=e.length,r,o=0,i,l,a,s;e[e.length-1]==="="&&(t--,e[e.length-2]==="="&&t--);const u=new ArrayBuffer(t),m=new Uint8Array(u);for(r=0;r<n;r+=4)i=Hn[e.charCodeAt(r)],l=Hn[e.charCodeAt(r+1)],a=Hn[e.charCodeAt(r+2)],s=Hn[e.charCodeAt(r+3)],m[o++]=i<<2|l>>4,m[o++]=(l&15)<<4|a>>2,m[o++]=(a&3)<<6|s&63;return u},Qp=typeof ArrayBuffer=="function",vs=(e,t)=>{if(typeof e!="string")return{type:"message",data:rf(e,t)};const n=e.charAt(0);return n==="b"?{type:"message",data:Gp(e.substring(1),t)}:to[n]?e.length>1?{type:to[n],data:e.substring(1)}:{type:to[n]}:gl},Gp=(e,t)=>{if(Qp){const n=Hp(e);return rf(n,t)}else return{base64:!0,data:e}},rf=(e,t)=>{switch(t){case"blob":return e instanceof Blob?e:new Blob([e]);case"arraybuffer":default:return e instanceof ArrayBuffer?e:e.buffer}},of="",Kp=(e,t)=>{const n=e.length,r=new Array(n);let o=0;e.forEach((i,l)=>{gs(i,!1,a=>{r[l]=a,++o===n&&t(r.join(of))})})},Yp=(e,t)=>{const n=e.split(of),r=[];for(let o=0;o<n.length;o++){const i=vs(n[o],t);if(r.push(i),i.type==="error")break}return r};function bp(){return new TransformStream({transform(e,t){Wp(e,n=>{const r=n.length;let o;if(r<126)o=new Uint8Array(1),new DataView(o.buffer).setUint8(0,r);else if(r<65536){o=new Uint8Array(3);const i=new DataView(o.buffer);i.setUint8(0,126),i.setUint16(1,r)}else{o=new Uint8Array(9);const i=new DataView(o.buffer);i.setUint8(0,127),i.setBigUint64(1,BigInt(r))}e.data&&typeof e.data!="string"&&(o[0]|=128),t.enqueue(o),t.enqueue(n)})}})}let Ci;function Ur(e){return e.reduce((t,n)=>t+n.length,0)}function Rr(e,t){if(e[0].length===t)return e.shift();const n=new Uint8Array(t);let r=0;for(let o=0;o<t;o++)n[o]=e[0][r++],r===e[0].length&&(e.shift(),r=0);return e.length&&r<e[0].length&&(e[0]=e[0].slice(r)),n}function qp(e,t){Ci||(Ci=new TextDecoder);const n=[];let r=0,o=-1,i=!1;return new TransformStream({transform(l,a){for(n.push(l);;){if(r===0){if(Ur(n)<1)break;const s=Rr(n,1);i=(s[0]&128)===128,o=s[0]&127,o<126?r=3:o===126?r=1:r=2}else if(r===1){if(Ur(n)<2)break;const s=Rr(n,2);o=new DataView(s.buffer,s.byteOffset,s.length).getUint16(0),r=3}else if(r===2){if(Ur(n)<8)break;const s=Rr(n,8),u=new DataView(s.buffer,s.byteOffset,s.length),m=u.getUint32(0);if(m>Math.pow(2,21)-1){a.enqueue(gl);break}o=m*Math.pow(2,32)+u.getUint32(4),r=3}else{if(Ur(n)<o)break;const s=Rr(n,o);a.enqueue(vs(i?s:Ci.decode(s),t)),r=0}if(o===0||o>e){a.enqueue(gl);break}}}})}const lf=4;function ee(e){if(e)return Xp(e)}function Xp(e){for(var t in ee.prototype)e[t]=ee.prototype[t];return e}ee.prototype.on=ee.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this};ee.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this};ee.prototype.off=ee.prototype.removeListener=ee.prototype.removeAllListeners=ee.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var n=this._callbacks["$"+e];if(!n)return this;if(arguments.length==1)return delete this._callbacks["$"+e],this;for(var r,o=0;o<n.length;o++)if(r=n[o],r===t||r.fn===t){n.splice(o,1);break}return n.length===0&&delete this._callbacks["$"+e],this};ee.prototype.emit=function(e){this._callbacks=this._callbacks||{};for(var t=new Array(arguments.length-1),n=this._callbacks["$"+e],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(n){n=n.slice(0);for(var r=0,o=n.length;r<o;++r)n[r].apply(this,t)}return this};ee.prototype.emitReserved=ee.prototype.emit;ee.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]};ee.prototype.hasListeners=function(e){return!!this.listeners(e).length};const Go=typeof Promise=="function"&&typeof Promise.resolve=="function"?t=>Promise.resolve().then(t):(t,n)=>n(t,0),je=typeof self<"u"?self:typeof window<"u"?window:Function("return this")(),Jp="arraybuffer";function sf(e,...t){return t.reduce((n,r)=>(e.hasOwnProperty(r)&&(n[r]=e[r]),n),{})}const Zp=je.setTimeout,eh=je.clearTimeout;function Ko(e,t){t.useNativeTimers?(e.setTimeoutFn=Zp.bind(je),e.clearTimeoutFn=eh.bind(je)):(e.setTimeoutFn=je.setTimeout.bind(je),e.clearTimeoutFn=je.clearTimeout.bind(je))}const th=1.33;function nh(e){return typeof e=="string"?rh(e):Math.ceil((e.byteLength||e.size)*th)}function rh(e){let t=0,n=0;for(let r=0,o=e.length;r<o;r++)t=e.charCodeAt(r),t<128?n+=1:t<2048?n+=2:t<55296||t>=57344?n+=3:(r++,n+=4);return n}function af(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function oh(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t}function ih(e){let t={},n=e.split("&");for(let r=0,o=n.length;r<o;r++){let i=n[r].split("=");t[decodeURIComponent(i[0])]=decodeURIComponent(i[1])}return t}class lh extends Error{constructor(t,n,r){super(t),this.description=n,this.context=r,this.type="TransportError"}}class ks extends ee{constructor(t){super(),this.writable=!1,Ko(this,t),this.opts=t,this.query=t.query,this.socket=t.socket,this.supportsBinary=!t.forceBase64}onError(t,n,r){return super.emitReserved("error",new lh(t,n,r)),this}open(){return this.readyState="opening",this.doOpen(),this}close(){return(this.readyState==="opening"||this.readyState==="open")&&(this.doClose(),this.onClose()),this}send(t){this.readyState==="open"&&this.write(t)}onOpen(){this.readyState="open",this.writable=!0,super.emitReserved("open")}onData(t){const n=vs(t,this.socket.binaryType);this.onPacket(n)}onPacket(t){super.emitReserved("packet",t)}onClose(t){this.readyState="closed",super.emitReserved("close",t)}pause(t){}createUri(t,n={}){return t+"://"+this._hostname()+this._port()+this.opts.path+this._query(n)}_hostname(){const t=this.opts.hostname;return t.indexOf(":")===-1?t:"["+t+"]"}_port(){return this.opts.port&&(this.opts.secure&&Number(this.opts.port)!==443||!this.opts.secure&&Number(this.opts.port)!==80)?":"+this.opts.port:""}_query(t){const n=oh(t);return n.length?"?"+n:""}}class sh extends ks{constructor(){super(...arguments),this._polling=!1}get name(){return"polling"}doOpen(){this._poll()}pause(t){this.readyState="pausing";const n=()=>{this.readyState="paused",t()};if(this._polling||!this.writable){let r=0;this._polling&&(r++,this.once("pollComplete",function(){--r||n()})),this.writable||(r++,this.once("drain",function(){--r||n()}))}else n()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved("poll")}onData(t){const n=r=>{if(this.readyState==="opening"&&r.type==="open"&&this.onOpen(),r.type==="close")return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(r)};Yp(t,this.socket.binaryType).forEach(n),this.readyState!=="closed"&&(this._polling=!1,this.emitReserved("pollComplete"),this.readyState==="open"&&this._poll())}doClose(){const t=()=>{this.write([{type:"close"}])};this.readyState==="open"?t():this.once("open",t)}write(t){this.writable=!1,Kp(t,n=>{this.doWrite(n,()=>{this.writable=!0,this.emitReserved("drain")})})}uri(){const t=this.opts.secure?"https":"http",n=this.query||{};return this.opts.timestampRequests!==!1&&(n[this.opts.timestampParam]=af()),!this.supportsBinary&&!n.sid&&(n.b64=1),this.createUri(t,n)}}let uf=!1;try{uf=typeof XMLHttpRequest<"u"&&"withCredentials"in new XMLHttpRequest}catch{}const ah=uf;function uh(){}class ch extends sh{constructor(t){if(super(t),typeof location<"u"){const n=location.protocol==="https:";let r=location.port;r||(r=n?"443":"80"),this.xd=typeof location<"u"&&t.hostname!==location.hostname||r!==t.port}}doWrite(t,n){const r=this.request({method:"POST",data:t});r.on("success",n),r.on("error",(o,i)=>{this.onError("xhr post error",o,i)})}doPoll(){const t=this.request();t.on("data",this.onData.bind(this)),t.on("error",(n,r)=>{this.onError("xhr poll error",n,r)}),this.pollXhr=t}}class Je extends ee{constructor(t,n,r){super(),this.createRequest=t,Ko(this,r),this._opts=r,this._method=r.method||"GET",this._uri=n,this._data=r.data!==void 0?r.data:null,this._create()}_create(){var t;const n=sf(this._opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");n.xdomain=!!this._opts.xd;const r=this._xhr=this.createRequest(n);try{r.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){r.setDisableHeaderCheck&&r.setDisableHeaderCheck(!0);for(let o in this._opts.extraHeaders)this._opts.extraHeaders.hasOwnProperty(o)&&r.setRequestHeader(o,this._opts.extraHeaders[o])}}catch{}if(this._method==="POST")try{r.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch{}try{r.setRequestHeader("Accept","*/*")}catch{}(t=this._opts.cookieJar)===null||t===void 0||t.addCookies(r),"withCredentials"in r&&(r.withCredentials=this._opts.withCredentials),this._opts.requestTimeout&&(r.timeout=this._opts.requestTimeout),r.onreadystatechange=()=>{var o;r.readyState===3&&((o=this._opts.cookieJar)===null||o===void 0||o.parseCookies(r.getResponseHeader("set-cookie"))),r.readyState===4&&(r.status===200||r.status===1223?this._onLoad():this.setTimeoutFn(()=>{this._onError(typeof r.status=="number"?r.status:0)},0))},r.send(this._data)}catch(o){this.setTimeoutFn(()=>{this._onError(o)},0);return}typeof document<"u"&&(this._index=Je.requestsCount++,Je.requests[this._index]=this)}_onError(t){this.emitReserved("error",t,this._xhr),this._cleanup(!0)}_cleanup(t){if(!(typeof this._xhr>"u"||this._xhr===null)){if(this._xhr.onreadystatechange=uh,t)try{this._xhr.abort()}catch{}typeof document<"u"&&delete Je.requests[this._index],this._xhr=null}}_onLoad(){const t=this._xhr.responseText;t!==null&&(this.emitReserved("data",t),this.emitReserved("success"),this._cleanup())}abort(){this._cleanup()}}Je.requestsCount=0;Je.requests={};if(typeof document<"u"){if(typeof attachEvent=="function")attachEvent("onunload",Ia);else if(typeof addEventListener=="function"){const e="onpagehide"in je?"pagehide":"unload";addEventListener(e,Ia,!1)}}function Ia(){for(let e in Je.requests)Je.requests.hasOwnProperty(e)&&Je.requests[e].abort()}const fh=function(){const e=cf({xdomain:!1});return e&&e.responseType!==null}();class dh extends ch{constructor(t){super(t);const n=t&&t.forceBase64;this.supportsBinary=fh&&!n}request(t={}){return Object.assign(t,{xd:this.xd},this.opts),new Je(cf,this.uri(),t)}}function cf(e){const t=e.xdomain;try{if(typeof XMLHttpRequest<"u"&&(!t||ah))return new XMLHttpRequest}catch{}if(!t)try{return new je[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch{}}const ff=typeof navigator<"u"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative";class ph extends ks{get name(){return"websocket"}doOpen(){const t=this.uri(),n=this.opts.protocols,r=ff?{}:sf(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");this.opts.extraHeaders&&(r.headers=this.opts.extraHeaders);try{this.ws=this.createSocket(t,n,r)}catch(o){return this.emitReserved("error",o)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=t=>this.onClose({description:"websocket connection closed",context:t}),this.ws.onmessage=t=>this.onData(t.data),this.ws.onerror=t=>this.onError("websocket error",t)}write(t){this.writable=!1;for(let n=0;n<t.length;n++){const r=t[n],o=n===t.length-1;gs(r,this.supportsBinary,i=>{try{this.doWrite(r,i)}catch{}o&&Go(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){typeof this.ws<"u"&&(this.ws.onerror=()=>{},this.ws.close(),this.ws=null)}uri(){const t=this.opts.secure?"wss":"ws",n=this.query||{};return this.opts.timestampRequests&&(n[this.opts.timestampParam]=af()),this.supportsBinary||(n.b64=1),this.createUri(t,n)}}const _i=je.WebSocket||je.MozWebSocket;class hh extends ph{createSocket(t,n,r){return ff?new _i(t,n,r):n?new _i(t,n):new _i(t)}doWrite(t,n){this.ws.send(n)}}class mh extends ks{get name(){return"webtransport"}doOpen(){try{this._transport=new WebTransport(this.createUri("https"),this.opts.transportOptions[this.name])}catch(t){return this.emitReserved("error",t)}this._transport.closed.then(()=>{this.onClose()}).catch(t=>{this.onError("webtransport error",t)}),this._transport.ready.then(()=>{this._transport.createBidirectionalStream().then(t=>{const n=qp(Number.MAX_SAFE_INTEGER,this.socket.binaryType),r=t.readable.pipeThrough(n).getReader(),o=bp();o.readable.pipeTo(t.writable),this._writer=o.writable.getWriter();const i=()=>{r.read().then(({done:a,value:s})=>{a||(this.onPacket(s),i())}).catch(a=>{})};i();const l={type:"open"};this.query.sid&&(l.data=`{"sid":"${this.query.sid}"}`),this._writer.write(l).then(()=>this.onOpen())})})}write(t){this.writable=!1;for(let n=0;n<t.length;n++){const r=t[n],o=n===t.length-1;this._writer.write(r).then(()=>{o&&Go(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var t;(t=this._transport)===null||t===void 0||t.close()}}const yh={websocket:hh,webtransport:mh,polling:dh},gh=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,vh=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function vl(e){if(e.length>8e3)throw"URI too long";const t=e,n=e.indexOf("["),r=e.indexOf("]");n!=-1&&r!=-1&&(e=e.substring(0,n)+e.substring(n,r).replace(/:/g,";")+e.substring(r,e.length));let o=gh.exec(e||""),i={},l=14;for(;l--;)i[vh[l]]=o[l]||"";return n!=-1&&r!=-1&&(i.source=t,i.host=i.host.substring(1,i.host.length-1).replace(/;/g,":"),i.authority=i.authority.replace("[","").replace("]","").replace(/;/g,":"),i.ipv6uri=!0),i.pathNames=kh(i,i.path),i.queryKey=Sh(i,i.query),i}function kh(e,t){const n=/\/{2,9}/g,r=t.replace(n,"/").split("/");return(t.slice(0,1)=="/"||t.length===0)&&r.splice(0,1),t.slice(-1)=="/"&&r.splice(r.length-1,1),r}function Sh(e,t){const n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(r,o,i){o&&(n[o]=i)}),n}const kl=typeof addEventListener=="function"&&typeof removeEventListener=="function",no=[];kl&&addEventListener("offline",()=>{no.forEach(e=>e())},!1);class Mt extends ee{constructor(t,n){if(super(),this.binaryType=Jp,this.writeBuffer=[],this._prevBufferLen=0,this._pingInterval=-1,this._pingTimeout=-1,this._maxPayload=-1,this._pingTimeoutTime=1/0,t&&typeof t=="object"&&(n=t,t=null),t){const r=vl(t);n.hostname=r.host,n.secure=r.protocol==="https"||r.protocol==="wss",n.port=r.port,r.query&&(n.query=r.query)}else n.host&&(n.hostname=vl(n.host).host);Ko(this,n),this.secure=n.secure!=null?n.secure:typeof location<"u"&&location.protocol==="https:",n.hostname&&!n.port&&(n.port=this.secure?"443":"80"),this.hostname=n.hostname||(typeof location<"u"?location.hostname:"localhost"),this.port=n.port||(typeof location<"u"&&location.port?location.port:this.secure?"443":"80"),this.transports=[],this._transportsByName={},n.transports.forEach(r=>{const o=r.prototype.name;this.transports.push(o),this._transportsByName[o]=r}),this.opts=Object.assign({path:"/engine.io",agent:!1,withCredentials:!1,upgrade:!0,timestampParam:"t",rememberUpgrade:!1,addTrailingSlash:!0,rejectUnauthorized:!0,perMessageDeflate:{threshold:1024},transportOptions:{},closeOnBeforeunload:!1},n),this.opts.path=this.opts.path.replace(/\/$/,"")+(this.opts.addTrailingSlash?"/":""),typeof this.opts.query=="string"&&(this.opts.query=ih(this.opts.query)),kl&&(this.opts.closeOnBeforeunload&&(this._beforeunloadEventListener=()=>{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener("beforeunload",this._beforeunloadEventListener,!1)),this.hostname!=="localhost"&&(this._offlineEventListener=()=>{this._onClose("transport close",{description:"network connection lost"})},no.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(t){const n=Object.assign({},this.opts.query);n.EIO=lf,n.transport=t,this.id&&(n.sid=this.id);const r=Object.assign({},this.opts,{query:n,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[t]);return new this._transportsByName[t](r)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}const t=this.opts.rememberUpgrade&&Mt.priorWebsocketSuccess&&this.transports.indexOf("websocket")!==-1?"websocket":this.transports[0];this.readyState="opening";const n=this.createTransport(t);n.open(),this.setTransport(n)}setTransport(t){this.transport&&this.transport.removeAllListeners(),this.transport=t,t.on("drain",this._onDrain.bind(this)).on("packet",this._onPacket.bind(this)).on("error",this._onError.bind(this)).on("close",n=>this._onClose("transport close",n))}onOpen(){this.readyState="open",Mt.priorWebsocketSuccess=this.transport.name==="websocket",this.emitReserved("open"),this.flush()}_onPacket(t){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing")switch(this.emitReserved("packet",t),this.emitReserved("heartbeat"),t.type){case"open":this.onHandshake(JSON.parse(t.data));break;case"ping":this._sendPacket("pong"),this.emitReserved("ping"),this.emitReserved("pong"),this._resetPingTimeout();break;case"error":const n=new Error("server error");n.code=t.data,this._onError(n);break;case"message":this.emitReserved("data",t.data),this.emitReserved("message",t.data);break}}onHandshake(t){this.emitReserved("handshake",t),this.id=t.sid,this.transport.query.sid=t.sid,this._pingInterval=t.pingInterval,this._pingTimeout=t.pingTimeout,this._maxPayload=t.maxPayload,this.onOpen(),this.readyState!=="closed"&&this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);const t=this._pingInterval+this._pingTimeout;this._pingTimeoutTime=Date.now()+t,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose("ping timeout")},t),this.opts.autoUnref&&this._pingTimeoutTimer.unref()}_onDrain(){this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,this.writeBuffer.length===0?this.emitReserved("drain"):this.flush()}flush(){if(this.readyState!=="closed"&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){const t=this._getWritablePackets();this.transport.send(t),this._prevBufferLen=t.length,this.emitReserved("flush")}}_getWritablePackets(){if(!(this._maxPayload&&this.transport.name==="polling"&&this.writeBuffer.length>1))return this.writeBuffer;let n=1;for(let r=0;r<this.writeBuffer.length;r++){const o=this.writeBuffer[r].data;if(o&&(n+=nh(o)),r>0&&n>this._maxPayload)return this.writeBuffer.slice(0,r);n+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;const t=Date.now()>this._pingTimeoutTime;return t&&(this._pingTimeoutTime=0,Go(()=>{this._onClose("ping timeout")},this.setTimeoutFn)),t}write(t,n,r){return this._sendPacket("message",t,n,r),this}send(t,n,r){return this._sendPacket("message",t,n,r),this}_sendPacket(t,n,r,o){if(typeof n=="function"&&(o=n,n=void 0),typeof r=="function"&&(o=r,r=null),this.readyState==="closing"||this.readyState==="closed")return;r=r||{},r.compress=r.compress!==!1;const i={type:t,data:n,options:r};this.emitReserved("packetCreate",i),this.writeBuffer.push(i),o&&this.once("flush",o),this.flush()}close(){const t=()=>{this._onClose("forced close"),this.transport.close()},n=()=>{this.off("upgrade",n),this.off("upgradeError",n),t()},r=()=>{this.once("upgrade",n),this.once("upgradeError",n)};return(this.readyState==="opening"||this.readyState==="open")&&(this.readyState="closing",this.writeBuffer.length?this.once("drain",()=>{this.upgrading?r():t()}):this.upgrading?r():t()),this}_onError(t){if(Mt.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&this.readyState==="opening")return this.transports.shift(),this._open();this.emitReserved("error",t),this._onClose("transport error",t)}_onClose(t,n){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing"){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),kl&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){const r=no.indexOf(this._offlineEventListener);r!==-1&&no.splice(r,1)}this.readyState="closed",this.id=null,this.emitReserved("close",t,n),this.writeBuffer=[],this._prevBufferLen=0}}}Mt.protocol=lf;class wh extends Mt{constructor(){super(...arguments),this._upgrades=[]}onOpen(){if(super.onOpen(),this.readyState==="open"&&this.opts.upgrade)for(let t=0;t<this._upgrades.length;t++)this._probe(this._upgrades[t])}_probe(t){let n=this.createTransport(t),r=!1;Mt.priorWebsocketSuccess=!1;const o=()=>{r||(n.send([{type:"ping",data:"probe"}]),n.once("packet",c=>{if(!r)if(c.type==="pong"&&c.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",n),!n)return;Mt.priorWebsocketSuccess=n.name==="websocket",this.transport.pause(()=>{r||this.readyState!=="closed"&&(m(),this.setTransport(n),n.send([{type:"upgrade"}]),this.emitReserved("upgrade",n),n=null,this.upgrading=!1,this.flush())})}else{const f=new Error("probe error");f.transport=n.name,this.emitReserved("upgradeError",f)}}))};function i(){r||(r=!0,m(),n.close(),n=null)}const l=c=>{const f=new Error("probe error: "+c);f.transport=n.name,i(),this.emitReserved("upgradeError",f)};function a(){l("transport closed")}function s(){l("socket closed")}function u(c){n&&c.name!==n.name&&i()}const m=()=>{n.removeListener("open",o),n.removeListener("error",l),n.removeListener("close",a),this.off("close",s),this.off("upgrading",u)};n.once("open",o),n.once("error",l),n.once("close",a),this.once("close",s),this.once("upgrading",u),this._upgrades.indexOf("webtransport")!==-1&&t!=="webtransport"?this.setTimeoutFn(()=>{r||n.open()},200):n.open()}onHandshake(t){this._upgrades=this._filterUpgrades(t.upgrades),super.onHandshake(t)}_filterUpgrades(t){const n=[];for(let r=0;r<t.length;r++)~this.transports.indexOf(t[r])&&n.push(t[r]);return n}}let Ch=class extends wh{constructor(t,n={}){const r=typeof t=="object"?t:n;(!r.transports||r.transports&&typeof r.transports[0]=="string")&&(r.transports=(r.transports||["polling","websocket","webtransport"]).map(o=>yh[o]).filter(o=>!!o)),super(t,r)}};function _h(e,t="",n){let r=e;n=n||typeof location<"u"&&location,e==null&&(e=n.protocol+"//"+n.host),typeof e=="string"&&(e.charAt(0)==="/"&&(e.charAt(1)==="/"?e=n.protocol+e:e=n.host+e),/^(https?|wss?):\/\//.test(e)||(typeof n<"u"?e=n.protocol+"//"+e:e="https://"+e),r=vl(e)),r.port||(/^(http|ws)$/.test(r.protocol)?r.port="80":/^(http|ws)s$/.test(r.protocol)&&(r.port="443")),r.path=r.path||"/";const i=r.host.indexOf(":")!==-1?"["+r.host+"]":r.host;return r.id=r.protocol+"://"+i+":"+r.port+t,r.href=r.protocol+"://"+i+(n&&n.port===r.port?"":":"+r.port),r}const Eh=typeof ArrayBuffer=="function",Nh=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer,df=Object.prototype.toString,Ph=typeof Blob=="function"||typeof Blob<"u"&&df.call(Blob)==="[object BlobConstructor]",Th=typeof File=="function"||typeof File<"u"&&df.call(File)==="[object FileConstructor]";function Ss(e){return Eh&&(e instanceof ArrayBuffer||Nh(e))||Ph&&e instanceof Blob||Th&&e instanceof File}function ro(e,t){if(!e||typeof e!="object")return!1;if(Array.isArray(e)){for(let n=0,r=e.length;n<r;n++)if(ro(e[n]))return!0;return!1}if(Ss(e))return!0;if(e.toJSON&&typeof e.toJSON=="function"&&arguments.length===1)return ro(e.toJSON(),!0);for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&ro(e[n]))return!0;return!1}function Lh(e){const t=[],n=e.data,r=e;return r.data=Sl(n,t),r.attachments=t.length,{packet:r,buffers:t}}function Sl(e,t){if(!e)return e;if(Ss(e)){const n={_placeholder:!0,num:t.length};return t.push(e),n}else if(Array.isArray(e)){const n=new Array(e.length);for(let r=0;r<e.length;r++)n[r]=Sl(e[r],t);return n}else if(typeof e=="object"&&!(e instanceof Date)){const n={};for(const r in e)Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=Sl(e[r],t));return n}return e}function Oh(e,t){return e.data=wl(e.data,t),delete e.attachments,e}function wl(e,t){if(!e)return e;if(e&&e._placeholder===!0){if(typeof e.num=="number"&&e.num>=0&&e.num<t.length)return t[e.num];throw new Error("illegal attachments")}else if(Array.isArray(e))for(let n=0;n<e.length;n++)e[n]=wl(e[n],t);else if(typeof e=="object")for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=wl(e[n],t));return e}const Mh=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"];var x;(function(e){e[e.CONNECT=0]="CONNECT",e[e.DISCONNECT=1]="DISCONNECT",e[e.EVENT=2]="EVENT",e[e.ACK=3]="ACK",e[e.CONNECT_ERROR=4]="CONNECT_ERROR",e[e.BINARY_EVENT=5]="BINARY_EVENT",e[e.BINARY_ACK=6]="BINARY_ACK"})(x||(x={}));class Ah{constructor(t){this.replacer=t}encode(t){return(t.type===x.EVENT||t.type===x.ACK)&&ro(t)?this.encodeAsBinary({type:t.type===x.EVENT?x.BINARY_EVENT:x.BINARY_ACK,nsp:t.nsp,data:t.data,id:t.id}):[this.encodeAsString(t)]}encodeAsString(t){let n=""+t.type;return(t.type===x.BINARY_EVENT||t.type===x.BINARY_ACK)&&(n+=t.attachments+"-"),t.nsp&&t.nsp!=="/"&&(n+=t.nsp+","),t.id!=null&&(n+=t.id),t.data!=null&&(n+=JSON.stringify(t.data,this.replacer)),n}encodeAsBinary(t){const n=Lh(t),r=this.encodeAsString(n.packet),o=n.buffers;return o.unshift(r),o}}class ws extends ee{constructor(t){super(),this.reviver=t}add(t){let n;if(typeof t=="string"){if(this.reconstructor)throw new Error("got plaintext data when reconstructing a packet");n=this.decodeString(t);const r=n.type===x.BINARY_EVENT;r||n.type===x.BINARY_ACK?(n.type=r?x.EVENT:x.ACK,this.reconstructor=new jh(n),n.attachments===0&&super.emitReserved("decoded",n)):super.emitReserved("decoded",n)}else if(Ss(t)||t.base64)if(this.reconstructor)n=this.reconstructor.takeBinaryData(t),n&&(this.reconstructor=null,super.emitReserved("decoded",n));else throw new Error("got binary data when not reconstructing a packet");else throw new Error("Unknown type: "+t)}decodeString(t){let n=0;const r={type:Number(t.charAt(0))};if(x[r.type]===void 0)throw new Error("unknown packet type "+r.type);if(r.type===x.BINARY_EVENT||r.type===x.BINARY_ACK){const i=n+1;for(;t.charAt(++n)!=="-"&&n!=t.length;);const l=t.substring(i,n);if(l!=Number(l)||t.charAt(n)!=="-")throw new Error("Illegal attachments");r.attachments=Number(l)}if(t.charAt(n+1)==="/"){const i=n+1;for(;++n&&!(t.charAt(n)===","||n===t.length););r.nsp=t.substring(i,n)}else r.nsp="/";const o=t.charAt(n+1);if(o!==""&&Number(o)==o){const i=n+1;for(;++n;){const l=t.charAt(n);if(l==null||Number(l)!=l){--n;break}if(n===t.length)break}r.id=Number(t.substring(i,n+1))}if(t.charAt(++n)){const i=this.tryParse(t.substr(n));if(ws.isPayloadValid(r.type,i))r.data=i;else throw new Error("invalid payload")}return r}tryParse(t){try{return JSON.parse(t,this.reviver)}catch{return!1}}static isPayloadValid(t,n){switch(t){case x.CONNECT:return Da(n);case x.DISCONNECT:return n===void 0;case x.CONNECT_ERROR:return typeof n=="string"||Da(n);case x.EVENT:case x.BINARY_EVENT:return Array.isArray(n)&&(typeof n[0]=="number"||typeof n[0]=="string"&&Mh.indexOf(n[0])===-1);case x.ACK:case x.BINARY_ACK:return Array.isArray(n)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}}class jh{constructor(t){this.packet=t,this.buffers=[],this.reconPack=t}takeBinaryData(t){if(this.buffers.push(t),this.buffers.length===this.reconPack.attachments){const n=Oh(this.reconPack,this.buffers);return this.finishedReconstruction(),n}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}function Da(e){return Object.prototype.toString.call(e)==="[object Object]"}const zh=Object.freeze(Object.defineProperty({__proto__:null,Decoder:ws,Encoder:Ah,get PacketType(){return x}},Symbol.toStringTag,{value:"Module"}));function Ue(e,t,n){return e.on(t,n),function(){e.off(t,n)}}const Ih=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class pf extends ee{constructor(t,n,r){super(),this.connected=!1,this.recovered=!1,this.receiveBuffer=[],this.sendBuffer=[],this._queue=[],this._queueSeq=0,this.ids=0,this.acks={},this.flags={},this.io=t,this.nsp=n,r&&r.auth&&(this.auth=r.auth),this._opts=Object.assign({},r),this.io._autoConnect&&this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;const t=this.io;this.subs=[Ue(t,"open",this.onopen.bind(this)),Ue(t,"packet",this.onpacket.bind(this)),Ue(t,"error",this.onerror.bind(this)),Ue(t,"close",this.onclose.bind(this))]}get active(){return!!this.subs}connect(){return this.connected?this:(this.subEvents(),this.io._reconnecting||this.io.open(),this.io._readyState==="open"&&this.onopen(),this)}open(){return this.connect()}send(...t){return t.unshift("message"),this.emit.apply(this,t),this}emit(t,...n){var r,o,i;if(Ih.hasOwnProperty(t))throw new Error('"'+t.toString()+'" is a reserved event name');if(n.unshift(t),this._opts.retries&&!this.flags.fromQueue&&!this.flags.volatile)return this._addToQueue(n),this;const l={type:x.EVENT,data:n};if(l.options={},l.options.compress=this.flags.compress!==!1,typeof n[n.length-1]=="function"){const m=this.ids++,c=n.pop();this._registerAckCallback(m,c),l.id=m}const a=(o=(r=this.io.engine)===null||r===void 0?void 0:r.transport)===null||o===void 0?void 0:o.writable,s=this.connected&&!(!((i=this.io.engine)===null||i===void 0)&&i._hasPingExpired());return this.flags.volatile&&!a||(s?(this.notifyOutgoingListeners(l),this.packet(l)):this.sendBuffer.push(l)),this.flags={},this}_registerAckCallback(t,n){var r;const o=(r=this.flags.timeout)!==null&&r!==void 0?r:this._opts.ackTimeout;if(o===void 0){this.acks[t]=n;return}const i=this.io.setTimeoutFn(()=>{delete this.acks[t];for(let a=0;a<this.sendBuffer.length;a++)this.sendBuffer[a].id===t&&this.sendBuffer.splice(a,1);n.call(this,new Error("operation has timed out"))},o),l=(...a)=>{this.io.clearTimeoutFn(i),n.apply(this,a)};l.withError=!0,this.acks[t]=l}emitWithAck(t,...n){return new Promise((r,o)=>{const i=(l,a)=>l?o(l):r(a);i.withError=!0,n.push(i),this.emit(t,...n)})}_addToQueue(t){let n;typeof t[t.length-1]=="function"&&(n=t.pop());const r={id:this._queueSeq++,tryCount:0,pending:!1,args:t,flags:Object.assign({fromQueue:!0},this.flags)};t.push((o,...i)=>(this._queue[0],o!==null?r.tryCount>this._opts.retries&&(this._queue.shift(),n&&n(o)):(this._queue.shift(),n&&n(null,...i)),r.pending=!1,this._drainQueue())),this._queue.push(r),this._drainQueue()}_drainQueue(t=!1){if(!this.connected||this._queue.length===0)return;const n=this._queue[0];n.pending&&!t||(n.pending=!0,n.tryCount++,this.flags=n.flags,this.emit.apply(this,n.args))}packet(t){t.nsp=this.nsp,this.io._packet(t)}onopen(){typeof this.auth=="function"?this.auth(t=>{this._sendConnectPacket(t)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(t){this.packet({type:x.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},t):t})}onerror(t){this.connected||this.emitReserved("connect_error",t)}onclose(t,n){this.connected=!1,delete this.id,this.emitReserved("disconnect",t,n),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach(t=>{if(!this.sendBuffer.some(r=>String(r.id)===t)){const r=this.acks[t];delete this.acks[t],r.withError&&r.call(this,new Error("socket has been disconnected"))}})}onpacket(t){if(t.nsp===this.nsp)switch(t.type){case x.CONNECT:t.data&&t.data.sid?this.onconnect(t.data.sid,t.data.pid):this.emitReserved("connect_error",new Error("It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)"));break;case x.EVENT:case x.BINARY_EVENT:this.onevent(t);break;case x.ACK:case x.BINARY_ACK:this.onack(t);break;case x.DISCONNECT:this.ondisconnect();break;case x.CONNECT_ERROR:this.destroy();const r=new Error(t.data.message);r.data=t.data.data,this.emitReserved("connect_error",r);break}}onevent(t){const n=t.data||[];t.id!=null&&n.push(this.ack(t.id)),this.connected?this.emitEvent(n):this.receiveBuffer.push(Object.freeze(n))}emitEvent(t){if(this._anyListeners&&this._anyListeners.length){const n=this._anyListeners.slice();for(const r of n)r.apply(this,t)}super.emit.apply(this,t),this._pid&&t.length&&typeof t[t.length-1]=="string"&&(this._lastOffset=t[t.length-1])}ack(t){const n=this;let r=!1;return function(...o){r||(r=!0,n.packet({type:x.ACK,id:t,data:o}))}}onack(t){const n=this.acks[t.id];typeof n=="function"&&(delete this.acks[t.id],n.withError&&t.data.unshift(null),n.apply(this,t.data))}onconnect(t,n){this.id=t,this.recovered=n&&this._pid===n,this._pid=n,this.connected=!0,this.emitBuffered(),this._drainQueue(!0),this.emitReserved("connect")}emitBuffered(){this.receiveBuffer.forEach(t=>this.emitEvent(t)),this.receiveBuffer=[],this.sendBuffer.forEach(t=>{this.notifyOutgoingListeners(t),this.packet(t)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach(t=>t()),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:x.DISCONNECT}),this.destroy(),this.connected&&this.onclose("io client disconnect"),this}close(){return this.disconnect()}compress(t){return this.flags.compress=t,this}get volatile(){return this.flags.volatile=!0,this}timeout(t){return this.flags.timeout=t,this}onAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(t),this}prependAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(t),this}offAny(t){if(!this._anyListeners)return this;if(t){const n=this._anyListeners;for(let r=0;r<n.length;r++)if(t===n[r])return n.splice(r,1),this}else this._anyListeners=[];return this}listenersAny(){return this._anyListeners||[]}onAnyOutgoing(t){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.push(t),this}prependAnyOutgoing(t){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.unshift(t),this}offAnyOutgoing(t){if(!this._anyOutgoingListeners)return this;if(t){const n=this._anyOutgoingListeners;for(let r=0;r<n.length;r++)if(t===n[r])return n.splice(r,1),this}else this._anyOutgoingListeners=[];return this}listenersAnyOutgoing(){return this._anyOutgoingListeners||[]}notifyOutgoingListeners(t){if(this._anyOutgoingListeners&&this._anyOutgoingListeners.length){const n=this._anyOutgoingListeners.slice();for(const r of n)r.apply(this,t.data)}}}function Ln(e){e=e||{},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}Ln.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=Math.floor(t*10)&1?e+n:e-n}return Math.min(e,this.max)|0};Ln.prototype.reset=function(){this.attempts=0};Ln.prototype.setMin=function(e){this.ms=e};Ln.prototype.setMax=function(e){this.max=e};Ln.prototype.setJitter=function(e){this.jitter=e};class Cl extends ee{constructor(t,n){var r;super(),this.nsps={},this.subs=[],t&&typeof t=="object"&&(n=t,t=void 0),n=n||{},n.path=n.path||"/socket.io",this.opts=n,Ko(this,n),this.reconnection(n.reconnection!==!1),this.reconnectionAttempts(n.reconnectionAttempts||1/0),this.reconnectionDelay(n.reconnectionDelay||1e3),this.reconnectionDelayMax(n.reconnectionDelayMax||5e3),this.randomizationFactor((r=n.randomizationFactor)!==null&&r!==void 0?r:.5),this.backoff=new Ln({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(n.timeout==null?2e4:n.timeout),this._readyState="closed",this.uri=t;const o=n.parser||zh;this.encoder=new o.Encoder,this.decoder=new o.Decoder,this._autoConnect=n.autoConnect!==!1,this._autoConnect&&this.open()}reconnection(t){return arguments.length?(this._reconnection=!!t,t||(this.skipReconnect=!0),this):this._reconnection}reconnectionAttempts(t){return t===void 0?this._reconnectionAttempts:(this._reconnectionAttempts=t,this)}reconnectionDelay(t){var n;return t===void 0?this._reconnectionDelay:(this._reconnectionDelay=t,(n=this.backoff)===null||n===void 0||n.setMin(t),this)}randomizationFactor(t){var n;return t===void 0?this._randomizationFactor:(this._randomizationFactor=t,(n=this.backoff)===null||n===void 0||n.setJitter(t),this)}reconnectionDelayMax(t){var n;return t===void 0?this._reconnectionDelayMax:(this._reconnectionDelayMax=t,(n=this.backoff)===null||n===void 0||n.setMax(t),this)}timeout(t){return arguments.length?(this._timeout=t,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&this.backoff.attempts===0&&this.reconnect()}open(t){if(~this._readyState.indexOf("open"))return this;this.engine=new Ch(this.uri,this.opts);const n=this.engine,r=this;this._readyState="opening",this.skipReconnect=!1;const o=Ue(n,"open",function(){r.onopen(),t&&t()}),i=a=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",a),t?t(a):this.maybeReconnectOnOpen()},l=Ue(n,"error",i);if(this._timeout!==!1){const a=this._timeout,s=this.setTimeoutFn(()=>{o(),i(new Error("timeout")),n.close()},a);this.opts.autoUnref&&s.unref(),this.subs.push(()=>{this.clearTimeoutFn(s)})}return this.subs.push(o),this.subs.push(l),this}connect(t){return this.open(t)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");const t=this.engine;this.subs.push(Ue(t,"ping",this.onping.bind(this)),Ue(t,"data",this.ondata.bind(this)),Ue(t,"error",this.onerror.bind(this)),Ue(t,"close",this.onclose.bind(this)),Ue(this.decoder,"decoded",this.ondecoded.bind(this)))}onping(){this.emitReserved("ping")}ondata(t){try{this.decoder.add(t)}catch(n){this.onclose("parse error",n)}}ondecoded(t){Go(()=>{this.emitReserved("packet",t)},this.setTimeoutFn)}onerror(t){this.emitReserved("error",t)}socket(t,n){let r=this.nsps[t];return r?this._autoConnect&&!r.active&&r.connect():(r=new pf(this,t,n),this.nsps[t]=r),r}_destroy(t){const n=Object.keys(this.nsps);for(const r of n)if(this.nsps[r].active)return;this._close()}_packet(t){const n=this.encoder.encode(t);for(let r=0;r<n.length;r++)this.engine.write(n[r],t.options)}cleanup(){this.subs.forEach(t=>t()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close")}disconnect(){return this._close()}onclose(t,n){var r;this.cleanup(),(r=this.engine)===null||r===void 0||r.close(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",t,n),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;const t=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{const n=this.backoff.duration();this._reconnecting=!0;const r=this.setTimeoutFn(()=>{t.skipReconnect||(this.emitReserved("reconnect_attempt",t.backoff.attempts),!t.skipReconnect&&t.open(o=>{o?(t._reconnecting=!1,t.reconnect(),this.emitReserved("reconnect_error",o)):t.onreconnect()}))},n);this.opts.autoUnref&&r.unref(),this.subs.push(()=>{this.clearTimeoutFn(r)})}}onreconnect(){const t=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",t)}}const $n={};function oo(e,t){typeof e=="object"&&(t=e,e=void 0),t=t||{};const n=_h(e,t.path||"/socket.io"),r=n.source,o=n.id,i=n.path,l=$n[o]&&i in $n[o].nsps,a=t.forceNew||t["force new connection"]||t.multiplex===!1||l;let s;return a?s=new Cl(r,t):($n[o]||($n[o]=new Cl(r,t)),s=$n[o]),n.query&&!t.query&&(t.query=n.queryKey),s.socket(n.path,t)}Object.assign(oo,{Manager:Cl,Socket:pf,io:oo,connect:oo});const Dh=window.location.hostname==="localhost"?"http://localhost:3001":`http://${window.location.hostname}:3001`,R=oo(Dh,{autoConnect:!1,reconnection:!0,reconnectionAttempts:10,reconnectionDelay:1e3}),xa=[{color:"radiance",name:"Dawn's Wrath",symbol:"☀",desc:"Healing, protection, order"},{color:"tide",name:"Depths of Knowledge",symbol:"🌊",desc:"Card draw, control, counters"},{color:"shadow",name:"Veil of Shadows",symbol:"💀",desc:"Removal, sacrifice, drain"},{color:"flame",name:"Infernal Fury",symbol:"🔥",desc:"Direct damage, speed, aggression"},{color:"growth",name:"Primal Might",symbol:"🌿",desc:"Big creatures, ramp, buffs"}];function xh({playerId:e,playerName:t,rooms:n,currentRoom:r,screen:o,onBackToLobby:i}){const[l,a]=z.useState("");z.useEffect(()=>{R.emit("getRooms")},[]);const s=()=>{R.emit("createRoom",{roomName:l||`${t}'s Game`}),a("")},u=f=>{R.emit("joinRoom",{roomId:f})},m=f=>{R.emit("selectDeck",{deckColor:f})},c=()=>{R.emit("startGame")};if(o==="room"&&r){const f=r.players.find(g=>g.id===e),v=r.hostId===e,y=r.players.length>=2&&r.players.every(g=>g.ready);return S.jsx("div",{className:"lobby",children:S.jsxs("div",{className:"room-view",children:[S.jsxs("div",{className:"room-header",children:[S.jsx("button",{className:"btn btn-back",onClick:i,children:"← Leave"}),S.jsx("h2",{children:r.name})]}),S.jsxs("div",{className:"room-players",children:[S.jsx("h3",{children:"Players"}),r.players.map(g=>{var N;return S.jsxs("div",{className:`room-player ${g.ready?"ready":""}`,children:[S.jsxs("span",{className:"player-name",children:[g.name," ",g.id===r.hostId?"(Host)":""]}),S.jsx("span",{className:"player-status",children:g.ready?`✔ ${typeof g.deck=="string"?(N=xa.find(p=>p.color===g.deck))==null?void 0:N.name:"Custom Deck"}`:"Choosing deck..."})]},g.id)}),r.players.length<2&&S.jsx("div",{className:"room-player waiting",children:"Waiting for opponent..."})]}),S.jsxs("div",{className:"deck-selection",children:[S.jsx("h3",{children:"Choose Your Deck"}),S.jsx("div",{className:"deck-grid",children:xa.map(g=>S.jsxs("button",{className:`deck-card ${(f==null?void 0:f.deck)===g.color?"selected":""} color-${g.color}`,onClick:()=>m(g.color),children:[S.jsx("span",{className:"deck-symbol",children:g.symbol}),S.jsx("span",{className:"deck-name",children:g.name}),S.jsx("span",{className:"deck-desc",children:g.desc})]},g.color))})]}),v&&S.jsx("button",{className:"btn btn-primary btn-start",onClick:c,disabled:!y,children:y?"Start Game":"Waiting for all players to be ready..."})]})})}return S.jsxs("div",{className:"lobby",children:[S.jsxs("div",{className:"lobby-header",children:[S.jsx("h1",{className:"game-title-small",children:"Arcane Duels"}),S.jsxs("span",{className:"player-badge",children:["Playing as: ",t]})]}),S.jsxs("div",{className:"lobby-content",children:[S.jsxs("div",{className:"create-room",children:[S.jsx("h3",{children:"Create a Game"}),S.jsxs("div",{className:"create-room-form",children:[S.jsx("input",{type:"text",value:l,onChange:f=>a(f.target.value),placeholder:"Room name (optional)",className:"room-input"}),S.jsx("button",{className:"btn btn-primary",onClick:s,children:"Create Room"})]})]}),S.jsxs("div",{className:"room-list",children:[S.jsxs("h3",{children:["Available Games ",n.length>0&&`(${n.length})`]}),n.length===0?S.jsx("div",{className:"no-rooms",children:"No games available. Create one!"}):n.map(f=>S.jsxs("div",{className:"room-item",children:[S.jsxs("div",{className:"room-info",children:[S.jsx("span",{className:"room-name",children:f.name}),S.jsxs("span",{className:"room-meta",children:["Host: ",f.host," · ",f.playerCount,"/",f.maxPlayers," players"]})]}),S.jsx("button",{className:"btn btn-join",onClick:()=>u(f.id),disabled:f.status!=="waiting"||f.playerCount>=f.maxPlayers,children:f.status!=="waiting"?"In Progress":f.playerCount>=f.maxPlayers?"Full":"Join"})]},f.id))]})]})]})}function Bh(e){let t=5381;for(let n=0;n<e.length;n++)t=(t<<5)+t+e.charCodeAt(n)>>>0;return t}function Fh(e){let t=e|0;return()=>{t=t+1831565813|0;let n=Math.imul(t^t>>>15,1|t);return n=n+Math.imul(n^n>>>7,61|n)^n,((n^n>>>14)>>>0)/4294967296}}function $h(e){const t=Fh(Bh(e||"card"));return t(),t(),t(),{f:()=>t(),r:(n,r)=>n+t()*(r-n),i:(n,r)=>Math.floor(n+t()*(r-n)),pick:n=>n[Math.floor(t()*n.length)]}}const Ba={radiance:{bg:["#7a6420","#b89530","#d4a843","#f0d060","#fff8e7"],fills:["#f0d060","#e8c040","#d4a843","#ffeebb","#c49840"],glow:"#fffce8",deep:"#5a4010"},tide:{bg:["#0d1825","#1a3355","#2266aa","#4499dd"],fills:["#3388cc","#55aaee","#4499dd","#77ccff","#2266aa"],glow:"#cceeff",deep:"#08101a"},shadow:{bg:["#05020a","#0f0a18","#1a1520","#2a1530"],fills:["#5a3070","#8a6098","#44224d","#6b4880","#3a1845"],glow:"#c8a0d8",deep:"#030108"},flame:{bg:["#180600","#331000","#662200","#993300"],fills:["#ee5533","#ff8844","#cc3311","#ffbb33","#ff6622"],glow:"#ffeecc",deep:"#100300"},growth:{bg:["#081a05","#153010","#224411","#336622"],fills:["#55aa44","#88cc66","#44884a","#66bb55","#339933"],glow:"#d4eec8",deep:"#040d02"},colorless:{bg:["#303030","#505050","#707070","#909090"],fills:["#aaaaaa","#bbbbbb","#999999","#cccccc","#888888"],glow:"#e8e8ee",deep:"#202020"}};function Uh(e,t,n,r,o){const i=t.r(r*.3,r*.7),l=t.r(o*.15,o*.45),a=e.createRadialGradient(i,l,0,i,l,Math.max(r,o)*1.1);a.addColorStop(0,"#fff8e7"),a.addColorStop(.25,"#f5e6b8"),a.addColorStop(.5,"#d4a843"),a.addColorStop(.8,"#b89530"),a.addColorStop(1,"#7a6420"),e.fillStyle=a,e.fillRect(0,0,r,o);const s=t.i(7,14);for(let v=0;v<s;v++){const y=t.r(0,Math.PI*2),g=t.r(r*.5,Math.max(r,o)*1.3),N=t.r(.04,.14);e.save(),e.beginPath(),e.moveTo(i,l),e.lineTo(i+Math.cos(y-N)*g,l+Math.sin(y-N)*g),e.lineTo(i+Math.cos(y+N)*g,l+Math.sin(y+N)*g),e.closePath();const p=e.createLinearGradient(i,l,i+Math.cos(y)*g,l+Math.sin(y)*g);p.addColorStop(0,`rgba(255,248,220,${t.r(.35,.65)})`),p.addColorStop(.4,`rgba(240,208,96,${t.r(.15,.35)})`),p.addColorStop(1,"rgba(212,168,67,0)"),e.fillStyle=p,e.fill(),e.restore()}const u=t.i(2,5);for(let v=0;v<u;v++){const y=t.r(8,Math.min(r,o)*.6);e.save(),e.beginPath(),e.arc(i,l,y,0,Math.PI*2),e.strokeStyle=`rgba(255,248,200,${t.r(.12,.35)})`,e.lineWidth=t.r(.5,2.5),e.stroke(),e.restore()}e.save();const m=e.createRadialGradient(i,l,0,i,l,t.r(10,22));m.addColorStop(0,"rgba(255,255,240,0.9)"),m.addColorStop(.4,"rgba(255,240,200,0.4)"),m.addColorStop(1,"rgba(240,208,96,0)"),e.fillStyle=m,e.fillRect(0,0,r,o),e.restore();const c=t.i(18,40);for(let v=0;v<c;v++){const y=t.r(0,r),g=t.r(0,o),N=t.r(.4,2.5);e.save(),e.beginPath(),e.arc(y,g,N,0,Math.PI*2),e.fillStyle=`rgba(255,250,210,${t.r(.2,.8)})`,e.fill(),e.restore()}e.save(),e.globalCompositeOperation="lighter";const f=t.i(3,6);for(let v=0;v<f;v++){const y=t.r(0,r),g=t.r(0,o),N=t.r(10,30),p=e.createRadialGradient(y,g,0,y,g,N);p.addColorStop(0,`rgba(240,210,100,${t.r(.04,.12)})`),p.addColorStop(1,"rgba(240,210,100,0)"),e.fillStyle=p,e.fillRect(y-N,g-N,N*2,N*2)}e.restore()}function Rh(e,t,n,r,o){const i=e.createLinearGradient(t.r(0,r*.3),0,t.r(r*.7,r),o);i.addColorStop(0,"#0d1825"),i.addColorStop(.35,"#1a3355"),i.addColorStop(.65,"#2266aa"),i.addColorStop(1,"#4499dd"),e.fillStyle=i,e.fillRect(0,0,r,o),e.save(),e.globalCompositeOperation="lighter";const l=e.createRadialGradient(r*.5,o*.7,0,r*.5,o*.7,o*.6);l.addColorStop(0,"rgba(60,140,200,0.15)"),l.addColorStop(1,"rgba(20,60,100,0)"),e.fillStyle=l,e.fillRect(0,0,r,o),e.restore();const a=t.i(4,8);for(let c=0;c<a;c++){const f=t.r(o*.05,o*.95),v=t.r(2,o*.12),y=t.r(.03,.09),g=t.r(0,Math.PI*2),N=y*t.r(1.8,2.8),p=t.r(0,Math.PI*2);e.save(),e.beginPath(),e.moveTo(-2,o+2);for(let d=-2;d<=r+2;d+=2){const h=f+Math.sin(d*y+g)*v+Math.sin(d*N+p)*v*.3;e.lineTo(d,h)}e.lineTo(r+2,o+2),e.closePath(),e.globalAlpha=t.r(.08,.28),e.fillStyle=t.pick(n.fills),e.fill(),e.globalAlpha=1,e.restore()}const s=t.i(2,5);for(let c=0;c<s;c++){const f=t.r(r*.1,r*.9),v=t.r(o*.1,o*.9),y=t.i(2,5);for(let g=0;g<y;g++){const N=t.r(4,12)+g*t.r(3,7);e.save(),e.beginPath(),e.arc(f,v,N,0,Math.PI*2),e.strokeStyle=`rgba(180,220,255,${t.r(.06,.22)})`,e.lineWidth=t.r(.3,1.2),e.stroke(),e.restore()}}const u=t.i(5,14);for(let c=0;c<u;c++){const f=t.r(0,r),v=t.r(0,o),y=t.r(3,10);e.save();const g=e.createRadialGradient(f,v,0,f,v,y);g.addColorStop(0,`rgba(200,235,255,${t.r(.08,.25)})`),g.addColorStop(1,"rgba(200,235,255,0)"),e.fillStyle=g,e.fillRect(f-y,v-y,y*2,y*2),e.restore()}const m=t.i(12,30);for(let c=0;c<m;c++)e.save(),e.beginPath(),e.arc(t.r(0,r),t.r(0,o),t.r(.3,1.8),0,Math.PI*2),e.fillStyle=`rgba(210,235,255,${t.r(.12,.5)})`,e.fill(),e.restore()}function Vh(e,t,n,r,o){const i=t.r(r*.3,r*.7),l=t.r(o*.3,o*.7),a=e.createRadialGradient(i,l,0,i,l,Math.max(r,o)*.8);a.addColorStop(0,"#2a1530"),a.addColorStop(.4,"#1a1520"),a.addColorStop(.7,"#0f0a18"),a.addColorStop(1,"#05020a"),e.fillStyle=a,e.fillRect(0,0,r,o);const s=t.i(5,9);for(let p=0;p<s;p++){const d=t.i(0,4);let h,k;d===0?(h=t.r(0,r),k=-2):d===1?(h=r+2,k=t.r(0,o)):d===2?(h=t.r(0,r),k=o+2):(h=-2,k=t.r(0,o));const C=t.r(r*.15,r*.85),P=t.r(o*.15,o*.85),E=t.r(0,r),_=t.r(0,o),F=t.r(0,r),A=t.r(0,o);e.save(),e.beginPath(),e.moveTo(h,k),e.bezierCurveTo(E,_,F,A,C,P),e.strokeStyle=`rgba(${t.i(60,110)},${t.i(30,70)},${t.i(80,140)},${t.r(.15,.45)})`,e.lineWidth=t.r(1.5,5),e.lineCap="round",e.stroke(),e.restore()}const u=t.i(5,10);for(let p=0;p<u;p++){const d=t.r(-5,r+5),h=t.r(-5,o+5),k=t.r(8,28);e.save();const C=e.createRadialGradient(d,h,0,d,h,k);C.addColorStop(0,`rgba(${t.i(70,120)},${t.i(40,80)},${t.i(90,140)},${t.r(.08,.25)})`),C.addColorStop(.6,`rgba(50,25,70,${t.r(.03,.1)})`),C.addColorStop(1,"rgba(30,15,50,0)"),e.fillStyle=C,e.fillRect(d-k,h-k,k*2,k*2),e.restore()}const m=t.i(3,8);for(let p=0;p<m;p++){const d=t.r(0,r),h=t.r(0,o),k=t.r(3,14),C=t.r(0,Math.PI*2),P=t.i(3,6);e.save(),e.beginPath();for(let E=0;E<P;E++){const _=C+E/P*Math.PI*2,F=k*(.4+t.f()*.6),A=d+Math.cos(_)*F,ue=h+Math.sin(_)*F;E===0?e.moveTo(A,ue):e.lineTo(A,ue)}e.closePath(),e.fillStyle=`rgba(${t.i(80,150)},${t.i(40,100)},${t.i(100,170)},${t.r(.08,.25)})`,e.fill(),e.restore()}const c=t.r(r*.2,r*.8),f=t.r(o*.2,o*.8),v=t.r(12,28);e.save();const y=e.createRadialGradient(c,f,0,c,f,v),g=t.pick([`rgba(90,200,120,${t.r(.06,.15)})`,`rgba(160,80,80,${t.r(.06,.15)})`,`rgba(100,80,180,${t.r(.08,.18)})`]);y.addColorStop(0,g),y.addColorStop(1,"rgba(0,0,0,0)"),e.fillStyle=y,e.fillRect(0,0,r,o),e.restore();const N=t.i(15,35);for(let p=0;p<N;p++)e.save(),e.beginPath(),e.arc(t.r(0,r),t.r(0,o),t.r(.3,1.5),0,Math.PI*2),e.fillStyle=`rgba(${t.i(100,190)},${t.i(60,130)},${t.i(120,210)},${t.r(.15,.55)})`,e.fill(),e.restore()}function Wh(e,t,n,r,o){const i=e.createLinearGradient(0,0,0,o);i.addColorStop(0,"#180600"),i.addColorStop(.3,"#331000"),i.addColorStop(.6,"#662200"),i.addColorStop(.85,"#993300"),i.addColorStop(1,"#bb4400"),e.fillStyle=i,e.fillRect(0,0,r,o);const l=t.r(r*.25,r*.75);e.save();const a=e.createRadialGradient(l,o+5,0,l,o*.5,o*.9);a.addColorStop(0,"rgba(255,200,50,0.45)"),a.addColorStop(.35,"rgba(255,120,30,0.25)"),a.addColorStop(.7,"rgba(180,50,10,0.1)"),a.addColorStop(1,"rgba(80,15,0,0)"),e.fillStyle=a,e.fillRect(0,0,r,o),e.restore();const s=t.i(6,12);for(let m=0;m<s;m++){const c=t.r(r*-.1,r*1.1),f=t.r(4,16),v=t.r(o*.25,o*.95),y=t.r(-10,10);e.save(),e.beginPath(),e.moveTo(c-f,o+2),e.bezierCurveTo(c-f*t.r(.3,.8)+y*.3,o-v*t.r(.2,.45),c+y*.6-f*t.r(.1,.3),o-v*t.r(.6,.85),c+y,o-v),e.bezierCurveTo(c+y*.6+f*t.r(.1,.3),o-v*t.r(.6,.85),c+f*t.r(.3,.8)+y*.3,o-v*t.r(.2,.45),c+f,o+2),e.closePath();const g=e.createLinearGradient(c,o,c+y,o-v);g.addColorStop(0,`rgba(255,220,60,${t.r(.3,.6)})`),g.addColorStop(.3,`rgba(255,140,30,${t.r(.25,.5)})`),g.addColorStop(.6,`rgba(230,70,20,${t.r(.15,.35)})`),g.addColorStop(1,`rgba(150,30,10,${t.r(.05,.15)})`),e.fillStyle=g,e.fill(),e.restore()}const u=t.i(25,55);for(let m=0;m<u;m++){const c=t.r(0,r),f=t.r(o*.05,o),v=t.r(.4,2.8),y=t.f(),g=Math.floor(200+y*55),N=Math.floor(80+y*120),p=Math.floor(y*50);e.save(),e.beginPath(),e.arc(c,f,v,0,Math.PI*2),e.fillStyle=`rgba(${g},${N},${p},${t.r(.3,.9)})`,e.fill(),e.restore()}e.save(),e.globalAlpha=.12;for(let m=0;m<4;m++){const c=t.r(1,o*.25);e.beginPath(),e.moveTo(0,c);const f=t.r(.08,.2),v=t.r(0,10);for(let y=0;y<=r;y+=2)e.lineTo(y,c+Math.sin(y*f+v)*t.r(1,3));e.strokeStyle=t.pick(["#ffaa44","#ff8833","#ffcc66"]),e.lineWidth=t.r(.4,1.2),e.stroke()}e.restore()}function Hh(e,t,n,r,o){const i=e.createLinearGradient(0,0,t.r(0,r*.3),o);i.addColorStop(0,"#0e2208"),i.addColorStop(.4,"#1a3310"),i.addColorStop(.7,"#224411"),i.addColorStop(1,"#2a5520"),e.fillStyle=i,e.fillRect(0,0,r,o);const l=t.i(1,3);for(let c=0;c<l;c++){const f=t.r(r*.1,r*.9),v=t.r(-5,o*.3),y=t.r(15,40);e.save();const g=e.createRadialGradient(f,v,0,f,v,y);g.addColorStop(0,`rgba(180,220,140,${t.r(.12,.3)})`),g.addColorStop(.5,`rgba(120,180,90,${t.r(.04,.12)})`),g.addColorStop(1,"rgba(80,140,60,0)"),e.fillStyle=g,e.fillRect(f-y,v-y,y*2,y*2),e.restore()}const a=t.i(3,5);for(let c=0;c<a;c++){const f=o-t.r(o*.05,o*.45),v=t.r(.015,.06),y=t.r(3,12),g=t.r(0,20);e.save(),e.beginPath(),e.moveTo(-2,o+2);for(let N=-2;N<=r+2;N+=2){const p=f+Math.sin(N*v+g)*y+Math.sin(N*v*2.7+g*1.3)*y*.3;e.lineTo(N,p)}e.lineTo(r+2,o+2),e.closePath(),e.globalAlpha=t.r(.15,.45),e.fillStyle=t.pick(n.fills),e.fill(),e.restore()}const s=t.i(2,5);for(let c=0;c<s;c++){const f=t.pick([t.r(-5,r*.15),t.r(r*.85,r+5)]),v=t.r(o*.4,o+5),y=f<r*.5?t.r(-1.2,-.3):t.r(-2.8,-1.9);hf(e,t,f,v,y,t.r(12,28),t.i(2,4),t.r(1.5,3.5))}const u=t.i(10,25);for(let c=0;c<u;c++){const f=t.r(0,r),v=t.r(0,o),y=t.r(1.5,5),g=t.r(0,Math.PI*2);e.save(),e.translate(f,v),e.rotate(g),e.beginPath(),e.ellipse(0,0,y,y*.35,0,0,Math.PI*2),e.fillStyle=`rgba(${t.i(70,150)},${t.i(150,230)},${t.i(50,120)},${t.r(.12,.4)})`,e.fill(),e.restore()}const m=t.i(10,20);for(let c=0;c<m;c++)e.save(),e.beginPath(),e.arc(t.r(0,r),t.r(0,o),t.r(.3,1.3),0,Math.PI*2),e.fillStyle=`rgba(200,240,170,${t.r(.15,.55)})`,e.fill(),e.restore()}function hf(e,t,n,r,o,i,l,a){if(l<=0||i<2)return;const s=n+Math.cos(o)*i,u=r+Math.sin(o)*i;e.save(),e.beginPath(),e.moveTo(n,r),e.lineTo(s,u),e.strokeStyle=`rgba(${t.i(50,90)},${t.i(70,130)},${t.i(30,70)},${t.r(.25,.6)})`,e.lineWidth=a,e.lineCap="round",e.stroke(),e.restore();const m=t.i(1,3);for(let c=0;c<m;c++)hf(e,t,s,u,o+t.r(-.9,.9),i*t.r(.45,.75),l-1,a*.55)}function Qh(e,t,n,r,o){const i=t.r(0,Math.PI),l=Math.cos(i),a=Math.sin(i),s=e.createLinearGradient(r*.5-l*r*.6,o*.5-a*o*.6,r*.5+l*r*.6,o*.5+a*o*.6);s.addColorStop(0,"#383838"),s.addColorStop(.3,"#606068"),s.addColorStop(.5,"#808088"),s.addColorStop(.7,"#606068"),s.addColorStop(1,"#404048"),e.fillStyle=s,e.fillRect(0,0,r,o);const u=t.r(7,13),m=u*Math.sqrt(3),c=t.r(-.25,.25);e.save(),e.translate(t.r(-8,8),t.r(-8,8)),e.rotate(c);for(let N=-2;N<o/m+3;N++)for(let p=-2;p<r/(u*1.5)+3;p++){const d=p*u*1.5,h=N*m+(p%2?m*.5:0);e.beginPath();for(let k=0;k<6;k++){const C=Math.PI/3*k+Math.PI/6,P=d+Math.cos(C)*u*.88,E=h+Math.sin(C)*u*.88;k===0?e.moveTo(P,E):e.lineTo(P,E)}e.closePath(),e.strokeStyle=`rgba(190,195,210,${t.r(.04,.18)})`,e.lineWidth=t.r(.3,.9),e.stroke()}e.restore();const f=t.i(3,7);for(let N=0;N<f;N++){const p=t.r(r*.05,r*.95),d=t.r(o*.05,o*.95),h=t.r(5,18),k=t.pick([4,5,6,8]),C=t.r(0,Math.PI*2);e.save(),e.beginPath();for(let P=0;P<k;P++){const E=C+P/k*Math.PI*2,_=h*(.6+t.f()*.4),F=p+Math.cos(E)*_,A=d+Math.sin(E)*_;P===0?e.moveTo(F,A):e.lineTo(F,A)}e.closePath(),e.fillStyle=`rgba(170,180,200,${t.r(.04,.18)})`,e.fill(),e.strokeStyle=`rgba(210,220,240,${t.r(.08,.3)})`,e.lineWidth=t.r(.3,1),e.stroke(),e.restore()}const v=t.i(4,10);for(let N=0;N<v;N++)e.save(),e.beginPath(),e.moveTo(t.r(0,r),t.r(0,o)),e.lineTo(t.r(0,r),t.r(0,o)),e.strokeStyle=`rgba(220,225,240,${t.r(.04,.16)})`,e.lineWidth=t.r(.2,.8),e.stroke(),e.restore();const y=t.r(r*.15,r*.85);e.save();const g=e.createLinearGradient(y-18,0,y+18,0);g.addColorStop(0,"rgba(255,255,255,0)"),g.addColorStop(.35,"rgba(255,255,255,0.06)"),g.addColorStop(.5,"rgba(255,255,255,0.12)"),g.addColorStop(.65,"rgba(255,255,255,0.06)"),g.addColorStop(1,"rgba(255,255,255,0)"),e.fillStyle=g,e.fillRect(0,0,r,o),e.restore()}const Fa={radiance:Uh,tide:Rh,shadow:Vh,flame:Wh,growth:Hh,colorless:Qh};function Gh(e,t,n,r,o){const i=t.i(0,5),l=r*.5,a=o*.5,s=Math.min(r,o)*.28;if(e.save(),e.globalAlpha=t.r(.07,.18),e.fillStyle=n.glow,i===0)e.beginPath(),e.arc(l,a-s*.65,s*.22,0,Math.PI*2),e.fill(),e.beginPath(),e.moveTo(l-s*.45,a+s*.85),e.lineTo(l-s*.35,a-s*.25),e.lineTo(l,a-s*.4),e.lineTo(l+s*.35,a-s*.25),e.lineTo(l+s*.45,a+s*.85),e.closePath(),e.fill(),e.beginPath(),e.moveTo(l-s*.35,a-s*.1),e.lineTo(l-s*.7,a+s*.15),e.lineTo(l-s*.65,a+s*.25),e.lineTo(l-s*.3,a+s*.05),e.closePath(),e.fill(),e.beginPath(),e.moveTo(l+s*.35,a-s*.1),e.lineTo(l+s*.7,a+s*.15),e.lineTo(l+s*.65,a+s*.25),e.lineTo(l+s*.3,a+s*.05),e.closePath(),e.fill();else if(i===1){e.beginPath(),e.ellipse(l,a,s*.55,s*.3,0,0,Math.PI*2),e.fill(),e.beginPath(),e.ellipse(l+s*.5,a-s*.22,s*.2,s*.18,-.3,0,Math.PI*2),e.fill();const u=s*.07;[l-s*.38,l-s*.15,l+s*.12,l+s*.35].forEach(function(m){e.fillRect(m-u,a+s*.22,u*2,s*.55)})}else i===2?(e.beginPath(),e.ellipse(l,a,s*.18,s*.35,0,0,Math.PI*2),e.fill(),e.beginPath(),e.moveTo(l-s*.1,a-s*.15),e.quadraticCurveTo(l-s*.85,a-s*.7,l-s*.75,a+s*.15),e.lineTo(l-s*.2,a+s*.05),e.closePath(),e.fill(),e.beginPath(),e.moveTo(l+s*.1,a-s*.15),e.quadraticCurveTo(l+s*.85,a-s*.7,l+s*.75,a+s*.15),e.lineTo(l+s*.2,a+s*.05),e.closePath(),e.fill()):i===3?(e.strokeStyle=n.glow,e.lineWidth=s*.18,e.lineCap="round",e.beginPath(),e.moveTo(l-s*.6,a+s*.4),e.bezierCurveTo(l-s*.2,a-s*.6,l+s*.2,a+s*.6,l+s*.6,a-s*.4),e.stroke()):(e.fillRect(l-s*.45,a-s*.35,s*.9,s*.9),e.fillRect(l-s*.2,a-s*.75,s*.4,s*.45));e.restore()}function $a(e,t,n,r,o){const i=r*.5+t.r(-r*.12,r*.12),l=o*.5+t.r(-o*.12,o*.12),a=Math.min(r,o)*t.r(.28,.42);e.save(),e.globalAlpha=t.r(.12,.28),e.strokeStyle=n.glow,e.lineWidth=t.r(.5,1.5),e.beginPath(),e.arc(i,l,a,0,Math.PI*2),e.stroke(),e.beginPath(),e.arc(i,l,a*.55,0,Math.PI*2),e.stroke();const s=t.i(4,9),u=t.r(0,Math.PI*2);for(let c=0;c<s;c++){const f=u+c/s*Math.PI*2;e.beginPath(),e.moveTo(i+Math.cos(f)*a*.55,l+Math.sin(f)*a*.55),e.lineTo(i+Math.cos(f)*a,l+Math.sin(f)*a),e.stroke()}const m=t.i(6,14);e.fillStyle=n.glow;for(let c=0;c<m;c++){const f=c/m*Math.PI*2,v=a*t.r(.75,1.25);e.beginPath(),e.arc(i+Math.cos(f)*v,l+Math.sin(f)*v,t.r(.5,2),0,Math.PI*2),e.fill()}e.beginPath(),e.arc(i,l,a*.15,0,Math.PI*2),e.fillStyle=n.glow,e.fill(),e.restore()}function Kh(e,t,n,r,o){e.save();const i=t.r(5,12);e.globalAlpha=t.r(.08,.2);let l=e.createLinearGradient(0,0,0,i);l.addColorStop(0,n.glow),l.addColorStop(1,"rgba(0,0,0,0)"),e.fillStyle=l,e.fillRect(0,0,r,i),l=e.createLinearGradient(0,o,0,o-i),l.addColorStop(0,n.glow),l.addColorStop(1,"rgba(0,0,0,0)"),e.fillStyle=l,e.fillRect(0,o-i,r,i),l=e.createLinearGradient(0,0,i,0),l.addColorStop(0,n.glow),l.addColorStop(1,"rgba(0,0,0,0)"),e.fillStyle=l,e.fillRect(0,0,i,o),l=e.createLinearGradient(r,0,r-i,0),l.addColorStop(0,n.glow),l.addColorStop(1,"rgba(0,0,0,0)"),e.fillStyle=l,e.fillRect(r-i,0,i,o);const a=t.i(6,16);for(let s=0;s<a;s++){const u=t.r(0,r),m=t.r(0,o),c=t.r(1.5,4),f=e.createRadialGradient(u,m,0,u,m,c);f.addColorStop(0,n.glow),f.addColorStop(1,"rgba(0,0,0,0)"),e.globalAlpha=t.r(.1,.35),e.fillStyle=f,e.fillRect(u-c,m-c,c*2,c*2)}e.restore()}function Yh(e,t,n,r,o){e.save();const i=o*t.r(.32,.52),l=e.createLinearGradient(0,0,0,i);l.addColorStop(0,n.deep),l.addColorStop(1,t.pick(n.fills)),e.globalAlpha=.3,e.fillStyle=l,e.fillRect(0,0,r,i),e.beginPath(),e.moveTo(-2,o+2);const a=t.r(.02,.07),s=t.r(2,8),u=t.r(0,20);for(let g=-2;g<=r+2;g+=2)e.lineTo(g,i+Math.sin(g*a+u)*s+Math.sin(g*a*2.5+u*.7)*s*.4);e.lineTo(r+2,o+2),e.closePath(),e.globalAlpha=.22,e.fillStyle=t.pick(n.fills),e.fill();const m=e.createLinearGradient(0,i-6,0,i+6);m.addColorStop(0,"rgba(0,0,0,0)"),m.addColorStop(.5,n.glow),m.addColorStop(1,"rgba(0,0,0,0)"),e.globalAlpha=.18,e.fillStyle=m,e.fillRect(0,i-6,r,12);const c=t.r(6,14),f=t.r(r*.2,r*.8),v=t.r(2,i*.5),y=e.createRadialGradient(f,v,0,f,v,c);y.addColorStop(0,n.glow),y.addColorStop(1,"rgba(0,0,0,0)"),e.globalAlpha=.15,e.fillStyle=y,e.fillRect(f-c,v-c,c*2,c*2),e.restore()}function bh(e,t,n,r,o){e.save();const i=t.i(1,4);for(let l=0;l<i;l++){const a=t.r(r*.15,r*.85),s=t.r(o*.15,o*.85),u=t.r(5,16),m=t.i(6,14),c=u*.28,f=u*.65;e.globalAlpha=t.r(.08,.22),e.strokeStyle=n.glow,e.lineWidth=t.r(.4,1.2),e.beginPath();for(let v=0;v<m;v++){const y=v/m*Math.PI*2,g=(v+.3)/m*Math.PI*2,N=(v+.7)/m*Math.PI*2,p=(v+1)/m*Math.PI*2;e.lineTo(a+Math.cos(y)*f,s+Math.sin(y)*f),e.lineTo(a+Math.cos(g)*(f+c),s+Math.sin(g)*(f+c)),e.lineTo(a+Math.cos(N)*(f+c),s+Math.sin(N)*(f+c)),e.lineTo(a+Math.cos(p)*f,s+Math.sin(p)*f)}e.closePath(),e.stroke(),e.beginPath(),e.arc(a,s,u*.22,0,Math.PI*2),e.stroke()}e.restore()}const qh={creature:Gh,sorcery:$a,instant:$a,enchantment:Kh,land:Yh,artifact:bh};function Xh(e,t,n){e.save();const r=e.createRadialGradient(t*.5,n*.5,Math.min(t,n)*.25,t*.5,n*.5,Math.max(t,n)*.85);r.addColorStop(0,"rgba(0,0,0,0)"),r.addColorStop(1,"rgba(0,0,0,0.35)"),e.fillStyle=r,e.fillRect(0,0,t,n),e.restore()}function Jh(e,t,n,r){e.save();const o=Math.floor(n*r*.04);for(let i=0;i<o;i++){const l=Math.floor(t.f()*n),a=Math.floor(t.f()*r),s=t.i(0,256);e.fillStyle=`rgba(${s},${s},${s},${t.r(.01,.04)})`,e.fillRect(l,a,1,1)}e.restore()}const Zh=z.memo(function({cardName:t,color:n="colorless",type:r="creature",width:o=130,height:i=70}){const l=z.useRef(null);return z.useEffect(()=>{const a=l.current;if(!a)return;const s=window.devicePixelRatio||1;a.width=o*s,a.height=i*s;const u=a.getContext("2d");u.scale(s,s);const m=$h(t),c=Ba[n]||Ba.colorless;(Fa[n]||Fa.colorless)(u,m,c,o,i);const v=qh[r];v&&v(u,m,c,o,i),Xh(u,o,i),Jh(u,m,o,i)},[t,n,r,o,i]),S.jsx("canvas",{ref:l,style:{width:`${o}px`,height:`${i}px`,display:"block"}})}),Ua={radiance:{bg:"#fff8e7",border:"#d4a843",accent:"#f0d060"},tide:{bg:"#e7f0ff",border:"#4477bb",accent:"#6699dd"},shadow:{bg:"#2a2a2a",border:"#666",accent:"#8a7090",text:"#ddd"},flame:{bg:"#fff0e7",border:"#cc4422",accent:"#ee6644"},growth:{bg:"#eaf5e7",border:"#448833",accent:"#66aa55"},colorless:{bg:"#f0f0f0",border:"#999",accent:"#bbb"}},e0={swift:"Swift",vigilant:"Vigilant",soaring:"Soaring",guardian:"Guardian",fortified:"Fortified",draining:"Draining",overwhelming:"Overwhelming",venomous:"Venomous",reaching:"Reaching"};function t0(e){if(!e)return"";const t=[];e.colorless&&t.push(String(e.colorless));const n={radiance:"☀",tide:"🌊",shadow:"💀",flame:"🔥",growth:"🌿"};for(const[r,o]of Object.entries(n))for(let i=0;i<(e[r]||0);i++)t.push(o);return t.join(" ")}function Vr({card:e,instance:t,onClick:n,selected:r,selectable:o,small:i,faceDown:l,zone:a}){if(l)return S.jsx("div",{className:"card card-facedown",onClick:n,children:S.jsx("div",{className:"card-back",children:"Arcane Duels"})});const s=(t==null?void 0:t.cardData)||e;if(!s)return null;const u=Ua[s.color]||Ua.colorless,m=s.type==="creature",c=s.type==="land",f=t==null?void 0:t.tapped,v=s.keywords||[],y=t?t.effectivePower:s.power,g=t?t.effectiveToughness-(t.damage||0):s.toughness,N=["card",`card-${s.type}`,`color-${s.color}`,f?"tapped":"",r?"selected":"",o?"selectable":"",i?"card-small":"",a?`zone-${a}`:"",t!=null&&t.summoningSickness?"summoning-sick":""].filter(Boolean).join(" "),p={"--card-bg":u.bg,"--card-border":u.border,"--card-accent":u.accent,color:u.text||"#222"};return S.jsxs("div",{className:N,style:p,onClick:n,children:[S.jsxs("div",{className:"card-header",children:[S.jsx("span",{className:"card-name",children:s.name}),!c&&S.jsx("span",{className:"card-cost",children:t0(s.cost)})]}),S.jsx("div",{className:"card-art",children:S.jsx(Zh,{cardName:s.name,color:s.color,type:s.type,width:i?100:130,height:i?45:70})}),S.jsxs("div",{className:"card-type-line",children:[s.type.charAt(0).toUpperCase()+s.type.slice(1),s.subtype?` — ${s.subtype}`:""]}),S.jsxs("div",{className:"card-text",children:[v.length>0&&S.jsx("div",{className:"card-keywords",children:v.map(d=>e0[d]||d).join(", ")}),s.flavor&&!i&&S.jsx("div",{className:"card-flavor",children:s.flavor})]}),m&&S.jsx("div",{className:"card-pt",children:S.jsxs("span",{className:(t==null?void 0:t.damage)>0?"damaged":"",children:[y,"/",g]})})]})}const n0={untap:"Untap",upkeep:"Upkeep",draw:"Draw",main1:"Main 1",combat_begin:"Combat",combat_attackers:"Attackers",combat_blockers:"Blockers",combat_damage:"Damage",combat_end:"End Combat",main2:"Main 2",end_step:"End",cleanup:"Cleanup"},Ra={radiance:"☀",tide:"🌊",shadow:"💀",flame:"🔥",growth:"🌿",colorless:"⚪"};function r0({gameState:e,playerId:t,onLeave:n}){var Qe;const[r,o]=z.useState(null),[i,l]=z.useState([]),[a,s]=z.useState({}),[u,m]=z.useState(null),[c,f]=z.useState(null),[v,y]=z.useState(0),[g,N]=z.useState(null),[p,d]=z.useState(!1),h=e.activePlayerId===t,k=e.currentPhase,C=e.players[t],P=Object.keys(e.players).find(T=>T!==t),E=e.players[P];z.useEffect(()=>{const T=M=>{M.type==="chooseManaColor"&&N(M.options)};return R.on("needsResponse",T),()=>R.off("needsResponse",T)},[]),z.useEffect(()=>{l([]),s({})},[k]);const _=z.useCallback(T=>{R.emit("gameAction",{action:T})},[]),F=z.useCallback(T=>{_({type:"tapLand",instanceId:T})},[_]),A=z.useCallback((T,M=!1)=>{_({type:"tapAbility",instanceId:T,sacrifice:M})},[_]),ue=z.useCallback(T=>{var $,dt,_e;const M=C.hand[T];if(!M)return;if(M.type==="land"){_({type:"playLand",handIndex:T}),o(null);return}const re=($=M.abilities)==null?void 0:$.some(pt=>["destroyCreature","destroyCreatureIf","bounceCreature","pumpCreature","dealDamage","drainLife","tapCreature","giveKeyword","preventDamage"].includes(pt.effect));if((dt=M.abilities)==null?void 0:dt.some(pt=>pt.isX)){f({handIndex:T,needsTarget:re,cardData:M}),m(null);return}if(re){f({handIndex:T,needsTarget:!0,cardData:M,xAmount:0}),m("creature");return}if((_e=M.abilities)==null?void 0:_e.some(pt=>pt.target==="any"&&["dealDamage","drainLife"].includes(pt.effect))){f({handIndex:T,needsTarget:!0,cardData:M,xAmount:0,canTargetPlayer:!0}),m("any");return}_({type:"castSpell",handIndex:T}),o(null)},[C,_]),ct=z.useCallback(T=>{c&&(_({type:"castSpell",handIndex:c.handIndex,targetInstanceId:T,xAmount:c.xAmount||v}),f(null),m(null),o(null),y(0))},[c,v,_]),ft=z.useCallback(T=>{c&&(_({type:"castSpell",handIndex:c.handIndex,targetPlayerId:T,xAmount:c.xAmount||v}),f(null),m(null),o(null),y(0))},[c,v,_]),Cr=z.useCallback(()=>{_({type:"declareAttackers",attackerIds:i}),l([])},[i,_]),Yo=z.useCallback(()=>{_({type:"declareBlockers",blockerAssignments:a}),s({})},[a,_]),On=z.useCallback(()=>{_({type:"passPriority"})},[_]),Mn=z.useCallback(()=>{window.confirm("Are you sure you want to concede?")&&_({type:"concede"})},[_]),L=z.useCallback(T=>{_({type:"chooseManaColor",color:T}),N(null)},[_]),j=z.useCallback(T=>{l(M=>M.includes(T)?M.filter(re=>re!==T):[...M,T])},[]),I=z.useCallback((T,M)=>{s(re=>{const Ge={...re};return Ge[T]===M?delete Ge[T]:Ge[T]=M,Ge})},[]),W=z.useCallback((T,M)=>{var Xt,$,dt;if(u&&c){ct(T.instanceId);return}if(M)return;if(k==="combat_attackers"&&h&&T.cardData.type==="creature"){j(T.instanceId);return}if((T.cardData.type==="land"||(Xt=T.cardData.abilities)!=null&&Xt.some(_e=>_e.trigger==="tap"&&_e.effect==="addMana"))&&!T.tapped){F(T.instanceId);return}const re=($=T.cardData.abilities)==null?void 0:$.some(_e=>_e.trigger==="tap"&&_e.effect!=="addMana"),Ge=(dt=T.cardData.abilities)==null?void 0:dt.some(_e=>_e.trigger==="tap_sacrifice");re&&!T.tapped?A(T.instanceId,!1):Ge&&A(T.instanceId,!0)},[u,c,k,h,ct,j,F,A]),X=T=>S.jsx("div",{className:"mana-pool",children:Object.entries(T).map(([M,re])=>re>0?S.jsxs("span",{className:`mana mana-${M}`,children:[Ra[M],re]},M):null)}),xt=(T,M)=>{const re=T.battlefield.filter($=>$.cardData.type==="land"),Ge=T.battlefield.filter($=>$.cardData.type==="creature"),Xt=T.battlefield.filter($=>$.cardData.type!=="land"&&$.cardData.type!=="creature");return S.jsxs("div",{className:`battlefield ${M?"opponent":"mine"}`,children:[Xt.length>0&&S.jsx("div",{className:"bf-row bf-others",children:Xt.map($=>S.jsx(Vr,{instance:$,small:!0,onClick:()=>W($,M),selected:i.includes($.instanceId),selectable:u!==null},$.instanceId))}),S.jsx("div",{className:"bf-row bf-creatures",children:Ge.length===0?S.jsx("div",{className:"bf-empty",children:"No creatures"}):Ge.map($=>{const dt=e.attackers.includes($.instanceId),_e=Object.values(a).includes($.instanceId)||Object.values(e.blockers).flat().includes($.instanceId);return S.jsxs("div",{className:`bf-creature-slot ${dt?"attacking":""} ${_e?"blocking":""}`,children:[S.jsx(Vr,{instance:$,small:!0,onClick:()=>{if(k==="combat_blockers"&&!h&&!M&&e.attackers.length>0){const pt=e.attackers[0];I($.instanceId,pt)}else W($,M)},selected:i.includes($.instanceId)||Object.keys(a).includes($.instanceId),selectable:k==="combat_attackers"&&h&&!M||k==="combat_blockers"&&!h&&!M||u!==null}),dt&&S.jsx("div",{className:"combat-badge attack-badge",children:"ATK"}),_e&&S.jsx("div",{className:"combat-badge block-badge",children:"BLK"})]},$.instanceId)})}),S.jsx("div",{className:"bf-row bf-lands",children:re.map($=>S.jsx(Vr,{instance:$,small:!0,onClick:()=>W($,M)},$.instanceId))})]})};return e.gameOver?S.jsx("div",{className:"game-over-overlay",children:S.jsxs("div",{className:"game-over-modal",children:[S.jsx("h1",{children:e.winner===t?"Victory!":"Defeat"}),S.jsx("p",{children:e.winner===t?"You have won the duel!":"You have been defeated."}),S.jsx("button",{className:"btn btn-primary",onClick:n,children:"Back to Lobby"})]})}):S.jsxs("div",{className:"game-board",children:[S.jsxs("div",{className:"game-top-bar",children:[S.jsx("button",{className:"btn btn-small btn-back",onClick:Mn,children:"Concede"}),S.jsx("div",{className:"phase-tracker",children:Object.entries(n0).map(([T,M])=>S.jsx("span",{className:`phase-pip ${k===T?"active":""} ${h?"my-turn":""}`,children:M},T))}),S.jsxs("div",{className:"turn-info",children:["Turn ",e.turnNumber," · ",h?"Your turn":"Opponent's turn"]}),S.jsx("button",{className:"btn btn-small",onClick:()=>d(!p),children:"Log"})]}),S.jsxs("div",{className:"opponent-area",children:[S.jsxs("div",{className:"player-info opponent-info",children:[S.jsxs("span",{className:"life-total",children:["❤"," ",E.life]}),S.jsxs("span",{className:"hand-count",children:["🃏"," ",E.handCount]}),S.jsxs("span",{className:"library-count",children:["Deck: ",E.libraryCount]}),X(E.manaPool),u==="any"&&S.jsx("button",{className:"btn btn-target",onClick:()=>ft(P),children:"Target Opponent"})]}),xt(E,!0)]}),S.jsxs("div",{className:"combat-zone",children:[k==="combat_attackers"&&h&&S.jsxs("div",{className:"combat-controls",children:[S.jsx("span",{children:"Select attackers, then:"}),S.jsx("button",{className:"btn btn-primary",onClick:Cr,children:i.length>0?`Attack with ${i.length} creature(s)`:"Skip Attack"})]}),k==="combat_blockers"&&!h&&S.jsxs("div",{className:"combat-controls",children:[S.jsx("span",{children:"Select blockers, then:"}),S.jsx("button",{className:"btn btn-primary",onClick:Yo,children:Object.keys(a).length>0?`Block with ${Object.keys(a).length} creature(s)`:"No Blocks"})]})]}),S.jsxs("div",{className:"my-area",children:[xt(C,!1),S.jsxs("div",{className:"player-info my-info",children:[S.jsxs("span",{className:"life-total",children:["❤"," ",C.life]}),S.jsxs("span",{className:"library-count",children:["Deck: ",C.libraryCount]}),X(C.manaPool),u==="any"&&S.jsx("button",{className:"btn btn-target",onClick:()=>ft(t),children:"Target Self"})]})]}),S.jsxs("div",{className:"hand-area",children:[S.jsx("div",{className:"hand",children:C.hand.map((T,M)=>S.jsx("div",{className:"hand-slot",children:S.jsx(Vr,{card:T,onClick:()=>{r===M?ue(M):o(M)},selected:r===M,selectable:h||T.type==="instant"})},`${T.cardId}-${M}`))}),S.jsx("div",{className:"hand-actions",children:(h||k==="combat_blockers")&&S.jsx("button",{className:"btn btn-pass",onClick:On,children:k==="main1"?"Go to Combat":k==="main2"?"End Turn":k==="combat_blockers"&&!h?"No Blocks":"Pass"})})]}),c&&((Qe=c.cardData.abilities)==null?void 0:Qe.some(T=>T.isX))&&!u&&S.jsx("div",{className:"modal-overlay",children:S.jsxs("div",{className:"modal",children:[S.jsxs("h3",{children:["Choose X value for ",c.cardData.name]}),S.jsxs("div",{className:"x-picker",children:[S.jsx("button",{onClick:()=>y(Math.max(0,v-1)),children:"-"}),S.jsx("span",{className:"x-value",children:v}),S.jsx("button",{onClick:()=>y(v+1),children:"+"})]}),S.jsxs("div",{className:"modal-actions",children:[S.jsx("button",{className:"btn btn-primary",onClick:()=>{c.needsTarget?(f({...c,xAmount:v}),m("any")):(_({type:"castSpell",handIndex:c.handIndex,xAmount:v,targetPlayerId:c.canTargetPlayer?P:void 0}),f(null),o(null),y(0))},children:c.needsTarget?"Choose Target":"Cast"}),S.jsx("button",{className:"btn",onClick:()=>{f(null),y(0)},children:"Cancel"})]})]})}),g&&S.jsx("div",{className:"modal-overlay",children:S.jsxs("div",{className:"modal",children:[S.jsx("h3",{children:"Choose mana color"}),S.jsx("div",{className:"mana-choice-grid",children:g.map(T=>S.jsxs("button",{className:`btn mana-choice-btn color-${T}`,onClick:()=>L(T),children:[Ra[T]," ",T.charAt(0).toUpperCase()+T.slice(1)]},T))})]})}),u&&S.jsxs("div",{className:"target-banner",children:["Choose a target (click a creature",u==="any"?" or player":"",")",S.jsx("button",{className:"btn btn-small",onClick:()=>{m(null),f(null)},children:"Cancel"})]}),p&&S.jsxs("div",{className:"game-log-panel",children:[S.jsxs("div",{className:"log-header",children:[S.jsx("h3",{children:"Game Log"}),S.jsx("button",{className:"btn btn-small",onClick:()=>d(!1),children:"Close"})]}),S.jsx("div",{className:"log-entries",children:e.log.slice().reverse().map((T,M)=>S.jsxs("div",{className:"log-entry",children:[S.jsxs("span",{className:"log-turn",children:["T",T.turn]}),S.jsx("span",{className:"log-msg",children:T.message})]},M))})]})]})}const mt={NAME:"name",LOBBY:"lobby",ROOM:"room",GAME:"game"};function o0(){const[e,t]=z.useState(mt.NAME),[n,r]=z.useState(""),[o,i]=z.useState(null),[l,a]=z.useState([]),[s,u]=z.useState(null),[m,c]=z.useState(null),[f,v]=z.useState(null),[y,g]=z.useState(null),[N,p]=z.useState(!1);z.useEffect(()=>(R.connect(),R.on("connect",()=>{p(!0),i(R.id)}),R.on("disconnect",()=>p(!1)),R.on("nameSet",k=>{i(k.id),t(mt.LOBBY)}),R.on("roomsUpdated",k=>a(k)),R.on("roomCreated",k=>{u(k),t(mt.ROOM)}),R.on("roomJoined",k=>{u(k),t(mt.ROOM)}),R.on("roomUpdated",k=>u(k)),R.on("gameStarted",k=>{v(k.gameId),c(k.state),t(mt.GAME)}),R.on("gameStateUpdated",k=>c(k)),R.on("error",k=>{g(k.message),setTimeout(()=>g(null),3e3)}),R.on("actionError",k=>{g(k.message),setTimeout(()=>g(null),3e3)}),R.on("playerDisconnected",k=>{g(`${k.playerName} disconnected`),setTimeout(()=>g(null),3e3)}),R.on("needsResponse",()=>{}),()=>{R.removeAllListeners(),R.disconnect()}),[]);const d=z.useCallback(k=>{k.preventDefault(),n.trim()&&R.emit("setName",n.trim())},[n]),h=z.useCallback(()=>{R.emit("leaveRoom"),u(null),c(null),v(null),t(mt.LOBBY),R.emit("getRooms")},[]);return e===mt.NAME?S.jsxs("div",{className:"app",children:[S.jsxs("div",{className:"title-screen",children:[S.jsx("h1",{className:"game-title",children:"Arcane Duels"}),S.jsx("p",{className:"game-subtitle",children:"A game of strategy, mana, and might"}),S.jsxs("form",{onSubmit:d,className:"name-form",children:[S.jsx("input",{type:"text",value:n,onChange:k=>r(k.target.value),placeholder:"Enter your name...",className:"name-input",maxLength:20,autoFocus:!0}),S.jsx("button",{type:"submit",className:"btn btn-primary",disabled:!N,children:N?"Enter the Arena":"Connecting..."})]})]}),y&&S.jsx("div",{className:"error-toast",children:y})]}):e===mt.GAME&&m?S.jsxs("div",{className:"app",children:[S.jsx(r0,{gameState:m,playerId:o,onLeave:h}),y&&S.jsx("div",{className:"error-toast",children:y})]}):S.jsxs("div",{className:"app",children:[S.jsx(xh,{playerId:o,playerName:n,rooms:l,currentRoom:s,screen:e,onBackToLobby:h}),y&&S.jsx("div",{className:"error-toast",children:y})]})}Ei.createRoot(document.getElementById("root")).render(S.jsx(Af.StrictMode,{children:S.jsx(o0,{})}));
|