@openafw/openafw 0.5.2
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.
- package/LICENSE +21 -0
- package/PRIVACY.md +377 -0
- package/README.md +152 -0
- package/dist/backends-Byh5VYtT.js +418 -0
- package/dist/bin/afw.js +45270 -0
- package/dist/bin/tap.js +83 -0
- package/dist/bin/tools.js +432 -0
- package/dist/secrets-9JqUBHyw.js +3 -0
- package/dist/secrets-Bj-gyv53.js +169 -0
- package/package.json +62 -0
- package/ui-dist/assets/index-BY6COSYk.css +1 -0
- package/ui-dist/assets/index-C9yCeZlD.js +20 -0
- package/ui-dist/index.html +13 -0
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
(function(){const d=document.createElement("link").relList;if(d&&d.supports&&d.supports("modulepreload"))return;for(const m of document.querySelectorAll('link[rel="modulepreload"]'))f(m);new MutationObserver(m=>{for(const g of m)if(g.type==="childList")for(const j of g.addedNodes)j.tagName==="LINK"&&j.rel==="modulepreload"&&f(j)}).observe(document,{childList:!0,subtree:!0});function o(m){const g={};return m.integrity&&(g.integrity=m.integrity),m.referrerPolicy&&(g.referrerPolicy=m.referrerPolicy),m.crossOrigin==="use-credentials"?g.credentials="include":m.crossOrigin==="anonymous"?g.credentials="omit":g.credentials="same-origin",g}function f(m){if(m.ep)return;m.ep=!0;const g=o(m);fetch(m.href,g)}})();var Ss={exports:{}},zn={};var Go;function $v(){if(Go)return zn;Go=1;var s=Symbol.for("react.transitional.element"),d=Symbol.for("react.fragment");function o(f,m,g){var j=null;if(g!==void 0&&(j=""+g),m.key!==void 0&&(j=""+m.key),"key"in m){g={};for(var E in m)E!=="key"&&(g[E]=m[E])}else g=m;return m=g.ref,{$$typeof:s,type:f,key:j,ref:m!==void 0?m:null,props:g}}return zn.Fragment=d,zn.jsx=o,zn.jsxs=o,zn}var Lo;function Wv(){return Lo||(Lo=1,Ss.exports=$v()),Ss.exports}var i=Wv(),Ns={exports:{}},ae={};var Xo;function Fv(){if(Xo)return ae;Xo=1;var s=Symbol.for("react.transitional.element"),d=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),f=Symbol.for("react.strict_mode"),m=Symbol.for("react.profiler"),g=Symbol.for("react.consumer"),j=Symbol.for("react.context"),E=Symbol.for("react.forward_ref"),T=Symbol.for("react.suspense"),x=Symbol.for("react.memo"),B=Symbol.for("react.lazy"),k=Symbol.for("react.activity"),Q=Symbol.iterator;function C(v){return v===null||typeof v!="object"?null:(v=Q&&v[Q]||v["@@iterator"],typeof v=="function"?v:null)}var w={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},ee=Object.assign,ce={};function G(v,D,X){this.props=v,this.context=D,this.refs=ce,this.updater=X||w}G.prototype.isReactComponent={},G.prototype.setState=function(v,D){if(typeof v!="object"&&typeof v!="function"&&v!=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,v,D,"setState")},G.prototype.forceUpdate=function(v){this.updater.enqueueForceUpdate(this,v,"forceUpdate")};function L(){}L.prototype=G.prototype;function P(v,D,X){this.props=v,this.context=D,this.refs=ce,this.updater=X||w}var le=P.prototype=new L;le.constructor=P,ee(le,G.prototype),le.isPureReactComponent=!0;var ve=Array.isArray;function F(){}var K={H:null,A:null,T:null,S:null},q=Object.prototype.hasOwnProperty;function se(v,D,X){var V=X.ref;return{$$typeof:s,type:v,key:D,ref:V!==void 0?V:null,props:X}}function we(v,D){return se(v.type,D,v.props)}function Me(v){return typeof v=="object"&&v!==null&&v.$$typeof===s}function Te(v){var D={"=":"=0",":":"=2"};return"$"+v.replace(/[=:]/g,function(X){return D[X]})}var _l=/\/+/g;function Qe(v,D){return typeof v=="object"&&v!==null&&v.key!=null?Te(""+v.key):D.toString(36)}function R(v){switch(v.status){case"fulfilled":return v.value;case"rejected":throw v.reason;default:switch(typeof v.status=="string"?v.then(F,F):(v.status="pending",v.then(function(D){v.status==="pending"&&(v.status="fulfilled",v.value=D)},function(D){v.status==="pending"&&(v.status="rejected",v.reason=D)})),v.status){case"fulfilled":return v.value;case"rejected":throw v.reason}}throw v}function z(v,D,X,V,ne){var re=typeof v;(re==="undefined"||re==="boolean")&&(v=null);var je=!1;if(v===null)je=!0;else switch(re){case"bigint":case"string":case"number":je=!0;break;case"object":switch(v.$$typeof){case s:case d:je=!0;break;case B:return je=v._init,z(je(v._payload),D,X,V,ne)}}if(je)return ne=ne(v),je=V===""?"."+Qe(v,0):V,ve(ne)?(X="",je!=null&&(X=je.replace(_l,"$&/")+"/"),z(ne,D,X,"",function(Da){return Da})):ne!=null&&(Me(ne)&&(ne=we(ne,X+(ne.key==null||v&&v.key===ne.key?"":(""+ne.key).replace(_l,"$&/")+"/")+je)),D.push(ne)),1;je=0;var Fe=V===""?".":V+":";if(ve(v))for(var De=0;De<v.length;De++)V=v[De],re=Fe+Qe(V,De),je+=z(V,D,X,re,ne);else if(De=C(v),typeof De=="function")for(v=De.call(v),De=0;!(V=v.next()).done;)V=V.value,re=Fe+Qe(V,De++),je+=z(V,D,X,re,ne);else if(re==="object"){if(typeof v.then=="function")return z(R(v),D,X,V,ne);throw D=String(v),Error("Objects are not valid as a React child (found: "+(D==="[object Object]"?"object with keys {"+Object.keys(v).join(", ")+"}":D)+"). If you meant to render a collection of children, use an array instead.")}return je}function p(v,D,X){if(v==null)return v;var V=[],ne=0;return z(v,V,"","",function(re){return D.call(X,re,ne++)}),V}function Y(v){if(v._status===-1){var D=v._result;D=D(),D.then(function(X){(v._status===0||v._status===-1)&&(v._status=1,v._result=X)},function(X){(v._status===0||v._status===-1)&&(v._status=2,v._result=X)}),v._status===-1&&(v._status=0,v._result=D)}if(v._status===1)return v._result.default;throw v._result}var $=typeof reportError=="function"?reportError:function(v){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var D=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof v=="object"&&v!==null&&typeof v.message=="string"?String(v.message):String(v),error:v});if(!window.dispatchEvent(D))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",v);return}console.error(v)},te={map:p,forEach:function(v,D,X){p(v,function(){D.apply(this,arguments)},X)},count:function(v){var D=0;return p(v,function(){D++}),D},toArray:function(v){return p(v,function(D){return D})||[]},only:function(v){if(!Me(v))throw Error("React.Children.only expected to receive a single React element child.");return v}};return ae.Activity=k,ae.Children=te,ae.Component=G,ae.Fragment=o,ae.Profiler=m,ae.PureComponent=P,ae.StrictMode=f,ae.Suspense=T,ae.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=K,ae.__COMPILER_RUNTIME={__proto__:null,c:function(v){return K.H.useMemoCache(v)}},ae.cache=function(v){return function(){return v.apply(null,arguments)}},ae.cacheSignal=function(){return null},ae.cloneElement=function(v,D,X){if(v==null)throw Error("The argument must be a React element, but you passed "+v+".");var V=ee({},v.props),ne=v.key;if(D!=null)for(re in D.key!==void 0&&(ne=""+D.key),D)!q.call(D,re)||re==="key"||re==="__self"||re==="__source"||re==="ref"&&D.ref===void 0||(V[re]=D[re]);var re=arguments.length-2;if(re===1)V.children=X;else if(1<re){for(var je=Array(re),Fe=0;Fe<re;Fe++)je[Fe]=arguments[Fe+2];V.children=je}return se(v.type,ne,V)},ae.createContext=function(v){return v={$$typeof:j,_currentValue:v,_currentValue2:v,_threadCount:0,Provider:null,Consumer:null},v.Provider=v,v.Consumer={$$typeof:g,_context:v},v},ae.createElement=function(v,D,X){var V,ne={},re=null;if(D!=null)for(V in D.key!==void 0&&(re=""+D.key),D)q.call(D,V)&&V!=="key"&&V!=="__self"&&V!=="__source"&&(ne[V]=D[V]);var je=arguments.length-2;if(je===1)ne.children=X;else if(1<je){for(var Fe=Array(je),De=0;De<je;De++)Fe[De]=arguments[De+2];ne.children=Fe}if(v&&v.defaultProps)for(V in je=v.defaultProps,je)ne[V]===void 0&&(ne[V]=je[V]);return se(v,re,ne)},ae.createRef=function(){return{current:null}},ae.forwardRef=function(v){return{$$typeof:E,render:v}},ae.isValidElement=Me,ae.lazy=function(v){return{$$typeof:B,_payload:{_status:-1,_result:v},_init:Y}},ae.memo=function(v,D){return{$$typeof:x,type:v,compare:D===void 0?null:D}},ae.startTransition=function(v){var D=K.T,X={};K.T=X;try{var V=v(),ne=K.S;ne!==null&&ne(X,V),typeof V=="object"&&V!==null&&typeof V.then=="function"&&V.then(F,$)}catch(re){$(re)}finally{D!==null&&X.types!==null&&(D.types=X.types),K.T=D}},ae.unstable_useCacheRefresh=function(){return K.H.useCacheRefresh()},ae.use=function(v){return K.H.use(v)},ae.useActionState=function(v,D,X){return K.H.useActionState(v,D,X)},ae.useCallback=function(v,D){return K.H.useCallback(v,D)},ae.useContext=function(v){return K.H.useContext(v)},ae.useDebugValue=function(){},ae.useDeferredValue=function(v,D){return K.H.useDeferredValue(v,D)},ae.useEffect=function(v,D){return K.H.useEffect(v,D)},ae.useEffectEvent=function(v){return K.H.useEffectEvent(v)},ae.useId=function(){return K.H.useId()},ae.useImperativeHandle=function(v,D,X){return K.H.useImperativeHandle(v,D,X)},ae.useInsertionEffect=function(v,D){return K.H.useInsertionEffect(v,D)},ae.useLayoutEffect=function(v,D){return K.H.useLayoutEffect(v,D)},ae.useMemo=function(v,D){return K.H.useMemo(v,D)},ae.useOptimistic=function(v,D){return K.H.useOptimistic(v,D)},ae.useReducer=function(v,D,X){return K.H.useReducer(v,D,X)},ae.useRef=function(v){return K.H.useRef(v)},ae.useState=function(v){return K.H.useState(v)},ae.useSyncExternalStore=function(v,D,X){return K.H.useSyncExternalStore(v,D,X)},ae.useTransition=function(){return K.H.useTransition()},ae.version="19.2.7",ae}var Qo;function Us(){return Qo||(Qo=1,Ns.exports=Fv()),Ns.exports}var H=Us(),Es={exports:{}},_n={},Ts={exports:{}},As={};var Zo;function Iv(){return Zo||(Zo=1,(function(s){function d(z,p){var Y=z.length;z.push(p);e:for(;0<Y;){var $=Y-1>>>1,te=z[$];if(0<m(te,p))z[$]=p,z[Y]=te,Y=$;else break e}}function o(z){return z.length===0?null:z[0]}function f(z){if(z.length===0)return null;var p=z[0],Y=z.pop();if(Y!==p){z[0]=Y;e:for(var $=0,te=z.length,v=te>>>1;$<v;){var D=2*($+1)-1,X=z[D],V=D+1,ne=z[V];if(0>m(X,Y))V<te&&0>m(ne,X)?(z[$]=ne,z[V]=Y,$=V):(z[$]=X,z[D]=Y,$=D);else if(V<te&&0>m(ne,Y))z[$]=ne,z[V]=Y,$=V;else break e}}return p}function m(z,p){var Y=z.sortIndex-p.sortIndex;return Y!==0?Y:z.id-p.id}if(s.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var g=performance;s.unstable_now=function(){return g.now()}}else{var j=Date,E=j.now();s.unstable_now=function(){return j.now()-E}}var T=[],x=[],B=1,k=null,Q=3,C=!1,w=!1,ee=!1,ce=!1,G=typeof setTimeout=="function"?setTimeout:null,L=typeof clearTimeout=="function"?clearTimeout:null,P=typeof setImmediate<"u"?setImmediate:null;function le(z){for(var p=o(x);p!==null;){if(p.callback===null)f(x);else if(p.startTime<=z)f(x),p.sortIndex=p.expirationTime,d(T,p);else break;p=o(x)}}function ve(z){if(ee=!1,le(z),!w)if(o(T)!==null)w=!0,F||(F=!0,Te());else{var p=o(x);p!==null&&R(ve,p.startTime-z)}}var F=!1,K=-1,q=5,se=-1;function we(){return ce?!0:!(s.unstable_now()-se<q)}function Me(){if(ce=!1,F){var z=s.unstable_now();se=z;var p=!0;try{e:{w=!1,ee&&(ee=!1,L(K),K=-1),C=!0;var Y=Q;try{l:{for(le(z),k=o(T);k!==null&&!(k.expirationTime>z&&we());){var $=k.callback;if(typeof $=="function"){k.callback=null,Q=k.priorityLevel;var te=$(k.expirationTime<=z);if(z=s.unstable_now(),typeof te=="function"){k.callback=te,le(z),p=!0;break l}k===o(T)&&f(T),le(z)}else f(T);k=o(T)}if(k!==null)p=!0;else{var v=o(x);v!==null&&R(ve,v.startTime-z),p=!1}}break e}finally{k=null,Q=Y,C=!1}p=void 0}}finally{p?Te():F=!1}}}var Te;if(typeof P=="function")Te=function(){P(Me)};else if(typeof MessageChannel<"u"){var _l=new MessageChannel,Qe=_l.port2;_l.port1.onmessage=Me,Te=function(){Qe.postMessage(null)}}else Te=function(){G(Me,0)};function R(z,p){K=G(function(){z(s.unstable_now())},p)}s.unstable_IdlePriority=5,s.unstable_ImmediatePriority=1,s.unstable_LowPriority=4,s.unstable_NormalPriority=3,s.unstable_Profiling=null,s.unstable_UserBlockingPriority=2,s.unstable_cancelCallback=function(z){z.callback=null},s.unstable_forceFrameRate=function(z){0>z||125<z?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):q=0<z?Math.floor(1e3/z):5},s.unstable_getCurrentPriorityLevel=function(){return Q},s.unstable_next=function(z){switch(Q){case 1:case 2:case 3:var p=3;break;default:p=Q}var Y=Q;Q=p;try{return z()}finally{Q=Y}},s.unstable_requestPaint=function(){ce=!0},s.unstable_runWithPriority=function(z,p){switch(z){case 1:case 2:case 3:case 4:case 5:break;default:z=3}var Y=Q;Q=z;try{return p()}finally{Q=Y}},s.unstable_scheduleCallback=function(z,p,Y){var $=s.unstable_now();switch(typeof Y=="object"&&Y!==null?(Y=Y.delay,Y=typeof Y=="number"&&0<Y?$+Y:$):Y=$,z){case 1:var te=-1;break;case 2:te=250;break;case 5:te=1073741823;break;case 4:te=1e4;break;default:te=5e3}return te=Y+te,z={id:B++,callback:p,priorityLevel:z,startTime:Y,expirationTime:te,sortIndex:-1},Y>$?(z.sortIndex=Y,d(x,z),o(T)===null&&z===o(x)&&(ee?(L(K),K=-1):ee=!0,R(ve,Y-$))):(z.sortIndex=te,d(T,z),w||C||(w=!0,F||(F=!0,Te()))),z},s.unstable_shouldYield=we,s.unstable_wrapCallback=function(z){var p=Q;return function(){var Y=Q;Q=p;try{return z.apply(this,arguments)}finally{Q=Y}}}})(As)),As}var Ko;function Pv(){return Ko||(Ko=1,Ts.exports=Iv()),Ts.exports}var zs={exports:{}},We={};var Vo;function ey(){if(Vo)return We;Vo=1;var s=Us();function d(T){var x="https://react.dev/errors/"+T;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 #"+T+"; visit "+x+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function o(){}var f={d:{f:o,r:function(){throw Error(d(522))},D:o,C:o,L:o,m:o,X:o,S:o,M:o},p:0,findDOMNode:null},m=Symbol.for("react.portal");function g(T,x,B){var k=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:m,key:k==null?null:""+k,children:T,containerInfo:x,implementation:B}}var j=s.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function E(T,x){if(T==="font")return"";if(typeof x=="string")return x==="use-credentials"?x:""}return We.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=f,We.createPortal=function(T,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(d(299));return g(T,x,null,B)},We.flushSync=function(T){var x=j.T,B=f.p;try{if(j.T=null,f.p=2,T)return T()}finally{j.T=x,f.p=B,f.d.f()}},We.preconnect=function(T,x){typeof T=="string"&&(x?(x=x.crossOrigin,x=typeof x=="string"?x==="use-credentials"?x:"":void 0):x=null,f.d.C(T,x))},We.prefetchDNS=function(T){typeof T=="string"&&f.d.D(T)},We.preinit=function(T,x){if(typeof T=="string"&&x&&typeof x.as=="string"){var B=x.as,k=E(B,x.crossOrigin),Q=typeof x.integrity=="string"?x.integrity:void 0,C=typeof x.fetchPriority=="string"?x.fetchPriority:void 0;B==="style"?f.d.S(T,typeof x.precedence=="string"?x.precedence:void 0,{crossOrigin:k,integrity:Q,fetchPriority:C}):B==="script"&&f.d.X(T,{crossOrigin:k,integrity:Q,fetchPriority:C,nonce:typeof x.nonce=="string"?x.nonce:void 0})}},We.preinitModule=function(T,x){if(typeof T=="string")if(typeof x=="object"&&x!==null){if(x.as==null||x.as==="script"){var B=E(x.as,x.crossOrigin);f.d.M(T,{crossOrigin:B,integrity:typeof x.integrity=="string"?x.integrity:void 0,nonce:typeof x.nonce=="string"?x.nonce:void 0})}}else x==null&&f.d.M(T)},We.preload=function(T,x){if(typeof T=="string"&&typeof x=="object"&&x!==null&&typeof x.as=="string"){var B=x.as,k=E(B,x.crossOrigin);f.d.L(T,B,{crossOrigin:k,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})}},We.preloadModule=function(T,x){if(typeof T=="string")if(x){var B=E(x.as,x.crossOrigin);f.d.m(T,{as:typeof x.as=="string"&&x.as!=="script"?x.as:void 0,crossOrigin:B,integrity:typeof x.integrity=="string"?x.integrity:void 0})}else f.d.m(T)},We.requestFormReset=function(T){f.d.r(T)},We.unstable_batchedUpdates=function(T,x){return T(x)},We.useFormState=function(T,x,B){return j.H.useFormState(T,x,B)},We.useFormStatus=function(){return j.H.useHostTransitionStatus()},We.version="19.2.7",We}var Jo;function ly(){if(Jo)return zs.exports;Jo=1;function s(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(s)}catch(d){console.error(d)}}return s(),zs.exports=ey(),zs.exports}var $o;function ty(){if($o)return _n;$o=1;var s=Pv(),d=Us(),o=ly();function f(e){var l="https://react.dev/errors/"+e;if(1<arguments.length){l+="?args[]="+encodeURIComponent(arguments[1]);for(var t=2;t<arguments.length;t++)l+="&args[]="+encodeURIComponent(arguments[t])}return"Minified React error #"+e+"; visit "+l+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function m(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function g(e){var l=e,t=e;if(e.alternate)for(;l.return;)l=l.return;else{e=l;do l=e,(l.flags&4098)!==0&&(t=l.return),e=l.return;while(e)}return l.tag===3?t:null}function j(e){if(e.tag===13){var l=e.memoizedState;if(l===null&&(e=e.alternate,e!==null&&(l=e.memoizedState)),l!==null)return l.dehydrated}return null}function E(e){if(e.tag===31){var l=e.memoizedState;if(l===null&&(e=e.alternate,e!==null&&(l=e.memoizedState)),l!==null)return l.dehydrated}return null}function T(e){if(g(e)!==e)throw Error(f(188))}function x(e){var l=e.alternate;if(!l){if(l=g(e),l===null)throw Error(f(188));return l!==e?null:e}for(var t=e,a=l;;){var n=t.return;if(n===null)break;var u=n.alternate;if(u===null){if(a=n.return,a!==null){t=a;continue}break}if(n.child===u.child){for(u=n.child;u;){if(u===t)return T(n),e;if(u===a)return T(n),l;u=u.sibling}throw Error(f(188))}if(t.return!==a.return)t=n,a=u;else{for(var c=!1,r=n.child;r;){if(r===t){c=!0,t=n,a=u;break}if(r===a){c=!0,a=n,t=u;break}r=r.sibling}if(!c){for(r=u.child;r;){if(r===t){c=!0,t=u,a=n;break}if(r===a){c=!0,a=u,t=n;break}r=r.sibling}if(!c)throw Error(f(189))}}if(t.alternate!==a)throw Error(f(190))}if(t.tag!==3)throw Error(f(188));return t.stateNode.current===t?e:l}function B(e){var l=e.tag;if(l===5||l===26||l===27||l===6)return e;for(e=e.child;e!==null;){if(l=B(e),l!==null)return l;e=e.sibling}return null}var k=Object.assign,Q=Symbol.for("react.element"),C=Symbol.for("react.transitional.element"),w=Symbol.for("react.portal"),ee=Symbol.for("react.fragment"),ce=Symbol.for("react.strict_mode"),G=Symbol.for("react.profiler"),L=Symbol.for("react.consumer"),P=Symbol.for("react.context"),le=Symbol.for("react.forward_ref"),ve=Symbol.for("react.suspense"),F=Symbol.for("react.suspense_list"),K=Symbol.for("react.memo"),q=Symbol.for("react.lazy"),se=Symbol.for("react.activity"),we=Symbol.for("react.memo_cache_sentinel"),Me=Symbol.iterator;function Te(e){return e===null||typeof e!="object"?null:(e=Me&&e[Me]||e["@@iterator"],typeof e=="function"?e:null)}var _l=Symbol.for("react.client.reference");function Qe(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===_l?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case ee:return"Fragment";case G:return"Profiler";case ce:return"StrictMode";case ve:return"Suspense";case F:return"SuspenseList";case se:return"Activity"}if(typeof e=="object")switch(e.$$typeof){case w:return"Portal";case P:return e.displayName||"Context";case L:return(e._context.displayName||"Context")+".Consumer";case le:var l=e.render;return e=e.displayName,e||(e=l.displayName||l.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case K:return l=e.displayName||null,l!==null?l:Qe(e.type)||"Memo";case q:l=e._payload,e=e._init;try{return Qe(e(l))}catch{}}return null}var R=Array.isArray,z=d.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,p=o.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Y={pending:!1,data:null,method:null,action:null},$=[],te=-1;function v(e){return{current:e}}function D(e){0>te||(e.current=$[te],$[te]=null,te--)}function X(e,l){te++,$[te]=e.current,e.current=l}var V=v(null),ne=v(null),re=v(null),je=v(null);function Fe(e,l){switch(X(re,l),X(ne,e),X(V,null),l.nodeType){case 9:case 11:e=(e=l.documentElement)&&(e=e.namespaceURI)?ro(e):0;break;default:if(e=l.tagName,l=l.namespaceURI)l=ro(l),e=fo(l,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}D(V),X(V,e)}function De(){D(V),D(ne),D(re)}function Da(e){e.memoizedState!==null&&X(je,e);var l=V.current,t=fo(l,e.type);l!==t&&(X(ne,e),X(V,t))}function Cn(e){ne.current===e&&(D(V),D(ne)),je.current===e&&(D(je),Nn._currentValue=Y)}var nu,Bs;function zt(e){if(nu===void 0)try{throw Error()}catch(t){var l=t.stack.trim().match(/\n( *(at )?)/);nu=l&&l[1]||"",Bs=-1<t.stack.indexOf(`
|
|
2
|
+
at`)?" (<anonymous>)":-1<t.stack.indexOf("@")?"@unknown:0:0":""}return`
|
|
3
|
+
`+nu+e+Bs}var iu=!1;function uu(e,l){if(!e||iu)return"";iu=!0;var t=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var a={DetermineComponentFrameRoot:function(){try{if(l){var U=function(){throw Error()};if(Object.defineProperty(U.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(U,[])}catch(_){var A=_}Reflect.construct(e,[],U)}else{try{U.call()}catch(_){A=_}e.call(U.prototype)}}else{try{throw Error()}catch(_){A=_}(U=e())&&typeof U.catch=="function"&&U.catch(function(){})}}catch(_){if(_&&A&&typeof _.stack=="string")return[_.stack,A.stack]}return[null,null]}};a.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var n=Object.getOwnPropertyDescriptor(a.DetermineComponentFrameRoot,"name");n&&n.configurable&&Object.defineProperty(a.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var u=a.DetermineComponentFrameRoot(),c=u[0],r=u[1];if(c&&r){var h=c.split(`
|
|
4
|
+
`),N=r.split(`
|
|
5
|
+
`);for(n=a=0;a<h.length&&!h[a].includes("DetermineComponentFrameRoot");)a++;for(;n<N.length&&!N[n].includes("DetermineComponentFrameRoot");)n++;if(a===h.length||n===N.length)for(a=h.length-1,n=N.length-1;1<=a&&0<=n&&h[a]!==N[n];)n--;for(;1<=a&&0<=n;a--,n--)if(h[a]!==N[n]){if(a!==1||n!==1)do if(a--,n--,0>n||h[a]!==N[n]){var M=`
|
|
6
|
+
`+h[a].replace(" at new "," at ");return e.displayName&&M.includes("<anonymous>")&&(M=M.replace("<anonymous>",e.displayName)),M}while(1<=a&&0<=n);break}}}finally{iu=!1,Error.prepareStackTrace=t}return(t=e?e.displayName||e.name:"")?zt(t):""}function Ah(e,l){switch(e.tag){case 26:case 27:case 5:return zt(e.type);case 16:return zt("Lazy");case 13:return e.child!==l&&l!==null?zt("Suspense Fallback"):zt("Suspense");case 19:return zt("SuspenseList");case 0:case 15:return uu(e.type,!1);case 11:return uu(e.type.render,!1);case 1:return uu(e.type,!0);case 31:return zt("Activity");default:return""}}function Ys(e){try{var l="",t=null;do l+=Ah(e,t),t=e,e=e.return;while(e);return l}catch(a){return`
|
|
7
|
+
Error generating stack: `+a.message+`
|
|
8
|
+
`+a.stack}}var cu=Object.prototype.hasOwnProperty,su=s.unstable_scheduleCallback,ru=s.unstable_cancelCallback,zh=s.unstable_shouldYield,_h=s.unstable_requestPaint,sl=s.unstable_now,Mh=s.unstable_getCurrentPriorityLevel,ws=s.unstable_ImmediatePriority,Gs=s.unstable_UserBlockingPriority,On=s.unstable_NormalPriority,Ch=s.unstable_LowPriority,Ls=s.unstable_IdlePriority,Oh=s.log,Uh=s.unstable_setDisableYieldValue,Ra=null,rl=null;function tt(e){if(typeof Oh=="function"&&Uh(e),rl&&typeof rl.setStrictMode=="function")try{rl.setStrictMode(Ra,e)}catch{}}var dl=Math.clz32?Math.clz32:Hh,Dh=Math.log,Rh=Math.LN2;function Hh(e){return e>>>=0,e===0?32:31-(Dh(e)/Rh|0)|0}var Un=256,Dn=262144,Rn=4194304;function _t(e){var l=e&42;if(l!==0)return l;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 Hn(e,l,t){var a=e.pendingLanes;if(a===0)return 0;var n=0,u=e.suspendedLanes,c=e.pingedLanes;e=e.warmLanes;var r=a&134217727;return r!==0?(a=r&~u,a!==0?n=_t(a):(c&=r,c!==0?n=_t(c):t||(t=r&~e,t!==0&&(n=_t(t))))):(r=a&~u,r!==0?n=_t(r):c!==0?n=_t(c):t||(t=a&~e,t!==0&&(n=_t(t)))),n===0?0:l!==0&&l!==n&&(l&u)===0&&(u=n&-n,t=l&-l,u>=t||u===32&&(t&4194048)!==0)?l:n}function Ha(e,l){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&l)===0}function kh(e,l){switch(e){case 1:case 2:case 4:case 8:case 64:return l+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 l+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 Xs(){var e=Rn;return Rn<<=1,(Rn&62914560)===0&&(Rn=4194304),e}function du(e){for(var l=[],t=0;31>t;t++)l.push(e);return l}function ka(e,l){e.pendingLanes|=l,l!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function qh(e,l,t,a,n,u){var c=e.pendingLanes;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=t,e.entangledLanes&=t,e.errorRecoveryDisabledLanes&=t,e.shellSuspendCounter=0;var r=e.entanglements,h=e.expirationTimes,N=e.hiddenUpdates;for(t=c&~t;0<t;){var M=31-dl(t),U=1<<M;r[M]=0,h[M]=-1;var A=N[M];if(A!==null)for(N[M]=null,M=0;M<A.length;M++){var _=A[M];_!==null&&(_.lane&=-536870913)}t&=~U}a!==0&&Qs(e,a,0),u!==0&&n===0&&e.tag!==0&&(e.suspendedLanes|=u&~(c&~l))}function Qs(e,l,t){e.pendingLanes|=l,e.suspendedLanes&=~l;var a=31-dl(l);e.entangledLanes|=l,e.entanglements[a]=e.entanglements[a]|1073741824|t&261930}function Zs(e,l){var t=e.entangledLanes|=l;for(e=e.entanglements;t;){var a=31-dl(t),n=1<<a;n&l|e[a]&l&&(e[a]|=l),t&=~n}}function Ks(e,l){var t=l&-l;return t=(t&42)!==0?1:fu(t),(t&(e.suspendedLanes|l))!==0?0:t}function fu(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 ou(e){return e&=-e,2<e?8<e?(e&134217727)!==0?32:268435456:8:2}function Vs(){var e=p.p;return e!==0?e:(e=window.event,e===void 0?32:Ro(e.type))}function Js(e,l){var t=p.p;try{return p.p=e,l()}finally{p.p=t}}var at=Math.random().toString(36).slice(2),Ze="__reactFiber$"+at,ll="__reactProps$"+at,Kt="__reactContainer$"+at,hu="__reactEvents$"+at,Bh="__reactListeners$"+at,Yh="__reactHandles$"+at,$s="__reactResources$"+at,qa="__reactMarker$"+at;function mu(e){delete e[Ze],delete e[ll],delete e[hu],delete e[Bh],delete e[Yh]}function Vt(e){var l=e[Ze];if(l)return l;for(var t=e.parentNode;t;){if(l=t[Kt]||t[Ze]){if(t=l.alternate,l.child!==null||t!==null&&t.child!==null)for(e=po(e);e!==null;){if(t=e[Ze])return t;e=po(e)}return l}e=t,t=e.parentNode}return null}function Jt(e){if(e=e[Ze]||e[Kt]){var l=e.tag;if(l===5||l===6||l===13||l===31||l===26||l===27||l===3)return e}return null}function Ba(e){var l=e.tag;if(l===5||l===26||l===27||l===6)return e.stateNode;throw Error(f(33))}function $t(e){var l=e[$s];return l||(l=e[$s]={hoistableStyles:new Map,hoistableScripts:new Map}),l}function Le(e){e[qa]=!0}var Ws=new Set,Fs={};function Mt(e,l){Wt(e,l),Wt(e+"Capture",l)}function Wt(e,l){for(Fs[e]=l,e=0;e<l.length;e++)Ws.add(l[e])}var wh=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]*$"),Is={},Ps={};function Gh(e){return cu.call(Ps,e)?!0:cu.call(Is,e)?!1:wh.test(e)?Ps[e]=!0:(Is[e]=!0,!1)}function kn(e,l,t){if(Gh(l))if(t===null)e.removeAttribute(l);else{switch(typeof t){case"undefined":case"function":case"symbol":e.removeAttribute(l);return;case"boolean":var a=l.toLowerCase().slice(0,5);if(a!=="data-"&&a!=="aria-"){e.removeAttribute(l);return}}e.setAttribute(l,""+t)}}function qn(e,l,t){if(t===null)e.removeAttribute(l);else{switch(typeof t){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(l);return}e.setAttribute(l,""+t)}}function kl(e,l,t,a){if(a===null)e.removeAttribute(t);else{switch(typeof a){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(t);return}e.setAttributeNS(l,t,""+a)}}function pl(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function er(e){var l=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(l==="checkbox"||l==="radio")}function Lh(e,l,t){var a=Object.getOwnPropertyDescriptor(e.constructor.prototype,l);if(!e.hasOwnProperty(l)&&typeof a<"u"&&typeof a.get=="function"&&typeof a.set=="function"){var n=a.get,u=a.set;return Object.defineProperty(e,l,{configurable:!0,get:function(){return n.call(this)},set:function(c){t=""+c,u.call(this,c)}}),Object.defineProperty(e,l,{enumerable:a.enumerable}),{getValue:function(){return t},setValue:function(c){t=""+c},stopTracking:function(){e._valueTracker=null,delete e[l]}}}}function vu(e){if(!e._valueTracker){var l=er(e)?"checked":"value";e._valueTracker=Lh(e,l,""+e[l])}}function lr(e){if(!e)return!1;var l=e._valueTracker;if(!l)return!0;var t=l.getValue(),a="";return e&&(a=er(e)?e.checked?"true":"false":e.value),e=a,e!==t?(l.setValue(e),!0):!1}function Bn(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 Xh=/[\n"\\]/g;function jl(e){return e.replace(Xh,function(l){return"\\"+l.charCodeAt(0).toString(16)+" "})}function yu(e,l,t,a,n,u,c,r){e.name="",c!=null&&typeof c!="function"&&typeof c!="symbol"&&typeof c!="boolean"?e.type=c:e.removeAttribute("type"),l!=null?c==="number"?(l===0&&e.value===""||e.value!=l)&&(e.value=""+pl(l)):e.value!==""+pl(l)&&(e.value=""+pl(l)):c!=="submit"&&c!=="reset"||e.removeAttribute("value"),l!=null?gu(e,c,pl(l)):t!=null?gu(e,c,pl(t)):a!=null&&e.removeAttribute("value"),n==null&&u!=null&&(e.defaultChecked=!!u),n!=null&&(e.checked=n&&typeof n!="function"&&typeof n!="symbol"),r!=null&&typeof r!="function"&&typeof r!="symbol"&&typeof r!="boolean"?e.name=""+pl(r):e.removeAttribute("name")}function tr(e,l,t,a,n,u,c,r){if(u!=null&&typeof u!="function"&&typeof u!="symbol"&&typeof u!="boolean"&&(e.type=u),l!=null||t!=null){if(!(u!=="submit"&&u!=="reset"||l!=null)){vu(e);return}t=t!=null?""+pl(t):"",l=l!=null?""+pl(l):t,r||l===e.value||(e.value=l),e.defaultValue=l}a=a??n,a=typeof a!="function"&&typeof a!="symbol"&&!!a,e.checked=r?e.checked:!!a,e.defaultChecked=!!a,c!=null&&typeof c!="function"&&typeof c!="symbol"&&typeof c!="boolean"&&(e.name=c),vu(e)}function gu(e,l,t){l==="number"&&Bn(e.ownerDocument)===e||e.defaultValue===""+t||(e.defaultValue=""+t)}function Ft(e,l,t,a){if(e=e.options,l){l={};for(var n=0;n<t.length;n++)l["$"+t[n]]=!0;for(t=0;t<e.length;t++)n=l.hasOwnProperty("$"+e[t].value),e[t].selected!==n&&(e[t].selected=n),n&&a&&(e[t].defaultSelected=!0)}else{for(t=""+pl(t),l=null,n=0;n<e.length;n++){if(e[n].value===t){e[n].selected=!0,a&&(e[n].defaultSelected=!0);return}l!==null||e[n].disabled||(l=e[n])}l!==null&&(l.selected=!0)}}function ar(e,l,t){if(l!=null&&(l=""+pl(l),l!==e.value&&(e.value=l),t==null)){e.defaultValue!==l&&(e.defaultValue=l);return}e.defaultValue=t!=null?""+pl(t):""}function nr(e,l,t,a){if(l==null){if(a!=null){if(t!=null)throw Error(f(92));if(R(a)){if(1<a.length)throw Error(f(93));a=a[0]}t=a}t==null&&(t=""),l=t}t=pl(l),e.defaultValue=t,a=e.textContent,a===t&&a!==""&&a!==null&&(e.value=a),vu(e)}function It(e,l){if(l){var t=e.firstChild;if(t&&t===e.lastChild&&t.nodeType===3){t.nodeValue=l;return}}e.textContent=l}var Qh=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 ir(e,l,t){var a=l.indexOf("--")===0;t==null||typeof t=="boolean"||t===""?a?e.setProperty(l,""):l==="float"?e.cssFloat="":e[l]="":a?e.setProperty(l,t):typeof t!="number"||t===0||Qh.has(l)?l==="float"?e.cssFloat=t:e[l]=(""+t).trim():e[l]=t+"px"}function ur(e,l,t){if(l!=null&&typeof l!="object")throw Error(f(62));if(e=e.style,t!=null){for(var a in t)!t.hasOwnProperty(a)||l!=null&&l.hasOwnProperty(a)||(a.indexOf("--")===0?e.setProperty(a,""):a==="float"?e.cssFloat="":e[a]="");for(var n in l)a=l[n],l.hasOwnProperty(n)&&t[n]!==a&&ir(e,n,a)}else for(var u in l)l.hasOwnProperty(u)&&ir(e,u,l[u])}function pu(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 Zh=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"]]),Kh=/^[\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 Yn(e){return Kh.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}function ql(){}var ju=null;function bu(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Pt=null,ea=null;function cr(e){var l=Jt(e);if(l&&(e=l.stateNode)){var t=e[ll]||null;e:switch(e=l.stateNode,l.type){case"input":if(yu(e,t.value,t.defaultValue,t.defaultValue,t.checked,t.defaultChecked,t.type,t.name),l=t.name,t.type==="radio"&&l!=null){for(t=e;t.parentNode;)t=t.parentNode;for(t=t.querySelectorAll('input[name="'+jl(""+l)+'"][type="radio"]'),l=0;l<t.length;l++){var a=t[l];if(a!==e&&a.form===e.form){var n=a[ll]||null;if(!n)throw Error(f(90));yu(a,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name)}}for(l=0;l<t.length;l++)a=t[l],a.form===e.form&&lr(a)}break e;case"textarea":ar(e,t.value,t.defaultValue);break e;case"select":l=t.value,l!=null&&Ft(e,!!t.multiple,l,!1)}}}var xu=!1;function sr(e,l,t){if(xu)return e(l,t);xu=!0;try{var a=e(l);return a}finally{if(xu=!1,(Pt!==null||ea!==null)&&(Ai(),Pt&&(l=Pt,e=ea,ea=Pt=null,cr(l),e)))for(l=0;l<e.length;l++)cr(e[l])}}function Ya(e,l){var t=e.stateNode;if(t===null)return null;var a=t[ll]||null;if(a===null)return null;t=a[l];e:switch(l){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(t&&typeof t!="function")throw Error(f(231,l,typeof t));return t}var Bl=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Su=!1;if(Bl)try{var wa={};Object.defineProperty(wa,"passive",{get:function(){Su=!0}}),window.addEventListener("test",wa,wa),window.removeEventListener("test",wa,wa)}catch{Su=!1}var nt=null,Nu=null,wn=null;function rr(){if(wn)return wn;var e,l=Nu,t=l.length,a,n="value"in nt?nt.value:nt.textContent,u=n.length;for(e=0;e<t&&l[e]===n[e];e++);var c=t-e;for(a=1;a<=c&&l[t-a]===n[u-a];a++);return wn=n.slice(e,1<a?1-a:void 0)}function Gn(e){var l=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&l===13&&(e=13)):e=l,e===10&&(e=13),32<=e||e===13?e:0}function Ln(){return!0}function dr(){return!1}function tl(e){function l(t,a,n,u,c){this._reactName=t,this._targetInst=n,this.type=a,this.nativeEvent=u,this.target=c,this.currentTarget=null;for(var r in e)e.hasOwnProperty(r)&&(t=e[r],this[r]=t?t(u):u[r]);return this.isDefaultPrevented=(u.defaultPrevented!=null?u.defaultPrevented:u.returnValue===!1)?Ln:dr,this.isPropagationStopped=dr,this}return k(l.prototype,{preventDefault:function(){this.defaultPrevented=!0;var t=this.nativeEvent;t&&(t.preventDefault?t.preventDefault():typeof t.returnValue!="unknown"&&(t.returnValue=!1),this.isDefaultPrevented=Ln)},stopPropagation:function(){var t=this.nativeEvent;t&&(t.stopPropagation?t.stopPropagation():typeof t.cancelBubble!="unknown"&&(t.cancelBubble=!0),this.isPropagationStopped=Ln)},persist:function(){},isPersistent:Ln}),l}var Ct={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Xn=tl(Ct),Ga=k({},Ct,{view:0,detail:0}),Vh=tl(Ga),Eu,Tu,La,Qn=k({},Ga,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:zu,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!==La&&(La&&e.type==="mousemove"?(Eu=e.screenX-La.screenX,Tu=e.screenY-La.screenY):Tu=Eu=0,La=e),Eu)},movementY:function(e){return"movementY"in e?e.movementY:Tu}}),fr=tl(Qn),Jh=k({},Qn,{dataTransfer:0}),$h=tl(Jh),Wh=k({},Ga,{relatedTarget:0}),Au=tl(Wh),Fh=k({},Ct,{animationName:0,elapsedTime:0,pseudoElement:0}),Ih=tl(Fh),Ph=k({},Ct,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),em=tl(Ph),lm=k({},Ct,{data:0}),or=tl(lm),tm={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},am={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"},nm={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function im(e){var l=this.nativeEvent;return l.getModifierState?l.getModifierState(e):(e=nm[e])?!!l[e]:!1}function zu(){return im}var um=k({},Ga,{key:function(e){if(e.key){var l=tm[e.key]||e.key;if(l!=="Unidentified")return l}return e.type==="keypress"?(e=Gn(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?am[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:zu,charCode:function(e){return e.type==="keypress"?Gn(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Gn(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),cm=tl(um),sm=k({},Qn,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),hr=tl(sm),rm=k({},Ga,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:zu}),dm=tl(rm),fm=k({},Ct,{propertyName:0,elapsedTime:0,pseudoElement:0}),om=tl(fm),hm=k({},Qn,{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}),mm=tl(hm),vm=k({},Ct,{newState:0,oldState:0}),ym=tl(vm),gm=[9,13,27,32],_u=Bl&&"CompositionEvent"in window,Xa=null;Bl&&"documentMode"in document&&(Xa=document.documentMode);var pm=Bl&&"TextEvent"in window&&!Xa,mr=Bl&&(!_u||Xa&&8<Xa&&11>=Xa),vr=" ",yr=!1;function gr(e,l){switch(e){case"keyup":return gm.indexOf(l.keyCode)!==-1;case"keydown":return l.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function pr(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var la=!1;function jm(e,l){switch(e){case"compositionend":return pr(l);case"keypress":return l.which!==32?null:(yr=!0,vr);case"textInput":return e=l.data,e===vr&&yr?null:e;default:return null}}function bm(e,l){if(la)return e==="compositionend"||!_u&&gr(e,l)?(e=rr(),wn=Nu=nt=null,la=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(l.ctrlKey||l.altKey||l.metaKey)||l.ctrlKey&&l.altKey){if(l.char&&1<l.char.length)return l.char;if(l.which)return String.fromCharCode(l.which)}return null;case"compositionend":return mr&&l.locale!=="ko"?null:l.data;default:return null}}var xm={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 jr(e){var l=e&&e.nodeName&&e.nodeName.toLowerCase();return l==="input"?!!xm[e.type]:l==="textarea"}function br(e,l,t,a){Pt?ea?ea.push(a):ea=[a]:Pt=a,l=Di(l,"onChange"),0<l.length&&(t=new Xn("onChange","change",null,t,a),e.push({event:t,listeners:l}))}var Qa=null,Za=null;function Sm(e){ao(e,0)}function Zn(e){var l=Ba(e);if(lr(l))return e}function xr(e,l){if(e==="change")return l}var Sr=!1;if(Bl){var Mu;if(Bl){var Cu="oninput"in document;if(!Cu){var Nr=document.createElement("div");Nr.setAttribute("oninput","return;"),Cu=typeof Nr.oninput=="function"}Mu=Cu}else Mu=!1;Sr=Mu&&(!document.documentMode||9<document.documentMode)}function Er(){Qa&&(Qa.detachEvent("onpropertychange",Tr),Za=Qa=null)}function Tr(e){if(e.propertyName==="value"&&Zn(Za)){var l=[];br(l,Za,e,bu(e)),sr(Sm,l)}}function Nm(e,l,t){e==="focusin"?(Er(),Qa=l,Za=t,Qa.attachEvent("onpropertychange",Tr)):e==="focusout"&&Er()}function Em(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Zn(Za)}function Tm(e,l){if(e==="click")return Zn(l)}function Am(e,l){if(e==="input"||e==="change")return Zn(l)}function zm(e,l){return e===l&&(e!==0||1/e===1/l)||e!==e&&l!==l}var fl=typeof Object.is=="function"?Object.is:zm;function Ka(e,l){if(fl(e,l))return!0;if(typeof e!="object"||e===null||typeof l!="object"||l===null)return!1;var t=Object.keys(e),a=Object.keys(l);if(t.length!==a.length)return!1;for(a=0;a<t.length;a++){var n=t[a];if(!cu.call(l,n)||!fl(e[n],l[n]))return!1}return!0}function Ar(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function zr(e,l){var t=Ar(e);e=0;for(var a;t;){if(t.nodeType===3){if(a=e+t.textContent.length,e<=l&&a>=l)return{node:t,offset:l-e};e=a}e:{for(;t;){if(t.nextSibling){t=t.nextSibling;break e}t=t.parentNode}t=void 0}t=Ar(t)}}function _r(e,l){return e&&l?e===l?!0:e&&e.nodeType===3?!1:l&&l.nodeType===3?_r(e,l.parentNode):"contains"in e?e.contains(l):e.compareDocumentPosition?!!(e.compareDocumentPosition(l)&16):!1:!1}function Mr(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var l=Bn(e.document);l instanceof e.HTMLIFrameElement;){try{var t=typeof l.contentWindow.location.href=="string"}catch{t=!1}if(t)e=l.contentWindow;else break;l=Bn(e.document)}return l}function Ou(e){var l=e&&e.nodeName&&e.nodeName.toLowerCase();return l&&(l==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||l==="textarea"||e.contentEditable==="true")}var _m=Bl&&"documentMode"in document&&11>=document.documentMode,ta=null,Uu=null,Va=null,Du=!1;function Cr(e,l,t){var a=t.window===t?t.document:t.nodeType===9?t:t.ownerDocument;Du||ta==null||ta!==Bn(a)||(a=ta,"selectionStart"in a&&Ou(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}),Va&&Ka(Va,a)||(Va=a,a=Di(Uu,"onSelect"),0<a.length&&(l=new Xn("onSelect","select",null,l,t),e.push({event:l,listeners:a}),l.target=ta)))}function Ot(e,l){var t={};return t[e.toLowerCase()]=l.toLowerCase(),t["Webkit"+e]="webkit"+l,t["Moz"+e]="moz"+l,t}var aa={animationend:Ot("Animation","AnimationEnd"),animationiteration:Ot("Animation","AnimationIteration"),animationstart:Ot("Animation","AnimationStart"),transitionrun:Ot("Transition","TransitionRun"),transitionstart:Ot("Transition","TransitionStart"),transitioncancel:Ot("Transition","TransitionCancel"),transitionend:Ot("Transition","TransitionEnd")},Ru={},Or={};Bl&&(Or=document.createElement("div").style,"AnimationEvent"in window||(delete aa.animationend.animation,delete aa.animationiteration.animation,delete aa.animationstart.animation),"TransitionEvent"in window||delete aa.transitionend.transition);function Ut(e){if(Ru[e])return Ru[e];if(!aa[e])return e;var l=aa[e],t;for(t in l)if(l.hasOwnProperty(t)&&t in Or)return Ru[e]=l[t];return e}var Ur=Ut("animationend"),Dr=Ut("animationiteration"),Rr=Ut("animationstart"),Mm=Ut("transitionrun"),Cm=Ut("transitionstart"),Om=Ut("transitioncancel"),Hr=Ut("transitionend"),kr=new Map,Hu="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(" ");Hu.push("scrollEnd");function Ml(e,l){kr.set(e,l),Mt(l,[e])}var Kn=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var l=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(l))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)},bl=[],na=0,ku=0;function Vn(){for(var e=na,l=ku=na=0;l<e;){var t=bl[l];bl[l++]=null;var a=bl[l];bl[l++]=null;var n=bl[l];bl[l++]=null;var u=bl[l];if(bl[l++]=null,a!==null&&n!==null){var c=a.pending;c===null?n.next=n:(n.next=c.next,c.next=n),a.pending=n}u!==0&&qr(t,n,u)}}function Jn(e,l,t,a){bl[na++]=e,bl[na++]=l,bl[na++]=t,bl[na++]=a,ku|=a,e.lanes|=a,e=e.alternate,e!==null&&(e.lanes|=a)}function qu(e,l,t,a){return Jn(e,l,t,a),$n(e)}function Dt(e,l){return Jn(e,null,null,l),$n(e)}function qr(e,l,t){e.lanes|=t;var a=e.alternate;a!==null&&(a.lanes|=t);for(var n=!1,u=e.return;u!==null;)u.childLanes|=t,a=u.alternate,a!==null&&(a.childLanes|=t),u.tag===22&&(e=u.stateNode,e===null||e._visibility&1||(n=!0)),e=u,u=u.return;return e.tag===3?(u=e.stateNode,n&&l!==null&&(n=31-dl(t),e=u.hiddenUpdates,a=e[n],a===null?e[n]=[l]:a.push(l),l.lane=t|536870912),u):null}function $n(e){if(50<yn)throw yn=0,Kc=null,Error(f(185));for(var l=e.return;l!==null;)e=l,l=e.return;return e.tag===3?e.stateNode:null}var ia={};function Um(e,l,t,a){this.tag=e,this.key=t,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=l,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 ol(e,l,t,a){return new Um(e,l,t,a)}function Bu(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Yl(e,l){var t=e.alternate;return t===null?(t=ol(e.tag,l,e.key,e.mode),t.elementType=e.elementType,t.type=e.type,t.stateNode=e.stateNode,t.alternate=e,e.alternate=t):(t.pendingProps=l,t.type=e.type,t.flags=0,t.subtreeFlags=0,t.deletions=null),t.flags=e.flags&65011712,t.childLanes=e.childLanes,t.lanes=e.lanes,t.child=e.child,t.memoizedProps=e.memoizedProps,t.memoizedState=e.memoizedState,t.updateQueue=e.updateQueue,l=e.dependencies,t.dependencies=l===null?null:{lanes:l.lanes,firstContext:l.firstContext},t.sibling=e.sibling,t.index=e.index,t.ref=e.ref,t.refCleanup=e.refCleanup,t}function Br(e,l){e.flags&=65011714;var t=e.alternate;return t===null?(e.childLanes=0,e.lanes=l,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=t.childLanes,e.lanes=t.lanes,e.child=t.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=t.memoizedProps,e.memoizedState=t.memoizedState,e.updateQueue=t.updateQueue,e.type=t.type,l=t.dependencies,e.dependencies=l===null?null:{lanes:l.lanes,firstContext:l.firstContext}),e}function Wn(e,l,t,a,n,u){var c=0;if(a=e,typeof e=="function")Bu(e)&&(c=1);else if(typeof e=="string")c=qv(e,t,V.current)?26:e==="html"||e==="head"||e==="body"?27:5;else e:switch(e){case se:return e=ol(31,t,l,n),e.elementType=se,e.lanes=u,e;case ee:return Rt(t.children,n,u,l);case ce:c=8,n|=24;break;case G:return e=ol(12,t,l,n|2),e.elementType=G,e.lanes=u,e;case ve:return e=ol(13,t,l,n),e.elementType=ve,e.lanes=u,e;case F:return e=ol(19,t,l,n),e.elementType=F,e.lanes=u,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case P:c=10;break e;case L:c=9;break e;case le:c=11;break e;case K:c=14;break e;case q:c=16,a=null;break e}c=29,t=Error(f(130,e===null?"null":typeof e,"")),a=null}return l=ol(c,t,l,n),l.elementType=e,l.type=a,l.lanes=u,l}function Rt(e,l,t,a){return e=ol(7,e,a,l),e.lanes=t,e}function Yu(e,l,t){return e=ol(6,e,null,l),e.lanes=t,e}function Yr(e){var l=ol(18,null,null,0);return l.stateNode=e,l}function wu(e,l,t){return l=ol(4,e.children!==null?e.children:[],e.key,l),l.lanes=t,l.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},l}var wr=new WeakMap;function xl(e,l){if(typeof e=="object"&&e!==null){var t=wr.get(e);return t!==void 0?t:(l={value:e,source:l,stack:Ys(l)},wr.set(e,l),l)}return{value:e,source:l,stack:Ys(l)}}var ua=[],ca=0,Fn=null,Ja=0,Sl=[],Nl=0,it=null,Ul=1,Dl="";function wl(e,l){ua[ca++]=Ja,ua[ca++]=Fn,Fn=e,Ja=l}function Gr(e,l,t){Sl[Nl++]=Ul,Sl[Nl++]=Dl,Sl[Nl++]=it,it=e;var a=Ul;e=Dl;var n=32-dl(a)-1;a&=~(1<<n),t+=1;var u=32-dl(l)+n;if(30<u){var c=n-n%5;u=(a&(1<<c)-1).toString(32),a>>=c,n-=c,Ul=1<<32-dl(l)+n|t<<n|a,Dl=u+e}else Ul=1<<u|t<<n|a,Dl=e}function Gu(e){e.return!==null&&(wl(e,1),Gr(e,1,0))}function Lu(e){for(;e===Fn;)Fn=ua[--ca],ua[ca]=null,Ja=ua[--ca],ua[ca]=null;for(;e===it;)it=Sl[--Nl],Sl[Nl]=null,Dl=Sl[--Nl],Sl[Nl]=null,Ul=Sl[--Nl],Sl[Nl]=null}function Lr(e,l){Sl[Nl++]=Ul,Sl[Nl++]=Dl,Sl[Nl++]=it,Ul=l.id,Dl=l.overflow,it=e}var Ke=null,ze=null,me=!1,ut=null,El=!1,Xu=Error(f(519));function ct(e){var l=Error(f(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw $a(xl(l,e)),Xu}function Xr(e){var l=e.stateNode,t=e.type,a=e.memoizedProps;switch(l[Ze]=e,l[ll]=a,t){case"dialog":fe("cancel",l),fe("close",l);break;case"iframe":case"object":case"embed":fe("load",l);break;case"video":case"audio":for(t=0;t<pn.length;t++)fe(pn[t],l);break;case"source":fe("error",l);break;case"img":case"image":case"link":fe("error",l),fe("load",l);break;case"details":fe("toggle",l);break;case"input":fe("invalid",l),tr(l,a.value,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name,!0);break;case"select":fe("invalid",l);break;case"textarea":fe("invalid",l),nr(l,a.value,a.defaultValue,a.children)}t=a.children,typeof t!="string"&&typeof t!="number"&&typeof t!="bigint"||l.textContent===""+t||a.suppressHydrationWarning===!0||co(l.textContent,t)?(a.popover!=null&&(fe("beforetoggle",l),fe("toggle",l)),a.onScroll!=null&&fe("scroll",l),a.onScrollEnd!=null&&fe("scrollend",l),a.onClick!=null&&(l.onclick=ql),l=!0):l=!1,l||ct(e,!0)}function Qr(e){for(Ke=e.return;Ke;)switch(Ke.tag){case 5:case 31:case 13:El=!1;return;case 27:case 3:El=!0;return;default:Ke=Ke.return}}function sa(e){if(e!==Ke)return!1;if(!me)return Qr(e),me=!0,!1;var l=e.tag,t;if((t=l!==3&&l!==27)&&((t=l===5)&&(t=e.type,t=!(t!=="form"&&t!=="button")||cs(e.type,e.memoizedProps)),t=!t),t&&ze&&ct(e),Qr(e),l===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(f(317));ze=go(e)}else if(l===31){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(f(317));ze=go(e)}else l===27?(l=ze,xt(e.type)?(e=os,os=null,ze=e):ze=l):ze=Ke?Al(e.stateNode.nextSibling):null;return!0}function Ht(){ze=Ke=null,me=!1}function Qu(){var e=ut;return e!==null&&(ul===null?ul=e:ul.push.apply(ul,e),ut=null),e}function $a(e){ut===null?ut=[e]:ut.push(e)}var Zu=v(null),kt=null,Gl=null;function st(e,l,t){X(Zu,l._currentValue),l._currentValue=t}function Ll(e){e._currentValue=Zu.current,D(Zu)}function Ku(e,l,t){for(;e!==null;){var a=e.alternate;if((e.childLanes&l)!==l?(e.childLanes|=l,a!==null&&(a.childLanes|=l)):a!==null&&(a.childLanes&l)!==l&&(a.childLanes|=l),e===t)break;e=e.return}}function Vu(e,l,t,a){var n=e.child;for(n!==null&&(n.return=e);n!==null;){var u=n.dependencies;if(u!==null){var c=n.child;u=u.firstContext;e:for(;u!==null;){var r=u;u=n;for(var h=0;h<l.length;h++)if(r.context===l[h]){u.lanes|=t,r=u.alternate,r!==null&&(r.lanes|=t),Ku(u.return,t,e),a||(c=null);break e}u=r.next}}else if(n.tag===18){if(c=n.return,c===null)throw Error(f(341));c.lanes|=t,u=c.alternate,u!==null&&(u.lanes|=t),Ku(c,t,e),c=null}else c=n.child;if(c!==null)c.return=n;else for(c=n;c!==null;){if(c===e){c=null;break}if(n=c.sibling,n!==null){n.return=c.return,c=n;break}c=c.return}n=c}}function ra(e,l,t,a){e=null;for(var n=l,u=!1;n!==null;){if(!u){if((n.flags&524288)!==0)u=!0;else if((n.flags&262144)!==0)break}if(n.tag===10){var c=n.alternate;if(c===null)throw Error(f(387));if(c=c.memoizedProps,c!==null){var r=n.type;fl(n.pendingProps.value,c.value)||(e!==null?e.push(r):e=[r])}}else if(n===je.current){if(c=n.alternate,c===null)throw Error(f(387));c.memoizedState.memoizedState!==n.memoizedState.memoizedState&&(e!==null?e.push(Nn):e=[Nn])}n=n.return}e!==null&&Vu(l,e,t,a),l.flags|=262144}function In(e){for(e=e.firstContext;e!==null;){if(!fl(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function qt(e){kt=e,Gl=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function Ve(e){return Zr(kt,e)}function Pn(e,l){return kt===null&&qt(e),Zr(e,l)}function Zr(e,l){var t=l._currentValue;if(l={context:l,memoizedValue:t,next:null},Gl===null){if(e===null)throw Error(f(308));Gl=l,e.dependencies={lanes:0,firstContext:l},e.flags|=524288}else Gl=Gl.next=l;return t}var Dm=typeof AbortController<"u"?AbortController:function(){var e=[],l=this.signal={aborted:!1,addEventListener:function(t,a){e.push(a)}};this.abort=function(){l.aborted=!0,e.forEach(function(t){return t()})}},Rm=s.unstable_scheduleCallback,Hm=s.unstable_NormalPriority,ke={$$typeof:P,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function Ju(){return{controller:new Dm,data:new Map,refCount:0}}function Wa(e){e.refCount--,e.refCount===0&&Rm(Hm,function(){e.controller.abort()})}var Fa=null,$u=0,da=0,fa=null;function km(e,l){if(Fa===null){var t=Fa=[];$u=0,da=Ic(),fa={status:"pending",value:void 0,then:function(a){t.push(a)}}}return $u++,l.then(Kr,Kr),l}function Kr(){if(--$u===0&&Fa!==null){fa!==null&&(fa.status="fulfilled");var e=Fa;Fa=null,da=0,fa=null;for(var l=0;l<e.length;l++)(0,e[l])()}}function qm(e,l){var t=[],a={status:"pending",value:null,reason:null,then:function(n){t.push(n)}};return e.then(function(){a.status="fulfilled",a.value=l;for(var n=0;n<t.length;n++)(0,t[n])(l)},function(n){for(a.status="rejected",a.reason=n,n=0;n<t.length;n++)(0,t[n])(void 0)}),a}var Vr=z.S;z.S=function(e,l){Of=sl(),typeof l=="object"&&l!==null&&typeof l.then=="function"&&km(e,l),Vr!==null&&Vr(e,l)};var Bt=v(null);function Wu(){var e=Bt.current;return e!==null?e:Ae.pooledCache}function ei(e,l){l===null?X(Bt,Bt.current):X(Bt,l.pool)}function Jr(){var e=Wu();return e===null?null:{parent:ke._currentValue,pool:e}}var oa=Error(f(460)),Fu=Error(f(474)),li=Error(f(542)),ti={then:function(){}};function $r(e){return e=e.status,e==="fulfilled"||e==="rejected"}function Wr(e,l,t){switch(t=e[t],t===void 0?e.push(l):t!==l&&(l.then(ql,ql),l=t),l.status){case"fulfilled":return l.value;case"rejected":throw e=l.reason,Ir(e),e;default:if(typeof l.status=="string")l.then(ql,ql);else{if(e=Ae,e!==null&&100<e.shellSuspendCounter)throw Error(f(482));e=l,e.status="pending",e.then(function(a){if(l.status==="pending"){var n=l;n.status="fulfilled",n.value=a}},function(a){if(l.status==="pending"){var n=l;n.status="rejected",n.reason=a}})}switch(l.status){case"fulfilled":return l.value;case"rejected":throw e=l.reason,Ir(e),e}throw wt=l,oa}}function Yt(e){try{var l=e._init;return l(e._payload)}catch(t){throw t!==null&&typeof t=="object"&&typeof t.then=="function"?(wt=t,oa):t}}var wt=null;function Fr(){if(wt===null)throw Error(f(459));var e=wt;return wt=null,e}function Ir(e){if(e===oa||e===li)throw Error(f(483))}var ha=null,Ia=0;function ai(e){var l=Ia;return Ia+=1,ha===null&&(ha=[]),Wr(ha,e,l)}function Pa(e,l){l=l.props.ref,e.ref=l!==void 0?l:null}function ni(e,l){throw l.$$typeof===Q?Error(f(525)):(e=Object.prototype.toString.call(l),Error(f(31,e==="[object Object]"?"object with keys {"+Object.keys(l).join(", ")+"}":e)))}function Pr(e){function l(b,y){if(e){var S=b.deletions;S===null?(b.deletions=[y],b.flags|=16):S.push(y)}}function t(b,y){if(!e)return null;for(;y!==null;)l(b,y),y=y.sibling;return null}function a(b){for(var y=new Map;b!==null;)b.key!==null?y.set(b.key,b):y.set(b.index,b),b=b.sibling;return y}function n(b,y){return b=Yl(b,y),b.index=0,b.sibling=null,b}function u(b,y,S){return b.index=S,e?(S=b.alternate,S!==null?(S=S.index,S<y?(b.flags|=67108866,y):S):(b.flags|=67108866,y)):(b.flags|=1048576,y)}function c(b){return e&&b.alternate===null&&(b.flags|=67108866),b}function r(b,y,S,O){return y===null||y.tag!==6?(y=Yu(S,b.mode,O),y.return=b,y):(y=n(y,S),y.return=b,y)}function h(b,y,S,O){var W=S.type;return W===ee?M(b,y,S.props.children,O,S.key):y!==null&&(y.elementType===W||typeof W=="object"&&W!==null&&W.$$typeof===q&&Yt(W)===y.type)?(y=n(y,S.props),Pa(y,S),y.return=b,y):(y=Wn(S.type,S.key,S.props,null,b.mode,O),Pa(y,S),y.return=b,y)}function N(b,y,S,O){return y===null||y.tag!==4||y.stateNode.containerInfo!==S.containerInfo||y.stateNode.implementation!==S.implementation?(y=wu(S,b.mode,O),y.return=b,y):(y=n(y,S.children||[]),y.return=b,y)}function M(b,y,S,O,W){return y===null||y.tag!==7?(y=Rt(S,b.mode,O,W),y.return=b,y):(y=n(y,S),y.return=b,y)}function U(b,y,S){if(typeof y=="string"&&y!==""||typeof y=="number"||typeof y=="bigint")return y=Yu(""+y,b.mode,S),y.return=b,y;if(typeof y=="object"&&y!==null){switch(y.$$typeof){case C:return S=Wn(y.type,y.key,y.props,null,b.mode,S),Pa(S,y),S.return=b,S;case w:return y=wu(y,b.mode,S),y.return=b,y;case q:return y=Yt(y),U(b,y,S)}if(R(y)||Te(y))return y=Rt(y,b.mode,S,null),y.return=b,y;if(typeof y.then=="function")return U(b,ai(y),S);if(y.$$typeof===P)return U(b,Pn(b,y),S);ni(b,y)}return null}function A(b,y,S,O){var W=y!==null?y.key:null;if(typeof S=="string"&&S!==""||typeof S=="number"||typeof S=="bigint")return W!==null?null:r(b,y,""+S,O);if(typeof S=="object"&&S!==null){switch(S.$$typeof){case C:return S.key===W?h(b,y,S,O):null;case w:return S.key===W?N(b,y,S,O):null;case q:return S=Yt(S),A(b,y,S,O)}if(R(S)||Te(S))return W!==null?null:M(b,y,S,O,null);if(typeof S.then=="function")return A(b,y,ai(S),O);if(S.$$typeof===P)return A(b,y,Pn(b,S),O);ni(b,S)}return null}function _(b,y,S,O,W){if(typeof O=="string"&&O!==""||typeof O=="number"||typeof O=="bigint")return b=b.get(S)||null,r(y,b,""+O,W);if(typeof O=="object"&&O!==null){switch(O.$$typeof){case C:return b=b.get(O.key===null?S:O.key)||null,h(y,b,O,W);case w:return b=b.get(O.key===null?S:O.key)||null,N(y,b,O,W);case q:return O=Yt(O),_(b,y,S,O,W)}if(R(O)||Te(O))return b=b.get(S)||null,M(y,b,O,W,null);if(typeof O.then=="function")return _(b,y,S,ai(O),W);if(O.$$typeof===P)return _(b,y,S,Pn(y,O),W);ni(y,O)}return null}function Z(b,y,S,O){for(var W=null,ye=null,J=y,ue=y=0,he=null;J!==null&&ue<S.length;ue++){J.index>ue?(he=J,J=null):he=J.sibling;var ge=A(b,J,S[ue],O);if(ge===null){J===null&&(J=he);break}e&&J&&ge.alternate===null&&l(b,J),y=u(ge,y,ue),ye===null?W=ge:ye.sibling=ge,ye=ge,J=he}if(ue===S.length)return t(b,J),me&&wl(b,ue),W;if(J===null){for(;ue<S.length;ue++)J=U(b,S[ue],O),J!==null&&(y=u(J,y,ue),ye===null?W=J:ye.sibling=J,ye=J);return me&&wl(b,ue),W}for(J=a(J);ue<S.length;ue++)he=_(J,b,ue,S[ue],O),he!==null&&(e&&he.alternate!==null&&J.delete(he.key===null?ue:he.key),y=u(he,y,ue),ye===null?W=he:ye.sibling=he,ye=he);return e&&J.forEach(function(At){return l(b,At)}),me&&wl(b,ue),W}function I(b,y,S,O){if(S==null)throw Error(f(151));for(var W=null,ye=null,J=y,ue=y=0,he=null,ge=S.next();J!==null&&!ge.done;ue++,ge=S.next()){J.index>ue?(he=J,J=null):he=J.sibling;var At=A(b,J,ge.value,O);if(At===null){J===null&&(J=he);break}e&&J&&At.alternate===null&&l(b,J),y=u(At,y,ue),ye===null?W=At:ye.sibling=At,ye=At,J=he}if(ge.done)return t(b,J),me&&wl(b,ue),W;if(J===null){for(;!ge.done;ue++,ge=S.next())ge=U(b,ge.value,O),ge!==null&&(y=u(ge,y,ue),ye===null?W=ge:ye.sibling=ge,ye=ge);return me&&wl(b,ue),W}for(J=a(J);!ge.done;ue++,ge=S.next())ge=_(J,b,ue,ge.value,O),ge!==null&&(e&&ge.alternate!==null&&J.delete(ge.key===null?ue:ge.key),y=u(ge,y,ue),ye===null?W=ge:ye.sibling=ge,ye=ge);return e&&J.forEach(function(Jv){return l(b,Jv)}),me&&wl(b,ue),W}function Ee(b,y,S,O){if(typeof S=="object"&&S!==null&&S.type===ee&&S.key===null&&(S=S.props.children),typeof S=="object"&&S!==null){switch(S.$$typeof){case C:e:{for(var W=S.key;y!==null;){if(y.key===W){if(W=S.type,W===ee){if(y.tag===7){t(b,y.sibling),O=n(y,S.props.children),O.return=b,b=O;break e}}else if(y.elementType===W||typeof W=="object"&&W!==null&&W.$$typeof===q&&Yt(W)===y.type){t(b,y.sibling),O=n(y,S.props),Pa(O,S),O.return=b,b=O;break e}t(b,y);break}else l(b,y);y=y.sibling}S.type===ee?(O=Rt(S.props.children,b.mode,O,S.key),O.return=b,b=O):(O=Wn(S.type,S.key,S.props,null,b.mode,O),Pa(O,S),O.return=b,b=O)}return c(b);case w:e:{for(W=S.key;y!==null;){if(y.key===W)if(y.tag===4&&y.stateNode.containerInfo===S.containerInfo&&y.stateNode.implementation===S.implementation){t(b,y.sibling),O=n(y,S.children||[]),O.return=b,b=O;break e}else{t(b,y);break}else l(b,y);y=y.sibling}O=wu(S,b.mode,O),O.return=b,b=O}return c(b);case q:return S=Yt(S),Ee(b,y,S,O)}if(R(S))return Z(b,y,S,O);if(Te(S)){if(W=Te(S),typeof W!="function")throw Error(f(150));return S=W.call(S),I(b,y,S,O)}if(typeof S.then=="function")return Ee(b,y,ai(S),O);if(S.$$typeof===P)return Ee(b,y,Pn(b,S),O);ni(b,S)}return typeof S=="string"&&S!==""||typeof S=="number"||typeof S=="bigint"?(S=""+S,y!==null&&y.tag===6?(t(b,y.sibling),O=n(y,S),O.return=b,b=O):(t(b,y),O=Yu(S,b.mode,O),O.return=b,b=O),c(b)):t(b,y)}return function(b,y,S,O){try{Ia=0;var W=Ee(b,y,S,O);return ha=null,W}catch(J){if(J===oa||J===li)throw J;var ye=ol(29,J,null,b.mode);return ye.lanes=O,ye.return=b,ye}}}var Gt=Pr(!0),ed=Pr(!1),rt=!1;function Iu(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Pu(e,l){e=e.updateQueue,l.updateQueue===e&&(l.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function dt(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function ft(e,l,t){var a=e.updateQueue;if(a===null)return null;if(a=a.shared,(pe&2)!==0){var n=a.pending;return n===null?l.next=l:(l.next=n.next,n.next=l),a.pending=l,l=$n(e),qr(e,null,t),l}return Jn(e,a,l,t),$n(e)}function en(e,l,t){if(l=l.updateQueue,l!==null&&(l=l.shared,(t&4194048)!==0)){var a=l.lanes;a&=e.pendingLanes,t|=a,l.lanes=t,Zs(e,t)}}function ec(e,l){var t=e.updateQueue,a=e.alternate;if(a!==null&&(a=a.updateQueue,t===a)){var n=null,u=null;if(t=t.firstBaseUpdate,t!==null){do{var c={lane:t.lane,tag:t.tag,payload:t.payload,callback:null,next:null};u===null?n=u=c:u=u.next=c,t=t.next}while(t!==null);u===null?n=u=l:u=u.next=l}else n=u=l;t={baseState:a.baseState,firstBaseUpdate:n,lastBaseUpdate:u,shared:a.shared,callbacks:a.callbacks},e.updateQueue=t;return}e=t.lastBaseUpdate,e===null?t.firstBaseUpdate=l:e.next=l,t.lastBaseUpdate=l}var lc=!1;function ln(){if(lc){var e=fa;if(e!==null)throw e}}function tn(e,l,t,a){lc=!1;var n=e.updateQueue;rt=!1;var u=n.firstBaseUpdate,c=n.lastBaseUpdate,r=n.shared.pending;if(r!==null){n.shared.pending=null;var h=r,N=h.next;h.next=null,c===null?u=N:c.next=N,c=h;var M=e.alternate;M!==null&&(M=M.updateQueue,r=M.lastBaseUpdate,r!==c&&(r===null?M.firstBaseUpdate=N:r.next=N,M.lastBaseUpdate=h))}if(u!==null){var U=n.baseState;c=0,M=N=h=null,r=u;do{var A=r.lane&-536870913,_=A!==r.lane;if(_?(oe&A)===A:(a&A)===A){A!==0&&A===da&&(lc=!0),M!==null&&(M=M.next={lane:0,tag:r.tag,payload:r.payload,callback:null,next:null});e:{var Z=e,I=r;A=l;var Ee=t;switch(I.tag){case 1:if(Z=I.payload,typeof Z=="function"){U=Z.call(Ee,U,A);break e}U=Z;break e;case 3:Z.flags=Z.flags&-65537|128;case 0:if(Z=I.payload,A=typeof Z=="function"?Z.call(Ee,U,A):Z,A==null)break e;U=k({},U,A);break e;case 2:rt=!0}}A=r.callback,A!==null&&(e.flags|=64,_&&(e.flags|=8192),_=n.callbacks,_===null?n.callbacks=[A]:_.push(A))}else _={lane:A,tag:r.tag,payload:r.payload,callback:r.callback,next:null},M===null?(N=M=_,h=U):M=M.next=_,c|=A;if(r=r.next,r===null){if(r=n.shared.pending,r===null)break;_=r,r=_.next,_.next=null,n.lastBaseUpdate=_,n.shared.pending=null}}while(!0);M===null&&(h=U),n.baseState=h,n.firstBaseUpdate=N,n.lastBaseUpdate=M,u===null&&(n.shared.lanes=0),yt|=c,e.lanes=c,e.memoizedState=U}}function ld(e,l){if(typeof e!="function")throw Error(f(191,e));e.call(l)}function td(e,l){var t=e.callbacks;if(t!==null)for(e.callbacks=null,e=0;e<t.length;e++)ld(t[e],l)}var ma=v(null),ii=v(0);function ad(e,l){e=Fl,X(ii,e),X(ma,l),Fl=e|l.baseLanes}function tc(){X(ii,Fl),X(ma,ma.current)}function ac(){Fl=ii.current,D(ma),D(ii)}var hl=v(null),Tl=null;function ot(e){var l=e.alternate;X(Re,Re.current&1),X(hl,e),Tl===null&&(l===null||ma.current!==null||l.memoizedState!==null)&&(Tl=e)}function nc(e){X(Re,Re.current),X(hl,e),Tl===null&&(Tl=e)}function nd(e){e.tag===22?(X(Re,Re.current),X(hl,e),Tl===null&&(Tl=e)):ht()}function ht(){X(Re,Re.current),X(hl,hl.current)}function ml(e){D(hl),Tl===e&&(Tl=null),D(Re)}var Re=v(0);function ui(e){for(var l=e;l!==null;){if(l.tag===13){var t=l.memoizedState;if(t!==null&&(t=t.dehydrated,t===null||ds(t)||fs(t)))return l}else if(l.tag===19&&(l.memoizedProps.revealOrder==="forwards"||l.memoizedProps.revealOrder==="backwards"||l.memoizedProps.revealOrder==="unstable_legacy-backwards"||l.memoizedProps.revealOrder==="together")){if((l.flags&128)!==0)return l}else if(l.child!==null){l.child.return=l,l=l.child;continue}if(l===e)break;for(;l.sibling===null;){if(l.return===null||l.return===e)return null;l=l.return}l.sibling.return=l.return,l=l.sibling}return null}var Xl=0,ie=null,Se=null,qe=null,ci=!1,va=!1,Lt=!1,si=0,an=0,ya=null,Bm=0;function Oe(){throw Error(f(321))}function ic(e,l){if(l===null)return!1;for(var t=0;t<l.length&&t<e.length;t++)if(!fl(e[t],l[t]))return!1;return!0}function uc(e,l,t,a,n,u){return Xl=u,ie=l,l.memoizedState=null,l.updateQueue=null,l.lanes=0,z.H=e===null||e.memoizedState===null?Gd:xc,Lt=!1,u=t(a,n),Lt=!1,va&&(u=ud(l,t,a,n)),id(e),u}function id(e){z.H=cn;var l=Se!==null&&Se.next!==null;if(Xl=0,qe=Se=ie=null,ci=!1,an=0,ya=null,l)throw Error(f(300));e===null||Be||(e=e.dependencies,e!==null&&In(e)&&(Be=!0))}function ud(e,l,t,a){ie=e;var n=0;do{if(va&&(ya=null),an=0,va=!1,25<=n)throw Error(f(301));if(n+=1,qe=Se=null,e.updateQueue!=null){var u=e.updateQueue;u.lastEffect=null,u.events=null,u.stores=null,u.memoCache!=null&&(u.memoCache.index=0)}z.H=Ld,u=l(t,a)}while(va);return u}function Ym(){var e=z.H,l=e.useState()[0];return l=typeof l.then=="function"?nn(l):l,e=e.useState()[0],(Se!==null?Se.memoizedState:null)!==e&&(ie.flags|=1024),l}function cc(){var e=si!==0;return si=0,e}function sc(e,l,t){l.updateQueue=e.updateQueue,l.flags&=-2053,e.lanes&=~t}function rc(e){if(ci){for(e=e.memoizedState;e!==null;){var l=e.queue;l!==null&&(l.pending=null),e=e.next}ci=!1}Xl=0,qe=Se=ie=null,va=!1,an=si=0,ya=null}function Ie(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return qe===null?ie.memoizedState=qe=e:qe=qe.next=e,qe}function He(){if(Se===null){var e=ie.alternate;e=e!==null?e.memoizedState:null}else e=Se.next;var l=qe===null?ie.memoizedState:qe.next;if(l!==null)qe=l,Se=e;else{if(e===null)throw ie.alternate===null?Error(f(467)):Error(f(310));Se=e,e={memoizedState:Se.memoizedState,baseState:Se.baseState,baseQueue:Se.baseQueue,queue:Se.queue,next:null},qe===null?ie.memoizedState=qe=e:qe=qe.next=e}return qe}function ri(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function nn(e){var l=an;return an+=1,ya===null&&(ya=[]),e=Wr(ya,e,l),l=ie,(qe===null?l.memoizedState:qe.next)===null&&(l=l.alternate,z.H=l===null||l.memoizedState===null?Gd:xc),e}function di(e){if(e!==null&&typeof e=="object"){if(typeof e.then=="function")return nn(e);if(e.$$typeof===P)return Ve(e)}throw Error(f(438,String(e)))}function dc(e){var l=null,t=ie.updateQueue;if(t!==null&&(l=t.memoCache),l==null){var a=ie.alternate;a!==null&&(a=a.updateQueue,a!==null&&(a=a.memoCache,a!=null&&(l={data:a.data.map(function(n){return n.slice()}),index:0})))}if(l==null&&(l={data:[],index:0}),t===null&&(t=ri(),ie.updateQueue=t),t.memoCache=l,t=l.data[l.index],t===void 0)for(t=l.data[l.index]=Array(e),a=0;a<e;a++)t[a]=we;return l.index++,t}function Ql(e,l){return typeof l=="function"?l(e):l}function fi(e){var l=He();return fc(l,Se,e)}function fc(e,l,t){var a=e.queue;if(a===null)throw Error(f(311));a.lastRenderedReducer=t;var n=e.baseQueue,u=a.pending;if(u!==null){if(n!==null){var c=n.next;n.next=u.next,u.next=c}l.baseQueue=n=u,a.pending=null}if(u=e.baseState,n===null)e.memoizedState=u;else{l=n.next;var r=c=null,h=null,N=l,M=!1;do{var U=N.lane&-536870913;if(U!==N.lane?(oe&U)===U:(Xl&U)===U){var A=N.revertLane;if(A===0)h!==null&&(h=h.next={lane:0,revertLane:0,gesture:null,action:N.action,hasEagerState:N.hasEagerState,eagerState:N.eagerState,next:null}),U===da&&(M=!0);else if((Xl&A)===A){N=N.next,A===da&&(M=!0);continue}else U={lane:0,revertLane:N.revertLane,gesture:null,action:N.action,hasEagerState:N.hasEagerState,eagerState:N.eagerState,next:null},h===null?(r=h=U,c=u):h=h.next=U,ie.lanes|=A,yt|=A;U=N.action,Lt&&t(u,U),u=N.hasEagerState?N.eagerState:t(u,U)}else A={lane:U,revertLane:N.revertLane,gesture:N.gesture,action:N.action,hasEagerState:N.hasEagerState,eagerState:N.eagerState,next:null},h===null?(r=h=A,c=u):h=h.next=A,ie.lanes|=U,yt|=U;N=N.next}while(N!==null&&N!==l);if(h===null?c=u:h.next=r,!fl(u,e.memoizedState)&&(Be=!0,M&&(t=fa,t!==null)))throw t;e.memoizedState=u,e.baseState=c,e.baseQueue=h,a.lastRenderedState=u}return n===null&&(a.lanes=0),[e.memoizedState,a.dispatch]}function oc(e){var l=He(),t=l.queue;if(t===null)throw Error(f(311));t.lastRenderedReducer=e;var a=t.dispatch,n=t.pending,u=l.memoizedState;if(n!==null){t.pending=null;var c=n=n.next;do u=e(u,c.action),c=c.next;while(c!==n);fl(u,l.memoizedState)||(Be=!0),l.memoizedState=u,l.baseQueue===null&&(l.baseState=u),t.lastRenderedState=u}return[u,a]}function cd(e,l,t){var a=ie,n=He(),u=me;if(u){if(t===void 0)throw Error(f(407));t=t()}else t=l();var c=!fl((Se||n).memoizedState,t);if(c&&(n.memoizedState=t,Be=!0),n=n.queue,vc(dd.bind(null,a,n,e),[e]),n.getSnapshot!==l||c||qe!==null&&qe.memoizedState.tag&1){if(a.flags|=2048,ga(9,{destroy:void 0},rd.bind(null,a,n,t,l),null),Ae===null)throw Error(f(349));u||(Xl&127)!==0||sd(a,l,t)}return t}function sd(e,l,t){e.flags|=16384,e={getSnapshot:l,value:t},l=ie.updateQueue,l===null?(l=ri(),ie.updateQueue=l,l.stores=[e]):(t=l.stores,t===null?l.stores=[e]:t.push(e))}function rd(e,l,t,a){l.value=t,l.getSnapshot=a,fd(l)&&od(e)}function dd(e,l,t){return t(function(){fd(l)&&od(e)})}function fd(e){var l=e.getSnapshot;e=e.value;try{var t=l();return!fl(e,t)}catch{return!0}}function od(e){var l=Dt(e,2);l!==null&&cl(l,e,2)}function hc(e){var l=Ie();if(typeof e=="function"){var t=e;if(e=t(),Lt){tt(!0);try{t()}finally{tt(!1)}}}return l.memoizedState=l.baseState=e,l.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ql,lastRenderedState:e},l}function hd(e,l,t,a){return e.baseState=t,fc(e,Se,typeof a=="function"?a:Ql)}function wm(e,l,t,a,n){if(mi(e))throw Error(f(485));if(e=l.action,e!==null){var u={payload:n,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(c){u.listeners.push(c)}};z.T!==null?t(!0):u.isTransition=!1,a(u),t=l.pending,t===null?(u.next=l.pending=u,md(l,u)):(u.next=t.next,l.pending=t.next=u)}}function md(e,l){var t=l.action,a=l.payload,n=e.state;if(l.isTransition){var u=z.T,c={};z.T=c;try{var r=t(n,a),h=z.S;h!==null&&h(c,r),vd(e,l,r)}catch(N){mc(e,l,N)}finally{u!==null&&c.types!==null&&(u.types=c.types),z.T=u}}else try{u=t(n,a),vd(e,l,u)}catch(N){mc(e,l,N)}}function vd(e,l,t){t!==null&&typeof t=="object"&&typeof t.then=="function"?t.then(function(a){yd(e,l,a)},function(a){return mc(e,l,a)}):yd(e,l,t)}function yd(e,l,t){l.status="fulfilled",l.value=t,gd(l),e.state=t,l=e.pending,l!==null&&(t=l.next,t===l?e.pending=null:(t=t.next,l.next=t,md(e,t)))}function mc(e,l,t){var a=e.pending;if(e.pending=null,a!==null){a=a.next;do l.status="rejected",l.reason=t,gd(l),l=l.next;while(l!==a)}e.action=null}function gd(e){e=e.listeners;for(var l=0;l<e.length;l++)(0,e[l])()}function pd(e,l){return l}function jd(e,l){if(me){var t=Ae.formState;if(t!==null){e:{var a=ie;if(me){if(ze){l:{for(var n=ze,u=El;n.nodeType!==8;){if(!u){n=null;break l}if(n=Al(n.nextSibling),n===null){n=null;break l}}u=n.data,n=u==="F!"||u==="F"?n:null}if(n){ze=Al(n.nextSibling),a=n.data==="F!";break e}}ct(a)}a=!1}a&&(l=t[0])}}return t=Ie(),t.memoizedState=t.baseState=l,a={pending:null,lanes:0,dispatch:null,lastRenderedReducer:pd,lastRenderedState:l},t.queue=a,t=Bd.bind(null,ie,a),a.dispatch=t,a=hc(!1),u=bc.bind(null,ie,!1,a.queue),a=Ie(),n={state:l,dispatch:null,action:e,pending:null},a.queue=n,t=wm.bind(null,ie,n,u,t),n.dispatch=t,a.memoizedState=e,[l,t,!1]}function bd(e){var l=He();return xd(l,Se,e)}function xd(e,l,t){if(l=fc(e,l,pd)[0],e=fi(Ql)[0],typeof l=="object"&&l!==null&&typeof l.then=="function")try{var a=nn(l)}catch(c){throw c===oa?li:c}else a=l;l=He();var n=l.queue,u=n.dispatch;return t!==l.memoizedState&&(ie.flags|=2048,ga(9,{destroy:void 0},Gm.bind(null,n,t),null)),[a,u,e]}function Gm(e,l){e.action=l}function Sd(e){var l=He(),t=Se;if(t!==null)return xd(l,t,e);He(),l=l.memoizedState,t=He();var a=t.queue.dispatch;return t.memoizedState=e,[l,a,!1]}function ga(e,l,t,a){return e={tag:e,create:t,deps:a,inst:l,next:null},l=ie.updateQueue,l===null&&(l=ri(),ie.updateQueue=l),t=l.lastEffect,t===null?l.lastEffect=e.next=e:(a=t.next,t.next=e,e.next=a,l.lastEffect=e),e}function Nd(){return He().memoizedState}function oi(e,l,t,a){var n=Ie();ie.flags|=e,n.memoizedState=ga(1|l,{destroy:void 0},t,a===void 0?null:a)}function hi(e,l,t,a){var n=He();a=a===void 0?null:a;var u=n.memoizedState.inst;Se!==null&&a!==null&&ic(a,Se.memoizedState.deps)?n.memoizedState=ga(l,u,t,a):(ie.flags|=e,n.memoizedState=ga(1|l,u,t,a))}function Ed(e,l){oi(8390656,8,e,l)}function vc(e,l){hi(2048,8,e,l)}function Lm(e){ie.flags|=4;var l=ie.updateQueue;if(l===null)l=ri(),ie.updateQueue=l,l.events=[e];else{var t=l.events;t===null?l.events=[e]:t.push(e)}}function Td(e){var l=He().memoizedState;return Lm({ref:l,nextImpl:e}),function(){if((pe&2)!==0)throw Error(f(440));return l.impl.apply(void 0,arguments)}}function Ad(e,l){return hi(4,2,e,l)}function zd(e,l){return hi(4,4,e,l)}function _d(e,l){if(typeof l=="function"){e=e();var t=l(e);return function(){typeof t=="function"?t():l(null)}}if(l!=null)return e=e(),l.current=e,function(){l.current=null}}function Md(e,l,t){t=t!=null?t.concat([e]):null,hi(4,4,_d.bind(null,l,e),t)}function yc(){}function Cd(e,l){var t=He();l=l===void 0?null:l;var a=t.memoizedState;return l!==null&&ic(l,a[1])?a[0]:(t.memoizedState=[e,l],e)}function Od(e,l){var t=He();l=l===void 0?null:l;var a=t.memoizedState;if(l!==null&&ic(l,a[1]))return a[0];if(a=e(),Lt){tt(!0);try{e()}finally{tt(!1)}}return t.memoizedState=[a,l],a}function gc(e,l,t){return t===void 0||(Xl&1073741824)!==0&&(oe&261930)===0?e.memoizedState=l:(e.memoizedState=t,e=Df(),ie.lanes|=e,yt|=e,t)}function Ud(e,l,t,a){return fl(t,l)?t:ma.current!==null?(e=gc(e,t,a),fl(e,l)||(Be=!0),e):(Xl&42)===0||(Xl&1073741824)!==0&&(oe&261930)===0?(Be=!0,e.memoizedState=t):(e=Df(),ie.lanes|=e,yt|=e,l)}function Dd(e,l,t,a,n){var u=p.p;p.p=u!==0&&8>u?u:8;var c=z.T,r={};z.T=r,bc(e,!1,l,t);try{var h=n(),N=z.S;if(N!==null&&N(r,h),h!==null&&typeof h=="object"&&typeof h.then=="function"){var M=qm(h,a);un(e,l,M,gl(e))}else un(e,l,a,gl(e))}catch(U){un(e,l,{then:function(){},status:"rejected",reason:U},gl())}finally{p.p=u,c!==null&&r.types!==null&&(c.types=r.types),z.T=c}}function Xm(){}function pc(e,l,t,a){if(e.tag!==5)throw Error(f(476));var n=Rd(e).queue;Dd(e,n,l,Y,t===null?Xm:function(){return Hd(e),t(a)})}function Rd(e){var l=e.memoizedState;if(l!==null)return l;l={memoizedState:Y,baseState:Y,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ql,lastRenderedState:Y},next:null};var t={};return l.next={memoizedState:t,baseState:t,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ql,lastRenderedState:t},next:null},e.memoizedState=l,e=e.alternate,e!==null&&(e.memoizedState=l),l}function Hd(e){var l=Rd(e);l.next===null&&(l=e.alternate.memoizedState),un(e,l.next.queue,{},gl())}function jc(){return Ve(Nn)}function kd(){return He().memoizedState}function qd(){return He().memoizedState}function Qm(e){for(var l=e.return;l!==null;){switch(l.tag){case 24:case 3:var t=gl();e=dt(t);var a=ft(l,e,t);a!==null&&(cl(a,l,t),en(a,l,t)),l={cache:Ju()},e.payload=l;return}l=l.return}}function Zm(e,l,t){var a=gl();t={lane:a,revertLane:0,gesture:null,action:t,hasEagerState:!1,eagerState:null,next:null},mi(e)?Yd(l,t):(t=qu(e,l,t,a),t!==null&&(cl(t,e,a),wd(t,l,a)))}function Bd(e,l,t){var a=gl();un(e,l,t,a)}function un(e,l,t,a){var n={lane:a,revertLane:0,gesture:null,action:t,hasEagerState:!1,eagerState:null,next:null};if(mi(e))Yd(l,n);else{var u=e.alternate;if(e.lanes===0&&(u===null||u.lanes===0)&&(u=l.lastRenderedReducer,u!==null))try{var c=l.lastRenderedState,r=u(c,t);if(n.hasEagerState=!0,n.eagerState=r,fl(r,c))return Jn(e,l,n,0),Ae===null&&Vn(),!1}catch{}if(t=qu(e,l,n,a),t!==null)return cl(t,e,a),wd(t,l,a),!0}return!1}function bc(e,l,t,a){if(a={lane:2,revertLane:Ic(),gesture:null,action:a,hasEagerState:!1,eagerState:null,next:null},mi(e)){if(l)throw Error(f(479))}else l=qu(e,t,a,2),l!==null&&cl(l,e,2)}function mi(e){var l=e.alternate;return e===ie||l!==null&&l===ie}function Yd(e,l){va=ci=!0;var t=e.pending;t===null?l.next=l:(l.next=t.next,t.next=l),e.pending=l}function wd(e,l,t){if((t&4194048)!==0){var a=l.lanes;a&=e.pendingLanes,t|=a,l.lanes=t,Zs(e,t)}}var cn={readContext:Ve,use:di,useCallback:Oe,useContext:Oe,useEffect:Oe,useImperativeHandle:Oe,useLayoutEffect:Oe,useInsertionEffect:Oe,useMemo:Oe,useReducer:Oe,useRef:Oe,useState:Oe,useDebugValue:Oe,useDeferredValue:Oe,useTransition:Oe,useSyncExternalStore:Oe,useId:Oe,useHostTransitionStatus:Oe,useFormState:Oe,useActionState:Oe,useOptimistic:Oe,useMemoCache:Oe,useCacheRefresh:Oe};cn.useEffectEvent=Oe;var Gd={readContext:Ve,use:di,useCallback:function(e,l){return Ie().memoizedState=[e,l===void 0?null:l],e},useContext:Ve,useEffect:Ed,useImperativeHandle:function(e,l,t){t=t!=null?t.concat([e]):null,oi(4194308,4,_d.bind(null,l,e),t)},useLayoutEffect:function(e,l){return oi(4194308,4,e,l)},useInsertionEffect:function(e,l){oi(4,2,e,l)},useMemo:function(e,l){var t=Ie();l=l===void 0?null:l;var a=e();if(Lt){tt(!0);try{e()}finally{tt(!1)}}return t.memoizedState=[a,l],a},useReducer:function(e,l,t){var a=Ie();if(t!==void 0){var n=t(l);if(Lt){tt(!0);try{t(l)}finally{tt(!1)}}}else n=l;return a.memoizedState=a.baseState=n,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:n},a.queue=e,e=e.dispatch=Zm.bind(null,ie,e),[a.memoizedState,e]},useRef:function(e){var l=Ie();return e={current:e},l.memoizedState=e},useState:function(e){e=hc(e);var l=e.queue,t=Bd.bind(null,ie,l);return l.dispatch=t,[e.memoizedState,t]},useDebugValue:yc,useDeferredValue:function(e,l){var t=Ie();return gc(t,e,l)},useTransition:function(){var e=hc(!1);return e=Dd.bind(null,ie,e.queue,!0,!1),Ie().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,l,t){var a=ie,n=Ie();if(me){if(t===void 0)throw Error(f(407));t=t()}else{if(t=l(),Ae===null)throw Error(f(349));(oe&127)!==0||sd(a,l,t)}n.memoizedState=t;var u={value:t,getSnapshot:l};return n.queue=u,Ed(dd.bind(null,a,u,e),[e]),a.flags|=2048,ga(9,{destroy:void 0},rd.bind(null,a,u,t,l),null),t},useId:function(){var e=Ie(),l=Ae.identifierPrefix;if(me){var t=Dl,a=Ul;t=(a&~(1<<32-dl(a)-1)).toString(32)+t,l="_"+l+"R_"+t,t=si++,0<t&&(l+="H"+t.toString(32)),l+="_"}else t=Bm++,l="_"+l+"r_"+t.toString(32)+"_";return e.memoizedState=l},useHostTransitionStatus:jc,useFormState:jd,useActionState:jd,useOptimistic:function(e){var l=Ie();l.memoizedState=l.baseState=e;var t={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return l.queue=t,l=bc.bind(null,ie,!0,t),t.dispatch=l,[e,l]},useMemoCache:dc,useCacheRefresh:function(){return Ie().memoizedState=Qm.bind(null,ie)},useEffectEvent:function(e){var l=Ie(),t={impl:e};return l.memoizedState=t,function(){if((pe&2)!==0)throw Error(f(440));return t.impl.apply(void 0,arguments)}}},xc={readContext:Ve,use:di,useCallback:Cd,useContext:Ve,useEffect:vc,useImperativeHandle:Md,useInsertionEffect:Ad,useLayoutEffect:zd,useMemo:Od,useReducer:fi,useRef:Nd,useState:function(){return fi(Ql)},useDebugValue:yc,useDeferredValue:function(e,l){var t=He();return Ud(t,Se.memoizedState,e,l)},useTransition:function(){var e=fi(Ql)[0],l=He().memoizedState;return[typeof e=="boolean"?e:nn(e),l]},useSyncExternalStore:cd,useId:kd,useHostTransitionStatus:jc,useFormState:bd,useActionState:bd,useOptimistic:function(e,l){var t=He();return hd(t,Se,e,l)},useMemoCache:dc,useCacheRefresh:qd};xc.useEffectEvent=Td;var Ld={readContext:Ve,use:di,useCallback:Cd,useContext:Ve,useEffect:vc,useImperativeHandle:Md,useInsertionEffect:Ad,useLayoutEffect:zd,useMemo:Od,useReducer:oc,useRef:Nd,useState:function(){return oc(Ql)},useDebugValue:yc,useDeferredValue:function(e,l){var t=He();return Se===null?gc(t,e,l):Ud(t,Se.memoizedState,e,l)},useTransition:function(){var e=oc(Ql)[0],l=He().memoizedState;return[typeof e=="boolean"?e:nn(e),l]},useSyncExternalStore:cd,useId:kd,useHostTransitionStatus:jc,useFormState:Sd,useActionState:Sd,useOptimistic:function(e,l){var t=He();return Se!==null?hd(t,Se,e,l):(t.baseState=e,[e,t.queue.dispatch])},useMemoCache:dc,useCacheRefresh:qd};Ld.useEffectEvent=Td;function Sc(e,l,t,a){l=e.memoizedState,t=t(a,l),t=t==null?l:k({},l,t),e.memoizedState=t,e.lanes===0&&(e.updateQueue.baseState=t)}var Nc={enqueueSetState:function(e,l,t){e=e._reactInternals;var a=gl(),n=dt(a);n.payload=l,t!=null&&(n.callback=t),l=ft(e,n,a),l!==null&&(cl(l,e,a),en(l,e,a))},enqueueReplaceState:function(e,l,t){e=e._reactInternals;var a=gl(),n=dt(a);n.tag=1,n.payload=l,t!=null&&(n.callback=t),l=ft(e,n,a),l!==null&&(cl(l,e,a),en(l,e,a))},enqueueForceUpdate:function(e,l){e=e._reactInternals;var t=gl(),a=dt(t);a.tag=2,l!=null&&(a.callback=l),l=ft(e,a,t),l!==null&&(cl(l,e,t),en(l,e,t))}};function Xd(e,l,t,a,n,u,c){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(a,u,c):l.prototype&&l.prototype.isPureReactComponent?!Ka(t,a)||!Ka(n,u):!0}function Qd(e,l,t,a){e=l.state,typeof l.componentWillReceiveProps=="function"&&l.componentWillReceiveProps(t,a),typeof l.UNSAFE_componentWillReceiveProps=="function"&&l.UNSAFE_componentWillReceiveProps(t,a),l.state!==e&&Nc.enqueueReplaceState(l,l.state,null)}function Xt(e,l){var t=l;if("ref"in l){t={};for(var a in l)a!=="ref"&&(t[a]=l[a])}if(e=e.defaultProps){t===l&&(t=k({},t));for(var n in e)t[n]===void 0&&(t[n]=e[n])}return t}function Zd(e){Kn(e)}function Kd(e){console.error(e)}function Vd(e){Kn(e)}function vi(e,l){try{var t=e.onUncaughtError;t(l.value,{componentStack:l.stack})}catch(a){setTimeout(function(){throw a})}}function Jd(e,l,t){try{var a=e.onCaughtError;a(t.value,{componentStack:t.stack,errorBoundary:l.tag===1?l.stateNode:null})}catch(n){setTimeout(function(){throw n})}}function Ec(e,l,t){return t=dt(t),t.tag=3,t.payload={element:null},t.callback=function(){vi(e,l)},t}function $d(e){return e=dt(e),e.tag=3,e}function Wd(e,l,t,a){var n=t.type.getDerivedStateFromError;if(typeof n=="function"){var u=a.value;e.payload=function(){return n(u)},e.callback=function(){Jd(l,t,a)}}var c=t.stateNode;c!==null&&typeof c.componentDidCatch=="function"&&(e.callback=function(){Jd(l,t,a),typeof n!="function"&&(gt===null?gt=new Set([this]):gt.add(this));var r=a.stack;this.componentDidCatch(a.value,{componentStack:r!==null?r:""})})}function Km(e,l,t,a,n){if(t.flags|=32768,a!==null&&typeof a=="object"&&typeof a.then=="function"){if(l=t.alternate,l!==null&&ra(l,t,n,!0),t=hl.current,t!==null){switch(t.tag){case 31:case 13:return Tl===null?zi():t.alternate===null&&Ue===0&&(Ue=3),t.flags&=-257,t.flags|=65536,t.lanes=n,a===ti?t.flags|=16384:(l=t.updateQueue,l===null?t.updateQueue=new Set([a]):l.add(a),$c(e,a,n)),!1;case 22:return t.flags|=65536,a===ti?t.flags|=16384:(l=t.updateQueue,l===null?(l={transitions:null,markerInstances:null,retryQueue:new Set([a])},t.updateQueue=l):(t=l.retryQueue,t===null?l.retryQueue=new Set([a]):t.add(a)),$c(e,a,n)),!1}throw Error(f(435,t.tag))}return $c(e,a,n),zi(),!1}if(me)return l=hl.current,l!==null?((l.flags&65536)===0&&(l.flags|=256),l.flags|=65536,l.lanes=n,a!==Xu&&(e=Error(f(422),{cause:a}),$a(xl(e,t)))):(a!==Xu&&(l=Error(f(423),{cause:a}),$a(xl(l,t))),e=e.current.alternate,e.flags|=65536,n&=-n,e.lanes|=n,a=xl(a,t),n=Ec(e.stateNode,a,n),ec(e,n),Ue!==4&&(Ue=2)),!1;var u=Error(f(520),{cause:a});if(u=xl(u,t),vn===null?vn=[u]:vn.push(u),Ue!==4&&(Ue=2),l===null)return!0;a=xl(a,t),t=l;do{switch(t.tag){case 3:return t.flags|=65536,e=n&-n,t.lanes|=e,e=Ec(t.stateNode,a,e),ec(t,e),!1;case 1:if(l=t.type,u=t.stateNode,(t.flags&128)===0&&(typeof l.getDerivedStateFromError=="function"||u!==null&&typeof u.componentDidCatch=="function"&&(gt===null||!gt.has(u))))return t.flags|=65536,n&=-n,t.lanes|=n,n=$d(n),Wd(n,e,t,a),ec(t,n),!1}t=t.return}while(t!==null);return!1}var Tc=Error(f(461)),Be=!1;function Je(e,l,t,a){l.child=e===null?ed(l,null,t,a):Gt(l,e.child,t,a)}function Fd(e,l,t,a,n){t=t.render;var u=l.ref;if("ref"in a){var c={};for(var r in a)r!=="ref"&&(c[r]=a[r])}else c=a;return qt(l),a=uc(e,l,t,c,u,n),r=cc(),e!==null&&!Be?(sc(e,l,n),Zl(e,l,n)):(me&&r&&Gu(l),l.flags|=1,Je(e,l,a,n),l.child)}function Id(e,l,t,a,n){if(e===null){var u=t.type;return typeof u=="function"&&!Bu(u)&&u.defaultProps===void 0&&t.compare===null?(l.tag=15,l.type=u,Pd(e,l,u,a,n)):(e=Wn(t.type,null,a,l,l.mode,n),e.ref=l.ref,e.return=l,l.child=e)}if(u=e.child,!Dc(e,n)){var c=u.memoizedProps;if(t=t.compare,t=t!==null?t:Ka,t(c,a)&&e.ref===l.ref)return Zl(e,l,n)}return l.flags|=1,e=Yl(u,a),e.ref=l.ref,e.return=l,l.child=e}function Pd(e,l,t,a,n){if(e!==null){var u=e.memoizedProps;if(Ka(u,a)&&e.ref===l.ref)if(Be=!1,l.pendingProps=a=u,Dc(e,n))(e.flags&131072)!==0&&(Be=!0);else return l.lanes=e.lanes,Zl(e,l,n)}return Ac(e,l,t,a,n)}function ef(e,l,t,a){var n=a.children,u=e!==null?e.memoizedState:null;if(e===null&&l.stateNode===null&&(l.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),a.mode==="hidden"){if((l.flags&128)!==0){if(u=u!==null?u.baseLanes|t:t,e!==null){for(a=l.child=e.child,n=0;a!==null;)n=n|a.lanes|a.childLanes,a=a.sibling;a=n&~u}else a=0,l.child=null;return lf(e,l,u,t,a)}if((t&536870912)!==0)l.memoizedState={baseLanes:0,cachePool:null},e!==null&&ei(l,u!==null?u.cachePool:null),u!==null?ad(l,u):tc(),nd(l);else return a=l.lanes=536870912,lf(e,l,u!==null?u.baseLanes|t:t,t,a)}else u!==null?(ei(l,u.cachePool),ad(l,u),ht(),l.memoizedState=null):(e!==null&&ei(l,null),tc(),ht());return Je(e,l,n,t),l.child}function sn(e,l){return e!==null&&e.tag===22||l.stateNode!==null||(l.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),l.sibling}function lf(e,l,t,a,n){var u=Wu();return u=u===null?null:{parent:ke._currentValue,pool:u},l.memoizedState={baseLanes:t,cachePool:u},e!==null&&ei(l,null),tc(),nd(l),e!==null&&ra(e,l,a,!0),l.childLanes=n,null}function yi(e,l){return l=pi({mode:l.mode,children:l.children},e.mode),l.ref=e.ref,e.child=l,l.return=e,l}function tf(e,l,t){return Gt(l,e.child,null,t),e=yi(l,l.pendingProps),e.flags|=2,ml(l),l.memoizedState=null,e}function Vm(e,l,t){var a=l.pendingProps,n=(l.flags&128)!==0;if(l.flags&=-129,e===null){if(me){if(a.mode==="hidden")return e=yi(l,a),l.lanes=536870912,sn(null,e);if(nc(l),(e=ze)?(e=yo(e,El),e=e!==null&&e.data==="&"?e:null,e!==null&&(l.memoizedState={dehydrated:e,treeContext:it!==null?{id:Ul,overflow:Dl}:null,retryLane:536870912,hydrationErrors:null},t=Yr(e),t.return=l,l.child=t,Ke=l,ze=null)):e=null,e===null)throw ct(l);return l.lanes=536870912,null}return yi(l,a)}var u=e.memoizedState;if(u!==null){var c=u.dehydrated;if(nc(l),n)if(l.flags&256)l.flags&=-257,l=tf(e,l,t);else if(l.memoizedState!==null)l.child=e.child,l.flags|=128,l=null;else throw Error(f(558));else if(Be||ra(e,l,t,!1),n=(t&e.childLanes)!==0,Be||n){if(a=Ae,a!==null&&(c=Ks(a,t),c!==0&&c!==u.retryLane))throw u.retryLane=c,Dt(e,c),cl(a,e,c),Tc;zi(),l=tf(e,l,t)}else e=u.treeContext,ze=Al(c.nextSibling),Ke=l,me=!0,ut=null,El=!1,e!==null&&Lr(l,e),l=yi(l,a),l.flags|=4096;return l}return e=Yl(e.child,{mode:a.mode,children:a.children}),e.ref=l.ref,l.child=e,e.return=l,e}function gi(e,l){var t=l.ref;if(t===null)e!==null&&e.ref!==null&&(l.flags|=4194816);else{if(typeof t!="function"&&typeof t!="object")throw Error(f(284));(e===null||e.ref!==t)&&(l.flags|=4194816)}}function Ac(e,l,t,a,n){return qt(l),t=uc(e,l,t,a,void 0,n),a=cc(),e!==null&&!Be?(sc(e,l,n),Zl(e,l,n)):(me&&a&&Gu(l),l.flags|=1,Je(e,l,t,n),l.child)}function af(e,l,t,a,n,u){return qt(l),l.updateQueue=null,t=ud(l,a,t,n),id(e),a=cc(),e!==null&&!Be?(sc(e,l,u),Zl(e,l,u)):(me&&a&&Gu(l),l.flags|=1,Je(e,l,t,u),l.child)}function nf(e,l,t,a,n){if(qt(l),l.stateNode===null){var u=ia,c=t.contextType;typeof c=="object"&&c!==null&&(u=Ve(c)),u=new t(a,u),l.memoizedState=u.state!==null&&u.state!==void 0?u.state:null,u.updater=Nc,l.stateNode=u,u._reactInternals=l,u=l.stateNode,u.props=a,u.state=l.memoizedState,u.refs={},Iu(l),c=t.contextType,u.context=typeof c=="object"&&c!==null?Ve(c):ia,u.state=l.memoizedState,c=t.getDerivedStateFromProps,typeof c=="function"&&(Sc(l,t,c,a),u.state=l.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof u.getSnapshotBeforeUpdate=="function"||typeof u.UNSAFE_componentWillMount!="function"&&typeof u.componentWillMount!="function"||(c=u.state,typeof u.componentWillMount=="function"&&u.componentWillMount(),typeof u.UNSAFE_componentWillMount=="function"&&u.UNSAFE_componentWillMount(),c!==u.state&&Nc.enqueueReplaceState(u,u.state,null),tn(l,a,u,n),ln(),u.state=l.memoizedState),typeof u.componentDidMount=="function"&&(l.flags|=4194308),a=!0}else if(e===null){u=l.stateNode;var r=l.memoizedProps,h=Xt(t,r);u.props=h;var N=u.context,M=t.contextType;c=ia,typeof M=="object"&&M!==null&&(c=Ve(M));var U=t.getDerivedStateFromProps;M=typeof U=="function"||typeof u.getSnapshotBeforeUpdate=="function",r=l.pendingProps!==r,M||typeof u.UNSAFE_componentWillReceiveProps!="function"&&typeof u.componentWillReceiveProps!="function"||(r||N!==c)&&Qd(l,u,a,c),rt=!1;var A=l.memoizedState;u.state=A,tn(l,a,u,n),ln(),N=l.memoizedState,r||A!==N||rt?(typeof U=="function"&&(Sc(l,t,U,a),N=l.memoizedState),(h=rt||Xd(l,t,h,a,A,N,c))?(M||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"&&(l.flags|=4194308)):(typeof u.componentDidMount=="function"&&(l.flags|=4194308),l.memoizedProps=a,l.memoizedState=N),u.props=a,u.state=N,u.context=c,a=h):(typeof u.componentDidMount=="function"&&(l.flags|=4194308),a=!1)}else{u=l.stateNode,Pu(e,l),c=l.memoizedProps,M=Xt(t,c),u.props=M,U=l.pendingProps,A=u.context,N=t.contextType,h=ia,typeof N=="object"&&N!==null&&(h=Ve(N)),r=t.getDerivedStateFromProps,(N=typeof r=="function"||typeof u.getSnapshotBeforeUpdate=="function")||typeof u.UNSAFE_componentWillReceiveProps!="function"&&typeof u.componentWillReceiveProps!="function"||(c!==U||A!==h)&&Qd(l,u,a,h),rt=!1,A=l.memoizedState,u.state=A,tn(l,a,u,n),ln();var _=l.memoizedState;c!==U||A!==_||rt||e!==null&&e.dependencies!==null&&In(e.dependencies)?(typeof r=="function"&&(Sc(l,t,r,a),_=l.memoizedState),(M=rt||Xd(l,t,M,a,A,_,h)||e!==null&&e.dependencies!==null&&In(e.dependencies))?(N||typeof u.UNSAFE_componentWillUpdate!="function"&&typeof u.componentWillUpdate!="function"||(typeof u.componentWillUpdate=="function"&&u.componentWillUpdate(a,_,h),typeof u.UNSAFE_componentWillUpdate=="function"&&u.UNSAFE_componentWillUpdate(a,_,h)),typeof u.componentDidUpdate=="function"&&(l.flags|=4),typeof u.getSnapshotBeforeUpdate=="function"&&(l.flags|=1024)):(typeof u.componentDidUpdate!="function"||c===e.memoizedProps&&A===e.memoizedState||(l.flags|=4),typeof u.getSnapshotBeforeUpdate!="function"||c===e.memoizedProps&&A===e.memoizedState||(l.flags|=1024),l.memoizedProps=a,l.memoizedState=_),u.props=a,u.state=_,u.context=h,a=M):(typeof u.componentDidUpdate!="function"||c===e.memoizedProps&&A===e.memoizedState||(l.flags|=4),typeof u.getSnapshotBeforeUpdate!="function"||c===e.memoizedProps&&A===e.memoizedState||(l.flags|=1024),a=!1)}return u=a,gi(e,l),a=(l.flags&128)!==0,u||a?(u=l.stateNode,t=a&&typeof t.getDerivedStateFromError!="function"?null:u.render(),l.flags|=1,e!==null&&a?(l.child=Gt(l,e.child,null,n),l.child=Gt(l,null,t,n)):Je(e,l,t,n),l.memoizedState=u.state,e=l.child):e=Zl(e,l,n),e}function uf(e,l,t,a){return Ht(),l.flags|=256,Je(e,l,t,a),l.child}var zc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function _c(e){return{baseLanes:e,cachePool:Jr()}}function Mc(e,l,t){return e=e!==null?e.childLanes&~t:0,l&&(e|=yl),e}function cf(e,l,t){var a=l.pendingProps,n=!1,u=(l.flags&128)!==0,c;if((c=u)||(c=e!==null&&e.memoizedState===null?!1:(Re.current&2)!==0),c&&(n=!0,l.flags&=-129),c=(l.flags&32)!==0,l.flags&=-33,e===null){if(me){if(n?ot(l):ht(),(e=ze)?(e=yo(e,El),e=e!==null&&e.data!=="&"?e:null,e!==null&&(l.memoizedState={dehydrated:e,treeContext:it!==null?{id:Ul,overflow:Dl}:null,retryLane:536870912,hydrationErrors:null},t=Yr(e),t.return=l,l.child=t,Ke=l,ze=null)):e=null,e===null)throw ct(l);return fs(e)?l.lanes=32:l.lanes=536870912,null}var r=a.children;return a=a.fallback,n?(ht(),n=l.mode,r=pi({mode:"hidden",children:r},n),a=Rt(a,n,t,null),r.return=l,a.return=l,r.sibling=a,l.child=r,a=l.child,a.memoizedState=_c(t),a.childLanes=Mc(e,c,t),l.memoizedState=zc,sn(null,a)):(ot(l),Cc(l,r))}var h=e.memoizedState;if(h!==null&&(r=h.dehydrated,r!==null)){if(u)l.flags&256?(ot(l),l.flags&=-257,l=Oc(e,l,t)):l.memoizedState!==null?(ht(),l.child=e.child,l.flags|=128,l=null):(ht(),r=a.fallback,n=l.mode,a=pi({mode:"visible",children:a.children},n),r=Rt(r,n,t,null),r.flags|=2,a.return=l,r.return=l,a.sibling=r,l.child=a,Gt(l,e.child,null,t),a=l.child,a.memoizedState=_c(t),a.childLanes=Mc(e,c,t),l.memoizedState=zc,l=sn(null,a));else if(ot(l),fs(r)){if(c=r.nextSibling&&r.nextSibling.dataset,c)var N=c.dgst;c=N,a=Error(f(419)),a.stack="",a.digest=c,$a({value:a,source:null,stack:null}),l=Oc(e,l,t)}else if(Be||ra(e,l,t,!1),c=(t&e.childLanes)!==0,Be||c){if(c=Ae,c!==null&&(a=Ks(c,t),a!==0&&a!==h.retryLane))throw h.retryLane=a,Dt(e,a),cl(c,e,a),Tc;ds(r)||zi(),l=Oc(e,l,t)}else ds(r)?(l.flags|=192,l.child=e.child,l=null):(e=h.treeContext,ze=Al(r.nextSibling),Ke=l,me=!0,ut=null,El=!1,e!==null&&Lr(l,e),l=Cc(l,a.children),l.flags|=4096);return l}return n?(ht(),r=a.fallback,n=l.mode,h=e.child,N=h.sibling,a=Yl(h,{mode:"hidden",children:a.children}),a.subtreeFlags=h.subtreeFlags&65011712,N!==null?r=Yl(N,r):(r=Rt(r,n,t,null),r.flags|=2),r.return=l,a.return=l,a.sibling=r,l.child=a,sn(null,a),a=l.child,r=e.child.memoizedState,r===null?r=_c(t):(n=r.cachePool,n!==null?(h=ke._currentValue,n=n.parent!==h?{parent:h,pool:h}:n):n=Jr(),r={baseLanes:r.baseLanes|t,cachePool:n}),a.memoizedState=r,a.childLanes=Mc(e,c,t),l.memoizedState=zc,sn(e.child,a)):(ot(l),t=e.child,e=t.sibling,t=Yl(t,{mode:"visible",children:a.children}),t.return=l,t.sibling=null,e!==null&&(c=l.deletions,c===null?(l.deletions=[e],l.flags|=16):c.push(e)),l.child=t,l.memoizedState=null,t)}function Cc(e,l){return l=pi({mode:"visible",children:l},e.mode),l.return=e,e.child=l}function pi(e,l){return e=ol(22,e,null,l),e.lanes=0,e}function Oc(e,l,t){return Gt(l,e.child,null,t),e=Cc(l,l.pendingProps.children),e.flags|=2,l.memoizedState=null,e}function sf(e,l,t){e.lanes|=l;var a=e.alternate;a!==null&&(a.lanes|=l),Ku(e.return,l,t)}function Uc(e,l,t,a,n,u){var c=e.memoizedState;c===null?e.memoizedState={isBackwards:l,rendering:null,renderingStartTime:0,last:a,tail:t,tailMode:n,treeForkCount:u}:(c.isBackwards=l,c.rendering=null,c.renderingStartTime=0,c.last=a,c.tail=t,c.tailMode=n,c.treeForkCount=u)}function rf(e,l,t){var a=l.pendingProps,n=a.revealOrder,u=a.tail;a=a.children;var c=Re.current,r=(c&2)!==0;if(r?(c=c&1|2,l.flags|=128):c&=1,X(Re,c),Je(e,l,a,t),a=me?Ja:0,!r&&e!==null&&(e.flags&128)!==0)e:for(e=l.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&sf(e,t,l);else if(e.tag===19)sf(e,t,l);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===l)break e;for(;e.sibling===null;){if(e.return===null||e.return===l)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(n){case"forwards":for(t=l.child,n=null;t!==null;)e=t.alternate,e!==null&&ui(e)===null&&(n=t),t=t.sibling;t=n,t===null?(n=l.child,l.child=null):(n=t.sibling,t.sibling=null),Uc(l,!1,n,t,u,a);break;case"backwards":case"unstable_legacy-backwards":for(t=null,n=l.child,l.child=null;n!==null;){if(e=n.alternate,e!==null&&ui(e)===null){l.child=n;break}e=n.sibling,n.sibling=t,t=n,n=e}Uc(l,!0,t,null,u,a);break;case"together":Uc(l,!1,null,null,void 0,a);break;default:l.memoizedState=null}return l.child}function Zl(e,l,t){if(e!==null&&(l.dependencies=e.dependencies),yt|=l.lanes,(t&l.childLanes)===0)if(e!==null){if(ra(e,l,t,!1),(t&l.childLanes)===0)return null}else return null;if(e!==null&&l.child!==e.child)throw Error(f(153));if(l.child!==null){for(e=l.child,t=Yl(e,e.pendingProps),l.child=t,t.return=l;e.sibling!==null;)e=e.sibling,t=t.sibling=Yl(e,e.pendingProps),t.return=l;t.sibling=null}return l.child}function Dc(e,l){return(e.lanes&l)!==0?!0:(e=e.dependencies,!!(e!==null&&In(e)))}function Jm(e,l,t){switch(l.tag){case 3:Fe(l,l.stateNode.containerInfo),st(l,ke,e.memoizedState.cache),Ht();break;case 27:case 5:Da(l);break;case 4:Fe(l,l.stateNode.containerInfo);break;case 10:st(l,l.type,l.memoizedProps.value);break;case 31:if(l.memoizedState!==null)return l.flags|=128,nc(l),null;break;case 13:var a=l.memoizedState;if(a!==null)return a.dehydrated!==null?(ot(l),l.flags|=128,null):(t&l.child.childLanes)!==0?cf(e,l,t):(ot(l),e=Zl(e,l,t),e!==null?e.sibling:null);ot(l);break;case 19:var n=(e.flags&128)!==0;if(a=(t&l.childLanes)!==0,a||(ra(e,l,t,!1),a=(t&l.childLanes)!==0),n){if(a)return rf(e,l,t);l.flags|=128}if(n=l.memoizedState,n!==null&&(n.rendering=null,n.tail=null,n.lastEffect=null),X(Re,Re.current),a)break;return null;case 22:return l.lanes=0,ef(e,l,t,l.pendingProps);case 24:st(l,ke,e.memoizedState.cache)}return Zl(e,l,t)}function df(e,l,t){if(e!==null)if(e.memoizedProps!==l.pendingProps)Be=!0;else{if(!Dc(e,t)&&(l.flags&128)===0)return Be=!1,Jm(e,l,t);Be=(e.flags&131072)!==0}else Be=!1,me&&(l.flags&1048576)!==0&&Gr(l,Ja,l.index);switch(l.lanes=0,l.tag){case 16:e:{var a=l.pendingProps;if(e=Yt(l.elementType),l.type=e,typeof e=="function")Bu(e)?(a=Xt(e,a),l.tag=1,l=nf(null,l,e,a,t)):(l.tag=0,l=Ac(null,l,e,a,t));else{if(e!=null){var n=e.$$typeof;if(n===le){l.tag=11,l=Fd(null,l,e,a,t);break e}else if(n===K){l.tag=14,l=Id(null,l,e,a,t);break e}}throw l=Qe(e)||e,Error(f(306,l,""))}}return l;case 0:return Ac(e,l,l.type,l.pendingProps,t);case 1:return a=l.type,n=Xt(a,l.pendingProps),nf(e,l,a,n,t);case 3:e:{if(Fe(l,l.stateNode.containerInfo),e===null)throw Error(f(387));a=l.pendingProps;var u=l.memoizedState;n=u.element,Pu(e,l),tn(l,a,null,t);var c=l.memoizedState;if(a=c.cache,st(l,ke,a),a!==u.cache&&Vu(l,[ke],t,!0),ln(),a=c.element,u.isDehydrated)if(u={element:a,isDehydrated:!1,cache:c.cache},l.updateQueue.baseState=u,l.memoizedState=u,l.flags&256){l=uf(e,l,a,t);break e}else if(a!==n){n=xl(Error(f(424)),l),$a(n),l=uf(e,l,a,t);break e}else for(e=l.stateNode.containerInfo,e.nodeType===9?e=e.body:e=e.nodeName==="HTML"?e.ownerDocument.body:e,ze=Al(e.firstChild),Ke=l,me=!0,ut=null,El=!0,t=ed(l,null,a,t),l.child=t;t;)t.flags=t.flags&-3|4096,t=t.sibling;else{if(Ht(),a===n){l=Zl(e,l,t);break e}Je(e,l,a,t)}l=l.child}return l;case 26:return gi(e,l),e===null?(t=So(l.type,null,l.pendingProps,null))?l.memoizedState=t:me||(t=l.type,e=l.pendingProps,a=Ri(re.current).createElement(t),a[Ze]=l,a[ll]=e,$e(a,t,e),Le(a),l.stateNode=a):l.memoizedState=So(l.type,e.memoizedProps,l.pendingProps,e.memoizedState),null;case 27:return Da(l),e===null&&me&&(a=l.stateNode=jo(l.type,l.pendingProps,re.current),Ke=l,El=!0,n=ze,xt(l.type)?(os=n,ze=Al(a.firstChild)):ze=n),Je(e,l,l.pendingProps.children,t),gi(e,l),e===null&&(l.flags|=4194304),l.child;case 5:return e===null&&me&&((n=a=ze)&&(a=Ev(a,l.type,l.pendingProps,El),a!==null?(l.stateNode=a,Ke=l,ze=Al(a.firstChild),El=!1,n=!0):n=!1),n||ct(l)),Da(l),n=l.type,u=l.pendingProps,c=e!==null?e.memoizedProps:null,a=u.children,cs(n,u)?a=null:c!==null&&cs(n,c)&&(l.flags|=32),l.memoizedState!==null&&(n=uc(e,l,Ym,null,null,t),Nn._currentValue=n),gi(e,l),Je(e,l,a,t),l.child;case 6:return e===null&&me&&((e=t=ze)&&(t=Tv(t,l.pendingProps,El),t!==null?(l.stateNode=t,Ke=l,ze=null,e=!0):e=!1),e||ct(l)),null;case 13:return cf(e,l,t);case 4:return Fe(l,l.stateNode.containerInfo),a=l.pendingProps,e===null?l.child=Gt(l,null,a,t):Je(e,l,a,t),l.child;case 11:return Fd(e,l,l.type,l.pendingProps,t);case 7:return Je(e,l,l.pendingProps,t),l.child;case 8:return Je(e,l,l.pendingProps.children,t),l.child;case 12:return Je(e,l,l.pendingProps.children,t),l.child;case 10:return a=l.pendingProps,st(l,l.type,a.value),Je(e,l,a.children,t),l.child;case 9:return n=l.type._context,a=l.pendingProps.children,qt(l),n=Ve(n),a=a(n),l.flags|=1,Je(e,l,a,t),l.child;case 14:return Id(e,l,l.type,l.pendingProps,t);case 15:return Pd(e,l,l.type,l.pendingProps,t);case 19:return rf(e,l,t);case 31:return Vm(e,l,t);case 22:return ef(e,l,t,l.pendingProps);case 24:return qt(l),a=Ve(ke),e===null?(n=Wu(),n===null&&(n=Ae,u=Ju(),n.pooledCache=u,u.refCount++,u!==null&&(n.pooledCacheLanes|=t),n=u),l.memoizedState={parent:a,cache:n},Iu(l),st(l,ke,n)):((e.lanes&t)!==0&&(Pu(e,l),tn(l,null,null,t),ln()),n=e.memoizedState,u=l.memoizedState,n.parent!==a?(n={parent:a,cache:a},l.memoizedState=n,l.lanes===0&&(l.memoizedState=l.updateQueue.baseState=n),st(l,ke,a)):(a=u.cache,st(l,ke,a),a!==n.cache&&Vu(l,[ke],t,!0))),Je(e,l,l.pendingProps.children,t),l.child;case 29:throw l.pendingProps}throw Error(f(156,l.tag))}function Kl(e){e.flags|=4}function Rc(e,l,t,a,n){if((l=(e.mode&32)!==0)&&(l=!1),l){if(e.flags|=16777216,(n&335544128)===n)if(e.stateNode.complete)e.flags|=8192;else if(qf())e.flags|=8192;else throw wt=ti,Fu}else e.flags&=-16777217}function ff(e,l){if(l.type!=="stylesheet"||(l.state.loading&4)!==0)e.flags&=-16777217;else if(e.flags|=16777216,!zo(l))if(qf())e.flags|=8192;else throw wt=ti,Fu}function ji(e,l){l!==null&&(e.flags|=4),e.flags&16384&&(l=e.tag!==22?Xs():536870912,e.lanes|=l,xa|=l)}function rn(e,l){if(!me)switch(e.tailMode){case"hidden":l=e.tail;for(var t=null;l!==null;)l.alternate!==null&&(t=l),l=l.sibling;t===null?e.tail=null:t.sibling=null;break;case"collapsed":t=e.tail;for(var a=null;t!==null;)t.alternate!==null&&(a=t),t=t.sibling;a===null?l||e.tail===null?e.tail=null:e.tail.sibling=null:a.sibling=null}}function _e(e){var l=e.alternate!==null&&e.alternate.child===e.child,t=0,a=0;if(l)for(var n=e.child;n!==null;)t|=n.lanes|n.childLanes,a|=n.subtreeFlags&65011712,a|=n.flags&65011712,n.return=e,n=n.sibling;else for(n=e.child;n!==null;)t|=n.lanes|n.childLanes,a|=n.subtreeFlags,a|=n.flags,n.return=e,n=n.sibling;return e.subtreeFlags|=a,e.childLanes=t,l}function $m(e,l,t){var a=l.pendingProps;switch(Lu(l),l.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return _e(l),null;case 1:return _e(l),null;case 3:return t=l.stateNode,a=null,e!==null&&(a=e.memoizedState.cache),l.memoizedState.cache!==a&&(l.flags|=2048),Ll(ke),De(),t.pendingContext&&(t.context=t.pendingContext,t.pendingContext=null),(e===null||e.child===null)&&(sa(l)?Kl(l):e===null||e.memoizedState.isDehydrated&&(l.flags&256)===0||(l.flags|=1024,Qu())),_e(l),null;case 26:var n=l.type,u=l.memoizedState;return e===null?(Kl(l),u!==null?(_e(l),ff(l,u)):(_e(l),Rc(l,n,null,a,t))):u?u!==e.memoizedState?(Kl(l),_e(l),ff(l,u)):(_e(l),l.flags&=-16777217):(e=e.memoizedProps,e!==a&&Kl(l),_e(l),Rc(l,n,e,a,t)),null;case 27:if(Cn(l),t=re.current,n=l.type,e!==null&&l.stateNode!=null)e.memoizedProps!==a&&Kl(l);else{if(!a){if(l.stateNode===null)throw Error(f(166));return _e(l),null}e=V.current,sa(l)?Xr(l):(e=jo(n,a,t),l.stateNode=e,Kl(l))}return _e(l),null;case 5:if(Cn(l),n=l.type,e!==null&&l.stateNode!=null)e.memoizedProps!==a&&Kl(l);else{if(!a){if(l.stateNode===null)throw Error(f(166));return _e(l),null}if(u=V.current,sa(l))Xr(l);else{var c=Ri(re.current);switch(u){case 1:u=c.createElementNS("http://www.w3.org/2000/svg",n);break;case 2:u=c.createElementNS("http://www.w3.org/1998/Math/MathML",n);break;default:switch(n){case"svg":u=c.createElementNS("http://www.w3.org/2000/svg",n);break;case"math":u=c.createElementNS("http://www.w3.org/1998/Math/MathML",n);break;case"script":u=c.createElement("div"),u.innerHTML="<script><\/script>",u=u.removeChild(u.firstChild);break;case"select":u=typeof a.is=="string"?c.createElement("select",{is:a.is}):c.createElement("select"),a.multiple?u.multiple=!0:a.size&&(u.size=a.size);break;default:u=typeof a.is=="string"?c.createElement(n,{is:a.is}):c.createElement(n)}}u[Ze]=l,u[ll]=a;e:for(c=l.child;c!==null;){if(c.tag===5||c.tag===6)u.appendChild(c.stateNode);else if(c.tag!==4&&c.tag!==27&&c.child!==null){c.child.return=c,c=c.child;continue}if(c===l)break e;for(;c.sibling===null;){if(c.return===null||c.return===l)break e;c=c.return}c.sibling.return=c.return,c=c.sibling}l.stateNode=u;e:switch($e(u,n,a),n){case"button":case"input":case"select":case"textarea":a=!!a.autoFocus;break e;case"img":a=!0;break e;default:a=!1}a&&Kl(l)}}return _e(l),Rc(l,l.type,e===null?null:e.memoizedProps,l.pendingProps,t),null;case 6:if(e&&l.stateNode!=null)e.memoizedProps!==a&&Kl(l);else{if(typeof a!="string"&&l.stateNode===null)throw Error(f(166));if(e=re.current,sa(l)){if(e=l.stateNode,t=l.memoizedProps,a=null,n=Ke,n!==null)switch(n.tag){case 27:case 5:a=n.memoizedProps}e[Ze]=l,e=!!(e.nodeValue===t||a!==null&&a.suppressHydrationWarning===!0||co(e.nodeValue,t)),e||ct(l,!0)}else e=Ri(e).createTextNode(a),e[Ze]=l,l.stateNode=e}return _e(l),null;case 31:if(t=l.memoizedState,e===null||e.memoizedState!==null){if(a=sa(l),t!==null){if(e===null){if(!a)throw Error(f(318));if(e=l.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(f(557));e[Ze]=l}else Ht(),(l.flags&128)===0&&(l.memoizedState=null),l.flags|=4;_e(l),e=!1}else t=Qu(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=t),e=!0;if(!e)return l.flags&256?(ml(l),l):(ml(l),null);if((l.flags&128)!==0)throw Error(f(558))}return _e(l),null;case 13:if(a=l.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(n=sa(l),a!==null&&a.dehydrated!==null){if(e===null){if(!n)throw Error(f(318));if(n=l.memoizedState,n=n!==null?n.dehydrated:null,!n)throw Error(f(317));n[Ze]=l}else Ht(),(l.flags&128)===0&&(l.memoizedState=null),l.flags|=4;_e(l),n=!1}else n=Qu(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),n=!0;if(!n)return l.flags&256?(ml(l),l):(ml(l),null)}return ml(l),(l.flags&128)!==0?(l.lanes=t,l):(t=a!==null,e=e!==null&&e.memoizedState!==null,t&&(a=l.child,n=null,a.alternate!==null&&a.alternate.memoizedState!==null&&a.alternate.memoizedState.cachePool!==null&&(n=a.alternate.memoizedState.cachePool.pool),u=null,a.memoizedState!==null&&a.memoizedState.cachePool!==null&&(u=a.memoizedState.cachePool.pool),u!==n&&(a.flags|=2048)),t!==e&&t&&(l.child.flags|=8192),ji(l,l.updateQueue),_e(l),null);case 4:return De(),e===null&&ts(l.stateNode.containerInfo),_e(l),null;case 10:return Ll(l.type),_e(l),null;case 19:if(D(Re),a=l.memoizedState,a===null)return _e(l),null;if(n=(l.flags&128)!==0,u=a.rendering,u===null)if(n)rn(a,!1);else{if(Ue!==0||e!==null&&(e.flags&128)!==0)for(e=l.child;e!==null;){if(u=ui(e),u!==null){for(l.flags|=128,rn(a,!1),e=u.updateQueue,l.updateQueue=e,ji(l,e),l.subtreeFlags=0,e=t,t=l.child;t!==null;)Br(t,e),t=t.sibling;return X(Re,Re.current&1|2),me&&wl(l,a.treeForkCount),l.child}e=e.sibling}a.tail!==null&&sl()>Ei&&(l.flags|=128,n=!0,rn(a,!1),l.lanes=4194304)}else{if(!n)if(e=ui(u),e!==null){if(l.flags|=128,n=!0,e=e.updateQueue,l.updateQueue=e,ji(l,e),rn(a,!0),a.tail===null&&a.tailMode==="hidden"&&!u.alternate&&!me)return _e(l),null}else 2*sl()-a.renderingStartTime>Ei&&t!==536870912&&(l.flags|=128,n=!0,rn(a,!1),l.lanes=4194304);a.isBackwards?(u.sibling=l.child,l.child=u):(e=a.last,e!==null?e.sibling=u:l.child=u,a.last=u)}return a.tail!==null?(e=a.tail,a.rendering=e,a.tail=e.sibling,a.renderingStartTime=sl(),e.sibling=null,t=Re.current,X(Re,n?t&1|2:t&1),me&&wl(l,a.treeForkCount),e):(_e(l),null);case 22:case 23:return ml(l),ac(),a=l.memoizedState!==null,e!==null?e.memoizedState!==null!==a&&(l.flags|=8192):a&&(l.flags|=8192),a?(t&536870912)!==0&&(l.flags&128)===0&&(_e(l),l.subtreeFlags&6&&(l.flags|=8192)):_e(l),t=l.updateQueue,t!==null&&ji(l,t.retryQueue),t=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(t=e.memoizedState.cachePool.pool),a=null,l.memoizedState!==null&&l.memoizedState.cachePool!==null&&(a=l.memoizedState.cachePool.pool),a!==t&&(l.flags|=2048),e!==null&&D(Bt),null;case 24:return t=null,e!==null&&(t=e.memoizedState.cache),l.memoizedState.cache!==t&&(l.flags|=2048),Ll(ke),_e(l),null;case 25:return null;case 30:return null}throw Error(f(156,l.tag))}function Wm(e,l){switch(Lu(l),l.tag){case 1:return e=l.flags,e&65536?(l.flags=e&-65537|128,l):null;case 3:return Ll(ke),De(),e=l.flags,(e&65536)!==0&&(e&128)===0?(l.flags=e&-65537|128,l):null;case 26:case 27:case 5:return Cn(l),null;case 31:if(l.memoizedState!==null){if(ml(l),l.alternate===null)throw Error(f(340));Ht()}return e=l.flags,e&65536?(l.flags=e&-65537|128,l):null;case 13:if(ml(l),e=l.memoizedState,e!==null&&e.dehydrated!==null){if(l.alternate===null)throw Error(f(340));Ht()}return e=l.flags,e&65536?(l.flags=e&-65537|128,l):null;case 19:return D(Re),null;case 4:return De(),null;case 10:return Ll(l.type),null;case 22:case 23:return ml(l),ac(),e!==null&&D(Bt),e=l.flags,e&65536?(l.flags=e&-65537|128,l):null;case 24:return Ll(ke),null;case 25:return null;default:return null}}function of(e,l){switch(Lu(l),l.tag){case 3:Ll(ke),De();break;case 26:case 27:case 5:Cn(l);break;case 4:De();break;case 31:l.memoizedState!==null&&ml(l);break;case 13:ml(l);break;case 19:D(Re);break;case 10:Ll(l.type);break;case 22:case 23:ml(l),ac(),e!==null&&D(Bt);break;case 24:Ll(ke)}}function dn(e,l){try{var t=l.updateQueue,a=t!==null?t.lastEffect:null;if(a!==null){var n=a.next;t=n;do{if((t.tag&e)===e){a=void 0;var u=t.create,c=t.inst;a=u(),c.destroy=a}t=t.next}while(t!==n)}}catch(r){xe(l,l.return,r)}}function mt(e,l,t){try{var a=l.updateQueue,n=a!==null?a.lastEffect:null;if(n!==null){var u=n.next;a=u;do{if((a.tag&e)===e){var c=a.inst,r=c.destroy;if(r!==void 0){c.destroy=void 0,n=l;var h=t,N=r;try{N()}catch(M){xe(n,h,M)}}}a=a.next}while(a!==u)}}catch(M){xe(l,l.return,M)}}function hf(e){var l=e.updateQueue;if(l!==null){var t=e.stateNode;try{td(l,t)}catch(a){xe(e,e.return,a)}}}function mf(e,l,t){t.props=Xt(e.type,e.memoizedProps),t.state=e.memoizedState;try{t.componentWillUnmount()}catch(a){xe(e,l,a)}}function fn(e,l){try{var t=e.ref;if(t!==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 t=="function"?e.refCleanup=t(a):t.current=a}}catch(n){xe(e,l,n)}}function Rl(e,l){var t=e.ref,a=e.refCleanup;if(t!==null)if(typeof a=="function")try{a()}catch(n){xe(e,l,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof t=="function")try{t(null)}catch(n){xe(e,l,n)}else t.current=null}function vf(e){var l=e.type,t=e.memoizedProps,a=e.stateNode;try{e:switch(l){case"button":case"input":case"select":case"textarea":t.autoFocus&&a.focus();break e;case"img":t.src?a.src=t.src:t.srcSet&&(a.srcset=t.srcSet)}}catch(n){xe(e,e.return,n)}}function Hc(e,l,t){try{var a=e.stateNode;pv(a,e.type,t,l),a[ll]=l}catch(n){xe(e,e.return,n)}}function yf(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&xt(e.type)||e.tag===4}function kc(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||yf(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&&xt(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 qc(e,l,t){var a=e.tag;if(a===5||a===6)e=e.stateNode,l?(t.nodeType===9?t.body:t.nodeName==="HTML"?t.ownerDocument.body:t).insertBefore(e,l):(l=t.nodeType===9?t.body:t.nodeName==="HTML"?t.ownerDocument.body:t,l.appendChild(e),t=t._reactRootContainer,t!=null||l.onclick!==null||(l.onclick=ql));else if(a!==4&&(a===27&&xt(e.type)&&(t=e.stateNode,l=null),e=e.child,e!==null))for(qc(e,l,t),e=e.sibling;e!==null;)qc(e,l,t),e=e.sibling}function bi(e,l,t){var a=e.tag;if(a===5||a===6)e=e.stateNode,l?t.insertBefore(e,l):t.appendChild(e);else if(a!==4&&(a===27&&xt(e.type)&&(t=e.stateNode),e=e.child,e!==null))for(bi(e,l,t),e=e.sibling;e!==null;)bi(e,l,t),e=e.sibling}function gf(e){var l=e.stateNode,t=e.memoizedProps;try{for(var a=e.type,n=l.attributes;n.length;)l.removeAttributeNode(n[0]);$e(l,a,t),l[Ze]=e,l[ll]=t}catch(u){xe(e,e.return,u)}}var Vl=!1,Ye=!1,Bc=!1,pf=typeof WeakSet=="function"?WeakSet:Set,Xe=null;function Fm(e,l){if(e=e.containerInfo,is=Gi,e=Mr(e),Ou(e)){if("selectionStart"in e)var t={start:e.selectionStart,end:e.selectionEnd};else e:{t=(t=e.ownerDocument)&&t.defaultView||window;var a=t.getSelection&&t.getSelection();if(a&&a.rangeCount!==0){t=a.anchorNode;var n=a.anchorOffset,u=a.focusNode;a=a.focusOffset;try{t.nodeType,u.nodeType}catch{t=null;break e}var c=0,r=-1,h=-1,N=0,M=0,U=e,A=null;l:for(;;){for(var _;U!==t||n!==0&&U.nodeType!==3||(r=c+n),U!==u||a!==0&&U.nodeType!==3||(h=c+a),U.nodeType===3&&(c+=U.nodeValue.length),(_=U.firstChild)!==null;)A=U,U=_;for(;;){if(U===e)break l;if(A===t&&++N===n&&(r=c),A===u&&++M===a&&(h=c),(_=U.nextSibling)!==null)break;U=A,A=U.parentNode}U=_}t=r===-1||h===-1?null:{start:r,end:h}}else t=null}t=t||{start:0,end:0}}else t=null;for(us={focusedElem:e,selectionRange:t},Gi=!1,Xe=l;Xe!==null;)if(l=Xe,e=l.child,(l.subtreeFlags&1028)!==0&&e!==null)e.return=l,Xe=e;else for(;Xe!==null;){switch(l=Xe,u=l.alternate,e=l.flags,l.tag){case 0:if((e&4)!==0&&(e=l.updateQueue,e=e!==null?e.events:null,e!==null))for(t=0;t<e.length;t++)n=e[t],n.ref.impl=n.nextImpl;break;case 11:case 15:break;case 1:if((e&1024)!==0&&u!==null){e=void 0,t=l,n=u.memoizedProps,u=u.memoizedState,a=t.stateNode;try{var Z=Xt(t.type,n);e=a.getSnapshotBeforeUpdate(Z,u),a.__reactInternalSnapshotBeforeUpdate=e}catch(I){xe(t,t.return,I)}}break;case 3:if((e&1024)!==0){if(e=l.stateNode.containerInfo,t=e.nodeType,t===9)rs(e);else if(t===1)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":rs(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(f(163))}if(e=l.sibling,e!==null){e.return=l.return,Xe=e;break}Xe=l.return}}function jf(e,l,t){var a=t.flags;switch(t.tag){case 0:case 11:case 15:$l(e,t),a&4&&dn(5,t);break;case 1:if($l(e,t),a&4)if(e=t.stateNode,l===null)try{e.componentDidMount()}catch(c){xe(t,t.return,c)}else{var n=Xt(t.type,l.memoizedProps);l=l.memoizedState;try{e.componentDidUpdate(n,l,e.__reactInternalSnapshotBeforeUpdate)}catch(c){xe(t,t.return,c)}}a&64&&hf(t),a&512&&fn(t,t.return);break;case 3:if($l(e,t),a&64&&(e=t.updateQueue,e!==null)){if(l=null,t.child!==null)switch(t.child.tag){case 27:case 5:l=t.child.stateNode;break;case 1:l=t.child.stateNode}try{td(e,l)}catch(c){xe(t,t.return,c)}}break;case 27:l===null&&a&4&&gf(t);case 26:case 5:$l(e,t),l===null&&a&4&&vf(t),a&512&&fn(t,t.return);break;case 12:$l(e,t);break;case 31:$l(e,t),a&4&&Sf(e,t);break;case 13:$l(e,t),a&4&&Nf(e,t),a&64&&(e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(t=uv.bind(null,t),Av(e,t))));break;case 22:if(a=t.memoizedState!==null||Vl,!a){l=l!==null&&l.memoizedState!==null||Ye,n=Vl;var u=Ye;Vl=a,(Ye=l)&&!u?Wl(e,t,(t.subtreeFlags&8772)!==0):$l(e,t),Vl=n,Ye=u}break;case 30:break;default:$l(e,t)}}function bf(e){var l=e.alternate;l!==null&&(e.alternate=null,bf(l)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(l=e.stateNode,l!==null&&mu(l)),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 Ce=null,al=!1;function Jl(e,l,t){for(t=t.child;t!==null;)xf(e,l,t),t=t.sibling}function xf(e,l,t){if(rl&&typeof rl.onCommitFiberUnmount=="function")try{rl.onCommitFiberUnmount(Ra,t)}catch{}switch(t.tag){case 26:Ye||Rl(t,l),Jl(e,l,t),t.memoizedState?t.memoizedState.count--:t.stateNode&&(t=t.stateNode,t.parentNode.removeChild(t));break;case 27:Ye||Rl(t,l);var a=Ce,n=al;xt(t.type)&&(Ce=t.stateNode,al=!1),Jl(e,l,t),bn(t.stateNode),Ce=a,al=n;break;case 5:Ye||Rl(t,l);case 6:if(a=Ce,n=al,Ce=null,Jl(e,l,t),Ce=a,al=n,Ce!==null)if(al)try{(Ce.nodeType===9?Ce.body:Ce.nodeName==="HTML"?Ce.ownerDocument.body:Ce).removeChild(t.stateNode)}catch(u){xe(t,l,u)}else try{Ce.removeChild(t.stateNode)}catch(u){xe(t,l,u)}break;case 18:Ce!==null&&(al?(e=Ce,mo(e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,t.stateNode),Ma(e)):mo(Ce,t.stateNode));break;case 4:a=Ce,n=al,Ce=t.stateNode.containerInfo,al=!0,Jl(e,l,t),Ce=a,al=n;break;case 0:case 11:case 14:case 15:mt(2,t,l),Ye||mt(4,t,l),Jl(e,l,t);break;case 1:Ye||(Rl(t,l),a=t.stateNode,typeof a.componentWillUnmount=="function"&&mf(t,l,a)),Jl(e,l,t);break;case 21:Jl(e,l,t);break;case 22:Ye=(a=Ye)||t.memoizedState!==null,Jl(e,l,t),Ye=a;break;default:Jl(e,l,t)}}function Sf(e,l){if(l.memoizedState===null&&(e=l.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Ma(e)}catch(t){xe(l,l.return,t)}}}function Nf(e,l){if(l.memoizedState===null&&(e=l.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Ma(e)}catch(t){xe(l,l.return,t)}}function Im(e){switch(e.tag){case 31:case 13:case 19:var l=e.stateNode;return l===null&&(l=e.stateNode=new pf),l;case 22:return e=e.stateNode,l=e._retryCache,l===null&&(l=e._retryCache=new pf),l;default:throw Error(f(435,e.tag))}}function xi(e,l){var t=Im(e);l.forEach(function(a){if(!t.has(a)){t.add(a);var n=cv.bind(null,e,a);a.then(n,n)}})}function nl(e,l){var t=l.deletions;if(t!==null)for(var a=0;a<t.length;a++){var n=t[a],u=e,c=l,r=c;e:for(;r!==null;){switch(r.tag){case 27:if(xt(r.type)){Ce=r.stateNode,al=!1;break e}break;case 5:Ce=r.stateNode,al=!1;break e;case 3:case 4:Ce=r.stateNode.containerInfo,al=!0;break e}r=r.return}if(Ce===null)throw Error(f(160));xf(u,c,n),Ce=null,al=!1,u=n.alternate,u!==null&&(u.return=null),n.return=null}if(l.subtreeFlags&13886)for(l=l.child;l!==null;)Ef(l,e),l=l.sibling}var Cl=null;function Ef(e,l){var t=e.alternate,a=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:nl(l,e),il(e),a&4&&(mt(3,e,e.return),dn(3,e),mt(5,e,e.return));break;case 1:nl(l,e),il(e),a&512&&(Ye||t===null||Rl(t,t.return)),a&64&&Vl&&(e=e.updateQueue,e!==null&&(a=e.callbacks,a!==null&&(t=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=t===null?a:t.concat(a))));break;case 26:var n=Cl;if(nl(l,e),il(e),a&512&&(Ye||t===null||Rl(t,t.return)),a&4){var u=t!==null?t.memoizedState:null;if(a=e.memoizedState,t===null)if(a===null)if(e.stateNode===null){e:{a=e.type,t=e.memoizedProps,n=n.ownerDocument||n;l:switch(a){case"title":u=n.getElementsByTagName("title")[0],(!u||u[qa]||u[Ze]||u.namespaceURI==="http://www.w3.org/2000/svg"||u.hasAttribute("itemprop"))&&(u=n.createElement(a),n.head.insertBefore(u,n.querySelector("head > title"))),$e(u,a,t),u[Ze]=e,Le(u),a=u;break e;case"link":var c=To("link","href",n).get(a+(t.href||""));if(c){for(var r=0;r<c.length;r++)if(u=c[r],u.getAttribute("href")===(t.href==null||t.href===""?null:t.href)&&u.getAttribute("rel")===(t.rel==null?null:t.rel)&&u.getAttribute("title")===(t.title==null?null:t.title)&&u.getAttribute("crossorigin")===(t.crossOrigin==null?null:t.crossOrigin)){c.splice(r,1);break l}}u=n.createElement(a),$e(u,a,t),n.head.appendChild(u);break;case"meta":if(c=To("meta","content",n).get(a+(t.content||""))){for(r=0;r<c.length;r++)if(u=c[r],u.getAttribute("content")===(t.content==null?null:""+t.content)&&u.getAttribute("name")===(t.name==null?null:t.name)&&u.getAttribute("property")===(t.property==null?null:t.property)&&u.getAttribute("http-equiv")===(t.httpEquiv==null?null:t.httpEquiv)&&u.getAttribute("charset")===(t.charSet==null?null:t.charSet)){c.splice(r,1);break l}}u=n.createElement(a),$e(u,a,t),n.head.appendChild(u);break;default:throw Error(f(468,a))}u[Ze]=e,Le(u),a=u}e.stateNode=a}else Ao(n,e.type,e.stateNode);else e.stateNode=Eo(n,a,e.memoizedProps);else u!==a?(u===null?t.stateNode!==null&&(t=t.stateNode,t.parentNode.removeChild(t)):u.count--,a===null?Ao(n,e.type,e.stateNode):Eo(n,a,e.memoizedProps)):a===null&&e.stateNode!==null&&Hc(e,e.memoizedProps,t.memoizedProps)}break;case 27:nl(l,e),il(e),a&512&&(Ye||t===null||Rl(t,t.return)),t!==null&&a&4&&Hc(e,e.memoizedProps,t.memoizedProps);break;case 5:if(nl(l,e),il(e),a&512&&(Ye||t===null||Rl(t,t.return)),e.flags&32){n=e.stateNode;try{It(n,"")}catch(Z){xe(e,e.return,Z)}}a&4&&e.stateNode!=null&&(n=e.memoizedProps,Hc(e,n,t!==null?t.memoizedProps:n)),a&1024&&(Bc=!0);break;case 6:if(nl(l,e),il(e),a&4){if(e.stateNode===null)throw Error(f(162));a=e.memoizedProps,t=e.stateNode;try{t.nodeValue=a}catch(Z){xe(e,e.return,Z)}}break;case 3:if(qi=null,n=Cl,Cl=Hi(l.containerInfo),nl(l,e),Cl=n,il(e),a&4&&t!==null&&t.memoizedState.isDehydrated)try{Ma(l.containerInfo)}catch(Z){xe(e,e.return,Z)}Bc&&(Bc=!1,Tf(e));break;case 4:a=Cl,Cl=Hi(e.stateNode.containerInfo),nl(l,e),il(e),Cl=a;break;case 12:nl(l,e),il(e);break;case 31:nl(l,e),il(e),a&4&&(a=e.updateQueue,a!==null&&(e.updateQueue=null,xi(e,a)));break;case 13:nl(l,e),il(e),e.child.flags&8192&&e.memoizedState!==null!=(t!==null&&t.memoizedState!==null)&&(Ni=sl()),a&4&&(a=e.updateQueue,a!==null&&(e.updateQueue=null,xi(e,a)));break;case 22:n=e.memoizedState!==null;var h=t!==null&&t.memoizedState!==null,N=Vl,M=Ye;if(Vl=N||n,Ye=M||h,nl(l,e),Ye=M,Vl=N,il(e),a&8192)e:for(l=e.stateNode,l._visibility=n?l._visibility&-2:l._visibility|1,n&&(t===null||h||Vl||Ye||Qt(e)),t=null,l=e;;){if(l.tag===5||l.tag===26){if(t===null){h=t=l;try{if(u=h.stateNode,n)c=u.style,typeof c.setProperty=="function"?c.setProperty("display","none","important"):c.display="none";else{r=h.stateNode;var U=h.memoizedProps.style,A=U!=null&&U.hasOwnProperty("display")?U.display:null;r.style.display=A==null||typeof A=="boolean"?"":(""+A).trim()}}catch(Z){xe(h,h.return,Z)}}}else if(l.tag===6){if(t===null){h=l;try{h.stateNode.nodeValue=n?"":h.memoizedProps}catch(Z){xe(h,h.return,Z)}}}else if(l.tag===18){if(t===null){h=l;try{var _=h.stateNode;n?vo(_,!0):vo(h.stateNode,!1)}catch(Z){xe(h,h.return,Z)}}}else if((l.tag!==22&&l.tag!==23||l.memoizedState===null||l===e)&&l.child!==null){l.child.return=l,l=l.child;continue}if(l===e)break e;for(;l.sibling===null;){if(l.return===null||l.return===e)break e;t===l&&(t=null),l=l.return}t===l&&(t=null),l.sibling.return=l.return,l=l.sibling}a&4&&(a=e.updateQueue,a!==null&&(t=a.retryQueue,t!==null&&(a.retryQueue=null,xi(e,t))));break;case 19:nl(l,e),il(e),a&4&&(a=e.updateQueue,a!==null&&(e.updateQueue=null,xi(e,a)));break;case 30:break;case 21:break;default:nl(l,e),il(e)}}function il(e){var l=e.flags;if(l&2){try{for(var t,a=e.return;a!==null;){if(yf(a)){t=a;break}a=a.return}if(t==null)throw Error(f(160));switch(t.tag){case 27:var n=t.stateNode,u=kc(e);bi(e,u,n);break;case 5:var c=t.stateNode;t.flags&32&&(It(c,""),t.flags&=-33);var r=kc(e);bi(e,r,c);break;case 3:case 4:var h=t.stateNode.containerInfo,N=kc(e);qc(e,N,h);break;default:throw Error(f(161))}}catch(M){xe(e,e.return,M)}e.flags&=-3}l&4096&&(e.flags&=-4097)}function Tf(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var l=e;Tf(l),l.tag===5&&l.flags&1024&&l.stateNode.reset(),e=e.sibling}}function $l(e,l){if(l.subtreeFlags&8772)for(l=l.child;l!==null;)jf(e,l.alternate,l),l=l.sibling}function Qt(e){for(e=e.child;e!==null;){var l=e;switch(l.tag){case 0:case 11:case 14:case 15:mt(4,l,l.return),Qt(l);break;case 1:Rl(l,l.return);var t=l.stateNode;typeof t.componentWillUnmount=="function"&&mf(l,l.return,t),Qt(l);break;case 27:bn(l.stateNode);case 26:case 5:Rl(l,l.return),Qt(l);break;case 22:l.memoizedState===null&&Qt(l);break;case 30:Qt(l);break;default:Qt(l)}e=e.sibling}}function Wl(e,l,t){for(t=t&&(l.subtreeFlags&8772)!==0,l=l.child;l!==null;){var a=l.alternate,n=e,u=l,c=u.flags;switch(u.tag){case 0:case 11:case 15:Wl(n,u,t),dn(4,u);break;case 1:if(Wl(n,u,t),a=u,n=a.stateNode,typeof n.componentDidMount=="function")try{n.componentDidMount()}catch(N){xe(a,a.return,N)}if(a=u,n=a.updateQueue,n!==null){var r=a.stateNode;try{var h=n.shared.hiddenCallbacks;if(h!==null)for(n.shared.hiddenCallbacks=null,n=0;n<h.length;n++)ld(h[n],r)}catch(N){xe(a,a.return,N)}}t&&c&64&&hf(u),fn(u,u.return);break;case 27:gf(u);case 26:case 5:Wl(n,u,t),t&&a===null&&c&4&&vf(u),fn(u,u.return);break;case 12:Wl(n,u,t);break;case 31:Wl(n,u,t),t&&c&4&&Sf(n,u);break;case 13:Wl(n,u,t),t&&c&4&&Nf(n,u);break;case 22:u.memoizedState===null&&Wl(n,u,t),fn(u,u.return);break;case 30:break;default:Wl(n,u,t)}l=l.sibling}}function Yc(e,l){var t=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(t=e.memoizedState.cachePool.pool),e=null,l.memoizedState!==null&&l.memoizedState.cachePool!==null&&(e=l.memoizedState.cachePool.pool),e!==t&&(e!=null&&e.refCount++,t!=null&&Wa(t))}function wc(e,l){e=null,l.alternate!==null&&(e=l.alternate.memoizedState.cache),l=l.memoizedState.cache,l!==e&&(l.refCount++,e!=null&&Wa(e))}function Ol(e,l,t,a){if(l.subtreeFlags&10256)for(l=l.child;l!==null;)Af(e,l,t,a),l=l.sibling}function Af(e,l,t,a){var n=l.flags;switch(l.tag){case 0:case 11:case 15:Ol(e,l,t,a),n&2048&&dn(9,l);break;case 1:Ol(e,l,t,a);break;case 3:Ol(e,l,t,a),n&2048&&(e=null,l.alternate!==null&&(e=l.alternate.memoizedState.cache),l=l.memoizedState.cache,l!==e&&(l.refCount++,e!=null&&Wa(e)));break;case 12:if(n&2048){Ol(e,l,t,a),e=l.stateNode;try{var u=l.memoizedProps,c=u.id,r=u.onPostCommit;typeof r=="function"&&r(c,l.alternate===null?"mount":"update",e.passiveEffectDuration,-0)}catch(h){xe(l,l.return,h)}}else Ol(e,l,t,a);break;case 31:Ol(e,l,t,a);break;case 13:Ol(e,l,t,a);break;case 23:break;case 22:u=l.stateNode,c=l.alternate,l.memoizedState!==null?u._visibility&2?Ol(e,l,t,a):on(e,l):u._visibility&2?Ol(e,l,t,a):(u._visibility|=2,pa(e,l,t,a,(l.subtreeFlags&10256)!==0||!1)),n&2048&&Yc(c,l);break;case 24:Ol(e,l,t,a),n&2048&&wc(l.alternate,l);break;default:Ol(e,l,t,a)}}function pa(e,l,t,a,n){for(n=n&&((l.subtreeFlags&10256)!==0||!1),l=l.child;l!==null;){var u=e,c=l,r=t,h=a,N=c.flags;switch(c.tag){case 0:case 11:case 15:pa(u,c,r,h,n),dn(8,c);break;case 23:break;case 22:var M=c.stateNode;c.memoizedState!==null?M._visibility&2?pa(u,c,r,h,n):on(u,c):(M._visibility|=2,pa(u,c,r,h,n)),n&&N&2048&&Yc(c.alternate,c);break;case 24:pa(u,c,r,h,n),n&&N&2048&&wc(c.alternate,c);break;default:pa(u,c,r,h,n)}l=l.sibling}}function on(e,l){if(l.subtreeFlags&10256)for(l=l.child;l!==null;){var t=e,a=l,n=a.flags;switch(a.tag){case 22:on(t,a),n&2048&&Yc(a.alternate,a);break;case 24:on(t,a),n&2048&&wc(a.alternate,a);break;default:on(t,a)}l=l.sibling}}var hn=8192;function ja(e,l,t){if(e.subtreeFlags&hn)for(e=e.child;e!==null;)zf(e,l,t),e=e.sibling}function zf(e,l,t){switch(e.tag){case 26:ja(e,l,t),e.flags&hn&&e.memoizedState!==null&&Bv(t,Cl,e.memoizedState,e.memoizedProps);break;case 5:ja(e,l,t);break;case 3:case 4:var a=Cl;Cl=Hi(e.stateNode.containerInfo),ja(e,l,t),Cl=a;break;case 22:e.memoizedState===null&&(a=e.alternate,a!==null&&a.memoizedState!==null?(a=hn,hn=16777216,ja(e,l,t),hn=a):ja(e,l,t));break;default:ja(e,l,t)}}function _f(e){var l=e.alternate;if(l!==null&&(e=l.child,e!==null)){l.child=null;do l=e.sibling,e.sibling=null,e=l;while(e!==null)}}function mn(e){var l=e.deletions;if((e.flags&16)!==0){if(l!==null)for(var t=0;t<l.length;t++){var a=l[t];Xe=a,Cf(a,e)}_f(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Mf(e),e=e.sibling}function Mf(e){switch(e.tag){case 0:case 11:case 15:mn(e),e.flags&2048&&mt(9,e,e.return);break;case 3:mn(e);break;case 12:mn(e);break;case 22:var l=e.stateNode;e.memoizedState!==null&&l._visibility&2&&(e.return===null||e.return.tag!==13)?(l._visibility&=-3,Si(e)):mn(e);break;default:mn(e)}}function Si(e){var l=e.deletions;if((e.flags&16)!==0){if(l!==null)for(var t=0;t<l.length;t++){var a=l[t];Xe=a,Cf(a,e)}_f(e)}for(e=e.child;e!==null;){switch(l=e,l.tag){case 0:case 11:case 15:mt(8,l,l.return),Si(l);break;case 22:t=l.stateNode,t._visibility&2&&(t._visibility&=-3,Si(l));break;default:Si(l)}e=e.sibling}}function Cf(e,l){for(;Xe!==null;){var t=Xe;switch(t.tag){case 0:case 11:case 15:mt(8,t,l);break;case 23:case 22:if(t.memoizedState!==null&&t.memoizedState.cachePool!==null){var a=t.memoizedState.cachePool.pool;a!=null&&a.refCount++}break;case 24:Wa(t.memoizedState.cache)}if(a=t.child,a!==null)a.return=t,Xe=a;else e:for(t=e;Xe!==null;){a=Xe;var n=a.sibling,u=a.return;if(bf(a),a===t){Xe=null;break e}if(n!==null){n.return=u,Xe=n;break e}Xe=u}}}var Pm={getCacheForType:function(e){var l=Ve(ke),t=l.data.get(e);return t===void 0&&(t=e(),l.data.set(e,t)),t},cacheSignal:function(){return Ve(ke).controller.signal}},ev=typeof WeakMap=="function"?WeakMap:Map,pe=0,Ae=null,de=null,oe=0,be=0,vl=null,vt=!1,ba=!1,Gc=!1,Fl=0,Ue=0,yt=0,Zt=0,Lc=0,yl=0,xa=0,vn=null,ul=null,Xc=!1,Ni=0,Of=0,Ei=1/0,Ti=null,gt=null,Ge=0,pt=null,Sa=null,Il=0,Qc=0,Zc=null,Uf=null,yn=0,Kc=null;function gl(){return(pe&2)!==0&&oe!==0?oe&-oe:z.T!==null?Ic():Vs()}function Df(){if(yl===0)if((oe&536870912)===0||me){var e=Dn;Dn<<=1,(Dn&3932160)===0&&(Dn=262144),yl=e}else yl=536870912;return e=hl.current,e!==null&&(e.flags|=32),yl}function cl(e,l,t){(e===Ae&&(be===2||be===9)||e.cancelPendingCommit!==null)&&(Na(e,0),jt(e,oe,yl,!1)),ka(e,t),((pe&2)===0||e!==Ae)&&(e===Ae&&((pe&2)===0&&(Zt|=t),Ue===4&&jt(e,oe,yl,!1)),Hl(e))}function Rf(e,l,t){if((pe&6)!==0)throw Error(f(327));var a=!t&&(l&127)===0&&(l&e.expiredLanes)===0||Ha(e,l),n=a?av(e,l):Jc(e,l,!0),u=a;do{if(n===0){ba&&!a&&jt(e,l,0,!1);break}else{if(t=e.current.alternate,u&&!lv(t)){n=Jc(e,l,!1),u=!1;continue}if(n===2){if(u=l,e.errorRecoveryDisabledLanes&u)var c=0;else c=e.pendingLanes&-536870913,c=c!==0?c:c&536870912?536870912:0;if(c!==0){l=c;e:{var r=e;n=vn;var h=r.current.memoizedState.isDehydrated;if(h&&(Na(r,c).flags|=256),c=Jc(r,c,!1),c!==2){if(Gc&&!h){r.errorRecoveryDisabledLanes|=u,Zt|=u,n=4;break e}u=ul,ul=n,u!==null&&(ul===null?ul=u:ul.push.apply(ul,u))}n=c}if(u=!1,n!==2)continue}}if(n===1){Na(e,0),jt(e,l,0,!0);break}e:{switch(a=e,u=n,u){case 0:case 1:throw Error(f(345));case 4:if((l&4194048)!==l)break;case 6:jt(a,l,yl,!vt);break e;case 2:ul=null;break;case 3:case 5:break;default:throw Error(f(329))}if((l&62914560)===l&&(n=Ni+300-sl(),10<n)){if(jt(a,l,yl,!vt),Hn(a,0,!0)!==0)break e;Il=l,a.timeoutHandle=oo(Hf.bind(null,a,t,ul,Ti,Xc,l,yl,Zt,xa,vt,u,"Throttled",-0,0),n);break e}Hf(a,t,ul,Ti,Xc,l,yl,Zt,xa,vt,u,null,-0,0)}}break}while(!0);Hl(e)}function Hf(e,l,t,a,n,u,c,r,h,N,M,U,A,_){if(e.timeoutHandle=-1,U=l.subtreeFlags,U&8192||(U&16785408)===16785408){U={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:ql},zf(l,u,U);var Z=(u&62914560)===u?Ni-sl():(u&4194048)===u?Of-sl():0;if(Z=Yv(U,Z),Z!==null){Il=u,e.cancelPendingCommit=Z(Xf.bind(null,e,l,u,t,a,n,c,r,h,M,U,null,A,_)),jt(e,u,c,!N);return}}Xf(e,l,u,t,a,n,c,r,h)}function lv(e){for(var l=e;;){var t=l.tag;if((t===0||t===11||t===15)&&l.flags&16384&&(t=l.updateQueue,t!==null&&(t=t.stores,t!==null)))for(var a=0;a<t.length;a++){var n=t[a],u=n.getSnapshot;n=n.value;try{if(!fl(u(),n))return!1}catch{return!1}}if(t=l.child,l.subtreeFlags&16384&&t!==null)t.return=l,l=t;else{if(l===e)break;for(;l.sibling===null;){if(l.return===null||l.return===e)return!0;l=l.return}l.sibling.return=l.return,l=l.sibling}}return!0}function jt(e,l,t,a){l&=~Lc,l&=~Zt,e.suspendedLanes|=l,e.pingedLanes&=~l,a&&(e.warmLanes|=l),a=e.expirationTimes;for(var n=l;0<n;){var u=31-dl(n),c=1<<u;a[u]=-1,n&=~c}t!==0&&Qs(e,t,l)}function Ai(){return(pe&6)===0?(gn(0),!1):!0}function Vc(){if(de!==null){if(be===0)var e=de.return;else e=de,Gl=kt=null,rc(e),ha=null,Ia=0,e=de;for(;e!==null;)of(e.alternate,e),e=e.return;de=null}}function Na(e,l){var t=e.timeoutHandle;t!==-1&&(e.timeoutHandle=-1,xv(t)),t=e.cancelPendingCommit,t!==null&&(e.cancelPendingCommit=null,t()),Il=0,Vc(),Ae=e,de=t=Yl(e.current,null),oe=l,be=0,vl=null,vt=!1,ba=Ha(e,l),Gc=!1,xa=yl=Lc=Zt=yt=Ue=0,ul=vn=null,Xc=!1,(l&8)!==0&&(l|=l&32);var a=e.entangledLanes;if(a!==0)for(e=e.entanglements,a&=l;0<a;){var n=31-dl(a),u=1<<n;l|=e[n],a&=~u}return Fl=l,Vn(),t}function kf(e,l){ie=null,z.H=cn,l===oa||l===li?(l=Fr(),be=3):l===Fu?(l=Fr(),be=4):be=l===Tc?8:l!==null&&typeof l=="object"&&typeof l.then=="function"?6:1,vl=l,de===null&&(Ue=1,vi(e,xl(l,e.current)))}function qf(){var e=hl.current;return e===null?!0:(oe&4194048)===oe?Tl===null:(oe&62914560)===oe||(oe&536870912)!==0?e===Tl:!1}function Bf(){var e=z.H;return z.H=cn,e===null?cn:e}function Yf(){var e=z.A;return z.A=Pm,e}function zi(){Ue=4,vt||(oe&4194048)!==oe&&hl.current!==null||(ba=!0),(yt&134217727)===0&&(Zt&134217727)===0||Ae===null||jt(Ae,oe,yl,!1)}function Jc(e,l,t){var a=pe;pe|=2;var n=Bf(),u=Yf();(Ae!==e||oe!==l)&&(Ti=null,Na(e,l)),l=!1;var c=Ue;e:do try{if(be!==0&&de!==null){var r=de,h=vl;switch(be){case 8:Vc(),c=6;break e;case 3:case 2:case 9:case 6:hl.current===null&&(l=!0);var N=be;if(be=0,vl=null,Ea(e,r,h,N),t&&ba){c=0;break e}break;default:N=be,be=0,vl=null,Ea(e,r,h,N)}}tv(),c=Ue;break}catch(M){kf(e,M)}while(!0);return l&&e.shellSuspendCounter++,Gl=kt=null,pe=a,z.H=n,z.A=u,de===null&&(Ae=null,oe=0,Vn()),c}function tv(){for(;de!==null;)wf(de)}function av(e,l){var t=pe;pe|=2;var a=Bf(),n=Yf();Ae!==e||oe!==l?(Ti=null,Ei=sl()+500,Na(e,l)):ba=Ha(e,l);e:do try{if(be!==0&&de!==null){l=de;var u=vl;l:switch(be){case 1:be=0,vl=null,Ea(e,l,u,1);break;case 2:case 9:if($r(u)){be=0,vl=null,Gf(l);break}l=function(){be!==2&&be!==9||Ae!==e||(be=7),Hl(e)},u.then(l,l);break e;case 3:be=7;break e;case 4:be=5;break e;case 7:$r(u)?(be=0,vl=null,Gf(l)):(be=0,vl=null,Ea(e,l,u,7));break;case 5:var c=null;switch(de.tag){case 26:c=de.memoizedState;case 5:case 27:var r=de;if(c?zo(c):r.stateNode.complete){be=0,vl=null;var h=r.sibling;if(h!==null)de=h;else{var N=r.return;N!==null?(de=N,_i(N)):de=null}break l}}be=0,vl=null,Ea(e,l,u,5);break;case 6:be=0,vl=null,Ea(e,l,u,6);break;case 8:Vc(),Ue=6;break e;default:throw Error(f(462))}}nv();break}catch(M){kf(e,M)}while(!0);return Gl=kt=null,z.H=a,z.A=n,pe=t,de!==null?0:(Ae=null,oe=0,Vn(),Ue)}function nv(){for(;de!==null&&!zh();)wf(de)}function wf(e){var l=df(e.alternate,e,Fl);e.memoizedProps=e.pendingProps,l===null?_i(e):de=l}function Gf(e){var l=e,t=l.alternate;switch(l.tag){case 15:case 0:l=af(t,l,l.pendingProps,l.type,void 0,oe);break;case 11:l=af(t,l,l.pendingProps,l.type.render,l.ref,oe);break;case 5:rc(l);default:of(t,l),l=de=Br(l,Fl),l=df(t,l,Fl)}e.memoizedProps=e.pendingProps,l===null?_i(e):de=l}function Ea(e,l,t,a){Gl=kt=null,rc(l),ha=null,Ia=0;var n=l.return;try{if(Km(e,n,l,t,oe)){Ue=1,vi(e,xl(t,e.current)),de=null;return}}catch(u){if(n!==null)throw de=n,u;Ue=1,vi(e,xl(t,e.current)),de=null;return}l.flags&32768?(me||a===1?e=!0:ba||(oe&536870912)!==0?e=!1:(vt=e=!0,(a===2||a===9||a===3||a===6)&&(a=hl.current,a!==null&&a.tag===13&&(a.flags|=16384))),Lf(l,e)):_i(l)}function _i(e){var l=e;do{if((l.flags&32768)!==0){Lf(l,vt);return}e=l.return;var t=$m(l.alternate,l,Fl);if(t!==null){de=t;return}if(l=l.sibling,l!==null){de=l;return}de=l=e}while(l!==null);Ue===0&&(Ue=5)}function Lf(e,l){do{var t=Wm(e.alternate,e);if(t!==null){t.flags&=32767,de=t;return}if(t=e.return,t!==null&&(t.flags|=32768,t.subtreeFlags=0,t.deletions=null),!l&&(e=e.sibling,e!==null)){de=e;return}de=e=t}while(e!==null);Ue=6,de=null}function Xf(e,l,t,a,n,u,c,r,h){e.cancelPendingCommit=null;do Mi();while(Ge!==0);if((pe&6)!==0)throw Error(f(327));if(l!==null){if(l===e.current)throw Error(f(177));if(u=l.lanes|l.childLanes,u|=ku,qh(e,t,u,c,r,h),e===Ae&&(de=Ae=null,oe=0),Sa=l,pt=e,Il=t,Qc=u,Zc=n,Uf=a,(l.subtreeFlags&10256)!==0||(l.flags&10256)!==0?(e.callbackNode=null,e.callbackPriority=0,sv(On,function(){return Jf(),null})):(e.callbackNode=null,e.callbackPriority=0),a=(l.flags&13878)!==0,(l.subtreeFlags&13878)!==0||a){a=z.T,z.T=null,n=p.p,p.p=2,c=pe,pe|=4;try{Fm(e,l,t)}finally{pe=c,p.p=n,z.T=a}}Ge=1,Qf(),Zf(),Kf()}}function Qf(){if(Ge===1){Ge=0;var e=pt,l=Sa,t=(l.flags&13878)!==0;if((l.subtreeFlags&13878)!==0||t){t=z.T,z.T=null;var a=p.p;p.p=2;var n=pe;pe|=4;try{Ef(l,e);var u=us,c=Mr(e.containerInfo),r=u.focusedElem,h=u.selectionRange;if(c!==r&&r&&r.ownerDocument&&_r(r.ownerDocument.documentElement,r)){if(h!==null&&Ou(r)){var N=h.start,M=h.end;if(M===void 0&&(M=N),"selectionStart"in r)r.selectionStart=N,r.selectionEnd=Math.min(M,r.value.length);else{var U=r.ownerDocument||document,A=U&&U.defaultView||window;if(A.getSelection){var _=A.getSelection(),Z=r.textContent.length,I=Math.min(h.start,Z),Ee=h.end===void 0?I:Math.min(h.end,Z);!_.extend&&I>Ee&&(c=Ee,Ee=I,I=c);var b=zr(r,I),y=zr(r,Ee);if(b&&y&&(_.rangeCount!==1||_.anchorNode!==b.node||_.anchorOffset!==b.offset||_.focusNode!==y.node||_.focusOffset!==y.offset)){var S=U.createRange();S.setStart(b.node,b.offset),_.removeAllRanges(),I>Ee?(_.addRange(S),_.extend(y.node,y.offset)):(S.setEnd(y.node,y.offset),_.addRange(S))}}}}for(U=[],_=r;_=_.parentNode;)_.nodeType===1&&U.push({element:_,left:_.scrollLeft,top:_.scrollTop});for(typeof r.focus=="function"&&r.focus(),r=0;r<U.length;r++){var O=U[r];O.element.scrollLeft=O.left,O.element.scrollTop=O.top}}Gi=!!is,us=is=null}finally{pe=n,p.p=a,z.T=t}}e.current=l,Ge=2}}function Zf(){if(Ge===2){Ge=0;var e=pt,l=Sa,t=(l.flags&8772)!==0;if((l.subtreeFlags&8772)!==0||t){t=z.T,z.T=null;var a=p.p;p.p=2;var n=pe;pe|=4;try{jf(e,l.alternate,l)}finally{pe=n,p.p=a,z.T=t}}Ge=3}}function Kf(){if(Ge===4||Ge===3){Ge=0,_h();var e=pt,l=Sa,t=Il,a=Uf;(l.subtreeFlags&10256)!==0||(l.flags&10256)!==0?Ge=5:(Ge=0,Sa=pt=null,Vf(e,e.pendingLanes));var n=e.pendingLanes;if(n===0&&(gt=null),ou(t),l=l.stateNode,rl&&typeof rl.onCommitFiberRoot=="function")try{rl.onCommitFiberRoot(Ra,l,void 0,(l.current.flags&128)===128)}catch{}if(a!==null){l=z.T,n=p.p,p.p=2,z.T=null;try{for(var u=e.onRecoverableError,c=0;c<a.length;c++){var r=a[c];u(r.value,{componentStack:r.stack})}}finally{z.T=l,p.p=n}}(Il&3)!==0&&Mi(),Hl(e),n=e.pendingLanes,(t&261930)!==0&&(n&42)!==0?e===Kc?yn++:(yn=0,Kc=e):yn=0,gn(0)}}function Vf(e,l){(e.pooledCacheLanes&=l)===0&&(l=e.pooledCache,l!=null&&(e.pooledCache=null,Wa(l)))}function Mi(){return Qf(),Zf(),Kf(),Jf()}function Jf(){if(Ge!==5)return!1;var e=pt,l=Qc;Qc=0;var t=ou(Il),a=z.T,n=p.p;try{p.p=32>t?32:t,z.T=null,t=Zc,Zc=null;var u=pt,c=Il;if(Ge=0,Sa=pt=null,Il=0,(pe&6)!==0)throw Error(f(331));var r=pe;if(pe|=4,Mf(u.current),Af(u,u.current,c,t),pe=r,gn(0,!1),rl&&typeof rl.onPostCommitFiberRoot=="function")try{rl.onPostCommitFiberRoot(Ra,u)}catch{}return!0}finally{p.p=n,z.T=a,Vf(e,l)}}function $f(e,l,t){l=xl(t,l),l=Ec(e.stateNode,l,2),e=ft(e,l,2),e!==null&&(ka(e,2),Hl(e))}function xe(e,l,t){if(e.tag===3)$f(e,e,t);else for(;l!==null;){if(l.tag===3){$f(l,e,t);break}else if(l.tag===1){var a=l.stateNode;if(typeof l.type.getDerivedStateFromError=="function"||typeof a.componentDidCatch=="function"&&(gt===null||!gt.has(a))){e=xl(t,e),t=$d(2),a=ft(l,t,2),a!==null&&(Wd(t,a,l,e),ka(a,2),Hl(a));break}}l=l.return}}function $c(e,l,t){var a=e.pingCache;if(a===null){a=e.pingCache=new ev;var n=new Set;a.set(l,n)}else n=a.get(l),n===void 0&&(n=new Set,a.set(l,n));n.has(t)||(Gc=!0,n.add(t),e=iv.bind(null,e,l,t),l.then(e,e))}function iv(e,l,t){var a=e.pingCache;a!==null&&a.delete(l),e.pingedLanes|=e.suspendedLanes&t,e.warmLanes&=~t,Ae===e&&(oe&t)===t&&(Ue===4||Ue===3&&(oe&62914560)===oe&&300>sl()-Ni?(pe&2)===0&&Na(e,0):Lc|=t,xa===oe&&(xa=0)),Hl(e)}function Wf(e,l){l===0&&(l=Xs()),e=Dt(e,l),e!==null&&(ka(e,l),Hl(e))}function uv(e){var l=e.memoizedState,t=0;l!==null&&(t=l.retryLane),Wf(e,t)}function cv(e,l){var t=0;switch(e.tag){case 31:case 13:var a=e.stateNode,n=e.memoizedState;n!==null&&(t=n.retryLane);break;case 19:a=e.stateNode;break;case 22:a=e.stateNode._retryCache;break;default:throw Error(f(314))}a!==null&&a.delete(l),Wf(e,t)}function sv(e,l){return su(e,l)}var Ci=null,Ta=null,Wc=!1,Oi=!1,Fc=!1,bt=0;function Hl(e){e!==Ta&&e.next===null&&(Ta===null?Ci=Ta=e:Ta=Ta.next=e),Oi=!0,Wc||(Wc=!0,dv())}function gn(e,l){if(!Fc&&Oi){Fc=!0;do for(var t=!1,a=Ci;a!==null;){if(e!==0){var n=a.pendingLanes;if(n===0)var u=0;else{var c=a.suspendedLanes,r=a.pingedLanes;u=(1<<31-dl(42|e)+1)-1,u&=n&~(c&~r),u=u&201326741?u&201326741|1:u?u|2:0}u!==0&&(t=!0,eo(a,u))}else u=oe,u=Hn(a,a===Ae?u:0,a.cancelPendingCommit!==null||a.timeoutHandle!==-1),(u&3)===0||Ha(a,u)||(t=!0,eo(a,u));a=a.next}while(t);Fc=!1}}function rv(){Ff()}function Ff(){Oi=Wc=!1;var e=0;bt!==0&&bv()&&(e=bt);for(var l=sl(),t=null,a=Ci;a!==null;){var n=a.next,u=If(a,l);u===0?(a.next=null,t===null?Ci=n:t.next=n,n===null&&(Ta=t)):(t=a,(e!==0||(u&3)!==0)&&(Oi=!0)),a=n}Ge!==0&&Ge!==5||gn(e),bt!==0&&(bt=0)}function If(e,l){for(var t=e.suspendedLanes,a=e.pingedLanes,n=e.expirationTimes,u=e.pendingLanes&-62914561;0<u;){var c=31-dl(u),r=1<<c,h=n[c];h===-1?((r&t)===0||(r&a)!==0)&&(n[c]=kh(r,l)):h<=l&&(e.expiredLanes|=r),u&=~r}if(l=Ae,t=oe,t=Hn(e,e===l?t:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),a=e.callbackNode,t===0||e===l&&(be===2||be===9)||e.cancelPendingCommit!==null)return a!==null&&a!==null&&ru(a),e.callbackNode=null,e.callbackPriority=0;if((t&3)===0||Ha(e,t)){if(l=t&-t,l===e.callbackPriority)return l;switch(a!==null&&ru(a),ou(t)){case 2:case 8:t=Gs;break;case 32:t=On;break;case 268435456:t=Ls;break;default:t=On}return a=Pf.bind(null,e),t=su(t,a),e.callbackPriority=l,e.callbackNode=t,l}return a!==null&&a!==null&&ru(a),e.callbackPriority=2,e.callbackNode=null,2}function Pf(e,l){if(Ge!==0&&Ge!==5)return e.callbackNode=null,e.callbackPriority=0,null;var t=e.callbackNode;if(Mi()&&e.callbackNode!==t)return null;var a=oe;return a=Hn(e,e===Ae?a:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),a===0?null:(Rf(e,a,l),If(e,sl()),e.callbackNode!=null&&e.callbackNode===t?Pf.bind(null,e):null)}function eo(e,l){if(Mi())return null;Rf(e,l,!0)}function dv(){Sv(function(){(pe&6)!==0?su(ws,rv):Ff()})}function Ic(){if(bt===0){var e=da;e===0&&(e=Un,Un<<=1,(Un&261888)===0&&(Un=256)),bt=e}return bt}function lo(e){return e==null||typeof e=="symbol"||typeof e=="boolean"?null:typeof e=="function"?e:Yn(""+e)}function to(e,l){var t=l.ownerDocument.createElement("input");return t.name=l.name,t.value=l.value,e.id&&t.setAttribute("form",e.id),l.parentNode.insertBefore(t,l),e=new FormData(e),t.parentNode.removeChild(t),e}function fv(e,l,t,a,n){if(l==="submit"&&t&&t.stateNode===n){var u=lo((n[ll]||null).action),c=a.submitter;c&&(l=(l=c[ll]||null)?lo(l.formAction):c.getAttribute("formAction"),l!==null&&(u=l,c=null));var r=new Xn("action","action",null,a,n);e.push({event:r,listeners:[{instance:null,listener:function(){if(a.defaultPrevented){if(bt!==0){var h=c?to(n,c):new FormData(n);pc(t,{pending:!0,data:h,method:n.method,action:u},null,h)}}else typeof u=="function"&&(r.preventDefault(),h=c?to(n,c):new FormData(n),pc(t,{pending:!0,data:h,method:n.method,action:u},u,h))},currentTarget:n}]})}}for(var Pc=0;Pc<Hu.length;Pc++){var es=Hu[Pc],ov=es.toLowerCase(),hv=es[0].toUpperCase()+es.slice(1);Ml(ov,"on"+hv)}Ml(Ur,"onAnimationEnd"),Ml(Dr,"onAnimationIteration"),Ml(Rr,"onAnimationStart"),Ml("dblclick","onDoubleClick"),Ml("focusin","onFocus"),Ml("focusout","onBlur"),Ml(Mm,"onTransitionRun"),Ml(Cm,"onTransitionStart"),Ml(Om,"onTransitionCancel"),Ml(Hr,"onTransitionEnd"),Wt("onMouseEnter",["mouseout","mouseover"]),Wt("onMouseLeave",["mouseout","mouseover"]),Wt("onPointerEnter",["pointerout","pointerover"]),Wt("onPointerLeave",["pointerout","pointerover"]),Mt("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Mt("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Mt("onBeforeInput",["compositionend","keypress","textInput","paste"]),Mt("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Mt("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Mt("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var pn="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(" "),mv=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(pn));function ao(e,l){l=(l&4)!==0;for(var t=0;t<e.length;t++){var a=e[t],n=a.event;a=a.listeners;e:{var u=void 0;if(l)for(var c=a.length-1;0<=c;c--){var r=a[c],h=r.instance,N=r.currentTarget;if(r=r.listener,h!==u&&n.isPropagationStopped())break e;u=r,n.currentTarget=N;try{u(n)}catch(M){Kn(M)}n.currentTarget=null,u=h}else for(c=0;c<a.length;c++){if(r=a[c],h=r.instance,N=r.currentTarget,r=r.listener,h!==u&&n.isPropagationStopped())break e;u=r,n.currentTarget=N;try{u(n)}catch(M){Kn(M)}n.currentTarget=null,u=h}}}}function fe(e,l){var t=l[hu];t===void 0&&(t=l[hu]=new Set);var a=e+"__bubble";t.has(a)||(no(l,e,2,!1),t.add(a))}function ls(e,l,t){var a=0;l&&(a|=4),no(t,e,a,l)}var Ui="_reactListening"+Math.random().toString(36).slice(2);function ts(e){if(!e[Ui]){e[Ui]=!0,Ws.forEach(function(t){t!=="selectionchange"&&(mv.has(t)||ls(t,!1,e),ls(t,!0,e))});var l=e.nodeType===9?e:e.ownerDocument;l===null||l[Ui]||(l[Ui]=!0,ls("selectionchange",!1,l))}}function no(e,l,t,a){switch(Ro(l)){case 2:var n=Lv;break;case 8:n=Xv;break;default:n=gs}t=n.bind(null,l,t,e),n=void 0,!Su||l!=="touchstart"&&l!=="touchmove"&&l!=="wheel"||(n=!0),a?n!==void 0?e.addEventListener(l,t,{capture:!0,passive:n}):e.addEventListener(l,t,!0):n!==void 0?e.addEventListener(l,t,{passive:n}):e.addEventListener(l,t,!1)}function as(e,l,t,a,n){var u=a;if((l&1)===0&&(l&2)===0&&a!==null)e:for(;;){if(a===null)return;var c=a.tag;if(c===3||c===4){var r=a.stateNode.containerInfo;if(r===n)break;if(c===4)for(c=a.return;c!==null;){var h=c.tag;if((h===3||h===4)&&c.stateNode.containerInfo===n)return;c=c.return}for(;r!==null;){if(c=Vt(r),c===null)return;if(h=c.tag,h===5||h===6||h===26||h===27){a=u=c;continue e}r=r.parentNode}}a=a.return}sr(function(){var N=u,M=bu(t),U=[];e:{var A=kr.get(e);if(A!==void 0){var _=Xn,Z=e;switch(e){case"keypress":if(Gn(t)===0)break e;case"keydown":case"keyup":_=cm;break;case"focusin":Z="focus",_=Au;break;case"focusout":Z="blur",_=Au;break;case"beforeblur":case"afterblur":_=Au;break;case"click":if(t.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":_=fr;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":_=$h;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":_=dm;break;case Ur:case Dr:case Rr:_=Ih;break;case Hr:_=om;break;case"scroll":case"scrollend":_=Vh;break;case"wheel":_=mm;break;case"copy":case"cut":case"paste":_=em;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":_=hr;break;case"toggle":case"beforetoggle":_=ym}var I=(l&4)!==0,Ee=!I&&(e==="scroll"||e==="scrollend"),b=I?A!==null?A+"Capture":null:A;I=[];for(var y=N,S;y!==null;){var O=y;if(S=O.stateNode,O=O.tag,O!==5&&O!==26&&O!==27||S===null||b===null||(O=Ya(y,b),O!=null&&I.push(jn(y,O,S))),Ee)break;y=y.return}0<I.length&&(A=new _(A,Z,null,t,M),U.push({event:A,listeners:I}))}}if((l&7)===0){e:{if(A=e==="mouseover"||e==="pointerover",_=e==="mouseout"||e==="pointerout",A&&t!==ju&&(Z=t.relatedTarget||t.fromElement)&&(Vt(Z)||Z[Kt]))break e;if((_||A)&&(A=M.window===M?M:(A=M.ownerDocument)?A.defaultView||A.parentWindow:window,_?(Z=t.relatedTarget||t.toElement,_=N,Z=Z?Vt(Z):null,Z!==null&&(Ee=g(Z),I=Z.tag,Z!==Ee||I!==5&&I!==27&&I!==6)&&(Z=null)):(_=null,Z=N),_!==Z)){if(I=fr,O="onMouseLeave",b="onMouseEnter",y="mouse",(e==="pointerout"||e==="pointerover")&&(I=hr,O="onPointerLeave",b="onPointerEnter",y="pointer"),Ee=_==null?A:Ba(_),S=Z==null?A:Ba(Z),A=new I(O,y+"leave",_,t,M),A.target=Ee,A.relatedTarget=S,O=null,Vt(M)===N&&(I=new I(b,y+"enter",Z,t,M),I.target=S,I.relatedTarget=Ee,O=I),Ee=O,_&&Z)l:{for(I=vv,b=_,y=Z,S=0,O=b;O;O=I(O))S++;O=0;for(var W=y;W;W=I(W))O++;for(;0<S-O;)b=I(b),S--;for(;0<O-S;)y=I(y),O--;for(;S--;){if(b===y||y!==null&&b===y.alternate){I=b;break l}b=I(b),y=I(y)}I=null}else I=null;_!==null&&io(U,A,_,I,!1),Z!==null&&Ee!==null&&io(U,Ee,Z,I,!0)}}e:{if(A=N?Ba(N):window,_=A.nodeName&&A.nodeName.toLowerCase(),_==="select"||_==="input"&&A.type==="file")var ye=xr;else if(jr(A))if(Sr)ye=Am;else{ye=Em;var J=Nm}else _=A.nodeName,!_||_.toLowerCase()!=="input"||A.type!=="checkbox"&&A.type!=="radio"?N&&pu(N.elementType)&&(ye=xr):ye=Tm;if(ye&&(ye=ye(e,N))){br(U,ye,t,M);break e}J&&J(e,A,N),e==="focusout"&&N&&A.type==="number"&&N.memoizedProps.value!=null&&gu(A,"number",A.value)}switch(J=N?Ba(N):window,e){case"focusin":(jr(J)||J.contentEditable==="true")&&(ta=J,Uu=N,Va=null);break;case"focusout":Va=Uu=ta=null;break;case"mousedown":Du=!0;break;case"contextmenu":case"mouseup":case"dragend":Du=!1,Cr(U,t,M);break;case"selectionchange":if(_m)break;case"keydown":case"keyup":Cr(U,t,M)}var ue;if(_u)e:{switch(e){case"compositionstart":var he="onCompositionStart";break e;case"compositionend":he="onCompositionEnd";break e;case"compositionupdate":he="onCompositionUpdate";break e}he=void 0}else la?gr(e,t)&&(he="onCompositionEnd"):e==="keydown"&&t.keyCode===229&&(he="onCompositionStart");he&&(mr&&t.locale!=="ko"&&(la||he!=="onCompositionStart"?he==="onCompositionEnd"&&la&&(ue=rr()):(nt=M,Nu="value"in nt?nt.value:nt.textContent,la=!0)),J=Di(N,he),0<J.length&&(he=new or(he,e,null,t,M),U.push({event:he,listeners:J}),ue?he.data=ue:(ue=pr(t),ue!==null&&(he.data=ue)))),(ue=pm?jm(e,t):bm(e,t))&&(he=Di(N,"onBeforeInput"),0<he.length&&(J=new or("onBeforeInput","beforeinput",null,t,M),U.push({event:J,listeners:he}),J.data=ue)),fv(U,e,N,t,M)}ao(U,l)})}function jn(e,l,t){return{instance:e,listener:l,currentTarget:t}}function Di(e,l){for(var t=l+"Capture",a=[];e!==null;){var n=e,u=n.stateNode;if(n=n.tag,n!==5&&n!==26&&n!==27||u===null||(n=Ya(e,t),n!=null&&a.unshift(jn(e,n,u)),n=Ya(e,l),n!=null&&a.push(jn(e,n,u))),e.tag===3)return a;e=e.return}return[]}function vv(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function io(e,l,t,a,n){for(var u=l._reactName,c=[];t!==null&&t!==a;){var r=t,h=r.alternate,N=r.stateNode;if(r=r.tag,h!==null&&h===a)break;r!==5&&r!==26&&r!==27||N===null||(h=N,n?(N=Ya(t,u),N!=null&&c.unshift(jn(t,N,h))):n||(N=Ya(t,u),N!=null&&c.push(jn(t,N,h)))),t=t.return}c.length!==0&&e.push({event:l,listeners:c})}var yv=/\r\n?/g,gv=/\u0000|\uFFFD/g;function uo(e){return(typeof e=="string"?e:""+e).replace(yv,`
|
|
9
|
+
`).replace(gv,"")}function co(e,l){return l=uo(l),uo(e)===l}function Ne(e,l,t,a,n,u){switch(t){case"children":typeof a=="string"?l==="body"||l==="textarea"&&a===""||It(e,a):(typeof a=="number"||typeof a=="bigint")&&l!=="body"&&It(e,""+a);break;case"className":qn(e,"class",a);break;case"tabIndex":qn(e,"tabindex",a);break;case"dir":case"role":case"viewBox":case"width":case"height":qn(e,t,a);break;case"style":ur(e,a,u);break;case"data":if(l!=="object"){qn(e,"data",a);break}case"src":case"href":if(a===""&&(l!=="a"||t!=="href")){e.removeAttribute(t);break}if(a==null||typeof a=="function"||typeof a=="symbol"||typeof a=="boolean"){e.removeAttribute(t);break}a=Yn(""+a),e.setAttribute(t,a);break;case"action":case"formAction":if(typeof a=="function"){e.setAttribute(t,"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"&&(t==="formAction"?(l!=="input"&&Ne(e,l,"name",n.name,n,null),Ne(e,l,"formEncType",n.formEncType,n,null),Ne(e,l,"formMethod",n.formMethod,n,null),Ne(e,l,"formTarget",n.formTarget,n,null)):(Ne(e,l,"encType",n.encType,n,null),Ne(e,l,"method",n.method,n,null),Ne(e,l,"target",n.target,n,null)));if(a==null||typeof a=="symbol"||typeof a=="boolean"){e.removeAttribute(t);break}a=Yn(""+a),e.setAttribute(t,a);break;case"onClick":a!=null&&(e.onclick=ql);break;case"onScroll":a!=null&&fe("scroll",e);break;case"onScrollEnd":a!=null&&fe("scrollend",e);break;case"dangerouslySetInnerHTML":if(a!=null){if(typeof a!="object"||!("__html"in a))throw Error(f(61));if(t=a.__html,t!=null){if(n.children!=null)throw Error(f(60));e.innerHTML=t}}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}t=Yn(""+a),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",t);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(t,""+a):e.removeAttribute(t);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(t,""):e.removeAttribute(t);break;case"capture":case"download":a===!0?e.setAttribute(t,""):a!==!1&&a!=null&&typeof a!="function"&&typeof a!="symbol"?e.setAttribute(t,a):e.removeAttribute(t);break;case"cols":case"rows":case"size":case"span":a!=null&&typeof a!="function"&&typeof a!="symbol"&&!isNaN(a)&&1<=a?e.setAttribute(t,a):e.removeAttribute(t);break;case"rowSpan":case"start":a==null||typeof a=="function"||typeof a=="symbol"||isNaN(a)?e.removeAttribute(t):e.setAttribute(t,a);break;case"popover":fe("beforetoggle",e),fe("toggle",e),kn(e,"popover",a);break;case"xlinkActuate":kl(e,"http://www.w3.org/1999/xlink","xlink:actuate",a);break;case"xlinkArcrole":kl(e,"http://www.w3.org/1999/xlink","xlink:arcrole",a);break;case"xlinkRole":kl(e,"http://www.w3.org/1999/xlink","xlink:role",a);break;case"xlinkShow":kl(e,"http://www.w3.org/1999/xlink","xlink:show",a);break;case"xlinkTitle":kl(e,"http://www.w3.org/1999/xlink","xlink:title",a);break;case"xlinkType":kl(e,"http://www.w3.org/1999/xlink","xlink:type",a);break;case"xmlBase":kl(e,"http://www.w3.org/XML/1998/namespace","xml:base",a);break;case"xmlLang":kl(e,"http://www.w3.org/XML/1998/namespace","xml:lang",a);break;case"xmlSpace":kl(e,"http://www.w3.org/XML/1998/namespace","xml:space",a);break;case"is":kn(e,"is",a);break;case"innerText":case"textContent":break;default:(!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(t=Zh.get(t)||t,kn(e,t,a))}}function ns(e,l,t,a,n,u){switch(t){case"style":ur(e,a,u);break;case"dangerouslySetInnerHTML":if(a!=null){if(typeof a!="object"||!("__html"in a))throw Error(f(61));if(t=a.__html,t!=null){if(n.children!=null)throw Error(f(60));e.innerHTML=t}}break;case"children":typeof a=="string"?It(e,a):(typeof a=="number"||typeof a=="bigint")&&It(e,""+a);break;case"onScroll":a!=null&&fe("scroll",e);break;case"onScrollEnd":a!=null&&fe("scrollend",e);break;case"onClick":a!=null&&(e.onclick=ql);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!Fs.hasOwnProperty(t))e:{if(t[0]==="o"&&t[1]==="n"&&(n=t.endsWith("Capture"),l=t.slice(2,n?t.length-7:void 0),u=e[ll]||null,u=u!=null?u[t]:null,typeof u=="function"&&e.removeEventListener(l,u,n),typeof a=="function")){typeof u!="function"&&u!==null&&(t in e?e[t]=null:e.hasAttribute(t)&&e.removeAttribute(t)),e.addEventListener(l,a,n);break e}t in e?e[t]=a:a===!0?e.setAttribute(t,""):kn(e,t,a)}}}function $e(e,l,t){switch(l){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":fe("error",e),fe("load",e);var a=!1,n=!1,u;for(u in t)if(t.hasOwnProperty(u)){var c=t[u];if(c!=null)switch(u){case"src":a=!0;break;case"srcSet":n=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(f(137,l));default:Ne(e,l,u,c,t,null)}}n&&Ne(e,l,"srcSet",t.srcSet,t,null),a&&Ne(e,l,"src",t.src,t,null);return;case"input":fe("invalid",e);var r=u=c=n=null,h=null,N=null;for(a in t)if(t.hasOwnProperty(a)){var M=t[a];if(M!=null)switch(a){case"name":n=M;break;case"type":c=M;break;case"checked":h=M;break;case"defaultChecked":N=M;break;case"value":u=M;break;case"defaultValue":r=M;break;case"children":case"dangerouslySetInnerHTML":if(M!=null)throw Error(f(137,l));break;default:Ne(e,l,a,M,t,null)}}tr(e,u,r,h,N,c,n,!1);return;case"select":fe("invalid",e),a=c=u=null;for(n in t)if(t.hasOwnProperty(n)&&(r=t[n],r!=null))switch(n){case"value":u=r;break;case"defaultValue":c=r;break;case"multiple":a=r;default:Ne(e,l,n,r,t,null)}l=u,t=c,e.multiple=!!a,l!=null?Ft(e,!!a,l,!1):t!=null&&Ft(e,!!a,t,!0);return;case"textarea":fe("invalid",e),u=n=a=null;for(c in t)if(t.hasOwnProperty(c)&&(r=t[c],r!=null))switch(c){case"value":a=r;break;case"defaultValue":n=r;break;case"children":u=r;break;case"dangerouslySetInnerHTML":if(r!=null)throw Error(f(91));break;default:Ne(e,l,c,r,t,null)}nr(e,a,n,u);return;case"option":for(h in t)t.hasOwnProperty(h)&&(a=t[h],a!=null)&&(h==="selected"?e.selected=a&&typeof a!="function"&&typeof a!="symbol":Ne(e,l,h,a,t,null));return;case"dialog":fe("beforetoggle",e),fe("toggle",e),fe("cancel",e),fe("close",e);break;case"iframe":case"object":fe("load",e);break;case"video":case"audio":for(a=0;a<pn.length;a++)fe(pn[a],e);break;case"image":fe("error",e),fe("load",e);break;case"details":fe("toggle",e);break;case"embed":case"source":case"link":fe("error",e),fe("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(N in t)if(t.hasOwnProperty(N)&&(a=t[N],a!=null))switch(N){case"children":case"dangerouslySetInnerHTML":throw Error(f(137,l));default:Ne(e,l,N,a,t,null)}return;default:if(pu(l)){for(M in t)t.hasOwnProperty(M)&&(a=t[M],a!==void 0&&ns(e,l,M,a,t,void 0));return}}for(r in t)t.hasOwnProperty(r)&&(a=t[r],a!=null&&Ne(e,l,r,a,t,null))}function pv(e,l,t,a){switch(l){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var n=null,u=null,c=null,r=null,h=null,N=null,M=null;for(_ in t){var U=t[_];if(t.hasOwnProperty(_)&&U!=null)switch(_){case"checked":break;case"value":break;case"defaultValue":h=U;default:a.hasOwnProperty(_)||Ne(e,l,_,null,a,U)}}for(var A in a){var _=a[A];if(U=t[A],a.hasOwnProperty(A)&&(_!=null||U!=null))switch(A){case"type":u=_;break;case"name":n=_;break;case"checked":N=_;break;case"defaultChecked":M=_;break;case"value":c=_;break;case"defaultValue":r=_;break;case"children":case"dangerouslySetInnerHTML":if(_!=null)throw Error(f(137,l));break;default:_!==U&&Ne(e,l,A,_,a,U)}}yu(e,c,r,h,N,M,u,n);return;case"select":_=c=r=A=null;for(u in t)if(h=t[u],t.hasOwnProperty(u)&&h!=null)switch(u){case"value":break;case"multiple":_=h;default:a.hasOwnProperty(u)||Ne(e,l,u,null,a,h)}for(n in a)if(u=a[n],h=t[n],a.hasOwnProperty(n)&&(u!=null||h!=null))switch(n){case"value":A=u;break;case"defaultValue":r=u;break;case"multiple":c=u;default:u!==h&&Ne(e,l,n,u,a,h)}l=r,t=c,a=_,A!=null?Ft(e,!!t,A,!1):!!a!=!!t&&(l!=null?Ft(e,!!t,l,!0):Ft(e,!!t,t?[]:"",!1));return;case"textarea":_=A=null;for(r in t)if(n=t[r],t.hasOwnProperty(r)&&n!=null&&!a.hasOwnProperty(r))switch(r){case"value":break;case"children":break;default:Ne(e,l,r,null,a,n)}for(c in a)if(n=a[c],u=t[c],a.hasOwnProperty(c)&&(n!=null||u!=null))switch(c){case"value":A=n;break;case"defaultValue":_=n;break;case"children":break;case"dangerouslySetInnerHTML":if(n!=null)throw Error(f(91));break;default:n!==u&&Ne(e,l,c,n,a,u)}ar(e,A,_);return;case"option":for(var Z in t)A=t[Z],t.hasOwnProperty(Z)&&A!=null&&!a.hasOwnProperty(Z)&&(Z==="selected"?e.selected=!1:Ne(e,l,Z,null,a,A));for(h in a)A=a[h],_=t[h],a.hasOwnProperty(h)&&A!==_&&(A!=null||_!=null)&&(h==="selected"?e.selected=A&&typeof A!="function"&&typeof A!="symbol":Ne(e,l,h,A,a,_));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 I in t)A=t[I],t.hasOwnProperty(I)&&A!=null&&!a.hasOwnProperty(I)&&Ne(e,l,I,null,a,A);for(N in a)if(A=a[N],_=t[N],a.hasOwnProperty(N)&&A!==_&&(A!=null||_!=null))switch(N){case"children":case"dangerouslySetInnerHTML":if(A!=null)throw Error(f(137,l));break;default:Ne(e,l,N,A,a,_)}return;default:if(pu(l)){for(var Ee in t)A=t[Ee],t.hasOwnProperty(Ee)&&A!==void 0&&!a.hasOwnProperty(Ee)&&ns(e,l,Ee,void 0,a,A);for(M in a)A=a[M],_=t[M],!a.hasOwnProperty(M)||A===_||A===void 0&&_===void 0||ns(e,l,M,A,a,_);return}}for(var b in t)A=t[b],t.hasOwnProperty(b)&&A!=null&&!a.hasOwnProperty(b)&&Ne(e,l,b,null,a,A);for(U in a)A=a[U],_=t[U],!a.hasOwnProperty(U)||A===_||A==null&&_==null||Ne(e,l,U,A,a,_)}function so(e){switch(e){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function jv(){if(typeof performance.getEntriesByType=="function"){for(var e=0,l=0,t=performance.getEntriesByType("resource"),a=0;a<t.length;a++){var n=t[a],u=n.transferSize,c=n.initiatorType,r=n.duration;if(u&&r&&so(c)){for(c=0,r=n.responseEnd,a+=1;a<t.length;a++){var h=t[a],N=h.startTime;if(N>r)break;var M=h.transferSize,U=h.initiatorType;M&&so(U)&&(h=h.responseEnd,c+=M*(h<r?1:(r-N)/(h-N)))}if(--a,l+=8*(u+c)/(n.duration/1e3),e++,10<e)break}}if(0<e)return l/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e=="number")?e:5}var is=null,us=null;function Ri(e){return e.nodeType===9?e:e.ownerDocument}function ro(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 fo(e,l){if(e===0)switch(l){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&l==="foreignObject"?0:e}function cs(e,l){return e==="textarea"||e==="noscript"||typeof l.children=="string"||typeof l.children=="number"||typeof l.children=="bigint"||typeof l.dangerouslySetInnerHTML=="object"&&l.dangerouslySetInnerHTML!==null&&l.dangerouslySetInnerHTML.__html!=null}var ss=null;function bv(){var e=window.event;return e&&e.type==="popstate"?e===ss?!1:(ss=e,!0):(ss=null,!1)}var oo=typeof setTimeout=="function"?setTimeout:void 0,xv=typeof clearTimeout=="function"?clearTimeout:void 0,ho=typeof Promise=="function"?Promise:void 0,Sv=typeof queueMicrotask=="function"?queueMicrotask:typeof ho<"u"?function(e){return ho.resolve(null).then(e).catch(Nv)}:oo;function Nv(e){setTimeout(function(){throw e})}function xt(e){return e==="head"}function mo(e,l){var t=l,a=0;do{var n=t.nextSibling;if(e.removeChild(t),n&&n.nodeType===8)if(t=n.data,t==="/$"||t==="/&"){if(a===0){e.removeChild(n),Ma(l);return}a--}else if(t==="$"||t==="$?"||t==="$~"||t==="$!"||t==="&")a++;else if(t==="html")bn(e.ownerDocument.documentElement);else if(t==="head"){t=e.ownerDocument.head,bn(t);for(var u=t.firstChild;u;){var c=u.nextSibling,r=u.nodeName;u[qa]||r==="SCRIPT"||r==="STYLE"||r==="LINK"&&u.rel.toLowerCase()==="stylesheet"||t.removeChild(u),u=c}}else t==="body"&&bn(e.ownerDocument.body);t=n}while(t);Ma(l)}function vo(e,l){var t=e;e=0;do{var a=t.nextSibling;if(t.nodeType===1?l?(t._stashedDisplay=t.style.display,t.style.display="none"):(t.style.display=t._stashedDisplay||"",t.getAttribute("style")===""&&t.removeAttribute("style")):t.nodeType===3&&(l?(t._stashedText=t.nodeValue,t.nodeValue=""):t.nodeValue=t._stashedText||""),a&&a.nodeType===8)if(t=a.data,t==="/$"){if(e===0)break;e--}else t!=="$"&&t!=="$?"&&t!=="$~"&&t!=="$!"||e++;t=a}while(t)}function rs(e){var l=e.firstChild;for(l&&l.nodeType===10&&(l=l.nextSibling);l;){var t=l;switch(l=l.nextSibling,t.nodeName){case"HTML":case"HEAD":case"BODY":rs(t),mu(t);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(t.rel.toLowerCase()==="stylesheet")continue}e.removeChild(t)}}function Ev(e,l,t,a){for(;e.nodeType===1;){var n=t;if(e.nodeName.toLowerCase()!==l.toLowerCase()){if(!a&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(a){if(!e[qa])switch(l){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!==n.rel||e.getAttribute("href")!==(n.href==null||n.href===""?null:n.href)||e.getAttribute("crossorigin")!==(n.crossOrigin==null?null:n.crossOrigin)||e.getAttribute("title")!==(n.title==null?null:n.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(u=e.getAttribute("src"),(u!==(n.src==null?null:n.src)||e.getAttribute("type")!==(n.type==null?null:n.type)||e.getAttribute("crossorigin")!==(n.crossOrigin==null?null:n.crossOrigin))&&u&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else if(l==="input"&&e.type==="hidden"){var u=n.name==null?null:""+n.name;if(n.type==="hidden"&&e.getAttribute("name")===u)return e}else return e;if(e=Al(e.nextSibling),e===null)break}return null}function Tv(e,l,t){if(l==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!t||(e=Al(e.nextSibling),e===null))return null;return e}function yo(e,l){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!l||(e=Al(e.nextSibling),e===null))return null;return e}function ds(e){return e.data==="$?"||e.data==="$~"}function fs(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState!=="loading"}function Av(e,l){var t=e.ownerDocument;if(e.data==="$~")e._reactRetry=l;else if(e.data!=="$?"||t.readyState!=="loading")l();else{var a=function(){l(),t.removeEventListener("DOMContentLoaded",a)};t.addEventListener("DOMContentLoaded",a),e._reactRetry=a}}function Al(e){for(;e!=null;e=e.nextSibling){var l=e.nodeType;if(l===1||l===3)break;if(l===8){if(l=e.data,l==="$"||l==="$!"||l==="$?"||l==="$~"||l==="&"||l==="F!"||l==="F")break;if(l==="/$"||l==="/&")return null}}return e}var os=null;function go(e){e=e.nextSibling;for(var l=0;e;){if(e.nodeType===8){var t=e.data;if(t==="/$"||t==="/&"){if(l===0)return Al(e.nextSibling);l--}else t!=="$"&&t!=="$!"&&t!=="$?"&&t!=="$~"&&t!=="&"||l++}e=e.nextSibling}return null}function po(e){e=e.previousSibling;for(var l=0;e;){if(e.nodeType===8){var t=e.data;if(t==="$"||t==="$!"||t==="$?"||t==="$~"||t==="&"){if(l===0)return e;l--}else t!=="/$"&&t!=="/&"||l++}e=e.previousSibling}return null}function jo(e,l,t){switch(l=Ri(t),e){case"html":if(e=l.documentElement,!e)throw Error(f(452));return e;case"head":if(e=l.head,!e)throw Error(f(453));return e;case"body":if(e=l.body,!e)throw Error(f(454));return e;default:throw Error(f(451))}}function bn(e){for(var l=e.attributes;l.length;)e.removeAttributeNode(l[0]);mu(e)}var zl=new Map,bo=new Set;function Hi(e){return typeof e.getRootNode=="function"?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var Pl=p.d;p.d={f:zv,r:_v,D:Mv,C:Cv,L:Ov,m:Uv,X:Rv,S:Dv,M:Hv};function zv(){var e=Pl.f(),l=Ai();return e||l}function _v(e){var l=Jt(e);l!==null&&l.tag===5&&l.type==="form"?Hd(l):Pl.r(e)}var Aa=typeof document>"u"?null:document;function xo(e,l,t){var a=Aa;if(a&&typeof l=="string"&&l){var n=jl(l);n='link[rel="'+e+'"][href="'+n+'"]',typeof t=="string"&&(n+='[crossorigin="'+t+'"]'),bo.has(n)||(bo.add(n),e={rel:e,crossOrigin:t,href:l},a.querySelector(n)===null&&(l=a.createElement("link"),$e(l,"link",e),Le(l),a.head.appendChild(l)))}}function Mv(e){Pl.D(e),xo("dns-prefetch",e,null)}function Cv(e,l){Pl.C(e,l),xo("preconnect",e,l)}function Ov(e,l,t){Pl.L(e,l,t);var a=Aa;if(a&&e&&l){var n='link[rel="preload"][as="'+jl(l)+'"]';l==="image"&&t&&t.imageSrcSet?(n+='[imagesrcset="'+jl(t.imageSrcSet)+'"]',typeof t.imageSizes=="string"&&(n+='[imagesizes="'+jl(t.imageSizes)+'"]')):n+='[href="'+jl(e)+'"]';var u=n;switch(l){case"style":u=za(e);break;case"script":u=_a(e)}zl.has(u)||(e=k({rel:"preload",href:l==="image"&&t&&t.imageSrcSet?void 0:e,as:l},t),zl.set(u,e),a.querySelector(n)!==null||l==="style"&&a.querySelector(xn(u))||l==="script"&&a.querySelector(Sn(u))||(l=a.createElement("link"),$e(l,"link",e),Le(l),a.head.appendChild(l)))}}function Uv(e,l){Pl.m(e,l);var t=Aa;if(t&&e){var a=l&&typeof l.as=="string"?l.as:"script",n='link[rel="modulepreload"][as="'+jl(a)+'"][href="'+jl(e)+'"]',u=n;switch(a){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":u=_a(e)}if(!zl.has(u)&&(e=k({rel:"modulepreload",href:e},l),zl.set(u,e),t.querySelector(n)===null)){switch(a){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(t.querySelector(Sn(u)))return}a=t.createElement("link"),$e(a,"link",e),Le(a),t.head.appendChild(a)}}}function Dv(e,l,t){Pl.S(e,l,t);var a=Aa;if(a&&e){var n=$t(a).hoistableStyles,u=za(e);l=l||"default";var c=n.get(u);if(!c){var r={loading:0,preload:null};if(c=a.querySelector(xn(u)))r.loading=5;else{e=k({rel:"stylesheet",href:e,"data-precedence":l},t),(t=zl.get(u))&&hs(e,t);var h=c=a.createElement("link");Le(h),$e(h,"link",e),h._p=new Promise(function(N,M){h.onload=N,h.onerror=M}),h.addEventListener("load",function(){r.loading|=1}),h.addEventListener("error",function(){r.loading|=2}),r.loading|=4,ki(c,l,a)}c={type:"stylesheet",instance:c,count:1,state:r},n.set(u,c)}}}function Rv(e,l){Pl.X(e,l);var t=Aa;if(t&&e){var a=$t(t).hoistableScripts,n=_a(e),u=a.get(n);u||(u=t.querySelector(Sn(n)),u||(e=k({src:e,async:!0},l),(l=zl.get(n))&&ms(e,l),u=t.createElement("script"),Le(u),$e(u,"link",e),t.head.appendChild(u)),u={type:"script",instance:u,count:1,state:null},a.set(n,u))}}function Hv(e,l){Pl.M(e,l);var t=Aa;if(t&&e){var a=$t(t).hoistableScripts,n=_a(e),u=a.get(n);u||(u=t.querySelector(Sn(n)),u||(e=k({src:e,async:!0,type:"module"},l),(l=zl.get(n))&&ms(e,l),u=t.createElement("script"),Le(u),$e(u,"link",e),t.head.appendChild(u)),u={type:"script",instance:u,count:1,state:null},a.set(n,u))}}function So(e,l,t,a){var n=(n=re.current)?Hi(n):null;if(!n)throw Error(f(446));switch(e){case"meta":case"title":return null;case"style":return typeof t.precedence=="string"&&typeof t.href=="string"?(l=za(t.href),t=$t(n).hoistableStyles,a=t.get(l),a||(a={type:"style",instance:null,count:0,state:null},t.set(l,a)),a):{type:"void",instance:null,count:0,state:null};case"link":if(t.rel==="stylesheet"&&typeof t.href=="string"&&typeof t.precedence=="string"){e=za(t.href);var u=$t(n).hoistableStyles,c=u.get(e);if(c||(n=n.ownerDocument||n,c={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},u.set(e,c),(u=n.querySelector(xn(e)))&&!u._p&&(c.instance=u,c.state.loading=5),zl.has(e)||(t={rel:"preload",as:"style",href:t.href,crossOrigin:t.crossOrigin,integrity:t.integrity,media:t.media,hrefLang:t.hrefLang,referrerPolicy:t.referrerPolicy},zl.set(e,t),u||kv(n,e,t,c.state))),l&&a===null)throw Error(f(528,""));return c}if(l&&a!==null)throw Error(f(529,""));return null;case"script":return l=t.async,t=t.src,typeof t=="string"&&l&&typeof l!="function"&&typeof l!="symbol"?(l=_a(t),t=$t(n).hoistableScripts,a=t.get(l),a||(a={type:"script",instance:null,count:0,state:null},t.set(l,a)),a):{type:"void",instance:null,count:0,state:null};default:throw Error(f(444,e))}}function za(e){return'href="'+jl(e)+'"'}function xn(e){return'link[rel="stylesheet"]['+e+"]"}function No(e){return k({},e,{"data-precedence":e.precedence,precedence:null})}function kv(e,l,t,a){e.querySelector('link[rel="preload"][as="style"]['+l+"]")?a.loading=1:(l=e.createElement("link"),a.preload=l,l.addEventListener("load",function(){return a.loading|=1}),l.addEventListener("error",function(){return a.loading|=2}),$e(l,"link",t),Le(l),e.head.appendChild(l))}function _a(e){return'[src="'+jl(e)+'"]'}function Sn(e){return"script[async]"+e}function Eo(e,l,t){if(l.count++,l.instance===null)switch(l.type){case"style":var a=e.querySelector('style[data-href~="'+jl(t.href)+'"]');if(a)return l.instance=a,Le(a),a;var n=k({},t,{"data-href":t.href,"data-precedence":t.precedence,href:null,precedence:null});return a=(e.ownerDocument||e).createElement("style"),Le(a),$e(a,"style",n),ki(a,t.precedence,e),l.instance=a;case"stylesheet":n=za(t.href);var u=e.querySelector(xn(n));if(u)return l.state.loading|=4,l.instance=u,Le(u),u;a=No(t),(n=zl.get(n))&&hs(a,n),u=(e.ownerDocument||e).createElement("link"),Le(u);var c=u;return c._p=new Promise(function(r,h){c.onload=r,c.onerror=h}),$e(u,"link",a),l.state.loading|=4,ki(u,t.precedence,e),l.instance=u;case"script":return u=_a(t.src),(n=e.querySelector(Sn(u)))?(l.instance=n,Le(n),n):(a=t,(n=zl.get(u))&&(a=k({},t),ms(a,n)),e=e.ownerDocument||e,n=e.createElement("script"),Le(n),$e(n,"link",a),e.head.appendChild(n),l.instance=n);case"void":return null;default:throw Error(f(443,l.type))}else l.type==="stylesheet"&&(l.state.loading&4)===0&&(a=l.instance,l.state.loading|=4,ki(a,t.precedence,e));return l.instance}function ki(e,l,t){for(var a=t.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),n=a.length?a[a.length-1]:null,u=n,c=0;c<a.length;c++){var r=a[c];if(r.dataset.precedence===l)u=r;else if(u!==n)break}u?u.parentNode.insertBefore(e,u.nextSibling):(l=t.nodeType===9?t.head:t,l.insertBefore(e,l.firstChild))}function hs(e,l){e.crossOrigin==null&&(e.crossOrigin=l.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=l.referrerPolicy),e.title==null&&(e.title=l.title)}function ms(e,l){e.crossOrigin==null&&(e.crossOrigin=l.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=l.referrerPolicy),e.integrity==null&&(e.integrity=l.integrity)}var qi=null;function To(e,l,t){if(qi===null){var a=new Map,n=qi=new Map;n.set(t,a)}else n=qi,a=n.get(t),a||(a=new Map,n.set(t,a));if(a.has(e))return a;for(a.set(e,null),t=t.getElementsByTagName(e),n=0;n<t.length;n++){var u=t[n];if(!(u[qa]||u[Ze]||e==="link"&&u.getAttribute("rel")==="stylesheet")&&u.namespaceURI!=="http://www.w3.org/2000/svg"){var c=u.getAttribute(l)||"";c=e+c;var r=a.get(c);r?r.push(u):a.set(c,[u])}}return a}function Ao(e,l,t){e=e.ownerDocument||e,e.head.insertBefore(t,l==="title"?e.querySelector("head > title"):null)}function qv(e,l,t){if(t===1||l.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof l.precedence!="string"||typeof l.href!="string"||l.href==="")break;return!0;case"link":if(typeof l.rel!="string"||typeof l.href!="string"||l.href===""||l.onLoad||l.onError)break;return l.rel==="stylesheet"?(e=l.disabled,typeof l.precedence=="string"&&e==null):!0;case"script":if(l.async&&typeof l.async!="function"&&typeof l.async!="symbol"&&!l.onLoad&&!l.onError&&l.src&&typeof l.src=="string")return!0}return!1}function zo(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}function Bv(e,l,t,a){if(t.type==="stylesheet"&&(typeof a.media!="string"||matchMedia(a.media).matches!==!1)&&(t.state.loading&4)===0){if(t.instance===null){var n=za(a.href),u=l.querySelector(xn(n));if(u){l=u._p,l!==null&&typeof l=="object"&&typeof l.then=="function"&&(e.count++,e=Bi.bind(e),l.then(e,e)),t.state.loading|=4,t.instance=u,Le(u);return}u=l.ownerDocument||l,a=No(a),(n=zl.get(n))&&hs(a,n),u=u.createElement("link"),Le(u);var c=u;c._p=new Promise(function(r,h){c.onload=r,c.onerror=h}),$e(u,"link",a),t.instance=u}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(t,l),(l=t.state.preload)&&(t.state.loading&3)===0&&(e.count++,t=Bi.bind(e),l.addEventListener("load",t),l.addEventListener("error",t))}}var vs=0;function Yv(e,l){return e.stylesheets&&e.count===0&&wi(e,e.stylesheets),0<e.count||0<e.imgCount?function(t){var a=setTimeout(function(){if(e.stylesheets&&wi(e,e.stylesheets),e.unsuspend){var u=e.unsuspend;e.unsuspend=null,u()}},6e4+l);0<e.imgBytes&&vs===0&&(vs=62500*jv());var n=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&wi(e,e.stylesheets),e.unsuspend)){var u=e.unsuspend;e.unsuspend=null,u()}},(e.imgBytes>vs?50:800)+l);return e.unsuspend=t,function(){e.unsuspend=null,clearTimeout(a),clearTimeout(n)}}:null}function Bi(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)wi(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Yi=null;function wi(e,l){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Yi=new Map,l.forEach(wv,e),Yi=null,Bi.call(e))}function wv(e,l){if(!(l.state.loading&4)){var t=Yi.get(e);if(t)var a=t.get(null);else{t=new Map,Yi.set(e,t);for(var n=e.querySelectorAll("link[data-precedence],style[data-precedence]"),u=0;u<n.length;u++){var c=n[u];(c.nodeName==="LINK"||c.getAttribute("media")!=="not all")&&(t.set(c.dataset.precedence,c),a=c)}a&&t.set(null,a)}n=l.instance,c=n.getAttribute("data-precedence"),u=t.get(c)||a,u===a&&t.set(null,n),t.set(c,n),this.count++,a=Bi.bind(this),n.addEventListener("load",a),n.addEventListener("error",a),u?u.parentNode.insertBefore(n,u.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(n,e.firstChild)),l.state.loading|=4}}var Nn={$$typeof:P,Provider:null,Consumer:null,_currentValue:Y,_currentValue2:Y,_threadCount:0};function Gv(e,l,t,a,n,u,c,r,h){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=du(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=du(0),this.hiddenUpdates=du(null),this.identifierPrefix=a,this.onUncaughtError=n,this.onCaughtError=u,this.onRecoverableError=c,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=h,this.incompleteTransitions=new Map}function _o(e,l,t,a,n,u,c,r,h,N,M,U){return e=new Gv(e,l,t,c,h,N,M,U,r),l=1,u===!0&&(l|=24),u=ol(3,null,null,l),e.current=u,u.stateNode=e,l=Ju(),l.refCount++,e.pooledCache=l,l.refCount++,u.memoizedState={element:a,isDehydrated:t,cache:l},Iu(u),e}function Mo(e){return e?(e=ia,e):ia}function Co(e,l,t,a,n,u){n=Mo(n),a.context===null?a.context=n:a.pendingContext=n,a=dt(l),a.payload={element:t},u=u===void 0?null:u,u!==null&&(a.callback=u),t=ft(e,a,l),t!==null&&(cl(t,e,l),en(t,e,l))}function Oo(e,l){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var t=e.retryLane;e.retryLane=t!==0&&t<l?t:l}}function ys(e,l){Oo(e,l),(e=e.alternate)&&Oo(e,l)}function Uo(e){if(e.tag===13||e.tag===31){var l=Dt(e,67108864);l!==null&&cl(l,e,67108864),ys(e,67108864)}}function Do(e){if(e.tag===13||e.tag===31){var l=gl();l=fu(l);var t=Dt(e,l);t!==null&&cl(t,e,l),ys(e,l)}}var Gi=!0;function Lv(e,l,t,a){var n=z.T;z.T=null;var u=p.p;try{p.p=2,gs(e,l,t,a)}finally{p.p=u,z.T=n}}function Xv(e,l,t,a){var n=z.T;z.T=null;var u=p.p;try{p.p=8,gs(e,l,t,a)}finally{p.p=u,z.T=n}}function gs(e,l,t,a){if(Gi){var n=ps(a);if(n===null)as(e,l,a,Li,t),Ho(e,a);else if(Zv(n,e,l,t,a))a.stopPropagation();else if(Ho(e,a),l&4&&-1<Qv.indexOf(e)){for(;n!==null;){var u=Jt(n);if(u!==null)switch(u.tag){case 3:if(u=u.stateNode,u.current.memoizedState.isDehydrated){var c=_t(u.pendingLanes);if(c!==0){var r=u;for(r.pendingLanes|=2,r.entangledLanes|=2;c;){var h=1<<31-dl(c);r.entanglements[1]|=h,c&=~h}Hl(u),(pe&6)===0&&(Ei=sl()+500,gn(0))}}break;case 31:case 13:r=Dt(u,2),r!==null&&cl(r,u,2),Ai(),ys(u,2)}if(u=ps(a),u===null&&as(e,l,a,Li,t),u===n)break;n=u}n!==null&&a.stopPropagation()}else as(e,l,a,null,t)}}function ps(e){return e=bu(e),js(e)}var Li=null;function js(e){if(Li=null,e=Vt(e),e!==null){var l=g(e);if(l===null)e=null;else{var t=l.tag;if(t===13){if(e=j(l),e!==null)return e;e=null}else if(t===31){if(e=E(l),e!==null)return e;e=null}else if(t===3){if(l.stateNode.current.memoizedState.isDehydrated)return l.tag===3?l.stateNode.containerInfo:null;e=null}else l!==e&&(e=null)}}return Li=e,null}function Ro(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(Mh()){case ws:return 2;case Gs:return 8;case On:case Ch:return 32;case Ls:return 268435456;default:return 32}default:return 32}}var bs=!1,St=null,Nt=null,Et=null,En=new Map,Tn=new Map,Tt=[],Qv="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 Ho(e,l){switch(e){case"focusin":case"focusout":St=null;break;case"dragenter":case"dragleave":Nt=null;break;case"mouseover":case"mouseout":Et=null;break;case"pointerover":case"pointerout":En.delete(l.pointerId);break;case"gotpointercapture":case"lostpointercapture":Tn.delete(l.pointerId)}}function An(e,l,t,a,n,u){return e===null||e.nativeEvent!==u?(e={blockedOn:l,domEventName:t,eventSystemFlags:a,nativeEvent:u,targetContainers:[n]},l!==null&&(l=Jt(l),l!==null&&Uo(l)),e):(e.eventSystemFlags|=a,l=e.targetContainers,n!==null&&l.indexOf(n)===-1&&l.push(n),e)}function Zv(e,l,t,a,n){switch(l){case"focusin":return St=An(St,e,l,t,a,n),!0;case"dragenter":return Nt=An(Nt,e,l,t,a,n),!0;case"mouseover":return Et=An(Et,e,l,t,a,n),!0;case"pointerover":var u=n.pointerId;return En.set(u,An(En.get(u)||null,e,l,t,a,n)),!0;case"gotpointercapture":return u=n.pointerId,Tn.set(u,An(Tn.get(u)||null,e,l,t,a,n)),!0}return!1}function ko(e){var l=Vt(e.target);if(l!==null){var t=g(l);if(t!==null){if(l=t.tag,l===13){if(l=j(t),l!==null){e.blockedOn=l,Js(e.priority,function(){Do(t)});return}}else if(l===31){if(l=E(t),l!==null){e.blockedOn=l,Js(e.priority,function(){Do(t)});return}}else if(l===3&&t.stateNode.current.memoizedState.isDehydrated){e.blockedOn=t.tag===3?t.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Xi(e){if(e.blockedOn!==null)return!1;for(var l=e.targetContainers;0<l.length;){var t=ps(e.nativeEvent);if(t===null){t=e.nativeEvent;var a=new t.constructor(t.type,t);ju=a,t.target.dispatchEvent(a),ju=null}else return l=Jt(t),l!==null&&Uo(l),e.blockedOn=t,!1;l.shift()}return!0}function qo(e,l,t){Xi(e)&&t.delete(l)}function Kv(){bs=!1,St!==null&&Xi(St)&&(St=null),Nt!==null&&Xi(Nt)&&(Nt=null),Et!==null&&Xi(Et)&&(Et=null),En.forEach(qo),Tn.forEach(qo)}function Qi(e,l){e.blockedOn===l&&(e.blockedOn=null,bs||(bs=!0,s.unstable_scheduleCallback(s.unstable_NormalPriority,Kv)))}var Zi=null;function Bo(e){Zi!==e&&(Zi=e,s.unstable_scheduleCallback(s.unstable_NormalPriority,function(){Zi===e&&(Zi=null);for(var l=0;l<e.length;l+=3){var t=e[l],a=e[l+1],n=e[l+2];if(typeof a!="function"){if(js(a||t)===null)continue;break}var u=Jt(t);u!==null&&(e.splice(l,3),l-=3,pc(u,{pending:!0,data:n,method:t.method,action:a},a,n))}}))}function Ma(e){function l(h){return Qi(h,e)}St!==null&&Qi(St,e),Nt!==null&&Qi(Nt,e),Et!==null&&Qi(Et,e),En.forEach(l),Tn.forEach(l);for(var t=0;t<Tt.length;t++){var a=Tt[t];a.blockedOn===e&&(a.blockedOn=null)}for(;0<Tt.length&&(t=Tt[0],t.blockedOn===null);)ko(t),t.blockedOn===null&&Tt.shift();if(t=(e.ownerDocument||e).$$reactFormReplay,t!=null)for(a=0;a<t.length;a+=3){var n=t[a],u=t[a+1],c=n[ll]||null;if(typeof u=="function")c||Bo(t);else if(c){var r=null;if(u&&u.hasAttribute("formAction")){if(n=u,c=u[ll]||null)r=c.formAction;else if(js(n)!==null)continue}else r=c.action;typeof r=="function"?t[a+1]=r:(t.splice(a,3),a-=3),Bo(t)}}}function Yo(){function e(u){u.canIntercept&&u.info==="react-transition"&&u.intercept({handler:function(){return new Promise(function(c){return n=c})},focusReset:"manual",scroll:"manual"})}function l(){n!==null&&(n(),n=null),a||setTimeout(t,20)}function t(){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,n=null;return navigation.addEventListener("navigate",e),navigation.addEventListener("navigatesuccess",l),navigation.addEventListener("navigateerror",l),setTimeout(t,100),function(){a=!0,navigation.removeEventListener("navigate",e),navigation.removeEventListener("navigatesuccess",l),navigation.removeEventListener("navigateerror",l),n!==null&&(n(),n=null)}}}function xs(e){this._internalRoot=e}Ki.prototype.render=xs.prototype.render=function(e){var l=this._internalRoot;if(l===null)throw Error(f(409));var t=l.current,a=gl();Co(t,a,e,l,null,null)},Ki.prototype.unmount=xs.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var l=e.containerInfo;Co(e.current,2,null,e,null,null),Ai(),l[Kt]=null}};function Ki(e){this._internalRoot=e}Ki.prototype.unstable_scheduleHydration=function(e){if(e){var l=Vs();e={blockedOn:null,target:e,priority:l};for(var t=0;t<Tt.length&&l!==0&&l<Tt[t].priority;t++);Tt.splice(t,0,e),t===0&&ko(e)}};var wo=d.version;if(wo!=="19.2.7")throw Error(f(527,wo,"19.2.7"));p.findDOMNode=function(e){var l=e._reactInternals;if(l===void 0)throw typeof e.render=="function"?Error(f(188)):(e=Object.keys(e).join(","),Error(f(268,e)));return e=x(l),e=e!==null?B(e):null,e=e===null?null:e.stateNode,e};var Vv={bundleType:0,version:"19.2.7",rendererPackageName:"react-dom",currentDispatcherRef:z,reconcilerVersion:"19.2.7"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Vi=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Vi.isDisabled&&Vi.supportsFiber)try{Ra=Vi.inject(Vv),rl=Vi}catch{}}return _n.createRoot=function(e,l){if(!m(e))throw Error(f(299));var t=!1,a="",n=Zd,u=Kd,c=Vd;return l!=null&&(l.unstable_strictMode===!0&&(t=!0),l.identifierPrefix!==void 0&&(a=l.identifierPrefix),l.onUncaughtError!==void 0&&(n=l.onUncaughtError),l.onCaughtError!==void 0&&(u=l.onCaughtError),l.onRecoverableError!==void 0&&(c=l.onRecoverableError)),l=_o(e,1,!1,null,null,t,a,null,n,u,c,Yo),e[Kt]=l.current,ts(e),new xs(l)},_n.hydrateRoot=function(e,l,t){if(!m(e))throw Error(f(299));var a=!1,n="",u=Zd,c=Kd,r=Vd,h=null;return t!=null&&(t.unstable_strictMode===!0&&(a=!0),t.identifierPrefix!==void 0&&(n=t.identifierPrefix),t.onUncaughtError!==void 0&&(u=t.onUncaughtError),t.onCaughtError!==void 0&&(c=t.onCaughtError),t.onRecoverableError!==void 0&&(r=t.onRecoverableError),t.formState!==void 0&&(h=t.formState)),l=_o(e,1,!0,l,t??null,a,n,h,u,c,r,Yo),l.context=Mo(null),t=l.current,a=gl(),a=fu(a),n=dt(a),n.callback=null,ft(t,n,a),t=a,l.current.lanes=t,ka(l,t),Hl(l),e[Kt]=l.current,ts(e),new Ki(l)},_n.version="19.2.7",_n}var Wo;function ay(){if(Wo)return Es.exports;Wo=1;function s(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(s)}catch(d){console.error(d)}}return s(),Es.exports=ty(),Es.exports}var ny=ay();async function Pe(s){const d=await fetch(s);if(!d.ok)throw new Error(`HTTP ${d.status}`);return await d.json()}async function el(s,d,o){const f=await fetch(d,{method:s,...o!==void 0?{headers:{"content-type":"application/json"},body:JSON.stringify(o)}:{}});if(!f.ok){const m=await f.json().catch(()=>({}));throw new Error(m.error??`HTTP ${f.status}`)}}async function iy(s){return Pe(`/api/runs/${encodeURIComponent(s)}`)}async function hh(s={}){const d=new URLSearchParams;return d.set("limit",String(s.limit??50)),d.set("offset",String(s.offset??0)),Pe(`/api/threads?${d.toString()}`)}async function uy(s){return Pe(`/api/threads/${encodeURIComponent(s)}`)}async function cy(){return(await Pe("/api/instances")).instances}async function sy(s){return Pe(`/api/instances/${s}`)}async function ry(){return(await Pe("/api/mcp")).servers}async function dy(){return(await Pe("/api/skills")).skills}async function mh(){return Pe("/api/wire/status")}async function Oa(){return Pe("/api/routing/registry")}async function fy(){return Pe("/api/tiers")}async function Fo(s,d){await el("POST","/api/tiers",{tier:s,target:d})}async function oy(s){await el("DELETE",`/api/tiers?tier=${encodeURIComponent(s)}`)}async function hy(){return Pe("/api/keys")}async function my(s){const d=await fetch("/api/keys",{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({label:s})});if(!d.ok){const o=await d.json().catch(()=>({}));throw new Error(o.error??`HTTP ${d.status}`)}return await d.json()}async function vy(s){await el("DELETE",`/api/keys?id=${encodeURIComponent(s)}`)}async function vh(){return Pe("/api/routing/policy")}async function Io(s,d){await el("POST","/api/routing/agent",{routeKey:s,target:d})}async function yy(s){await el("DELETE",`/api/routing/agent?routeKey=${encodeURIComponent(s)}`)}async function gy(s){await el("POST","/api/routing/subagent",s)}async function py(s){await el("POST","/api/routing/provider",s)}async function Po(s){await el("DELETE",`/api/routing/provider?id=${encodeURIComponent(s)}`)}async function eh(s){await el("POST","/api/routing/model",s)}async function jy(s){const d=await fetch("/api/routing/list-models",{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(s)}),o=await d.json().catch(()=>({}));if(!d.ok)throw new Error(o.error??`HTTP ${d.status}`);return o.models??[]}async function by(s){await el("POST","/api/routing/combo",s)}async function xy(s){await el("DELETE",`/api/routing/combo?id=${encodeURIComponent(s)}`)}async function lh(s,d){const o=d?`id=${encodeURIComponent(s)}&providerId=${encodeURIComponent(d)}`:`id=${encodeURIComponent(s)}`;await el("DELETE",`/api/routing/model?${o}`)}async function yh(){return Pe("/api/tool-providers")}async function Sy(s){await el("POST","/api/tool-providers",s)}async function Ny(s){await el("DELETE",`/api/tool-providers?id=${encodeURIComponent(s)}`)}async function Ey(s,d){await el("POST","/api/tool-providers/active",{kind:s,providerId:d})}async function gh(s={}){const d=new URLSearchParams;return d.set("limit",String(s.limit??100)),Pe(`/api/risk?${d.toString()}`)}async function Ty(){return Pe("/api/masking")}async function au(s,d){const o=await fetch(s,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(d)});if(!o.ok){const f=await o.json().catch(()=>({}));throw new Error(f.error??`HTTP ${o.status}`)}return await o.json()}function Ay(s,d,o){return au("/api/masking/rule",{provider:s,id:d,enabled:o})}function th(s,d){return au("/api/masking/provider",{provider:s,enabled:d})}function zy(s,d){return au("/api/masking/fake",{id:s,fake:d})}function _y(s){return au("/api/masking/custom",s)}async function My(s){const d=await fetch(`/api/masking/custom?id=${encodeURIComponent(s)}`,{method:"DELETE"});if(!d.ok){const o=await d.json().catch(()=>({}));throw new Error(o.error??`HTTP ${d.status}`)}return await d.json()}function Cy(s){return s.wiredAgents.length}const Oy=[{key:"see",href:"#/see",label:"See",verb:"see"},{key:"routing",href:"#/routing",label:"Routing",verb:"route"},{key:"keys",href:"#/keys",label:"Connect",verb:"keys"},{key:"guard",href:"#/guard",label:"Guard",verb:"guard"}];function Uy({active:s}){const[d,o]=H.useState(null),[f,m]=H.useState(null);return H.useEffect(()=>{let g=!1;const j=async()=>{try{const[T,x]=await Promise.all([mh(),fetch("/health")]);g||(o(T),m(x.ok))}catch{g||m(!1)}};j();const E=setInterval(j,15e3);return()=>{g=!0,clearInterval(E)}},[]),i.jsx("header",{className:"nav",children:i.jsxs("div",{className:"nav-row nav-row-main",children:[i.jsxs("a",{className:"nav-brand",href:"#/",title:"Home",children:[i.jsx("span",{className:"nav-dot"}),i.jsx("span",{children:"afw"})]}),i.jsx("nav",{className:"nav-pillars","aria-label":"Sections",children:Oy.map(g=>i.jsxs("a",{href:g.href,className:`nav-pillar ${s===g.key?"active":""}`,children:[i.jsx("span",{className:"nav-pillar-label",children:g.label}),g.verb&&i.jsx("span",{className:"nav-pillar-sub",children:g.verb})]},g.key))}),i.jsxs("div",{className:"nav-meta",children:[d&&i.jsxs("span",{className:"nav-stat",title:d.wiredAgents.length>0?`Agents the wire accepts traffic for:
|
|
10
|
+
${d.wiredAgents.join(`
|
|
11
|
+
`)}`:"No agents wired yet — launch one with `afw claude`",children:["●●● ",Cy(d)," wired",d.driftedCount>0&&i.jsxs("span",{className:"nav-drift",children:[" · ",d.driftedCount," drifted"]})]}),i.jsx("span",{className:`nav-health ${f?"ok":"fail"}`,children:f==null?"…":f?"daemon ok":"daemon down"})]})]})})}function lt({ms:s}){const d=new Date(s),o=f=>String(f).padStart(2,"0");return i.jsxs("span",{title:d.toISOString(),children:[o(d.getHours()),":",o(d.getMinutes()),":",o(d.getSeconds())]})}function Mn({ms:s}){return s==null?i.jsx(i.Fragment,{children:"—"}):s<1e3?i.jsxs(i.Fragment,{children:[s,"ms"]}):s<6e4?i.jsxs(i.Fragment,{children:[(s/1e3).toFixed(1),"s"]}):i.jsxs(i.Fragment,{children:[(s/6e4).toFixed(1),"m"]})}function ph({tokensIn:s,tokensOut:d}){return s==null&&d==null?i.jsx(i.Fragment,{children:"—"}):i.jsxs(i.Fragment,{children:[s??0,"/",d??0]})}function Ds({read:s,write:d}){const o=s??0,f=d??0;return o===0&&f===0?i.jsx(i.Fragment,{children:"—"}):i.jsxs("span",{title:`${o} read, ${f} write`,children:[Cs(o),"/",Cs(f)]})}function Cs(s){return s<1e3?String(s):s<1e6?`${(s/1e3).toFixed(s<1e4?1:0).replace(/\.0$/,"")}K`:`${(s/1e6).toFixed(1).replace(/\.0$/,"")}M`}function Os(s){return Cs(s)}function Ua(s){const d=s.indexOf("_");return d<0?s.slice(0,10):`${s.slice(0,d+1)}${s.slice(d+1,d+9)}`}const Dy=s=>s.toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/(^-|-$)/g,"");function Ry(){const[s,d]=H.useState(null),[o,f]=H.useState([]),[m,g]=H.useState(null),[j,E]=H.useState(null),[T,x]=H.useState(null),[B,k]=H.useState({}),[Q,C]=H.useState(!1),[w,ee]=H.useState({label:"",pattern:"",fake:"",group:""}),ce=q=>{d(q.rules),f(q.providers),g(se=>se??q.providers[0]?.id??null)};H.useEffect(()=>{let q=!1;return Ty().then(se=>!q&&ce(se)).catch(se=>!q&&E(se.message)),()=>{q=!0}},[]);const G=o.find(q=>q.id===m)??null,L=async(q,se)=>{x(q),E(null);try{ce(await se())}catch(we){E(we.message)}finally{x(null)}},P=(q,se)=>G&&L(q.id,()=>Ay(G.id,q.id,se)),le=()=>G&&L("__all",()=>th(G.id,s?.map(q=>q.id)??[])),ve=()=>G&&L("__clear",()=>th(G.id,[])),F=q=>{const se=B[q.id];se==null||se===q.fake||L(`fake:${q.id}`,()=>zy(q.id,se)).then(()=>k(we=>{const Me={...we};return delete Me[q.id],Me}))},K=()=>{const q=Dy(w.label);if(!q||!w.pattern||!w.fake){E("Custom credential needs a name, a pattern, and a fake value.");return}const se={id:q,label:w.label,pattern:w.pattern,fake:w.fake,...w.group.trim()?{group:Number(w.group)}:{}};L("__custom",()=>_y(se)).then(()=>{ee({label:"",pattern:"",fake:"",group:""}),C(!1)})};return i.jsxs("section",{className:"mask-panel",children:[i.jsxs("div",{className:"mask-head",children:[i.jsx("h2",{className:"mask-title",children:"Credential masking"}),i.jsx("span",{className:"mask-sub",children:"Off by default. Pick a provider and turn on the credential types to de-identify — they're swapped for real-looking fakes before the request reaches that provider, then restored in the response, so the provider (or an API relay) never sees the real value."})]}),j&&i.jsxs("div",{className:"error",children:["Error: ",j]}),s==null?i.jsx("div",{className:"loading",children:"Loading…"}):o.length===0?i.jsxs("div",{className:"empty",children:[i.jsx("p",{children:"No providers yet."}),i.jsx("p",{className:"hint",children:"Add a provider (Routing) or launch an agent to register an upstream."})]}):i.jsxs(i.Fragment,{children:[i.jsxs("div",{className:"mask-provider-row",children:[i.jsx("label",{className:"mask-provider-label",htmlFor:"mask-provider",children:"Provider"}),i.jsx("select",{id:"mask-provider",className:"mask-provider-select",value:m??"",onChange:q=>g(q.target.value),children:o.map(q=>i.jsxs("option",{value:q.id,children:[q.label,q.baseUrl?` — ${q.baseUrl}`:""," (",q.enabled.length," on)"]},q.id))}),i.jsxs("div",{className:"mask-bulk",children:[i.jsx("button",{type:"button",className:"btn-small",disabled:T!=null,onClick:le,children:"Select all"}),i.jsx("button",{type:"button",className:"btn-small",disabled:T!=null,onClick:ve,children:"Clear"})]})]}),i.jsxs("table",{className:"runs mask-table",children:[i.jsx("thead",{children:i.jsxs("tr",{children:[i.jsx("th",{children:"On"}),i.jsx("th",{children:"Credential"}),i.jsx("th",{children:"Matches"}),i.jsx("th",{children:"Replaced with (editable)"}),i.jsx("th",{})]})}),i.jsx("tbody",{children:s.map(q=>{const se=G?.enabled.includes(q.id)??!1,we=B[q.id]??q.fake;return i.jsxs("tr",{className:se?"":"mask-off",children:[i.jsx("td",{children:i.jsx("label",{className:"toggle",children:i.jsx("input",{type:"checkbox",checked:se,disabled:T!=null||!G,onChange:Me=>{P(q,Me.target.checked)}})})}),i.jsxs("td",{children:[q.label,q.custom&&i.jsx("span",{className:"mask-badge",children:"custom"})]}),i.jsx("td",{className:"mask-desc",children:q.custom?i.jsxs("code",{className:"mask-pat",children:["/",q.pattern,"/"]}):q.description}),i.jsx("td",{children:i.jsx("input",{className:"mask-fake-input",value:we,spellCheck:!1,onChange:Me=>k(Te=>({...Te,[q.id]:Me.target.value})),onBlur:()=>F(q),onKeyDown:Me=>Me.key==="Enter"&&F(q)})}),i.jsx("td",{children:q.custom&&i.jsx("button",{type:"button",className:"btn-small btn-danger",disabled:T!=null,onClick:()=>{L(`del:${q.id}`,()=>My(q.id))},children:"Remove"})})]},q.id)})})]}),Q?i.jsxs("div",{className:"mask-add-form",children:[i.jsx("input",{placeholder:"Name (e.g. Internal token)",value:w.label,onChange:q=>ee({...w,label:q.target.value})}),i.jsx("input",{placeholder:"Regex pattern (e.g. INT-[0-9]{8})",value:w.pattern,spellCheck:!1,onChange:q=>ee({...w,pattern:q.target.value})}),i.jsx("input",{placeholder:"Fake value to substitute",value:w.fake,spellCheck:!1,onChange:q=>ee({...w,fake:q.target.value})}),i.jsx("input",{className:"mask-group-input",placeholder:"group #",value:w.group,onChange:q=>ee({...w,group:q.target.value})}),i.jsx("button",{type:"button",className:"btn-small btn-primary",disabled:T!=null,onClick:K,children:"Add"}),i.jsx("button",{type:"button",className:"btn-small",onClick:()=>C(!1),children:"Cancel"})]}):i.jsx("button",{type:"button",className:"btn-small",onClick:()=>C(!0),children:"+ Add credential type"})]})]})}const ah={high:0,warn:1,info:2};function Hy(s){if(s==null)return"";if(typeof s=="string")return s;try{return JSON.stringify(s)}catch{return String(s)}}function ky(){const[s,d]=H.useState(null),[o,f]=H.useState(null);H.useEffect(()=>{let j=!1;const E=async()=>{try{const x=await gh({limit:200});j||(d(x),f(null))}catch(x){j||f(x.message)}};E();const T=setInterval(E,6e3);return()=>{j=!0,clearInterval(T)}},[]);const m=s?.findings.reduce((j,E)=>(j[E.severity]=(j[E.severity]??0)+1,j),{})??{},g=[...s?.findings??[]].sort((j,E)=>(ah[j.severity]??9)-(ah[E.severity]??9)||E.ts-j.ts);return i.jsxs("div",{className:"guard",children:[i.jsx(Ry,{}),i.jsx("h2",{className:"mask-title guard-findings-title",children:"Risk findings"}),o&&!s?i.jsxs("div",{className:"error",children:["Error: ",o]}):s?s.findings.length===0?i.jsxs("div",{className:"empty",children:[i.jsx("p",{children:"No risk findings."}),i.jsx("p",{className:"hint",children:"The detector pipeline (secret-leak, dangerous-shell) runs over every captured packet. Findings show up here as agents pull in untrusted content."})]}):i.jsxs(i.Fragment,{children:[i.jsx("div",{className:"guard-summary",children:["high","warn","info"].map(j=>i.jsxs("span",{className:`sev-pill sev-${j}`,children:[m[j]??0," ",j]},j))}),i.jsxs("table",{className:"runs",children:[i.jsx("thead",{children:i.jsxs("tr",{children:[i.jsx("th",{children:"Severity"}),i.jsx("th",{children:"Detector"}),i.jsx("th",{children:"Agent"}),i.jsx("th",{children:"Kind"}),i.jsx("th",{children:"When"}),i.jsx("th",{children:"Detail"}),i.jsx("th",{children:"Run"})]})}),i.jsx("tbody",{children:g.map(j=>i.jsxs("tr",{onClick:()=>{window.location.hash=`#/run/${encodeURIComponent(j.runId)}`},children:[i.jsx("td",{children:i.jsx("span",{className:`sev-pill sev-${j.severity}`,children:j.severity})}),i.jsx("td",{children:j.tag}),i.jsx("td",{children:j.agent}),i.jsx("td",{children:j.kind}),i.jsx("td",{children:i.jsx(lt,{ms:j.ts})}),i.jsx("td",{className:"guard-detail",children:Hy(j.detail)}),i.jsx("td",{children:i.jsx("code",{children:Ua(j.runId)})})]},`${j.actionId}-${j.tag}`))})]})]}):i.jsx("div",{className:"loading",children:"Loading…"})]})}function qy(s){return!s||s.kind==="passthrough"?"passthrough (no model swap)":s.kind==="composite"?`fusion: ${s.comboId}`:s.members.map(d=>d.modelId).join(" → ")}function Ji(s){return(s.tokensIn??0)+(s.tokensOut??0)}function By(){const[s,d]=H.useState(null),[o,f]=H.useState(null),[m,g]=H.useState(null),[j,E]=H.useState(null),[T,x]=H.useState(null),[B,k]=H.useState(null);if(H.useEffect(()=>{let w=!1;const ee=async()=>{try{const[G,L,P,le,ve]=await Promise.all([mh(),Oa(),vh(),gh({limit:200}),hh({limit:200})]);w||(d(G),f(L),g(P),E(le),x(ve.rows),k(null))}catch(G){w||k(G.message)}};ee();const ce=setInterval(ee,15e3);return()=>{w=!0,clearInterval(ce)}},[]),B)return i.jsxs("div",{className:"error",children:["Error: ",B]});if(!s||!o||!m||!j||!T)return i.jsx("div",{className:"loading",children:"Loading…"});const Q=new Map;for(const w of s.entries)w.drifted&&Q.set(w.agent,!0);const C=T.reduce((w,ee)=>w==null||Ji(ee)>Ji(w)?ee:w,null);return i.jsxs("div",{className:"home",children:[i.jsxs("section",{className:"home-hero",children:[i.jsx("h1",{children:"afw"}),i.jsxs("p",{className:"home-sub",children:["An AI agent firewall on the wire. Every call your agents make is captured here —",i.jsx("strong",{children:" see"})," it, ",i.jsx("strong",{children:"route"})," it to the model you pick, and",i.jsx("strong",{children:" guard"})," the untrusted content tool calls pull in."]})]}),i.jsxs("div",{className:"home-grid",children:[i.jsxs("a",{className:"home-card",href:"#/tasks",children:[i.jsx("div",{className:"home-card-num",children:s.wiredAgents.length}),i.jsxs("div",{className:"home-card-label",children:["agent",s.wiredAgents.length===1?"":"s"," wired"]}),i.jsx("div",{className:"home-card-cta",children:"See tasks →"})]}),i.jsxs("a",{className:"home-card",href:"#/routing",children:[i.jsx("div",{className:"home-card-num",children:o.models.length}),i.jsxs("div",{className:"home-card-label",children:["models · ",o.providers.length," provider",o.providers.length===1?"":"s"]}),i.jsx("div",{className:"home-card-cta",children:"Routing →"})]}),i.jsxs("a",{className:"home-card",href:"#/guard",children:[i.jsx("div",{className:"home-card-num",children:j.total}),i.jsxs("div",{className:"home-card-label",children:["risk finding",j.total===1?"":"s"]}),i.jsx("div",{className:"home-card-cta",children:"Guard →"})]}),C&&Ji(C)>0&&i.jsxs("a",{className:"home-card",href:`#/task/${encodeURIComponent(C.id)}`,children:[i.jsx("div",{className:"home-card-num",children:Os(Ji(C))}),i.jsxs("div",{className:"home-card-label",children:["tokens · heaviest task",i.jsx("br",{}),i.jsxs("span",{className:"muted",children:[C.title??Ua(C.id),C.model?` · ${C.model}`:""]})]}),i.jsx("div",{className:"home-card-cta",children:"Open task →"})]})]}),i.jsxs("section",{className:"home-section",children:[i.jsx("h2",{children:"Wired agents"}),s.wiredAgents.length===0?i.jsxs("div",{className:"empty",children:[i.jsx("p",{children:"No agents wired yet."}),i.jsxs("p",{className:"hint",children:["Launch one through afw — e.g. ",i.jsx("code",{children:"afw claude"}),". afw never edits the agent's own config; it taps the wire per launch."]})]}):i.jsxs("table",{className:"kv-table",children:[i.jsx("thead",{children:i.jsxs("tr",{children:[i.jsx("th",{children:"Agent"}),i.jsx("th",{children:"Routes to"}),i.jsx("th",{children:"Config"})]})}),i.jsx("tbody",{children:s.wiredAgents.map(w=>i.jsxs("tr",{children:[i.jsx("td",{children:w}),i.jsx("td",{children:qy(m.policy.agents[`${w}/*`]?.target)}),i.jsx("td",{children:Q.get(w)?i.jsx("span",{className:"run-error-badge",children:"drifted"}):i.jsx("span",{className:"muted",children:"untouched"})})]},w))})]})]})]})}const eu="__unset__";function Yy(s,d){return s.find(o=>o.id===d)?.label??d}function wy(s){if(!s||s.kind==="passthrough")return eu;if(s.kind==="composite")return`c:${s.comboId}`;if(s.kind==="chain"&&s.members[0]){const d=s.members[0];return`m:${d.providerId??""}/${d.modelId}`}return eu}function jh({value:s}){const[d,o]=H.useState(!1);return i.jsx("button",{type:"button",className:"muted",onClick:()=>{navigator.clipboard?.writeText(s).then(()=>{o(!0),setTimeout(()=>o(!1),1200)})},children:d?"copied":"copy"})}function Gy({conn:s,token:d}){const o=[["Base URL (OpenAI)",s.baseUrl],["Base URL (Anthropic)",s.anthropicBaseUrl],["API key",d]];return i.jsx("div",{className:"card",children:i.jsx("table",{className:"kv-table",children:i.jsxs("tbody",{children:[o.map(([f,m])=>i.jsxs("tr",{children:[i.jsx("td",{children:f}),i.jsx("td",{children:i.jsx("code",{children:m})}),i.jsx("td",{className:"row-actions",children:i.jsx(jh,{value:m})})]},f)),i.jsxs("tr",{children:[i.jsx("td",{children:"Model names"}),i.jsx("td",{children:s.modelNames.map((f,m)=>i.jsxs("span",{children:[m>0&&" · ",i.jsx("code",{children:f.name})]},f.tier))}),i.jsx("td",{})]})]})})})}function Ly(){const[s,d]=H.useState(null),[o,f]=H.useState(null),[m,g]=H.useState(null),[j,E]=H.useState([]),[T,x]=H.useState([]),[B,k]=H.useState([]),[Q,C]=H.useState(null),[w,ee]=H.useState(!1),[ce,G]=H.useState("default"),L=H.useCallback(async()=>{try{const[F,K,q]=await Promise.all([fy(),hy(),Oa()]);d(F.tiers),f(F.connection),g(K.keys),E(q.models),x(q.providers),k(q.combos),C(null)}catch(F){C(F.message)}},[]);H.useEffect(()=>{L()},[L]);const P=async F=>{ee(!0);try{await F(),await L(),C(null)}catch(K){C(K.message)}finally{ee(!1)}},le=(F,K)=>P(async()=>{if(K===eu){await oy(F);return}if(K.startsWith("c:")){await Fo(F,{kind:"composite",comboId:K.slice(2)});return}const q=K.slice(2),se=q.indexOf("/"),we=q.slice(0,se),Te={kind:"chain",members:[{modelId:q.slice(se+1),...we?{providerId:we}:{}}]};await Fo(F,Te)});if(!s||!o||!m)return i.jsx("div",{className:"hint",children:Q?`Error: ${Q}`:"Loading…"});const ve=j.length===0;return i.jsxs("div",{children:[Q&&i.jsx("div",{className:"error",children:Q}),i.jsxs("section",{className:"home-section",children:[i.jsx("h2",{children:"Models"}),i.jsx("p",{className:"hint",children:"afw exposes three fixed model names, low → high. Map each to one of your configured models (or a Fusion combo); agents request these names and afw routes to your choice."}),ve?i.jsxs("p",{className:"hint",children:["Register a model first on the ",i.jsx("a",{href:"#/routing",children:"Routing"})," tab (or"," ",i.jsx("code",{children:"afw model add"}),")."]}):i.jsxs("table",{className:"kv-table",children:[i.jsx("thead",{children:i.jsxs("tr",{children:[i.jsx("th",{children:"Model name"}),i.jsx("th",{children:"Maps to"})]})}),i.jsx("tbody",{children:s.map(F=>i.jsxs("tr",{children:[i.jsx("td",{children:i.jsx("code",{children:F.display})}),i.jsx("td",{children:i.jsxs("select",{value:wy(F.target),disabled:w,onChange:K=>{le(F.tier,K.target.value)},children:[i.jsx("option",{value:eu,children:"— not mapped —"}),B.length>0&&i.jsx("optgroup",{label:"Model Fusion",children:B.map(K=>i.jsx("option",{value:`c:${K.id}`,children:K.label},K.id))}),i.jsx("optgroup",{label:"Models",children:j.map(K=>i.jsxs("option",{value:`m:${K.providerId}/${K.id}`,children:[K.id," (",Yy(T,K.providerId),")"]},`${K.providerId}/${K.id}`))})]})})]},F.tier))})]})]}),i.jsxs("section",{className:"home-section",children:[i.jsx("h2",{children:"API keys"}),i.jsxs("p",{className:"hint",children:["An API key is an auth token. Point your OpenAI/Anthropic-compatible agent at the base URL below with a key, and request one of the three model names. Claude Code / Codex need no key — run ",i.jsx("code",{children:"afw claude"})," or ",i.jsx("code",{children:"afw codex"}),"."]}),i.jsx(Gy,{conn:o,token:m[0]?.token??"(create a key below)"}),m.length===0?i.jsx("p",{className:"hint",children:"No keys yet — create one below."}):i.jsxs("table",{className:"kv-table",children:[i.jsx("thead",{children:i.jsxs("tr",{children:[i.jsx("th",{children:"Agent"}),i.jsx("th",{children:"Label"}),i.jsx("th",{children:"Token"}),i.jsx("th",{children:"Last used"}),i.jsx("th",{})]})}),i.jsx("tbody",{children:m.map(F=>i.jsxs("tr",{children:[i.jsx("td",{children:F.instance?`${F.agent}@${F.instance}`:F.agent}),i.jsx("td",{children:F.label}),i.jsx("td",{children:i.jsx("code",{children:F.token})}),i.jsx("td",{children:F.lastUsedAt?new Date(F.lastUsedAt).toLocaleString():"never"}),i.jsxs("td",{className:"row-actions",children:[i.jsx(jh,{value:F.token}),i.jsx("button",{type:"button",className:"btn-danger",disabled:w,onClick:()=>{P(()=>vy(F.id))},children:"revoke"})]})]},F.id))})]}),i.jsxs("form",{className:"add-form",onSubmit:F=>{F.preventDefault(),P(async()=>{await my(ce.trim()||"default")})},children:[i.jsxs("label",{children:["Label",i.jsx("input",{value:ce,onChange:F=>G(F.target.value),disabled:w})]}),i.jsx("button",{type:"submit",className:"primary",disabled:w,children:"Create key"})]})]})]})}const nh=s=>`${s.providerId??""}/${s.modelId}`,Xy=s=>(s.input??["text"]).includes("image"),et=s=>`${encodeURIComponent(s.providerId??"")}/${encodeURIComponent(s.modelId)}`;function Ca(s){const d=s.indexOf("/"),o=decodeURIComponent(s.slice(0,d));return{modelId:decodeURIComponent(s.slice(d+1)),...o?{providerId:o}:{}}}function Qy(s){return s&&typeof s=="object"&&"rollingHours"in s?"5h":s==="month"?"month":"day"}function Zy(s){const d=s.switchOn?.find(m=>m.kind==="tokens"),o=s.switchOn?.find(m=>m.kind==="quota-pct"),f=o?"quota-pct":d?"tokens":"none";return{modelId:s.modelId,...s.providerId?{providerId:s.providerId}:{},...s.fallback?{fallback:s.fallback}:{},limitKind:f,tokenLimit:d&&"tokenLimit"in d?d.tokenLimit:0,period:d&&"period"in d?Qy(d.period):"5h",usedPct:o&&"usedPct"in o?o.usedPct:0,onError:s.switchOn?.some(m=>m.kind==="error")??!0}}function Ky({models:s,providers:d,toolProviders:o,editing:f,busy:m,onSubmit:g,onCancel:j}){const[E,T]=H.useState(f?.label??""),[x,B]=H.useState(f?.panel.map(Zy)??[]),[k,Q]=H.useState(f?.vision?et(f.vision):""),[C,w]=H.useState(f?.webSearch?.providerId??""),[ee,ce]=H.useState(f?.judge?et(f.judge):""),[G,L]=H.useState(f?.synthesizer?et(f.synthesizer):""),[P,le]=H.useState(f?.cheapModel?et(f.cheapModel):""),ve=R=>R&&d.find(z=>z.id===R)?.label||R||"—",F=R=>!!R&&d.find(z=>z.id===R)?.auth?.kind==="agent-oauth",K=R=>F(R)?"quota-pct":"tokens",q=new Set(x.map(nh)),se=s.filter(R=>!q.has(`${R.providerId}/${R.id}`)),we=s.filter(Xy),Me=o.filter(R=>R.kind==="web_search"),Te=(R,z)=>B(x.map((p,Y)=>Y===R?{...p,...z}:p)),_l=()=>{!E.trim()||x.length===0||g({...f?{id:f.id}:{},label:E.trim(),panel:x.map(R=>{const z=[];if(R.fallback){if(R.limitKind==="tokens"&&R.tokenLimit>0){const p=R.period==="5h"?{rollingHours:5}:R.period;z.push({kind:"tokens",tokenLimit:R.tokenLimit,period:p})}else R.limitKind==="quota-pct"&&R.usedPct>0&&z.push({kind:"quota-pct",usedPct:R.usedPct});R.onError&&z.push({kind:"error"})}return{modelId:R.modelId,...R.providerId?{providerId:R.providerId}:{},...z.length>0?{switchOn:z}:{},...R.fallback?{fallback:R.fallback}:{}}}),...k?{vision:Ca(k)}:{},...C?{webSearch:{providerId:C}}:{},...ee?{judge:Ca(ee)}:{},...G?{synthesizer:Ca(G)}:{},...P?{cheapModel:Ca(P)}:{}})},Qe=s.map(R=>i.jsxs("option",{value:et({modelId:R.id,providerId:R.providerId}),children:[R.id," (",ve(R.providerId),")"]},`${R.providerId}/${R.id}`));return i.jsxs("div",{className:"combo-editor",children:[i.jsxs("div",{className:"combo-row",children:[i.jsx("span",{className:"combo-label",children:"Name"}),i.jsx("input",{placeholder:"fusion name (e.g. frontier-panel)",value:E,onChange:R=>T(R.target.value)})]}),i.jsxs("div",{className:"combo-row combo-row-top",children:[i.jsxs("span",{className:"combo-label",children:["Panel",i.jsx("div",{className:"dim",children:"these models all answer in parallel — diversity is the point"})]}),i.jsxs("div",{className:"fallback-edit",children:[x.map((R,z)=>i.jsxs("div",{className:"fusion-member",children:[i.jsxs("div",{className:"fallback-row",children:[i.jsxs("span",{children:[i.jsx("code",{children:R.modelId})," ",i.jsxs("span",{className:"dim",children:["(",ve(R.providerId),")"]})]}),i.jsx("button",{type:"button",className:"btn-small",disabled:m,onClick:()=>B(x.filter((p,Y)=>Y!==z)),children:"×"})]}),i.jsxs("div",{className:"fusion-member-caps",children:[i.jsxs("label",{className:"fusion-cap",children:[i.jsx("span",{className:"dim",children:"fallback"}),i.jsxs("select",{disabled:m,value:R.fallback?et(R.fallback):"",onChange:p=>Te(z,{fallback:p.target.value?Ca(p.target.value):void 0}),children:[i.jsx("option",{value:"",children:"none"}),s.filter(p=>!(p.id===R.modelId&&p.providerId===R.providerId)).map(p=>i.jsxs("option",{value:et({modelId:p.id,providerId:p.providerId}),children:[p.id," (",ve(p.providerId),")"]},`${p.providerId}/${p.id}`))]})]}),R.fallback?i.jsxs(i.Fragment,{children:[i.jsxs("label",{className:"fusion-cap",children:[i.jsx("span",{className:"dim",children:"switch when"}),i.jsxs("select",{disabled:m,value:R.limitKind,onChange:p=>Te(z,{limitKind:p.target.value}),children:[i.jsx("option",{value:"none",children:"never (only on failure)"}),i.jsx("option",{value:"tokens",children:"over token cap"}),i.jsx("option",{value:"quota-pct",children:"over subscription %"})]})]}),R.limitKind==="tokens"?i.jsxs(i.Fragment,{children:[i.jsx("label",{className:"fusion-cap",children:i.jsx("input",{type:"number",min:0,step:1e5,placeholder:"tokens",style:{width:"7rem"},disabled:m,value:R.tokenLimit||"",onChange:p=>Te(z,{tokenLimit:Number.parseInt(p.target.value,10)||0})})}),i.jsx("label",{className:"fusion-cap",children:i.jsxs("select",{disabled:m,value:R.period,onChange:p=>Te(z,{period:p.target.value}),children:[i.jsx("option",{value:"5h",children:"/ 5h"}),i.jsx("option",{value:"day",children:"/ day"}),i.jsx("option",{value:"month",children:"/ month"})]})})]}):null,R.limitKind==="quota-pct"?i.jsxs("label",{className:"fusion-cap",children:[i.jsx("input",{type:"number",min:1,max:100,step:5,placeholder:"80",style:{width:"4.5rem"},disabled:m,value:R.usedPct||"",onChange:p=>Te(z,{usedPct:Number.parseInt(p.target.value,10)||0})}),i.jsx("span",{className:"dim",children:"% of 5h quota used"})]}):null,i.jsxs("label",{className:"fusion-cap",children:[i.jsx("input",{type:"checkbox",disabled:m,checked:R.onError,onChange:p=>Te(z,{onError:p.target.checked})})," ",i.jsx("span",{className:"dim",children:"on failure"})]})]}):null]})]},nh(R))),se.length>0&&i.jsxs("select",{disabled:m,value:"",onChange:R=>{if(!R.target.value)return;const z=Ca(R.target.value);B([...x,{...z,limitKind:K(z.providerId),tokenLimit:0,period:"5h",usedPct:0,onError:!0}])},children:[i.jsx("option",{value:"",children:"+ add panel model…"}),se.map(R=>i.jsxs("option",{value:et({modelId:R.id,providerId:R.providerId}),children:[R.id," (",ve(R.providerId),")"]},`${R.providerId}/${R.id}`))]})]})]}),i.jsxs("div",{className:"combo-row",children:[i.jsxs("span",{className:"combo-label",children:["Multimodal",i.jsx("div",{className:"dim",children:"one model that describes images for any text-only panel member — skip it if the panel is already multimodal"})]}),i.jsxs("select",{disabled:m,value:k,onChange:R=>Q(R.target.value),children:[i.jsx("option",{value:"",children:"none"}),we.map(R=>i.jsxs("option",{value:et({modelId:R.id,providerId:R.providerId}),children:[R.id," (",ve(R.providerId),")"]},`${R.providerId}/${R.id}`))]})]}),i.jsxs("div",{className:"combo-row",children:[i.jsxs("span",{className:"combo-label",children:["Web search",i.jsx("div",{className:"dim",children:"fulfills the panel's web_search calls (Anthropic clients)"})]}),i.jsxs("select",{disabled:m,value:C,onChange:R=>w(R.target.value),children:[i.jsx("option",{value:"",children:"none"}),Me.map(R=>i.jsxs("option",{value:R.id,children:[R.label," (",R.backend,")"]},R.id))]})]}),i.jsxs("div",{className:"combo-row",children:[i.jsxs("span",{className:"combo-label",children:["Synthesizer",i.jsxs("div",{className:"dim",children:["Writes the final answer from the judge's notes. Most of fusion's quality gain comes from this step — ",i.jsx("strong",{children:"use your strongest model here"}),"."]})]}),i.jsxs("select",{disabled:m,value:G,onChange:R=>L(R.target.value),children:[i.jsx("option",{value:"",children:"default — the first panel model"}),Qe]})]}),i.jsxs("div",{className:"combo-row",children:[i.jsxs("span",{className:"combo-label",children:["Judge",i.jsx("div",{className:"dim",children:"Organizes the panel's answers into structured notes (consensus, contradictions, blind spots) — it doesn't write the answer, so a solid mid-tier model is plenty."})]}),i.jsxs("select",{disabled:m,value:ee,onChange:R=>ce(R.target.value),children:[i.jsx("option",{value:"",children:"default — same model as the synthesizer"}),Qe]})]}),i.jsxs("div",{className:"combo-row",children:[i.jsxs("span",{className:"combo-label",children:["Cheap model",i.jsx("div",{className:"dim",children:"For the simple, high-volume work routed here — Claude Code subagents and hermes/openclaw cron jobs. These skip the panel and go straight to this one model."})]}),i.jsxs("select",{disabled:m,value:P,onChange:R=>le(R.target.value),children:[i.jsx("option",{value:"",children:"none — every request runs the full fusion"}),Qe]})]}),i.jsxs("div",{className:"combo-actions",children:[i.jsx("button",{type:"button",className:"btn-small btn-primary",disabled:m||!E.trim()||x.length===0,onClick:_l,children:f?"save changes":"create fusion"}),i.jsx("button",{type:"button",className:"btn-small",disabled:m,onClick:j,children:"cancel"})]})]})}function Vy(){const[s,d]=H.useState(null),[o,f]=H.useState([]),[m,g]=H.useState(null),[j,E]=H.useState(!1),[T,x]=H.useState(void 0),B=H.useCallback(async()=>{try{const[L,P]=await Promise.all([Oa(),yh()]);d(L),f(P.providers),g(null)}catch(L){g(L.message)}},[]);H.useEffect(()=>{B()},[B]);const k=async L=>{E(!0);try{await L(),await B()}catch(P){g(P.message)}finally{E(!1)}},Q=L=>{k(async()=>{await by(L),x(void 0)})};if(m&&!s)return i.jsxs("div",{className:"error",children:["Error: ",m]});if(!s)return i.jsx("div",{className:"loading",children:"Loading…"});const{providers:C,models:w,combos:ee}=s,ce=L=>L.panel.map(P=>P.fallback?`${P.modelId}→${P.fallback.modelId}`:P.modelId).join(" + "),G=L=>{const P=L.judge?.modelId??"synthesizer",le=L.synthesizer?.modelId??L.panel[0]?.modelId??"—",ve=[];return L.vision&&ve.push(`vision: ${L.vision.modelId}`),L.webSearch&&ve.push("web search"),`judge: ${P} → synth: ${le}${ve.length?` · ${ve.join(" · ")}`:""}`};return i.jsxs("div",{children:[m&&i.jsx("div",{className:"error inline",children:m}),i.jsxs("section",{className:"home-section",children:[i.jsx("h2",{children:"Model Fusion"}),i.jsxs("p",{className:"hint",children:["Diversity beats any one model. A fusion turns one request into a small deliberation across"," ",i.jsx("em",{children:"your"})," providers, on your wire — then hands your agent a single answer. Assign a fusion to an agent on the ",i.jsx("strong",{children:"Routes"})," tab."]}),i.jsxs("div",{className:"fusion-how",children:[i.jsxs("div",{className:"fusion-flow",children:[i.jsxs("div",{className:"fusion-step",children:[i.jsx("div",{className:"fusion-step-n",children:"1"}),i.jsx("strong",{children:"Panel"}),i.jsxs("p",{children:["Your models all answer the same prompt ",i.jsx("em",{children:"in parallel"}),". Each can fail over to a backup on a token cap or error; one multimodal companion lets a text-only model join an image prompt."]})]}),i.jsx("div",{className:"fusion-arrow","aria-hidden":"true",children:"→"}),i.jsxs("div",{className:"fusion-step",children:[i.jsx("div",{className:"fusion-step-n",children:"2"}),i.jsx("strong",{children:"Judge"}),i.jsx("p",{children:"Reads every answer and distils structured notes — consensus, contradictions, unique insights, blind spots. It organizes; it doesn't write the answer, so a mid-tier model is plenty."})]}),i.jsx("div",{className:"fusion-arrow","aria-hidden":"true",children:"→"}),i.jsxs("div",{className:"fusion-step fusion-step-key",children:[i.jsx("div",{className:"fusion-step-n",children:"3"}),i.jsx("strong",{children:"Synthesize"}),i.jsxs("p",{children:["Writes the single best final answer, grounded in those notes. Most of the quality gain is here — ",i.jsx("strong",{children:"give it your strongest model"}),"."]})]})]}),i.jsx("p",{className:"hint",children:"Your agent sees one normal response. Cost = the sum of every call; latency = the slowest panel model + judge + synthesizer."})]}),ee.length===0?i.jsx("p",{className:"hint",children:"No fusion models yet — create one below."}):i.jsxs("table",{className:"kv-table",children:[i.jsx("thead",{children:i.jsxs("tr",{children:[i.jsx("th",{children:"Name"}),i.jsx("th",{children:"Panel"}),i.jsx("th",{children:"Pipeline"}),i.jsx("th",{})]})}),i.jsx("tbody",{children:ee.map(L=>i.jsxs("tr",{children:[i.jsxs("td",{children:[i.jsx("span",{className:"reg-name",children:L.label}),i.jsx("span",{className:"reg-id",children:L.id})]}),i.jsx("td",{children:ce(L)}),i.jsx("td",{className:"dim",children:G(L)}),i.jsxs("td",{className:"row-actions",children:[i.jsx("button",{type:"button",className:"btn-plain",disabled:j,onClick:()=>x(L),children:"edit"}),i.jsx("button",{type:"button",className:"btn-danger",disabled:j,onClick:()=>{k(()=>xy(L.id))},children:"remove"})]})]},L.id))})]}),T!==void 0?i.jsx(Ky,{models:w,providers:C,toolProviders:o,editing:T,busy:j,onSubmit:Q,onCancel:()=>x(void 0)}):i.jsx("button",{type:"button",className:"btn-small",disabled:w.length===0,onClick:()=>x(null),children:"+ New fusion model"}),w.length===0&&i.jsxs("p",{className:"hint",children:["Add some models on the ",i.jsx("strong",{children:"Models"})," tab first."]})]})]})}const Jy=["anthropic-messages","openai-chat","openai-responses"],$y=["passthrough","bearer","api-key"],Wy=["text","image","pdf","audio","video"],ih={name:"",baseUrl:"",api:"openai-chat",authKind:"bearer",authHeader:"x-api-key",apiKey:""},$i={id:"",input:["text"],window:0,showWindow:!1},Wi=s=>s.label||s.id;function Fy(){const[s,d]=H.useState(null),[o,f]=H.useState(null),[m,g]=H.useState(!1),[j,E]=H.useState(ih),[T,x]=H.useState(null),[B,k]=H.useState(null),[Q,C]=H.useState($i),[w,ee]=H.useState(null),[ce,G]=H.useState(null),L=H.useRef(null),P=H.useCallback(async()=>{try{d(await Oa()),f(null)}catch(p){f(p.message)}},[]);H.useEffect(()=>{P()},[P]),H.useEffect(()=>{B&&L.current?.focus()},[B]);const le=async p=>{g(!0);try{await p(),await P()}catch(Y){f(Y.message)}finally{g(!1)}},ve=()=>{E(ih),x(null)},F=p=>{k(p),C($i),ee(null),G(null)},K=p=>{x(p.id),E({name:Wi(p),id:p.id,baseUrl:p.baseUrl,api:p.api,authKind:p.auth?.kind??"bearer",authHeader:p.auth?.header??"x-api-key",apiKey:""})},q=p=>{if(p.preventDefault(),!j.name.trim()||!j.baseUrl.trim())return f("provider name and base URL are required");const Y=!T,$=j.name.trim();g(!0),(async()=>{try{await py({...j,...T?{id:T}:{},...j.authKind==="api-key"?{}:{authHeader:void 0},...j.authKind==="passthrough"?{apiKey:void 0}:{}});const te=await Oa();if(d(te),f(null),ve(),Y){const v=te.providers.find(D=>(D.label||D.id)===$)??te.providers[te.providers.length-1];v&&F(v.id)}}catch(te){f(te.message)}finally{g(!1)}})()},se=async p=>{g(!0),f(null);try{const Y=await jy({baseUrl:p.baseUrl,api:p.api,authKind:p.auth?.kind??"passthrough",...p.auth?.header?{authHeader:p.auth.header}:{},providerId:p.id});G({models:Y,picked:new Set})}catch(Y){f(Y.message)}finally{g(!1)}},we=p=>{if(!ce)return;const{models:Y,picked:$}=ce;le(async()=>{for(const te of Y)$.has(te.id)&&await eh({id:te.id,providerId:p,label:te.label??te.id,input:["text"]});G(null)})},Me=p=>C(Y=>{const te=Y.input.includes(p)?Y.input.filter(v=>v!==p):[...Y.input,p];return{...Y,input:te.length?te:["text"]}}),Te=p=>{ee(p.id),C({id:p.id,input:p.input?.length?p.input:["text"],window:p.contextWindow??0,showWindow:!!p.contextWindow}),L.current?.focus()},_l=p=>{const Y=Q.id.trim();if(!Y)return f("a model name is required");le(async()=>{await eh({id:Y,providerId:p,label:Y,input:Q.input,...Q.window>0?{contextWindow:Q.window}:{}}),w&&w!==Y&&await lh(w,p),C($i),ee(null),L.current?.focus()})};if(o&&!s)return i.jsxs("div",{className:"error",children:["Error: ",o]});if(!s)return i.jsx("div",{className:"loading",children:"Loading…"});const{providers:Qe,models:R}=s,z=p=>R.filter(Y=>Y.providerId===p);if(B){const p=Qe.find($=>$.id===B);if(!p)return k(null),i.jsx("div",{className:"loading",children:"…"});const Y=z(p.id);return i.jsxs("div",{children:[o&&i.jsx("div",{className:"error inline",children:o}),i.jsxs("section",{className:"home-section",children:[i.jsx("div",{className:"detail-back",children:i.jsx("button",{type:"button",className:"btn-plain",onClick:()=>k(null),children:"← all providers"})}),i.jsxs("h2",{children:["Models for ",i.jsx("code",{children:Wi(p)})]}),i.jsxs("p",{className:"hint",children:["A provider isn't usable until it has models. Pull its catalog with"," ",i.jsx("strong",{children:"List models"}),", or add them by hand — then finish."]}),Y.length===0?i.jsx("div",{className:"flash",children:"No models yet — list the catalog or add one below."}):i.jsxs("table",{className:"kv-table",children:[i.jsx("thead",{children:i.jsxs("tr",{children:[i.jsx("th",{children:"Model"}),i.jsx("th",{children:"Modalities"}),i.jsx("th",{children:"Window"}),i.jsx("th",{})]})}),i.jsx("tbody",{children:Y.map($=>i.jsxs("tr",{children:[i.jsx("td",{children:i.jsx("code",{children:$.id})}),i.jsx("td",{children:($.input??["text"]).join(", ")}),i.jsx("td",{children:$.contextWindow?`${Math.round($.contextWindow/1024)}k`:"—"}),i.jsxs("td",{className:"row-actions",children:[i.jsx("button",{type:"button",className:"btn-plain",disabled:m,onClick:()=>Te($),children:"edit"}),i.jsx("button",{type:"button",className:"btn-danger",disabled:m,onClick:()=>{le(()=>lh($.id,p.id))},children:"remove"})]})]},$.id))})]}),i.jsx("div",{className:"setup-actions",children:i.jsx("button",{type:"button",className:"btn-small",disabled:m,onClick:()=>{se(p)},children:"List models from provider"})}),ce&&i.jsxs("div",{className:"list-models-panel",children:[i.jsxs("div",{className:"list-models-head",children:[i.jsx("strong",{children:ce.models.length})," models from"," ",i.jsx("code",{children:Wi(p)}),i.jsx("button",{type:"button",className:"btn-plain",onClick:()=>G(null),children:"close"})]}),ce.models.length===0?i.jsx("p",{className:"hint",children:"No models returned."}):i.jsxs(i.Fragment,{children:[i.jsx("div",{className:"list-models-grid",children:ce.models.map($=>i.jsxs("label",{className:"toggle",children:[i.jsx("input",{type:"checkbox",checked:ce.picked.has($.id),onChange:te=>{const v=new Set(ce.picked);te.target.checked?v.add($.id):v.delete($.id),G({...ce,picked:v})}})," ",i.jsx("code",{children:$.id})]},$.id))}),i.jsxs("button",{type:"button",className:"btn-small btn-primary",disabled:m||ce.picked.size===0,onClick:()=>we(p.id),children:["add ",ce.picked.size," model",ce.picked.size===1?"":"s"]})]})]}),i.jsxs("form",{className:"add-form",onSubmit:$=>{$.preventDefault(),_l(p.id)},children:[i.jsx("input",{ref:L,placeholder:"model name (sent to provider, e.g. claude-sonnet-4-6)",value:Q.id,onChange:$=>C({...Q,id:$.target.value})}),i.jsx("span",{className:"modality-select",children:Wy.map($=>i.jsxs("label",{className:"toggle",children:[i.jsx("input",{type:"checkbox",checked:Q.input.includes($),onChange:()=>Me($)})," ",$]},$))}),Q.showWindow?i.jsx("input",{type:"number",min:1,step:1024,placeholder:"context window (tokens)",value:Q.window||"",onChange:$=>C({...Q,window:Number.parseInt($.target.value,10)||0})}):i.jsx("button",{type:"button",className:"btn-plain",disabled:m,title:"Only needed when the model's real context window is smaller than what the agent requests.",onClick:()=>C({...Q,showWindow:!0}),children:"+ context window"}),i.jsx("button",{type:"submit",disabled:m,children:w?"save model":"add model"}),w?i.jsx("button",{type:"button",className:"btn-plain",disabled:m,onClick:()=>{C($i),ee(null)},children:"cancel"}):null]}),i.jsxs("div",{className:"setup-footer",children:[i.jsx("button",{type:"button",className:"btn-small btn-primary",disabled:m||Y.length===0,title:Y.length===0?"Add at least one model first":"",onClick:()=>k(null),children:"Done"}),Y.length===0&&i.jsx("button",{type:"button",className:"btn-danger",disabled:m,onClick:()=>{le(async()=>{await Po(p.id),k(null)})},children:"discard provider"})]})]})]})}return i.jsxs("div",{children:[o&&i.jsx("div",{className:"error inline",children:o}),i.jsxs("section",{className:"home-section",children:[i.jsx("h2",{children:"Model providers"}),i.jsx("p",{className:"hint",children:"An upstream afw can route to, and the models it serves. Add a provider, then give it models — list its catalog or add them by hand. Providers and models discovered at wire time appear here automatically."}),Qe.length===0?i.jsx("p",{className:"hint",children:"No providers yet — add one below."}):i.jsxs("table",{className:"kv-table",children:[i.jsx("thead",{children:i.jsxs("tr",{children:[i.jsx("th",{children:"Name"}),i.jsx("th",{children:"API"}),i.jsx("th",{children:"Auth"}),i.jsx("th",{children:"Base URL"}),i.jsx("th",{children:"Models"}),i.jsx("th",{})]})}),i.jsx("tbody",{children:Qe.map(p=>{const Y=z(p.id).length;return i.jsxs("tr",{children:[i.jsxs("td",{children:[i.jsx("span",{className:"reg-name",children:Wi(p)}),p.label&&p.label!==p.id?i.jsx("span",{className:"reg-id",title:"internal id (referenced by routing)",children:p.id}):null]}),i.jsx("td",{children:p.api}),i.jsx("td",{children:p.auth?.kind??"—"}),i.jsx("td",{children:i.jsx("code",{className:"path",children:p.baseUrl})}),i.jsx("td",{children:Y===0?i.jsx("span",{className:"dim",title:"this provider has no models yet",children:"none"}):Y}),i.jsxs("td",{className:"row-actions",children:[i.jsx("button",{type:"button",className:"btn-plain",disabled:m,onClick:()=>F(p.id),children:Y===0?"add models":"manage models"}),i.jsx("button",{type:"button",className:"btn-plain",disabled:m,onClick:()=>K(p),children:"edit"}),i.jsx("button",{type:"button",className:"btn-danger",disabled:m,onClick:()=>{le(()=>Po(p.id))},children:"remove"})]})]},p.id)})})]}),i.jsxs("form",{className:"add-form",onSubmit:q,children:[i.jsx("input",{placeholder:"provider name (e.g. Xiangxin)",value:j.name,onChange:p=>E({...j,name:p.target.value})}),i.jsx("input",{placeholder:"base URL (https://…/v1)",value:j.baseUrl,onChange:p=>E({...j,baseUrl:p.target.value})}),i.jsx("select",{value:j.api,onChange:p=>E({...j,api:p.target.value}),children:Jy.map(p=>i.jsx("option",{value:p,children:p},p))}),i.jsx("select",{value:j.authKind,onChange:p=>E({...j,authKind:p.target.value}),children:$y.map(p=>i.jsx("option",{value:p,children:p},p))}),j.authKind==="api-key"&&i.jsx("input",{placeholder:"header (x-api-key)",value:j.authHeader??"",onChange:p=>E({...j,authHeader:p.target.value})}),j.authKind!=="passthrough"&&i.jsx("input",{type:"password",placeholder:T?"API key (blank = keep)":"API key",value:j.apiKey??"",onChange:p=>E({...j,apiKey:p.target.value})}),i.jsx("button",{type:"submit",disabled:m,children:T?"save changes":"add provider → models"}),T?i.jsx("button",{type:"button",className:"btn-plain",disabled:m,onClick:ve,children:"cancel"}):null]})]})]})}function Fi({children:s}){return i.jsxs("span",{className:"helptip",children:[i.jsx("span",{className:"helptip-icon","aria-hidden":!0,children:"?"}),i.jsx("span",{className:"helptip-content",role:"tooltip",children:s})]})}const lu="__passthrough__",Ii="combo:";function Iy(s){return!s||s.kind==="passthrough"?lu:s.kind==="composite"?`${Ii}${s.comboId}`:s.kind==="chain"&&s.members[0]?s.members[0].modelId:lu}function Py(s,d){if(!s||s.kind==="passthrough")return"passthrough (no model swap)";if(s.kind==="composite"){const o=d.find(f=>f.id===s.comboId);return o?`fusion: ${o.label}`:`fusion: ${s.comboId} (missing)`}return s.members.map(o=>o.modelId).join(" → ")}function eg(s){const o=[`panel: ${s.panel.map(g=>g.fallback?`${g.modelId}→${g.fallback.modelId}`:g.modelId).join(" + ")}`],f=s.judge?.modelId??"synthesizer",m=s.synthesizer?.modelId??s.panel[0]?.modelId??"—";return o.push(`judge ${f} → synth ${m}`),s.vision&&o.push(`vision ${s.vision.modelId}`),s.webSearch&&o.push("web search"),o.join(" · ")}function lg(){const[s,d]=H.useState(null),[o,f]=H.useState(null),[m,g]=H.useState(null),[j,E]=H.useState(null),T=H.useCallback(async()=>{try{const[G,L]=await Promise.all([Oa(),vh()]);d(G),f(L),g(null)}catch(G){g(G.message)}},[]);H.useEffect(()=>{T()},[T]);const x=async(G,L,P)=>{E(G);try{if(L===lu)await yy(G);else if(L.startsWith(Ii))await Io(G,{kind:"composite",comboId:L.slice(Ii.length)});else{const le=P.find(ve=>ve.id===L);await Io(G,{kind:"chain",members:[{modelId:L,...le?{providerId:le.providerId}:{}}]})}await T()}catch(le){g(le.message)}finally{E(null)}},B=async G=>{E("subagent");try{await gy(G),await T()}catch(L){g(L.message)}finally{E(null)}};if(m&&!s)return i.jsxs("div",{className:"error",children:["Error: ",m]});if(!s||!o)return i.jsx("div",{className:"loading",children:"Loading…"});const{models:k,providers:Q,combos:C}=s,w=o.subagentDowngrade,ee=G=>Q.find(L=>L.id===G)?.label??G,ce=G=>C.find(L=>L.id===G);return i.jsxs("div",{children:[m&&i.jsx("div",{className:"error inline",children:m}),i.jsxs("section",{className:"home-section",children:[i.jsx("h2",{children:"Per-agent routes"}),i.jsxs("p",{className:"hint",children:["Each wired agent passes through unchanged, swaps to a single model, or uses a"," ",i.jsx("strong",{children:"fusion model"})," (parallel panel → judge → synthesize), built on the"," ",i.jsx("strong",{children:"Models"})," tab. ",i.jsx("code",{children:"<agent>/*"})," is the agent-wide default."]}),o.routes.length===0?i.jsx("div",{className:"empty",children:i.jsxs("p",{children:["No routes yet — launch a wired agent (e.g. ",i.jsx("code",{children:"afw claude"}),")."]})}):i.jsxs("table",{className:"kv-table",children:[i.jsx("thead",{children:i.jsxs("tr",{children:[i.jsx("th",{children:"Route"}),i.jsx("th",{children:"Decoder"}),i.jsx("th",{children:"Currently"}),i.jsx("th",{children:"Route to"}),i.jsxs("th",{children:["Details",i.jsxs(Fi,{children:["For a fusion model, the panel + judge + synthesizer it carries. Edit these on the ",i.jsx("strong",{children:"Models"})," tab — a route just picks one."]})]})]})}),i.jsx("tbody",{children:o.routes.map(G=>{const L=o.policy.agents[G.routeKey]?.target,P=L?.kind==="composite"?ce(L.comboId):void 0;return i.jsxs("tr",{children:[i.jsx("td",{children:i.jsx("code",{children:G.routeKey})}),i.jsx("td",{children:G.decoder}),i.jsx("td",{children:Py(L,C)}),i.jsx("td",{children:i.jsxs("select",{disabled:j===G.routeKey,value:Iy(L),onChange:le=>{x(G.routeKey,le.target.value,k)},children:[i.jsx("option",{value:lu,children:"passthrough (no swap)"}),C.length>0&&i.jsx("optgroup",{label:"Model Fusion",children:C.map(le=>i.jsx("option",{value:`${Ii}${le.id}`,children:le.label},le.id))}),i.jsx("optgroup",{label:"Models",children:k.map(le=>i.jsxs("option",{value:le.id,children:[le.id," (",ee(le.providerId),")"]},`${le.providerId}/${le.id}`))})]})}),i.jsx("td",{className:"dim",children:P?eg(P):L?.kind==="composite"?i.jsx("span",{title:"this fusion model no longer exists",children:"missing fusion"}):"—"})]},G.routeKey)})})]})]}),w&&i.jsxs("section",{className:"home-section",children:[i.jsx("h2",{children:"Subagent downgrade"}),i.jsx("p",{className:"hint",children:"Route Claude Code dynamic-workflow subagents to a cheaper model; the planner stays on its model. Small utility calls (under the min output budget) are left untouched."}),i.jsx("table",{className:"kv-table",children:i.jsxs("tbody",{children:[i.jsxs("tr",{children:[i.jsx("td",{children:"Enabled"}),i.jsx("td",{children:i.jsxs("label",{className:"toggle",children:[i.jsx("input",{type:"checkbox",disabled:j==="subagent",checked:w.enabled,onChange:G=>{B({enabled:G.target.checked})}})," ",w.enabled?"on":"off"]})})]}),i.jsxs("tr",{children:[i.jsxs("td",{children:["Run subagents on",i.jsx(Fi,{children:"The model Claude Code subagents are routed to while the planner stays on its own model. Pick a model that's actually registered with a provider — an unregistered id can't be resolved, so the call fails instead of downgrading."})]}),i.jsx("td",{children:i.jsxs("select",{disabled:j==="subagent",value:w.modelId,onChange:G=>{B({modelId:G.target.value})},children:[k.every(G=>G.id!==w.modelId)?i.jsxs("option",{value:w.modelId,children:[w.modelId," (unregistered)"]}):null,k.map(G=>i.jsxs("option",{value:G.id,children:[G.id," (",ee(G.providerId),")",G.id===w.modelId?" — current":""]},`${G.providerId}/${G.id}`))]})})]}),i.jsxs("tr",{children:[i.jsxs("td",{children:["Min output budget",i.jsxs(Fi,{children:["afw tells a subagent apart from a tiny utility call by the request's",i.jsx("code",{children:" max_tokens"}),". Calls asking for fewer than"," ",w.minMaxTokens.toLocaleString()," output tokens are treated as utility calls and left on their original model — only larger calls get downgraded."]})]}),i.jsxs("td",{children:["leave calls under ",w.minMaxTokens.toLocaleString()," max_tokens untouched"]})]})]})})]})]})}const tg=["duckduckgo","brave","searxng","tavily","baidu"],uh=new Set(["brave","tavily","baidu"]),ch=new Set(["searxng"]),sh={id:"",backend:"duckduckgo",baseUrl:"",apiKey:""};function ag(s){return s.active.web_search??s.providers.find(d=>d.kind==="web_search")?.id}function ng(){const[s,d]=H.useState(null),[o,f]=H.useState(null),[m,g]=H.useState(!1),[j,E]=H.useState(sh),T=H.useCallback(async()=>{try{d(await yh()),f(null)}catch(C){f(C.message)}},[]);H.useEffect(()=>{T()},[T]);const x=async C=>{g(!0);try{await C(),await T()}catch(w){f(w.message)}finally{g(!1)}},B=C=>{if(C.preventDefault(),!j.id)return f("tool provider id is required");x(async()=>{await Sy({id:j.id,kind:"web_search",backend:j.backend,...ch.has(j.backend)&&j.baseUrl?{baseUrl:j.baseUrl}:{},...uh.has(j.backend)&&j.apiKey?{apiKey:j.apiKey}:{}}),E(sh)})};if(o&&!s)return i.jsxs("div",{className:"error",children:["Error: ",o]});if(!s)return i.jsx("div",{className:"loading",children:"Loading…"});const k=ag(s),Q=s.providers.filter(C=>C.kind==="web_search");return i.jsxs("div",{children:[o&&i.jsx("div",{className:"error inline",children:o}),i.jsxs("section",{className:"home-section",children:[i.jsx("h2",{children:"Web search backends"}),i.jsxs("p",{className:"hint",children:["Backends that fulfill the ",i.jsx("code",{children:"web_search"})," capability for models that lack it. The active one serves every routed search; changes apply on the next call (no restart)."]}),Q.length===0?i.jsx("p",{className:"hint",children:"No tool providers."}):i.jsxs("table",{className:"kv-table",children:[i.jsx("thead",{children:i.jsxs("tr",{children:[i.jsx("th",{children:"Active"}),i.jsx("th",{children:"Provider"}),i.jsx("th",{children:"Backend"}),i.jsx("th",{children:"Endpoint / key"}),i.jsx("th",{children:"$/call"}),i.jsx("th",{})]})}),i.jsx("tbody",{children:Q.map(C=>i.jsxs("tr",{children:[i.jsx("td",{children:i.jsx("input",{type:"radio",name:"active-web_search",checked:k===C.id,disabled:m,onChange:()=>{x(()=>Ey("web_search",C.id))}})}),i.jsxs("td",{children:[C.label,C.origin==="seeded"&&i.jsx("span",{className:"muted",children:" (default)"})]}),i.jsx("td",{children:C.backend}),i.jsxs("td",{children:[C.baseUrl?i.jsx("code",{className:"path",children:C.baseUrl}):null,C.authRef?i.jsx("span",{className:"ok-badge",children:"key set"}):null,!C.baseUrl&&!C.authRef?i.jsx("span",{className:"muted",children:"—"}):null]}),i.jsx("td",{children:C.costPerCall?`$${C.costPerCall}`:"—"}),i.jsx("td",{children:C.origin==="seeded"?i.jsx("span",{className:"muted",children:"built-in"}):i.jsx("button",{type:"button",className:"btn-danger",disabled:m,onClick:()=>{x(()=>Ny(C.id))},children:"remove"})})]},C.id))})]}),i.jsxs("form",{className:"add-form",onSubmit:B,children:[i.jsx("input",{placeholder:"provider id",value:j.id,onChange:C=>E({...j,id:C.target.value})}),i.jsx("select",{value:j.backend,onChange:C=>E({...j,backend:C.target.value}),children:tg.map(C=>i.jsx("option",{value:C,children:C},C))}),ch.has(j.backend)&&i.jsx("input",{placeholder:"instance URL",value:j.baseUrl,onChange:C=>E({...j,baseUrl:C.target.value})}),uh.has(j.backend)&&i.jsx("input",{type:"password",placeholder:"API key",value:j.apiKey,onChange:C=>E({...j,apiKey:C.target.value})}),i.jsx("button",{type:"submit",disabled:m,children:"add backend"})]})]})]})}const ig=[{key:"routes",label:"Routes"},{key:"fusion",label:"Model Fusion"},{key:"models",label:"Model providers"},{key:"tools",label:"Tool providers"}];function ug(){const[s,d]=H.useState("routes");return i.jsxs("div",{className:"routing",children:[i.jsx("div",{className:"subtabs",children:ig.map(o=>i.jsx("button",{type:"button",className:`subtab ${s===o.key?"active":""}`,onClick:()=>d(o.key),children:o.label},o.key))}),s==="routes"?i.jsx(lg,{}):s==="models"?i.jsx(Fy,{}):s==="fusion"?i.jsx(Vy,{}):i.jsx(ng,{})]})}function rh(s){if(!s||s.length<200)return!1;if(s.includes("<available_skills>")||s.includes("<system-reminder>")||/^<[A-Za-z][A-Za-z0-9_ -]*>\s*$/m.test(s)||/^You are a personal assistant running inside OpenClaw/m.test(s)||/^# Hermes Agent Persona/m.test(s))return!0;const d=s.match(/^##\s+\S/gm);return!!(d&&d.length>=3)}function Rs(s){if(!s)return[];const d=[];let o=s;const f=/^[ \t]*<([A-Za-z][A-Za-z0-9_ -]*)>[ \t]*\n([\s\S]*?)\n^[ \t]*<\/\1>[ \t]*$/gm;o=o.replace(f,(T,x,B)=>{const k=x.trim();return k==="available_skills"?d.push({kind:"skills",skills:cg(B)}):k==="system-reminder"?d.push({kind:"reminder",body:B.trim()}):d.push({kind:"tagged",tag:k,body:B.trim()}),`
|
|
12
|
+
__EMBED_${d.length-1}__
|
|
13
|
+
`}),o=o.replace(/<!--[\s\S]*?-->/g,"");const m=o.split(`
|
|
14
|
+
`),g=[];let j={title:null,level:2,body:[]};const E=()=>{const T=j.body.join(`
|
|
15
|
+
`).trim();if(j.title||T||j.embedded){const x={title:j.title,level:j.level,body:T};j.embedded&&(x.embedded=j.embedded),g.push(x)}};for(const T of m){const x=/^(#{1,2})\s+(.+)$/.exec(T);if(x){E(),j={title:x[2].trim(),level:x[1].length===1?1:2,body:[]};continue}const B=/^__EMBED_(\d+)__$/.exec(T.trim());if(B){E(),g.push({title:null,level:2,body:"",embedded:d[Number(B[1])]}),j={title:null,level:2,body:[]};continue}j.body.push(T)}return E(),g.length>0?g:[{title:null,level:2,body:s}]}function cg(s){const d=[],o=/<skill>\s*<name>([\s\S]*?)<\/name>\s*<description>([\s\S]*?)<\/description>(?:\s*<location>([\s\S]*?)<\/location>)?\s*<\/skill>/g;let f;for(;(f=o.exec(s))!=null;)d.push({name:f[1].trim(),description:f[2].replace(/\s+/g," ").trim(),...f[3]?{location:f[3].trim()}:{}});if(d.length>0)return d;const m=s.split(`
|
|
16
|
+
`);let g;for(const j of m){const E=/^\s{0,4}([\w-]+)(?::\s*(.*))?$/.exec(j.replace(/\s+$/,"")),T=/^\s+-\s+([\w-]+):\s*(.*)$/.exec(j);T?d.push({name:T[1].trim(),description:T[2].trim(),...g?{category:g}:{}}):E&&!j.trim().startsWith("-")&&j.trim().endsWith(":")&&(g=E[1].trim())}return d}function sg({content:s}){const d=Rs(s);return i.jsx("div",{className:"prompt-structured",children:d.map((o,f)=>i.jsx(Hs,{section:o},f))})}function Hs({section:s}){const d=s.title==null;return s.embedded&&!s.body?i.jsx(dg,{title:s.title,embedded:s.embedded}):i.jsxs("div",{className:`prompt-section${d?" prompt-lede":""}`,children:[s.title?i.jsxs("div",{className:"prompt-section-title",children:[i.jsx("span",{className:"prompt-section-marker",children:s.level===1?"§":"#"}),s.title]}):null,s.body?i.jsx(rg,{body:s.body}):null]})}function rg({body:s}){const d=s.replace(/\n\[\[(?:skills|reminder):\d+\]\]\n/g,"").trim();return d?i.jsx("div",{className:"prompt-section-body",children:d}):null}function dg({title:s,embedded:d}){return d.kind==="skills"?i.jsx(og,{title:s,skills:d.skills}):d.kind==="reminder"?i.jsx(hg,{title:s,body:d.body}):i.jsx(fg,{tag:d.tag,body:d.body})}function fg({tag:s,body:d}){const o=Rs(d);return i.jsxs("div",{className:"prompt-section prompt-tagged",children:[i.jsxs("div",{className:"prompt-section-title",children:[i.jsx("span",{className:"prompt-section-marker",children:"‹›"}),s]}),i.jsx("div",{className:"prompt-section-body prompt-tagged-body",children:o.length>1||o[0]?.embedded!=null?i.jsx("div",{className:"prompt-structured",children:o.map((f,m)=>i.jsx(Hs,{section:f},m))}):d.trim()})]})}function og({title:s,skills:d}){const[o,f]=H.useState(!1);if(d.length===0)return null;const m=d.some(x=>x.category),g=new Map;for(const x of d){const B=x.category??"(uncategorised)",k=g.get(B)??[];k.push(x),g.set(B,k)}const j=12,E=o?d:d.slice(0,j),T=d.length-E.length;return i.jsxs("div",{className:"prompt-section prompt-skills",children:[i.jsxs("div",{className:"prompt-section-title",children:[i.jsx("span",{className:"prompt-section-marker",children:"⚒"}),s||"Available skills",i.jsx("span",{className:"prompt-section-count",children:d.length}),d.length>j?i.jsx("button",{type:"button",className:"msg-expand-btn prompt-section-expand",onClick:()=>f(x=>!x),children:o?"▾ show fewer":`▸ show all ${d.length}`}):null]}),m?i.jsx("div",{className:"prompt-skills-groups",children:[...g.entries()].map(([x,B])=>{const k=o?B:B.slice(0,4),Q=B.length-k.length;return i.jsxs("div",{className:"prompt-skills-group",children:[i.jsx("div",{className:"prompt-skills-group-name",children:x}),i.jsxs("div",{className:"prompt-skills-list",children:[k.map(C=>i.jsx(dh,{skill:C},`${x}-${C.name}`)),Q>0?i.jsxs("span",{className:"prompt-skills-more",children:["+ ",Q," more"]}):null]})]},x)})}):i.jsxs("div",{className:"prompt-skills-list",children:[E.map(x=>i.jsx(dh,{skill:x},x.name)),T>0?i.jsxs("span",{className:"prompt-skills-more",children:["+ ",T," more"]}):null]})]})}function dh({skill:s}){return i.jsxs("div",{className:"skill-chip",title:s.description,children:[i.jsx("span",{className:"skill-chip-name",children:s.name}),s.description?i.jsx("span",{className:"skill-chip-desc",children:s.description}):null]})}function hg({title:s,body:d}){const o=Rs(d),f=o.length>1||o[0]?.embedded!=null||o[0]?.title!=null;return i.jsxs("div",{className:"prompt-section prompt-reminder",children:[i.jsxs("div",{className:"prompt-section-title",children:[i.jsx("span",{className:"prompt-section-marker",children:"⚠"}),s||"system-reminder"]}),i.jsx("div",{className:"prompt-section-body prompt-reminder-body",children:f?i.jsx("div",{className:"prompt-structured",children:o.map((m,g)=>i.jsx(Hs,{section:m},g))}):d.trim()})]})}function mg(s,d){return d&&((s==="system"||s==="developer")&&rh(d)||s==="user"&&d.includes("<system-reminder>")&&rh(d))?d:null}function vg({runId:s}){const[d,o]=H.useState(null),[f,m]=H.useState(null);if(H.useEffect(()=>{let j=!1;return(async()=>{try{const E=await iy(s);j||o(E)}catch(E){j||m(E.message)}})(),()=>{j=!0}},[s]),f)return i.jsxs("div",{className:"error",children:["Error: ",f]});if(!d)return i.jsx("div",{className:"loading",children:"Loading…"});const g=d.run;return i.jsxs("div",{className:"run-detail",children:[i.jsx("button",{type:"button",className:"back",onClick:()=>{window.location.hash=g.threadId?`#/task/${encodeURIComponent(g.threadId)}`:"#/tasks"},children:"← back to task"}),i.jsxs("div",{className:"run-header",children:[i.jsx("h2",{children:i.jsx("code",{children:g.id})}),i.jsxs("div",{className:"run-header-meta",children:[i.jsx("span",{children:g.agent}),i.jsx("span",{children:"·"}),i.jsx("span",{children:g.status}),i.jsx("span",{children:"·"}),i.jsxs("span",{children:["model: ",g.model?i.jsx("code",{children:g.model}):i.jsx("span",{className:"muted",children:"—"})]}),i.jsx("span",{children:"·"}),i.jsx("span",{children:i.jsx(lt,{ms:g.startedAt})}),i.jsx("span",{children:"·"}),i.jsx("span",{children:i.jsx(Mn,{ms:g.durMs})})]})]}),i.jsx(gg,{actions:d.actions}),i.jsx(pg,{actions:d.actions}),i.jsx("div",{className:"meta",children:i.jsxs("dl",{children:[i.jsx("dt",{children:"Tokens"}),i.jsxs("dd",{children:[g.tokensIn??0," / ",g.tokensOut??0]}),i.jsx("dt",{children:"Cache R/W"}),i.jsx("dd",{children:i.jsx(Ds,{read:g.cacheReadTokens,write:g.cacheWriteTokens})})]})}),i.jsx(jg,{actions:d.actions})]})}function yg(s){if(s.kind!=="model_call")return null;const d=s.payload;return!d||typeof d!="object"?null:d}function _s(s){return typeof s.status=="number"&&s.status>=400||!!s.error}function gg({actions:s}){const d=s.filter(E=>E.kind==="model_call").map(E=>({id:E.id,ts:E.ts,p:yg(E)})).filter(E=>E.p!=null).sort((E,T)=>E.ts-T.ts),o=d.filter(E=>_s(E.p));if(o.length===0)return null;const f=d.find(E=>!_s(E.p)&&E.p.orchestration?.role==="failover"),m=!_s(d[d.length-1].p),g=f!=null||m&&o.length<d.length,j=f?.p.model??d[d.length-1]?.p.model;return i.jsxs("section",{className:`run-errors${g?" run-errors-recovered":""}`,children:[g?i.jsxs("div",{className:"run-recovered-note",children:[i.jsx("span",{className:"run-recovered-badge",children:"recovered"}),"Chain failed over and completed",j?i.jsxs(i.Fragment,{children:[" ","on ",i.jsx("code",{children:j})]}):null,". The attempt",o.length>1?"s":""," below errored but did not break the run."]}):null,o.map(({id:E,p:T})=>i.jsxs("div",{className:`run-error-card${g?" run-error-card-recovered":""}`,children:[i.jsxs("div",{className:"run-error-head",children:[i.jsx("span",{className:"run-error-badge",children:g?"failover":"error"}),typeof T.status=="number"?i.jsxs("span",{className:"run-error-status",children:["HTTP ",T.status]}):null,i.jsxs("span",{className:"run-error-model",children:[T.clientModel&&T.clientModel!==T.model?i.jsxs(i.Fragment,{children:["requested ",i.jsx("code",{children:T.clientModel})," →"," "]}):null,T.model?i.jsx("code",{children:T.model}):null,T.providerId?i.jsxs("span",{className:"muted",children:[" @ ",T.providerId]}):null]})]}),T.error?i.jsx("pre",{className:"run-error-body",children:T.error}):null]},E))]})}function pg({actions:s}){const d=new Map;for(const g of s){const j=d.get(g.kind)??{tokens:0,count:0};j.tokens+=(g.tokensIn??0)+(g.tokensOut??0),j.count+=1,d.set(g.kind,j)}const o=Array.from(d.entries()).sort((g,j)=>j[1].tokens-g[1].tokens),f=o.reduce((g,[,j])=>g+j.tokens,0),m=Math.max(...o.map(g=>g[1].tokens),1);return i.jsxs("section",{className:"cost-breakdown",children:[i.jsxs("div",{className:"cost-breakdown-head",children:[i.jsxs("span",{className:"cost-breakdown-title",children:["Token breakdown",i.jsxs(Fi,{children:["This run's input + output tokens, split by action kind.",i.jsx("br",{}),i.jsx("code",{children:"model_call"})," = a call to an LLM endpoint.",i.jsx("br",{}),i.jsx("code",{children:"mcp_call"})," = MCP JSON-RPC frame (usually 0 tokens).",i.jsx("br",{}),i.jsx("code",{children:"network"})," = other HTTP through the proxy."]})]}),i.jsxs("span",{className:"cost-breakdown-total",children:[Os(f)," tok"]})]}),i.jsx("div",{className:"cost-breakdown-rows",children:o.map(([g,j])=>i.jsxs("div",{className:"cost-breakdown-row",children:[i.jsx("span",{className:`kind kind-${g}`,children:g}),i.jsxs("span",{className:"cost-breakdown-count",children:["(",j.count,")"]}),i.jsx("span",{className:"cost-breakdown-bar-track",children:i.jsx("span",{className:"cost-breakdown-bar-fill",style:{width:`${j.tokens/m*100}%`}})}),i.jsx("span",{className:"cost-breakdown-cost",children:Os(j.tokens)}),i.jsx("span",{className:"cost-breakdown-pct",children:f>0?`${Math.round(j.tokens/f*100)}%`:"—"})]},g))})]})}const fh=800;function jg({actions:s}){const d=H.useMemo(()=>Tg(s),[s]),[o,f]=H.useState(new Set);if(d.length===0)return i.jsx("div",{className:"empty",children:"No model calls captured for this run."});const m=g=>{f(j=>{const E=new Set(j);return E.has(g)?E.delete(g):E.add(g),E})};return i.jsxs("section",{className:"full-messages",children:[i.jsxs("div",{className:"full-messages-head",children:[i.jsx("span",{className:"full-messages-title",children:"Full messages"}),i.jsx("span",{className:"full-messages-count",children:d.length})]}),i.jsx("div",{className:"full-messages-list",children:d.map((g,j)=>i.jsx(bg,{index:j+1,message:g,isExpanded:o.has(j),onToggle:()=>m(j)},j))})]})}function bg({index:s,message:d,isExpanded:o,onToggle:f}){const m=d.role||"unknown",g=ks(d.content),j=m==="tool"?bh(g):null,E=j?null:mg(m,g),T=j||E?"":m==="tool"?_g(g):g,x=T.length>fh,B=x&&!o?`${T.slice(0,fh)}…`:T,k=g.length;return i.jsxs("div",{className:"msg-card",children:[i.jsxs("div",{className:"msg-card-head",children:[i.jsxs("div",{className:"msg-card-head-left",children:[i.jsxs("span",{className:"msg-card-num",children:["#",s]}),i.jsx("span",{className:`msg-role msg-role-${m}`,children:m}),d.name?i.jsxs("span",{className:"msg-meta",children:["name: ",i.jsx("code",{children:d.name})]}):null,d.tool_call_id?i.jsxs("span",{className:"msg-meta",children:["tool_call_id: ",i.jsx("code",{children:d.tool_call_id})]}):null,k?i.jsxs("span",{className:"msg-meta",title:"Approximate token count (ASCII ÷ 4 + CJK × 0.6). Real count comes from the upstream usage field; this is just a budget hint.",children:[k.toLocaleString()," chars · ~",Nh(Sh(g))," tok"]}):null]}),!j&&!E&&x?i.jsx("button",{type:"button",className:"msg-expand-btn",onClick:f,children:o?"▾ collapse":"▸ expand"}):null]}),j?i.jsx("div",{className:"msg-card-result",children:i.jsx(xh,{args:j,variant:"result"})}):E?i.jsx("div",{className:"msg-card-prompt",children:i.jsx(sg,{content:E})}):T?i.jsx("pre",{className:"msg-card-body",children:B}):null,Array.isArray(d.tool_calls)&&d.tool_calls.length>0?i.jsx("div",{className:"msg-card-toolcalls",children:d.tool_calls.map((Q,C)=>i.jsx(xg,{call:Q},Q.id||C))}):null]})}function xg({call:s}){const d=s.function?.name||"function",o=bh(s.function?.arguments),f=Sg(s.function?.arguments),m=f.length;return i.jsxs("div",{className:"toolcall-card",children:[i.jsxs("div",{className:"toolcall-card-head",children:[i.jsx("span",{className:"toolcall-badge",children:"tool call"}),i.jsx("code",{className:"toolcall-name",children:d}),s.id?i.jsxs("span",{className:"toolcall-id",children:["id: ",i.jsx("code",{children:s.id})]}):null,m>0?i.jsxs("span",{className:"toolcall-id",title:"Approximate token count for the tool-call arguments",children:[m.toLocaleString()," chars · ~",Nh(Sh(f))," tok"]}):null]}),o?i.jsx(xh,{args:o}):null]})}function Sg(s){if(s==null)return"";if(typeof s=="string")return s;try{return JSON.stringify(s)}catch{return String(s)}}function bh(s){if(s==null)return null;if(typeof s=="string"){const d=s.trim();if(!d||!(d.startsWith("{")||d.startsWith("[")))return null;try{const o=JSON.parse(d);return o&&typeof o=="object"&&!Array.isArray(o)?Object.keys(o).length===0?null:o:null}catch{return null}}if(Array.isArray(s))return null;if(typeof s=="object"){const d=s;return Object.keys(d).length===0?null:d}return null}function xh({args:s,variant:d="args"}){const o=Object.keys(s);return o.length===0?null:i.jsx("dl",{className:`args-list args-list-${d}`,children:o.map(f=>i.jsxs("div",{className:"args-row",children:[i.jsx("dt",{className:"args-key",children:f}),i.jsx("dd",{className:"args-val",children:i.jsx(Ng,{value:s[f]})})]},f))})}function Ng({value:s}){if(s==null)return i.jsx("span",{className:"args-dim",children:"null"});if(typeof s=="string")return s===""?i.jsx("span",{className:"args-dim",children:'""'}):i.jsx("span",{className:"args-string",children:s});if(typeof s=="number")return i.jsx("span",{className:"args-num",children:s});if(typeof s=="boolean")return i.jsx("span",{className:"args-bool",children:String(s)});if(Array.isArray(s))return s.length===0?i.jsx("span",{className:"args-dim",children:"[]"}):s.every(o=>o==null||typeof o=="string"||typeof o=="number"||typeof o=="boolean")&&s.length<=8?i.jsxs("span",{className:"args-array",children:["[",s.map((o,f)=>i.jsx("span",{className:"args-array-item",children:String(o)},f)),"]"]}):i.jsxs("span",{className:"args-dim",children:["[",s.length," items]"]});if(typeof s=="object"){const d=s,o=Object.keys(d);return o.length===0?i.jsx("span",{className:"args-dim",children:"{}"}):i.jsxs("div",{className:"args-nested",children:[o.slice(0,8).map(f=>i.jsxs("div",{className:"args-row",children:[i.jsx("dt",{className:"args-key args-key-nested",children:f}),i.jsx("dd",{className:"args-val",children:i.jsx(Eg,{value:d[f]})})]},f)),o.length>8?i.jsxs("div",{className:"args-dim",children:["+ ",o.length-8," more fields"]}):null]})}return i.jsx("span",{className:"args-string",children:String(s)})}function Sh(s){if(!s)return 0;let d=0,o=0;for(let f=0;f<s.length;f++)s.charCodeAt(f)<128?d++:o++;return Math.round(d/4+o*.6)}function Nh(s){return s<1e3?String(s):s<1e6?`${(s/1e3).toFixed(s<1e4?1:0)}K`:`${(s/1e6).toFixed(2)}M`}function Eg({value:s}){if(s==null)return i.jsx("span",{className:"args-dim",children:"null"});if(typeof s=="string")return s===""?i.jsx("span",{className:"args-dim",children:'""'}):i.jsx("span",{className:"args-string",children:s});if(typeof s=="number")return i.jsx("span",{className:"args-num",children:s});if(typeof s=="boolean")return i.jsx("span",{className:"args-bool",children:String(s)});if(Array.isArray(s))return i.jsxs("span",{className:"args-dim",children:["[",s.length," ",s.length===1?"item":"items","]"]});if(typeof s=="object"){const d=Object.keys(s);return i.jsx("span",{className:"args-dim",children:`{${d.slice(0,3).join(", ")}${d.length>3?", …":""}}`})}return i.jsx("span",{className:"args-string",children:String(s)})}function Tg(s){const d=s.filter(E=>E.kind==="model_call").sort((E,T)=>E.ts-T.ts);if(d.length===0)return[];const f=d[d.length-1].payload??{},m=Array.isArray(f.messages)?f.messages:[],g=[];for(const E of m)for(const T of Ag(E))g.push(T);const j=Array.isArray(f.response)?f.response:[];if(j.length>0)for(const E of Eh("assistant",j))g.push(E);return g}function Ag(s){if(!s||typeof s!="object")return[];const d=s;if(typeof d.role!="string")return[];if(Array.isArray(d.content)&&zg(d.content))return Eh(d.role,d.content,d);const o={role:d.role,content:d.content};return typeof d.name=="string"&&(o.name=d.name),typeof d.tool_call_id=="string"&&(o.tool_call_id=d.tool_call_id),Array.isArray(d.tool_calls)&&(o.tool_calls=d.tool_calls),[o]}function Eh(s,d,o){const f=[],m=[],g=[];for(const E of d){if(!E||typeof E!="object")continue;const T=E;if(T.type==="text"&&typeof T.text=="string")f.push(T.text);else if(T.type==="thinking"){const x=typeof T.thinking=="string"?T.thinking:typeof T.text=="string"?T.text:"";x.trim()&&f.push(`[thinking]
|
|
17
|
+
${x}`)}else if(T.type==="tool_use")m.push({id:typeof T.id=="string"?T.id:void 0,type:"function",function:{name:typeof T.name=="string"?T.name:"tool",arguments:T.input}});else if(T.type==="tool_result"){const x=T.content;let B="";typeof x=="string"?B=x:Array.isArray(x)?B=ks(x):x!=null&&(B=Pi(x));const k=typeof T.tool_use_id=="string"?T.tool_use_id:typeof T.tool_call_id=="string"?T.tool_call_id:void 0,Q={role:"tool",content:B};k&&(Q.tool_call_id=k),g.push(Q)}}const j=[];if(f.length>0||m.length>0){const E={role:s,content:f.join(`
|
|
18
|
+
|
|
19
|
+
`)};m.length>0&&(E.tool_calls=m),o&&(typeof o.name=="string"&&(E.name=o.name),typeof o.tool_call_id=="string"&&(E.tool_call_id=o.tool_call_id),Array.isArray(o.tool_calls)&&(E.tool_calls=[...E.tool_calls??[],...o.tool_calls])),j.push(E)}for(const E of g)j.push(E);return j}function zg(s){for(const d of s){if(!d||typeof d!="object")continue;const o=d.type;if(o==="text"||o==="thinking"||o==="tool_use"||o==="tool_result")return!0}return!1}function ks(s){return s==null?"":typeof s=="string"?s:Array.isArray(s)?s.map(d=>{if(d==null)return"";if(typeof d=="string")return d;if(typeof d!="object")return String(d);const o=d;return o.type==="text"&&typeof o.text=="string"?o.text:o.type==="tool_result"?typeof o.content=="string"?o.content:Array.isArray(o.content)?ks(o.content):Pi(o.content):Pi(d)}).filter(Boolean).join(`
|
|
20
|
+
`):Pi(s)}function _g(s){if(!s)return s;const d=s.trim();if(!d.startsWith("{")&&!d.startsWith("["))return s;try{return JSON.stringify(JSON.parse(d),null,2)}catch{return s}}function Pi(s){try{return JSON.stringify(s,null,2)}catch{return String(s)}}function tu({outcome:s}){return s==="failed"?i.jsx("span",{className:"run-error-badge",children:"error"}):s==="recovered"?i.jsx("span",{className:"run-recovered-badge",title:"An attempt errored but failover succeeded",children:"recovered"}):null}function qs(s){if(s==="failed")return"run-errored";if(s==="recovered")return"run-recovered"}const oh=50;function Mg(){const[s,d]=H.useState(null),[o,f]=H.useState(null),[m,g]=H.useState(0);if(H.useEffect(()=>{let C=!1;const w=async()=>{try{const ce=await hh({limit:oh,offset:m*oh});C||(d(ce),f(null))}catch(ce){C||f(ce.message)}};w();const ee=setInterval(()=>{m===0&&w()},4e3);return()=>{C=!0,clearInterval(ee)}},[m]),o&&!s)return i.jsxs("div",{className:"error",children:["Error: ",o]});if(s===null)return i.jsx("div",{className:"loading",children:"Loading…"});const{rows:j,total:E,offset:T,limit:x}=s,B=Math.max(0,Math.ceil(E/x)-1),k=E===0?0:T+1,Q=Math.min(E,T+j.length);return E===0?i.jsxs("div",{className:"empty",children:[i.jsx("p",{children:"No tasks yet."}),i.jsxs("p",{className:"hint",children:["Run a wired agent (e.g. ",i.jsx("code",{children:"afw claude"}),") and refresh. A task is one correlated conversation — its turns show up as runs inside."]})]}):i.jsxs("div",{className:"run-list-wrap",children:[i.jsxs("table",{className:"runs",children:[i.jsx("thead",{children:i.jsxs("tr",{children:[i.jsx("th",{children:"Task"}),i.jsx("th",{children:"Started"}),i.jsx("th",{children:"Agent"}),i.jsx("th",{children:"Model"}),i.jsx("th",{children:"Status"}),i.jsx("th",{children:"Runs"}),i.jsx("th",{children:"Actions"}),i.jsx("th",{children:"Dur"}),i.jsx("th",{children:"In/Out"}),i.jsx("th",{children:"Cache R/W"})]})}),i.jsx("tbody",{children:j.map(C=>i.jsxs("tr",{className:qs(C.outcome),onClick:()=>{window.location.hash=`#/task/${encodeURIComponent(C.id)}`},children:[i.jsx("td",{children:C.title?i.jsx("span",{className:"task-title",children:C.title}):i.jsx("code",{children:Ua(C.id)})}),i.jsx("td",{children:i.jsx(lt,{ms:C.startedAt})}),i.jsx("td",{children:C.agent}),i.jsx("td",{children:C.model?i.jsx("code",{children:C.model}):i.jsx("span",{className:"muted",children:"—"})}),i.jsx("td",{children:C.outcome!=="ok"?i.jsx(tu,{outcome:C.outcome}):C.endedAt==null?i.jsx("span",{className:"muted",children:"running"}):"done"}),i.jsx("td",{children:C.runCount}),i.jsx("td",{children:C.actionCount}),i.jsx("td",{children:i.jsx(Mn,{ms:C.durMs})}),i.jsx("td",{children:i.jsx(ph,{tokensIn:C.tokensIn,tokensOut:C.tokensOut})}),i.jsx("td",{children:i.jsx(Ds,{read:C.cacheReadTokens,write:C.cacheWriteTokens})})]},C.id))})]}),i.jsxs("div",{className:"pager",children:[i.jsxs("div",{className:"pager-count",children:[k.toLocaleString(),"–",Q.toLocaleString()," of ",E.toLocaleString()]}),i.jsxs("div",{className:"pager-controls",children:[i.jsx("button",{type:"button",disabled:m===0,onClick:()=>g(0),className:"pager-btn",children:"« first"}),i.jsx("button",{type:"button",disabled:m===0,onClick:()=>g(C=>Math.max(0,C-1)),className:"pager-btn",children:"← prev"}),i.jsxs("span",{className:"pager-page",children:["page ",m+1," / ",B+1]}),i.jsx("button",{type:"button",disabled:m>=B,onClick:()=>g(C=>Math.min(B,C+1)),className:"pager-btn",children:"next →"}),i.jsx("button",{type:"button",disabled:m>=B,onClick:()=>g(B),className:"pager-btn",children:"last »"})]})]})]})}function Cg(){const[s,d]=H.useState(null),[o,f]=H.useState(null);return H.useEffect(()=>{let m=!1;const g=()=>cy().then(E=>{m||(d(E),f(null))}).catch(E=>!m&&f(E.message));g();const j=setInterval(g,5e3);return()=>{m=!0,clearInterval(j)}},[]),o&&!s?i.jsxs("div",{className:"error",children:["Error: ",o]}):s?s.length===0?i.jsxs("div",{className:"empty",children:[i.jsx("p",{children:"No agent instances yet."}),i.jsxs("p",{className:"hint",children:["Populated from new traffic. Launch a wired agent (e.g. ",i.jsx("code",{children:"afw claude"}),") — each running instance shows up here with the MCP servers, skills, and tools it used."]})]}):i.jsx("div",{className:"run-list-wrap",children:i.jsxs("table",{className:"runs",children:[i.jsx("thead",{children:i.jsxs("tr",{children:[i.jsx("th",{children:"Agent"}),i.jsx("th",{children:"Instance"}),i.jsx("th",{children:"Tasks"}),i.jsx("th",{children:"MCP"}),i.jsx("th",{children:"Skills"}),i.jsx("th",{children:"Tools"}),i.jsx("th",{children:"Actions"}),i.jsx("th",{children:"Last active"})]})}),i.jsx("tbody",{children:s.map(m=>i.jsxs("tr",{onClick:()=>{window.location.hash=`#/instance/${m.key}`},children:[i.jsx("td",{children:m.agent}),i.jsx("td",{children:m.instanceId?i.jsx("code",{children:m.instanceId}):i.jsx("span",{className:"muted",children:"(unknown)"})}),i.jsx("td",{children:m.taskCount}),i.jsx("td",{children:m.mcpCount||i.jsx("span",{className:"muted",children:"—"})}),i.jsx("td",{children:m.skillCount||i.jsx("span",{className:"muted",children:"—"})}),i.jsx("td",{children:m.toolCount||i.jsx("span",{className:"muted",children:"—"})}),i.jsx("td",{children:m.actionCount}),i.jsx("td",{children:i.jsx(lt,{ms:m.lastActive})})]},m.key))})]})}):i.jsx("div",{className:"loading",children:"Loading…"})}function Og(){const[s,d]=H.useState(null),[o,f]=H.useState(null);return H.useEffect(()=>{let m=!1;return ry().then(g=>!m&&d(g)).catch(g=>!m&&f(g.message)),()=>{m=!0}},[]),o&&!s?i.jsxs("div",{className:"error",children:["Error: ",o]}):s?s.length===0?i.jsxs("div",{className:"empty",children:[i.jsx("p",{children:"No MCP activity yet."}),i.jsxs("p",{className:"hint",children:["Populated from new traffic. When an agent calls an MCP server (or an ",i.jsx("code",{children:"mcp__*"})," ","tool), it shows up here aggregated across instances."]})]}):i.jsx("div",{className:"run-list-wrap",children:i.jsxs("table",{className:"runs",children:[i.jsx("thead",{children:i.jsxs("tr",{children:[i.jsx("th",{children:"MCP server"}),i.jsx("th",{children:"Calls"}),i.jsx("th",{children:"Methods"}),i.jsx("th",{children:"Instances"}),i.jsx("th",{children:"Tasks"}),i.jsx("th",{children:"Errors"}),i.jsx("th",{children:"Last active"})]})}),i.jsx("tbody",{children:s.map(m=>i.jsxs("tr",{children:[i.jsx("td",{children:i.jsx("code",{children:m.server})}),i.jsx("td",{children:m.callCount}),i.jsx("td",{children:m.methodCount}),i.jsx("td",{children:m.instanceCount}),i.jsx("td",{children:m.taskCount}),i.jsx("td",{children:m.errorCount||i.jsx("span",{className:"muted",children:"—"})}),i.jsx("td",{children:i.jsx(lt,{ms:m.lastActive})})]},m.server))})]})}):i.jsx("div",{className:"loading",children:"Loading…"})}function Ug(){const[s,d]=H.useState(null),[o,f]=H.useState(null);return H.useEffect(()=>{let m=!1;return dy().then(g=>!m&&d(g)).catch(g=>!m&&f(g.message)),()=>{m=!0}},[]),o&&!s?i.jsxs("div",{className:"error",children:["Error: ",o]}):s?s.length===0?i.jsxs("div",{className:"empty",children:[i.jsx("p",{children:"No skills used yet."}),i.jsxs("p",{className:"hint",children:["Populated from new traffic. When an agent invokes a skill (the ",i.jsx("code",{children:"Skill"})," tool), it shows up here aggregated across instances."]})]}):i.jsx("div",{className:"run-list-wrap",children:i.jsxs("table",{className:"runs",children:[i.jsx("thead",{children:i.jsxs("tr",{children:[i.jsx("th",{children:"Skill"}),i.jsx("th",{children:"Uses"}),i.jsx("th",{children:"Instances"}),i.jsx("th",{children:"Tasks"}),i.jsx("th",{children:"Last used"})]})}),i.jsx("tbody",{children:s.map(m=>i.jsxs("tr",{children:[i.jsx("td",{children:i.jsx("code",{children:m.skill})}),i.jsx("td",{children:m.useCount}),i.jsx("td",{children:m.instanceCount}),i.jsx("td",{children:m.taskCount}),i.jsx("td",{children:i.jsx(lt,{ms:m.lastActive})})]},m.skill))})]})}):i.jsx("div",{className:"loading",children:"Loading…"})}const Dg=[{key:"agents",label:"Agents"},{key:"mcp",label:"MCP"},{key:"skills",label:"Skills"},{key:"tasks",label:"Tasks"}];function Rg(s){return/^#\/see\/(agents|mcp|skills|tasks)/.exec(s)?.[1]??"agents"}function Hg({hash:s}){const d=Rg(s);return i.jsxs("div",{className:"routing",children:[i.jsx("div",{className:"subtabs",children:Dg.map(o=>i.jsx("button",{type:"button",className:`subtab ${d===o.key?"active":""}`,onClick:()=>{window.location.hash=`#/see/${o.key}`},children:o.label},o.key))}),d==="agents"?i.jsx(Cg,{}):d==="mcp"?i.jsx(Og,{}):d==="skills"?i.jsx(Ug,{}):i.jsx(Mg,{})]})}function kg({taskId:s}){const[d,o]=H.useState(null),[f,m]=H.useState(null);if(H.useEffect(()=>{let E=!1;return uy(s).then(T=>{E||o(T)}).catch(T=>{E||m(T.message)}),()=>{E=!0}},[s]),f)return i.jsxs("div",{className:"error",children:["Error: ",f]});if(!d)return i.jsx("div",{className:"loading",children:"Loading…"});const{thread:g,runs:j}=d;return i.jsxs("div",{className:"task-detail",children:[i.jsx("div",{className:"detail-back",children:i.jsx("a",{href:"#/tasks",children:"← Tasks"})}),i.jsx("h1",{className:"task-detail-title",children:g.title??i.jsx("code",{children:Ua(g.id)})}),i.jsxs("div",{className:"task-meta",children:[i.jsx("span",{children:g.agent}),i.jsx("span",{children:i.jsx(lt,{ms:g.startedAt})}),i.jsx("span",{children:i.jsx(Mn,{ms:g.durMs})}),i.jsxs("span",{children:[g.runCount," run",g.runCount===1?"":"s"," · ",g.actionCount," actions"]}),i.jsxs("span",{children:["model: ",g.model?i.jsx("code",{children:g.model}):i.jsx("span",{className:"muted",children:"—"})]}),i.jsx(tu,{outcome:g.outcome})]}),i.jsxs("section",{className:"home-section",children:[i.jsx("h2",{children:"Runs in this task"}),j.length===0?i.jsx("div",{className:"empty",children:i.jsx("p",{children:"No runs captured for this task."})}):i.jsxs("table",{className:"runs",children:[i.jsx("thead",{children:i.jsxs("tr",{children:[i.jsx("th",{children:"Run"}),i.jsx("th",{children:"Started"}),i.jsx("th",{children:"Model"}),i.jsx("th",{children:"Status"}),i.jsx("th",{children:"Actions"}),i.jsx("th",{children:"Dur"}),i.jsx("th",{children:"In/Out"}),i.jsx("th",{children:"Cache R/W"})]})}),i.jsx("tbody",{children:j.map(E=>i.jsxs("tr",{className:qs(E.outcome),onClick:()=>{window.location.hash=`#/run/${encodeURIComponent(E.id)}`},children:[i.jsx("td",{children:i.jsx("code",{children:Ua(E.id)})}),i.jsx("td",{children:i.jsx(lt,{ms:E.startedAt})}),i.jsx("td",{children:E.model?i.jsx("code",{children:E.model}):i.jsx("span",{className:"muted",children:"—"})}),i.jsx("td",{children:E.outcome!=="ok"?i.jsx(tu,{outcome:E.outcome}):E.status}),i.jsx("td",{children:E.actionCount}),i.jsx("td",{children:i.jsx(Mn,{ms:E.durMs})}),i.jsx("td",{children:i.jsx(ph,{tokensIn:E.tokensIn,tokensOut:E.tokensOut})}),i.jsx("td",{children:i.jsx(Ds,{read:E.cacheReadTokens,write:E.cacheWriteTokens})})]},E.id))})]})]})]})}function Ms({title:s,rows:d,empty:o}){return i.jsxs("section",{className:"home-section instance-panel",children:[i.jsx("h3",{children:s}),d.length===0?i.jsx("p",{className:"hint",children:o}):i.jsx("ul",{className:"usage-list",children:d.map(f=>i.jsxs("li",{children:[i.jsx("code",{children:f.name}),f.category&&f.category!=="builtin"?i.jsx("span",{className:"usage-cat",children:f.category}):null,i.jsx("span",{className:"usage-count",children:f.count})]},f.name))})]})}function qg({instanceKey:s}){const[d,o]=H.useState(null),[f,m]=H.useState(null);return H.useEffect(()=>{let g=!1;return sy(s).then(j=>!g&&o(j)).catch(j=>!g&&m(j.message)),()=>{g=!0}},[s]),f?i.jsxs("div",{className:"error",children:["Error: ",f]}):d?i.jsxs("div",{children:[i.jsx("div",{className:"detail-back",children:i.jsx("a",{href:"#/see/agents",children:"← Agents"})}),i.jsxs("h2",{className:"task-detail-title",children:[d.agent,d.instanceId?i.jsxs(i.Fragment,{children:[" ",i.jsx("code",{children:d.instanceId})]}):i.jsx("span",{className:"muted",children:" (unknown instance)"})]}),i.jsxs("div",{className:"instance-panels",children:[i.jsx(Ms,{title:"MCP servers",rows:d.mcpServers,empty:"No MCP calls."}),i.jsx(Ms,{title:"Skills",rows:d.skills,empty:"No skills used."}),i.jsx(Ms,{title:"Tools",rows:d.tools,empty:"No tool calls."})]}),i.jsxs("section",{className:"home-section",children:[i.jsx("h3",{children:"Tasks"}),d.tasks.length===0?i.jsx("p",{className:"hint",children:"No tasks recorded for this instance."}):i.jsx("div",{className:"run-list-wrap",children:i.jsxs("table",{className:"runs",children:[i.jsx("thead",{children:i.jsxs("tr",{children:[i.jsx("th",{children:"Task"}),i.jsx("th",{children:"Started"}),i.jsx("th",{children:"Model"}),i.jsx("th",{children:"Status"}),i.jsx("th",{children:"Runs"}),i.jsx("th",{children:"Dur"})]})}),i.jsx("tbody",{children:d.tasks.map(g=>i.jsxs("tr",{className:qs(g.outcome),onClick:()=>{window.location.hash=`#/task/${encodeURIComponent(g.id)}`},children:[i.jsx("td",{children:g.title?i.jsx("span",{className:"task-title",children:g.title}):i.jsx("code",{children:Ua(g.id)})}),i.jsx("td",{children:i.jsx(lt,{ms:g.startedAt})}),i.jsx("td",{children:g.model?i.jsx("code",{children:g.model}):i.jsx("span",{className:"muted",children:"—"})}),i.jsx("td",{children:g.outcome!=="ok"?i.jsx(tu,{outcome:g.outcome}):g.endedAt==null?i.jsx("span",{className:"muted",children:"running"}):"done"}),i.jsx("td",{children:g.runCount}),i.jsx("td",{children:i.jsx(Mn,{ms:g.durMs})})]},g.id))})]})})]})]}):i.jsx("div",{className:"loading",children:"Loading…"})}function Bg(){const[s,d]=H.useState(window.location.hash);H.useEffect(()=>{const j=()=>d(window.location.hash);return window.addEventListener("hashchange",j),()=>window.removeEventListener("hashchange",j)},[]);const o=/^#\/run\/(.+)$/.exec(s)?.[1],f=/^#\/task\/(.+)$/.exec(s)?.[1],m=/^#\/instance\/(.+)$/.exec(s)?.[1],g=o||f||m||/^#\/(see|tasks)/.test(s)?"see":/^#\/routing/.test(s)?"routing":/^#\/keys/.test(s)?"keys":/^#\/guard/.test(s)?"guard":"home";return i.jsxs("div",{className:"app",children:[i.jsx(Uy,{active:g}),i.jsx("main",{children:o?i.jsx(vg,{runId:decodeURIComponent(o)}):f?i.jsx(kg,{taskId:decodeURIComponent(f)}):m?i.jsx(qg,{instanceKey:m}):g==="see"?i.jsx(Hg,{hash:s}):g==="routing"?i.jsx(ug,{}):g==="keys"?i.jsx(Ly,{}):g==="guard"?i.jsx(ky,{}):i.jsx(By,{})})]})}const Th=document.getElementById("root");if(!Th)throw new Error("#root element not found");ny.createRoot(Th).render(i.jsx(H.StrictMode,{children:i.jsx(Bg,{})}));
|