@axlsdk/studio 0.13.5 → 0.13.6

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,191 @@
1
+ var x0=Object.defineProperty;var fp=n=>{throw TypeError(n)};var y0=(n,i,c)=>i in n?x0(n,i,{enumerable:!0,configurable:!0,writable:!0,value:c}):n[i]=c;var ai=(n,i,c)=>y0(n,typeof i!="symbol"?i+"":i,c),mo=(n,i,c)=>i.has(n)||fp("Cannot "+c);var N=(n,i,c)=>(mo(n,i,"read from private field"),c?c.call(n):i.get(n)),ne=(n,i,c)=>i.has(n)?fp("Cannot add the same private member more than once"):i instanceof WeakSet?i.add(n):i.set(n,c),I=(n,i,c,o)=>(mo(n,i,"write to private field"),o?o.call(n,c):i.set(n,c),c),me=(n,i,c)=>(mo(n,i,"access private method"),c);var qu=(n,i,c,o)=>({set _(d){I(n,i,d,c)},get _(){return N(n,i,o)}});(function(){const i=document.createElement("link").relList;if(i&&i.supports&&i.supports("modulepreload"))return;for(const d of document.querySelectorAll('link[rel="modulepreload"]'))o(d);new MutationObserver(d=>{for(const h of d)if(h.type==="childList")for(const v of h.addedNodes)v.tagName==="LINK"&&v.rel==="modulepreload"&&o(v)}).observe(document,{childList:!0,subtree:!0});function c(d){const h={};return d.integrity&&(h.integrity=d.integrity),d.referrerPolicy&&(h.referrerPolicy=d.referrerPolicy),d.crossOrigin==="use-credentials"?h.credentials="include":d.crossOrigin==="anonymous"?h.credentials="omit":h.credentials="same-origin",h}function o(d){if(d.ep)return;d.ep=!0;const h=c(d);fetch(d.href,h)}})();var po={exports:{}},ni={};/**
2
+ * @license React
3
+ * react-jsx-runtime.production.js
4
+ *
5
+ * Copyright (c) Meta Platforms, Inc. and 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 dp;function g0(){if(dp)return ni;dp=1;var n=Symbol.for("react.transitional.element"),i=Symbol.for("react.fragment");function c(o,d,h){var v=null;if(h!==void 0&&(v=""+h),d.key!==void 0&&(v=""+d.key),"key"in d){h={};for(var p in d)p!=="key"&&(h[p]=d[p])}else h=d;return d=h.ref,{$$typeof:n,type:o,key:v,ref:d!==void 0?d:null,props:h}}return ni.Fragment=i,ni.jsx=c,ni.jsxs=c,ni}var hp;function b0(){return hp||(hp=1,po.exports=g0()),po.exports}var r=b0(),vo={exports:{}},ce={};/**
10
+ * @license React
11
+ * react.production.js
12
+ *
13
+ * Copyright (c) Meta Platforms, Inc. and 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 mp;function S0(){if(mp)return ce;mp=1;var n=Symbol.for("react.transitional.element"),i=Symbol.for("react.portal"),c=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),d=Symbol.for("react.profiler"),h=Symbol.for("react.consumer"),v=Symbol.for("react.context"),p=Symbol.for("react.forward_ref"),y=Symbol.for("react.suspense"),x=Symbol.for("react.memo"),b=Symbol.for("react.lazy"),g=Symbol.for("react.activity"),A=Symbol.iterator;function O(C){return C===null||typeof C!="object"?null:(C=A&&C[A]||C["@@iterator"],typeof C=="function"?C:null)}var k={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},H=Object.assign,U={};function V(C,X,J){this.props=C,this.context=X,this.refs=U,this.updater=J||k}V.prototype.isReactComponent={},V.prototype.setState=function(C,X){if(typeof C!="object"&&typeof C!="function"&&C!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,C,X,"setState")},V.prototype.forceUpdate=function(C){this.updater.enqueueForceUpdate(this,C,"forceUpdate")};function $(){}$.prototype=V.prototype;function M(C,X,J){this.props=C,this.context=X,this.refs=U,this.updater=J||k}var Y=M.prototype=new $;Y.constructor=M,H(Y,V.prototype),Y.isPureReactComponent=!0;var R=Array.isArray;function P(){}var q={H:null,A:null,T:null,S:null},Z=Object.prototype.hasOwnProperty;function G(C,X,J){var ee=J.ref;return{$$typeof:n,type:C,key:X,ref:ee!==void 0?ee:null,props:J}}function W(C,X){return G(C.type,X,C.props)}function ue(C){return typeof C=="object"&&C!==null&&C.$$typeof===n}function He(C){var X={"=":"=0",":":"=2"};return"$"+C.replace(/[=:]/g,function(J){return X[J]})}var Yt=/\/+/g;function dt(C,X){return typeof C=="object"&&C!==null&&C.key!=null?He(""+C.key):X.toString(36)}function tt(C){switch(C.status){case"fulfilled":return C.value;case"rejected":throw C.reason;default:switch(typeof C.status=="string"?C.then(P,P):(C.status="pending",C.then(function(X){C.status==="pending"&&(C.status="fulfilled",C.value=X)},function(X){C.status==="pending"&&(C.status="rejected",C.reason=X)})),C.status){case"fulfilled":return C.value;case"rejected":throw C.reason}}throw C}function L(C,X,J,ee,re){var he=typeof C;(he==="undefined"||he==="boolean")&&(C=null);var Ne=!1;if(C===null)Ne=!0;else switch(he){case"bigint":case"string":case"number":Ne=!0;break;case"object":switch(C.$$typeof){case n:case i:Ne=!0;break;case b:return Ne=C._init,L(Ne(C._payload),X,J,ee,re)}}if(Ne)return re=re(C),Ne=ee===""?"."+dt(C,0):ee,R(re)?(J="",Ne!=null&&(J=Ne.replace(Yt,"$&/")+"/"),L(re,X,J,"",function(gt){return gt})):re!=null&&(ue(re)&&(re=W(re,J+(re.key==null||C&&C.key===re.key?"":(""+re.key).replace(Yt,"$&/")+"/")+Ne)),X.push(re)),1;Ne=0;var oe=ee===""?".":ee+":";if(R(C))for(var De=0;De<C.length;De++)ee=C[De],he=oe+dt(ee,De),Ne+=L(ee,X,J,he,re);else if(De=O(C),typeof De=="function")for(C=De.call(C),De=0;!(ee=C.next()).done;)ee=ee.value,he=oe+dt(ee,De++),Ne+=L(ee,X,J,he,re);else if(he==="object"){if(typeof C.then=="function")return L(tt(C),X,J,ee,re);throw X=String(C),Error("Objects are not valid as a React child (found: "+(X==="[object Object]"?"object with keys {"+Object.keys(C).join(", ")+"}":X)+"). If you meant to render a collection of children, use an array instead.")}return Ne}function F(C,X,J){if(C==null)return C;var ee=[],re=0;return L(C,ee,"","",function(he){return X.call(J,he,re++)}),ee}function ae(C){if(C._status===-1){var X=C._result;X=X(),X.then(function(J){(C._status===0||C._status===-1)&&(C._status=1,C._result=J)},function(J){(C._status===0||C._status===-1)&&(C._status=2,C._result=J)}),C._status===-1&&(C._status=0,C._result=X)}if(C._status===1)return C._result.default;throw C._result}var ve=typeof reportError=="function"?reportError:function(C){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var X=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof C=="object"&&C!==null&&typeof C.message=="string"?String(C.message):String(C),error:C});if(!window.dispatchEvent(X))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",C);return}console.error(C)},Re={map:F,forEach:function(C,X,J){F(C,function(){X.apply(this,arguments)},J)},count:function(C){var X=0;return F(C,function(){X++}),X},toArray:function(C){return F(C,function(X){return X})||[]},only:function(C){if(!ue(C))throw Error("React.Children.only expected to receive a single React element child.");return C}};return ce.Activity=g,ce.Children=Re,ce.Component=V,ce.Fragment=c,ce.Profiler=d,ce.PureComponent=M,ce.StrictMode=o,ce.Suspense=y,ce.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=q,ce.__COMPILER_RUNTIME={__proto__:null,c:function(C){return q.H.useMemoCache(C)}},ce.cache=function(C){return function(){return C.apply(null,arguments)}},ce.cacheSignal=function(){return null},ce.cloneElement=function(C,X,J){if(C==null)throw Error("The argument must be a React element, but you passed "+C+".");var ee=H({},C.props),re=C.key;if(X!=null)for(he in X.key!==void 0&&(re=""+X.key),X)!Z.call(X,he)||he==="key"||he==="__self"||he==="__source"||he==="ref"&&X.ref===void 0||(ee[he]=X[he]);var he=arguments.length-2;if(he===1)ee.children=J;else if(1<he){for(var Ne=Array(he),oe=0;oe<he;oe++)Ne[oe]=arguments[oe+2];ee.children=Ne}return G(C.type,re,ee)},ce.createContext=function(C){return C={$$typeof:v,_currentValue:C,_currentValue2:C,_threadCount:0,Provider:null,Consumer:null},C.Provider=C,C.Consumer={$$typeof:h,_context:C},C},ce.createElement=function(C,X,J){var ee,re={},he=null;if(X!=null)for(ee in X.key!==void 0&&(he=""+X.key),X)Z.call(X,ee)&&ee!=="key"&&ee!=="__self"&&ee!=="__source"&&(re[ee]=X[ee]);var Ne=arguments.length-2;if(Ne===1)re.children=J;else if(1<Ne){for(var oe=Array(Ne),De=0;De<Ne;De++)oe[De]=arguments[De+2];re.children=oe}if(C&&C.defaultProps)for(ee in Ne=C.defaultProps,Ne)re[ee]===void 0&&(re[ee]=Ne[ee]);return G(C,he,re)},ce.createRef=function(){return{current:null}},ce.forwardRef=function(C){return{$$typeof:p,render:C}},ce.isValidElement=ue,ce.lazy=function(C){return{$$typeof:b,_payload:{_status:-1,_result:C},_init:ae}},ce.memo=function(C,X){return{$$typeof:x,type:C,compare:X===void 0?null:X}},ce.startTransition=function(C){var X=q.T,J={};q.T=J;try{var ee=C(),re=q.S;re!==null&&re(J,ee),typeof ee=="object"&&ee!==null&&typeof ee.then=="function"&&ee.then(P,ve)}catch(he){ve(he)}finally{X!==null&&J.types!==null&&(X.types=J.types),q.T=X}},ce.unstable_useCacheRefresh=function(){return q.H.useCacheRefresh()},ce.use=function(C){return q.H.use(C)},ce.useActionState=function(C,X,J){return q.H.useActionState(C,X,J)},ce.useCallback=function(C,X){return q.H.useCallback(C,X)},ce.useContext=function(C){return q.H.useContext(C)},ce.useDebugValue=function(){},ce.useDeferredValue=function(C,X){return q.H.useDeferredValue(C,X)},ce.useEffect=function(C,X){return q.H.useEffect(C,X)},ce.useEffectEvent=function(C){return q.H.useEffectEvent(C)},ce.useId=function(){return q.H.useId()},ce.useImperativeHandle=function(C,X,J){return q.H.useImperativeHandle(C,X,J)},ce.useInsertionEffect=function(C,X){return q.H.useInsertionEffect(C,X)},ce.useLayoutEffect=function(C,X){return q.H.useLayoutEffect(C,X)},ce.useMemo=function(C,X){return q.H.useMemo(C,X)},ce.useOptimistic=function(C,X){return q.H.useOptimistic(C,X)},ce.useReducer=function(C,X,J){return q.H.useReducer(C,X,J)},ce.useRef=function(C){return q.H.useRef(C)},ce.useState=function(C){return q.H.useState(C)},ce.useSyncExternalStore=function(C,X,J){return q.H.useSyncExternalStore(C,X,J)},ce.useTransition=function(){return q.H.useTransition()},ce.version="19.2.4",ce}var pp;function Zo(){return pp||(pp=1,vo.exports=S0()),vo.exports}var S=Zo(),xo={exports:{}},si={},yo={exports:{}},go={};/**
18
+ * @license React
19
+ * scheduler.production.js
20
+ *
21
+ * Copyright (c) Meta Platforms, Inc. and 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
+ */var vp;function j0(){return vp||(vp=1,(function(n){function i(L,F){var ae=L.length;L.push(F);e:for(;0<ae;){var ve=ae-1>>>1,Re=L[ve];if(0<d(Re,F))L[ve]=F,L[ae]=Re,ae=ve;else break e}}function c(L){return L.length===0?null:L[0]}function o(L){if(L.length===0)return null;var F=L[0],ae=L.pop();if(ae!==F){L[0]=ae;e:for(var ve=0,Re=L.length,C=Re>>>1;ve<C;){var X=2*(ve+1)-1,J=L[X],ee=X+1,re=L[ee];if(0>d(J,ae))ee<Re&&0>d(re,J)?(L[ve]=re,L[ee]=ae,ve=ee):(L[ve]=J,L[X]=ae,ve=X);else if(ee<Re&&0>d(re,ae))L[ve]=re,L[ee]=ae,ve=ee;else break e}}return F}function d(L,F){var ae=L.sortIndex-F.sortIndex;return ae!==0?ae:L.id-F.id}if(n.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var h=performance;n.unstable_now=function(){return h.now()}}else{var v=Date,p=v.now();n.unstable_now=function(){return v.now()-p}}var y=[],x=[],b=1,g=null,A=3,O=!1,k=!1,H=!1,U=!1,V=typeof setTimeout=="function"?setTimeout:null,$=typeof clearTimeout=="function"?clearTimeout:null,M=typeof setImmediate<"u"?setImmediate:null;function Y(L){for(var F=c(x);F!==null;){if(F.callback===null)o(x);else if(F.startTime<=L)o(x),F.sortIndex=F.expirationTime,i(y,F);else break;F=c(x)}}function R(L){if(H=!1,Y(L),!k)if(c(y)!==null)k=!0,P||(P=!0,He());else{var F=c(x);F!==null&&tt(R,F.startTime-L)}}var P=!1,q=-1,Z=5,G=-1;function W(){return U?!0:!(n.unstable_now()-G<Z)}function ue(){if(U=!1,P){var L=n.unstable_now();G=L;var F=!0;try{e:{k=!1,H&&(H=!1,$(q),q=-1),O=!0;var ae=A;try{t:{for(Y(L),g=c(y);g!==null&&!(g.expirationTime>L&&W());){var ve=g.callback;if(typeof ve=="function"){g.callback=null,A=g.priorityLevel;var Re=ve(g.expirationTime<=L);if(L=n.unstable_now(),typeof Re=="function"){g.callback=Re,Y(L),F=!0;break t}g===c(y)&&o(y),Y(L)}else o(y);g=c(y)}if(g!==null)F=!0;else{var C=c(x);C!==null&&tt(R,C.startTime-L),F=!1}}break e}finally{g=null,A=ae,O=!1}F=void 0}}finally{F?He():P=!1}}}var He;if(typeof M=="function")He=function(){M(ue)};else if(typeof MessageChannel<"u"){var Yt=new MessageChannel,dt=Yt.port2;Yt.port1.onmessage=ue,He=function(){dt.postMessage(null)}}else He=function(){V(ue,0)};function tt(L,F){q=V(function(){L(n.unstable_now())},F)}n.unstable_IdlePriority=5,n.unstable_ImmediatePriority=1,n.unstable_LowPriority=4,n.unstable_NormalPriority=3,n.unstable_Profiling=null,n.unstable_UserBlockingPriority=2,n.unstable_cancelCallback=function(L){L.callback=null},n.unstable_forceFrameRate=function(L){0>L||125<L?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):Z=0<L?Math.floor(1e3/L):5},n.unstable_getCurrentPriorityLevel=function(){return A},n.unstable_next=function(L){switch(A){case 1:case 2:case 3:var F=3;break;default:F=A}var ae=A;A=F;try{return L()}finally{A=ae}},n.unstable_requestPaint=function(){U=!0},n.unstable_runWithPriority=function(L,F){switch(L){case 1:case 2:case 3:case 4:case 5:break;default:L=3}var ae=A;A=L;try{return F()}finally{A=ae}},n.unstable_scheduleCallback=function(L,F,ae){var ve=n.unstable_now();switch(typeof ae=="object"&&ae!==null?(ae=ae.delay,ae=typeof ae=="number"&&0<ae?ve+ae:ve):ae=ve,L){case 1:var Re=-1;break;case 2:Re=250;break;case 5:Re=1073741823;break;case 4:Re=1e4;break;default:Re=5e3}return Re=ae+Re,L={id:b++,callback:F,priorityLevel:L,startTime:ae,expirationTime:Re,sortIndex:-1},ae>ve?(L.sortIndex=ae,i(x,L),c(y)===null&&L===c(x)&&(H?($(q),q=-1):H=!0,tt(R,ae-ve))):(L.sortIndex=Re,i(y,L),k||O||(k=!0,P||(P=!0,He()))),L},n.unstable_shouldYield=W,n.unstable_wrapCallback=function(L){var F=A;return function(){var ae=A;A=F;try{return L.apply(this,arguments)}finally{A=ae}}}})(go)),go}var xp;function N0(){return xp||(xp=1,yo.exports=j0()),yo.exports}var bo={exports:{}},ht={};/**
26
+ * @license React
27
+ * react-dom.production.js
28
+ *
29
+ * Copyright (c) Meta Platforms, Inc. and 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 yp;function E0(){if(yp)return ht;yp=1;var n=Zo();function i(y){var x="https://react.dev/errors/"+y;if(1<arguments.length){x+="?args[]="+encodeURIComponent(arguments[1]);for(var b=2;b<arguments.length;b++)x+="&args[]="+encodeURIComponent(arguments[b])}return"Minified React error #"+y+"; visit "+x+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function c(){}var o={d:{f:c,r:function(){throw Error(i(522))},D:c,C:c,L:c,m:c,X:c,S:c,M:c},p:0,findDOMNode:null},d=Symbol.for("react.portal");function h(y,x,b){var g=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:d,key:g==null?null:""+g,children:y,containerInfo:x,implementation:b}}var v=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function p(y,x){if(y==="font")return"";if(typeof x=="string")return x==="use-credentials"?x:""}return ht.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=o,ht.createPortal=function(y,x){var b=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!x||x.nodeType!==1&&x.nodeType!==9&&x.nodeType!==11)throw Error(i(299));return h(y,x,null,b)},ht.flushSync=function(y){var x=v.T,b=o.p;try{if(v.T=null,o.p=2,y)return y()}finally{v.T=x,o.p=b,o.d.f()}},ht.preconnect=function(y,x){typeof y=="string"&&(x?(x=x.crossOrigin,x=typeof x=="string"?x==="use-credentials"?x:"":void 0):x=null,o.d.C(y,x))},ht.prefetchDNS=function(y){typeof y=="string"&&o.d.D(y)},ht.preinit=function(y,x){if(typeof y=="string"&&x&&typeof x.as=="string"){var b=x.as,g=p(b,x.crossOrigin),A=typeof x.integrity=="string"?x.integrity:void 0,O=typeof x.fetchPriority=="string"?x.fetchPriority:void 0;b==="style"?o.d.S(y,typeof x.precedence=="string"?x.precedence:void 0,{crossOrigin:g,integrity:A,fetchPriority:O}):b==="script"&&o.d.X(y,{crossOrigin:g,integrity:A,fetchPriority:O,nonce:typeof x.nonce=="string"?x.nonce:void 0})}},ht.preinitModule=function(y,x){if(typeof y=="string")if(typeof x=="object"&&x!==null){if(x.as==null||x.as==="script"){var b=p(x.as,x.crossOrigin);o.d.M(y,{crossOrigin:b,integrity:typeof x.integrity=="string"?x.integrity:void 0,nonce:typeof x.nonce=="string"?x.nonce:void 0})}}else x==null&&o.d.M(y)},ht.preload=function(y,x){if(typeof y=="string"&&typeof x=="object"&&x!==null&&typeof x.as=="string"){var b=x.as,g=p(b,x.crossOrigin);o.d.L(y,b,{crossOrigin:g,integrity:typeof x.integrity=="string"?x.integrity:void 0,nonce:typeof x.nonce=="string"?x.nonce:void 0,type:typeof x.type=="string"?x.type:void 0,fetchPriority:typeof x.fetchPriority=="string"?x.fetchPriority:void 0,referrerPolicy:typeof x.referrerPolicy=="string"?x.referrerPolicy:void 0,imageSrcSet:typeof x.imageSrcSet=="string"?x.imageSrcSet:void 0,imageSizes:typeof x.imageSizes=="string"?x.imageSizes:void 0,media:typeof x.media=="string"?x.media:void 0})}},ht.preloadModule=function(y,x){if(typeof y=="string")if(x){var b=p(x.as,x.crossOrigin);o.d.m(y,{as:typeof x.as=="string"&&x.as!=="script"?x.as:void 0,crossOrigin:b,integrity:typeof x.integrity=="string"?x.integrity:void 0})}else o.d.m(y)},ht.requestFormReset=function(y){o.d.r(y)},ht.unstable_batchedUpdates=function(y,x){return y(x)},ht.useFormState=function(y,x,b){return v.H.useFormState(y,x,b)},ht.useFormStatus=function(){return v.H.useHostTransitionStatus()},ht.version="19.2.4",ht}var gp;function C0(){if(gp)return bo.exports;gp=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(i){console.error(i)}}return n(),bo.exports=E0(),bo.exports}/**
34
+ * @license React
35
+ * react-dom-client.production.js
36
+ *
37
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
38
+ *
39
+ * This source code is licensed under the MIT license found in the
40
+ * LICENSE file in the root directory of this source tree.
41
+ */var bp;function T0(){if(bp)return si;bp=1;var n=N0(),i=Zo(),c=C0();function o(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var l=2;l<arguments.length;l++)t+="&args[]="+encodeURIComponent(arguments[l])}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."}function d(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function h(e){var t=e,l=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,(t.flags&4098)!==0&&(l=t.return),e=t.return;while(e)}return t.tag===3?l:null}function v(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 p(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function y(e){if(h(e)!==e)throw Error(o(188))}function x(e){var t=e.alternate;if(!t){if(t=h(e),t===null)throw Error(o(188));return t!==e?null:e}for(var l=e,a=t;;){var s=l.return;if(s===null)break;var u=s.alternate;if(u===null){if(a=s.return,a!==null){l=a;continue}break}if(s.child===u.child){for(u=s.child;u;){if(u===l)return y(s),e;if(u===a)return y(s),t;u=u.sibling}throw Error(o(188))}if(l.return!==a.return)l=s,a=u;else{for(var f=!1,m=s.child;m;){if(m===l){f=!0,l=s,a=u;break}if(m===a){f=!0,a=s,l=u;break}m=m.sibling}if(!f){for(m=u.child;m;){if(m===l){f=!0,l=u,a=s;break}if(m===a){f=!0,a=u,l=s;break}m=m.sibling}if(!f)throw Error(o(189))}}if(l.alternate!==a)throw Error(o(190))}if(l.tag!==3)throw Error(o(188));return l.stateNode.current===l?e:t}function b(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=b(e),t!==null)return t;e=e.sibling}return null}var g=Object.assign,A=Symbol.for("react.element"),O=Symbol.for("react.transitional.element"),k=Symbol.for("react.portal"),H=Symbol.for("react.fragment"),U=Symbol.for("react.strict_mode"),V=Symbol.for("react.profiler"),$=Symbol.for("react.consumer"),M=Symbol.for("react.context"),Y=Symbol.for("react.forward_ref"),R=Symbol.for("react.suspense"),P=Symbol.for("react.suspense_list"),q=Symbol.for("react.memo"),Z=Symbol.for("react.lazy"),G=Symbol.for("react.activity"),W=Symbol.for("react.memo_cache_sentinel"),ue=Symbol.iterator;function He(e){return e===null||typeof e!="object"?null:(e=ue&&e[ue]||e["@@iterator"],typeof e=="function"?e:null)}var Yt=Symbol.for("react.client.reference");function dt(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===Yt?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case H:return"Fragment";case V:return"Profiler";case U:return"StrictMode";case R:return"Suspense";case P:return"SuspenseList";case G:return"Activity"}if(typeof e=="object")switch(e.$$typeof){case k:return"Portal";case M:return e.displayName||"Context";case $:return(e._context.displayName||"Context")+".Consumer";case Y:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case q:return t=e.displayName||null,t!==null?t:dt(e.type)||"Memo";case Z:t=e._payload,e=e._init;try{return dt(e(t))}catch{}}return null}var tt=Array.isArray,L=i.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,F=c.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,ae={pending:!1,data:null,method:null,action:null},ve=[],Re=-1;function C(e){return{current:e}}function X(e){0>Re||(e.current=ve[Re],ve[Re]=null,Re--)}function J(e,t){Re++,ve[Re]=e.current,e.current=t}var ee=C(null),re=C(null),he=C(null),Ne=C(null);function oe(e,t){switch(J(he,t),J(re,e),J(ee,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Dm(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Dm(t),e=Um(t,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}X(ee),J(ee,e)}function De(){X(ee),X(re),X(he)}function gt(e){e.memoizedState!==null&&J(Ne,e);var t=ee.current,l=Um(t,e.type);t!==l&&(J(re,e),J(ee,l))}function Ta(e){re.current===e&&(X(ee),X(re)),Ne.current===e&&(X(Ne),Ps._currentValue=ae)}var os,of;function Oa(e){if(os===void 0)try{throw Error()}catch(l){var t=l.stack.trim().match(/\n( *(at )?)/);os=t&&t[1]||"",of=-1<l.stack.indexOf(`
42
+ at`)?" (<anonymous>)":-1<l.stack.indexOf("@")?"@unknown:0:0":""}return`
43
+ `+os+e+of}var Fu=!1;function Wu(e,t){if(!e||Fu)return"";Fu=!0;var l=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var a={DetermineComponentFrameRoot:function(){try{if(t){var K=function(){throw Error()};if(Object.defineProperty(K.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(K,[])}catch(D){var w=D}Reflect.construct(e,[],K)}else{try{K.call()}catch(D){w=D}e.call(K.prototype)}}else{try{throw Error()}catch(D){w=D}(K=e())&&typeof K.catch=="function"&&K.catch(function(){})}}catch(D){if(D&&w&&typeof D.stack=="string")return[D.stack,w.stack]}return[null,null]}};a.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var s=Object.getOwnPropertyDescriptor(a.DetermineComponentFrameRoot,"name");s&&s.configurable&&Object.defineProperty(a.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var u=a.DetermineComponentFrameRoot(),f=u[0],m=u[1];if(f&&m){var j=f.split(`
44
+ `),_=m.split(`
45
+ `);for(s=a=0;a<j.length&&!j[a].includes("DetermineComponentFrameRoot");)a++;for(;s<_.length&&!_[s].includes("DetermineComponentFrameRoot");)s++;if(a===j.length||s===_.length)for(a=j.length-1,s=_.length-1;1<=a&&0<=s&&j[a]!==_[s];)s--;for(;1<=a&&0<=s;a--,s--)if(j[a]!==_[s]){if(a!==1||s!==1)do if(a--,s--,0>s||j[a]!==_[s]){var B=`
46
+ `+j[a].replace(" at new "," at ");return e.displayName&&B.includes("<anonymous>")&&(B=B.replace("<anonymous>",e.displayName)),B}while(1<=a&&0<=s);break}}}finally{Fu=!1,Error.prepareStackTrace=l}return(l=e?e.displayName||e.name:"")?Oa(l):""}function Jv(e,t){switch(e.tag){case 26:case 27:case 5:return Oa(e.type);case 16:return Oa("Lazy");case 13:return e.child!==t&&t!==null?Oa("Suspense Fallback"):Oa("Suspense");case 19:return Oa("SuspenseList");case 0:case 15:return Wu(e.type,!1);case 11:return Wu(e.type.render,!1);case 1:return Wu(e.type,!0);case 31:return Oa("Activity");default:return""}}function ff(e){try{var t="",l=null;do t+=Jv(e,l),l=e,e=e.return;while(e);return t}catch(a){return`
47
+ Error generating stack: `+a.message+`
48
+ `+a.stack}}var Iu=Object.prototype.hasOwnProperty,Pu=n.unstable_scheduleCallback,er=n.unstable_cancelCallback,$v=n.unstable_shouldYield,Fv=n.unstable_requestPaint,At=n.unstable_now,Wv=n.unstable_getCurrentPriorityLevel,df=n.unstable_ImmediatePriority,hf=n.unstable_UserBlockingPriority,bi=n.unstable_NormalPriority,Iv=n.unstable_LowPriority,mf=n.unstable_IdlePriority,Pv=n.log,ex=n.unstable_setDisableYieldValue,fs=null,Mt=null;function Gl(e){if(typeof Pv=="function"&&ex(e),Mt&&typeof Mt.setStrictMode=="function")try{Mt.setStrictMode(fs,e)}catch{}}var zt=Math.clz32?Math.clz32:ax,tx=Math.log,lx=Math.LN2;function ax(e){return e>>>=0,e===0?32:31-(tx(e)/lx|0)|0}var Si=256,ji=262144,Ni=4194304;function Ra(e){var t=e&42;if(t!==0)return t;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:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function Ei(e,t,l){var a=e.pendingLanes;if(a===0)return 0;var s=0,u=e.suspendedLanes,f=e.pingedLanes;e=e.warmLanes;var m=a&134217727;return m!==0?(a=m&~u,a!==0?s=Ra(a):(f&=m,f!==0?s=Ra(f):l||(l=m&~e,l!==0&&(s=Ra(l))))):(m=a&~u,m!==0?s=Ra(m):f!==0?s=Ra(f):l||(l=a&~e,l!==0&&(s=Ra(l)))),s===0?0:t!==0&&t!==s&&(t&u)===0&&(u=s&-s,l=t&-t,u>=l||u===32&&(l&4194048)!==0)?t:s}function ds(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function nx(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32: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:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function pf(){var e=Ni;return Ni<<=1,(Ni&62914560)===0&&(Ni=4194304),e}function tr(e){for(var t=[],l=0;31>l;l++)t.push(e);return t}function hs(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function sx(e,t,l,a,s,u){var f=e.pendingLanes;e.pendingLanes=l,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=l,e.entangledLanes&=l,e.errorRecoveryDisabledLanes&=l,e.shellSuspendCounter=0;var m=e.entanglements,j=e.expirationTimes,_=e.hiddenUpdates;for(l=f&~l;0<l;){var B=31-zt(l),K=1<<B;m[B]=0,j[B]=-1;var w=_[B];if(w!==null)for(_[B]=null,B=0;B<w.length;B++){var D=w[B];D!==null&&(D.lane&=-536870913)}l&=~K}a!==0&&vf(e,a,0),u!==0&&s===0&&e.tag!==0&&(e.suspendedLanes|=u&~(f&~t))}function vf(e,t,l){e.pendingLanes|=t,e.suspendedLanes&=~t;var a=31-zt(t);e.entangledLanes|=t,e.entanglements[a]=e.entanglements[a]|1073741824|l&261930}function xf(e,t){var l=e.entangledLanes|=t;for(e=e.entanglements;l;){var a=31-zt(l),s=1<<a;s&t|e[a]&t&&(e[a]|=t),l&=~s}}function yf(e,t){var l=t&-t;return l=(l&42)!==0?1:lr(l),(l&(e.suspendedLanes|t))!==0?0:l}function lr(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;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:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function ar(e){return e&=-e,2<e?8<e?(e&134217727)!==0?32:268435456:8:2}function gf(){var e=F.p;return e!==0?e:(e=window.event,e===void 0?32:np(e.type))}function bf(e,t){var l=F.p;try{return F.p=e,t()}finally{F.p=l}}var Xl=Math.random().toString(36).slice(2),it="__reactFiber$"+Xl,bt="__reactProps$"+Xl,sn="__reactContainer$"+Xl,nr="__reactEvents$"+Xl,ix="__reactListeners$"+Xl,ux="__reactHandles$"+Xl,Sf="__reactResources$"+Xl,ms="__reactMarker$"+Xl;function sr(e){delete e[it],delete e[bt],delete e[nr],delete e[ix],delete e[ux]}function un(e){var t=e[it];if(t)return t;for(var l=e.parentNode;l;){if(t=l[sn]||l[it]){if(l=t.alternate,t.child!==null||l!==null&&l.child!==null)for(e=Ym(e);e!==null;){if(l=e[it])return l;e=Ym(e)}return t}e=l,l=e.parentNode}return null}function rn(e){if(e=e[it]||e[sn]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function ps(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(o(33))}function cn(e){var t=e[Sf];return t||(t=e[Sf]={hoistableStyles:new Map,hoistableScripts:new Map}),t}function lt(e){e[ms]=!0}var jf=new Set,Nf={};function Aa(e,t){on(e,t),on(e+"Capture",t)}function on(e,t){for(Nf[e]=t,e=0;e<t.length;e++)jf.add(t[e])}var rx=RegExp("^[: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]*$"),Ef={},Cf={};function cx(e){return Iu.call(Cf,e)?!0:Iu.call(Ef,e)?!1:rx.test(e)?Cf[e]=!0:(Ef[e]=!0,!1)}function Ci(e,t,l){if(cx(t))if(l===null)e.removeAttribute(t);else{switch(typeof l){case"undefined":case"function":case"symbol":e.removeAttribute(t);return;case"boolean":var a=t.toLowerCase().slice(0,5);if(a!=="data-"&&a!=="aria-"){e.removeAttribute(t);return}}e.setAttribute(t,""+l)}}function Ti(e,t,l){if(l===null)e.removeAttribute(t);else{switch(typeof l){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(t);return}e.setAttribute(t,""+l)}}function xl(e,t,l,a){if(a===null)e.removeAttribute(l);else{switch(typeof a){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(l);return}e.setAttributeNS(t,l,""+a)}}function Gt(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Tf(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function ox(e,t,l){var a=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&typeof a<"u"&&typeof a.get=="function"&&typeof a.set=="function"){var s=a.get,u=a.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return s.call(this)},set:function(f){l=""+f,u.call(this,f)}}),Object.defineProperty(e,t,{enumerable:a.enumerable}),{getValue:function(){return l},setValue:function(f){l=""+f},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function ir(e){if(!e._valueTracker){var t=Tf(e)?"checked":"value";e._valueTracker=ox(e,t,""+e[t])}}function Of(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var l=t.getValue(),a="";return e&&(a=Tf(e)?e.checked?"true":"false":e.value),e=a,e!==l?(t.setValue(e),!0):!1}function Oi(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}}var fx=/[\n"\\]/g;function Xt(e){return e.replace(fx,function(t){return"\\"+t.charCodeAt(0).toString(16)+" "})}function ur(e,t,l,a,s,u,f,m){e.name="",f!=null&&typeof f!="function"&&typeof f!="symbol"&&typeof f!="boolean"?e.type=f:e.removeAttribute("type"),t!=null?f==="number"?(t===0&&e.value===""||e.value!=t)&&(e.value=""+Gt(t)):e.value!==""+Gt(t)&&(e.value=""+Gt(t)):f!=="submit"&&f!=="reset"||e.removeAttribute("value"),t!=null?rr(e,f,Gt(t)):l!=null?rr(e,f,Gt(l)):a!=null&&e.removeAttribute("value"),s==null&&u!=null&&(e.defaultChecked=!!u),s!=null&&(e.checked=s&&typeof s!="function"&&typeof s!="symbol"),m!=null&&typeof m!="function"&&typeof m!="symbol"&&typeof m!="boolean"?e.name=""+Gt(m):e.removeAttribute("name")}function Rf(e,t,l,a,s,u,f,m){if(u!=null&&typeof u!="function"&&typeof u!="symbol"&&typeof u!="boolean"&&(e.type=u),t!=null||l!=null){if(!(u!=="submit"&&u!=="reset"||t!=null)){ir(e);return}l=l!=null?""+Gt(l):"",t=t!=null?""+Gt(t):l,m||t===e.value||(e.value=t),e.defaultValue=t}a=a??s,a=typeof a!="function"&&typeof a!="symbol"&&!!a,e.checked=m?e.checked:!!a,e.defaultChecked=!!a,f!=null&&typeof f!="function"&&typeof f!="symbol"&&typeof f!="boolean"&&(e.name=f),ir(e)}function rr(e,t,l){t==="number"&&Oi(e.ownerDocument)===e||e.defaultValue===""+l||(e.defaultValue=""+l)}function fn(e,t,l,a){if(e=e.options,t){t={};for(var s=0;s<l.length;s++)t["$"+l[s]]=!0;for(l=0;l<e.length;l++)s=t.hasOwnProperty("$"+e[l].value),e[l].selected!==s&&(e[l].selected=s),s&&a&&(e[l].defaultSelected=!0)}else{for(l=""+Gt(l),t=null,s=0;s<e.length;s++){if(e[s].value===l){e[s].selected=!0,a&&(e[s].defaultSelected=!0);return}t!==null||e[s].disabled||(t=e[s])}t!==null&&(t.selected=!0)}}function Af(e,t,l){if(t!=null&&(t=""+Gt(t),t!==e.value&&(e.value=t),l==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=l!=null?""+Gt(l):""}function Mf(e,t,l,a){if(t==null){if(a!=null){if(l!=null)throw Error(o(92));if(tt(a)){if(1<a.length)throw Error(o(93));a=a[0]}l=a}l==null&&(l=""),t=l}l=Gt(t),e.defaultValue=l,a=e.textContent,a===l&&a!==""&&a!==null&&(e.value=a),ir(e)}function dn(e,t){if(t){var l=e.firstChild;if(l&&l===e.lastChild&&l.nodeType===3){l.nodeValue=t;return}}e.textContent=t}var dx=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function zf(e,t,l){var a=t.indexOf("--")===0;l==null||typeof l=="boolean"||l===""?a?e.setProperty(t,""):t==="float"?e.cssFloat="":e[t]="":a?e.setProperty(t,l):typeof l!="number"||l===0||dx.has(t)?t==="float"?e.cssFloat=l:e[t]=(""+l).trim():e[t]=l+"px"}function _f(e,t,l){if(t!=null&&typeof t!="object")throw Error(o(62));if(e=e.style,l!=null){for(var a in l)!l.hasOwnProperty(a)||t!=null&&t.hasOwnProperty(a)||(a.indexOf("--")===0?e.setProperty(a,""):a==="float"?e.cssFloat="":e[a]="");for(var s in t)a=t[s],t.hasOwnProperty(s)&&l[s]!==a&&zf(e,s,a)}else for(var u in t)t.hasOwnProperty(u)&&zf(e,u,t[u])}function cr(e){if(e.indexOf("-")===-1)return!1;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 hx=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),mx=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Ri(e){return mx.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}function yl(){}var or=null;function fr(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var hn=null,mn=null;function wf(e){var t=rn(e);if(t&&(e=t.stateNode)){var l=e[bt]||null;e:switch(e=t.stateNode,t.type){case"input":if(ur(e,l.value,l.defaultValue,l.defaultValue,l.checked,l.defaultChecked,l.type,l.name),t=l.name,l.type==="radio"&&t!=null){for(l=e;l.parentNode;)l=l.parentNode;for(l=l.querySelectorAll('input[name="'+Xt(""+t)+'"][type="radio"]'),t=0;t<l.length;t++){var a=l[t];if(a!==e&&a.form===e.form){var s=a[bt]||null;if(!s)throw Error(o(90));ur(a,s.value,s.defaultValue,s.defaultValue,s.checked,s.defaultChecked,s.type,s.name)}}for(t=0;t<l.length;t++)a=l[t],a.form===e.form&&Of(a)}break e;case"textarea":Af(e,l.value,l.defaultValue);break e;case"select":t=l.value,t!=null&&fn(e,!!l.multiple,t,!1)}}}var dr=!1;function Df(e,t,l){if(dr)return e(t,l);dr=!0;try{var a=e(t);return a}finally{if(dr=!1,(hn!==null||mn!==null)&&(pu(),hn&&(t=hn,e=mn,mn=hn=null,wf(t),e)))for(t=0;t<e.length;t++)wf(e[t])}}function vs(e,t){var l=e.stateNode;if(l===null)return null;var a=l[bt]||null;if(a===null)return null;l=a[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":(a=!a.disabled)||(e=e.type,a=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!a;break e;default:e=!1}if(e)return null;if(l&&typeof l!="function")throw Error(o(231,t,typeof l));return l}var gl=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),hr=!1;if(gl)try{var xs={};Object.defineProperty(xs,"passive",{get:function(){hr=!0}}),window.addEventListener("test",xs,xs),window.removeEventListener("test",xs,xs)}catch{hr=!1}var Kl=null,mr=null,Ai=null;function Uf(){if(Ai)return Ai;var e,t=mr,l=t.length,a,s="value"in Kl?Kl.value:Kl.textContent,u=s.length;for(e=0;e<l&&t[e]===s[e];e++);var f=l-e;for(a=1;a<=f&&t[l-a]===s[u-a];a++);return Ai=s.slice(e,1<a?1-a:void 0)}function Mi(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 zi(){return!0}function Hf(){return!1}function St(e){function t(l,a,s,u,f){this._reactName=l,this._targetInst=s,this.type=a,this.nativeEvent=u,this.target=f,this.currentTarget=null;for(var m in e)e.hasOwnProperty(m)&&(l=e[m],this[m]=l?l(u):u[m]);return this.isDefaultPrevented=(u.defaultPrevented!=null?u.defaultPrevented:u.returnValue===!1)?zi:Hf,this.isPropagationStopped=Hf,this}return g(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var l=this.nativeEvent;l&&(l.preventDefault?l.preventDefault():typeof l.returnValue!="unknown"&&(l.returnValue=!1),this.isDefaultPrevented=zi)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=zi)},persist:function(){},isPersistent:zi}),t}var Ma={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},_i=St(Ma),ys=g({},Ma,{view:0,detail:0}),px=St(ys),pr,vr,gs,wi=g({},ys,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:yr,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!==gs&&(gs&&e.type==="mousemove"?(pr=e.screenX-gs.screenX,vr=e.screenY-gs.screenY):vr=pr=0,gs=e),pr)},movementY:function(e){return"movementY"in e?e.movementY:vr}}),qf=St(wi),vx=g({},wi,{dataTransfer:0}),xx=St(vx),yx=g({},ys,{relatedTarget:0}),xr=St(yx),gx=g({},Ma,{animationName:0,elapsedTime:0,pseudoElement:0}),bx=St(gx),Sx=g({},Ma,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),jx=St(Sx),Nx=g({},Ma,{data:0}),Bf=St(Nx),Ex={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Cx={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"},Tx={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Ox(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Tx[e])?!!t[e]:!1}function yr(){return Ox}var Rx=g({},ys,{key:function(e){if(e.key){var t=Ex[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Mi(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?Cx[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:yr,charCode:function(e){return e.type==="keypress"?Mi(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Mi(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),Ax=St(Rx),Mx=g({},wi,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Lf=St(Mx),zx=g({},ys,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:yr}),_x=St(zx),wx=g({},Ma,{propertyName:0,elapsedTime:0,pseudoElement:0}),Dx=St(wx),Ux=g({},wi,{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}),Hx=St(Ux),qx=g({},Ma,{newState:0,oldState:0}),Bx=St(qx),Lx=[9,13,27,32],gr=gl&&"CompositionEvent"in window,bs=null;gl&&"documentMode"in document&&(bs=document.documentMode);var kx=gl&&"TextEvent"in window&&!bs,kf=gl&&(!gr||bs&&8<bs&&11>=bs),Qf=" ",Yf=!1;function Gf(e,t){switch(e){case"keyup":return Lx.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Xf(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var pn=!1;function Qx(e,t){switch(e){case"compositionend":return Xf(t);case"keypress":return t.which!==32?null:(Yf=!0,Qf);case"textInput":return e=t.data,e===Qf&&Yf?null:e;default:return null}}function Yx(e,t){if(pn)return e==="compositionend"||!gr&&Gf(e,t)?(e=Uf(),Ai=mr=Kl=null,pn=!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 kf&&t.locale!=="ko"?null:t.data;default:return null}}var Gx={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 Kf(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!Gx[e.type]:t==="textarea"}function Vf(e,t,l,a){hn?mn?mn.push(a):mn=[a]:hn=a,t=ju(t,"onChange"),0<t.length&&(l=new _i("onChange","change",null,l,a),e.push({event:l,listeners:t}))}var Ss=null,js=null;function Xx(e){Rm(e,0)}function Di(e){var t=ps(e);if(Of(t))return e}function Zf(e,t){if(e==="change")return t}var Jf=!1;if(gl){var br;if(gl){var Sr="oninput"in document;if(!Sr){var $f=document.createElement("div");$f.setAttribute("oninput","return;"),Sr=typeof $f.oninput=="function"}br=Sr}else br=!1;Jf=br&&(!document.documentMode||9<document.documentMode)}function Ff(){Ss&&(Ss.detachEvent("onpropertychange",Wf),js=Ss=null)}function Wf(e){if(e.propertyName==="value"&&Di(js)){var t=[];Vf(t,js,e,fr(e)),Df(Xx,t)}}function Kx(e,t,l){e==="focusin"?(Ff(),Ss=t,js=l,Ss.attachEvent("onpropertychange",Wf)):e==="focusout"&&Ff()}function Vx(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Di(js)}function Zx(e,t){if(e==="click")return Di(t)}function Jx(e,t){if(e==="input"||e==="change")return Di(t)}function $x(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var _t=typeof Object.is=="function"?Object.is:$x;function Ns(e,t){if(_t(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var l=Object.keys(e),a=Object.keys(t);if(l.length!==a.length)return!1;for(a=0;a<l.length;a++){var s=l[a];if(!Iu.call(t,s)||!_t(e[s],t[s]))return!1}return!0}function If(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Pf(e,t){var l=If(e);e=0;for(var a;l;){if(l.nodeType===3){if(a=e+l.textContent.length,e<=t&&a>=t)return{node:l,offset:t-e};e=a}e:{for(;l;){if(l.nextSibling){l=l.nextSibling;break e}l=l.parentNode}l=void 0}l=If(l)}}function ed(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?ed(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function td(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Oi(e.document);t instanceof e.HTMLIFrameElement;){try{var l=typeof t.contentWindow.location.href=="string"}catch{l=!1}if(l)e=t.contentWindow;else break;t=Oi(e.document)}return t}function jr(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")}var Fx=gl&&"documentMode"in document&&11>=document.documentMode,vn=null,Nr=null,Es=null,Er=!1;function ld(e,t,l){var a=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;Er||vn==null||vn!==Oi(a)||(a=vn,"selectionStart"in a&&jr(a)?a={start:a.selectionStart,end:a.selectionEnd}:(a=(a.ownerDocument&&a.ownerDocument.defaultView||window).getSelection(),a={anchorNode:a.anchorNode,anchorOffset:a.anchorOffset,focusNode:a.focusNode,focusOffset:a.focusOffset}),Es&&Ns(Es,a)||(Es=a,a=ju(Nr,"onSelect"),0<a.length&&(t=new _i("onSelect","select",null,t,l),e.push({event:t,listeners:a}),t.target=vn)))}function za(e,t){var l={};return l[e.toLowerCase()]=t.toLowerCase(),l["Webkit"+e]="webkit"+t,l["Moz"+e]="moz"+t,l}var xn={animationend:za("Animation","AnimationEnd"),animationiteration:za("Animation","AnimationIteration"),animationstart:za("Animation","AnimationStart"),transitionrun:za("Transition","TransitionRun"),transitionstart:za("Transition","TransitionStart"),transitioncancel:za("Transition","TransitionCancel"),transitionend:za("Transition","TransitionEnd")},Cr={},ad={};gl&&(ad=document.createElement("div").style,"AnimationEvent"in window||(delete xn.animationend.animation,delete xn.animationiteration.animation,delete xn.animationstart.animation),"TransitionEvent"in window||delete xn.transitionend.transition);function _a(e){if(Cr[e])return Cr[e];if(!xn[e])return e;var t=xn[e],l;for(l in t)if(t.hasOwnProperty(l)&&l in ad)return Cr[e]=t[l];return e}var nd=_a("animationend"),sd=_a("animationiteration"),id=_a("animationstart"),Wx=_a("transitionrun"),Ix=_a("transitionstart"),Px=_a("transitioncancel"),ud=_a("transitionend"),rd=new Map,Tr="abort auxClick beforeToggle 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(" ");Tr.push("scrollEnd");function ll(e,t){rd.set(e,t),Aa(t,[e])}var Ui=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)},Kt=[],yn=0,Or=0;function Hi(){for(var e=yn,t=Or=yn=0;t<e;){var l=Kt[t];Kt[t++]=null;var a=Kt[t];Kt[t++]=null;var s=Kt[t];Kt[t++]=null;var u=Kt[t];if(Kt[t++]=null,a!==null&&s!==null){var f=a.pending;f===null?s.next=s:(s.next=f.next,f.next=s),a.pending=s}u!==0&&cd(l,s,u)}}function qi(e,t,l,a){Kt[yn++]=e,Kt[yn++]=t,Kt[yn++]=l,Kt[yn++]=a,Or|=a,e.lanes|=a,e=e.alternate,e!==null&&(e.lanes|=a)}function Rr(e,t,l,a){return qi(e,t,l,a),Bi(e)}function wa(e,t){return qi(e,null,null,t),Bi(e)}function cd(e,t,l){e.lanes|=l;var a=e.alternate;a!==null&&(a.lanes|=l);for(var s=!1,u=e.return;u!==null;)u.childLanes|=l,a=u.alternate,a!==null&&(a.childLanes|=l),u.tag===22&&(e=u.stateNode,e===null||e._visibility&1||(s=!0)),e=u,u=u.return;return e.tag===3?(u=e.stateNode,s&&t!==null&&(s=31-zt(l),e=u.hiddenUpdates,a=e[s],a===null?e[s]=[t]:a.push(t),t.lane=l|536870912),u):null}function Bi(e){if(50<Vs)throw Vs=0,qc=null,Error(o(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var gn={};function ey(e,t,l,a){this.tag=e,this.key=l,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=a,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function wt(e,t,l,a){return new ey(e,t,l,a)}function Ar(e){return e=e.prototype,!(!e||!e.isReactComponent)}function bl(e,t){var l=e.alternate;return l===null?(l=wt(e.tag,t,e.key,e.mode),l.elementType=e.elementType,l.type=e.type,l.stateNode=e.stateNode,l.alternate=e,e.alternate=l):(l.pendingProps=t,l.type=e.type,l.flags=0,l.subtreeFlags=0,l.deletions=null),l.flags=e.flags&65011712,l.childLanes=e.childLanes,l.lanes=e.lanes,l.child=e.child,l.memoizedProps=e.memoizedProps,l.memoizedState=e.memoizedState,l.updateQueue=e.updateQueue,t=e.dependencies,l.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},l.sibling=e.sibling,l.index=e.index,l.ref=e.ref,l.refCleanup=e.refCleanup,l}function od(e,t){e.flags&=65011714;var l=e.alternate;return l===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=l.childLanes,e.lanes=l.lanes,e.child=l.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=l.memoizedProps,e.memoizedState=l.memoizedState,e.updateQueue=l.updateQueue,e.type=l.type,t=l.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function Li(e,t,l,a,s,u){var f=0;if(a=e,typeof e=="function")Ar(e)&&(f=1);else if(typeof e=="string")f=s0(e,l,ee.current)?26:e==="html"||e==="head"||e==="body"?27:5;else e:switch(e){case G:return e=wt(31,l,t,s),e.elementType=G,e.lanes=u,e;case H:return Da(l.children,s,u,t);case U:f=8,s|=24;break;case V:return e=wt(12,l,t,s|2),e.elementType=V,e.lanes=u,e;case R:return e=wt(13,l,t,s),e.elementType=R,e.lanes=u,e;case P:return e=wt(19,l,t,s),e.elementType=P,e.lanes=u,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case M:f=10;break e;case $:f=9;break e;case Y:f=11;break e;case q:f=14;break e;case Z:f=16,a=null;break e}f=29,l=Error(o(130,e===null?"null":typeof e,"")),a=null}return t=wt(f,l,t,s),t.elementType=e,t.type=a,t.lanes=u,t}function Da(e,t,l,a){return e=wt(7,e,a,t),e.lanes=l,e}function Mr(e,t,l){return e=wt(6,e,null,t),e.lanes=l,e}function fd(e){var t=wt(18,null,null,0);return t.stateNode=e,t}function zr(e,t,l){return t=wt(4,e.children!==null?e.children:[],e.key,t),t.lanes=l,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var dd=new WeakMap;function Vt(e,t){if(typeof e=="object"&&e!==null){var l=dd.get(e);return l!==void 0?l:(t={value:e,source:t,stack:ff(t)},dd.set(e,t),t)}return{value:e,source:t,stack:ff(t)}}var bn=[],Sn=0,ki=null,Cs=0,Zt=[],Jt=0,Vl=null,rl=1,cl="";function Sl(e,t){bn[Sn++]=Cs,bn[Sn++]=ki,ki=e,Cs=t}function hd(e,t,l){Zt[Jt++]=rl,Zt[Jt++]=cl,Zt[Jt++]=Vl,Vl=e;var a=rl;e=cl;var s=32-zt(a)-1;a&=~(1<<s),l+=1;var u=32-zt(t)+s;if(30<u){var f=s-s%5;u=(a&(1<<f)-1).toString(32),a>>=f,s-=f,rl=1<<32-zt(t)+s|l<<s|a,cl=u+e}else rl=1<<u|l<<s|a,cl=e}function _r(e){e.return!==null&&(Sl(e,1),hd(e,1,0))}function wr(e){for(;e===ki;)ki=bn[--Sn],bn[Sn]=null,Cs=bn[--Sn],bn[Sn]=null;for(;e===Vl;)Vl=Zt[--Jt],Zt[Jt]=null,cl=Zt[--Jt],Zt[Jt]=null,rl=Zt[--Jt],Zt[Jt]=null}function md(e,t){Zt[Jt++]=rl,Zt[Jt++]=cl,Zt[Jt++]=Vl,rl=t.id,cl=t.overflow,Vl=e}var ut=null,qe=null,Se=!1,Zl=null,$t=!1,Dr=Error(o(519));function Jl(e){var t=Error(o(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw Ts(Vt(t,e)),Dr}function pd(e){var t=e.stateNode,l=e.type,a=e.memoizedProps;switch(t[it]=e,t[bt]=a,l){case"dialog":ye("cancel",t),ye("close",t);break;case"iframe":case"object":case"embed":ye("load",t);break;case"video":case"audio":for(l=0;l<Js.length;l++)ye(Js[l],t);break;case"source":ye("error",t);break;case"img":case"image":case"link":ye("error",t),ye("load",t);break;case"details":ye("toggle",t);break;case"input":ye("invalid",t),Rf(t,a.value,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name,!0);break;case"select":ye("invalid",t);break;case"textarea":ye("invalid",t),Mf(t,a.value,a.defaultValue,a.children)}l=a.children,typeof l!="string"&&typeof l!="number"&&typeof l!="bigint"||t.textContent===""+l||a.suppressHydrationWarning===!0||_m(t.textContent,l)?(a.popover!=null&&(ye("beforetoggle",t),ye("toggle",t)),a.onScroll!=null&&ye("scroll",t),a.onScrollEnd!=null&&ye("scrollend",t),a.onClick!=null&&(t.onclick=yl),t=!0):t=!1,t||Jl(e,!0)}function vd(e){for(ut=e.return;ut;)switch(ut.tag){case 5:case 31:case 13:$t=!1;return;case 27:case 3:$t=!0;return;default:ut=ut.return}}function jn(e){if(e!==ut)return!1;if(!Se)return vd(e),Se=!0,!1;var t=e.tag,l;if((l=t!==3&&t!==27)&&((l=t===5)&&(l=e.type,l=!(l!=="form"&&l!=="button")||Ic(e.type,e.memoizedProps)),l=!l),l&&qe&&Jl(e),vd(e),t===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(o(317));qe=Qm(e)}else if(t===31){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(o(317));qe=Qm(e)}else t===27?(t=qe,ra(e.type)?(e=ao,ao=null,qe=e):qe=t):qe=ut?Wt(e.stateNode.nextSibling):null;return!0}function Ua(){qe=ut=null,Se=!1}function Ur(){var e=Zl;return e!==null&&(Ct===null?Ct=e:Ct.push.apply(Ct,e),Zl=null),e}function Ts(e){Zl===null?Zl=[e]:Zl.push(e)}var Hr=C(null),Ha=null,jl=null;function $l(e,t,l){J(Hr,t._currentValue),t._currentValue=l}function Nl(e){e._currentValue=Hr.current,X(Hr)}function qr(e,t,l){for(;e!==null;){var a=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,a!==null&&(a.childLanes|=t)):a!==null&&(a.childLanes&t)!==t&&(a.childLanes|=t),e===l)break;e=e.return}}function Br(e,t,l,a){var s=e.child;for(s!==null&&(s.return=e);s!==null;){var u=s.dependencies;if(u!==null){var f=s.child;u=u.firstContext;e:for(;u!==null;){var m=u;u=s;for(var j=0;j<t.length;j++)if(m.context===t[j]){u.lanes|=l,m=u.alternate,m!==null&&(m.lanes|=l),qr(u.return,l,e),a||(f=null);break e}u=m.next}}else if(s.tag===18){if(f=s.return,f===null)throw Error(o(341));f.lanes|=l,u=f.alternate,u!==null&&(u.lanes|=l),qr(f,l,e),f=null}else f=s.child;if(f!==null)f.return=s;else for(f=s;f!==null;){if(f===e){f=null;break}if(s=f.sibling,s!==null){s.return=f.return,f=s;break}f=f.return}s=f}}function Nn(e,t,l,a){e=null;for(var s=t,u=!1;s!==null;){if(!u){if((s.flags&524288)!==0)u=!0;else if((s.flags&262144)!==0)break}if(s.tag===10){var f=s.alternate;if(f===null)throw Error(o(387));if(f=f.memoizedProps,f!==null){var m=s.type;_t(s.pendingProps.value,f.value)||(e!==null?e.push(m):e=[m])}}else if(s===Ne.current){if(f=s.alternate,f===null)throw Error(o(387));f.memoizedState.memoizedState!==s.memoizedState.memoizedState&&(e!==null?e.push(Ps):e=[Ps])}s=s.return}e!==null&&Br(t,e,l,a),t.flags|=262144}function Qi(e){for(e=e.firstContext;e!==null;){if(!_t(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function qa(e){Ha=e,jl=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function rt(e){return xd(Ha,e)}function Yi(e,t){return Ha===null&&qa(e),xd(e,t)}function xd(e,t){var l=t._currentValue;if(t={context:t,memoizedValue:l,next:null},jl===null){if(e===null)throw Error(o(308));jl=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else jl=jl.next=t;return l}var ty=typeof AbortController<"u"?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(l,a){e.push(a)}};this.abort=function(){t.aborted=!0,e.forEach(function(l){return l()})}},ly=n.unstable_scheduleCallback,ay=n.unstable_NormalPriority,Je={$$typeof:M,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function Lr(){return{controller:new ty,data:new Map,refCount:0}}function Os(e){e.refCount--,e.refCount===0&&ly(ay,function(){e.controller.abort()})}var Rs=null,kr=0,En=0,Cn=null;function ny(e,t){if(Rs===null){var l=Rs=[];kr=0,En=Gc(),Cn={status:"pending",value:void 0,then:function(a){l.push(a)}}}return kr++,t.then(yd,yd),t}function yd(){if(--kr===0&&Rs!==null){Cn!==null&&(Cn.status="fulfilled");var e=Rs;Rs=null,En=0,Cn=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function sy(e,t){var l=[],a={status:"pending",value:null,reason:null,then:function(s){l.push(s)}};return e.then(function(){a.status="fulfilled",a.value=t;for(var s=0;s<l.length;s++)(0,l[s])(t)},function(s){for(a.status="rejected",a.reason=s,s=0;s<l.length;s++)(0,l[s])(void 0)}),a}var gd=L.S;L.S=function(e,t){lm=At(),typeof t=="object"&&t!==null&&typeof t.then=="function"&&ny(e,t),gd!==null&&gd(e,t)};var Ba=C(null);function Qr(){var e=Ba.current;return e!==null?e:Ue.pooledCache}function Gi(e,t){t===null?J(Ba,Ba.current):J(Ba,t.pool)}function bd(){var e=Qr();return e===null?null:{parent:Je._currentValue,pool:e}}var Tn=Error(o(460)),Yr=Error(o(474)),Xi=Error(o(542)),Ki={then:function(){}};function Sd(e){return e=e.status,e==="fulfilled"||e==="rejected"}function jd(e,t,l){switch(l=e[l],l===void 0?e.push(t):l!==t&&(t.then(yl,yl),t=l),t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,Ed(e),e;default:if(typeof t.status=="string")t.then(yl,yl);else{if(e=Ue,e!==null&&100<e.shellSuspendCounter)throw Error(o(482));e=t,e.status="pending",e.then(function(a){if(t.status==="pending"){var s=t;s.status="fulfilled",s.value=a}},function(a){if(t.status==="pending"){var s=t;s.status="rejected",s.reason=a}})}switch(t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,Ed(e),e}throw ka=t,Tn}}function La(e){try{var t=e._init;return t(e._payload)}catch(l){throw l!==null&&typeof l=="object"&&typeof l.then=="function"?(ka=l,Tn):l}}var ka=null;function Nd(){if(ka===null)throw Error(o(459));var e=ka;return ka=null,e}function Ed(e){if(e===Tn||e===Xi)throw Error(o(483))}var On=null,As=0;function Vi(e){var t=As;return As+=1,On===null&&(On=[]),jd(On,e,t)}function Ms(e,t){t=t.props.ref,e.ref=t!==void 0?t:null}function Zi(e,t){throw t.$$typeof===A?Error(o(525)):(e=Object.prototype.toString.call(t),Error(o(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e)))}function Cd(e){function t(T,E){if(e){var z=T.deletions;z===null?(T.deletions=[E],T.flags|=16):z.push(E)}}function l(T,E){if(!e)return null;for(;E!==null;)t(T,E),E=E.sibling;return null}function a(T){for(var E=new Map;T!==null;)T.key!==null?E.set(T.key,T):E.set(T.index,T),T=T.sibling;return E}function s(T,E){return T=bl(T,E),T.index=0,T.sibling=null,T}function u(T,E,z){return T.index=z,e?(z=T.alternate,z!==null?(z=z.index,z<E?(T.flags|=67108866,E):z):(T.flags|=67108866,E)):(T.flags|=1048576,E)}function f(T){return e&&T.alternate===null&&(T.flags|=67108866),T}function m(T,E,z,Q){return E===null||E.tag!==6?(E=Mr(z,T.mode,Q),E.return=T,E):(E=s(E,z),E.return=T,E)}function j(T,E,z,Q){var se=z.type;return se===H?B(T,E,z.props.children,Q,z.key):E!==null&&(E.elementType===se||typeof se=="object"&&se!==null&&se.$$typeof===Z&&La(se)===E.type)?(E=s(E,z.props),Ms(E,z),E.return=T,E):(E=Li(z.type,z.key,z.props,null,T.mode,Q),Ms(E,z),E.return=T,E)}function _(T,E,z,Q){return E===null||E.tag!==4||E.stateNode.containerInfo!==z.containerInfo||E.stateNode.implementation!==z.implementation?(E=zr(z,T.mode,Q),E.return=T,E):(E=s(E,z.children||[]),E.return=T,E)}function B(T,E,z,Q,se){return E===null||E.tag!==7?(E=Da(z,T.mode,Q,se),E.return=T,E):(E=s(E,z),E.return=T,E)}function K(T,E,z){if(typeof E=="string"&&E!==""||typeof E=="number"||typeof E=="bigint")return E=Mr(""+E,T.mode,z),E.return=T,E;if(typeof E=="object"&&E!==null){switch(E.$$typeof){case O:return z=Li(E.type,E.key,E.props,null,T.mode,z),Ms(z,E),z.return=T,z;case k:return E=zr(E,T.mode,z),E.return=T,E;case Z:return E=La(E),K(T,E,z)}if(tt(E)||He(E))return E=Da(E,T.mode,z,null),E.return=T,E;if(typeof E.then=="function")return K(T,Vi(E),z);if(E.$$typeof===M)return K(T,Yi(T,E),z);Zi(T,E)}return null}function w(T,E,z,Q){var se=E!==null?E.key:null;if(typeof z=="string"&&z!==""||typeof z=="number"||typeof z=="bigint")return se!==null?null:m(T,E,""+z,Q);if(typeof z=="object"&&z!==null){switch(z.$$typeof){case O:return z.key===se?j(T,E,z,Q):null;case k:return z.key===se?_(T,E,z,Q):null;case Z:return z=La(z),w(T,E,z,Q)}if(tt(z)||He(z))return se!==null?null:B(T,E,z,Q,null);if(typeof z.then=="function")return w(T,E,Vi(z),Q);if(z.$$typeof===M)return w(T,E,Yi(T,z),Q);Zi(T,z)}return null}function D(T,E,z,Q,se){if(typeof Q=="string"&&Q!==""||typeof Q=="number"||typeof Q=="bigint")return T=T.get(z)||null,m(E,T,""+Q,se);if(typeof Q=="object"&&Q!==null){switch(Q.$$typeof){case O:return T=T.get(Q.key===null?z:Q.key)||null,j(E,T,Q,se);case k:return T=T.get(Q.key===null?z:Q.key)||null,_(E,T,Q,se);case Z:return Q=La(Q),D(T,E,z,Q,se)}if(tt(Q)||He(Q))return T=T.get(z)||null,B(E,T,Q,se,null);if(typeof Q.then=="function")return D(T,E,z,Vi(Q),se);if(Q.$$typeof===M)return D(T,E,z,Yi(E,Q),se);Zi(E,Q)}return null}function te(T,E,z,Q){for(var se=null,Ee=null,le=E,de=E=0,be=null;le!==null&&de<z.length;de++){le.index>de?(be=le,le=null):be=le.sibling;var Ce=w(T,le,z[de],Q);if(Ce===null){le===null&&(le=be);break}e&&le&&Ce.alternate===null&&t(T,le),E=u(Ce,E,de),Ee===null?se=Ce:Ee.sibling=Ce,Ee=Ce,le=be}if(de===z.length)return l(T,le),Se&&Sl(T,de),se;if(le===null){for(;de<z.length;de++)le=K(T,z[de],Q),le!==null&&(E=u(le,E,de),Ee===null?se=le:Ee.sibling=le,Ee=le);return Se&&Sl(T,de),se}for(le=a(le);de<z.length;de++)be=D(le,T,de,z[de],Q),be!==null&&(e&&be.alternate!==null&&le.delete(be.key===null?de:be.key),E=u(be,E,de),Ee===null?se=be:Ee.sibling=be,Ee=be);return e&&le.forEach(function(ha){return t(T,ha)}),Se&&Sl(T,de),se}function ie(T,E,z,Q){if(z==null)throw Error(o(151));for(var se=null,Ee=null,le=E,de=E=0,be=null,Ce=z.next();le!==null&&!Ce.done;de++,Ce=z.next()){le.index>de?(be=le,le=null):be=le.sibling;var ha=w(T,le,Ce.value,Q);if(ha===null){le===null&&(le=be);break}e&&le&&ha.alternate===null&&t(T,le),E=u(ha,E,de),Ee===null?se=ha:Ee.sibling=ha,Ee=ha,le=be}if(Ce.done)return l(T,le),Se&&Sl(T,de),se;if(le===null){for(;!Ce.done;de++,Ce=z.next())Ce=K(T,Ce.value,Q),Ce!==null&&(E=u(Ce,E,de),Ee===null?se=Ce:Ee.sibling=Ce,Ee=Ce);return Se&&Sl(T,de),se}for(le=a(le);!Ce.done;de++,Ce=z.next())Ce=D(le,T,de,Ce.value,Q),Ce!==null&&(e&&Ce.alternate!==null&&le.delete(Ce.key===null?de:Ce.key),E=u(Ce,E,de),Ee===null?se=Ce:Ee.sibling=Ce,Ee=Ce);return e&&le.forEach(function(v0){return t(T,v0)}),Se&&Sl(T,de),se}function we(T,E,z,Q){if(typeof z=="object"&&z!==null&&z.type===H&&z.key===null&&(z=z.props.children),typeof z=="object"&&z!==null){switch(z.$$typeof){case O:e:{for(var se=z.key;E!==null;){if(E.key===se){if(se=z.type,se===H){if(E.tag===7){l(T,E.sibling),Q=s(E,z.props.children),Q.return=T,T=Q;break e}}else if(E.elementType===se||typeof se=="object"&&se!==null&&se.$$typeof===Z&&La(se)===E.type){l(T,E.sibling),Q=s(E,z.props),Ms(Q,z),Q.return=T,T=Q;break e}l(T,E);break}else t(T,E);E=E.sibling}z.type===H?(Q=Da(z.props.children,T.mode,Q,z.key),Q.return=T,T=Q):(Q=Li(z.type,z.key,z.props,null,T.mode,Q),Ms(Q,z),Q.return=T,T=Q)}return f(T);case k:e:{for(se=z.key;E!==null;){if(E.key===se)if(E.tag===4&&E.stateNode.containerInfo===z.containerInfo&&E.stateNode.implementation===z.implementation){l(T,E.sibling),Q=s(E,z.children||[]),Q.return=T,T=Q;break e}else{l(T,E);break}else t(T,E);E=E.sibling}Q=zr(z,T.mode,Q),Q.return=T,T=Q}return f(T);case Z:return z=La(z),we(T,E,z,Q)}if(tt(z))return te(T,E,z,Q);if(He(z)){if(se=He(z),typeof se!="function")throw Error(o(150));return z=se.call(z),ie(T,E,z,Q)}if(typeof z.then=="function")return we(T,E,Vi(z),Q);if(z.$$typeof===M)return we(T,E,Yi(T,z),Q);Zi(T,z)}return typeof z=="string"&&z!==""||typeof z=="number"||typeof z=="bigint"?(z=""+z,E!==null&&E.tag===6?(l(T,E.sibling),Q=s(E,z),Q.return=T,T=Q):(l(T,E),Q=Mr(z,T.mode,Q),Q.return=T,T=Q),f(T)):l(T,E)}return function(T,E,z,Q){try{As=0;var se=we(T,E,z,Q);return On=null,se}catch(le){if(le===Tn||le===Xi)throw le;var Ee=wt(29,le,null,T.mode);return Ee.lanes=Q,Ee.return=T,Ee}finally{}}}var Qa=Cd(!0),Td=Cd(!1),Fl=!1;function Gr(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Xr(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function Wl(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Il(e,t,l){var a=e.updateQueue;if(a===null)return null;if(a=a.shared,(Te&2)!==0){var s=a.pending;return s===null?t.next=t:(t.next=s.next,s.next=t),a.pending=t,t=Bi(e),cd(e,null,l),t}return qi(e,a,t,l),Bi(e)}function zs(e,t,l){if(t=t.updateQueue,t!==null&&(t=t.shared,(l&4194048)!==0)){var a=t.lanes;a&=e.pendingLanes,l|=a,t.lanes=l,xf(e,l)}}function Kr(e,t){var l=e.updateQueue,a=e.alternate;if(a!==null&&(a=a.updateQueue,l===a)){var s=null,u=null;if(l=l.firstBaseUpdate,l!==null){do{var f={lane:l.lane,tag:l.tag,payload:l.payload,callback:null,next:null};u===null?s=u=f:u=u.next=f,l=l.next}while(l!==null);u===null?s=u=t:u=u.next=t}else s=u=t;l={baseState:a.baseState,firstBaseUpdate:s,lastBaseUpdate:u,shared:a.shared,callbacks:a.callbacks},e.updateQueue=l;return}e=l.lastBaseUpdate,e===null?l.firstBaseUpdate=t:e.next=t,l.lastBaseUpdate=t}var Vr=!1;function _s(){if(Vr){var e=Cn;if(e!==null)throw e}}function ws(e,t,l,a){Vr=!1;var s=e.updateQueue;Fl=!1;var u=s.firstBaseUpdate,f=s.lastBaseUpdate,m=s.shared.pending;if(m!==null){s.shared.pending=null;var j=m,_=j.next;j.next=null,f===null?u=_:f.next=_,f=j;var B=e.alternate;B!==null&&(B=B.updateQueue,m=B.lastBaseUpdate,m!==f&&(m===null?B.firstBaseUpdate=_:m.next=_,B.lastBaseUpdate=j))}if(u!==null){var K=s.baseState;f=0,B=_=j=null,m=u;do{var w=m.lane&-536870913,D=w!==m.lane;if(D?(ge&w)===w:(a&w)===w){w!==0&&w===En&&(Vr=!0),B!==null&&(B=B.next={lane:0,tag:m.tag,payload:m.payload,callback:null,next:null});e:{var te=e,ie=m;w=t;var we=l;switch(ie.tag){case 1:if(te=ie.payload,typeof te=="function"){K=te.call(we,K,w);break e}K=te;break e;case 3:te.flags=te.flags&-65537|128;case 0:if(te=ie.payload,w=typeof te=="function"?te.call(we,K,w):te,w==null)break e;K=g({},K,w);break e;case 2:Fl=!0}}w=m.callback,w!==null&&(e.flags|=64,D&&(e.flags|=8192),D=s.callbacks,D===null?s.callbacks=[w]:D.push(w))}else D={lane:w,tag:m.tag,payload:m.payload,callback:m.callback,next:null},B===null?(_=B=D,j=K):B=B.next=D,f|=w;if(m=m.next,m===null){if(m=s.shared.pending,m===null)break;D=m,m=D.next,D.next=null,s.lastBaseUpdate=D,s.shared.pending=null}}while(!0);B===null&&(j=K),s.baseState=j,s.firstBaseUpdate=_,s.lastBaseUpdate=B,u===null&&(s.shared.lanes=0),aa|=f,e.lanes=f,e.memoizedState=K}}function Od(e,t){if(typeof e!="function")throw Error(o(191,e));e.call(t)}function Rd(e,t){var l=e.callbacks;if(l!==null)for(e.callbacks=null,e=0;e<l.length;e++)Od(l[e],t)}var Rn=C(null),Ji=C(0);function Ad(e,t){e=_l,J(Ji,e),J(Rn,t),_l=e|t.baseLanes}function Zr(){J(Ji,_l),J(Rn,Rn.current)}function Jr(){_l=Ji.current,X(Rn),X(Ji)}var Dt=C(null),Ft=null;function Pl(e){var t=e.alternate;J(Ve,Ve.current&1),J(Dt,e),Ft===null&&(t===null||Rn.current!==null||t.memoizedState!==null)&&(Ft=e)}function $r(e){J(Ve,Ve.current),J(Dt,e),Ft===null&&(Ft=e)}function Md(e){e.tag===22?(J(Ve,Ve.current),J(Dt,e),Ft===null&&(Ft=e)):ea()}function ea(){J(Ve,Ve.current),J(Dt,Dt.current)}function Ut(e){X(Dt),Ft===e&&(Ft=null),X(Ve)}var Ve=C(0);function $i(e){for(var t=e;t!==null;){if(t.tag===13){var l=t.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||to(l)||lo(l)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder==="forwards"||t.memoizedProps.revealOrder==="backwards"||t.memoizedProps.revealOrder==="unstable_legacy-backwards"||t.memoizedProps.revealOrder==="together")){if((t.flags&128)!==0)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 El=0,fe=null,ze=null,$e=null,Fi=!1,An=!1,Ya=!1,Wi=0,Ds=0,Mn=null,iy=0;function Qe(){throw Error(o(321))}function Fr(e,t){if(t===null)return!1;for(var l=0;l<t.length&&l<e.length;l++)if(!_t(e[l],t[l]))return!1;return!0}function Wr(e,t,l,a,s,u){return El=u,fe=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,L.H=e===null||e.memoizedState===null?hh:dc,Ya=!1,u=l(a,s),Ya=!1,An&&(u=_d(t,l,a,s)),zd(e),u}function zd(e){L.H=qs;var t=ze!==null&&ze.next!==null;if(El=0,$e=ze=fe=null,Fi=!1,Ds=0,Mn=null,t)throw Error(o(300));e===null||Fe||(e=e.dependencies,e!==null&&Qi(e)&&(Fe=!0))}function _d(e,t,l,a){fe=e;var s=0;do{if(An&&(Mn=null),Ds=0,An=!1,25<=s)throw Error(o(301));if(s+=1,$e=ze=null,e.updateQueue!=null){var u=e.updateQueue;u.lastEffect=null,u.events=null,u.stores=null,u.memoCache!=null&&(u.memoCache.index=0)}L.H=mh,u=t(l,a)}while(An);return u}function uy(){var e=L.H,t=e.useState()[0];return t=typeof t.then=="function"?Us(t):t,e=e.useState()[0],(ze!==null?ze.memoizedState:null)!==e&&(fe.flags|=1024),t}function Ir(){var e=Wi!==0;return Wi=0,e}function Pr(e,t,l){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~l}function ec(e){if(Fi){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}Fi=!1}El=0,$e=ze=fe=null,An=!1,Ds=Wi=0,Mn=null}function vt(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return $e===null?fe.memoizedState=$e=e:$e=$e.next=e,$e}function Ze(){if(ze===null){var e=fe.alternate;e=e!==null?e.memoizedState:null}else e=ze.next;var t=$e===null?fe.memoizedState:$e.next;if(t!==null)$e=t,ze=e;else{if(e===null)throw fe.alternate===null?Error(o(467)):Error(o(310));ze=e,e={memoizedState:ze.memoizedState,baseState:ze.baseState,baseQueue:ze.baseQueue,queue:ze.queue,next:null},$e===null?fe.memoizedState=$e=e:$e=$e.next=e}return $e}function Ii(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Us(e){var t=Ds;return Ds+=1,Mn===null&&(Mn=[]),e=jd(Mn,e,t),t=fe,($e===null?t.memoizedState:$e.next)===null&&(t=t.alternate,L.H=t===null||t.memoizedState===null?hh:dc),e}function Pi(e){if(e!==null&&typeof e=="object"){if(typeof e.then=="function")return Us(e);if(e.$$typeof===M)return rt(e)}throw Error(o(438,String(e)))}function tc(e){var t=null,l=fe.updateQueue;if(l!==null&&(t=l.memoCache),t==null){var a=fe.alternate;a!==null&&(a=a.updateQueue,a!==null&&(a=a.memoCache,a!=null&&(t={data:a.data.map(function(s){return s.slice()}),index:0})))}if(t==null&&(t={data:[],index:0}),l===null&&(l=Ii(),fe.updateQueue=l),l.memoCache=t,l=t.data[t.index],l===void 0)for(l=t.data[t.index]=Array(e),a=0;a<e;a++)l[a]=W;return t.index++,l}function Cl(e,t){return typeof t=="function"?t(e):t}function eu(e){var t=Ze();return lc(t,ze,e)}function lc(e,t,l){var a=e.queue;if(a===null)throw Error(o(311));a.lastRenderedReducer=l;var s=e.baseQueue,u=a.pending;if(u!==null){if(s!==null){var f=s.next;s.next=u.next,u.next=f}t.baseQueue=s=u,a.pending=null}if(u=e.baseState,s===null)e.memoizedState=u;else{t=s.next;var m=f=null,j=null,_=t,B=!1;do{var K=_.lane&-536870913;if(K!==_.lane?(ge&K)===K:(El&K)===K){var w=_.revertLane;if(w===0)j!==null&&(j=j.next={lane:0,revertLane:0,gesture:null,action:_.action,hasEagerState:_.hasEagerState,eagerState:_.eagerState,next:null}),K===En&&(B=!0);else if((El&w)===w){_=_.next,w===En&&(B=!0);continue}else K={lane:0,revertLane:_.revertLane,gesture:null,action:_.action,hasEagerState:_.hasEagerState,eagerState:_.eagerState,next:null},j===null?(m=j=K,f=u):j=j.next=K,fe.lanes|=w,aa|=w;K=_.action,Ya&&l(u,K),u=_.hasEagerState?_.eagerState:l(u,K)}else w={lane:K,revertLane:_.revertLane,gesture:_.gesture,action:_.action,hasEagerState:_.hasEagerState,eagerState:_.eagerState,next:null},j===null?(m=j=w,f=u):j=j.next=w,fe.lanes|=K,aa|=K;_=_.next}while(_!==null&&_!==t);if(j===null?f=u:j.next=m,!_t(u,e.memoizedState)&&(Fe=!0,B&&(l=Cn,l!==null)))throw l;e.memoizedState=u,e.baseState=f,e.baseQueue=j,a.lastRenderedState=u}return s===null&&(a.lanes=0),[e.memoizedState,a.dispatch]}function ac(e){var t=Ze(),l=t.queue;if(l===null)throw Error(o(311));l.lastRenderedReducer=e;var a=l.dispatch,s=l.pending,u=t.memoizedState;if(s!==null){l.pending=null;var f=s=s.next;do u=e(u,f.action),f=f.next;while(f!==s);_t(u,t.memoizedState)||(Fe=!0),t.memoizedState=u,t.baseQueue===null&&(t.baseState=u),l.lastRenderedState=u}return[u,a]}function wd(e,t,l){var a=fe,s=Ze(),u=Se;if(u){if(l===void 0)throw Error(o(407));l=l()}else l=t();var f=!_t((ze||s).memoizedState,l);if(f&&(s.memoizedState=l,Fe=!0),s=s.queue,ic(Hd.bind(null,a,s,e),[e]),s.getSnapshot!==t||f||$e!==null&&$e.memoizedState.tag&1){if(a.flags|=2048,zn(9,{destroy:void 0},Ud.bind(null,a,s,l,t),null),Ue===null)throw Error(o(349));u||(El&127)!==0||Dd(a,t,l)}return l}function Dd(e,t,l){e.flags|=16384,e={getSnapshot:t,value:l},t=fe.updateQueue,t===null?(t=Ii(),fe.updateQueue=t,t.stores=[e]):(l=t.stores,l===null?t.stores=[e]:l.push(e))}function Ud(e,t,l,a){t.value=l,t.getSnapshot=a,qd(t)&&Bd(e)}function Hd(e,t,l){return l(function(){qd(t)&&Bd(e)})}function qd(e){var t=e.getSnapshot;e=e.value;try{var l=t();return!_t(e,l)}catch{return!0}}function Bd(e){var t=wa(e,2);t!==null&&Tt(t,e,2)}function nc(e){var t=vt();if(typeof e=="function"){var l=e;if(e=l(),Ya){Gl(!0);try{l()}finally{Gl(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Cl,lastRenderedState:e},t}function Ld(e,t,l,a){return e.baseState=l,lc(e,ze,typeof a=="function"?a:Cl)}function ry(e,t,l,a,s){if(au(e))throw Error(o(485));if(e=t.action,e!==null){var u={payload:s,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(f){u.listeners.push(f)}};L.T!==null?l(!0):u.isTransition=!1,a(u),l=t.pending,l===null?(u.next=t.pending=u,kd(t,u)):(u.next=l.next,t.pending=l.next=u)}}function kd(e,t){var l=t.action,a=t.payload,s=e.state;if(t.isTransition){var u=L.T,f={};L.T=f;try{var m=l(s,a),j=L.S;j!==null&&j(f,m),Qd(e,t,m)}catch(_){sc(e,t,_)}finally{u!==null&&f.types!==null&&(u.types=f.types),L.T=u}}else try{u=l(s,a),Qd(e,t,u)}catch(_){sc(e,t,_)}}function Qd(e,t,l){l!==null&&typeof l=="object"&&typeof l.then=="function"?l.then(function(a){Yd(e,t,a)},function(a){return sc(e,t,a)}):Yd(e,t,l)}function Yd(e,t,l){t.status="fulfilled",t.value=l,Gd(t),e.state=l,t=e.pending,t!==null&&(l=t.next,l===t?e.pending=null:(l=l.next,t.next=l,kd(e,l)))}function sc(e,t,l){var a=e.pending;if(e.pending=null,a!==null){a=a.next;do t.status="rejected",t.reason=l,Gd(t),t=t.next;while(t!==a)}e.action=null}function Gd(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function Xd(e,t){return t}function Kd(e,t){if(Se){var l=Ue.formState;if(l!==null){e:{var a=fe;if(Se){if(qe){t:{for(var s=qe,u=$t;s.nodeType!==8;){if(!u){s=null;break t}if(s=Wt(s.nextSibling),s===null){s=null;break t}}u=s.data,s=u==="F!"||u==="F"?s:null}if(s){qe=Wt(s.nextSibling),a=s.data==="F!";break e}}Jl(a)}a=!1}a&&(t=l[0])}}return l=vt(),l.memoizedState=l.baseState=t,a={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Xd,lastRenderedState:t},l.queue=a,l=oh.bind(null,fe,a),a.dispatch=l,a=nc(!1),u=fc.bind(null,fe,!1,a.queue),a=vt(),s={state:t,dispatch:null,action:e,pending:null},a.queue=s,l=ry.bind(null,fe,s,u,l),s.dispatch=l,a.memoizedState=e,[t,l,!1]}function Vd(e){var t=Ze();return Zd(t,ze,e)}function Zd(e,t,l){if(t=lc(e,t,Xd)[0],e=eu(Cl)[0],typeof t=="object"&&t!==null&&typeof t.then=="function")try{var a=Us(t)}catch(f){throw f===Tn?Xi:f}else a=t;t=Ze();var s=t.queue,u=s.dispatch;return l!==t.memoizedState&&(fe.flags|=2048,zn(9,{destroy:void 0},cy.bind(null,s,l),null)),[a,u,e]}function cy(e,t){e.action=t}function Jd(e){var t=Ze(),l=ze;if(l!==null)return Zd(t,l,e);Ze(),t=t.memoizedState,l=Ze();var a=l.queue.dispatch;return l.memoizedState=e,[t,a,!1]}function zn(e,t,l,a){return e={tag:e,create:l,deps:a,inst:t,next:null},t=fe.updateQueue,t===null&&(t=Ii(),fe.updateQueue=t),l=t.lastEffect,l===null?t.lastEffect=e.next=e:(a=l.next,l.next=e,e.next=a,t.lastEffect=e),e}function $d(){return Ze().memoizedState}function tu(e,t,l,a){var s=vt();fe.flags|=e,s.memoizedState=zn(1|t,{destroy:void 0},l,a===void 0?null:a)}function lu(e,t,l,a){var s=Ze();a=a===void 0?null:a;var u=s.memoizedState.inst;ze!==null&&a!==null&&Fr(a,ze.memoizedState.deps)?s.memoizedState=zn(t,u,l,a):(fe.flags|=e,s.memoizedState=zn(1|t,u,l,a))}function Fd(e,t){tu(8390656,8,e,t)}function ic(e,t){lu(2048,8,e,t)}function oy(e){fe.flags|=4;var t=fe.updateQueue;if(t===null)t=Ii(),fe.updateQueue=t,t.events=[e];else{var l=t.events;l===null?t.events=[e]:l.push(e)}}function Wd(e){var t=Ze().memoizedState;return oy({ref:t,nextImpl:e}),function(){if((Te&2)!==0)throw Error(o(440));return t.impl.apply(void 0,arguments)}}function Id(e,t){return lu(4,2,e,t)}function Pd(e,t){return lu(4,4,e,t)}function eh(e,t){if(typeof t=="function"){e=e();var l=t(e);return function(){typeof l=="function"?l():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function th(e,t,l){l=l!=null?l.concat([e]):null,lu(4,4,eh.bind(null,t,e),l)}function uc(){}function lh(e,t){var l=Ze();t=t===void 0?null:t;var a=l.memoizedState;return t!==null&&Fr(t,a[1])?a[0]:(l.memoizedState=[e,t],e)}function ah(e,t){var l=Ze();t=t===void 0?null:t;var a=l.memoizedState;if(t!==null&&Fr(t,a[1]))return a[0];if(a=e(),Ya){Gl(!0);try{e()}finally{Gl(!1)}}return l.memoizedState=[a,t],a}function rc(e,t,l){return l===void 0||(El&1073741824)!==0&&(ge&261930)===0?e.memoizedState=t:(e.memoizedState=l,e=nm(),fe.lanes|=e,aa|=e,l)}function nh(e,t,l,a){return _t(l,t)?l:Rn.current!==null?(e=rc(e,l,a),_t(e,t)||(Fe=!0),e):(El&42)===0||(El&1073741824)!==0&&(ge&261930)===0?(Fe=!0,e.memoizedState=l):(e=nm(),fe.lanes|=e,aa|=e,t)}function sh(e,t,l,a,s){var u=F.p;F.p=u!==0&&8>u?u:8;var f=L.T,m={};L.T=m,fc(e,!1,t,l);try{var j=s(),_=L.S;if(_!==null&&_(m,j),j!==null&&typeof j=="object"&&typeof j.then=="function"){var B=sy(j,a);Hs(e,t,B,Bt(e))}else Hs(e,t,a,Bt(e))}catch(K){Hs(e,t,{then:function(){},status:"rejected",reason:K},Bt())}finally{F.p=u,f!==null&&m.types!==null&&(f.types=m.types),L.T=f}}function fy(){}function cc(e,t,l,a){if(e.tag!==5)throw Error(o(476));var s=ih(e).queue;sh(e,s,t,ae,l===null?fy:function(){return uh(e),l(a)})}function ih(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:ae,baseState:ae,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Cl,lastRenderedState:ae},next:null};var l={};return t.next={memoizedState:l,baseState:l,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Cl,lastRenderedState:l},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function uh(e){var t=ih(e);t.next===null&&(t=e.alternate.memoizedState),Hs(e,t.next.queue,{},Bt())}function oc(){return rt(Ps)}function rh(){return Ze().memoizedState}function ch(){return Ze().memoizedState}function dy(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var l=Bt();e=Wl(l);var a=Il(t,e,l);a!==null&&(Tt(a,t,l),zs(a,t,l)),t={cache:Lr()},e.payload=t;return}t=t.return}}function hy(e,t,l){var a=Bt();l={lane:a,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null},au(e)?fh(t,l):(l=Rr(e,t,l,a),l!==null&&(Tt(l,e,a),dh(l,t,a)))}function oh(e,t,l){var a=Bt();Hs(e,t,l,a)}function Hs(e,t,l,a){var s={lane:a,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null};if(au(e))fh(t,s);else{var u=e.alternate;if(e.lanes===0&&(u===null||u.lanes===0)&&(u=t.lastRenderedReducer,u!==null))try{var f=t.lastRenderedState,m=u(f,l);if(s.hasEagerState=!0,s.eagerState=m,_t(m,f))return qi(e,t,s,0),Ue===null&&Hi(),!1}catch{}finally{}if(l=Rr(e,t,s,a),l!==null)return Tt(l,e,a),dh(l,t,a),!0}return!1}function fc(e,t,l,a){if(a={lane:2,revertLane:Gc(),gesture:null,action:a,hasEagerState:!1,eagerState:null,next:null},au(e)){if(t)throw Error(o(479))}else t=Rr(e,l,a,2),t!==null&&Tt(t,e,2)}function au(e){var t=e.alternate;return e===fe||t!==null&&t===fe}function fh(e,t){An=Fi=!0;var l=e.pending;l===null?t.next=t:(t.next=l.next,l.next=t),e.pending=t}function dh(e,t,l){if((l&4194048)!==0){var a=t.lanes;a&=e.pendingLanes,l|=a,t.lanes=l,xf(e,l)}}var qs={readContext:rt,use:Pi,useCallback:Qe,useContext:Qe,useEffect:Qe,useImperativeHandle:Qe,useLayoutEffect:Qe,useInsertionEffect:Qe,useMemo:Qe,useReducer:Qe,useRef:Qe,useState:Qe,useDebugValue:Qe,useDeferredValue:Qe,useTransition:Qe,useSyncExternalStore:Qe,useId:Qe,useHostTransitionStatus:Qe,useFormState:Qe,useActionState:Qe,useOptimistic:Qe,useMemoCache:Qe,useCacheRefresh:Qe};qs.useEffectEvent=Qe;var hh={readContext:rt,use:Pi,useCallback:function(e,t){return vt().memoizedState=[e,t===void 0?null:t],e},useContext:rt,useEffect:Fd,useImperativeHandle:function(e,t,l){l=l!=null?l.concat([e]):null,tu(4194308,4,eh.bind(null,t,e),l)},useLayoutEffect:function(e,t){return tu(4194308,4,e,t)},useInsertionEffect:function(e,t){tu(4,2,e,t)},useMemo:function(e,t){var l=vt();t=t===void 0?null:t;var a=e();if(Ya){Gl(!0);try{e()}finally{Gl(!1)}}return l.memoizedState=[a,t],a},useReducer:function(e,t,l){var a=vt();if(l!==void 0){var s=l(t);if(Ya){Gl(!0);try{l(t)}finally{Gl(!1)}}}else s=t;return a.memoizedState=a.baseState=s,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:s},a.queue=e,e=e.dispatch=hy.bind(null,fe,e),[a.memoizedState,e]},useRef:function(e){var t=vt();return e={current:e},t.memoizedState=e},useState:function(e){e=nc(e);var t=e.queue,l=oh.bind(null,fe,t);return t.dispatch=l,[e.memoizedState,l]},useDebugValue:uc,useDeferredValue:function(e,t){var l=vt();return rc(l,e,t)},useTransition:function(){var e=nc(!1);return e=sh.bind(null,fe,e.queue,!0,!1),vt().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,l){var a=fe,s=vt();if(Se){if(l===void 0)throw Error(o(407));l=l()}else{if(l=t(),Ue===null)throw Error(o(349));(ge&127)!==0||Dd(a,t,l)}s.memoizedState=l;var u={value:l,getSnapshot:t};return s.queue=u,Fd(Hd.bind(null,a,u,e),[e]),a.flags|=2048,zn(9,{destroy:void 0},Ud.bind(null,a,u,l,t),null),l},useId:function(){var e=vt(),t=Ue.identifierPrefix;if(Se){var l=cl,a=rl;l=(a&~(1<<32-zt(a)-1)).toString(32)+l,t="_"+t+"R_"+l,l=Wi++,0<l&&(t+="H"+l.toString(32)),t+="_"}else l=iy++,t="_"+t+"r_"+l.toString(32)+"_";return e.memoizedState=t},useHostTransitionStatus:oc,useFormState:Kd,useActionState:Kd,useOptimistic:function(e){var t=vt();t.memoizedState=t.baseState=e;var l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=l,t=fc.bind(null,fe,!0,l),l.dispatch=t,[e,t]},useMemoCache:tc,useCacheRefresh:function(){return vt().memoizedState=dy.bind(null,fe)},useEffectEvent:function(e){var t=vt(),l={impl:e};return t.memoizedState=l,function(){if((Te&2)!==0)throw Error(o(440));return l.impl.apply(void 0,arguments)}}},dc={readContext:rt,use:Pi,useCallback:lh,useContext:rt,useEffect:ic,useImperativeHandle:th,useInsertionEffect:Id,useLayoutEffect:Pd,useMemo:ah,useReducer:eu,useRef:$d,useState:function(){return eu(Cl)},useDebugValue:uc,useDeferredValue:function(e,t){var l=Ze();return nh(l,ze.memoizedState,e,t)},useTransition:function(){var e=eu(Cl)[0],t=Ze().memoizedState;return[typeof e=="boolean"?e:Us(e),t]},useSyncExternalStore:wd,useId:rh,useHostTransitionStatus:oc,useFormState:Vd,useActionState:Vd,useOptimistic:function(e,t){var l=Ze();return Ld(l,ze,e,t)},useMemoCache:tc,useCacheRefresh:ch};dc.useEffectEvent=Wd;var mh={readContext:rt,use:Pi,useCallback:lh,useContext:rt,useEffect:ic,useImperativeHandle:th,useInsertionEffect:Id,useLayoutEffect:Pd,useMemo:ah,useReducer:ac,useRef:$d,useState:function(){return ac(Cl)},useDebugValue:uc,useDeferredValue:function(e,t){var l=Ze();return ze===null?rc(l,e,t):nh(l,ze.memoizedState,e,t)},useTransition:function(){var e=ac(Cl)[0],t=Ze().memoizedState;return[typeof e=="boolean"?e:Us(e),t]},useSyncExternalStore:wd,useId:rh,useHostTransitionStatus:oc,useFormState:Jd,useActionState:Jd,useOptimistic:function(e,t){var l=Ze();return ze!==null?Ld(l,ze,e,t):(l.baseState=e,[e,l.queue.dispatch])},useMemoCache:tc,useCacheRefresh:ch};mh.useEffectEvent=Wd;function hc(e,t,l,a){t=e.memoizedState,l=l(a,t),l=l==null?t:g({},t,l),e.memoizedState=l,e.lanes===0&&(e.updateQueue.baseState=l)}var mc={enqueueSetState:function(e,t,l){e=e._reactInternals;var a=Bt(),s=Wl(a);s.payload=t,l!=null&&(s.callback=l),t=Il(e,s,a),t!==null&&(Tt(t,e,a),zs(t,e,a))},enqueueReplaceState:function(e,t,l){e=e._reactInternals;var a=Bt(),s=Wl(a);s.tag=1,s.payload=t,l!=null&&(s.callback=l),t=Il(e,s,a),t!==null&&(Tt(t,e,a),zs(t,e,a))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var l=Bt(),a=Wl(l);a.tag=2,t!=null&&(a.callback=t),t=Il(e,a,l),t!==null&&(Tt(t,e,l),zs(t,e,l))}};function ph(e,t,l,a,s,u,f){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(a,u,f):t.prototype&&t.prototype.isPureReactComponent?!Ns(l,a)||!Ns(s,u):!0}function vh(e,t,l,a){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(l,a),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(l,a),t.state!==e&&mc.enqueueReplaceState(t,t.state,null)}function Ga(e,t){var l=t;if("ref"in t){l={};for(var a in t)a!=="ref"&&(l[a]=t[a])}if(e=e.defaultProps){l===t&&(l=g({},l));for(var s in e)l[s]===void 0&&(l[s]=e[s])}return l}function xh(e){Ui(e)}function yh(e){console.error(e)}function gh(e){Ui(e)}function nu(e,t){try{var l=e.onUncaughtError;l(t.value,{componentStack:t.stack})}catch(a){setTimeout(function(){throw a})}}function bh(e,t,l){try{var a=e.onCaughtError;a(l.value,{componentStack:l.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(s){setTimeout(function(){throw s})}}function pc(e,t,l){return l=Wl(l),l.tag=3,l.payload={element:null},l.callback=function(){nu(e,t)},l}function Sh(e){return e=Wl(e),e.tag=3,e}function jh(e,t,l,a){var s=l.type.getDerivedStateFromError;if(typeof s=="function"){var u=a.value;e.payload=function(){return s(u)},e.callback=function(){bh(t,l,a)}}var f=l.stateNode;f!==null&&typeof f.componentDidCatch=="function"&&(e.callback=function(){bh(t,l,a),typeof s!="function"&&(na===null?na=new Set([this]):na.add(this));var m=a.stack;this.componentDidCatch(a.value,{componentStack:m!==null?m:""})})}function my(e,t,l,a,s){if(l.flags|=32768,a!==null&&typeof a=="object"&&typeof a.then=="function"){if(t=l.alternate,t!==null&&Nn(t,l,s,!0),l=Dt.current,l!==null){switch(l.tag){case 31:case 13:return Ft===null?vu():l.alternate===null&&Ye===0&&(Ye=3),l.flags&=-257,l.flags|=65536,l.lanes=s,a===Ki?l.flags|=16384:(t=l.updateQueue,t===null?l.updateQueue=new Set([a]):t.add(a),kc(e,a,s)),!1;case 22:return l.flags|=65536,a===Ki?l.flags|=16384:(t=l.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([a])},l.updateQueue=t):(l=t.retryQueue,l===null?t.retryQueue=new Set([a]):l.add(a)),kc(e,a,s)),!1}throw Error(o(435,l.tag))}return kc(e,a,s),vu(),!1}if(Se)return t=Dt.current,t!==null?((t.flags&65536)===0&&(t.flags|=256),t.flags|=65536,t.lanes=s,a!==Dr&&(e=Error(o(422),{cause:a}),Ts(Vt(e,l)))):(a!==Dr&&(t=Error(o(423),{cause:a}),Ts(Vt(t,l))),e=e.current.alternate,e.flags|=65536,s&=-s,e.lanes|=s,a=Vt(a,l),s=pc(e.stateNode,a,s),Kr(e,s),Ye!==4&&(Ye=2)),!1;var u=Error(o(520),{cause:a});if(u=Vt(u,l),Ks===null?Ks=[u]:Ks.push(u),Ye!==4&&(Ye=2),t===null)return!0;a=Vt(a,l),l=t;do{switch(l.tag){case 3:return l.flags|=65536,e=s&-s,l.lanes|=e,e=pc(l.stateNode,a,e),Kr(l,e),!1;case 1:if(t=l.type,u=l.stateNode,(l.flags&128)===0&&(typeof t.getDerivedStateFromError=="function"||u!==null&&typeof u.componentDidCatch=="function"&&(na===null||!na.has(u))))return l.flags|=65536,s&=-s,l.lanes|=s,s=Sh(s),jh(s,e,l,a),Kr(l,s),!1}l=l.return}while(l!==null);return!1}var vc=Error(o(461)),Fe=!1;function ct(e,t,l,a){t.child=e===null?Td(t,null,l,a):Qa(t,e.child,l,a)}function Nh(e,t,l,a,s){l=l.render;var u=t.ref;if("ref"in a){var f={};for(var m in a)m!=="ref"&&(f[m]=a[m])}else f=a;return qa(t),a=Wr(e,t,l,f,u,s),m=Ir(),e!==null&&!Fe?(Pr(e,t,s),Tl(e,t,s)):(Se&&m&&_r(t),t.flags|=1,ct(e,t,a,s),t.child)}function Eh(e,t,l,a,s){if(e===null){var u=l.type;return typeof u=="function"&&!Ar(u)&&u.defaultProps===void 0&&l.compare===null?(t.tag=15,t.type=u,Ch(e,t,u,a,s)):(e=Li(l.type,null,a,t,t.mode,s),e.ref=t.ref,e.return=t,t.child=e)}if(u=e.child,!Ec(e,s)){var f=u.memoizedProps;if(l=l.compare,l=l!==null?l:Ns,l(f,a)&&e.ref===t.ref)return Tl(e,t,s)}return t.flags|=1,e=bl(u,a),e.ref=t.ref,e.return=t,t.child=e}function Ch(e,t,l,a,s){if(e!==null){var u=e.memoizedProps;if(Ns(u,a)&&e.ref===t.ref)if(Fe=!1,t.pendingProps=a=u,Ec(e,s))(e.flags&131072)!==0&&(Fe=!0);else return t.lanes=e.lanes,Tl(e,t,s)}return xc(e,t,l,a,s)}function Th(e,t,l,a){var s=a.children,u=e!==null?e.memoizedState:null;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),a.mode==="hidden"){if((t.flags&128)!==0){if(u=u!==null?u.baseLanes|l:l,e!==null){for(a=t.child=e.child,s=0;a!==null;)s=s|a.lanes|a.childLanes,a=a.sibling;a=s&~u}else a=0,t.child=null;return Oh(e,t,u,l,a)}if((l&536870912)!==0)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&Gi(t,u!==null?u.cachePool:null),u!==null?Ad(t,u):Zr(),Md(t);else return a=t.lanes=536870912,Oh(e,t,u!==null?u.baseLanes|l:l,l,a)}else u!==null?(Gi(t,u.cachePool),Ad(t,u),ea(),t.memoizedState=null):(e!==null&&Gi(t,null),Zr(),ea());return ct(e,t,s,l),t.child}function Bs(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function Oh(e,t,l,a,s){var u=Qr();return u=u===null?null:{parent:Je._currentValue,pool:u},t.memoizedState={baseLanes:l,cachePool:u},e!==null&&Gi(t,null),Zr(),Md(t),e!==null&&Nn(e,t,a,!0),t.childLanes=s,null}function su(e,t){return t=uu({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function Rh(e,t,l){return Qa(t,e.child,null,l),e=su(t,t.pendingProps),e.flags|=2,Ut(t),t.memoizedState=null,e}function py(e,t,l){var a=t.pendingProps,s=(t.flags&128)!==0;if(t.flags&=-129,e===null){if(Se){if(a.mode==="hidden")return e=su(t,a),t.lanes=536870912,Bs(null,e);if($r(t),(e=qe)?(e=km(e,$t),e=e!==null&&e.data==="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Vl!==null?{id:rl,overflow:cl}:null,retryLane:536870912,hydrationErrors:null},l=fd(e),l.return=t,t.child=l,ut=t,qe=null)):e=null,e===null)throw Jl(t);return t.lanes=536870912,null}return su(t,a)}var u=e.memoizedState;if(u!==null){var f=u.dehydrated;if($r(t),s)if(t.flags&256)t.flags&=-257,t=Rh(e,t,l);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(o(558));else if(Fe||Nn(e,t,l,!1),s=(l&e.childLanes)!==0,Fe||s){if(a=Ue,a!==null&&(f=yf(a,l),f!==0&&f!==u.retryLane))throw u.retryLane=f,wa(e,f),Tt(a,e,f),vc;vu(),t=Rh(e,t,l)}else e=u.treeContext,qe=Wt(f.nextSibling),ut=t,Se=!0,Zl=null,$t=!1,e!==null&&md(t,e),t=su(t,a),t.flags|=4096;return t}return e=bl(e.child,{mode:a.mode,children:a.children}),e.ref=t.ref,t.child=e,e.return=t,e}function iu(e,t){var l=t.ref;if(l===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof l!="function"&&typeof l!="object")throw Error(o(284));(e===null||e.ref!==l)&&(t.flags|=4194816)}}function xc(e,t,l,a,s){return qa(t),l=Wr(e,t,l,a,void 0,s),a=Ir(),e!==null&&!Fe?(Pr(e,t,s),Tl(e,t,s)):(Se&&a&&_r(t),t.flags|=1,ct(e,t,l,s),t.child)}function Ah(e,t,l,a,s,u){return qa(t),t.updateQueue=null,l=_d(t,a,l,s),zd(e),a=Ir(),e!==null&&!Fe?(Pr(e,t,u),Tl(e,t,u)):(Se&&a&&_r(t),t.flags|=1,ct(e,t,l,u),t.child)}function Mh(e,t,l,a,s){if(qa(t),t.stateNode===null){var u=gn,f=l.contextType;typeof f=="object"&&f!==null&&(u=rt(f)),u=new l(a,u),t.memoizedState=u.state!==null&&u.state!==void 0?u.state:null,u.updater=mc,t.stateNode=u,u._reactInternals=t,u=t.stateNode,u.props=a,u.state=t.memoizedState,u.refs={},Gr(t),f=l.contextType,u.context=typeof f=="object"&&f!==null?rt(f):gn,u.state=t.memoizedState,f=l.getDerivedStateFromProps,typeof f=="function"&&(hc(t,l,f,a),u.state=t.memoizedState),typeof l.getDerivedStateFromProps=="function"||typeof u.getSnapshotBeforeUpdate=="function"||typeof u.UNSAFE_componentWillMount!="function"&&typeof u.componentWillMount!="function"||(f=u.state,typeof u.componentWillMount=="function"&&u.componentWillMount(),typeof u.UNSAFE_componentWillMount=="function"&&u.UNSAFE_componentWillMount(),f!==u.state&&mc.enqueueReplaceState(u,u.state,null),ws(t,a,u,s),_s(),u.state=t.memoizedState),typeof u.componentDidMount=="function"&&(t.flags|=4194308),a=!0}else if(e===null){u=t.stateNode;var m=t.memoizedProps,j=Ga(l,m);u.props=j;var _=u.context,B=l.contextType;f=gn,typeof B=="object"&&B!==null&&(f=rt(B));var K=l.getDerivedStateFromProps;B=typeof K=="function"||typeof u.getSnapshotBeforeUpdate=="function",m=t.pendingProps!==m,B||typeof u.UNSAFE_componentWillReceiveProps!="function"&&typeof u.componentWillReceiveProps!="function"||(m||_!==f)&&vh(t,u,a,f),Fl=!1;var w=t.memoizedState;u.state=w,ws(t,a,u,s),_s(),_=t.memoizedState,m||w!==_||Fl?(typeof K=="function"&&(hc(t,l,K,a),_=t.memoizedState),(j=Fl||ph(t,l,j,a,w,_,f))?(B||typeof u.UNSAFE_componentWillMount!="function"&&typeof u.componentWillMount!="function"||(typeof u.componentWillMount=="function"&&u.componentWillMount(),typeof u.UNSAFE_componentWillMount=="function"&&u.UNSAFE_componentWillMount()),typeof u.componentDidMount=="function"&&(t.flags|=4194308)):(typeof u.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=a,t.memoizedState=_),u.props=a,u.state=_,u.context=f,a=j):(typeof u.componentDidMount=="function"&&(t.flags|=4194308),a=!1)}else{u=t.stateNode,Xr(e,t),f=t.memoizedProps,B=Ga(l,f),u.props=B,K=t.pendingProps,w=u.context,_=l.contextType,j=gn,typeof _=="object"&&_!==null&&(j=rt(_)),m=l.getDerivedStateFromProps,(_=typeof m=="function"||typeof u.getSnapshotBeforeUpdate=="function")||typeof u.UNSAFE_componentWillReceiveProps!="function"&&typeof u.componentWillReceiveProps!="function"||(f!==K||w!==j)&&vh(t,u,a,j),Fl=!1,w=t.memoizedState,u.state=w,ws(t,a,u,s),_s();var D=t.memoizedState;f!==K||w!==D||Fl||e!==null&&e.dependencies!==null&&Qi(e.dependencies)?(typeof m=="function"&&(hc(t,l,m,a),D=t.memoizedState),(B=Fl||ph(t,l,B,a,w,D,j)||e!==null&&e.dependencies!==null&&Qi(e.dependencies))?(_||typeof u.UNSAFE_componentWillUpdate!="function"&&typeof u.componentWillUpdate!="function"||(typeof u.componentWillUpdate=="function"&&u.componentWillUpdate(a,D,j),typeof u.UNSAFE_componentWillUpdate=="function"&&u.UNSAFE_componentWillUpdate(a,D,j)),typeof u.componentDidUpdate=="function"&&(t.flags|=4),typeof u.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof u.componentDidUpdate!="function"||f===e.memoizedProps&&w===e.memoizedState||(t.flags|=4),typeof u.getSnapshotBeforeUpdate!="function"||f===e.memoizedProps&&w===e.memoizedState||(t.flags|=1024),t.memoizedProps=a,t.memoizedState=D),u.props=a,u.state=D,u.context=j,a=B):(typeof u.componentDidUpdate!="function"||f===e.memoizedProps&&w===e.memoizedState||(t.flags|=4),typeof u.getSnapshotBeforeUpdate!="function"||f===e.memoizedProps&&w===e.memoizedState||(t.flags|=1024),a=!1)}return u=a,iu(e,t),a=(t.flags&128)!==0,u||a?(u=t.stateNode,l=a&&typeof l.getDerivedStateFromError!="function"?null:u.render(),t.flags|=1,e!==null&&a?(t.child=Qa(t,e.child,null,s),t.child=Qa(t,null,l,s)):ct(e,t,l,s),t.memoizedState=u.state,e=t.child):e=Tl(e,t,s),e}function zh(e,t,l,a){return Ua(),t.flags|=256,ct(e,t,l,a),t.child}var yc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function gc(e){return{baseLanes:e,cachePool:bd()}}function bc(e,t,l){return e=e!==null?e.childLanes&~l:0,t&&(e|=qt),e}function _h(e,t,l){var a=t.pendingProps,s=!1,u=(t.flags&128)!==0,f;if((f=u)||(f=e!==null&&e.memoizedState===null?!1:(Ve.current&2)!==0),f&&(s=!0,t.flags&=-129),f=(t.flags&32)!==0,t.flags&=-33,e===null){if(Se){if(s?Pl(t):ea(),(e=qe)?(e=km(e,$t),e=e!==null&&e.data!=="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Vl!==null?{id:rl,overflow:cl}:null,retryLane:536870912,hydrationErrors:null},l=fd(e),l.return=t,t.child=l,ut=t,qe=null)):e=null,e===null)throw Jl(t);return lo(e)?t.lanes=32:t.lanes=536870912,null}var m=a.children;return a=a.fallback,s?(ea(),s=t.mode,m=uu({mode:"hidden",children:m},s),a=Da(a,s,l,null),m.return=t,a.return=t,m.sibling=a,t.child=m,a=t.child,a.memoizedState=gc(l),a.childLanes=bc(e,f,l),t.memoizedState=yc,Bs(null,a)):(Pl(t),Sc(t,m))}var j=e.memoizedState;if(j!==null&&(m=j.dehydrated,m!==null)){if(u)t.flags&256?(Pl(t),t.flags&=-257,t=jc(e,t,l)):t.memoizedState!==null?(ea(),t.child=e.child,t.flags|=128,t=null):(ea(),m=a.fallback,s=t.mode,a=uu({mode:"visible",children:a.children},s),m=Da(m,s,l,null),m.flags|=2,a.return=t,m.return=t,a.sibling=m,t.child=a,Qa(t,e.child,null,l),a=t.child,a.memoizedState=gc(l),a.childLanes=bc(e,f,l),t.memoizedState=yc,t=Bs(null,a));else if(Pl(t),lo(m)){if(f=m.nextSibling&&m.nextSibling.dataset,f)var _=f.dgst;f=_,a=Error(o(419)),a.stack="",a.digest=f,Ts({value:a,source:null,stack:null}),t=jc(e,t,l)}else if(Fe||Nn(e,t,l,!1),f=(l&e.childLanes)!==0,Fe||f){if(f=Ue,f!==null&&(a=yf(f,l),a!==0&&a!==j.retryLane))throw j.retryLane=a,wa(e,a),Tt(f,e,a),vc;to(m)||vu(),t=jc(e,t,l)}else to(m)?(t.flags|=192,t.child=e.child,t=null):(e=j.treeContext,qe=Wt(m.nextSibling),ut=t,Se=!0,Zl=null,$t=!1,e!==null&&md(t,e),t=Sc(t,a.children),t.flags|=4096);return t}return s?(ea(),m=a.fallback,s=t.mode,j=e.child,_=j.sibling,a=bl(j,{mode:"hidden",children:a.children}),a.subtreeFlags=j.subtreeFlags&65011712,_!==null?m=bl(_,m):(m=Da(m,s,l,null),m.flags|=2),m.return=t,a.return=t,a.sibling=m,t.child=a,Bs(null,a),a=t.child,m=e.child.memoizedState,m===null?m=gc(l):(s=m.cachePool,s!==null?(j=Je._currentValue,s=s.parent!==j?{parent:j,pool:j}:s):s=bd(),m={baseLanes:m.baseLanes|l,cachePool:s}),a.memoizedState=m,a.childLanes=bc(e,f,l),t.memoizedState=yc,Bs(e.child,a)):(Pl(t),l=e.child,e=l.sibling,l=bl(l,{mode:"visible",children:a.children}),l.return=t,l.sibling=null,e!==null&&(f=t.deletions,f===null?(t.deletions=[e],t.flags|=16):f.push(e)),t.child=l,t.memoizedState=null,l)}function Sc(e,t){return t=uu({mode:"visible",children:t},e.mode),t.return=e,e.child=t}function uu(e,t){return e=wt(22,e,null,t),e.lanes=0,e}function jc(e,t,l){return Qa(t,e.child,null,l),e=Sc(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function wh(e,t,l){e.lanes|=t;var a=e.alternate;a!==null&&(a.lanes|=t),qr(e.return,t,l)}function Nc(e,t,l,a,s,u){var f=e.memoizedState;f===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:a,tail:l,tailMode:s,treeForkCount:u}:(f.isBackwards=t,f.rendering=null,f.renderingStartTime=0,f.last=a,f.tail=l,f.tailMode=s,f.treeForkCount=u)}function Dh(e,t,l){var a=t.pendingProps,s=a.revealOrder,u=a.tail;a=a.children;var f=Ve.current,m=(f&2)!==0;if(m?(f=f&1|2,t.flags|=128):f&=1,J(Ve,f),ct(e,t,a,l),a=Se?Cs:0,!m&&e!==null&&(e.flags&128)!==0)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&wh(e,l,t);else if(e.tag===19)wh(e,l,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}switch(s){case"forwards":for(l=t.child,s=null;l!==null;)e=l.alternate,e!==null&&$i(e)===null&&(s=l),l=l.sibling;l=s,l===null?(s=t.child,t.child=null):(s=l.sibling,l.sibling=null),Nc(t,!1,s,l,u,a);break;case"backwards":case"unstable_legacy-backwards":for(l=null,s=t.child,t.child=null;s!==null;){if(e=s.alternate,e!==null&&$i(e)===null){t.child=s;break}e=s.sibling,s.sibling=l,l=s,s=e}Nc(t,!0,l,null,u,a);break;case"together":Nc(t,!1,null,null,void 0,a);break;default:t.memoizedState=null}return t.child}function Tl(e,t,l){if(e!==null&&(t.dependencies=e.dependencies),aa|=t.lanes,(l&t.childLanes)===0)if(e!==null){if(Nn(e,t,l,!1),(l&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(o(153));if(t.child!==null){for(e=t.child,l=bl(e,e.pendingProps),t.child=l,l.return=t;e.sibling!==null;)e=e.sibling,l=l.sibling=bl(e,e.pendingProps),l.return=t;l.sibling=null}return t.child}function Ec(e,t){return(e.lanes&t)!==0?!0:(e=e.dependencies,!!(e!==null&&Qi(e)))}function vy(e,t,l){switch(t.tag){case 3:oe(t,t.stateNode.containerInfo),$l(t,Je,e.memoizedState.cache),Ua();break;case 27:case 5:gt(t);break;case 4:oe(t,t.stateNode.containerInfo);break;case 10:$l(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,$r(t),null;break;case 13:var a=t.memoizedState;if(a!==null)return a.dehydrated!==null?(Pl(t),t.flags|=128,null):(l&t.child.childLanes)!==0?_h(e,t,l):(Pl(t),e=Tl(e,t,l),e!==null?e.sibling:null);Pl(t);break;case 19:var s=(e.flags&128)!==0;if(a=(l&t.childLanes)!==0,a||(Nn(e,t,l,!1),a=(l&t.childLanes)!==0),s){if(a)return Dh(e,t,l);t.flags|=128}if(s=t.memoizedState,s!==null&&(s.rendering=null,s.tail=null,s.lastEffect=null),J(Ve,Ve.current),a)break;return null;case 22:return t.lanes=0,Th(e,t,l,t.pendingProps);case 24:$l(t,Je,e.memoizedState.cache)}return Tl(e,t,l)}function Uh(e,t,l){if(e!==null)if(e.memoizedProps!==t.pendingProps)Fe=!0;else{if(!Ec(e,l)&&(t.flags&128)===0)return Fe=!1,vy(e,t,l);Fe=(e.flags&131072)!==0}else Fe=!1,Se&&(t.flags&1048576)!==0&&hd(t,Cs,t.index);switch(t.lanes=0,t.tag){case 16:e:{var a=t.pendingProps;if(e=La(t.elementType),t.type=e,typeof e=="function")Ar(e)?(a=Ga(e,a),t.tag=1,t=Mh(null,t,e,a,l)):(t.tag=0,t=xc(null,t,e,a,l));else{if(e!=null){var s=e.$$typeof;if(s===Y){t.tag=11,t=Nh(null,t,e,a,l);break e}else if(s===q){t.tag=14,t=Eh(null,t,e,a,l);break e}}throw t=dt(e)||e,Error(o(306,t,""))}}return t;case 0:return xc(e,t,t.type,t.pendingProps,l);case 1:return a=t.type,s=Ga(a,t.pendingProps),Mh(e,t,a,s,l);case 3:e:{if(oe(t,t.stateNode.containerInfo),e===null)throw Error(o(387));a=t.pendingProps;var u=t.memoizedState;s=u.element,Xr(e,t),ws(t,a,null,l);var f=t.memoizedState;if(a=f.cache,$l(t,Je,a),a!==u.cache&&Br(t,[Je],l,!0),_s(),a=f.element,u.isDehydrated)if(u={element:a,isDehydrated:!1,cache:f.cache},t.updateQueue.baseState=u,t.memoizedState=u,t.flags&256){t=zh(e,t,a,l);break e}else if(a!==s){s=Vt(Error(o(424)),t),Ts(s),t=zh(e,t,a,l);break e}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName==="HTML"?e.ownerDocument.body:e}for(qe=Wt(e.firstChild),ut=t,Se=!0,Zl=null,$t=!0,l=Td(t,null,a,l),t.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling}else{if(Ua(),a===s){t=Tl(e,t,l);break e}ct(e,t,a,l)}t=t.child}return t;case 26:return iu(e,t),e===null?(l=Vm(t.type,null,t.pendingProps,null))?t.memoizedState=l:Se||(l=t.type,e=t.pendingProps,a=Nu(he.current).createElement(l),a[it]=t,a[bt]=e,ot(a,l,e),lt(a),t.stateNode=a):t.memoizedState=Vm(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return gt(t),e===null&&Se&&(a=t.stateNode=Gm(t.type,t.pendingProps,he.current),ut=t,$t=!0,s=qe,ra(t.type)?(ao=s,qe=Wt(a.firstChild)):qe=s),ct(e,t,t.pendingProps.children,l),iu(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&Se&&((s=a=qe)&&(a=Vy(a,t.type,t.pendingProps,$t),a!==null?(t.stateNode=a,ut=t,qe=Wt(a.firstChild),$t=!1,s=!0):s=!1),s||Jl(t)),gt(t),s=t.type,u=t.pendingProps,f=e!==null?e.memoizedProps:null,a=u.children,Ic(s,u)?a=null:f!==null&&Ic(s,f)&&(t.flags|=32),t.memoizedState!==null&&(s=Wr(e,t,uy,null,null,l),Ps._currentValue=s),iu(e,t),ct(e,t,a,l),t.child;case 6:return e===null&&Se&&((e=l=qe)&&(l=Zy(l,t.pendingProps,$t),l!==null?(t.stateNode=l,ut=t,qe=null,e=!0):e=!1),e||Jl(t)),null;case 13:return _h(e,t,l);case 4:return oe(t,t.stateNode.containerInfo),a=t.pendingProps,e===null?t.child=Qa(t,null,a,l):ct(e,t,a,l),t.child;case 11:return Nh(e,t,t.type,t.pendingProps,l);case 7:return ct(e,t,t.pendingProps,l),t.child;case 8:return ct(e,t,t.pendingProps.children,l),t.child;case 12:return ct(e,t,t.pendingProps.children,l),t.child;case 10:return a=t.pendingProps,$l(t,t.type,a.value),ct(e,t,a.children,l),t.child;case 9:return s=t.type._context,a=t.pendingProps.children,qa(t),s=rt(s),a=a(s),t.flags|=1,ct(e,t,a,l),t.child;case 14:return Eh(e,t,t.type,t.pendingProps,l);case 15:return Ch(e,t,t.type,t.pendingProps,l);case 19:return Dh(e,t,l);case 31:return py(e,t,l);case 22:return Th(e,t,l,t.pendingProps);case 24:return qa(t),a=rt(Je),e===null?(s=Qr(),s===null&&(s=Ue,u=Lr(),s.pooledCache=u,u.refCount++,u!==null&&(s.pooledCacheLanes|=l),s=u),t.memoizedState={parent:a,cache:s},Gr(t),$l(t,Je,s)):((e.lanes&l)!==0&&(Xr(e,t),ws(t,null,null,l),_s()),s=e.memoizedState,u=t.memoizedState,s.parent!==a?(s={parent:a,cache:a},t.memoizedState=s,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=s),$l(t,Je,a)):(a=u.cache,$l(t,Je,a),a!==s.cache&&Br(t,[Je],l,!0))),ct(e,t,t.pendingProps.children,l),t.child;case 29:throw t.pendingProps}throw Error(o(156,t.tag))}function Ol(e){e.flags|=4}function Cc(e,t,l,a,s){if((t=(e.mode&32)!==0)&&(t=!1),t){if(e.flags|=16777216,(s&335544128)===s)if(e.stateNode.complete)e.flags|=8192;else if(rm())e.flags|=8192;else throw ka=Ki,Yr}else e.flags&=-16777217}function Hh(e,t){if(t.type!=="stylesheet"||(t.state.loading&4)!==0)e.flags&=-16777217;else if(e.flags|=16777216,!Wm(t))if(rm())e.flags|=8192;else throw ka=Ki,Yr}function ru(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag!==22?pf():536870912,e.lanes|=t,Un|=t)}function Ls(e,t){if(!Se)switch(e.tailMode){case"hidden":t=e.tail;for(var l=null;t!==null;)t.alternate!==null&&(l=t),t=t.sibling;l===null?e.tail=null:l.sibling=null;break;case"collapsed":l=e.tail;for(var a=null;l!==null;)l.alternate!==null&&(a=l),l=l.sibling;a===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:a.sibling=null}}function Be(e){var t=e.alternate!==null&&e.alternate.child===e.child,l=0,a=0;if(t)for(var s=e.child;s!==null;)l|=s.lanes|s.childLanes,a|=s.subtreeFlags&65011712,a|=s.flags&65011712,s.return=e,s=s.sibling;else for(s=e.child;s!==null;)l|=s.lanes|s.childLanes,a|=s.subtreeFlags,a|=s.flags,s.return=e,s=s.sibling;return e.subtreeFlags|=a,e.childLanes=l,t}function xy(e,t,l){var a=t.pendingProps;switch(wr(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Be(t),null;case 1:return Be(t),null;case 3:return l=t.stateNode,a=null,e!==null&&(a=e.memoizedState.cache),t.memoizedState.cache!==a&&(t.flags|=2048),Nl(Je),De(),l.pendingContext&&(l.context=l.pendingContext,l.pendingContext=null),(e===null||e.child===null)&&(jn(t)?Ol(t):e===null||e.memoizedState.isDehydrated&&(t.flags&256)===0||(t.flags|=1024,Ur())),Be(t),null;case 26:var s=t.type,u=t.memoizedState;return e===null?(Ol(t),u!==null?(Be(t),Hh(t,u)):(Be(t),Cc(t,s,null,a,l))):u?u!==e.memoizedState?(Ol(t),Be(t),Hh(t,u)):(Be(t),t.flags&=-16777217):(e=e.memoizedProps,e!==a&&Ol(t),Be(t),Cc(t,s,e,a,l)),null;case 27:if(Ta(t),l=he.current,s=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==a&&Ol(t);else{if(!a){if(t.stateNode===null)throw Error(o(166));return Be(t),null}e=ee.current,jn(t)?pd(t):(e=Gm(s,a,l),t.stateNode=e,Ol(t))}return Be(t),null;case 5:if(Ta(t),s=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==a&&Ol(t);else{if(!a){if(t.stateNode===null)throw Error(o(166));return Be(t),null}if(u=ee.current,jn(t))pd(t);else{var f=Nu(he.current);switch(u){case 1:u=f.createElementNS("http://www.w3.org/2000/svg",s);break;case 2:u=f.createElementNS("http://www.w3.org/1998/Math/MathML",s);break;default:switch(s){case"svg":u=f.createElementNS("http://www.w3.org/2000/svg",s);break;case"math":u=f.createElementNS("http://www.w3.org/1998/Math/MathML",s);break;case"script":u=f.createElement("div"),u.innerHTML="<script><\/script>",u=u.removeChild(u.firstChild);break;case"select":u=typeof a.is=="string"?f.createElement("select",{is:a.is}):f.createElement("select"),a.multiple?u.multiple=!0:a.size&&(u.size=a.size);break;default:u=typeof a.is=="string"?f.createElement(s,{is:a.is}):f.createElement(s)}}u[it]=t,u[bt]=a;e:for(f=t.child;f!==null;){if(f.tag===5||f.tag===6)u.appendChild(f.stateNode);else if(f.tag!==4&&f.tag!==27&&f.child!==null){f.child.return=f,f=f.child;continue}if(f===t)break e;for(;f.sibling===null;){if(f.return===null||f.return===t)break e;f=f.return}f.sibling.return=f.return,f=f.sibling}t.stateNode=u;e:switch(ot(u,s,a),s){case"button":case"input":case"select":case"textarea":a=!!a.autoFocus;break e;case"img":a=!0;break e;default:a=!1}a&&Ol(t)}}return Be(t),Cc(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,l),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==a&&Ol(t);else{if(typeof a!="string"&&t.stateNode===null)throw Error(o(166));if(e=he.current,jn(t)){if(e=t.stateNode,l=t.memoizedProps,a=null,s=ut,s!==null)switch(s.tag){case 27:case 5:a=s.memoizedProps}e[it]=t,e=!!(e.nodeValue===l||a!==null&&a.suppressHydrationWarning===!0||_m(e.nodeValue,l)),e||Jl(t,!0)}else e=Nu(e).createTextNode(a),e[it]=t,t.stateNode=e}return Be(t),null;case 31:if(l=t.memoizedState,e===null||e.memoizedState!==null){if(a=jn(t),l!==null){if(e===null){if(!a)throw Error(o(318));if(e=t.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(o(557));e[it]=t}else Ua(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;Be(t),e=!1}else l=Ur(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=l),e=!0;if(!e)return t.flags&256?(Ut(t),t):(Ut(t),null);if((t.flags&128)!==0)throw Error(o(558))}return Be(t),null;case 13:if(a=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(s=jn(t),a!==null&&a.dehydrated!==null){if(e===null){if(!s)throw Error(o(318));if(s=t.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(o(317));s[it]=t}else Ua(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;Be(t),s=!1}else s=Ur(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=s),s=!0;if(!s)return t.flags&256?(Ut(t),t):(Ut(t),null)}return Ut(t),(t.flags&128)!==0?(t.lanes=l,t):(l=a!==null,e=e!==null&&e.memoizedState!==null,l&&(a=t.child,s=null,a.alternate!==null&&a.alternate.memoizedState!==null&&a.alternate.memoizedState.cachePool!==null&&(s=a.alternate.memoizedState.cachePool.pool),u=null,a.memoizedState!==null&&a.memoizedState.cachePool!==null&&(u=a.memoizedState.cachePool.pool),u!==s&&(a.flags|=2048)),l!==e&&l&&(t.child.flags|=8192),ru(t,t.updateQueue),Be(t),null);case 4:return De(),e===null&&Zc(t.stateNode.containerInfo),Be(t),null;case 10:return Nl(t.type),Be(t),null;case 19:if(X(Ve),a=t.memoizedState,a===null)return Be(t),null;if(s=(t.flags&128)!==0,u=a.rendering,u===null)if(s)Ls(a,!1);else{if(Ye!==0||e!==null&&(e.flags&128)!==0)for(e=t.child;e!==null;){if(u=$i(e),u!==null){for(t.flags|=128,Ls(a,!1),e=u.updateQueue,t.updateQueue=e,ru(t,e),t.subtreeFlags=0,e=l,l=t.child;l!==null;)od(l,e),l=l.sibling;return J(Ve,Ve.current&1|2),Se&&Sl(t,a.treeForkCount),t.child}e=e.sibling}a.tail!==null&&At()>hu&&(t.flags|=128,s=!0,Ls(a,!1),t.lanes=4194304)}else{if(!s)if(e=$i(u),e!==null){if(t.flags|=128,s=!0,e=e.updateQueue,t.updateQueue=e,ru(t,e),Ls(a,!0),a.tail===null&&a.tailMode==="hidden"&&!u.alternate&&!Se)return Be(t),null}else 2*At()-a.renderingStartTime>hu&&l!==536870912&&(t.flags|=128,s=!0,Ls(a,!1),t.lanes=4194304);a.isBackwards?(u.sibling=t.child,t.child=u):(e=a.last,e!==null?e.sibling=u:t.child=u,a.last=u)}return a.tail!==null?(e=a.tail,a.rendering=e,a.tail=e.sibling,a.renderingStartTime=At(),e.sibling=null,l=Ve.current,J(Ve,s?l&1|2:l&1),Se&&Sl(t,a.treeForkCount),e):(Be(t),null);case 22:case 23:return Ut(t),Jr(),a=t.memoizedState!==null,e!==null?e.memoizedState!==null!==a&&(t.flags|=8192):a&&(t.flags|=8192),a?(l&536870912)!==0&&(t.flags&128)===0&&(Be(t),t.subtreeFlags&6&&(t.flags|=8192)):Be(t),l=t.updateQueue,l!==null&&ru(t,l.retryQueue),l=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(l=e.memoizedState.cachePool.pool),a=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(a=t.memoizedState.cachePool.pool),a!==l&&(t.flags|=2048),e!==null&&X(Ba),null;case 24:return l=null,e!==null&&(l=e.memoizedState.cache),t.memoizedState.cache!==l&&(t.flags|=2048),Nl(Je),Be(t),null;case 25:return null;case 30:return null}throw Error(o(156,t.tag))}function yy(e,t){switch(wr(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Nl(Je),De(),e=t.flags,(e&65536)!==0&&(e&128)===0?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return Ta(t),null;case 31:if(t.memoizedState!==null){if(Ut(t),t.alternate===null)throw Error(o(340));Ua()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(Ut(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(o(340));Ua()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return X(Ve),null;case 4:return De(),null;case 10:return Nl(t.type),null;case 22:case 23:return Ut(t),Jr(),e!==null&&X(Ba),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Nl(Je),null;case 25:return null;default:return null}}function qh(e,t){switch(wr(t),t.tag){case 3:Nl(Je),De();break;case 26:case 27:case 5:Ta(t);break;case 4:De();break;case 31:t.memoizedState!==null&&Ut(t);break;case 13:Ut(t);break;case 19:X(Ve);break;case 10:Nl(t.type);break;case 22:case 23:Ut(t),Jr(),e!==null&&X(Ba);break;case 24:Nl(Je)}}function ks(e,t){try{var l=t.updateQueue,a=l!==null?l.lastEffect:null;if(a!==null){var s=a.next;l=s;do{if((l.tag&e)===e){a=void 0;var u=l.create,f=l.inst;a=u(),f.destroy=a}l=l.next}while(l!==s)}}catch(m){Me(t,t.return,m)}}function ta(e,t,l){try{var a=t.updateQueue,s=a!==null?a.lastEffect:null;if(s!==null){var u=s.next;a=u;do{if((a.tag&e)===e){var f=a.inst,m=f.destroy;if(m!==void 0){f.destroy=void 0,s=t;var j=l,_=m;try{_()}catch(B){Me(s,j,B)}}}a=a.next}while(a!==u)}}catch(B){Me(t,t.return,B)}}function Bh(e){var t=e.updateQueue;if(t!==null){var l=e.stateNode;try{Rd(t,l)}catch(a){Me(e,e.return,a)}}}function Lh(e,t,l){l.props=Ga(e.type,e.memoizedProps),l.state=e.memoizedState;try{l.componentWillUnmount()}catch(a){Me(e,t,a)}}function Qs(e,t){try{var l=e.ref;if(l!==null){switch(e.tag){case 26:case 27:case 5:var a=e.stateNode;break;case 30:a=e.stateNode;break;default:a=e.stateNode}typeof l=="function"?e.refCleanup=l(a):l.current=a}}catch(s){Me(e,t,s)}}function ol(e,t){var l=e.ref,a=e.refCleanup;if(l!==null)if(typeof a=="function")try{a()}catch(s){Me(e,t,s)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof l=="function")try{l(null)}catch(s){Me(e,t,s)}else l.current=null}function kh(e){var t=e.type,l=e.memoizedProps,a=e.stateNode;try{e:switch(t){case"button":case"input":case"select":case"textarea":l.autoFocus&&a.focus();break e;case"img":l.src?a.src=l.src:l.srcSet&&(a.srcset=l.srcSet)}}catch(s){Me(e,e.return,s)}}function Tc(e,t,l){try{var a=e.stateNode;ky(a,e.type,l,t),a[bt]=t}catch(s){Me(e,e.return,s)}}function Qh(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&ra(e.type)||e.tag===4}function Oc(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Qh(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.tag===27&&ra(e.type)||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 Rc(e,t,l){var a=e.tag;if(a===5||a===6)e=e.stateNode,t?(l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l).insertBefore(e,t):(t=l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l,t.appendChild(e),l=l._reactRootContainer,l!=null||t.onclick!==null||(t.onclick=yl));else if(a!==4&&(a===27&&ra(e.type)&&(l=e.stateNode,t=null),e=e.child,e!==null))for(Rc(e,t,l),e=e.sibling;e!==null;)Rc(e,t,l),e=e.sibling}function cu(e,t,l){var a=e.tag;if(a===5||a===6)e=e.stateNode,t?l.insertBefore(e,t):l.appendChild(e);else if(a!==4&&(a===27&&ra(e.type)&&(l=e.stateNode),e=e.child,e!==null))for(cu(e,t,l),e=e.sibling;e!==null;)cu(e,t,l),e=e.sibling}function Yh(e){var t=e.stateNode,l=e.memoizedProps;try{for(var a=e.type,s=t.attributes;s.length;)t.removeAttributeNode(s[0]);ot(t,a,l),t[it]=e,t[bt]=l}catch(u){Me(e,e.return,u)}}var Rl=!1,We=!1,Ac=!1,Gh=typeof WeakSet=="function"?WeakSet:Set,at=null;function gy(e,t){if(e=e.containerInfo,Fc=Mu,e=td(e),jr(e)){if("selectionStart"in e)var l={start:e.selectionStart,end:e.selectionEnd};else e:{l=(l=e.ownerDocument)&&l.defaultView||window;var a=l.getSelection&&l.getSelection();if(a&&a.rangeCount!==0){l=a.anchorNode;var s=a.anchorOffset,u=a.focusNode;a=a.focusOffset;try{l.nodeType,u.nodeType}catch{l=null;break e}var f=0,m=-1,j=-1,_=0,B=0,K=e,w=null;t:for(;;){for(var D;K!==l||s!==0&&K.nodeType!==3||(m=f+s),K!==u||a!==0&&K.nodeType!==3||(j=f+a),K.nodeType===3&&(f+=K.nodeValue.length),(D=K.firstChild)!==null;)w=K,K=D;for(;;){if(K===e)break t;if(w===l&&++_===s&&(m=f),w===u&&++B===a&&(j=f),(D=K.nextSibling)!==null)break;K=w,w=K.parentNode}K=D}l=m===-1||j===-1?null:{start:m,end:j}}else l=null}l=l||{start:0,end:0}}else l=null;for(Wc={focusedElem:e,selectionRange:l},Mu=!1,at=t;at!==null;)if(t=at,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,at=e;else for(;at!==null;){switch(t=at,u=t.alternate,e=t.flags,t.tag){case 0:if((e&4)!==0&&(e=t.updateQueue,e=e!==null?e.events:null,e!==null))for(l=0;l<e.length;l++)s=e[l],s.ref.impl=s.nextImpl;break;case 11:case 15:break;case 1:if((e&1024)!==0&&u!==null){e=void 0,l=t,s=u.memoizedProps,u=u.memoizedState,a=l.stateNode;try{var te=Ga(l.type,s);e=a.getSnapshotBeforeUpdate(te,u),a.__reactInternalSnapshotBeforeUpdate=e}catch(ie){Me(l,l.return,ie)}}break;case 3:if((e&1024)!==0){if(e=t.stateNode.containerInfo,l=e.nodeType,l===9)eo(e);else if(l===1)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":eo(e);break;default:e.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((e&1024)!==0)throw Error(o(163))}if(e=t.sibling,e!==null){e.return=t.return,at=e;break}at=t.return}}function Xh(e,t,l){var a=l.flags;switch(l.tag){case 0:case 11:case 15:Ml(e,l),a&4&&ks(5,l);break;case 1:if(Ml(e,l),a&4)if(e=l.stateNode,t===null)try{e.componentDidMount()}catch(f){Me(l,l.return,f)}else{var s=Ga(l.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(s,t,e.__reactInternalSnapshotBeforeUpdate)}catch(f){Me(l,l.return,f)}}a&64&&Bh(l),a&512&&Qs(l,l.return);break;case 3:if(Ml(e,l),a&64&&(e=l.updateQueue,e!==null)){if(t=null,l.child!==null)switch(l.child.tag){case 27:case 5:t=l.child.stateNode;break;case 1:t=l.child.stateNode}try{Rd(e,t)}catch(f){Me(l,l.return,f)}}break;case 27:t===null&&a&4&&Yh(l);case 26:case 5:Ml(e,l),t===null&&a&4&&kh(l),a&512&&Qs(l,l.return);break;case 12:Ml(e,l);break;case 31:Ml(e,l),a&4&&Zh(e,l);break;case 13:Ml(e,l),a&4&&Jh(e,l),a&64&&(e=l.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(l=Ry.bind(null,l),Jy(e,l))));break;case 22:if(a=l.memoizedState!==null||Rl,!a){t=t!==null&&t.memoizedState!==null||We,s=Rl;var u=We;Rl=a,(We=t)&&!u?zl(e,l,(l.subtreeFlags&8772)!==0):Ml(e,l),Rl=s,We=u}break;case 30:break;default:Ml(e,l)}}function Kh(e){var t=e.alternate;t!==null&&(e.alternate=null,Kh(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&sr(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var Le=null,jt=!1;function Al(e,t,l){for(l=l.child;l!==null;)Vh(e,t,l),l=l.sibling}function Vh(e,t,l){if(Mt&&typeof Mt.onCommitFiberUnmount=="function")try{Mt.onCommitFiberUnmount(fs,l)}catch{}switch(l.tag){case 26:We||ol(l,t),Al(e,t,l),l.memoizedState?l.memoizedState.count--:l.stateNode&&(l=l.stateNode,l.parentNode.removeChild(l));break;case 27:We||ol(l,t);var a=Le,s=jt;ra(l.type)&&(Le=l.stateNode,jt=!1),Al(e,t,l),Fs(l.stateNode),Le=a,jt=s;break;case 5:We||ol(l,t);case 6:if(a=Le,s=jt,Le=null,Al(e,t,l),Le=a,jt=s,Le!==null)if(jt)try{(Le.nodeType===9?Le.body:Le.nodeName==="HTML"?Le.ownerDocument.body:Le).removeChild(l.stateNode)}catch(u){Me(l,t,u)}else try{Le.removeChild(l.stateNode)}catch(u){Me(l,t,u)}break;case 18:Le!==null&&(jt?(e=Le,Bm(e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,l.stateNode),Gn(e)):Bm(Le,l.stateNode));break;case 4:a=Le,s=jt,Le=l.stateNode.containerInfo,jt=!0,Al(e,t,l),Le=a,jt=s;break;case 0:case 11:case 14:case 15:ta(2,l,t),We||ta(4,l,t),Al(e,t,l);break;case 1:We||(ol(l,t),a=l.stateNode,typeof a.componentWillUnmount=="function"&&Lh(l,t,a)),Al(e,t,l);break;case 21:Al(e,t,l);break;case 22:We=(a=We)||l.memoizedState!==null,Al(e,t,l),We=a;break;default:Al(e,t,l)}}function Zh(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Gn(e)}catch(l){Me(t,t.return,l)}}}function Jh(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Gn(e)}catch(l){Me(t,t.return,l)}}function by(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new Gh),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new Gh),t;default:throw Error(o(435,e.tag))}}function ou(e,t){var l=by(e);t.forEach(function(a){if(!l.has(a)){l.add(a);var s=Ay.bind(null,e,a);a.then(s,s)}})}function Nt(e,t){var l=t.deletions;if(l!==null)for(var a=0;a<l.length;a++){var s=l[a],u=e,f=t,m=f;e:for(;m!==null;){switch(m.tag){case 27:if(ra(m.type)){Le=m.stateNode,jt=!1;break e}break;case 5:Le=m.stateNode,jt=!1;break e;case 3:case 4:Le=m.stateNode.containerInfo,jt=!0;break e}m=m.return}if(Le===null)throw Error(o(160));Vh(u,f,s),Le=null,jt=!1,u=s.alternate,u!==null&&(u.return=null),s.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)$h(t,e),t=t.sibling}var al=null;function $h(e,t){var l=e.alternate,a=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:Nt(t,e),Et(e),a&4&&(ta(3,e,e.return),ks(3,e),ta(5,e,e.return));break;case 1:Nt(t,e),Et(e),a&512&&(We||l===null||ol(l,l.return)),a&64&&Rl&&(e=e.updateQueue,e!==null&&(a=e.callbacks,a!==null&&(l=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=l===null?a:l.concat(a))));break;case 26:var s=al;if(Nt(t,e),Et(e),a&512&&(We||l===null||ol(l,l.return)),a&4){var u=l!==null?l.memoizedState:null;if(a=e.memoizedState,l===null)if(a===null)if(e.stateNode===null){e:{a=e.type,l=e.memoizedProps,s=s.ownerDocument||s;t:switch(a){case"title":u=s.getElementsByTagName("title")[0],(!u||u[ms]||u[it]||u.namespaceURI==="http://www.w3.org/2000/svg"||u.hasAttribute("itemprop"))&&(u=s.createElement(a),s.head.insertBefore(u,s.querySelector("head > title"))),ot(u,a,l),u[it]=e,lt(u),a=u;break e;case"link":var f=$m("link","href",s).get(a+(l.href||""));if(f){for(var m=0;m<f.length;m++)if(u=f[m],u.getAttribute("href")===(l.href==null||l.href===""?null:l.href)&&u.getAttribute("rel")===(l.rel==null?null:l.rel)&&u.getAttribute("title")===(l.title==null?null:l.title)&&u.getAttribute("crossorigin")===(l.crossOrigin==null?null:l.crossOrigin)){f.splice(m,1);break t}}u=s.createElement(a),ot(u,a,l),s.head.appendChild(u);break;case"meta":if(f=$m("meta","content",s).get(a+(l.content||""))){for(m=0;m<f.length;m++)if(u=f[m],u.getAttribute("content")===(l.content==null?null:""+l.content)&&u.getAttribute("name")===(l.name==null?null:l.name)&&u.getAttribute("property")===(l.property==null?null:l.property)&&u.getAttribute("http-equiv")===(l.httpEquiv==null?null:l.httpEquiv)&&u.getAttribute("charset")===(l.charSet==null?null:l.charSet)){f.splice(m,1);break t}}u=s.createElement(a),ot(u,a,l),s.head.appendChild(u);break;default:throw Error(o(468,a))}u[it]=e,lt(u),a=u}e.stateNode=a}else Fm(s,e.type,e.stateNode);else e.stateNode=Jm(s,a,e.memoizedProps);else u!==a?(u===null?l.stateNode!==null&&(l=l.stateNode,l.parentNode.removeChild(l)):u.count--,a===null?Fm(s,e.type,e.stateNode):Jm(s,a,e.memoizedProps)):a===null&&e.stateNode!==null&&Tc(e,e.memoizedProps,l.memoizedProps)}break;case 27:Nt(t,e),Et(e),a&512&&(We||l===null||ol(l,l.return)),l!==null&&a&4&&Tc(e,e.memoizedProps,l.memoizedProps);break;case 5:if(Nt(t,e),Et(e),a&512&&(We||l===null||ol(l,l.return)),e.flags&32){s=e.stateNode;try{dn(s,"")}catch(te){Me(e,e.return,te)}}a&4&&e.stateNode!=null&&(s=e.memoizedProps,Tc(e,s,l!==null?l.memoizedProps:s)),a&1024&&(Ac=!0);break;case 6:if(Nt(t,e),Et(e),a&4){if(e.stateNode===null)throw Error(o(162));a=e.memoizedProps,l=e.stateNode;try{l.nodeValue=a}catch(te){Me(e,e.return,te)}}break;case 3:if(Tu=null,s=al,al=Eu(t.containerInfo),Nt(t,e),al=s,Et(e),a&4&&l!==null&&l.memoizedState.isDehydrated)try{Gn(t.containerInfo)}catch(te){Me(e,e.return,te)}Ac&&(Ac=!1,Fh(e));break;case 4:a=al,al=Eu(e.stateNode.containerInfo),Nt(t,e),Et(e),al=a;break;case 12:Nt(t,e),Et(e);break;case 31:Nt(t,e),Et(e),a&4&&(a=e.updateQueue,a!==null&&(e.updateQueue=null,ou(e,a)));break;case 13:Nt(t,e),Et(e),e.child.flags&8192&&e.memoizedState!==null!=(l!==null&&l.memoizedState!==null)&&(du=At()),a&4&&(a=e.updateQueue,a!==null&&(e.updateQueue=null,ou(e,a)));break;case 22:s=e.memoizedState!==null;var j=l!==null&&l.memoizedState!==null,_=Rl,B=We;if(Rl=_||s,We=B||j,Nt(t,e),We=B,Rl=_,Et(e),a&8192)e:for(t=e.stateNode,t._visibility=s?t._visibility&-2:t._visibility|1,s&&(l===null||j||Rl||We||Xa(e)),l=null,t=e;;){if(t.tag===5||t.tag===26){if(l===null){j=l=t;try{if(u=j.stateNode,s)f=u.style,typeof f.setProperty=="function"?f.setProperty("display","none","important"):f.display="none";else{m=j.stateNode;var K=j.memoizedProps.style,w=K!=null&&K.hasOwnProperty("display")?K.display:null;m.style.display=w==null||typeof w=="boolean"?"":(""+w).trim()}}catch(te){Me(j,j.return,te)}}}else if(t.tag===6){if(l===null){j=t;try{j.stateNode.nodeValue=s?"":j.memoizedProps}catch(te){Me(j,j.return,te)}}}else if(t.tag===18){if(l===null){j=t;try{var D=j.stateNode;s?Lm(D,!0):Lm(j.stateNode,!1)}catch(te){Me(j,j.return,te)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break e;for(;t.sibling===null;){if(t.return===null||t.return===e)break e;l===t&&(l=null),t=t.return}l===t&&(l=null),t.sibling.return=t.return,t=t.sibling}a&4&&(a=e.updateQueue,a!==null&&(l=a.retryQueue,l!==null&&(a.retryQueue=null,ou(e,l))));break;case 19:Nt(t,e),Et(e),a&4&&(a=e.updateQueue,a!==null&&(e.updateQueue=null,ou(e,a)));break;case 30:break;case 21:break;default:Nt(t,e),Et(e)}}function Et(e){var t=e.flags;if(t&2){try{for(var l,a=e.return;a!==null;){if(Qh(a)){l=a;break}a=a.return}if(l==null)throw Error(o(160));switch(l.tag){case 27:var s=l.stateNode,u=Oc(e);cu(e,u,s);break;case 5:var f=l.stateNode;l.flags&32&&(dn(f,""),l.flags&=-33);var m=Oc(e);cu(e,m,f);break;case 3:case 4:var j=l.stateNode.containerInfo,_=Oc(e);Rc(e,_,j);break;default:throw Error(o(161))}}catch(B){Me(e,e.return,B)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Fh(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;Fh(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function Ml(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)Xh(e,t.alternate,t),t=t.sibling}function Xa(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:ta(4,t,t.return),Xa(t);break;case 1:ol(t,t.return);var l=t.stateNode;typeof l.componentWillUnmount=="function"&&Lh(t,t.return,l),Xa(t);break;case 27:Fs(t.stateNode);case 26:case 5:ol(t,t.return),Xa(t);break;case 22:t.memoizedState===null&&Xa(t);break;case 30:Xa(t);break;default:Xa(t)}e=e.sibling}}function zl(e,t,l){for(l=l&&(t.subtreeFlags&8772)!==0,t=t.child;t!==null;){var a=t.alternate,s=e,u=t,f=u.flags;switch(u.tag){case 0:case 11:case 15:zl(s,u,l),ks(4,u);break;case 1:if(zl(s,u,l),a=u,s=a.stateNode,typeof s.componentDidMount=="function")try{s.componentDidMount()}catch(_){Me(a,a.return,_)}if(a=u,s=a.updateQueue,s!==null){var m=a.stateNode;try{var j=s.shared.hiddenCallbacks;if(j!==null)for(s.shared.hiddenCallbacks=null,s=0;s<j.length;s++)Od(j[s],m)}catch(_){Me(a,a.return,_)}}l&&f&64&&Bh(u),Qs(u,u.return);break;case 27:Yh(u);case 26:case 5:zl(s,u,l),l&&a===null&&f&4&&kh(u),Qs(u,u.return);break;case 12:zl(s,u,l);break;case 31:zl(s,u,l),l&&f&4&&Zh(s,u);break;case 13:zl(s,u,l),l&&f&4&&Jh(s,u);break;case 22:u.memoizedState===null&&zl(s,u,l),Qs(u,u.return);break;case 30:break;default:zl(s,u,l)}t=t.sibling}}function Mc(e,t){var l=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(l=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==l&&(e!=null&&e.refCount++,l!=null&&Os(l))}function zc(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&Os(e))}function nl(e,t,l,a){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Wh(e,t,l,a),t=t.sibling}function Wh(e,t,l,a){var s=t.flags;switch(t.tag){case 0:case 11:case 15:nl(e,t,l,a),s&2048&&ks(9,t);break;case 1:nl(e,t,l,a);break;case 3:nl(e,t,l,a),s&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&Os(e)));break;case 12:if(s&2048){nl(e,t,l,a),e=t.stateNode;try{var u=t.memoizedProps,f=u.id,m=u.onPostCommit;typeof m=="function"&&m(f,t.alternate===null?"mount":"update",e.passiveEffectDuration,-0)}catch(j){Me(t,t.return,j)}}else nl(e,t,l,a);break;case 31:nl(e,t,l,a);break;case 13:nl(e,t,l,a);break;case 23:break;case 22:u=t.stateNode,f=t.alternate,t.memoizedState!==null?u._visibility&2?nl(e,t,l,a):Ys(e,t):u._visibility&2?nl(e,t,l,a):(u._visibility|=2,_n(e,t,l,a,(t.subtreeFlags&10256)!==0||!1)),s&2048&&Mc(f,t);break;case 24:nl(e,t,l,a),s&2048&&zc(t.alternate,t);break;default:nl(e,t,l,a)}}function _n(e,t,l,a,s){for(s=s&&((t.subtreeFlags&10256)!==0||!1),t=t.child;t!==null;){var u=e,f=t,m=l,j=a,_=f.flags;switch(f.tag){case 0:case 11:case 15:_n(u,f,m,j,s),ks(8,f);break;case 23:break;case 22:var B=f.stateNode;f.memoizedState!==null?B._visibility&2?_n(u,f,m,j,s):Ys(u,f):(B._visibility|=2,_n(u,f,m,j,s)),s&&_&2048&&Mc(f.alternate,f);break;case 24:_n(u,f,m,j,s),s&&_&2048&&zc(f.alternate,f);break;default:_n(u,f,m,j,s)}t=t.sibling}}function Ys(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var l=e,a=t,s=a.flags;switch(a.tag){case 22:Ys(l,a),s&2048&&Mc(a.alternate,a);break;case 24:Ys(l,a),s&2048&&zc(a.alternate,a);break;default:Ys(l,a)}t=t.sibling}}var Gs=8192;function wn(e,t,l){if(e.subtreeFlags&Gs)for(e=e.child;e!==null;)Ih(e,t,l),e=e.sibling}function Ih(e,t,l){switch(e.tag){case 26:wn(e,t,l),e.flags&Gs&&e.memoizedState!==null&&i0(l,al,e.memoizedState,e.memoizedProps);break;case 5:wn(e,t,l);break;case 3:case 4:var a=al;al=Eu(e.stateNode.containerInfo),wn(e,t,l),al=a;break;case 22:e.memoizedState===null&&(a=e.alternate,a!==null&&a.memoizedState!==null?(a=Gs,Gs=16777216,wn(e,t,l),Gs=a):wn(e,t,l));break;default:wn(e,t,l)}}function Ph(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Xs(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var l=0;l<t.length;l++){var a=t[l];at=a,tm(a,e)}Ph(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)em(e),e=e.sibling}function em(e){switch(e.tag){case 0:case 11:case 15:Xs(e),e.flags&2048&&ta(9,e,e.return);break;case 3:Xs(e);break;case 12:Xs(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,fu(e)):Xs(e);break;default:Xs(e)}}function fu(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var l=0;l<t.length;l++){var a=t[l];at=a,tm(a,e)}Ph(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:ta(8,t,t.return),fu(t);break;case 22:l=t.stateNode,l._visibility&2&&(l._visibility&=-3,fu(t));break;default:fu(t)}e=e.sibling}}function tm(e,t){for(;at!==null;){var l=at;switch(l.tag){case 0:case 11:case 15:ta(8,l,t);break;case 23:case 22:if(l.memoizedState!==null&&l.memoizedState.cachePool!==null){var a=l.memoizedState.cachePool.pool;a!=null&&a.refCount++}break;case 24:Os(l.memoizedState.cache)}if(a=l.child,a!==null)a.return=l,at=a;else e:for(l=e;at!==null;){a=at;var s=a.sibling,u=a.return;if(Kh(a),a===l){at=null;break e}if(s!==null){s.return=u,at=s;break e}at=u}}}var Sy={getCacheForType:function(e){var t=rt(Je),l=t.data.get(e);return l===void 0&&(l=e(),t.data.set(e,l)),l},cacheSignal:function(){return rt(Je).controller.signal}},jy=typeof WeakMap=="function"?WeakMap:Map,Te=0,Ue=null,xe=null,ge=0,Ae=0,Ht=null,la=!1,Dn=!1,_c=!1,_l=0,Ye=0,aa=0,Ka=0,wc=0,qt=0,Un=0,Ks=null,Ct=null,Dc=!1,du=0,lm=0,hu=1/0,mu=null,na=null,Pe=0,sa=null,Hn=null,wl=0,Uc=0,Hc=null,am=null,Vs=0,qc=null;function Bt(){return(Te&2)!==0&&ge!==0?ge&-ge:L.T!==null?Gc():gf()}function nm(){if(qt===0)if((ge&536870912)===0||Se){var e=ji;ji<<=1,(ji&3932160)===0&&(ji=262144),qt=e}else qt=536870912;return e=Dt.current,e!==null&&(e.flags|=32),qt}function Tt(e,t,l){(e===Ue&&(Ae===2||Ae===9)||e.cancelPendingCommit!==null)&&(qn(e,0),ia(e,ge,qt,!1)),hs(e,l),((Te&2)===0||e!==Ue)&&(e===Ue&&((Te&2)===0&&(Ka|=l),Ye===4&&ia(e,ge,qt,!1)),fl(e))}function sm(e,t,l){if((Te&6)!==0)throw Error(o(327));var a=!l&&(t&127)===0&&(t&e.expiredLanes)===0||ds(e,t),s=a?Cy(e,t):Lc(e,t,!0),u=a;do{if(s===0){Dn&&!a&&ia(e,t,0,!1);break}else{if(l=e.current.alternate,u&&!Ny(l)){s=Lc(e,t,!1),u=!1;continue}if(s===2){if(u=t,e.errorRecoveryDisabledLanes&u)var f=0;else f=e.pendingLanes&-536870913,f=f!==0?f:f&536870912?536870912:0;if(f!==0){t=f;e:{var m=e;s=Ks;var j=m.current.memoizedState.isDehydrated;if(j&&(qn(m,f).flags|=256),f=Lc(m,f,!1),f!==2){if(_c&&!j){m.errorRecoveryDisabledLanes|=u,Ka|=u,s=4;break e}u=Ct,Ct=s,u!==null&&(Ct===null?Ct=u:Ct.push.apply(Ct,u))}s=f}if(u=!1,s!==2)continue}}if(s===1){qn(e,0),ia(e,t,0,!0);break}e:{switch(a=e,u=s,u){case 0:case 1:throw Error(o(345));case 4:if((t&4194048)!==t)break;case 6:ia(a,t,qt,!la);break e;case 2:Ct=null;break;case 3:case 5:break;default:throw Error(o(329))}if((t&62914560)===t&&(s=du+300-At(),10<s)){if(ia(a,t,qt,!la),Ei(a,0,!0)!==0)break e;wl=t,a.timeoutHandle=Hm(im.bind(null,a,l,Ct,mu,Dc,t,qt,Ka,Un,la,u,"Throttled",-0,0),s);break e}im(a,l,Ct,mu,Dc,t,qt,Ka,Un,la,u,null,-0,0)}}break}while(!0);fl(e)}function im(e,t,l,a,s,u,f,m,j,_,B,K,w,D){if(e.timeoutHandle=-1,K=t.subtreeFlags,K&8192||(K&16785408)===16785408){K={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:yl},Ih(t,u,K);var te=(u&62914560)===u?du-At():(u&4194048)===u?lm-At():0;if(te=u0(K,te),te!==null){wl=u,e.cancelPendingCommit=te(mm.bind(null,e,t,u,l,a,s,f,m,j,B,K,null,w,D)),ia(e,u,f,!_);return}}mm(e,t,u,l,a,s,f,m,j)}function Ny(e){for(var t=e;;){var l=t.tag;if((l===0||l===11||l===15)&&t.flags&16384&&(l=t.updateQueue,l!==null&&(l=l.stores,l!==null)))for(var a=0;a<l.length;a++){var s=l[a],u=s.getSnapshot;s=s.value;try{if(!_t(u(),s))return!1}catch{return!1}}if(l=t.child,t.subtreeFlags&16384&&l!==null)l.return=t,t=l;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 ia(e,t,l,a){t&=~wc,t&=~Ka,e.suspendedLanes|=t,e.pingedLanes&=~t,a&&(e.warmLanes|=t),a=e.expirationTimes;for(var s=t;0<s;){var u=31-zt(s),f=1<<u;a[u]=-1,s&=~f}l!==0&&vf(e,l,t)}function pu(){return(Te&6)===0?(Zs(0),!1):!0}function Bc(){if(xe!==null){if(Ae===0)var e=xe.return;else e=xe,jl=Ha=null,ec(e),On=null,As=0,e=xe;for(;e!==null;)qh(e.alternate,e),e=e.return;xe=null}}function qn(e,t){var l=e.timeoutHandle;l!==-1&&(e.timeoutHandle=-1,Gy(l)),l=e.cancelPendingCommit,l!==null&&(e.cancelPendingCommit=null,l()),wl=0,Bc(),Ue=e,xe=l=bl(e.current,null),ge=t,Ae=0,Ht=null,la=!1,Dn=ds(e,t),_c=!1,Un=qt=wc=Ka=aa=Ye=0,Ct=Ks=null,Dc=!1,(t&8)!==0&&(t|=t&32);var a=e.entangledLanes;if(a!==0)for(e=e.entanglements,a&=t;0<a;){var s=31-zt(a),u=1<<s;t|=e[s],a&=~u}return _l=t,Hi(),l}function um(e,t){fe=null,L.H=qs,t===Tn||t===Xi?(t=Nd(),Ae=3):t===Yr?(t=Nd(),Ae=4):Ae=t===vc?8:t!==null&&typeof t=="object"&&typeof t.then=="function"?6:1,Ht=t,xe===null&&(Ye=1,nu(e,Vt(t,e.current)))}function rm(){var e=Dt.current;return e===null?!0:(ge&4194048)===ge?Ft===null:(ge&62914560)===ge||(ge&536870912)!==0?e===Ft:!1}function cm(){var e=L.H;return L.H=qs,e===null?qs:e}function om(){var e=L.A;return L.A=Sy,e}function vu(){Ye=4,la||(ge&4194048)!==ge&&Dt.current!==null||(Dn=!0),(aa&134217727)===0&&(Ka&134217727)===0||Ue===null||ia(Ue,ge,qt,!1)}function Lc(e,t,l){var a=Te;Te|=2;var s=cm(),u=om();(Ue!==e||ge!==t)&&(mu=null,qn(e,t)),t=!1;var f=Ye;e:do try{if(Ae!==0&&xe!==null){var m=xe,j=Ht;switch(Ae){case 8:Bc(),f=6;break e;case 3:case 2:case 9:case 6:Dt.current===null&&(t=!0);var _=Ae;if(Ae=0,Ht=null,Bn(e,m,j,_),l&&Dn){f=0;break e}break;default:_=Ae,Ae=0,Ht=null,Bn(e,m,j,_)}}Ey(),f=Ye;break}catch(B){um(e,B)}while(!0);return t&&e.shellSuspendCounter++,jl=Ha=null,Te=a,L.H=s,L.A=u,xe===null&&(Ue=null,ge=0,Hi()),f}function Ey(){for(;xe!==null;)fm(xe)}function Cy(e,t){var l=Te;Te|=2;var a=cm(),s=om();Ue!==e||ge!==t?(mu=null,hu=At()+500,qn(e,t)):Dn=ds(e,t);e:do try{if(Ae!==0&&xe!==null){t=xe;var u=Ht;t:switch(Ae){case 1:Ae=0,Ht=null,Bn(e,t,u,1);break;case 2:case 9:if(Sd(u)){Ae=0,Ht=null,dm(t);break}t=function(){Ae!==2&&Ae!==9||Ue!==e||(Ae=7),fl(e)},u.then(t,t);break e;case 3:Ae=7;break e;case 4:Ae=5;break e;case 7:Sd(u)?(Ae=0,Ht=null,dm(t)):(Ae=0,Ht=null,Bn(e,t,u,7));break;case 5:var f=null;switch(xe.tag){case 26:f=xe.memoizedState;case 5:case 27:var m=xe;if(f?Wm(f):m.stateNode.complete){Ae=0,Ht=null;var j=m.sibling;if(j!==null)xe=j;else{var _=m.return;_!==null?(xe=_,xu(_)):xe=null}break t}}Ae=0,Ht=null,Bn(e,t,u,5);break;case 6:Ae=0,Ht=null,Bn(e,t,u,6);break;case 8:Bc(),Ye=6;break e;default:throw Error(o(462))}}Ty();break}catch(B){um(e,B)}while(!0);return jl=Ha=null,L.H=a,L.A=s,Te=l,xe!==null?0:(Ue=null,ge=0,Hi(),Ye)}function Ty(){for(;xe!==null&&!$v();)fm(xe)}function fm(e){var t=Uh(e.alternate,e,_l);e.memoizedProps=e.pendingProps,t===null?xu(e):xe=t}function dm(e){var t=e,l=t.alternate;switch(t.tag){case 15:case 0:t=Ah(l,t,t.pendingProps,t.type,void 0,ge);break;case 11:t=Ah(l,t,t.pendingProps,t.type.render,t.ref,ge);break;case 5:ec(t);default:qh(l,t),t=xe=od(t,_l),t=Uh(l,t,_l)}e.memoizedProps=e.pendingProps,t===null?xu(e):xe=t}function Bn(e,t,l,a){jl=Ha=null,ec(t),On=null,As=0;var s=t.return;try{if(my(e,s,t,l,ge)){Ye=1,nu(e,Vt(l,e.current)),xe=null;return}}catch(u){if(s!==null)throw xe=s,u;Ye=1,nu(e,Vt(l,e.current)),xe=null;return}t.flags&32768?(Se||a===1?e=!0:Dn||(ge&536870912)!==0?e=!1:(la=e=!0,(a===2||a===9||a===3||a===6)&&(a=Dt.current,a!==null&&a.tag===13&&(a.flags|=16384))),hm(t,e)):xu(t)}function xu(e){var t=e;do{if((t.flags&32768)!==0){hm(t,la);return}e=t.return;var l=xy(t.alternate,t,_l);if(l!==null){xe=l;return}if(t=t.sibling,t!==null){xe=t;return}xe=t=e}while(t!==null);Ye===0&&(Ye=5)}function hm(e,t){do{var l=yy(e.alternate,e);if(l!==null){l.flags&=32767,xe=l;return}if(l=e.return,l!==null&&(l.flags|=32768,l.subtreeFlags=0,l.deletions=null),!t&&(e=e.sibling,e!==null)){xe=e;return}xe=e=l}while(e!==null);Ye=6,xe=null}function mm(e,t,l,a,s,u,f,m,j){e.cancelPendingCommit=null;do yu();while(Pe!==0);if((Te&6)!==0)throw Error(o(327));if(t!==null){if(t===e.current)throw Error(o(177));if(u=t.lanes|t.childLanes,u|=Or,sx(e,l,u,f,m,j),e===Ue&&(xe=Ue=null,ge=0),Hn=t,sa=e,wl=l,Uc=u,Hc=s,am=a,(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?(e.callbackNode=null,e.callbackPriority=0,My(bi,function(){return gm(),null})):(e.callbackNode=null,e.callbackPriority=0),a=(t.flags&13878)!==0,(t.subtreeFlags&13878)!==0||a){a=L.T,L.T=null,s=F.p,F.p=2,f=Te,Te|=4;try{gy(e,t,l)}finally{Te=f,F.p=s,L.T=a}}Pe=1,pm(),vm(),xm()}}function pm(){if(Pe===1){Pe=0;var e=sa,t=Hn,l=(t.flags&13878)!==0;if((t.subtreeFlags&13878)!==0||l){l=L.T,L.T=null;var a=F.p;F.p=2;var s=Te;Te|=4;try{$h(t,e);var u=Wc,f=td(e.containerInfo),m=u.focusedElem,j=u.selectionRange;if(f!==m&&m&&m.ownerDocument&&ed(m.ownerDocument.documentElement,m)){if(j!==null&&jr(m)){var _=j.start,B=j.end;if(B===void 0&&(B=_),"selectionStart"in m)m.selectionStart=_,m.selectionEnd=Math.min(B,m.value.length);else{var K=m.ownerDocument||document,w=K&&K.defaultView||window;if(w.getSelection){var D=w.getSelection(),te=m.textContent.length,ie=Math.min(j.start,te),we=j.end===void 0?ie:Math.min(j.end,te);!D.extend&&ie>we&&(f=we,we=ie,ie=f);var T=Pf(m,ie),E=Pf(m,we);if(T&&E&&(D.rangeCount!==1||D.anchorNode!==T.node||D.anchorOffset!==T.offset||D.focusNode!==E.node||D.focusOffset!==E.offset)){var z=K.createRange();z.setStart(T.node,T.offset),D.removeAllRanges(),ie>we?(D.addRange(z),D.extend(E.node,E.offset)):(z.setEnd(E.node,E.offset),D.addRange(z))}}}}for(K=[],D=m;D=D.parentNode;)D.nodeType===1&&K.push({element:D,left:D.scrollLeft,top:D.scrollTop});for(typeof m.focus=="function"&&m.focus(),m=0;m<K.length;m++){var Q=K[m];Q.element.scrollLeft=Q.left,Q.element.scrollTop=Q.top}}Mu=!!Fc,Wc=Fc=null}finally{Te=s,F.p=a,L.T=l}}e.current=t,Pe=2}}function vm(){if(Pe===2){Pe=0;var e=sa,t=Hn,l=(t.flags&8772)!==0;if((t.subtreeFlags&8772)!==0||l){l=L.T,L.T=null;var a=F.p;F.p=2;var s=Te;Te|=4;try{Xh(e,t.alternate,t)}finally{Te=s,F.p=a,L.T=l}}Pe=3}}function xm(){if(Pe===4||Pe===3){Pe=0,Fv();var e=sa,t=Hn,l=wl,a=am;(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?Pe=5:(Pe=0,Hn=sa=null,ym(e,e.pendingLanes));var s=e.pendingLanes;if(s===0&&(na=null),ar(l),t=t.stateNode,Mt&&typeof Mt.onCommitFiberRoot=="function")try{Mt.onCommitFiberRoot(fs,t,void 0,(t.current.flags&128)===128)}catch{}if(a!==null){t=L.T,s=F.p,F.p=2,L.T=null;try{for(var u=e.onRecoverableError,f=0;f<a.length;f++){var m=a[f];u(m.value,{componentStack:m.stack})}}finally{L.T=t,F.p=s}}(wl&3)!==0&&yu(),fl(e),s=e.pendingLanes,(l&261930)!==0&&(s&42)!==0?e===qc?Vs++:(Vs=0,qc=e):Vs=0,Zs(0)}}function ym(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,Os(t)))}function yu(){return pm(),vm(),xm(),gm()}function gm(){if(Pe!==5)return!1;var e=sa,t=Uc;Uc=0;var l=ar(wl),a=L.T,s=F.p;try{F.p=32>l?32:l,L.T=null,l=Hc,Hc=null;var u=sa,f=wl;if(Pe=0,Hn=sa=null,wl=0,(Te&6)!==0)throw Error(o(331));var m=Te;if(Te|=4,em(u.current),Wh(u,u.current,f,l),Te=m,Zs(0,!1),Mt&&typeof Mt.onPostCommitFiberRoot=="function")try{Mt.onPostCommitFiberRoot(fs,u)}catch{}return!0}finally{F.p=s,L.T=a,ym(e,t)}}function bm(e,t,l){t=Vt(l,t),t=pc(e.stateNode,t,2),e=Il(e,t,2),e!==null&&(hs(e,2),fl(e))}function Me(e,t,l){if(e.tag===3)bm(e,e,l);else for(;t!==null;){if(t.tag===3){bm(t,e,l);break}else if(t.tag===1){var a=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof a.componentDidCatch=="function"&&(na===null||!na.has(a))){e=Vt(l,e),l=Sh(2),a=Il(t,l,2),a!==null&&(jh(l,a,t,e),hs(a,2),fl(a));break}}t=t.return}}function kc(e,t,l){var a=e.pingCache;if(a===null){a=e.pingCache=new jy;var s=new Set;a.set(t,s)}else s=a.get(t),s===void 0&&(s=new Set,a.set(t,s));s.has(l)||(_c=!0,s.add(l),e=Oy.bind(null,e,t,l),t.then(e,e))}function Oy(e,t,l){var a=e.pingCache;a!==null&&a.delete(t),e.pingedLanes|=e.suspendedLanes&l,e.warmLanes&=~l,Ue===e&&(ge&l)===l&&(Ye===4||Ye===3&&(ge&62914560)===ge&&300>At()-du?(Te&2)===0&&qn(e,0):wc|=l,Un===ge&&(Un=0)),fl(e)}function Sm(e,t){t===0&&(t=pf()),e=wa(e,t),e!==null&&(hs(e,t),fl(e))}function Ry(e){var t=e.memoizedState,l=0;t!==null&&(l=t.retryLane),Sm(e,l)}function Ay(e,t){var l=0;switch(e.tag){case 31:case 13:var a=e.stateNode,s=e.memoizedState;s!==null&&(l=s.retryLane);break;case 19:a=e.stateNode;break;case 22:a=e.stateNode._retryCache;break;default:throw Error(o(314))}a!==null&&a.delete(t),Sm(e,l)}function My(e,t){return Pu(e,t)}var gu=null,Ln=null,Qc=!1,bu=!1,Yc=!1,ua=0;function fl(e){e!==Ln&&e.next===null&&(Ln===null?gu=Ln=e:Ln=Ln.next=e),bu=!0,Qc||(Qc=!0,_y())}function Zs(e,t){if(!Yc&&bu){Yc=!0;do for(var l=!1,a=gu;a!==null;){if(e!==0){var s=a.pendingLanes;if(s===0)var u=0;else{var f=a.suspendedLanes,m=a.pingedLanes;u=(1<<31-zt(42|e)+1)-1,u&=s&~(f&~m),u=u&201326741?u&201326741|1:u?u|2:0}u!==0&&(l=!0,Cm(a,u))}else u=ge,u=Ei(a,a===Ue?u:0,a.cancelPendingCommit!==null||a.timeoutHandle!==-1),(u&3)===0||ds(a,u)||(l=!0,Cm(a,u));a=a.next}while(l);Yc=!1}}function zy(){jm()}function jm(){bu=Qc=!1;var e=0;ua!==0&&Yy()&&(e=ua);for(var t=At(),l=null,a=gu;a!==null;){var s=a.next,u=Nm(a,t);u===0?(a.next=null,l===null?gu=s:l.next=s,s===null&&(Ln=l)):(l=a,(e!==0||(u&3)!==0)&&(bu=!0)),a=s}Pe!==0&&Pe!==5||Zs(e),ua!==0&&(ua=0)}function Nm(e,t){for(var l=e.suspendedLanes,a=e.pingedLanes,s=e.expirationTimes,u=e.pendingLanes&-62914561;0<u;){var f=31-zt(u),m=1<<f,j=s[f];j===-1?((m&l)===0||(m&a)!==0)&&(s[f]=nx(m,t)):j<=t&&(e.expiredLanes|=m),u&=~m}if(t=Ue,l=ge,l=Ei(e,e===t?l:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),a=e.callbackNode,l===0||e===t&&(Ae===2||Ae===9)||e.cancelPendingCommit!==null)return a!==null&&a!==null&&er(a),e.callbackNode=null,e.callbackPriority=0;if((l&3)===0||ds(e,l)){if(t=l&-l,t===e.callbackPriority)return t;switch(a!==null&&er(a),ar(l)){case 2:case 8:l=hf;break;case 32:l=bi;break;case 268435456:l=mf;break;default:l=bi}return a=Em.bind(null,e),l=Pu(l,a),e.callbackPriority=t,e.callbackNode=l,t}return a!==null&&a!==null&&er(a),e.callbackPriority=2,e.callbackNode=null,2}function Em(e,t){if(Pe!==0&&Pe!==5)return e.callbackNode=null,e.callbackPriority=0,null;var l=e.callbackNode;if(yu()&&e.callbackNode!==l)return null;var a=ge;return a=Ei(e,e===Ue?a:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),a===0?null:(sm(e,a,t),Nm(e,At()),e.callbackNode!=null&&e.callbackNode===l?Em.bind(null,e):null)}function Cm(e,t){if(yu())return null;sm(e,t,!0)}function _y(){Xy(function(){(Te&6)!==0?Pu(df,zy):jm()})}function Gc(){if(ua===0){var e=En;e===0&&(e=Si,Si<<=1,(Si&261888)===0&&(Si=256)),ua=e}return ua}function Tm(e){return e==null||typeof e=="symbol"||typeof e=="boolean"?null:typeof e=="function"?e:Ri(""+e)}function Om(e,t){var l=t.ownerDocument.createElement("input");return l.name=t.name,l.value=t.value,e.id&&l.setAttribute("form",e.id),t.parentNode.insertBefore(l,t),e=new FormData(e),l.parentNode.removeChild(l),e}function wy(e,t,l,a,s){if(t==="submit"&&l&&l.stateNode===s){var u=Tm((s[bt]||null).action),f=a.submitter;f&&(t=(t=f[bt]||null)?Tm(t.formAction):f.getAttribute("formAction"),t!==null&&(u=t,f=null));var m=new _i("action","action",null,a,s);e.push({event:m,listeners:[{instance:null,listener:function(){if(a.defaultPrevented){if(ua!==0){var j=f?Om(s,f):new FormData(s);cc(l,{pending:!0,data:j,method:s.method,action:u},null,j)}}else typeof u=="function"&&(m.preventDefault(),j=f?Om(s,f):new FormData(s),cc(l,{pending:!0,data:j,method:s.method,action:u},u,j))},currentTarget:s}]})}}for(var Xc=0;Xc<Tr.length;Xc++){var Kc=Tr[Xc],Dy=Kc.toLowerCase(),Uy=Kc[0].toUpperCase()+Kc.slice(1);ll(Dy,"on"+Uy)}ll(nd,"onAnimationEnd"),ll(sd,"onAnimationIteration"),ll(id,"onAnimationStart"),ll("dblclick","onDoubleClick"),ll("focusin","onFocus"),ll("focusout","onBlur"),ll(Wx,"onTransitionRun"),ll(Ix,"onTransitionStart"),ll(Px,"onTransitionCancel"),ll(ud,"onTransitionEnd"),on("onMouseEnter",["mouseout","mouseover"]),on("onMouseLeave",["mouseout","mouseover"]),on("onPointerEnter",["pointerout","pointerover"]),on("onPointerLeave",["pointerout","pointerover"]),Aa("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Aa("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Aa("onBeforeInput",["compositionend","keypress","textInput","paste"]),Aa("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Aa("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Aa("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Js="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(" "),Hy=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Js));function Rm(e,t){t=(t&4)!==0;for(var l=0;l<e.length;l++){var a=e[l],s=a.event;a=a.listeners;e:{var u=void 0;if(t)for(var f=a.length-1;0<=f;f--){var m=a[f],j=m.instance,_=m.currentTarget;if(m=m.listener,j!==u&&s.isPropagationStopped())break e;u=m,s.currentTarget=_;try{u(s)}catch(B){Ui(B)}s.currentTarget=null,u=j}else for(f=0;f<a.length;f++){if(m=a[f],j=m.instance,_=m.currentTarget,m=m.listener,j!==u&&s.isPropagationStopped())break e;u=m,s.currentTarget=_;try{u(s)}catch(B){Ui(B)}s.currentTarget=null,u=j}}}}function ye(e,t){var l=t[nr];l===void 0&&(l=t[nr]=new Set);var a=e+"__bubble";l.has(a)||(Am(t,e,2,!1),l.add(a))}function Vc(e,t,l){var a=0;t&&(a|=4),Am(l,e,a,t)}var Su="_reactListening"+Math.random().toString(36).slice(2);function Zc(e){if(!e[Su]){e[Su]=!0,jf.forEach(function(l){l!=="selectionchange"&&(Hy.has(l)||Vc(l,!1,e),Vc(l,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Su]||(t[Su]=!0,Vc("selectionchange",!1,t))}}function Am(e,t,l,a){switch(np(t)){case 2:var s=o0;break;case 8:s=f0;break;default:s=ro}l=s.bind(null,t,l,e),s=void 0,!hr||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(s=!0),a?s!==void 0?e.addEventListener(t,l,{capture:!0,passive:s}):e.addEventListener(t,l,!0):s!==void 0?e.addEventListener(t,l,{passive:s}):e.addEventListener(t,l,!1)}function Jc(e,t,l,a,s){var u=a;if((t&1)===0&&(t&2)===0&&a!==null)e:for(;;){if(a===null)return;var f=a.tag;if(f===3||f===4){var m=a.stateNode.containerInfo;if(m===s)break;if(f===4)for(f=a.return;f!==null;){var j=f.tag;if((j===3||j===4)&&f.stateNode.containerInfo===s)return;f=f.return}for(;m!==null;){if(f=un(m),f===null)return;if(j=f.tag,j===5||j===6||j===26||j===27){a=u=f;continue e}m=m.parentNode}}a=a.return}Df(function(){var _=u,B=fr(l),K=[];e:{var w=rd.get(e);if(w!==void 0){var D=_i,te=e;switch(e){case"keypress":if(Mi(l)===0)break e;case"keydown":case"keyup":D=Ax;break;case"focusin":te="focus",D=xr;break;case"focusout":te="blur",D=xr;break;case"beforeblur":case"afterblur":D=xr;break;case"click":if(l.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":D=qf;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":D=xx;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":D=_x;break;case nd:case sd:case id:D=bx;break;case ud:D=Dx;break;case"scroll":case"scrollend":D=px;break;case"wheel":D=Hx;break;case"copy":case"cut":case"paste":D=jx;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":D=Lf;break;case"toggle":case"beforetoggle":D=Bx}var ie=(t&4)!==0,we=!ie&&(e==="scroll"||e==="scrollend"),T=ie?w!==null?w+"Capture":null:w;ie=[];for(var E=_,z;E!==null;){var Q=E;if(z=Q.stateNode,Q=Q.tag,Q!==5&&Q!==26&&Q!==27||z===null||T===null||(Q=vs(E,T),Q!=null&&ie.push($s(E,Q,z))),we)break;E=E.return}0<ie.length&&(w=new D(w,te,null,l,B),K.push({event:w,listeners:ie}))}}if((t&7)===0){e:{if(w=e==="mouseover"||e==="pointerover",D=e==="mouseout"||e==="pointerout",w&&l!==or&&(te=l.relatedTarget||l.fromElement)&&(un(te)||te[sn]))break e;if((D||w)&&(w=B.window===B?B:(w=B.ownerDocument)?w.defaultView||w.parentWindow:window,D?(te=l.relatedTarget||l.toElement,D=_,te=te?un(te):null,te!==null&&(we=h(te),ie=te.tag,te!==we||ie!==5&&ie!==27&&ie!==6)&&(te=null)):(D=null,te=_),D!==te)){if(ie=qf,Q="onMouseLeave",T="onMouseEnter",E="mouse",(e==="pointerout"||e==="pointerover")&&(ie=Lf,Q="onPointerLeave",T="onPointerEnter",E="pointer"),we=D==null?w:ps(D),z=te==null?w:ps(te),w=new ie(Q,E+"leave",D,l,B),w.target=we,w.relatedTarget=z,Q=null,un(B)===_&&(ie=new ie(T,E+"enter",te,l,B),ie.target=z,ie.relatedTarget=we,Q=ie),we=Q,D&&te)t:{for(ie=qy,T=D,E=te,z=0,Q=T;Q;Q=ie(Q))z++;Q=0;for(var se=E;se;se=ie(se))Q++;for(;0<z-Q;)T=ie(T),z--;for(;0<Q-z;)E=ie(E),Q--;for(;z--;){if(T===E||E!==null&&T===E.alternate){ie=T;break t}T=ie(T),E=ie(E)}ie=null}else ie=null;D!==null&&Mm(K,w,D,ie,!1),te!==null&&we!==null&&Mm(K,we,te,ie,!0)}}e:{if(w=_?ps(_):window,D=w.nodeName&&w.nodeName.toLowerCase(),D==="select"||D==="input"&&w.type==="file")var Ee=Zf;else if(Kf(w))if(Jf)Ee=Jx;else{Ee=Vx;var le=Kx}else D=w.nodeName,!D||D.toLowerCase()!=="input"||w.type!=="checkbox"&&w.type!=="radio"?_&&cr(_.elementType)&&(Ee=Zf):Ee=Zx;if(Ee&&(Ee=Ee(e,_))){Vf(K,Ee,l,B);break e}le&&le(e,w,_),e==="focusout"&&_&&w.type==="number"&&_.memoizedProps.value!=null&&rr(w,"number",w.value)}switch(le=_?ps(_):window,e){case"focusin":(Kf(le)||le.contentEditable==="true")&&(vn=le,Nr=_,Es=null);break;case"focusout":Es=Nr=vn=null;break;case"mousedown":Er=!0;break;case"contextmenu":case"mouseup":case"dragend":Er=!1,ld(K,l,B);break;case"selectionchange":if(Fx)break;case"keydown":case"keyup":ld(K,l,B)}var de;if(gr)e:{switch(e){case"compositionstart":var be="onCompositionStart";break e;case"compositionend":be="onCompositionEnd";break e;case"compositionupdate":be="onCompositionUpdate";break e}be=void 0}else pn?Gf(e,l)&&(be="onCompositionEnd"):e==="keydown"&&l.keyCode===229&&(be="onCompositionStart");be&&(kf&&l.locale!=="ko"&&(pn||be!=="onCompositionStart"?be==="onCompositionEnd"&&pn&&(de=Uf()):(Kl=B,mr="value"in Kl?Kl.value:Kl.textContent,pn=!0)),le=ju(_,be),0<le.length&&(be=new Bf(be,e,null,l,B),K.push({event:be,listeners:le}),de?be.data=de:(de=Xf(l),de!==null&&(be.data=de)))),(de=kx?Qx(e,l):Yx(e,l))&&(be=ju(_,"onBeforeInput"),0<be.length&&(le=new Bf("onBeforeInput","beforeinput",null,l,B),K.push({event:le,listeners:be}),le.data=de)),wy(K,e,_,l,B)}Rm(K,t)})}function $s(e,t,l){return{instance:e,listener:t,currentTarget:l}}function ju(e,t){for(var l=t+"Capture",a=[];e!==null;){var s=e,u=s.stateNode;if(s=s.tag,s!==5&&s!==26&&s!==27||u===null||(s=vs(e,l),s!=null&&a.unshift($s(e,s,u)),s=vs(e,t),s!=null&&a.push($s(e,s,u))),e.tag===3)return a;e=e.return}return[]}function qy(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Mm(e,t,l,a,s){for(var u=t._reactName,f=[];l!==null&&l!==a;){var m=l,j=m.alternate,_=m.stateNode;if(m=m.tag,j!==null&&j===a)break;m!==5&&m!==26&&m!==27||_===null||(j=_,s?(_=vs(l,u),_!=null&&f.unshift($s(l,_,j))):s||(_=vs(l,u),_!=null&&f.push($s(l,_,j)))),l=l.return}f.length!==0&&e.push({event:t,listeners:f})}var By=/\r\n?/g,Ly=/\u0000|\uFFFD/g;function zm(e){return(typeof e=="string"?e:""+e).replace(By,`
49
+ `).replace(Ly,"")}function _m(e,t){return t=zm(t),zm(e)===t}function _e(e,t,l,a,s,u){switch(l){case"children":typeof a=="string"?t==="body"||t==="textarea"&&a===""||dn(e,a):(typeof a=="number"||typeof a=="bigint")&&t!=="body"&&dn(e,""+a);break;case"className":Ti(e,"class",a);break;case"tabIndex":Ti(e,"tabindex",a);break;case"dir":case"role":case"viewBox":case"width":case"height":Ti(e,l,a);break;case"style":_f(e,a,u);break;case"data":if(t!=="object"){Ti(e,"data",a);break}case"src":case"href":if(a===""&&(t!=="a"||l!=="href")){e.removeAttribute(l);break}if(a==null||typeof a=="function"||typeof a=="symbol"||typeof a=="boolean"){e.removeAttribute(l);break}a=Ri(""+a),e.setAttribute(l,a);break;case"action":case"formAction":if(typeof a=="function"){e.setAttribute(l,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof u=="function"&&(l==="formAction"?(t!=="input"&&_e(e,t,"name",s.name,s,null),_e(e,t,"formEncType",s.formEncType,s,null),_e(e,t,"formMethod",s.formMethod,s,null),_e(e,t,"formTarget",s.formTarget,s,null)):(_e(e,t,"encType",s.encType,s,null),_e(e,t,"method",s.method,s,null),_e(e,t,"target",s.target,s,null)));if(a==null||typeof a=="symbol"||typeof a=="boolean"){e.removeAttribute(l);break}a=Ri(""+a),e.setAttribute(l,a);break;case"onClick":a!=null&&(e.onclick=yl);break;case"onScroll":a!=null&&ye("scroll",e);break;case"onScrollEnd":a!=null&&ye("scrollend",e);break;case"dangerouslySetInnerHTML":if(a!=null){if(typeof a!="object"||!("__html"in a))throw Error(o(61));if(l=a.__html,l!=null){if(s.children!=null)throw Error(o(60));e.innerHTML=l}}break;case"multiple":e.multiple=a&&typeof a!="function"&&typeof a!="symbol";break;case"muted":e.muted=a&&typeof a!="function"&&typeof a!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(a==null||typeof a=="function"||typeof a=="boolean"||typeof a=="symbol"){e.removeAttribute("xlink:href");break}l=Ri(""+a),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",l);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":a!=null&&typeof a!="function"&&typeof a!="symbol"?e.setAttribute(l,""+a):e.removeAttribute(l);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":a&&typeof a!="function"&&typeof a!="symbol"?e.setAttribute(l,""):e.removeAttribute(l);break;case"capture":case"download":a===!0?e.setAttribute(l,""):a!==!1&&a!=null&&typeof a!="function"&&typeof a!="symbol"?e.setAttribute(l,a):e.removeAttribute(l);break;case"cols":case"rows":case"size":case"span":a!=null&&typeof a!="function"&&typeof a!="symbol"&&!isNaN(a)&&1<=a?e.setAttribute(l,a):e.removeAttribute(l);break;case"rowSpan":case"start":a==null||typeof a=="function"||typeof a=="symbol"||isNaN(a)?e.removeAttribute(l):e.setAttribute(l,a);break;case"popover":ye("beforetoggle",e),ye("toggle",e),Ci(e,"popover",a);break;case"xlinkActuate":xl(e,"http://www.w3.org/1999/xlink","xlink:actuate",a);break;case"xlinkArcrole":xl(e,"http://www.w3.org/1999/xlink","xlink:arcrole",a);break;case"xlinkRole":xl(e,"http://www.w3.org/1999/xlink","xlink:role",a);break;case"xlinkShow":xl(e,"http://www.w3.org/1999/xlink","xlink:show",a);break;case"xlinkTitle":xl(e,"http://www.w3.org/1999/xlink","xlink:title",a);break;case"xlinkType":xl(e,"http://www.w3.org/1999/xlink","xlink:type",a);break;case"xmlBase":xl(e,"http://www.w3.org/XML/1998/namespace","xml:base",a);break;case"xmlLang":xl(e,"http://www.w3.org/XML/1998/namespace","xml:lang",a);break;case"xmlSpace":xl(e,"http://www.w3.org/XML/1998/namespace","xml:space",a);break;case"is":Ci(e,"is",a);break;case"innerText":case"textContent":break;default:(!(2<l.length)||l[0]!=="o"&&l[0]!=="O"||l[1]!=="n"&&l[1]!=="N")&&(l=hx.get(l)||l,Ci(e,l,a))}}function $c(e,t,l,a,s,u){switch(l){case"style":_f(e,a,u);break;case"dangerouslySetInnerHTML":if(a!=null){if(typeof a!="object"||!("__html"in a))throw Error(o(61));if(l=a.__html,l!=null){if(s.children!=null)throw Error(o(60));e.innerHTML=l}}break;case"children":typeof a=="string"?dn(e,a):(typeof a=="number"||typeof a=="bigint")&&dn(e,""+a);break;case"onScroll":a!=null&&ye("scroll",e);break;case"onScrollEnd":a!=null&&ye("scrollend",e);break;case"onClick":a!=null&&(e.onclick=yl);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!Nf.hasOwnProperty(l))e:{if(l[0]==="o"&&l[1]==="n"&&(s=l.endsWith("Capture"),t=l.slice(2,s?l.length-7:void 0),u=e[bt]||null,u=u!=null?u[l]:null,typeof u=="function"&&e.removeEventListener(t,u,s),typeof a=="function")){typeof u!="function"&&u!==null&&(l in e?e[l]=null:e.hasAttribute(l)&&e.removeAttribute(l)),e.addEventListener(t,a,s);break e}l in e?e[l]=a:a===!0?e.setAttribute(l,""):Ci(e,l,a)}}}function ot(e,t,l){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":ye("error",e),ye("load",e);var a=!1,s=!1,u;for(u in l)if(l.hasOwnProperty(u)){var f=l[u];if(f!=null)switch(u){case"src":a=!0;break;case"srcSet":s=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(o(137,t));default:_e(e,t,u,f,l,null)}}s&&_e(e,t,"srcSet",l.srcSet,l,null),a&&_e(e,t,"src",l.src,l,null);return;case"input":ye("invalid",e);var m=u=f=s=null,j=null,_=null;for(a in l)if(l.hasOwnProperty(a)){var B=l[a];if(B!=null)switch(a){case"name":s=B;break;case"type":f=B;break;case"checked":j=B;break;case"defaultChecked":_=B;break;case"value":u=B;break;case"defaultValue":m=B;break;case"children":case"dangerouslySetInnerHTML":if(B!=null)throw Error(o(137,t));break;default:_e(e,t,a,B,l,null)}}Rf(e,u,m,j,_,f,s,!1);return;case"select":ye("invalid",e),a=f=u=null;for(s in l)if(l.hasOwnProperty(s)&&(m=l[s],m!=null))switch(s){case"value":u=m;break;case"defaultValue":f=m;break;case"multiple":a=m;default:_e(e,t,s,m,l,null)}t=u,l=f,e.multiple=!!a,t!=null?fn(e,!!a,t,!1):l!=null&&fn(e,!!a,l,!0);return;case"textarea":ye("invalid",e),u=s=a=null;for(f in l)if(l.hasOwnProperty(f)&&(m=l[f],m!=null))switch(f){case"value":a=m;break;case"defaultValue":s=m;break;case"children":u=m;break;case"dangerouslySetInnerHTML":if(m!=null)throw Error(o(91));break;default:_e(e,t,f,m,l,null)}Mf(e,a,s,u);return;case"option":for(j in l)if(l.hasOwnProperty(j)&&(a=l[j],a!=null))switch(j){case"selected":e.selected=a&&typeof a!="function"&&typeof a!="symbol";break;default:_e(e,t,j,a,l,null)}return;case"dialog":ye("beforetoggle",e),ye("toggle",e),ye("cancel",e),ye("close",e);break;case"iframe":case"object":ye("load",e);break;case"video":case"audio":for(a=0;a<Js.length;a++)ye(Js[a],e);break;case"image":ye("error",e),ye("load",e);break;case"details":ye("toggle",e);break;case"embed":case"source":case"link":ye("error",e),ye("load",e);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(_ in l)if(l.hasOwnProperty(_)&&(a=l[_],a!=null))switch(_){case"children":case"dangerouslySetInnerHTML":throw Error(o(137,t));default:_e(e,t,_,a,l,null)}return;default:if(cr(t)){for(B in l)l.hasOwnProperty(B)&&(a=l[B],a!==void 0&&$c(e,t,B,a,l,void 0));return}}for(m in l)l.hasOwnProperty(m)&&(a=l[m],a!=null&&_e(e,t,m,a,l,null))}function ky(e,t,l,a){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var s=null,u=null,f=null,m=null,j=null,_=null,B=null;for(D in l){var K=l[D];if(l.hasOwnProperty(D)&&K!=null)switch(D){case"checked":break;case"value":break;case"defaultValue":j=K;default:a.hasOwnProperty(D)||_e(e,t,D,null,a,K)}}for(var w in a){var D=a[w];if(K=l[w],a.hasOwnProperty(w)&&(D!=null||K!=null))switch(w){case"type":u=D;break;case"name":s=D;break;case"checked":_=D;break;case"defaultChecked":B=D;break;case"value":f=D;break;case"defaultValue":m=D;break;case"children":case"dangerouslySetInnerHTML":if(D!=null)throw Error(o(137,t));break;default:D!==K&&_e(e,t,w,D,a,K)}}ur(e,f,m,j,_,B,u,s);return;case"select":D=f=m=w=null;for(u in l)if(j=l[u],l.hasOwnProperty(u)&&j!=null)switch(u){case"value":break;case"multiple":D=j;default:a.hasOwnProperty(u)||_e(e,t,u,null,a,j)}for(s in a)if(u=a[s],j=l[s],a.hasOwnProperty(s)&&(u!=null||j!=null))switch(s){case"value":w=u;break;case"defaultValue":m=u;break;case"multiple":f=u;default:u!==j&&_e(e,t,s,u,a,j)}t=m,l=f,a=D,w!=null?fn(e,!!l,w,!1):!!a!=!!l&&(t!=null?fn(e,!!l,t,!0):fn(e,!!l,l?[]:"",!1));return;case"textarea":D=w=null;for(m in l)if(s=l[m],l.hasOwnProperty(m)&&s!=null&&!a.hasOwnProperty(m))switch(m){case"value":break;case"children":break;default:_e(e,t,m,null,a,s)}for(f in a)if(s=a[f],u=l[f],a.hasOwnProperty(f)&&(s!=null||u!=null))switch(f){case"value":w=s;break;case"defaultValue":D=s;break;case"children":break;case"dangerouslySetInnerHTML":if(s!=null)throw Error(o(91));break;default:s!==u&&_e(e,t,f,s,a,u)}Af(e,w,D);return;case"option":for(var te in l)if(w=l[te],l.hasOwnProperty(te)&&w!=null&&!a.hasOwnProperty(te))switch(te){case"selected":e.selected=!1;break;default:_e(e,t,te,null,a,w)}for(j in a)if(w=a[j],D=l[j],a.hasOwnProperty(j)&&w!==D&&(w!=null||D!=null))switch(j){case"selected":e.selected=w&&typeof w!="function"&&typeof w!="symbol";break;default:_e(e,t,j,w,a,D)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var ie in l)w=l[ie],l.hasOwnProperty(ie)&&w!=null&&!a.hasOwnProperty(ie)&&_e(e,t,ie,null,a,w);for(_ in a)if(w=a[_],D=l[_],a.hasOwnProperty(_)&&w!==D&&(w!=null||D!=null))switch(_){case"children":case"dangerouslySetInnerHTML":if(w!=null)throw Error(o(137,t));break;default:_e(e,t,_,w,a,D)}return;default:if(cr(t)){for(var we in l)w=l[we],l.hasOwnProperty(we)&&w!==void 0&&!a.hasOwnProperty(we)&&$c(e,t,we,void 0,a,w);for(B in a)w=a[B],D=l[B],!a.hasOwnProperty(B)||w===D||w===void 0&&D===void 0||$c(e,t,B,w,a,D);return}}for(var T in l)w=l[T],l.hasOwnProperty(T)&&w!=null&&!a.hasOwnProperty(T)&&_e(e,t,T,null,a,w);for(K in a)w=a[K],D=l[K],!a.hasOwnProperty(K)||w===D||w==null&&D==null||_e(e,t,K,w,a,D)}function wm(e){switch(e){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function Qy(){if(typeof performance.getEntriesByType=="function"){for(var e=0,t=0,l=performance.getEntriesByType("resource"),a=0;a<l.length;a++){var s=l[a],u=s.transferSize,f=s.initiatorType,m=s.duration;if(u&&m&&wm(f)){for(f=0,m=s.responseEnd,a+=1;a<l.length;a++){var j=l[a],_=j.startTime;if(_>m)break;var B=j.transferSize,K=j.initiatorType;B&&wm(K)&&(j=j.responseEnd,f+=B*(j<m?1:(m-_)/(j-_)))}if(--a,t+=8*(u+f)/(s.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e=="number")?e:5}var Fc=null,Wc=null;function Nu(e){return e.nodeType===9?e:e.ownerDocument}function Dm(e){switch(e){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function Um(e,t){if(e===0)switch(t){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&t==="foreignObject"?0:e}function Ic(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.children=="bigint"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var Pc=null;function Yy(){var e=window.event;return e&&e.type==="popstate"?e===Pc?!1:(Pc=e,!0):(Pc=null,!1)}var Hm=typeof setTimeout=="function"?setTimeout:void 0,Gy=typeof clearTimeout=="function"?clearTimeout:void 0,qm=typeof Promise=="function"?Promise:void 0,Xy=typeof queueMicrotask=="function"?queueMicrotask:typeof qm<"u"?function(e){return qm.resolve(null).then(e).catch(Ky)}:Hm;function Ky(e){setTimeout(function(){throw e})}function ra(e){return e==="head"}function Bm(e,t){var l=t,a=0;do{var s=l.nextSibling;if(e.removeChild(l),s&&s.nodeType===8)if(l=s.data,l==="/$"||l==="/&"){if(a===0){e.removeChild(s),Gn(t);return}a--}else if(l==="$"||l==="$?"||l==="$~"||l==="$!"||l==="&")a++;else if(l==="html")Fs(e.ownerDocument.documentElement);else if(l==="head"){l=e.ownerDocument.head,Fs(l);for(var u=l.firstChild;u;){var f=u.nextSibling,m=u.nodeName;u[ms]||m==="SCRIPT"||m==="STYLE"||m==="LINK"&&u.rel.toLowerCase()==="stylesheet"||l.removeChild(u),u=f}}else l==="body"&&Fs(e.ownerDocument.body);l=s}while(l);Gn(t)}function Lm(e,t){var l=e;e=0;do{var a=l.nextSibling;if(l.nodeType===1?t?(l._stashedDisplay=l.style.display,l.style.display="none"):(l.style.display=l._stashedDisplay||"",l.getAttribute("style")===""&&l.removeAttribute("style")):l.nodeType===3&&(t?(l._stashedText=l.nodeValue,l.nodeValue=""):l.nodeValue=l._stashedText||""),a&&a.nodeType===8)if(l=a.data,l==="/$"){if(e===0)break;e--}else l!=="$"&&l!=="$?"&&l!=="$~"&&l!=="$!"||e++;l=a}while(l)}function eo(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var l=t;switch(t=t.nextSibling,l.nodeName){case"HTML":case"HEAD":case"BODY":eo(l),sr(l);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(l.rel.toLowerCase()==="stylesheet")continue}e.removeChild(l)}}function Vy(e,t,l,a){for(;e.nodeType===1;){var s=l;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!a&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(a){if(!e[ms])switch(t){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if(u=e.getAttribute("rel"),u==="stylesheet"&&e.hasAttribute("data-precedence"))break;if(u!==s.rel||e.getAttribute("href")!==(s.href==null||s.href===""?null:s.href)||e.getAttribute("crossorigin")!==(s.crossOrigin==null?null:s.crossOrigin)||e.getAttribute("title")!==(s.title==null?null:s.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(u=e.getAttribute("src"),(u!==(s.src==null?null:s.src)||e.getAttribute("type")!==(s.type==null?null:s.type)||e.getAttribute("crossorigin")!==(s.crossOrigin==null?null:s.crossOrigin))&&u&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else if(t==="input"&&e.type==="hidden"){var u=s.name==null?null:""+s.name;if(s.type==="hidden"&&e.getAttribute("name")===u)return e}else return e;if(e=Wt(e.nextSibling),e===null)break}return null}function Zy(e,t,l){if(t==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!l||(e=Wt(e.nextSibling),e===null))return null;return e}function km(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!t||(e=Wt(e.nextSibling),e===null))return null;return e}function to(e){return e.data==="$?"||e.data==="$~"}function lo(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState!=="loading"}function Jy(e,t){var l=e.ownerDocument;if(e.data==="$~")e._reactRetry=t;else if(e.data!=="$?"||l.readyState!=="loading")t();else{var a=function(){t(),l.removeEventListener("DOMContentLoaded",a)};l.addEventListener("DOMContentLoaded",a),e._reactRetry=a}}function Wt(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==="$?"||t==="$~"||t==="&"||t==="F!"||t==="F")break;if(t==="/$"||t==="/&")return null}}return e}var ao=null;function Qm(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var l=e.data;if(l==="/$"||l==="/&"){if(t===0)return Wt(e.nextSibling);t--}else l!=="$"&&l!=="$!"&&l!=="$?"&&l!=="$~"&&l!=="&"||t++}e=e.nextSibling}return null}function Ym(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var l=e.data;if(l==="$"||l==="$!"||l==="$?"||l==="$~"||l==="&"){if(t===0)return e;t--}else l!=="/$"&&l!=="/&"||t++}e=e.previousSibling}return null}function Gm(e,t,l){switch(t=Nu(l),e){case"html":if(e=t.documentElement,!e)throw Error(o(452));return e;case"head":if(e=t.head,!e)throw Error(o(453));return e;case"body":if(e=t.body,!e)throw Error(o(454));return e;default:throw Error(o(451))}}function Fs(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);sr(e)}var It=new Map,Xm=new Set;function Eu(e){return typeof e.getRootNode=="function"?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var Dl=F.d;F.d={f:$y,r:Fy,D:Wy,C:Iy,L:Py,m:e0,X:l0,S:t0,M:a0};function $y(){var e=Dl.f(),t=pu();return e||t}function Fy(e){var t=rn(e);t!==null&&t.tag===5&&t.type==="form"?uh(t):Dl.r(e)}var kn=typeof document>"u"?null:document;function Km(e,t,l){var a=kn;if(a&&typeof t=="string"&&t){var s=Xt(t);s='link[rel="'+e+'"][href="'+s+'"]',typeof l=="string"&&(s+='[crossorigin="'+l+'"]'),Xm.has(s)||(Xm.add(s),e={rel:e,crossOrigin:l,href:t},a.querySelector(s)===null&&(t=a.createElement("link"),ot(t,"link",e),lt(t),a.head.appendChild(t)))}}function Wy(e){Dl.D(e),Km("dns-prefetch",e,null)}function Iy(e,t){Dl.C(e,t),Km("preconnect",e,t)}function Py(e,t,l){Dl.L(e,t,l);var a=kn;if(a&&e&&t){var s='link[rel="preload"][as="'+Xt(t)+'"]';t==="image"&&l&&l.imageSrcSet?(s+='[imagesrcset="'+Xt(l.imageSrcSet)+'"]',typeof l.imageSizes=="string"&&(s+='[imagesizes="'+Xt(l.imageSizes)+'"]')):s+='[href="'+Xt(e)+'"]';var u=s;switch(t){case"style":u=Qn(e);break;case"script":u=Yn(e)}It.has(u)||(e=g({rel:"preload",href:t==="image"&&l&&l.imageSrcSet?void 0:e,as:t},l),It.set(u,e),a.querySelector(s)!==null||t==="style"&&a.querySelector(Ws(u))||t==="script"&&a.querySelector(Is(u))||(t=a.createElement("link"),ot(t,"link",e),lt(t),a.head.appendChild(t)))}}function e0(e,t){Dl.m(e,t);var l=kn;if(l&&e){var a=t&&typeof t.as=="string"?t.as:"script",s='link[rel="modulepreload"][as="'+Xt(a)+'"][href="'+Xt(e)+'"]',u=s;switch(a){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":u=Yn(e)}if(!It.has(u)&&(e=g({rel:"modulepreload",href:e},t),It.set(u,e),l.querySelector(s)===null)){switch(a){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(l.querySelector(Is(u)))return}a=l.createElement("link"),ot(a,"link",e),lt(a),l.head.appendChild(a)}}}function t0(e,t,l){Dl.S(e,t,l);var a=kn;if(a&&e){var s=cn(a).hoistableStyles,u=Qn(e);t=t||"default";var f=s.get(u);if(!f){var m={loading:0,preload:null};if(f=a.querySelector(Ws(u)))m.loading=5;else{e=g({rel:"stylesheet",href:e,"data-precedence":t},l),(l=It.get(u))&&no(e,l);var j=f=a.createElement("link");lt(j),ot(j,"link",e),j._p=new Promise(function(_,B){j.onload=_,j.onerror=B}),j.addEventListener("load",function(){m.loading|=1}),j.addEventListener("error",function(){m.loading|=2}),m.loading|=4,Cu(f,t,a)}f={type:"stylesheet",instance:f,count:1,state:m},s.set(u,f)}}}function l0(e,t){Dl.X(e,t);var l=kn;if(l&&e){var a=cn(l).hoistableScripts,s=Yn(e),u=a.get(s);u||(u=l.querySelector(Is(s)),u||(e=g({src:e,async:!0},t),(t=It.get(s))&&so(e,t),u=l.createElement("script"),lt(u),ot(u,"link",e),l.head.appendChild(u)),u={type:"script",instance:u,count:1,state:null},a.set(s,u))}}function a0(e,t){Dl.M(e,t);var l=kn;if(l&&e){var a=cn(l).hoistableScripts,s=Yn(e),u=a.get(s);u||(u=l.querySelector(Is(s)),u||(e=g({src:e,async:!0,type:"module"},t),(t=It.get(s))&&so(e,t),u=l.createElement("script"),lt(u),ot(u,"link",e),l.head.appendChild(u)),u={type:"script",instance:u,count:1,state:null},a.set(s,u))}}function Vm(e,t,l,a){var s=(s=he.current)?Eu(s):null;if(!s)throw Error(o(446));switch(e){case"meta":case"title":return null;case"style":return typeof l.precedence=="string"&&typeof l.href=="string"?(t=Qn(l.href),l=cn(s).hoistableStyles,a=l.get(t),a||(a={type:"style",instance:null,count:0,state:null},l.set(t,a)),a):{type:"void",instance:null,count:0,state:null};case"link":if(l.rel==="stylesheet"&&typeof l.href=="string"&&typeof l.precedence=="string"){e=Qn(l.href);var u=cn(s).hoistableStyles,f=u.get(e);if(f||(s=s.ownerDocument||s,f={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},u.set(e,f),(u=s.querySelector(Ws(e)))&&!u._p&&(f.instance=u,f.state.loading=5),It.has(e)||(l={rel:"preload",as:"style",href:l.href,crossOrigin:l.crossOrigin,integrity:l.integrity,media:l.media,hrefLang:l.hrefLang,referrerPolicy:l.referrerPolicy},It.set(e,l),u||n0(s,e,l,f.state))),t&&a===null)throw Error(o(528,""));return f}if(t&&a!==null)throw Error(o(529,""));return null;case"script":return t=l.async,l=l.src,typeof l=="string"&&t&&typeof t!="function"&&typeof t!="symbol"?(t=Yn(l),l=cn(s).hoistableScripts,a=l.get(t),a||(a={type:"script",instance:null,count:0,state:null},l.set(t,a)),a):{type:"void",instance:null,count:0,state:null};default:throw Error(o(444,e))}}function Qn(e){return'href="'+Xt(e)+'"'}function Ws(e){return'link[rel="stylesheet"]['+e+"]"}function Zm(e){return g({},e,{"data-precedence":e.precedence,precedence:null})}function n0(e,t,l,a){e.querySelector('link[rel="preload"][as="style"]['+t+"]")?a.loading=1:(t=e.createElement("link"),a.preload=t,t.addEventListener("load",function(){return a.loading|=1}),t.addEventListener("error",function(){return a.loading|=2}),ot(t,"link",l),lt(t),e.head.appendChild(t))}function Yn(e){return'[src="'+Xt(e)+'"]'}function Is(e){return"script[async]"+e}function Jm(e,t,l){if(t.count++,t.instance===null)switch(t.type){case"style":var a=e.querySelector('style[data-href~="'+Xt(l.href)+'"]');if(a)return t.instance=a,lt(a),a;var s=g({},l,{"data-href":l.href,"data-precedence":l.precedence,href:null,precedence:null});return a=(e.ownerDocument||e).createElement("style"),lt(a),ot(a,"style",s),Cu(a,l.precedence,e),t.instance=a;case"stylesheet":s=Qn(l.href);var u=e.querySelector(Ws(s));if(u)return t.state.loading|=4,t.instance=u,lt(u),u;a=Zm(l),(s=It.get(s))&&no(a,s),u=(e.ownerDocument||e).createElement("link"),lt(u);var f=u;return f._p=new Promise(function(m,j){f.onload=m,f.onerror=j}),ot(u,"link",a),t.state.loading|=4,Cu(u,l.precedence,e),t.instance=u;case"script":return u=Yn(l.src),(s=e.querySelector(Is(u)))?(t.instance=s,lt(s),s):(a=l,(s=It.get(u))&&(a=g({},l),so(a,s)),e=e.ownerDocument||e,s=e.createElement("script"),lt(s),ot(s,"link",a),e.head.appendChild(s),t.instance=s);case"void":return null;default:throw Error(o(443,t.type))}else t.type==="stylesheet"&&(t.state.loading&4)===0&&(a=t.instance,t.state.loading|=4,Cu(a,l.precedence,e));return t.instance}function Cu(e,t,l){for(var a=l.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),s=a.length?a[a.length-1]:null,u=s,f=0;f<a.length;f++){var m=a[f];if(m.dataset.precedence===t)u=m;else if(u!==s)break}u?u.parentNode.insertBefore(e,u.nextSibling):(t=l.nodeType===9?l.head:l,t.insertBefore(e,t.firstChild))}function no(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.title==null&&(e.title=t.title)}function so(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.integrity==null&&(e.integrity=t.integrity)}var Tu=null;function $m(e,t,l){if(Tu===null){var a=new Map,s=Tu=new Map;s.set(l,a)}else s=Tu,a=s.get(l),a||(a=new Map,s.set(l,a));if(a.has(e))return a;for(a.set(e,null),l=l.getElementsByTagName(e),s=0;s<l.length;s++){var u=l[s];if(!(u[ms]||u[it]||e==="link"&&u.getAttribute("rel")==="stylesheet")&&u.namespaceURI!=="http://www.w3.org/2000/svg"){var f=u.getAttribute(t)||"";f=e+f;var m=a.get(f);m?m.push(u):a.set(f,[u])}}return a}function Fm(e,t,l){e=e.ownerDocument||e,e.head.insertBefore(l,t==="title"?e.querySelector("head > title"):null)}function s0(e,t,l){if(l===1||t.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof t.precedence!="string"||typeof t.href!="string"||t.href==="")break;return!0;case"link":if(typeof t.rel!="string"||typeof t.href!="string"||t.href===""||t.onLoad||t.onError)break;switch(t.rel){case"stylesheet":return e=t.disabled,typeof t.precedence=="string"&&e==null;default:return!0}case"script":if(t.async&&typeof t.async!="function"&&typeof t.async!="symbol"&&!t.onLoad&&!t.onError&&t.src&&typeof t.src=="string")return!0}return!1}function Wm(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}function i0(e,t,l,a){if(l.type==="stylesheet"&&(typeof a.media!="string"||matchMedia(a.media).matches!==!1)&&(l.state.loading&4)===0){if(l.instance===null){var s=Qn(a.href),u=t.querySelector(Ws(s));if(u){t=u._p,t!==null&&typeof t=="object"&&typeof t.then=="function"&&(e.count++,e=Ou.bind(e),t.then(e,e)),l.state.loading|=4,l.instance=u,lt(u);return}u=t.ownerDocument||t,a=Zm(a),(s=It.get(s))&&no(a,s),u=u.createElement("link"),lt(u);var f=u;f._p=new Promise(function(m,j){f.onload=m,f.onerror=j}),ot(u,"link",a),l.instance=u}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(l,t),(t=l.state.preload)&&(l.state.loading&3)===0&&(e.count++,l=Ou.bind(e),t.addEventListener("load",l),t.addEventListener("error",l))}}var io=0;function u0(e,t){return e.stylesheets&&e.count===0&&Au(e,e.stylesheets),0<e.count||0<e.imgCount?function(l){var a=setTimeout(function(){if(e.stylesheets&&Au(e,e.stylesheets),e.unsuspend){var u=e.unsuspend;e.unsuspend=null,u()}},6e4+t);0<e.imgBytes&&io===0&&(io=62500*Qy());var s=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&Au(e,e.stylesheets),e.unsuspend)){var u=e.unsuspend;e.unsuspend=null,u()}},(e.imgBytes>io?50:800)+t);return e.unsuspend=l,function(){e.unsuspend=null,clearTimeout(a),clearTimeout(s)}}:null}function Ou(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Au(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Ru=null;function Au(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Ru=new Map,t.forEach(r0,e),Ru=null,Ou.call(e))}function r0(e,t){if(!(t.state.loading&4)){var l=Ru.get(e);if(l)var a=l.get(null);else{l=new Map,Ru.set(e,l);for(var s=e.querySelectorAll("link[data-precedence],style[data-precedence]"),u=0;u<s.length;u++){var f=s[u];(f.nodeName==="LINK"||f.getAttribute("media")!=="not all")&&(l.set(f.dataset.precedence,f),a=f)}a&&l.set(null,a)}s=t.instance,f=s.getAttribute("data-precedence"),u=l.get(f)||a,u===a&&l.set(null,s),l.set(f,s),this.count++,a=Ou.bind(this),s.addEventListener("load",a),s.addEventListener("error",a),u?u.parentNode.insertBefore(s,u.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(s,e.firstChild)),t.state.loading|=4}}var Ps={$$typeof:M,Provider:null,Consumer:null,_currentValue:ae,_currentValue2:ae,_threadCount:0};function c0(e,t,l,a,s,u,f,m,j){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=tr(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=tr(0),this.hiddenUpdates=tr(null),this.identifierPrefix=a,this.onUncaughtError=s,this.onCaughtError=u,this.onRecoverableError=f,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=j,this.incompleteTransitions=new Map}function Im(e,t,l,a,s,u,f,m,j,_,B,K){return e=new c0(e,t,l,f,j,_,B,K,m),t=1,u===!0&&(t|=24),u=wt(3,null,null,t),e.current=u,u.stateNode=e,t=Lr(),t.refCount++,e.pooledCache=t,t.refCount++,u.memoizedState={element:a,isDehydrated:l,cache:t},Gr(u),e}function Pm(e){return e?(e=gn,e):gn}function ep(e,t,l,a,s,u){s=Pm(s),a.context===null?a.context=s:a.pendingContext=s,a=Wl(t),a.payload={element:l},u=u===void 0?null:u,u!==null&&(a.callback=u),l=Il(e,a,t),l!==null&&(Tt(l,e,t),zs(l,e,t))}function tp(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var l=e.retryLane;e.retryLane=l!==0&&l<t?l:t}}function uo(e,t){tp(e,t),(e=e.alternate)&&tp(e,t)}function lp(e){if(e.tag===13||e.tag===31){var t=wa(e,67108864);t!==null&&Tt(t,e,67108864),uo(e,67108864)}}function ap(e){if(e.tag===13||e.tag===31){var t=Bt();t=lr(t);var l=wa(e,t);l!==null&&Tt(l,e,t),uo(e,t)}}var Mu=!0;function o0(e,t,l,a){var s=L.T;L.T=null;var u=F.p;try{F.p=2,ro(e,t,l,a)}finally{F.p=u,L.T=s}}function f0(e,t,l,a){var s=L.T;L.T=null;var u=F.p;try{F.p=8,ro(e,t,l,a)}finally{F.p=u,L.T=s}}function ro(e,t,l,a){if(Mu){var s=co(a);if(s===null)Jc(e,t,a,zu,l),sp(e,a);else if(h0(s,e,t,l,a))a.stopPropagation();else if(sp(e,a),t&4&&-1<d0.indexOf(e)){for(;s!==null;){var u=rn(s);if(u!==null)switch(u.tag){case 3:if(u=u.stateNode,u.current.memoizedState.isDehydrated){var f=Ra(u.pendingLanes);if(f!==0){var m=u;for(m.pendingLanes|=2,m.entangledLanes|=2;f;){var j=1<<31-zt(f);m.entanglements[1]|=j,f&=~j}fl(u),(Te&6)===0&&(hu=At()+500,Zs(0))}}break;case 31:case 13:m=wa(u,2),m!==null&&Tt(m,u,2),pu(),uo(u,2)}if(u=co(a),u===null&&Jc(e,t,a,zu,l),u===s)break;s=u}s!==null&&a.stopPropagation()}else Jc(e,t,a,null,l)}}function co(e){return e=fr(e),oo(e)}var zu=null;function oo(e){if(zu=null,e=un(e),e!==null){var t=h(e);if(t===null)e=null;else{var l=t.tag;if(l===13){if(e=v(t),e!==null)return e;e=null}else if(l===31){if(e=p(t),e!==null)return e;e=null}else if(l===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return zu=e,null}function np(e){switch(e){case"beforetoggle":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"toggle":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 2;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"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(Wv()){case df:return 2;case hf:return 8;case bi:case Iv:return 32;case mf:return 268435456;default:return 32}default:return 32}}var fo=!1,ca=null,oa=null,fa=null,ei=new Map,ti=new Map,da=[],d0="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".split(" ");function sp(e,t){switch(e){case"focusin":case"focusout":ca=null;break;case"dragenter":case"dragleave":oa=null;break;case"mouseover":case"mouseout":fa=null;break;case"pointerover":case"pointerout":ei.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":ti.delete(t.pointerId)}}function li(e,t,l,a,s,u){return e===null||e.nativeEvent!==u?(e={blockedOn:t,domEventName:l,eventSystemFlags:a,nativeEvent:u,targetContainers:[s]},t!==null&&(t=rn(t),t!==null&&lp(t)),e):(e.eventSystemFlags|=a,t=e.targetContainers,s!==null&&t.indexOf(s)===-1&&t.push(s),e)}function h0(e,t,l,a,s){switch(t){case"focusin":return ca=li(ca,e,t,l,a,s),!0;case"dragenter":return oa=li(oa,e,t,l,a,s),!0;case"mouseover":return fa=li(fa,e,t,l,a,s),!0;case"pointerover":var u=s.pointerId;return ei.set(u,li(ei.get(u)||null,e,t,l,a,s)),!0;case"gotpointercapture":return u=s.pointerId,ti.set(u,li(ti.get(u)||null,e,t,l,a,s)),!0}return!1}function ip(e){var t=un(e.target);if(t!==null){var l=h(t);if(l!==null){if(t=l.tag,t===13){if(t=v(l),t!==null){e.blockedOn=t,bf(e.priority,function(){ap(l)});return}}else if(t===31){if(t=p(l),t!==null){e.blockedOn=t,bf(e.priority,function(){ap(l)});return}}else if(t===3&&l.stateNode.current.memoizedState.isDehydrated){e.blockedOn=l.tag===3?l.stateNode.containerInfo:null;return}}}e.blockedOn=null}function _u(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var l=co(e.nativeEvent);if(l===null){l=e.nativeEvent;var a=new l.constructor(l.type,l);or=a,l.target.dispatchEvent(a),or=null}else return t=rn(l),t!==null&&lp(t),e.blockedOn=l,!1;t.shift()}return!0}function up(e,t,l){_u(e)&&l.delete(t)}function m0(){fo=!1,ca!==null&&_u(ca)&&(ca=null),oa!==null&&_u(oa)&&(oa=null),fa!==null&&_u(fa)&&(fa=null),ei.forEach(up),ti.forEach(up)}function wu(e,t){e.blockedOn===t&&(e.blockedOn=null,fo||(fo=!0,n.unstable_scheduleCallback(n.unstable_NormalPriority,m0)))}var Du=null;function rp(e){Du!==e&&(Du=e,n.unstable_scheduleCallback(n.unstable_NormalPriority,function(){Du===e&&(Du=null);for(var t=0;t<e.length;t+=3){var l=e[t],a=e[t+1],s=e[t+2];if(typeof a!="function"){if(oo(a||l)===null)continue;break}var u=rn(l);u!==null&&(e.splice(t,3),t-=3,cc(u,{pending:!0,data:s,method:l.method,action:a},a,s))}}))}function Gn(e){function t(j){return wu(j,e)}ca!==null&&wu(ca,e),oa!==null&&wu(oa,e),fa!==null&&wu(fa,e),ei.forEach(t),ti.forEach(t);for(var l=0;l<da.length;l++){var a=da[l];a.blockedOn===e&&(a.blockedOn=null)}for(;0<da.length&&(l=da[0],l.blockedOn===null);)ip(l),l.blockedOn===null&&da.shift();if(l=(e.ownerDocument||e).$$reactFormReplay,l!=null)for(a=0;a<l.length;a+=3){var s=l[a],u=l[a+1],f=s[bt]||null;if(typeof u=="function")f||rp(l);else if(f){var m=null;if(u&&u.hasAttribute("formAction")){if(s=u,f=u[bt]||null)m=f.formAction;else if(oo(s)!==null)continue}else m=f.action;typeof m=="function"?l[a+1]=m:(l.splice(a,3),a-=3),rp(l)}}}function cp(){function e(u){u.canIntercept&&u.info==="react-transition"&&u.intercept({handler:function(){return new Promise(function(f){return s=f})},focusReset:"manual",scroll:"manual"})}function t(){s!==null&&(s(),s=null),a||setTimeout(l,20)}function l(){if(!a&&!navigation.transition){var u=navigation.currentEntry;u&&u.url!=null&&navigation.navigate(u.url,{state:u.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var a=!1,s=null;return navigation.addEventListener("navigate",e),navigation.addEventListener("navigatesuccess",t),navigation.addEventListener("navigateerror",t),setTimeout(l,100),function(){a=!0,navigation.removeEventListener("navigate",e),navigation.removeEventListener("navigatesuccess",t),navigation.removeEventListener("navigateerror",t),s!==null&&(s(),s=null)}}}function ho(e){this._internalRoot=e}Uu.prototype.render=ho.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(o(409));var l=t.current,a=Bt();ep(l,a,e,t,null,null)},Uu.prototype.unmount=ho.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;ep(e.current,2,null,e,null,null),pu(),t[sn]=null}};function Uu(e){this._internalRoot=e}Uu.prototype.unstable_scheduleHydration=function(e){if(e){var t=gf();e={blockedOn:null,target:e,priority:t};for(var l=0;l<da.length&&t!==0&&t<da[l].priority;l++);da.splice(l,0,e),l===0&&ip(e)}};var op=i.version;if(op!=="19.2.4")throw Error(o(527,op,"19.2.4"));F.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(o(188)):(e=Object.keys(e).join(","),Error(o(268,e)));return e=x(t),e=e!==null?b(e):null,e=e===null?null:e.stateNode,e};var p0={bundleType:0,version:"19.2.4",rendererPackageName:"react-dom",currentDispatcherRef:L,reconcilerVersion:"19.2.4"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Hu=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Hu.isDisabled&&Hu.supportsFiber)try{fs=Hu.inject(p0),Mt=Hu}catch{}}return si.createRoot=function(e,t){if(!d(e))throw Error(o(299));var l=!1,a="",s=xh,u=yh,f=gh;return t!=null&&(t.unstable_strictMode===!0&&(l=!0),t.identifierPrefix!==void 0&&(a=t.identifierPrefix),t.onUncaughtError!==void 0&&(s=t.onUncaughtError),t.onCaughtError!==void 0&&(u=t.onCaughtError),t.onRecoverableError!==void 0&&(f=t.onRecoverableError)),t=Im(e,1,!1,null,null,l,a,null,s,u,f,cp),e[sn]=t.current,Zc(e),new ho(t)},si.hydrateRoot=function(e,t,l){if(!d(e))throw Error(o(299));var a=!1,s="",u=xh,f=yh,m=gh,j=null;return l!=null&&(l.unstable_strictMode===!0&&(a=!0),l.identifierPrefix!==void 0&&(s=l.identifierPrefix),l.onUncaughtError!==void 0&&(u=l.onUncaughtError),l.onCaughtError!==void 0&&(f=l.onCaughtError),l.onRecoverableError!==void 0&&(m=l.onRecoverableError),l.formState!==void 0&&(j=l.formState)),t=Im(e,1,!0,t,l??null,a,s,j,u,f,m,cp),t.context=Pm(null),l=t.current,a=Bt(),a=lr(a),s=Wl(a),s.callback=null,Il(l,s,a),l=a,t.current.lanes=l,hs(t,l),fl(t),e[sn]=t.current,Zc(e),new Uu(t)},si.version="19.2.4",si}var Sp;function O0(){if(Sp)return xo.exports;Sp=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(i){console.error(i)}}return n(),xo.exports=T0(),xo.exports}var R0=O0(),is=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(n){return this.listeners.add(n),this.onSubscribe(),()=>{this.listeners.delete(n),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},A0={setTimeout:(n,i)=>setTimeout(n,i),clearTimeout:n=>clearTimeout(n),setInterval:(n,i)=>setInterval(n,i),clearInterval:n=>clearInterval(n)},pa,Vo,Yp,M0=(Yp=class{constructor(){ne(this,pa,A0);ne(this,Vo,!1)}setTimeoutProvider(n){I(this,pa,n)}setTimeout(n,i){return N(this,pa).setTimeout(n,i)}clearTimeout(n){N(this,pa).clearTimeout(n)}setInterval(n,i){return N(this,pa).setInterval(n,i)}clearInterval(n){N(this,pa).clearInterval(n)}},pa=new WeakMap,Vo=new WeakMap,Yp),Va=new M0;function z0(n){setTimeout(n,0)}var ln=typeof window>"u"||"Deno"in globalThis;function yt(){}function _0(n,i){return typeof n=="function"?n(i):n}function Oo(n){return typeof n=="number"&&n>=0&&n!==1/0}function Pp(n,i){return Math.max(n+(i||0)-Date.now(),0)}function Ea(n,i){return typeof n=="function"?n(i):n}function el(n,i){return typeof n=="function"?n(i):n}function jp(n,i){const{type:c="all",exact:o,fetchStatus:d,predicate:h,queryKey:v,stale:p}=n;if(v){if(o){if(i.queryHash!==Jo(v,i.options))return!1}else if(!oi(i.queryKey,v))return!1}if(c!=="all"){const y=i.isActive();if(c==="active"&&!y||c==="inactive"&&y)return!1}return!(typeof p=="boolean"&&i.isStale()!==p||d&&d!==i.state.fetchStatus||h&&!h(i))}function Np(n,i){const{exact:c,status:o,predicate:d,mutationKey:h}=n;if(h){if(!i.options.mutationKey)return!1;if(c){if(an(i.options.mutationKey)!==an(h))return!1}else if(!oi(i.options.mutationKey,h))return!1}return!(o&&i.state.status!==o||d&&!d(i))}function Jo(n,i){return((i==null?void 0:i.queryKeyHashFn)||an)(n)}function an(n){return JSON.stringify(n,(i,c)=>Ro(c)?Object.keys(c).sort().reduce((o,d)=>(o[d]=c[d],o),{}):c)}function oi(n,i){return n===i?!0:typeof n!=typeof i?!1:n&&i&&typeof n=="object"&&typeof i=="object"?Object.keys(i).every(c=>oi(n[c],i[c])):!1}var w0=Object.prototype.hasOwnProperty;function ev(n,i,c=0){if(n===i)return n;if(c>500)return i;const o=Ep(n)&&Ep(i);if(!o&&!(Ro(n)&&Ro(i)))return i;const h=(o?n:Object.keys(n)).length,v=o?i:Object.keys(i),p=v.length,y=o?new Array(p):{};let x=0;for(let b=0;b<p;b++){const g=o?b:v[b],A=n[g],O=i[g];if(A===O){y[g]=A,(o?b<h:w0.call(n,g))&&x++;continue}if(A===null||O===null||typeof A!="object"||typeof O!="object"){y[g]=O;continue}const k=ev(A,O,c+1);y[g]=k,k===A&&x++}return h===p&&x===h?n:y}function Xu(n,i){if(!i||Object.keys(n).length!==Object.keys(i).length)return!1;for(const c in n)if(n[c]!==i[c])return!1;return!0}function Ep(n){return Array.isArray(n)&&n.length===Object.keys(n).length}function Ro(n){if(!Cp(n))return!1;const i=n.constructor;if(i===void 0)return!0;const c=i.prototype;return!(!Cp(c)||!c.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(n)!==Object.prototype)}function Cp(n){return Object.prototype.toString.call(n)==="[object Object]"}function D0(n){return new Promise(i=>{Va.setTimeout(i,n)})}function Ao(n,i,c){return typeof c.structuralSharing=="function"?c.structuralSharing(n,i):c.structuralSharing!==!1?ev(n,i):i}function U0(n,i,c=0){const o=[...n,i];return c&&o.length>c?o.slice(1):o}function H0(n,i,c=0){const o=[i,...n];return c&&o.length>c?o.slice(0,-1):o}var $o=Symbol();function tv(n,i){return!n.queryFn&&(i!=null&&i.initialPromise)?()=>i.initialPromise:!n.queryFn||n.queryFn===$o?()=>Promise.reject(new Error(`Missing queryFn: '${n.queryHash}'`)):n.queryFn}function Fo(n,i){return typeof n=="function"?n(...i):!!n}function q0(n,i,c){let o=!1,d;return Object.defineProperty(n,"signal",{enumerable:!0,get:()=>(d??(d=i()),o||(o=!0,d.aborted?c():d.addEventListener("abort",c,{once:!0})),d)}),n}var Za,va,Vn,Gp,B0=(Gp=class extends is{constructor(){super();ne(this,Za);ne(this,va);ne(this,Vn);I(this,Vn,i=>{if(!ln&&window.addEventListener){const c=()=>i();return window.addEventListener("visibilitychange",c,!1),()=>{window.removeEventListener("visibilitychange",c)}}})}onSubscribe(){N(this,va)||this.setEventListener(N(this,Vn))}onUnsubscribe(){var i;this.hasListeners()||((i=N(this,va))==null||i.call(this),I(this,va,void 0))}setEventListener(i){var c;I(this,Vn,i),(c=N(this,va))==null||c.call(this),I(this,va,i(o=>{typeof o=="boolean"?this.setFocused(o):this.onFocus()}))}setFocused(i){N(this,Za)!==i&&(I(this,Za,i),this.onFocus())}onFocus(){const i=this.isFocused();this.listeners.forEach(c=>{c(i)})}isFocused(){var i;return typeof N(this,Za)=="boolean"?N(this,Za):((i=globalThis.document)==null?void 0:i.visibilityState)!=="hidden"}},Za=new WeakMap,va=new WeakMap,Vn=new WeakMap,Gp),Wo=new B0;function Mo(){let n,i;const c=new Promise((d,h)=>{n=d,i=h});c.status="pending",c.catch(()=>{});function o(d){Object.assign(c,d),delete c.resolve,delete c.reject}return c.resolve=d=>{o({status:"fulfilled",value:d}),n(d)},c.reject=d=>{o({status:"rejected",reason:d}),i(d)},c}var L0=z0;function k0(){let n=[],i=0,c=p=>{p()},o=p=>{p()},d=L0;const h=p=>{i?n.push(p):d(()=>{c(p)})},v=()=>{const p=n;n=[],p.length&&d(()=>{o(()=>{p.forEach(y=>{c(y)})})})};return{batch:p=>{let y;i++;try{y=p()}finally{i--,i||v()}return y},batchCalls:p=>(...y)=>{h(()=>{p(...y)})},schedule:h,setNotifyFunction:p=>{c=p},setBatchNotifyFunction:p=>{o=p},setScheduler:p=>{d=p}}}var et=k0(),Zn,xa,Jn,Xp,Q0=(Xp=class extends is{constructor(){super();ne(this,Zn,!0);ne(this,xa);ne(this,Jn);I(this,Jn,i=>{if(!ln&&window.addEventListener){const c=()=>i(!0),o=()=>i(!1);return window.addEventListener("online",c,!1),window.addEventListener("offline",o,!1),()=>{window.removeEventListener("online",c),window.removeEventListener("offline",o)}}})}onSubscribe(){N(this,xa)||this.setEventListener(N(this,Jn))}onUnsubscribe(){var i;this.hasListeners()||((i=N(this,xa))==null||i.call(this),I(this,xa,void 0))}setEventListener(i){var c;I(this,Jn,i),(c=N(this,xa))==null||c.call(this),I(this,xa,i(this.setOnline.bind(this)))}setOnline(i){N(this,Zn)!==i&&(I(this,Zn,i),this.listeners.forEach(o=>{o(i)}))}isOnline(){return N(this,Zn)}},Zn=new WeakMap,xa=new WeakMap,Jn=new WeakMap,Xp),Ku=new Q0;function Y0(n){return Math.min(1e3*2**n,3e4)}function lv(n){return(n??"online")==="online"?Ku.isOnline():!0}var zo=class extends Error{constructor(n){super("CancelledError"),this.revert=n==null?void 0:n.revert,this.silent=n==null?void 0:n.silent}};function av(n){let i=!1,c=0,o;const d=Mo(),h=()=>d.status!=="pending",v=H=>{var U;if(!h()){const V=new zo(H);A(V),(U=n.onCancel)==null||U.call(n,V)}},p=()=>{i=!0},y=()=>{i=!1},x=()=>Wo.isFocused()&&(n.networkMode==="always"||Ku.isOnline())&&n.canRun(),b=()=>lv(n.networkMode)&&n.canRun(),g=H=>{h()||(o==null||o(),d.resolve(H))},A=H=>{h()||(o==null||o(),d.reject(H))},O=()=>new Promise(H=>{var U;o=V=>{(h()||x())&&H(V)},(U=n.onPause)==null||U.call(n)}).then(()=>{var H;o=void 0,h()||(H=n.onContinue)==null||H.call(n)}),k=()=>{if(h())return;let H;const U=c===0?n.initialPromise:void 0;try{H=U??n.fn()}catch(V){H=Promise.reject(V)}Promise.resolve(H).then(g).catch(V=>{var P;if(h())return;const $=n.retry??(ln?0:3),M=n.retryDelay??Y0,Y=typeof M=="function"?M(c,V):M,R=$===!0||typeof $=="number"&&c<$||typeof $=="function"&&$(c,V);if(i||!R){A(V);return}c++,(P=n.onFail)==null||P.call(n,c,V),D0(Y).then(()=>x()?void 0:O()).then(()=>{i?A(V):k()})})};return{promise:d,status:()=>d.status,cancel:v,continue:()=>(o==null||o(),d),cancelRetry:p,continueRetry:y,canStart:b,start:()=>(b()?k():O().then(k),d)}}var Ja,Kp,nv=(Kp=class{constructor(){ne(this,Ja)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Oo(this.gcTime)&&I(this,Ja,Va.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(n){this.gcTime=Math.max(this.gcTime||0,n??(ln?1/0:300*1e3))}clearGcTimeout(){N(this,Ja)&&(Va.clearTimeout(N(this,Ja)),I(this,Ja,void 0))}},Ja=new WeakMap,Kp),$a,$n,Pt,Fa,nt,di,Wa,sl,Ul,Vp,G0=(Vp=class extends nv{constructor(i){super();ne(this,sl);ne(this,$a);ne(this,$n);ne(this,Pt);ne(this,Fa);ne(this,nt);ne(this,di);ne(this,Wa);I(this,Wa,!1),I(this,di,i.defaultOptions),this.setOptions(i.options),this.observers=[],I(this,Fa,i.client),I(this,Pt,N(this,Fa).getQueryCache()),this.queryKey=i.queryKey,this.queryHash=i.queryHash,I(this,$a,Op(this.options)),this.state=i.state??N(this,$a),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var i;return(i=N(this,nt))==null?void 0:i.promise}setOptions(i){if(this.options={...N(this,di),...i},this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){const c=Op(this.options);c.data!==void 0&&(this.setState(Tp(c.data,c.dataUpdatedAt)),I(this,$a,c))}}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&N(this,Pt).remove(this)}setData(i,c){const o=Ao(this.state.data,i,this.options);return me(this,sl,Ul).call(this,{data:o,type:"success",dataUpdatedAt:c==null?void 0:c.updatedAt,manual:c==null?void 0:c.manual}),o}setState(i,c){me(this,sl,Ul).call(this,{type:"setState",state:i,setStateOptions:c})}cancel(i){var o,d;const c=(o=N(this,nt))==null?void 0:o.promise;return(d=N(this,nt))==null||d.cancel(i),c?c.then(yt).catch(yt):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(N(this,$a))}isActive(){return this.observers.some(i=>el(i.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===$o||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(i=>Ea(i.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(i=>i.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(i=0){return this.state.data===void 0?!0:i==="static"?!1:this.state.isInvalidated?!0:!Pp(this.state.dataUpdatedAt,i)}onFocus(){var c;const i=this.observers.find(o=>o.shouldFetchOnWindowFocus());i==null||i.refetch({cancelRefetch:!1}),(c=N(this,nt))==null||c.continue()}onOnline(){var c;const i=this.observers.find(o=>o.shouldFetchOnReconnect());i==null||i.refetch({cancelRefetch:!1}),(c=N(this,nt))==null||c.continue()}addObserver(i){this.observers.includes(i)||(this.observers.push(i),this.clearGcTimeout(),N(this,Pt).notify({type:"observerAdded",query:this,observer:i}))}removeObserver(i){this.observers.includes(i)&&(this.observers=this.observers.filter(c=>c!==i),this.observers.length||(N(this,nt)&&(N(this,Wa)?N(this,nt).cancel({revert:!0}):N(this,nt).cancelRetry()),this.scheduleGc()),N(this,Pt).notify({type:"observerRemoved",query:this,observer:i}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||me(this,sl,Ul).call(this,{type:"invalidate"})}async fetch(i,c){var y,x,b,g,A,O,k,H,U,V,$,M;if(this.state.fetchStatus!=="idle"&&((y=N(this,nt))==null?void 0:y.status())!=="rejected"){if(this.state.data!==void 0&&(c!=null&&c.cancelRefetch))this.cancel({silent:!0});else if(N(this,nt))return N(this,nt).continueRetry(),N(this,nt).promise}if(i&&this.setOptions(i),!this.options.queryFn){const Y=this.observers.find(R=>R.options.queryFn);Y&&this.setOptions(Y.options)}const o=new AbortController,d=Y=>{Object.defineProperty(Y,"signal",{enumerable:!0,get:()=>(I(this,Wa,!0),o.signal)})},h=()=>{const Y=tv(this.options,c),P=(()=>{const q={client:N(this,Fa),queryKey:this.queryKey,meta:this.meta};return d(q),q})();return I(this,Wa,!1),this.options.persister?this.options.persister(Y,P,this):Y(P)},p=(()=>{const Y={fetchOptions:c,options:this.options,queryKey:this.queryKey,client:N(this,Fa),state:this.state,fetchFn:h};return d(Y),Y})();(x=this.options.behavior)==null||x.onFetch(p,this),I(this,$n,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((b=p.fetchOptions)==null?void 0:b.meta))&&me(this,sl,Ul).call(this,{type:"fetch",meta:(g=p.fetchOptions)==null?void 0:g.meta}),I(this,nt,av({initialPromise:c==null?void 0:c.initialPromise,fn:p.fetchFn,onCancel:Y=>{Y instanceof zo&&Y.revert&&this.setState({...N(this,$n),fetchStatus:"idle"}),o.abort()},onFail:(Y,R)=>{me(this,sl,Ul).call(this,{type:"failed",failureCount:Y,error:R})},onPause:()=>{me(this,sl,Ul).call(this,{type:"pause"})},onContinue:()=>{me(this,sl,Ul).call(this,{type:"continue"})},retry:p.options.retry,retryDelay:p.options.retryDelay,networkMode:p.options.networkMode,canRun:()=>!0}));try{const Y=await N(this,nt).start();if(Y===void 0)throw new Error(`${this.queryHash} data is undefined`);return this.setData(Y),(O=(A=N(this,Pt).config).onSuccess)==null||O.call(A,Y,this),(H=(k=N(this,Pt).config).onSettled)==null||H.call(k,Y,this.state.error,this),Y}catch(Y){if(Y instanceof zo){if(Y.silent)return N(this,nt).promise;if(Y.revert){if(this.state.data===void 0)throw Y;return this.state.data}}throw me(this,sl,Ul).call(this,{type:"error",error:Y}),(V=(U=N(this,Pt).config).onError)==null||V.call(U,Y,this),(M=($=N(this,Pt).config).onSettled)==null||M.call($,this.state.data,Y,this),Y}finally{this.scheduleGc()}}},$a=new WeakMap,$n=new WeakMap,Pt=new WeakMap,Fa=new WeakMap,nt=new WeakMap,di=new WeakMap,Wa=new WeakMap,sl=new WeakSet,Ul=function(i){const c=o=>{switch(i.type){case"failed":return{...o,fetchFailureCount:i.failureCount,fetchFailureReason:i.error};case"pause":return{...o,fetchStatus:"paused"};case"continue":return{...o,fetchStatus:"fetching"};case"fetch":return{...o,...sv(o.data,this.options),fetchMeta:i.meta??null};case"success":const d={...o,...Tp(i.data,i.dataUpdatedAt),dataUpdateCount:o.dataUpdateCount+1,...!i.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return I(this,$n,i.manual?d:void 0),d;case"error":const h=i.error;return{...o,error:h,errorUpdateCount:o.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:o.fetchFailureCount+1,fetchFailureReason:h,fetchStatus:"idle",status:"error",isInvalidated:!0};case"invalidate":return{...o,isInvalidated:!0};case"setState":return{...o,...i.state}}};this.state=c(this.state),et.batch(()=>{this.observers.forEach(o=>{o.onQueryUpdate()}),N(this,Pt).notify({query:this,type:"updated",action:i})})},Vp);function sv(n,i){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:lv(i.networkMode)?"fetching":"paused",...n===void 0&&{error:null,status:"pending"}}}function Tp(n,i){return{data:n,dataUpdatedAt:i??Date.now(),error:null,isInvalidated:!1,status:"success"}}function Op(n){const i=typeof n.initialData=="function"?n.initialData():n.initialData,c=i!==void 0,o=c?typeof n.initialDataUpdatedAt=="function"?n.initialDataUpdatedAt():n.initialDataUpdatedAt:0;return{data:i,dataUpdateCount:0,dataUpdatedAt:c?o??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:c?"success":"pending",fetchStatus:"idle"}}var Ot,je,hi,xt,Ia,Fn,Hl,ya,mi,Wn,In,Pa,en,ga,Pn,Oe,ri,_o,wo,Do,Uo,Ho,qo,Bo,iv,Zp,X0=(Zp=class extends is{constructor(i,c){super();ne(this,Oe);ne(this,Ot);ne(this,je);ne(this,hi);ne(this,xt);ne(this,Ia);ne(this,Fn);ne(this,Hl);ne(this,ya);ne(this,mi);ne(this,Wn);ne(this,In);ne(this,Pa);ne(this,en);ne(this,ga);ne(this,Pn,new Set);this.options=c,I(this,Ot,i),I(this,ya,null),I(this,Hl,Mo()),this.bindMethods(),this.setOptions(c)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(N(this,je).addObserver(this),Rp(N(this,je),this.options)?me(this,Oe,ri).call(this):this.updateResult(),me(this,Oe,Uo).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return Lo(N(this,je),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return Lo(N(this,je),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,me(this,Oe,Ho).call(this),me(this,Oe,qo).call(this),N(this,je).removeObserver(this)}setOptions(i){const c=this.options,o=N(this,je);if(this.options=N(this,Ot).defaultQueryOptions(i),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof el(this.options.enabled,N(this,je))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");me(this,Oe,Bo).call(this),N(this,je).setOptions(this.options),c._defaulted&&!Xu(this.options,c)&&N(this,Ot).getQueryCache().notify({type:"observerOptionsUpdated",query:N(this,je),observer:this});const d=this.hasListeners();d&&Ap(N(this,je),o,this.options,c)&&me(this,Oe,ri).call(this),this.updateResult(),d&&(N(this,je)!==o||el(this.options.enabled,N(this,je))!==el(c.enabled,N(this,je))||Ea(this.options.staleTime,N(this,je))!==Ea(c.staleTime,N(this,je)))&&me(this,Oe,_o).call(this);const h=me(this,Oe,wo).call(this);d&&(N(this,je)!==o||el(this.options.enabled,N(this,je))!==el(c.enabled,N(this,je))||h!==N(this,ga))&&me(this,Oe,Do).call(this,h)}getOptimisticResult(i){const c=N(this,Ot).getQueryCache().build(N(this,Ot),i),o=this.createResult(c,i);return V0(this,o)&&(I(this,xt,o),I(this,Fn,this.options),I(this,Ia,N(this,je).state)),o}getCurrentResult(){return N(this,xt)}trackResult(i,c){return new Proxy(i,{get:(o,d)=>(this.trackProp(d),c==null||c(d),d==="promise"&&(this.trackProp("data"),!this.options.experimental_prefetchInRender&&N(this,Hl).status==="pending"&&N(this,Hl).reject(new Error("experimental_prefetchInRender feature flag is not enabled"))),Reflect.get(o,d))})}trackProp(i){N(this,Pn).add(i)}getCurrentQuery(){return N(this,je)}refetch({...i}={}){return this.fetch({...i})}fetchOptimistic(i){const c=N(this,Ot).defaultQueryOptions(i),o=N(this,Ot).getQueryCache().build(N(this,Ot),c);return o.fetch().then(()=>this.createResult(o,c))}fetch(i){return me(this,Oe,ri).call(this,{...i,cancelRefetch:i.cancelRefetch??!0}).then(()=>(this.updateResult(),N(this,xt)))}createResult(i,c){var G;const o=N(this,je),d=this.options,h=N(this,xt),v=N(this,Ia),p=N(this,Fn),x=i!==o?i.state:N(this,hi),{state:b}=i;let g={...b},A=!1,O;if(c._optimisticResults){const W=this.hasListeners(),ue=!W&&Rp(i,c),He=W&&Ap(i,o,c,d);(ue||He)&&(g={...g,...sv(b.data,i.options)}),c._optimisticResults==="isRestoring"&&(g.fetchStatus="idle")}let{error:k,errorUpdatedAt:H,status:U}=g;O=g.data;let V=!1;if(c.placeholderData!==void 0&&O===void 0&&U==="pending"){let W;h!=null&&h.isPlaceholderData&&c.placeholderData===(p==null?void 0:p.placeholderData)?(W=h.data,V=!0):W=typeof c.placeholderData=="function"?c.placeholderData((G=N(this,In))==null?void 0:G.state.data,N(this,In)):c.placeholderData,W!==void 0&&(U="success",O=Ao(h==null?void 0:h.data,W,c),A=!0)}if(c.select&&O!==void 0&&!V)if(h&&O===(v==null?void 0:v.data)&&c.select===N(this,mi))O=N(this,Wn);else try{I(this,mi,c.select),O=c.select(O),O=Ao(h==null?void 0:h.data,O,c),I(this,Wn,O),I(this,ya,null)}catch(W){I(this,ya,W)}N(this,ya)&&(k=N(this,ya),O=N(this,Wn),H=Date.now(),U="error");const $=g.fetchStatus==="fetching",M=U==="pending",Y=U==="error",R=M&&$,P=O!==void 0,Z={status:U,fetchStatus:g.fetchStatus,isPending:M,isSuccess:U==="success",isError:Y,isInitialLoading:R,isLoading:R,data:O,dataUpdatedAt:g.dataUpdatedAt,error:k,errorUpdatedAt:H,failureCount:g.fetchFailureCount,failureReason:g.fetchFailureReason,errorUpdateCount:g.errorUpdateCount,isFetched:g.dataUpdateCount>0||g.errorUpdateCount>0,isFetchedAfterMount:g.dataUpdateCount>x.dataUpdateCount||g.errorUpdateCount>x.errorUpdateCount,isFetching:$,isRefetching:$&&!M,isLoadingError:Y&&!P,isPaused:g.fetchStatus==="paused",isPlaceholderData:A,isRefetchError:Y&&P,isStale:Io(i,c),refetch:this.refetch,promise:N(this,Hl),isEnabled:el(c.enabled,i)!==!1};if(this.options.experimental_prefetchInRender){const W=Z.data!==void 0,ue=Z.status==="error"&&!W,He=tt=>{ue?tt.reject(Z.error):W&&tt.resolve(Z.data)},Yt=()=>{const tt=I(this,Hl,Z.promise=Mo());He(tt)},dt=N(this,Hl);switch(dt.status){case"pending":i.queryHash===o.queryHash&&He(dt);break;case"fulfilled":(ue||Z.data!==dt.value)&&Yt();break;case"rejected":(!ue||Z.error!==dt.reason)&&Yt();break}}return Z}updateResult(){const i=N(this,xt),c=this.createResult(N(this,je),this.options);if(I(this,Ia,N(this,je).state),I(this,Fn,this.options),N(this,Ia).data!==void 0&&I(this,In,N(this,je)),Xu(c,i))return;I(this,xt,c);const o=()=>{if(!i)return!0;const{notifyOnChangeProps:d}=this.options,h=typeof d=="function"?d():d;if(h==="all"||!h&&!N(this,Pn).size)return!0;const v=new Set(h??N(this,Pn));return this.options.throwOnError&&v.add("error"),Object.keys(N(this,xt)).some(p=>{const y=p;return N(this,xt)[y]!==i[y]&&v.has(y)})};me(this,Oe,iv).call(this,{listeners:o()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&me(this,Oe,Uo).call(this)}},Ot=new WeakMap,je=new WeakMap,hi=new WeakMap,xt=new WeakMap,Ia=new WeakMap,Fn=new WeakMap,Hl=new WeakMap,ya=new WeakMap,mi=new WeakMap,Wn=new WeakMap,In=new WeakMap,Pa=new WeakMap,en=new WeakMap,ga=new WeakMap,Pn=new WeakMap,Oe=new WeakSet,ri=function(i){me(this,Oe,Bo).call(this);let c=N(this,je).fetch(this.options,i);return i!=null&&i.throwOnError||(c=c.catch(yt)),c},_o=function(){me(this,Oe,Ho).call(this);const i=Ea(this.options.staleTime,N(this,je));if(ln||N(this,xt).isStale||!Oo(i))return;const o=Pp(N(this,xt).dataUpdatedAt,i)+1;I(this,Pa,Va.setTimeout(()=>{N(this,xt).isStale||this.updateResult()},o))},wo=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(N(this,je)):this.options.refetchInterval)??!1},Do=function(i){me(this,Oe,qo).call(this),I(this,ga,i),!(ln||el(this.options.enabled,N(this,je))===!1||!Oo(N(this,ga))||N(this,ga)===0)&&I(this,en,Va.setInterval(()=>{(this.options.refetchIntervalInBackground||Wo.isFocused())&&me(this,Oe,ri).call(this)},N(this,ga)))},Uo=function(){me(this,Oe,_o).call(this),me(this,Oe,Do).call(this,me(this,Oe,wo).call(this))},Ho=function(){N(this,Pa)&&(Va.clearTimeout(N(this,Pa)),I(this,Pa,void 0))},qo=function(){N(this,en)&&(Va.clearInterval(N(this,en)),I(this,en,void 0))},Bo=function(){const i=N(this,Ot).getQueryCache().build(N(this,Ot),this.options);if(i===N(this,je))return;const c=N(this,je);I(this,je,i),I(this,hi,i.state),this.hasListeners()&&(c==null||c.removeObserver(this),i.addObserver(this))},iv=function(i){et.batch(()=>{i.listeners&&this.listeners.forEach(c=>{c(N(this,xt))}),N(this,Ot).getQueryCache().notify({query:N(this,je),type:"observerResultsUpdated"})})},Zp);function K0(n,i){return el(i.enabled,n)!==!1&&n.state.data===void 0&&!(n.state.status==="error"&&i.retryOnMount===!1)}function Rp(n,i){return K0(n,i)||n.state.data!==void 0&&Lo(n,i,i.refetchOnMount)}function Lo(n,i,c){if(el(i.enabled,n)!==!1&&Ea(i.staleTime,n)!=="static"){const o=typeof c=="function"?c(n):c;return o==="always"||o!==!1&&Io(n,i)}return!1}function Ap(n,i,c,o){return(n!==i||el(o.enabled,n)===!1)&&(!c.suspense||n.state.status!=="error")&&Io(n,c)}function Io(n,i){return el(i.enabled,n)!==!1&&n.isStaleByTime(Ea(i.staleTime,n))}function V0(n,i){return!Xu(n.getCurrentResult(),i)}function Mp(n){return{onFetch:(i,c)=>{var b,g,A,O,k;const o=i.options,d=(A=(g=(b=i.fetchOptions)==null?void 0:b.meta)==null?void 0:g.fetchMore)==null?void 0:A.direction,h=((O=i.state.data)==null?void 0:O.pages)||[],v=((k=i.state.data)==null?void 0:k.pageParams)||[];let p={pages:[],pageParams:[]},y=0;const x=async()=>{let H=!1;const U=M=>{q0(M,()=>i.signal,()=>H=!0)},V=tv(i.options,i.fetchOptions),$=async(M,Y,R)=>{if(H)return Promise.reject();if(Y==null&&M.pages.length)return Promise.resolve(M);const q=(()=>{const ue={client:i.client,queryKey:i.queryKey,pageParam:Y,direction:R?"backward":"forward",meta:i.options.meta};return U(ue),ue})(),Z=await V(q),{maxPages:G}=i.options,W=R?H0:U0;return{pages:W(M.pages,Z,G),pageParams:W(M.pageParams,Y,G)}};if(d&&h.length){const M=d==="backward",Y=M?Z0:zp,R={pages:h,pageParams:v},P=Y(o,R);p=await $(R,P,M)}else{const M=n??h.length;do{const Y=y===0?v[0]??o.initialPageParam:zp(o,p);if(y>0&&Y==null)break;p=await $(p,Y),y++}while(y<M)}return p};i.options.persister?i.fetchFn=()=>{var H,U;return(U=(H=i.options).persister)==null?void 0:U.call(H,x,{client:i.client,queryKey:i.queryKey,meta:i.options.meta,signal:i.signal},c)}:i.fetchFn=x}}}function zp(n,{pages:i,pageParams:c}){const o=i.length-1;return i.length>0?n.getNextPageParam(i[o],i,c[o],c):void 0}function Z0(n,{pages:i,pageParams:c}){var o;return i.length>0?(o=n.getPreviousPageParam)==null?void 0:o.call(n,i[0],i,c[0],c):void 0}var pi,hl,mt,tn,ml,ma,Jp,J0=(Jp=class extends nv{constructor(i){super();ne(this,ml);ne(this,pi);ne(this,hl);ne(this,mt);ne(this,tn);I(this,pi,i.client),this.mutationId=i.mutationId,I(this,mt,i.mutationCache),I(this,hl,[]),this.state=i.state||uv(),this.setOptions(i.options),this.scheduleGc()}setOptions(i){this.options=i,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(i){N(this,hl).includes(i)||(N(this,hl).push(i),this.clearGcTimeout(),N(this,mt).notify({type:"observerAdded",mutation:this,observer:i}))}removeObserver(i){I(this,hl,N(this,hl).filter(c=>c!==i)),this.scheduleGc(),N(this,mt).notify({type:"observerRemoved",mutation:this,observer:i})}optionalRemove(){N(this,hl).length||(this.state.status==="pending"?this.scheduleGc():N(this,mt).remove(this))}continue(){var i;return((i=N(this,tn))==null?void 0:i.continue())??this.execute(this.state.variables)}async execute(i){var v,p,y,x,b,g,A,O,k,H,U,V,$,M,Y,R,P,q;const c=()=>{me(this,ml,ma).call(this,{type:"continue"})},o={client:N(this,pi),meta:this.options.meta,mutationKey:this.options.mutationKey};I(this,tn,av({fn:()=>this.options.mutationFn?this.options.mutationFn(i,o):Promise.reject(new Error("No mutationFn found")),onFail:(Z,G)=>{me(this,ml,ma).call(this,{type:"failed",failureCount:Z,error:G})},onPause:()=>{me(this,ml,ma).call(this,{type:"pause"})},onContinue:c,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>N(this,mt).canRun(this)}));const d=this.state.status==="pending",h=!N(this,tn).canStart();try{if(d)c();else{me(this,ml,ma).call(this,{type:"pending",variables:i,isPaused:h}),N(this,mt).config.onMutate&&await N(this,mt).config.onMutate(i,this,o);const G=await((p=(v=this.options).onMutate)==null?void 0:p.call(v,i,o));G!==this.state.context&&me(this,ml,ma).call(this,{type:"pending",context:G,variables:i,isPaused:h})}const Z=await N(this,tn).start();return await((x=(y=N(this,mt).config).onSuccess)==null?void 0:x.call(y,Z,i,this.state.context,this,o)),await((g=(b=this.options).onSuccess)==null?void 0:g.call(b,Z,i,this.state.context,o)),await((O=(A=N(this,mt).config).onSettled)==null?void 0:O.call(A,Z,null,this.state.variables,this.state.context,this,o)),await((H=(k=this.options).onSettled)==null?void 0:H.call(k,Z,null,i,this.state.context,o)),me(this,ml,ma).call(this,{type:"success",data:Z}),Z}catch(Z){try{await((V=(U=N(this,mt).config).onError)==null?void 0:V.call(U,Z,i,this.state.context,this,o))}catch(G){Promise.reject(G)}try{await((M=($=this.options).onError)==null?void 0:M.call($,Z,i,this.state.context,o))}catch(G){Promise.reject(G)}try{await((R=(Y=N(this,mt).config).onSettled)==null?void 0:R.call(Y,void 0,Z,this.state.variables,this.state.context,this,o))}catch(G){Promise.reject(G)}try{await((q=(P=this.options).onSettled)==null?void 0:q.call(P,void 0,Z,i,this.state.context,o))}catch(G){Promise.reject(G)}throw me(this,ml,ma).call(this,{type:"error",error:Z}),Z}finally{N(this,mt).runNext(this)}}},pi=new WeakMap,hl=new WeakMap,mt=new WeakMap,tn=new WeakMap,ml=new WeakSet,ma=function(i){const c=o=>{switch(i.type){case"failed":return{...o,failureCount:i.failureCount,failureReason:i.error};case"pause":return{...o,isPaused:!0};case"continue":return{...o,isPaused:!1};case"pending":return{...o,context:i.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:i.isPaused,status:"pending",variables:i.variables,submittedAt:Date.now()};case"success":return{...o,data:i.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...o,data:void 0,error:i.error,failureCount:o.failureCount+1,failureReason:i.error,isPaused:!1,status:"error"}}};this.state=c(this.state),et.batch(()=>{N(this,hl).forEach(o=>{o.onMutationUpdate(i)}),N(this,mt).notify({mutation:this,type:"updated",action:i})})},Jp);function uv(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var ql,il,vi,$p,$0=($p=class extends is{constructor(i={}){super();ne(this,ql);ne(this,il);ne(this,vi);this.config=i,I(this,ql,new Set),I(this,il,new Map),I(this,vi,0)}build(i,c,o){const d=new J0({client:i,mutationCache:this,mutationId:++qu(this,vi)._,options:i.defaultMutationOptions(c),state:o});return this.add(d),d}add(i){N(this,ql).add(i);const c=Bu(i);if(typeof c=="string"){const o=N(this,il).get(c);o?o.push(i):N(this,il).set(c,[i])}this.notify({type:"added",mutation:i})}remove(i){if(N(this,ql).delete(i)){const c=Bu(i);if(typeof c=="string"){const o=N(this,il).get(c);if(o)if(o.length>1){const d=o.indexOf(i);d!==-1&&o.splice(d,1)}else o[0]===i&&N(this,il).delete(c)}}this.notify({type:"removed",mutation:i})}canRun(i){const c=Bu(i);if(typeof c=="string"){const o=N(this,il).get(c),d=o==null?void 0:o.find(h=>h.state.status==="pending");return!d||d===i}else return!0}runNext(i){var o;const c=Bu(i);if(typeof c=="string"){const d=(o=N(this,il).get(c))==null?void 0:o.find(h=>h!==i&&h.state.isPaused);return(d==null?void 0:d.continue())??Promise.resolve()}else return Promise.resolve()}clear(){et.batch(()=>{N(this,ql).forEach(i=>{this.notify({type:"removed",mutation:i})}),N(this,ql).clear(),N(this,il).clear()})}getAll(){return Array.from(N(this,ql))}find(i){const c={exact:!0,...i};return this.getAll().find(o=>Np(c,o))}findAll(i={}){return this.getAll().filter(c=>Np(i,c))}notify(i){et.batch(()=>{this.listeners.forEach(c=>{c(i)})})}resumePausedMutations(){const i=this.getAll().filter(c=>c.state.isPaused);return et.batch(()=>Promise.all(i.map(c=>c.continue().catch(yt))))}},ql=new WeakMap,il=new WeakMap,vi=new WeakMap,$p);function Bu(n){var i;return(i=n.options.scope)==null?void 0:i.id}var Bl,ba,Rt,Ll,Ql,Qu,ko,Fp,F0=(Fp=class extends is{constructor(c,o){super();ne(this,Ql);ne(this,Bl);ne(this,ba);ne(this,Rt);ne(this,Ll);I(this,Bl,c),this.setOptions(o),this.bindMethods(),me(this,Ql,Qu).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(c){var d;const o=this.options;this.options=N(this,Bl).defaultMutationOptions(c),Xu(this.options,o)||N(this,Bl).getMutationCache().notify({type:"observerOptionsUpdated",mutation:N(this,Rt),observer:this}),o!=null&&o.mutationKey&&this.options.mutationKey&&an(o.mutationKey)!==an(this.options.mutationKey)?this.reset():((d=N(this,Rt))==null?void 0:d.state.status)==="pending"&&N(this,Rt).setOptions(this.options)}onUnsubscribe(){var c;this.hasListeners()||(c=N(this,Rt))==null||c.removeObserver(this)}onMutationUpdate(c){me(this,Ql,Qu).call(this),me(this,Ql,ko).call(this,c)}getCurrentResult(){return N(this,ba)}reset(){var c;(c=N(this,Rt))==null||c.removeObserver(this),I(this,Rt,void 0),me(this,Ql,Qu).call(this),me(this,Ql,ko).call(this)}mutate(c,o){var d;return I(this,Ll,o),(d=N(this,Rt))==null||d.removeObserver(this),I(this,Rt,N(this,Bl).getMutationCache().build(N(this,Bl),this.options)),N(this,Rt).addObserver(this),N(this,Rt).execute(c)}},Bl=new WeakMap,ba=new WeakMap,Rt=new WeakMap,Ll=new WeakMap,Ql=new WeakSet,Qu=function(){var o;const c=((o=N(this,Rt))==null?void 0:o.state)??uv();I(this,ba,{...c,isPending:c.status==="pending",isSuccess:c.status==="success",isError:c.status==="error",isIdle:c.status==="idle",mutate:this.mutate,reset:this.reset})},ko=function(c){et.batch(()=>{var o,d,h,v,p,y,x,b;if(N(this,Ll)&&this.hasListeners()){const g=N(this,ba).variables,A=N(this,ba).context,O={client:N(this,Bl),meta:this.options.meta,mutationKey:this.options.mutationKey};if((c==null?void 0:c.type)==="success"){try{(d=(o=N(this,Ll)).onSuccess)==null||d.call(o,c.data,g,A,O)}catch(k){Promise.reject(k)}try{(v=(h=N(this,Ll)).onSettled)==null||v.call(h,c.data,null,g,A,O)}catch(k){Promise.reject(k)}}else if((c==null?void 0:c.type)==="error"){try{(y=(p=N(this,Ll)).onError)==null||y.call(p,c.error,g,A,O)}catch(k){Promise.reject(k)}try{(b=(x=N(this,Ll)).onSettled)==null||b.call(x,void 0,c.error,g,A,O)}catch(k){Promise.reject(k)}}}this.listeners.forEach(g=>{g(N(this,ba))})})},Fp),pl,Wp,W0=(Wp=class extends is{constructor(i={}){super();ne(this,pl);this.config=i,I(this,pl,new Map)}build(i,c,o){const d=c.queryKey,h=c.queryHash??Jo(d,c);let v=this.get(h);return v||(v=new G0({client:i,queryKey:d,queryHash:h,options:i.defaultQueryOptions(c),state:o,defaultOptions:i.getQueryDefaults(d)}),this.add(v)),v}add(i){N(this,pl).has(i.queryHash)||(N(this,pl).set(i.queryHash,i),this.notify({type:"added",query:i}))}remove(i){const c=N(this,pl).get(i.queryHash);c&&(i.destroy(),c===i&&N(this,pl).delete(i.queryHash),this.notify({type:"removed",query:i}))}clear(){et.batch(()=>{this.getAll().forEach(i=>{this.remove(i)})})}get(i){return N(this,pl).get(i)}getAll(){return[...N(this,pl).values()]}find(i){const c={exact:!0,...i};return this.getAll().find(o=>jp(c,o))}findAll(i={}){const c=this.getAll();return Object.keys(i).length>0?c.filter(o=>jp(i,o)):c}notify(i){et.batch(()=>{this.listeners.forEach(c=>{c(i)})})}onFocus(){et.batch(()=>{this.getAll().forEach(i=>{i.onFocus()})})}onOnline(){et.batch(()=>{this.getAll().forEach(i=>{i.onOnline()})})}},pl=new WeakMap,Wp),Ge,Sa,ja,es,ts,Na,ls,as,Ip,I0=(Ip=class{constructor(n={}){ne(this,Ge);ne(this,Sa);ne(this,ja);ne(this,es);ne(this,ts);ne(this,Na);ne(this,ls);ne(this,as);I(this,Ge,n.queryCache||new W0),I(this,Sa,n.mutationCache||new $0),I(this,ja,n.defaultOptions||{}),I(this,es,new Map),I(this,ts,new Map),I(this,Na,0)}mount(){qu(this,Na)._++,N(this,Na)===1&&(I(this,ls,Wo.subscribe(async n=>{n&&(await this.resumePausedMutations(),N(this,Ge).onFocus())})),I(this,as,Ku.subscribe(async n=>{n&&(await this.resumePausedMutations(),N(this,Ge).onOnline())})))}unmount(){var n,i;qu(this,Na)._--,N(this,Na)===0&&((n=N(this,ls))==null||n.call(this),I(this,ls,void 0),(i=N(this,as))==null||i.call(this),I(this,as,void 0))}isFetching(n){return N(this,Ge).findAll({...n,fetchStatus:"fetching"}).length}isMutating(n){return N(this,Sa).findAll({...n,status:"pending"}).length}getQueryData(n){var c;const i=this.defaultQueryOptions({queryKey:n});return(c=N(this,Ge).get(i.queryHash))==null?void 0:c.state.data}ensureQueryData(n){const i=this.defaultQueryOptions(n),c=N(this,Ge).build(this,i),o=c.state.data;return o===void 0?this.fetchQuery(n):(n.revalidateIfStale&&c.isStaleByTime(Ea(i.staleTime,c))&&this.prefetchQuery(i),Promise.resolve(o))}getQueriesData(n){return N(this,Ge).findAll(n).map(({queryKey:i,state:c})=>{const o=c.data;return[i,o]})}setQueryData(n,i,c){const o=this.defaultQueryOptions({queryKey:n}),d=N(this,Ge).get(o.queryHash),h=d==null?void 0:d.state.data,v=_0(i,h);if(v!==void 0)return N(this,Ge).build(this,o).setData(v,{...c,manual:!0})}setQueriesData(n,i,c){return et.batch(()=>N(this,Ge).findAll(n).map(({queryKey:o})=>[o,this.setQueryData(o,i,c)]))}getQueryState(n){var c;const i=this.defaultQueryOptions({queryKey:n});return(c=N(this,Ge).get(i.queryHash))==null?void 0:c.state}removeQueries(n){const i=N(this,Ge);et.batch(()=>{i.findAll(n).forEach(c=>{i.remove(c)})})}resetQueries(n,i){const c=N(this,Ge);return et.batch(()=>(c.findAll(n).forEach(o=>{o.reset()}),this.refetchQueries({type:"active",...n},i)))}cancelQueries(n,i={}){const c={revert:!0,...i},o=et.batch(()=>N(this,Ge).findAll(n).map(d=>d.cancel(c)));return Promise.all(o).then(yt).catch(yt)}invalidateQueries(n,i={}){return et.batch(()=>(N(this,Ge).findAll(n).forEach(c=>{c.invalidate()}),(n==null?void 0:n.refetchType)==="none"?Promise.resolve():this.refetchQueries({...n,type:(n==null?void 0:n.refetchType)??(n==null?void 0:n.type)??"active"},i)))}refetchQueries(n,i={}){const c={...i,cancelRefetch:i.cancelRefetch??!0},o=et.batch(()=>N(this,Ge).findAll(n).filter(d=>!d.isDisabled()&&!d.isStatic()).map(d=>{let h=d.fetch(void 0,c);return c.throwOnError||(h=h.catch(yt)),d.state.fetchStatus==="paused"?Promise.resolve():h}));return Promise.all(o).then(yt)}fetchQuery(n){const i=this.defaultQueryOptions(n);i.retry===void 0&&(i.retry=!1);const c=N(this,Ge).build(this,i);return c.isStaleByTime(Ea(i.staleTime,c))?c.fetch(i):Promise.resolve(c.state.data)}prefetchQuery(n){return this.fetchQuery(n).then(yt).catch(yt)}fetchInfiniteQuery(n){return n.behavior=Mp(n.pages),this.fetchQuery(n)}prefetchInfiniteQuery(n){return this.fetchInfiniteQuery(n).then(yt).catch(yt)}ensureInfiniteQueryData(n){return n.behavior=Mp(n.pages),this.ensureQueryData(n)}resumePausedMutations(){return Ku.isOnline()?N(this,Sa).resumePausedMutations():Promise.resolve()}getQueryCache(){return N(this,Ge)}getMutationCache(){return N(this,Sa)}getDefaultOptions(){return N(this,ja)}setDefaultOptions(n){I(this,ja,n)}setQueryDefaults(n,i){N(this,es).set(an(n),{queryKey:n,defaultOptions:i})}getQueryDefaults(n){const i=[...N(this,es).values()],c={};return i.forEach(o=>{oi(n,o.queryKey)&&Object.assign(c,o.defaultOptions)}),c}setMutationDefaults(n,i){N(this,ts).set(an(n),{mutationKey:n,defaultOptions:i})}getMutationDefaults(n){const i=[...N(this,ts).values()],c={};return i.forEach(o=>{oi(n,o.mutationKey)&&Object.assign(c,o.defaultOptions)}),c}defaultQueryOptions(n){if(n._defaulted)return n;const i={...N(this,ja).queries,...this.getQueryDefaults(n.queryKey),...n,_defaulted:!0};return i.queryHash||(i.queryHash=Jo(i.queryKey,i)),i.refetchOnReconnect===void 0&&(i.refetchOnReconnect=i.networkMode!=="always"),i.throwOnError===void 0&&(i.throwOnError=!!i.suspense),!i.networkMode&&i.persister&&(i.networkMode="offlineFirst"),i.queryFn===$o&&(i.enabled=!1),i}defaultMutationOptions(n){return n!=null&&n._defaulted?n:{...N(this,ja).mutations,...(n==null?void 0:n.mutationKey)&&this.getMutationDefaults(n.mutationKey),...n,_defaulted:!0}}clear(){N(this,Ge).clear(),N(this,Sa).clear()}},Ge=new WeakMap,Sa=new WeakMap,ja=new WeakMap,es=new WeakMap,ts=new WeakMap,Na=new WeakMap,ls=new WeakMap,as=new WeakMap,Ip),rv=S.createContext(void 0),xi=n=>{const i=S.useContext(rv);if(!i)throw new Error("No QueryClient set, use QueryClientProvider to set one");return i},P0=({client:n,children:i})=>(S.useEffect(()=>(n.mount(),()=>{n.unmount()}),[n]),r.jsx(rv.Provider,{value:n,children:i})),cv=S.createContext(!1),eg=()=>S.useContext(cv);cv.Provider;function tg(){let n=!1;return{clearReset:()=>{n=!1},reset:()=>{n=!0},isReset:()=>n}}var lg=S.createContext(tg()),ag=()=>S.useContext(lg),ng=(n,i,c)=>{const o=c!=null&&c.state.error&&typeof n.throwOnError=="function"?Fo(n.throwOnError,[c.state.error,c]):n.throwOnError;(n.suspense||n.experimental_prefetchInRender||o)&&(i.isReset()||(n.retryOnMount=!1))},sg=n=>{S.useEffect(()=>{n.clearReset()},[n])},ig=({result:n,errorResetBoundary:i,throwOnError:c,query:o,suspense:d})=>n.isError&&!i.isReset()&&!n.isFetching&&o&&(d&&n.data===void 0||Fo(c,[n.error,o])),ug=n=>{if(n.suspense){const c=d=>d==="static"?d:Math.max(d??1e3,1e3),o=n.staleTime;n.staleTime=typeof o=="function"?(...d)=>c(o(...d)):c(o),typeof n.gcTime=="number"&&(n.gcTime=Math.max(n.gcTime,1e3))}},rg=(n,i)=>n.isLoading&&n.isFetching&&!i,cg=(n,i)=>(n==null?void 0:n.suspense)&&i.isPending,_p=(n,i,c)=>i.fetchOptimistic(n).catch(()=>{c.clearReset()});function og(n,i,c){var A,O,k,H;const o=eg(),d=ag(),h=xi(),v=h.defaultQueryOptions(n);(O=(A=h.getDefaultOptions().queries)==null?void 0:A._experimental_beforeQuery)==null||O.call(A,v);const p=h.getQueryCache().get(v.queryHash);v._optimisticResults=o?"isRestoring":"optimistic",ug(v),ng(v,d,p),sg(d);const y=!h.getQueryCache().get(v.queryHash),[x]=S.useState(()=>new i(h,v)),b=x.getOptimisticResult(v),g=!o&&n.subscribed!==!1;if(S.useSyncExternalStore(S.useCallback(U=>{const V=g?x.subscribe(et.batchCalls(U)):yt;return x.updateResult(),V},[x,g]),()=>x.getCurrentResult(),()=>x.getCurrentResult()),S.useEffect(()=>{x.setOptions(v)},[v,x]),cg(v,b))throw _p(v,x,d);if(ig({result:b,errorResetBoundary:d,throwOnError:v.throwOnError,query:p,suspense:v.suspense}))throw b.error;if((H=(k=h.getDefaultOptions().queries)==null?void 0:k._experimental_afterQuery)==null||H.call(k,v,b),v.experimental_prefetchInRender&&!ln&&rg(b,o)){const U=y?_p(v,x,d):p==null?void 0:p.promise;U==null||U.catch(yt).finally(()=>{x.updateResult()})}return v.notifyOnChangeProps?b:x.trackResult(b)}function tl(n,i){return og(n,X0)}function Qo(n,i){const c=xi(),[o]=S.useState(()=>new F0(c,n));S.useEffect(()=>{o.setOptions(n)},[o,n]);const d=S.useSyncExternalStore(S.useCallback(v=>o.subscribe(et.batchCalls(v)),[o]),()=>o.getCurrentResult(),()=>o.getCurrentResult()),h=S.useCallback((v,p)=>{o.mutate(v,p).catch(yt)},[o]);if(d.error&&Fo(o.options.throwOnError,[d.error]))throw d.error;return{...d,mutate:h,mutateAsync:d.mutate}}const fg=new I0({defaultOptions:{queries:{staleTime:5e3,retry:1}}});/**
50
+ * react-router v7.13.0
51
+ *
52
+ * Copyright (c) Remix Software Inc.
53
+ *
54
+ * This source code is licensed under the MIT license found in the
55
+ * LICENSE.md file in the root directory of this source tree.
56
+ *
57
+ * @license MIT
58
+ */var wp="popstate";function dg(n={}){function i(o,d){let{pathname:h,search:v,hash:p}=o.location;return Yo("",{pathname:h,search:v,hash:p},d.state&&d.state.usr||null,d.state&&d.state.key||"default")}function c(o,d){return typeof d=="string"?d:fi(d)}return mg(i,c,null,n)}function ke(n,i){if(n===!1||n===null||typeof n>"u")throw new Error(i)}function ul(n,i){if(!n){typeof console<"u"&&console.warn(i);try{throw new Error(i)}catch{}}}function hg(){return Math.random().toString(36).substring(2,10)}function Dp(n,i){return{usr:n.state,key:n.key,idx:i}}function Yo(n,i,c=null,o){return{pathname:typeof n=="string"?n:n.pathname,search:"",hash:"",...typeof i=="string"?us(i):i,state:c,key:i&&i.key||o||hg()}}function fi({pathname:n="/",search:i="",hash:c=""}){return i&&i!=="?"&&(n+=i.charAt(0)==="?"?i:"?"+i),c&&c!=="#"&&(n+=c.charAt(0)==="#"?c:"#"+c),n}function us(n){let i={};if(n){let c=n.indexOf("#");c>=0&&(i.hash=n.substring(c),n=n.substring(0,c));let o=n.indexOf("?");o>=0&&(i.search=n.substring(o),n=n.substring(0,o)),n&&(i.pathname=n)}return i}function mg(n,i,c,o={}){let{window:d=document.defaultView,v5Compat:h=!1}=o,v=d.history,p="POP",y=null,x=b();x==null&&(x=0,v.replaceState({...v.state,idx:x},""));function b(){return(v.state||{idx:null}).idx}function g(){p="POP";let U=b(),V=U==null?null:U-x;x=U,y&&y({action:p,location:H.location,delta:V})}function A(U,V){p="PUSH";let $=Yo(H.location,U,V);x=b()+1;let M=Dp($,x),Y=H.createHref($);try{v.pushState(M,"",Y)}catch(R){if(R instanceof DOMException&&R.name==="DataCloneError")throw R;d.location.assign(Y)}h&&y&&y({action:p,location:H.location,delta:1})}function O(U,V){p="REPLACE";let $=Yo(H.location,U,V);x=b();let M=Dp($,x),Y=H.createHref($);v.replaceState(M,"",Y),h&&y&&y({action:p,location:H.location,delta:0})}function k(U){return pg(U)}let H={get action(){return p},get location(){return n(d,v)},listen(U){if(y)throw new Error("A history only accepts one active listener");return d.addEventListener(wp,g),y=U,()=>{d.removeEventListener(wp,g),y=null}},createHref(U){return i(d,U)},createURL:k,encodeLocation(U){let V=k(U);return{pathname:V.pathname,search:V.search,hash:V.hash}},push:A,replace:O,go(U){return v.go(U)}};return H}function pg(n,i=!1){let c="http://localhost";typeof window<"u"&&(c=window.location.origin!=="null"?window.location.origin:window.location.href),ke(c,"No window.location.(origin|href) available to create URL");let o=typeof n=="string"?n:fi(n);return o=o.replace(/ $/,"%20"),!i&&o.startsWith("//")&&(o=c+o),new URL(o,c)}function ov(n,i,c="/"){return vg(n,i,c,!1)}function vg(n,i,c,o){let d=typeof i=="string"?us(i):i,h=Yl(d.pathname||"/",c);if(h==null)return null;let v=fv(n);xg(v);let p=null;for(let y=0;p==null&&y<v.length;++y){let x=Rg(h);p=Tg(v[y],x,o)}return p}function fv(n,i=[],c=[],o="",d=!1){let h=(v,p,y=d,x)=>{let b={relativePath:x===void 0?v.path||"":x,caseSensitive:v.caseSensitive===!0,childrenIndex:p,route:v};if(b.relativePath.startsWith("/")){if(!b.relativePath.startsWith(o)&&y)return;ke(b.relativePath.startsWith(o),`Absolute route path "${b.relativePath}" nested under path "${o}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),b.relativePath=b.relativePath.slice(o.length)}let g=kl([o,b.relativePath]),A=c.concat(b);v.children&&v.children.length>0&&(ke(v.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${g}".`),fv(v.children,i,A,g,y)),!(v.path==null&&!v.index)&&i.push({path:g,score:Eg(g,v.index),routesMeta:A})};return n.forEach((v,p)=>{var y;if(v.path===""||!((y=v.path)!=null&&y.includes("?")))h(v,p);else for(let x of dv(v.path))h(v,p,!0,x)}),i}function dv(n){let i=n.split("/");if(i.length===0)return[];let[c,...o]=i,d=c.endsWith("?"),h=c.replace(/\?$/,"");if(o.length===0)return d?[h,""]:[h];let v=dv(o.join("/")),p=[];return p.push(...v.map(y=>y===""?h:[h,y].join("/"))),d&&p.push(...v),p.map(y=>n.startsWith("/")&&y===""?"/":y)}function xg(n){n.sort((i,c)=>i.score!==c.score?c.score-i.score:Cg(i.routesMeta.map(o=>o.childrenIndex),c.routesMeta.map(o=>o.childrenIndex)))}var yg=/^:[\w-]+$/,gg=3,bg=2,Sg=1,jg=10,Ng=-2,Up=n=>n==="*";function Eg(n,i){let c=n.split("/"),o=c.length;return c.some(Up)&&(o+=Ng),i&&(o+=bg),c.filter(d=>!Up(d)).reduce((d,h)=>d+(yg.test(h)?gg:h===""?Sg:jg),o)}function Cg(n,i){return n.length===i.length&&n.slice(0,-1).every((o,d)=>o===i[d])?n[n.length-1]-i[i.length-1]:0}function Tg(n,i,c=!1){let{routesMeta:o}=n,d={},h="/",v=[];for(let p=0;p<o.length;++p){let y=o[p],x=p===o.length-1,b=h==="/"?i:i.slice(h.length)||"/",g=Vu({path:y.relativePath,caseSensitive:y.caseSensitive,end:x},b),A=y.route;if(!g&&x&&c&&!o[o.length-1].route.index&&(g=Vu({path:y.relativePath,caseSensitive:y.caseSensitive,end:!1},b)),!g)return null;Object.assign(d,g.params),v.push({params:d,pathname:kl([h,g.pathname]),pathnameBase:_g(kl([h,g.pathnameBase])),route:A}),g.pathnameBase!=="/"&&(h=kl([h,g.pathnameBase]))}return v}function Vu(n,i){typeof n=="string"&&(n={path:n,caseSensitive:!1,end:!0});let[c,o]=Og(n.path,n.caseSensitive,n.end),d=i.match(c);if(!d)return null;let h=d[0],v=h.replace(/(.)\/+$/,"$1"),p=d.slice(1);return{params:o.reduce((x,{paramName:b,isOptional:g},A)=>{if(b==="*"){let k=p[A]||"";v=h.slice(0,h.length-k.length).replace(/(.)\/+$/,"$1")}const O=p[A];return g&&!O?x[b]=void 0:x[b]=(O||"").replace(/%2F/g,"/"),x},{}),pathname:h,pathnameBase:v,pattern:n}}function Og(n,i=!1,c=!0){ul(n==="*"||!n.endsWith("*")||n.endsWith("/*"),`Route path "${n}" will be treated as if it were "${n.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${n.replace(/\*$/,"/*")}".`);let o=[],d="^"+n.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(v,p,y)=>(o.push({paramName:p,isOptional:y!=null}),y?"/?([^\\/]+)?":"/([^\\/]+)")).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return n.endsWith("*")?(o.push({paramName:"*"}),d+=n==="*"||n==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):c?d+="\\/*$":n!==""&&n!=="/"&&(d+="(?:(?=\\/|$))"),[new RegExp(d,i?void 0:"i"),o]}function Rg(n){try{return n.split("/").map(i=>decodeURIComponent(i).replace(/\//g,"%2F")).join("/")}catch(i){return ul(!1,`The URL path "${n}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${i}).`),n}}function Yl(n,i){if(i==="/")return n;if(!n.toLowerCase().startsWith(i.toLowerCase()))return null;let c=i.endsWith("/")?i.length-1:i.length,o=n.charAt(c);return o&&o!=="/"?null:n.slice(c)||"/"}var Ag=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i;function Mg(n,i="/"){let{pathname:c,search:o="",hash:d=""}=typeof n=="string"?us(n):n,h;return c?(c=c.replace(/\/\/+/g,"/"),c.startsWith("/")?h=Hp(c.substring(1),"/"):h=Hp(c,i)):h=i,{pathname:h,search:wg(o),hash:Dg(d)}}function Hp(n,i){let c=i.replace(/\/+$/,"").split("/");return n.split("/").forEach(d=>{d===".."?c.length>1&&c.pop():d!=="."&&c.push(d)}),c.length>1?c.join("/"):"/"}function So(n,i,c,o){return`Cannot include a '${n}' character in a manually specified \`to.${i}\` field [${JSON.stringify(o)}]. Please separate it out to the \`to.${c}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function zg(n){return n.filter((i,c)=>c===0||i.route.path&&i.route.path.length>0)}function Po(n){let i=zg(n);return i.map((c,o)=>o===i.length-1?c.pathname:c.pathnameBase)}function ef(n,i,c,o=!1){let d;typeof n=="string"?d=us(n):(d={...n},ke(!d.pathname||!d.pathname.includes("?"),So("?","pathname","search",d)),ke(!d.pathname||!d.pathname.includes("#"),So("#","pathname","hash",d)),ke(!d.search||!d.search.includes("#"),So("#","search","hash",d)));let h=n===""||d.pathname==="",v=h?"/":d.pathname,p;if(v==null)p=c;else{let g=i.length-1;if(!o&&v.startsWith("..")){let A=v.split("/");for(;A[0]==="..";)A.shift(),g-=1;d.pathname=A.join("/")}p=g>=0?i[g]:"/"}let y=Mg(d,p),x=v&&v!=="/"&&v.endsWith("/"),b=(h||v===".")&&c.endsWith("/");return!y.pathname.endsWith("/")&&(x||b)&&(y.pathname+="/"),y}var kl=n=>n.join("/").replace(/\/\/+/g,"/"),_g=n=>n.replace(/\/+$/,"").replace(/^\/*/,"/"),wg=n=>!n||n==="?"?"":n.startsWith("?")?n:"?"+n,Dg=n=>!n||n==="#"?"":n.startsWith("#")?n:"#"+n,Ug=class{constructor(n,i,c,o=!1){this.status=n,this.statusText=i||"",this.internal=o,c instanceof Error?(this.data=c.toString(),this.error=c):this.data=c}};function Hg(n){return n!=null&&typeof n.status=="number"&&typeof n.statusText=="string"&&typeof n.internal=="boolean"&&"data"in n}function qg(n){return n.map(i=>i.route.path).filter(Boolean).join("/").replace(/\/\/*/g,"/")||"/"}var hv=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function mv(n,i){let c=n;if(typeof c!="string"||!Ag.test(c))return{absoluteURL:void 0,isExternal:!1,to:c};let o=c,d=!1;if(hv)try{let h=new URL(window.location.href),v=c.startsWith("//")?new URL(h.protocol+c):new URL(c),p=Yl(v.pathname,i);v.origin===h.origin&&p!=null?c=p+v.search+v.hash:d=!0}catch{ul(!1,`<Link to="${c}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:o,isExternal:d,to:c}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var pv=["POST","PUT","PATCH","DELETE"];new Set(pv);var Bg=["GET",...pv];new Set(Bg);var rs=S.createContext(null);rs.displayName="DataRouter";var Ju=S.createContext(null);Ju.displayName="DataRouterState";var Lg=S.createContext(!1),vv=S.createContext({isTransitioning:!1});vv.displayName="ViewTransition";var kg=S.createContext(new Map);kg.displayName="Fetchers";var Qg=S.createContext(null);Qg.displayName="Await";var Qt=S.createContext(null);Qt.displayName="Navigation";var yi=S.createContext(null);yi.displayName="Location";var vl=S.createContext({outlet:null,matches:[],isDataRoute:!1});vl.displayName="Route";var tf=S.createContext(null);tf.displayName="RouteError";var xv="REACT_ROUTER_ERROR",Yg="REDIRECT",Gg="ROUTE_ERROR_RESPONSE";function Xg(n){if(n.startsWith(`${xv}:${Yg}:{`))try{let i=JSON.parse(n.slice(28));if(typeof i=="object"&&i&&typeof i.status=="number"&&typeof i.statusText=="string"&&typeof i.location=="string"&&typeof i.reloadDocument=="boolean"&&typeof i.replace=="boolean")return i}catch{}}function Kg(n){if(n.startsWith(`${xv}:${Gg}:{`))try{let i=JSON.parse(n.slice(40));if(typeof i=="object"&&i&&typeof i.status=="number"&&typeof i.statusText=="string")return new Ug(i.status,i.statusText,i.data)}catch{}}function Vg(n,{relative:i}={}){ke(cs(),"useHref() may be used only in the context of a <Router> component.");let{basename:c,navigator:o}=S.useContext(Qt),{hash:d,pathname:h,search:v}=gi(n,{relative:i}),p=h;return c!=="/"&&(p=h==="/"?c:kl([c,h])),o.createHref({pathname:p,search:v,hash:d})}function cs(){return S.useContext(yi)!=null}function Ca(){return ke(cs(),"useLocation() may be used only in the context of a <Router> component."),S.useContext(yi).location}var yv="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function gv(n){S.useContext(Qt).static||S.useLayoutEffect(n)}function bv(){let{isDataRoute:n}=S.useContext(vl);return n?sb():Zg()}function Zg(){ke(cs(),"useNavigate() may be used only in the context of a <Router> component.");let n=S.useContext(rs),{basename:i,navigator:c}=S.useContext(Qt),{matches:o}=S.useContext(vl),{pathname:d}=Ca(),h=JSON.stringify(Po(o)),v=S.useRef(!1);return gv(()=>{v.current=!0}),S.useCallback((y,x={})=>{if(ul(v.current,yv),!v.current)return;if(typeof y=="number"){c.go(y);return}let b=ef(y,JSON.parse(h),d,x.relative==="path");n==null&&i!=="/"&&(b.pathname=b.pathname==="/"?i:kl([i,b.pathname])),(x.replace?c.replace:c.push)(b,x.state,x)},[i,c,h,d,n])}S.createContext(null);function gi(n,{relative:i}={}){let{matches:c}=S.useContext(vl),{pathname:o}=Ca(),d=JSON.stringify(Po(c));return S.useMemo(()=>ef(n,JSON.parse(d),o,i==="path"),[n,d,o,i])}function Jg(n,i){return Sv(n,i)}function Sv(n,i,c,o,d){var $;ke(cs(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:h}=S.useContext(Qt),{matches:v}=S.useContext(vl),p=v[v.length-1],y=p?p.params:{},x=p?p.pathname:"/",b=p?p.pathnameBase:"/",g=p&&p.route;{let M=g&&g.path||"";Nv(x,!g||M.endsWith("*")||M.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${x}" (under <Route path="${M}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.
59
+
60
+ Please change the parent <Route path="${M}"> to <Route path="${M==="/"?"*":`${M}/*`}">.`)}let A=Ca(),O;if(i){let M=typeof i=="string"?us(i):i;ke(b==="/"||(($=M.pathname)==null?void 0:$.startsWith(b)),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${b}" but pathname "${M.pathname}" was given in the \`location\` prop.`),O=M}else O=A;let k=O.pathname||"/",H=k;if(b!=="/"){let M=b.replace(/^\//,"").split("/");H="/"+k.replace(/^\//,"").split("/").slice(M.length).join("/")}let U=ov(n,{pathname:H});ul(g||U!=null,`No routes matched location "${O.pathname}${O.search}${O.hash}" `),ul(U==null||U[U.length-1].route.element!==void 0||U[U.length-1].route.Component!==void 0||U[U.length-1].route.lazy!==void 0,`Matched leaf route at location "${O.pathname}${O.search}${O.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`);let V=Pg(U&&U.map(M=>Object.assign({},M,{params:Object.assign({},y,M.params),pathname:kl([b,h.encodeLocation?h.encodeLocation(M.pathname.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:M.pathname]),pathnameBase:M.pathnameBase==="/"?b:kl([b,h.encodeLocation?h.encodeLocation(M.pathnameBase.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:M.pathnameBase])})),v,c,o,d);return i&&V?S.createElement(yi.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",...O},navigationType:"POP"}},V):V}function $g(){let n=nb(),i=Hg(n)?`${n.status} ${n.statusText}`:n instanceof Error?n.message:JSON.stringify(n),c=n instanceof Error?n.stack:null,o="rgba(200,200,200, 0.5)",d={padding:"0.5rem",backgroundColor:o},h={padding:"2px 4px",backgroundColor:o},v=null;return console.error("Error handled by React Router default ErrorBoundary:",n),v=S.createElement(S.Fragment,null,S.createElement("p",null,"💿 Hey developer 👋"),S.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",S.createElement("code",{style:h},"ErrorBoundary")," or"," ",S.createElement("code",{style:h},"errorElement")," prop on your route.")),S.createElement(S.Fragment,null,S.createElement("h2",null,"Unexpected Application Error!"),S.createElement("h3",{style:{fontStyle:"italic"}},i),c?S.createElement("pre",{style:d},c):null,v)}var Fg=S.createElement($g,null),jv=class extends S.Component{constructor(n){super(n),this.state={location:n.location,revalidation:n.revalidation,error:n.error}}static getDerivedStateFromError(n){return{error:n}}static getDerivedStateFromProps(n,i){return i.location!==n.location||i.revalidation!=="idle"&&n.revalidation==="idle"?{error:n.error,location:n.location,revalidation:n.revalidation}:{error:n.error!==void 0?n.error:i.error,location:i.location,revalidation:n.revalidation||i.revalidation}}componentDidCatch(n,i){this.props.onError?this.props.onError(n,i):console.error("React Router caught the following error during render",n)}render(){let n=this.state.error;if(this.context&&typeof n=="object"&&n&&"digest"in n&&typeof n.digest=="string"){const c=Kg(n.digest);c&&(n=c)}let i=n!==void 0?S.createElement(vl.Provider,{value:this.props.routeContext},S.createElement(tf.Provider,{value:n,children:this.props.component})):this.props.children;return this.context?S.createElement(Wg,{error:n},i):i}};jv.contextType=Lg;var jo=new WeakMap;function Wg({children:n,error:i}){let{basename:c}=S.useContext(Qt);if(typeof i=="object"&&i&&"digest"in i&&typeof i.digest=="string"){let o=Xg(i.digest);if(o){let d=jo.get(i);if(d)throw d;let h=mv(o.location,c);if(hv&&!jo.get(i))if(h.isExternal||o.reloadDocument)window.location.href=h.absoluteURL||h.to;else{const v=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(h.to,{replace:o.replace}));throw jo.set(i,v),v}return S.createElement("meta",{httpEquiv:"refresh",content:`0;url=${h.absoluteURL||h.to}`})}}return n}function Ig({routeContext:n,match:i,children:c}){let o=S.useContext(rs);return o&&o.static&&o.staticContext&&(i.route.errorElement||i.route.ErrorBoundary)&&(o.staticContext._deepestRenderedBoundaryId=i.route.id),S.createElement(vl.Provider,{value:n},c)}function Pg(n,i=[],c=null,o=null,d=null){if(n==null){if(!c)return null;if(c.errors)n=c.matches;else if(i.length===0&&!c.initialized&&c.matches.length>0)n=c.matches;else return null}let h=n,v=c==null?void 0:c.errors;if(v!=null){let b=h.findIndex(g=>g.route.id&&(v==null?void 0:v[g.route.id])!==void 0);ke(b>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(v).join(",")}`),h=h.slice(0,Math.min(h.length,b+1))}let p=!1,y=-1;if(c)for(let b=0;b<h.length;b++){let g=h[b];if((g.route.HydrateFallback||g.route.hydrateFallbackElement)&&(y=b),g.route.id){let{loaderData:A,errors:O}=c,k=g.route.loader&&!A.hasOwnProperty(g.route.id)&&(!O||O[g.route.id]===void 0);if(g.route.lazy||k){p=!0,y>=0?h=h.slice(0,y+1):h=[h[0]];break}}}let x=c&&o?(b,g)=>{var A,O;o(b,{location:c.location,params:((O=(A=c.matches)==null?void 0:A[0])==null?void 0:O.params)??{},unstable_pattern:qg(c.matches),errorInfo:g})}:void 0;return h.reduceRight((b,g,A)=>{let O,k=!1,H=null,U=null;c&&(O=v&&g.route.id?v[g.route.id]:void 0,H=g.route.errorElement||Fg,p&&(y<0&&A===0?(Nv("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),k=!0,U=null):y===A&&(k=!0,U=g.route.hydrateFallbackElement||null)));let V=i.concat(h.slice(0,A+1)),$=()=>{let M;return O?M=H:k?M=U:g.route.Component?M=S.createElement(g.route.Component,null):g.route.element?M=g.route.element:M=b,S.createElement(Ig,{match:g,routeContext:{outlet:b,matches:V,isDataRoute:c!=null},children:M})};return c&&(g.route.ErrorBoundary||g.route.errorElement||A===0)?S.createElement(jv,{location:c.location,revalidation:c.revalidation,component:H,error:O,children:$(),routeContext:{outlet:null,matches:V,isDataRoute:!0},onError:x}):$()},null)}function lf(n){return`${n} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function eb(n){let i=S.useContext(rs);return ke(i,lf(n)),i}function tb(n){let i=S.useContext(Ju);return ke(i,lf(n)),i}function lb(n){let i=S.useContext(vl);return ke(i,lf(n)),i}function af(n){let i=lb(n),c=i.matches[i.matches.length-1];return ke(c.route.id,`${n} can only be used on routes that contain a unique "id"`),c.route.id}function ab(){return af("useRouteId")}function nb(){var o;let n=S.useContext(tf),i=tb("useRouteError"),c=af("useRouteError");return n!==void 0?n:(o=i.errors)==null?void 0:o[c]}function sb(){let{router:n}=eb("useNavigate"),i=af("useNavigate"),c=S.useRef(!1);return gv(()=>{c.current=!0}),S.useCallback(async(d,h={})=>{ul(c.current,yv),c.current&&(typeof d=="number"?await n.navigate(d):await n.navigate(d,{fromRouteId:i,...h}))},[n,i])}var qp={};function Nv(n,i,c){!i&&!qp[n]&&(qp[n]=!0,ul(!1,c))}S.memo(ib);function ib({routes:n,future:i,state:c,onError:o}){return Sv(n,void 0,c,o,i)}function ub({to:n,replace:i,state:c,relative:o}){ke(cs(),"<Navigate> may be used only in the context of a <Router> component.");let{static:d}=S.useContext(Qt);ul(!d,"<Navigate> must not be used on the initial render in a <StaticRouter>. This is a no-op, but you should modify your code so the <Navigate> is only ever rendered in response to some user interaction or state change.");let{matches:h}=S.useContext(vl),{pathname:v}=Ca(),p=bv(),y=ef(n,Po(h),v,o==="path"),x=JSON.stringify(y);return S.useEffect(()=>{p(JSON.parse(x),{replace:i,state:c,relative:o})},[p,x,o,i,c]),null}function dl(n){ke(!1,"A <Route> is only ever to be used as the child of <Routes> element, never rendered directly. Please wrap your <Route> in a <Routes>.")}function rb({basename:n="/",children:i=null,location:c,navigationType:o="POP",navigator:d,static:h=!1,unstable_useTransitions:v}){ke(!cs(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let p=n.replace(/^\/*/,"/"),y=S.useMemo(()=>({basename:p,navigator:d,static:h,unstable_useTransitions:v,future:{}}),[p,d,h,v]);typeof c=="string"&&(c=us(c));let{pathname:x="/",search:b="",hash:g="",state:A=null,key:O="default"}=c,k=S.useMemo(()=>{let H=Yl(x,p);return H==null?null:{location:{pathname:H,search:b,hash:g,state:A,key:O},navigationType:o}},[p,x,b,g,A,O,o]);return ul(k!=null,`<Router basename="${p}"> is not able to match the URL "${x}${b}${g}" because it does not start with the basename, so the <Router> won't render anything.`),k==null?null:S.createElement(Qt.Provider,{value:y},S.createElement(yi.Provider,{children:i,value:k}))}function cb({children:n,location:i}){return Jg(Go(n),i)}function Go(n,i=[]){let c=[];return S.Children.forEach(n,(o,d)=>{if(!S.isValidElement(o))return;let h=[...i,d];if(o.type===S.Fragment){c.push.apply(c,Go(o.props.children,h));return}ke(o.type===dl,`[${typeof o.type=="string"?o.type:o.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),ke(!o.props.index||!o.props.children,"An index route cannot have child routes.");let v={id:o.props.id||h.join("-"),caseSensitive:o.props.caseSensitive,element:o.props.element,Component:o.props.Component,index:o.props.index,path:o.props.path,middleware:o.props.middleware,loader:o.props.loader,action:o.props.action,hydrateFallbackElement:o.props.hydrateFallbackElement,HydrateFallback:o.props.HydrateFallback,errorElement:o.props.errorElement,ErrorBoundary:o.props.ErrorBoundary,hasErrorBoundary:o.props.hasErrorBoundary===!0||o.props.ErrorBoundary!=null||o.props.errorElement!=null,shouldRevalidate:o.props.shouldRevalidate,handle:o.props.handle,lazy:o.props.lazy};o.props.children&&(v.children=Go(o.props.children,h)),c.push(v)}),c}var Yu="get",Gu="application/x-www-form-urlencoded";function $u(n){return typeof HTMLElement<"u"&&n instanceof HTMLElement}function ob(n){return $u(n)&&n.tagName.toLowerCase()==="button"}function fb(n){return $u(n)&&n.tagName.toLowerCase()==="form"}function db(n){return $u(n)&&n.tagName.toLowerCase()==="input"}function hb(n){return!!(n.metaKey||n.altKey||n.ctrlKey||n.shiftKey)}function mb(n,i){return n.button===0&&(!i||i==="_self")&&!hb(n)}var Lu=null;function pb(){if(Lu===null)try{new FormData(document.createElement("form"),0),Lu=!1}catch{Lu=!0}return Lu}var vb=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function No(n){return n!=null&&!vb.has(n)?(ul(!1,`"${n}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${Gu}"`),null):n}function xb(n,i){let c,o,d,h,v;if(fb(n)){let p=n.getAttribute("action");o=p?Yl(p,i):null,c=n.getAttribute("method")||Yu,d=No(n.getAttribute("enctype"))||Gu,h=new FormData(n)}else if(ob(n)||db(n)&&(n.type==="submit"||n.type==="image")){let p=n.form;if(p==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let y=n.getAttribute("formaction")||p.getAttribute("action");if(o=y?Yl(y,i):null,c=n.getAttribute("formmethod")||p.getAttribute("method")||Yu,d=No(n.getAttribute("formenctype"))||No(p.getAttribute("enctype"))||Gu,h=new FormData(p,n),!pb()){let{name:x,type:b,value:g}=n;if(b==="image"){let A=x?`${x}.`:"";h.append(`${A}x`,"0"),h.append(`${A}y`,"0")}else x&&h.append(x,g)}}else{if($u(n))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');c=Yu,o=null,d=Gu,v=n}return h&&d==="text/plain"&&(v=h,h=void 0),{action:o,method:c.toLowerCase(),encType:d,formData:h,body:v}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function nf(n,i){if(n===!1||n===null||typeof n>"u")throw new Error(i)}function yb(n,i,c,o){let d=typeof n=="string"?new URL(n,typeof window>"u"?"server://singlefetch/":window.location.origin):n;return c?d.pathname.endsWith("/")?d.pathname=`${d.pathname}_.${o}`:d.pathname=`${d.pathname}.${o}`:d.pathname==="/"?d.pathname=`_root.${o}`:i&&Yl(d.pathname,i)==="/"?d.pathname=`${i.replace(/\/$/,"")}/_root.${o}`:d.pathname=`${d.pathname.replace(/\/$/,"")}.${o}`,d}async function gb(n,i){if(n.id in i)return i[n.id];try{let c=await import(n.module);return i[n.id]=c,c}catch(c){return console.error(`Error loading route module \`${n.module}\`, reloading page...`),console.error(c),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function bb(n){return n==null?!1:n.href==null?n.rel==="preload"&&typeof n.imageSrcSet=="string"&&typeof n.imageSizes=="string":typeof n.rel=="string"&&typeof n.href=="string"}async function Sb(n,i,c){let o=await Promise.all(n.map(async d=>{let h=i.routes[d.route.id];if(h){let v=await gb(h,c);return v.links?v.links():[]}return[]}));return Cb(o.flat(1).filter(bb).filter(d=>d.rel==="stylesheet"||d.rel==="preload").map(d=>d.rel==="stylesheet"?{...d,rel:"prefetch",as:"style"}:{...d,rel:"prefetch"}))}function Bp(n,i,c,o,d,h){let v=(y,x)=>c[x]?y.route.id!==c[x].route.id:!0,p=(y,x)=>{var b;return c[x].pathname!==y.pathname||((b=c[x].route.path)==null?void 0:b.endsWith("*"))&&c[x].params["*"]!==y.params["*"]};return h==="assets"?i.filter((y,x)=>v(y,x)||p(y,x)):h==="data"?i.filter((y,x)=>{var g;let b=o.routes[y.route.id];if(!b||!b.hasLoader)return!1;if(v(y,x)||p(y,x))return!0;if(y.route.shouldRevalidate){let A=y.route.shouldRevalidate({currentUrl:new URL(d.pathname+d.search+d.hash,window.origin),currentParams:((g=c[0])==null?void 0:g.params)||{},nextUrl:new URL(n,window.origin),nextParams:y.params,defaultShouldRevalidate:!0});if(typeof A=="boolean")return A}return!0}):[]}function jb(n,i,{includeHydrateFallback:c}={}){return Nb(n.map(o=>{let d=i.routes[o.route.id];if(!d)return[];let h=[d.module];return d.clientActionModule&&(h=h.concat(d.clientActionModule)),d.clientLoaderModule&&(h=h.concat(d.clientLoaderModule)),c&&d.hydrateFallbackModule&&(h=h.concat(d.hydrateFallbackModule)),d.imports&&(h=h.concat(d.imports)),h}).flat(1))}function Nb(n){return[...new Set(n)]}function Eb(n){let i={},c=Object.keys(n).sort();for(let o of c)i[o]=n[o];return i}function Cb(n,i){let c=new Set;return new Set(i),n.reduce((o,d)=>{let h=JSON.stringify(Eb(d));return c.has(h)||(c.add(h),o.push({key:h,link:d})),o},[])}function Ev(){let n=S.useContext(rs);return nf(n,"You must render this element inside a <DataRouterContext.Provider> element"),n}function Tb(){let n=S.useContext(Ju);return nf(n,"You must render this element inside a <DataRouterStateContext.Provider> element"),n}var sf=S.createContext(void 0);sf.displayName="FrameworkContext";function Cv(){let n=S.useContext(sf);return nf(n,"You must render this element inside a <HydratedRouter> element"),n}function Ob(n,i){let c=S.useContext(sf),[o,d]=S.useState(!1),[h,v]=S.useState(!1),{onFocus:p,onBlur:y,onMouseEnter:x,onMouseLeave:b,onTouchStart:g}=i,A=S.useRef(null);S.useEffect(()=>{if(n==="render"&&v(!0),n==="viewport"){let H=V=>{V.forEach($=>{v($.isIntersecting)})},U=new IntersectionObserver(H,{threshold:.5});return A.current&&U.observe(A.current),()=>{U.disconnect()}}},[n]),S.useEffect(()=>{if(o){let H=setTimeout(()=>{v(!0)},100);return()=>{clearTimeout(H)}}},[o]);let O=()=>{d(!0)},k=()=>{d(!1),v(!1)};return c?n!=="intent"?[h,A,{}]:[h,A,{onFocus:ii(p,O),onBlur:ii(y,k),onMouseEnter:ii(x,O),onMouseLeave:ii(b,k),onTouchStart:ii(g,O)}]:[!1,A,{}]}function ii(n,i){return c=>{n&&n(c),c.defaultPrevented||i(c)}}function Rb({page:n,...i}){let{router:c}=Ev(),o=S.useMemo(()=>ov(c.routes,n,c.basename),[c.routes,n,c.basename]);return o?S.createElement(Mb,{page:n,matches:o,...i}):null}function Ab(n){let{manifest:i,routeModules:c}=Cv(),[o,d]=S.useState([]);return S.useEffect(()=>{let h=!1;return Sb(n,i,c).then(v=>{h||d(v)}),()=>{h=!0}},[n,i,c]),o}function Mb({page:n,matches:i,...c}){let o=Ca(),{future:d,manifest:h,routeModules:v}=Cv(),{basename:p}=Ev(),{loaderData:y,matches:x}=Tb(),b=S.useMemo(()=>Bp(n,i,x,h,o,"data"),[n,i,x,h,o]),g=S.useMemo(()=>Bp(n,i,x,h,o,"assets"),[n,i,x,h,o]),A=S.useMemo(()=>{if(n===o.pathname+o.search+o.hash)return[];let H=new Set,U=!1;if(i.forEach($=>{var Y;let M=h.routes[$.route.id];!M||!M.hasLoader||(!b.some(R=>R.route.id===$.route.id)&&$.route.id in y&&((Y=v[$.route.id])!=null&&Y.shouldRevalidate)||M.hasClientLoader?U=!0:H.add($.route.id))}),H.size===0)return[];let V=yb(n,p,d.unstable_trailingSlashAwareDataRequests,"data");return U&&H.size>0&&V.searchParams.set("_routes",i.filter($=>H.has($.route.id)).map($=>$.route.id).join(",")),[V.pathname+V.search]},[p,d.unstable_trailingSlashAwareDataRequests,y,o,h,b,i,n,v]),O=S.useMemo(()=>jb(g,h),[g,h]),k=Ab(g);return S.createElement(S.Fragment,null,A.map(H=>S.createElement("link",{key:H,rel:"prefetch",as:"fetch",href:H,...c})),O.map(H=>S.createElement("link",{key:H,rel:"modulepreload",href:H,...c})),k.map(({key:H,link:U})=>S.createElement("link",{key:H,nonce:c.nonce,...U,crossOrigin:U.crossOrigin??c.crossOrigin})))}function zb(...n){return i=>{n.forEach(c=>{typeof c=="function"?c(i):c!=null&&(c.current=i)})}}var _b=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{_b&&(window.__reactRouterVersion="7.13.0")}catch{}function wb({basename:n,children:i,unstable_useTransitions:c,window:o}){let d=S.useRef();d.current==null&&(d.current=dg({window:o,v5Compat:!0}));let h=d.current,[v,p]=S.useState({action:h.action,location:h.location}),y=S.useCallback(x=>{c===!1?p(x):S.startTransition(()=>p(x))},[c]);return S.useLayoutEffect(()=>h.listen(y),[h,y]),S.createElement(rb,{basename:n,children:i,location:v.location,navigationType:v.action,navigator:h,unstable_useTransitions:c})}var Tv=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Ov=S.forwardRef(function({onClick:i,discover:c="render",prefetch:o="none",relative:d,reloadDocument:h,replace:v,state:p,target:y,to:x,preventScrollReset:b,viewTransition:g,unstable_defaultShouldRevalidate:A,...O},k){let{basename:H,unstable_useTransitions:U}=S.useContext(Qt),V=typeof x=="string"&&Tv.test(x),$=mv(x,H);x=$.to;let M=Vg(x,{relative:d}),[Y,R,P]=Ob(o,O),q=Hb(x,{replace:v,state:p,target:y,preventScrollReset:b,relative:d,viewTransition:g,unstable_defaultShouldRevalidate:A,unstable_useTransitions:U});function Z(W){i&&i(W),W.defaultPrevented||q(W)}let G=S.createElement("a",{...O,...P,href:$.absoluteURL||M,onClick:$.isExternal||h?i:Z,ref:zb(k,R),target:y,"data-discover":!V&&c==="render"?"true":void 0});return Y&&!V?S.createElement(S.Fragment,null,G,S.createElement(Rb,{page:M})):G});Ov.displayName="Link";var Rv=S.forwardRef(function({"aria-current":i="page",caseSensitive:c=!1,className:o="",end:d=!1,style:h,to:v,viewTransition:p,children:y,...x},b){let g=gi(v,{relative:x.relative}),A=Ca(),O=S.useContext(Ju),{navigator:k,basename:H}=S.useContext(Qt),U=O!=null&&Qb(g)&&p===!0,V=k.encodeLocation?k.encodeLocation(g).pathname:g.pathname,$=A.pathname,M=O&&O.navigation&&O.navigation.location?O.navigation.location.pathname:null;c||($=$.toLowerCase(),M=M?M.toLowerCase():null,V=V.toLowerCase()),M&&H&&(M=Yl(M,H)||M);const Y=V!=="/"&&V.endsWith("/")?V.length-1:V.length;let R=$===V||!d&&$.startsWith(V)&&$.charAt(Y)==="/",P=M!=null&&(M===V||!d&&M.startsWith(V)&&M.charAt(V.length)==="/"),q={isActive:R,isPending:P,isTransitioning:U},Z=R?i:void 0,G;typeof o=="function"?G=o(q):G=[o,R?"active":null,P?"pending":null,U?"transitioning":null].filter(Boolean).join(" ");let W=typeof h=="function"?h(q):h;return S.createElement(Ov,{...x,"aria-current":Z,className:G,ref:b,style:W,to:v,viewTransition:p},typeof y=="function"?y(q):y)});Rv.displayName="NavLink";var Db=S.forwardRef(({discover:n="render",fetcherKey:i,navigate:c,reloadDocument:o,replace:d,state:h,method:v=Yu,action:p,onSubmit:y,relative:x,preventScrollReset:b,viewTransition:g,unstable_defaultShouldRevalidate:A,...O},k)=>{let{unstable_useTransitions:H}=S.useContext(Qt),U=Lb(),V=kb(p,{relative:x}),$=v.toLowerCase()==="get"?"get":"post",M=typeof p=="string"&&Tv.test(p),Y=R=>{if(y&&y(R),R.defaultPrevented)return;R.preventDefault();let P=R.nativeEvent.submitter,q=(P==null?void 0:P.getAttribute("formmethod"))||v,Z=()=>U(P||R.currentTarget,{fetcherKey:i,method:q,navigate:c,replace:d,state:h,relative:x,preventScrollReset:b,viewTransition:g,unstable_defaultShouldRevalidate:A});H&&c!==!1?S.startTransition(()=>Z()):Z()};return S.createElement("form",{ref:k,method:$,action:V,onSubmit:o?y:Y,...O,"data-discover":!M&&n==="render"?"true":void 0})});Db.displayName="Form";function Ub(n){return`${n} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Av(n){let i=S.useContext(rs);return ke(i,Ub(n)),i}function Hb(n,{target:i,replace:c,state:o,preventScrollReset:d,relative:h,viewTransition:v,unstable_defaultShouldRevalidate:p,unstable_useTransitions:y}={}){let x=bv(),b=Ca(),g=gi(n,{relative:h});return S.useCallback(A=>{if(mb(A,i)){A.preventDefault();let O=c!==void 0?c:fi(b)===fi(g),k=()=>x(n,{replace:O,state:o,preventScrollReset:d,relative:h,viewTransition:v,unstable_defaultShouldRevalidate:p});y?S.startTransition(()=>k()):k()}},[b,x,g,c,o,i,n,d,h,v,p,y])}var qb=0,Bb=()=>`__${String(++qb)}__`;function Lb(){let{router:n}=Av("useSubmit"),{basename:i}=S.useContext(Qt),c=ab(),o=n.fetch,d=n.navigate;return S.useCallback(async(h,v={})=>{let{action:p,method:y,encType:x,formData:b,body:g}=xb(h,i);if(v.navigate===!1){let A=v.fetcherKey||Bb();await o(A,c,v.action||p,{unstable_defaultShouldRevalidate:v.unstable_defaultShouldRevalidate,preventScrollReset:v.preventScrollReset,formData:b,body:g,formMethod:v.method||y,formEncType:v.encType||x,flushSync:v.flushSync})}else await d(v.action||p,{unstable_defaultShouldRevalidate:v.unstable_defaultShouldRevalidate,preventScrollReset:v.preventScrollReset,formData:b,body:g,formMethod:v.method||y,formEncType:v.encType||x,replace:v.replace,state:v.state,fromRouteId:c,flushSync:v.flushSync,viewTransition:v.viewTransition})},[o,d,i,c])}function kb(n,{relative:i}={}){let{basename:c}=S.useContext(Qt),o=S.useContext(vl);ke(o,"useFormAction must be used inside a RouteContext");let[d]=o.matches.slice(-1),h={...gi(n||".",{relative:i})},v=Ca();if(n==null){h.search=v.search;let p=new URLSearchParams(h.search),y=p.getAll("index");if(y.some(b=>b==="")){p.delete("index"),y.filter(g=>g).forEach(g=>p.append("index",g));let b=p.toString();h.search=b?`?${b}`:""}}return(!n||n===".")&&d.route.index&&(h.search=h.search?h.search.replace(/^\?/,"?index&"):"?index"),c!=="/"&&(h.pathname=h.pathname==="/"?c:kl([c,h.pathname])),fi(h)}function Qb(n,{relative:i}={}){let c=S.useContext(vv);ke(c!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:o}=Av("useViewTransitionState"),d=gi(n,{relative:i});if(!c.isTransitioning)return!1;let h=Yl(c.currentLocation.pathname,o)||c.currentLocation.pathname,v=Yl(c.nextLocation.pathname,o)||c.nextLocation.pathname;return Vu(d.pathname,v)!=null||Vu(d.pathname,h)!=null}/**
61
+ * @license lucide-react v0.474.0 - ISC
62
+ *
63
+ * This source code is licensed under the ISC license.
64
+ * See the LICENSE file in the root directory of this source tree.
65
+ */const Yb=n=>n.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Mv=(...n)=>n.filter((i,c,o)=>!!i&&i.trim()!==""&&o.indexOf(i)===c).join(" ").trim();/**
66
+ * @license lucide-react v0.474.0 - ISC
67
+ *
68
+ * This source code is licensed under the ISC license.
69
+ * See the LICENSE file in the root directory of this source tree.
70
+ */var Gb={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"};/**
71
+ * @license lucide-react v0.474.0 - ISC
72
+ *
73
+ * This source code is licensed under the ISC license.
74
+ * See the LICENSE file in the root directory of this source tree.
75
+ */const Xb=S.forwardRef(({color:n="currentColor",size:i=24,strokeWidth:c=2,absoluteStrokeWidth:o,className:d="",children:h,iconNode:v,...p},y)=>S.createElement("svg",{ref:y,...Gb,width:i,height:i,stroke:n,strokeWidth:o?Number(c)*24/Number(i):c,className:Mv("lucide",d),...p},[...v.map(([x,b])=>S.createElement(x,b)),...Array.isArray(h)?h:[h]]));/**
76
+ * @license lucide-react v0.474.0 - ISC
77
+ *
78
+ * This source code is licensed under the ISC license.
79
+ * See the LICENSE file in the root directory of this source tree.
80
+ */const Xe=(n,i)=>{const c=S.forwardRef(({className:o,...d},h)=>S.createElement(Xb,{ref:h,iconNode:i,className:Mv(`lucide-${Yb(n)}`,o),...d}));return c.displayName=`${n}`,c};/**
81
+ * @license lucide-react v0.474.0 - ISC
82
+ *
83
+ * This source code is licensed under the ISC license.
84
+ * See the LICENSE file in the root directory of this source tree.
85
+ */const Kb=[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]],zv=Xe("Activity",Kb);/**
86
+ * @license lucide-react v0.474.0 - ISC
87
+ *
88
+ * This source code is licensed under the ISC license.
89
+ * See the LICENSE file in the root directory of this source tree.
90
+ */const Vb=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]],Xo=Xe("ArrowRight",Vb);/**
91
+ * @license lucide-react v0.474.0 - ISC
92
+ *
93
+ * This source code is licensed under the ISC license.
94
+ * See the LICENSE file in the root directory of this source tree.
95
+ */const Zb=[["path",{d:"M12 5a3 3 0 1 0-5.997.125 4 4 0 0 0-2.526 5.77 4 4 0 0 0 .556 6.588A4 4 0 1 0 12 18Z",key:"l5xja"}],["path",{d:"M12 5a3 3 0 1 1 5.997.125 4 4 0 0 1 2.526 5.77 4 4 0 0 1-.556 6.588A4 4 0 1 1 12 18Z",key:"ep3f8r"}],["path",{d:"M15 13a4.5 4.5 0 0 1-3-4 4.5 4.5 0 0 1-3 4",key:"1p4c4q"}],["path",{d:"M17.599 6.5a3 3 0 0 0 .399-1.375",key:"tmeiqw"}],["path",{d:"M6.003 5.125A3 3 0 0 0 6.401 6.5",key:"105sqy"}],["path",{d:"M3.477 10.896a4 4 0 0 1 .585-.396",key:"ql3yin"}],["path",{d:"M19.938 10.5a4 4 0 0 1 .585.396",key:"1qfode"}],["path",{d:"M6 18a4 4 0 0 1-1.967-.516",key:"2e4loj"}],["path",{d:"M19.967 17.484A4 4 0 0 1 18 18",key:"159ez6"}]],_v=Xe("Brain",Zb);/**
96
+ * @license lucide-react v0.474.0 - ISC
97
+ *
98
+ * This source code is licensed under the ISC license.
99
+ * See the LICENSE file in the root directory of this source tree.
100
+ */const Jb=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],$b=Xe("Check",Jb);/**
101
+ * @license lucide-react v0.474.0 - ISC
102
+ *
103
+ * This source code is licensed under the ISC license.
104
+ * See the LICENSE file in the root directory of this source tree.
105
+ */const Fb=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],Wb=Xe("ChevronDown",Fb);/**
106
+ * @license lucide-react v0.474.0 - ISC
107
+ *
108
+ * This source code is licensed under the ISC license.
109
+ * See the LICENSE file in the root directory of this source tree.
110
+ */const Ib=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],ns=Xe("ChevronRight",Ib);/**
111
+ * @license lucide-react v0.474.0 - ISC
112
+ *
113
+ * This source code is licensed under the ISC license.
114
+ * See the LICENSE file in the root directory of this source tree.
115
+ */const Pb=[["path",{d:"m7 20 5-5 5 5",key:"13a0gw"}],["path",{d:"m7 4 5 5 5-5",key:"1kwcof"}]],wv=Xe("ChevronsDownUp",Pb);/**
116
+ * @license lucide-react v0.474.0 - ISC
117
+ *
118
+ * This source code is licensed under the ISC license.
119
+ * See the LICENSE file in the root directory of this source tree.
120
+ */const e1=[["path",{d:"m7 15 5 5 5-5",key:"1hf1tw"}],["path",{d:"m7 9 5-5 5 5",key:"sgt6xg"}]],Dv=Xe("ChevronsUpDown",e1);/**
121
+ * @license lucide-react v0.474.0 - ISC
122
+ *
123
+ * This source code is licensed under the ISC license.
124
+ * See the LICENSE file in the root directory of this source tree.
125
+ */const t1=[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]],l1=Xe("Copy",t1);/**
126
+ * @license lucide-react v0.474.0 - ISC
127
+ *
128
+ * This source code is licensed under the ISC license.
129
+ * See the LICENSE file in the root directory of this source tree.
130
+ */const a1=[["line",{x1:"12",x2:"12",y1:"2",y2:"22",key:"7eqyqh"}],["path",{d:"M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6",key:"1b0p4s"}]],Uv=Xe("DollarSign",a1);/**
131
+ * @license lucide-react v0.474.0 - ISC
132
+ *
133
+ * This source code is licensed under the ISC license.
134
+ * See the LICENSE file in the root directory of this source tree.
135
+ */const n1=[["path",{d:"M14 2v6a2 2 0 0 0 .245.96l5.51 10.08A2 2 0 0 1 18 22H6a2 2 0 0 1-1.755-2.96l5.51-10.08A2 2 0 0 0 10 8V2",key:"18mbvz"}],["path",{d:"M6.453 15h11.094",key:"3shlmq"}],["path",{d:"M8.5 2h7",key:"csnxdl"}]],Kn=Xe("FlaskConical",n1);/**
136
+ * @license lucide-react v0.474.0 - ISC
137
+ *
138
+ * This source code is licensed under the ISC license.
139
+ * See the LICENSE file in the root directory of this source tree.
140
+ */const s1=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],i1=Xe("LoaderCircle",s1);/**
141
+ * @license lucide-react v0.474.0 - ISC
142
+ *
143
+ * This source code is licensed under the ISC license.
144
+ * See the LICENSE file in the root directory of this source tree.
145
+ */const u1=[["path",{d:"M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z",key:"1lielz"}]],Hv=Xe("MessageSquare",u1);/**
146
+ * @license lucide-react v0.474.0 - ISC
147
+ *
148
+ * This source code is licensed under the ISC license.
149
+ * See the LICENSE file in the root directory of this source tree.
150
+ */const r1=[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]],c1=Xe("Pencil",r1);/**
151
+ * @license lucide-react v0.474.0 - ISC
152
+ *
153
+ * This source code is licensed under the ISC license.
154
+ * See the LICENSE file in the root directory of this source tree.
155
+ */const o1=[["polygon",{points:"6 3 20 12 6 21 6 3",key:"1oa8hb"}]],uf=Xe("Play",o1);/**
156
+ * @license lucide-react v0.474.0 - ISC
157
+ *
158
+ * This source code is licensed under the ISC license.
159
+ * See the LICENSE file in the root directory of this source tree.
160
+ */const f1=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],d1=Xe("Plus",f1);/**
161
+ * @license lucide-react v0.474.0 - ISC
162
+ *
163
+ * This source code is licensed under the ISC license.
164
+ * See the LICENSE file in the root directory of this source tree.
165
+ */const h1=[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]],m1=Xe("Search",h1);/**
166
+ * @license lucide-react v0.474.0 - ISC
167
+ *
168
+ * This source code is licensed under the ISC license.
169
+ * See the LICENSE file in the root directory of this source tree.
170
+ */const p1=[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]],v1=Xe("Send",p1);/**
171
+ * @license lucide-react v0.474.0 - ISC
172
+ *
173
+ * This source code is licensed under the ISC license.
174
+ * See the LICENSE file in the root directory of this source tree.
175
+ */const x1=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],y1=Xe("ShieldCheck",x1);/**
176
+ * @license lucide-react v0.474.0 - ISC
177
+ *
178
+ * This source code is licensed under the ISC license.
179
+ * See the LICENSE file in the root directory of this source tree.
180
+ */const g1=[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]],qv=Xe("Trash2",g1);/**
181
+ * @license lucide-react v0.474.0 - ISC
182
+ *
183
+ * This source code is licensed under the ISC license.
184
+ * See the LICENSE file in the root directory of this source tree.
185
+ */const b1=[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]],Bv=Xe("Users",b1);/**
186
+ * @license lucide-react v0.474.0 - ISC
187
+ *
188
+ * This source code is licensed under the ISC license.
189
+ * See the LICENSE file in the root directory of this source tree.
190
+ */const S1=[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.77-3.77a6 6 0 0 1-7.94 7.94l-6.91 6.91a2.12 2.12 0 0 1-3-3l6.91-6.91a6 6 0 0 1 7.94-7.94l-3.76 3.76z",key:"cbrjhi"}]],Lv=Xe("Wrench",S1);function pe(...n){return n.filter(Boolean).join(" ")}function ft(n){return n===0?"$0.00":n<.01?`$${n.toFixed(4)}`:`$${n.toFixed(2)}`}function Ie(n){return n<1e3?`${Math.round(n)}ms`:n<6e4?`${(n/1e3).toFixed(1)}s`:`${(n/6e4).toFixed(1)}m`}function ci(n){return n.toLocaleString()}function kv(n,i=80){const c=o=>o.length<=i?o:o.slice(0,i-3)+"…";if(typeof n=="string")return c(n);if(typeof n=="object"&&n!==null&&!Array.isArray(n)){const o=n;for(const d of["question","prompt","text","input","query","message","content","name","title"])if(typeof o[d]=="string"&&o[d].length>0)return c(o[d]);for(const d of Object.values(o))if(typeof d=="string"&&d.length>0)return c(d)}return c(JSON.stringify(n))}function j1(n){switch(n){case"running":return"text-blue-500";case"completed":return"text-green-500";case"failed":return"text-red-500";case"waiting":return"text-amber-500";default:return"text-gray-500"}}const N1=[{to:"/playground",label:"Playground",icon:Hv},{to:"/workflows",label:"Workflows",icon:uf},{to:"/traces",label:"Traces",icon:zv},{to:"/costs",label:"Costs",icon:Uv},{to:"/memory",label:"Memory",icon:_v},{to:"/sessions",label:"Sessions",icon:Bv},{to:"/tools",label:"Tools",icon:Lv},{to:"/evals",label:"Evals",icon:Kn}];function E1(){return r.jsxs("aside",{className:"w-56 border-r border-[hsl(var(--border))] bg-[hsl(var(--card))] flex flex-col h-screen",children:[r.jsx("div",{className:"p-4 border-b border-[hsl(var(--border))]",children:r.jsx("h1",{className:"text-lg font-semibold tracking-tight",children:"Axl Studio"})}),r.jsx("nav",{className:"flex-1 p-2 space-y-0.5",children:N1.map(({to:n,label:i,icon:c})=>r.jsxs(Rv,{to:n,className:({isActive:o})=>pe("flex items-center gap-2.5 px-3 py-2 rounded-md text-sm transition-colors",o?"bg-[hsl(var(--accent))] text-[hsl(var(--accent-foreground))] font-medium":"text-[hsl(var(--muted-foreground))] hover:bg-[hsl(var(--accent))] hover:text-[hsl(var(--accent-foreground))]"),children:[r.jsx(c,{size:16}),i]},n))}),r.jsx("div",{className:"p-4 border-t border-[hsl(var(--border))] text-xs text-[hsl(var(--muted-foreground))]",children:"@axlsdk/studio"})]})}function ss({title:n,description:i,actions:c,children:o}){return r.jsxs("div",{className:"flex flex-col h-screen",children:[r.jsxs("header",{className:"flex items-center justify-between px-6 py-4 border-b border-[hsl(var(--border))]",children:[r.jsxs("div",{children:[r.jsx("h2",{className:"text-xl font-semibold",children:n}),i&&r.jsx("p",{className:"text-sm text-[hsl(var(--muted-foreground))] mt-0.5",children:i})]}),c&&r.jsx("div",{className:"flex items-center gap-2",children:c})]}),r.jsx("main",{className:"flex-1 overflow-auto p-6",children:o})]})}function kt({title:n,description:i,icon:c}){return r.jsxs("div",{className:"flex flex-col items-center justify-center py-16 text-center",children:[c&&r.jsx("div",{className:"mb-3 text-[hsl(var(--muted-foreground))]",children:c}),r.jsx("h3",{className:"text-sm font-medium text-[hsl(var(--foreground))]",children:n}),i&&r.jsx("p",{className:"text-sm text-[hsl(var(--muted-foreground))] mt-1 max-w-sm",children:i})]})}function C1({text:n,className:i}){return r.jsxs("div",{className:`whitespace-pre-wrap ${i??""}`,children:[n,r.jsx("span",{className:"animate-pulse",children:"|"})]})}function Qv(n){if(n==null)return"null";if(Array.isArray(n))return"array";const i=typeof n;return i==="object"?"object":i==="number"?"number":i==="boolean"?"boolean":"string"}function T1(n,i){if(i==="array"){const c=n;return c.length===0?"[]":`[${c.length}]`}if(i==="object"){const c=Object.keys(n);return c.length===0?"{}":c.length<=4?`{ ${c.join(", ")} }`:`{ ${c.slice(0,3).join(", ")}, …${c.length-3} more }`}return""}function O1(n,i){return i==="array"?n.map((c,o)=>[o,c]):i==="object"?Object.entries(n):[]}const Lt={key:"text-[hsl(var(--foreground))]",string:"text-emerald-700 dark:text-emerald-400",number:"text-blue-600 dark:text-blue-400",boolean:"text-amber-600 dark:text-amber-400",null:"text-[hsl(var(--muted-foreground))] italic",punct:"text-[hsl(var(--muted-foreground))]"},ui="w-3.5 shrink-0 flex items-center justify-center pt-0.5",Yv="inline-flex items-center gap-1 px-2 py-1 text-[10px] font-medium rounded-md border border-[hsl(var(--border))] text-[hsl(var(--muted-foreground))] hover:text-[hsl(var(--foreground))] hover:bg-[hsl(var(--accent))] transition-colors cursor-pointer";function R1({text:n}){const[i,c]=S.useState(!1),o=S.useRef(void 0);S.useEffect(()=>()=>{o.current&&clearTimeout(o.current)},[]);const d=S.useCallback(h=>{h.stopPropagation(),navigator.clipboard.writeText(n),c(!0),o.current&&clearTimeout(o.current),o.current=setTimeout(()=>c(!1),2e3)},[n]);return r.jsxs("button",{onClick:d,className:Yv,children:[i?r.jsx($b,{size:10,className:"text-emerald-500"}):r.jsx(l1,{size:10}),i?"Copied":"Copy"]})}function A1({value:n,type:i}){if(i==="null")return r.jsx("span",{className:Lt.null,children:"null"});if(i==="boolean")return r.jsx("span",{className:Lt.boolean,children:String(n)});if(i==="number")return r.jsx("span",{className:Lt.number,children:String(n)});if(i==="string"){const c=n;return c.includes(`
191
+ `)&&c.length>80?r.jsxs("span",{className:Lt.string,children:['"',c,'"']}):r.jsxs("span",{className:Lt.string,children:['"',c,'"']})}return null}const ku=100,M1=S.memo(function n({value:i,label:c,depth:o,expandDepth:d,isLast:h}){const v=Qv(i),p=v==="object"||v==="array",[y,x]=S.useState(o<d),[b,g]=S.useState(!1),A=h?"":",",O=c!=null?typeof c=="number"?r.jsxs("span",{className:Lt.punct,children:[c,": "]}):r.jsxs(r.Fragment,{children:[r.jsxs("span",{className:Lt.key,children:['"',c,'"']}),r.jsx("span",{className:Lt.punct,children:": "})]}):null;if(!p)return r.jsxs("div",{className:"flex items-start leading-relaxed hover:bg-[hsl(var(--accent))]/40 rounded",children:[r.jsx("span",{className:ui}),r.jsxs("span",{children:[O,r.jsx(A1,{value:i,type:v}),r.jsx("span",{className:Lt.punct,children:A})]})]});const k=O1(i,v),H=v==="array"?"[":"{",U=v==="array"?"]":"}";return k.length===0?r.jsxs("div",{className:"flex items-start leading-relaxed",children:[r.jsx("span",{className:ui}),r.jsxs("span",{children:[O,r.jsxs("span",{className:Lt.punct,children:[H,U,A]})]})]}):r.jsxs("div",{children:[r.jsxs("div",{className:pe("flex items-start leading-relaxed hover:bg-[hsl(var(--accent))]/40 rounded cursor-pointer",y&&"hidden"),onClick:()=>x(!0),children:[r.jsx("span",{className:ui,children:r.jsx(ns,{size:10,className:"text-[hsl(var(--muted-foreground))]"})}),r.jsxs("span",{children:[O,r.jsxs("span",{className:Lt.punct,children:[T1(i,v),A]})]})]}),r.jsxs("div",{className:pe(!y&&"hidden"),children:[r.jsxs("div",{className:"flex items-start leading-relaxed hover:bg-[hsl(var(--accent))]/40 rounded cursor-pointer",onClick:()=>x(!1),children:[r.jsx("span",{className:ui,children:r.jsx(ns,{size:10,className:"text-[hsl(var(--muted-foreground))] rotate-90 transition-transform"})}),r.jsxs("span",{children:[O,r.jsx("span",{className:Lt.punct,children:H})]})]}),r.jsxs("div",{className:"pl-5 border-l border-[hsl(var(--border))]/40 ml-1.5",children:[(b?k:k.slice(0,ku)).map(([V,$],M,Y)=>r.jsx(n,{value:$,label:V,depth:o+1,expandDepth:d,isLast:!b&&k.length>ku?!1:M===Y.length-1},typeof V=="number"?V:String(V))),!b&&k.length>ku&&r.jsxs("button",{onClick:V=>{V.stopPropagation(),g(!0)},className:"text-[10px] text-[hsl(var(--muted-foreground))] hover:text-[hsl(var(--foreground))] py-1 transition-colors",children:["Show all ",k.length," items (",k.length-ku," more)"]})]}),r.jsxs("div",{className:"flex items-start leading-relaxed",children:[r.jsx("span",{className:ui}),r.jsxs("span",{className:Lt.punct,children:[U,A]})]})]})]})});function st({data:n,defaultExpandDepth:i,maxHeight:c,className:o,collapsed:d}){const h=i??(d?0:2),v=c??"24rem",p=JSON.stringify(n,null,2),[y,x]=S.useState(0),[b,g]=S.useState(h),A=b===1/0,O=S.useCallback(()=>{g(U=>U===1/0?0:1/0),x(U=>U+1)},[]),k=Qv(n),H=k==="object"||k==="array";return r.jsxs("div",{className:pe("relative group/json",o),children:[r.jsxs("div",{className:"absolute top-2 right-2 flex items-center gap-1 opacity-0 group-hover/json:opacity-100 transition-opacity z-10",children:[H&&r.jsxs("button",{onClick:U=>{U.stopPropagation(),O()},className:Yv,children:[A?r.jsx(wv,{size:10}):r.jsx(Dv,{size:10}),A?"Collapse":"Expand"]}),r.jsx(R1,{text:p})]}),r.jsx("div",{className:"text-xs font-mono overflow-auto rounded-lg bg-[hsl(var(--secondary))] p-3",style:{maxHeight:v},children:r.jsx(M1,{value:n,depth:0,expandDepth:b,isLast:!0},y)})]})}const z1=(window.__AXL_STUDIO_BASE__??"")+"/api";async function Ke(n,i){const o=await(await fetch(`${z1}${n}`,{headers:{"Content-Type":"application/json",...i==null?void 0:i.headers},...i})).json();if(!o.ok)throw new Error(o.error.message);return o.data}const _1=()=>Ke("/workflows"),w1=n=>Ke(`/workflows/${encodeURIComponent(n)}`),D1=(n,i,c=!1)=>Ke(`/workflows/${encodeURIComponent(n)}/execute`,{method:"POST",body:JSON.stringify({input:i,stream:c})}),U1=()=>Ke("/executions"),H1=()=>Ke("/sessions"),q1=n=>Ke(`/sessions/${encodeURIComponent(n)}`),B1=n=>Ke(`/sessions/${encodeURIComponent(n)}`,{method:"DELETE"}),L1=()=>Ke("/agents"),k1=()=>Ke("/tools"),Q1=n=>Ke(`/tools/${encodeURIComponent(n)}`),Y1=(n,i)=>Ke(`/tools/${encodeURIComponent(n)}/test`,{method:"POST",body:JSON.stringify({input:i})}),G1=n=>Ke(`/memory/${encodeURIComponent(n)}`),X1=(n,i,c)=>Ke(`/memory/${encodeURIComponent(n)}/${encodeURIComponent(i)}`,{method:"PUT",body:JSON.stringify({value:c})}),K1=(n,i)=>Ke(`/memory/${encodeURIComponent(n)}/${encodeURIComponent(i)}`,{method:"DELETE"}),V1=(n,i,c)=>Ke("/memory/search",{method:"POST",body:JSON.stringify({query:n,scope:i,limit:c})}),Z1=()=>Ke("/costs"),J1=()=>Ke("/costs/reset",{method:"POST"}),$1=()=>Ke("/evals"),F1=()=>Ke("/evals/history"),W1=n=>Ke(`/evals/${encodeURIComponent(n)}/run`,{method:"POST"}),I1=(n,i)=>Ke("/evals/compare",{method:"POST",body:JSON.stringify({baseline:n,candidate:i})}),P1=(n,i,c)=>Ke("/playground/chat",{method:"POST",body:JSON.stringify({message:n,sessionId:i,agent:c})});class e2{constructor(){ai(this,"ws",null);ai(this,"listeners",new Map);ai(this,"reconnectTimer",null);ai(this,"url");const i=window.location.protocol==="https:"?"wss:":"ws:",c=window.__AXL_STUDIO_BASE__??"";this.url=`${i}//${window.location.host}${c}/ws`}connect(){var i;((i=this.ws)==null?void 0:i.readyState)!==WebSocket.OPEN&&(this.ws=new WebSocket(this.url),this.ws.onopen=()=>{for(const c of this.listeners.keys())this.send({type:"subscribe",channel:c})},this.ws.onmessage=c=>{try{const o=JSON.parse(c.data);if(o.type==="event"&&o.channel){const d=this.listeners.get(o.channel);if(d)for(const v of d)v(o.data);const h=o.channel.indexOf(":");if(h>0){const v=o.channel.substring(0,h)+":*",p=this.listeners.get(v);if(p)for(const y of p)y(o.data)}}}catch{}},this.ws.onclose=()=>{this.scheduleReconnect()},this.ws.onerror=()=>{var c;(c=this.ws)==null||c.close()})}scheduleReconnect(){this.reconnectTimer||(this.reconnectTimer=setTimeout(()=>{this.reconnectTimer=null,this.connect()},2e3))}send(i){var c;((c=this.ws)==null?void 0:c.readyState)===WebSocket.OPEN&&this.ws.send(JSON.stringify(i))}subscribe(i,c){let o=this.listeners.get(i);return o||(o=new Set,this.listeners.set(i,o),this.send({type:"subscribe",channel:i})),o.add(c),this.connect(),()=>{o.delete(c),o.size===0&&(this.listeners.delete(i),this.send({type:"unsubscribe",channel:i}))}}disconnect(){var i;this.reconnectTimer&&(clearTimeout(this.reconnectTimer),this.reconnectTimer=null),(i=this.ws)==null||i.close(),this.ws=null}}const t2=new e2;function rf(n,i){const c=S.useRef(i);c.current=i,S.useEffect(()=>{if(n)return t2.subscribe(n,o=>c.current(o))},[n])}const Lp={tokens:"",events:[],done:!1,error:null,result:null};function Gv(n){const[i,c]=S.useState(Lp),o=S.useRef(null);S.useEffect(()=>{n!==o.current&&(o.current=n,n&&c(Lp))},[n]);const d=S.useCallback(h=>{const v=h;c(p=>{switch(v.type){case"token":return{...p,tokens:p.tokens+v.data,events:[...p.events,v]};case"done":return{...p,done:!0,result:v.data,events:[...p.events,v]};case"error":return{...p,done:!0,error:v.message,events:[...p.events,v]};default:return{...p,events:[...p.events,v]}}})},[]);return rf(n?`execution:${n}`:null,d),i}function l2(){const[n,i]=S.useState([]),[c,o]=S.useState(""),[d,h]=S.useState(null),[v,p]=S.useState(null),[y,x]=S.useState(""),[b,g]=S.useState(!1),[A,O]=S.useState(0),[k,H]=S.useState({input:0,output:0}),U=S.useRef(null),V=S.useRef(0),{data:$=[]}=tl({queryKey:["agents"],queryFn:L1}),M=Gv(v);S.useEffect(()=>{M.tokens&&b&&i(q=>{const Z=q[q.length-1];return(Z==null?void 0:Z.role)==="assistant"?[...q.slice(0,-1),{...Z,content:M.tokens}]:[...q,{role:"assistant",content:M.tokens}]}),M.done&&(g(!1),p(null),M.error&&i(q=>{const Z=q[q.length-1];return(Z==null?void 0:Z.role)==="assistant"&&!Z.content?[...q.slice(0,-1),{role:"assistant",content:`Error: ${M.error}`}]:[...q,{role:"assistant",content:`Error: ${M.error}`}]}))},[M.tokens,M.done,M.error,b]),S.useEffect(()=>{const q=[],Z=[],G=[];for(const W of M.events){if(W.type==="tool_call"&&q.push({name:W.name,args:W.args,callId:W.callId}),W.type==="tool_result"){const ue=W.callId?q.find(He=>He.callId===W.callId):q.find(He=>He.name===W.name&&!He.result);ue&&(ue.result=W.result)}W.type==="handoff"&&Z.push({source:W.source,target:W.target,mode:W.mode??"oneway"}),W.type==="tool_approval"&&G.push({tool:W.name,approved:W.approved})}(q.length>0||Z.length>0||G.length>0)&&i(W=>{const ue=W[W.length-1];return(ue==null?void 0:ue.role)==="assistant"?[...W.slice(0,-1),{...ue,toolCalls:q.length>0?q:ue.toolCalls,handoffs:Z.length>0?Z:ue.handoffs,approvals:G.length>0?G:ue.approvals}]:W})},[M.events]),S.useEffect(()=>{const q=M.events.slice(V.current);if(q.length===0)return;V.current=M.events.length;let Z=0,G=0,W=0;for(const ue of q)ue.type==="agent_end"&&ue.cost&&(Z+=ue.cost),ue.type==="step"&&ue.data.tokens&&(G+=ue.data.tokens.input??0,W+=ue.data.tokens.output??0);Z>0&&O(ue=>ue+Z),(G>0||W>0)&&H(ue=>({input:ue.input+G,output:ue.output+W}))},[M.events]),S.useEffect(()=>{var q;(q=U.current)==null||q.scrollIntoView({behavior:"smooth"})},[n]);const Y=S.useCallback(async()=>{if(!c.trim()||b)return;const q=c.trim();o(""),i(Z=>[...Z,{role:"user",content:q}]),g(!0);try{const Z=await P1(q,d??void 0,y||void 0);h(Z.sessionId),p(Z.executionId)}catch(Z){g(!1),i(G=>[...G,{role:"assistant",content:`Error: ${Z instanceof Error?Z.message:String(Z)}`}])}},[c,b,d,y]),R=q=>{q.key==="Enter"&&!q.shiftKey&&(q.preventDefault(),Y())},P=A>0||k.input>0;return r.jsx(ss,{title:"Agent Playground",description:"Chat with registered agents in real-time",actions:r.jsxs("div",{className:"flex items-center gap-2",children:[P&&r.jsxs("div",{className:"flex items-center gap-1.5",children:[A>0&&r.jsx("span",{className:"px-1.5 py-0.5 rounded text-xs font-mono bg-[hsl(var(--secondary))] text-[hsl(var(--secondary-foreground))]",children:ft(A)}),k.input>0&&r.jsxs("span",{className:"px-1.5 py-0.5 rounded text-xs font-mono bg-[hsl(var(--secondary))] text-[hsl(var(--secondary-foreground))]",children:[ci(k.input+k.output)," tok"]})]}),$.length>0&&r.jsxs("select",{value:y,onChange:q=>x(q.target.value),className:"px-2 py-1.5 text-sm rounded-md border border-[hsl(var(--input))] bg-[hsl(var(--background))]",children:[r.jsx("option",{value:"",children:"Default agent"}),$.map(q=>r.jsx("option",{value:q.name,children:q.name},q.name))]}),r.jsx("button",{onClick:()=>{i([]),h(null),p(null),O(0),H({input:0,output:0})},className:"px-3 py-1.5 text-sm rounded-md border border-[hsl(var(--input))] hover:bg-[hsl(var(--accent))]",children:"New Chat"})]}),children:r.jsxs("div",{className:"flex flex-col h-full max-w-3xl mx-auto",children:[r.jsxs("div",{className:"flex-1 overflow-auto space-y-4 pb-4",children:[n.length===0&&r.jsx(kt,{title:"Start a conversation",description:"Type a message below to chat with an agent. Tool calls, handoffs, and streaming responses will be displayed in real-time."}),n.map((q,Z)=>r.jsx("div",{className:`flex ${q.role==="user"?"justify-end":"justify-start"}`,children:r.jsxs("div",{className:`max-w-[80%] rounded-xl px-4 py-2.5 text-sm ${q.role==="user"?"bg-[hsl(var(--primary))] text-[hsl(var(--primary-foreground))]":"bg-[hsl(var(--secondary))] text-[hsl(var(--secondary-foreground))]"}`,children:[q.role==="assistant"&&b&&Z===n.length-1?r.jsx(C1,{text:q.content}):r.jsx("div",{className:"whitespace-pre-wrap",children:q.content}),q.handoffs&&q.handoffs.length>0&&r.jsx("div",{className:"mt-2 space-y-1 border-t border-[hsl(var(--border))] pt-2",children:q.handoffs.map((G,W)=>r.jsxs("div",{className:"flex items-center gap-1.5 text-xs",children:[r.jsx(Xo,{size:12,className:"text-amber-500"}),r.jsx("span",{className:"font-medium",children:G.source}),r.jsx(Xo,{size:10}),r.jsx("span",{className:"font-medium",children:G.target}),r.jsxs("span",{className:"text-[hsl(var(--muted-foreground))]",children:["(",G.mode,")"]})]},W))}),q.approvals&&q.approvals.length>0&&r.jsx("div",{className:"mt-2 space-y-1 border-t border-[hsl(var(--border))] pt-2",children:q.approvals.map((G,W)=>r.jsxs("div",{className:"flex items-center gap-1.5 text-xs",children:[r.jsx(y1,{size:12,className:G.approved?"text-green-500":"text-red-500"}),r.jsxs("span",{children:["Tool ",r.jsx("span",{className:"font-mono",children:G.tool}),":"," ",G.approved?"approved":"denied"]})]},W))}),q.toolCalls&&q.toolCalls.length>0&&r.jsx("div",{className:"mt-2 space-y-2 border-t border-[hsl(var(--border))] pt-2",children:q.toolCalls.map((G,W)=>r.jsxs("div",{className:"text-xs",children:[r.jsxs("div",{className:"font-medium mb-1",children:["Tool: ",G.name]}),r.jsxs("div",{className:"space-y-1",children:[r.jsx("div",{className:"text-[hsl(var(--muted-foreground))]",children:"Input:"}),r.jsx(st,{data:G.args,collapsed:!0}),G.result!==void 0&&r.jsxs(r.Fragment,{children:[r.jsx("div",{className:"text-[hsl(var(--muted-foreground))]",children:"Output:"}),r.jsx(st,{data:G.result,collapsed:!0})]})]})]},W))})]})},Z)),r.jsx("div",{ref:U})]}),r.jsx("div",{className:"border-t border-[hsl(var(--border))] pt-4",children:r.jsxs("div",{className:"flex items-end gap-2",children:[r.jsx("textarea",{value:c,onChange:q=>o(q.target.value),onKeyDown:R,placeholder:"Type a message...",rows:1,className:"flex-1 px-3 py-2.5 text-sm rounded-xl border border-[hsl(var(--input))] bg-[hsl(var(--background))] resize-none focus:outline-none focus:ring-2 focus:ring-[hsl(var(--ring))]"}),r.jsx("button",{onClick:Y,disabled:!c.trim()||b,className:"p-2.5 rounded-xl bg-[hsl(var(--primary))] text-[hsl(var(--primary-foreground))] hover:opacity-90 disabled:opacity-50 transition-opacity",children:r.jsx(v1,{size:16})})]})})]})})}function Xv({value:n,onChange:i,placeholder:c,className:o}){const[d,h]=S.useState(!1),[v,p]=S.useState(null),y=S.useRef(null),x=S.useCallback(g=>{const A=g.target.value;i(A);try{A.trim()&&JSON.parse(A),p(null)}catch(O){p(O instanceof Error?O.message:"Invalid JSON")}},[i]);S.useEffect(()=>{var g;d&&((g=y.current)==null||g.focus())},[d]);let b=null;try{b=n.trim()?JSON.parse(n):{}}catch{}return b===null||d?r.jsxs("div",{className:o,children:[r.jsx("textarea",{ref:y,value:n,onChange:x,onBlur:()=>{v||h(!1)},placeholder:c??"{}",className:"w-full h-40 p-3 text-xs font-mono rounded-xl bg-[hsl(var(--secondary))] text-[hsl(var(--foreground))] border-none resize-y focus:outline-none focus:ring-2 focus:ring-[hsl(var(--ring))]",spellCheck:!1}),v&&r.jsx("p",{className:"text-xs text-red-500 mt-1",children:v})]}):r.jsx("div",{className:o,children:r.jsxs("div",{children:[r.jsx(st,{data:b,maxHeight:"12rem"}),r.jsxs("button",{onClick:()=>h(!0),className:"mt-1.5 inline-flex items-center gap-1 px-2 py-1 text-[10px] font-medium rounded-md text-[hsl(var(--muted-foreground))] hover:text-[hsl(var(--foreground))] hover:bg-[hsl(var(--accent))] transition-colors cursor-pointer",children:[r.jsx(c1,{size:10}),"Edit"]})]})})}function Kv({schema:n,onSubmit:i,submitLabel:c="Submit",className:o}){const[d,h]=S.useState({}),v=n.properties??{},p=new Set(n.required??[]),y=S.useCallback(x=>{x.preventDefault();const b={};for(const[g,A]of Object.entries(v)){const O=d[g]??"";if(!(!O&&!p.has(g)))if(A.type==="number")b[g]=Number(O);else if(A.type==="boolean")b[g]=O==="true";else if(A.type==="object"||A.type==="array")try{b[g]=JSON.parse(O)}catch{b[g]=O}else b[g]=O}i(b)},[d,v,p,i]);return r.jsxs("form",{onSubmit:y,className:`space-y-3 ${o??""}`,children:[Object.entries(v).map(([x,b])=>r.jsxs("div",{children:[r.jsxs("label",{className:"block text-xs font-medium text-[hsl(var(--foreground))] mb-1",children:[x,p.has(x)&&r.jsx("span",{className:"text-red-500 ml-0.5",children:"*"}),b.description&&r.jsxs("span",{className:"text-[hsl(var(--muted-foreground))] font-normal ml-1",children:["- ",b.description]})]}),b.enum?r.jsxs("select",{value:d[x]??"",onChange:g=>h({...d,[x]:g.target.value}),className:"w-full px-2 py-1.5 text-sm rounded-md border border-[hsl(var(--input))] bg-[hsl(var(--background))]",children:[r.jsx("option",{value:"",children:"Select..."}),b.enum.map(g=>r.jsx("option",{value:g,children:g},g))]}):b.type==="boolean"?r.jsxs("select",{value:d[x]??"",onChange:g=>h({...d,[x]:g.target.value}),className:"w-full px-2 py-1.5 text-sm rounded-md border border-[hsl(var(--input))] bg-[hsl(var(--background))]",children:[r.jsx("option",{value:"",children:"Select..."}),r.jsx("option",{value:"true",children:"true"}),r.jsx("option",{value:"false",children:"false"})]}):r.jsx("input",{type:b.type==="number"?"number":"text",value:d[x]??"",onChange:g=>h({...d,[x]:g.target.value}),placeholder:b.type??"string",className:"w-full px-2 py-1.5 text-sm rounded-md border border-[hsl(var(--input))] bg-[hsl(var(--background))]"})]},x)),r.jsx("button",{type:"submit",className:"px-4 py-2 text-sm font-medium rounded-md bg-[hsl(var(--primary))] text-[hsl(var(--primary-foreground))] hover:opacity-90 transition-opacity",children:c})]})}function Vv({status:n,className:i}){return r.jsxs("span",{className:pe("inline-flex items-center gap-1.5 px-2 py-0.5 rounded-full text-xs font-medium",j1(n),n==="running"&&"animate-pulse",i),children:[r.jsx("span",{className:pe("w-1.5 h-1.5 rounded-full",n==="running"&&"bg-blue-500",n==="completed"&&"bg-green-500",n==="failed"&&"bg-red-500",n==="waiting"&&"bg-amber-500")}),n]})}function pt({label:n,value:i,subtitle:c,subtitleColor:o,accent:d,tint:h,badge:v}){return r.jsxs("div",{className:pe("px-4 py-3.5 rounded-xl",h||"bg-[hsl(var(--card))] border border-[hsl(var(--border))]"),children:[r.jsx("p",{className:"text-[11px] font-medium uppercase tracking-wider text-[hsl(var(--muted-foreground))]",children:n}),v?r.jsx("div",{className:"mt-1",children:v}):r.jsx("p",{className:pe("text-2xl font-semibold mt-1 font-mono tracking-tight",d),children:i}),c&&r.jsx("p",{className:pe("text-xs mt-0.5",o??"text-[hsl(var(--muted-foreground))]"),children:c})]})}const a2={agent_call:"bg-blue-500",tool_call:"bg-purple-500",tool_call_complete:"bg-purple-400",workflow_start:"bg-green-500",workflow_complete:"bg-green-400",handoff:"bg-amber-500",await_human:"bg-red-500",vote_start:"bg-cyan-500",spawn:"bg-indigo-500"};function Zu(n){return a2[n]??"bg-slate-500"}function Zv(n){const i=n.type;return i==="workflow_start"||i==="workflow_complete"?0:i==="agent_call"||i==="spawn"||i==="vote_start"?1:i==="tool_call"||i==="tool_call_complete"||i==="handoff"?2:1}function n2(){const[n,i]=S.useState(""),[c,o]=S.useState("{}"),[d,h]=S.useState(!0),[v,p]=S.useState(null),[y,x]=S.useState(void 0),[b,g]=S.useState(null),[A,O]=S.useState("idle"),{data:k=[]}=tl({queryKey:["workflows"],queryFn:_1}),{data:H}=tl({queryKey:["workflow",n],queryFn:()=>w1(n),enabled:!!n}),U=Gv(v),V=S.useCallback(async G=>{if(n){x(void 0),g(null),O("running");try{const W=await D1(n,G,!0);W.streaming&&W.executionId?p(W.executionId):(x(W.result),O("completed"))}catch(W){g(W instanceof Error?W.message:String(W)),O("failed")}}},[n]),$=S.useCallback(()=>{try{const G=JSON.parse(c);V(G)}catch(G){g(G instanceof Error?G.message:String(G)),O("failed")}},[c,V]),M=S.useCallback(G=>{V(G)},[V]);S.useEffect(()=>{U.done&&A==="running"&&(O(U.error?"failed":"completed"),U.error&&g(U.error),U.result!==void 0&&x(U.result),p(null))},[U.done,U.error,U.result,A]);const Y=U.events.filter(G=>G.type==="step").map(G=>G.data),R=!!(H!=null&&H.inputSchema),P=Math.max(...Y.map(G=>G.duration??0),1),q=Y.reduce((G,W)=>G+(W.duration??0),0),Z=Y.reduce((G,W)=>G+(W.cost??0),0);return r.jsxs("div",{className:"flex flex-col h-screen",children:[r.jsxs("header",{className:"shrink-0 flex items-center justify-between px-6 py-4 border-b border-[hsl(var(--border))]",children:[r.jsx("h2",{className:"text-xl font-semibold",children:"Workflows"}),k.length>0&&r.jsxs("div",{className:"flex items-center gap-2",children:[r.jsxs("select",{value:n,onChange:G=>{i(G.target.value),o("{}"),x(void 0),g(null),O("idle")},className:"px-3 py-1.5 text-sm rounded-lg border border-[hsl(var(--input))] bg-[hsl(var(--background))] min-w-[180px]",children:[r.jsx("option",{value:"",children:"Select workflow…"}),k.map(G=>r.jsx("option",{value:G.name,children:G.name},G.name))]}),r.jsxs("button",{onClick:$,disabled:!n||A==="running",className:pe("inline-flex items-center gap-1.5 px-4 py-1.5 text-sm font-medium rounded-lg transition-all","bg-[hsl(var(--foreground))] text-[hsl(var(--background))]","hover:opacity-90 disabled:opacity-40"),children:[r.jsx(uf,{size:12,className:A==="running"?"animate-spin":""}),A==="running"?"Running…":"Run"]})]})]}),r.jsxs("div",{className:"flex-1 min-h-0 flex border-t border-[hsl(var(--border))]",children:[r.jsxs("div",{className:"w-[400px] xl:w-[480px] shrink-0 border-r border-[hsl(var(--border))] overflow-y-auto p-5 space-y-4",children:[R&&r.jsxs("div",{className:"flex items-center gap-1",children:[r.jsx("button",{onClick:()=>h(!0),className:pe("px-3 py-1 text-xs rounded-lg transition-colors",d?"bg-[hsl(var(--foreground))] text-[hsl(var(--background))]":"text-[hsl(var(--muted-foreground))] hover:bg-[hsl(var(--accent))]"),children:"Form"}),r.jsx("button",{onClick:()=>h(!1),className:pe("px-3 py-1 text-xs rounded-lg transition-colors",d?"text-[hsl(var(--muted-foreground))] hover:bg-[hsl(var(--accent))]":"bg-[hsl(var(--foreground))] text-[hsl(var(--background))]"),children:"JSON"})]}),R&&d?r.jsx(Kv,{schema:H.inputSchema,onSubmit:M,submitLabel:A==="running"?"Running…":"Execute"}):r.jsxs("div",{children:[r.jsx("label",{className:"block text-[11px] font-medium uppercase tracking-wider text-[hsl(var(--muted-foreground))] mb-2",children:"Input (JSON)"}),r.jsx(Xv,{value:c,onChange:o})]}),(H==null?void 0:H.outputSchema)!=null&&r.jsxs("div",{children:[r.jsx("label",{className:"block text-[11px] font-medium uppercase tracking-wider text-[hsl(var(--muted-foreground))] mb-2",children:"Output Schema"}),r.jsx(st,{data:H.outputSchema,collapsed:!0})]})]}),r.jsx("div",{className:"flex-1 overflow-y-auto p-5",children:A==="idle"?r.jsx("div",{className:"flex items-center justify-center h-full",children:r.jsx(kt,{icon:r.jsx(Kn,{size:32}),title:"No execution",description:"Select a workflow and click Run to see results."})}):r.jsxs("div",{className:"space-y-5",children:[r.jsxs("div",{className:"grid grid-cols-2 lg:grid-cols-4 gap-3",children:[r.jsx(pt,{label:"Status",badge:r.jsx(Vv,{status:A})}),r.jsx(pt,{label:"Steps",value:String(Y.length)}),r.jsx(pt,{label:"Duration",value:q>0?Ie(q):"—"}),r.jsx(pt,{label:"Cost",value:Z>0?ft(Z):"—"})]}),b&&r.jsx("div",{className:"p-4 rounded-xl bg-red-50 dark:bg-red-950/30 border border-red-200 dark:border-red-800 text-red-700 dark:text-red-300 text-sm",children:b}),y!==void 0&&r.jsxs("div",{children:[r.jsx("h3",{className:"text-[11px] font-medium uppercase tracking-wider text-[hsl(var(--muted-foreground))] mb-2",children:"Result"}),r.jsx(st,{data:y})]}),Y.length>0&&r.jsxs("div",{children:[r.jsx("h3",{className:"text-[11px] font-medium uppercase tracking-wider text-[hsl(var(--muted-foreground))] mb-2",children:"Timeline"}),r.jsx("div",{className:"space-y-1",children:Y.map((G,W)=>{const ue=Zv(G);return r.jsxs("details",{className:"group",children:[r.jsxs("summary",{className:"flex items-center gap-2 px-3 py-1.5 text-xs rounded-xl bg-[hsl(var(--secondary))] cursor-pointer hover:bg-[hsl(var(--accent))]",style:{marginLeft:`${ue*16}px`},children:[r.jsxs("span",{className:"font-mono text-[hsl(var(--muted-foreground))] w-8",children:["#",G.step]}),r.jsx("span",{className:`w-1.5 h-1.5 rounded-full shrink-0 ${Zu(G.type)}`}),r.jsx("span",{className:"font-medium w-24 truncate",children:G.type}),G.agent&&r.jsx("span",{className:"text-blue-600 dark:text-blue-400 w-24 truncate",children:G.agent}),G.tool&&r.jsx("span",{className:"text-purple-600 dark:text-purple-400 w-24 truncate",children:G.tool}),r.jsx("div",{className:"flex-1 h-3 bg-[hsl(var(--background))] rounded overflow-hidden",children:G.duration!=null&&G.duration>0&&r.jsx("div",{className:`h-full rounded ${Zu(G.type)}`,style:{width:`${Math.max(G.duration/P*100,2)}%`,opacity:.7}})}),G.duration!=null&&r.jsx("span",{className:"text-[10px] font-mono text-[hsl(var(--muted-foreground))]",children:Ie(G.duration)})]}),r.jsxs("div",{className:"mt-1 mb-2 p-3 rounded-xl bg-[hsl(var(--card))] border border-[hsl(var(--border))]",style:{marginLeft:`${ue*16+32}px`},children:[G.model&&r.jsxs("p",{className:"text-xs mb-1",children:[r.jsx("strong",{children:"Model:"})," ",G.model]}),G.tokens&&r.jsxs("p",{className:"text-xs mb-1",children:[r.jsx("strong",{children:"Tokens:"})," in=",G.tokens.input," out=",G.tokens.output,G.tokens.reasoning?` reasoning=${G.tokens.reasoning}`:""]}),G.data!=null&&r.jsx(st,{data:G.data,collapsed:!0})]})]},W)})})]}),A==="running"&&Y.length===0&&r.jsxs("div",{className:"flex items-center justify-center py-12 text-sm text-[hsl(var(--muted-foreground))]",children:[r.jsx(Kn,{size:16,className:"animate-pulse mr-2"}),"Executing workflow…"]})]})})]})]})}function Xn({cost:n,className:i}){return r.jsx("span",{className:`inline-flex items-center px-1.5 py-0.5 rounded text-xs font-mono bg-[hsl(var(--secondary))] text-[hsl(var(--secondary-foreground))] ${i??""}`,children:ft(n)})}function s2({ms:n,className:i}){return r.jsx("span",{className:`inline-flex items-center px-1.5 py-0.5 rounded text-xs font-mono bg-[hsl(var(--secondary))] text-[hsl(var(--secondary-foreground))] ${i??""}`,children:Ie(n)})}const i2={running:"border-l-blue-500",completed:"border-l-green-500",failed:"border-l-red-500"};function u2(n){const i=new Date(n),c=new Date;return i.getFullYear()===c.getFullYear()&&i.getMonth()===c.getMonth()&&i.getDate()===c.getDate()?i.toLocaleTimeString(void 0,{hour:"2-digit",minute:"2-digit",second:"2-digit"}):i.toLocaleDateString(void 0,{month:"short",day:"numeric",hour:"2-digit",minute:"2-digit"})}function r2(){const[n,i]=S.useState(null),[c,o]=S.useState([]),[d,h]=S.useState(""),[v,p]=S.useState(""),[y,x]=S.useState(new Set),{data:b=[],refetch:g}=tl({queryKey:["executions"],queryFn:U1,refetchInterval:3e3});rf("trace:*",S.useCallback(R=>{o(P=>[...P.slice(-200),R])},[]));const A=n?n.steps:c;let O=A;d&&(O=O.filter(R=>R.type===d)),v&&(O=O.filter(R=>R.agent===v));const k=[...new Set(A.map(R=>R.type))],H=[...new Set(A.map(R=>R.agent).filter(Boolean))],U=Math.max(...O.map(R=>R.duration??0),1),V=R=>{x(P=>{const q=new Set(P);return q.has(R)?q.delete(R):q.add(R),q})},$=()=>{const R=O.map((P,q)=>P.step??q);x(new Set(R))},M=()=>{x(new Set)},Y=S.useMemo(()=>{if(!n)return null;const R=[...new Set(n.steps.map(P=>P.model).filter(Boolean))];return{duration:n.duration,eventCount:n.steps.length,cost:n.totalCost,models:R}},[n]);return r.jsxs("div",{className:"flex flex-col h-screen",children:[r.jsxs("header",{className:"shrink-0 flex items-center justify-between px-6 py-4 border-b border-[hsl(var(--border))]",children:[r.jsx("h2",{className:"text-xl font-semibold",children:"Trace Explorer"}),r.jsxs("div",{className:"flex items-center gap-2",children:[r.jsxs("select",{value:d,onChange:R=>h(R.target.value),className:"px-2 py-1.5 text-xs rounded-lg border border-[hsl(var(--input))] bg-[hsl(var(--background))]",children:[r.jsx("option",{value:"",children:"All types"}),k.map(R=>r.jsx("option",{value:R,children:R},R))]}),H.length>0&&r.jsxs("select",{value:v,onChange:R=>p(R.target.value),className:"px-2 py-1.5 text-xs rounded-lg border border-[hsl(var(--input))] bg-[hsl(var(--background))]",children:[r.jsx("option",{value:"",children:"All agents"}),H.map(R=>r.jsx("option",{value:R,children:R},R))]}),r.jsx("button",{onClick:()=>{g(),o([])},className:"px-3 py-1.5 text-sm rounded-lg border border-[hsl(var(--input))] hover:bg-[hsl(var(--accent))]",children:"Refresh"})]})]}),r.jsx("div",{className:"flex-1 min-h-0 overflow-auto p-6",children:r.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-4 gap-6",children:[r.jsxs("div",{className:"lg:col-span-1 space-y-2",children:[r.jsx("h3",{className:"text-sm font-medium mb-2",children:"Executions"}),r.jsxs("button",{onClick:()=>{i(null),x(new Set)},className:pe("w-full text-left px-3 py-2 text-xs rounded-xl border",n?"border-[hsl(var(--border))] hover:bg-[hsl(var(--accent))]":"border-[hsl(var(--primary))] bg-[hsl(var(--accent))]"),children:["Live Events (",c.length,")"]}),b.map(R=>r.jsxs("button",{onClick:()=>{i(R),x(new Set)},className:pe("w-full text-left px-3 py-2.5 text-xs rounded-xl border border-l-[3px] transition-colors",i2[R.status]??"border-l-slate-400",(n==null?void 0:n.executionId)===R.executionId?"border-[hsl(var(--primary))] bg-[hsl(var(--accent))]":"border-[hsl(var(--border))] hover:bg-[hsl(var(--accent))]"),children:[r.jsxs("div",{className:"flex items-center justify-between",children:[r.jsx("span",{className:"font-medium truncate",children:R.workflow}),r.jsx(Vv,{status:R.status})]}),r.jsxs("div",{className:"flex items-center justify-between mt-1",children:[r.jsxs("span",{className:"text-[hsl(var(--muted-foreground))] truncate",children:[R.executionId.slice(0,8),"… | ",R.steps.length," steps"]}),R.totalCost>0&&r.jsx(Xn,{cost:R.totalCost})]}),r.jsxs("div",{className:"flex items-center gap-2 mt-1 text-[10px] text-[hsl(var(--muted-foreground))]",children:[r.jsx("span",{children:u2(R.startedAt)}),R.duration>0&&r.jsxs(r.Fragment,{children:[r.jsx("span",{className:"text-[hsl(var(--border))]",children:"·"}),r.jsx("span",{children:Ie(R.duration)})]})]})]},R.executionId)),b.length===0&&r.jsx("p",{className:"text-xs text-[hsl(var(--muted-foreground))]",children:"No executions yet"})]}),r.jsxs("div",{className:"lg:col-span-3",children:[Y&&r.jsxs("div",{className:"grid grid-cols-2 lg:grid-cols-4 gap-3 mb-4",children:[r.jsx(pt,{label:"Duration",value:Ie(Y.duration)}),r.jsx(pt,{label:"Events",value:String(Y.eventCount)}),r.jsx(pt,{label:"Cost",value:Y.cost>0?ft(Y.cost):"—"}),r.jsx(pt,{label:"Model",value:Y.models.length>0?Y.models[0]:"—",subtitle:Y.models.length>1?`+${Y.models.length-1} more`:void 0})]}),(n==null?void 0:n.status)==="completed"&&n.result!=null&&r.jsxs("div",{className:"mb-4",children:[r.jsx("h3",{className:"text-[11px] font-medium uppercase tracking-wider text-[hsl(var(--muted-foreground))] mb-2",children:"Result"}),r.jsx(st,{data:n.result})]}),r.jsxs("div",{className:"flex items-center justify-between mb-3",children:[r.jsxs("span",{className:"text-xs text-[hsl(var(--muted-foreground))]",children:[O.length," events"]}),O.length>0&&r.jsxs("div",{className:"flex items-center gap-1",children:[r.jsxs("button",{onClick:$,className:"inline-flex items-center gap-1 px-2 py-1 text-xs rounded-md hover:bg-[hsl(var(--accent))] text-[hsl(var(--muted-foreground))]",title:"Expand all",children:[r.jsx(Dv,{size:12}),"Expand"]}),r.jsxs("button",{onClick:M,className:"inline-flex items-center gap-1 px-2 py-1 text-xs rounded-md hover:bg-[hsl(var(--accent))] text-[hsl(var(--muted-foreground))]",title:"Collapse all",children:[r.jsx(wv,{size:12}),"Collapse"]})]})]}),O.length===0?r.jsx(kt,{icon:r.jsx(zv,{size:32}),title:"No trace events",description:"Execute a workflow to see trace events here."}):r.jsx("div",{className:"space-y-1",children:O.map((R,P)=>{const q=Zv(R),Z=R.step??P,G=y.has(Z);return r.jsxs("div",{children:[r.jsxs("button",{onClick:()=>V(Z),className:"w-full flex items-center gap-2 px-3 py-1.5 text-xs rounded-xl bg-[hsl(var(--secondary))] cursor-pointer hover:bg-[hsl(var(--accent))] text-left",style:{marginLeft:`${q*16}px`},children:[G?r.jsx(Wb,{size:12,className:"shrink-0 text-[hsl(var(--muted-foreground))]"}):r.jsx(ns,{size:12,className:"shrink-0 text-[hsl(var(--muted-foreground))]"}),r.jsxs("span",{className:"font-mono text-[hsl(var(--muted-foreground))] w-8",children:["#",R.step!=null?R.step:P]}),r.jsx("span",{className:`w-1.5 h-1.5 rounded-full shrink-0 ${Zu(R.type)}`}),r.jsx("span",{className:"font-medium w-28 truncate",children:R.type}),R.agent&&r.jsx("span",{className:"text-blue-600 dark:text-blue-400 w-28 truncate",children:R.agent}),R.tool&&r.jsx("span",{className:"text-purple-600 dark:text-purple-400 w-28 truncate",children:R.tool}),r.jsx("div",{className:"flex-1 h-3 bg-[hsl(var(--background))] rounded overflow-hidden",children:R.duration!=null&&R.duration>0&&r.jsx("div",{className:`h-full rounded ${Zu(R.type)}`,style:{width:`${Math.max(R.duration/U*100,2)}%`,opacity:.7}})}),R.duration!=null&&r.jsx(s2,{ms:R.duration}),R.cost!=null&&R.cost>0&&r.jsx(Xn,{cost:R.cost})]}),G&&r.jsxs("div",{className:"mt-1 mb-2 p-3 rounded-xl bg-[hsl(var(--card))] border border-[hsl(var(--border))]",style:{marginLeft:`${q*16+32}px`},children:[R.model&&r.jsxs("p",{className:"text-xs mb-1",children:[r.jsx("strong",{children:"Model:"})," ",R.model]}),R.promptVersion&&r.jsxs("p",{className:"text-xs mb-1",children:[r.jsx("strong",{children:"Version:"})," ",R.promptVersion]}),R.tokens&&r.jsxs("p",{className:"text-xs mb-1",children:[r.jsx("strong",{children:"Tokens:"})," in=",R.tokens.input," out=",R.tokens.output,R.tokens.reasoning?` reasoning=${R.tokens.reasoning}`:""]}),R.data!=null&&r.jsx(st,{data:R.data,collapsed:!0})]})]},Z)})})]})]})})]})}function c2({tokens:n,label:i,className:c}){return r.jsxs("span",{className:`inline-flex items-center gap-1 px-1.5 py-0.5 rounded text-xs font-mono bg-[hsl(var(--secondary))] text-[hsl(var(--secondary-foreground))] ${c??""}`,children:[i&&r.jsx("span",{className:"text-[hsl(var(--muted-foreground))]",children:i}),ci(n)]})}function o2(){const[n,i]=S.useState(null),{data:c,refetch:o}=tl({queryKey:["costs"],queryFn:Z1});rf("costs",S.useCallback(p=>{i(p)},[]));const d=n??c,h=async()=>{await J1(),i(null),o()};if(!d)return r.jsx(ss,{title:"Cost Dashboard",description:"Track spending across agents, models, and workflows",children:r.jsx(kt,{icon:r.jsx(Uv,{size:32}),title:"No cost data",description:"Execute workflows to see cost data."})});const v=d.totalTokens.reasoning>0;return r.jsxs(ss,{title:"Cost Dashboard",description:"Track spending across agents, models, and workflows",actions:r.jsx("button",{onClick:h,className:"px-3 py-1.5 text-sm rounded-md border border-[hsl(var(--input))] hover:bg-[hsl(var(--accent))]",children:"Reset"}),children:[r.jsxs("div",{className:pe("grid grid-cols-1 sm:grid-cols-2 gap-3 mb-8",v?"lg:grid-cols-4":"lg:grid-cols-3"),children:[r.jsx(pt,{label:"Total Cost",value:ft(d.totalCost),subtitle:"all time"}),r.jsx(pt,{label:"Input Tokens",value:ci(d.totalTokens.input),subtitle:"prompt"}),r.jsx(pt,{label:"Output Tokens",value:ci(d.totalTokens.output),subtitle:"completion"}),v&&r.jsx(pt,{label:"Reasoning Tokens",value:ci(d.totalTokens.reasoning),subtitle:"thinking"})]}),r.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-6",children:[r.jsxs("div",{children:[r.jsx("h3",{className:"text-sm font-medium mb-3",children:"Cost by Agent"}),Object.keys(d.byAgent).length===0?r.jsx("p",{className:"text-xs text-[hsl(var(--muted-foreground))]",children:"No agent data"}):r.jsx(Eo,{headers:["Agent","Calls","Cost"],rows:Object.entries(d.byAgent).sort(([,p],[,y])=>y.cost-p.cost).map(([p,y])=>({key:p,cells:[r.jsx("span",{className:"font-mono",children:p}),r.jsx("span",{children:y.calls}),r.jsx(Xn,{cost:y.cost})],cost:y.cost})),maxCost:Math.max(...Object.values(d.byAgent).map(p=>p.cost))})]}),r.jsxs("div",{children:[r.jsx("h3",{className:"text-sm font-medium mb-3",children:"Cost by Model"}),Object.keys(d.byModel).length===0?r.jsx("p",{className:"text-xs text-[hsl(var(--muted-foreground))]",children:"No model data"}):r.jsx(Eo,{headers:["Model","Calls","Tokens","Cost"],rows:Object.entries(d.byModel).sort(([,p],[,y])=>y.cost-p.cost).map(([p,y])=>({key:p,cells:[r.jsx("span",{className:"font-mono",children:p}),r.jsx("span",{children:y.calls}),r.jsx(c2,{tokens:y.tokens.input+y.tokens.output}),r.jsx(Xn,{cost:y.cost})],cost:y.cost})),maxCost:Math.max(...Object.values(d.byModel).map(p=>p.cost))})]}),r.jsxs("div",{className:"lg:col-span-2",children:[r.jsx("h3",{className:"text-sm font-medium mb-3",children:"Cost by Workflow"}),Object.keys(d.byWorkflow).length===0?r.jsx("p",{className:"text-xs text-[hsl(var(--muted-foreground))]",children:"No workflow data"}):r.jsx(Eo,{headers:["Workflow","Executions","Total Cost","Avg Cost"],rows:Object.entries(d.byWorkflow).sort(([,p],[,y])=>y.cost-p.cost).map(([p,y])=>({key:p,cells:[r.jsx("span",{className:"font-mono",children:p}),r.jsx("span",{children:y.executions}),r.jsx(Xn,{cost:y.cost}),r.jsx(Xn,{cost:y.executions>0?y.cost/y.executions:0})],cost:y.cost})),maxCost:Math.max(...Object.values(d.byWorkflow).map(p=>p.cost))})]})]})]})}function Eo({headers:n,rows:i,maxCost:c}){return r.jsx("div",{className:"rounded-xl border border-[hsl(var(--border))] overflow-hidden",children:r.jsxs("table",{className:"w-full text-xs",children:[r.jsx("thead",{children:r.jsx("tr",{className:"border-b border-[hsl(var(--border))] bg-[hsl(var(--card))]",children:n.map((o,d)=>r.jsx("th",{className:pe("py-2 px-3 font-medium",d===0?"text-left":"text-right"),children:o},o))})}),r.jsx("tbody",{children:i.map(o=>r.jsx("tr",{className:"border-b last:border-b-0 border-[hsl(var(--border))]",children:o.cells.map((d,h)=>r.jsxs("td",{className:pe("py-2 px-3 relative",h===0?"text-left":"text-right"),children:[h===o.cells.length-1&&c>0&&r.jsx("div",{className:"absolute inset-y-0 right-0 bg-[hsl(var(--primary)/0.08)] rounded-sm",style:{width:`${o.cost/c*100}%`}}),r.jsx("span",{className:"relative",children:d})]},h))},o.key))})]})})}function f2(){const[n,i]=S.useState("session"),[c,o]=S.useState(""),[d,h]=S.useState("{}"),[v,p]=S.useState(!1),[y,x]=S.useState(""),[b,g]=S.useState(null),[A,O]=S.useState(null),k=xi(),{data:H=[]}=tl({queryKey:["memory",n],queryFn:()=>G1(n)}),U=Qo({mutationFn:({key:R,value:P})=>X1(n,R,P),onSuccess:()=>{k.invalidateQueries({queryKey:["memory",n]}),p(!1),o(""),h("{}")}}),V=Qo({mutationFn:R=>K1(n,R),onSuccess:()=>{k.invalidateQueries({queryKey:["memory",n]}),O(null)}}),$=S.useCallback(async()=>{if(!y.trim())return;const R=await V1(y,n);g(R.results)},[y,n]),M=S.useCallback(()=>{if(c.trim())try{const R=JSON.parse(d);U.mutate({key:c,value:R})}catch{U.mutate({key:c,value:d})}},[c,d,U]),Y=S.useCallback(R=>{A===R?V.mutate(R):O(R)},[A,V]);return r.jsxs(ss,{title:"Memory Browser",description:"View and manage agent memory entries",actions:r.jsxs("button",{onClick:()=>p(!v),className:"flex items-center gap-1.5 px-3 py-1.5 text-sm rounded-md bg-[hsl(var(--primary))] text-[hsl(var(--primary-foreground))] hover:opacity-90",children:[r.jsx(d1,{size:14}),"Add Entry"]}),children:[r.jsxs("div",{className:"flex items-center gap-0 mb-4 border-b border-[hsl(var(--border))]",children:[["session","global"].map(R=>r.jsx("button",{onClick:()=>{i(R),g(null),O(null)},className:pe("px-3 py-2.5 text-sm -mb-px border-b-2 transition-colors",n===R?"border-[hsl(var(--foreground))] text-[hsl(var(--foreground))] font-medium":"border-transparent text-[hsl(var(--muted-foreground))] hover:text-[hsl(var(--foreground))]"),children:R.charAt(0).toUpperCase()+R.slice(1)},R)),r.jsx("div",{className:"flex-1"}),r.jsxs("div",{className:"flex items-center gap-1 -mb-px pb-2",children:[r.jsx("input",{value:y,onChange:R=>x(R.target.value),onKeyDown:R=>R.key==="Enter"&&$(),placeholder:"Semantic search...",className:"px-2 py-1.5 text-sm rounded-md border border-[hsl(var(--input))] bg-[hsl(var(--background))] w-48"}),r.jsx("button",{onClick:$,className:"p-1.5 rounded-md hover:bg-[hsl(var(--accent))]",children:r.jsx(m1,{size:14})})]})]}),v&&r.jsxs("div",{className:"mb-4 p-4 rounded-xl border border-[hsl(var(--border))] bg-[hsl(var(--card))] space-y-3",children:[r.jsx("input",{value:c,onChange:R=>o(R.target.value),placeholder:"Key",className:"w-full px-2 py-1.5 text-sm rounded-md border border-[hsl(var(--input))] bg-[hsl(var(--background))]"}),r.jsx(Xv,{value:d,onChange:h,placeholder:"Value (JSON)"}),r.jsxs("div",{className:"flex items-center gap-2",children:[r.jsx("button",{onClick:M,disabled:!c.trim(),className:"px-3 py-1.5 text-sm rounded-md bg-[hsl(var(--primary))] text-[hsl(var(--primary-foreground))] hover:opacity-90 disabled:opacity-50",children:"Save"}),r.jsx("button",{onClick:()=>p(!1),className:"px-3 py-1.5 text-sm rounded-md border border-[hsl(var(--input))] hover:bg-[hsl(var(--accent))]",children:"Cancel"})]})]}),b&&r.jsxs("div",{className:"mb-4 p-4 rounded-xl border border-[hsl(var(--border))] bg-[hsl(var(--card))]",children:[r.jsx("h3",{className:"text-sm font-medium mb-2",children:"Search Results"}),b.length===0?r.jsx("p",{className:"text-xs text-[hsl(var(--muted-foreground))]",children:"No results found"}):r.jsx(st,{data:b})]}),H.length===0?r.jsx(kt,{icon:r.jsx(_v,{size:32}),title:"No memory entries",description:`No entries in the ${n} scope. Use ctx.remember() in workflows or add entries manually.`}):r.jsx("div",{className:"space-y-2",children:H.map(R=>r.jsxs("div",{className:"p-3 rounded-xl border border-[hsl(var(--border))] bg-[hsl(var(--card))]",children:[r.jsxs("div",{className:"flex items-center justify-between mb-2",children:[r.jsx("span",{className:"text-sm font-mono font-medium",children:R.key}),r.jsx("div",{className:"flex items-center gap-1",children:A===R.key?r.jsxs(r.Fragment,{children:[r.jsx("button",{onClick:()=>Y(R.key),className:"px-2 py-0.5 text-xs rounded bg-[hsl(var(--destructive))] text-[hsl(var(--destructive-foreground))]",children:"Confirm"}),r.jsx("button",{onClick:()=>O(null),className:"px-2 py-0.5 text-xs rounded border border-[hsl(var(--input))] hover:bg-[hsl(var(--accent))]",children:"Cancel"})]}):r.jsx("button",{onClick:()=>Y(R.key),className:"p-1 rounded hover:bg-[hsl(var(--destructive))] hover:text-[hsl(var(--destructive-foreground))] text-[hsl(var(--muted-foreground))]",children:r.jsx(qv,{size:14})})})]}),r.jsx(st,{data:R.value,collapsed:!0})]},R.key))})]})}function d2(n){try{return JSON.parse(n)}catch{return n}}function h2(n,i){if(i==="assistant"){const c=n.trim();if(c.startsWith("{")||c.startsWith("["))try{const o=JSON.parse(c);return r.jsx(st,{data:o,collapsed:!0})}catch{}}return r.jsx("div",{className:"whitespace-pre-wrap",children:n})}function m2(){const[n,i]=S.useState(null),[c,o]=S.useState(null),[d,h]=S.useState(null),v=xi(),{data:p=[]}=tl({queryKey:["sessions"],queryFn:H1,refetchInterval:5e3}),{data:y}=tl({queryKey:["session",n],queryFn:()=>q1(n),enabled:!!n}),x=Qo({mutationFn:B1,onSuccess:()=>{v.invalidateQueries({queryKey:["sessions"]}),i(null),h(null)}}),b=y!=null&&y.history?c!==null?y.history.slice(0,c+1):y.history:[];return r.jsx(ss,{title:"Session Manager",description:"Browse active sessions, replay conversations, and view handoff chains",children:r.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-3 gap-6",children:[r.jsxs("div",{className:"space-y-2",children:[r.jsxs("h3",{className:"text-sm font-medium mb-2",children:["Sessions (",p.length,")"]}),p.length===0?r.jsx(kt,{icon:r.jsx(Bv,{size:24}),title:"No sessions",description:"Sessions are created when using runtime.session()"}):p.map(g=>r.jsxs("button",{onClick:()=>{i(g.id),o(null)},className:`w-full text-left px-3 py-2.5 text-xs rounded-xl border transition-colors ${n===g.id?"border-[hsl(var(--primary))] bg-[hsl(var(--accent))]":"border-[hsl(var(--border))] hover:bg-[hsl(var(--accent))]"}`,children:[r.jsx("div",{className:"font-mono truncate text-[11px]",title:g.id,children:g.id}),r.jsxs("div",{className:"flex items-center gap-1.5 text-[hsl(var(--muted-foreground))] mt-1",children:[r.jsx(Hv,{size:11}),r.jsxs("span",{children:[g.messageCount," message",g.messageCount!==1?"s":""]})]})]},g.id))]}),r.jsx("div",{className:"lg:col-span-2",children:y?r.jsxs("div",{className:"space-y-4",children:[r.jsxs("div",{className:"flex items-center justify-between",children:[r.jsxs("div",{children:[r.jsx("h3",{className:"text-sm font-medium font-mono",children:y.id}),r.jsxs("p",{className:"text-xs text-[hsl(var(--muted-foreground))]",children:[y.history.length," messages"]})]}),d===y.id?r.jsxs("div",{className:"flex items-center gap-1.5",children:[r.jsx("button",{onClick:()=>x.mutate(y.id),className:"px-2 py-1 text-xs rounded-md bg-red-600 text-white hover:bg-red-700 dark:bg-red-700 dark:hover:bg-red-800",children:"Confirm"}),r.jsx("button",{onClick:()=>h(null),className:"px-2 py-1 text-xs rounded-md border border-[hsl(var(--border))] hover:bg-[hsl(var(--accent))]",children:"Cancel"})]}):r.jsxs("button",{onClick:()=>h(y.id),className:"flex items-center gap-1 px-2 py-1 text-xs rounded-md border border-red-300 text-red-600 hover:bg-red-50 dark:border-red-800 dark:text-red-400 dark:hover:bg-red-950",children:[r.jsx(qv,{size:12}),"Delete"]})]}),y.handoffHistory&&y.handoffHistory.length>0&&r.jsxs("div",{children:[r.jsx("h4",{className:"text-xs font-medium mb-2",children:"Handoff Chain"}),r.jsx("div",{className:"flex items-center gap-1 flex-wrap",children:y.handoffHistory.map((g,A)=>r.jsxs("div",{className:"flex items-center gap-1",children:[r.jsx("span",{className:"px-2 py-0.5 text-xs rounded bg-blue-100 dark:bg-blue-900 text-blue-700 dark:text-blue-300",children:g.source}),r.jsx(Xo,{size:12,className:"text-[hsl(var(--muted-foreground))]"}),r.jsx("span",{className:"px-2 py-0.5 text-xs rounded bg-blue-100 dark:bg-blue-900 text-blue-700 dark:text-blue-300",children:g.target}),r.jsxs("span",{className:"text-xs text-[hsl(var(--muted-foreground))]",children:["(",g.mode,")"]}),A<y.handoffHistory.length-1&&r.jsx("span",{className:"mx-1 text-[hsl(var(--muted-foreground))]",children:"|"})]},A))})]}),y.history.length>1&&r.jsxs("div",{className:"rounded-xl border border-[hsl(var(--border))] p-3",children:[r.jsxs("div",{className:"flex items-center justify-between mb-2",children:[r.jsx("label",{className:"text-xs font-medium",children:"Replay"}),r.jsx("span",{className:"text-xs text-[hsl(var(--muted-foreground))] font-mono",children:c!==null?`${c+1} / ${y.history.length}`:`${y.history.length} / ${y.history.length}`})]}),r.jsx("input",{type:"range",min:0,max:y.history.length-1,value:c??y.history.length-1,onChange:g=>o(Number(g.target.value)),className:"w-full h-1.5 rounded-full appearance-none cursor-pointer bg-[hsl(var(--secondary))] [&::-webkit-slider-thumb]:appearance-none [&::-webkit-slider-thumb]:w-3.5 [&::-webkit-slider-thumb]:h-3.5 [&::-webkit-slider-thumb]:rounded-full [&::-webkit-slider-thumb]:bg-[hsl(var(--primary))] [&::-webkit-slider-thumb]:shadow-sm [&::-moz-range-thumb]:w-3.5 [&::-moz-range-thumb]:h-3.5 [&::-moz-range-thumb]:rounded-full [&::-moz-range-thumb]:bg-[hsl(var(--primary))] [&::-moz-range-thumb]:border-0"}),r.jsxs("div",{className:"flex justify-between mt-1",children:[r.jsx("span",{className:"text-[10px] text-[hsl(var(--muted-foreground))]",children:"Start"}),r.jsx("span",{className:"text-[10px] text-[hsl(var(--muted-foreground))]",children:"Latest"})]})]}),r.jsx("div",{className:"space-y-3",children:b.map((g,A)=>r.jsxs("div",{className:`p-3 rounded-xl text-sm ${g.role==="user"?"bg-[hsl(var(--primary))] text-[hsl(var(--primary-foreground))] ml-8":g.role==="assistant"?"bg-[hsl(var(--secondary))] mr-8":"bg-[hsl(var(--muted))] text-xs font-mono"}`,children:[r.jsx("div",{className:"text-xs font-medium mb-1 opacity-70",children:g.role}),h2(g.content,g.role),g.tool_calls&&g.tool_calls.length>0&&r.jsx("div",{className:"mt-2 space-y-1",children:g.tool_calls.map(O=>r.jsxs("details",{className:"text-xs",children:[r.jsx("summary",{className:"cursor-pointer font-mono",children:O.function.name}),r.jsx(st,{data:d2(O.function.arguments),collapsed:!0})]},O.id))})]},A))})]}):r.jsx(kt,{title:"Select a session",description:"Click a session to view its history"})})]})})}function p2(){const[n,i]=S.useState(null),[c,o]=S.useState(void 0),[d,h]=S.useState(null),[v,p]=S.useState(!1),[y,x]=S.useState(!1),{data:b=[]}=tl({queryKey:["tools"],queryFn:k1}),{data:g}=tl({queryKey:["tool",n],queryFn:()=>Q1(n),enabled:!!n}),A=S.useCallback(async O=>{if(n){o(null),h(null),p(!0);try{const k=await Y1(n,O);o(k.result)}catch(k){h(k instanceof Error?k.message:String(k))}finally{p(!1)}}},[n]);return r.jsx(ss,{title:"Tool Inspector",description:"View tool schemas and test tools directly",children:r.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-3 gap-6",children:[r.jsxs("div",{className:"space-y-2",children:[r.jsxs("h3",{className:"text-sm font-medium mb-2",children:["Tools (",b.length,")"]}),b.length===0?r.jsx(kt,{icon:r.jsx(Lv,{size:24}),title:"No tools",description:"Register tools with runtime.registerTool()"}):b.map(O=>r.jsxs("button",{onClick:()=>{i(O.name),o(void 0),h(null),x(!1)},className:`w-full text-left px-3 py-2 text-xs rounded-xl border ${n===O.name?"border-[hsl(var(--primary))] bg-[hsl(var(--accent))]":"border-[hsl(var(--border))] hover:bg-[hsl(var(--accent))]"}`,children:[r.jsx("div",{className:"font-medium",children:O.name}),r.jsx("div",{className:"text-[hsl(var(--muted-foreground))] mt-0.5 truncate",children:O.description}),r.jsxs("div",{className:"flex items-center gap-1.5 mt-1",children:[O.sensitive&&r.jsx("span",{className:"px-1 py-0.5 rounded bg-amber-100 dark:bg-amber-900 text-amber-700 dark:text-amber-300 text-[10px]",children:"sensitive"}),O.requireApproval&&r.jsx("span",{className:"px-1 py-0.5 rounded bg-blue-100 dark:bg-blue-900 text-blue-700 dark:text-blue-300 text-[10px]",children:"approval"})]})]},O.name))]}),r.jsx("div",{className:"lg:col-span-2",children:n?g?r.jsxs("div",{className:"space-y-6",children:[r.jsxs("div",{children:[r.jsx("h3",{className:"text-lg font-medium",children:g.name}),r.jsx("p",{className:"text-sm text-[hsl(var(--muted-foreground))]",children:g.description})]}),r.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[g.sensitive&&r.jsx("span",{className:"px-2 py-1 text-xs rounded-md bg-amber-100 dark:bg-amber-900 text-amber-700 dark:text-amber-300",children:"Sensitive"}),g.requireApproval&&r.jsx("span",{className:"px-2 py-1 text-xs rounded-md bg-blue-100 dark:bg-blue-900 text-blue-700 dark:text-blue-300",children:"Requires Approval"}),g.retry.attempts&&g.retry.attempts>1&&r.jsxs("span",{className:"px-2 py-1 text-xs rounded-md bg-green-100 dark:bg-green-900 text-green-700 dark:text-green-300",children:["Retry: ",g.retry.attempts,"x ",g.retry.backoff]}),g.hasHooks&&g.hooks&&r.jsxs("span",{className:"px-2 py-1 text-xs rounded-md bg-purple-100 dark:bg-purple-900 text-purple-700 dark:text-purple-300",children:["Hooks:"," ",[g.hooks.hasBefore&&"before",g.hooks.hasAfter&&"after"].filter(Boolean).join(" + ")]})]}),r.jsxs("div",{children:[r.jsxs("button",{onClick:()=>x(!y),className:"flex items-center gap-1.5 text-sm font-medium text-[hsl(var(--muted-foreground))] hover:text-[hsl(var(--foreground))] transition-colors",children:[r.jsx(ns,{size:14,className:pe("transition-transform",y&&"rotate-90")}),"View raw schema"]}),y&&r.jsx("div",{className:"mt-2",children:r.jsx(st,{data:g.inputSchema})})]}),r.jsxs("div",{children:[r.jsx("h4",{className:"text-sm font-medium mb-2",children:"Test Tool"}),r.jsx("div",{className:"rounded-xl border border-[hsl(var(--border))] p-4 bg-[hsl(var(--card))]",children:r.jsx(Kv,{schema:g.inputSchema,onSubmit:A,submitLabel:v?"Running...":"Run Tool"})})]}),c!==void 0&&r.jsxs("div",{children:[r.jsx("h4",{className:"text-sm font-medium mb-2",children:"Result"}),r.jsx("div",{className:"rounded-xl border border-[hsl(var(--border))] p-4 bg-[hsl(var(--card))]",children:r.jsx(st,{data:c})})]}),d&&r.jsx("div",{className:"p-3 rounded-xl bg-red-50 dark:bg-red-950 border border-red-200 dark:border-red-800 text-red-700 dark:text-red-300 text-sm",children:d})]}):r.jsxs("div",{className:"flex items-center gap-2 text-sm text-[hsl(var(--muted-foreground))]",children:[r.jsx(i1,{size:16,className:"animate-spin"}),"Loading tool details..."]}):r.jsx(kt,{title:"Select a tool",description:"Click a tool to view its schema and test it"})})]})})}function Ko(n){return n>=.8?"bg-emerald-100 dark:bg-emerald-900/50 text-emerald-700 dark:text-emerald-300":n>=.5?"bg-amber-100 dark:bg-amber-900/40 text-amber-700 dark:text-amber-300":"bg-red-100 dark:bg-red-900/40 text-red-700 dark:text-red-300"}function cf(n){return n>=.8?"bg-emerald-500 dark:bg-emerald-400":n>=.5?"bg-amber-500 dark:bg-amber-400":"bg-red-500 dark:bg-red-400"}function nn(n){return n>=.8?"text-emerald-600 dark:text-emerald-400":n>=.5?"text-amber-600 dark:text-amber-400":"text-red-600 dark:text-red-400"}function v2(n){return n>=.8?"bg-emerald-50/60 dark:bg-emerald-950/20":n>=.5?"bg-amber-50/60 dark:bg-amber-950/20":"bg-red-50/60 dark:bg-red-950/20"}function x2({summary:n,items:i,totalCost:c}){const o=n.scorers?Object.entries(n.scorers):[];return o.length===0&&!n.timing&&c<=0?null:r.jsxs("div",{className:"rounded-xl border border-[hsl(var(--border))] overflow-hidden",children:[r.jsx("div",{className:"px-4 py-2.5 bg-[hsl(var(--muted))] border-b border-[hsl(var(--border))]",children:r.jsx("h3",{className:"text-[11px] font-medium uppercase tracking-wider text-[hsl(var(--muted-foreground))]",children:"Scorer Summary"})}),r.jsx("div",{className:"overflow-x-auto",children:r.jsxs("table",{className:"w-full text-xs",children:[r.jsx("thead",{children:r.jsxs("tr",{className:"border-b border-[hsl(var(--border))]",children:[r.jsx("th",{className:"text-left px-4 py-2 font-medium w-48",children:"Metric"}),r.jsx("th",{className:"px-4 py-2 w-28"}),r.jsx("th",{className:"text-right px-3 py-2 font-medium",children:"Mean"}),r.jsx("th",{className:"text-right px-3 py-2 font-medium",children:"P50"}),r.jsx("th",{className:"text-right px-3 py-2 font-medium",children:"P95"}),r.jsx("th",{className:"text-right px-3 py-2 font-medium",children:"Min"}),r.jsx("th",{className:"text-right px-3 py-2 font-medium",children:"Max"})]})}),r.jsxs("tbody",{children:[o.map(([d,h])=>{const v=i.some(p=>!p.error&&p.scores[d]!=null);return r.jsxs("tr",{className:"border-b border-[hsl(var(--border))] last:border-b-0",children:[r.jsx("td",{className:"px-4 py-2.5 font-mono text-[hsl(var(--foreground))]",children:d}),v?r.jsxs(r.Fragment,{children:[r.jsx("td",{className:"px-4 py-2.5",children:r.jsx("div",{className:"h-2 bg-[hsl(var(--secondary))] rounded-full overflow-hidden",children:r.jsx("div",{className:pe("h-full rounded-full transition-all",cf(h.mean)),style:{width:`${h.mean*100}%`}})})}),r.jsx("td",{className:pe("px-3 py-2.5 text-right font-mono font-medium",nn(h.mean)),children:h.mean.toFixed(3)}),r.jsx("td",{className:"px-3 py-2.5 text-right font-mono text-[hsl(var(--muted-foreground))]",children:h.p50.toFixed(3)}),r.jsx("td",{className:"px-3 py-2.5 text-right font-mono text-[hsl(var(--muted-foreground))]",children:h.p95.toFixed(3)}),r.jsx("td",{className:"px-3 py-2.5 text-right font-mono text-[hsl(var(--muted-foreground))]",children:h.min.toFixed(3)}),r.jsx("td",{className:"px-3 py-2.5 text-right font-mono text-[hsl(var(--muted-foreground))]",children:h.max.toFixed(3)})]}):r.jsx("td",{colSpan:6,className:"px-3 py-2.5 text-center text-[hsl(var(--muted-foreground))]",children:"No valid scores"})]},d)}),n.timing&&r.jsxs("tr",{className:"border-t border-[hsl(var(--border))]",children:[r.jsx("td",{className:"px-4 py-2.5 font-mono text-[hsl(var(--muted-foreground))]",children:"Timing"}),r.jsx("td",{className:"px-4 py-2.5"}),r.jsx("td",{className:"px-3 py-2.5 text-right font-mono text-[hsl(var(--muted-foreground))]",children:Ie(n.timing.mean)}),r.jsx("td",{className:"px-3 py-2.5 text-right font-mono text-[hsl(var(--muted-foreground))]",children:Ie(n.timing.p50)}),r.jsx("td",{className:"px-3 py-2.5 text-right font-mono text-[hsl(var(--muted-foreground))]",children:Ie(n.timing.p95)}),r.jsx("td",{className:"px-3 py-2.5 text-right font-mono text-[hsl(var(--muted-foreground))]",children:Ie(n.timing.min)}),r.jsx("td",{className:"px-3 py-2.5 text-right font-mono text-[hsl(var(--muted-foreground))]",children:Ie(n.timing.max)})]})]})]})}),c>0&&r.jsx("div",{className:"px-4 py-2 border-t border-[hsl(var(--border))] bg-[hsl(var(--muted))]/50",children:r.jsxs("span",{className:"text-xs text-[hsl(var(--muted-foreground))]",children:["Total cost: ",r.jsx("span",{className:"font-mono font-medium",children:ft(c)})]})})]})}function y2({items:n,scorerNames:i,onSelectItem:c,errorFilter:o,onErrorFilterChange:d,scorerFilter:h,onScorerFilterChange:v,threshold:p,onThresholdChange:y,sortField:x,onSortFieldChange:b,sortDir:g,onSortDirChange:A}){const O=p!==""?parseFloat(p):null,k=o!=="all"||h!==""&&O!=null&&!isNaN(O),H=S.useMemo(()=>n.map((M,Y)=>({item:M,index:Y})),[n]),U=S.useMemo(()=>{let M=H;return o==="errors"?M=M.filter(({item:Y})=>!!Y.error):o==="no-errors"&&(M=M.filter(({item:Y})=>!Y.error)),h&&O!=null&&!isNaN(O)&&(M=M.filter(({item:Y})=>{const R=Y.scores[h];return R!=null&&R<O})),M},[H,o,h,O]),V=S.useMemo(()=>{const M=[...U],Y=g==="asc"?1:-1;return M.sort((R,P)=>{let q,Z;return x==="index"?(q=R.index,Z=P.index):x==="duration"?(q=R.item.duration??1/0,Z=P.item.duration??1/0):x==="cost"?(q=R.item.cost??1/0,Z=P.item.cost??1/0):(q=R.item.scores[x]??-1/0,Z=P.item.scores[x]??-1/0),(q-Z)*Y}),M},[U,x,g]),$=[{value:"index",label:"Item #"},{value:"duration",label:"Duration"},{value:"cost",label:"Cost"},...i.map(M=>({value:M,label:M}))];return r.jsxs("div",{children:[r.jsxs("div",{className:"flex items-center justify-between gap-3 mb-3 flex-wrap",children:[r.jsxs("div",{className:"flex items-center gap-2",children:[r.jsx("h3",{className:"text-[11px] font-medium uppercase tracking-wider text-[hsl(var(--muted-foreground))]",children:"All Items"}),r.jsx("span",{className:"text-xs text-[hsl(var(--muted-foreground))] font-mono tabular-nums",children:k?`${U.length} of ${n.length}`:String(n.length)}),k&&r.jsx("button",{onClick:()=>{d("all"),v(""),y("")},className:"text-xs text-[hsl(var(--primary))] hover:underline",children:"Reset"})]}),r.jsxs("div",{className:"flex items-center gap-2 flex-wrap",children:[r.jsxs("select",{value:o,onChange:M=>d(M.target.value),className:"px-2 py-1 text-xs rounded-lg border border-[hsl(var(--input))] bg-[hsl(var(--background))]",children:[r.jsx("option",{value:"all",children:"All"}),r.jsx("option",{value:"errors",children:"Errors"}),r.jsx("option",{value:"no-errors",children:"Passed"})]}),i.length>0&&r.jsxs(r.Fragment,{children:[r.jsxs("select",{value:h,onChange:M=>v(M.target.value),className:"px-2 py-1 text-xs rounded-lg border border-[hsl(var(--input))] bg-[hsl(var(--background))]",children:[r.jsx("option",{value:"",children:"Score filter…"}),i.map(M=>r.jsx("option",{value:M,children:M},M))]}),h&&r.jsx("input",{type:"number",step:"0.1",min:"0",max:"1",placeholder:"< threshold",value:p,onChange:M=>y(M.target.value),className:"w-20 px-2 py-1 text-xs rounded-lg border border-[hsl(var(--input))] bg-[hsl(var(--background))]"})]}),r.jsx("div",{className:"w-px h-4 bg-[hsl(var(--border))]"}),r.jsx("select",{value:x,onChange:M=>b(M.target.value),className:"px-2 py-1 text-xs rounded-lg border border-[hsl(var(--input))] bg-[hsl(var(--background))]",children:$.map(M=>r.jsx("option",{value:M.value,children:M.label},M.value))}),r.jsx("button",{onClick:()=>A(g==="asc"?"desc":"asc"),className:"px-2 py-1 text-xs rounded-lg border border-[hsl(var(--input))] hover:bg-[hsl(var(--accent))] transition-colors",title:g==="asc"?"Ascending":"Descending",children:g==="asc"?"↑":"↓"})]})]}),V.length===0&&k&&r.jsx("p",{className:"text-xs text-[hsl(var(--muted-foreground))] py-6 text-center",children:"No items match the current filters."}),V.length>0&&r.jsx("div",{className:"rounded-xl border border-[hsl(var(--border))] overflow-hidden",children:r.jsx("div",{className:"overflow-x-auto",children:r.jsxs("table",{className:"w-full text-xs",children:[r.jsx("thead",{children:r.jsxs("tr",{className:"bg-[hsl(var(--muted))]",children:[r.jsx("th",{className:"text-left px-3 py-2.5 font-medium w-10",children:"#"}),r.jsx("th",{className:"text-left px-3 py-2.5 font-medium min-w-[180px]",children:"Input"}),i.map(M=>r.jsx("th",{className:"text-right px-2 py-2.5 font-medium font-mono max-w-24 truncate",title:M,children:M},M)),r.jsx("th",{className:"text-right px-3 py-2.5 font-medium w-16",children:"Duration"}),r.jsx("th",{className:"text-right px-3 py-2.5 font-medium w-16",children:"Cost"}),r.jsx("th",{className:"w-8"})]})}),r.jsx("tbody",{children:V.map(({item:M,index:Y})=>r.jsxs("tr",{onClick:()=>c(Y),className:"border-t border-[hsl(var(--border))] hover:bg-[hsl(var(--accent))] cursor-pointer transition-colors group",children:[r.jsxs("td",{className:"px-3 py-2 font-mono text-[hsl(var(--muted-foreground))]",children:[Y+1,M.error&&r.jsx("span",{className:"ml-1 text-red-500",title:"Workflow error",children:"!"}),!M.error&&M.scorerErrors&&M.scorerErrors.length>0&&r.jsx("span",{className:"ml-1 text-amber-500",title:"Scorer errors",children:"!"})]}),r.jsx("td",{className:"px-3 py-2 max-w-xs",children:r.jsx("span",{className:"text-[11px] leading-tight text-[hsl(var(--muted-foreground))] truncate block group-hover:text-[hsl(var(--foreground))] transition-colors",children:kv(M.input)})}),i.map(R=>{const P=M.scores[R];return r.jsx("td",{className:"text-right px-2 py-2 font-mono",children:P!=null?r.jsx("span",{className:pe("font-medium tabular-nums",nn(P)),children:P.toFixed(2)}):r.jsx("span",{className:"text-[hsl(var(--muted-foreground))]",children:"—"})},R)}),r.jsx("td",{className:"text-right px-3 py-2 font-mono text-[hsl(var(--muted-foreground))]",children:M.duration!=null?Ie(M.duration):"—"}),r.jsx("td",{className:"text-right px-3 py-2 font-mono text-[hsl(var(--muted-foreground))]",children:M.cost!=null&&M.cost>0?ft(M.cost):"—"}),r.jsx("td",{className:"px-2 py-2",children:r.jsx(ns,{size:12,className:"text-[hsl(var(--muted-foreground))] opacity-0 group-hover:opacity-60 transition-opacity"})})]},Y))})]})})})]})}const kp=300;function g2({text:n}){const[i,c]=S.useState(!1),o=n.length>kp;return r.jsxs("div",{children:[r.jsx("pre",{className:"text-xs font-mono p-3 rounded-lg bg-[hsl(var(--secondary))] overflow-auto max-h-96 whitespace-pre-wrap leading-relaxed",children:o&&!i?n.slice(0,kp)+"…":n}),o&&r.jsx("button",{onClick:()=>c(!i),className:"text-xs text-[hsl(var(--primary))] hover:underline mt-1.5",children:i?"Show less":"Show more"})]})}function Co({label:n,data:i}){return r.jsxs("div",{className:"rounded-xl border border-[hsl(var(--border))] overflow-hidden",children:[r.jsx("div",{className:"px-4 py-2.5 bg-[hsl(var(--muted))]/50 border-b border-[hsl(var(--border))]",children:r.jsx("span",{className:"text-[11px] font-medium uppercase tracking-wider text-[hsl(var(--muted-foreground))]",children:n})}),r.jsx("div",{className:"p-4",children:r.jsx(st,{data:i,collapsed:!0})})]})}function b2({item:n,itemIndex:i,scorerNames:c,onBack:o}){const d=n.scorerErrors??[],h=n.cost??0,v=n.scorerCost??0,p=h+v;return r.jsxs("div",{className:"space-y-5",children:[r.jsxs("div",{className:"flex items-center justify-between",children:[r.jsxs("nav",{className:"flex items-center gap-1.5 text-sm",children:[r.jsx("button",{onClick:o,className:"text-[hsl(var(--muted-foreground))] hover:text-[hsl(var(--foreground))] transition-colors",children:"Overview"}),r.jsx("span",{className:"text-[hsl(var(--muted-foreground))]",children:"/"}),r.jsxs("span",{className:"font-medium",children:["Item #",i+1]}),n.error&&r.jsx("span",{className:"ml-1 inline-flex items-center px-2 py-0.5 rounded-full text-[10px] font-medium text-red-600 dark:text-red-400 bg-red-50 dark:bg-red-950/30",children:"Error"})]}),r.jsxs("div",{className:"flex items-center gap-2 text-xs text-[hsl(var(--muted-foreground))] font-mono",children:[n.duration!=null&&r.jsx("span",{children:Ie(n.duration)}),p>0&&r.jsx("span",{children:ft(p)})]})]}),c.length>0&&r.jsx("div",{className:"flex flex-wrap items-center gap-x-4 gap-y-2 py-3 px-4 rounded-xl bg-[hsl(var(--muted))]/50",children:c.map(y=>{const x=n.scores[y];return r.jsxs("div",{className:"flex items-center gap-2",children:[r.jsx("span",{className:"text-xs text-[hsl(var(--muted-foreground))]",children:y}),x!=null?r.jsxs("div",{className:"flex items-center gap-1.5",children:[r.jsx("div",{className:"w-12 h-1.5 bg-[hsl(var(--secondary))] rounded-full overflow-hidden",children:r.jsx("div",{className:pe("h-full rounded-full",cf(x)),style:{width:`${x*100}%`}})}),r.jsx("span",{className:pe("text-xs font-mono font-medium tabular-nums",nn(x)),children:x.toFixed(2)})]}):r.jsx("span",{className:"text-xs text-[hsl(var(--muted-foreground))] font-mono",children:"—"})]},y)})}),n.error&&r.jsx("div",{className:"p-3 rounded-xl bg-red-50 dark:bg-red-950/30 border border-red-200 dark:border-red-800 text-red-700 dark:text-red-300 text-xs font-mono",children:n.error}),r.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-3",children:[r.jsx(Co,{label:"Input",data:n.input}),r.jsx(Co,{label:"Output",data:n.output})]}),n.annotations!=null&&r.jsx(Co,{label:"Expected (Annotations)",data:n.annotations}),p>0&&h>0&&v>0&&r.jsxs("div",{className:"flex items-center gap-3 text-xs text-[hsl(var(--muted-foreground))] font-mono",children:[r.jsxs("span",{children:["Workflow: ",ft(h)]}),r.jsx("span",{children:"+"}),r.jsxs("span",{children:["Scoring: ",ft(v)]}),r.jsx("span",{children:"="}),r.jsx("span",{className:"font-medium text-[hsl(var(--foreground))]",children:ft(p)})]}),c.length>0&&r.jsxs("div",{className:"space-y-3",children:[r.jsx("h4",{className:"text-[11px] font-medium uppercase tracking-wider text-[hsl(var(--muted-foreground))]",children:"Scorer Results"}),c.map(y=>{var A;const x=n.scores[y],b=(A=n.scoreDetails)==null?void 0:A[y],g=d.find(O=>O.includes(`"${y}"`));return r.jsxs("div",{className:"rounded-xl border border-[hsl(var(--border))] overflow-hidden",children:[r.jsxs("div",{className:"flex items-center gap-2 px-4 py-2.5 bg-[hsl(var(--muted))]/50",children:[r.jsx("span",{className:"font-mono text-xs font-medium",children:y}),x!=null&&r.jsx("span",{className:pe("px-2 py-0.5 rounded-full text-xs font-mono font-medium",Ko(x)),children:x.toFixed(3)}),x==null&&!g&&r.jsx("span",{className:"px-2 py-0.5 rounded-full text-xs font-mono bg-[hsl(var(--secondary))] text-[hsl(var(--muted-foreground))]",children:"null"}),r.jsxs("div",{className:"ml-auto flex items-center gap-2",children:[(b==null?void 0:b.duration)!=null&&r.jsx("span",{className:"text-xs font-mono text-[hsl(var(--muted-foreground))]",children:Ie(b.duration)}),(b==null?void 0:b.cost)!=null&&b.cost>0&&r.jsx("span",{className:"text-xs font-mono text-[hsl(var(--muted-foreground))]",children:ft(b.cost)})]})]}),((b==null?void 0:b.metadata)||g)&&r.jsxs("div",{className:"px-4 py-3 space-y-2",children:[(b==null?void 0:b.metadata)&&typeof b.metadata.reasoning=="string"&&b.metadata.reasoning.length>0&&r.jsxs("div",{children:[r.jsx("span",{className:"text-[11px] font-medium text-[hsl(var(--muted-foreground))] block mb-1.5 uppercase tracking-wider",children:"Reasoning"}),r.jsx(g2,{text:b.metadata.reasoning})]}),(b==null?void 0:b.metadata)&&(()=>{const O=Object.keys(b.metadata).filter(H=>H!=="reasoning");if(O.length===0)return null;const k={};for(const H of O)k[H]=b.metadata[H];return r.jsxs("div",{children:[r.jsx("span",{className:"text-[11px] font-medium text-[hsl(var(--muted-foreground))] block mb-1.5 uppercase tracking-wider",children:"Metadata"}),r.jsx(st,{data:k,collapsed:!0})]})})(),g&&r.jsx("div",{className:"text-xs text-amber-600 dark:text-amber-400 font-mono p-2.5 rounded-lg bg-amber-50 dark:bg-amber-950/30",children:g})]})]},y)})]})]})}function S2(n,i){const c=i.map(o=>n.scores[o]).filter(o=>o!=null);return c.length===0?null:c.reduce((o,d)=>o+d,0)/c.length}function j2({items:n,scorerNames:i,selectedIndex:c,onSelectItem:o,onDeselectItem:d}){const h=S.useMemo(()=>n.map((p,y)=>({item:p,index:y,avg:S2(p,i),label:kv(p.input,60)})),[n,i]),v=n.filter(p=>p.error).length;return r.jsxs("div",{className:"flex flex-col h-full",children:[r.jsx("div",{className:"shrink-0 px-4 py-3 border-b border-[hsl(var(--border))]",children:r.jsxs("div",{className:"flex items-center justify-between",children:[r.jsxs("button",{onClick:d,className:pe("text-xs font-medium transition-colors",c==null?"text-[hsl(var(--foreground))]":"text-[hsl(var(--muted-foreground))] hover:text-[hsl(var(--foreground))]"),children:[n.length," items"]}),v>0?r.jsxs("span",{className:"text-[10px] font-medium text-red-600 dark:text-red-400",children:[v," failed"]}):r.jsx("span",{className:"text-[10px] font-medium text-emerald-600 dark:text-emerald-400",children:"all passed"})]})}),r.jsx("div",{className:"flex-1 overflow-y-auto",children:h.map(({item:p,index:y,avg:x,label:b})=>{const g=c===y;return r.jsxs("button",{onClick:()=>o(y),className:pe("w-full text-left px-4 py-2.5 flex items-center gap-3 border-b border-[hsl(var(--border))]/50 transition-colors group",g?"bg-[hsl(var(--accent))] border-l-2 border-l-[hsl(var(--foreground))]":"hover:bg-[hsl(var(--accent))]/50 border-l-2 border-l-transparent"),children:[r.jsx("span",{className:pe("text-[10px] font-mono w-5 shrink-0",g?"text-[hsl(var(--foreground))] font-medium":"text-[hsl(var(--muted-foreground))]"),children:y+1}),r.jsx("span",{className:pe("flex-1 text-xs truncate leading-snug",g?"text-[hsl(var(--foreground))]":"text-[hsl(var(--muted-foreground))] group-hover:text-[hsl(var(--foreground))]"),children:b}),p.error&&r.jsx("span",{className:"text-[10px] text-red-500 shrink-0",title:"Workflow error",children:"!"}),!p.error&&p.scorerErrors&&p.scorerErrors.length>0&&r.jsx("span",{className:"text-[10px] text-amber-500 shrink-0",title:"Scorer errors",children:"!"}),x!=null?r.jsx("span",{className:pe("text-[11px] font-mono font-medium shrink-0 tabular-nums",nn(x)),children:x.toFixed(2)}):r.jsx("span",{className:"text-[10px] text-[hsl(var(--muted-foreground))] shrink-0",children:"-"}),r.jsx(ns,{size:12,className:pe("shrink-0 transition-all",g?"text-[hsl(var(--foreground))] opacity-100":"text-[hsl(var(--muted-foreground))] opacity-0 group-hover:opacity-60")})]},y)})})]})}function N2({name:n,scores:i,mean:c}){return i.length===0?r.jsxs("div",{className:"flex items-center gap-3",children:[r.jsx("span",{className:"w-28 text-xs font-mono truncate text-[hsl(var(--muted-foreground))]",title:n,children:n}),r.jsx("span",{className:"text-xs text-[hsl(var(--muted-foreground))]",children:"No valid scores"})]}):r.jsxs("div",{className:"flex items-center gap-3",children:[r.jsx("span",{className:"w-28 text-xs font-mono truncate",title:n,children:n}),r.jsxs("div",{className:"flex-1 h-5 relative bg-[hsl(var(--secondary))] rounded",children:[[.25,.5,.75].map(o=>r.jsx("div",{className:"absolute top-0 bottom-0 w-px bg-[hsl(var(--border))]",style:{left:`${o*100}%`}},o)),i.map((o,d)=>r.jsx("div",{className:pe("absolute w-1 top-[3px] bottom-[3px] rounded-sm",cf(o)),style:{left:`${Math.max(1,Math.min(99,o*100))}%`,transform:"translateX(-50%)",opacity:.45},title:o.toFixed(3)},d)),r.jsx("div",{className:"absolute top-0 bottom-0 w-0.5 bg-[hsl(var(--foreground))]",style:{left:`${c*100}%`,opacity:.3},title:`Mean: ${c.toFixed(3)}`})]}),r.jsx("span",{className:"w-12 text-xs font-mono text-right text-[hsl(var(--muted-foreground))] tabular-nums",children:c.toFixed(3)})]})}function E2({items:n,scorerNames:i}){const c=S.useMemo(()=>i.map(o=>{const d=[];for(const v of n){const p=v.scores[o];p!=null&&!v.error&&d.push(p)}const h=d.length>0?d.reduce((v,p)=>v+p,0)/d.length:0;return{name:o,scores:d,mean:h}}),[n,i]);return i.length===0?null:r.jsxs("div",{className:"rounded-xl border border-[hsl(var(--border))] overflow-hidden",children:[r.jsx("div",{className:"px-4 py-2.5 bg-[hsl(var(--muted))] border-b border-[hsl(var(--border))]",children:r.jsx("h3",{className:"text-[11px] font-medium uppercase tracking-wider text-[hsl(var(--muted-foreground))]",children:"Score Distribution"})}),r.jsxs("div",{className:"p-4 space-y-2",children:[r.jsxs("div",{className:"flex items-center gap-3 mb-1",children:[r.jsx("span",{className:"w-28"}),r.jsxs("div",{className:"flex-1 flex justify-between text-[10px] font-mono text-[hsl(var(--muted-foreground))]",children:[r.jsx("span",{children:"0"}),r.jsx("span",{children:"0.25"}),r.jsx("span",{children:"0.5"}),r.jsx("span",{children:"0.75"}),r.jsx("span",{children:"1.0"})]}),r.jsx("span",{className:"w-12"})]}),c.map(o=>r.jsx(N2,{name:o.name,scores:o.scores,mean:o.mean},o.name))]})]})}function To({value:n,percent:i,invert:c,format:o}){const d=c?n<0:n>0,h=c?n>0:n<0,v=d?"text-emerald-600 dark:text-emerald-400":h?"text-red-600 dark:text-red-400":"text-[hsl(var(--muted-foreground))]",p=o?`${n>0?"+":n<0?"-":""}${o(Math.abs(n))}`:`${n>0?"+":""}${Math.abs(n)<100?n.toFixed(3):n.toFixed(0)}`;return r.jsxs(r.Fragment,{children:[r.jsx("td",{className:pe("py-2.5 text-right font-mono",v),children:p}),r.jsxs("td",{className:pe("py-2.5 text-right font-mono",v),children:[i>0?"+":"",i.toFixed(1),"%"]})]})}function C2({compareResult:n,baseline:i,candidate:c}){const[o,d]=S.useState(null),h=(v,p)=>{(o==null?void 0:o.type)===v&&(o==null?void 0:o.index)===p?d(null):d({type:v,index:p})};return r.jsxs("div",{className:"space-y-6",children:[n.summary&&r.jsx("p",{className:"text-sm text-[hsl(var(--muted-foreground))]",children:n.summary}),n.scorers&&Object.keys(n.scorers).length>0&&r.jsxs("div",{className:"border border-[hsl(var(--border))] rounded-xl overflow-hidden",children:[r.jsx("div",{className:"px-4 py-2.5 bg-[hsl(var(--muted))] border-b border-[hsl(var(--border))]",children:r.jsx("h3",{className:"text-xs font-medium uppercase tracking-wider text-[hsl(var(--muted-foreground))]",children:"Scorer Comparison"})}),r.jsx("div",{className:"overflow-x-auto",children:r.jsxs("table",{className:"w-full text-xs",children:[r.jsx("thead",{children:r.jsxs("tr",{className:"border-b border-[hsl(var(--border))]",children:[r.jsx("th",{className:"text-left px-4 py-2 font-medium",children:"Metric"}),r.jsx("th",{className:"text-right px-3 py-2 font-medium",children:"Baseline"}),r.jsx("th",{className:"text-right px-3 py-2 font-medium",children:"Candidate"}),r.jsx("th",{className:"text-right px-3 py-2 font-medium",children:"Delta"}),r.jsx("th",{className:"text-right px-3 py-2 font-medium",children:"%"})]})}),r.jsxs("tbody",{children:[Object.entries(n.scorers).map(([v,p])=>r.jsxs("tr",{className:"border-b border-[hsl(var(--border))] last:border-b-0",children:[r.jsx("td",{className:"px-4 py-2.5 font-mono",children:v}),r.jsx("td",{className:"px-3 py-2.5 text-right font-mono text-[hsl(var(--muted-foreground))]",children:p.baselineMean.toFixed(3)}),r.jsx("td",{className:pe("px-3 py-2.5 text-right font-mono",nn(p.candidateMean)),children:p.candidateMean.toFixed(3)}),r.jsx(To,{value:p.delta,percent:p.deltaPercent})]},v)),n.timing&&r.jsxs("tr",{className:"border-t-2 border-[hsl(var(--border))]",children:[r.jsx("td",{className:"px-4 py-2.5 font-mono text-[hsl(var(--muted-foreground))]",children:"Timing (mean)"}),r.jsx("td",{className:"px-3 py-2.5 text-right font-mono text-[hsl(var(--muted-foreground))]",children:Ie(n.timing.baselineMean)}),r.jsx("td",{className:"px-3 py-2.5 text-right font-mono text-[hsl(var(--muted-foreground))]",children:Ie(n.timing.candidateMean)}),r.jsx(To,{value:n.timing.delta,percent:n.timing.deltaPercent,invert:!0,format:Ie})]}),n.cost!=null&&r.jsxs("tr",{className:"border-t border-[hsl(var(--border))]",children:[r.jsx("td",{className:"px-4 py-2.5 font-mono text-[hsl(var(--muted-foreground))]",children:"Cost (total)"}),r.jsx("td",{className:"px-3 py-2.5 text-right font-mono text-[hsl(var(--muted-foreground))]",children:ft(n.cost.baselineTotal)}),r.jsx("td",{className:"px-3 py-2.5 text-right font-mono text-[hsl(var(--muted-foreground))]",children:ft(n.cost.candidateTotal)}),r.jsx(To,{value:n.cost.delta,percent:n.cost.deltaPercent,invert:!0,format:ft})]})]})]})})]}),n.regressions&&n.regressions.length>0&&r.jsxs("div",{className:"border border-red-200 dark:border-red-900 rounded-lg overflow-hidden",children:[r.jsx("div",{className:"px-4 py-2.5 bg-red-50 dark:bg-red-950/30 border-b border-red-200 dark:border-red-900",children:r.jsxs("h3",{className:"text-xs font-medium text-red-700 dark:text-red-300",children:["Regressions (",n.regressions.length,")"]})}),r.jsx("div",{className:"divide-y divide-[hsl(var(--border))]",children:n.regressions.map((v,p)=>{const y=(o==null?void 0:o.type)==="regression"&&o.index===p,x=i==null?void 0:i.items[v.itemIndex],b=c==null?void 0:c.items[v.itemIndex];return r.jsxs("div",{children:[r.jsxs("button",{onClick:()=>h("regression",p),className:"w-full text-left flex items-center justify-between px-4 py-2.5 text-xs hover:bg-[hsl(var(--accent))] transition-colors",children:[r.jsxs("span",{className:"font-mono",children:["Item #",v.itemIndex+1," ",r.jsx("span",{className:"text-[hsl(var(--muted-foreground))]",children:v.scorer})]}),r.jsxs("span",{className:"font-mono text-red-600 dark:text-red-400",children:[v.baselineScore.toFixed(2)," ","→"," ",v.candidateScore.toFixed(2)," ",r.jsxs("span",{className:"text-[hsl(var(--muted-foreground))]",children:["(",v.delta.toFixed(2),")"]})]})]}),y&&x&&b&&r.jsx(Qp,{baselineItem:x,candidateItem:b,scorer:v.scorer})]},p)})})]}),n.improvements&&n.improvements.length>0&&r.jsxs("div",{className:"border border-emerald-200 dark:border-emerald-900 rounded-lg overflow-hidden",children:[r.jsx("div",{className:"px-4 py-2.5 bg-emerald-50 dark:bg-emerald-950/30 border-b border-emerald-200 dark:border-emerald-900",children:r.jsxs("h3",{className:"text-xs font-medium text-emerald-700 dark:text-emerald-300",children:["Improvements (",n.improvements.length,")"]})}),r.jsx("div",{className:"divide-y divide-[hsl(var(--border))]",children:n.improvements.map((v,p)=>{const y=(o==null?void 0:o.type)==="improvement"&&o.index===p,x=i==null?void 0:i.items[v.itemIndex],b=c==null?void 0:c.items[v.itemIndex];return r.jsxs("div",{children:[r.jsxs("button",{onClick:()=>h("improvement",p),className:"w-full text-left flex items-center justify-between px-4 py-2.5 text-xs hover:bg-[hsl(var(--accent))] transition-colors",children:[r.jsxs("span",{className:"font-mono",children:["Item #",v.itemIndex+1," ",r.jsx("span",{className:"text-[hsl(var(--muted-foreground))]",children:v.scorer})]}),r.jsxs("span",{className:"font-mono text-emerald-600 dark:text-emerald-400",children:[v.baselineScore.toFixed(2)," ","→"," ",v.candidateScore.toFixed(2)," ",r.jsxs("span",{className:"text-[hsl(var(--muted-foreground))]",children:["(+",v.delta.toFixed(2),")"]})]})]}),y&&x&&b&&r.jsx(Qp,{baselineItem:x,candidateItem:b,scorer:v.scorer})]},p)})})]})]})}function Qp({baselineItem:n,candidateItem:i,scorer:c}){var p,y,x,b;const o=(p=n.scoreDetails)==null?void 0:p[c],d=(y=i.scoreDetails)==null?void 0:y[c],h=typeof((x=o==null?void 0:o.metadata)==null?void 0:x.reasoning)=="string"?o.metadata.reasoning:null,v=typeof((b=d==null?void 0:d.metadata)==null?void 0:b.reasoning)=="string"?d.metadata.reasoning:null;return r.jsxs("div",{className:"border-t border-[hsl(var(--border))] bg-[hsl(var(--card))] grid grid-cols-2 gap-0 text-xs",children:[r.jsxs("div",{className:"p-4 space-y-3 border-r border-[hsl(var(--border))]",children:[r.jsx("h5",{className:"font-medium text-[hsl(var(--muted-foreground))] uppercase tracking-wider text-[10px]",children:"Baseline"}),r.jsx(st,{data:n.output,collapsed:!0}),(o==null?void 0:o.score)!=null&&r.jsxs("div",{className:"flex items-center gap-1.5",children:[r.jsx("span",{className:"text-[hsl(var(--muted-foreground))]",children:"Score:"}),r.jsx("span",{className:pe("px-2 py-0.5 rounded-full font-mono font-medium",Ko(o.score)),children:o.score.toFixed(3)})]}),h&&r.jsxs("div",{children:[r.jsx("span",{className:"font-medium text-[hsl(var(--muted-foreground))] text-[10px] uppercase tracking-wider block mb-1",children:"Reasoning"}),r.jsx("pre",{className:"text-xs font-mono p-2 rounded-md bg-[hsl(var(--secondary))] overflow-auto max-h-48 whitespace-pre-wrap leading-relaxed",children:h})]})]}),r.jsxs("div",{className:"p-4 space-y-3",children:[r.jsx("h5",{className:"font-medium text-[hsl(var(--muted-foreground))] uppercase tracking-wider text-[10px]",children:"Candidate"}),r.jsx(st,{data:i.output,collapsed:!0}),(d==null?void 0:d.score)!=null&&r.jsxs("div",{className:"flex items-center gap-1.5",children:[r.jsx("span",{className:"text-[hsl(var(--muted-foreground))]",children:"Score:"}),r.jsx("span",{className:pe("px-2 py-0.5 rounded-full font-mono font-medium",Ko(d.score)),children:d.score.toFixed(3)})]}),v&&r.jsxs("div",{children:[r.jsx("span",{className:"font-medium text-[hsl(var(--muted-foreground))] text-[10px] uppercase tracking-wider block mb-1",children:"Reasoning"}),r.jsx("pre",{className:"text-xs font-mono p-2 rounded-md bg-[hsl(var(--secondary))] overflow-auto max-h-48 whitespace-pre-wrap leading-relaxed",children:v})]})]})]})}function T2(){var he,Ne;const n=xi(),[i,c]=S.useState("run"),[o,d]=S.useState(""),[h,v]=S.useState(!1),[p,y]=S.useState(null),[x,b]=S.useState(null),[g,A]=S.useState(null),[O,k]=S.useState("all"),[H,U]=S.useState(""),[V,$]=S.useState(""),[M,Y]=S.useState("index"),[R,P]=S.useState("asc"),[q,Z]=S.useState(""),[G,W]=S.useState(!1),[ue,He]=S.useState(null),[Yt,dt]=S.useState(null),[tt,L]=S.useState(null),{data:F=[]}=tl({queryKey:["evals"],queryFn:$1}),{data:ae=[]}=tl({queryKey:["evalHistory"],queryFn:F1}),ve=F.find(oe=>oe.name===o),Re=S.useCallback(async()=>{if(o){v(!0),b(null),y(null),A(null);try{const oe=await W1(o);y(oe),n.invalidateQueries({queryKey:["evalHistory"]})}catch(oe){b(oe instanceof Error?oe.message:String(oe))}finally{v(!1)}}},[o,n]),C=S.useCallback(async()=>{if(ae.length<2)return;const oe=ae[0].eval,De=ae.filter(gt=>gt.eval===oe);if(!(De.length<2)){W(!0);try{const gt=De[0].data,Ta=De[1].data;dt(Ta),L(gt);const os=await I1(Ta,gt);He(os)}catch(gt){b(gt instanceof Error?gt.message:String(gt))}finally{W(!1)}}},[ae]),X=(he=p==null?void 0:p.summary)!=null&&he.scorers?Object.keys(p.summary.scorers):[],J=(Ne=p==null?void 0:p.summary)!=null&&Ne.scorers?Object.entries(p.summary.scorers):[],ee=J.length>0?J.reduce((oe,[,De])=>oe+De.mean,0)/J.length:0,re=["run","history","compare"];return r.jsxs("div",{className:"flex flex-col h-screen",children:[r.jsxs("header",{className:"shrink-0 flex items-center justify-between px-6 py-4 border-b border-[hsl(var(--border))]",children:[r.jsx("h2",{className:"text-xl font-semibold",children:"Evals"}),F.length>0&&r.jsxs("div",{className:"flex items-center gap-2",children:[r.jsxs("select",{value:o,onChange:oe=>d(oe.target.value),className:"px-3 py-1.5 text-sm rounded-lg border border-[hsl(var(--input))] bg-[hsl(var(--background))] min-w-[180px]",children:[r.jsx("option",{value:"",children:"Select eval…"}),F.map(oe=>r.jsx("option",{value:oe.name,children:oe.name},oe.name))]}),r.jsxs("button",{onClick:Re,disabled:!o||h,className:pe("inline-flex items-center gap-1.5 px-4 py-1.5 text-sm font-medium rounded-lg transition-all","bg-[hsl(var(--foreground))] text-[hsl(var(--background))]","hover:opacity-90 disabled:opacity-40"),children:[r.jsx(uf,{size:12,className:h?"animate-spin":""}),h?"Running…":"Run"]})]})]}),r.jsxs("div",{role:"tablist",className:"shrink-0 flex items-center gap-1 px-6 border-b border-[hsl(var(--border))]",children:[re.map(oe=>r.jsx("button",{role:"tab","aria-selected":i===oe,onClick:()=>c(oe),className:pe("px-3 py-2.5 text-sm -mb-px border-b-2 transition-colors",i===oe?"border-[hsl(var(--foreground))] text-[hsl(var(--foreground))] font-medium":"border-transparent text-[hsl(var(--muted-foreground))] hover:text-[hsl(var(--foreground))]"),children:oe.charAt(0).toUpperCase()+oe.slice(1)},oe)),ve&&i==="run"&&r.jsxs("div",{className:"ml-auto flex items-center gap-2 py-2",children:[r.jsx("span",{className:"text-[10px] text-[hsl(var(--muted-foreground))] uppercase tracking-wider",children:ve.workflow}),r.jsx("span",{className:"text-[hsl(var(--border))]",children:"/"}),r.jsx("span",{className:"text-[10px] text-[hsl(var(--muted-foreground))] uppercase tracking-wider",children:ve.dataset}),r.jsx("span",{className:"text-[hsl(var(--border))]",children:"/"}),r.jsxs("span",{className:"text-[10px] text-[hsl(var(--muted-foreground))]",children:[ve.scorers.length," scorer",ve.scorers.length!==1?"s":""]})]})]}),i==="run"&&r.jsx("div",{className:"flex-1 min-h-0 flex flex-col",children:F.length===0?r.jsx("div",{className:"flex-1 flex items-center justify-center p-6",children:r.jsx(kt,{icon:r.jsx(Kn,{size:32}),title:"No evals registered",description:"Define evals with defineEval() and load them via the evals middleware option or runtime.registerEval()."})}):x?r.jsx("div",{className:"p-6",children:r.jsx("div",{className:"p-4 rounded-xl bg-red-50 dark:bg-red-950/30 border border-red-200 dark:border-red-800 text-red-700 dark:text-red-300 text-sm",children:x})}):p?r.jsxs(r.Fragment,{children:[r.jsx("div",{className:"shrink-0 px-6 py-4",children:r.jsxs("div",{className:"grid grid-cols-2 lg:grid-cols-4 gap-3",children:[r.jsx(pt,{label:"Items",value:String(p.summary.count),subtitle:p.summary.failures>0?`${p.summary.failures} failed`:"all passed",subtitleColor:p.summary.failures>0?"text-red-600 dark:text-red-400":"text-emerald-600 dark:text-emerald-400"}),r.jsx(pt,{label:"Mean Score",value:J.length>0?ee.toFixed(3):"—",accent:J.length>0?nn(ee):void 0,tint:J.length>0?v2(ee):void 0,subtitle:"across all scorers"}),r.jsx(pt,{label:"Duration",value:p.summary.timing?Ie(p.summary.timing.mean):Ie(p.duration),subtitle:p.summary.timing?`p95 ${Ie(p.summary.timing.p95)}`:"total"}),r.jsx(pt,{label:"Cost",value:p.totalCost>0?ft(p.totalCost):"—",subtitle:"total"})]})}),r.jsxs("div",{className:"flex flex-1 min-h-0 border-t border-[hsl(var(--border))]",children:[r.jsx("div",{className:"w-[340px] xl:w-[380px] shrink-0 border-r border-[hsl(var(--border))] bg-[hsl(var(--card))]",children:r.jsx(j2,{items:p.items,scorerNames:X,selectedIndex:g,onSelectItem:A,onDeselectItem:()=>A(null)})}),r.jsx("div",{className:"flex-1 overflow-y-auto",children:g!=null?r.jsx("div",{className:"p-6",children:r.jsx(b2,{item:p.items[g],itemIndex:g,scorerNames:X,onBack:()=>A(null)})}):r.jsxs("div",{className:"p-6 space-y-6",children:[r.jsx(x2,{summary:p.summary,items:p.items,totalCost:p.totalCost}),r.jsx(E2,{items:p.items,scorerNames:X}),p.items.length>0&&r.jsx(y2,{items:p.items,scorerNames:X,onSelectItem:A,errorFilter:O,onErrorFilterChange:k,scorerFilter:H,onScorerFilterChange:U,threshold:V,onThresholdChange:$,sortField:M,onSortFieldChange:Y,sortDir:R,onSortDirChange:P})]})})]})]}):h?r.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center gap-4",children:[r.jsxs("div",{className:"relative",children:[r.jsx(Kn,{size:28,className:"text-[hsl(var(--muted-foreground))]"}),r.jsx("div",{className:"absolute -top-0.5 -right-0.5 w-2.5 h-2.5 rounded-full bg-emerald-500 animate-ping"}),r.jsx("div",{className:"absolute -top-0.5 -right-0.5 w-2.5 h-2.5 rounded-full bg-emerald-500"})]}),r.jsxs("div",{className:"text-center",children:[r.jsx("p",{className:"text-sm font-medium",children:"Running evaluation…"}),r.jsx("p",{className:"text-xs text-[hsl(var(--muted-foreground))] mt-1",children:ve?`${ve.dataset} · ${ve.scorers.length} scorers`:o})]})]}):r.jsx("div",{className:"flex-1 flex items-center justify-center",children:r.jsx(kt,{icon:r.jsx(Kn,{size:32}),title:"No results",description:"Select an eval and run it to see results."})})}),i==="history"&&r.jsx("div",{className:"flex-1 overflow-auto p-6",children:ae.length===0?r.jsx(kt,{title:"No eval history",description:"Run evaluations to build history."}):r.jsx(O2,{history:ae,evalFilter:q,onEvalFilterChange:Z,onSelect:oe=>{y(oe),A(null),c("run")}})}),i==="compare"&&r.jsx("div",{className:"flex-1 overflow-auto p-6",children:r.jsx("div",{className:"space-y-4",children:ae.length<2?r.jsx(kt,{title:"Need at least 2 eval runs",description:"Run evaluations to compare results."}):r.jsxs(r.Fragment,{children:[r.jsxs("div",{className:"flex items-center gap-3",children:[r.jsx("p",{className:"text-sm text-[hsl(var(--muted-foreground))]",children:"Comparing most recent run against previous run."}),r.jsx("button",{onClick:C,disabled:G,className:"px-4 py-2 text-sm font-medium rounded-lg bg-[hsl(var(--foreground))] text-[hsl(var(--background))] hover:opacity-90 disabled:opacity-50",children:G?"Comparing…":"Compare"})]}),ue&&r.jsx(C2,{compareResult:ue,baseline:Yt,candidate:tt})]})})})]})}function O2({history:n,evalFilter:i,onEvalFilterChange:c,onSelect:o}){var y;const d=[...new Set(n.map(x=>x.eval))].sort(),h=i?n.filter(x=>x.eval===i):n,v=new Set;for(const x of h){const b=x.data;if((y=b.summary)!=null&&y.scorers)for(const g of Object.keys(b.summary.scorers))v.add(g)}const p=[...v].sort();return r.jsxs("div",{children:[d.length>1&&r.jsxs("div",{className:"flex items-center gap-2 mb-4",children:[r.jsxs("select",{value:i,onChange:x=>c(x.target.value),className:"px-2 py-1 text-xs rounded-lg border border-[hsl(var(--input))] bg-[hsl(var(--background))]",children:[r.jsx("option",{value:"",children:"All evals"}),d.map(x=>r.jsx("option",{value:x,children:x},x))]}),i&&r.jsxs("span",{className:"text-xs text-[hsl(var(--muted-foreground))]",children:[h.length," run",h.length!==1?"s":""]})]}),r.jsx("div",{className:"border border-[hsl(var(--border))] rounded-xl overflow-hidden",children:r.jsx("div",{className:"overflow-x-auto",children:r.jsxs("table",{className:"w-full text-xs",children:[r.jsx("thead",{children:r.jsxs("tr",{className:"bg-[hsl(var(--muted))]",children:[r.jsx("th",{className:"text-left px-3 py-2.5 font-medium",children:"Eval"}),r.jsx("th",{className:"text-left px-3 py-2.5 font-medium",children:"Timestamp"}),r.jsx("th",{className:"text-right px-3 py-2.5 font-medium",children:"Items"}),r.jsx("th",{className:"text-right px-3 py-2.5 font-medium",children:"Failures"}),r.jsx("th",{className:"text-right px-3 py-2.5 font-medium",children:"Duration"}),r.jsx("th",{className:"text-right px-3 py-2.5 font-medium",children:"Cost"}),p.map(x=>r.jsx("th",{className:"text-right px-3 py-2.5 font-medium font-mono max-w-20 truncate",title:x,children:x},x))]})}),r.jsx("tbody",{children:h.map((x,b)=>{const g=x.data;return r.jsxs("tr",{className:pe("border-t border-[hsl(var(--border))] cursor-pointer hover:bg-[hsl(var(--accent))] transition-colors",b===0&&"bg-[hsl(var(--accent))]/30"),onClick:()=>o(g),children:[r.jsx("td",{className:"px-3 py-2.5 font-mono",children:x.eval}),r.jsx("td",{className:"px-3 py-2.5 text-[hsl(var(--muted-foreground))]",children:new Date(x.timestamp).toLocaleString()}),r.jsx("td",{className:"px-3 py-2.5 text-right font-mono",children:g.summary.count}),r.jsx("td",{className:"px-3 py-2.5 text-right font-mono",children:g.summary.failures>0?r.jsx("span",{className:"text-red-600 dark:text-red-400",children:g.summary.failures}):r.jsx("span",{className:"text-[hsl(var(--muted-foreground))]",children:"0"})}),r.jsx("td",{className:"px-3 py-2.5 text-right font-mono text-[hsl(var(--muted-foreground))]",children:g.duration>0?Ie(g.duration):"-"}),r.jsx("td",{className:"px-3 py-2.5 text-right font-mono text-[hsl(var(--muted-foreground))]",children:g.totalCost>0?ft(g.totalCost):"-"}),p.map(A=>{var k,H;const O=(H=(k=g.summary)==null?void 0:k.scorers)==null?void 0:H[A];return r.jsx("td",{className:"px-3 py-2.5 text-right font-mono",children:O?r.jsx("span",{className:nn(O.mean),children:O.mean.toFixed(3)}):r.jsx("span",{className:"text-[hsl(var(--muted-foreground))]",children:"-"})},A)})]},x.id)})})]})})})]})}function R2(){return r.jsx(wb,{basename:window.__AXL_STUDIO_BASE__||"/",children:r.jsxs("div",{className:"flex h-screen overflow-hidden",children:[r.jsx(E1,{}),r.jsx("div",{className:"flex-1 overflow-hidden",children:r.jsxs(cb,{children:[r.jsx(dl,{path:"/playground",element:r.jsx(l2,{})}),r.jsx(dl,{path:"/workflows",element:r.jsx(n2,{})}),r.jsx(dl,{path:"/traces",element:r.jsx(r2,{})}),r.jsx(dl,{path:"/costs",element:r.jsx(o2,{})}),r.jsx(dl,{path:"/memory",element:r.jsx(f2,{})}),r.jsx(dl,{path:"/sessions",element:r.jsx(m2,{})}),r.jsx(dl,{path:"/tools",element:r.jsx(p2,{})}),r.jsx(dl,{path:"/evals",element:r.jsx(T2,{})}),r.jsx(dl,{path:"*",element:r.jsx(ub,{to:"/playground",replace:!0})})]})})]})})}R0.createRoot(document.getElementById("root")).render(r.jsx(S.StrictMode,{children:r.jsx(P0,{client:fg,children:r.jsx(R2,{})})}));