@puth/gui 0.1.4 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,91 @@
1
+ var jy=Object.defineProperty;var Ty=(e,t,n)=>t in e?jy(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var I=(e,t,n)=>Ty(e,typeof t!="symbol"?t+"":t,n);function Ry(e,t){for(var n=0;n<t.length;n++){const r=t[n];if(typeof r!="string"&&!Array.isArray(r)){for(const i in r)if(i!=="default"&&!(i in e)){const o=Object.getOwnPropertyDescriptor(r,i);o&&Object.defineProperty(e,i,o.get?o:{enumerable:!0,get:()=>r[i]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))r(i);new MutationObserver(i=>{for(const o of i)if(o.type==="childList")for(const s of o.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&r(s)}).observe(document,{childList:!0,subtree:!0});function n(i){const o={};return i.integrity&&(o.integrity=i.integrity),i.referrerPolicy&&(o.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?o.credentials="include":i.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function r(i){if(i.ep)return;i.ep=!0;const o=n(i);fetch(i.href,o)}})();function Fc(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Lp={exports:{}},Vl={},Ip={exports:{}},G={};/**
2
+ * @license React
3
+ * react.production.min.js
4
+ *
5
+ * Copyright (c) Facebook, Inc. and its affiliates.
6
+ *
7
+ * This source code is licensed under the MIT license found in the
8
+ * LICENSE file in the root directory of this source tree.
9
+ */var zo=Symbol.for("react.element"),Dy=Symbol.for("react.portal"),My=Symbol.for("react.fragment"),Ly=Symbol.for("react.strict_mode"),Iy=Symbol.for("react.profiler"),Fy=Symbol.for("react.provider"),zy=Symbol.for("react.context"),Uy=Symbol.for("react.forward_ref"),By=Symbol.for("react.suspense"),$y=Symbol.for("react.memo"),Vy=Symbol.for("react.lazy"),ud=Symbol.iterator;function Wy(e){return e===null||typeof e!="object"?null:(e=ud&&e[ud]||e["@@iterator"],typeof e=="function"?e:null)}var Fp={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},zp=Object.assign,Up={};function bi(e,t,n){this.props=e,this.context=t,this.refs=Up,this.updater=n||Fp}bi.prototype.isReactComponent={};bi.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")};bi.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Bp(){}Bp.prototype=bi.prototype;function zc(e,t,n){this.props=e,this.context=t,this.refs=Up,this.updater=n||Fp}var Uc=zc.prototype=new Bp;Uc.constructor=zc;zp(Uc,bi.prototype);Uc.isPureReactComponent=!0;var cd=Array.isArray,$p=Object.prototype.hasOwnProperty,Bc={current:null},Vp={key:!0,ref:!0,__self:!0,__source:!0};function Wp(e,t,n){var r,i={},o=null,s=null;if(t!=null)for(r in t.ref!==void 0&&(s=t.ref),t.key!==void 0&&(o=""+t.key),t)$p.call(t,r)&&!Vp.hasOwnProperty(r)&&(i[r]=t[r]);var l=arguments.length-2;if(l===1)i.children=n;else if(1<l){for(var a=Array(l),u=0;u<l;u++)a[u]=arguments[u+2];i.children=a}if(e&&e.defaultProps)for(r in l=e.defaultProps,l)i[r]===void 0&&(i[r]=l[r]);return{$$typeof:zo,type:e,key:o,ref:s,props:i,_owner:Bc.current}}function Hy(e,t){return{$$typeof:zo,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function $c(e){return typeof e=="object"&&e!==null&&e.$$typeof===zo}function Ky(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var fd=/\/+/g;function ka(e,t){return typeof e=="object"&&e!==null&&e.key!=null?Ky(""+e.key):t.toString(36)}function Ds(e,t,n,r,i){var o=typeof e;(o==="undefined"||o==="boolean")&&(e=null);var s=!1;if(e===null)s=!0;else switch(o){case"string":case"number":s=!0;break;case"object":switch(e.$$typeof){case zo:case Dy:s=!0}}if(s)return s=e,i=i(s),e=r===""?"."+ka(s,0):r,cd(i)?(n="",e!=null&&(n=e.replace(fd,"$&/")+"/"),Ds(i,t,n,"",function(u){return u})):i!=null&&($c(i)&&(i=Hy(i,n+(!i.key||s&&s.key===i.key?"":(""+i.key).replace(fd,"$&/")+"/")+e)),t.push(i)),1;if(s=0,r=r===""?".":r+":",cd(e))for(var l=0;l<e.length;l++){o=e[l];var a=r+ka(o,l);s+=Ds(o,t,n,a,i)}else if(a=Wy(e),typeof a=="function")for(e=a.call(e),l=0;!(o=e.next()).done;)o=o.value,a=r+ka(o,l++),s+=Ds(o,t,n,a,i);else if(o==="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 s}function os(e,t,n){if(e==null)return e;var r=[],i=0;return Ds(e,r,"","",function(o){return t.call(n,o,i++)}),r}function Gy(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 Le={current:null},Ms={transition:null},Qy={ReactCurrentDispatcher:Le,ReactCurrentBatchConfig:Ms,ReactCurrentOwner:Bc};function Hp(){throw Error("act(...) is not supported in production builds of React.")}G.Children={map:os,forEach:function(e,t,n){os(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return os(e,function(){t++}),t},toArray:function(e){return os(e,function(t){return t})||[]},only:function(e){if(!$c(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};G.Component=bi;G.Fragment=My;G.Profiler=Iy;G.PureComponent=zc;G.StrictMode=Ly;G.Suspense=By;G.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Qy;G.act=Hp;G.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=zp({},e.props),i=e.key,o=e.ref,s=e._owner;if(t!=null){if(t.ref!==void 0&&(o=t.ref,s=Bc.current),t.key!==void 0&&(i=""+t.key),e.type&&e.type.defaultProps)var l=e.type.defaultProps;for(a in t)$p.call(t,a)&&!Vp.hasOwnProperty(a)&&(r[a]=t[a]===void 0&&l!==void 0?l[a]:t[a])}var a=arguments.length-2;if(a===1)r.children=n;else if(1<a){l=Array(a);for(var u=0;u<a;u++)l[u]=arguments[u+2];r.children=l}return{$$typeof:zo,type:e.type,key:i,ref:o,props:r,_owner:s}};G.createContext=function(e){return e={$$typeof:zy,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:Fy,_context:e},e.Consumer=e};G.createElement=Wp;G.createFactory=function(e){var t=Wp.bind(null,e);return t.type=e,t};G.createRef=function(){return{current:null}};G.forwardRef=function(e){return{$$typeof:Uy,render:e}};G.isValidElement=$c;G.lazy=function(e){return{$$typeof:Vy,_payload:{_status:-1,_result:e},_init:Gy}};G.memo=function(e,t){return{$$typeof:$y,type:e,compare:t===void 0?null:t}};G.startTransition=function(e){var t=Ms.transition;Ms.transition={};try{e()}finally{Ms.transition=t}};G.unstable_act=Hp;G.useCallback=function(e,t){return Le.current.useCallback(e,t)};G.useContext=function(e){return Le.current.useContext(e)};G.useDebugValue=function(){};G.useDeferredValue=function(e){return Le.current.useDeferredValue(e)};G.useEffect=function(e,t){return Le.current.useEffect(e,t)};G.useId=function(){return Le.current.useId()};G.useImperativeHandle=function(e,t,n){return Le.current.useImperativeHandle(e,t,n)};G.useInsertionEffect=function(e,t){return Le.current.useInsertionEffect(e,t)};G.useLayoutEffect=function(e,t){return Le.current.useLayoutEffect(e,t)};G.useMemo=function(e,t){return Le.current.useMemo(e,t)};G.useReducer=function(e,t,n){return Le.current.useReducer(e,t,n)};G.useRef=function(e){return Le.current.useRef(e)};G.useState=function(e){return Le.current.useState(e)};G.useSyncExternalStore=function(e,t,n){return Le.current.useSyncExternalStore(e,t,n)};G.useTransition=function(){return Le.current.useTransition()};G.version="18.3.1";Ip.exports=G;var x=Ip.exports;const Cn=Fc(x),Kp=Ry({__proto__:null,default:Cn},[x]);/**
10
+ * @license React
11
+ * react-jsx-runtime.production.min.js
12
+ *
13
+ * Copyright (c) Facebook, Inc. and its affiliates.
14
+ *
15
+ * This source code is licensed under the MIT license found in the
16
+ * LICENSE file in the root directory of this source tree.
17
+ */var Yy=x,Xy=Symbol.for("react.element"),Zy=Symbol.for("react.fragment"),Jy=Object.prototype.hasOwnProperty,qy=Yy.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,ew={key:!0,ref:!0,__self:!0,__source:!0};function Gp(e,t,n){var r,i={},o=null,s=null;n!==void 0&&(o=""+n),t.key!==void 0&&(o=""+t.key),t.ref!==void 0&&(s=t.ref);for(r in t)Jy.call(t,r)&&!ew.hasOwnProperty(r)&&(i[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)i[r]===void 0&&(i[r]=t[r]);return{$$typeof:Xy,type:e,key:o,ref:s,props:i,_owner:qy.current}}Vl.Fragment=Zy;Vl.jsx=Gp;Vl.jsxs=Gp;Lp.exports=Vl;var h=Lp.exports,_u={},Qp={exports:{}},et={},Yp={exports:{}},Xp={};/**
18
+ * @license React
19
+ * scheduler.production.min.js
20
+ *
21
+ * Copyright (c) Facebook, Inc. and its affiliates.
22
+ *
23
+ * This source code is licensed under the MIT license found in the
24
+ * LICENSE file in the root directory of this source tree.
25
+ */(function(e){function t(O,R){var F=O.length;O.push(R);e:for(;0<F;){var H=F-1>>>1,ce=O[H];if(0<i(ce,R))O[H]=R,O[F]=ce,F=H;else break e}}function n(O){return O.length===0?null:O[0]}function r(O){if(O.length===0)return null;var R=O[0],F=O.pop();if(F!==R){O[0]=F;e:for(var H=0,ce=O.length,Yt=ce>>>1;H<Yt;){var rt=2*(H+1)-1,jt=O[rt],Fe=rt+1,ze=O[Fe];if(0>i(jt,F))Fe<ce&&0>i(ze,jt)?(O[H]=ze,O[Fe]=F,H=Fe):(O[H]=jt,O[rt]=F,H=rt);else if(Fe<ce&&0>i(ze,F))O[H]=ze,O[Fe]=F,H=Fe;else break e}}return R}function i(O,R){var F=O.sortIndex-R.sortIndex;return F!==0?F:O.id-R.id}if(typeof performance=="object"&&typeof performance.now=="function"){var o=performance;e.unstable_now=function(){return o.now()}}else{var s=Date,l=s.now();e.unstable_now=function(){return s.now()-l}}var a=[],u=[],c=1,f=null,d=3,p=!1,y=!1,m=!1,b=typeof setTimeout=="function"?setTimeout:null,v=typeof clearTimeout=="function"?clearTimeout:null,g=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function w(O){for(var R=n(u);R!==null;){if(R.callback===null)r(u);else if(R.startTime<=O)r(u),R.sortIndex=R.expirationTime,t(a,R);else break;R=n(u)}}function _(O){if(m=!1,w(O),!y)if(n(a)!==null)y=!0,Z(S);else{var R=n(u);R!==null&&J(_,R.startTime-O)}}function S(O,R){y=!1,m&&(m=!1,v(C),C=-1),p=!0;var F=d;try{for(w(R),f=n(a);f!==null&&(!(f.expirationTime>R)||O&&!D());){var H=f.callback;if(typeof H=="function"){f.callback=null,d=f.priorityLevel;var ce=H(f.expirationTime<=R);R=e.unstable_now(),typeof ce=="function"?f.callback=ce:f===n(a)&&r(a),w(R)}else r(a);f=n(a)}if(f!==null)var Yt=!0;else{var rt=n(u);rt!==null&&J(_,rt.startTime-R),Yt=!1}return Yt}finally{f=null,d=F,p=!1}}var E=!1,A=null,C=-1,j=5,P=-1;function D(){return!(e.unstable_now()-P<j)}function k(){if(A!==null){var O=e.unstable_now();P=O;var R=!0;try{R=A(!0,O)}finally{R?z():(E=!1,A=null)}}else E=!1}var z;if(typeof g=="function")z=function(){g(k)};else if(typeof MessageChannel<"u"){var B=new MessageChannel,K=B.port2;B.port1.onmessage=k,z=function(){K.postMessage(null)}}else z=function(){b(k,0)};function Z(O){A=O,E||(E=!0,z())}function J(O,R){C=b(function(){O(e.unstable_now())},R)}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(O){O.callback=null},e.unstable_continueExecution=function(){y||p||(y=!0,Z(S))},e.unstable_forceFrameRate=function(O){0>O||125<O?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):j=0<O?Math.floor(1e3/O):5},e.unstable_getCurrentPriorityLevel=function(){return d},e.unstable_getFirstCallbackNode=function(){return n(a)},e.unstable_next=function(O){switch(d){case 1:case 2:case 3:var R=3;break;default:R=d}var F=d;d=R;try{return O()}finally{d=F}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(O,R){switch(O){case 1:case 2:case 3:case 4:case 5:break;default:O=3}var F=d;d=O;try{return R()}finally{d=F}},e.unstable_scheduleCallback=function(O,R,F){var H=e.unstable_now();switch(typeof F=="object"&&F!==null?(F=F.delay,F=typeof F=="number"&&0<F?H+F:H):F=H,O){case 1:var ce=-1;break;case 2:ce=250;break;case 5:ce=1073741823;break;case 4:ce=1e4;break;default:ce=5e3}return ce=F+ce,O={id:c++,callback:R,priorityLevel:O,startTime:F,expirationTime:ce,sortIndex:-1},F>H?(O.sortIndex=F,t(u,O),n(a)===null&&O===n(u)&&(m?(v(C),C=-1):m=!0,J(_,F-H))):(O.sortIndex=ce,t(a,O),y||p||(y=!0,Z(S))),O},e.unstable_shouldYield=D,e.unstable_wrapCallback=function(O){var R=d;return function(){var F=d;d=R;try{return O.apply(this,arguments)}finally{d=F}}}})(Xp);Yp.exports=Xp;var tw=Yp.exports;/**
26
+ * @license React
27
+ * react-dom.production.min.js
28
+ *
29
+ * Copyright (c) Facebook, Inc. and its affiliates.
30
+ *
31
+ * This source code is licensed under the MIT license found in the
32
+ * LICENSE file in the root directory of this source tree.
33
+ */var nw=x,qe=tw;function N(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 Zp=new Set,vo={};function Cr(e,t){ui(e,t),ui(e+"Capture",t)}function ui(e,t){for(vo[e]=t,e=0;e<t.length;e++)Zp.add(t[e])}var fn=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),bu=Object.prototype.hasOwnProperty,rw=/^[: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]*$/,dd={},hd={};function iw(e){return bu.call(hd,e)?!0:bu.call(dd,e)?!1:rw.test(e)?hd[e]=!0:(dd[e]=!0,!1)}function ow(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 sw(e,t,n,r){if(t===null||typeof t>"u"||ow(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 Ie(e,t,n,r,i,o,s){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=o,this.removeEmptyString=s}var Pe={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Pe[e]=new Ie(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Pe[t]=new Ie(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Pe[e]=new Ie(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Pe[e]=new Ie(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){Pe[e]=new Ie(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Pe[e]=new Ie(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Pe[e]=new Ie(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Pe[e]=new Ie(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Pe[e]=new Ie(e,5,!1,e.toLowerCase(),null,!1,!1)});var Vc=/[\-:]([a-z])/g;function Wc(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(Vc,Wc);Pe[t]=new Ie(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(Vc,Wc);Pe[t]=new Ie(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(Vc,Wc);Pe[t]=new Ie(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Pe[e]=new Ie(e,1,!1,e.toLowerCase(),null,!1,!1)});Pe.xlinkHref=new Ie("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Pe[e]=new Ie(e,1,!1,e.toLowerCase(),null,!0,!0)});function Hc(e,t,n,r){var i=Pe.hasOwnProperty(t)?Pe[t]:null;(i!==null?i.type!==0:r||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(sw(t,n,i,r)&&(n=null),r||i===null?iw(t)&&(n===null?e.removeAttribute(t):e.setAttribute(t,""+n)):i.mustUseProperty?e[i.propertyName]=n===null?i.type===3?!1:"":n:(t=i.attributeName,r=i.attributeNamespace,n===null?e.removeAttribute(t):(i=i.type,n=i===3||i===4&&n===!0?"":""+n,r?e.setAttributeNS(r,t,n):e.setAttribute(t,n))))}var yn=nw.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,ss=Symbol.for("react.element"),Fr=Symbol.for("react.portal"),zr=Symbol.for("react.fragment"),Kc=Symbol.for("react.strict_mode"),Su=Symbol.for("react.profiler"),Jp=Symbol.for("react.provider"),qp=Symbol.for("react.context"),Gc=Symbol.for("react.forward_ref"),Eu=Symbol.for("react.suspense"),Au=Symbol.for("react.suspense_list"),Qc=Symbol.for("react.memo"),En=Symbol.for("react.lazy"),ev=Symbol.for("react.offscreen"),pd=Symbol.iterator;function Ii(e){return e===null||typeof e!="object"?null:(e=pd&&e[pd]||e["@@iterator"],typeof e=="function"?e:null)}var pe=Object.assign,Oa;function Yi(e){if(Oa===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);Oa=t&&t[1]||""}return`
34
+ `+Oa+e}var Pa=!1;function Na(e,t){if(!e||Pa)return"";Pa=!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 i=u.stack.split(`
35
+ `),o=r.stack.split(`
36
+ `),s=i.length-1,l=o.length-1;1<=s&&0<=l&&i[s]!==o[l];)l--;for(;1<=s&&0<=l;s--,l--)if(i[s]!==o[l]){if(s!==1||l!==1)do if(s--,l--,0>l||i[s]!==o[l]){var a=`
37
+ `+i[s].replace(" at new "," at ");return e.displayName&&a.includes("<anonymous>")&&(a=a.replace("<anonymous>",e.displayName)),a}while(1<=s&&0<=l);break}}}finally{Pa=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?Yi(e):""}function lw(e){switch(e.tag){case 5:return Yi(e.type);case 16:return Yi("Lazy");case 13:return Yi("Suspense");case 19:return Yi("SuspenseList");case 0:case 2:case 15:return e=Na(e.type,!1),e;case 11:return e=Na(e.type.render,!1),e;case 1:return e=Na(e.type,!0),e;default:return""}}function Cu(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 zr:return"Fragment";case Fr:return"Portal";case Su:return"Profiler";case Kc:return"StrictMode";case Eu:return"Suspense";case Au:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case qp:return(e.displayName||"Context")+".Consumer";case Jp:return(e._context.displayName||"Context")+".Provider";case Gc:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Qc:return t=e.displayName||null,t!==null?t:Cu(e.type)||"Memo";case En:t=e._payload,e=e._init;try{return Cu(e(t))}catch{}}return null}function aw(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 Cu(t);case 8:return t===Kc?"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 Vn(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function tv(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function uw(e){var t=tv(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 i=n.get,o=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(s){r=""+s,o.call(this,s)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(s){r=""+s},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function ls(e){e._valueTracker||(e._valueTracker=uw(e))}function nv(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=tv(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function Js(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 ku(e,t){var n=t.checked;return pe({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function vd(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=Vn(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 rv(e,t){t=t.checked,t!=null&&Hc(e,"checked",t,!1)}function Ou(e,t){rv(e,t);var n=Vn(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")?Pu(e,t.type,n):t.hasOwnProperty("defaultValue")&&Pu(e,t.type,Vn(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function gd(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 Pu(e,t,n){(t!=="number"||Js(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var Xi=Array.isArray;function Jr(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t["$"+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty("$"+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=""+Vn(n),t=null,i=0;i<e.length;i++){if(e[i].value===n){e[i].selected=!0,r&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function Nu(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(N(91));return pe({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function md(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error(N(92));if(Xi(n)){if(1<n.length)throw Error(N(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:Vn(n)}}function iv(e,t){var n=Vn(t.value),r=Vn(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 yd(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function ov(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 ju(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?ov(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var as,sv=function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,n,r,i){MSApp.execUnsafeLocalFunction(function(){return e(t,n,r,i)})}:e}(function(e,t){if(e.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in e)e.innerHTML=t;else{for(as=as||document.createElement("div"),as.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=as.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function go(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var eo={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},cw=["Webkit","ms","Moz","O"];Object.keys(eo).forEach(function(e){cw.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),eo[t]=eo[e]})});function lv(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||eo.hasOwnProperty(e)&&eo[e]?(""+t).trim():t+"px"}function av(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,i=lv(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,i):e[n]=i}}var fw=pe({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 Tu(e,t){if(t){if(fw[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(N(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(N(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(N(61))}if(t.style!=null&&typeof t.style!="object")throw Error(N(62))}}function Ru(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 Du=null;function Yc(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Mu=null,qr=null,ei=null;function wd(e){if(e=$o(e)){if(typeof Mu!="function")throw Error(N(280));var t=e.stateNode;t&&(t=Ql(t),Mu(e.stateNode,e.type,t))}}function uv(e){qr?ei?ei.push(e):ei=[e]:qr=e}function cv(){if(qr){var e=qr,t=ei;if(ei=qr=null,wd(e),t)for(e=0;e<t.length;e++)wd(t[e])}}function fv(e,t){return e(t)}function dv(){}var ja=!1;function hv(e,t,n){if(ja)return e(t,n);ja=!0;try{return fv(e,t,n)}finally{ja=!1,(qr!==null||ei!==null)&&(dv(),cv())}}function mo(e,t){var n=e.stateNode;if(n===null)return null;var r=Ql(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(N(231,t,typeof n));return n}var Lu=!1;if(fn)try{var Fi={};Object.defineProperty(Fi,"passive",{get:function(){Lu=!0}}),window.addEventListener("test",Fi,Fi),window.removeEventListener("test",Fi,Fi)}catch{Lu=!1}function dw(e,t,n,r,i,o,s,l,a){var u=Array.prototype.slice.call(arguments,3);try{t.apply(n,u)}catch(c){this.onError(c)}}var to=!1,qs=null,el=!1,Iu=null,hw={onError:function(e){to=!0,qs=e}};function pw(e,t,n,r,i,o,s,l,a){to=!1,qs=null,dw.apply(hw,arguments)}function vw(e,t,n,r,i,o,s,l,a){if(pw.apply(this,arguments),to){if(to){var u=qs;to=!1,qs=null}else throw Error(N(198));el||(el=!0,Iu=u)}}function kr(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 pv(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 xd(e){if(kr(e)!==e)throw Error(N(188))}function gw(e){var t=e.alternate;if(!t){if(t=kr(e),t===null)throw Error(N(188));return t!==e?null:e}for(var n=e,r=t;;){var i=n.return;if(i===null)break;var o=i.alternate;if(o===null){if(r=i.return,r!==null){n=r;continue}break}if(i.child===o.child){for(o=i.child;o;){if(o===n)return xd(i),e;if(o===r)return xd(i),t;o=o.sibling}throw Error(N(188))}if(n.return!==r.return)n=i,r=o;else{for(var s=!1,l=i.child;l;){if(l===n){s=!0,n=i,r=o;break}if(l===r){s=!0,r=i,n=o;break}l=l.sibling}if(!s){for(l=o.child;l;){if(l===n){s=!0,n=o,r=i;break}if(l===r){s=!0,r=o,n=i;break}l=l.sibling}if(!s)throw Error(N(189))}}if(n.alternate!==r)throw Error(N(190))}if(n.tag!==3)throw Error(N(188));return n.stateNode.current===n?e:t}function vv(e){return e=gw(e),e!==null?gv(e):null}function gv(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=gv(e);if(t!==null)return t;e=e.sibling}return null}var mv=qe.unstable_scheduleCallback,_d=qe.unstable_cancelCallback,mw=qe.unstable_shouldYield,yw=qe.unstable_requestPaint,ge=qe.unstable_now,ww=qe.unstable_getCurrentPriorityLevel,Xc=qe.unstable_ImmediatePriority,yv=qe.unstable_UserBlockingPriority,tl=qe.unstable_NormalPriority,xw=qe.unstable_LowPriority,wv=qe.unstable_IdlePriority,Wl=null,Ut=null;function _w(e){if(Ut&&typeof Ut.onCommitFiberRoot=="function")try{Ut.onCommitFiberRoot(Wl,e,void 0,(e.current.flags&128)===128)}catch{}}var xt=Math.clz32?Math.clz32:Ew,bw=Math.log,Sw=Math.LN2;function Ew(e){return e>>>=0,e===0?32:31-(bw(e)/Sw|0)|0}var us=64,cs=4194304;function Zi(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 nl(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,i=e.suspendedLanes,o=e.pingedLanes,s=n&268435455;if(s!==0){var l=s&~i;l!==0?r=Zi(l):(o&=s,o!==0&&(r=Zi(o)))}else s=n&~i,s!==0?r=Zi(s):o!==0&&(r=Zi(o));if(r===0)return 0;if(t!==0&&t!==r&&!(t&i)&&(i=r&-r,o=t&-t,i>=o||i===16&&(o&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-xt(t),i=1<<n,r|=e[n],t&=~i;return r}function Aw(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 Cw(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,o=e.pendingLanes;0<o;){var s=31-xt(o),l=1<<s,a=i[s];a===-1?(!(l&n)||l&r)&&(i[s]=Aw(l,t)):a<=t&&(e.expiredLanes|=l),o&=~l}}function Fu(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function xv(){var e=us;return us<<=1,!(us&4194240)&&(us=64),e}function Ta(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Uo(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-xt(t),e[t]=n}function kw(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 i=31-xt(n),o=1<<i;t[i]=0,r[i]=-1,e[i]=-1,n&=~o}}function Zc(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-xt(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}var q=0;function _v(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var bv,Jc,Sv,Ev,Av,zu=!1,fs=[],Rn=null,Dn=null,Mn=null,yo=new Map,wo=new Map,kn=[],Ow="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 bd(e,t){switch(e){case"focusin":case"focusout":Rn=null;break;case"dragenter":case"dragleave":Dn=null;break;case"mouseover":case"mouseout":Mn=null;break;case"pointerover":case"pointerout":yo.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":wo.delete(t.pointerId)}}function zi(e,t,n,r,i,o){return e===null||e.nativeEvent!==o?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:o,targetContainers:[i]},t!==null&&(t=$o(t),t!==null&&Jc(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function Pw(e,t,n,r,i){switch(t){case"focusin":return Rn=zi(Rn,e,t,n,r,i),!0;case"dragenter":return Dn=zi(Dn,e,t,n,r,i),!0;case"mouseover":return Mn=zi(Mn,e,t,n,r,i),!0;case"pointerover":var o=i.pointerId;return yo.set(o,zi(yo.get(o)||null,e,t,n,r,i)),!0;case"gotpointercapture":return o=i.pointerId,wo.set(o,zi(wo.get(o)||null,e,t,n,r,i)),!0}return!1}function Cv(e){var t=ar(e.target);if(t!==null){var n=kr(t);if(n!==null){if(t=n.tag,t===13){if(t=pv(n),t!==null){e.blockedOn=t,Av(e.priority,function(){Sv(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 Ls(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=Uu(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);Du=r,n.target.dispatchEvent(r),Du=null}else return t=$o(n),t!==null&&Jc(t),e.blockedOn=n,!1;t.shift()}return!0}function Sd(e,t,n){Ls(e)&&n.delete(t)}function Nw(){zu=!1,Rn!==null&&Ls(Rn)&&(Rn=null),Dn!==null&&Ls(Dn)&&(Dn=null),Mn!==null&&Ls(Mn)&&(Mn=null),yo.forEach(Sd),wo.forEach(Sd)}function Ui(e,t){e.blockedOn===t&&(e.blockedOn=null,zu||(zu=!0,qe.unstable_scheduleCallback(qe.unstable_NormalPriority,Nw)))}function xo(e){function t(i){return Ui(i,e)}if(0<fs.length){Ui(fs[0],e);for(var n=1;n<fs.length;n++){var r=fs[n];r.blockedOn===e&&(r.blockedOn=null)}}for(Rn!==null&&Ui(Rn,e),Dn!==null&&Ui(Dn,e),Mn!==null&&Ui(Mn,e),yo.forEach(t),wo.forEach(t),n=0;n<kn.length;n++)r=kn[n],r.blockedOn===e&&(r.blockedOn=null);for(;0<kn.length&&(n=kn[0],n.blockedOn===null);)Cv(n),n.blockedOn===null&&kn.shift()}var ti=yn.ReactCurrentBatchConfig,rl=!0;function jw(e,t,n,r){var i=q,o=ti.transition;ti.transition=null;try{q=1,qc(e,t,n,r)}finally{q=i,ti.transition=o}}function Tw(e,t,n,r){var i=q,o=ti.transition;ti.transition=null;try{q=4,qc(e,t,n,r)}finally{q=i,ti.transition=o}}function qc(e,t,n,r){if(rl){var i=Uu(e,t,n,r);if(i===null)$a(e,t,r,il,n),bd(e,r);else if(Pw(i,e,t,n,r))r.stopPropagation();else if(bd(e,r),t&4&&-1<Ow.indexOf(e)){for(;i!==null;){var o=$o(i);if(o!==null&&bv(o),o=Uu(e,t,n,r),o===null&&$a(e,t,r,il,n),o===i)break;i=o}i!==null&&r.stopPropagation()}else $a(e,t,r,null,n)}}var il=null;function Uu(e,t,n,r){if(il=null,e=Yc(r),e=ar(e),e!==null)if(t=kr(e),t===null)e=null;else if(n=t.tag,n===13){if(e=pv(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 il=e,null}function kv(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(ww()){case Xc:return 1;case yv:return 4;case tl:case xw:return 16;case wv:return 536870912;default:return 16}default:return 16}}var Pn=null,ef=null,Is=null;function Ov(){if(Is)return Is;var e,t=ef,n=t.length,r,i="value"in Pn?Pn.value:Pn.textContent,o=i.length;for(e=0;e<n&&t[e]===i[e];e++);var s=n-e;for(r=1;r<=s&&t[n-r]===i[o-r];r++);return Is=i.slice(e,1<r?1-r:void 0)}function Fs(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 ds(){return!0}function Ed(){return!1}function tt(e){function t(n,r,i,o,s){this._reactName=n,this._targetInst=i,this.type=r,this.nativeEvent=o,this.target=s,this.currentTarget=null;for(var l in e)e.hasOwnProperty(l)&&(n=e[l],this[l]=n?n(o):o[l]);return this.isDefaultPrevented=(o.defaultPrevented!=null?o.defaultPrevented:o.returnValue===!1)?ds:Ed,this.isPropagationStopped=Ed,this}return pe(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=ds)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=ds)},persist:function(){},isPersistent:ds}),t}var Si={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},tf=tt(Si),Bo=pe({},Si,{view:0,detail:0}),Rw=tt(Bo),Ra,Da,Bi,Hl=pe({},Bo,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:nf,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!==Bi&&(Bi&&e.type==="mousemove"?(Ra=e.screenX-Bi.screenX,Da=e.screenY-Bi.screenY):Da=Ra=0,Bi=e),Ra)},movementY:function(e){return"movementY"in e?e.movementY:Da}}),Ad=tt(Hl),Dw=pe({},Hl,{dataTransfer:0}),Mw=tt(Dw),Lw=pe({},Bo,{relatedTarget:0}),Ma=tt(Lw),Iw=pe({},Si,{animationName:0,elapsedTime:0,pseudoElement:0}),Fw=tt(Iw),zw=pe({},Si,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),Uw=tt(zw),Bw=pe({},Si,{data:0}),Cd=tt(Bw),$w={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Vw={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"},Ww={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Hw(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Ww[e])?!!t[e]:!1}function nf(){return Hw}var Kw=pe({},Bo,{key:function(e){if(e.key){var t=$w[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Fs(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?Vw[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:nf,charCode:function(e){return e.type==="keypress"?Fs(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Fs(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),Gw=tt(Kw),Qw=pe({},Hl,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),kd=tt(Qw),Yw=pe({},Bo,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:nf}),Xw=tt(Yw),Zw=pe({},Si,{propertyName:0,elapsedTime:0,pseudoElement:0}),Jw=tt(Zw),qw=pe({},Hl,{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}),ex=tt(qw),tx=[9,13,27,32],rf=fn&&"CompositionEvent"in window,no=null;fn&&"documentMode"in document&&(no=document.documentMode);var nx=fn&&"TextEvent"in window&&!no,Pv=fn&&(!rf||no&&8<no&&11>=no),Od=" ",Pd=!1;function Nv(e,t){switch(e){case"keyup":return tx.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function jv(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Ur=!1;function rx(e,t){switch(e){case"compositionend":return jv(t);case"keypress":return t.which!==32?null:(Pd=!0,Od);case"textInput":return e=t.data,e===Od&&Pd?null:e;default:return null}}function ix(e,t){if(Ur)return e==="compositionend"||!rf&&Nv(e,t)?(e=Ov(),Is=ef=Pn=null,Ur=!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 Pv&&t.locale!=="ko"?null:t.data;default:return null}}var ox={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 Nd(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!ox[e.type]:t==="textarea"}function Tv(e,t,n,r){uv(r),t=ol(t,"onChange"),0<t.length&&(n=new tf("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var ro=null,_o=null;function sx(e){Vv(e,0)}function Kl(e){var t=Vr(e);if(nv(t))return e}function lx(e,t){if(e==="change")return t}var Rv=!1;if(fn){var La;if(fn){var Ia="oninput"in document;if(!Ia){var jd=document.createElement("div");jd.setAttribute("oninput","return;"),Ia=typeof jd.oninput=="function"}La=Ia}else La=!1;Rv=La&&(!document.documentMode||9<document.documentMode)}function Td(){ro&&(ro.detachEvent("onpropertychange",Dv),_o=ro=null)}function Dv(e){if(e.propertyName==="value"&&Kl(_o)){var t=[];Tv(t,_o,e,Yc(e)),hv(sx,t)}}function ax(e,t,n){e==="focusin"?(Td(),ro=t,_o=n,ro.attachEvent("onpropertychange",Dv)):e==="focusout"&&Td()}function ux(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Kl(_o)}function cx(e,t){if(e==="click")return Kl(t)}function fx(e,t){if(e==="input"||e==="change")return Kl(t)}function dx(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Et=typeof Object.is=="function"?Object.is:dx;function bo(e,t){if(Et(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 i=n[r];if(!bu.call(t,i)||!Et(e[i],t[i]))return!1}return!0}function Rd(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Dd(e,t){var n=Rd(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=Rd(n)}}function Mv(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Mv(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Lv(){for(var e=window,t=Js();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Js(e.document)}return t}function of(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 hx(e){var t=Lv(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&Mv(n.ownerDocument.documentElement,n)){if(r!==null&&of(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 i=n.textContent.length,o=Math.min(r.start,i);r=r.end===void 0?o:Math.min(r.end,i),!e.extend&&o>r&&(i=r,r=o,o=i),i=Dd(n,o);var s=Dd(n,r);i&&s&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==s.node||e.focusOffset!==s.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),o>r?(e.addRange(t),e.extend(s.node,s.offset)):(t.setEnd(s.node,s.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 px=fn&&"documentMode"in document&&11>=document.documentMode,Br=null,Bu=null,io=null,$u=!1;function Md(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;$u||Br==null||Br!==Js(r)||(r=Br,"selectionStart"in r&&of(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}),io&&bo(io,r)||(io=r,r=ol(Bu,"onSelect"),0<r.length&&(t=new tf("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=Br)))}function hs(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var $r={animationend:hs("Animation","AnimationEnd"),animationiteration:hs("Animation","AnimationIteration"),animationstart:hs("Animation","AnimationStart"),transitionend:hs("Transition","TransitionEnd")},Fa={},Iv={};fn&&(Iv=document.createElement("div").style,"AnimationEvent"in window||(delete $r.animationend.animation,delete $r.animationiteration.animation,delete $r.animationstart.animation),"TransitionEvent"in window||delete $r.transitionend.transition);function Gl(e){if(Fa[e])return Fa[e];if(!$r[e])return e;var t=$r[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Iv)return Fa[e]=t[n];return e}var Fv=Gl("animationend"),zv=Gl("animationiteration"),Uv=Gl("animationstart"),Bv=Gl("transitionend"),$v=new Map,Ld="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 Qn(e,t){$v.set(e,t),Cr(t,[e])}for(var za=0;za<Ld.length;za++){var Ua=Ld[za],vx=Ua.toLowerCase(),gx=Ua[0].toUpperCase()+Ua.slice(1);Qn(vx,"on"+gx)}Qn(Fv,"onAnimationEnd");Qn(zv,"onAnimationIteration");Qn(Uv,"onAnimationStart");Qn("dblclick","onDoubleClick");Qn("focusin","onFocus");Qn("focusout","onBlur");Qn(Bv,"onTransitionEnd");ui("onMouseEnter",["mouseout","mouseover"]);ui("onMouseLeave",["mouseout","mouseover"]);ui("onPointerEnter",["pointerout","pointerover"]);ui("onPointerLeave",["pointerout","pointerover"]);Cr("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));Cr("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));Cr("onBeforeInput",["compositionend","keypress","textInput","paste"]);Cr("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));Cr("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));Cr("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Ji="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(" "),mx=new Set("cancel close invalid load scroll toggle".split(" ").concat(Ji));function Id(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,vw(r,t,void 0,e),e.currentTarget=null}function Vv(e,t){t=(t&4)!==0;for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;e:{var o=void 0;if(t)for(var s=r.length-1;0<=s;s--){var l=r[s],a=l.instance,u=l.currentTarget;if(l=l.listener,a!==o&&i.isPropagationStopped())break e;Id(i,l,u),o=a}else for(s=0;s<r.length;s++){if(l=r[s],a=l.instance,u=l.currentTarget,l=l.listener,a!==o&&i.isPropagationStopped())break e;Id(i,l,u),o=a}}}if(el)throw e=Iu,el=!1,Iu=null,e}function se(e,t){var n=t[Gu];n===void 0&&(n=t[Gu]=new Set);var r=e+"__bubble";n.has(r)||(Wv(t,e,2,!1),n.add(r))}function Ba(e,t,n){var r=0;t&&(r|=4),Wv(n,e,r,t)}var ps="_reactListening"+Math.random().toString(36).slice(2);function So(e){if(!e[ps]){e[ps]=!0,Zp.forEach(function(n){n!=="selectionchange"&&(mx.has(n)||Ba(n,!1,e),Ba(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[ps]||(t[ps]=!0,Ba("selectionchange",!1,t))}}function Wv(e,t,n,r){switch(kv(t)){case 1:var i=jw;break;case 4:i=Tw;break;default:i=qc}n=i.bind(null,t,n,e),i=void 0,!Lu||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(i=!0),r?i!==void 0?e.addEventListener(t,n,{capture:!0,passive:i}):e.addEventListener(t,n,!0):i!==void 0?e.addEventListener(t,n,{passive:i}):e.addEventListener(t,n,!1)}function $a(e,t,n,r,i){var o=r;if(!(t&1)&&!(t&2)&&r!==null)e:for(;;){if(r===null)return;var s=r.tag;if(s===3||s===4){var l=r.stateNode.containerInfo;if(l===i||l.nodeType===8&&l.parentNode===i)break;if(s===4)for(s=r.return;s!==null;){var a=s.tag;if((a===3||a===4)&&(a=s.stateNode.containerInfo,a===i||a.nodeType===8&&a.parentNode===i))return;s=s.return}for(;l!==null;){if(s=ar(l),s===null)return;if(a=s.tag,a===5||a===6){r=o=s;continue e}l=l.parentNode}}r=r.return}hv(function(){var u=o,c=Yc(n),f=[];e:{var d=$v.get(e);if(d!==void 0){var p=tf,y=e;switch(e){case"keypress":if(Fs(n)===0)break e;case"keydown":case"keyup":p=Gw;break;case"focusin":y="focus",p=Ma;break;case"focusout":y="blur",p=Ma;break;case"beforeblur":case"afterblur":p=Ma;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":p=Ad;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":p=Mw;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":p=Xw;break;case Fv:case zv:case Uv:p=Fw;break;case Bv:p=Jw;break;case"scroll":p=Rw;break;case"wheel":p=ex;break;case"copy":case"cut":case"paste":p=Uw;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":p=kd}var m=(t&4)!==0,b=!m&&e==="scroll",v=m?d!==null?d+"Capture":null:d;m=[];for(var g=u,w;g!==null;){w=g;var _=w.stateNode;if(w.tag===5&&_!==null&&(w=_,v!==null&&(_=mo(g,v),_!=null&&m.push(Eo(g,_,w)))),b)break;g=g.return}0<m.length&&(d=new p(d,y,null,n,c),f.push({event:d,listeners:m}))}}if(!(t&7)){e:{if(d=e==="mouseover"||e==="pointerover",p=e==="mouseout"||e==="pointerout",d&&n!==Du&&(y=n.relatedTarget||n.fromElement)&&(ar(y)||y[dn]))break e;if((p||d)&&(d=c.window===c?c:(d=c.ownerDocument)?d.defaultView||d.parentWindow:window,p?(y=n.relatedTarget||n.toElement,p=u,y=y?ar(y):null,y!==null&&(b=kr(y),y!==b||y.tag!==5&&y.tag!==6)&&(y=null)):(p=null,y=u),p!==y)){if(m=Ad,_="onMouseLeave",v="onMouseEnter",g="mouse",(e==="pointerout"||e==="pointerover")&&(m=kd,_="onPointerLeave",v="onPointerEnter",g="pointer"),b=p==null?d:Vr(p),w=y==null?d:Vr(y),d=new m(_,g+"leave",p,n,c),d.target=b,d.relatedTarget=w,_=null,ar(c)===u&&(m=new m(v,g+"enter",y,n,c),m.target=w,m.relatedTarget=b,_=m),b=_,p&&y)t:{for(m=p,v=y,g=0,w=m;w;w=Tr(w))g++;for(w=0,_=v;_;_=Tr(_))w++;for(;0<g-w;)m=Tr(m),g--;for(;0<w-g;)v=Tr(v),w--;for(;g--;){if(m===v||v!==null&&m===v.alternate)break t;m=Tr(m),v=Tr(v)}m=null}else m=null;p!==null&&Fd(f,d,p,m,!1),y!==null&&b!==null&&Fd(f,b,y,m,!0)}}e:{if(d=u?Vr(u):window,p=d.nodeName&&d.nodeName.toLowerCase(),p==="select"||p==="input"&&d.type==="file")var S=lx;else if(Nd(d))if(Rv)S=fx;else{S=ux;var E=ax}else(p=d.nodeName)&&p.toLowerCase()==="input"&&(d.type==="checkbox"||d.type==="radio")&&(S=cx);if(S&&(S=S(e,u))){Tv(f,S,n,c);break e}E&&E(e,d,u),e==="focusout"&&(E=d._wrapperState)&&E.controlled&&d.type==="number"&&Pu(d,"number",d.value)}switch(E=u?Vr(u):window,e){case"focusin":(Nd(E)||E.contentEditable==="true")&&(Br=E,Bu=u,io=null);break;case"focusout":io=Bu=Br=null;break;case"mousedown":$u=!0;break;case"contextmenu":case"mouseup":case"dragend":$u=!1,Md(f,n,c);break;case"selectionchange":if(px)break;case"keydown":case"keyup":Md(f,n,c)}var A;if(rf)e:{switch(e){case"compositionstart":var C="onCompositionStart";break e;case"compositionend":C="onCompositionEnd";break e;case"compositionupdate":C="onCompositionUpdate";break e}C=void 0}else Ur?Nv(e,n)&&(C="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(C="onCompositionStart");C&&(Pv&&n.locale!=="ko"&&(Ur||C!=="onCompositionStart"?C==="onCompositionEnd"&&Ur&&(A=Ov()):(Pn=c,ef="value"in Pn?Pn.value:Pn.textContent,Ur=!0)),E=ol(u,C),0<E.length&&(C=new Cd(C,e,null,n,c),f.push({event:C,listeners:E}),A?C.data=A:(A=jv(n),A!==null&&(C.data=A)))),(A=nx?rx(e,n):ix(e,n))&&(u=ol(u,"onBeforeInput"),0<u.length&&(c=new Cd("onBeforeInput","beforeinput",null,n,c),f.push({event:c,listeners:u}),c.data=A))}Vv(f,t)})}function Eo(e,t,n){return{instance:e,listener:t,currentTarget:n}}function ol(e,t){for(var n=t+"Capture",r=[];e!==null;){var i=e,o=i.stateNode;i.tag===5&&o!==null&&(i=o,o=mo(e,n),o!=null&&r.unshift(Eo(e,o,i)),o=mo(e,t),o!=null&&r.push(Eo(e,o,i))),e=e.return}return r}function Tr(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function Fd(e,t,n,r,i){for(var o=t._reactName,s=[];n!==null&&n!==r;){var l=n,a=l.alternate,u=l.stateNode;if(a!==null&&a===r)break;l.tag===5&&u!==null&&(l=u,i?(a=mo(n,o),a!=null&&s.unshift(Eo(n,a,l))):i||(a=mo(n,o),a!=null&&s.push(Eo(n,a,l)))),n=n.return}s.length!==0&&e.push({event:t,listeners:s})}var yx=/\r\n?/g,wx=/\u0000|\uFFFD/g;function zd(e){return(typeof e=="string"?e:""+e).replace(yx,`
38
+ `).replace(wx,"")}function vs(e,t,n){if(t=zd(t),zd(e)!==t&&n)throw Error(N(425))}function sl(){}var Vu=null,Wu=null;function Hu(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 Ku=typeof setTimeout=="function"?setTimeout:void 0,xx=typeof clearTimeout=="function"?clearTimeout:void 0,Ud=typeof Promise=="function"?Promise:void 0,_x=typeof queueMicrotask=="function"?queueMicrotask:typeof Ud<"u"?function(e){return Ud.resolve(null).then(e).catch(bx)}:Ku;function bx(e){setTimeout(function(){throw e})}function Va(e,t){var n=t,r=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8)if(n=i.data,n==="/$"){if(r===0){e.removeChild(i),xo(t);return}r--}else n!=="$"&&n!=="$?"&&n!=="$!"||r++;n=i}while(n);xo(t)}function Ln(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 Bd(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 Ei=Math.random().toString(36).slice(2),Lt="__reactFiber$"+Ei,Ao="__reactProps$"+Ei,dn="__reactContainer$"+Ei,Gu="__reactEvents$"+Ei,Sx="__reactListeners$"+Ei,Ex="__reactHandles$"+Ei;function ar(e){var t=e[Lt];if(t)return t;for(var n=e.parentNode;n;){if(t=n[dn]||n[Lt]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=Bd(e);e!==null;){if(n=e[Lt])return n;e=Bd(e)}return t}e=n,n=e.parentNode}return null}function $o(e){return e=e[Lt]||e[dn],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function Vr(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(N(33))}function Ql(e){return e[Ao]||null}var Qu=[],Wr=-1;function Yn(e){return{current:e}}function le(e){0>Wr||(e.current=Qu[Wr],Qu[Wr]=null,Wr--)}function re(e,t){Wr++,Qu[Wr]=e.current,e.current=t}var Wn={},Re=Yn(Wn),Ve=Yn(!1),vr=Wn;function ci(e,t){var n=e.type.contextTypes;if(!n)return Wn;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var i={},o;for(o in n)i[o]=t[o];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function We(e){return e=e.childContextTypes,e!=null}function ll(){le(Ve),le(Re)}function $d(e,t,n){if(Re.current!==Wn)throw Error(N(168));re(Re,t),re(Ve,n)}function Hv(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var i in r)if(!(i in t))throw Error(N(108,aw(e)||"Unknown",i));return pe({},n,r)}function al(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Wn,vr=Re.current,re(Re,e),re(Ve,Ve.current),!0}function Vd(e,t,n){var r=e.stateNode;if(!r)throw Error(N(169));n?(e=Hv(e,t,vr),r.__reactInternalMemoizedMergedChildContext=e,le(Ve),le(Re),re(Re,e)):le(Ve),re(Ve,n)}var en=null,Yl=!1,Wa=!1;function Kv(e){en===null?en=[e]:en.push(e)}function Ax(e){Yl=!0,Kv(e)}function Xn(){if(!Wa&&en!==null){Wa=!0;var e=0,t=q;try{var n=en;for(q=1;e<n.length;e++){var r=n[e];do r=r(!0);while(r!==null)}en=null,Yl=!1}catch(i){throw en!==null&&(en=en.slice(e+1)),mv(Xc,Xn),i}finally{q=t,Wa=!1}}return null}var Hr=[],Kr=0,ul=null,cl=0,it=[],ot=0,gr=null,rn=1,on="";function or(e,t){Hr[Kr++]=cl,Hr[Kr++]=ul,ul=e,cl=t}function Gv(e,t,n){it[ot++]=rn,it[ot++]=on,it[ot++]=gr,gr=e;var r=rn;e=on;var i=32-xt(r)-1;r&=~(1<<i),n+=1;var o=32-xt(t)+i;if(30<o){var s=i-i%5;o=(r&(1<<s)-1).toString(32),r>>=s,i-=s,rn=1<<32-xt(t)+i|n<<i|r,on=o+e}else rn=1<<o|n<<i|r,on=e}function sf(e){e.return!==null&&(or(e,1),Gv(e,1,0))}function lf(e){for(;e===ul;)ul=Hr[--Kr],Hr[Kr]=null,cl=Hr[--Kr],Hr[Kr]=null;for(;e===gr;)gr=it[--ot],it[ot]=null,on=it[--ot],it[ot]=null,rn=it[--ot],it[ot]=null}var Ze=null,Xe=null,ue=!1,yt=null;function Qv(e,t){var n=at(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 Wd(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,Ze=e,Xe=Ln(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,Ze=e,Xe=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(n=gr!==null?{id:rn,overflow:on}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},n=at(18,null,null,0),n.stateNode=t,n.return=e,e.child=n,Ze=e,Xe=null,!0):!1;default:return!1}}function Yu(e){return(e.mode&1)!==0&&(e.flags&128)===0}function Xu(e){if(ue){var t=Xe;if(t){var n=t;if(!Wd(e,t)){if(Yu(e))throw Error(N(418));t=Ln(n.nextSibling);var r=Ze;t&&Wd(e,t)?Qv(r,n):(e.flags=e.flags&-4097|2,ue=!1,Ze=e)}}else{if(Yu(e))throw Error(N(418));e.flags=e.flags&-4097|2,ue=!1,Ze=e}}}function Hd(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;Ze=e}function gs(e){if(e!==Ze)return!1;if(!ue)return Hd(e),ue=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!Hu(e.type,e.memoizedProps)),t&&(t=Xe)){if(Yu(e))throw Yv(),Error(N(418));for(;t;)Qv(e,t),t=Ln(t.nextSibling)}if(Hd(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(N(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){Xe=Ln(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}Xe=null}}else Xe=Ze?Ln(e.stateNode.nextSibling):null;return!0}function Yv(){for(var e=Xe;e;)e=Ln(e.nextSibling)}function fi(){Xe=Ze=null,ue=!1}function af(e){yt===null?yt=[e]:yt.push(e)}var Cx=yn.ReactCurrentBatchConfig;function $i(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(N(309));var r=n.stateNode}if(!r)throw Error(N(147,e));var i=r,o=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===o?t.ref:(t=function(s){var l=i.refs;s===null?delete l[o]:l[o]=s},t._stringRef=o,t)}if(typeof e!="string")throw Error(N(284));if(!n._owner)throw Error(N(290,e))}return e}function ms(e,t){throw e=Object.prototype.toString.call(t),Error(N(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function Kd(e){var t=e._init;return t(e._payload)}function Xv(e){function t(v,g){if(e){var w=v.deletions;w===null?(v.deletions=[g],v.flags|=16):w.push(g)}}function n(v,g){if(!e)return null;for(;g!==null;)t(v,g),g=g.sibling;return null}function r(v,g){for(v=new Map;g!==null;)g.key!==null?v.set(g.key,g):v.set(g.index,g),g=g.sibling;return v}function i(v,g){return v=Un(v,g),v.index=0,v.sibling=null,v}function o(v,g,w){return v.index=w,e?(w=v.alternate,w!==null?(w=w.index,w<g?(v.flags|=2,g):w):(v.flags|=2,g)):(v.flags|=1048576,g)}function s(v){return e&&v.alternate===null&&(v.flags|=2),v}function l(v,g,w,_){return g===null||g.tag!==6?(g=Za(w,v.mode,_),g.return=v,g):(g=i(g,w),g.return=v,g)}function a(v,g,w,_){var S=w.type;return S===zr?c(v,g,w.props.children,_,w.key):g!==null&&(g.elementType===S||typeof S=="object"&&S!==null&&S.$$typeof===En&&Kd(S)===g.type)?(_=i(g,w.props),_.ref=$i(v,g,w),_.return=v,_):(_=Hs(w.type,w.key,w.props,null,v.mode,_),_.ref=$i(v,g,w),_.return=v,_)}function u(v,g,w,_){return g===null||g.tag!==4||g.stateNode.containerInfo!==w.containerInfo||g.stateNode.implementation!==w.implementation?(g=Ja(w,v.mode,_),g.return=v,g):(g=i(g,w.children||[]),g.return=v,g)}function c(v,g,w,_,S){return g===null||g.tag!==7?(g=pr(w,v.mode,_,S),g.return=v,g):(g=i(g,w),g.return=v,g)}function f(v,g,w){if(typeof g=="string"&&g!==""||typeof g=="number")return g=Za(""+g,v.mode,w),g.return=v,g;if(typeof g=="object"&&g!==null){switch(g.$$typeof){case ss:return w=Hs(g.type,g.key,g.props,null,v.mode,w),w.ref=$i(v,null,g),w.return=v,w;case Fr:return g=Ja(g,v.mode,w),g.return=v,g;case En:var _=g._init;return f(v,_(g._payload),w)}if(Xi(g)||Ii(g))return g=pr(g,v.mode,w,null),g.return=v,g;ms(v,g)}return null}function d(v,g,w,_){var S=g!==null?g.key:null;if(typeof w=="string"&&w!==""||typeof w=="number")return S!==null?null:l(v,g,""+w,_);if(typeof w=="object"&&w!==null){switch(w.$$typeof){case ss:return w.key===S?a(v,g,w,_):null;case Fr:return w.key===S?u(v,g,w,_):null;case En:return S=w._init,d(v,g,S(w._payload),_)}if(Xi(w)||Ii(w))return S!==null?null:c(v,g,w,_,null);ms(v,w)}return null}function p(v,g,w,_,S){if(typeof _=="string"&&_!==""||typeof _=="number")return v=v.get(w)||null,l(g,v,""+_,S);if(typeof _=="object"&&_!==null){switch(_.$$typeof){case ss:return v=v.get(_.key===null?w:_.key)||null,a(g,v,_,S);case Fr:return v=v.get(_.key===null?w:_.key)||null,u(g,v,_,S);case En:var E=_._init;return p(v,g,w,E(_._payload),S)}if(Xi(_)||Ii(_))return v=v.get(w)||null,c(g,v,_,S,null);ms(g,_)}return null}function y(v,g,w,_){for(var S=null,E=null,A=g,C=g=0,j=null;A!==null&&C<w.length;C++){A.index>C?(j=A,A=null):j=A.sibling;var P=d(v,A,w[C],_);if(P===null){A===null&&(A=j);break}e&&A&&P.alternate===null&&t(v,A),g=o(P,g,C),E===null?S=P:E.sibling=P,E=P,A=j}if(C===w.length)return n(v,A),ue&&or(v,C),S;if(A===null){for(;C<w.length;C++)A=f(v,w[C],_),A!==null&&(g=o(A,g,C),E===null?S=A:E.sibling=A,E=A);return ue&&or(v,C),S}for(A=r(v,A);C<w.length;C++)j=p(A,v,C,w[C],_),j!==null&&(e&&j.alternate!==null&&A.delete(j.key===null?C:j.key),g=o(j,g,C),E===null?S=j:E.sibling=j,E=j);return e&&A.forEach(function(D){return t(v,D)}),ue&&or(v,C),S}function m(v,g,w,_){var S=Ii(w);if(typeof S!="function")throw Error(N(150));if(w=S.call(w),w==null)throw Error(N(151));for(var E=S=null,A=g,C=g=0,j=null,P=w.next();A!==null&&!P.done;C++,P=w.next()){A.index>C?(j=A,A=null):j=A.sibling;var D=d(v,A,P.value,_);if(D===null){A===null&&(A=j);break}e&&A&&D.alternate===null&&t(v,A),g=o(D,g,C),E===null?S=D:E.sibling=D,E=D,A=j}if(P.done)return n(v,A),ue&&or(v,C),S;if(A===null){for(;!P.done;C++,P=w.next())P=f(v,P.value,_),P!==null&&(g=o(P,g,C),E===null?S=P:E.sibling=P,E=P);return ue&&or(v,C),S}for(A=r(v,A);!P.done;C++,P=w.next())P=p(A,v,C,P.value,_),P!==null&&(e&&P.alternate!==null&&A.delete(P.key===null?C:P.key),g=o(P,g,C),E===null?S=P:E.sibling=P,E=P);return e&&A.forEach(function(k){return t(v,k)}),ue&&or(v,C),S}function b(v,g,w,_){if(typeof w=="object"&&w!==null&&w.type===zr&&w.key===null&&(w=w.props.children),typeof w=="object"&&w!==null){switch(w.$$typeof){case ss:e:{for(var S=w.key,E=g;E!==null;){if(E.key===S){if(S=w.type,S===zr){if(E.tag===7){n(v,E.sibling),g=i(E,w.props.children),g.return=v,v=g;break e}}else if(E.elementType===S||typeof S=="object"&&S!==null&&S.$$typeof===En&&Kd(S)===E.type){n(v,E.sibling),g=i(E,w.props),g.ref=$i(v,E,w),g.return=v,v=g;break e}n(v,E);break}else t(v,E);E=E.sibling}w.type===zr?(g=pr(w.props.children,v.mode,_,w.key),g.return=v,v=g):(_=Hs(w.type,w.key,w.props,null,v.mode,_),_.ref=$i(v,g,w),_.return=v,v=_)}return s(v);case Fr:e:{for(E=w.key;g!==null;){if(g.key===E)if(g.tag===4&&g.stateNode.containerInfo===w.containerInfo&&g.stateNode.implementation===w.implementation){n(v,g.sibling),g=i(g,w.children||[]),g.return=v,v=g;break e}else{n(v,g);break}else t(v,g);g=g.sibling}g=Ja(w,v.mode,_),g.return=v,v=g}return s(v);case En:return E=w._init,b(v,g,E(w._payload),_)}if(Xi(w))return y(v,g,w,_);if(Ii(w))return m(v,g,w,_);ms(v,w)}return typeof w=="string"&&w!==""||typeof w=="number"?(w=""+w,g!==null&&g.tag===6?(n(v,g.sibling),g=i(g,w),g.return=v,v=g):(n(v,g),g=Za(w,v.mode,_),g.return=v,v=g),s(v)):n(v,g)}return b}var di=Xv(!0),Zv=Xv(!1),fl=Yn(null),dl=null,Gr=null,uf=null;function cf(){uf=Gr=dl=null}function ff(e){var t=fl.current;le(fl),e._currentValue=t}function Zu(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 ni(e,t){dl=e,uf=Gr=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&($e=!0),e.firstContext=null)}function dt(e){var t=e._currentValue;if(uf!==e)if(e={context:e,memoizedValue:t,next:null},Gr===null){if(dl===null)throw Error(N(308));Gr=e,dl.dependencies={lanes:0,firstContext:e}}else Gr=Gr.next=e;return t}var ur=null;function df(e){ur===null?ur=[e]:ur.push(e)}function Jv(e,t,n,r){var i=t.interleaved;return i===null?(n.next=n,df(t)):(n.next=i.next,i.next=n),t.interleaved=n,hn(e,r)}function hn(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 An=!1;function hf(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function qv(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 sn(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function In(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,Y&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,hn(e,n)}return i=r.interleaved,i===null?(t.next=t,df(r)):(t.next=i.next,i.next=t),r.interleaved=t,hn(e,n)}function zs(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,Zc(e,n)}}function Gd(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,o=null;if(n=n.firstBaseUpdate,n!==null){do{var s={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};o===null?i=o=s:o=o.next=s,n=n.next}while(n!==null);o===null?i=o=t:o=o.next=t}else i=o=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:o,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 hl(e,t,n,r){var i=e.updateQueue;An=!1;var o=i.firstBaseUpdate,s=i.lastBaseUpdate,l=i.shared.pending;if(l!==null){i.shared.pending=null;var a=l,u=a.next;a.next=null,s===null?o=u:s.next=u,s=a;var c=e.alternate;c!==null&&(c=c.updateQueue,l=c.lastBaseUpdate,l!==s&&(l===null?c.firstBaseUpdate=u:l.next=u,c.lastBaseUpdate=a))}if(o!==null){var f=i.baseState;s=0,c=u=a=null,l=o;do{var d=l.lane,p=l.eventTime;if((r&d)===d){c!==null&&(c=c.next={eventTime:p,lane:0,tag:l.tag,payload:l.payload,callback:l.callback,next:null});e:{var y=e,m=l;switch(d=t,p=n,m.tag){case 1:if(y=m.payload,typeof y=="function"){f=y.call(p,f,d);break e}f=y;break e;case 3:y.flags=y.flags&-65537|128;case 0:if(y=m.payload,d=typeof y=="function"?y.call(p,f,d):y,d==null)break e;f=pe({},f,d);break e;case 2:An=!0}}l.callback!==null&&l.lane!==0&&(e.flags|=64,d=i.effects,d===null?i.effects=[l]:d.push(l))}else p={eventTime:p,lane:d,tag:l.tag,payload:l.payload,callback:l.callback,next:null},c===null?(u=c=p,a=f):c=c.next=p,s|=d;if(l=l.next,l===null){if(l=i.shared.pending,l===null)break;d=l,l=d.next,d.next=null,i.lastBaseUpdate=d,i.shared.pending=null}}while(!0);if(c===null&&(a=f),i.baseState=a,i.firstBaseUpdate=u,i.lastBaseUpdate=c,t=i.shared.interleaved,t!==null){i=t;do s|=i.lane,i=i.next;while(i!==t)}else o===null&&(i.shared.lanes=0);yr|=s,e.lanes=s,e.memoizedState=f}}function Qd(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var r=e[t],i=r.callback;if(i!==null){if(r.callback=null,r=n,typeof i!="function")throw Error(N(191,i));i.call(r)}}}var Vo={},Bt=Yn(Vo),Co=Yn(Vo),ko=Yn(Vo);function cr(e){if(e===Vo)throw Error(N(174));return e}function pf(e,t){switch(re(ko,t),re(Co,e),re(Bt,Vo),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:ju(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=ju(t,e)}le(Bt),re(Bt,t)}function hi(){le(Bt),le(Co),le(ko)}function eg(e){cr(ko.current);var t=cr(Bt.current),n=ju(t,e.type);t!==n&&(re(Co,e),re(Bt,n))}function vf(e){Co.current===e&&(le(Bt),le(Co))}var de=Yn(0);function pl(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 Ha=[];function gf(){for(var e=0;e<Ha.length;e++)Ha[e]._workInProgressVersionPrimary=null;Ha.length=0}var Us=yn.ReactCurrentDispatcher,Ka=yn.ReactCurrentBatchConfig,mr=0,he=null,we=null,_e=null,vl=!1,oo=!1,Oo=0,kx=0;function Ne(){throw Error(N(321))}function mf(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Et(e[n],t[n]))return!1;return!0}function yf(e,t,n,r,i,o){if(mr=o,he=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,Us.current=e===null||e.memoizedState===null?jx:Tx,e=n(r,i),oo){o=0;do{if(oo=!1,Oo=0,25<=o)throw Error(N(301));o+=1,_e=we=null,t.updateQueue=null,Us.current=Rx,e=n(r,i)}while(oo)}if(Us.current=gl,t=we!==null&&we.next!==null,mr=0,_e=we=he=null,vl=!1,t)throw Error(N(300));return e}function wf(){var e=Oo!==0;return Oo=0,e}function Mt(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return _e===null?he.memoizedState=_e=e:_e=_e.next=e,_e}function ht(){if(we===null){var e=he.alternate;e=e!==null?e.memoizedState:null}else e=we.next;var t=_e===null?he.memoizedState:_e.next;if(t!==null)_e=t,we=e;else{if(e===null)throw Error(N(310));we=e,e={memoizedState:we.memoizedState,baseState:we.baseState,baseQueue:we.baseQueue,queue:we.queue,next:null},_e===null?he.memoizedState=_e=e:_e=_e.next=e}return _e}function Po(e,t){return typeof t=="function"?t(e):t}function Ga(e){var t=ht(),n=t.queue;if(n===null)throw Error(N(311));n.lastRenderedReducer=e;var r=we,i=r.baseQueue,o=n.pending;if(o!==null){if(i!==null){var s=i.next;i.next=o.next,o.next=s}r.baseQueue=i=o,n.pending=null}if(i!==null){o=i.next,r=r.baseState;var l=s=null,a=null,u=o;do{var c=u.lane;if((mr&c)===c)a!==null&&(a=a.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 f={lane:c,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null};a===null?(l=a=f,s=r):a=a.next=f,he.lanes|=c,yr|=c}u=u.next}while(u!==null&&u!==o);a===null?s=r:a.next=l,Et(r,t.memoizedState)||($e=!0),t.memoizedState=r,t.baseState=s,t.baseQueue=a,n.lastRenderedState=r}if(e=n.interleaved,e!==null){i=e;do o=i.lane,he.lanes|=o,yr|=o,i=i.next;while(i!==e)}else i===null&&(n.lanes=0);return[t.memoizedState,n.dispatch]}function Qa(e){var t=ht(),n=t.queue;if(n===null)throw Error(N(311));n.lastRenderedReducer=e;var r=n.dispatch,i=n.pending,o=t.memoizedState;if(i!==null){n.pending=null;var s=i=i.next;do o=e(o,s.action),s=s.next;while(s!==i);Et(o,t.memoizedState)||($e=!0),t.memoizedState=o,t.baseQueue===null&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function tg(){}function ng(e,t){var n=he,r=ht(),i=t(),o=!Et(r.memoizedState,i);if(o&&(r.memoizedState=i,$e=!0),r=r.queue,xf(og.bind(null,n,r,e),[e]),r.getSnapshot!==t||o||_e!==null&&_e.memoizedState.tag&1){if(n.flags|=2048,No(9,ig.bind(null,n,r,i,t),void 0,null),be===null)throw Error(N(349));mr&30||rg(n,t,i)}return i}function rg(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=he.updateQueue,t===null?(t={lastEffect:null,stores:null},he.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function ig(e,t,n,r){t.value=n,t.getSnapshot=r,sg(t)&&lg(e)}function og(e,t,n){return n(function(){sg(t)&&lg(e)})}function sg(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Et(e,n)}catch{return!0}}function lg(e){var t=hn(e,1);t!==null&&_t(t,e,1,-1)}function Yd(e){var t=Mt();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:Po,lastRenderedState:e},t.queue=e,e=e.dispatch=Nx.bind(null,he,e),[t.memoizedState,e]}function No(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},t=he.updateQueue,t===null?(t={lastEffect:null,stores:null},he.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 ag(){return ht().memoizedState}function Bs(e,t,n,r){var i=Mt();he.flags|=e,i.memoizedState=No(1|t,n,void 0,r===void 0?null:r)}function Xl(e,t,n,r){var i=ht();r=r===void 0?null:r;var o=void 0;if(we!==null){var s=we.memoizedState;if(o=s.destroy,r!==null&&mf(r,s.deps)){i.memoizedState=No(t,n,o,r);return}}he.flags|=e,i.memoizedState=No(1|t,n,o,r)}function Xd(e,t){return Bs(8390656,8,e,t)}function xf(e,t){return Xl(2048,8,e,t)}function ug(e,t){return Xl(4,2,e,t)}function cg(e,t){return Xl(4,4,e,t)}function fg(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 dg(e,t,n){return n=n!=null?n.concat([e]):null,Xl(4,4,fg.bind(null,t,e),n)}function _f(){}function hg(e,t){var n=ht();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&mf(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function pg(e,t){var n=ht();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&mf(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function vg(e,t,n){return mr&21?(Et(n,t)||(n=xv(),he.lanes|=n,yr|=n,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,$e=!0),e.memoizedState=n)}function Ox(e,t){var n=q;q=n!==0&&4>n?n:4,e(!0);var r=Ka.transition;Ka.transition={};try{e(!1),t()}finally{q=n,Ka.transition=r}}function gg(){return ht().memoizedState}function Px(e,t,n){var r=zn(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},mg(e))yg(t,n);else if(n=Jv(e,t,n,r),n!==null){var i=Me();_t(n,e,r,i),wg(n,t,r)}}function Nx(e,t,n){var r=zn(e),i={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(mg(e))yg(t,i);else{var o=e.alternate;if(e.lanes===0&&(o===null||o.lanes===0)&&(o=t.lastRenderedReducer,o!==null))try{var s=t.lastRenderedState,l=o(s,n);if(i.hasEagerState=!0,i.eagerState=l,Et(l,s)){var a=t.interleaved;a===null?(i.next=i,df(t)):(i.next=a.next,a.next=i),t.interleaved=i;return}}catch{}finally{}n=Jv(e,t,i,r),n!==null&&(i=Me(),_t(n,e,r,i),wg(n,t,r))}}function mg(e){var t=e.alternate;return e===he||t!==null&&t===he}function yg(e,t){oo=vl=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function wg(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Zc(e,n)}}var gl={readContext:dt,useCallback:Ne,useContext:Ne,useEffect:Ne,useImperativeHandle:Ne,useInsertionEffect:Ne,useLayoutEffect:Ne,useMemo:Ne,useReducer:Ne,useRef:Ne,useState:Ne,useDebugValue:Ne,useDeferredValue:Ne,useTransition:Ne,useMutableSource:Ne,useSyncExternalStore:Ne,useId:Ne,unstable_isNewReconciler:!1},jx={readContext:dt,useCallback:function(e,t){return Mt().memoizedState=[e,t===void 0?null:t],e},useContext:dt,useEffect:Xd,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Bs(4194308,4,fg.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Bs(4194308,4,e,t)},useInsertionEffect:function(e,t){return Bs(4,2,e,t)},useMemo:function(e,t){var n=Mt();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=Mt();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=Px.bind(null,he,e),[r.memoizedState,e]},useRef:function(e){var t=Mt();return e={current:e},t.memoizedState=e},useState:Yd,useDebugValue:_f,useDeferredValue:function(e){return Mt().memoizedState=e},useTransition:function(){var e=Yd(!1),t=e[0];return e=Ox.bind(null,e[1]),Mt().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=he,i=Mt();if(ue){if(n===void 0)throw Error(N(407));n=n()}else{if(n=t(),be===null)throw Error(N(349));mr&30||rg(r,t,n)}i.memoizedState=n;var o={value:n,getSnapshot:t};return i.queue=o,Xd(og.bind(null,r,o,e),[e]),r.flags|=2048,No(9,ig.bind(null,r,o,n,t),void 0,null),n},useId:function(){var e=Mt(),t=be.identifierPrefix;if(ue){var n=on,r=rn;n=(r&~(1<<32-xt(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=Oo++,0<n&&(t+="H"+n.toString(32)),t+=":"}else n=kx++,t=":"+t+"r"+n.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},Tx={readContext:dt,useCallback:hg,useContext:dt,useEffect:xf,useImperativeHandle:dg,useInsertionEffect:ug,useLayoutEffect:cg,useMemo:pg,useReducer:Ga,useRef:ag,useState:function(){return Ga(Po)},useDebugValue:_f,useDeferredValue:function(e){var t=ht();return vg(t,we.memoizedState,e)},useTransition:function(){var e=Ga(Po)[0],t=ht().memoizedState;return[e,t]},useMutableSource:tg,useSyncExternalStore:ng,useId:gg,unstable_isNewReconciler:!1},Rx={readContext:dt,useCallback:hg,useContext:dt,useEffect:xf,useImperativeHandle:dg,useInsertionEffect:ug,useLayoutEffect:cg,useMemo:pg,useReducer:Qa,useRef:ag,useState:function(){return Qa(Po)},useDebugValue:_f,useDeferredValue:function(e){var t=ht();return we===null?t.memoizedState=e:vg(t,we.memoizedState,e)},useTransition:function(){var e=Qa(Po)[0],t=ht().memoizedState;return[e,t]},useMutableSource:tg,useSyncExternalStore:ng,useId:gg,unstable_isNewReconciler:!1};function gt(e,t){if(e&&e.defaultProps){t=pe({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}function Ju(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:pe({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Zl={isMounted:function(e){return(e=e._reactInternals)?kr(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=Me(),i=zn(e),o=sn(r,i);o.payload=t,n!=null&&(o.callback=n),t=In(e,o,i),t!==null&&(_t(t,e,i,r),zs(t,e,i))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=Me(),i=zn(e),o=sn(r,i);o.tag=1,o.payload=t,n!=null&&(o.callback=n),t=In(e,o,i),t!==null&&(_t(t,e,i,r),zs(t,e,i))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=Me(),r=zn(e),i=sn(n,r);i.tag=2,t!=null&&(i.callback=t),t=In(e,i,r),t!==null&&(_t(t,e,r,n),zs(t,e,r))}};function Zd(e,t,n,r,i,o,s){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(r,o,s):t.prototype&&t.prototype.isPureReactComponent?!bo(n,r)||!bo(i,o):!0}function xg(e,t,n){var r=!1,i=Wn,o=t.contextType;return typeof o=="object"&&o!==null?o=dt(o):(i=We(t)?vr:Re.current,r=t.contextTypes,o=(r=r!=null)?ci(e,i):Wn),t=new t(n,o),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=Zl,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=i,e.__reactInternalMemoizedMaskedChildContext=o),t}function Jd(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&&Zl.enqueueReplaceState(t,t.state,null)}function qu(e,t,n,r){var i=e.stateNode;i.props=n,i.state=e.memoizedState,i.refs={},hf(e);var o=t.contextType;typeof o=="object"&&o!==null?i.context=dt(o):(o=We(t)?vr:Re.current,i.context=ci(e,o)),i.state=e.memoizedState,o=t.getDerivedStateFromProps,typeof o=="function"&&(Ju(e,t,o,n),i.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof i.getSnapshotBeforeUpdate=="function"||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(t=i.state,typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount(),t!==i.state&&Zl.enqueueReplaceState(i,i.state,null),hl(e,n,i,r),i.state=e.memoizedState),typeof i.componentDidMount=="function"&&(e.flags|=4194308)}function pi(e,t){try{var n="",r=t;do n+=lw(r),r=r.return;while(r);var i=n}catch(o){i=`
39
+ Error generating stack: `+o.message+`
40
+ `+o.stack}return{value:e,source:t,stack:i,digest:null}}function Ya(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function ec(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var Dx=typeof WeakMap=="function"?WeakMap:Map;function _g(e,t,n){n=sn(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){yl||(yl=!0,cc=r),ec(e,t)},n}function bg(e,t,n){n=sn(-1,n),n.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var i=t.value;n.payload=function(){return r(i)},n.callback=function(){ec(e,t)}}var o=e.stateNode;return o!==null&&typeof o.componentDidCatch=="function"&&(n.callback=function(){ec(e,t),typeof r!="function"&&(Fn===null?Fn=new Set([this]):Fn.add(this));var s=t.stack;this.componentDidCatch(t.value,{componentStack:s!==null?s:""})}),n}function qd(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Dx;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(i.add(n),e=Qx.bind(null,e,t,n),t.then(e,e))}function eh(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 th(e,t,n,r,i){return e.mode&1?(e.flags|=65536,e.lanes=i,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=sn(-1,1),t.tag=2,In(n,t,1))),n.lanes|=1),e)}var Mx=yn.ReactCurrentOwner,$e=!1;function De(e,t,n,r){t.child=e===null?Zv(t,null,n,r):di(t,e.child,n,r)}function nh(e,t,n,r,i){n=n.render;var o=t.ref;return ni(t,i),r=yf(e,t,n,r,o,i),n=wf(),e!==null&&!$e?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,pn(e,t,i)):(ue&&n&&sf(t),t.flags|=1,De(e,t,r,i),t.child)}function rh(e,t,n,r,i){if(e===null){var o=n.type;return typeof o=="function"&&!Pf(o)&&o.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=o,Sg(e,t,o,r,i)):(e=Hs(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(o=e.child,!(e.lanes&i)){var s=o.memoizedProps;if(n=n.compare,n=n!==null?n:bo,n(s,r)&&e.ref===t.ref)return pn(e,t,i)}return t.flags|=1,e=Un(o,r),e.ref=t.ref,e.return=t,t.child=e}function Sg(e,t,n,r,i){if(e!==null){var o=e.memoizedProps;if(bo(o,r)&&e.ref===t.ref)if($e=!1,t.pendingProps=r=o,(e.lanes&i)!==0)e.flags&131072&&($e=!0);else return t.lanes=e.lanes,pn(e,t,i)}return tc(e,t,n,r,i)}function Eg(e,t,n){var r=t.pendingProps,i=r.children,o=e!==null?e.memoizedState:null;if(r.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},re(Yr,Ke),Ke|=n;else{if(!(n&1073741824))return e=o!==null?o.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,re(Yr,Ke),Ke|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=o!==null?o.baseLanes:n,re(Yr,Ke),Ke|=r}else o!==null?(r=o.baseLanes|n,t.memoizedState=null):r=n,re(Yr,Ke),Ke|=r;return De(e,t,i,n),t.child}function Ag(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function tc(e,t,n,r,i){var o=We(n)?vr:Re.current;return o=ci(t,o),ni(t,i),n=yf(e,t,n,r,o,i),r=wf(),e!==null&&!$e?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,pn(e,t,i)):(ue&&r&&sf(t),t.flags|=1,De(e,t,n,i),t.child)}function ih(e,t,n,r,i){if(We(n)){var o=!0;al(t)}else o=!1;if(ni(t,i),t.stateNode===null)$s(e,t),xg(t,n,r),qu(t,n,r,i),r=!0;else if(e===null){var s=t.stateNode,l=t.memoizedProps;s.props=l;var a=s.context,u=n.contextType;typeof u=="object"&&u!==null?u=dt(u):(u=We(n)?vr:Re.current,u=ci(t,u));var c=n.getDerivedStateFromProps,f=typeof c=="function"||typeof s.getSnapshotBeforeUpdate=="function";f||typeof s.UNSAFE_componentWillReceiveProps!="function"&&typeof s.componentWillReceiveProps!="function"||(l!==r||a!==u)&&Jd(t,s,r,u),An=!1;var d=t.memoizedState;s.state=d,hl(t,r,s,i),a=t.memoizedState,l!==r||d!==a||Ve.current||An?(typeof c=="function"&&(Ju(t,n,c,r),a=t.memoizedState),(l=An||Zd(t,n,l,r,d,a,u))?(f||typeof s.UNSAFE_componentWillMount!="function"&&typeof s.componentWillMount!="function"||(typeof s.componentWillMount=="function"&&s.componentWillMount(),typeof s.UNSAFE_componentWillMount=="function"&&s.UNSAFE_componentWillMount()),typeof s.componentDidMount=="function"&&(t.flags|=4194308)):(typeof s.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=a),s.props=r,s.state=a,s.context=u,r=l):(typeof s.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{s=t.stateNode,qv(e,t),l=t.memoizedProps,u=t.type===t.elementType?l:gt(t.type,l),s.props=u,f=t.pendingProps,d=s.context,a=n.contextType,typeof a=="object"&&a!==null?a=dt(a):(a=We(n)?vr:Re.current,a=ci(t,a));var p=n.getDerivedStateFromProps;(c=typeof p=="function"||typeof s.getSnapshotBeforeUpdate=="function")||typeof s.UNSAFE_componentWillReceiveProps!="function"&&typeof s.componentWillReceiveProps!="function"||(l!==f||d!==a)&&Jd(t,s,r,a),An=!1,d=t.memoizedState,s.state=d,hl(t,r,s,i);var y=t.memoizedState;l!==f||d!==y||Ve.current||An?(typeof p=="function"&&(Ju(t,n,p,r),y=t.memoizedState),(u=An||Zd(t,n,u,r,d,y,a)||!1)?(c||typeof s.UNSAFE_componentWillUpdate!="function"&&typeof s.componentWillUpdate!="function"||(typeof s.componentWillUpdate=="function"&&s.componentWillUpdate(r,y,a),typeof s.UNSAFE_componentWillUpdate=="function"&&s.UNSAFE_componentWillUpdate(r,y,a)),typeof s.componentDidUpdate=="function"&&(t.flags|=4),typeof s.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof s.componentDidUpdate!="function"||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=4),typeof s.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=y),s.props=r,s.state=y,s.context=a,r=u):(typeof s.componentDidUpdate!="function"||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=4),typeof s.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=1024),r=!1)}return nc(e,t,n,r,o,i)}function nc(e,t,n,r,i,o){Ag(e,t);var s=(t.flags&128)!==0;if(!r&&!s)return i&&Vd(t,n,!1),pn(e,t,o);r=t.stateNode,Mx.current=t;var l=s&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&s?(t.child=di(t,e.child,null,o),t.child=di(t,null,l,o)):De(e,t,l,o),t.memoizedState=r.state,i&&Vd(t,n,!0),t.child}function Cg(e){var t=e.stateNode;t.pendingContext?$d(e,t.pendingContext,t.pendingContext!==t.context):t.context&&$d(e,t.context,!1),pf(e,t.containerInfo)}function oh(e,t,n,r,i){return fi(),af(i),t.flags|=256,De(e,t,n,r),t.child}var rc={dehydrated:null,treeContext:null,retryLane:0};function ic(e){return{baseLanes:e,cachePool:null,transitions:null}}function kg(e,t,n){var r=t.pendingProps,i=de.current,o=!1,s=(t.flags&128)!==0,l;if((l=s)||(l=e!==null&&e.memoizedState===null?!1:(i&2)!==0),l?(o=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(i|=1),re(de,i&1),e===null)return Xu(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):(s=r.children,e=r.fallback,o?(r=t.mode,o=t.child,s={mode:"hidden",children:s},!(r&1)&&o!==null?(o.childLanes=0,o.pendingProps=s):o=ea(s,r,0,null),e=pr(e,r,n,null),o.return=t,e.return=t,o.sibling=e,t.child=o,t.child.memoizedState=ic(n),t.memoizedState=rc,e):bf(t,s));if(i=e.memoizedState,i!==null&&(l=i.dehydrated,l!==null))return Lx(e,t,s,r,l,i,n);if(o){o=r.fallback,s=t.mode,i=e.child,l=i.sibling;var a={mode:"hidden",children:r.children};return!(s&1)&&t.child!==i?(r=t.child,r.childLanes=0,r.pendingProps=a,t.deletions=null):(r=Un(i,a),r.subtreeFlags=i.subtreeFlags&14680064),l!==null?o=Un(l,o):(o=pr(o,s,n,null),o.flags|=2),o.return=t,r.return=t,r.sibling=o,t.child=r,r=o,o=t.child,s=e.child.memoizedState,s=s===null?ic(n):{baseLanes:s.baseLanes|n,cachePool:null,transitions:s.transitions},o.memoizedState=s,o.childLanes=e.childLanes&~n,t.memoizedState=rc,r}return o=e.child,e=o.sibling,r=Un(o,{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 bf(e,t){return t=ea({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function ys(e,t,n,r){return r!==null&&af(r),di(t,e.child,null,n),e=bf(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Lx(e,t,n,r,i,o,s){if(n)return t.flags&256?(t.flags&=-257,r=Ya(Error(N(422))),ys(e,t,s,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(o=r.fallback,i=t.mode,r=ea({mode:"visible",children:r.children},i,0,null),o=pr(o,i,s,null),o.flags|=2,r.return=t,o.return=t,r.sibling=o,t.child=r,t.mode&1&&di(t,e.child,null,s),t.child.memoizedState=ic(s),t.memoizedState=rc,o);if(!(t.mode&1))return ys(e,t,s,null);if(i.data==="$!"){if(r=i.nextSibling&&i.nextSibling.dataset,r)var l=r.dgst;return r=l,o=Error(N(419)),r=Ya(o,r,void 0),ys(e,t,s,r)}if(l=(s&e.childLanes)!==0,$e||l){if(r=be,r!==null){switch(s&-s){case 4:i=2;break;case 16:i=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:i=32;break;case 536870912:i=268435456;break;default:i=0}i=i&(r.suspendedLanes|s)?0:i,i!==0&&i!==o.retryLane&&(o.retryLane=i,hn(e,i),_t(r,e,i,-1))}return Of(),r=Ya(Error(N(421))),ys(e,t,s,r)}return i.data==="$?"?(t.flags|=128,t.child=e.child,t=Yx.bind(null,e),i._reactRetry=t,null):(e=o.treeContext,Xe=Ln(i.nextSibling),Ze=t,ue=!0,yt=null,e!==null&&(it[ot++]=rn,it[ot++]=on,it[ot++]=gr,rn=e.id,on=e.overflow,gr=t),t=bf(t,r.children),t.flags|=4096,t)}function sh(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Zu(e.return,t,n)}function Xa(e,t,n,r,i){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=i)}function Og(e,t,n){var r=t.pendingProps,i=r.revealOrder,o=r.tail;if(De(e,t,r.children,n),r=de.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&&sh(e,n,t);else if(e.tag===19)sh(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(re(de,r),!(t.mode&1))t.memoizedState=null;else switch(i){case"forwards":for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&pl(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),Xa(t,!1,i,n,o);break;case"backwards":for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&pl(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}Xa(t,!0,n,null,o);break;case"together":Xa(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function $s(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function pn(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),yr|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(N(153));if(t.child!==null){for(e=t.child,n=Un(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=Un(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function Ix(e,t,n){switch(t.tag){case 3:Cg(t),fi();break;case 5:eg(t);break;case 1:We(t.type)&&al(t);break;case 4:pf(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,i=t.memoizedProps.value;re(fl,r._currentValue),r._currentValue=i;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(re(de,de.current&1),t.flags|=128,null):n&t.child.childLanes?kg(e,t,n):(re(de,de.current&1),e=pn(e,t,n),e!==null?e.sibling:null);re(de,de.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return Og(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),re(de,de.current),r)break;return null;case 22:case 23:return t.lanes=0,Eg(e,t,n)}return pn(e,t,n)}var Pg,oc,Ng,jg;Pg=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}};oc=function(){};Ng=function(e,t,n,r){var i=e.memoizedProps;if(i!==r){e=t.stateNode,cr(Bt.current);var o=null;switch(n){case"input":i=ku(e,i),r=ku(e,r),o=[];break;case"select":i=pe({},i,{value:void 0}),r=pe({},r,{value:void 0}),o=[];break;case"textarea":i=Nu(e,i),r=Nu(e,r),o=[];break;default:typeof i.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=sl)}Tu(n,r);var s;n=null;for(u in i)if(!r.hasOwnProperty(u)&&i.hasOwnProperty(u)&&i[u]!=null)if(u==="style"){var l=i[u];for(s in l)l.hasOwnProperty(s)&&(n||(n={}),n[s]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(vo.hasOwnProperty(u)?o||(o=[]):(o=o||[]).push(u,null));for(u in r){var a=r[u];if(l=i!=null?i[u]:void 0,r.hasOwnProperty(u)&&a!==l&&(a!=null||l!=null))if(u==="style")if(l){for(s in l)!l.hasOwnProperty(s)||a&&a.hasOwnProperty(s)||(n||(n={}),n[s]="");for(s in a)a.hasOwnProperty(s)&&l[s]!==a[s]&&(n||(n={}),n[s]=a[s])}else n||(o||(o=[]),o.push(u,n)),n=a;else u==="dangerouslySetInnerHTML"?(a=a?a.__html:void 0,l=l?l.__html:void 0,a!=null&&l!==a&&(o=o||[]).push(u,a)):u==="children"?typeof a!="string"&&typeof a!="number"||(o=o||[]).push(u,""+a):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(vo.hasOwnProperty(u)?(a!=null&&u==="onScroll"&&se("scroll",e),o||l===a||(o=[])):(o=o||[]).push(u,a))}n&&(o=o||[]).push("style",n);var u=o;(t.updateQueue=u)&&(t.flags|=4)}};jg=function(e,t,n,r){n!==r&&(t.flags|=4)};function Vi(e,t){if(!ue)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 je(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&14680064,r|=i.flags&14680064,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function Fx(e,t,n){var r=t.pendingProps;switch(lf(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return je(t),null;case 1:return We(t.type)&&ll(),je(t),null;case 3:return r=t.stateNode,hi(),le(Ve),le(Re),gf(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(gs(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,yt!==null&&(hc(yt),yt=null))),oc(e,t),je(t),null;case 5:vf(t);var i=cr(ko.current);if(n=t.type,e!==null&&t.stateNode!=null)Ng(e,t,n,r,i),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(N(166));return je(t),null}if(e=cr(Bt.current),gs(t)){r=t.stateNode,n=t.type;var o=t.memoizedProps;switch(r[Lt]=t,r[Ao]=o,e=(t.mode&1)!==0,n){case"dialog":se("cancel",r),se("close",r);break;case"iframe":case"object":case"embed":se("load",r);break;case"video":case"audio":for(i=0;i<Ji.length;i++)se(Ji[i],r);break;case"source":se("error",r);break;case"img":case"image":case"link":se("error",r),se("load",r);break;case"details":se("toggle",r);break;case"input":vd(r,o),se("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!o.multiple},se("invalid",r);break;case"textarea":md(r,o),se("invalid",r)}Tu(n,o),i=null;for(var s in o)if(o.hasOwnProperty(s)){var l=o[s];s==="children"?typeof l=="string"?r.textContent!==l&&(o.suppressHydrationWarning!==!0&&vs(r.textContent,l,e),i=["children",l]):typeof l=="number"&&r.textContent!==""+l&&(o.suppressHydrationWarning!==!0&&vs(r.textContent,l,e),i=["children",""+l]):vo.hasOwnProperty(s)&&l!=null&&s==="onScroll"&&se("scroll",r)}switch(n){case"input":ls(r),gd(r,o,!0);break;case"textarea":ls(r),yd(r);break;case"select":case"option":break;default:typeof o.onClick=="function"&&(r.onclick=sl)}r=i,t.updateQueue=r,r!==null&&(t.flags|=4)}else{s=i.nodeType===9?i:i.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=ov(n)),e==="http://www.w3.org/1999/xhtml"?n==="script"?(e=s.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=s.createElement(n,{is:r.is}):(e=s.createElement(n),n==="select"&&(s=e,r.multiple?s.multiple=!0:r.size&&(s.size=r.size))):e=s.createElementNS(e,n),e[Lt]=t,e[Ao]=r,Pg(e,t,!1,!1),t.stateNode=e;e:{switch(s=Ru(n,r),n){case"dialog":se("cancel",e),se("close",e),i=r;break;case"iframe":case"object":case"embed":se("load",e),i=r;break;case"video":case"audio":for(i=0;i<Ji.length;i++)se(Ji[i],e);i=r;break;case"source":se("error",e),i=r;break;case"img":case"image":case"link":se("error",e),se("load",e),i=r;break;case"details":se("toggle",e),i=r;break;case"input":vd(e,r),i=ku(e,r),se("invalid",e);break;case"option":i=r;break;case"select":e._wrapperState={wasMultiple:!!r.multiple},i=pe({},r,{value:void 0}),se("invalid",e);break;case"textarea":md(e,r),i=Nu(e,r),se("invalid",e);break;default:i=r}Tu(n,i),l=i;for(o in l)if(l.hasOwnProperty(o)){var a=l[o];o==="style"?av(e,a):o==="dangerouslySetInnerHTML"?(a=a?a.__html:void 0,a!=null&&sv(e,a)):o==="children"?typeof a=="string"?(n!=="textarea"||a!=="")&&go(e,a):typeof a=="number"&&go(e,""+a):o!=="suppressContentEditableWarning"&&o!=="suppressHydrationWarning"&&o!=="autoFocus"&&(vo.hasOwnProperty(o)?a!=null&&o==="onScroll"&&se("scroll",e):a!=null&&Hc(e,o,a,s))}switch(n){case"input":ls(e),gd(e,r,!1);break;case"textarea":ls(e),yd(e);break;case"option":r.value!=null&&e.setAttribute("value",""+Vn(r.value));break;case"select":e.multiple=!!r.multiple,o=r.value,o!=null?Jr(e,!!r.multiple,o,!1):r.defaultValue!=null&&Jr(e,!!r.multiple,r.defaultValue,!0);break;default:typeof i.onClick=="function"&&(e.onclick=sl)}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 je(t),null;case 6:if(e&&t.stateNode!=null)jg(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(N(166));if(n=cr(ko.current),cr(Bt.current),gs(t)){if(r=t.stateNode,n=t.memoizedProps,r[Lt]=t,(o=r.nodeValue!==n)&&(e=Ze,e!==null))switch(e.tag){case 3:vs(r.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&vs(r.nodeValue,n,(e.mode&1)!==0)}o&&(t.flags|=4)}else r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[Lt]=t,t.stateNode=r}return je(t),null;case 13:if(le(de),r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(ue&&Xe!==null&&t.mode&1&&!(t.flags&128))Yv(),fi(),t.flags|=98560,o=!1;else if(o=gs(t),r!==null&&r.dehydrated!==null){if(e===null){if(!o)throw Error(N(318));if(o=t.memoizedState,o=o!==null?o.dehydrated:null,!o)throw Error(N(317));o[Lt]=t}else fi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;je(t),o=!1}else yt!==null&&(hc(yt),yt=null),o=!0;if(!o)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||de.current&1?xe===0&&(xe=3):Of())),t.updateQueue!==null&&(t.flags|=4),je(t),null);case 4:return hi(),oc(e,t),e===null&&So(t.stateNode.containerInfo),je(t),null;case 10:return ff(t.type._context),je(t),null;case 17:return We(t.type)&&ll(),je(t),null;case 19:if(le(de),o=t.memoizedState,o===null)return je(t),null;if(r=(t.flags&128)!==0,s=o.rendering,s===null)if(r)Vi(o,!1);else{if(xe!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(s=pl(e),s!==null){for(t.flags|=128,Vi(o,!1),r=s.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),t.subtreeFlags=0,r=n,n=t.child;n!==null;)o=n,e=r,o.flags&=14680066,s=o.alternate,s===null?(o.childLanes=0,o.lanes=e,o.child=null,o.subtreeFlags=0,o.memoizedProps=null,o.memoizedState=null,o.updateQueue=null,o.dependencies=null,o.stateNode=null):(o.childLanes=s.childLanes,o.lanes=s.lanes,o.child=s.child,o.subtreeFlags=0,o.deletions=null,o.memoizedProps=s.memoizedProps,o.memoizedState=s.memoizedState,o.updateQueue=s.updateQueue,o.type=s.type,e=s.dependencies,o.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return re(de,de.current&1|2),t.child}e=e.sibling}o.tail!==null&&ge()>vi&&(t.flags|=128,r=!0,Vi(o,!1),t.lanes=4194304)}else{if(!r)if(e=pl(s),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),Vi(o,!0),o.tail===null&&o.tailMode==="hidden"&&!s.alternate&&!ue)return je(t),null}else 2*ge()-o.renderingStartTime>vi&&n!==1073741824&&(t.flags|=128,r=!0,Vi(o,!1),t.lanes=4194304);o.isBackwards?(s.sibling=t.child,t.child=s):(n=o.last,n!==null?n.sibling=s:t.child=s,o.last=s)}return o.tail!==null?(t=o.tail,o.rendering=t,o.tail=t.sibling,o.renderingStartTime=ge(),t.sibling=null,n=de.current,re(de,r?n&1|2:n&1),t):(je(t),null);case 22:case 23:return kf(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?Ke&1073741824&&(je(t),t.subtreeFlags&6&&(t.flags|=8192)):je(t),null;case 24:return null;case 25:return null}throw Error(N(156,t.tag))}function zx(e,t){switch(lf(t),t.tag){case 1:return We(t.type)&&ll(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return hi(),le(Ve),le(Re),gf(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return vf(t),null;case 13:if(le(de),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(N(340));fi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return le(de),null;case 4:return hi(),null;case 10:return ff(t.type._context),null;case 22:case 23:return kf(),null;case 24:return null;default:return null}}var ws=!1,Te=!1,Ux=typeof WeakSet=="function"?WeakSet:Set,M=null;function Qr(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){ve(e,t,r)}else n.current=null}function sc(e,t,n){try{n()}catch(r){ve(e,t,r)}}var lh=!1;function Bx(e,t){if(Vu=rl,e=Lv(),of(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 i=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break e}var s=0,l=-1,a=-1,u=0,c=0,f=e,d=null;t:for(;;){for(var p;f!==n||i!==0&&f.nodeType!==3||(l=s+i),f!==o||r!==0&&f.nodeType!==3||(a=s+r),f.nodeType===3&&(s+=f.nodeValue.length),(p=f.firstChild)!==null;)d=f,f=p;for(;;){if(f===e)break t;if(d===n&&++u===i&&(l=s),d===o&&++c===r&&(a=s),(p=f.nextSibling)!==null)break;f=d,d=f.parentNode}f=p}n=l===-1||a===-1?null:{start:l,end:a}}else n=null}n=n||{start:0,end:0}}else n=null;for(Wu={focusedElem:e,selectionRange:n},rl=!1,M=t;M!==null;)if(t=M,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,M=e;else for(;M!==null;){t=M;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 m=y.memoizedProps,b=y.memoizedState,v=t.stateNode,g=v.getSnapshotBeforeUpdate(t.elementType===t.type?m:gt(t.type,m),b);v.__reactInternalSnapshotBeforeUpdate=g}break;case 3:var w=t.stateNode.containerInfo;w.nodeType===1?w.textContent="":w.nodeType===9&&w.documentElement&&w.removeChild(w.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(N(163))}}catch(_){ve(t,t.return,_)}if(e=t.sibling,e!==null){e.return=t.return,M=e;break}M=t.return}return y=lh,lh=!1,y}function so(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var i=r=r.next;do{if((i.tag&e)===e){var o=i.destroy;i.destroy=void 0,o!==void 0&&sc(t,n,o)}i=i.next}while(i!==r)}}function Jl(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 lc(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 Tg(e){var t=e.alternate;t!==null&&(e.alternate=null,Tg(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Lt],delete t[Ao],delete t[Gu],delete t[Sx],delete t[Ex])),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 Rg(e){return e.tag===5||e.tag===3||e.tag===4}function ah(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Rg(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 ac(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=sl));else if(r!==4&&(e=e.child,e!==null))for(ac(e,t,n),e=e.sibling;e!==null;)ac(e,t,n),e=e.sibling}function uc(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(uc(e,t,n),e=e.sibling;e!==null;)uc(e,t,n),e=e.sibling}var ke=null,mt=!1;function xn(e,t,n){for(n=n.child;n!==null;)Dg(e,t,n),n=n.sibling}function Dg(e,t,n){if(Ut&&typeof Ut.onCommitFiberUnmount=="function")try{Ut.onCommitFiberUnmount(Wl,n)}catch{}switch(n.tag){case 5:Te||Qr(n,t);case 6:var r=ke,i=mt;ke=null,xn(e,t,n),ke=r,mt=i,ke!==null&&(mt?(e=ke,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):ke.removeChild(n.stateNode));break;case 18:ke!==null&&(mt?(e=ke,n=n.stateNode,e.nodeType===8?Va(e.parentNode,n):e.nodeType===1&&Va(e,n),xo(e)):Va(ke,n.stateNode));break;case 4:r=ke,i=mt,ke=n.stateNode.containerInfo,mt=!0,xn(e,t,n),ke=r,mt=i;break;case 0:case 11:case 14:case 15:if(!Te&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){i=r=r.next;do{var o=i,s=o.destroy;o=o.tag,s!==void 0&&(o&2||o&4)&&sc(n,t,s),i=i.next}while(i!==r)}xn(e,t,n);break;case 1:if(!Te&&(Qr(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(l){ve(n,t,l)}xn(e,t,n);break;case 21:xn(e,t,n);break;case 22:n.mode&1?(Te=(r=Te)||n.memoizedState!==null,xn(e,t,n),Te=r):xn(e,t,n);break;default:xn(e,t,n)}}function uh(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new Ux),t.forEach(function(r){var i=Xx.bind(null,e,r);n.has(r)||(n.add(r),r.then(i,i))})}}function vt(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var i=n[r];try{var o=e,s=t,l=s;e:for(;l!==null;){switch(l.tag){case 5:ke=l.stateNode,mt=!1;break e;case 3:ke=l.stateNode.containerInfo,mt=!0;break e;case 4:ke=l.stateNode.containerInfo,mt=!0;break e}l=l.return}if(ke===null)throw Error(N(160));Dg(o,s,i),ke=null,mt=!1;var a=i.alternate;a!==null&&(a.return=null),i.return=null}catch(u){ve(i,t,u)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)Mg(t,e),t=t.sibling}function Mg(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(vt(t,e),Tt(e),r&4){try{so(3,e,e.return),Jl(3,e)}catch(m){ve(e,e.return,m)}try{so(5,e,e.return)}catch(m){ve(e,e.return,m)}}break;case 1:vt(t,e),Tt(e),r&512&&n!==null&&Qr(n,n.return);break;case 5:if(vt(t,e),Tt(e),r&512&&n!==null&&Qr(n,n.return),e.flags&32){var i=e.stateNode;try{go(i,"")}catch(m){ve(e,e.return,m)}}if(r&4&&(i=e.stateNode,i!=null)){var o=e.memoizedProps,s=n!==null?n.memoizedProps:o,l=e.type,a=e.updateQueue;if(e.updateQueue=null,a!==null)try{l==="input"&&o.type==="radio"&&o.name!=null&&rv(i,o),Ru(l,s);var u=Ru(l,o);for(s=0;s<a.length;s+=2){var c=a[s],f=a[s+1];c==="style"?av(i,f):c==="dangerouslySetInnerHTML"?sv(i,f):c==="children"?go(i,f):Hc(i,c,f,u)}switch(l){case"input":Ou(i,o);break;case"textarea":iv(i,o);break;case"select":var d=i._wrapperState.wasMultiple;i._wrapperState.wasMultiple=!!o.multiple;var p=o.value;p!=null?Jr(i,!!o.multiple,p,!1):d!==!!o.multiple&&(o.defaultValue!=null?Jr(i,!!o.multiple,o.defaultValue,!0):Jr(i,!!o.multiple,o.multiple?[]:"",!1))}i[Ao]=o}catch(m){ve(e,e.return,m)}}break;case 6:if(vt(t,e),Tt(e),r&4){if(e.stateNode===null)throw Error(N(162));i=e.stateNode,o=e.memoizedProps;try{i.nodeValue=o}catch(m){ve(e,e.return,m)}}break;case 3:if(vt(t,e),Tt(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{xo(t.containerInfo)}catch(m){ve(e,e.return,m)}break;case 4:vt(t,e),Tt(e);break;case 13:vt(t,e),Tt(e),i=e.child,i.flags&8192&&(o=i.memoizedState!==null,i.stateNode.isHidden=o,!o||i.alternate!==null&&i.alternate.memoizedState!==null||(Af=ge())),r&4&&uh(e);break;case 22:if(c=n!==null&&n.memoizedState!==null,e.mode&1?(Te=(u=Te)||c,vt(t,e),Te=u):vt(t,e),Tt(e),r&8192){if(u=e.memoizedState!==null,(e.stateNode.isHidden=u)&&!c&&e.mode&1)for(M=e,c=e.child;c!==null;){for(f=M=c;M!==null;){switch(d=M,p=d.child,d.tag){case 0:case 11:case 14:case 15:so(4,d,d.return);break;case 1:Qr(d,d.return);var y=d.stateNode;if(typeof y.componentWillUnmount=="function"){r=d,n=d.return;try{t=r,y.props=t.memoizedProps,y.state=t.memoizedState,y.componentWillUnmount()}catch(m){ve(r,n,m)}}break;case 5:Qr(d,d.return);break;case 22:if(d.memoizedState!==null){fh(f);continue}}p!==null?(p.return=d,M=p):fh(f)}c=c.sibling}e:for(c=null,f=e;;){if(f.tag===5){if(c===null){c=f;try{i=f.stateNode,u?(o=i.style,typeof o.setProperty=="function"?o.setProperty("display","none","important"):o.display="none"):(l=f.stateNode,a=f.memoizedProps.style,s=a!=null&&a.hasOwnProperty("display")?a.display:null,l.style.display=lv("display",s))}catch(m){ve(e,e.return,m)}}}else if(f.tag===6){if(c===null)try{f.stateNode.nodeValue=u?"":f.memoizedProps}catch(m){ve(e,e.return,m)}}else if((f.tag!==22&&f.tag!==23||f.memoizedState===null||f===e)&&f.child!==null){f.child.return=f,f=f.child;continue}if(f===e)break e;for(;f.sibling===null;){if(f.return===null||f.return===e)break e;c===f&&(c=null),f=f.return}c===f&&(c=null),f.sibling.return=f.return,f=f.sibling}}break;case 19:vt(t,e),Tt(e),r&4&&uh(e);break;case 21:break;default:vt(t,e),Tt(e)}}function Tt(e){var t=e.flags;if(t&2){try{e:{for(var n=e.return;n!==null;){if(Rg(n)){var r=n;break e}n=n.return}throw Error(N(160))}switch(r.tag){case 5:var i=r.stateNode;r.flags&32&&(go(i,""),r.flags&=-33);var o=ah(e);uc(e,o,i);break;case 3:case 4:var s=r.stateNode.containerInfo,l=ah(e);ac(e,l,s);break;default:throw Error(N(161))}}catch(a){ve(e,e.return,a)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function $x(e,t,n){M=e,Lg(e)}function Lg(e,t,n){for(var r=(e.mode&1)!==0;M!==null;){var i=M,o=i.child;if(i.tag===22&&r){var s=i.memoizedState!==null||ws;if(!s){var l=i.alternate,a=l!==null&&l.memoizedState!==null||Te;l=ws;var u=Te;if(ws=s,(Te=a)&&!u)for(M=i;M!==null;)s=M,a=s.child,s.tag===22&&s.memoizedState!==null?dh(i):a!==null?(a.return=s,M=a):dh(i);for(;o!==null;)M=o,Lg(o),o=o.sibling;M=i,ws=l,Te=u}ch(e)}else i.subtreeFlags&8772&&o!==null?(o.return=i,M=o):ch(e)}}function ch(e){for(;M!==null;){var t=M;if(t.flags&8772){var n=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:Te||Jl(5,t);break;case 1:var r=t.stateNode;if(t.flags&4&&!Te)if(n===null)r.componentDidMount();else{var i=t.elementType===t.type?n.memoizedProps:gt(t.type,n.memoizedProps);r.componentDidUpdate(i,n.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var o=t.updateQueue;o!==null&&Qd(t,o,r);break;case 3:var s=t.updateQueue;if(s!==null){if(n=null,t.child!==null)switch(t.child.tag){case 5:n=t.child.stateNode;break;case 1:n=t.child.stateNode}Qd(t,s,n)}break;case 5:var l=t.stateNode;if(n===null&&t.flags&4){n=l;var a=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":a.autoFocus&&n.focus();break;case"img":a.src&&(n.src=a.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 c=u.memoizedState;if(c!==null){var f=c.dehydrated;f!==null&&xo(f)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(N(163))}Te||t.flags&512&&lc(t)}catch(d){ve(t,t.return,d)}}if(t===e){M=null;break}if(n=t.sibling,n!==null){n.return=t.return,M=n;break}M=t.return}}function fh(e){for(;M!==null;){var t=M;if(t===e){M=null;break}var n=t.sibling;if(n!==null){n.return=t.return,M=n;break}M=t.return}}function dh(e){for(;M!==null;){var t=M;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{Jl(4,t)}catch(a){ve(t,n,a)}break;case 1:var r=t.stateNode;if(typeof r.componentDidMount=="function"){var i=t.return;try{r.componentDidMount()}catch(a){ve(t,i,a)}}var o=t.return;try{lc(t)}catch(a){ve(t,o,a)}break;case 5:var s=t.return;try{lc(t)}catch(a){ve(t,s,a)}}}catch(a){ve(t,t.return,a)}if(t===e){M=null;break}var l=t.sibling;if(l!==null){l.return=t.return,M=l;break}M=t.return}}var Vx=Math.ceil,ml=yn.ReactCurrentDispatcher,Sf=yn.ReactCurrentOwner,ft=yn.ReactCurrentBatchConfig,Y=0,be=null,me=null,Oe=0,Ke=0,Yr=Yn(0),xe=0,jo=null,yr=0,ql=0,Ef=0,lo=null,Be=null,Af=0,vi=1/0,qt=null,yl=!1,cc=null,Fn=null,xs=!1,Nn=null,wl=0,ao=0,fc=null,Vs=-1,Ws=0;function Me(){return Y&6?ge():Vs!==-1?Vs:Vs=ge()}function zn(e){return e.mode&1?Y&2&&Oe!==0?Oe&-Oe:Cx.transition!==null?(Ws===0&&(Ws=xv()),Ws):(e=q,e!==0||(e=window.event,e=e===void 0?16:kv(e.type)),e):1}function _t(e,t,n,r){if(50<ao)throw ao=0,fc=null,Error(N(185));Uo(e,n,r),(!(Y&2)||e!==be)&&(e===be&&(!(Y&2)&&(ql|=n),xe===4&&On(e,Oe)),He(e,r),n===1&&Y===0&&!(t.mode&1)&&(vi=ge()+500,Yl&&Xn()))}function He(e,t){var n=e.callbackNode;Cw(e,t);var r=nl(e,e===be?Oe:0);if(r===0)n!==null&&_d(n),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(n!=null&&_d(n),t===1)e.tag===0?Ax(hh.bind(null,e)):Kv(hh.bind(null,e)),_x(function(){!(Y&6)&&Xn()}),n=null;else{switch(_v(r)){case 1:n=Xc;break;case 4:n=yv;break;case 16:n=tl;break;case 536870912:n=wv;break;default:n=tl}n=Wg(n,Ig.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function Ig(e,t){if(Vs=-1,Ws=0,Y&6)throw Error(N(327));var n=e.callbackNode;if(ri()&&e.callbackNode!==n)return null;var r=nl(e,e===be?Oe:0);if(r===0)return null;if(r&30||r&e.expiredLanes||t)t=xl(e,r);else{t=r;var i=Y;Y|=2;var o=zg();(be!==e||Oe!==t)&&(qt=null,vi=ge()+500,hr(e,t));do try{Kx();break}catch(l){Fg(e,l)}while(!0);cf(),ml.current=o,Y=i,me!==null?t=0:(be=null,Oe=0,t=xe)}if(t!==0){if(t===2&&(i=Fu(e),i!==0&&(r=i,t=dc(e,i))),t===1)throw n=jo,hr(e,0),On(e,r),He(e,ge()),n;if(t===6)On(e,r);else{if(i=e.current.alternate,!(r&30)&&!Wx(i)&&(t=xl(e,r),t===2&&(o=Fu(e),o!==0&&(r=o,t=dc(e,o))),t===1))throw n=jo,hr(e,0),On(e,r),He(e,ge()),n;switch(e.finishedWork=i,e.finishedLanes=r,t){case 0:case 1:throw Error(N(345));case 2:sr(e,Be,qt);break;case 3:if(On(e,r),(r&130023424)===r&&(t=Af+500-ge(),10<t)){if(nl(e,0)!==0)break;if(i=e.suspendedLanes,(i&r)!==r){Me(),e.pingedLanes|=e.suspendedLanes&i;break}e.timeoutHandle=Ku(sr.bind(null,e,Be,qt),t);break}sr(e,Be,qt);break;case 4:if(On(e,r),(r&4194240)===r)break;for(t=e.eventTimes,i=-1;0<r;){var s=31-xt(r);o=1<<s,s=t[s],s>i&&(i=s),r&=~o}if(r=i,r=ge()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*Vx(r/1960))-r,10<r){e.timeoutHandle=Ku(sr.bind(null,e,Be,qt),r);break}sr(e,Be,qt);break;case 5:sr(e,Be,qt);break;default:throw Error(N(329))}}}return He(e,ge()),e.callbackNode===n?Ig.bind(null,e):null}function dc(e,t){var n=lo;return e.current.memoizedState.isDehydrated&&(hr(e,t).flags|=256),e=xl(e,t),e!==2&&(t=Be,Be=n,t!==null&&hc(t)),e}function hc(e){Be===null?Be=e:Be.push.apply(Be,e)}function Wx(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 i=n[r],o=i.getSnapshot;i=i.value;try{if(!Et(o(),i))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 On(e,t){for(t&=~Ef,t&=~ql,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-xt(t),r=1<<n;e[n]=-1,t&=~r}}function hh(e){if(Y&6)throw Error(N(327));ri();var t=nl(e,0);if(!(t&1))return He(e,ge()),null;var n=xl(e,t);if(e.tag!==0&&n===2){var r=Fu(e);r!==0&&(t=r,n=dc(e,r))}if(n===1)throw n=jo,hr(e,0),On(e,t),He(e,ge()),n;if(n===6)throw Error(N(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,sr(e,Be,qt),He(e,ge()),null}function Cf(e,t){var n=Y;Y|=1;try{return e(t)}finally{Y=n,Y===0&&(vi=ge()+500,Yl&&Xn())}}function wr(e){Nn!==null&&Nn.tag===0&&!(Y&6)&&ri();var t=Y;Y|=1;var n=ft.transition,r=q;try{if(ft.transition=null,q=1,e)return e()}finally{q=r,ft.transition=n,Y=t,!(Y&6)&&Xn()}}function kf(){Ke=Yr.current,le(Yr)}function hr(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,xx(n)),me!==null)for(n=me.return;n!==null;){var r=n;switch(lf(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&ll();break;case 3:hi(),le(Ve),le(Re),gf();break;case 5:vf(r);break;case 4:hi();break;case 13:le(de);break;case 19:le(de);break;case 10:ff(r.type._context);break;case 22:case 23:kf()}n=n.return}if(be=e,me=e=Un(e.current,null),Oe=Ke=t,xe=0,jo=null,Ef=ql=yr=0,Be=lo=null,ur!==null){for(t=0;t<ur.length;t++)if(n=ur[t],r=n.interleaved,r!==null){n.interleaved=null;var i=r.next,o=n.pending;if(o!==null){var s=o.next;o.next=i,r.next=s}n.pending=r}ur=null}return e}function Fg(e,t){do{var n=me;try{if(cf(),Us.current=gl,vl){for(var r=he.memoizedState;r!==null;){var i=r.queue;i!==null&&(i.pending=null),r=r.next}vl=!1}if(mr=0,_e=we=he=null,oo=!1,Oo=0,Sf.current=null,n===null||n.return===null){xe=1,jo=t,me=null;break}e:{var o=e,s=n.return,l=n,a=t;if(t=Oe,l.flags|=32768,a!==null&&typeof a=="object"&&typeof a.then=="function"){var u=a,c=l,f=c.tag;if(!(c.mode&1)&&(f===0||f===11||f===15)){var d=c.alternate;d?(c.updateQueue=d.updateQueue,c.memoizedState=d.memoizedState,c.lanes=d.lanes):(c.updateQueue=null,c.memoizedState=null)}var p=eh(s);if(p!==null){p.flags&=-257,th(p,s,l,o,t),p.mode&1&&qd(o,u,t),t=p,a=u;var y=t.updateQueue;if(y===null){var m=new Set;m.add(a),t.updateQueue=m}else y.add(a);break e}else{if(!(t&1)){qd(o,u,t),Of();break e}a=Error(N(426))}}else if(ue&&l.mode&1){var b=eh(s);if(b!==null){!(b.flags&65536)&&(b.flags|=256),th(b,s,l,o,t),af(pi(a,l));break e}}o=a=pi(a,l),xe!==4&&(xe=2),lo===null?lo=[o]:lo.push(o),o=s;do{switch(o.tag){case 3:o.flags|=65536,t&=-t,o.lanes|=t;var v=_g(o,a,t);Gd(o,v);break e;case 1:l=a;var g=o.type,w=o.stateNode;if(!(o.flags&128)&&(typeof g.getDerivedStateFromError=="function"||w!==null&&typeof w.componentDidCatch=="function"&&(Fn===null||!Fn.has(w)))){o.flags|=65536,t&=-t,o.lanes|=t;var _=bg(o,l,t);Gd(o,_);break e}}o=o.return}while(o!==null)}Bg(n)}catch(S){t=S,me===n&&n!==null&&(me=n=n.return);continue}break}while(!0)}function zg(){var e=ml.current;return ml.current=gl,e===null?gl:e}function Of(){(xe===0||xe===3||xe===2)&&(xe=4),be===null||!(yr&268435455)&&!(ql&268435455)||On(be,Oe)}function xl(e,t){var n=Y;Y|=2;var r=zg();(be!==e||Oe!==t)&&(qt=null,hr(e,t));do try{Hx();break}catch(i){Fg(e,i)}while(!0);if(cf(),Y=n,ml.current=r,me!==null)throw Error(N(261));return be=null,Oe=0,xe}function Hx(){for(;me!==null;)Ug(me)}function Kx(){for(;me!==null&&!mw();)Ug(me)}function Ug(e){var t=Vg(e.alternate,e,Ke);e.memoizedProps=e.pendingProps,t===null?Bg(e):me=t,Sf.current=null}function Bg(e){var t=e;do{var n=t.alternate;if(e=t.return,t.flags&32768){if(n=zx(n,t),n!==null){n.flags&=32767,me=n;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{xe=6,me=null;return}}else if(n=Fx(n,t,Ke),n!==null){me=n;return}if(t=t.sibling,t!==null){me=t;return}me=t=e}while(t!==null);xe===0&&(xe=5)}function sr(e,t,n){var r=q,i=ft.transition;try{ft.transition=null,q=1,Gx(e,t,n,r)}finally{ft.transition=i,q=r}return null}function Gx(e,t,n,r){do ri();while(Nn!==null);if(Y&6)throw Error(N(327));n=e.finishedWork;var i=e.finishedLanes;if(n===null)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(N(177));e.callbackNode=null,e.callbackPriority=0;var o=n.lanes|n.childLanes;if(kw(e,o),e===be&&(me=be=null,Oe=0),!(n.subtreeFlags&2064)&&!(n.flags&2064)||xs||(xs=!0,Wg(tl,function(){return ri(),null})),o=(n.flags&15990)!==0,n.subtreeFlags&15990||o){o=ft.transition,ft.transition=null;var s=q;q=1;var l=Y;Y|=4,Sf.current=null,Bx(e,n),Mg(n,e),hx(Wu),rl=!!Vu,Wu=Vu=null,e.current=n,$x(n),yw(),Y=l,q=s,ft.transition=o}else e.current=n;if(xs&&(xs=!1,Nn=e,wl=i),o=e.pendingLanes,o===0&&(Fn=null),_w(n.stateNode),He(e,ge()),t!==null)for(r=e.onRecoverableError,n=0;n<t.length;n++)i=t[n],r(i.value,{componentStack:i.stack,digest:i.digest});if(yl)throw yl=!1,e=cc,cc=null,e;return wl&1&&e.tag!==0&&ri(),o=e.pendingLanes,o&1?e===fc?ao++:(ao=0,fc=e):ao=0,Xn(),null}function ri(){if(Nn!==null){var e=_v(wl),t=ft.transition,n=q;try{if(ft.transition=null,q=16>e?16:e,Nn===null)var r=!1;else{if(e=Nn,Nn=null,wl=0,Y&6)throw Error(N(331));var i=Y;for(Y|=4,M=e.current;M!==null;){var o=M,s=o.child;if(M.flags&16){var l=o.deletions;if(l!==null){for(var a=0;a<l.length;a++){var u=l[a];for(M=u;M!==null;){var c=M;switch(c.tag){case 0:case 11:case 15:so(8,c,o)}var f=c.child;if(f!==null)f.return=c,M=f;else for(;M!==null;){c=M;var d=c.sibling,p=c.return;if(Tg(c),c===u){M=null;break}if(d!==null){d.return=p,M=d;break}M=p}}}var y=o.alternate;if(y!==null){var m=y.child;if(m!==null){y.child=null;do{var b=m.sibling;m.sibling=null,m=b}while(m!==null)}}M=o}}if(o.subtreeFlags&2064&&s!==null)s.return=o,M=s;else e:for(;M!==null;){if(o=M,o.flags&2048)switch(o.tag){case 0:case 11:case 15:so(9,o,o.return)}var v=o.sibling;if(v!==null){v.return=o.return,M=v;break e}M=o.return}}var g=e.current;for(M=g;M!==null;){s=M;var w=s.child;if(s.subtreeFlags&2064&&w!==null)w.return=s,M=w;else e:for(s=g;M!==null;){if(l=M,l.flags&2048)try{switch(l.tag){case 0:case 11:case 15:Jl(9,l)}}catch(S){ve(l,l.return,S)}if(l===s){M=null;break e}var _=l.sibling;if(_!==null){_.return=l.return,M=_;break e}M=l.return}}if(Y=i,Xn(),Ut&&typeof Ut.onPostCommitFiberRoot=="function")try{Ut.onPostCommitFiberRoot(Wl,e)}catch{}r=!0}return r}finally{q=n,ft.transition=t}}return!1}function ph(e,t,n){t=pi(n,t),t=_g(e,t,1),e=In(e,t,1),t=Me(),e!==null&&(Uo(e,1,t),He(e,t))}function ve(e,t,n){if(e.tag===3)ph(e,e,n);else for(;t!==null;){if(t.tag===3){ph(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(Fn===null||!Fn.has(r))){e=pi(n,e),e=bg(t,e,1),t=In(t,e,1),e=Me(),t!==null&&(Uo(t,1,e),He(t,e));break}}t=t.return}}function Qx(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),t=Me(),e.pingedLanes|=e.suspendedLanes&n,be===e&&(Oe&n)===n&&(xe===4||xe===3&&(Oe&130023424)===Oe&&500>ge()-Af?hr(e,0):Ef|=n),He(e,t)}function $g(e,t){t===0&&(e.mode&1?(t=cs,cs<<=1,!(cs&130023424)&&(cs=4194304)):t=1);var n=Me();e=hn(e,t),e!==null&&(Uo(e,t,n),He(e,n))}function Yx(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),$g(e,n)}function Xx(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(N(314))}r!==null&&r.delete(t),$g(e,n)}var Vg;Vg=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||Ve.current)$e=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return $e=!1,Ix(e,t,n);$e=!!(e.flags&131072)}else $e=!1,ue&&t.flags&1048576&&Gv(t,cl,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;$s(e,t),e=t.pendingProps;var i=ci(t,Re.current);ni(t,n),i=yf(null,t,r,e,i,n);var o=wf();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,We(r)?(o=!0,al(t)):o=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,hf(t),i.updater=Zl,t.stateNode=i,i._reactInternals=t,qu(t,r,e,n),t=nc(null,t,r,!0,o,n)):(t.tag=0,ue&&o&&sf(t),De(null,t,i,n),t=t.child),t;case 16:r=t.elementType;e:{switch($s(e,t),e=t.pendingProps,i=r._init,r=i(r._payload),t.type=r,i=t.tag=Jx(r),e=gt(r,e),i){case 0:t=tc(null,t,r,e,n);break e;case 1:t=ih(null,t,r,e,n);break e;case 11:t=nh(null,t,r,e,n);break e;case 14:t=rh(null,t,r,gt(r.type,e),n);break e}throw Error(N(306,r,""))}return t;case 0:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:gt(r,i),tc(e,t,r,i,n);case 1:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:gt(r,i),ih(e,t,r,i,n);case 3:e:{if(Cg(t),e===null)throw Error(N(387));r=t.pendingProps,o=t.memoizedState,i=o.element,qv(e,t),hl(t,r,null,n);var s=t.memoizedState;if(r=s.element,o.isDehydrated)if(o={element:r,isDehydrated:!1,cache:s.cache,pendingSuspenseBoundaries:s.pendingSuspenseBoundaries,transitions:s.transitions},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){i=pi(Error(N(423)),t),t=oh(e,t,r,n,i);break e}else if(r!==i){i=pi(Error(N(424)),t),t=oh(e,t,r,n,i);break e}else for(Xe=Ln(t.stateNode.containerInfo.firstChild),Ze=t,ue=!0,yt=null,n=Zv(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(fi(),r===i){t=pn(e,t,n);break e}De(e,t,r,n)}t=t.child}return t;case 5:return eg(t),e===null&&Xu(t),r=t.type,i=t.pendingProps,o=e!==null?e.memoizedProps:null,s=i.children,Hu(r,i)?s=null:o!==null&&Hu(r,o)&&(t.flags|=32),Ag(e,t),De(e,t,s,n),t.child;case 6:return e===null&&Xu(t),null;case 13:return kg(e,t,n);case 4:return pf(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=di(t,null,r,n):De(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:gt(r,i),nh(e,t,r,i,n);case 7:return De(e,t,t.pendingProps,n),t.child;case 8:return De(e,t,t.pendingProps.children,n),t.child;case 12:return De(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,i=t.pendingProps,o=t.memoizedProps,s=i.value,re(fl,r._currentValue),r._currentValue=s,o!==null)if(Et(o.value,s)){if(o.children===i.children&&!Ve.current){t=pn(e,t,n);break e}}else for(o=t.child,o!==null&&(o.return=t);o!==null;){var l=o.dependencies;if(l!==null){s=o.child;for(var a=l.firstContext;a!==null;){if(a.context===r){if(o.tag===1){a=sn(-1,n&-n),a.tag=2;var u=o.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?a.next=a:(a.next=c.next,c.next=a),u.pending=a}}o.lanes|=n,a=o.alternate,a!==null&&(a.lanes|=n),Zu(o.return,n,t),l.lanes|=n;break}a=a.next}}else if(o.tag===10)s=o.type===t.type?null:o.child;else if(o.tag===18){if(s=o.return,s===null)throw Error(N(341));s.lanes|=n,l=s.alternate,l!==null&&(l.lanes|=n),Zu(s,n,t),s=o.sibling}else s=o.child;if(s!==null)s.return=o;else for(s=o;s!==null;){if(s===t){s=null;break}if(o=s.sibling,o!==null){o.return=s.return,s=o;break}s=s.return}o=s}De(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=t.pendingProps.children,ni(t,n),i=dt(i),r=r(i),t.flags|=1,De(e,t,r,n),t.child;case 14:return r=t.type,i=gt(r,t.pendingProps),i=gt(r.type,i),rh(e,t,r,i,n);case 15:return Sg(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:gt(r,i),$s(e,t),t.tag=1,We(r)?(e=!0,al(t)):e=!1,ni(t,n),xg(t,r,i),qu(t,r,i,n),nc(null,t,r,!0,e,n);case 19:return Og(e,t,n);case 22:return Eg(e,t,n)}throw Error(N(156,t.tag))};function Wg(e,t){return mv(e,t)}function Zx(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 at(e,t,n,r){return new Zx(e,t,n,r)}function Pf(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Jx(e){if(typeof e=="function")return Pf(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Gc)return 11;if(e===Qc)return 14}return 2}function Un(e,t){var n=e.alternate;return n===null?(n=at(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 Hs(e,t,n,r,i,o){var s=2;if(r=e,typeof e=="function")Pf(e)&&(s=1);else if(typeof e=="string")s=5;else e:switch(e){case zr:return pr(n.children,i,o,t);case Kc:s=8,i|=8;break;case Su:return e=at(12,n,t,i|2),e.elementType=Su,e.lanes=o,e;case Eu:return e=at(13,n,t,i),e.elementType=Eu,e.lanes=o,e;case Au:return e=at(19,n,t,i),e.elementType=Au,e.lanes=o,e;case ev:return ea(n,i,o,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Jp:s=10;break e;case qp:s=9;break e;case Gc:s=11;break e;case Qc:s=14;break e;case En:s=16,r=null;break e}throw Error(N(130,e==null?e:typeof e,""))}return t=at(s,n,t,i),t.elementType=e,t.type=r,t.lanes=o,t}function pr(e,t,n,r){return e=at(7,e,r,t),e.lanes=n,e}function ea(e,t,n,r){return e=at(22,e,r,t),e.elementType=ev,e.lanes=n,e.stateNode={isHidden:!1},e}function Za(e,t,n){return e=at(6,e,null,t),e.lanes=n,e}function Ja(e,t,n){return t=at(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function qx(e,t,n,r,i){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=Ta(0),this.expirationTimes=Ta(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ta(0),this.identifierPrefix=r,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function Nf(e,t,n,r,i,o,s,l,a){return e=new qx(e,t,n,l,a),t===1?(t=1,o===!0&&(t|=8)):t=0,o=at(3,null,null,t),e.current=o,o.stateNode=e,o.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},hf(o),e}function e1(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Fr,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}function Hg(e){if(!e)return Wn;e=e._reactInternals;e:{if(kr(e)!==e||e.tag!==1)throw Error(N(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(N(171))}if(e.tag===1){var n=e.type;if(We(n))return Hv(e,n,t)}return t}function Kg(e,t,n,r,i,o,s,l,a){return e=Nf(n,r,!0,e,i,o,s,l,a),e.context=Hg(null),n=e.current,r=Me(),i=zn(n),o=sn(r,i),o.callback=t??null,In(n,o,i),e.current.lanes=i,Uo(e,i,r),He(e,r),e}function ta(e,t,n,r){var i=t.current,o=Me(),s=zn(i);return n=Hg(n),t.context===null?t.context=n:t.pendingContext=n,t=sn(o,s),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),e=In(i,t,s),e!==null&&(_t(e,i,s,o),zs(e,i,s)),s}function _l(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 vh(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function jf(e,t){vh(e,t),(e=e.alternate)&&vh(e,t)}function t1(){return null}var Gg=typeof reportError=="function"?reportError:function(e){console.error(e)};function Tf(e){this._internalRoot=e}na.prototype.render=Tf.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(N(409));ta(e,t,null,null)};na.prototype.unmount=Tf.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;wr(function(){ta(null,e,null,null)}),t[dn]=null}};function na(e){this._internalRoot=e}na.prototype.unstable_scheduleHydration=function(e){if(e){var t=Ev();e={blockedOn:null,target:e,priority:t};for(var n=0;n<kn.length&&t!==0&&t<kn[n].priority;n++);kn.splice(n,0,e),n===0&&Cv(e)}};function Rf(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function ra(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function gh(){}function n1(e,t,n,r,i){if(i){if(typeof r=="function"){var o=r;r=function(){var u=_l(s);o.call(u)}}var s=Kg(t,r,e,0,null,!1,!1,"",gh);return e._reactRootContainer=s,e[dn]=s.current,So(e.nodeType===8?e.parentNode:e),wr(),s}for(;i=e.lastChild;)e.removeChild(i);if(typeof r=="function"){var l=r;r=function(){var u=_l(a);l.call(u)}}var a=Nf(e,0,!1,null,null,!1,!1,"",gh);return e._reactRootContainer=a,e[dn]=a.current,So(e.nodeType===8?e.parentNode:e),wr(function(){ta(t,a,n,r)}),a}function ia(e,t,n,r,i){var o=n._reactRootContainer;if(o){var s=o;if(typeof i=="function"){var l=i;i=function(){var a=_l(s);l.call(a)}}ta(t,s,e,i)}else s=n1(n,t,e,i,r);return _l(s)}bv=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=Zi(t.pendingLanes);n!==0&&(Zc(t,n|1),He(t,ge()),!(Y&6)&&(vi=ge()+500,Xn()))}break;case 13:wr(function(){var r=hn(e,1);if(r!==null){var i=Me();_t(r,e,1,i)}}),jf(e,1)}};Jc=function(e){if(e.tag===13){var t=hn(e,134217728);if(t!==null){var n=Me();_t(t,e,134217728,n)}jf(e,134217728)}};Sv=function(e){if(e.tag===13){var t=zn(e),n=hn(e,t);if(n!==null){var r=Me();_t(n,e,t,r)}jf(e,t)}};Ev=function(){return q};Av=function(e,t){var n=q;try{return q=e,t()}finally{q=n}};Mu=function(e,t,n){switch(t){case"input":if(Ou(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 i=Ql(r);if(!i)throw Error(N(90));nv(r),Ou(r,i)}}}break;case"textarea":iv(e,n);break;case"select":t=n.value,t!=null&&Jr(e,!!n.multiple,t,!1)}};fv=Cf;dv=wr;var r1={usingClientEntryPoint:!1,Events:[$o,Vr,Ql,uv,cv,Cf]},Wi={findFiberByHostInstance:ar,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},i1={bundleType:Wi.bundleType,version:Wi.version,rendererPackageName:Wi.rendererPackageName,rendererConfig:Wi.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:yn.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=vv(e),e===null?null:e.stateNode},findFiberByHostInstance:Wi.findFiberByHostInstance||t1,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 _s=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!_s.isDisabled&&_s.supportsFiber)try{Wl=_s.inject(i1),Ut=_s}catch{}}et.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=r1;et.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Rf(t))throw Error(N(200));return e1(e,t,null,n)};et.createRoot=function(e,t){if(!Rf(e))throw Error(N(299));var n=!1,r="",i=Gg;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onRecoverableError!==void 0&&(i=t.onRecoverableError)),t=Nf(e,1,!1,null,null,n,!1,r,i),e[dn]=t.current,So(e.nodeType===8?e.parentNode:e),new Tf(t)};et.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(N(188)):(e=Object.keys(e).join(","),Error(N(268,e)));return e=vv(t),e=e===null?null:e.stateNode,e};et.flushSync=function(e){return wr(e)};et.hydrate=function(e,t,n){if(!ra(t))throw Error(N(200));return ia(null,e,t,!0,n)};et.hydrateRoot=function(e,t,n){if(!Rf(e))throw Error(N(405));var r=n!=null&&n.hydratedSources||null,i=!1,o="",s=Gg;if(n!=null&&(n.unstable_strictMode===!0&&(i=!0),n.identifierPrefix!==void 0&&(o=n.identifierPrefix),n.onRecoverableError!==void 0&&(s=n.onRecoverableError)),t=Kg(t,null,e,1,n??null,i,!1,o,s),e[dn]=t.current,So(e),r)for(e=0;e<r.length;e++)n=r[e],i=n._getVersion,i=i(n._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[n,i]:t.mutableSourceEagerHydrationData.push(n,i);return new na(t)};et.render=function(e,t,n){if(!ra(t))throw Error(N(200));return ia(null,e,t,!1,n)};et.unmountComponentAtNode=function(e){if(!ra(e))throw Error(N(40));return e._reactRootContainer?(wr(function(){ia(null,null,e,!1,function(){e._reactRootContainer=null,e[dn]=null})}),!0):!1};et.unstable_batchedUpdates=Cf;et.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!ra(n))throw Error(N(200));if(e==null||e._reactInternals===void 0)throw Error(N(38));return ia(e,t,n,!1,r)};et.version="18.3.1-next-f1338f8080-20240426";function Qg(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Qg)}catch(e){console.error(e)}}Qg(),Qp.exports=et;var Wo=Qp.exports;const o1=Fc(Wo);var mh=Wo;_u.createRoot=mh.createRoot,_u.hydrateRoot=mh.hydrateRoot;function Q(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];throw new Error(typeof e=="number"?"[MobX] minified error nr: "+e+(n.length?" "+n.map(String).join(","):"")+". Find the full error at: https://github.com/mobxjs/mobx/blob/main/packages/mobx/src/errors.ts":"[MobX] "+e)}var s1={};function oa(){return typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:s1}var Yg=Object.assign,bl=Object.getOwnPropertyDescriptor,$t=Object.defineProperty,Ho=Object.prototype,pc=[];Object.freeze(pc);var Xg={};Object.freeze(Xg);var l1=typeof Proxy<"u",a1=Object.toString();function Zg(){l1||Q("Proxy not available")}function Jg(e){var t=!1;return function(){if(!t)return t=!0,e.apply(this,arguments)}}var Xr=function(){};function At(e){return typeof e=="function"}function xr(e){var t=typeof e;switch(t){case"string":case"symbol":case"number":return!0}return!1}function sa(e){return e!==null&&typeof e=="object"}function vn(e){if(!sa(e))return!1;var t=Object.getPrototypeOf(e);if(t==null)return!0;var n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return typeof n=="function"&&n.toString()===a1}function qg(e){var t=e==null?void 0:e.constructor;return t?t.name==="GeneratorFunction"||t.displayName==="GeneratorFunction":!1}function Ko(e,t,n){$t(e,t,{enumerable:!1,writable:!0,configurable:!0,value:n})}function em(e,t,n){$t(e,t,{enumerable:!1,writable:!1,configurable:!0,value:n})}function Zn(e,t){var n="isMobX"+e;return t.prototype[n]=!0,function(r){return sa(r)&&r[n]===!0}}function Ai(e){return e!=null&&Object.prototype.toString.call(e)==="[object Map]"}function u1(e){var t=Object.getPrototypeOf(e),n=Object.getPrototypeOf(t),r=Object.getPrototypeOf(n);return r===null}function tn(e){return e!=null&&Object.prototype.toString.call(e)==="[object Set]"}var tm=typeof Object.getOwnPropertySymbols<"u";function c1(e){var t=Object.keys(e);if(!tm)return t;var n=Object.getOwnPropertySymbols(e);return n.length?[].concat(t,n.filter(function(r){return Ho.propertyIsEnumerable.call(e,r)})):t}var gi=typeof Reflect<"u"&&Reflect.ownKeys?Reflect.ownKeys:tm?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:Object.getOwnPropertyNames;function nm(e){return e===null?null:typeof e=="object"?""+e:e}function ln(e,t){return Ho.hasOwnProperty.call(e,t)}var f1=Object.getOwnPropertyDescriptors||function(t){var n={};return gi(t).forEach(function(r){n[r]=bl(t,r)}),n};function Qe(e,t){return!!(e&t)}function Ye(e,t,n){return n?e|=t:e&=~t,e}function yh(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function d1(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,p1(r.key),r)}}function Ci(e,t,n){return t&&d1(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Zr(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=v1(e))||t){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
41
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function _r(){return _r=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},_r.apply(null,arguments)}function rm(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,vc(e,t)}function vc(e,t){return vc=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,r){return n.__proto__=r,n},vc(e,t)}function h1(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function p1(e){var t=h1(e,"string");return typeof t=="symbol"?t:t+""}function v1(e,t){if(e){if(typeof e=="string")return yh(e,t);var n={}.toString.call(e).slice(8,-1);return n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set"?Array.from(e):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?yh(e,t):void 0}}var Ft=Symbol("mobx-stored-annotations");function Vt(e){function t(n,r){if(Qo(r))return e.decorate_20223_(n,r);Go(n,r,e)}return Object.assign(t,e)}function Go(e,t,n){ln(e,Ft)||Ko(e,Ft,_r({},e[Ft])),b1(n)||(e[Ft][t]=n)}function g1(e){return ln(e,Ft)||Ko(e,Ft,_r({},e[Ft])),e[Ft]}function Qo(e){return typeof e=="object"&&typeof e.kind=="string"}var $=Symbol("mobx administration"),Jn=function(){function e(n){n===void 0&&(n="Atom"),this.name_=void 0,this.flags_=0,this.observers_=new Set,this.lastAccessedBy_=0,this.lowestObserverState_=X.NOT_TRACKING_,this.onBOL=void 0,this.onBUOL=void 0,this.name_=n}var t=e.prototype;return t.onBO=function(){this.onBOL&&this.onBOL.forEach(function(r){return r()})},t.onBUO=function(){this.onBUOL&&this.onBUOL.forEach(function(r){return r()})},t.reportObserved=function(){return xm(this)},t.reportChanged=function(){ut(),_m(this),ct()},t.toString=function(){return this.name_},Ci(e,[{key:"isBeingObserved",get:function(){return Qe(this.flags_,e.isBeingObservedMask_)},set:function(r){this.flags_=Ye(this.flags_,e.isBeingObservedMask_,r)}},{key:"isPendingUnobservation",get:function(){return Qe(this.flags_,e.isPendingUnobservationMask_)},set:function(r){this.flags_=Ye(this.flags_,e.isPendingUnobservationMask_,r)}},{key:"diffValue",get:function(){return Qe(this.flags_,e.diffValueMask_)?1:0},set:function(r){this.flags_=Ye(this.flags_,e.diffValueMask_,r===1)}}])}();Jn.isBeingObservedMask_=1;Jn.isPendingUnobservationMask_=2;Jn.diffValueMask_=4;var Df=Zn("Atom",Jn);function im(e,t,n){t===void 0&&(t=Xr),n===void 0&&(n=Xr);var r=new Jn(e);return t!==Xr&&A_(r,t),n!==Xr&&km(r,n),r}function m1(e,t){return zm(e,t)}function y1(e,t){return Object.is?Object.is(e,t):e===t?e!==0||1/e===1/t:e!==e&&t!==t}var Sl={structural:m1,default:y1};function br(e,t,n){return zf(e)?e:Array.isArray(e)?U.array(e,{name:n}):vn(e)?U.object(e,void 0,{name:n}):Ai(e)?U.map(e,{name:n}):tn(e)?U.set(e,{name:n}):typeof e=="function"&&!mi(e)&&!Ro(e)?qg(e)?yi(e):To(n,e):e}function w1(e,t,n){if(e==null||es(e)||qo(e)||qn(e)||wt(e))return e;if(Array.isArray(e))return U.array(e,{name:n,deep:!1});if(vn(e))return U.object(e,void 0,{name:n,deep:!1});if(Ai(e))return U.map(e,{name:n,deep:!1});if(tn(e))return U.set(e,{name:n,deep:!1})}function la(e){return e}function x1(e,t){return zm(e,t)?t:e}var _1="override";function b1(e){return e.annotationType_===_1}function Yo(e,t){return{annotationType_:e,options_:t,make_:S1,extend_:E1,decorate_20223_:A1}}function S1(e,t,n,r){var i;if((i=this.options_)!=null&&i.bound)return this.extend_(e,t,n,!1)===null?0:1;if(r===e.target_)return this.extend_(e,t,n,!1)===null?0:2;if(mi(n.value))return 1;var o=om(e,this,t,n,!1);return $t(r,t,o),2}function E1(e,t,n,r){var i=om(e,this,t,n);return e.defineProperty_(t,i,r)}function A1(e,t){var n=t.kind,r=t.name,i=t.addInitializer,o=this,s=function(u){var c,f,d,p;return Sr((c=(f=o.options_)==null?void 0:f.name)!=null?c:r.toString(),u,(d=(p=o.options_)==null?void 0:p.autoAction)!=null?d:!1)};if(n=="field")return function(a){var u,c=a;return mi(c)||(c=s(c)),(u=o.options_)!=null&&u.bound&&(c=c.bind(this),c.isMobxAction=!0),c};if(n=="method"){var l;return mi(e)||(e=s(e)),(l=this.options_)!=null&&l.bound&&i(function(){var a=this,u=a[r].bind(a);u.isMobxAction=!0,a[r]=u}),e}Q("Cannot apply '"+o.annotationType_+"' to '"+String(r)+"' (kind: "+n+"):"+(`
42
+ '`+o.annotationType_+"' can only be used on properties with a function value."))}function C1(e,t,n,r){t.annotationType_,r.value}function om(e,t,n,r,i){var o,s,l,a,u,c,f;i===void 0&&(i=T.safeDescriptors),C1(e,t,n,r);var d=r.value;if((o=t.options_)!=null&&o.bound){var p;d=d.bind((p=e.proxy_)!=null?p:e.target_)}return{value:Sr((s=(l=t.options_)==null?void 0:l.name)!=null?s:n.toString(),d,(a=(u=t.options_)==null?void 0:u.autoAction)!=null?a:!1,(c=t.options_)!=null&&c.bound?(f=e.proxy_)!=null?f:e.target_:void 0),configurable:i?e.isPlainObject_:!0,enumerable:!1,writable:!i}}function sm(e,t){return{annotationType_:e,options_:t,make_:k1,extend_:O1,decorate_20223_:P1}}function k1(e,t,n,r){var i;if(r===e.target_)return this.extend_(e,t,n,!1)===null?0:2;if((i=this.options_)!=null&&i.bound&&(!ln(e.target_,t)||!Ro(e.target_[t]))&&this.extend_(e,t,n,!1)===null)return 0;if(Ro(n.value))return 1;var o=lm(e,this,t,n,!1,!1);return $t(r,t,o),2}function O1(e,t,n,r){var i,o=lm(e,this,t,n,(i=this.options_)==null?void 0:i.bound);return e.defineProperty_(t,o,r)}function P1(e,t){var n,r=t.name,i=t.addInitializer;return Ro(e)||(e=yi(e)),(n=this.options_)!=null&&n.bound&&i(function(){var o=this,s=o[r].bind(o);s.isMobXFlow=!0,o[r]=s}),e}function N1(e,t,n,r){t.annotationType_,r.value}function lm(e,t,n,r,i,o){o===void 0&&(o=T.safeDescriptors),N1(e,t,n,r);var s=r.value;if(Ro(s)||(s=yi(s)),i){var l;s=s.bind((l=e.proxy_)!=null?l:e.target_),s.isMobXFlow=!0}return{value:s,configurable:o?e.isPlainObject_:!0,enumerable:!1,writable:!o}}function Mf(e,t){return{annotationType_:e,options_:t,make_:j1,extend_:T1,decorate_20223_:R1}}function j1(e,t,n){return this.extend_(e,t,n,!1)===null?0:1}function T1(e,t,n,r){return D1(e,this,t,n),e.defineComputedProperty_(t,_r({},this.options_,{get:n.get,set:n.set}),r)}function R1(e,t){var n=this,r=t.name,i=t.addInitializer;return i(function(){var o=Pr(this)[$],s=_r({},n.options_,{get:e,context:this});s.name||(s.name="ObservableObject."+r.toString()),o.values_.set(r,new Ct(s))}),function(){return this[$].getObservablePropValue_(r)}}function D1(e,t,n,r){t.annotationType_,r.get}function aa(e,t){return{annotationType_:e,options_:t,make_:M1,extend_:L1,decorate_20223_:I1}}function M1(e,t,n){return this.extend_(e,t,n,!1)===null?0:1}function L1(e,t,n,r){var i,o;return F1(e,this),e.defineObservableProperty_(t,n.value,(i=(o=this.options_)==null?void 0:o.enhancer)!=null?i:br,r)}function I1(e,t){var n=this,r=t.kind,i=t.name,o=new WeakSet;function s(l,a){var u,c,f=Pr(l)[$],d=new Bn(a,(u=(c=n.options_)==null?void 0:c.enhancer)!=null?u:br,"ObservableObject."+i.toString(),!1);f.values_.set(i,d),o.add(l)}if(r=="accessor")return{get:function(){return o.has(this)||s(this,e.get.call(this)),this[$].getObservablePropValue_(i)},set:function(a){return o.has(this)||s(this,a),this[$].setObservablePropValue_(i,a)},init:function(a){return o.has(this)||s(this,a),a}}}function F1(e,t,n,r){t.annotationType_}var z1="true",U1=am();function am(e){return{annotationType_:z1,options_:e,make_:B1,extend_:$1,decorate_20223_:V1}}function B1(e,t,n,r){var i,o;if(n.get)return ne.make_(e,t,n,r);if(n.set){var s=mi(n.set)?n.set:Sr(t.toString(),n.set);return r===e.target_?e.defineProperty_(t,{configurable:T.safeDescriptors?e.isPlainObject_:!0,set:s})===null?0:2:($t(r,t,{configurable:!0,set:s}),2)}if(r!==e.target_&&typeof n.value=="function"){var l;if(qg(n.value)){var a,u=(a=this.options_)!=null&&a.autoBind?yi.bound:yi;return u.make_(e,t,n,r)}var c=(l=this.options_)!=null&&l.autoBind?To.bound:To;return c.make_(e,t,n,r)}var f=((i=this.options_)==null?void 0:i.deep)===!1?U.ref:U;if(typeof n.value=="function"&&(o=this.options_)!=null&&o.autoBind){var d;n.value=n.value.bind((d=e.proxy_)!=null?d:e.target_)}return f.make_(e,t,n,r)}function $1(e,t,n,r){var i,o;if(n.get)return ne.extend_(e,t,n,r);if(n.set)return e.defineProperty_(t,{configurable:T.safeDescriptors?e.isPlainObject_:!0,set:Sr(t.toString(),n.set)},r);if(typeof n.value=="function"&&(i=this.options_)!=null&&i.autoBind){var s;n.value=n.value.bind((s=e.proxy_)!=null?s:e.target_)}var l=((o=this.options_)==null?void 0:o.deep)===!1?U.ref:U;return l.extend_(e,t,n,r)}function V1(e,t){Q("'"+this.annotationType_+"' cannot be used as a decorator")}var W1="observable",H1="observable.ref",K1="observable.shallow",G1="observable.struct",um={deep:!0,name:void 0,defaultDecorator:void 0,proxy:!0};Object.freeze(um);function bs(e){return e||um}var gc=aa(W1),Q1=aa(H1,{enhancer:la}),Y1=aa(K1,{enhancer:w1}),X1=aa(G1,{enhancer:x1}),cm=Vt(gc);function Ss(e){return e.deep===!0?br:e.deep===!1?la:J1(e.defaultDecorator)}function Z1(e){var t;return e?(t=e.defaultDecorator)!=null?t:am(e):void 0}function J1(e){var t,n;return e&&(t=(n=e.options_)==null?void 0:n.enhancer)!=null?t:br}function fm(e,t,n){if(Qo(t))return gc.decorate_20223_(e,t);if(xr(t)){Go(e,t,gc);return}return zf(e)?e:vn(e)?U.object(e,t,n):Array.isArray(e)?U.array(e,t):Ai(e)?U.map(e,t):tn(e)?U.set(e,t):typeof e=="object"&&e!==null?e:U.box(e,t)}Yg(fm,cm);var q1={box:function(t,n){var r=bs(n);return new Bn(t,Ss(r),r.name,!0,r.equals)},array:function(t,n){var r=bs(n);return(T.useProxies===!1||r.proxy===!1?Y_:z_)(t,Ss(r),r.name)},map:function(t,n){var r=bs(n);return new Rm(t,Ss(r),r.name)},set:function(t,n){var r=bs(n);return new Dm(t,Ss(r),r.name)},object:function(t,n,r){return er(function(){return Pm(T.useProxies===!1||(r==null?void 0:r.proxy)===!1?Pr({},r):L_({},r),t,n)})},ref:Vt(Q1),shallow:Vt(Y1),deep:cm,struct:Vt(X1)},U=Yg(fm,q1),dm="computed",e_="computed.struct",mc=Mf(dm),t_=Mf(e_,{equals:Sl.structural}),ne=function(t,n){if(Qo(n))return mc.decorate_20223_(t,n);if(xr(n))return Go(t,n,mc);if(vn(t))return Vt(Mf(dm,t));var r=vn(n)?n:{};return r.get=t,r.name||(r.name=t.name||""),new Ct(r)};Object.assign(ne,mc);ne.struct=Vt(t_);var wh,xh,El=0,n_=1,r_=(wh=(xh=bl(function(){},"name"))==null?void 0:xh.configurable)!=null?wh:!1,_h={value:"action",configurable:!0,writable:!1,enumerable:!1};function Sr(e,t,n,r){n===void 0&&(n=!1);function i(){return hm(e,n,t,r||this,arguments)}return i.isMobxAction=!0,i.toString=function(){return t.toString()},r_&&(_h.value=e,$t(i,"name",_h)),i}function hm(e,t,n,r,i){var o=i_(e,t);try{return n.apply(r,i)}catch(s){throw o.error_=s,s}finally{o_(o)}}function i_(e,t,n,r){var i=!1,o=0,s=T.trackingDerivation,l=!t||!s;ut();var a=T.allowStateChanges;l&&(Or(),a=Lf(!0));var u=Ff(!0),c={runAsAction_:l,prevDerivation_:s,prevAllowStateChanges_:a,prevAllowStateReads_:u,notifySpy_:i,startTime_:o,actionId_:n_++,parentActionId_:El};return El=c.actionId_,c}function o_(e){El!==e.actionId_&&Q(30),El=e.parentActionId_,e.error_!==void 0&&(T.suppressReactionErrors=!0),If(e.prevAllowStateChanges_),uo(e.prevAllowStateReads_),ct(),e.runAsAction_&&an(e.prevDerivation_),T.suppressReactionErrors=!1}function Lf(e){var t=T.allowStateChanges;return T.allowStateChanges=e,t}function If(e){T.allowStateChanges=e}var Bn=function(e){function t(r,i,o,s,l){var a;return o===void 0&&(o="ObservableValue"),l===void 0&&(l=Sl.default),a=e.call(this,o)||this,a.enhancer=void 0,a.name_=void 0,a.equals=void 0,a.hasUnreportedChange_=!1,a.interceptors_=void 0,a.changeListeners_=void 0,a.value_=void 0,a.dehancer=void 0,a.enhancer=i,a.name_=o,a.equals=l,a.value_=i(r,void 0,o),a}rm(t,e);var n=t.prototype;return n.dehanceValue=function(i){return this.dehancer!==void 0?this.dehancer(i):i},n.set=function(i){this.value_,i=this.prepareNewValue_(i),i!==T.UNCHANGED&&this.setNewValue_(i)},n.prepareNewValue_=function(i){if(st(this)){var o=lt(this,{object:this,type:Wt,newValue:i});if(!o)return T.UNCHANGED;i=o.newValue}return i=this.enhancer(i,this.value_,this.name_),this.equals(this.value_,i)?T.UNCHANGED:i},n.setNewValue_=function(i){var o=this.value_;this.value_=i,this.reportChanged(),bt(this)&&St(this,{type:Wt,object:this,newValue:i,oldValue:o})},n.get=function(){return this.reportObserved(),this.dehanceValue(this.value_)},n.intercept_=function(i){return Zo(this,i)},n.observe_=function(i,o){return o&&i({observableKind:"value",debugObjectName:this.name_,object:this,type:Wt,newValue:this.value_,oldValue:void 0}),Jo(this,i)},n.raw=function(){return this.value_},n.toJSON=function(){return this.get()},n.toString=function(){return this.name_+"["+this.value_+"]"},n.valueOf=function(){return nm(this.get())},n[Symbol.toPrimitive]=function(){return this.valueOf()},t}(Jn),s_=Zn("ObservableValue",Bn),Ct=function(){function e(n){this.dependenciesState_=X.NOT_TRACKING_,this.observing_=[],this.newObserving_=null,this.observers_=new Set,this.runId_=0,this.lastAccessedBy_=0,this.lowestObserverState_=X.UP_TO_DATE_,this.unboundDepsCount_=0,this.value_=new Cl(null),this.name_=void 0,this.triggeredBy_=void 0,this.flags_=0,this.derivation=void 0,this.setter_=void 0,this.isTracing_=Al.NONE,this.scope_=void 0,this.equals_=void 0,this.requiresReaction_=void 0,this.keepAlive_=void 0,this.onBOL=void 0,this.onBUOL=void 0,n.get||Q(31),this.derivation=n.get,this.name_=n.name||"ComputedValue",n.set&&(this.setter_=Sr("ComputedValue-setter",n.set)),this.equals_=n.equals||(n.compareStructural||n.struct?Sl.structural:Sl.default),this.scope_=n.context,this.requiresReaction_=n.requiresReaction,this.keepAlive_=!!n.keepAlive}var t=e.prototype;return t.onBecomeStale_=function(){f_(this)},t.onBO=function(){this.onBOL&&this.onBOL.forEach(function(r){return r()})},t.onBUO=function(){this.onBUOL&&this.onBUOL.forEach(function(r){return r()})},t.get=function(){if(this.isComputing&&Q(32,this.name_,this.derivation),T.inBatch===0&&this.observers_.size===0&&!this.keepAlive_)yc(this)&&(this.warnAboutUntrackedRead_(),ut(),this.value_=this.computeValue_(!1),ct());else if(xm(this),yc(this)){var r=T.trackingContext;this.keepAlive_&&!r&&(T.trackingContext=this),this.trackAndCompute()&&c_(this),T.trackingContext=r}var i=this.value_;if(Ks(i))throw i.cause;return i},t.set=function(r){if(this.setter_){this.isRunningSetter&&Q(33,this.name_),this.isRunningSetter=!0;try{this.setter_.call(this.scope_,r)}finally{this.isRunningSetter=!1}}else Q(34,this.name_)},t.trackAndCompute=function(){var r=this.value_,i=this.dependenciesState_===X.NOT_TRACKING_,o=this.computeValue_(!0),s=i||Ks(r)||Ks(o)||!this.equals_(r,o);return s&&(this.value_=o),s},t.computeValue_=function(r){this.isComputing=!0;var i=Lf(!1),o;if(r)o=pm(this,this.derivation,this.scope_);else if(T.disableErrorBoundaries===!0)o=this.derivation.call(this.scope_);else try{o=this.derivation.call(this.scope_)}catch(s){o=new Cl(s)}return If(i),this.isComputing=!1,o},t.suspend_=function(){this.keepAlive_||(wc(this),this.value_=void 0)},t.observe_=function(r,i){var o=this,s=!0,l=void 0;return x_(function(){var a=o.get();if(!s||i){var u=Or();r({observableKind:"computed",debugObjectName:o.name_,type:Wt,object:o,newValue:a,oldValue:l}),an(u)}s=!1,l=a})},t.warnAboutUntrackedRead_=function(){},t.toString=function(){return this.name_+"["+this.derivation.toString()+"]"},t.valueOf=function(){return nm(this.get())},t[Symbol.toPrimitive]=function(){return this.valueOf()},Ci(e,[{key:"isComputing",get:function(){return Qe(this.flags_,e.isComputingMask_)},set:function(r){this.flags_=Ye(this.flags_,e.isComputingMask_,r)}},{key:"isRunningSetter",get:function(){return Qe(this.flags_,e.isRunningSetterMask_)},set:function(r){this.flags_=Ye(this.flags_,e.isRunningSetterMask_,r)}},{key:"isBeingObserved",get:function(){return Qe(this.flags_,e.isBeingObservedMask_)},set:function(r){this.flags_=Ye(this.flags_,e.isBeingObservedMask_,r)}},{key:"isPendingUnobservation",get:function(){return Qe(this.flags_,e.isPendingUnobservationMask_)},set:function(r){this.flags_=Ye(this.flags_,e.isPendingUnobservationMask_,r)}},{key:"diffValue",get:function(){return Qe(this.flags_,e.diffValueMask_)?1:0},set:function(r){this.flags_=Ye(this.flags_,e.diffValueMask_,r===1)}}])}();Ct.isComputingMask_=1;Ct.isRunningSetterMask_=2;Ct.isBeingObservedMask_=4;Ct.isPendingUnobservationMask_=8;Ct.diffValueMask_=16;var Xo=Zn("ComputedValue",Ct),X;(function(e){e[e.NOT_TRACKING_=-1]="NOT_TRACKING_",e[e.UP_TO_DATE_=0]="UP_TO_DATE_",e[e.POSSIBLY_STALE_=1]="POSSIBLY_STALE_",e[e.STALE_=2]="STALE_"})(X||(X={}));var Al;(function(e){e[e.NONE=0]="NONE",e[e.LOG=1]="LOG",e[e.BREAK=2]="BREAK"})(Al||(Al={}));var Cl=function(t){this.cause=void 0,this.cause=t};function Ks(e){return e instanceof Cl}function yc(e){switch(e.dependenciesState_){case X.UP_TO_DATE_:return!1;case X.NOT_TRACKING_:case X.STALE_:return!0;case X.POSSIBLY_STALE_:{for(var t=Ff(!0),n=Or(),r=e.observing_,i=r.length,o=0;o<i;o++){var s=r[o];if(Xo(s)){if(T.disableErrorBoundaries)s.get();else try{s.get()}catch{return an(n),uo(t),!0}if(e.dependenciesState_===X.STALE_)return an(n),uo(t),!0}}return gm(e),an(n),uo(t),!1}}}function pm(e,t,n){var r=Ff(!0);gm(e),e.newObserving_=new Array(e.runId_===0?100:e.observing_.length),e.unboundDepsCount_=0,e.runId_=++T.runId;var i=T.trackingDerivation;T.trackingDerivation=e,T.inBatch++;var o;if(T.disableErrorBoundaries===!0)o=t.call(n);else try{o=t.call(n)}catch(s){o=new Cl(s)}return T.inBatch--,T.trackingDerivation=i,l_(e),uo(r),o}function l_(e){for(var t=e.observing_,n=e.observing_=e.newObserving_,r=X.UP_TO_DATE_,i=0,o=e.unboundDepsCount_,s=0;s<o;s++){var l=n[s];l.diffValue===0&&(l.diffValue=1,i!==s&&(n[i]=l),i++),l.dependenciesState_>r&&(r=l.dependenciesState_)}for(n.length=i,e.newObserving_=null,o=t.length;o--;){var a=t[o];a.diffValue===0&&ym(a,e),a.diffValue=0}for(;i--;){var u=n[i];u.diffValue===1&&(u.diffValue=0,u_(u,e))}r!==X.UP_TO_DATE_&&(e.dependenciesState_=r,e.onBecomeStale_())}function wc(e){var t=e.observing_;e.observing_=[];for(var n=t.length;n--;)ym(t[n],e);e.dependenciesState_=X.NOT_TRACKING_}function vm(e){var t=Or();try{return e()}finally{an(t)}}function Or(){var e=T.trackingDerivation;return T.trackingDerivation=null,e}function an(e){T.trackingDerivation=e}function Ff(e){var t=T.allowStateReads;return T.allowStateReads=e,t}function uo(e){T.allowStateReads=e}function gm(e){if(e.dependenciesState_!==X.UP_TO_DATE_){e.dependenciesState_=X.UP_TO_DATE_;for(var t=e.observing_,n=t.length;n--;)t[n].lowestObserverState_=X.UP_TO_DATE_}}var Gs=function(){this.version=6,this.UNCHANGED={},this.trackingDerivation=null,this.trackingContext=null,this.runId=0,this.mobxGuid=0,this.inBatch=0,this.pendingUnobservations=[],this.pendingReactions=[],this.isRunningReactions=!1,this.allowStateChanges=!1,this.allowStateReads=!0,this.enforceActions=!0,this.spyListeners=[],this.globalReactionErrorHandlers=[],this.computedRequiresReaction=!1,this.reactionRequiresObservable=!1,this.observableRequiresReaction=!1,this.disableErrorBoundaries=!1,this.suppressReactionErrors=!1,this.useProxies=!0,this.verifyProxies=!1,this.safeDescriptors=!0},Qs=!0,mm=!1,T=function(){var e=oa();return e.__mobxInstanceCount>0&&!e.__mobxGlobals&&(Qs=!1),e.__mobxGlobals&&e.__mobxGlobals.version!==new Gs().version&&(Qs=!1),Qs?e.__mobxGlobals?(e.__mobxInstanceCount+=1,e.__mobxGlobals.UNCHANGED||(e.__mobxGlobals.UNCHANGED={}),e.__mobxGlobals):(e.__mobxInstanceCount=1,e.__mobxGlobals=new Gs):(setTimeout(function(){mm||Q(35)},1),new Gs)}();function a_(){if((T.pendingReactions.length||T.inBatch||T.isRunningReactions)&&Q(36),mm=!0,Qs){var e=oa();--e.__mobxInstanceCount===0&&(e.__mobxGlobals=void 0),T=new Gs}}function u_(e,t){e.observers_.add(t),e.lowestObserverState_>t.dependenciesState_&&(e.lowestObserverState_=t.dependenciesState_)}function ym(e,t){e.observers_.delete(t),e.observers_.size===0&&wm(e)}function wm(e){e.isPendingUnobservation===!1&&(e.isPendingUnobservation=!0,T.pendingUnobservations.push(e))}function ut(){T.inBatch++}function ct(){if(--T.inBatch===0){bm();for(var e=T.pendingUnobservations,t=0;t<e.length;t++){var n=e[t];n.isPendingUnobservation=!1,n.observers_.size===0&&(n.isBeingObserved&&(n.isBeingObserved=!1,n.onBUO()),n instanceof Ct&&n.suspend_())}T.pendingUnobservations=[]}}function xm(e){var t=T.trackingDerivation;return t!==null?(t.runId_!==e.lastAccessedBy_&&(e.lastAccessedBy_=t.runId_,t.newObserving_[t.unboundDepsCount_++]=e,!e.isBeingObserved&&T.trackingContext&&(e.isBeingObserved=!0,e.onBO())),e.isBeingObserved):(e.observers_.size===0&&T.inBatch>0&&wm(e),!1)}function _m(e){e.lowestObserverState_!==X.STALE_&&(e.lowestObserverState_=X.STALE_,e.observers_.forEach(function(t){t.dependenciesState_===X.UP_TO_DATE_&&t.onBecomeStale_(),t.dependenciesState_=X.STALE_}))}function c_(e){e.lowestObserverState_!==X.STALE_&&(e.lowestObserverState_=X.STALE_,e.observers_.forEach(function(t){t.dependenciesState_===X.POSSIBLY_STALE_?t.dependenciesState_=X.STALE_:t.dependenciesState_===X.UP_TO_DATE_&&(e.lowestObserverState_=X.UP_TO_DATE_)}))}function f_(e){e.lowestObserverState_===X.UP_TO_DATE_&&(e.lowestObserverState_=X.POSSIBLY_STALE_,e.observers_.forEach(function(t){t.dependenciesState_===X.UP_TO_DATE_&&(t.dependenciesState_=X.POSSIBLY_STALE_,t.onBecomeStale_())}))}var Kt=function(){function e(n,r,i,o){n===void 0&&(n="Reaction"),this.name_=void 0,this.onInvalidate_=void 0,this.errorHandler_=void 0,this.requiresObservable_=void 0,this.observing_=[],this.newObserving_=[],this.dependenciesState_=X.NOT_TRACKING_,this.runId_=0,this.unboundDepsCount_=0,this.flags_=0,this.isTracing_=Al.NONE,this.name_=n,this.onInvalidate_=r,this.errorHandler_=i,this.requiresObservable_=o}var t=e.prototype;return t.onBecomeStale_=function(){this.schedule_()},t.schedule_=function(){this.isScheduled||(this.isScheduled=!0,T.pendingReactions.push(this),bm())},t.runReaction_=function(){if(!this.isDisposed){ut(),this.isScheduled=!1;var r=T.trackingContext;if(T.trackingContext=this,yc(this)){this.isTrackPending=!0;try{this.onInvalidate_()}catch(i){this.reportExceptionInDerivation_(i)}}T.trackingContext=r,ct()}},t.track=function(r){if(!this.isDisposed){ut(),this.isRunning=!0;var i=T.trackingContext;T.trackingContext=this;var o=pm(this,r,void 0);T.trackingContext=i,this.isRunning=!1,this.isTrackPending=!1,this.isDisposed&&wc(this),Ks(o)&&this.reportExceptionInDerivation_(o.cause),ct()}},t.reportExceptionInDerivation_=function(r){var i=this;if(this.errorHandler_){this.errorHandler_(r,this);return}if(T.disableErrorBoundaries)throw r;var o="[mobx] uncaught error in '"+this+"'";T.suppressReactionErrors||console.error(o,r),T.globalReactionErrorHandlers.forEach(function(s){return s(r,i)})},t.dispose=function(){this.isDisposed||(this.isDisposed=!0,this.isRunning||(ut(),wc(this),ct()))},t.getDisposer_=function(r){var i=this,o=function s(){i.dispose(),r==null||r.removeEventListener==null||r.removeEventListener("abort",s)};return r==null||r.addEventListener==null||r.addEventListener("abort",o),o[$]=this,"dispose"in Symbol&&typeof Symbol.dispose=="symbol"&&(o[Symbol.dispose]=o),o},t.toString=function(){return"Reaction["+this.name_+"]"},t.trace=function(r){},Ci(e,[{key:"isDisposed",get:function(){return Qe(this.flags_,e.isDisposedMask_)},set:function(r){this.flags_=Ye(this.flags_,e.isDisposedMask_,r)}},{key:"isScheduled",get:function(){return Qe(this.flags_,e.isScheduledMask_)},set:function(r){this.flags_=Ye(this.flags_,e.isScheduledMask_,r)}},{key:"isTrackPending",get:function(){return Qe(this.flags_,e.isTrackPendingMask_)},set:function(r){this.flags_=Ye(this.flags_,e.isTrackPendingMask_,r)}},{key:"isRunning",get:function(){return Qe(this.flags_,e.isRunningMask_)},set:function(r){this.flags_=Ye(this.flags_,e.isRunningMask_,r)}},{key:"diffValue",get:function(){return Qe(this.flags_,e.diffValueMask_)?1:0},set:function(r){this.flags_=Ye(this.flags_,e.diffValueMask_,r===1)}}])}();Kt.isDisposedMask_=1;Kt.isScheduledMask_=2;Kt.isTrackPendingMask_=4;Kt.isRunningMask_=8;Kt.diffValueMask_=16;var d_=100,xc=function(t){return t()};function bm(){T.inBatch>0||T.isRunningReactions||xc(h_)}function h_(){T.isRunningReactions=!0;for(var e=T.pendingReactions,t=0;e.length>0;){++t===d_&&(console.error("[mobx] cycle in reaction: "+e[0]),e.splice(0));for(var n=e.splice(0),r=0,i=n.length;r<i;r++)n[r].runReaction_()}T.isRunningReactions=!1}var kl=Zn("Reaction",Kt);function p_(e){var t=xc;xc=function(r){return e(function(){return t(r)})}}function co(){return!1}function v_(e){return console.warn("[mobx.spy] Is a no-op in production builds"),function(){}}var Sm="action",g_="action.bound",Em="autoAction",m_="autoAction.bound",Am="<unnamed action>",_c=Yo(Sm),y_=Yo(g_,{bound:!0}),bc=Yo(Em,{autoAction:!0}),w_=Yo(m_,{autoAction:!0,bound:!0});function Cm(e){var t=function(r,i){if(At(r))return Sr(r.name||Am,r,e);if(At(i))return Sr(r,i,e);if(Qo(i))return(e?bc:_c).decorate_20223_(r,i);if(xr(i))return Go(r,i,e?bc:_c);if(xr(r))return Vt(Yo(e?Em:Sm,{name:r,autoAction:e}))};return t}var te=Cm(!1);Object.assign(te,_c);var To=Cm(!0);Object.assign(To,bc);te.bound=Vt(y_);To.bound=Vt(w_);function jn(e){return hm(e.name||Am,!1,e,this,void 0)}function mi(e){return At(e)&&e.isMobxAction===!0}function x_(e,t){var n,r,i,o;t===void 0&&(t=Xg);var s=(n=(r=t)==null?void 0:r.name)!=null?n:"Autorun",l=!t.scheduler&&!t.delay,a;if(l)a=new Kt(s,function(){this.track(f)},t.onError,t.requiresObservable);else{var u=b_(t),c=!1;a=new Kt(s,function(){c||(c=!0,u(function(){c=!1,a.isDisposed||a.track(f)}))},t.onError,t.requiresObservable)}function f(){e(a)}return(i=t)!=null&&(i=i.signal)!=null&&i.aborted||a.schedule_(),a.getDisposer_((o=t)==null?void 0:o.signal)}var __=function(t){return t()};function b_(e){return e.scheduler?e.scheduler:e.delay?function(t){return setTimeout(t,e.delay)}:__}var S_="onBO",E_="onBUO";function A_(e,t,n){return Om(S_,e,t,n)}function km(e,t,n){return Om(E_,e,t,n)}function Om(e,t,n,r){var i=Nl(t),o=At(r)?r:n,s=e+"L";return i[s]?i[s].add(o):i[s]=new Set([o]),function(){var l=i[s];l&&(l.delete(o),l.size===0&&delete i[s])}}var C_="never",Es="always",k_="observed";function O_(e){e.isolateGlobalState===!0&&a_();var t=e.useProxies,n=e.enforceActions;if(t!==void 0&&(T.useProxies=t===Es?!0:t===C_?!1:typeof Proxy<"u"),t==="ifavailable"&&(T.verifyProxies=!0),n!==void 0){var r=n===Es?Es:n===k_;T.enforceActions=r,T.allowStateChanges=!(r===!0||r===Es)}["computedRequiresReaction","reactionRequiresObservable","observableRequiresReaction","disableErrorBoundaries","safeDescriptors"].forEach(function(i){i in e&&(T[i]=!!e[i])}),T.allowStateReads=!T.observableRequiresReaction,e.reactionScheduler&&p_(e.reactionScheduler)}function Pm(e,t,n,r){var i=f1(t);return er(function(){var o=Pr(e,r)[$];gi(i).forEach(function(s){o.extend_(s,i[s],n&&s in n?n[s]:!0)})}),e}function P_(e,t){return Nm(Nl(e,t))}function Nm(e){var t={name:e.name_};return e.observing_&&e.observing_.length>0&&(t.dependencies=N_(e.observing_).map(Nm)),t}function N_(e){return Array.from(new Set(e))}var j_=0;function jm(){this.message="FLOW_CANCELLED"}jm.prototype=Object.create(Error.prototype);var qa=sm("flow"),T_=sm("flow.bound",{bound:!0}),yi=Object.assign(function(t,n){if(Qo(n))return qa.decorate_20223_(t,n);if(xr(n))return Go(t,n,qa);var r=t,i=r.name||"<unnamed flow>",o=function(){var l=this,a=arguments,u=++j_,c=te(i+" - runid: "+u+" - init",r).apply(l,a),f,d=void 0,p=new Promise(function(y,m){var b=0;f=m;function v(_){d=void 0;var S;try{S=te(i+" - runid: "+u+" - yield "+b++,c.next).call(c,_)}catch(E){return m(E)}w(S)}function g(_){d=void 0;var S;try{S=te(i+" - runid: "+u+" - yield "+b++,c.throw).call(c,_)}catch(E){return m(E)}w(S)}function w(_){if(At(_==null?void 0:_.then)){_.then(w,m);return}return _.done?y(_.value):(d=Promise.resolve(_.value),d.then(v,g))}v(void 0)});return p.cancel=te(i+" - runid: "+u+" - cancel",function(){try{d&&bh(d);var y=c.return(void 0),m=Promise.resolve(y.value);m.then(Xr,Xr),bh(m),f(new jm)}catch(b){f(b)}}),p};return o.isMobXFlow=!0,o},qa);yi.bound=Vt(T_);function bh(e){At(e.cancel)&&e.cancel()}function Ro(e){return(e==null?void 0:e.isMobXFlow)===!0}function R_(e,t){return e?es(e)||!!e[$]||Df(e)||kl(e)||Xo(e):!1}function zf(e){return R_(e)}function D_(e){if(es(e))return e[$].ownKeys_();Q(38)}function As(e,t,n){return e.set(t,n),n}function Ir(e,t){if(e==null||typeof e!="object"||e instanceof Date||!zf(e))return e;if(s_(e)||Xo(e))return Ir(e.get(),t);if(t.has(e))return t.get(e);if(qo(e)){var n=As(t,e,new Array(e.length));return e.forEach(function(s,l){n[l]=Ir(s,t)}),n}if(wt(e)){var r=As(t,e,new Set);return e.forEach(function(s){r.add(Ir(s,t))}),r}if(qn(e)){var i=As(t,e,new Map);return e.forEach(function(s,l){i.set(l,Ir(s,t))}),i}else{var o=As(t,e,{});return D_(e).forEach(function(s){Ho.propertyIsEnumerable.call(e,s)&&(o[s]=Ir(e[s],t))}),o}}function Sh(e,t){return Ir(e,new Map)}function nn(e,t){t===void 0&&(t=void 0),ut();try{return e.apply(t)}finally{ct()}}function Rr(e){return e[$]}var M_={has:function(t,n){return Rr(t).has_(n)},get:function(t,n){return Rr(t).get_(n)},set:function(t,n,r){var i;return xr(n)?(i=Rr(t).set_(n,r,!0))!=null?i:!0:!1},deleteProperty:function(t,n){var r;return xr(n)?(r=Rr(t).delete_(n,!0))!=null?r:!0:!1},defineProperty:function(t,n,r){var i;return(i=Rr(t).defineProperty_(n,r))!=null?i:!0},ownKeys:function(t){return Rr(t).ownKeys_()},preventExtensions:function(t){Q(13)}};function L_(e,t){var n,r;return Zg(),e=Pr(e,t),(r=(n=e[$]).proxy_)!=null?r:n.proxy_=new Proxy(e,M_)}function st(e){return e.interceptors_!==void 0&&e.interceptors_.length>0}function Zo(e,t){var n=e.interceptors_||(e.interceptors_=[]);return n.push(t),Jg(function(){var r=n.indexOf(t);r!==-1&&n.splice(r,1)})}function lt(e,t){var n=Or();try{for(var r=[].concat(e.interceptors_||[]),i=0,o=r.length;i<o&&(t=r[i](t),t&&!t.type&&Q(14),!!t);i++);return t}finally{an(n)}}function bt(e){return e.changeListeners_!==void 0&&e.changeListeners_.length>0}function Jo(e,t){var n=e.changeListeners_||(e.changeListeners_=[]);return n.push(t),Jg(function(){var r=n.indexOf(t);r!==-1&&n.splice(r,1)})}function St(e,t){var n=Or(),r=e.changeListeners_;if(r){r=r.slice();for(var i=0,o=r.length;i<o;i++)r[i](t);an(n)}}function ua(e,t,n){return er(function(){var r,i=Pr(e,n)[$];(r=t)!=null||(t=g1(e)),gi(t).forEach(function(o){return i.make_(o,t[o])})}),e}var eu=Symbol("mobx-keys");function Uf(e,t,n){return vn(e)?Pm(e,e,t,n):(er(function(){var r=Pr(e,n)[$];if(!e[eu]){var i=Object.getPrototypeOf(e),o=new Set([].concat(gi(e),gi(i)));o.delete("constructor"),o.delete($),Ko(i,eu,o)}e[eu].forEach(function(s){return r.make_(s,t&&s in t?t[s]:!0)})}),e)}var Eh="splice",Wt="update",I_=1e4,F_={get:function(t,n){var r=t[$];return n===$?r:n==="length"?r.getArrayLength_():typeof n=="string"&&!isNaN(n)?r.get_(parseInt(n)):ln(Ol,n)?Ol[n]:t[n]},set:function(t,n,r){var i=t[$];return n==="length"&&i.setArrayLength_(r),typeof n=="symbol"||isNaN(n)?t[n]=r:i.set_(parseInt(n),r),!0},preventExtensions:function(){Q(15)}},Bf=function(){function e(n,r,i,o){n===void 0&&(n="ObservableArray"),this.owned_=void 0,this.legacyMode_=void 0,this.atom_=void 0,this.values_=[],this.interceptors_=void 0,this.changeListeners_=void 0,this.enhancer_=void 0,this.dehancer=void 0,this.proxy_=void 0,this.lastKnownLength_=0,this.owned_=i,this.legacyMode_=o,this.atom_=new Jn(n),this.enhancer_=function(s,l){return r(s,l,"ObservableArray[..]")}}var t=e.prototype;return t.dehanceValue_=function(r){return this.dehancer!==void 0?this.dehancer(r):r},t.dehanceValues_=function(r){return this.dehancer!==void 0&&r.length>0?r.map(this.dehancer):r},t.intercept_=function(r){return Zo(this,r)},t.observe_=function(r,i){return i===void 0&&(i=!1),i&&r({observableKind:"array",object:this.proxy_,debugObjectName:this.atom_.name_,type:"splice",index:0,added:this.values_.slice(),addedCount:this.values_.length,removed:[],removedCount:0}),Jo(this,r)},t.getArrayLength_=function(){return this.atom_.reportObserved(),this.values_.length},t.setArrayLength_=function(r){(typeof r!="number"||isNaN(r)||r<0)&&Q("Out of range: "+r);var i=this.values_.length;if(r!==i)if(r>i){for(var o=new Array(r-i),s=0;s<r-i;s++)o[s]=void 0;this.spliceWithArray_(i,0,o)}else this.spliceWithArray_(r,i-r)},t.updateArrayLength_=function(r,i){r!==this.lastKnownLength_&&Q(16),this.lastKnownLength_+=i,this.legacyMode_&&i>0&&Fm(r+i+1)},t.spliceWithArray_=function(r,i,o){var s=this;this.atom_;var l=this.values_.length;if(r===void 0?r=0:r>l?r=l:r<0&&(r=Math.max(0,l+r)),arguments.length===1?i=l-r:i==null?i=0:i=Math.max(0,Math.min(i,l-r)),o===void 0&&(o=pc),st(this)){var a=lt(this,{object:this.proxy_,type:Eh,index:r,removedCount:i,added:o});if(!a)return pc;i=a.removedCount,o=a.added}if(o=o.length===0?o:o.map(function(f){return s.enhancer_(f,void 0)}),this.legacyMode_){var u=o.length-i;this.updateArrayLength_(l,u)}var c=this.spliceItemsIntoValues_(r,i,o);return(i!==0||o.length!==0)&&this.notifyArraySplice_(r,o,c),this.dehanceValues_(c)},t.spliceItemsIntoValues_=function(r,i,o){if(o.length<I_){var s;return(s=this.values_).splice.apply(s,[r,i].concat(o))}else{var l=this.values_.slice(r,r+i),a=this.values_.slice(r+i);this.values_.length+=o.length-i;for(var u=0;u<o.length;u++)this.values_[r+u]=o[u];for(var c=0;c<a.length;c++)this.values_[r+o.length+c]=a[c];return l}},t.notifyArrayChildUpdate_=function(r,i,o){var s=!this.owned_&&co(),l=bt(this),a=l||s?{observableKind:"array",object:this.proxy_,type:Wt,debugObjectName:this.atom_.name_,index:r,newValue:i,oldValue:o}:null;this.atom_.reportChanged(),l&&St(this,a)},t.notifyArraySplice_=function(r,i,o){var s=!this.owned_&&co(),l=bt(this),a=l||s?{observableKind:"array",object:this.proxy_,debugObjectName:this.atom_.name_,type:Eh,index:r,removed:o,added:i,removedCount:o.length,addedCount:i.length}:null;this.atom_.reportChanged(),l&&St(this,a)},t.get_=function(r){if(this.legacyMode_&&r>=this.values_.length){console.warn("[mobx] Out of bounds read: "+r);return}return this.atom_.reportObserved(),this.dehanceValue_(this.values_[r])},t.set_=function(r,i){var o=this.values_;if(this.legacyMode_&&r>o.length&&Q(17,r,o.length),r<o.length){this.atom_;var s=o[r];if(st(this)){var l=lt(this,{type:Wt,object:this.proxy_,index:r,newValue:i});if(!l)return;i=l.newValue}i=this.enhancer_(i,s);var a=i!==s;a&&(o[r]=i,this.notifyArrayChildUpdate_(r,i,s))}else{for(var u=new Array(r+1-o.length),c=0;c<u.length-1;c++)u[c]=void 0;u[u.length-1]=i,this.spliceWithArray_(o.length,0,u)}},e}();function z_(e,t,n,r){return n===void 0&&(n="ObservableArray"),r===void 0&&(r=!1),Zg(),er(function(){var i=new Bf(n,t,r,!1);em(i.values_,$,i);var o=new Proxy(i.values_,F_);return i.proxy_=o,e&&e.length&&i.spliceWithArray_(0,0,e),o})}var Ol={clear:function(){return this.splice(0)},replace:function(t){var n=this[$];return n.spliceWithArray_(0,n.values_.length,t)},toJSON:function(){return this.slice()},splice:function(t,n){for(var r=arguments.length,i=new Array(r>2?r-2:0),o=2;o<r;o++)i[o-2]=arguments[o];var s=this[$];switch(arguments.length){case 0:return[];case 1:return s.spliceWithArray_(t);case 2:return s.spliceWithArray_(t,n)}return s.spliceWithArray_(t,n,i)},spliceWithArray:function(t,n,r){return this[$].spliceWithArray_(t,n,r)},push:function(){for(var t=this[$],n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return t.spliceWithArray_(t.values_.length,0,r),t.values_.length},pop:function(){return this.splice(Math.max(this[$].values_.length-1,0),1)[0]},shift:function(){return this.splice(0,1)[0]},unshift:function(){for(var t=this[$],n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return t.spliceWithArray_(0,0,r),t.values_.length},reverse:function(){return T.trackingDerivation&&Q(37,"reverse"),this.replace(this.slice().reverse()),this},sort:function(){T.trackingDerivation&&Q(37,"sort");var t=this.slice();return t.sort.apply(t,arguments),this.replace(t),this},remove:function(t){var n=this[$],r=n.dehanceValues_(n.values_).indexOf(t);return r>-1?(this.splice(r,1),!0):!1}};ie("at",nt);ie("concat",nt);ie("flat",nt);ie("includes",nt);ie("indexOf",nt);ie("join",nt);ie("lastIndexOf",nt);ie("slice",nt);ie("toString",nt);ie("toLocaleString",nt);ie("toSorted",nt);ie("toSpliced",nt);ie("with",nt);ie("every",Nt);ie("filter",Nt);ie("find",Nt);ie("findIndex",Nt);ie("findLast",Nt);ie("findLastIndex",Nt);ie("flatMap",Nt);ie("forEach",Nt);ie("map",Nt);ie("some",Nt);ie("toReversed",Nt);ie("reduce",Tm);ie("reduceRight",Tm);function ie(e,t){typeof Array.prototype[e]=="function"&&(Ol[e]=t(e))}function nt(e){return function(){var t=this[$];t.atom_.reportObserved();var n=t.dehanceValues_(t.values_);return n[e].apply(n,arguments)}}function Nt(e){return function(t,n){var r=this,i=this[$];i.atom_.reportObserved();var o=i.dehanceValues_(i.values_);return o[e](function(s,l){return t.call(n,s,l,r)})}}function Tm(e){return function(){var t=this,n=this[$];n.atom_.reportObserved();var r=n.dehanceValues_(n.values_),i=arguments[0];return arguments[0]=function(o,s,l){return i(o,s,l,t)},r[e].apply(r,arguments)}}var U_=Zn("ObservableArrayAdministration",Bf);function qo(e){return sa(e)&&U_(e[$])}var B_={},Tn="add",Pl="delete",Rm=function(){function e(n,r,i){var o=this;r===void 0&&(r=br),i===void 0&&(i="ObservableMap"),this.enhancer_=void 0,this.name_=void 0,this[$]=B_,this.data_=void 0,this.hasMap_=void 0,this.keysAtom_=void 0,this.interceptors_=void 0,this.changeListeners_=void 0,this.dehancer=void 0,this.enhancer_=r,this.name_=i,At(Map)||Q(18),er(function(){o.keysAtom_=im("ObservableMap.keys()"),o.data_=new Map,o.hasMap_=new Map,n&&o.merge(n)})}var t=e.prototype;return t.has_=function(r){return this.data_.has(r)},t.has=function(r){var i=this;if(!T.trackingDerivation)return this.has_(r);var o=this.hasMap_.get(r);if(!o){var s=o=new Bn(this.has_(r),la,"ObservableMap.key?",!1);this.hasMap_.set(r,s),km(s,function(){return i.hasMap_.delete(r)})}return o.get()},t.set=function(r,i){var o=this.has_(r);if(st(this)){var s=lt(this,{type:o?Wt:Tn,object:this,newValue:i,name:r});if(!s)return this;i=s.newValue}return o?this.updateValue_(r,i):this.addValue_(r,i),this},t.delete=function(r){var i=this;if(this.keysAtom_,st(this)){var o=lt(this,{type:Pl,object:this,name:r});if(!o)return!1}if(this.has_(r)){var s=co(),l=bt(this),a=l||s?{observableKind:"map",debugObjectName:this.name_,type:Pl,object:this,oldValue:this.data_.get(r).value_,name:r}:null;return nn(function(){var u;i.keysAtom_.reportChanged(),(u=i.hasMap_.get(r))==null||u.setNewValue_(!1);var c=i.data_.get(r);c.setNewValue_(void 0),i.data_.delete(r)}),l&&St(this,a),!0}return!1},t.updateValue_=function(r,i){var o=this.data_.get(r);if(i=o.prepareNewValue_(i),i!==T.UNCHANGED){var s=co(),l=bt(this),a=l||s?{observableKind:"map",debugObjectName:this.name_,type:Wt,object:this,oldValue:o.value_,name:r,newValue:i}:null;o.setNewValue_(i),l&&St(this,a)}},t.addValue_=function(r,i){var o=this;this.keysAtom_,nn(function(){var u,c=new Bn(i,o.enhancer_,"ObservableMap.key",!1);o.data_.set(r,c),i=c.value_,(u=o.hasMap_.get(r))==null||u.setNewValue_(!0),o.keysAtom_.reportChanged()});var s=co(),l=bt(this),a=l||s?{observableKind:"map",debugObjectName:this.name_,type:Tn,object:this,name:r,newValue:i}:null;l&&St(this,a)},t.get=function(r){return this.has(r)?this.dehanceValue_(this.data_.get(r).get()):this.dehanceValue_(void 0)},t.dehanceValue_=function(r){return this.dehancer!==void 0?this.dehancer(r):r},t.keys=function(){return this.keysAtom_.reportObserved(),this.data_.keys()},t.values=function(){var r=this,i=this.keys();return Ah({next:function(){var s=i.next(),l=s.done,a=s.value;return{done:l,value:l?void 0:r.get(a)}}})},t.entries=function(){var r=this,i=this.keys();return Ah({next:function(){var s=i.next(),l=s.done,a=s.value;return{done:l,value:l?void 0:[a,r.get(a)]}}})},t[Symbol.iterator]=function(){return this.entries()},t.forEach=function(r,i){for(var o=Zr(this),s;!(s=o()).done;){var l=s.value,a=l[0],u=l[1];r.call(i,u,a,this)}},t.merge=function(r){var i=this;return qn(r)&&(r=new Map(r)),nn(function(){vn(r)?c1(r).forEach(function(o){return i.set(o,r[o])}):Array.isArray(r)?r.forEach(function(o){var s=o[0],l=o[1];return i.set(s,l)}):Ai(r)?(u1(r)||Q(19,r),r.forEach(function(o,s){return i.set(s,o)})):r!=null&&Q(20,r)}),this},t.clear=function(){var r=this;nn(function(){vm(function(){for(var i=Zr(r.keys()),o;!(o=i()).done;){var s=o.value;r.delete(s)}})})},t.replace=function(r){var i=this;return nn(function(){for(var o=$_(r),s=new Map,l=!1,a=Zr(i.data_.keys()),u;!(u=a()).done;){var c=u.value;if(!o.has(c)){var f=i.delete(c);if(f)l=!0;else{var d=i.data_.get(c);s.set(c,d)}}}for(var p=Zr(o.entries()),y;!(y=p()).done;){var m=y.value,b=m[0],v=m[1],g=i.data_.has(b);if(i.set(b,v),i.data_.has(b)){var w=i.data_.get(b);s.set(b,w),g||(l=!0)}}if(!l)if(i.data_.size!==s.size)i.keysAtom_.reportChanged();else for(var _=i.data_.keys(),S=s.keys(),E=_.next(),A=S.next();!E.done;){if(E.value!==A.value){i.keysAtom_.reportChanged();break}E=_.next(),A=S.next()}i.data_=s}),this},t.toString=function(){return"[object ObservableMap]"},t.toJSON=function(){return Array.from(this)},t.observe_=function(r,i){return Jo(this,r)},t.intercept_=function(r){return Zo(this,r)},Ci(e,[{key:"size",get:function(){return this.keysAtom_.reportObserved(),this.data_.size}},{key:Symbol.toStringTag,get:function(){return"Map"}}])}(),qn=Zn("ObservableMap",Rm);function Ah(e){return e[Symbol.toStringTag]="MapIterator",Vf(e)}function $_(e){if(Ai(e)||qn(e))return e;if(Array.isArray(e))return new Map(e);if(vn(e)){var t=new Map;for(var n in e)t.set(n,e[n]);return t}else return Q(21,e)}var V_={},Dm=function(){function e(n,r,i){var o=this;r===void 0&&(r=br),i===void 0&&(i="ObservableSet"),this.name_=void 0,this[$]=V_,this.data_=new Set,this.atom_=void 0,this.changeListeners_=void 0,this.interceptors_=void 0,this.dehancer=void 0,this.enhancer_=void 0,this.name_=i,At(Set)||Q(22),this.enhancer_=function(s,l){return r(s,l,i)},er(function(){o.atom_=im(o.name_),n&&o.replace(n)})}var t=e.prototype;return t.dehanceValue_=function(r){return this.dehancer!==void 0?this.dehancer(r):r},t.clear=function(){var r=this;nn(function(){vm(function(){for(var i=Zr(r.data_.values()),o;!(o=i()).done;){var s=o.value;r.delete(s)}})})},t.forEach=function(r,i){for(var o=Zr(this),s;!(s=o()).done;){var l=s.value;r.call(i,l,l,this)}},t.add=function(r){var i=this;if(this.atom_,st(this)){var o=lt(this,{type:Tn,object:this,newValue:r});if(!o)return this;r=o.newValue}if(!this.has(r)){nn(function(){i.data_.add(i.enhancer_(r,void 0)),i.atom_.reportChanged()});var s=!1,l=bt(this),a=l||s?{observableKind:"set",debugObjectName:this.name_,type:Tn,object:this,newValue:r}:null;l&&St(this,a)}return this},t.delete=function(r){var i=this;if(st(this)){var o=lt(this,{type:Pl,object:this,oldValue:r});if(!o)return!1}if(this.has(r)){var s=!1,l=bt(this),a=l||s?{observableKind:"set",debugObjectName:this.name_,type:Pl,object:this,oldValue:r}:null;return nn(function(){i.atom_.reportChanged(),i.data_.delete(r)}),l&&St(this,a),!0}return!1},t.has=function(r){return this.atom_.reportObserved(),this.data_.has(this.dehanceValue_(r))},t.entries=function(){var r=this.values();return Ch({next:function(){var o=r.next(),s=o.value,l=o.done;return l?{value:void 0,done:l}:{value:[s,s],done:l}}})},t.keys=function(){return this.values()},t.values=function(){this.atom_.reportObserved();var r=this,i=this.data_.values();return Ch({next:function(){var s=i.next(),l=s.value,a=s.done;return a?{value:void 0,done:a}:{value:r.dehanceValue_(l),done:a}}})},t.intersection=function(r){if(tn(r)&&!wt(r))return r.intersection(this);var i=new Set(this);return i.intersection(r)},t.union=function(r){if(tn(r)&&!wt(r))return r.union(this);var i=new Set(this);return i.union(r)},t.difference=function(r){return new Set(this).difference(r)},t.symmetricDifference=function(r){if(tn(r)&&!wt(r))return r.symmetricDifference(this);var i=new Set(this);return i.symmetricDifference(r)},t.isSubsetOf=function(r){return new Set(this).isSubsetOf(r)},t.isSupersetOf=function(r){return new Set(this).isSupersetOf(r)},t.isDisjointFrom=function(r){if(tn(r)&&!wt(r))return r.isDisjointFrom(this);var i=new Set(this);return i.isDisjointFrom(r)},t.replace=function(r){var i=this;return wt(r)&&(r=new Set(r)),nn(function(){Array.isArray(r)?(i.clear(),r.forEach(function(o){return i.add(o)})):tn(r)?(i.clear(),r.forEach(function(o){return i.add(o)})):r!=null&&Q("Cannot initialize set from "+r)}),this},t.observe_=function(r,i){return Jo(this,r)},t.intercept_=function(r){return Zo(this,r)},t.toJSON=function(){return Array.from(this)},t.toString=function(){return"[object ObservableSet]"},t[Symbol.iterator]=function(){return this.values()},Ci(e,[{key:"size",get:function(){return this.atom_.reportObserved(),this.data_.size}},{key:Symbol.toStringTag,get:function(){return"Set"}}])}(),wt=Zn("ObservableSet",Dm);function Ch(e){return e[Symbol.toStringTag]="SetIterator",Vf(e)}var kh=Object.create(null),Oh="remove",Mm=function(){function e(n,r,i,o){r===void 0&&(r=new Map),o===void 0&&(o=U1),this.target_=void 0,this.values_=void 0,this.name_=void 0,this.defaultAnnotation_=void 0,this.keysAtom_=void 0,this.changeListeners_=void 0,this.interceptors_=void 0,this.proxy_=void 0,this.isPlainObject_=void 0,this.appliedAnnotations_=void 0,this.pendingKeys_=void 0,this.target_=n,this.values_=r,this.name_=i,this.defaultAnnotation_=o,this.keysAtom_=new Jn("ObservableObject.keys"),this.isPlainObject_=vn(this.target_)}var t=e.prototype;return t.getObservablePropValue_=function(r){return this.values_.get(r).get()},t.setObservablePropValue_=function(r,i){var o=this.values_.get(r);if(o instanceof Ct)return o.set(i),!0;if(st(this)){var s=lt(this,{type:Wt,object:this.proxy_||this.target_,name:r,newValue:i});if(!s)return null;i=s.newValue}if(i=o.prepareNewValue_(i),i!==T.UNCHANGED){var l=bt(this),a=!1,u=l||a?{type:Wt,observableKind:"object",debugObjectName:this.name_,object:this.proxy_||this.target_,oldValue:o.value_,name:r,newValue:i}:null;o.setNewValue_(i),l&&St(this,u)}return!0},t.get_=function(r){return T.trackingDerivation&&!ln(this.target_,r)&&this.has_(r),this.target_[r]},t.set_=function(r,i,o){return o===void 0&&(o=!1),ln(this.target_,r)?this.values_.has(r)?this.setObservablePropValue_(r,i):o?Reflect.set(this.target_,r,i):(this.target_[r]=i,!0):this.extend_(r,{value:i,enumerable:!0,writable:!0,configurable:!0},this.defaultAnnotation_,o)},t.has_=function(r){if(!T.trackingDerivation)return r in this.target_;this.pendingKeys_||(this.pendingKeys_=new Map);var i=this.pendingKeys_.get(r);return i||(i=new Bn(r in this.target_,la,"ObservableObject.key?",!1),this.pendingKeys_.set(r,i)),i.get()},t.make_=function(r,i){if(i===!0&&(i=this.defaultAnnotation_),i!==!1){if(!(r in this.target_)){var o;if((o=this.target_[Ft])!=null&&o[r])return;Q(1,i.annotationType_,this.name_+"."+r.toString())}for(var s=this.target_;s&&s!==Ho;){var l=bl(s,r);if(l){var a=i.make_(this,r,l,s);if(a===0)return;if(a===1)break}s=Object.getPrototypeOf(s)}Nh(this,i,r)}},t.extend_=function(r,i,o,s){if(s===void 0&&(s=!1),o===!0&&(o=this.defaultAnnotation_),o===!1)return this.defineProperty_(r,i,s);var l=o.extend_(this,r,i,s);return l&&Nh(this,o,r),l},t.defineProperty_=function(r,i,o){o===void 0&&(o=!1),this.keysAtom_;try{ut();var s=this.delete_(r);if(!s)return s;if(st(this)){var l=lt(this,{object:this.proxy_||this.target_,name:r,type:Tn,newValue:i.value});if(!l)return null;var a=l.newValue;i.value!==a&&(i=_r({},i,{value:a}))}if(o){if(!Reflect.defineProperty(this.target_,r,i))return!1}else $t(this.target_,r,i);this.notifyPropertyAddition_(r,i.value)}finally{ct()}return!0},t.defineObservableProperty_=function(r,i,o,s){s===void 0&&(s=!1),this.keysAtom_;try{ut();var l=this.delete_(r);if(!l)return l;if(st(this)){var a=lt(this,{object:this.proxy_||this.target_,name:r,type:Tn,newValue:i});if(!a)return null;i=a.newValue}var u=Ph(r),c={configurable:T.safeDescriptors?this.isPlainObject_:!0,enumerable:!0,get:u.get,set:u.set};if(s){if(!Reflect.defineProperty(this.target_,r,c))return!1}else $t(this.target_,r,c);var f=new Bn(i,o,"ObservableObject.key",!1);this.values_.set(r,f),this.notifyPropertyAddition_(r,f.value_)}finally{ct()}return!0},t.defineComputedProperty_=function(r,i,o){o===void 0&&(o=!1),this.keysAtom_;try{ut();var s=this.delete_(r);if(!s)return s;if(st(this)){var l=lt(this,{object:this.proxy_||this.target_,name:r,type:Tn,newValue:void 0});if(!l)return null}i.name||(i.name="ObservableObject.key"),i.context=this.proxy_||this.target_;var a=Ph(r),u={configurable:T.safeDescriptors?this.isPlainObject_:!0,enumerable:!1,get:a.get,set:a.set};if(o){if(!Reflect.defineProperty(this.target_,r,u))return!1}else $t(this.target_,r,u);this.values_.set(r,new Ct(i)),this.notifyPropertyAddition_(r,void 0)}finally{ct()}return!0},t.delete_=function(r,i){if(i===void 0&&(i=!1),this.keysAtom_,!ln(this.target_,r))return!0;if(st(this)){var o=lt(this,{object:this.proxy_||this.target_,name:r,type:Oh});if(!o)return null}try{var s;ut();var l=bt(this),a=!1,u=this.values_.get(r),c=void 0;if(!u&&(l||a)){var f;c=(f=bl(this.target_,r))==null?void 0:f.value}if(i){if(!Reflect.deleteProperty(this.target_,r))return!1}else delete this.target_[r];if(u&&(this.values_.delete(r),u instanceof Bn&&(c=u.value_),_m(u)),this.keysAtom_.reportChanged(),(s=this.pendingKeys_)==null||(s=s.get(r))==null||s.set(r in this.target_),l||a){var d={type:Oh,observableKind:"object",object:this.proxy_||this.target_,debugObjectName:this.name_,oldValue:c,name:r};l&&St(this,d)}}finally{ct()}return!0},t.observe_=function(r,i){return Jo(this,r)},t.intercept_=function(r){return Zo(this,r)},t.notifyPropertyAddition_=function(r,i){var o,s=bt(this),l=!1;if(s||l){var a=s||l?{type:Tn,observableKind:"object",debugObjectName:this.name_,object:this.proxy_||this.target_,name:r,newValue:i}:null;s&&St(this,a)}(o=this.pendingKeys_)==null||(o=o.get(r))==null||o.set(!0),this.keysAtom_.reportChanged()},t.ownKeys_=function(){return this.keysAtom_.reportObserved(),gi(this.target_)},t.keys_=function(){return this.keysAtom_.reportObserved(),Object.keys(this.target_)},e}();function Pr(e,t){var n;if(ln(e,$))return e;var r=(n=t==null?void 0:t.name)!=null?n:"ObservableObject",i=new Mm(e,new Map,String(r),Z1(t));return Ko(e,$,i),e}var W_=Zn("ObservableObjectAdministration",Mm);function Ph(e){return kh[e]||(kh[e]={get:function(){return this[$].getObservablePropValue_(e)},set:function(n){return this[$].setObservablePropValue_(e,n)}})}function es(e){return sa(e)?W_(e[$]):!1}function Nh(e,t,n){var r;(r=e.target_[Ft])==null||delete r[n]}var H_=Im(0),K_=function(){var e=!1,t={};return Object.defineProperty(t,"0",{set:function(){e=!0}}),Object.create(t)[0]=1,e===!1}(),tu=0,Lm=function(){};function G_(e,t){Object.setPrototypeOf?Object.setPrototypeOf(e.prototype,t):e.prototype.__proto__!==void 0?e.prototype.__proto__=t:e.prototype=t}G_(Lm,Array.prototype);var $f=function(e){function t(r,i,o,s){var l;return o===void 0&&(o="ObservableArray"),s===void 0&&(s=!1),l=e.call(this)||this,er(function(){var a=new Bf(o,i,s,!0);a.proxy_=l,em(l,$,a),r&&r.length&&l.spliceWithArray(0,0,r),K_&&Object.defineProperty(l,"0",H_)}),l}rm(t,e);var n=t.prototype;return n.concat=function(){this[$].atom_.reportObserved();for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return Array.prototype.concat.apply(this.slice(),o.map(function(l){return qo(l)?l.slice():l}))},n[Symbol.iterator]=function(){var r=this,i=0;return Vf({next:function(){return i<r.length?{value:r[i++],done:!1}:{done:!0,value:void 0}}})},Ci(t,[{key:"length",get:function(){return this[$].getArrayLength_()},set:function(i){this[$].setArrayLength_(i)}},{key:Symbol.toStringTag,get:function(){return"Array"}}])}(Lm);Object.entries(Ol).forEach(function(e){var t=e[0],n=e[1];t!=="concat"&&Ko($f.prototype,t,n)});function Im(e){return{enumerable:!1,configurable:!0,get:function(){return this[$].get_(e)},set:function(n){this[$].set_(e,n)}}}function Q_(e){$t($f.prototype,""+e,Im(e))}function Fm(e){if(e>tu){for(var t=tu;t<e+100;t++)Q_(t);tu=e}}Fm(1e3);function Y_(e,t,n){return new $f(e,t,n)}function Nl(e,t){if(typeof e=="object"&&e!==null){if(qo(e))return t!==void 0&&Q(23),e[$].atom_;if(wt(e))return e.atom_;if(qn(e)){if(t===void 0)return e.keysAtom_;var n=e.data_.get(t)||e.hasMap_.get(t);return n||Q(25,t,Sc(e)),n}if(es(e)){if(!t)return Q(26);var r=e[$].values_.get(t);return r||Q(27,t,Sc(e)),r}if(Df(e)||Xo(e)||kl(e))return e}else if(At(e)&&kl(e[$]))return e[$];Q(28)}function X_(e,t){if(e||Q(29),Df(e)||Xo(e)||kl(e)||qn(e)||wt(e))return e;if(e[$])return e[$];Q(24,e)}function Sc(e,t){var n;if(t!==void 0)n=Nl(e,t);else{if(mi(e))return e.name;es(e)||qn(e)||wt(e)?n=X_(e):n=Nl(e)}return n.name_}function er(e){var t=Or(),n=Lf(!0);ut();try{return e()}finally{ct(),If(n),an(t)}}var jh=Ho.toString;function zm(e,t,n){return n===void 0&&(n=-1),Ec(e,t,n)}function Ec(e,t,n,r,i){if(e===t)return e!==0||1/e===1/t;if(e==null||t==null)return!1;if(e!==e)return t!==t;var o=typeof e;if(o!=="function"&&o!=="object"&&typeof t!="object")return!1;var s=jh.call(e);if(s!==jh.call(t))return!1;switch(s){case"[object RegExp]":case"[object String]":return""+e==""+t;case"[object Number]":return+e!=+e?+t!=+t:+e==0?1/+e===1/t:+e==+t;case"[object Date]":case"[object Boolean]":return+e==+t;case"[object Symbol]":return typeof Symbol<"u"&&Symbol.valueOf.call(e)===Symbol.valueOf.call(t);case"[object Map]":case"[object Set]":n>=0&&n++;break}e=Th(e),t=Th(t);var l=s==="[object Array]";if(!l){if(typeof e!="object"||typeof t!="object")return!1;var a=e.constructor,u=t.constructor;if(a!==u&&!(At(a)&&a instanceof a&&At(u)&&u instanceof u)&&"constructor"in e&&"constructor"in t)return!1}if(n===0)return!1;n<0&&(n=-1),r=r||[],i=i||[];for(var c=r.length;c--;)if(r[c]===e)return i[c]===t;if(r.push(e),i.push(t),l){if(c=e.length,c!==t.length)return!1;for(;c--;)if(!Ec(e[c],t[c],n-1,r,i))return!1}else{var f=Object.keys(e),d=f.length;if(Object.keys(t).length!==d)return!1;for(var p=0;p<d;p++){var y=f[p];if(!(ln(t,y)&&Ec(e[y],t[y],n-1,r,i)))return!1}}return r.pop(),i.pop(),!0}function Th(e){return qo(e)?e.slice():Ai(e)||qn(e)||tn(e)||wt(e)?Array.from(e.entries()):e}var Rh,Z_=((Rh=oa().Iterator)==null?void 0:Rh.prototype)||{};function Vf(e){return e[Symbol.iterator]=J_,Object.assign(Object.create(Z_),e)}function J_(){return this}["Symbol","Map","Set"].forEach(function(e){var t=oa();typeof t[e]>"u"&&Q("MobX requires global '"+e+"' to be available or polyfilled")});typeof __MOBX_DEVTOOLS_GLOBAL_HOOK__=="object"&&__MOBX_DEVTOOLS_GLOBAL_HOOK__.injectMobx({spy:v_,extras:{getDebugName:Sc},$mobx:$});if(!x.useState)throw new Error("mobx-react-lite requires React with Hooks support");if(!ua)throw new Error("mobx-react-lite@3 requires mobx at least version 6 to be available");function q_(e){e()}function eb(e){e||(e=q_),O_({reactionScheduler:e})}function tb(e){return P_(e)}var nb=1e4,rb=1e4,ib=function(){function e(t){var n=this;Object.defineProperty(this,"finalize",{enumerable:!0,configurable:!0,writable:!0,value:t}),Object.defineProperty(this,"registrations",{enumerable:!0,configurable:!0,writable:!0,value:new Map}),Object.defineProperty(this,"sweepTimeout",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"sweep",{enumerable:!0,configurable:!0,writable:!0,value:function(r){r===void 0&&(r=nb),clearTimeout(n.sweepTimeout),n.sweepTimeout=void 0;var i=Date.now();n.registrations.forEach(function(o,s){i-o.registeredAt>=r&&(n.finalize(o.value),n.registrations.delete(s))}),n.registrations.size>0&&n.scheduleSweep()}}),Object.defineProperty(this,"finalizeAllImmediately",{enumerable:!0,configurable:!0,writable:!0,value:function(){n.sweep(0)}})}return Object.defineProperty(e.prototype,"register",{enumerable:!1,configurable:!0,writable:!0,value:function(t,n,r){this.registrations.set(r,{value:n,registeredAt:Date.now()}),this.scheduleSweep()}}),Object.defineProperty(e.prototype,"unregister",{enumerable:!1,configurable:!0,writable:!0,value:function(t){this.registrations.delete(t)}}),Object.defineProperty(e.prototype,"scheduleSweep",{enumerable:!1,configurable:!0,writable:!0,value:function(){this.sweepTimeout===void 0&&(this.sweepTimeout=setTimeout(this.sweep,rb))}}),e}(),ob=typeof FinalizationRegistry<"u"?FinalizationRegistry:ib,Ac=new ob(function(e){var t;(t=e.reaction)===null||t===void 0||t.dispose(),e.reaction=null}),Dh=function(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var r=n.call(e),i,o=[],s;try{for(;(t===void 0||t-- >0)&&!(i=r.next()).done;)o.push(i.value)}catch(l){s={error:l}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(s)throw s.error}}return o};function Mh(e){return"observer".concat(e)}var sb=function(){function e(){}return e}();function lb(){return new sb}function ab(e,t){t===void 0&&(t="observed");var n=Dh(Cn.useState(lb),1),r=n[0],i=Dh(Cn.useState(),2),o=i[1],s=function(){return o([])},l=Cn.useRef(null);l.current||(l.current={reaction:null,mounted:!1,changedBeforeMount:!1});var a=l.current;a.reaction||(a.reaction=new Kt(Mh(t),function(){a.mounted?s():a.changedBeforeMount=!0}),Ac.register(r,a,a)),Cn.useDebugValue(a.reaction,tb),Cn.useEffect(function(){return Ac.unregister(a),a.mounted=!0,a.reaction?a.changedBeforeMount&&(a.changedBeforeMount=!1,s()):(a.reaction=new Kt(Mh(t),function(){s()}),s()),function(){a.reaction.dispose(),a.reaction=null,a.mounted=!1,a.changedBeforeMount=!1}},[]);var u,c;if(a.reaction.track(function(){try{u=e()}catch(f){c=f}}),c)throw c;return u}var Um=typeof Symbol=="function"&&Symbol.for,Lh=Um?Symbol.for("react.forward_ref"):typeof x.forwardRef=="function"&&x.forwardRef(function(e){return null}).$$typeof,Ih=Um?Symbol.for("react.memo"):typeof x.memo=="function"&&x.memo(function(e){return null}).$$typeof;function Se(e,t){var n;if(Ih&&e.$$typeof===Ih)throw new Error("[mobx-react-lite] You are trying to use `observer` on a function component wrapped in either another `observer` or `React.memo`. The observer already applies 'React.memo' for you.");var r=(n=void 0)!==null&&n!==void 0?n:!1,i=e,o=e.displayName||e.name;if(Lh&&e.$$typeof===Lh&&(r=!0,i=e.render,typeof i!="function"))throw new Error("[mobx-react-lite] `render` property of ForwardRef was not a function");var s=function(l,a){return ab(function(){return i(l,a)},o)};return o!==""&&(s.displayName=o),e.contextTypes&&(s.contextTypes=e.contextTypes),r&&(s=x.forwardRef(s)),s=x.memo(s),cb(e,s),s}var ub={$$typeof:!0,render:!0,compare:!0,type:!0,displayName:!0};function cb(e,t){Object.keys(e).forEach(function(n){ub[n]||Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(e,n))})}var nu;eb(Wo.unstable_batchedUpdates);nu=Ac.finalizeAllImmediately;const Ee=x.createContext(void 0),fb="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIAAAACACAYAAADDPmHLAAABhGlDQ1BJQ0MgcHJvZmlsZQAAKJF9kT1Iw1AUhU9TpSoVB4uIiGSoTnZREcdahSJUCLVCqw4mL/0RmjQkKS6OgmvBwZ/FqoOLs64OroIg+APi6uKk6CIl3pcUWsT44PI+znvncN99gFAvM83qiAOabpvpZELM5lbE0Cu6MUI1gJDMLGNWklLwXV/3CPD9Lsaz/O/9uXrVvMWAgEgcZ4ZpE68TT2/aBud94ggrySrxOfG4SQ0SP3Jd8fiNc9FlgWdGzEx6jjhCLBbbWGljVjI14iniqKrplC9kPVY5b3HWylXW7JO/MJzXl5e4TjWMJBawCAkiFFSxgTJsxGjXSbGQpvOEj3/I9UvkUsi1AUaOeVSgQXb94H/we7ZWYXLCSwongM4Xx/kYBUK7QKPmON/HjtM4AYLPwJXe8lfqwMwn6bWWFj0C+raBi+uWpuwBlzvA4JMhm7IrBamEQgF4P6NvygH9t0DPqje35jlOH4AMzSp1AxwcAmNFyl7zeXdX+9z+vdOc3w9cCXKdY3hzngAAAAZiS0dEADsAggD2md2qLwAAAAlwSFlzAAAuIwAALiMBeKU/dgAAAAd0SU1FB+cJHgkjNZ2IS4oAAAAZdEVYdENvbW1lbnQAQ3JlYXRlZCB3aXRoIEdJTVBXgQ4XAAAFjklEQVR42u3cT2wUVQDH8d+8ndl2tyt2gQoUliLQtIAKAkEMLSHCyYgSDAk9mNiTUTyo4abGiIkXEhPxTyKayL9IjEYlmpAGDWJBDKRx0dLQlAKtWAultGxpu92Z954HTmhLZ7YlzM78vtfuNtt9n33zZjpvjTU7hjRYaBN8CwiAEQAjAEYAjAAYATACYATACIARACMARgCMABgBMAJggcucyJPf3Whi7TJrQi9AKg0pAcfRGMwCg8MaPf0aXb0KZzo0jnYo2IoD5UsAk1FEGIgIIGoZiMeAsiQwr/zWz56pBbZnFc5dUjiSlvi+jRICB2C84sUCy6sFllebqOuW2PuTg4YLhBDKNcDcmRG8XhfFjidNRAwOXigXgUIYeGKFhY/qLFhcwob3LOChBSZ2brY4gmE+DVy5yMRLqyMcxTBfB9hUY2JeggsC358F/H1Vom/g9j0owgCKowZKYsC0UgEzj5VdPCZQXxvBW4cdjqafATT+KfHhr3LMnydMYNMSgQ2PmliY8jatP7Y4AqvB4QWjQj4E3HSAA2cUnt+Tw/6GHBzpfsdaIi7wdBVPCQKzBvjklMQ3x2xPz1n6IAH4+hDgtV0nJGofkZg13d3hIFU2PoBdWywsr3b3J7+2O4tTV7zvm50VA77aHnP12LZOifq9Oc4AY9XUKl0/NnkfzwQCByB9yf0nMF7MwQwcgK4b7gGYJmeAwAHIeji1V4rfcxE4AOX3u39szuZgBg5A9Sz3Ly8zyBkgcABWVLp/eVf7CCBQAJ5aKFBV4f6ScPs/vA4cGAA1sw28uNGCEO5W9lpr/NhCAPnkqyuBCRN4eW0EG1aaKC5yb/PyVYWz13kIKCgAUyxgZtzA3FKgqlygOiVQVSEQL/Y+Kf2clhxJvwPYuj6Kresn//f29ivsbyKAQJ4FuOmLozaGOP7hBNCYtvFlMxd/oQTQ3O7gjR94G1goATSmbWw7aENy4R+s08DxujGgcPCojQNnOO2HCkDmpsLJsxIfH3PQO+Lv12oV2J413wLoyyhc6FL4vV3iYFphpEA+9KVFnAFGbbR9AUoBOQfIORrZEaAno3G5V6OlW6O1vzAP8AkCGGPhNs6+gKA0vcB2KfFe6rHKcxxT0wggECWi+T1vZpIAAlGyJL+BnF8uCMCvaQ/ryooy7wCmRoHyMgLwbbaHS4eVs71/78BzqyKwTB4CfNuQh4tIlSkDZR42m8QjwLplZsG9J6ECcH3A/QxQXCTwygb3A/r2RhNlSUEAfq6929vFpdqlJl6tvfOhYEYMeH+LhccfLszvKzLDBOBEh4LjaNfbyIQw8Oy6KFYtUjh9zsH5bo0bwxpTSww8MMXAknkC1XnexkYA9+IQkAM6uhUWzPG2wEvNEEjNiAbyPQnddYDjzbx/LNQA9jVJXOu7u/9azNxUBbNZNXQARhSw54gNeZcGKDOosO2zHLp6FAH4te9aFQ412tB6chFkRxQ+OGTj4oBG618E4Ove+0ViX4ON7CTdadI/oLDzaxuH22/9vtNtBOD7Pj0tsf3zHNo6Zd6zge1o/NZs44XdI7d9jX3DBYXhrP8RmAh56R6N+r051Mw2sHm1ico5Askpd/5cSKXR3avwx3mFb5skWkbZmm4r4GKXwuL5/v6MGWt2DPHm6v+0OGlgZYWB0hIDiZiBIguwHSAzpNF5TeNkp8KV4WD8rSaH+/+19OlRP9W8DsAIgBEAIwBGAIwAGAEwAmAEwAiAEQAjAEYAjAAYATACYATACIARACMARgCMABgBMAJgBMAIgBEAIwBGAIwAGAGwexS/H2ACHX8zxhmAEQAjAEYAjAAYATACYATACIARACuAeCl4AtW8M8wZgBEAIwBGAIwAGAEwAmAEwAiAEQAjAEYAjAAYATACYH7sX+VXpk3NRQ0eAAAAAElFTkSuQmCC";function $n(e,t,{checkForDefaultPrevented:n=!0}={}){return function(i){if(e==null||e(i),n===!1||!i.defaultPrevented)return t==null?void 0:t(i)}}function Fh(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Bm(...e){return t=>{let n=!1;const r=e.map(i=>{const o=Fh(i,t);return!n&&typeof o=="function"&&(n=!0),o});if(n)return()=>{for(let i=0;i<r.length;i++){const o=r[i];typeof o=="function"?o():Fh(e[i],null)}}}}function tr(...e){return x.useCallback(Bm(...e),e)}function $m(e,t=[]){let n=[];function r(o,s){const l=x.createContext(s),a=n.length;n=[...n,s];const u=f=>{var v;const{scope:d,children:p,...y}=f,m=((v=d==null?void 0:d[e])==null?void 0:v[a])||l,b=x.useMemo(()=>y,Object.values(y));return h.jsx(m.Provider,{value:b,children:p})};u.displayName=o+"Provider";function c(f,d){var m;const p=((m=d==null?void 0:d[e])==null?void 0:m[a])||l,y=x.useContext(p);if(y)return y;if(s!==void 0)return s;throw new Error(`\`${f}\` must be used within \`${o}\``)}return[u,c]}const i=()=>{const o=n.map(s=>x.createContext(s));return function(l){const a=(l==null?void 0:l[e])||o;return x.useMemo(()=>({[`__scope${e}`]:{...l,[e]:a}}),[l,a])}};return i.scopeName=e,[r,db(i,...t)]}function db(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(o){const s=r.reduce((l,{useScope:a,scopeName:u})=>{const f=a(o)[`__scope${u}`];return{...l,...f}},{});return x.useMemo(()=>({[`__scope${t.scopeName}`]:s}),[s])}};return n.scopeName=t.scopeName,n}function Vm(e){const t=hb(e),n=x.forwardRef((r,i)=>{const{children:o,...s}=r,l=x.Children.toArray(o),a=l.find(vb);if(a){const u=a.props.children,c=l.map(f=>f===a?x.Children.count(u)>1?x.Children.only(null):x.isValidElement(u)?u.props.children:null:f);return h.jsx(t,{...s,ref:i,children:x.isValidElement(u)?x.cloneElement(u,void 0,c):null})}return h.jsx(t,{...s,ref:i,children:o})});return n.displayName=`${e}.Slot`,n}function hb(e){const t=x.forwardRef((n,r)=>{const{children:i,...o}=n;if(x.isValidElement(i)){const s=mb(i),l=gb(o,i.props);return i.type!==x.Fragment&&(l.ref=r?Bm(r,s):s),x.cloneElement(i,l)}return x.Children.count(i)>1?x.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var pb=Symbol("radix.slottable");function vb(e){return x.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===pb}function gb(e,t){const n={...t};for(const r in t){const i=e[r],o=t[r];/^on[A-Z]/.test(r)?i&&o?n[r]=(...l)=>{const a=o(...l);return i(...l),a}:i&&(n[r]=i):r==="style"?n[r]={...i,...o}:r==="className"&&(n[r]=[i,o].filter(Boolean).join(" "))}return{...e,...n}}function mb(e){var r,i;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var yb=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],wn=yb.reduce((e,t)=>{const n=Vm(`Primitive.${t}`),r=x.forwardRef((i,o)=>{const{asChild:s,...l}=i,a=s?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),h.jsx(a,{...l,ref:o})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function wb(e,t){e&&Wo.flushSync(()=>e.dispatchEvent(t))}function wi(e){const t=x.useRef(e);return x.useEffect(()=>{t.current=e}),x.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}function xb(e,t=globalThis==null?void 0:globalThis.document){const n=wi(e);x.useEffect(()=>{const r=i=>{i.key==="Escape"&&n(i)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var _b="DismissableLayer",Cc="dismissableLayer.update",bb="dismissableLayer.pointerDownOutside",Sb="dismissableLayer.focusOutside",zh,Wm=x.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Hm=x.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:i,onFocusOutside:o,onInteractOutside:s,onDismiss:l,...a}=e,u=x.useContext(Wm),[c,f]=x.useState(null),d=(c==null?void 0:c.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,p]=x.useState({}),y=tr(t,A=>f(A)),m=Array.from(u.layers),[b]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),v=m.indexOf(b),g=c?m.indexOf(c):-1,w=u.layersWithOutsidePointerEventsDisabled.size>0,_=g>=v,S=Cb(A=>{const C=A.target,j=[...u.branches].some(P=>P.contains(C));!_||j||(i==null||i(A),s==null||s(A),A.defaultPrevented||l==null||l())},d),E=kb(A=>{const C=A.target;[...u.branches].some(P=>P.contains(C))||(o==null||o(A),s==null||s(A),A.defaultPrevented||l==null||l())},d);return xb(A=>{g===u.layers.size-1&&(r==null||r(A),!A.defaultPrevented&&l&&(A.preventDefault(),l()))},d),x.useEffect(()=>{if(c)return n&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(zh=d.body.style.pointerEvents,d.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(c)),u.layers.add(c),Uh(),()=>{n&&u.layersWithOutsidePointerEventsDisabled.size===1&&(d.body.style.pointerEvents=zh)}},[c,d,n,u]),x.useEffect(()=>()=>{c&&(u.layers.delete(c),u.layersWithOutsidePointerEventsDisabled.delete(c),Uh())},[c,u]),x.useEffect(()=>{const A=()=>p({});return document.addEventListener(Cc,A),()=>document.removeEventListener(Cc,A)},[]),h.jsx(wn.div,{...a,ref:y,style:{pointerEvents:w?_?"auto":"none":void 0,...e.style},onFocusCapture:$n(e.onFocusCapture,E.onFocusCapture),onBlurCapture:$n(e.onBlurCapture,E.onBlurCapture),onPointerDownCapture:$n(e.onPointerDownCapture,S.onPointerDownCapture)})});Hm.displayName=_b;var Eb="DismissableLayerBranch",Ab=x.forwardRef((e,t)=>{const n=x.useContext(Wm),r=x.useRef(null),i=tr(t,r);return x.useEffect(()=>{const o=r.current;if(o)return n.branches.add(o),()=>{n.branches.delete(o)}},[n.branches]),h.jsx(wn.div,{...e,ref:i})});Ab.displayName=Eb;function Cb(e,t=globalThis==null?void 0:globalThis.document){const n=wi(e),r=x.useRef(!1),i=x.useRef(()=>{});return x.useEffect(()=>{const o=l=>{if(l.target&&!r.current){let a=function(){Km(bb,n,u,{discrete:!0})};const u={originalEvent:l};l.pointerType==="touch"?(t.removeEventListener("click",i.current),i.current=a,t.addEventListener("click",i.current,{once:!0})):a()}else t.removeEventListener("click",i.current);r.current=!1},s=window.setTimeout(()=>{t.addEventListener("pointerdown",o)},0);return()=>{window.clearTimeout(s),t.removeEventListener("pointerdown",o),t.removeEventListener("click",i.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function kb(e,t=globalThis==null?void 0:globalThis.document){const n=wi(e),r=x.useRef(!1);return x.useEffect(()=>{const i=o=>{o.target&&!r.current&&Km(Sb,n,{originalEvent:o},{discrete:!1})};return t.addEventListener("focusin",i),()=>t.removeEventListener("focusin",i)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function Uh(){const e=new CustomEvent(Cc);document.dispatchEvent(e)}function Km(e,t,n,{discrete:r}){const i=n.originalEvent.target,o=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),r?wb(i,o):i.dispatchEvent(o)}var ru=0;function Ob(){x.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Bh()),document.body.insertAdjacentElement("beforeend",e[1]??Bh()),ru++,()=>{ru===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),ru--}},[])}function Bh(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var iu="focusScope.autoFocusOnMount",ou="focusScope.autoFocusOnUnmount",$h={bubbles:!1,cancelable:!0},Pb="FocusScope",Gm=x.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:o,...s}=e,[l,a]=x.useState(null),u=wi(i),c=wi(o),f=x.useRef(null),d=tr(t,m=>a(m)),p=x.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;x.useEffect(()=>{if(r){let m=function(w){if(p.paused||!l)return;const _=w.target;l.contains(_)?f.current=_:Sn(f.current,{select:!0})},b=function(w){if(p.paused||!l)return;const _=w.relatedTarget;_!==null&&(l.contains(_)||Sn(f.current,{select:!0}))},v=function(w){if(document.activeElement===document.body)for(const S of w)S.removedNodes.length>0&&Sn(l)};document.addEventListener("focusin",m),document.addEventListener("focusout",b);const g=new MutationObserver(v);return l&&g.observe(l,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",m),document.removeEventListener("focusout",b),g.disconnect()}}},[r,l,p.paused]),x.useEffect(()=>{if(l){Wh.add(p);const m=document.activeElement;if(!l.contains(m)){const v=new CustomEvent(iu,$h);l.addEventListener(iu,u),l.dispatchEvent(v),v.defaultPrevented||(Nb(Mb(Qm(l)),{select:!0}),document.activeElement===m&&Sn(l))}return()=>{l.removeEventListener(iu,u),setTimeout(()=>{const v=new CustomEvent(ou,$h);l.addEventListener(ou,c),l.dispatchEvent(v),v.defaultPrevented||Sn(m??document.body,{select:!0}),l.removeEventListener(ou,c),Wh.remove(p)},0)}}},[l,u,c,p]);const y=x.useCallback(m=>{if(!n&&!r||p.paused)return;const b=m.key==="Tab"&&!m.altKey&&!m.ctrlKey&&!m.metaKey,v=document.activeElement;if(b&&v){const g=m.currentTarget,[w,_]=jb(g);w&&_?!m.shiftKey&&v===_?(m.preventDefault(),n&&Sn(w,{select:!0})):m.shiftKey&&v===w&&(m.preventDefault(),n&&Sn(_,{select:!0})):v===g&&m.preventDefault()}},[n,r,p.paused]);return h.jsx(wn.div,{tabIndex:-1,...s,ref:d,onKeyDown:y})});Gm.displayName=Pb;function Nb(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(Sn(r,{select:t}),document.activeElement!==n)return}function jb(e){const t=Qm(e),n=Vh(t,e),r=Vh(t.reverse(),e);return[n,r]}function Qm(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const i=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||i?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Vh(e,t){for(const n of e)if(!Tb(n,{upTo:t}))return n}function Tb(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function Rb(e){return e instanceof HTMLInputElement&&"select"in e}function Sn(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&Rb(e)&&t&&e.select()}}var Wh=Db();function Db(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=Hh(e,t),e.unshift(t)},remove(t){var n;e=Hh(e,t),(n=e[0])==null||n.resume()}}}function Hh(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function Mb(e){return e.filter(t=>t.tagName!=="A")}var Hn=globalThis!=null&&globalThis.document?x.useLayoutEffect:()=>{},Lb=Kp[" useId ".trim().toString()]||(()=>{}),Ib=0;function Fb(e){const[t,n]=x.useState(Lb());return Hn(()=>{n(r=>r??String(Ib++))},[e]),e||(t?`radix-${t}`:"")}const zb=["top","right","bottom","left"],Kn=Math.min,Ge=Math.max,jl=Math.round,Cs=Math.floor,Ht=e=>({x:e,y:e}),Ub={left:"right",right:"left",bottom:"top",top:"bottom"},Bb={start:"end",end:"start"};function kc(e,t,n){return Ge(e,Kn(t,n))}function gn(e,t){return typeof e=="function"?e(t):e}function mn(e){return e.split("-")[0]}function ki(e){return e.split("-")[1]}function Wf(e){return e==="x"?"y":"x"}function Hf(e){return e==="y"?"height":"width"}const $b=new Set(["top","bottom"]);function zt(e){return $b.has(mn(e))?"y":"x"}function Kf(e){return Wf(zt(e))}function Vb(e,t,n){n===void 0&&(n=!1);const r=ki(e),i=Kf(e),o=Hf(i);let s=i==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[o]>t.floating[o]&&(s=Tl(s)),[s,Tl(s)]}function Wb(e){const t=Tl(e);return[Oc(e),t,Oc(t)]}function Oc(e){return e.replace(/start|end/g,t=>Bb[t])}const Kh=["left","right"],Gh=["right","left"],Hb=["top","bottom"],Kb=["bottom","top"];function Gb(e,t,n){switch(e){case"top":case"bottom":return n?t?Gh:Kh:t?Kh:Gh;case"left":case"right":return t?Hb:Kb;default:return[]}}function Qb(e,t,n,r){const i=ki(e);let o=Gb(mn(e),n==="start",r);return i&&(o=o.map(s=>s+"-"+i),t&&(o=o.concat(o.map(Oc)))),o}function Tl(e){return e.replace(/left|right|bottom|top/g,t=>Ub[t])}function Yb(e){return{top:0,right:0,bottom:0,left:0,...e}}function Ym(e){return typeof e!="number"?Yb(e):{top:e,right:e,bottom:e,left:e}}function Rl(e){const{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function Qh(e,t,n){let{reference:r,floating:i}=e;const o=zt(t),s=Kf(t),l=Hf(s),a=mn(t),u=o==="y",c=r.x+r.width/2-i.width/2,f=r.y+r.height/2-i.height/2,d=r[l]/2-i[l]/2;let p;switch(a){case"top":p={x:c,y:r.y-i.height};break;case"bottom":p={x:c,y:r.y+r.height};break;case"right":p={x:r.x+r.width,y:f};break;case"left":p={x:r.x-i.width,y:f};break;default:p={x:r.x,y:r.y}}switch(ki(t)){case"start":p[s]-=d*(n&&u?-1:1);break;case"end":p[s]+=d*(n&&u?-1:1);break}return p}const Xb=async(e,t,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:o=[],platform:s}=n,l=o.filter(Boolean),a=await(s.isRTL==null?void 0:s.isRTL(t));let u=await s.getElementRects({reference:e,floating:t,strategy:i}),{x:c,y:f}=Qh(u,r,a),d=r,p={},y=0;for(let m=0;m<l.length;m++){const{name:b,fn:v}=l[m],{x:g,y:w,data:_,reset:S}=await v({x:c,y:f,initialPlacement:r,placement:d,strategy:i,middlewareData:p,rects:u,platform:s,elements:{reference:e,floating:t}});c=g??c,f=w??f,p={...p,[b]:{...p[b],..._}},S&&y<=50&&(y++,typeof S=="object"&&(S.placement&&(d=S.placement),S.rects&&(u=S.rects===!0?await s.getElementRects({reference:e,floating:t,strategy:i}):S.rects),{x:c,y:f}=Qh(u,d,a)),m=-1)}return{x:c,y:f,placement:d,strategy:i,middlewareData:p}};async function Do(e,t){var n;t===void 0&&(t={});const{x:r,y:i,platform:o,rects:s,elements:l,strategy:a}=e,{boundary:u="clippingAncestors",rootBoundary:c="viewport",elementContext:f="floating",altBoundary:d=!1,padding:p=0}=gn(t,e),y=Ym(p),b=l[d?f==="floating"?"reference":"floating":f],v=Rl(await o.getClippingRect({element:(n=await(o.isElement==null?void 0:o.isElement(b)))==null||n?b:b.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(l.floating)),boundary:u,rootBoundary:c,strategy:a})),g=f==="floating"?{x:r,y:i,width:s.floating.width,height:s.floating.height}:s.reference,w=await(o.getOffsetParent==null?void 0:o.getOffsetParent(l.floating)),_=await(o.isElement==null?void 0:o.isElement(w))?await(o.getScale==null?void 0:o.getScale(w))||{x:1,y:1}:{x:1,y:1},S=Rl(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:g,offsetParent:w,strategy:a}):g);return{top:(v.top-S.top+y.top)/_.y,bottom:(S.bottom-v.bottom+y.bottom)/_.y,left:(v.left-S.left+y.left)/_.x,right:(S.right-v.right+y.right)/_.x}}const Zb=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:i,rects:o,platform:s,elements:l,middlewareData:a}=t,{element:u,padding:c=0}=gn(e,t)||{};if(u==null)return{};const f=Ym(c),d={x:n,y:r},p=Kf(i),y=Hf(p),m=await s.getDimensions(u),b=p==="y",v=b?"top":"left",g=b?"bottom":"right",w=b?"clientHeight":"clientWidth",_=o.reference[y]+o.reference[p]-d[p]-o.floating[y],S=d[p]-o.reference[p],E=await(s.getOffsetParent==null?void 0:s.getOffsetParent(u));let A=E?E[w]:0;(!A||!await(s.isElement==null?void 0:s.isElement(E)))&&(A=l.floating[w]||o.floating[y]);const C=_/2-S/2,j=A/2-m[y]/2-1,P=Kn(f[v],j),D=Kn(f[g],j),k=P,z=A-m[y]-D,B=A/2-m[y]/2+C,K=kc(k,B,z),Z=!a.arrow&&ki(i)!=null&&B!==K&&o.reference[y]/2-(B<k?P:D)-m[y]/2<0,J=Z?B<k?B-k:B-z:0;return{[p]:d[p]+J,data:{[p]:K,centerOffset:B-K-J,...Z&&{alignmentOffset:J}},reset:Z}}}),Jb=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:i,middlewareData:o,rects:s,initialPlacement:l,platform:a,elements:u}=t,{mainAxis:c=!0,crossAxis:f=!0,fallbackPlacements:d,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:y="none",flipAlignment:m=!0,...b}=gn(e,t);if((n=o.arrow)!=null&&n.alignmentOffset)return{};const v=mn(i),g=zt(l),w=mn(l)===l,_=await(a.isRTL==null?void 0:a.isRTL(u.floating)),S=d||(w||!m?[Tl(l)]:Wb(l)),E=y!=="none";!d&&E&&S.push(...Qb(l,m,y,_));const A=[l,...S],C=await Do(t,b),j=[];let P=((r=o.flip)==null?void 0:r.overflows)||[];if(c&&j.push(C[v]),f){const B=Vb(i,s,_);j.push(C[B[0]],C[B[1]])}if(P=[...P,{placement:i,overflows:j}],!j.every(B=>B<=0)){var D,k;const B=(((D=o.flip)==null?void 0:D.index)||0)+1,K=A[B];if(K&&(!(f==="alignment"?g!==zt(K):!1)||P.every(O=>zt(O.placement)===g?O.overflows[0]>0:!0)))return{data:{index:B,overflows:P},reset:{placement:K}};let Z=(k=P.filter(J=>J.overflows[0]<=0).sort((J,O)=>J.overflows[1]-O.overflows[1])[0])==null?void 0:k.placement;if(!Z)switch(p){case"bestFit":{var z;const J=(z=P.filter(O=>{if(E){const R=zt(O.placement);return R===g||R==="y"}return!0}).map(O=>[O.placement,O.overflows.filter(R=>R>0).reduce((R,F)=>R+F,0)]).sort((O,R)=>O[1]-R[1])[0])==null?void 0:z[0];J&&(Z=J);break}case"initialPlacement":Z=l;break}if(i!==Z)return{reset:{placement:Z}}}return{}}}};function Yh(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Xh(e){return zb.some(t=>e[t]>=0)}const qb=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...i}=gn(e,t);switch(r){case"referenceHidden":{const o=await Do(t,{...i,elementContext:"reference"}),s=Yh(o,n.reference);return{data:{referenceHiddenOffsets:s,referenceHidden:Xh(s)}}}case"escaped":{const o=await Do(t,{...i,altBoundary:!0}),s=Yh(o,n.floating);return{data:{escapedOffsets:s,escaped:Xh(s)}}}default:return{}}}}},Xm=new Set(["left","top"]);async function eS(e,t){const{placement:n,platform:r,elements:i}=e,o=await(r.isRTL==null?void 0:r.isRTL(i.floating)),s=mn(n),l=ki(n),a=zt(n)==="y",u=Xm.has(s)?-1:1,c=o&&a?-1:1,f=gn(t,e);let{mainAxis:d,crossAxis:p,alignmentAxis:y}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:f.mainAxis||0,crossAxis:f.crossAxis||0,alignmentAxis:f.alignmentAxis};return l&&typeof y=="number"&&(p=l==="end"?y*-1:y),a?{x:p*c,y:d*u}:{x:d*u,y:p*c}}const tS=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:i,y:o,placement:s,middlewareData:l}=t,a=await eS(t,e);return s===((n=l.offset)==null?void 0:n.placement)&&(r=l.arrow)!=null&&r.alignmentOffset?{}:{x:i+a.x,y:o+a.y,data:{...a,placement:s}}}}},nS=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:i}=t,{mainAxis:o=!0,crossAxis:s=!1,limiter:l={fn:b=>{let{x:v,y:g}=b;return{x:v,y:g}}},...a}=gn(e,t),u={x:n,y:r},c=await Do(t,a),f=zt(mn(i)),d=Wf(f);let p=u[d],y=u[f];if(o){const b=d==="y"?"top":"left",v=d==="y"?"bottom":"right",g=p+c[b],w=p-c[v];p=kc(g,p,w)}if(s){const b=f==="y"?"top":"left",v=f==="y"?"bottom":"right",g=y+c[b],w=y-c[v];y=kc(g,y,w)}const m=l.fn({...t,[d]:p,[f]:y});return{...m,data:{x:m.x-n,y:m.y-r,enabled:{[d]:o,[f]:s}}}}}},rS=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:i,rects:o,middlewareData:s}=t,{offset:l=0,mainAxis:a=!0,crossAxis:u=!0}=gn(e,t),c={x:n,y:r},f=zt(i),d=Wf(f);let p=c[d],y=c[f];const m=gn(l,t),b=typeof m=="number"?{mainAxis:m,crossAxis:0}:{mainAxis:0,crossAxis:0,...m};if(a){const w=d==="y"?"height":"width",_=o.reference[d]-o.floating[w]+b.mainAxis,S=o.reference[d]+o.reference[w]-b.mainAxis;p<_?p=_:p>S&&(p=S)}if(u){var v,g;const w=d==="y"?"width":"height",_=Xm.has(mn(i)),S=o.reference[f]-o.floating[w]+(_&&((v=s.offset)==null?void 0:v[f])||0)+(_?0:b.crossAxis),E=o.reference[f]+o.reference[w]+(_?0:((g=s.offset)==null?void 0:g[f])||0)-(_?b.crossAxis:0);y<S?y=S:y>E&&(y=E)}return{[d]:p,[f]:y}}}},iS=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:i,rects:o,platform:s,elements:l}=t,{apply:a=()=>{},...u}=gn(e,t),c=await Do(t,u),f=mn(i),d=ki(i),p=zt(i)==="y",{width:y,height:m}=o.floating;let b,v;f==="top"||f==="bottom"?(b=f,v=d===(await(s.isRTL==null?void 0:s.isRTL(l.floating))?"start":"end")?"left":"right"):(v=f,b=d==="end"?"top":"bottom");const g=m-c.top-c.bottom,w=y-c.left-c.right,_=Kn(m-c[b],g),S=Kn(y-c[v],w),E=!t.middlewareData.shift;let A=_,C=S;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(C=w),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(A=g),E&&!d){const P=Ge(c.left,0),D=Ge(c.right,0),k=Ge(c.top,0),z=Ge(c.bottom,0);p?C=y-2*(P!==0||D!==0?P+D:Ge(c.left,c.right)):A=m-2*(k!==0||z!==0?k+z:Ge(c.top,c.bottom))}await a({...t,availableWidth:C,availableHeight:A});const j=await s.getDimensions(l.floating);return y!==j.width||m!==j.height?{reset:{rects:!0}}:{}}}};function ca(){return typeof window<"u"}function Oi(e){return Zm(e)?(e.nodeName||"").toLowerCase():"#document"}function Je(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Qt(e){var t;return(t=(Zm(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Zm(e){return ca()?e instanceof Node||e instanceof Je(e).Node:!1}function kt(e){return ca()?e instanceof Element||e instanceof Je(e).Element:!1}function Gt(e){return ca()?e instanceof HTMLElement||e instanceof Je(e).HTMLElement:!1}function Zh(e){return!ca()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Je(e).ShadowRoot}const oS=new Set(["inline","contents"]);function ts(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=Ot(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!oS.has(i)}const sS=new Set(["table","td","th"]);function lS(e){return sS.has(Oi(e))}const aS=[":popover-open",":modal"];function fa(e){return aS.some(t=>{try{return e.matches(t)}catch{return!1}})}const uS=["transform","translate","scale","rotate","perspective"],cS=["transform","translate","scale","rotate","perspective","filter"],fS=["paint","layout","strict","content"];function Gf(e){const t=Qf(),n=kt(e)?Ot(e):e;return uS.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||cS.some(r=>(n.willChange||"").includes(r))||fS.some(r=>(n.contain||"").includes(r))}function dS(e){let t=Gn(e);for(;Gt(t)&&!xi(t);){if(Gf(t))return t;if(fa(t))return null;t=Gn(t)}return null}function Qf(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const hS=new Set(["html","body","#document"]);function xi(e){return hS.has(Oi(e))}function Ot(e){return Je(e).getComputedStyle(e)}function da(e){return kt(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Gn(e){if(Oi(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Zh(e)&&e.host||Qt(e);return Zh(t)?t.host:t}function Jm(e){const t=Gn(e);return xi(t)?e.ownerDocument?e.ownerDocument.body:e.body:Gt(t)&&ts(t)?t:Jm(t)}function Mo(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const i=Jm(e),o=i===((r=e.ownerDocument)==null?void 0:r.body),s=Je(i);if(o){const l=Pc(s);return t.concat(s,s.visualViewport||[],ts(i)?i:[],l&&n?Mo(l):[])}return t.concat(i,Mo(i,[],n))}function Pc(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function qm(e){const t=Ot(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const i=Gt(e),o=i?e.offsetWidth:n,s=i?e.offsetHeight:r,l=jl(n)!==o||jl(r)!==s;return l&&(n=o,r=s),{width:n,height:r,$:l}}function Yf(e){return kt(e)?e:e.contextElement}function ii(e){const t=Yf(e);if(!Gt(t))return Ht(1);const n=t.getBoundingClientRect(),{width:r,height:i,$:o}=qm(t);let s=(o?jl(n.width):n.width)/r,l=(o?jl(n.height):n.height)/i;return(!s||!Number.isFinite(s))&&(s=1),(!l||!Number.isFinite(l))&&(l=1),{x:s,y:l}}const pS=Ht(0);function e0(e){const t=Je(e);return!Qf()||!t.visualViewport?pS:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function vS(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Je(e)?!1:t}function Er(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const i=e.getBoundingClientRect(),o=Yf(e);let s=Ht(1);t&&(r?kt(r)&&(s=ii(r)):s=ii(e));const l=vS(o,n,r)?e0(o):Ht(0);let a=(i.left+l.x)/s.x,u=(i.top+l.y)/s.y,c=i.width/s.x,f=i.height/s.y;if(o){const d=Je(o),p=r&&kt(r)?Je(r):r;let y=d,m=Pc(y);for(;m&&r&&p!==y;){const b=ii(m),v=m.getBoundingClientRect(),g=Ot(m),w=v.left+(m.clientLeft+parseFloat(g.paddingLeft))*b.x,_=v.top+(m.clientTop+parseFloat(g.paddingTop))*b.y;a*=b.x,u*=b.y,c*=b.x,f*=b.y,a+=w,u+=_,y=Je(m),m=Pc(y)}}return Rl({width:c,height:f,x:a,y:u})}function ha(e,t){const n=da(e).scrollLeft;return t?t.left+n:Er(Qt(e)).left+n}function t0(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-ha(e,n),i=n.top+t.scrollTop;return{x:r,y:i}}function gS(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e;const o=i==="fixed",s=Qt(r),l=t?fa(t.floating):!1;if(r===s||l&&o)return n;let a={scrollLeft:0,scrollTop:0},u=Ht(1);const c=Ht(0),f=Gt(r);if((f||!f&&!o)&&((Oi(r)!=="body"||ts(s))&&(a=da(r)),Gt(r))){const p=Er(r);u=ii(r),c.x=p.x+r.clientLeft,c.y=p.y+r.clientTop}const d=s&&!f&&!o?t0(s,a):Ht(0);return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-a.scrollLeft*u.x+c.x+d.x,y:n.y*u.y-a.scrollTop*u.y+c.y+d.y}}function mS(e){return Array.from(e.getClientRects())}function yS(e){const t=Qt(e),n=da(e),r=e.ownerDocument.body,i=Ge(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),o=Ge(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let s=-n.scrollLeft+ha(e);const l=-n.scrollTop;return Ot(r).direction==="rtl"&&(s+=Ge(t.clientWidth,r.clientWidth)-i),{width:i,height:o,x:s,y:l}}const Jh=25;function wS(e,t){const n=Je(e),r=Qt(e),i=n.visualViewport;let o=r.clientWidth,s=r.clientHeight,l=0,a=0;if(i){o=i.width,s=i.height;const c=Qf();(!c||c&&t==="fixed")&&(l=i.offsetLeft,a=i.offsetTop)}const u=ha(r);if(u<=0){const c=r.ownerDocument,f=c.body,d=getComputedStyle(f),p=c.compatMode==="CSS1Compat"&&parseFloat(d.marginLeft)+parseFloat(d.marginRight)||0,y=Math.abs(r.clientWidth-f.clientWidth-p);y<=Jh&&(o-=y)}else u<=Jh&&(o+=u);return{width:o,height:s,x:l,y:a}}const xS=new Set(["absolute","fixed"]);function _S(e,t){const n=Er(e,!0,t==="fixed"),r=n.top+e.clientTop,i=n.left+e.clientLeft,o=Gt(e)?ii(e):Ht(1),s=e.clientWidth*o.x,l=e.clientHeight*o.y,a=i*o.x,u=r*o.y;return{width:s,height:l,x:a,y:u}}function qh(e,t,n){let r;if(t==="viewport")r=wS(e,n);else if(t==="document")r=yS(Qt(e));else if(kt(t))r=_S(t,n);else{const i=e0(e);r={x:t.x-i.x,y:t.y-i.y,width:t.width,height:t.height}}return Rl(r)}function n0(e,t){const n=Gn(e);return n===t||!kt(n)||xi(n)?!1:Ot(n).position==="fixed"||n0(n,t)}function bS(e,t){const n=t.get(e);if(n)return n;let r=Mo(e,[],!1).filter(l=>kt(l)&&Oi(l)!=="body"),i=null;const o=Ot(e).position==="fixed";let s=o?Gn(e):e;for(;kt(s)&&!xi(s);){const l=Ot(s),a=Gf(s);!a&&l.position==="fixed"&&(i=null),(o?!a&&!i:!a&&l.position==="static"&&!!i&&xS.has(i.position)||ts(s)&&!a&&n0(e,s))?r=r.filter(c=>c!==s):i=l,s=Gn(s)}return t.set(e,r),r}function SS(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e;const s=[...n==="clippingAncestors"?fa(t)?[]:bS(t,this._c):[].concat(n),r],l=s[0],a=s.reduce((u,c)=>{const f=qh(t,c,i);return u.top=Ge(f.top,u.top),u.right=Kn(f.right,u.right),u.bottom=Kn(f.bottom,u.bottom),u.left=Ge(f.left,u.left),u},qh(t,l,i));return{width:a.right-a.left,height:a.bottom-a.top,x:a.left,y:a.top}}function ES(e){const{width:t,height:n}=qm(e);return{width:t,height:n}}function AS(e,t,n){const r=Gt(t),i=Qt(t),o=n==="fixed",s=Er(e,!0,o,t);let l={scrollLeft:0,scrollTop:0};const a=Ht(0);function u(){a.x=ha(i)}if(r||!r&&!o)if((Oi(t)!=="body"||ts(i))&&(l=da(t)),r){const p=Er(t,!0,o,t);a.x=p.x+t.clientLeft,a.y=p.y+t.clientTop}else i&&u();o&&!r&&i&&u();const c=i&&!r&&!o?t0(i,l):Ht(0),f=s.left+l.scrollLeft-a.x-c.x,d=s.top+l.scrollTop-a.y-c.y;return{x:f,y:d,width:s.width,height:s.height}}function su(e){return Ot(e).position==="static"}function ep(e,t){if(!Gt(e)||Ot(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Qt(e)===n&&(n=n.ownerDocument.body),n}function r0(e,t){const n=Je(e);if(fa(e))return n;if(!Gt(e)){let i=Gn(e);for(;i&&!xi(i);){if(kt(i)&&!su(i))return i;i=Gn(i)}return n}let r=ep(e,t);for(;r&&lS(r)&&su(r);)r=ep(r,t);return r&&xi(r)&&su(r)&&!Gf(r)?n:r||dS(e)||n}const CS=async function(e){const t=this.getOffsetParent||r0,n=this.getDimensions,r=await n(e.floating);return{reference:AS(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function kS(e){return Ot(e).direction==="rtl"}const OS={convertOffsetParentRelativeRectToViewportRelativeRect:gS,getDocumentElement:Qt,getClippingRect:SS,getOffsetParent:r0,getElementRects:CS,getClientRects:mS,getDimensions:ES,getScale:ii,isElement:kt,isRTL:kS};function i0(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function PS(e,t){let n=null,r;const i=Qt(e);function o(){var l;clearTimeout(r),(l=n)==null||l.disconnect(),n=null}function s(l,a){l===void 0&&(l=!1),a===void 0&&(a=1),o();const u=e.getBoundingClientRect(),{left:c,top:f,width:d,height:p}=u;if(l||t(),!d||!p)return;const y=Cs(f),m=Cs(i.clientWidth-(c+d)),b=Cs(i.clientHeight-(f+p)),v=Cs(c),w={rootMargin:-y+"px "+-m+"px "+-b+"px "+-v+"px",threshold:Ge(0,Kn(1,a))||1};let _=!0;function S(E){const A=E[0].intersectionRatio;if(A!==a){if(!_)return s();A?s(!1,A):r=setTimeout(()=>{s(!1,1e-7)},1e3)}A===1&&!i0(u,e.getBoundingClientRect())&&s(),_=!1}try{n=new IntersectionObserver(S,{...w,root:i.ownerDocument})}catch{n=new IntersectionObserver(S,w)}n.observe(e)}return s(!0),o}function NS(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:l=typeof IntersectionObserver=="function",animationFrame:a=!1}=r,u=Yf(e),c=i||o?[...u?Mo(u):[],...Mo(t)]:[];c.forEach(v=>{i&&v.addEventListener("scroll",n,{passive:!0}),o&&v.addEventListener("resize",n)});const f=u&&l?PS(u,n):null;let d=-1,p=null;s&&(p=new ResizeObserver(v=>{let[g]=v;g&&g.target===u&&p&&(p.unobserve(t),cancelAnimationFrame(d),d=requestAnimationFrame(()=>{var w;(w=p)==null||w.observe(t)})),n()}),u&&!a&&p.observe(u),p.observe(t));let y,m=a?Er(e):null;a&&b();function b(){const v=Er(e);m&&!i0(m,v)&&n(),m=v,y=requestAnimationFrame(b)}return n(),()=>{var v;c.forEach(g=>{i&&g.removeEventListener("scroll",n),o&&g.removeEventListener("resize",n)}),f==null||f(),(v=p)==null||v.disconnect(),p=null,a&&cancelAnimationFrame(y)}}const jS=tS,TS=nS,RS=Jb,DS=iS,MS=qb,tp=Zb,LS=rS,IS=(e,t,n)=>{const r=new Map,i={platform:OS,...n},o={...i.platform,_c:r};return Xb(e,t,{...i,platform:o})};var FS=typeof document<"u",zS=function(){},Ys=FS?x.useLayoutEffect:zS;function Dl(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!Dl(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){const o=i[r];if(!(o==="_owner"&&e.$$typeof)&&!Dl(e[o],t[o]))return!1}return!0}return e!==e&&t!==t}function o0(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function np(e,t){const n=o0(e);return Math.round(t*n)/n}function lu(e){const t=x.useRef(e);return Ys(()=>{t.current=e}),t}function US(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:o,floating:s}={},transform:l=!0,whileElementsMounted:a,open:u}=e,[c,f]=x.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[d,p]=x.useState(r);Dl(d,r)||p(r);const[y,m]=x.useState(null),[b,v]=x.useState(null),g=x.useCallback(O=>{O!==E.current&&(E.current=O,m(O))},[]),w=x.useCallback(O=>{O!==A.current&&(A.current=O,v(O))},[]),_=o||y,S=s||b,E=x.useRef(null),A=x.useRef(null),C=x.useRef(c),j=a!=null,P=lu(a),D=lu(i),k=lu(u),z=x.useCallback(()=>{if(!E.current||!A.current)return;const O={placement:t,strategy:n,middleware:d};D.current&&(O.platform=D.current),IS(E.current,A.current,O).then(R=>{const F={...R,isPositioned:k.current!==!1};B.current&&!Dl(C.current,F)&&(C.current=F,Wo.flushSync(()=>{f(F)}))})},[d,t,n,D,k]);Ys(()=>{u===!1&&C.current.isPositioned&&(C.current.isPositioned=!1,f(O=>({...O,isPositioned:!1})))},[u]);const B=x.useRef(!1);Ys(()=>(B.current=!0,()=>{B.current=!1}),[]),Ys(()=>{if(_&&(E.current=_),S&&(A.current=S),_&&S){if(P.current)return P.current(_,S,z);z()}},[_,S,z,P,j]);const K=x.useMemo(()=>({reference:E,floating:A,setReference:g,setFloating:w}),[g,w]),Z=x.useMemo(()=>({reference:_,floating:S}),[_,S]),J=x.useMemo(()=>{const O={position:n,left:0,top:0};if(!Z.floating)return O;const R=np(Z.floating,c.x),F=np(Z.floating,c.y);return l?{...O,transform:"translate("+R+"px, "+F+"px)",...o0(Z.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:R,top:F}},[n,l,Z.floating,c.x,c.y]);return x.useMemo(()=>({...c,update:z,refs:K,elements:Z,floatingStyles:J}),[c,z,K,Z,J])}const BS=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:i}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?tp({element:r.current,padding:i}).fn(n):{}:r?tp({element:r,padding:i}).fn(n):{}}}},$S=(e,t)=>({...jS(e),options:[e,t]}),VS=(e,t)=>({...TS(e),options:[e,t]}),WS=(e,t)=>({...LS(e),options:[e,t]}),HS=(e,t)=>({...RS(e),options:[e,t]}),KS=(e,t)=>({...DS(e),options:[e,t]}),GS=(e,t)=>({...MS(e),options:[e,t]}),QS=(e,t)=>({...BS(e),options:[e,t]});var YS="Arrow",s0=x.forwardRef((e,t)=>{const{children:n,width:r=10,height:i=5,...o}=e;return h.jsx(wn.svg,{...o,ref:t,width:r,height:i,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:h.jsx("polygon",{points:"0,0 30,0 15,10"})})});s0.displayName=YS;var XS=s0;function ZS(e){const[t,n]=x.useState(void 0);return Hn(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(i=>{if(!Array.isArray(i)||!i.length)return;const o=i[0];let s,l;if("borderBoxSize"in o){const a=o.borderBoxSize,u=Array.isArray(a)?a[0]:a;s=u.inlineSize,l=u.blockSize}else s=e.offsetWidth,l=e.offsetHeight;n({width:s,height:l})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var Xf="Popper",[l0,a0]=$m(Xf),[JS,u0]=l0(Xf),c0=e=>{const{__scopePopper:t,children:n}=e,[r,i]=x.useState(null);return h.jsx(JS,{scope:t,anchor:r,onAnchorChange:i,children:n})};c0.displayName=Xf;var f0="PopperAnchor",d0=x.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...i}=e,o=u0(f0,n),s=x.useRef(null),l=tr(t,s),a=x.useRef(null);return x.useEffect(()=>{const u=a.current;a.current=(r==null?void 0:r.current)||s.current,u!==a.current&&o.onAnchorChange(a.current)}),r?null:h.jsx(wn.div,{...i,ref:l})});d0.displayName=f0;var Zf="PopperContent",[qS,eE]=l0(Zf),h0=x.forwardRef((e,t)=>{var ze,Ti,Ri,Di,Mi,Xt;const{__scopePopper:n,side:r="bottom",sideOffset:i=0,align:o="center",alignOffset:s=0,arrowPadding:l=0,avoidCollisions:a=!0,collisionBoundary:u=[],collisionPadding:c=0,sticky:f="partial",hideWhenDetached:d=!1,updatePositionStrategy:p="optimized",onPlaced:y,...m}=e,b=u0(Zf,n),[v,g]=x.useState(null),w=tr(t,Zt=>g(Zt)),[_,S]=x.useState(null),E=ZS(_),A=(E==null?void 0:E.width)??0,C=(E==null?void 0:E.height)??0,j=r+(o!=="center"?"-"+o:""),P=typeof c=="number"?c:{top:0,right:0,bottom:0,left:0,...c},D=Array.isArray(u)?u:[u],k=D.length>0,z={padding:P,boundary:D.filter(nE),altBoundary:k},{refs:B,floatingStyles:K,placement:Z,isPositioned:J,middlewareData:O}=US({strategy:"fixed",placement:j,whileElementsMounted:(...Zt)=>NS(...Zt,{animationFrame:p==="always"}),elements:{reference:b.anchor},middleware:[$S({mainAxis:i+C,alignmentAxis:s}),a&&VS({mainAxis:!0,crossAxis:!1,limiter:f==="partial"?WS():void 0,...z}),a&&HS({...z}),KS({...z,apply:({elements:Zt,rects:rr,availableWidth:Nr,availableHeight:ma})=>{const{width:ya,height:wa}=rr.reference,ir=Zt.floating.style;ir.setProperty("--radix-popper-available-width",`${Nr}px`),ir.setProperty("--radix-popper-available-height",`${ma}px`),ir.setProperty("--radix-popper-anchor-width",`${ya}px`),ir.setProperty("--radix-popper-anchor-height",`${wa}px`)}}),_&&QS({element:_,padding:l}),rE({arrowWidth:A,arrowHeight:C}),d&&GS({strategy:"referenceHidden",...z})]}),[R,F]=g0(Z),H=wi(y);Hn(()=>{J&&(H==null||H())},[J,H]);const ce=(ze=O.arrow)==null?void 0:ze.x,Yt=(Ti=O.arrow)==null?void 0:Ti.y,rt=((Ri=O.arrow)==null?void 0:Ri.centerOffset)!==0,[jt,Fe]=x.useState();return Hn(()=>{v&&Fe(window.getComputedStyle(v).zIndex)},[v]),h.jsx("div",{ref:B.setFloating,"data-radix-popper-content-wrapper":"",style:{...K,transform:J?K.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:jt,"--radix-popper-transform-origin":[(Di=O.transformOrigin)==null?void 0:Di.x,(Mi=O.transformOrigin)==null?void 0:Mi.y].join(" "),...((Xt=O.hide)==null?void 0:Xt.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:h.jsx(qS,{scope:n,placedSide:R,onArrowChange:S,arrowX:ce,arrowY:Yt,shouldHideArrow:rt,children:h.jsx(wn.div,{"data-side":R,"data-align":F,...m,ref:w,style:{...m.style,animation:J?void 0:"none"}})})})});h0.displayName=Zf;var p0="PopperArrow",tE={top:"bottom",right:"left",bottom:"top",left:"right"},v0=x.forwardRef(function(t,n){const{__scopePopper:r,...i}=t,o=eE(p0,r),s=tE[o.placedSide];return h.jsx("span",{ref:o.onArrowChange,style:{position:"absolute",left:o.arrowX,top:o.arrowY,[s]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[o.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[o.placedSide],visibility:o.shouldHideArrow?"hidden":void 0},children:h.jsx(XS,{...i,ref:n,style:{...i.style,display:"block"}})})});v0.displayName=p0;function nE(e){return e!==null}var rE=e=>({name:"transformOrigin",options:e,fn(t){var b,v,g;const{placement:n,rects:r,middlewareData:i}=t,s=((b=i.arrow)==null?void 0:b.centerOffset)!==0,l=s?0:e.arrowWidth,a=s?0:e.arrowHeight,[u,c]=g0(n),f={start:"0%",center:"50%",end:"100%"}[c],d=(((v=i.arrow)==null?void 0:v.x)??0)+l/2,p=(((g=i.arrow)==null?void 0:g.y)??0)+a/2;let y="",m="";return u==="bottom"?(y=s?f:`${d}px`,m=`${-a}px`):u==="top"?(y=s?f:`${d}px`,m=`${r.floating.height+a}px`):u==="right"?(y=`${-a}px`,m=s?f:`${p}px`):u==="left"&&(y=`${r.floating.width+a}px`,m=s?f:`${p}px`),{data:{x:y,y:m}}}});function g0(e){const[t,n="center"]=e.split("-");return[t,n]}var iE=c0,m0=d0,oE=h0,sE=v0,lE="Portal",y0=x.forwardRef((e,t)=>{var l;const{container:n,...r}=e,[i,o]=x.useState(!1);Hn(()=>o(!0),[]);const s=n||i&&((l=globalThis==null?void 0:globalThis.document)==null?void 0:l.body);return s?o1.createPortal(h.jsx(wn.div,{...r,ref:t}),s):null});y0.displayName=lE;function aE(e,t){return x.useReducer((n,r)=>t[n][r]??n,e)}var Jf=e=>{const{present:t,children:n}=e,r=uE(t),i=typeof n=="function"?n({present:r.isPresent}):x.Children.only(n),o=tr(r.ref,cE(i));return typeof n=="function"||r.isPresent?x.cloneElement(i,{ref:o}):null};Jf.displayName="Presence";function uE(e){const[t,n]=x.useState(),r=x.useRef(null),i=x.useRef(e),o=x.useRef("none"),s=e?"mounted":"unmounted",[l,a]=aE(s,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return x.useEffect(()=>{const u=ks(r.current);o.current=l==="mounted"?u:"none"},[l]),Hn(()=>{const u=r.current,c=i.current;if(c!==e){const d=o.current,p=ks(u);e?a("MOUNT"):p==="none"||(u==null?void 0:u.display)==="none"?a("UNMOUNT"):a(c&&d!==p?"ANIMATION_OUT":"UNMOUNT"),i.current=e}},[e,a]),Hn(()=>{if(t){let u;const c=t.ownerDocument.defaultView??window,f=p=>{const m=ks(r.current).includes(CSS.escape(p.animationName));if(p.target===t&&m&&(a("ANIMATION_END"),!i.current)){const b=t.style.animationFillMode;t.style.animationFillMode="forwards",u=c.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=b)})}},d=p=>{p.target===t&&(o.current=ks(r.current))};return t.addEventListener("animationstart",d),t.addEventListener("animationcancel",f),t.addEventListener("animationend",f),()=>{c.clearTimeout(u),t.removeEventListener("animationstart",d),t.removeEventListener("animationcancel",f),t.removeEventListener("animationend",f)}}else a("ANIMATION_END")},[t,a]),{isPresent:["mounted","unmountSuspended"].includes(l),ref:x.useCallback(u=>{r.current=u?getComputedStyle(u):null,n(u)},[])}}function ks(e){return(e==null?void 0:e.animationName)||"none"}function cE(e){var r,i;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var fE=Kp[" useInsertionEffect ".trim().toString()]||Hn;function dE({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[i,o,s]=hE({defaultProp:t,onChange:n}),l=e!==void 0,a=l?e:i;{const c=x.useRef(e!==void 0);x.useEffect(()=>{const f=c.current;f!==l&&console.warn(`${r} is changing from ${f?"controlled":"uncontrolled"} to ${l?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),c.current=l},[l,r])}const u=x.useCallback(c=>{var f;if(l){const d=pE(c)?c(e):c;d!==e&&((f=s.current)==null||f.call(s,d))}else o(c)},[l,e,o,s]);return[a,u]}function hE({defaultProp:e,onChange:t}){const[n,r]=x.useState(e),i=x.useRef(n),o=x.useRef(t);return fE(()=>{o.current=t},[t]),x.useEffect(()=>{var s;i.current!==n&&((s=o.current)==null||s.call(o,n),i.current=n)},[n,i]),[n,r,o]}function pE(e){return typeof e=="function"}var vE=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Dr=new WeakMap,Os=new WeakMap,Ps={},au=0,w0=function(e){return e&&(e.host||w0(e.parentNode))},gE=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=w0(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},mE=function(e,t,n,r){var i=gE(t,Array.isArray(e)?e:[e]);Ps[n]||(Ps[n]=new WeakMap);var o=Ps[n],s=[],l=new Set,a=new Set(i),u=function(f){!f||l.has(f)||(l.add(f),u(f.parentNode))};i.forEach(u);var c=function(f){!f||a.has(f)||Array.prototype.forEach.call(f.children,function(d){if(l.has(d))c(d);else try{var p=d.getAttribute(r),y=p!==null&&p!=="false",m=(Dr.get(d)||0)+1,b=(o.get(d)||0)+1;Dr.set(d,m),o.set(d,b),s.push(d),m===1&&y&&Os.set(d,!0),b===1&&d.setAttribute(n,"true"),y||d.setAttribute(r,"true")}catch(v){console.error("aria-hidden: cannot operate on ",d,v)}})};return c(t),l.clear(),au++,function(){s.forEach(function(f){var d=Dr.get(f)-1,p=o.get(f)-1;Dr.set(f,d),o.set(f,p),d||(Os.has(f)||f.removeAttribute(r),Os.delete(f)),p||f.removeAttribute(n)}),au--,au||(Dr=new WeakMap,Dr=new WeakMap,Os=new WeakMap,Ps={})}},yE=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),i=vE(e);return i?(r.push.apply(r,Array.from(i.querySelectorAll("[aria-live], script"))),mE(r,i,n,"aria-hidden")):function(){return null}},It=function(){return It=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},It.apply(this,arguments)};function x0(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function Pi(e,t,n,r){function i(o){return o instanceof n?o:new n(function(s){s(o)})}return new(n||(n=Promise))(function(o,s){function l(c){try{u(r.next(c))}catch(f){s(f)}}function a(c){try{u(r.throw(c))}catch(f){s(f)}}function u(c){c.done?o(c.value):i(c.value).then(l,a)}u((r=r.apply(e,t||[])).next())})}function Ni(e,t){var n={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},r,i,o,s=Object.create((typeof Iterator=="function"?Iterator:Object).prototype);return s.next=l(0),s.throw=l(1),s.return=l(2),typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function l(u){return function(c){return a([u,c])}}function a(u){if(r)throw new TypeError("Generator is already executing.");for(;s&&(s=0,u[0]&&(n=0)),n;)try{if(r=1,i&&(o=u[0]&2?i.return:u[0]?i.throw||((o=i.return)&&o.call(i),0):i.next)&&!(o=o.call(i,u[1])).done)return o;switch(i=0,o&&(u=[u[0]&2,o.value]),u[0]){case 0:case 1:o=u;break;case 4:return n.label++,{value:u[1],done:!1};case 5:n.label++,i=u[1],u=[0];continue;case 7:u=n.ops.pop(),n.trys.pop();continue;default:if(o=n.trys,!(o=o.length>0&&o[o.length-1])&&(u[0]===6||u[0]===2)){n=0;continue}if(u[0]===3&&(!o||u[1]>o[0]&&u[1]<o[3])){n.label=u[1];break}if(u[0]===6&&n.label<o[1]){n.label=o[1],o=u;break}if(o&&n.label<o[2]){n.label=o[2],n.ops.push(u);break}o[2]&&n.ops.pop(),n.trys.pop();continue}u=t.call(e,n)}catch(c){u=[6,c],i=0}finally{r=o=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}function wE(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var r=n.call(e),i,o=[],s;try{for(;(t===void 0||t-- >0)&&!(i=r.next()).done;)o.push(i.value)}catch(l){s={error:l}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(s)throw s.error}}return o}function xE(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(wE(arguments[t]));return e}function _E(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,o;r<i;r++)(o||!(r in t))&&(o||(o=Array.prototype.slice.call(t,0,r)),o[r]=t[r]);return e.concat(o||Array.prototype.slice.call(t))}var Xs="right-scroll-bar-position",Zs="width-before-scroll-bar",bE="with-scroll-bars-hidden",SE="--removed-body-scroll-bar-size";function uu(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function EE(e,t){var n=x.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var i=n.value;i!==r&&(n.value=r,n.callback(r,i))}}}})[0];return n.callback=t,n.facade}var AE=typeof window<"u"?x.useLayoutEffect:x.useEffect,rp=new WeakMap;function CE(e,t){var n=EE(null,function(r){return e.forEach(function(i){return uu(i,r)})});return AE(function(){var r=rp.get(n);if(r){var i=new Set(r),o=new Set(e),s=n.current;i.forEach(function(l){o.has(l)||uu(l,null)}),o.forEach(function(l){i.has(l)||uu(l,s)})}rp.set(n,e)},[e]),n}function kE(e){return e}function OE(e,t){t===void 0&&(t=kE);var n=[],r=!1,i={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(o){var s=t(o,r);return n.push(s),function(){n=n.filter(function(l){return l!==s})}},assignSyncMedium:function(o){for(r=!0;n.length;){var s=n;n=[],s.forEach(o)}n={push:function(l){return o(l)},filter:function(){return n}}},assignMedium:function(o){r=!0;var s=[];if(n.length){var l=n;n=[],l.forEach(o),s=n}var a=function(){var c=s;s=[],c.forEach(o)},u=function(){return Promise.resolve().then(a)};u(),n={push:function(c){s.push(c),u()},filter:function(c){return s=s.filter(c),n}}}};return i}function PE(e){e===void 0&&(e={});var t=OE(null);return t.options=It({async:!0,ssr:!1},e),t}var _0=function(e){var t=e.sideCar,n=x0(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return x.createElement(r,It({},n))};_0.isSideCarExport=!0;function NE(e,t){return e.useMedium(t),_0}var b0=PE(),cu=function(){},pa=x.forwardRef(function(e,t){var n=x.useRef(null),r=x.useState({onScrollCapture:cu,onWheelCapture:cu,onTouchMoveCapture:cu}),i=r[0],o=r[1],s=e.forwardProps,l=e.children,a=e.className,u=e.removeScrollBar,c=e.enabled,f=e.shards,d=e.sideCar,p=e.noRelative,y=e.noIsolation,m=e.inert,b=e.allowPinchZoom,v=e.as,g=v===void 0?"div":v,w=e.gapMode,_=x0(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),S=d,E=CE([n,t]),A=It(It({},_),i);return x.createElement(x.Fragment,null,c&&x.createElement(S,{sideCar:b0,removeScrollBar:u,shards:f,noRelative:p,noIsolation:y,inert:m,setCallbacks:o,allowPinchZoom:!!b,lockRef:n,gapMode:w}),s?x.cloneElement(x.Children.only(l),It(It({},A),{ref:E})):x.createElement(g,It({},A,{className:a,ref:E}),l))});pa.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};pa.classNames={fullWidth:Zs,zeroRight:Xs};var jE=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function TE(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=jE();return t&&e.setAttribute("nonce",t),e}function RE(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function DE(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var ME=function(){var e=0,t=null;return{add:function(n){e==0&&(t=TE())&&(RE(t,n),DE(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},LE=function(){var e=ME();return function(t,n){x.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},S0=function(){var e=LE(),t=function(n){var r=n.styles,i=n.dynamic;return e(r,i),null};return t},IE={left:0,top:0,right:0,gap:0},fu=function(e){return parseInt(e||"",10)||0},FE=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],i=t[e==="padding"?"paddingRight":"marginRight"];return[fu(n),fu(r),fu(i)]},zE=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return IE;var t=FE(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},UE=S0(),oi="data-scroll-locked",BE=function(e,t,n,r){var i=e.left,o=e.top,s=e.right,l=e.gap;return n===void 0&&(n="margin"),`
43
+ .`.concat(bE,` {
44
+ overflow: hidden `).concat(r,`;
45
+ padding-right: `).concat(l,"px ").concat(r,`;
46
+ }
47
+ body[`).concat(oi,`] {
48
+ overflow: hidden `).concat(r,`;
49
+ overscroll-behavior: contain;
50
+ `).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&`
51
+ padding-left: `.concat(i,`px;
52
+ padding-top: `).concat(o,`px;
53
+ padding-right: `).concat(s,`px;
54
+ margin-left:0;
55
+ margin-top:0;
56
+ margin-right: `).concat(l,"px ").concat(r,`;
57
+ `),n==="padding"&&"padding-right: ".concat(l,"px ").concat(r,";")].filter(Boolean).join(""),`
58
+ }
59
+
60
+ .`).concat(Xs,` {
61
+ right: `).concat(l,"px ").concat(r,`;
62
+ }
63
+
64
+ .`).concat(Zs,` {
65
+ margin-right: `).concat(l,"px ").concat(r,`;
66
+ }
67
+
68
+ .`).concat(Xs," .").concat(Xs,` {
69
+ right: 0 `).concat(r,`;
70
+ }
71
+
72
+ .`).concat(Zs," .").concat(Zs,` {
73
+ margin-right: 0 `).concat(r,`;
74
+ }
75
+
76
+ body[`).concat(oi,`] {
77
+ `).concat(SE,": ").concat(l,`px;
78
+ }
79
+ `)},ip=function(){var e=parseInt(document.body.getAttribute(oi)||"0",10);return isFinite(e)?e:0},$E=function(){x.useEffect(function(){return document.body.setAttribute(oi,(ip()+1).toString()),function(){var e=ip()-1;e<=0?document.body.removeAttribute(oi):document.body.setAttribute(oi,e.toString())}},[])},VE=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,i=r===void 0?"margin":r;$E();var o=x.useMemo(function(){return zE(i)},[i]);return x.createElement(UE,{styles:BE(o,!t,i,n?"":"!important")})},Nc=!1;if(typeof window<"u")try{var Ns=Object.defineProperty({},"passive",{get:function(){return Nc=!0,!0}});window.addEventListener("test",Ns,Ns),window.removeEventListener("test",Ns,Ns)}catch{Nc=!1}var Mr=Nc?{passive:!1}:!1,WE=function(e){return e.tagName==="TEXTAREA"},E0=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!WE(e)&&n[t]==="visible")},HE=function(e){return E0(e,"overflowY")},KE=function(e){return E0(e,"overflowX")},op=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var i=A0(e,r);if(i){var o=C0(e,r),s=o[1],l=o[2];if(s>l)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},GE=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},QE=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},A0=function(e,t){return e==="v"?HE(t):KE(t)},C0=function(e,t){return e==="v"?GE(t):QE(t)},YE=function(e,t){return e==="h"&&t==="rtl"?-1:1},XE=function(e,t,n,r,i){var o=YE(e,window.getComputedStyle(t).direction),s=o*r,l=n.target,a=t.contains(l),u=!1,c=s>0,f=0,d=0;do{if(!l)break;var p=C0(e,l),y=p[0],m=p[1],b=p[2],v=m-b-o*y;(y||v)&&A0(e,l)&&(f+=v,d+=y);var g=l.parentNode;l=g&&g.nodeType===Node.DOCUMENT_FRAGMENT_NODE?g.host:g}while(!a&&l!==document.body||a&&(t.contains(l)||t===l));return(c&&Math.abs(f)<1||!c&&Math.abs(d)<1)&&(u=!0),u},js=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},sp=function(e){return[e.deltaX,e.deltaY]},lp=function(e){return e&&"current"in e?e.current:e},ZE=function(e,t){return e[0]===t[0]&&e[1]===t[1]},JE=function(e){return`
80
+ .block-interactivity-`.concat(e,` {pointer-events: none;}
81
+ .allow-interactivity-`).concat(e,` {pointer-events: all;}
82
+ `)},qE=0,Lr=[];function e2(e){var t=x.useRef([]),n=x.useRef([0,0]),r=x.useRef(),i=x.useState(qE++)[0],o=x.useState(S0)[0],s=x.useRef(e);x.useEffect(function(){s.current=e},[e]),x.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(i));var m=_E([e.lockRef.current],(e.shards||[]).map(lp),!0).filter(Boolean);return m.forEach(function(b){return b.classList.add("allow-interactivity-".concat(i))}),function(){document.body.classList.remove("block-interactivity-".concat(i)),m.forEach(function(b){return b.classList.remove("allow-interactivity-".concat(i))})}}},[e.inert,e.lockRef.current,e.shards]);var l=x.useCallback(function(m,b){if("touches"in m&&m.touches.length===2||m.type==="wheel"&&m.ctrlKey)return!s.current.allowPinchZoom;var v=js(m),g=n.current,w="deltaX"in m?m.deltaX:g[0]-v[0],_="deltaY"in m?m.deltaY:g[1]-v[1],S,E=m.target,A=Math.abs(w)>Math.abs(_)?"h":"v";if("touches"in m&&A==="h"&&E.type==="range")return!1;var C=op(A,E);if(!C)return!0;if(C?S=A:(S=A==="v"?"h":"v",C=op(A,E)),!C)return!1;if(!r.current&&"changedTouches"in m&&(w||_)&&(r.current=S),!S)return!0;var j=r.current||S;return XE(j,b,m,j==="h"?w:_)},[]),a=x.useCallback(function(m){var b=m;if(!(!Lr.length||Lr[Lr.length-1]!==o)){var v="deltaY"in b?sp(b):js(b),g=t.current.filter(function(S){return S.name===b.type&&(S.target===b.target||b.target===S.shadowParent)&&ZE(S.delta,v)})[0];if(g&&g.should){b.cancelable&&b.preventDefault();return}if(!g){var w=(s.current.shards||[]).map(lp).filter(Boolean).filter(function(S){return S.contains(b.target)}),_=w.length>0?l(b,w[0]):!s.current.noIsolation;_&&b.cancelable&&b.preventDefault()}}},[]),u=x.useCallback(function(m,b,v,g){var w={name:m,delta:b,target:v,should:g,shadowParent:t2(v)};t.current.push(w),setTimeout(function(){t.current=t.current.filter(function(_){return _!==w})},1)},[]),c=x.useCallback(function(m){n.current=js(m),r.current=void 0},[]),f=x.useCallback(function(m){u(m.type,sp(m),m.target,l(m,e.lockRef.current))},[]),d=x.useCallback(function(m){u(m.type,js(m),m.target,l(m,e.lockRef.current))},[]);x.useEffect(function(){return Lr.push(o),e.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:d}),document.addEventListener("wheel",a,Mr),document.addEventListener("touchmove",a,Mr),document.addEventListener("touchstart",c,Mr),function(){Lr=Lr.filter(function(m){return m!==o}),document.removeEventListener("wheel",a,Mr),document.removeEventListener("touchmove",a,Mr),document.removeEventListener("touchstart",c,Mr)}},[]);var p=e.removeScrollBar,y=e.inert;return x.createElement(x.Fragment,null,y?x.createElement(o,{styles:JE(i)}):null,p?x.createElement(VE,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function t2(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const n2=NE(b0,e2);var k0=x.forwardRef(function(e,t){return x.createElement(pa,It({},e,{ref:t,sideCar:n2}))});k0.classNames=pa.classNames;var va="Popover",[O0]=$m(va,[a0]),ns=a0(),[r2,nr]=O0(va),P0=e=>{const{__scopePopover:t,children:n,open:r,defaultOpen:i,onOpenChange:o,modal:s=!1}=e,l=ns(t),a=x.useRef(null),[u,c]=x.useState(!1),[f,d]=dE({prop:r,defaultProp:i??!1,onChange:o,caller:va});return h.jsx(iE,{...l,children:h.jsx(r2,{scope:t,contentId:Fb(),triggerRef:a,open:f,onOpenChange:d,onOpenToggle:x.useCallback(()=>d(p=>!p),[d]),hasCustomAnchor:u,onCustomAnchorAdd:x.useCallback(()=>c(!0),[]),onCustomAnchorRemove:x.useCallback(()=>c(!1),[]),modal:s,children:n})})};P0.displayName=va;var N0="PopoverAnchor",j0=x.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,i=nr(N0,n),o=ns(n),{onCustomAnchorAdd:s,onCustomAnchorRemove:l}=i;return x.useEffect(()=>(s(),()=>l()),[s,l]),h.jsx(m0,{...o,...r,ref:t})});j0.displayName=N0;var T0="PopoverTrigger",R0=x.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,i=nr(T0,n),o=ns(n),s=tr(t,i.triggerRef),l=h.jsx(wn.button,{type:"button","aria-haspopup":"dialog","aria-expanded":i.open,"aria-controls":i.contentId,"data-state":F0(i.open),...r,ref:s,onClick:$n(e.onClick,i.onOpenToggle)});return i.hasCustomAnchor?l:h.jsx(m0,{asChild:!0,...o,children:l})});R0.displayName=T0;var qf="PopoverPortal",[i2,o2]=O0(qf,{forceMount:void 0}),D0=e=>{const{__scopePopover:t,forceMount:n,children:r,container:i}=e,o=nr(qf,t);return h.jsx(i2,{scope:t,forceMount:n,children:h.jsx(Jf,{present:n||o.open,children:h.jsx(y0,{asChild:!0,container:i,children:r})})})};D0.displayName=qf;var _i="PopoverContent",M0=x.forwardRef((e,t)=>{const n=o2(_i,e.__scopePopover),{forceMount:r=n.forceMount,...i}=e,o=nr(_i,e.__scopePopover);return h.jsx(Jf,{present:r||o.open,children:o.modal?h.jsx(l2,{...i,ref:t}):h.jsx(a2,{...i,ref:t})})});M0.displayName=_i;var s2=Vm("PopoverContent.RemoveScroll"),l2=x.forwardRef((e,t)=>{const n=nr(_i,e.__scopePopover),r=x.useRef(null),i=tr(t,r),o=x.useRef(!1);return x.useEffect(()=>{const s=r.current;if(s)return yE(s)},[]),h.jsx(k0,{as:s2,allowPinchZoom:!0,children:h.jsx(L0,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:$n(e.onCloseAutoFocus,s=>{var l;s.preventDefault(),o.current||(l=n.triggerRef.current)==null||l.focus()}),onPointerDownOutside:$n(e.onPointerDownOutside,s=>{const l=s.detail.originalEvent,a=l.button===0&&l.ctrlKey===!0,u=l.button===2||a;o.current=u},{checkForDefaultPrevented:!1}),onFocusOutside:$n(e.onFocusOutside,s=>s.preventDefault(),{checkForDefaultPrevented:!1})})})}),a2=x.forwardRef((e,t)=>{const n=nr(_i,e.__scopePopover),r=x.useRef(!1),i=x.useRef(!1);return h.jsx(L0,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:o=>{var s,l;(s=e.onCloseAutoFocus)==null||s.call(e,o),o.defaultPrevented||(r.current||(l=n.triggerRef.current)==null||l.focus(),o.preventDefault()),r.current=!1,i.current=!1},onInteractOutside:o=>{var a,u;(a=e.onInteractOutside)==null||a.call(e,o),o.defaultPrevented||(r.current=!0,o.detail.originalEvent.type==="pointerdown"&&(i.current=!0));const s=o.target;((u=n.triggerRef.current)==null?void 0:u.contains(s))&&o.preventDefault(),o.detail.originalEvent.type==="focusin"&&i.current&&o.preventDefault()}})}),L0=x.forwardRef((e,t)=>{const{__scopePopover:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:o,disableOutsidePointerEvents:s,onEscapeKeyDown:l,onPointerDownOutside:a,onFocusOutside:u,onInteractOutside:c,...f}=e,d=nr(_i,n),p=ns(n);return Ob(),h.jsx(Gm,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:o,children:h.jsx(Hm,{asChild:!0,disableOutsidePointerEvents:s,onInteractOutside:c,onEscapeKeyDown:l,onPointerDownOutside:a,onFocusOutside:u,onDismiss:()=>d.onOpenChange(!1),children:h.jsx(oE,{"data-state":F0(d.open),role:"dialog",id:d.contentId,...p,...f,ref:t,style:{...f.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),I0="PopoverClose",u2=x.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,i=nr(I0,n);return h.jsx(wn.button,{type:"button",...r,ref:t,onClick:$n(e.onClick,()=>i.onOpenChange(!1))})});u2.displayName=I0;var c2="PopoverArrow",f2=x.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,i=ns(n);return h.jsx(sE,{...i,...r,ref:t})});f2.displayName=c2;function F0(e){return e?"open":"closed"}var z0=P0,d2=j0,h2=R0,U0=D0,ed=M0;function B0(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=B0(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function p2(){for(var e,t,n=0,r="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=B0(e))&&(r&&(r+=" "),r+=t);return r}const td="-",v2=e=>{const t=m2(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:s=>{const l=s.split(td);return l[0]===""&&l.length!==1&&l.shift(),$0(l,t)||g2(s)},getConflictingClassGroupIds:(s,l)=>{const a=n[s]||[];return l&&r[s]?[...a,...r[s]]:a}}},$0=(e,t)=>{var s;if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),i=r?$0(e.slice(1),r):void 0;if(i)return i;if(t.validators.length===0)return;const o=e.join(td);return(s=t.validators.find(({validator:l})=>l(o)))==null?void 0:s.classGroupId},ap=/^\[(.+)\]$/,g2=e=>{if(ap.test(e)){const t=ap.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},m2=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return w2(Object.entries(e.classGroups),n).forEach(([o,s])=>{jc(s,r,o,t)}),r},jc=(e,t,n,r)=>{e.forEach(i=>{if(typeof i=="string"){const o=i===""?t:up(t,i);o.classGroupId=n;return}if(typeof i=="function"){if(y2(i)){jc(i(r),t,n,r);return}t.validators.push({validator:i,classGroupId:n});return}Object.entries(i).forEach(([o,s])=>{jc(s,up(t,o),n,r)})})},up=(e,t)=>{let n=e;return t.split(td).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},y2=e=>e.isThemeGetter,w2=(e,t)=>t?e.map(([n,r])=>{const i=r.map(o=>typeof o=="string"?t+o:typeof o=="object"?Object.fromEntries(Object.entries(o).map(([s,l])=>[t+s,l])):o);return[n,i]}):e,x2=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const i=(o,s)=>{n.set(o,s),t++,t>e&&(t=0,r=n,n=new Map)};return{get(o){let s=n.get(o);if(s!==void 0)return s;if((s=r.get(o))!==void 0)return i(o,s),s},set(o,s){n.has(o)?n.set(o,s):i(o,s)}}},V0="!",_2=e=>{const{separator:t,experimentalParseClassName:n}=e,r=t.length===1,i=t[0],o=t.length,s=l=>{const a=[];let u=0,c=0,f;for(let b=0;b<l.length;b++){let v=l[b];if(u===0){if(v===i&&(r||l.slice(b,b+o)===t)){a.push(l.slice(c,b)),c=b+o;continue}if(v==="/"){f=b;continue}}v==="["?u++:v==="]"&&u--}const d=a.length===0?l:l.substring(c),p=d.startsWith(V0),y=p?d.substring(1):d,m=f&&f>c?f-c:void 0;return{modifiers:a,hasImportantModifier:p,baseClassName:y,maybePostfixModifierPosition:m}};return n?l=>n({className:l,parseClassName:s}):s},b2=e=>{if(e.length<=1)return e;const t=[];let n=[];return e.forEach(r=>{r[0]==="["?(t.push(...n.sort(),r),n=[]):n.push(r)}),t.push(...n.sort()),t},S2=e=>({cache:x2(e.cacheSize),parseClassName:_2(e),...v2(e)}),E2=/\s+/,A2=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i}=t,o=[],s=e.trim().split(E2);let l="";for(let a=s.length-1;a>=0;a-=1){const u=s[a],{modifiers:c,hasImportantModifier:f,baseClassName:d,maybePostfixModifierPosition:p}=n(u);let y=!!p,m=r(y?d.substring(0,p):d);if(!m){if(!y){l=u+(l.length>0?" "+l:l);continue}if(m=r(d),!m){l=u+(l.length>0?" "+l:l);continue}y=!1}const b=b2(c).join(":"),v=f?b+V0:b,g=v+m;if(o.includes(g))continue;o.push(g);const w=i(m,y);for(let _=0;_<w.length;++_){const S=w[_];o.push(v+S)}l=u+(l.length>0?" "+l:l)}return l};function C2(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=W0(t))&&(r&&(r+=" "),r+=n);return r}const W0=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=W0(e[r]))&&(n&&(n+=" "),n+=t);return n};function k2(e,...t){let n,r,i,o=s;function s(a){const u=t.reduce((c,f)=>f(c),e());return n=S2(u),r=n.cache.get,i=n.cache.set,o=l,l(a)}function l(a){const u=r(a);if(u)return u;const c=A2(a,n);return i(a,c),c}return function(){return o(C2.apply(null,arguments))}}const oe=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},H0=/^\[(?:([a-z-]+):)?(.+)\]$/i,O2=/^\d+\/\d+$/,P2=new Set(["px","full","screen"]),N2=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,j2=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,T2=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,R2=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,D2=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Jt=e=>si(e)||P2.has(e)||O2.test(e),_n=e=>ji(e,"length",$2),si=e=>!!e&&!Number.isNaN(Number(e)),du=e=>ji(e,"number",si),Hi=e=>!!e&&Number.isInteger(Number(e)),M2=e=>e.endsWith("%")&&si(e.slice(0,-1)),V=e=>H0.test(e),bn=e=>N2.test(e),L2=new Set(["length","size","percentage"]),I2=e=>ji(e,L2,K0),F2=e=>ji(e,"position",K0),z2=new Set(["image","url"]),U2=e=>ji(e,z2,W2),B2=e=>ji(e,"",V2),Ki=()=>!0,ji=(e,t,n)=>{const r=H0.exec(e);return r?r[1]?typeof t=="string"?r[1]===t:t.has(r[1]):n(r[2]):!1},$2=e=>j2.test(e)&&!T2.test(e),K0=()=>!1,V2=e=>R2.test(e),W2=e=>D2.test(e),H2=()=>{const e=oe("colors"),t=oe("spacing"),n=oe("blur"),r=oe("brightness"),i=oe("borderColor"),o=oe("borderRadius"),s=oe("borderSpacing"),l=oe("borderWidth"),a=oe("contrast"),u=oe("grayscale"),c=oe("hueRotate"),f=oe("invert"),d=oe("gap"),p=oe("gradientColorStops"),y=oe("gradientColorStopPositions"),m=oe("inset"),b=oe("margin"),v=oe("opacity"),g=oe("padding"),w=oe("saturate"),_=oe("scale"),S=oe("sepia"),E=oe("skew"),A=oe("space"),C=oe("translate"),j=()=>["auto","contain","none"],P=()=>["auto","hidden","clip","visible","scroll"],D=()=>["auto",V,t],k=()=>[V,t],z=()=>["",Jt,_n],B=()=>["auto",si,V],K=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],Z=()=>["solid","dashed","dotted","double","none"],J=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],O=()=>["start","end","center","between","around","evenly","stretch"],R=()=>["","0",V],F=()=>["auto","avoid","all","avoid-page","page","left","right","column"],H=()=>[si,V];return{cacheSize:500,separator:":",theme:{colors:[Ki],spacing:[Jt,_n],blur:["none","",bn,V],brightness:H(),borderColor:[e],borderRadius:["none","","full",bn,V],borderSpacing:k(),borderWidth:z(),contrast:H(),grayscale:R(),hueRotate:H(),invert:R(),gap:k(),gradientColorStops:[e],gradientColorStopPositions:[M2,_n],inset:D(),margin:D(),opacity:H(),padding:k(),saturate:H(),scale:H(),sepia:R(),skew:H(),space:k(),translate:k()},classGroups:{aspect:[{aspect:["auto","square","video",V]}],container:["container"],columns:[{columns:[bn]}],"break-after":[{"break-after":F()}],"break-before":[{"break-before":F()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...K(),V]}],overflow:[{overflow:P()}],"overflow-x":[{"overflow-x":P()}],"overflow-y":[{"overflow-y":P()}],overscroll:[{overscroll:j()}],"overscroll-x":[{"overscroll-x":j()}],"overscroll-y":[{"overscroll-y":j()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[m]}],"inset-x":[{"inset-x":[m]}],"inset-y":[{"inset-y":[m]}],start:[{start:[m]}],end:[{end:[m]}],top:[{top:[m]}],right:[{right:[m]}],bottom:[{bottom:[m]}],left:[{left:[m]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Hi,V]}],basis:[{basis:D()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",V]}],grow:[{grow:R()}],shrink:[{shrink:R()}],order:[{order:["first","last","none",Hi,V]}],"grid-cols":[{"grid-cols":[Ki]}],"col-start-end":[{col:["auto",{span:["full",Hi,V]},V]}],"col-start":[{"col-start":B()}],"col-end":[{"col-end":B()}],"grid-rows":[{"grid-rows":[Ki]}],"row-start-end":[{row:["auto",{span:[Hi,V]},V]}],"row-start":[{"row-start":B()}],"row-end":[{"row-end":B()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",V]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",V]}],gap:[{gap:[d]}],"gap-x":[{"gap-x":[d]}],"gap-y":[{"gap-y":[d]}],"justify-content":[{justify:["normal",...O()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...O(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...O(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[g]}],px:[{px:[g]}],py:[{py:[g]}],ps:[{ps:[g]}],pe:[{pe:[g]}],pt:[{pt:[g]}],pr:[{pr:[g]}],pb:[{pb:[g]}],pl:[{pl:[g]}],m:[{m:[b]}],mx:[{mx:[b]}],my:[{my:[b]}],ms:[{ms:[b]}],me:[{me:[b]}],mt:[{mt:[b]}],mr:[{mr:[b]}],mb:[{mb:[b]}],ml:[{ml:[b]}],"space-x":[{"space-x":[A]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[A]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",V,t]}],"min-w":[{"min-w":[V,t,"min","max","fit"]}],"max-w":[{"max-w":[V,t,"none","full","min","max","fit","prose",{screen:[bn]},bn]}],h:[{h:[V,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[V,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[V,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[V,t,"auto","min","max","fit"]}],"font-size":[{text:["base",bn,_n]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",du]}],"font-family":[{font:[Ki]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",V]}],"line-clamp":[{"line-clamp":["none",si,du]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Jt,V]}],"list-image":[{"list-image":["none",V]}],"list-style-type":[{list:["none","disc","decimal",V]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[v]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[v]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...Z(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Jt,_n]}],"underline-offset":[{"underline-offset":["auto",Jt,V]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:k()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",V]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",V]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[v]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...K(),F2]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",I2]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},U2]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[y]}],"gradient-via-pos":[{via:[y]}],"gradient-to-pos":[{to:[y]}],"gradient-from":[{from:[p]}],"gradient-via":[{via:[p]}],"gradient-to":[{to:[p]}],rounded:[{rounded:[o]}],"rounded-s":[{"rounded-s":[o]}],"rounded-e":[{"rounded-e":[o]}],"rounded-t":[{"rounded-t":[o]}],"rounded-r":[{"rounded-r":[o]}],"rounded-b":[{"rounded-b":[o]}],"rounded-l":[{"rounded-l":[o]}],"rounded-ss":[{"rounded-ss":[o]}],"rounded-se":[{"rounded-se":[o]}],"rounded-ee":[{"rounded-ee":[o]}],"rounded-es":[{"rounded-es":[o]}],"rounded-tl":[{"rounded-tl":[o]}],"rounded-tr":[{"rounded-tr":[o]}],"rounded-br":[{"rounded-br":[o]}],"rounded-bl":[{"rounded-bl":[o]}],"border-w":[{border:[l]}],"border-w-x":[{"border-x":[l]}],"border-w-y":[{"border-y":[l]}],"border-w-s":[{"border-s":[l]}],"border-w-e":[{"border-e":[l]}],"border-w-t":[{"border-t":[l]}],"border-w-r":[{"border-r":[l]}],"border-w-b":[{"border-b":[l]}],"border-w-l":[{"border-l":[l]}],"border-opacity":[{"border-opacity":[v]}],"border-style":[{border:[...Z(),"hidden"]}],"divide-x":[{"divide-x":[l]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[l]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[v]}],"divide-style":[{divide:Z()}],"border-color":[{border:[i]}],"border-color-x":[{"border-x":[i]}],"border-color-y":[{"border-y":[i]}],"border-color-s":[{"border-s":[i]}],"border-color-e":[{"border-e":[i]}],"border-color-t":[{"border-t":[i]}],"border-color-r":[{"border-r":[i]}],"border-color-b":[{"border-b":[i]}],"border-color-l":[{"border-l":[i]}],"divide-color":[{divide:[i]}],"outline-style":[{outline:["",...Z()]}],"outline-offset":[{"outline-offset":[Jt,V]}],"outline-w":[{outline:[Jt,_n]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:z()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[v]}],"ring-offset-w":[{"ring-offset":[Jt,_n]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",bn,B2]}],"shadow-color":[{shadow:[Ki]}],opacity:[{opacity:[v]}],"mix-blend":[{"mix-blend":[...J(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":J()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[a]}],"drop-shadow":[{"drop-shadow":["","none",bn,V]}],grayscale:[{grayscale:[u]}],"hue-rotate":[{"hue-rotate":[c]}],invert:[{invert:[f]}],saturate:[{saturate:[w]}],sepia:[{sepia:[S]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[a]}],"backdrop-grayscale":[{"backdrop-grayscale":[u]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[c]}],"backdrop-invert":[{"backdrop-invert":[f]}],"backdrop-opacity":[{"backdrop-opacity":[v]}],"backdrop-saturate":[{"backdrop-saturate":[w]}],"backdrop-sepia":[{"backdrop-sepia":[S]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[s]}],"border-spacing-x":[{"border-spacing-x":[s]}],"border-spacing-y":[{"border-spacing-y":[s]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",V]}],duration:[{duration:H()}],ease:[{ease:["linear","in","out","in-out",V]}],delay:[{delay:H()}],animate:[{animate:["none","spin","ping","pulse","bounce",V]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[_]}],"scale-x":[{"scale-x":[_]}],"scale-y":[{"scale-y":[_]}],rotate:[{rotate:[Hi,V]}],"translate-x":[{"translate-x":[C]}],"translate-y":[{"translate-y":[C]}],"skew-x":[{"skew-x":[E]}],"skew-y":[{"skew-y":[E]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",V]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",V]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":k()}],"scroll-mx":[{"scroll-mx":k()}],"scroll-my":[{"scroll-my":k()}],"scroll-ms":[{"scroll-ms":k()}],"scroll-me":[{"scroll-me":k()}],"scroll-mt":[{"scroll-mt":k()}],"scroll-mr":[{"scroll-mr":k()}],"scroll-mb":[{"scroll-mb":k()}],"scroll-ml":[{"scroll-ml":k()}],"scroll-p":[{"scroll-p":k()}],"scroll-px":[{"scroll-px":k()}],"scroll-py":[{"scroll-py":k()}],"scroll-ps":[{"scroll-ps":k()}],"scroll-pe":[{"scroll-pe":k()}],"scroll-pt":[{"scroll-pt":k()}],"scroll-pr":[{"scroll-pr":k()}],"scroll-pb":[{"scroll-pb":k()}],"scroll-pl":[{"scroll-pl":k()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",V]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Jt,_n,du]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},K2=k2(H2);function ae(...e){return K2(p2(e))}const G0=z0,Q0=h2,nd=x.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},i)=>h.jsx(U0,{children:h.jsx(ed,{ref:i,align:t,sideOffset:n,className:ae("z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...r})}));nd.displayName=ed.displayName;function Y0(e){return{all:e=e||new Map,on:function(t,n){var r=e.get(t);r?r.push(n):e.set(t,[n])},off:function(t,n){var r=e.get(t);r&&(n?r.splice(r.indexOf(n)>>>0,1):e.set(t,[]))},emit:function(t,n){var r=e.get(t);r&&r.slice().map(function(i){i(n)}),(r=e.get("*"))&&r.slice().map(function(i){i(t,n)})}}}const Ar=Y0();var X0={exports:{}};(function(e){var t=function(){this.Diff_Timeout=1,this.Diff_EditCost=4,this.Match_Threshold=.5,this.Match_Distance=1e3,this.Patch_DeleteThreshold=.5,this.Patch_Margin=4,this.Match_MaxBits=32},n=-1,r=1,i=0;t.Diff=function(o,s){return[o,s]},t.prototype.diff_main=function(o,s,l,a){typeof a>"u"&&(this.Diff_Timeout<=0?a=Number.MAX_VALUE:a=new Date().getTime()+this.Diff_Timeout*1e3);var u=a;if(o==null||s==null)throw new Error("Null input. (diff_main)");if(o==s)return o?[new t.Diff(i,o)]:[];typeof l>"u"&&(l=!0);var c=l,f=this.diff_commonPrefix(o,s),d=o.substring(0,f);o=o.substring(f),s=s.substring(f),f=this.diff_commonSuffix(o,s);var p=o.substring(o.length-f);o=o.substring(0,o.length-f),s=s.substring(0,s.length-f);var y=this.diff_compute_(o,s,c,u);return d&&y.unshift(new t.Diff(i,d)),p&&y.push(new t.Diff(i,p)),this.diff_cleanupMerge(y),y},t.prototype.diff_compute_=function(o,s,l,a){var u;if(!o)return[new t.Diff(r,s)];if(!s)return[new t.Diff(n,o)];var c=o.length>s.length?o:s,f=o.length>s.length?s:o,d=c.indexOf(f);if(d!=-1)return u=[new t.Diff(r,c.substring(0,d)),new t.Diff(i,f),new t.Diff(r,c.substring(d+f.length))],o.length>s.length&&(u[0][0]=u[2][0]=n),u;if(f.length==1)return[new t.Diff(n,o),new t.Diff(r,s)];var p=this.diff_halfMatch_(o,s);if(p){var y=p[0],m=p[1],b=p[2],v=p[3],g=p[4],w=this.diff_main(y,b,l,a),_=this.diff_main(m,v,l,a);return w.concat([new t.Diff(i,g)],_)}return l&&o.length>100&&s.length>100?this.diff_lineMode_(o,s,a):this.diff_bisect_(o,s,a)},t.prototype.diff_lineMode_=function(o,s,l){var a=this.diff_linesToChars_(o,s);o=a.chars1,s=a.chars2;var u=a.lineArray,c=this.diff_main(o,s,!1,l);this.diff_charsToLines_(c,u),this.diff_cleanupSemantic(c),c.push(new t.Diff(i,""));for(var f=0,d=0,p=0,y="",m="";f<c.length;){switch(c[f][0]){case r:p++,m+=c[f][1];break;case n:d++,y+=c[f][1];break;case i:if(d>=1&&p>=1){c.splice(f-d-p,d+p),f=f-d-p;for(var b=this.diff_main(y,m,!1,l),v=b.length-1;v>=0;v--)c.splice(f,0,b[v]);f=f+b.length}p=0,d=0,y="",m="";break}f++}return c.pop(),c},t.prototype.diff_bisect_=function(o,s,l){for(var a=o.length,u=s.length,c=Math.ceil((a+u)/2),f=c,d=2*c,p=new Array(d),y=new Array(d),m=0;m<d;m++)p[m]=-1,y[m]=-1;p[f+1]=0,y[f+1]=0;for(var b=a-u,v=b%2!=0,g=0,w=0,_=0,S=0,E=0;E<c&&!(new Date().getTime()>l);E++){for(var A=-E+g;A<=E-w;A+=2){var C=f+A,j;A==-E||A!=E&&p[C-1]<p[C+1]?j=p[C+1]:j=p[C-1]+1;for(var P=j-A;j<a&&P<u&&o.charAt(j)==s.charAt(P);)j++,P++;if(p[C]=j,j>a)w+=2;else if(P>u)g+=2;else if(v){var D=f+b-A;if(D>=0&&D<d&&y[D]!=-1){var k=a-y[D];if(j>=k)return this.diff_bisectSplit_(o,s,j,P,l)}}}for(var z=-E+_;z<=E-S;z+=2){var D=f+z,k;z==-E||z!=E&&y[D-1]<y[D+1]?k=y[D+1]:k=y[D-1]+1;for(var B=k-z;k<a&&B<u&&o.charAt(a-k-1)==s.charAt(u-B-1);)k++,B++;if(y[D]=k,k>a)S+=2;else if(B>u)_+=2;else if(!v){var C=f+b-z;if(C>=0&&C<d&&p[C]!=-1){var j=p[C],P=f+j-C;if(k=a-k,j>=k)return this.diff_bisectSplit_(o,s,j,P,l)}}}}return[new t.Diff(n,o),new t.Diff(r,s)]},t.prototype.diff_bisectSplit_=function(o,s,l,a,u){var c=o.substring(0,l),f=s.substring(0,a),d=o.substring(l),p=s.substring(a),y=this.diff_main(c,f,!1,u),m=this.diff_main(d,p,!1,u);return y.concat(m)},t.prototype.diff_linesToChars_=function(o,s){var l=[],a={};l[0]="";function u(p){for(var y="",m=0,b=-1,v=l.length;b<p.length-1;){b=p.indexOf(`
83
+ `,m),b==-1&&(b=p.length-1);var g=p.substring(m,b+1);(a.hasOwnProperty?a.hasOwnProperty(g):a[g]!==void 0)?y+=String.fromCharCode(a[g]):(v==c&&(g=p.substring(m),b=p.length),y+=String.fromCharCode(v),a[g]=v,l[v++]=g),m=b+1}return y}var c=4e4,f=u(o);c=65535;var d=u(s);return{chars1:f,chars2:d,lineArray:l}},t.prototype.diff_charsToLines_=function(o,s){for(var l=0;l<o.length;l++){for(var a=o[l][1],u=[],c=0;c<a.length;c++)u[c]=s[a.charCodeAt(c)];o[l][1]=u.join("")}},t.prototype.diff_commonPrefix=function(o,s){if(!o||!s||o.charAt(0)!=s.charAt(0))return 0;for(var l=0,a=Math.min(o.length,s.length),u=a,c=0;l<u;)o.substring(c,u)==s.substring(c,u)?(l=u,c=l):a=u,u=Math.floor((a-l)/2+l);return u},t.prototype.diff_commonSuffix=function(o,s){if(!o||!s||o.charAt(o.length-1)!=s.charAt(s.length-1))return 0;for(var l=0,a=Math.min(o.length,s.length),u=a,c=0;l<u;)o.substring(o.length-u,o.length-c)==s.substring(s.length-u,s.length-c)?(l=u,c=l):a=u,u=Math.floor((a-l)/2+l);return u},t.prototype.diff_commonOverlap_=function(o,s){var l=o.length,a=s.length;if(l==0||a==0)return 0;l>a?o=o.substring(l-a):l<a&&(s=s.substring(0,l));var u=Math.min(l,a);if(o==s)return u;for(var c=0,f=1;;){var d=o.substring(u-f),p=s.indexOf(d);if(p==-1)return c;f+=p,(p==0||o.substring(u-f)==s.substring(0,f))&&(c=f,f++)}},t.prototype.diff_halfMatch_=function(o,s){if(this.Diff_Timeout<=0)return null;var l=o.length>s.length?o:s,a=o.length>s.length?s:o;if(l.length<4||a.length*2<l.length)return null;var u=this;function c(w,_,S){for(var E=w.substring(S,S+Math.floor(w.length/4)),A=-1,C="",j,P,D,k;(A=_.indexOf(E,A+1))!=-1;){var z=u.diff_commonPrefix(w.substring(S),_.substring(A)),B=u.diff_commonSuffix(w.substring(0,S),_.substring(0,A));C.length<B+z&&(C=_.substring(A-B,A)+_.substring(A,A+z),j=w.substring(0,S-B),P=w.substring(S+z),D=_.substring(0,A-B),k=_.substring(A+z))}return C.length*2>=w.length?[j,P,D,k,C]:null}var f=c(l,a,Math.ceil(l.length/4)),d=c(l,a,Math.ceil(l.length/2)),p;if(!f&&!d)return null;d?f?p=f[4].length>d[4].length?f:d:p=d:p=f;var y,m,b,v;o.length>s.length?(y=p[0],m=p[1],b=p[2],v=p[3]):(b=p[0],v=p[1],y=p[2],m=p[3]);var g=p[4];return[y,m,b,v,g]},t.prototype.diff_cleanupSemantic=function(o){for(var s=!1,l=[],a=0,u=null,c=0,f=0,d=0,p=0,y=0;c<o.length;)o[c][0]==i?(l[a++]=c,f=p,d=y,p=0,y=0,u=o[c][1]):(o[c][0]==r?p+=o[c][1].length:y+=o[c][1].length,u&&u.length<=Math.max(f,d)&&u.length<=Math.max(p,y)&&(o.splice(l[a-1],0,new t.Diff(n,u)),o[l[a-1]+1][0]=r,a--,a--,c=a>0?l[a-1]:-1,f=0,d=0,p=0,y=0,u=null,s=!0)),c++;for(s&&this.diff_cleanupMerge(o),this.diff_cleanupSemanticLossless(o),c=1;c<o.length;){if(o[c-1][0]==n&&o[c][0]==r){var m=o[c-1][1],b=o[c][1],v=this.diff_commonOverlap_(m,b),g=this.diff_commonOverlap_(b,m);v>=g?(v>=m.length/2||v>=b.length/2)&&(o.splice(c,0,new t.Diff(i,b.substring(0,v))),o[c-1][1]=m.substring(0,m.length-v),o[c+1][1]=b.substring(v),c++):(g>=m.length/2||g>=b.length/2)&&(o.splice(c,0,new t.Diff(i,m.substring(0,g))),o[c-1][0]=r,o[c-1][1]=b.substring(0,b.length-g),o[c+1][0]=n,o[c+1][1]=m.substring(g),c++),c++}c++}},t.prototype.diff_cleanupSemanticLossless=function(o){function s(g,w){if(!g||!w)return 6;var _=g.charAt(g.length-1),S=w.charAt(0),E=_.match(t.nonAlphaNumericRegex_),A=S.match(t.nonAlphaNumericRegex_),C=E&&_.match(t.whitespaceRegex_),j=A&&S.match(t.whitespaceRegex_),P=C&&_.match(t.linebreakRegex_),D=j&&S.match(t.linebreakRegex_),k=P&&g.match(t.blanklineEndRegex_),z=D&&w.match(t.blanklineStartRegex_);return k||z?5:P||D?4:E&&!C&&j?3:C||j?2:E||A?1:0}for(var l=1;l<o.length-1;){if(o[l-1][0]==i&&o[l+1][0]==i){var a=o[l-1][1],u=o[l][1],c=o[l+1][1],f=this.diff_commonSuffix(a,u);if(f){var d=u.substring(u.length-f);a=a.substring(0,a.length-f),u=d+u.substring(0,u.length-f),c=d+c}for(var p=a,y=u,m=c,b=s(a,u)+s(u,c);u.charAt(0)===c.charAt(0);){a+=u.charAt(0),u=u.substring(1)+c.charAt(0),c=c.substring(1);var v=s(a,u)+s(u,c);v>=b&&(b=v,p=a,y=u,m=c)}o[l-1][1]!=p&&(p?o[l-1][1]=p:(o.splice(l-1,1),l--),o[l][1]=y,m?o[l+1][1]=m:(o.splice(l+1,1),l--))}l++}},t.nonAlphaNumericRegex_=/[^a-zA-Z0-9]/,t.whitespaceRegex_=/\s/,t.linebreakRegex_=/[\r\n]/,t.blanklineEndRegex_=/\n\r?\n$/,t.blanklineStartRegex_=/^\r?\n\r?\n/,t.prototype.diff_cleanupEfficiency=function(o){for(var s=!1,l=[],a=0,u=null,c=0,f=!1,d=!1,p=!1,y=!1;c<o.length;)o[c][0]==i?(o[c][1].length<this.Diff_EditCost&&(p||y)?(l[a++]=c,f=p,d=y,u=o[c][1]):(a=0,u=null),p=y=!1):(o[c][0]==n?y=!0:p=!0,u&&(f&&d&&p&&y||u.length<this.Diff_EditCost/2&&f+d+p+y==3)&&(o.splice(l[a-1],0,new t.Diff(n,u)),o[l[a-1]+1][0]=r,a--,u=null,f&&d?(p=y=!0,a=0):(a--,c=a>0?l[a-1]:-1,p=y=!1),s=!0)),c++;s&&this.diff_cleanupMerge(o)},t.prototype.diff_cleanupMerge=function(o){o.push(new t.Diff(i,""));for(var s=0,l=0,a=0,u="",c="",f;s<o.length;)switch(o[s][0]){case r:a++,c+=o[s][1],s++;break;case n:l++,u+=o[s][1],s++;break;case i:l+a>1?(l!==0&&a!==0&&(f=this.diff_commonPrefix(c,u),f!==0&&(s-l-a>0&&o[s-l-a-1][0]==i?o[s-l-a-1][1]+=c.substring(0,f):(o.splice(0,0,new t.Diff(i,c.substring(0,f))),s++),c=c.substring(f),u=u.substring(f)),f=this.diff_commonSuffix(c,u),f!==0&&(o[s][1]=c.substring(c.length-f)+o[s][1],c=c.substring(0,c.length-f),u=u.substring(0,u.length-f))),s-=l+a,o.splice(s,l+a),u.length&&(o.splice(s,0,new t.Diff(n,u)),s++),c.length&&(o.splice(s,0,new t.Diff(r,c)),s++),s++):s!==0&&o[s-1][0]==i?(o[s-1][1]+=o[s][1],o.splice(s,1)):s++,a=0,l=0,u="",c="";break}o[o.length-1][1]===""&&o.pop();var d=!1;for(s=1;s<o.length-1;)o[s-1][0]==i&&o[s+1][0]==i&&(o[s][1].substring(o[s][1].length-o[s-1][1].length)==o[s-1][1]?(o[s][1]=o[s-1][1]+o[s][1].substring(0,o[s][1].length-o[s-1][1].length),o[s+1][1]=o[s-1][1]+o[s+1][1],o.splice(s-1,1),d=!0):o[s][1].substring(0,o[s+1][1].length)==o[s+1][1]&&(o[s-1][1]+=o[s+1][1],o[s][1]=o[s][1].substring(o[s+1][1].length)+o[s+1][1],o.splice(s+1,1),d=!0)),s++;d&&this.diff_cleanupMerge(o)},t.prototype.diff_xIndex=function(o,s){var l=0,a=0,u=0,c=0,f;for(f=0;f<o.length&&(o[f][0]!==r&&(l+=o[f][1].length),o[f][0]!==n&&(a+=o[f][1].length),!(l>s));f++)u=l,c=a;return o.length!=f&&o[f][0]===n?c:c+(s-u)},t.prototype.diff_prettyHtml=function(o){for(var s=[],l=/&/g,a=/</g,u=/>/g,c=/\n/g,f=0;f<o.length;f++){var d=o[f][0],p=o[f][1],y=p.replace(l,"&amp;").replace(a,"&lt;").replace(u,"&gt;").replace(c,"&para;<br>");switch(d){case r:s[f]='<ins style="background:#e6ffe6;">'+y+"</ins>";break;case n:s[f]='<del style="background:#ffe6e6;">'+y+"</del>";break;case i:s[f]="<span>"+y+"</span>";break}}return s.join("")},t.prototype.diff_text1=function(o){for(var s=[],l=0;l<o.length;l++)o[l][0]!==r&&(s[l]=o[l][1]);return s.join("")},t.prototype.diff_text2=function(o){for(var s=[],l=0;l<o.length;l++)o[l][0]!==n&&(s[l]=o[l][1]);return s.join("")},t.prototype.diff_levenshtein=function(o){for(var s=0,l=0,a=0,u=0;u<o.length;u++){var c=o[u][0],f=o[u][1];switch(c){case r:l+=f.length;break;case n:a+=f.length;break;case i:s+=Math.max(l,a),l=0,a=0;break}}return s+=Math.max(l,a),s},t.prototype.diff_toDelta=function(o){for(var s=[],l=0;l<o.length;l++)switch(o[l][0]){case r:s[l]="+"+encodeURI(o[l][1]);break;case n:s[l]="-"+o[l][1].length;break;case i:s[l]="="+o[l][1].length;break}return s.join(" ").replace(/%20/g," ")},t.prototype.diff_fromDelta=function(o,s){for(var l=[],a=0,u=0,c=s.split(/\t/g),f=0;f<c.length;f++){var d=c[f].substring(1);switch(c[f].charAt(0)){case"+":try{l[a++]=new t.Diff(r,decodeURI(d))}catch{throw new Error("Illegal escape in diff_fromDelta: "+d)}break;case"-":case"=":var p=parseInt(d,10);if(isNaN(p)||p<0)throw new Error("Invalid number in diff_fromDelta: "+d);var y=o.substring(u,u+=p);c[f].charAt(0)=="="?l[a++]=new t.Diff(i,y):l[a++]=new t.Diff(n,y);break;default:if(c[f])throw new Error("Invalid diff operation in diff_fromDelta: "+c[f])}}if(u!=o.length)throw new Error("Delta length ("+u+") does not equal source text length ("+o.length+").");return l},t.prototype.match_main=function(o,s,l){if(o==null||s==null||l==null)throw new Error("Null input. (match_main)");return l=Math.max(0,Math.min(l,o.length)),o==s?0:o.length?o.substring(l,l+s.length)==s?l:this.match_bitap_(o,s,l):-1},t.prototype.match_bitap_=function(o,s,l){if(s.length>this.Match_MaxBits)throw new Error("Pattern too long for this browser.");var a=this.match_alphabet_(s),u=this;function c(j,P){var D=j/s.length,k=Math.abs(l-P);return u.Match_Distance?D+k/u.Match_Distance:k?1:D}var f=this.Match_Threshold,d=o.indexOf(s,l);d!=-1&&(f=Math.min(c(0,d),f),d=o.lastIndexOf(s,l+s.length),d!=-1&&(f=Math.min(c(0,d),f)));var p=1<<s.length-1;d=-1;for(var y,m,b=s.length+o.length,v,g=0;g<s.length;g++){for(y=0,m=b;y<m;)c(g,l+m)<=f?y=m:b=m,m=Math.floor((b-y)/2+y);b=m;var w=Math.max(1,l-m+1),_=Math.min(l+m,o.length)+s.length,S=Array(_+2);S[_+1]=(1<<g)-1;for(var E=_;E>=w;E--){var A=a[o.charAt(E-1)];if(g===0?S[E]=(S[E+1]<<1|1)&A:S[E]=(S[E+1]<<1|1)&A|((v[E+1]|v[E])<<1|1)|v[E+1],S[E]&p){var C=c(g,E-1);if(C<=f)if(f=C,d=E-1,d>l)w=Math.max(1,2*l-d);else break}}if(c(g+1,l)>f)break;v=S}return d},t.prototype.match_alphabet_=function(o){for(var s={},l=0;l<o.length;l++)s[o.charAt(l)]=0;for(var l=0;l<o.length;l++)s[o.charAt(l)]|=1<<o.length-l-1;return s},t.prototype.patch_addContext_=function(o,s){if(s.length!=0){if(o.start2===null)throw Error("patch not initialized");for(var l=s.substring(o.start2,o.start2+o.length1),a=0;s.indexOf(l)!=s.lastIndexOf(l)&&l.length<this.Match_MaxBits-this.Patch_Margin-this.Patch_Margin;)a+=this.Patch_Margin,l=s.substring(o.start2-a,o.start2+o.length1+a);a+=this.Patch_Margin;var u=s.substring(o.start2-a,o.start2);u&&o.diffs.unshift(new t.Diff(i,u));var c=s.substring(o.start2+o.length1,o.start2+o.length1+a);c&&o.diffs.push(new t.Diff(i,c)),o.start1-=u.length,o.start2-=u.length,o.length1+=u.length+c.length,o.length2+=u.length+c.length}},t.prototype.patch_make=function(o,s,l){var a,u;if(typeof o=="string"&&typeof s=="string"&&typeof l>"u")a=o,u=this.diff_main(a,s,!0),u.length>2&&(this.diff_cleanupSemantic(u),this.diff_cleanupEfficiency(u));else if(o&&typeof o=="object"&&typeof s>"u"&&typeof l>"u")u=o,a=this.diff_text1(u);else if(typeof o=="string"&&s&&typeof s=="object"&&typeof l>"u")a=o,u=s;else if(typeof o=="string"&&typeof s=="string"&&l&&typeof l=="object")a=o,u=l;else throw new Error("Unknown call format to patch_make.");if(u.length===0)return[];for(var c=[],f=new t.patch_obj,d=0,p=0,y=0,m=a,b=a,v=0;v<u.length;v++){var g=u[v][0],w=u[v][1];switch(!d&&g!==i&&(f.start1=p,f.start2=y),g){case r:f.diffs[d++]=u[v],f.length2+=w.length,b=b.substring(0,y)+w+b.substring(y);break;case n:f.length1+=w.length,f.diffs[d++]=u[v],b=b.substring(0,y)+b.substring(y+w.length);break;case i:w.length<=2*this.Patch_Margin&&d&&u.length!=v+1?(f.diffs[d++]=u[v],f.length1+=w.length,f.length2+=w.length):w.length>=2*this.Patch_Margin&&d&&(this.patch_addContext_(f,m),c.push(f),f=new t.patch_obj,d=0,m=b,p=y);break}g!==r&&(p+=w.length),g!==n&&(y+=w.length)}return d&&(this.patch_addContext_(f,m),c.push(f)),c},t.prototype.patch_deepCopy=function(o){for(var s=[],l=0;l<o.length;l++){var a=o[l],u=new t.patch_obj;u.diffs=[];for(var c=0;c<a.diffs.length;c++)u.diffs[c]=new t.Diff(a.diffs[c][0],a.diffs[c][1]);u.start1=a.start1,u.start2=a.start2,u.length1=a.length1,u.length2=a.length2,s[l]=u}return s},t.prototype.patch_apply=function(o,s){if(o.length==0)return[s,[]];o=this.patch_deepCopy(o);var l=this.patch_addPadding(o);s=l+s+l,this.patch_splitMax(o);for(var a=0,u=[],c=0;c<o.length;c++){var f=o[c].start2+a,d=this.diff_text1(o[c].diffs),p,y=-1;if(d.length>this.Match_MaxBits?(p=this.match_main(s,d.substring(0,this.Match_MaxBits),f),p!=-1&&(y=this.match_main(s,d.substring(d.length-this.Match_MaxBits),f+d.length-this.Match_MaxBits),(y==-1||p>=y)&&(p=-1))):p=this.match_main(s,d,f),p==-1)u[c]=!1,a-=o[c].length2-o[c].length1;else{u[c]=!0,a=p-f;var m;if(y==-1?m=s.substring(p,p+d.length):m=s.substring(p,y+this.Match_MaxBits),d==m)s=s.substring(0,p)+this.diff_text2(o[c].diffs)+s.substring(p+d.length);else{var b=this.diff_main(d,m,!1);if(d.length>this.Match_MaxBits&&this.diff_levenshtein(b)/d.length>this.Patch_DeleteThreshold)u[c]=!1;else{this.diff_cleanupSemanticLossless(b);for(var v=0,g,w=0;w<o[c].diffs.length;w++){var _=o[c].diffs[w];_[0]!==i&&(g=this.diff_xIndex(b,v)),_[0]===r?s=s.substring(0,p+g)+_[1]+s.substring(p+g):_[0]===n&&(s=s.substring(0,p+g)+s.substring(p+this.diff_xIndex(b,v+_[1].length))),_[0]!==n&&(v+=_[1].length)}}}}}return s=s.substring(l.length,s.length-l.length),[s,u]},t.prototype.patch_addPadding=function(o){for(var s=this.Patch_Margin,l="",a=1;a<=s;a++)l+=String.fromCharCode(a);for(var a=0;a<o.length;a++)o[a].start1+=s,o[a].start2+=s;var u=o[0],c=u.diffs;if(c.length==0||c[0][0]!=i)c.unshift(new t.Diff(i,l)),u.start1-=s,u.start2-=s,u.length1+=s,u.length2+=s;else if(s>c[0][1].length){var f=s-c[0][1].length;c[0][1]=l.substring(c[0][1].length)+c[0][1],u.start1-=f,u.start2-=f,u.length1+=f,u.length2+=f}if(u=o[o.length-1],c=u.diffs,c.length==0||c[c.length-1][0]!=i)c.push(new t.Diff(i,l)),u.length1+=s,u.length2+=s;else if(s>c[c.length-1][1].length){var f=s-c[c.length-1][1].length;c[c.length-1][1]+=l.substring(0,f),u.length1+=f,u.length2+=f}return l},t.prototype.patch_splitMax=function(o){for(var s=this.Match_MaxBits,l=0;l<o.length;l++)if(!(o[l].length1<=s)){var a=o[l];o.splice(l--,1);for(var u=a.start1,c=a.start2,f="";a.diffs.length!==0;){var d=new t.patch_obj,p=!0;for(d.start1=u-f.length,d.start2=c-f.length,f!==""&&(d.length1=d.length2=f.length,d.diffs.push(new t.Diff(i,f)));a.diffs.length!==0&&d.length1<s-this.Patch_Margin;){var y=a.diffs[0][0],m=a.diffs[0][1];y===r?(d.length2+=m.length,c+=m.length,d.diffs.push(a.diffs.shift()),p=!1):y===n&&d.diffs.length==1&&d.diffs[0][0]==i&&m.length>2*s?(d.length1+=m.length,u+=m.length,p=!1,d.diffs.push(new t.Diff(y,m)),a.diffs.shift()):(m=m.substring(0,s-d.length1-this.Patch_Margin),d.length1+=m.length,u+=m.length,y===i?(d.length2+=m.length,c+=m.length):p=!1,d.diffs.push(new t.Diff(y,m)),m==a.diffs[0][1]?a.diffs.shift():a.diffs[0][1]=a.diffs[0][1].substring(m.length))}f=this.diff_text2(d.diffs),f=f.substring(f.length-this.Patch_Margin);var b=this.diff_text1(a.diffs).substring(0,this.Patch_Margin);b!==""&&(d.length1+=b.length,d.length2+=b.length,d.diffs.length!==0&&d.diffs[d.diffs.length-1][0]===i?d.diffs[d.diffs.length-1][1]+=b:d.diffs.push(new t.Diff(i,b))),p||o.splice(++l,0,d)}}},t.prototype.patch_toText=function(o){for(var s=[],l=0;l<o.length;l++)s[l]=o[l];return s.join("")},t.prototype.patch_fromText=function(o){var s=[];if(!o)return s;for(var l=o.split(`
84
+ `),a=0,u=/^@@ -(\d+),?(\d*) \+(\d+),?(\d*) @@$/;a<l.length;){var c=l[a].match(u);if(!c)throw new Error("Invalid patch string: "+l[a]);var f=new t.patch_obj;for(s.push(f),f.start1=parseInt(c[1],10),c[2]===""?(f.start1--,f.length1=1):c[2]=="0"?f.length1=0:(f.start1--,f.length1=parseInt(c[2],10)),f.start2=parseInt(c[3],10),c[4]===""?(f.start2--,f.length2=1):c[4]=="0"?f.length2=0:(f.start2--,f.length2=parseInt(c[4],10)),a++;a<l.length;){var d=l[a].charAt(0);try{var p=decodeURI(l[a].substring(1))}catch{throw new Error("Illegal escape in patch_fromText: "+p)}if(d=="-")f.diffs.push(new t.Diff(n,p));else if(d=="+")f.diffs.push(new t.Diff(r,p));else if(d==" ")f.diffs.push(new t.Diff(i,p));else{if(d=="@")break;if(d!=="")throw new Error('Invalid patch mode "'+d+'" in: '+p)}a++}}return s},t.patch_obj=function(){this.diffs=[],this.start1=null,this.start2=null,this.length1=0,this.length2=0},t.patch_obj.prototype.toString=function(){var o,s;this.length1===0?o=this.start1+",0":this.length1==1?o=this.start1+1:o=this.start1+1+","+this.length1,this.length2===0?s=this.start2+",0":this.length2==1?s=this.start2+1:s=this.start2+1+","+this.length2;for(var l=["@@ -"+o+" +"+s+` @@
85
+ `],a,u=0;u<this.diffs.length;u++){switch(this.diffs[u][0]){case r:a="+";break;case n:a="-";break;case i:a=" ";break}l[u+1]=a+encodeURI(this.diffs[u][1])+`
86
+ `}return l.join("").replace(/%20/g," ")},e.exports=t,e.exports.diff_match_patch=t,e.exports.DIFF_DELETE=n,e.exports.DIFF_INSERT=r,e.exports.DIFF_EQUAL=i})(X0);var G2=X0.exports;new G2.diff_match_patch;class Q2{constructor(){I(this,"value",0);Uf(this)}}new Q2;function Z0(e){var n,r,i,o,s,l;let t=[0,0,0,0];return t&&((n=e==null?void 0:e.html)!=null&&n.src&&(t[1]+=(r=e.html)==null?void 0:r.src.length),((o=(i=e==null?void 0:e.html)==null?void 0:i.untracked)==null?void 0:o.length)===2&&((s=e==null?void 0:e.html)==null||s.untracked[0].forEach(a=>{var u;t[2]+=(u=a==null?void 0:a.content)==null?void 0:u.length}),(l=e==null?void 0:e.html)==null||l.untracked[1].forEach(a=>{var u;t[3]+=(u=a==null?void 0:a.value)==null?void 0:u.length})),t[0]=t[1]+t[2]+t[3],t)}function Y2(e){let t={total:0,before:[0,0,0,0],after:[0,0,0,0]};for(let n in e)t[n]=Z0(e[n]),t.total+=t[n][0];return t}function J0(e){Array.isArray(e)?e.forEach(t=>cp(t)):cp(e)}function cp(e){e.type==="command"?X2(e):e.type==="request"?J2(e):e.type==="response"?q2(e):e.type==="log"?eA(e):e.type==="context"?tA(e):console.warn(e)}function X2(e){var a,u;let t="";((a=e.snapshots)!=null&&a.after||(u=e.snapshots)!=null&&u.before)&&(t+="S");let n=Y2(e.snapshots),r=(n.total/1e3).toFixed(2),i=(((n==null?void 0:n.before[1])+(n==null?void 0:n.after[1]))/1e3).toFixed(2),o=(((n==null?void 0:n.before[2])+(n==null?void 0:n.after[2]))/1e3).toFixed(2),s=(((n==null?void 0:n.before[3])+(n==null?void 0:n.after[3]))/1e3).toFixed(2),l=["color: #18c0d1","kb","color: #d2d3d3"];console.groupCollapsed("%s %s %s %c%s %c%s%c%s%c [%s%c%s%c, %s%c%s%c, %s%c%s%c] %s",e.context.id,e.type,e.func.padEnd(10),"color: #bada55",t.length===0?"-":t,"color: #d2d3d3",r,...l,i,...l,o,...l,s,...l,e.func),console.group("Snapshots");for(let c in e.snapshots)Z2(c,e.snapshots[c]);console.groupEnd(),console.log("source",e),console.groupEnd()}function Z2(e,t){if(!t)return;let n=Z0(t);console.group(e),console.log("Url:",t.url),console.log("Size total:",(n[0]/1e3).toFixed(2),"kb"),console.log("Size html:",(n[1]/1e3).toFixed(2),"kb"),console.log("Size css:",(n[2]/1e3).toFixed(2),"kb"),console.log("Size js:",(n[3]/1e3).toFixed(2),"kb"),console.log("Viewport:",t.viewport),console.log("Version:",t.version),console.log(t),console.groupEnd()}function J2(e){console.groupCollapsed(e.context.id,e.type.substring(0,3),e.resourceType.padEnd(10),e.method.padEnd(6),e.url.length>64?e.url.substring(0,60)+"...":e.url),console.log("Headers"),console.table(e.headers),console.log("source",e),console.groupEnd()}function q2(e){var n;let t=((n=e.content)==null?void 0:n.byteLength)??e.contentLength??0;console.groupCollapsed(e.context.id,e.type.substring(0,3),e.resourceType.padEnd(10),e.method.padEnd(6),e.url.length>64?e.url.substring(0,60)+"...":e.url,(t/1e3).toFixed(2),"kb"),console.log("Headers"),console.table(e.headers),console.log("source",e),console.groupEnd()}function eA(e){console.groupCollapsed(e.context.id,e.type,e.messageType,e.args),console.log("source",e),console.groupEnd()}function tA(e){console.groupCollapsed(e.id,e.type),console.log("source",e),console.groupEnd()}let Ml=()=>{};function nA(e){Ml(()=>{console.group("Packet received"),console.groupCollapsed("Events",Array.isArray(e)?e.length:1),J0(e),console.groupEnd(),console.groupEnd()})}class Ll{constructor(){I(this,"_debug",!1);I(this,"_connectAutomatically",!1);I(this,"_originalDebugFunc");Uf(this),this._originalDebugFunc=console.debug,this.debug=localStorage.getItem("debug.enabled")==="true",this.connectAutomatically=localStorage.getItem("connectAutomatically.enabled")==="true"}get debug(){return this._debug}set debug(t){this._debug=t,localStorage.setItem("debug.enabled",t?"true":"false"),t?this.enable():this.disable()}get connectAutomatically(){return this._connectAutomatically}set connectAutomatically(t){this._connectAutomatically=t,localStorage.setItem("connectAutomatically.enabled",t?"true":"false")}enable(){console.debug=this._originalDebugFunc,Ml=t=>t(),Ar.on("*",Ll.eventLogger),this.printPerformanceWarning()}disable(){this._originalDebugFunc=console.debug,console.debug=()=>{},Ml=()=>{},Ar.off("*",Ll.eventLogger)}static eventLogger(t,n){console.log("[EventLogger]",t,n)}printPerformanceWarning(){console.warn("[Puth] Performance is affected by debug")}}const fp=new Ll;var rA={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};const iA=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Ae=(e,t)=>{const n=x.forwardRef(({color:r="currentColor",size:i=24,strokeWidth:o=2,absoluteStrokeWidth:s,children:l,...a},u)=>x.createElement("svg",{ref:u,...rA,width:i,height:i,stroke:r,strokeWidth:s?Number(o)*24/Number(i):o,className:`lucide lucide-${iA(e)}`,...a},[...t.map(([c,f])=>x.createElement(c,f)),...(Array.isArray(l)?l:[l])||[]]));return n.displayName=`${e}`,n},oA=Ae("AlertCircle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]),sA=Ae("CheckCircle2",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]),lA=Ae("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]),aA=Ae("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]),uA=Ae("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]),cA=Ae("CircleDashed",[["path",{d:"M10.1 2.18a9.93 9.93 0 0 1 3.8 0",key:"1qdqn0"}],["path",{d:"M17.6 3.71a9.95 9.95 0 0 1 2.69 2.7",key:"1bq7p6"}],["path",{d:"M21.82 10.1a9.93 9.93 0 0 1 0 3.8",key:"1rlaqf"}],["path",{d:"M20.29 17.6a9.95 9.95 0 0 1-2.7 2.69",key:"1xk03u"}],["path",{d:"M13.9 21.82a9.94 9.94 0 0 1-3.8 0",key:"l7re25"}],["path",{d:"M6.4 20.29a9.95 9.95 0 0 1-2.69-2.7",key:"1v18p6"}],["path",{d:"M2.18 13.9a9.93 9.93 0 0 1 0-3.8",key:"xdo6bj"}],["path",{d:"M3.71 6.4a9.95 9.95 0 0 1 2.7-2.69",key:"1jjmaz"}]]),fA=Ae("CloudOff",[["path",{d:"m2 2 20 20",key:"1ooewy"}],["path",{d:"M5.782 5.782A7 7 0 0 0 9 19h8.5a4.5 4.5 0 0 0 1.307-.193",key:"yfwify"}],["path",{d:"M21.532 16.5A4.5 4.5 0 0 0 17.5 10h-1.79A7.008 7.008 0 0 0 10 5.07",key:"jlfiyv"}]]),dA=Ae("Compass",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polygon",{points:"16.24 7.76 14.12 14.12 7.76 16.24 9.88 9.88 16.24 7.76",key:"m9r19z"}]]),hA=Ae("Download",[["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["polyline",{points:"7 10 12 15 17 10",key:"2ggqvy"}],["line",{x1:"12",x2:"12",y1:"15",y2:"3",key:"1vk2je"}]]),pA=Ae("Folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]),vA=Ae("History",[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}],["path",{d:"M12 7v5l4 2",key:"1fdv2h"}]]),gA=Ae("Loader2",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]),mA=Ae("RefreshCw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]),yA=Ae("Settings",[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]),wA=Ae("Timer",[["line",{x1:"10",x2:"14",y1:"2",y2:"2",key:"14vaq8"}],["line",{x1:"12",x2:"15",y1:"14",y2:"11",key:"17fdiu"}],["circle",{cx:"12",cy:"14",r:"8",key:"1e1u0o"}]]),xA=Ae("XCircle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]),_A=Ae("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),bA=Ae("Zap",[["polygon",{points:"13 2 3 14 12 14 11 22 21 10 12 10 13 2",key:"45s27k"}]]),SA={bolt:bA,cancel:xA,check:lA,check_circle:sA,close:_A,cloud_off:fA,download:hA,error:oA,expand_less:uA,expand_more:aA,explore:dA,folder:pA,history:vA,pending:cA,progress_activity:gA,refresh:mA,settings:yA,timer:wA},Pt=({name:e,size:t,className:n,onClick:r,...i})=>{const o=SA[e];return h.jsx(o,{size:t??"1rem",className:"inline-block "+(n??""),onClick:r,...i})},q0=Se(function({onConnected:t}){const{app:n}=x.useContext(Ee),[r,i]=x.useState(!1),[o,s]=x.useState(""),[l,a]=x.useState(null),u=x.useCallback(c=>{i(!0),n.tryConnectingTo(c).then(()=>{s(""),a(null),t==null||t()}).finally(()=>{i(!1)}).catch(f=>a(f))},[t]);return h.jsxs("div",{className:"flex flex-col gap-3.5",children:[h.jsxs("label",{className:"flex flex-col gap-1.5",children:[h.jsx("span",{className:"font-mono text-[11.5px] text-ink-muted",children:"Address"}),h.jsx("input",{className:"h-10 w-full rounded-lg border border-shell-control bg-shell-main px-3 font-mono text-[13px] text-ink outline-none focus:border-accent-blue/50",placeholder:"ws://host:7345/websocket",onChange:c=>s(c.target.value),onKeyDown:c=>c.key==="Enter"&&o!==""&&u(o),value:o})]}),l&&h.jsxs("div",{role:"alert",className:"flex gap-2.5 rounded-lg border border-red-400/30 bg-red-500/[0.08] px-3 py-2.5",children:[h.jsx(Pt,{name:"bolt",className:"mt-0.5 flex-none text-red-300"}),h.jsx("span",{className:"font-mono text-xs text-red-300",children:(l==null?void 0:l.reason)??"Unknown error"})]}),n.connectionSuggestions.length>0&&h.jsxs("div",{className:"flex flex-col gap-1.5",children:[h.jsx("span",{className:"font-mono text-[11.5px] text-ink-muted",children:"Suggestions"}),n.connectionSuggestions.map((c,f)=>h.jsx("button",{type:"button",disabled:r,className:"flex min-h-[44px] w-full items-center rounded-lg border border-white/[0.12] bg-shell-main px-3 text-left font-mono text-[12.5px] text-ink hover:border-accent-blue/45 hover:bg-blue-600/10",onClick:()=>u(c),children:c},f))]}),h.jsxs("div",{className:"flex items-center justify-end gap-3",children:[r&&h.jsxs("span",{className:"flex items-center gap-2 font-mono text-xs text-ink-muted",children:[h.jsx(Pt,{name:"progress_activity",className:"animate-spin text-accent-blue"})," Connecting"]}),h.jsx("button",{type:"button",onClick:()=>u(o),disabled:r||o==="",className:"inline-flex min-h-[40px] items-center gap-2 bg-blue-600 px-4 font-mono text-[13px] font-medium text-white hover:bg-blue-500 disabled:opacity-50",children:"Connect"})]})]})}),EA=Se(function(){const{app:t}=x.useContext(Ee),[n,r]=x.useState(!1),[i,o]=x.useState(!1),s=t.connections[0],l=s?s.isConnected?"connected":"closed":"none",a=async()=>{o(!0),await(s==null?void 0:s.retry().catch(()=>{}).finally(()=>o(!1)))},u={none:"No connection",connected:"Connected",closed:"Connection closed"}[l];return h.jsxs(G0,{open:n,onOpenChange:r,children:[h.jsx(Q0,{asChild:!0,children:h.jsx("button",{type:"button","aria-label":`${u}. Connection details`,title:s?`${u} · ${s.uri}`:u,className:ae("flex h-10 w-10 items-center justify-center rounded-[10px] border",n?"border-accent-blue/35 bg-blue-600/[0.16]":"border-transparent hover:bg-white/[0.05]"),children:h.jsx("span",{"aria-hidden":!0,className:ae("h-[9px] w-[9px] rounded-full",l==="connected"&&"bg-green-500 shadow-[0_0_0_4px_rgba(34,197,94,0.18)]",l==="closed"&&"bg-red-400 shadow-[0_0_0_4px_rgba(248,113,113,0.18)]",l==="none"&&"border-[1.5px] border-ink-muted")})})}),h.jsxs(nd,{side:"right",align:"end",sideOffset:10,className:"w-[420px] max-w-[calc(100vw-80px)] overflow-hidden rounded-xl border-white/[0.16] bg-[#151515] p-0 text-ink shadow-[0_24px_60px_rgba(0,0,0,0.65)]",children:[h.jsxs("div",{className:"flex justify-between border-b border-dashed border-neutral-800 px-[18px] py-3 font-mono text-xs",children:[h.jsx("span",{className:"text-accent-blue",children:"Connection"}),h.jsx("span",{className:ae(l==="connected"?"text-green-300":l==="closed"?"text-red-300":"text-ink-muted"),children:u})]}),h.jsxs("div",{className:"flex flex-col gap-3.5 p-[18px]",children:[s&&h.jsxs("div",{className:"flex items-center gap-3 rounded-lg border border-white/[0.12] bg-shell-main px-3 py-2.5",children:[h.jsx("span",{className:"min-w-0 flex-1 truncate font-mono text-[12.5px] text-ink-body",children:s.uri}),l==="closed"&&h.jsxs("button",{type:"button",onClick:a,disabled:i,className:"flex min-h-[30px] items-center gap-1.5 rounded-md border border-white/20 px-2.5 text-xs text-ink-body hover:bg-white/[0.08]",children:[h.jsx(Pt,{name:"refresh",className:i?"animate-spin":""})," Reconnect"]})]}),h.jsx("div",{className:"text-[13px] text-ink-muted",children:s?"Switch to another instance":"Connect to a Puth instance"}),h.jsx(q0,{onConnected:()=>r(!1)})]})]})]})}),qi=({d:e})=>h.jsx("svg",{"aria-hidden":!0,width:"18",height:"18",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round",strokeLinejoin:"round",children:h.jsx("path",{d:e})}),hu=({label:e,active:t,onClick:n,children:r,badge:i})=>h.jsxs("button",{type:"button","aria-label":i!==void 0?`${e}, ${i}`:e,"aria-current":t?"page":void 0,title:e,onClick:n,className:ae("relative flex h-10 w-10 items-center justify-center rounded-[10px] border",t?"border-accent-blue/35 bg-blue-600/[0.16] text-accent-sky":"border-transparent text-ink-muted hover:bg-white/[0.05] hover:text-ink"),children:[r,i!==void 0&&h.jsx("span",{className:"absolute right-[3px] top-1 flex h-[15px] min-w-[15px] items-center justify-center rounded-full bg-neutral-800 px-[3px] font-mono text-[10px] text-ink-body",children:i})]}),dp=({id:e,label:t,checked:n,onChange:r})=>h.jsxs("label",{htmlFor:e,className:"flex min-h-[44px] cursor-pointer items-center gap-2.5 rounded-md px-2 text-sm text-ink-body hover:bg-white/[0.04]",children:[h.jsx("input",{id:e,type:"checkbox",checked:n,onChange:i=>r(i.target.checked),className:"m-0 h-4 w-4 accent-blue-600"}),t]}),AA=Se(function(){const{app:t}=x.useContext(Ee);return h.jsxs(G0,{children:[h.jsx(Q0,{asChild:!0,children:h.jsx("button",{type:"button","aria-label":"Settings",title:"Settings",className:"flex h-10 w-10 items-center justify-center rounded-[10px] border border-transparent text-ink-muted hover:bg-white/[0.05] hover:text-ink data-[state=open]:border-accent-blue/35 data-[state=open]:bg-blue-600/[0.16] data-[state=open]:text-accent-sky",children:h.jsx(qi,{d:"M4 6h10M18 6h2M4 12h4M12 12h8M4 18h12"})})}),h.jsxs(nd,{side:"right",align:"end",sideOffset:10,className:"w-[260px] overflow-hidden rounded-[10px] border-white/[0.16] bg-[#151515] p-0 text-ink shadow-[0_20px_50px_rgba(0,0,0,0.6)]",children:[h.jsx("div",{className:"border-b border-dashed border-neutral-800 px-3.5 py-2.5 font-mono text-[11.5px] text-accent-blue",children:"Settings"}),h.jsxs("div",{className:"flex flex-col p-1.5",children:[h.jsx(dp,{id:"darken-preview",label:"Darken preview",checked:t.settings.preview.darken,onChange:n=>t.setDarkenPreview(n)}),h.jsx(dp,{id:"debug-mode",label:"Debug mode",checked:fp.debug,onChange:n=>fp.debug=n})]})]})]})}),CA=Se(function(){const{app:t}=x.useContext(Ee);return h.jsxs("nav",{"aria-label":"App",className:"flex w-14 flex-none flex-col items-center gap-1.5 border-r border-shell-line bg-shell-rail py-3",children:[h.jsxs("div",{className:"flex flex-col items-center gap-0.5",title:t.name.suffix?`Puth ${t.name.suffix}`:"Puth",children:[h.jsx("img",{src:fb,alt:"Puth",className:"h-6 w-6 object-contain"}),t.name.suffix&&h.jsx("span",{className:"font-mono text-[9px] text-accent-sky",children:t.name.suffix})]}),h.jsx("span",{"aria-hidden":!0,className:"my-1 w-6 border-t border-dashed border-neutral-700"}),h.jsx(hu,{label:"Instance",active:t.view==="instance",onClick:()=>t.setView("instance"),children:h.jsx(qi,{d:"M4 5h16v11H4zM8 20h8M12 16v4"})}),t.isConnected&&h.jsx(hu,{label:"Agents",active:t.view==="agents",onClick:()=>t.setView("agents"),badge:t.liveAgents||void 0,children:h.jsx(qi,{d:"M12 3v3M8 6h8a3 3 0 0 1 3 3v6a3 3 0 0 1-3 3H8a3 3 0 0 1-3-3V9a3 3 0 0 1 3-3ZM9.5 11.5v1M14.5 11.5v1M2 12h3M19 12h3"})}),t.hasLocalContexts&&h.jsx(hu,{label:"Local snapshots",active:t.view==="local",onClick:()=>t.setView("local"),badge:t.dragAndDropped.contexts.length,children:h.jsx(qi,{d:"M4 7h6l2 2h8v10H4z"})}),h.jsx("span",{className:"flex-1"}),h.jsx("a",{href:"https://puth.io/guide/getting-started",target:"_blank",rel:"noreferrer","aria-label":"Documentation, opens puth.io",title:"Documentation",puth:"docs",className:"flex h-10 w-10 items-center justify-center rounded-[10px] border border-transparent text-ink-muted hover:bg-white/[0.05] hover:text-ink",children:h.jsx(qi,{d:"M4 5.5A2.5 2.5 0 0 1 6.5 3H20v15H6.5A2.5 2.5 0 0 0 4 20.5zM4 20.5A2.5 2.5 0 0 0 6.5 23H20v-5"})}),h.jsx(AA,{}),h.jsx(EA,{})]})});var fo=(e=>(e.SUCCESSFUL="successful",e.FAILED="failed",e.PENDING="pending",e))(fo||{}),ey=(e=>(e.FRAME="frame",e.DOM="dom",e))(ey||{}),ye=(e=>(e.BEFORE="before",e.AFTER="after",e.REPLAY="replay",e))(ye||{});const ho={Page:"CdpPage",Browser:"CdpBrowser",ElementHandle:"CdpElementHandle"},hp=1,kA=500,OA=150;function Il({content:e,children:t,className:n}){const[r,i]=x.useState(!1),o=x.useRef(),s=x.useRef();x.useEffect(()=>()=>{window.clearTimeout(o.current),window.clearTimeout(s.current)},[]);const l=()=>{window.clearTimeout(s.current),r||(window.clearTimeout(o.current),o.current=window.setTimeout(()=>i(!0),kA))},a=()=>{window.clearTimeout(o.current),s.current=window.setTimeout(()=>i(!1),OA)},u=()=>window.clearTimeout(s.current);return h.jsxs(z0,{open:r,onOpenChange:i,children:[h.jsx(d2,{asChild:!0,children:h.jsx("div",{className:n,onMouseEnter:l,onMouseMove:l,onMouseLeave:a,onMouseDown:()=>{window.clearTimeout(o.current),i(!1)},children:t})}),h.jsx(U0,{children:h.jsx(ed,{side:"right",align:"start",sideOffset:10,collisionPadding:8,onMouseEnter:u,onMouseLeave:a,onOpenAutoFocus:c=>c.preventDefault(),onCloseAutoFocus:c=>c.preventDefault(),puth:"detail",className:"z-50 w-[440px] max-w-[calc(100vw-24px)] overflow-hidden rounded-[10px] border border-white/[0.16] bg-[#151515] text-ink shadow-[0_20px_50px_rgba(0,0,0,0.6)] outline-none data-[state=open]:animate-in data-[state=open]:fade-in-0",children:e()})})]})}const Fl=({children:e})=>h.jsx("div",{className:"flex items-center gap-2 border-b border-dashed border-neutral-800 px-3.5 py-2.5 font-mono text-[11.5px]",children:e}),fr=({label:e,children:t})=>h.jsxs("div",{className:"px-3.5 py-2.5",children:[e&&h.jsx("div",{className:"mb-1.5 font-mono text-[11px] text-ink-muted",children:e}),h.jsx("div",{className:"max-h-[280px] overflow-auto whitespace-pre-wrap font-mono text-xs leading-relaxed text-ink-body [overflow-wrap:anywhere]",children:t})]});function ty({status:e,className:t,...n}){let r="pending";return e==="failed"?(r="error",t="text-red-400 "+(t??"")):e==="successful"?(r="check_circle",t="text-green-400 "+(t??"")):t="text-amber-300 "+(t??""),h.jsx(Pt,{name:r,className:t,...n})}function PA({resolver:e,name:t}){const n=x.useRef(null),r=async()=>{if(!n.current)return;let i=await e();n.current.href=URL.createObjectURL(i),n.current.download=t??"snapshot.puth",n.current.click(),URL.revokeObjectURL(n.current.href)};return h.jsxs(h.Fragment,{children:[h.jsx("button",{type:"button",puth:"export-snapshot","aria-label":"Export snapshot",title:"Export snapshot",className:"flex h-8 w-8 items-center justify-center rounded-md border border-shell-control bg-shell-main text-ink-body hover:border-accent-blue/40 hover:text-ink",onClick:r,children:h.jsx(Pt,{name:"download"})}),h.jsx("a",{href:"",style:{display:"none"},ref:n})]})}function ny(e){return e===ho.ElementHandle?"Element":e===ho.Page?"Page":e===ho.Browser?"Browser":e}function ry(e){return(e??[]).map(t=>typeof t=="string"?`'${t}'`:JSON.stringify(t)).join(", ")}function iy(e){return e.messageType==="error"&&(e.args??[]).length===0?e.text??"":(e.args??[]).map(t=>typeof t=="object"?JSON.stringify(t):t).join(" ")}function rd(e){var n,r,i,o;const t=(n=e.errors)==null?void 0:n[0];if(t)return{title:t.type==="error"?((r=t.error)==null?void 0:r.name)??"Error":"Expectation missed",message:t.type==="error"?((i=t.error)==null?void 0:i.message)??"":((o=t.expectation)==null?void 0:o.message)??""}}function oy(e){var t,n,r;return((t=e.time)==null?void 0:t.took)??Math.max(0,(((n=e.time)==null?void 0:n.finished)??0)-(((r=e.time)==null?void 0:r.started)??0))}const un=e=>e.type==="log",sy=e=>e.type==="response"||e.type==="update",Lo=e=>un(e)?e.messageType==="error"||e.messageType==="warning":e.status==="failed"||Number(e.status)>=400,NA=["visit","setContent","blank","refresh","reload","back","forward","goto"];function jA(e,t){if(e.initiator==="setContent")return{label:e.title||"Page content",detail:"setContent",url:`${e.url}#${e.title}`};try{const n=new URL(e.url),r=t&&t.url.startsWith(n.origin),i=n.pathname+n.search+n.hash;return n.protocol.startsWith("http")?{label:r?i:n.host+i,url:e.url}:{label:n.hash||e.url,url:e.url}}catch{return{label:e.url,url:e.url}}}function ly(e){var u;const t=[],n=[],r=[],i=e.some(c=>c.type==="annotation"||c.type==="handoff");let o=!1,s,l;const a=()=>(r.length===0&&r.push({drafts:[],steps:[]}),r[r.length-1]);for(const c of e)if(c.type==="navigation"){if(c.url==="about:blank"&&c.initiator!=="setContent"&&s===void 0)continue;const f=jA(c,s);if(f.url===(s==null?void 0:s.url)&&f.label===(s==null?void 0:s.label))continue;s=f;const d=n[n.length-1],p=d&&c.timestamp<=(((u=d.command.time)==null?void 0:u.finished)||1/0);d&&p&&NA.includes(d.command.func)?d.page=f:l=f}else if(c.type==="handoff")c.state==="ended"&&(o=!1,r.push({label:"After the handoff",drafts:[],steps:[]}));else if(c.type==="annotation")c.kind==="quiet"?o=c.quiet===!0:c.kind==="tool"?r.push({tool:c,drafts:[],steps:[]}):c.kind==="draft"&&a().drafts.push(c);else if(c.type==="command"){if(o||i&&c.func==="setTimeout")continue;const f={command:c,events:[],page:l};l=void 0,n.push(f),a().steps.push(f)}else(un(c)||sy(c))&&(n.length===0?t:n[n.length-1].events).push(c);return{leading:t,steps:n,sections:r}}function ay(e){const t=n=>(n<10?"0":"")+n;return`${t(e.minutes)}:${t(e.seconds)}s`}function TA(e){if(!e)return"";try{const t=new URL(e);return t.pathname+t.search}catch{return e}}function uy(e){return un(e)?iy(e):`${e.method??""} ${e.status==="failed"?`failed ${e.errorText??""}`:e.status??""} ${TA(e.url)}`.trim()}const RA={failed:["Failed","text-red-300"],successful:["Passed","text-green-300"]},DA=e=>{if(un(e)){const t=(e.stackTrace??[]).map(n=>`${n.url??""}${n.lineNumber!=null?":"+n.lineNumber:""}${n.columnNumber!=null?":"+n.columnNumber:""}`).filter(Boolean);return h.jsxs(h.Fragment,{children:[h.jsx(Fl,{children:h.jsxs("span",{className:Lo(e)?"text-amber-300":"text-ink-muted",children:["console.",e.messageType]})}),h.jsx(fr,{children:iy(e)}),t.length>0&&h.jsx(fr,{label:"Stack",children:t.join(`
87
+ `)})]})}return h.jsxs(h.Fragment,{children:[h.jsxs(Fl,{children:[h.jsxs("span",{className:Lo(e)?"text-amber-300":"text-accent-sky",children:[e.method??"GET"," ",e.status==="failed"?"failed":e.status]}),h.jsx("span",{className:"ml-auto text-ink-muted",children:e.resourceType})]}),h.jsx(fr,{label:"URL",children:e.url}),e.errorText&&h.jsx(fr,{label:"Error",children:e.errorText})]})},cy=({event:e})=>{const t=un(e);return h.jsx("li",{puth:t?"console-message":"network-request","data-level":t?e.messageType:void 0,children:h.jsxs(Il,{content:()=>DA(e),className:"flex min-h-[24px] items-center gap-2 rounded px-1 font-mono text-[11.5px] hover:bg-white/[0.04]",children:[h.jsx("span",{className:ae("flex-none",Lo(e)?"text-amber-300":"text-ink-muted"),children:t?`console.${e.messageType}`:e.resourceType??"request"}),h.jsx("span",{className:"min-w-0 flex-1 truncate text-ink-body",children:uy(e)})]})})};function pp(e){const t=e.filter(un).length,n=e.length-t;return[t&&`${t} console`,n&&`${n} ${n===1?"request":"requests"}`].filter(Boolean).join(" · ")}const fy=({events:e,open:t,onToggle:n,label:r})=>{if(e.length===0)return null;const i=e.some(Lo);return h.jsxs("div",{className:"ml-10 border-l border-dashed border-neutral-700 pl-2",children:[h.jsxs("button",{type:"button",puth:"step-events","aria-expanded":t,"aria-label":`${t?"Hide":"Show"} ${pp(e)} ${r}`,onClick:n,className:ae("flex min-h-[22px] w-full items-center gap-1 rounded px-1 text-left font-mono text-[11px] hover:bg-white/[0.04]",i?"text-amber-300":"text-ink-muted"),children:[h.jsx(Pt,{name:"expand_more",size:"0.7rem",className:ae("flex-none transition-transform",!t&&"-rotate-90")}),pp(e)]}),t&&h.jsx("ul",{className:"pb-1 pl-4",children:e.map(o=>h.jsx(cy,{event:o},o.id))})]})},MA=["visit","setContent","blank","refresh","reload","back","forward","goto","clickLink"],LA=/^(evaluate|value|text|attribute|url|title|screenshot|viewport|first|find|get|element|has|is|count|wait$|pause)/;function IA(e){return MA.includes(e)?"navigation":/^(assert|waitFor|waitUntil|waitUsing|expect)/.test(e)?"check":LA.test(e)?"read":"action"}const FA={navigation:"text-teal-300",action:"text-accent-sky",check:"text-violet-300",read:"text-ink-muted"},zA=({page:e})=>h.jsxs("li",{className:"flex items-center gap-2 px-3 pb-1 pt-2.5 font-mono text-[11px] text-ink-muted",puth:"page-divider",title:e.url,children:[h.jsx("span",{"aria-hidden":!0,children:"→"}),h.jsx("span",{className:"max-w-[70%] truncate text-ink-body",children:e.label}),e.detail&&h.jsx("span",{children:e.detail}),h.jsx("span",{"aria-hidden":!0,className:"flex-1 border-t border-dashed border-neutral-700"})]}),dy=e=>e>=1e3?(e/1e3).toFixed(1)+"s":Math.round(e)+"ms",UA=e=>typeof e=="string"?`'${e}'`:JSON.stringify(e,null,2),vp=(e,t,n)=>{var o;const r=rd(e),i=e.args??[];return h.jsxs(h.Fragment,{children:[h.jsxs(Fl,{children:[h.jsxs("span",{className:"text-accent-sky",children:[ny((o=e.on)==null?void 0:o.type),".",e.func]}),h.jsxs("span",{className:"ml-auto text-ink-muted",children:["step ",t+1," of ",n," · ",dy(oy(e))]})]}),i.length>0&&h.jsx(fr,{label:i.length===1?"Argument":"Arguments",children:i.map(UA).join(`,
88
+ `)}),r&&h.jsx(fr,{label:r.title,children:r.message})]})},BA=Se(function({context:t,step:n,index:r,count:i,open:o,onToggle:s}){var m;const{command:l,events:a}=n,u=t.preview,c=((m=u==null?void 0:u.activeCommand)==null?void 0:m.id)===l.id,f=(l.errors??[]).length>0,d=oy(l),p=c||f||d>=1e3,y=f&&t.isAgent?rd(l):void 0;return h.jsxs("li",{onMouseEnter:()=>u==null?void 0:u.highlightCommand(l),onMouseLeave:()=>u==null?void 0:u.unhighlightCommand(l),children:[h.jsx(Il,{content:()=>vp(l,r,i),children:h.jsxs("button",{type:"button",puth:"step","data-active":c?"true":void 0,"data-failed":f?"true":void 0,"aria-pressed":c,className:ae("flex h-[34px] w-full items-center gap-2.5 rounded-lg border px-3 text-left",c?"border-accent-blue/45 bg-blue-600/[0.12]":"border-transparent hover:bg-white/[0.04]"),onClick:()=>u==null?void 0:u.toggleCommand(l),children:[h.jsx("span",{className:ae("w-[18px] flex-none text-right font-mono text-[11px]",c?"text-accent-sky":f?"text-red-300":"text-[#8f8f8f]"),children:String(r+1).padStart(2,"0")}),h.jsx("span",{className:ae("flex-none font-mono text-[13px]",FA[IA(l.func)]),children:l.func}),h.jsx("span",{className:"min-w-0 flex-1 truncate font-mono text-xs text-ink-body",children:ry(l.args)}),p&&h.jsx("span",{className:ae("flex-none font-mono text-[11px]",f?"text-red-300":d>=1e3?"text-amber-300":"text-ink-muted"),children:dy(d)})]})}),y&&h.jsx(Il,{content:()=>vp(l,r,i),className:"ml-10 border-l border-dashed border-red-400/40 pl-2",children:h.jsxs("div",{className:"flex min-h-[22px] items-center gap-1.5 px-1 text-[12px] text-red-200","data-messagetype":"error",children:[h.jsxs("span",{className:"flex-none text-red-300/80",children:[y.title,"."]}),h.jsx("span",{className:"min-w-0 flex-1 truncate",children:y.message})]})}),h.jsx(fy,{events:a,open:o,onToggle:s,label:`after ${l.func}`})]})}),$A=Se(function({context:t}){const{app:n}=x.useContext(Ee),[r,i]=x.useState(!1);if(!t.group)return null;const o=n.history.filter(l=>l.group===t.group);if(o.length<2)return h.jsx("div",{className:"mt-1 font-mono text-xs text-ink-muted",children:t.group});const s=o.filter(l=>l.test.status==="failed").length;return h.jsxs(h.Fragment,{children:[h.jsxs("button",{type:"button","aria-expanded":r,onClick:()=>i(!r),className:"mt-1 flex min-h-[28px] flex-wrap items-center gap-1.5 text-left font-mono text-xs text-ink-muted",children:[h.jsx("span",{children:t.group}),h.jsxs("span",{className:"text-ink-body",children:["· ",o.length," tests"]}),s>0&&h.jsxs("span",{children:["· ",s," failed"]}),h.jsx(Pt,{name:"expand_more",size:"0.7rem",className:ae("transition-transform",r&&"rotate-180")})]}),r&&h.jsx("ul",{"aria-label":`Tests in ${t.group}`,className:"mt-2 flex flex-col gap-0.5 rounded-lg border border-white/[0.08] bg-shell-main p-1",children:o.map(l=>h.jsx("li",{children:h.jsxs("button",{type:"button","aria-current":l===t,onClick:()=>n.setActive(l),className:ae("flex min-h-[36px] w-full items-center gap-2.5 rounded-md border px-2.5 text-left text-[13px] hover:bg-white/[0.04]",l===t?"border-accent-blue/45 bg-blue-600/[0.12]":"border-transparent"),children:[h.jsx(ty,{status:l.test.status,size:"0.8rem"}),h.jsx("span",{className:"min-w-0 flex-1 truncate",children:l.test.name}),h.jsx("span",{className:"font-mono text-[11.5px] text-ink-muted",children:ay(l.took)})]})},l.id))})]})});function VA(e,t){x.useEffect(()=>{const n=r=>{const i=r.target;if(r.altKey||r.ctrlKey||r.metaKey||i!=null&&i.closest('input, textarea, select, [contenteditable="true"]'))return;const o=e.preview;if(!o||t.length===0)return;if(r.key==="ArrowLeft"||r.key==="ArrowRight"){o.state=r.key==="ArrowLeft"?ye.BEFORE:ye.AFTER,r.preventDefault();return}if(r.key!=="ArrowUp"&&r.key!=="ArrowDown")return;const s=t.findIndex(a=>{var u;return a.id===((u=o.activeCommand)==null?void 0:u.id)}),l=s===-1?r.key==="ArrowDown"?0:t.length-1:Math.min(t.length-1,Math.max(0,s+(r.key==="ArrowDown"?1:-1)));l!==s&&o.toggleCommand(t[l]),r.preventDefault()};return window.addEventListener("keydown",n),()=>window.removeEventListener("keydown",n)},[e,t])}const WA=({tool:e,steps:t})=>{const n=t.some(r=>(r.command.errors??[]).length>0);return h.jsxs("div",{className:"flex items-baseline gap-2 px-3 pb-1 pt-3 font-mono text-[11.5px]",puth:"tool-call",children:[h.jsx("span",{className:n?"text-red-300":"text-accent-sky",children:e.tool}),h.jsx("span",{className:"min-w-0 flex-1 truncate text-ink-muted",title:e.summary,children:e.summary}),t.length>0&&h.jsxs("span",{className:"flex-none text-ink-muted",children:[t.length," ",t.length===1?"step":"steps"]})]})},HA=({draft:e})=>{const[t,n]=x.useState(!1),r=()=>{var i;(i=navigator.clipboard)==null||i.writeText(e.code??"").then(()=>{n(!0),setTimeout(()=>n(!1),1500)}).catch(()=>{})};return h.jsx("div",{className:"mx-1 my-1 rounded-lg border border-white/[0.12] bg-shell-main",puth:"draft",children:h.jsxs(Il,{className:"flex h-[34px] items-center gap-2 pl-3 pr-1.5 font-mono text-[11.5px]",content:()=>h.jsxs(h.Fragment,{children:[h.jsxs(Fl,{children:[h.jsx("span",{className:"text-indigo-300",children:"Draft"}),h.jsxs("span",{className:"text-ink-body",children:[e.format," · ",e.name]}),h.jsx("span",{className:"ml-auto text-amber-300",children:"unverified until the suite passed it"})]}),h.jsx(fr,{children:e.code})]}),children:[h.jsx("span",{className:"flex-none text-indigo-300",children:"Draft"}),h.jsxs("span",{className:"min-w-0 flex-1 truncate text-ink-body",children:[e.format," · ",e.name]}),h.jsx("span",{className:"flex-none rounded bg-amber-500/[0.14] px-1.5 text-[10.5px] text-amber-300",children:"unverified"}),h.jsx("button",{type:"button",onClick:r,className:"min-h-[26px] flex-none rounded-md border border-white/20 px-2 text-ink-body hover:bg-white/[0.08]",children:t?"Copied":"Copy"})]})})},KA={waiting:"Waiting for an agent to take over",claimed:"An agent drives this test",ended:"Handed back to the test"},GA=Se(function({context:t}){var D;const{app:n}=x.useContext(Ee),r=x.useRef(null),[i,o]=x.useState("steps"),[s,l]=x.useState({}),{leading:a,steps:u,sections:c}=ly(t.renderedEvents),f=u.map(k=>k.command),d=t.renderedEvents.filter(un),p=t.renderedEvents.filter(sy);VA(t,f);const y=t.isAgent,m=t.handoff,b=y?-1:u.findIndex(k=>(k.command.errors??[]).length>0),v=b===-1?void 0:u[b],g=v&&rd(v.command),w=v&&[...a,...u.slice(0,b).flatMap(k=>k.events)].reverse().find(k=>un(k)?k.messageType==="error":Lo(k)),[_,S]=y?t.isLive?["Live","text-green-300"]:["Closed","text-ink-muted"]:RA[t.test.status??""]??["Running","text-amber-300"];x.useLayoutEffect(()=>{r.current&&t.followIncoming&&t.renderedEvents.length!==0&&(r.current.scrollTop=r.current.scrollHeight)},[t,t.renderedEvents.length]);const E=()=>jn(()=>{var z,B,K;t.followIncoming=!t.followIncoming;const k=f[f.length-1];t.followIncoming&&k&&((B=(z=t.preview)==null?void 0:z.activeCommand)==null?void 0:B.id)!==k.id&&((K=t.preview)==null||K.toggleCommand(k))}),A=()=>{var k,z,B;o("steps"),v&&((z=(k=t.preview)==null?void 0:k.activeCommand)==null?void 0:z.id)!==v.command.id&&((B=t.preview)==null||B.toggleCommand(v.command))},C=k=>ae("flex min-h-[32px] items-center gap-1.5 rounded-md border px-2.5 text-[13px]",k?"border-white/20 bg-neutral-800 text-ink":"border-transparent text-ink-muted hover:text-ink"),j=k=>ae("flex h-8 items-center gap-1.5 rounded-md border px-2.5 font-mono text-[11.5px]",k?"border-accent-blue/45 bg-blue-600/[0.14] text-accent-sky":"border-shell-control bg-shell-main text-ink-body hover:text-ink"),P=k=>{const z=u.indexOf(k),B=s[k.command.id]??!1;return h.jsxs(x.Fragment,{children:[k.page&&h.jsx(zA,{page:k.page}),h.jsx(BA,{context:t,step:k,index:z,count:u.length,open:B,onToggle:()=>l({...s,[k.command.id]:!B})})]},k.command.id)};return h.jsxs("section",{"aria-label":y?"Agent session":"Test run",className:"flex min-h-0 flex-1 flex-col",children:[h.jsxs("div",{className:"flex items-center gap-2 border-b border-dashed border-neutral-800 py-2 pl-4 pr-3 font-mono text-xs",children:[h.jsxs("span",{className:ae("flex items-center gap-1.5",S),children:[y&&t.isLive&&h.jsx("span",{"aria-hidden":!0,className:"h-[7px] w-[7px] animate-pulse rounded-full bg-green-500"}),_]}),h.jsxs("span",{className:"ml-auto mr-1 text-ink-muted",children:[y&&`${t.toolCalls} ${t.toolCalls===1?"call":"calls"} · `,u.length," ",u.length===1?"step":"steps"," · ",ay(t.took)]}),y&&t.isLive&&h.jsx("button",{type:"button",puth:"follow","aria-pressed":t.followIncoming,onClick:E,className:j(t.followIncoming),children:"Follow"}),y&&h.jsx("button",{type:"button","aria-pressed":n.pinned.includes(t.id),onClick:()=>n.togglePinned(t),className:j(n.pinned.includes(t.id)),title:"Keep this session listed after it closed",children:n.pinned.includes(t.id)?"Pinned":"Pin"}),h.jsx(PA,{name:`snapshot-${t.createdAt}-${t.id}.puth`,resolver:()=>t.blob()})]}),h.jsxs("div",{className:"px-4 pb-3 pt-3.5",children:[h.jsx("div",{className:"break-words text-[17px] font-medium tracking-[-0.01em]",children:t.test.name}),y?h.jsx("div",{className:"mt-1 font-mono text-xs text-ink-muted",children:"Agent session"}):h.jsx($A,{context:t})]}),m&&h.jsxs("div",{className:"mx-3 mb-3 flex items-center gap-2.5 rounded-[10px] border border-indigo-300/25 bg-indigo-500/[0.08] px-3 py-2 text-[12.5px]",puth:"handoff",children:[h.jsx("span",{"aria-hidden":!0,className:ae("h-[7px] w-[7px] flex-none rounded-full",m.state==="claimed"?"animate-pulse bg-indigo-300":"bg-indigo-300/50")}),h.jsxs("span",{className:"min-w-0 flex-1 text-ink-body",children:[KA[m.state],m.name&&h.jsxs("span",{className:"font-mono text-ink-muted",children:[" · ",m.name]})]}),m.state==="ended"&&m.reason&&h.jsx("span",{className:"font-mono text-[11px] text-ink-muted",children:m.reason})]}),v&&g&&h.jsxs("div",{className:"mx-3 mb-3 overflow-hidden rounded-[10px] border border-white/[0.14] bg-shell-main","data-messagetype":"error",children:[h.jsxs("div",{className:"flex items-center gap-2 border-b border-dashed border-neutral-800 py-2 pl-3 pr-2 font-mono text-[11.5px]",children:[h.jsxs("span",{className:"min-w-0 flex-1 truncate text-red-300",children:["Failed at ",v.command.func," ",(D=v.command.args)!=null&&D.length?ry(v.command.args.slice(0,1)):""]}),h.jsx("button",{type:"button",onClick:A,className:"min-h-[28px] flex-none rounded-md border border-white/20 px-2.5 text-ink-body hover:bg-white/[0.08]",children:"Show step"})]}),h.jsxs("div",{className:"px-3 py-2.5 text-[13px] leading-relaxed text-neutral-200",children:[h.jsxs("span",{className:"text-ink-muted",children:[g.title,"."]})," ",g.message]}),w&&h.jsxs("div",{className:"px-3 pb-2.5 text-[12.5px] leading-normal text-ink-muted",children:[un(w)?"Console error":"Request"," before this step: ",h.jsx("span",{className:"font-mono text-ink-body",children:uy(w)})]})]}),h.jsxs("div",{role:"tablist","aria-label":"Events",className:"flex gap-1 border-b border-dashed border-neutral-800 px-3 pb-2.5",children:[h.jsxs("button",{type:"button",role:"tab",puth:"tab-steps","aria-selected":i==="steps",className:C(i==="steps"),onClick:()=>o("steps"),children:["Steps ",h.jsx("span",{className:"font-mono text-[11px] text-ink-muted",children:u.length})]}),h.jsxs("button",{type:"button",role:"tab",puth:"tab-console","aria-selected":i==="console",className:C(i==="console"),onClick:()=>o("console"),children:["Console ",h.jsx("span",{className:"font-mono text-[11px] text-ink-muted",children:d.length})]}),p.length>0&&h.jsxs("button",{type:"button",role:"tab",puth:"tab-network","aria-selected":i==="network",className:C(i==="network"),onClick:()=>o("network"),children:["Network ",h.jsx("span",{className:"font-mono text-[11px] text-ink-muted",children:p.length})]})]}),h.jsx("div",{ref:r,className:"min-h-0 flex-1 overflow-y-auto p-2",children:i==="steps"?h.jsxs(h.Fragment,{children:[h.jsx(fy,{events:a,open:s.leading??!1,onToggle:()=>l({...s,leading:!s.leading}),label:"before the first step"}),c.map((k,z)=>{var B;return h.jsxs("div",{children:[k.tool&&h.jsx(WA,{tool:k.tool,steps:k.steps}),!k.tool&&(k.label||z===0&&c.length>1&&t.handoff)&&h.jsx("div",{className:"px-3 pb-1 pt-3 font-mono text-[11.5px] text-ink-muted",children:k.label??"Before the handoff"}),h.jsx("ol",{className:"flex flex-col",children:k.steps.map(P)}),k.drafts.map(K=>h.jsx(HA,{draft:K},K.id))]},((B=k.tool)==null?void 0:B.id)??z)}),u.length===0&&a.length===0&&c.length===0&&h.jsx("div",{className:"px-3 py-4 text-[13px] text-ink-muted",children:"No steps recorded yet."})]}):h.jsxs("ul",{className:"px-3",children:[(i==="console"?d:p).map(k=>h.jsx(cy,{event:k},k.id)),i==="console"&&d.length===0&&h.jsx("li",{className:"py-4 text-[13px] text-ink-muted",children:"No console output."})]})}),h.jsx("div",{className:"border-t border-shell-line px-4 py-2 font-mono text-[11.5px] text-ink-muted",children:"↑ ↓ step · ← → before / after"})]})}),QA=Se(function(){const{app:t}=x.useContext(Ee);return t.activeContext?h.jsx(GA,{context:t.activeContext},t.activeContext.id):h.jsxs("div",{className:"flex flex-1 flex-col items-center justify-center gap-3 p-8 text-center text-sm text-ink-muted",children:[h.jsx(Pt,{name:"explore",size:"2rem"}),t.view==="agents"?"Select an agent session below.":"Select a test in the history list below."]})});function YA(e){let t=new Date(e),n=""+(t.getMonth()+1),r=""+t.getDate(),i=t.getFullYear();return n.length<2&&(n="0"+n),r.length<2&&(r="0"+r),[i,n,r].join("-")}function XA(e){const t=n=>(n<10?"0":"")+n;return`${t(e.minutes)}:${t(e.seconds)}s`}const ZA=Se(function({context:t}){var i,o;const{app:n}=x.useContext(Ee),r=n.activeContext===t;return h.jsx("li",{children:h.jsxs("button",{type:"button",puth:"history-item","aria-current":r,className:ae("flex w-full items-start gap-2.5 rounded-lg border px-2.5 py-2 text-left hover:bg-white/[0.04]",r?"border-accent-blue/45 bg-blue-600/[0.12]":"border-transparent"),onClick:()=>n.setActive(t),children:[h.jsx(ty,{status:t.test.status,size:"0.95rem",className:"mt-0.5 flex-none"}),h.jsxs("span",{className:"flex min-w-0 flex-1 flex-col gap-[3px]",children:[h.jsxs("span",{className:"flex items-center gap-1.5",children:[h.jsx("span",{className:"truncate text-sm text-ink",children:t.test.name}),(((i=t.handoff)==null?void 0:i.state)==="waiting"||((o=t.handoff)==null?void 0:o.state)==="claimed")&&h.jsx("span",{className:"flex-none rounded bg-indigo-500/[0.16] px-1.5 font-mono text-[10.5px] text-indigo-200",children:t.handoff.state==="claimed"?"agent":"handoff"})]}),t.group&&h.jsx("span",{className:"truncate font-mono text-[11.5px] text-ink-muted",children:t.group})]}),h.jsxs("span",{className:"flex flex-none flex-col items-end gap-[3px] font-mono text-[11.5px] text-ink-muted",children:[h.jsx("span",{children:XA(t.took)}),h.jsx("span",{children:YA(t.lastActivity)})]})]})})}),JA=[["","All"],[fo.FAILED,"Failed"],[fo.SUCCESSFUL,"Passed"],[fo.PENDING,"Running"]],qA=Se(function(){const{app:t}=x.useContext(Ee),[n,r]=x.useState(!0),[i,o]=x.useState(""),[s,l]=x.useState("");if(t.empty)return h.jsx(h.Fragment,{});let a=t.history;if(i!==""){let u=i.toLowerCase();a=a.filter(c=>c.test.name.toLowerCase().includes(u)||(c.group??"").toLowerCase().includes(u))}return s!==""&&(a=a.filter(u=>(u.test.status??fo.PENDING)===s)),h.jsxs("section",{"aria-label":"History",className:ae("flex flex-col border-t border-shell-line",n&&"max-h-[40vh]"),children:[h.jsxs("button",{type:"button","aria-expanded":n,onClick:()=>r(!n),className:"flex min-h-[44px] flex-none items-center gap-2.5 border-b border-dashed border-neutral-800 px-4 font-mono text-xs",children:[h.jsx("span",{className:"text-accent-sky",children:"History"}),h.jsx("span",{className:"text-ink-muted",children:t.history.length}),h.jsx(Pt,{name:"expand_more",className:ae("ml-auto text-ink-muted transition-transform",n&&"rotate-180")})]}),n&&h.jsxs(h.Fragment,{children:[h.jsxs("div",{className:"flex flex-none flex-wrap gap-2 px-3 pb-1 pt-2.5",children:[h.jsxs("label",{className:"flex h-[34px] min-w-[160px] flex-1 items-center gap-2 rounded-lg border border-shell-control bg-shell-main px-2.5 text-ink-muted",children:[h.jsxs("svg",{"aria-hidden":!0,width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",children:[h.jsx("circle",{cx:"11",cy:"11",r:"7"}),h.jsx("path",{d:"m20 20-3.5-3.5"})]}),h.jsx("input",{type:"search","aria-label":"Filter history",placeholder:"Filter tests",value:i,onChange:u=>o(u.target.value),className:"min-w-0 flex-1 border-0 bg-transparent text-[13px] text-ink outline-none"})]}),h.jsx("div",{role:"group","aria-label":"Status",className:"flex h-[34px] rounded-lg border border-shell-control bg-shell-main p-0.5",children:JA.map(([u,c])=>h.jsx("button",{type:"button","aria-pressed":s===u,onClick:()=>l(u),className:ae("rounded-md px-2.5 font-mono text-[11.5px]",s===u?"bg-neutral-800 text-ink":"text-ink-muted hover:text-ink"),children:c},c))})]}),h.jsxs("ul",{className:"flex min-h-0 flex-col gap-0.5 overflow-y-auto px-2 pb-2.5 pt-1.5",children:[a.length===0&&h.jsx("li",{className:"px-2.5 py-3.5 text-[13px] text-ink-muted",children:t.history.length===0?"No tests have run on this instance yet.":"No tests match this filter."}),a.map(u=>h.jsx(ZA,{context:u},u.id))]})]})]})}),eC=10*60*1e3;function tC(e){const t=n=>(n<10?"0":"")+n;return`${t(e.minutes)}:${t(e.seconds)}s`}function nC(e,t){const n=Math.round((t-e)/6e4);return n<1?"just now":n<60?`${n} min ago`:`${Math.round(n/60)} h ago`}const gp=Se(function({context:t,now:n}){const{app:r}=x.useContext(Ee),i=r.activeContext===t,o=r.pinned.includes(t.id),s=!t.isAgent;return h.jsx("li",{children:h.jsxs("button",{type:"button",puth:"agent-item","aria-current":i,onClick:()=>r.setActive(t),className:ae("flex w-full items-start gap-2.5 rounded-lg border px-2.5 py-2 text-left hover:bg-white/[0.04]",i?"border-accent-blue/45 bg-blue-600/[0.12]":"border-transparent"),children:[h.jsx("span",{"aria-hidden":!0,className:ae("mt-[7px] h-[7px] w-[7px] flex-none rounded-full",t.isLive?"animate-pulse bg-green-500":"border border-ink-muted")}),h.jsxs("span",{className:"flex min-w-0 flex-1 flex-col gap-[3px]",children:[h.jsx("span",{className:"truncate text-sm text-ink",children:t.test.name}),h.jsxs("span",{className:"truncate font-mono text-[11.5px] text-ink-muted",children:[s?`handoff · ${t.group}`:`${t.toolCalls} ${t.toolCalls===1?"call":"calls"}`,o&&" · pinned"]})]}),h.jsxs("span",{className:"flex flex-none flex-col items-end gap-[3px] font-mono text-[11.5px] text-ink-muted",children:[h.jsx("span",{className:t.isLive?"text-green-300":void 0,children:t.isLive?"live":tC(t.took)}),!t.isLive&&h.jsx("span",{children:nC(t.lastActivity,n)})]})]})})}),rC=Se(function(){const{app:t}=x.useContext(Ee),[n,r]=x.useState(!1),[i,o]=x.useState(Date.now());x.useEffect(()=>{const d=setInterval(()=>o(Date.now()),3e4);return()=>clearInterval(d)},[]);const s=t.agents,l=d=>d.isLive||t.pinned.includes(d.id)||t.activeContext===d||i-d.lastActivity<eC,a=n?s:s.filter(l),u=s.length-s.filter(l).length,c=a.filter(d=>d.isLive),f=a.filter(d=>!d.isLive);return h.jsxs("section",{"aria-label":"Agent sessions",className:"flex max-h-[45vh] flex-col border-t border-shell-line",children:[h.jsxs("div",{className:"flex min-h-[44px] flex-none items-center gap-2.5 border-b border-dashed border-neutral-800 px-4 font-mono text-xs",children:[h.jsx("span",{className:"text-accent-sky",children:"Agent sessions"}),h.jsx("span",{className:"text-ink-muted",children:s.length}),t.liveAgents>0&&h.jsxs("span",{className:"ml-auto text-green-300",children:[t.liveAgents," live"]})]}),h.jsxs("ul",{className:"flex min-h-0 flex-col gap-0.5 overflow-y-auto px-2 pb-2.5 pt-1.5",children:[s.length===0&&h.jsxs("li",{className:"px-2.5 py-3.5 text-[13px] leading-relaxed text-ink-muted",children:["No agent sessions yet. Agents connected through the Puth MCP server show up here while they work."," ",h.jsx("a",{href:"https://puth.io/guide/mcp",target:"_blank",rel:"noreferrer",className:"text-accent-sky hover:text-blue-200",children:"Set up the MCP server"})]}),c.map(d=>h.jsx(gp,{context:d,now:i},d.id)),f.length>0&&c.length>0&&h.jsx("li",{"aria-hidden":!0,className:"mx-2.5 my-1 border-t border-dashed border-neutral-800"}),f.map(d=>h.jsx(gp,{context:d,now:i},d.id)),u>0&&h.jsx("li",{children:h.jsx("button",{type:"button",onClick:()=>r(!n),className:"w-full rounded-md px-2.5 py-2 text-left font-mono text-[11.5px] text-ink-muted hover:text-ink",children:n?"Hide older sessions":`Show ${u} older ${u===1?"session":"sessions"}`})})]})]})}),mp=e=>ae("min-w-[64px] rounded-md px-3 font-mono text-xs",e?"bg-blue-600 text-white":"text-ink-muted hover:text-ink"),iC=Se(function(){var s;const{app:t}=x.useContext(Ee),n=t.previewStore,r=(n==null?void 0:n.visibleHighlightState)??(n==null?void 0:n.state),i=(s=n==null?void 0:n.visibleScreencast)==null?void 0:s.page,o=l=>{n&&(n.state=l)};return h.jsxs("div",{className:"flex flex-none flex-wrap items-center gap-2.5 border-b border-shell-line bg-shell-bar px-3 py-2.5",children:[h.jsxs("div",{role:"group","aria-label":"Snapshot",className:"flex h-8 rounded-lg border border-shell-control bg-shell-main p-0.5",children:[h.jsx("button",{type:"button","aria-pressed":r===ye.BEFORE,className:mp(r===ye.BEFORE),onClick:()=>o(ye.BEFORE),children:"Before"}),h.jsx("button",{type:"button","aria-pressed":r===ye.AFTER,className:mp(r===ye.AFTER),onClick:()=>o(ye.AFTER),children:"After"})]}),h.jsxs("div",{className:"flex h-8 min-w-[200px] flex-1 items-center gap-2 rounded-lg border border-white/[0.12] bg-shell-main px-3 font-mono text-xs text-ink-body",children:[h.jsxs("svg",{"aria-hidden":!0,width:"13",height:"13",viewBox:"0 0 24 24",fill:"none",stroke:"#a3a3a3",strokeWidth:"2",children:[h.jsx("rect",{x:"5",y:"11",width:"14",height:"9",rx:"2"}),h.jsx("path",{d:"M8 11V8a4 4 0 0 1 8 0v3"})]}),h.jsx("span",{className:"truncate","aria-label":"Page URL",children:(i==null?void 0:i.url)??""})]}),(i==null?void 0:i.viewport)&&h.jsxs("span",{className:"font-mono text-xs text-ink-muted",children:[i.viewport.width," × ",i.viewport.height]})]})}),oC=Se(function(){var l,a;const{app:t}=x.useContext(Ee),n=t.previewStore,r=n==null?void 0:n.visibleCommand,i=ly(((l=t.activeContext)==null?void 0:l.renderedEvents)??[]).steps.map(u=>u.command),o=r?i.findIndex(u=>u.id===r.id):-1,s=u=>(u<10?"0":"")+u;return h.jsxs("div",{className:"flex flex-none flex-wrap justify-between gap-x-6 gap-y-2 border-t border-shell-line bg-shell-bar px-4 py-3 font-mono text-xs text-ink-muted",children:[r&&o!==-1?h.jsxs("span",{children:["Step ",h.jsx("span",{className:"text-ink",children:s(o+1)})," / ",s(i.length)," · ",h.jsxs("span",{className:"text-accent-sky",children:[ny((a=r.on)==null?void 0:a.type),".",r.func]})," · ",n==null?void 0:n.visibleHighlightState]}):h.jsx("span",{children:"Latest frame"}),h.jsx("span",{children:n!=null&&n.isVisibleHighlight?"Previewing · click to pin":"Hover a step to preview it"})]})}),sC=Se(function(){var n,r,i;const{app:t}=x.useContext(Ee);return(n=t.previewStore)!=null&&n.activeScreencastUrl?h.jsxs("div",{className:"relative w-full overflow-hidden rounded-lg border border-white/[0.18] shadow-[0_24px_60px_rgba(0,0,0,0.5)]",style:{maxWidth:`${(r=t.previewStore)==null?void 0:r.visibleScreencast.page.viewport.width}px`},children:[h.jsx("img",{src:(i=t.previewStore)==null?void 0:i.activeScreencastUrl,alt:"Page at the selected step",className:"block w-full"}),t.settings.preview.darken&&h.jsx("div",{className:"pointer-events-none absolute inset-0 bg-black/50"})]}):h.jsx("div",{className:"mt-16 font-mono text-xs text-ink-muted",children:"No frame recorded for this step."})}),yp="https://puth.io/guide",pu=({label:e,labelClass:t,children:n,link:r})=>h.jsxs("section",{className:"overflow-hidden rounded-xl border border-white/[0.12] bg-gradient-to-b from-[#191919] to-[#141414] shadow-[inset_0_1px_0_rgba(255,255,255,0.04)]",children:[h.jsx("div",{className:"border-b border-dashed border-neutral-800 px-5 py-3 font-mono text-xs",children:h.jsx("span",{className:t,children:e})}),h.jsx("div",{className:"p-5",children:n}),r&&h.jsx("div",{className:"flex justify-end border-t border-dashed border-neutral-800 px-5 py-3 font-mono text-[12.5px]",children:h.jsxs("a",{href:r[1],target:"_blank",rel:"noreferrer",className:"text-accent-sky hover:text-blue-200",children:[r[0]," →"]})})]}),wp=()=>h.jsx("div",{className:"min-h-0 flex-1 overflow-y-auto",children:h.jsxs("div",{className:"mx-auto flex max-w-[1200px] flex-col gap-4 px-4 pb-8 pt-4",children:[h.jsxs("section",{className:"shell-hero relative flex min-h-[300px] flex-col justify-end overflow-hidden rounded-xl px-10 pb-9 pt-12",children:[h.jsx("div",{"aria-hidden":!0,className:"shell-hero-dots absolute inset-0"}),h.jsx("div",{"aria-hidden":!0,className:"shell-hero-grain absolute inset-0"}),h.jsx("div",{"aria-hidden":!0,className:"shell-hero-scrim absolute inset-0"}),h.jsxs("div",{className:"relative max-w-[620px]",children:[h.jsx("div",{className:"font-mono text-xs text-blue-100",children:"No instance connected"}),h.jsx("h1",{className:"mt-3 text-4xl font-medium leading-tight tracking-[-0.02em] text-white",children:"Connect to a server, or drop in a snapshot."}),h.jsxs("p",{className:"mt-3.5 text-[15px] leading-relaxed text-blue-50",children:["Tests show up here as they run. A ",h.jsx("code",{className:"rounded bg-white/15 px-1.5 py-px font-mono text-[13px] text-white",children:".puth"})," file from CI works without any connection."]})]})]}),h.jsxs("div",{className:"grid grid-cols-[repeat(auto-fit,minmax(300px,1fr))] gap-4",children:[h.jsx(pu,{label:"Connect",labelClass:"text-accent-blue",children:h.jsx(q0,{})}),h.jsxs("div",{className:"flex flex-col gap-4",children:[h.jsxs(pu,{label:"Start a server",labelClass:"text-accent-blue",link:["Getting started",`${yp}/getting-started`],children:[h.jsx("p",{className:"text-sm leading-relaxed text-ink-muted",children:"One container serves the browser API and this GUI."}),h.jsx("code",{className:"mt-3.5 block overflow-x-auto whitespace-nowrap rounded-lg border border-white/10 bg-shell-main px-3.5 py-3 font-mono text-[12.5px] text-ink-body",children:"docker run -it --rm -p 127.0.0.1:7345:7345 puthio/puth"})]}),h.jsx(pu,{label:"Replay from CI",labelClass:"text-indigo-300",link:["Snapshots in CI",`${yp}/ci-cd`],children:h.jsxs("p",{className:"text-sm leading-relaxed text-ink-muted",children:["Drag a ",h.jsx("code",{className:"rounded bg-white/[0.12] px-1.5 py-px font-mono text-[12.5px] text-ink",children:".puth"})," snapshot anywhere into this window to step through a recorded test."]})})]})]})]})}),lC=Se(function(){const{app:t}=x.useContext(Ee),n=t.view!=="local"&&t.history.length===0;return h.jsx("div",{className:"shell-dots flex flex-1 items-center justify-center p-8 text-center font-mono text-xs text-ink-muted",children:t.view==="agents"?n?"No agent sessions yet.":"Select an agent session to watch it.":n?"Connected. Tests show up here as they run.":"Select a test in the history to inspect it."})}),aC=Se(function(){const{app:t}=x.useContext(Ee),n=t.view!=="local"&&!t.isConnected;return h.jsxs("div",{className:"flex h-screen w-screen bg-shell-main text-ink",children:[h.jsx(CA,{}),t.empty?h.jsx("main",{className:"flex min-w-0 flex-1 flex-col",children:h.jsx(wp,{})}):h.jsxs("div",{className:"flex min-w-0 flex-1",children:[h.jsxs("aside",{"aria-label":"Test",className:"flex w-[440px] min-w-[320px] flex-shrink flex-col border-r border-shell-line bg-shell-side",children:[h.jsx(QA,{}),t.view==="agents"?h.jsx(rC,{}):h.jsx(qA,{})]}),h.jsx("main",{className:"flex min-w-0 flex-1 flex-col",children:t.previewStore?h.jsxs(h.Fragment,{children:[h.jsx(iC,{}),h.jsx("div",{className:"shell-dots flex min-h-0 flex-1 items-start justify-center overflow-auto p-4",children:h.jsx(sC,{})}),h.jsx(oC,{})]}):n?h.jsx(wp,{}):h.jsx(lC,{})})]})]})});var hy={exports:{}},uC="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",cC=uC,fC=cC;function py(){}function vy(){}vy.resetWarningCache=py;var dC=function(){function e(r,i,o,s,l,a){if(a!==fC){var u=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw u.name="Invariant Violation",u}}e.isRequired=e;function t(){return e}var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:vy,resetWarningCache:py};return n.PropTypes=n,n};hy.exports=dC();var hC=hy.exports;const ee=Fc(hC);var pC=new Map([["aac","audio/aac"],["abw","application/x-abiword"],["arc","application/x-freearc"],["avif","image/avif"],["avi","video/x-msvideo"],["azw","application/vnd.amazon.ebook"],["bin","application/octet-stream"],["bmp","image/bmp"],["bz","application/x-bzip"],["bz2","application/x-bzip2"],["cda","application/x-cdf"],["csh","application/x-csh"],["css","text/css"],["csv","text/csv"],["doc","application/msword"],["docx","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],["eot","application/vnd.ms-fontobject"],["epub","application/epub+zip"],["gz","application/gzip"],["gif","image/gif"],["htm","text/html"],["html","text/html"],["ico","image/vnd.microsoft.icon"],["ics","text/calendar"],["jar","application/java-archive"],["jpeg","image/jpeg"],["jpg","image/jpeg"],["js","text/javascript"],["json","application/json"],["jsonld","application/ld+json"],["mid","audio/midi"],["midi","audio/midi"],["mjs","text/javascript"],["mp3","audio/mpeg"],["mp4","video/mp4"],["mpeg","video/mpeg"],["mpkg","application/vnd.apple.installer+xml"],["odp","application/vnd.oasis.opendocument.presentation"],["ods","application/vnd.oasis.opendocument.spreadsheet"],["odt","application/vnd.oasis.opendocument.text"],["oga","audio/ogg"],["ogv","video/ogg"],["ogx","application/ogg"],["opus","audio/opus"],["otf","font/otf"],["png","image/png"],["pdf","application/pdf"],["php","application/x-httpd-php"],["ppt","application/vnd.ms-powerpoint"],["pptx","application/vnd.openxmlformats-officedocument.presentationml.presentation"],["rar","application/vnd.rar"],["rtf","application/rtf"],["sh","application/x-sh"],["svg","image/svg+xml"],["swf","application/x-shockwave-flash"],["tar","application/x-tar"],["tif","image/tiff"],["tiff","image/tiff"],["ts","video/mp2t"],["ttf","font/ttf"],["txt","text/plain"],["vsd","application/vnd.visio"],["wav","audio/wav"],["weba","audio/webm"],["webm","video/webm"],["webp","image/webp"],["woff","font/woff"],["woff2","font/woff2"],["xhtml","application/xhtml+xml"],["xls","application/vnd.ms-excel"],["xlsx","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"],["xml","application/xml"],["xul","application/vnd.mozilla.xul+xml"],["zip","application/zip"],["7z","application/x-7z-compressed"],["mkv","video/x-matroska"],["mov","video/quicktime"],["msg","application/vnd.ms-outlook"]]);function rs(e,t){var n=vC(e);if(typeof n.path!="string"){var r=e.webkitRelativePath;Object.defineProperty(n,"path",{value:typeof t=="string"?t:typeof r=="string"&&r.length>0?r:e.name,writable:!1,configurable:!1,enumerable:!0})}return n}function vC(e){var t=e.name,n=t&&t.lastIndexOf(".")!==-1;if(n&&!e.type){var r=t.split(".").pop().toLowerCase(),i=pC.get(r);i&&Object.defineProperty(e,"type",{value:i,writable:!1,configurable:!1,enumerable:!0})}return e}var gC=[".DS_Store","Thumbs.db"];function mC(e){return Pi(this,void 0,void 0,function(){return Ni(this,function(t){return zl(e)&&yC(e)?[2,bC(e.dataTransfer,e.type)]:wC(e)?[2,xC(e)]:Array.isArray(e)&&e.every(function(n){return"getFile"in n&&typeof n.getFile=="function"})?[2,_C(e)]:[2,[]]})})}function yC(e){return zl(e.dataTransfer)}function wC(e){return zl(e)&&zl(e.target)}function zl(e){return typeof e=="object"&&e!==null}function xC(e){return Tc(e.target.files).map(function(t){return rs(t)})}function _C(e){return Pi(this,void 0,void 0,function(){var t;return Ni(this,function(n){switch(n.label){case 0:return[4,Promise.all(e.map(function(r){return r.getFile()}))];case 1:return t=n.sent(),[2,t.map(function(r){return rs(r)})]}})})}function bC(e,t){return Pi(this,void 0,void 0,function(){var n,r;return Ni(this,function(i){switch(i.label){case 0:return e===null?[2,[]]:e.items?(n=Tc(e.items).filter(function(o){return o.kind==="file"}),t!=="drop"?[2,n]:[4,Promise.all(n.map(SC))]):[3,2];case 1:return r=i.sent(),[2,xp(gy(r))];case 2:return[2,xp(Tc(e.files).map(function(o){return rs(o)}))]}})})}function xp(e){return e.filter(function(t){return gC.indexOf(t.name)===-1})}function Tc(e){if(e===null)return[];for(var t=[],n=0;n<e.length;n++){var r=e[n];t.push(r)}return t}function SC(e){if(typeof e.webkitGetAsEntry!="function")return _p(e);var t=e.webkitGetAsEntry();return t&&t.isDirectory?my(t):_p(e)}function gy(e){return e.reduce(function(t,n){return xE(t,Array.isArray(n)?gy(n):[n])},[])}function _p(e){var t=e.getAsFile();if(!t)return Promise.reject(e+" is not a File");var n=rs(t);return Promise.resolve(n)}function EC(e){return Pi(this,void 0,void 0,function(){return Ni(this,function(t){return[2,e.isDirectory?my(e):AC(e)]})})}function my(e){var t=e.createReader();return new Promise(function(n,r){var i=[];function o(){var s=this;t.readEntries(function(l){return Pi(s,void 0,void 0,function(){var a,u,c;return Ni(this,function(f){switch(f.label){case 0:if(l.length)return[3,5];f.label=1;case 1:return f.trys.push([1,3,,4]),[4,Promise.all(i)];case 2:return a=f.sent(),n(a),[3,4];case 3:return u=f.sent(),r(u),[3,4];case 4:return[3,6];case 5:c=Promise.all(l.map(EC)),i.push(c),o(),f.label=6;case 6:return[2]}})})},function(l){r(l)})}o()})}function AC(e){return Pi(this,void 0,void 0,function(){return Ni(this,function(t){return[2,new Promise(function(n,r){e.file(function(i){var o=rs(i,e.fullPath);n(o)},function(i){r(i)})})]})})}var CC=function(e,t){if(e&&t){var n=Array.isArray(t)?t:t.split(",");if(n.length===0)return!0;var r=e.name||"",i=(e.type||"").toLowerCase(),o=i.replace(/\/.*$/,"");return n.some(function(s){var l=s.trim().toLowerCase();return l.charAt(0)==="."?r.toLowerCase().endsWith(l):l.endsWith("/*")?o===l.replace(/\/.*$/,""):i===l})}return!0};function bp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Sp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?bp(Object(n),!0).forEach(function(r){yy(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bp(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function yy(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ep(e,t){return NC(e)||PC(e,t)||OC(e,t)||kC()}function kC(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
89
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function OC(e,t){if(e){if(typeof e=="string")return Ap(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Ap(e,t)}}function Ap(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function PC(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r=[],i=!0,o=!1,s,l;try{for(n=n.call(e);!(i=(s=n.next()).done)&&(r.push(s.value),!(t&&r.length===t));i=!0);}catch(a){o=!0,l=a}finally{try{!i&&n.return!=null&&n.return()}finally{if(o)throw l}}return r}}function NC(e){if(Array.isArray(e))return e}var jC="file-invalid-type",TC="file-too-large",RC="file-too-small",DC="too-many-files",MC=function(t){t=Array.isArray(t)&&t.length===1?t[0]:t;var n=Array.isArray(t)?"one of ".concat(t.join(", ")):t;return{code:jC,message:"File type must be ".concat(n)}},Cp=function(t){return{code:TC,message:"File is larger than ".concat(t," ").concat(t===1?"byte":"bytes")}},kp=function(t){return{code:RC,message:"File is smaller than ".concat(t," ").concat(t===1?"byte":"bytes")}},LC={code:DC,message:"Too many files"};function wy(e,t){var n=e.type==="application/x-moz-file"||CC(e,t);return[n,n?null:MC(t)]}function xy(e,t,n){if(Gi(e.size))if(Gi(t)&&Gi(n)){if(e.size>n)return[!1,Cp(n)];if(e.size<t)return[!1,kp(t)]}else{if(Gi(t)&&e.size<t)return[!1,kp(t)];if(Gi(n)&&e.size>n)return[!1,Cp(n)]}return[!0,null]}function Gi(e){return e!=null}function IC(e){var t=e.files,n=e.accept,r=e.minSize,i=e.maxSize,o=e.multiple,s=e.maxFiles;return!o&&t.length>1||o&&s>=1&&t.length>s?!1:t.every(function(l){var a=wy(l,n),u=Ep(a,1),c=u[0],f=xy(l,r,i),d=Ep(f,1),p=d[0];return c&&p})}function Ul(e){return typeof e.isPropagationStopped=="function"?e.isPropagationStopped():typeof e.cancelBubble<"u"?e.cancelBubble:!1}function Ts(e){return e.dataTransfer?Array.prototype.some.call(e.dataTransfer.types,function(t){return t==="Files"||t==="application/x-moz-file"}):!!e.target&&!!e.target.files}function Op(e){e.preventDefault()}function FC(e){return e.indexOf("MSIE")!==-1||e.indexOf("Trident/")!==-1}function zC(e){return e.indexOf("Edge/")!==-1}function UC(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.navigator.userAgent;return FC(e)||zC(e)}function Rt(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(r){for(var i=arguments.length,o=new Array(i>1?i-1:0),s=1;s<i;s++)o[s-1]=arguments[s];return t.some(function(l){return!Ul(r)&&l&&l.apply(void 0,[r].concat(o)),Ul(r)})}}function Pp(){return"showOpenFilePicker"in window}function BC(e){return e=typeof e=="string"?e.split(","):e,[{description:"everything",accept:Array.isArray(e)?e.filter(function(t){return t==="audio/*"||t==="video/*"||t==="image/*"||t==="text/*"||/\w+\/[-+.\w]+/g.test(t)}).reduce(function(t,n){return Sp(Sp({},t),{},yy({},n,[]))},{}):{}}]}var $C=["children"],VC=["open"],WC=["refKey","role","onKeyDown","onFocus","onBlur","onClick","onDragEnter","onDragOver","onDragLeave","onDrop"],HC=["refKey","onChange","onClick"];function KC(e){return YC(e)||QC(e)||_y(e)||GC()}function GC(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
90
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function QC(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function YC(e){if(Array.isArray(e))return Rc(e)}function vu(e,t){return JC(e)||ZC(e,t)||_y(e,t)||XC()}function XC(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
91
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function _y(e,t){if(e){if(typeof e=="string")return Rc(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Rc(e,t)}}function Rc(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function ZC(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r=[],i=!0,o=!1,s,l;try{for(n=n.call(e);!(i=(s=n.next()).done)&&(r.push(s.value),!(t&&r.length===t));i=!0);}catch(a){o=!0,l=a}finally{try{!i&&n.return!=null&&n.return()}finally{if(o)throw l}}return r}}function JC(e){if(Array.isArray(e))return e}function Np(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function fe(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Np(Object(n),!0).forEach(function(r){Dc(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Np(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Dc(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Bl(e,t){if(e==null)return{};var n=qC(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function qC(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o<r.length;o++)i=r[o],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}var id=x.forwardRef(function(e,t){var n=e.children,r=Bl(e,$C),i=Sy(r),o=i.open,s=Bl(i,VC);return x.useImperativeHandle(t,function(){return{open:o}},[o]),Cn.createElement(x.Fragment,null,n(fe(fe({},s),{},{open:o})))});id.displayName="Dropzone";var by={disabled:!1,getFilesFromEvent:mC,maxSize:1/0,minSize:0,multiple:!0,maxFiles:0,preventDropOnDocument:!0,noClick:!1,noKeyboard:!1,noDrag:!1,noDragEventsBubbling:!1,validator:null,useFsAccessApi:!1};id.defaultProps=by;id.propTypes={children:ee.func,accept:ee.oneOfType([ee.string,ee.arrayOf(ee.string)]),multiple:ee.bool,preventDropOnDocument:ee.bool,noClick:ee.bool,noKeyboard:ee.bool,noDrag:ee.bool,noDragEventsBubbling:ee.bool,minSize:ee.number,maxSize:ee.number,maxFiles:ee.number,disabled:ee.bool,getFilesFromEvent:ee.func,onFileDialogCancel:ee.func,onFileDialogOpen:ee.func,useFsAccessApi:ee.bool,onDragEnter:ee.func,onDragLeave:ee.func,onDragOver:ee.func,onDrop:ee.func,onDropAccepted:ee.func,onDropRejected:ee.func,validator:ee.func};var Mc={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,draggedFiles:[],acceptedFiles:[],fileRejections:[]};function Sy(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=fe(fe({},by),e),n=t.accept,r=t.disabled,i=t.getFilesFromEvent,o=t.maxSize,s=t.minSize,l=t.multiple,a=t.maxFiles,u=t.onDragEnter,c=t.onDragLeave,f=t.onDragOver,d=t.onDrop,p=t.onDropAccepted,y=t.onDropRejected,m=t.onFileDialogCancel,b=t.onFileDialogOpen,v=t.useFsAccessApi,g=t.preventDropOnDocument,w=t.noClick,_=t.noKeyboard,S=t.noDrag,E=t.noDragEventsBubbling,A=t.validator,C=x.useMemo(function(){return typeof b=="function"?b:jp},[b]),j=x.useMemo(function(){return typeof m=="function"?m:jp},[m]),P=x.useRef(null),D=x.useRef(null),k=x.useReducer(ek,Mc),z=vu(k,2),B=z[0],K=z[1],Z=B.isFocused,J=B.isFileDialogActive,O=B.draggedFiles,R=function(){J&&setTimeout(function(){if(D.current){var W=D.current.files;W.length||(K({type:"closeDialog"}),j())}},300)};x.useEffect(function(){return v&&Pp()?function(){}:(window.addEventListener("focus",R,!1),function(){window.removeEventListener("focus",R,!1)})},[D,J,j,v]);var F=x.useRef([]),H=function(W){P.current&&P.current.contains(W.target)||(W.preventDefault(),F.current=[])};x.useEffect(function(){return g&&(document.addEventListener("dragover",Op,!1),document.addEventListener("drop",H,!1)),function(){g&&(document.removeEventListener("dragover",Op),document.removeEventListener("drop",H))}},[P,g]);var ce=x.useCallback(function(L){L.preventDefault(),L.persist(),Nr(L),F.current=[].concat(KC(F.current),[L.target]),Ts(L)&&Promise.resolve(i(L)).then(function(W){Ul(L)&&!E||(K({draggedFiles:W,isDragActive:!0,type:"setDraggedFiles"}),u&&u(L))})},[i,u,E]),Yt=x.useCallback(function(L){L.preventDefault(),L.persist(),Nr(L);var W=Ts(L);if(W&&L.dataTransfer)try{L.dataTransfer.dropEffect="copy"}catch{}return W&&f&&f(L),!1},[f,E]),rt=x.useCallback(function(L){L.preventDefault(),L.persist(),Nr(L);var W=F.current.filter(function(Ue){return P.current&&P.current.contains(Ue)}),Ce=W.indexOf(L.target);Ce!==-1&&W.splice(Ce,1),F.current=W,!(W.length>0)&&(K({isDragActive:!1,type:"setDraggedFiles",draggedFiles:[]}),Ts(L)&&c&&c(L))},[P,c,E]),jt=x.useCallback(function(L,W){var Ce=[],Ue=[];L.forEach(function(pt){var Li=wy(pt,n),jr=vu(Li,2),xa=jr[0],_a=jr[1],ba=xy(pt,s,o),is=vu(ba,2),Sa=is[0],Ea=is[1],Aa=A?A(pt):null;if(xa&&Sa&&!Aa)Ce.push(pt);else{var Ca=[_a,Ea];Aa&&(Ca=Ca.concat(Aa)),Ue.push({file:pt,errors:Ca.filter(function(Ny){return Ny})})}}),(!l&&Ce.length>1||l&&a>=1&&Ce.length>a)&&(Ce.forEach(function(pt){Ue.push({file:pt,errors:[LC]})}),Ce.splice(0)),K({acceptedFiles:Ce,fileRejections:Ue,type:"setFiles"}),d&&d(Ce,Ue,W),Ue.length>0&&y&&y(Ue,W),Ce.length>0&&p&&p(Ce,W)},[K,l,n,s,o,a,d,p,y,A]),Fe=x.useCallback(function(L){L.preventDefault(),L.persist(),Nr(L),F.current=[],Ts(L)&&Promise.resolve(i(L)).then(function(W){Ul(L)&&!E||jt(W,L)}),K({type:"reset"})},[i,jt,E]),ze=x.useCallback(function(){if(v&&Pp()){K({type:"openDialog"}),C();var L={multiple:l,types:BC(n)};window.showOpenFilePicker(L).then(function(W){return i(W)}).then(function(W){return jt(W,null)}).catch(function(W){return j(W)}).finally(function(){return K({type:"closeDialog"})});return}D.current&&(K({type:"openDialog"}),C(),D.current.value=null,D.current.click())},[K,C,j,v,jt,n,l]),Ti=x.useCallback(function(L){!P.current||!P.current.isEqualNode(L.target)||(L.keyCode===32||L.keyCode===13)&&(L.preventDefault(),ze())},[P,D,ze]),Ri=x.useCallback(function(){K({type:"focus"})},[]),Di=x.useCallback(function(){K({type:"blur"})},[]),Mi=x.useCallback(function(){w||(UC()?setTimeout(ze,0):ze())},[D,w,ze]),Xt=function(W){return r?null:W},Zt=function(W){return _?null:Xt(W)},rr=function(W){return S?null:Xt(W)},Nr=function(W){E&&W.stopPropagation()},ma=x.useMemo(function(){return function(){var L=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},W=L.refKey,Ce=W===void 0?"ref":W,Ue=L.role,pt=L.onKeyDown,Li=L.onFocus,jr=L.onBlur,xa=L.onClick,_a=L.onDragEnter,ba=L.onDragOver,is=L.onDragLeave,Sa=L.onDrop,Ea=Bl(L,WC);return fe(fe(Dc({onKeyDown:Zt(Rt(pt,Ti)),onFocus:Zt(Rt(Li,Ri)),onBlur:Zt(Rt(jr,Di)),onClick:Xt(Rt(xa,Mi)),onDragEnter:rr(Rt(_a,ce)),onDragOver:rr(Rt(ba,Yt)),onDragLeave:rr(Rt(is,rt)),onDrop:rr(Rt(Sa,Fe)),role:typeof Ue=="string"&&Ue!==""?Ue:"button"},Ce,P),!r&&!_?{tabIndex:0}:{}),Ea)}},[P,Ti,Ri,Di,Mi,ce,Yt,rt,Fe,_,S,r]),ya=x.useCallback(function(L){L.stopPropagation()},[]),wa=x.useMemo(function(){return function(){var L=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},W=L.refKey,Ce=W===void 0?"ref":W,Ue=L.onChange,pt=L.onClick,Li=Bl(L,HC),jr=Dc({accept:n,multiple:l,type:"file",style:{display:"none"},onChange:Xt(Rt(Ue,Fe)),onClick:Xt(Rt(pt,ya)),autoComplete:"off",tabIndex:-1},Ce,D);return fe(fe({},jr),Li)}},[D,n,l,Fe,r]),ir=O.length,ad=ir>0&&IC({files:O,accept:n,minSize:s,maxSize:o,multiple:l,maxFiles:a}),Py=ir>0&&!ad;return fe(fe({},B),{},{isDragAccept:ad,isDragReject:Py,isFocused:Z&&!r,getRootProps:ma,getInputProps:wa,rootRef:P,inputRef:D,open:Xt(ze)})}function ek(e,t){switch(t.type){case"focus":return fe(fe({},e),{},{isFocused:!0});case"blur":return fe(fe({},e),{},{isFocused:!1});case"openDialog":return fe(fe({},Mc),{},{isFileDialogActive:!0});case"closeDialog":return fe(fe({},e),{},{isFileDialogActive:!1});case"setDraggedFiles":var n=t.isDragActive,r=t.draggedFiles;return fe(fe({},e),{},{draggedFiles:r,isDragActive:n});case"setFiles":return fe(fe({},e),{},{acceptedFiles:t.acceptedFiles,fileRejections:t.fileRejections});case"reset":return fe({},Mc);default:return e}}function jp(){}const Io=U({active:0});var lr=4294967295;function tk(e,t,n){var r=n/4294967296,i=n;e.setUint32(t,r),e.setUint32(t+4,i)}function Ey(e,t,n){var r=Math.floor(n/4294967296),i=n;e.setUint32(t,r),e.setUint32(t+4,i)}function Ay(e,t){var n=e.getInt32(t),r=e.getUint32(t+4);return n*4294967296+r}function nk(e,t){var n=e.getUint32(t),r=e.getUint32(t+4);return n*4294967296+r}var od={},gu,mu,yu,ga=(typeof process>"u"||((gu=process==null?void 0:od)===null||gu===void 0?void 0:gu.TEXT_ENCODING)!=="never")&&typeof TextEncoder<"u"&&typeof TextDecoder<"u";function Tp(e){for(var t=e.length,n=0,r=0;r<t;){var i=e.charCodeAt(r++);if(i&4294967168)if(!(i&4294965248))n+=2;else{if(i>=55296&&i<=56319&&r<t){var o=e.charCodeAt(r);(o&64512)===56320&&(++r,i=((i&1023)<<10)+(o&1023)+65536)}i&4294901760?n+=4:n+=3}else{n++;continue}}return n}function rk(e,t,n){for(var r=e.length,i=n,o=0;o<r;){var s=e.charCodeAt(o++);if(s&4294967168)if(!(s&4294965248))t[i++]=s>>6&31|192;else{if(s>=55296&&s<=56319&&o<r){var l=e.charCodeAt(o);(l&64512)===56320&&(++o,s=((s&1023)<<10)+(l&1023)+65536)}s&4294901760?(t[i++]=s>>18&7|240,t[i++]=s>>12&63|128,t[i++]=s>>6&63|128):(t[i++]=s>>12&15|224,t[i++]=s>>6&63|128)}else{t[i++]=s;continue}t[i++]=s&63|128}}var po=ga?new TextEncoder:void 0,ik=ga?typeof process<"u"&&((mu=process==null?void 0:od)===null||mu===void 0?void 0:mu.TEXT_ENCODING)!=="force"?200:0:lr;function ok(e,t,n){t.set(po.encode(e),n)}function sk(e,t,n){po.encodeInto(e,t.subarray(n))}var lk=po!=null&&po.encodeInto?sk:ok,ak=4096;function Cy(e,t,n){for(var r=t,i=r+n,o=[],s="";r<i;){var l=e[r++];if(!(l&128))o.push(l);else if((l&224)===192){var a=e[r++]&63;o.push((l&31)<<6|a)}else if((l&240)===224){var a=e[r++]&63,u=e[r++]&63;o.push((l&31)<<12|a<<6|u)}else if((l&248)===240){var a=e[r++]&63,u=e[r++]&63,c=e[r++]&63,f=(l&7)<<18|a<<12|u<<6|c;f>65535&&(f-=65536,o.push(f>>>10&1023|55296),f=56320|f&1023),o.push(f)}else o.push(l);o.length>=ak&&(s+=String.fromCharCode.apply(String,o),o.length=0)}return o.length>0&&(s+=String.fromCharCode.apply(String,o)),s}var uk=ga?new TextDecoder:null,ck=ga?typeof process<"u"&&((yu=process==null?void 0:od)===null||yu===void 0?void 0:yu.TEXT_DECODER)!=="force"?200:0:lr;function fk(e,t,n){var r=e.subarray(t,t+n);return uk.decode(r)}var Rs=function(){function e(t,n){this.type=t,this.data=n}return e}(),dk=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(t,n)};return function(t,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");e(t,n);function r(){this.constructor=t}t.prototype=n===null?Object.create(n):(r.prototype=n.prototype,new r)}}(),Dt=function(e){dk(t,e);function t(n){var r=e.call(this,n)||this,i=Object.create(t.prototype);return Object.setPrototypeOf(r,i),Object.defineProperty(r,"name",{configurable:!0,enumerable:!1,value:t.name}),r}return t}(Error),hk=-1,pk=4294967296-1,vk=17179869184-1;function gk(e){var t=e.sec,n=e.nsec;if(t>=0&&n>=0&&t<=vk)if(n===0&&t<=pk){var r=new Uint8Array(4),i=new DataView(r.buffer);return i.setUint32(0,t),r}else{var o=t/4294967296,s=t&4294967295,r=new Uint8Array(8),i=new DataView(r.buffer);return i.setUint32(0,n<<2|o&3),i.setUint32(4,s),r}else{var r=new Uint8Array(12),i=new DataView(r.buffer);return i.setUint32(0,n),Ey(i,4,t),r}}function mk(e){var t=e.getTime(),n=Math.floor(t/1e3),r=(t-n*1e3)*1e6,i=Math.floor(r/1e9);return{sec:n+i,nsec:r-i*1e9}}function yk(e){if(e instanceof Date){var t=mk(e);return gk(t)}else return null}function wk(e){var t=new DataView(e.buffer,e.byteOffset,e.byteLength);switch(e.byteLength){case 4:{var n=t.getUint32(0),r=0;return{sec:n,nsec:r}}case 8:{var i=t.getUint32(0),o=t.getUint32(4),n=(i&3)*4294967296+o,r=i>>>2;return{sec:n,nsec:r}}case 12:{var n=Ay(t,4),r=t.getUint32(0);return{sec:n,nsec:r}}default:throw new Dt("Unrecognized data size for timestamp (expected 4, 8, or 12): ".concat(e.length))}}function xk(e){var t=wk(e);return new Date(t.sec*1e3+t.nsec/1e6)}var _k={type:hk,encode:yk,decode:xk},sd=function(){function e(){this.builtInEncoders=[],this.builtInDecoders=[],this.encoders=[],this.decoders=[],this.register(_k)}return e.prototype.register=function(t){var n=t.type,r=t.encode,i=t.decode;if(n>=0)this.encoders[n]=r,this.decoders[n]=i;else{var o=1+n;this.builtInEncoders[o]=r,this.builtInDecoders[o]=i}},e.prototype.tryToEncode=function(t,n){for(var r=0;r<this.builtInEncoders.length;r++){var i=this.builtInEncoders[r];if(i!=null){var o=i(t,n);if(o!=null){var s=-1-r;return new Rs(s,o)}}}for(var r=0;r<this.encoders.length;r++){var i=this.encoders[r];if(i!=null){var o=i(t,n);if(o!=null){var s=r;return new Rs(s,o)}}}return t instanceof Rs?t:null},e.prototype.decode=function(t,n,r){var i=n<0?this.builtInDecoders[-1-n]:this.decoders[n];return i?i(t,n,r):new Rs(n,t)},e.defaultCodec=new e,e}();function $l(e){return e instanceof Uint8Array?e:ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength):e instanceof ArrayBuffer?new Uint8Array(e):Uint8Array.from(e)}function bk(e){if(e instanceof ArrayBuffer)return new DataView(e);var t=$l(e);return new DataView(t.buffer,t.byteOffset,t.byteLength)}var Sk=100,Ek=2048,Ak=function(){function e(t,n,r,i,o,s,l,a){t===void 0&&(t=sd.defaultCodec),n===void 0&&(n=void 0),r===void 0&&(r=Sk),i===void 0&&(i=Ek),o===void 0&&(o=!1),s===void 0&&(s=!1),l===void 0&&(l=!1),a===void 0&&(a=!1),this.extensionCodec=t,this.context=n,this.maxDepth=r,this.initialBufferSize=i,this.sortKeys=o,this.forceFloat32=s,this.ignoreUndefined=l,this.forceIntegerToFloat=a,this.pos=0,this.view=new DataView(new ArrayBuffer(this.initialBufferSize)),this.bytes=new Uint8Array(this.view.buffer)}return e.prototype.reinitializeState=function(){this.pos=0},e.prototype.encodeSharedRef=function(t){return this.reinitializeState(),this.doEncode(t,1),this.bytes.subarray(0,this.pos)},e.prototype.encode=function(t){return this.reinitializeState(),this.doEncode(t,1),this.bytes.slice(0,this.pos)},e.prototype.doEncode=function(t,n){if(n>this.maxDepth)throw new Error("Too deep objects in depth ".concat(n));t==null?this.encodeNil():typeof t=="boolean"?this.encodeBoolean(t):typeof t=="number"?this.encodeNumber(t):typeof t=="string"?this.encodeString(t):this.encodeObject(t,n)},e.prototype.ensureBufferSizeToWrite=function(t){var n=this.pos+t;this.view.byteLength<n&&this.resizeBuffer(n*2)},e.prototype.resizeBuffer=function(t){var n=new ArrayBuffer(t),r=new Uint8Array(n),i=new DataView(n);r.set(this.bytes),this.view=i,this.bytes=r},e.prototype.encodeNil=function(){this.writeU8(192)},e.prototype.encodeBoolean=function(t){t===!1?this.writeU8(194):this.writeU8(195)},e.prototype.encodeNumber=function(t){Number.isSafeInteger(t)&&!this.forceIntegerToFloat?t>=0?t<128?this.writeU8(t):t<256?(this.writeU8(204),this.writeU8(t)):t<65536?(this.writeU8(205),this.writeU16(t)):t<4294967296?(this.writeU8(206),this.writeU32(t)):(this.writeU8(207),this.writeU64(t)):t>=-32?this.writeU8(224|t+32):t>=-128?(this.writeU8(208),this.writeI8(t)):t>=-32768?(this.writeU8(209),this.writeI16(t)):t>=-2147483648?(this.writeU8(210),this.writeI32(t)):(this.writeU8(211),this.writeI64(t)):this.forceFloat32?(this.writeU8(202),this.writeF32(t)):(this.writeU8(203),this.writeF64(t))},e.prototype.writeStringHeader=function(t){if(t<32)this.writeU8(160+t);else if(t<256)this.writeU8(217),this.writeU8(t);else if(t<65536)this.writeU8(218),this.writeU16(t);else if(t<4294967296)this.writeU8(219),this.writeU32(t);else throw new Error("Too long string: ".concat(t," bytes in UTF-8"))},e.prototype.encodeString=function(t){var n=5,r=t.length;if(r>ik){var i=Tp(t);this.ensureBufferSizeToWrite(n+i),this.writeStringHeader(i),lk(t,this.bytes,this.pos),this.pos+=i}else{var i=Tp(t);this.ensureBufferSizeToWrite(n+i),this.writeStringHeader(i),rk(t,this.bytes,this.pos),this.pos+=i}},e.prototype.encodeObject=function(t,n){var r=this.extensionCodec.tryToEncode(t,this.context);if(r!=null)this.encodeExtension(r);else if(Array.isArray(t))this.encodeArray(t,n);else if(ArrayBuffer.isView(t))this.encodeBinary(t);else if(typeof t=="object")this.encodeMap(t,n);else throw new Error("Unrecognized object: ".concat(Object.prototype.toString.apply(t)))},e.prototype.encodeBinary=function(t){var n=t.byteLength;if(n<256)this.writeU8(196),this.writeU8(n);else if(n<65536)this.writeU8(197),this.writeU16(n);else if(n<4294967296)this.writeU8(198),this.writeU32(n);else throw new Error("Too large binary: ".concat(n));var r=$l(t);this.writeU8a(r)},e.prototype.encodeArray=function(t,n){var r=t.length;if(r<16)this.writeU8(144+r);else if(r<65536)this.writeU8(220),this.writeU16(r);else if(r<4294967296)this.writeU8(221),this.writeU32(r);else throw new Error("Too large array: ".concat(r));for(var i=0,o=t;i<o.length;i++){var s=o[i];this.doEncode(s,n+1)}},e.prototype.countWithoutUndefined=function(t,n){for(var r=0,i=0,o=n;i<o.length;i++){var s=o[i];t[s]!==void 0&&r++}return r},e.prototype.encodeMap=function(t,n){var r=Object.keys(t);this.sortKeys&&r.sort();var i=this.ignoreUndefined?this.countWithoutUndefined(t,r):r.length;if(i<16)this.writeU8(128+i);else if(i<65536)this.writeU8(222),this.writeU16(i);else if(i<4294967296)this.writeU8(223),this.writeU32(i);else throw new Error("Too large map object: ".concat(i));for(var o=0,s=r;o<s.length;o++){var l=s[o],a=t[l];this.ignoreUndefined&&a===void 0||(this.encodeString(l),this.doEncode(a,n+1))}},e.prototype.encodeExtension=function(t){var n=t.data.length;if(n===1)this.writeU8(212);else if(n===2)this.writeU8(213);else if(n===4)this.writeU8(214);else if(n===8)this.writeU8(215);else if(n===16)this.writeU8(216);else if(n<256)this.writeU8(199),this.writeU8(n);else if(n<65536)this.writeU8(200),this.writeU16(n);else if(n<4294967296)this.writeU8(201),this.writeU32(n);else throw new Error("Too large extension object: ".concat(n));this.writeI8(t.type),this.writeU8a(t.data)},e.prototype.writeU8=function(t){this.ensureBufferSizeToWrite(1),this.view.setUint8(this.pos,t),this.pos++},e.prototype.writeU8a=function(t){var n=t.length;this.ensureBufferSizeToWrite(n),this.bytes.set(t,this.pos),this.pos+=n},e.prototype.writeI8=function(t){this.ensureBufferSizeToWrite(1),this.view.setInt8(this.pos,t),this.pos++},e.prototype.writeU16=function(t){this.ensureBufferSizeToWrite(2),this.view.setUint16(this.pos,t),this.pos+=2},e.prototype.writeI16=function(t){this.ensureBufferSizeToWrite(2),this.view.setInt16(this.pos,t),this.pos+=2},e.prototype.writeU32=function(t){this.ensureBufferSizeToWrite(4),this.view.setUint32(this.pos,t),this.pos+=4},e.prototype.writeI32=function(t){this.ensureBufferSizeToWrite(4),this.view.setInt32(this.pos,t),this.pos+=4},e.prototype.writeF32=function(t){this.ensureBufferSizeToWrite(4),this.view.setFloat32(this.pos,t),this.pos+=4},e.prototype.writeF64=function(t){this.ensureBufferSizeToWrite(8),this.view.setFloat64(this.pos,t),this.pos+=8},e.prototype.writeU64=function(t){this.ensureBufferSizeToWrite(8),tk(this.view,this.pos,t),this.pos+=8},e.prototype.writeI64=function(t){this.ensureBufferSizeToWrite(8),Ey(this.view,this.pos,t),this.pos+=8},e}(),Ck={};function ky(e,t){t===void 0&&(t=Ck);var n=new Ak(t.extensionCodec,t.context,t.maxDepth,t.initialBufferSize,t.sortKeys,t.forceFloat32,t.ignoreUndefined,t.forceIntegerToFloat);return n.encodeSharedRef(e)}function wu(e){return"".concat(e<0?"-":"","0x").concat(Math.abs(e).toString(16).padStart(2,"0"))}var kk=16,Ok=16,Pk=function(){function e(t,n){t===void 0&&(t=kk),n===void 0&&(n=Ok),this.maxKeyLength=t,this.maxLengthPerKey=n,this.hit=0,this.miss=0,this.caches=[];for(var r=0;r<this.maxKeyLength;r++)this.caches.push([])}return e.prototype.canBeCached=function(t){return t>0&&t<=this.maxKeyLength},e.prototype.find=function(t,n,r){var i=this.caches[r-1];e:for(var o=0,s=i;o<s.length;o++){for(var l=s[o],a=l.bytes,u=0;u<r;u++)if(a[u]!==t[n+u])continue e;return l.str}return null},e.prototype.store=function(t,n){var r=this.caches[t.length-1],i={bytes:t,str:n};r.length>=this.maxLengthPerKey?r[Math.random()*r.length|0]=i:r.push(i)},e.prototype.decode=function(t,n,r){var i=this.find(t,n,r);if(i!=null)return this.hit++,i;this.miss++;var o=Cy(t,n,r),s=Uint8Array.prototype.slice.call(t,n,n+r);return this.store(s,o),o},e}(),Nk=function(e,t,n,r){function i(o){return o instanceof n?o:new n(function(s){s(o)})}return new(n||(n=Promise))(function(o,s){function l(c){try{u(r.next(c))}catch(f){s(f)}}function a(c){try{u(r.throw(c))}catch(f){s(f)}}function u(c){c.done?o(c.value):i(c.value).then(l,a)}u((r=r.apply(e,t||[])).next())})},xu=function(e,t){var n={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},r,i,o,s;return s={next:l(0),throw:l(1),return:l(2)},typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function l(u){return function(c){return a([u,c])}}function a(u){if(r)throw new TypeError("Generator is already executing.");for(;n;)try{if(r=1,i&&(o=u[0]&2?i.return:u[0]?i.throw||((o=i.return)&&o.call(i),0):i.next)&&!(o=o.call(i,u[1])).done)return o;switch(i=0,o&&(u=[u[0]&2,o.value]),u[0]){case 0:case 1:o=u;break;case 4:return n.label++,{value:u[1],done:!1};case 5:n.label++,i=u[1],u=[0];continue;case 7:u=n.ops.pop(),n.trys.pop();continue;default:if(o=n.trys,!(o=o.length>0&&o[o.length-1])&&(u[0]===6||u[0]===2)){n=0;continue}if(u[0]===3&&(!o||u[1]>o[0]&&u[1]<o[3])){n.label=u[1];break}if(u[0]===6&&n.label<o[1]){n.label=o[1],o=u;break}if(o&&n.label<o[2]){n.label=o[2],n.ops.push(u);break}o[2]&&n.ops.pop(),n.trys.pop();continue}u=t.call(e,n)}catch(c){u=[6,c],i=0}finally{r=o=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Rp=function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],n;return t?t.call(e):(e=typeof __values=="function"?__values(e):e[Symbol.iterator](),n={},r("next"),r("throw"),r("return"),n[Symbol.asyncIterator]=function(){return this},n);function r(o){n[o]=e[o]&&function(s){return new Promise(function(l,a){s=e[o](s),i(l,a,s.done,s.value)})}}function i(o,s,l,a){Promise.resolve(a).then(function(u){o({value:u,done:l})},s)}},li=function(e){return this instanceof li?(this.v=e,this):new li(e)},jk=function(e,t,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r=n.apply(e,t||[]),i,o=[];return i={},s("next"),s("throw"),s("return"),i[Symbol.asyncIterator]=function(){return this},i;function s(d){r[d]&&(i[d]=function(p){return new Promise(function(y,m){o.push([d,p,y,m])>1||l(d,p)})})}function l(d,p){try{a(r[d](p))}catch(y){f(o[0][3],y)}}function a(d){d.value instanceof li?Promise.resolve(d.value.v).then(u,c):f(o[0][2],d)}function u(d){l("next",d)}function c(d){l("throw",d)}function f(d,p){d(p),o.shift(),o.length&&l(o[0][0],o[0][1])}},Tk=function(e){var t=typeof e;return t==="string"||t==="number"},Qi=-1,ld=new DataView(new ArrayBuffer(0)),Rk=new Uint8Array(ld.buffer),Lc=function(){try{ld.getInt8(0)}catch(e){return e.constructor}throw new Error("never reached")}(),Dp=new Lc("Insufficient data"),Dk=new Pk,Mk=function(){function e(t,n,r,i,o,s,l,a){t===void 0&&(t=sd.defaultCodec),n===void 0&&(n=void 0),r===void 0&&(r=lr),i===void 0&&(i=lr),o===void 0&&(o=lr),s===void 0&&(s=lr),l===void 0&&(l=lr),a===void 0&&(a=Dk),this.extensionCodec=t,this.context=n,this.maxStrLength=r,this.maxBinLength=i,this.maxArrayLength=o,this.maxMapLength=s,this.maxExtLength=l,this.keyDecoder=a,this.totalPos=0,this.pos=0,this.view=ld,this.bytes=Rk,this.headByte=Qi,this.stack=[]}return e.prototype.reinitializeState=function(){this.totalPos=0,this.headByte=Qi,this.stack.length=0},e.prototype.setBuffer=function(t){this.bytes=$l(t),this.view=bk(this.bytes),this.pos=0},e.prototype.appendBuffer=function(t){if(this.headByte===Qi&&!this.hasRemaining(1))this.setBuffer(t);else{var n=this.bytes.subarray(this.pos),r=$l(t),i=new Uint8Array(n.length+r.length);i.set(n),i.set(r,n.length),this.setBuffer(i)}},e.prototype.hasRemaining=function(t){return this.view.byteLength-this.pos>=t},e.prototype.createExtraByteError=function(t){var n=this,r=n.view,i=n.pos;return new RangeError("Extra ".concat(r.byteLength-i," of ").concat(r.byteLength," byte(s) found at buffer[").concat(t,"]"))},e.prototype.decode=function(t){this.reinitializeState(),this.setBuffer(t);var n=this.doDecodeSync();if(this.hasRemaining(1))throw this.createExtraByteError(this.pos);return n},e.prototype.decodeMulti=function(t){return xu(this,function(n){switch(n.label){case 0:this.reinitializeState(),this.setBuffer(t),n.label=1;case 1:return this.hasRemaining(1)?[4,this.doDecodeSync()]:[3,3];case 2:return n.sent(),[3,1];case 3:return[2]}})},e.prototype.decodeAsync=function(t){var n,r,i,o;return Nk(this,void 0,void 0,function(){var s,l,a,u,c,f,d,p;return xu(this,function(y){switch(y.label){case 0:s=!1,y.label=1;case 1:y.trys.push([1,6,7,12]),n=Rp(t),y.label=2;case 2:return[4,n.next()];case 3:if(r=y.sent(),!!r.done)return[3,5];if(a=r.value,s)throw this.createExtraByteError(this.totalPos);this.appendBuffer(a);try{l=this.doDecodeSync(),s=!0}catch(m){if(!(m instanceof Lc))throw m}this.totalPos+=this.pos,y.label=4;case 4:return[3,2];case 5:return[3,12];case 6:return u=y.sent(),i={error:u},[3,12];case 7:return y.trys.push([7,,10,11]),r&&!r.done&&(o=n.return)?[4,o.call(n)]:[3,9];case 8:y.sent(),y.label=9;case 9:return[3,11];case 10:if(i)throw i.error;return[7];case 11:return[7];case 12:if(s){if(this.hasRemaining(1))throw this.createExtraByteError(this.totalPos);return[2,l]}throw c=this,f=c.headByte,d=c.pos,p=c.totalPos,new RangeError("Insufficient data in parsing ".concat(wu(f)," at ").concat(p," (").concat(d," in the current buffer)"))}})})},e.prototype.decodeArrayStream=function(t){return this.decodeMultiAsync(t,!0)},e.prototype.decodeStream=function(t){return this.decodeMultiAsync(t,!1)},e.prototype.decodeMultiAsync=function(t,n){return jk(this,arguments,function(){var i,o,s,l,a,u,c,f,d;return xu(this,function(p){switch(p.label){case 0:i=n,o=-1,p.label=1;case 1:p.trys.push([1,13,14,19]),s=Rp(t),p.label=2;case 2:return[4,li(s.next())];case 3:if(l=p.sent(),!!l.done)return[3,12];if(a=l.value,n&&o===0)throw this.createExtraByteError(this.totalPos);this.appendBuffer(a),i&&(o=this.readArraySize(),i=!1,this.complete()),p.label=4;case 4:p.trys.push([4,9,,10]),p.label=5;case 5:return[4,li(this.doDecodeSync())];case 6:return[4,p.sent()];case 7:return p.sent(),--o===0?[3,8]:[3,5];case 8:return[3,10];case 9:if(u=p.sent(),!(u instanceof Lc))throw u;return[3,10];case 10:this.totalPos+=this.pos,p.label=11;case 11:return[3,2];case 12:return[3,19];case 13:return c=p.sent(),f={error:c},[3,19];case 14:return p.trys.push([14,,17,18]),l&&!l.done&&(d=s.return)?[4,li(d.call(s))]:[3,16];case 15:p.sent(),p.label=16;case 16:return[3,18];case 17:if(f)throw f.error;return[7];case 18:return[7];case 19:return[2]}})})},e.prototype.doDecodeSync=function(){e:for(;;){var t=this.readHeadByte(),n=void 0;if(t>=224)n=t-256;else if(t<192)if(t<128)n=t;else if(t<144){var r=t-128;if(r!==0){this.pushMapState(r),this.complete();continue e}else n={}}else if(t<160){var r=t-144;if(r!==0){this.pushArrayState(r),this.complete();continue e}else n=[]}else{var i=t-160;n=this.decodeUtf8String(i,0)}else if(t===192)n=null;else if(t===194)n=!1;else if(t===195)n=!0;else if(t===202)n=this.readF32();else if(t===203)n=this.readF64();else if(t===204)n=this.readU8();else if(t===205)n=this.readU16();else if(t===206)n=this.readU32();else if(t===207)n=this.readU64();else if(t===208)n=this.readI8();else if(t===209)n=this.readI16();else if(t===210)n=this.readI32();else if(t===211)n=this.readI64();else if(t===217){var i=this.lookU8();n=this.decodeUtf8String(i,1)}else if(t===218){var i=this.lookU16();n=this.decodeUtf8String(i,2)}else if(t===219){var i=this.lookU32();n=this.decodeUtf8String(i,4)}else if(t===220){var r=this.readU16();if(r!==0){this.pushArrayState(r),this.complete();continue e}else n=[]}else if(t===221){var r=this.readU32();if(r!==0){this.pushArrayState(r),this.complete();continue e}else n=[]}else if(t===222){var r=this.readU16();if(r!==0){this.pushMapState(r),this.complete();continue e}else n={}}else if(t===223){var r=this.readU32();if(r!==0){this.pushMapState(r),this.complete();continue e}else n={}}else if(t===196){var r=this.lookU8();n=this.decodeBinary(r,1)}else if(t===197){var r=this.lookU16();n=this.decodeBinary(r,2)}else if(t===198){var r=this.lookU32();n=this.decodeBinary(r,4)}else if(t===212)n=this.decodeExtension(1,0);else if(t===213)n=this.decodeExtension(2,0);else if(t===214)n=this.decodeExtension(4,0);else if(t===215)n=this.decodeExtension(8,0);else if(t===216)n=this.decodeExtension(16,0);else if(t===199){var r=this.lookU8();n=this.decodeExtension(r,1)}else if(t===200){var r=this.lookU16();n=this.decodeExtension(r,2)}else if(t===201){var r=this.lookU32();n=this.decodeExtension(r,4)}else throw new Dt("Unrecognized type byte: ".concat(wu(t)));this.complete();for(var o=this.stack;o.length>0;){var s=o[o.length-1];if(s.type===0)if(s.array[s.position]=n,s.position++,s.position===s.size)o.pop(),n=s.array;else continue e;else if(s.type===1){if(!Tk(n))throw new Dt("The type of key must be string or number but "+typeof n);if(n==="__proto__")throw new Dt("The key __proto__ is not allowed");s.key=n,s.type=2;continue e}else if(s.map[s.key]=n,s.readCount++,s.readCount===s.size)o.pop(),n=s.map;else{s.key=null,s.type=1;continue e}}return n}},e.prototype.readHeadByte=function(){return this.headByte===Qi&&(this.headByte=this.readU8()),this.headByte},e.prototype.complete=function(){this.headByte=Qi},e.prototype.readArraySize=function(){var t=this.readHeadByte();switch(t){case 220:return this.readU16();case 221:return this.readU32();default:{if(t<160)return t-144;throw new Dt("Unrecognized array type byte: ".concat(wu(t)))}}},e.prototype.pushMapState=function(t){if(t>this.maxMapLength)throw new Dt("Max length exceeded: map length (".concat(t,") > maxMapLengthLength (").concat(this.maxMapLength,")"));this.stack.push({type:1,size:t,key:null,readCount:0,map:{}})},e.prototype.pushArrayState=function(t){if(t>this.maxArrayLength)throw new Dt("Max length exceeded: array length (".concat(t,") > maxArrayLength (").concat(this.maxArrayLength,")"));this.stack.push({type:0,size:t,array:new Array(t),position:0})},e.prototype.decodeUtf8String=function(t,n){var r;if(t>this.maxStrLength)throw new Dt("Max length exceeded: UTF-8 byte length (".concat(t,") > maxStrLength (").concat(this.maxStrLength,")"));if(this.bytes.byteLength<this.pos+n+t)throw Dp;var i=this.pos+n,o;return this.stateIsMapKey()&&(!((r=this.keyDecoder)===null||r===void 0)&&r.canBeCached(t))?o=this.keyDecoder.decode(this.bytes,i,t):t>ck?o=fk(this.bytes,i,t):o=Cy(this.bytes,i,t),this.pos+=n+t,o},e.prototype.stateIsMapKey=function(){if(this.stack.length>0){var t=this.stack[this.stack.length-1];return t.type===1}return!1},e.prototype.decodeBinary=function(t,n){if(t>this.maxBinLength)throw new Dt("Max length exceeded: bin length (".concat(t,") > maxBinLength (").concat(this.maxBinLength,")"));if(!this.hasRemaining(t+n))throw Dp;var r=this.pos+n,i=this.bytes.subarray(r,r+t);return this.pos+=n+t,i},e.prototype.decodeExtension=function(t,n){if(t>this.maxExtLength)throw new Dt("Max length exceeded: ext length (".concat(t,") > maxExtLength (").concat(this.maxExtLength,")"));var r=this.view.getInt8(this.pos+n),i=this.decodeBinary(t,n+1);return this.extensionCodec.decode(i,r,this.context)},e.prototype.lookU8=function(){return this.view.getUint8(this.pos)},e.prototype.lookU16=function(){return this.view.getUint16(this.pos)},e.prototype.lookU32=function(){return this.view.getUint32(this.pos)},e.prototype.readU8=function(){var t=this.view.getUint8(this.pos);return this.pos++,t},e.prototype.readI8=function(){var t=this.view.getInt8(this.pos);return this.pos++,t},e.prototype.readU16=function(){var t=this.view.getUint16(this.pos);return this.pos+=2,t},e.prototype.readI16=function(){var t=this.view.getInt16(this.pos);return this.pos+=2,t},e.prototype.readU32=function(){var t=this.view.getUint32(this.pos);return this.pos+=4,t},e.prototype.readI32=function(){var t=this.view.getInt32(this.pos);return this.pos+=4,t},e.prototype.readU64=function(){var t=nk(this.view,this.pos);return this.pos+=8,t},e.prototype.readI64=function(){var t=Ay(this.view,this.pos);return this.pos+=8,t},e.prototype.readF32=function(){var t=this.view.getFloat32(this.pos);return this.pos+=4,t},e.prototype.readF64=function(){var t=this.view.getFloat64(this.pos);return this.pos+=8,t},e}(),Lk={};function Oy(e,t){t===void 0&&(t=Lk);var n=new Mk(t.extensionCodec,t.context,t.maxStrLength,t.maxBinLength,t.maxArrayLength,t.maxMapLength,t.maxExtLength);return n.decode(e)}class Ik{constructor(t){I(this,"context");I(this,"_activeContext");I(this,"_activeCommand");I(this,"_highlightCommand");I(this,"highlightState",ye.AFTER);I(this,"highlightScreencast",null);I(this,"highlightInterval");I(this,"_darken",!1);I(this,"screencast",{lastFrameBeforeSector:null,inBetween:[]});I(this,"defaults",{highlightCommandState:ye.AFTER});I(this,"_mode",ey.FRAME);I(this,"_state",ye.AFTER);I(this,"_lastActiveScreencastUrl",null);this.context=t,ua(this,{_activeContext:U,_activeCommand:U,_highlightCommand:U,highlightState:U,highlightScreencast:U,highlightInterval:U,_darken:U,screencast:U,_mode:U,_state:U,clear:te,resetHighlightInterval:te,toggleHighlightState:te,findLastEventUntil:te,findEventsBetween:te,findLastScreencastForCommand:te,registerEvents:te,toggleCommand:te,highlightCommand:te,unhighlightCommand:te,activeScreencast:ne,visibleScreencast:ne,activeScreencastUrl:ne,visibleCommand:ne,visibleHighlightState:ne,isVisibleHighlight:ne,mode:ne,state:ne}),this.registerEvents()}get mode(){return this._mode}set mode(t){this._mode=t}get state(){return this._state}set state(t){this._state=t}get activeScreencast(){if(!this._activeCommand){const t=this.context.screencasts;return t[t.length-1]??null}return this.state===ye.AFTER&&this.screencast.inBetween.length>0?this.screencast.inBetween[this.screencast.inBetween.length-1]:this.state===ye.BEFORE?this.screencast.lastFrameBeforeSector:this.screencast.lastFrameBeforeSector}get visibleScreencast(){return this._highlightCommand?this.highlightScreencast:this.activeScreencast}get activeScreencastUrl(){return this._lastActiveScreencastUrl&&URL.revokeObjectURL(this._lastActiveScreencastUrl),this.visibleScreencast?(this._lastActiveScreencastUrl=URL.createObjectURL(new Blob([this.visibleScreencast.frame],{type:"image/jpeg"})),this._lastActiveScreencastUrl):null}clear(){this._highlightCommand=void 0,this.highlightScreencast=void 0,this.highlightState=ye.AFTER,this._activeCommand=void 0,this._activeContext=void 0,this.screencast.lastFrameBeforeSector=null,this.screencast.inBetween=[],this._lastActiveScreencastUrl!==null&&(URL.revokeObjectURL(this._lastActiveScreencastUrl),this._lastActiveScreencastUrl=null)}set darken(t){this._darken=t}get darken(){return this._darken}resetHighlightInterval(){clearInterval(this.highlightInterval),this.highlightState=ye.AFTER}toggleHighlightState(){this.highlightState=this.highlightState===ye.BEFORE?ye.AFTER:ye.BEFORE}get visibleCommand(){return this._highlightCommand??this.activeCommand}get visibleHighlightState(){return this._highlightCommand?this.defaults.highlightCommandState:this.state}get isVisibleHighlight(){return this._highlightCommand!==void 0}set activeCommand(t){t&&(this.activeContext=t.context),this._activeCommand=t}get activeCommand(){return this._activeCommand}set activeContext(t){this._activeContext=t}get activeContext(){return this._activeContext}findLastEventUntil(t,n){let r=null;for(let i of n){if(i.timestamp>=t)break;r=i}return r}findEventsBetween(t,n,r){let i=[];for(let o of r)o.timestamp>t&&o.timestamp<n&&i.push(o);return i}findLastScreencastForCommand(t){let n=t.context.commands.findIndex(r=>t.id===r.id);if(n===t.context.commands.length-1)return{screencast:t.context.screencasts[t.context.screencasts.length-1],until:t.timestamp};{let r=t.context.commands[n+1].time.started;return{screencast:this.findLastEventUntil(r,t.context.screencasts),until:r}}}toggleCommand(t){var i,o;if(((i=this.activeCommand)==null?void 0:i.id)===(t==null?void 0:t.id)){this.activeCommand=void 0,this.screencast.lastFrameBeforeSector=void 0,this.screencast.inBetween=[],Ar.emit("command:active",void 0);return}((o=this._highlightCommand)==null?void 0:o.id)===(t==null?void 0:t.id)&&(this._highlightCommand=void 0,this.highlightScreencast=null),this.activeCommand=t;let n=t.context.commands.findIndex(s=>t.id===s.id),r=n===t.context.commands.length-1?t.time.finished+100:t.context.commands[n+1].time.started;this.screencast.inBetween=this.findEventsBetween(t.time.started,r,t.context.screencasts),this.screencast.lastFrameBeforeSector=this.findLastEventUntil(t.time.started,t.context.screencasts),Ar.emit("command:active",t)}highlightCommand(t){var r,i;if(((r=this.visibleCommand)==null?void 0:r.id)===(t==null?void 0:t.id)||((i=this.activeCommand)==null?void 0:i.id)===(t==null?void 0:t.id))return;this._highlightCommand=t,this.resetHighlightInterval();let n=this.findLastScreencastForCommand(t);this.highlightScreencast=n.screencast,console.debug("[Preview] highlightCommand",t,n)}unhighlightCommand(t){var n;((n=this._highlightCommand)==null?void 0:n.id)===(t==null?void 0:t.id)&&(console.debug("[Preview] unhighlightCommand",t),this._highlightCommand=void 0,this.highlightScreencast=null)}registerEvents(){}}class ai{constructor(t,n,r){I(this,"id");I(this,"commands",[]);I(this,"logs",[]);I(this,"network",[]);I(this,"annotations",[]);I(this,"handoffs",[]);I(this,"navigations",[]);I(this,"screencasts",[]);I(this,"unspecific",[]);I(this,"renderedEvents",[]);I(this,"responseContentByPacketId",new Map);I(this,"group","");I(this,"test",{name:"",status:void 0});I(this,"options");I(this,"capabilities");I(this,"createdAt");I(this,"lastActivity");I(this,"original");I(this,"app");I(this,"connection");I(this,"preview",null);I(this,"followIncoming",!0);this.original=t,this.app=n,this.connection=r;let{id:i,options:o,test:s,group:l,capabilities:a,timestamp:u}=t;this.id=i,this.options=o,this.test=s,this.group=l,this.capabilities=a,this.createdAt=u,this.lastActivity=u,this.preview=null,this.initializePreviewStore(),ua(this,{commands:U,logs:U,network:U,annotations:U,handoffs:U,navigations:U,screencasts:U,unspecific:U,group:U,test:U,options:U,capabilities:U,lastActivity:U,connection:U,followIncoming:U,renderedEvents:U,initializePreviewStore:te,received:te,getEventTime:te,packets:te,blob:te,took:ne,isForeground:ne,isAgent:ne,isLive:ne,handoff:ne,toolCalls:ne})}initializePreviewStore(){if(this.preview!==null){console.warn("[Context] Already initialized preview store");return}this.preview=new Ik(this),this.renderedEvents.length!==0&&this.preview.toggleCommand(this.renderedEvents[this.renderedEvents.length-1])}received(t){var r;t.context=this,this.registerResponseContent(t),t.type==="command"?(this.commands.push(t),[ho.Page,ho.ElementHandle,"Browser"].includes(t.on.type)&&this.pushRenderedPacket(t)):t.type==="log"?(this.logs.push(t),this.pushRenderedPacket(t)):t.type==="request"||t.type==="response"||t.type==="update"&&t.specific==="request.failed"?(this.network.push(t),t.type!=="request"&&this.pushRenderedPacket(t)):t.type==="annotation"?(this.annotations.push(t),this.pushRenderedPacket(t)):t.type==="navigation"?(this.navigations.push(t),this.pushRenderedPacket(t)):t.type==="handoff"?(this.handoffs.push(t),this.pushRenderedPacket(t)):t.type==="test"?(t.specific==="status"&&(this.test.status=t.status),this.unspecific.push(t)):t.type==="screencasts"?this.screencasts.push(t):(console.log("unhandled event packet",t),this.unspecific.push(t));let n=((r=t==null?void 0:t.time)==null?void 0:r.finished)>t.timestamp?t.time.finished:t.timestamp;n>this.lastActivity&&(this.lastActivity=n)}static eventTime(t){var n;return t.timestamp??((n=t.time)==null?void 0:n.finished)??t.time??0}pushRenderedPacket(t){var i;const n=ai.eventTime(t),r=this.renderedEvents.length;if(r===0||ai.eventTime(this.renderedEvents[r-1])<=n)this.renderedEvents.push(t);else{let o=this.renderedEvents.findIndex(s=>ai.eventTime(s)>n);this.renderedEvents.splice(o,0,t)}if(t.type==="command"&&this.isForeground&&this.followIncoming&&this.preview!==null){const o=this.renderedEvents.filter(l=>l.type==="command"),s=o.length;s>1&&o[s-2].id===((i=this.preview.activeCommand)==null?void 0:i.id)&&this.preview.toggleCommand(o[s-1])}}getEventTime(t){var n,r;return((n=t==null?void 0:t.time)==null?void 0:n.started)??((r=t==null?void 0:t.time)==null?void 0:r.created)??(t==null?void 0:t.timestamp)??(t==null?void 0:t.time)}packets(){let t=[structuredClone(Sh(this.original)),...this.commands,...this.logs,...this.network,...this.annotations,...this.handoffs,...this.navigations,...this.screencasts,...this.unspecific];for(let n=1;n<t.length;n++){let r=t[n];r.context=t[0].context,t[n]=structuredClone(Sh(r)),r.context=this}return t}responseContent(t){return t.content??(t.contentReference==null?void 0:this.responseContentByPacketId.get(t.contentReference))}registerResponseContent(t){if(t.type==="response"){if(t.content instanceof Uint8Array){this.responseContentByPacketId.set(t.id,t.content);return}t.contentReference!=null&&!this.responseContentByPacketId.has(t.contentReference)&&console.warn("Response content reference could not be resolved",t)}}blob(){return new Blob([ky(this.packets(),{extensionCodec:Fo})])}get took(){const t=this.lastActivity-this.createdAt,n=Math.floor(t/1e3/60),r=Math.ceil(t/1e3%60);return{ms:t,minutes:n,seconds:r}}get isAgent(){return this.group==="mcp"}get isLive(){return(this.test.status??"pending")==="pending"}get handoff(){return this.handoffs[this.handoffs.length-1]}get toolCalls(){return this.annotations.filter(t=>t.kind==="tool").length}get isForeground(){var t;return((t=this.app.activeContext)==null?void 0:t.id)===this.id}}const Fo=new sd;Fo.register({type:0,encode:e=>e instanceof Function?new TextEncoder().encode(e.toString()):null,decode:e=>new TextDecoder().decode(e)});class Mp{constructor(t){I(this,"app");I(this,"websocket");I(this,"uri","");I(this,"connectionTimeout",2e3);I(this,"connectionState",WebSocket.CLOSED);I(this,"totalBytesReceived",0);I(this,"contexts",[]);I(this,"emitter",Y0());I(this,"active",{context:void 0});Uf(this),this.app=t}setActiveContext(t){t.initializePreviewStore(),this.active.context=t}retry(){return new Promise((t,n)=>{if(this.connectionState!==WebSocket.CLOSED){t(this);return}if(this.uri===""){console.warn("[Connection] No uri set. Hint: call connect() before retrying.",this),n({code:"missing",reason:"Missing uri"});return}t(this.connect(this.uri))})}destroy(){this.websocket.close()}connect(t){return new Promise((n,r)=>{this.uri=t,this.websocket=new WebSocket(this.uri),this.websocket.binaryType="arraybuffer",this.connectionState=this.websocket.readyState;const i=()=>{clearTimeout(a),this.connectionState=this.websocket.readyState,n(this)},o=()=>{clearTimeout(a),l(),this.connectionState=this.websocket.readyState,r({code:"closed",reason:"Connection closed"})},s=u=>{this.received(u.data)};this.websocket.addEventListener("open",i),this.websocket.addEventListener("close",o),this.websocket.addEventListener("message",s);const l=()=>{this.websocket.removeEventListener("open",i),this.websocket.removeEventListener("close",o),this.websocket.removeEventListener("message",s)},a=setTimeout(()=>{this.websocket.readyState===WebSocket.CONNECTING&&(l(),this.websocket.close(),r({code:"timeout",reason:"Connection timeout reached (2s)"}))},this.connectionTimeout)})}send(t){if(this.websocket.readyState!==WebSocket.OPEN){console.error("Did not send packet because websocket was not open",t);return}let n=ky(t,{extensionCodec:Fo});this.websocket.send(n)}received(t){this.totalBytesReceived+=t.byteLength;let n=Date.now(),r=Oy(t,{extensionCodec:Fo}),i=Date.now();if(Array.isArray(r))for(let s of r)this.receivedPacket(s);else this.receivedPacket(r);let o=Date.now();Ml(()=>{let s=(t.byteLength/1e3/1e3).toFixed(2);console.group("Packet received"),console.groupCollapsed("Events",Array.isArray(r)?r.length:1),J0(r),console.groupEnd(),console.log("Size",s,"mb"),console.log("Delta time parse",i-n,"ms"),console.log("Delta time proc.",o-i,"ms"),console.log("Delta time debug",Date.now()-o,"ms"),console.groupEnd()})}receivedPacket(t){if(t.type==="context"){let r=new ai(t,this.app,this);this.contexts.unshift(r),Ar.emit("context:created",r),this.emit("context:created",r);return}let n=this.getContext(t.context.id);if(!n){console.log("ignored packet because no context was initialized",t);return}n.received(t),Ar.emit("context:received",{context:n,packet:t}),this.emit("context:received",{context:n,packet:t})}getContext(t){return this.contexts.find(n=>n.id===t)}get hasNoContexts(){return this.contexts.length===0}get isForeground(){return this.app.active.connection===this}get isConnected(){return this.connectionState===WebSocket.OPEN}getTotalBytesReceived(){return this.totalBytesReceived}getMetrics(){let t={contexts:this.contexts.length,events:0};return this.contexts.forEach(n=>{t.events+=n.commands.length,t.events+=n.logs.length}),t}clear(){}on(t,n){return this.emitter.on(t,n)}off(t,n){return this.emitter.on(t,n)}emit(t,n){return this.emitter.emit(t,n)}}class dr extends Error{}function Fk(e){try{return Oy(e,{extensionCodec:Fo})}catch{throw new dr("This file is not a Puth snapshot or it is damaged.")}}function zk(e){var s;const t=Fk(e);if(!Array.isArray(t)||t.length===0)throw new dr("This snapshot does not contain any packets.");const[n]=t;if((n==null?void 0:n.type)!=="context"||((s=n==null?void 0:n.context)==null?void 0:s.id)==null)throw new dr("This snapshot does not start with a context packet.");const r=n.snapshotVersion??1;if(!Number.isInteger(r)||r<1||r>hp)throw new dr(`Snapshot version ${r} is not supported. This GUI reads versions up to ${hp}.`);const i=new Set(t.filter(l=>(l==null?void 0:l.content)!=null).map(l=>l.id)),o=t.find(l=>(l==null?void 0:l.contentReference)!=null&&!i.has(l.contentReference));if(o!==void 0)throw new dr(`Response ${o.id} references content that is missing from this snapshot.`);return t}const Uk=Se(()=>{const{app:e}=x.useContext(Ee),[t,n]=x.useState(!1),r=async l=>{const a=zk(await l.arrayBuffer());if(nA(a),e.dragAndDropped.contexts.some(c=>c.id===a[0].context.id))throw new dr("This snapshot is already imported.");let u=new ai(a[0],e);for(let c=1;c<a.length;c++)u.received(a[c]);jn(()=>e.dragAndDropped.contexts.unshift(u))};let i=async l=>{n(!0),jn(()=>e.importErrors=[]);const u=(await Promise.allSettled(l.map(r))).flatMap((c,f)=>{if(c.status==="fulfilled")return[];console.warn("Could not import snapshot",c.reason);const d=c.reason instanceof dr?c.reason.message:"This snapshot contains packets that could not be read.";return[`${l[f].name}: ${d}`]});jn(()=>{e.importErrors=u,u.length!==l.length&&(e.setView("local"),e.dragAndDropped.active=e.dragAndDropped.contexts[0]),Io.active=0}),n(!1)};const{getRootProps:o,getInputProps:s}=Sy({accept:".puth",onDropAccepted:i,noDragEventsBubbling:!0});return h.jsxs(h.Fragment,{children:[h.jsxs("div",{...o({className:`dropzone-wrapper ${Io.active>0?"active":""}`}),children:[h.jsx("input",{...s()}),h.jsxs("div",{className:"dropzone shell-hero relative overflow-hidden",children:[h.jsx("div",{"aria-hidden":!0,className:"shell-hero-dots absolute inset-0"}),h.jsx("div",{"aria-hidden":!0,className:"shell-hero-grain absolute inset-0"}),h.jsx("div",{"aria-hidden":!0,className:"shell-hero-scrim absolute inset-0"}),h.jsx("div",{className:"relative flex flex-col items-center gap-3.5",children:t?h.jsxs(h.Fragment,{children:[h.jsx(Pt,{name:"progress_activity",size:"2rem",className:"animate-spin text-blue-100"}),h.jsx("div",{role:"status",className:"text-[22px] font-medium text-blue-50",children:"Importing snapshot..."})]}):h.jsxs(h.Fragment,{children:[h.jsx("span",{"aria-hidden":!0,className:"flex h-[60px] w-[60px] items-center justify-center rounded-[14px] border border-blue-200/45 bg-blue-950/50 text-blue-100",children:h.jsx(Pt,{name:"download",size:"1.6rem",className:"rotate-180"})}),h.jsx("p",{className:"text-[26px] font-medium tracking-[-0.01em] text-blue-50",children:"Drag and drop a snapshot"}),h.jsx("em",{className:"font-mono text-[12.5px] not-italic text-blue-50",children:"Only .puth files · stays on this machine"})]})})]})]}),e.importErrors.length>0&&h.jsx("div",{className:"fixed left-1/2 top-4 z-[110] w-[min(520px,calc(100%-32px))] -translate-x-1/2",children:h.jsxs("button",{type:"button",puth:"import-errors",role:"alert","aria-label":"Import failed, click to dismiss",className:"flex w-full flex-col overflow-hidden rounded-[10px] border border-red-400/35 bg-gradient-to-b from-[#2a1414] to-[#1c1010] text-left shadow-[0_20px_50px_rgba(0,0,0,0.6)]",onClick:()=>jn(()=>e.importErrors=[]),children:[h.jsxs("span",{className:"flex w-full justify-between border-b border-dashed border-red-400/25 px-3.5 py-2.5 font-mono text-xs",children:[h.jsxs("span",{className:"text-red-300",children:["Import failed · ",e.importErrors.length," ",e.importErrors.length===1?"file":"files"]}),h.jsx("span",{className:"text-ink-body",children:"Dismiss"})]}),h.jsx("span",{className:"flex flex-col gap-1.5 px-3.5 py-3 text-[13px] leading-normal text-red-100",children:e.importErrors.map((l,a)=>h.jsx("span",{children:l},a))})]})})]})}),Bk=()=>h.jsxs(h.Fragment,{children:[h.jsx(aC,{}),h.jsx(Uk,{})]});class $k{constructor(){I(this,"name",{suffix:""});I(this,"connections",[]);I(this,"connectionSuggestions",[(document.location.protocol==="https:"?"wss://":"ws://")+window.location.host+"/websocket"]);I(this,"active",{connection:void 0});I(this,"modals",{connectionViewer:!0});I(this,"mode","default");I(this,"classes",{Connection:Mp});I(this,"dragAndDropped",{contexts:[],active:null});I(this,"settings",{preview:{darken:!1}});I(this,"view","instance");I(this,"agentsActive",null);I(this,"pinned",[]);I(this,"importErrors",[]);this.settings.preview.darken=this.readLocalStorageBoolean("previewStore.darken"),ua(this,{name:U,connections:U,connectionSuggestions:U,active:U,modals:U,mode:U,classes:U,dragAndDropped:U,settings:U,view:U,agentsActive:U,pinned:U,togglePinned:te,agents:ne,liveAgents:ne,importErrors:U,tryConnectingTo:te,setActive:te,setView:te,setDarkenPreview:te,history:ne,activeContext:ne,previewStore:ne,empty:ne,hasLocalContexts:ne,isConnected:ne})}async tryConnectingTo(t){return new Mp(this).connect(t).then(n=>(this.connections.length!==0&&(this.connections[0].destroy(),this.connections=[]),this.connections.push(n),this.active.connection=n,n))}get history(){var t;return this.view==="instance"?(((t=this.active.connection)==null?void 0:t.contexts)??[]).filter(n=>!n.isAgent):this.view==="agents"?this.agents:this.dragAndDropped.contexts}get agents(){var t;return(((t=this.active.connection)==null?void 0:t.contexts)??[]).filter(n=>n.isAgent||n.handoffs.some(r=>r.state==="claimed"))}get liveAgents(){return this.agents.filter(t=>t.isLive).length}get activeContext(){var t;return this.view==="instance"?(t=this.active.connection)==null?void 0:t.active.context:this.view==="agents"?this.agentsActive??void 0:this.dragAndDropped.active}togglePinned(t){this.pinned=this.pinned.includes(t.id)?this.pinned.filter(n=>n!==t.id):[...this.pinned,t.id]}get previewStore(){var t;return(t=this.activeContext)==null?void 0:t.preview}get empty(){return!this.hasLocalContexts&&!this.isConnected}get hasLocalContexts(){return this.dragAndDropped.contexts.length!==0}get isConnected(){return this.connections.length!==0}setActive(t){if(this.view==="agents"){this.agentsActive=t;return}if(this.view==="instance"){if(!this.active.connection||this.active.connection.active.context===t)return;this.active.connection.setActiveContext(t);return}this.dragAndDropped.active=t}setView(t){this.view=t}setDarkenPreview(t){this.settings.preview.darken=t,this.writeLocalStorageBoolean("previewStore.darken",t)}readLocalStorageBoolean(t){return localStorage.getItem(t)==="true"}writeLocalStorageBoolean(t,n){localStorage.setItem(t,n?"true":"false")}}const Ic=new $k;Ar.on("command:active",e=>{Ic.mode==="follow"&&(Ic.mode="default")});_u.createRoot(document.getElementById("root")).render(h.jsx(Cn.StrictMode,{children:h.jsx(Ee.Provider,{value:{app:Ic},children:h.jsx(Bk,{})})}));let cn=document.getElementById("root");cn==null||cn.addEventListener("dragenter",()=>{jn(()=>Io.active++)});cn==null||cn.addEventListener("dragleave",()=>{jn(()=>Io.active--)});cn==null||cn.addEventListener("drop",()=>{jn(()=>Io.active--)});