leglas 0.4.0 → 0.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,14 @@
1
+ (function(){const r=document.createElement("link").relList;if(r&&r.supports&&r.supports("modulepreload"))return;for(const d of document.querySelectorAll('link[rel="modulepreload"]'))f(d);new MutationObserver(d=>{for(const y of d)if(y.type==="childList")for(const E of y.addedNodes)E.tagName==="LINK"&&E.rel==="modulepreload"&&f(E)}).observe(document,{childList:!0,subtree:!0});function m(d){const y={};return d.integrity&&(y.integrity=d.integrity),d.referrerPolicy&&(y.referrerPolicy=d.referrerPolicy),d.crossOrigin==="use-credentials"?y.credentials="include":d.crossOrigin==="anonymous"?y.credentials="omit":y.credentials="same-origin",y}function f(d){if(d.ep)return;d.ep=!0;const y=m(d);fetch(d.href,y)}})();var io={exports:{}},Ru={};var i0;function kh(){if(i0)return Ru;i0=1;var c=Symbol.for("react.transitional.element"),r=Symbol.for("react.fragment");function m(f,d,y){var E=null;if(y!==void 0&&(E=""+y),d.key!==void 0&&(E=""+d.key),"key"in d){y={};for(var A in d)A!=="key"&&(y[A]=d[A])}else y=d;return d=y.ref,{$$typeof:c,type:f,key:E,ref:d!==void 0?d:null,props:y}}return Ru.Fragment=r,Ru.jsx=m,Ru.jsxs=m,Ru}var c0;function Qh(){return c0||(c0=1,io.exports=kh()),io.exports}var s=Qh(),co={exports:{}},vt={};var s0;function Zh(){if(s0)return vt;s0=1;var c=Symbol.for("react.transitional.element"),r=Symbol.for("react.portal"),m=Symbol.for("react.fragment"),f=Symbol.for("react.strict_mode"),d=Symbol.for("react.profiler"),y=Symbol.for("react.consumer"),E=Symbol.for("react.context"),A=Symbol.for("react.forward_ref"),D=Symbol.for("react.suspense"),x=Symbol.for("react.memo"),L=Symbol.for("react.lazy"),H=Symbol.for("react.activity"),G=Symbol.iterator;function Y(v){return v===null||typeof v!="object"?null:(v=G&&v[G]||v["@@iterator"],typeof v=="function"?v:null)}var X={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},F=Object.assign,dt={};function g(v,N,k){this.props=v,this.context=N,this.refs=dt,this.updater=k||X}g.prototype.isReactComponent={},g.prototype.setState=function(v,N){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,N,"setState")},g.prototype.forceUpdate=function(v){this.updater.enqueueForceUpdate(this,v,"forceUpdate")};function Q(){}Q.prototype=g.prototype;function I(v,N,k){this.props=v,this.context=N,this.refs=dt,this.updater=k||X}var et=I.prototype=new Q;et.constructor=I,F(et,g.prototype),et.isPureReactComponent=!0;var lt=Array.isArray;function P(){}var J={H:null,A:null,T:null,S:null},nt=Object.prototype.hasOwnProperty;function it(v,N,k){var V=k.ref;return{$$typeof:c,type:v,key:N,ref:V!==void 0?V:null,props:k}}function ut(v,N){return it(v.type,N,v.props)}function xt(v){return typeof v=="object"&&v!==null&&v.$$typeof===c}function gt(v){var N={"=":"=0",":":"=2"};return"$"+v.replace(/[=:]/g,function(k){return N[k]})}var Ht=/\/+/g;function pt(v,N){return typeof v=="object"&&v!==null&&v.key!=null?gt(""+v.key):N.toString(36)}function $t(v){switch(v.status){case"fulfilled":return v.value;case"rejected":throw v.reason;default:switch(typeof v.status=="string"?v.then(P,P):(v.status="pending",v.then(function(N){v.status==="pending"&&(v.status="fulfilled",v.value=N)},function(N){v.status==="pending"&&(v.status="rejected",v.reason=N)})),v.status){case"fulfilled":return v.value;case"rejected":throw v.reason}}throw v}function z(v,N,k,V,ot){var ft=typeof v;(ft==="undefined"||ft==="boolean")&&(v=null);var Tt=!1;if(v===null)Tt=!0;else switch(ft){case"bigint":case"string":case"number":Tt=!0;break;case"object":switch(v.$$typeof){case c:case r:Tt=!0;break;case L:return Tt=v._init,z(Tt(v._payload),N,k,V,ot)}}if(Tt)return ot=ot(v),Tt=V===""?"."+pt(v,0):V,lt(ot)?(k="",Tt!=null&&(k=Tt.replace(Ht,"$&/")+"/"),z(ot,N,k,"",function(Oe){return Oe})):ot!=null&&(xt(ot)&&(ot=ut(ot,k+(ot.key==null||v&&v.key===ot.key?"":(""+ot.key).replace(Ht,"$&/")+"/")+Tt)),N.push(ot)),1;Tt=0;var Vt=V===""?".":V+":";if(lt(v))for(var wt=0;wt<v.length;wt++)V=v[wt],ft=Vt+pt(V,wt),Tt+=z(V,N,k,ft,ot);else if(wt=Y(v),typeof wt=="function")for(v=wt.call(v),wt=0;!(V=v.next()).done;)V=V.value,ft=Vt+pt(V,wt++),Tt+=z(V,N,k,ft,ot);else if(ft==="object"){if(typeof v.then=="function")return z($t(v),N,k,V,ot);throw N=String(v),Error("Objects are not valid as a React child (found: "+(N==="[object Object]"?"object with keys {"+Object.keys(v).join(", ")+"}":N)+"). If you meant to render a collection of children, use an array instead.")}return Tt}function q(v,N,k){if(v==null)return v;var V=[],ot=0;return z(v,V,"","",function(ft){return N.call(k,ft,ot++)}),V}function $(v){if(v._status===-1){var N=v._result;N=N(),N.then(function(k){(v._status===0||v._status===-1)&&(v._status=1,v._result=k)},function(k){(v._status===0||v._status===-1)&&(v._status=2,v._result=k)}),v._status===-1&&(v._status=0,v._result=N)}if(v._status===1)return v._result.default;throw v._result}var yt=typeof reportError=="function"?reportError:function(v){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var N=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(N))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",v);return}console.error(v)},Mt={map:q,forEach:function(v,N,k){q(v,function(){N.apply(this,arguments)},k)},count:function(v){var N=0;return q(v,function(){N++}),N},toArray:function(v){return q(v,function(N){return N})||[]},only:function(v){if(!xt(v))throw Error("React.Children.only expected to receive a single React element child.");return v}};return vt.Activity=H,vt.Children=Mt,vt.Component=g,vt.Fragment=m,vt.Profiler=d,vt.PureComponent=I,vt.StrictMode=f,vt.Suspense=D,vt.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=J,vt.__COMPILER_RUNTIME={__proto__:null,c:function(v){return J.H.useMemoCache(v)}},vt.cache=function(v){return function(){return v.apply(null,arguments)}},vt.cacheSignal=function(){return null},vt.cloneElement=function(v,N,k){if(v==null)throw Error("The argument must be a React element, but you passed "+v+".");var V=F({},v.props),ot=v.key;if(N!=null)for(ft in N.key!==void 0&&(ot=""+N.key),N)!nt.call(N,ft)||ft==="key"||ft==="__self"||ft==="__source"||ft==="ref"&&N.ref===void 0||(V[ft]=N[ft]);var ft=arguments.length-2;if(ft===1)V.children=k;else if(1<ft){for(var Tt=Array(ft),Vt=0;Vt<ft;Vt++)Tt[Vt]=arguments[Vt+2];V.children=Tt}return it(v.type,ot,V)},vt.createContext=function(v){return v={$$typeof:E,_currentValue:v,_currentValue2:v,_threadCount:0,Provider:null,Consumer:null},v.Provider=v,v.Consumer={$$typeof:y,_context:v},v},vt.createElement=function(v,N,k){var V,ot={},ft=null;if(N!=null)for(V in N.key!==void 0&&(ft=""+N.key),N)nt.call(N,V)&&V!=="key"&&V!=="__self"&&V!=="__source"&&(ot[V]=N[V]);var Tt=arguments.length-2;if(Tt===1)ot.children=k;else if(1<Tt){for(var Vt=Array(Tt),wt=0;wt<Tt;wt++)Vt[wt]=arguments[wt+2];ot.children=Vt}if(v&&v.defaultProps)for(V in Tt=v.defaultProps,Tt)ot[V]===void 0&&(ot[V]=Tt[V]);return it(v,ft,ot)},vt.createRef=function(){return{current:null}},vt.forwardRef=function(v){return{$$typeof:A,render:v}},vt.isValidElement=xt,vt.lazy=function(v){return{$$typeof:L,_payload:{_status:-1,_result:v},_init:$}},vt.memo=function(v,N){return{$$typeof:x,type:v,compare:N===void 0?null:N}},vt.startTransition=function(v){var N=J.T,k={};J.T=k;try{var V=v(),ot=J.S;ot!==null&&ot(k,V),typeof V=="object"&&V!==null&&typeof V.then=="function"&&V.then(P,yt)}catch(ft){yt(ft)}finally{N!==null&&k.types!==null&&(N.types=k.types),J.T=N}},vt.unstable_useCacheRefresh=function(){return J.H.useCacheRefresh()},vt.use=function(v){return J.H.use(v)},vt.useActionState=function(v,N,k){return J.H.useActionState(v,N,k)},vt.useCallback=function(v,N){return J.H.useCallback(v,N)},vt.useContext=function(v){return J.H.useContext(v)},vt.useDebugValue=function(){},vt.useDeferredValue=function(v,N){return J.H.useDeferredValue(v,N)},vt.useEffect=function(v,N){return J.H.useEffect(v,N)},vt.useEffectEvent=function(v){return J.H.useEffectEvent(v)},vt.useId=function(){return J.H.useId()},vt.useImperativeHandle=function(v,N,k){return J.H.useImperativeHandle(v,N,k)},vt.useInsertionEffect=function(v,N){return J.H.useInsertionEffect(v,N)},vt.useLayoutEffect=function(v,N){return J.H.useLayoutEffect(v,N)},vt.useMemo=function(v,N){return J.H.useMemo(v,N)},vt.useOptimistic=function(v,N){return J.H.useOptimistic(v,N)},vt.useReducer=function(v,N,k){return J.H.useReducer(v,N,k)},vt.useRef=function(v){return J.H.useRef(v)},vt.useState=function(v){return J.H.useState(v)},vt.useSyncExternalStore=function(v,N,k){return J.H.useSyncExternalStore(v,N,k)},vt.useTransition=function(){return J.H.useTransition()},vt.version="19.2.8",vt}var o0;function Ao(){return o0||(o0=1,co.exports=Zh()),co.exports}var R=Ao(),so={exports:{}},Uu={},oo={exports:{}},fo={};var f0;function Vh(){return f0||(f0=1,(function(c){function r(z,q){var $=z.length;z.push(q);t:for(;0<$;){var yt=$-1>>>1,Mt=z[yt];if(0<d(Mt,q))z[yt]=q,z[$]=Mt,$=yt;else break t}}function m(z){return z.length===0?null:z[0]}function f(z){if(z.length===0)return null;var q=z[0],$=z.pop();if($!==q){z[0]=$;t:for(var yt=0,Mt=z.length,v=Mt>>>1;yt<v;){var N=2*(yt+1)-1,k=z[N],V=N+1,ot=z[V];if(0>d(k,$))V<Mt&&0>d(ot,k)?(z[yt]=ot,z[V]=$,yt=V):(z[yt]=k,z[N]=$,yt=N);else if(V<Mt&&0>d(ot,$))z[yt]=ot,z[V]=$,yt=V;else break t}}return q}function d(z,q){var $=z.sortIndex-q.sortIndex;return $!==0?$:z.id-q.id}if(c.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var y=performance;c.unstable_now=function(){return y.now()}}else{var E=Date,A=E.now();c.unstable_now=function(){return E.now()-A}}var D=[],x=[],L=1,H=null,G=3,Y=!1,X=!1,F=!1,dt=!1,g=typeof setTimeout=="function"?setTimeout:null,Q=typeof clearTimeout=="function"?clearTimeout:null,I=typeof setImmediate<"u"?setImmediate:null;function et(z){for(var q=m(x);q!==null;){if(q.callback===null)f(x);else if(q.startTime<=z)f(x),q.sortIndex=q.expirationTime,r(D,q);else break;q=m(x)}}function lt(z){if(F=!1,et(z),!X)if(m(D)!==null)X=!0,P||(P=!0,gt());else{var q=m(x);q!==null&&$t(lt,q.startTime-z)}}var P=!1,J=-1,nt=5,it=-1;function ut(){return dt?!0:!(c.unstable_now()-it<nt)}function xt(){if(dt=!1,P){var z=c.unstable_now();it=z;var q=!0;try{t:{X=!1,F&&(F=!1,Q(J),J=-1),Y=!0;var $=G;try{e:{for(et(z),H=m(D);H!==null&&!(H.expirationTime>z&&ut());){var yt=H.callback;if(typeof yt=="function"){H.callback=null,G=H.priorityLevel;var Mt=yt(H.expirationTime<=z);if(z=c.unstable_now(),typeof Mt=="function"){H.callback=Mt,et(z),q=!0;break e}H===m(D)&&f(D),et(z)}else f(D);H=m(D)}if(H!==null)q=!0;else{var v=m(x);v!==null&&$t(lt,v.startTime-z),q=!1}}break t}finally{H=null,G=$,Y=!1}q=void 0}}finally{q?gt():P=!1}}}var gt;if(typeof I=="function")gt=function(){I(xt)};else if(typeof MessageChannel<"u"){var Ht=new MessageChannel,pt=Ht.port2;Ht.port1.onmessage=xt,gt=function(){pt.postMessage(null)}}else gt=function(){g(xt,0)};function $t(z,q){J=g(function(){z(c.unstable_now())},q)}c.unstable_IdlePriority=5,c.unstable_ImmediatePriority=1,c.unstable_LowPriority=4,c.unstable_NormalPriority=3,c.unstable_Profiling=null,c.unstable_UserBlockingPriority=2,c.unstable_cancelCallback=function(z){z.callback=null},c.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"):nt=0<z?Math.floor(1e3/z):5},c.unstable_getCurrentPriorityLevel=function(){return G},c.unstable_next=function(z){switch(G){case 1:case 2:case 3:var q=3;break;default:q=G}var $=G;G=q;try{return z()}finally{G=$}},c.unstable_requestPaint=function(){dt=!0},c.unstable_runWithPriority=function(z,q){switch(z){case 1:case 2:case 3:case 4:case 5:break;default:z=3}var $=G;G=z;try{return q()}finally{G=$}},c.unstable_scheduleCallback=function(z,q,$){var yt=c.unstable_now();switch(typeof $=="object"&&$!==null?($=$.delay,$=typeof $=="number"&&0<$?yt+$:yt):$=yt,z){case 1:var Mt=-1;break;case 2:Mt=250;break;case 5:Mt=1073741823;break;case 4:Mt=1e4;break;default:Mt=5e3}return Mt=$+Mt,z={id:L++,callback:q,priorityLevel:z,startTime:$,expirationTime:Mt,sortIndex:-1},$>yt?(z.sortIndex=$,r(x,z),m(D)===null&&z===m(x)&&(F?(Q(J),J=-1):F=!0,$t(lt,$-yt))):(z.sortIndex=Mt,r(D,z),X||Y||(X=!0,P||(P=!0,gt()))),z},c.unstable_shouldYield=ut,c.unstable_wrapCallback=function(z){var q=G;return function(){var $=G;G=q;try{return z.apply(this,arguments)}finally{G=$}}}})(fo)),fo}var r0;function Kh(){return r0||(r0=1,oo.exports=Vh()),oo.exports}var ro={exports:{}},De={};var d0;function Jh(){if(d0)return De;d0=1;var c=Ao();function r(D){var x="https://react.dev/errors/"+D;if(1<arguments.length){x+="?args[]="+encodeURIComponent(arguments[1]);for(var L=2;L<arguments.length;L++)x+="&args[]="+encodeURIComponent(arguments[L])}return"Minified React error #"+D+"; visit "+x+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function m(){}var f={d:{f:m,r:function(){throw Error(r(522))},D:m,C:m,L:m,m,X:m,S:m,M:m},p:0,findDOMNode:null},d=Symbol.for("react.portal");function y(D,x,L){var H=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:d,key:H==null?null:""+H,children:D,containerInfo:x,implementation:L}}var E=c.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function A(D,x){if(D==="font")return"";if(typeof x=="string")return x==="use-credentials"?x:""}return De.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=f,De.createPortal=function(D,x){var L=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!x||x.nodeType!==1&&x.nodeType!==9&&x.nodeType!==11)throw Error(r(299));return y(D,x,null,L)},De.flushSync=function(D){var x=E.T,L=f.p;try{if(E.T=null,f.p=2,D)return D()}finally{E.T=x,f.p=L,f.d.f()}},De.preconnect=function(D,x){typeof D=="string"&&(x?(x=x.crossOrigin,x=typeof x=="string"?x==="use-credentials"?x:"":void 0):x=null,f.d.C(D,x))},De.prefetchDNS=function(D){typeof D=="string"&&f.d.D(D)},De.preinit=function(D,x){if(typeof D=="string"&&x&&typeof x.as=="string"){var L=x.as,H=A(L,x.crossOrigin),G=typeof x.integrity=="string"?x.integrity:void 0,Y=typeof x.fetchPriority=="string"?x.fetchPriority:void 0;L==="style"?f.d.S(D,typeof x.precedence=="string"?x.precedence:void 0,{crossOrigin:H,integrity:G,fetchPriority:Y}):L==="script"&&f.d.X(D,{crossOrigin:H,integrity:G,fetchPriority:Y,nonce:typeof x.nonce=="string"?x.nonce:void 0})}},De.preinitModule=function(D,x){if(typeof D=="string")if(typeof x=="object"&&x!==null){if(x.as==null||x.as==="script"){var L=A(x.as,x.crossOrigin);f.d.M(D,{crossOrigin:L,integrity:typeof x.integrity=="string"?x.integrity:void 0,nonce:typeof x.nonce=="string"?x.nonce:void 0})}}else x==null&&f.d.M(D)},De.preload=function(D,x){if(typeof D=="string"&&typeof x=="object"&&x!==null&&typeof x.as=="string"){var L=x.as,H=A(L,x.crossOrigin);f.d.L(D,L,{crossOrigin:H,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})}},De.preloadModule=function(D,x){if(typeof D=="string")if(x){var L=A(x.as,x.crossOrigin);f.d.m(D,{as:typeof x.as=="string"&&x.as!=="script"?x.as:void 0,crossOrigin:L,integrity:typeof x.integrity=="string"?x.integrity:void 0})}else f.d.m(D)},De.requestFormReset=function(D){f.d.r(D)},De.unstable_batchedUpdates=function(D,x){return D(x)},De.useFormState=function(D,x,L){return E.H.useFormState(D,x,L)},De.useFormStatus=function(){return E.H.useHostTransitionStatus()},De.version="19.2.8",De}var h0;function $h(){if(h0)return ro.exports;h0=1;function c(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(c)}catch(r){console.error(r)}}return c(),ro.exports=Jh(),ro.exports}var m0;function Wh(){if(m0)return Uu;m0=1;var c=Kh(),r=Ao(),m=$h();function f(t){var e="https://react.dev/errors/"+t;if(1<arguments.length){e+="?args[]="+encodeURIComponent(arguments[1]);for(var l=2;l<arguments.length;l++)e+="&args[]="+encodeURIComponent(arguments[l])}return"Minified React error #"+t+"; visit "+e+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function d(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)}function y(t){var e=t,l=t;if(t.alternate)for(;e.return;)e=e.return;else{t=e;do e=t,(e.flags&4098)!==0&&(l=e.return),t=e.return;while(t)}return e.tag===3?l:null}function E(t){if(t.tag===13){var e=t.memoizedState;if(e===null&&(t=t.alternate,t!==null&&(e=t.memoizedState)),e!==null)return e.dehydrated}return null}function A(t){if(t.tag===31){var e=t.memoizedState;if(e===null&&(t=t.alternate,t!==null&&(e=t.memoizedState)),e!==null)return e.dehydrated}return null}function D(t){if(y(t)!==t)throw Error(f(188))}function x(t){var e=t.alternate;if(!e){if(e=y(t),e===null)throw Error(f(188));return e!==t?null:t}for(var l=t,n=e;;){var a=l.return;if(a===null)break;var u=a.alternate;if(u===null){if(n=a.return,n!==null){l=n;continue}break}if(a.child===u.child){for(u=a.child;u;){if(u===l)return D(a),t;if(u===n)return D(a),e;u=u.sibling}throw Error(f(188))}if(l.return!==n.return)l=a,n=u;else{for(var i=!1,o=a.child;o;){if(o===l){i=!0,l=a,n=u;break}if(o===n){i=!0,n=a,l=u;break}o=o.sibling}if(!i){for(o=u.child;o;){if(o===l){i=!0,l=u,n=a;break}if(o===n){i=!0,n=u,l=a;break}o=o.sibling}if(!i)throw Error(f(189))}}if(l.alternate!==n)throw Error(f(190))}if(l.tag!==3)throw Error(f(188));return l.stateNode.current===l?t:e}function L(t){var e=t.tag;if(e===5||e===26||e===27||e===6)return t;for(t=t.child;t!==null;){if(e=L(t),e!==null)return e;t=t.sibling}return null}var H=Object.assign,G=Symbol.for("react.element"),Y=Symbol.for("react.transitional.element"),X=Symbol.for("react.portal"),F=Symbol.for("react.fragment"),dt=Symbol.for("react.strict_mode"),g=Symbol.for("react.profiler"),Q=Symbol.for("react.consumer"),I=Symbol.for("react.context"),et=Symbol.for("react.forward_ref"),lt=Symbol.for("react.suspense"),P=Symbol.for("react.suspense_list"),J=Symbol.for("react.memo"),nt=Symbol.for("react.lazy"),it=Symbol.for("react.activity"),ut=Symbol.for("react.memo_cache_sentinel"),xt=Symbol.iterator;function gt(t){return t===null||typeof t!="object"?null:(t=xt&&t[xt]||t["@@iterator"],typeof t=="function"?t:null)}var Ht=Symbol.for("react.client.reference");function pt(t){if(t==null)return null;if(typeof t=="function")return t.$$typeof===Ht?null:t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case F:return"Fragment";case g:return"Profiler";case dt:return"StrictMode";case lt:return"Suspense";case P:return"SuspenseList";case it:return"Activity"}if(typeof t=="object")switch(t.$$typeof){case X:return"Portal";case I:return t.displayName||"Context";case Q:return(t._context.displayName||"Context")+".Consumer";case et:var e=t.render;return t=t.displayName,t||(t=e.displayName||e.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case J:return e=t.displayName||null,e!==null?e:pt(t.type)||"Memo";case nt:e=t._payload,t=t._init;try{return pt(t(e))}catch{}}return null}var $t=Array.isArray,z=r.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,q=m.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,$={pending:!1,data:null,method:null,action:null},yt=[],Mt=-1;function v(t){return{current:t}}function N(t){0>Mt||(t.current=yt[Mt],yt[Mt]=null,Mt--)}function k(t,e){Mt++,yt[Mt]=t.current,t.current=e}var V=v(null),ot=v(null),ft=v(null),Tt=v(null);function Vt(t,e){switch(k(ft,e),k(ot,t),k(V,null),e.nodeType){case 9:case 11:t=(t=e.documentElement)&&(t=t.namespaceURI)?jd(t):0;break;default:if(t=e.tagName,e=e.namespaceURI)e=jd(e),t=Nd(e,t);else switch(t){case"svg":t=1;break;case"math":t=2;break;default:t=0}}N(V),k(V,t)}function wt(){N(V),N(ot),N(ft)}function Oe(t){t.memoizedState!==null&&k(Tt,t);var e=V.current,l=Nd(e,t.type);e!==l&&(k(ot,t),k(V,l))}function xl(t){ot.current===t&&(N(V),N(ot)),Tt.current===t&&(N(Tt),Nu._currentValue=$)}var fl,rl;function Kt(t){if(fl===void 0)try{throw Error()}catch(l){var e=l.stack.trim().match(/\n( *(at )?)/);fl=e&&e[1]||"",rl=-1<l.stack.indexOf(`
2
+ at`)?" (<anonymous>)":-1<l.stack.indexOf("@")?"@unknown:0:0":""}return`
3
+ `+fl+t+rl}var We=!1;function Ol(t,e){if(!t||We)return"";We=!0;var l=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var n={DetermineComponentFrameRoot:function(){try{if(e){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(j){var T=j}Reflect.construct(t,[],U)}else{try{U.call()}catch(j){T=j}t.call(U.prototype)}}else{try{throw Error()}catch(j){T=j}(U=t())&&typeof U.catch=="function"&&U.catch(function(){})}}catch(j){if(j&&T&&typeof j.stack=="string")return[j.stack,T.stack]}return[null,null]}};n.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var a=Object.getOwnPropertyDescriptor(n.DetermineComponentFrameRoot,"name");a&&a.configurable&&Object.defineProperty(n.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var u=n.DetermineComponentFrameRoot(),i=u[0],o=u[1];if(i&&o){var p=i.split(`
4
+ `),C=o.split(`
5
+ `);for(a=n=0;n<p.length&&!p[n].includes("DetermineComponentFrameRoot");)n++;for(;a<C.length&&!C[a].includes("DetermineComponentFrameRoot");)a++;if(n===p.length||a===C.length)for(n=p.length-1,a=C.length-1;1<=n&&0<=a&&p[n]!==C[a];)a--;for(;1<=n&&0<=a;n--,a--)if(p[n]!==C[a]){if(n!==1||a!==1)do if(n--,a--,0>a||p[n]!==C[a]){var w=`
6
+ `+p[n].replace(" at new "," at ");return t.displayName&&w.includes("<anonymous>")&&(w=w.replace("<anonymous>",t.displayName)),w}while(1<=n&&0<=a);break}}}finally{We=!1,Error.prepareStackTrace=l}return(l=t?t.displayName||t.name:"")?Kt(l):""}function _l(t,e){switch(t.tag){case 26:case 27:case 5:return Kt(t.type);case 16:return Kt("Lazy");case 13:return t.child!==e&&e!==null?Kt("Suspense Fallback"):Kt("Suspense");case 19:return Kt("SuspenseList");case 0:case 15:return Ol(t.type,!1);case 11:return Ol(t.type.render,!1);case 1:return Ol(t.type,!0);case 31:return Kt("Activity");default:return""}}function je(t){try{var e="",l=null;do e+=_l(t,l),l=t,t=t.return;while(t);return e}catch(n){return`
7
+ Error generating stack: `+n.message+`
8
+ `+n.stack}}var dl=Object.prototype.hasOwnProperty,Sl=c.unstable_scheduleCallback,Pl=c.unstable_cancelCallback,Fe=c.unstable_shouldYield,la=c.unstable_requestPaint,ye=c.unstable_now,El=c.unstable_getCurrentPriorityLevel,tn=c.unstable_ImmediatePriority,wn=c.unstable_UserBlockingPriority,Ml=c.unstable_NormalPriority,en=c.unstable_LowPriority,ln=c.unstable_IdlePriority,na=c.log,On=c.unstable_setDisableYieldValue,ve=null,ie=null;function le(t){if(typeof na=="function"&&On(t),ie&&typeof ie.setStrictMode=="function")try{ie.setStrictMode(ve,t)}catch{}}var xe=Math.clz32?Math.clz32:O,aa=Math.log,ua=Math.LN2;function O(t){return t>>>=0,t===0?32:31-(aa(t)/ua|0)|0}var K=256,St=262144,ht=4194304;function mt(t){var e=t&42;if(e!==0)return e;switch(t&-t){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 t&261888;case 262144:case 524288:case 1048576:case 2097152:return t&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return t&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return t}}function Wt(t,e,l){var n=t.pendingLanes;if(n===0)return 0;var a=0,u=t.suspendedLanes,i=t.pingedLanes;t=t.warmLanes;var o=n&134217727;return o!==0?(n=o&~u,n!==0?a=mt(n):(i&=o,i!==0?a=mt(i):l||(l=o&~t,l!==0&&(a=mt(l))))):(o=n&~u,o!==0?a=mt(o):i!==0?a=mt(i):l||(l=n&~t,l!==0&&(a=mt(l)))),a===0?0:e!==0&&e!==a&&(e&u)===0&&(u=a&-a,l=e&-e,u>=l||u===32&&(l&4194048)!==0)?e:a}function Gt(t,e){return(t.pendingLanes&~(t.suspendedLanes&~t.pingedLanes)&e)===0}function oe(t,e){switch(t){case 1:case 2:case 4:case 8:case 64:return e+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 e+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 Ee(){var t=ht;return ht<<=1,(ht&62914560)===0&&(ht=4194304),t}function Ga(t){for(var e=[],l=0;31>l;l++)e.push(t);return e}function _n(t,e){t.pendingLanes|=e,e!==268435456&&(t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0)}function Xe(t,e,l,n,a,u){var i=t.pendingLanes;t.pendingLanes=l,t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0,t.expiredLanes&=l,t.entangledLanes&=l,t.errorRecoveryDisabledLanes&=l,t.shellSuspendCounter=0;var o=t.entanglements,p=t.expirationTimes,C=t.hiddenUpdates;for(l=i&~l;0<l;){var w=31-xe(l),U=1<<w;o[w]=0,p[w]=-1;var T=C[w];if(T!==null)for(C[w]=null,w=0;w<T.length;w++){var j=T[w];j!==null&&(j.lane&=-536870913)}l&=~U}n!==0&&Xa(t,n,0),u!==0&&a===0&&t.tag!==0&&(t.suspendedLanes|=u&~(i&~e))}function Xa(t,e,l){t.pendingLanes|=e,t.suspendedLanes&=~e;var n=31-xe(e);t.entangledLanes|=e,t.entanglements[n]=t.entanglements[n]|1073741824|l&261930}function Cl(t,e){var l=t.entangledLanes|=e;for(t=t.entanglements;l;){var n=31-xe(l),a=1<<n;a&e|t[n]&e&&(t[n]|=e),l&=~a}}function qu(t,e){var l=e&-e;return l=(l&42)!==0?1:nn(l),(l&(t.suspendedLanes|e))!==0?0:l}function nn(t){switch(t){case 2:t=1;break;case 8:t=4;break;case 32:t=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:t=128;break;case 268435456:t=134217728;break;default:t=0}return t}function ka(t){return t&=-t,2<t?8<t?(t&134217727)!==0?32:268435456:8:2}function hl(){var t=q.p;return t!==0?t:(t=window.event,t===void 0?32:Pd(t.type))}function Lu(t,e){var l=q.p;try{return q.p=t,e()}finally{q.p=l}}var Al=Math.random().toString(36).slice(2),fe="__reactFiber$"+Al,ze="__reactProps$"+Al,ml="__reactContainer$"+Al,Jt="__reactEvents$"+Al,tc="__reactListeners$"+Al,qt="__reactHandles$"+Al,Rn="__reactResources$"+Al,Un="__reactMarker$"+Al;function ia(t){delete t[fe],delete t[ze],delete t[Jt],delete t[tc],delete t[qt]}function Tl(t){var e=t[fe];if(e)return e;for(var l=t.parentNode;l;){if(e=l[ml]||l[fe]){if(l=e.alternate,e.child!==null||l!==null&&l.child!==null)for(t=Bd(t);t!==null;){if(l=t[fe])return l;t=Bd(t)}return e}t=l,l=t.parentNode}return null}function an(t){if(t=t[fe]||t[ml]){var e=t.tag;if(e===5||e===6||e===13||e===31||e===26||e===27||e===3)return t}return null}function Hn(t){var e=t.tag;if(e===5||e===26||e===27||e===6)return t.stateNode;throw Error(f(33))}function Rl(t){var e=t[Rn];return e||(e=t[Rn]={hoistableStyles:new Map,hoistableScripts:new Map}),e}function re(t){t[Un]=!0}var Qa=new Set,ca={};function gl(t,e){Ie(t,e),Ie(t+"Capture",e)}function Ie(t,e){for(ca[t]=e,t=0;t<e.length;t++)Qa.add(e[t])}var un=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]*$"),Za={},Yu={};function zl(t){return dl.call(Yu,t)?!0:dl.call(Za,t)?!1:un.test(t)?Yu[t]=!0:(Za[t]=!0,!1)}function sa(t,e,l){if(zl(e))if(l===null)t.removeAttribute(e);else{switch(typeof l){case"undefined":case"function":case"symbol":t.removeAttribute(e);return;case"boolean":var n=e.toLowerCase().slice(0,5);if(n!=="data-"&&n!=="aria-"){t.removeAttribute(e);return}}t.setAttribute(e,""+l)}}function oa(t,e,l){if(l===null)t.removeAttribute(e);else{switch(typeof l){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(e);return}t.setAttribute(e,""+l)}}function pl(t,e,l,n){if(n===null)t.removeAttribute(l);else{switch(typeof n){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(l);return}t.setAttributeNS(e,l,""+n)}}function _e(t){switch(typeof t){case"bigint":case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function Gu(t){var e=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(e==="checkbox"||e==="radio")}function ec(t,e,l){var n=Object.getOwnPropertyDescriptor(t.constructor.prototype,e);if(!t.hasOwnProperty(e)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var a=n.get,u=n.set;return Object.defineProperty(t,e,{configurable:!0,get:function(){return a.call(this)},set:function(i){l=""+i,u.call(this,i)}}),Object.defineProperty(t,e,{enumerable:n.enumerable}),{getValue:function(){return l},setValue:function(i){l=""+i},stopTracking:function(){t._valueTracker=null,delete t[e]}}}}function Va(t){if(!t._valueTracker){var e=Gu(t)?"checked":"value";t._valueTracker=ec(t,e,""+t[e])}}function h(t){if(!t)return!1;var e=t._valueTracker;if(!e)return!0;var l=e.getValue(),n="";return t&&(n=Gu(t)?t.checked?"true":"false":t.value),t=n,t!==l?(e.setValue(t),!0):!1}function B(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}var Z=/[\n"\\]/g;function W(t){return t.replace(Z,function(e){return"\\"+e.charCodeAt(0).toString(16)+" "})}function ct(t,e,l,n,a,u,i,o){t.name="",i!=null&&typeof i!="function"&&typeof i!="symbol"&&typeof i!="boolean"?t.type=i:t.removeAttribute("type"),e!=null?i==="number"?(e===0&&t.value===""||t.value!=e)&&(t.value=""+_e(e)):t.value!==""+_e(e)&&(t.value=""+_e(e)):i!=="submit"&&i!=="reset"||t.removeAttribute("value"),e!=null?Ct(t,i,_e(e)):l!=null?Ct(t,i,_e(l)):n!=null&&t.removeAttribute("value"),a==null&&u!=null&&(t.defaultChecked=!!u),a!=null&&(t.checked=a&&typeof a!="function"&&typeof a!="symbol"),o!=null&&typeof o!="function"&&typeof o!="symbol"&&typeof o!="boolean"?t.name=""+_e(o):t.removeAttribute("name")}function At(t,e,l,n,a,u,i,o){if(u!=null&&typeof u!="function"&&typeof u!="symbol"&&typeof u!="boolean"&&(t.type=u),e!=null||l!=null){if(!(u!=="submit"&&u!=="reset"||e!=null)){Va(t);return}l=l!=null?""+_e(l):"",e=e!=null?""+_e(e):l,o||e===t.value||(t.value=e),t.defaultValue=e}n=n??a,n=typeof n!="function"&&typeof n!="symbol"&&!!n,t.checked=o?t.checked:!!n,t.defaultChecked=!!n,i!=null&&typeof i!="function"&&typeof i!="symbol"&&typeof i!="boolean"&&(t.name=i),Va(t)}function Ct(t,e,l){e==="number"&&B(t.ownerDocument)===t||t.defaultValue===""+l||(t.defaultValue=""+l)}function _t(t,e,l,n){if(t=t.options,e){e={};for(var a=0;a<l.length;a++)e["$"+l[a]]=!0;for(l=0;l<t.length;l++)a=e.hasOwnProperty("$"+t[l].value),t[l].selected!==a&&(t[l].selected=a),a&&n&&(t[l].defaultSelected=!0)}else{for(l=""+_e(l),e=null,a=0;a<t.length;a++){if(t[a].value===l){t[a].selected=!0,n&&(t[a].defaultSelected=!0);return}e!==null||t[a].disabled||(e=t[a])}e!==null&&(e.selected=!0)}}function te(t,e,l){if(e!=null&&(e=""+_e(e),e!==t.value&&(t.value=e),l==null)){t.defaultValue!==e&&(t.defaultValue=e);return}t.defaultValue=l!=null?""+_e(l):""}function de(t,e,l,n){if(e==null){if(n!=null){if(l!=null)throw Error(f(92));if($t(n)){if(1<n.length)throw Error(f(93));n=n[0]}l=n}l==null&&(l=""),e=l}l=_e(e),t.defaultValue=l,n=t.textContent,n===l&&n!==""&&n!==null&&(t.value=n),Va(t)}function ne(t,e){if(e){var l=t.firstChild;if(l&&l===t.lastChild&&l.nodeType===3){l.nodeValue=e;return}}t.textContent=e}var Re=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 Ft(t,e,l){var n=e.indexOf("--")===0;l==null||typeof l=="boolean"||l===""?n?t.setProperty(e,""):e==="float"?t.cssFloat="":t[e]="":n?t.setProperty(e,l):typeof l!="number"||l===0||Re.has(e)?e==="float"?t.cssFloat=l:t[e]=(""+l).trim():t[e]=l+"px"}function Xu(t,e,l){if(e!=null&&typeof e!="object")throw Error(f(62));if(t=t.style,l!=null){for(var n in l)!l.hasOwnProperty(n)||e!=null&&e.hasOwnProperty(n)||(n.indexOf("--")===0?t.setProperty(n,""):n==="float"?t.cssFloat="":t[n]="");for(var a in e)n=e[a],e.hasOwnProperty(a)&&l[a]!==n&&Ft(t,a,n)}else for(var u in e)e.hasOwnProperty(u)&&Ft(t,u,e[u])}function lc(t){if(t.indexOf("-")===-1)return!1;switch(t){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 L0=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"]]),Y0=/^[\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 ku(t){return Y0.test(""+t)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":t}function Ul(){}var nc=null;function ac(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var fa=null,ra=null;function zo(t){var e=an(t);if(e&&(t=e.stateNode)){var l=t[ze]||null;t:switch(t=e.stateNode,e.type){case"input":if(ct(t,l.value,l.defaultValue,l.defaultValue,l.checked,l.defaultChecked,l.type,l.name),e=l.name,l.type==="radio"&&e!=null){for(l=t;l.parentNode;)l=l.parentNode;for(l=l.querySelectorAll('input[name="'+W(""+e)+'"][type="radio"]'),e=0;e<l.length;e++){var n=l[e];if(n!==t&&n.form===t.form){var a=n[ze]||null;if(!a)throw Error(f(90));ct(n,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name)}}for(e=0;e<l.length;e++)n=l[e],n.form===t.form&&h(n)}break t;case"textarea":te(t,l.value,l.defaultValue);break t;case"select":e=l.value,e!=null&&_t(t,!!l.multiple,e,!1)}}}var uc=!1;function Do(t,e,l){if(uc)return t(e,l);uc=!0;try{var n=t(e);return n}finally{if(uc=!1,(fa!==null||ra!==null)&&(Ni(),fa&&(e=fa,t=ra,ra=fa=null,zo(e),t)))for(e=0;e<t.length;e++)zo(t[e])}}function Ka(t,e){var l=t.stateNode;if(l===null)return null;var n=l[ze]||null;if(n===null)return null;l=n[e];t:switch(e){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(n=!n.disabled)||(t=t.type,n=!(t==="button"||t==="input"||t==="select"||t==="textarea")),t=!n;break t;default:t=!1}if(t)return null;if(l&&typeof l!="function")throw Error(f(231,e,typeof l));return l}var Hl=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),ic=!1;if(Hl)try{var Ja={};Object.defineProperty(Ja,"passive",{get:function(){ic=!0}}),window.addEventListener("test",Ja,Ja),window.removeEventListener("test",Ja,Ja)}catch{ic=!1}var cn=null,cc=null,Qu=null;function jo(){if(Qu)return Qu;var t,e=cc,l=e.length,n,a="value"in cn?cn.value:cn.textContent,u=a.length;for(t=0;t<l&&e[t]===a[t];t++);var i=l-t;for(n=1;n<=i&&e[l-n]===a[u-n];n++);return Qu=a.slice(t,1<n?1-n:void 0)}function Zu(t){var e=t.keyCode;return"charCode"in t?(t=t.charCode,t===0&&e===13&&(t=13)):t=e,t===10&&(t=13),32<=t||t===13?t:0}function Vu(){return!0}function No(){return!1}function Ue(t){function e(l,n,a,u,i){this._reactName=l,this._targetInst=a,this.type=n,this.nativeEvent=u,this.target=i,this.currentTarget=null;for(var o in t)t.hasOwnProperty(o)&&(l=t[o],this[o]=l?l(u):u[o]);return this.isDefaultPrevented=(u.defaultPrevented!=null?u.defaultPrevented:u.returnValue===!1)?Vu:No,this.isPropagationStopped=No,this}return H(e.prototype,{preventDefault:function(){this.defaultPrevented=!0;var l=this.nativeEvent;l&&(l.preventDefault?l.preventDefault():typeof l.returnValue!="unknown"&&(l.returnValue=!1),this.isDefaultPrevented=Vu)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=Vu)},persist:function(){},isPersistent:Vu}),e}var Bn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(t){return t.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Ku=Ue(Bn),$a=H({},Bn,{view:0,detail:0}),G0=Ue($a),sc,oc,Wa,Ju=H({},$a,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:rc,button:0,buttons:0,relatedTarget:function(t){return t.relatedTarget===void 0?t.fromElement===t.srcElement?t.toElement:t.fromElement:t.relatedTarget},movementX:function(t){return"movementX"in t?t.movementX:(t!==Wa&&(Wa&&t.type==="mousemove"?(sc=t.screenX-Wa.screenX,oc=t.screenY-Wa.screenY):oc=sc=0,Wa=t),sc)},movementY:function(t){return"movementY"in t?t.movementY:oc}}),wo=Ue(Ju),X0=H({},Ju,{dataTransfer:0}),k0=Ue(X0),Q0=H({},$a,{relatedTarget:0}),fc=Ue(Q0),Z0=H({},Bn,{animationName:0,elapsedTime:0,pseudoElement:0}),V0=Ue(Z0),K0=H({},Bn,{clipboardData:function(t){return"clipboardData"in t?t.clipboardData:window.clipboardData}}),J0=Ue(K0),$0=H({},Bn,{data:0}),Oo=Ue($0),W0={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},F0={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"},I0={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function P0(t){var e=this.nativeEvent;return e.getModifierState?e.getModifierState(t):(t=I0[t])?!!e[t]:!1}function rc(){return P0}var t1=H({},$a,{key:function(t){if(t.key){var e=W0[t.key]||t.key;if(e!=="Unidentified")return e}return t.type==="keypress"?(t=Zu(t),t===13?"Enter":String.fromCharCode(t)):t.type==="keydown"||t.type==="keyup"?F0[t.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:rc,charCode:function(t){return t.type==="keypress"?Zu(t):0},keyCode:function(t){return t.type==="keydown"||t.type==="keyup"?t.keyCode:0},which:function(t){return t.type==="keypress"?Zu(t):t.type==="keydown"||t.type==="keyup"?t.keyCode:0}}),e1=Ue(t1),l1=H({},Ju,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),_o=Ue(l1),n1=H({},$a,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:rc}),a1=Ue(n1),u1=H({},Bn,{propertyName:0,elapsedTime:0,pseudoElement:0}),i1=Ue(u1),c1=H({},Ju,{deltaX:function(t){return"deltaX"in t?t.deltaX:"wheelDeltaX"in t?-t.wheelDeltaX:0},deltaY:function(t){return"deltaY"in t?t.deltaY:"wheelDeltaY"in t?-t.wheelDeltaY:"wheelDelta"in t?-t.wheelDelta:0},deltaZ:0,deltaMode:0}),s1=Ue(c1),o1=H({},Bn,{newState:0,oldState:0}),f1=Ue(o1),r1=[9,13,27,32],dc=Hl&&"CompositionEvent"in window,Fa=null;Hl&&"documentMode"in document&&(Fa=document.documentMode);var d1=Hl&&"TextEvent"in window&&!Fa,Ro=Hl&&(!dc||Fa&&8<Fa&&11>=Fa),Uo=" ",Ho=!1;function Bo(t,e){switch(t){case"keyup":return r1.indexOf(e.keyCode)!==-1;case"keydown":return e.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function qo(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var da=!1;function h1(t,e){switch(t){case"compositionend":return qo(e);case"keypress":return e.which!==32?null:(Ho=!0,Uo);case"textInput":return t=e.data,t===Uo&&Ho?null:t;default:return null}}function m1(t,e){if(da)return t==="compositionend"||!dc&&Bo(t,e)?(t=jo(),Qu=cc=cn=null,da=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(e.ctrlKey||e.altKey||e.metaKey)||e.ctrlKey&&e.altKey){if(e.char&&1<e.char.length)return e.char;if(e.which)return String.fromCharCode(e.which)}return null;case"compositionend":return Ro&&e.locale!=="ko"?null:e.data;default:return null}}var g1={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 Lo(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e==="input"?!!g1[t.type]:e==="textarea"}function Yo(t,e,l,n){fa?ra?ra.push(n):ra=[n]:fa=n,e=Bi(e,"onChange"),0<e.length&&(l=new Ku("onChange","change",null,l,n),t.push({event:l,listeners:e}))}var Ia=null,Pa=null;function p1(t){Md(t,0)}function $u(t){var e=Hn(t);if(h(e))return t}function Go(t,e){if(t==="change")return e}var Xo=!1;if(Hl){var hc;if(Hl){var mc="oninput"in document;if(!mc){var ko=document.createElement("div");ko.setAttribute("oninput","return;"),mc=typeof ko.oninput=="function"}hc=mc}else hc=!1;Xo=hc&&(!document.documentMode||9<document.documentMode)}function Qo(){Ia&&(Ia.detachEvent("onpropertychange",Zo),Pa=Ia=null)}function Zo(t){if(t.propertyName==="value"&&$u(Pa)){var e=[];Yo(e,Pa,t,ac(t)),Do(p1,e)}}function y1(t,e,l){t==="focusin"?(Qo(),Ia=e,Pa=l,Ia.attachEvent("onpropertychange",Zo)):t==="focusout"&&Qo()}function v1(t){if(t==="selectionchange"||t==="keyup"||t==="keydown")return $u(Pa)}function b1(t,e){if(t==="click")return $u(e)}function x1(t,e){if(t==="input"||t==="change")return $u(e)}function S1(t,e){return t===e&&(t!==0||1/t===1/e)||t!==t&&e!==e}var ke=typeof Object.is=="function"?Object.is:S1;function tu(t,e){if(ke(t,e))return!0;if(typeof t!="object"||t===null||typeof e!="object"||e===null)return!1;var l=Object.keys(t),n=Object.keys(e);if(l.length!==n.length)return!1;for(n=0;n<l.length;n++){var a=l[n];if(!dl.call(e,a)||!ke(t[a],e[a]))return!1}return!0}function Vo(t){for(;t&&t.firstChild;)t=t.firstChild;return t}function Ko(t,e){var l=Vo(t);t=0;for(var n;l;){if(l.nodeType===3){if(n=t+l.textContent.length,t<=e&&n>=e)return{node:l,offset:e-t};t=n}t:{for(;l;){if(l.nextSibling){l=l.nextSibling;break t}l=l.parentNode}l=void 0}l=Vo(l)}}function Jo(t,e){return t&&e?t===e?!0:t&&t.nodeType===3?!1:e&&e.nodeType===3?Jo(t,e.parentNode):"contains"in t?t.contains(e):t.compareDocumentPosition?!!(t.compareDocumentPosition(e)&16):!1:!1}function $o(t){t=t!=null&&t.ownerDocument!=null&&t.ownerDocument.defaultView!=null?t.ownerDocument.defaultView:window;for(var e=B(t.document);e instanceof t.HTMLIFrameElement;){try{var l=typeof e.contentWindow.location.href=="string"}catch{l=!1}if(l)t=e.contentWindow;else break;e=B(t.document)}return e}function gc(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e&&(e==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||e==="textarea"||t.contentEditable==="true")}var E1=Hl&&"documentMode"in document&&11>=document.documentMode,ha=null,pc=null,eu=null,yc=!1;function Wo(t,e,l){var n=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;yc||ha==null||ha!==B(n)||(n=ha,"selectionStart"in n&&gc(n)?n={start:n.selectionStart,end:n.selectionEnd}:(n=(n.ownerDocument&&n.ownerDocument.defaultView||window).getSelection(),n={anchorNode:n.anchorNode,anchorOffset:n.anchorOffset,focusNode:n.focusNode,focusOffset:n.focusOffset}),eu&&tu(eu,n)||(eu=n,n=Bi(pc,"onSelect"),0<n.length&&(e=new Ku("onSelect","select",null,e,l),t.push({event:e,listeners:n}),e.target=ha)))}function qn(t,e){var l={};return l[t.toLowerCase()]=e.toLowerCase(),l["Webkit"+t]="webkit"+e,l["Moz"+t]="moz"+e,l}var ma={animationend:qn("Animation","AnimationEnd"),animationiteration:qn("Animation","AnimationIteration"),animationstart:qn("Animation","AnimationStart"),transitionrun:qn("Transition","TransitionRun"),transitionstart:qn("Transition","TransitionStart"),transitioncancel:qn("Transition","TransitionCancel"),transitionend:qn("Transition","TransitionEnd")},vc={},Fo={};Hl&&(Fo=document.createElement("div").style,"AnimationEvent"in window||(delete ma.animationend.animation,delete ma.animationiteration.animation,delete ma.animationstart.animation),"TransitionEvent"in window||delete ma.transitionend.transition);function Ln(t){if(vc[t])return vc[t];if(!ma[t])return t;var e=ma[t],l;for(l in e)if(e.hasOwnProperty(l)&&l in Fo)return vc[t]=e[l];return t}var Io=Ln("animationend"),Po=Ln("animationiteration"),tf=Ln("animationstart"),M1=Ln("transitionrun"),C1=Ln("transitionstart"),A1=Ln("transitioncancel"),ef=Ln("transitionend"),lf=new Map,bc="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(" ");bc.push("scrollEnd");function yl(t,e){lf.set(t,e),gl(e,[t])}var Wu=typeof reportError=="function"?reportError:function(t){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var e=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof t=="object"&&t!==null&&typeof t.message=="string"?String(t.message):String(t),error:t});if(!window.dispatchEvent(e))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",t);return}console.error(t)},Pe=[],ga=0,xc=0;function Fu(){for(var t=ga,e=xc=ga=0;e<t;){var l=Pe[e];Pe[e++]=null;var n=Pe[e];Pe[e++]=null;var a=Pe[e];Pe[e++]=null;var u=Pe[e];if(Pe[e++]=null,n!==null&&a!==null){var i=n.pending;i===null?a.next=a:(a.next=i.next,i.next=a),n.pending=a}u!==0&&nf(l,a,u)}}function Iu(t,e,l,n){Pe[ga++]=t,Pe[ga++]=e,Pe[ga++]=l,Pe[ga++]=n,xc|=n,t.lanes|=n,t=t.alternate,t!==null&&(t.lanes|=n)}function Sc(t,e,l,n){return Iu(t,e,l,n),Pu(t)}function Yn(t,e){return Iu(t,null,null,e),Pu(t)}function nf(t,e,l){t.lanes|=l;var n=t.alternate;n!==null&&(n.lanes|=l);for(var a=!1,u=t.return;u!==null;)u.childLanes|=l,n=u.alternate,n!==null&&(n.childLanes|=l),u.tag===22&&(t=u.stateNode,t===null||t._visibility&1||(a=!0)),t=u,u=u.return;return t.tag===3?(u=t.stateNode,a&&e!==null&&(a=31-xe(l),t=u.hiddenUpdates,n=t[a],n===null?t[a]=[e]:n.push(e),e.lane=l|536870912),u):null}function Pu(t){if(50<Mu)throw Mu=0,Ns=null,Error(f(185));for(var e=t.return;e!==null;)t=e,e=t.return;return t.tag===3?t.stateNode:null}var pa={};function T1(t,e,l,n){this.tag=t,this.key=l,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=e,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=n,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Qe(t,e,l,n){return new T1(t,e,l,n)}function Ec(t){return t=t.prototype,!(!t||!t.isReactComponent)}function Bl(t,e){var l=t.alternate;return l===null?(l=Qe(t.tag,e,t.key,t.mode),l.elementType=t.elementType,l.type=t.type,l.stateNode=t.stateNode,l.alternate=t,t.alternate=l):(l.pendingProps=e,l.type=t.type,l.flags=0,l.subtreeFlags=0,l.deletions=null),l.flags=t.flags&65011712,l.childLanes=t.childLanes,l.lanes=t.lanes,l.child=t.child,l.memoizedProps=t.memoizedProps,l.memoizedState=t.memoizedState,l.updateQueue=t.updateQueue,e=t.dependencies,l.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext},l.sibling=t.sibling,l.index=t.index,l.ref=t.ref,l.refCleanup=t.refCleanup,l}function af(t,e){t.flags&=65011714;var l=t.alternate;return l===null?(t.childLanes=0,t.lanes=e,t.child=null,t.subtreeFlags=0,t.memoizedProps=null,t.memoizedState=null,t.updateQueue=null,t.dependencies=null,t.stateNode=null):(t.childLanes=l.childLanes,t.lanes=l.lanes,t.child=l.child,t.subtreeFlags=0,t.deletions=null,t.memoizedProps=l.memoizedProps,t.memoizedState=l.memoizedState,t.updateQueue=l.updateQueue,t.type=l.type,e=l.dependencies,t.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),t}function ti(t,e,l,n,a,u){var i=0;if(n=t,typeof t=="function")Ec(t)&&(i=1);else if(typeof t=="string")i=wh(t,l,V.current)?26:t==="html"||t==="head"||t==="body"?27:5;else t:switch(t){case it:return t=Qe(31,l,e,a),t.elementType=it,t.lanes=u,t;case F:return Gn(l.children,a,u,e);case dt:i=8,a|=24;break;case g:return t=Qe(12,l,e,a|2),t.elementType=g,t.lanes=u,t;case lt:return t=Qe(13,l,e,a),t.elementType=lt,t.lanes=u,t;case P:return t=Qe(19,l,e,a),t.elementType=P,t.lanes=u,t;default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case I:i=10;break t;case Q:i=9;break t;case et:i=11;break t;case J:i=14;break t;case nt:i=16,n=null;break t}i=29,l=Error(f(130,t===null?"null":typeof t,"")),n=null}return e=Qe(i,l,e,a),e.elementType=t,e.type=n,e.lanes=u,e}function Gn(t,e,l,n){return t=Qe(7,t,n,e),t.lanes=l,t}function Mc(t,e,l){return t=Qe(6,t,null,e),t.lanes=l,t}function uf(t){var e=Qe(18,null,null,0);return e.stateNode=t,e}function Cc(t,e,l){return e=Qe(4,t.children!==null?t.children:[],t.key,e),e.lanes=l,e.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},e}var cf=new WeakMap;function tl(t,e){if(typeof t=="object"&&t!==null){var l=cf.get(t);return l!==void 0?l:(e={value:t,source:e,stack:je(e)},cf.set(t,e),e)}return{value:t,source:e,stack:je(e)}}var ya=[],va=0,ei=null,lu=0,el=[],ll=0,sn=null,Dl=1,jl="";function ql(t,e){ya[va++]=lu,ya[va++]=ei,ei=t,lu=e}function sf(t,e,l){el[ll++]=Dl,el[ll++]=jl,el[ll++]=sn,sn=t;var n=Dl;t=jl;var a=32-xe(n)-1;n&=~(1<<a),l+=1;var u=32-xe(e)+a;if(30<u){var i=a-a%5;u=(n&(1<<i)-1).toString(32),n>>=i,a-=i,Dl=1<<32-xe(e)+a|l<<a|n,jl=u+t}else Dl=1<<u|l<<a|n,jl=t}function Ac(t){t.return!==null&&(ql(t,1),sf(t,1,0))}function Tc(t){for(;t===ei;)ei=ya[--va],ya[va]=null,lu=ya[--va],ya[va]=null;for(;t===sn;)sn=el[--ll],el[ll]=null,jl=el[--ll],el[ll]=null,Dl=el[--ll],el[ll]=null}function of(t,e){el[ll++]=Dl,el[ll++]=jl,el[ll++]=sn,Dl=e.id,jl=e.overflow,sn=t}var Me=null,It=null,Ot=!1,on=null,nl=!1,zc=Error(f(519));function fn(t){var e=Error(f(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw nu(tl(e,t)),zc}function ff(t){var e=t.stateNode,l=t.type,n=t.memoizedProps;switch(e[fe]=t,e[ze]=n,l){case"dialog":Dt("cancel",e),Dt("close",e);break;case"iframe":case"object":case"embed":Dt("load",e);break;case"video":case"audio":for(l=0;l<Au.length;l++)Dt(Au[l],e);break;case"source":Dt("error",e);break;case"img":case"image":case"link":Dt("error",e),Dt("load",e);break;case"details":Dt("toggle",e);break;case"input":Dt("invalid",e),At(e,n.value,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name,!0);break;case"select":Dt("invalid",e);break;case"textarea":Dt("invalid",e),de(e,n.value,n.defaultValue,n.children)}l=n.children,typeof l!="string"&&typeof l!="number"&&typeof l!="bigint"||e.textContent===""+l||n.suppressHydrationWarning===!0||zd(e.textContent,l)?(n.popover!=null&&(Dt("beforetoggle",e),Dt("toggle",e)),n.onScroll!=null&&Dt("scroll",e),n.onScrollEnd!=null&&Dt("scrollend",e),n.onClick!=null&&(e.onclick=Ul),e=!0):e=!1,e||fn(t,!0)}function rf(t){for(Me=t.return;Me;)switch(Me.tag){case 5:case 31:case 13:nl=!1;return;case 27:case 3:nl=!0;return;default:Me=Me.return}}function ba(t){if(t!==Me)return!1;if(!Ot)return rf(t),Ot=!0,!1;var e=t.tag,l;if((l=e!==3&&e!==27)&&((l=e===5)&&(l=t.type,l=!(l!=="form"&&l!=="button")||Zs(t.type,t.memoizedProps)),l=!l),l&&It&&fn(t),rf(t),e===13){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(f(317));It=Hd(t)}else if(e===31){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(f(317));It=Hd(t)}else e===27?(e=It,Cn(t.type)?(t=Ws,Ws=null,It=t):It=e):It=Me?ul(t.stateNode.nextSibling):null;return!0}function Xn(){It=Me=null,Ot=!1}function Dc(){var t=on;return t!==null&&(Le===null?Le=t:Le.push.apply(Le,t),on=null),t}function nu(t){on===null?on=[t]:on.push(t)}var jc=v(null),kn=null,Ll=null;function rn(t,e,l){k(jc,e._currentValue),e._currentValue=l}function Yl(t){t._currentValue=jc.current,N(jc)}function Nc(t,e,l){for(;t!==null;){var n=t.alternate;if((t.childLanes&e)!==e?(t.childLanes|=e,n!==null&&(n.childLanes|=e)):n!==null&&(n.childLanes&e)!==e&&(n.childLanes|=e),t===l)break;t=t.return}}function wc(t,e,l,n){var a=t.child;for(a!==null&&(a.return=t);a!==null;){var u=a.dependencies;if(u!==null){var i=a.child;u=u.firstContext;t:for(;u!==null;){var o=u;u=a;for(var p=0;p<e.length;p++)if(o.context===e[p]){u.lanes|=l,o=u.alternate,o!==null&&(o.lanes|=l),Nc(u.return,l,t),n||(i=null);break t}u=o.next}}else if(a.tag===18){if(i=a.return,i===null)throw Error(f(341));i.lanes|=l,u=i.alternate,u!==null&&(u.lanes|=l),Nc(i,l,t),i=null}else i=a.child;if(i!==null)i.return=a;else for(i=a;i!==null;){if(i===t){i=null;break}if(a=i.sibling,a!==null){a.return=i.return,i=a;break}i=i.return}a=i}}function xa(t,e,l,n){t=null;for(var a=e,u=!1;a!==null;){if(!u){if((a.flags&524288)!==0)u=!0;else if((a.flags&262144)!==0)break}if(a.tag===10){var i=a.alternate;if(i===null)throw Error(f(387));if(i=i.memoizedProps,i!==null){var o=a.type;ke(a.pendingProps.value,i.value)||(t!==null?t.push(o):t=[o])}}else if(a===Tt.current){if(i=a.alternate,i===null)throw Error(f(387));i.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(t!==null?t.push(Nu):t=[Nu])}a=a.return}t!==null&&wc(e,t,l,n),e.flags|=262144}function li(t){for(t=t.firstContext;t!==null;){if(!ke(t.context._currentValue,t.memoizedValue))return!0;t=t.next}return!1}function Qn(t){kn=t,Ll=null,t=t.dependencies,t!==null&&(t.firstContext=null)}function Ce(t){return df(kn,t)}function ni(t,e){return kn===null&&Qn(t),df(t,e)}function df(t,e){var l=e._currentValue;if(e={context:e,memoizedValue:l,next:null},Ll===null){if(t===null)throw Error(f(308));Ll=e,t.dependencies={lanes:0,firstContext:e},t.flags|=524288}else Ll=Ll.next=e;return l}var z1=typeof AbortController<"u"?AbortController:function(){var t=[],e=this.signal={aborted:!1,addEventListener:function(l,n){t.push(n)}};this.abort=function(){e.aborted=!0,t.forEach(function(l){return l()})}},D1=c.unstable_scheduleCallback,j1=c.unstable_NormalPriority,he={$$typeof:I,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function Oc(){return{controller:new z1,data:new Map,refCount:0}}function au(t){t.refCount--,t.refCount===0&&D1(j1,function(){t.controller.abort()})}var uu=null,_c=0,Sa=0,Ea=null;function N1(t,e){if(uu===null){var l=uu=[];_c=0,Sa=Hs(),Ea={status:"pending",value:void 0,then:function(n){l.push(n)}}}return _c++,e.then(hf,hf),e}function hf(){if(--_c===0&&uu!==null){Ea!==null&&(Ea.status="fulfilled");var t=uu;uu=null,Sa=0,Ea=null;for(var e=0;e<t.length;e++)(0,t[e])()}}function w1(t,e){var l=[],n={status:"pending",value:null,reason:null,then:function(a){l.push(a)}};return t.then(function(){n.status="fulfilled",n.value=e;for(var a=0;a<l.length;a++)(0,l[a])(e)},function(a){for(n.status="rejected",n.reason=a,a=0;a<l.length;a++)(0,l[a])(void 0)}),n}var mf=z.S;z.S=function(t,e){Fr=ye(),typeof e=="object"&&e!==null&&typeof e.then=="function"&&N1(t,e),mf!==null&&mf(t,e)};var Zn=v(null);function Rc(){var t=Zn.current;return t!==null?t:Zt.pooledCache}function ai(t,e){e===null?k(Zn,Zn.current):k(Zn,e.pool)}function gf(){var t=Rc();return t===null?null:{parent:he._currentValue,pool:t}}var Ma=Error(f(460)),Uc=Error(f(474)),ui=Error(f(542)),ii={then:function(){}};function pf(t){return t=t.status,t==="fulfilled"||t==="rejected"}function yf(t,e,l){switch(l=t[l],l===void 0?t.push(e):l!==e&&(e.then(Ul,Ul),e=l),e.status){case"fulfilled":return e.value;case"rejected":throw t=e.reason,bf(t),t;default:if(typeof e.status=="string")e.then(Ul,Ul);else{if(t=Zt,t!==null&&100<t.shellSuspendCounter)throw Error(f(482));t=e,t.status="pending",t.then(function(n){if(e.status==="pending"){var a=e;a.status="fulfilled",a.value=n}},function(n){if(e.status==="pending"){var a=e;a.status="rejected",a.reason=n}})}switch(e.status){case"fulfilled":return e.value;case"rejected":throw t=e.reason,bf(t),t}throw Kn=e,Ma}}function Vn(t){try{var e=t._init;return e(t._payload)}catch(l){throw l!==null&&typeof l=="object"&&typeof l.then=="function"?(Kn=l,Ma):l}}var Kn=null;function vf(){if(Kn===null)throw Error(f(459));var t=Kn;return Kn=null,t}function bf(t){if(t===Ma||t===ui)throw Error(f(483))}var Ca=null,iu=0;function ci(t){var e=iu;return iu+=1,Ca===null&&(Ca=[]),yf(Ca,t,e)}function cu(t,e){e=e.props.ref,t.ref=e!==void 0?e:null}function si(t,e){throw e.$$typeof===G?Error(f(525)):(t=Object.prototype.toString.call(e),Error(f(31,t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)))}function xf(t){function e(S,b){if(t){var M=S.deletions;M===null?(S.deletions=[b],S.flags|=16):M.push(b)}}function l(S,b){if(!t)return null;for(;b!==null;)e(S,b),b=b.sibling;return null}function n(S){for(var b=new Map;S!==null;)S.key!==null?b.set(S.key,S):b.set(S.index,S),S=S.sibling;return b}function a(S,b){return S=Bl(S,b),S.index=0,S.sibling=null,S}function u(S,b,M){return S.index=M,t?(M=S.alternate,M!==null?(M=M.index,M<b?(S.flags|=67108866,b):M):(S.flags|=67108866,b)):(S.flags|=1048576,b)}function i(S){return t&&S.alternate===null&&(S.flags|=67108866),S}function o(S,b,M,_){return b===null||b.tag!==6?(b=Mc(M,S.mode,_),b.return=S,b):(b=a(b,M),b.return=S,b)}function p(S,b,M,_){var st=M.type;return st===F?w(S,b,M.props.children,_,M.key):b!==null&&(b.elementType===st||typeof st=="object"&&st!==null&&st.$$typeof===nt&&Vn(st)===b.type)?(b=a(b,M.props),cu(b,M),b.return=S,b):(b=ti(M.type,M.key,M.props,null,S.mode,_),cu(b,M),b.return=S,b)}function C(S,b,M,_){return b===null||b.tag!==4||b.stateNode.containerInfo!==M.containerInfo||b.stateNode.implementation!==M.implementation?(b=Cc(M,S.mode,_),b.return=S,b):(b=a(b,M.children||[]),b.return=S,b)}function w(S,b,M,_,st){return b===null||b.tag!==7?(b=Gn(M,S.mode,_,st),b.return=S,b):(b=a(b,M),b.return=S,b)}function U(S,b,M){if(typeof b=="string"&&b!==""||typeof b=="number"||typeof b=="bigint")return b=Mc(""+b,S.mode,M),b.return=S,b;if(typeof b=="object"&&b!==null){switch(b.$$typeof){case Y:return M=ti(b.type,b.key,b.props,null,S.mode,M),cu(M,b),M.return=S,M;case X:return b=Cc(b,S.mode,M),b.return=S,b;case nt:return b=Vn(b),U(S,b,M)}if($t(b)||gt(b))return b=Gn(b,S.mode,M,null),b.return=S,b;if(typeof b.then=="function")return U(S,ci(b),M);if(b.$$typeof===I)return U(S,ni(S,b),M);si(S,b)}return null}function T(S,b,M,_){var st=b!==null?b.key:null;if(typeof M=="string"&&M!==""||typeof M=="number"||typeof M=="bigint")return st!==null?null:o(S,b,""+M,_);if(typeof M=="object"&&M!==null){switch(M.$$typeof){case Y:return M.key===st?p(S,b,M,_):null;case X:return M.key===st?C(S,b,M,_):null;case nt:return M=Vn(M),T(S,b,M,_)}if($t(M)||gt(M))return st!==null?null:w(S,b,M,_,null);if(typeof M.then=="function")return T(S,b,ci(M),_);if(M.$$typeof===I)return T(S,b,ni(S,M),_);si(S,M)}return null}function j(S,b,M,_,st){if(typeof _=="string"&&_!==""||typeof _=="number"||typeof _=="bigint")return S=S.get(M)||null,o(b,S,""+_,st);if(typeof _=="object"&&_!==null){switch(_.$$typeof){case Y:return S=S.get(_.key===null?M:_.key)||null,p(b,S,_,st);case X:return S=S.get(_.key===null?M:_.key)||null,C(b,S,_,st);case nt:return _=Vn(_),j(S,b,M,_,st)}if($t(_)||gt(_))return S=S.get(M)||null,w(b,S,_,st,null);if(typeof _.then=="function")return j(S,b,M,ci(_),st);if(_.$$typeof===I)return j(S,b,M,ni(b,_),st);si(b,_)}return null}function tt(S,b,M,_){for(var st=null,Rt=null,at=b,Et=b=0,Nt=null;at!==null&&Et<M.length;Et++){at.index>Et?(Nt=at,at=null):Nt=at.sibling;var Ut=T(S,at,M[Et],_);if(Ut===null){at===null&&(at=Nt);break}t&&at&&Ut.alternate===null&&e(S,at),b=u(Ut,b,Et),Rt===null?st=Ut:Rt.sibling=Ut,Rt=Ut,at=Nt}if(Et===M.length)return l(S,at),Ot&&ql(S,Et),st;if(at===null){for(;Et<M.length;Et++)at=U(S,M[Et],_),at!==null&&(b=u(at,b,Et),Rt===null?st=at:Rt.sibling=at,Rt=at);return Ot&&ql(S,Et),st}for(at=n(at);Et<M.length;Et++)Nt=j(at,S,Et,M[Et],_),Nt!==null&&(t&&Nt.alternate!==null&&at.delete(Nt.key===null?Et:Nt.key),b=u(Nt,b,Et),Rt===null?st=Nt:Rt.sibling=Nt,Rt=Nt);return t&&at.forEach(function(jn){return e(S,jn)}),Ot&&ql(S,Et),st}function rt(S,b,M,_){if(M==null)throw Error(f(151));for(var st=null,Rt=null,at=b,Et=b=0,Nt=null,Ut=M.next();at!==null&&!Ut.done;Et++,Ut=M.next()){at.index>Et?(Nt=at,at=null):Nt=at.sibling;var jn=T(S,at,Ut.value,_);if(jn===null){at===null&&(at=Nt);break}t&&at&&jn.alternate===null&&e(S,at),b=u(jn,b,Et),Rt===null?st=jn:Rt.sibling=jn,Rt=jn,at=Nt}if(Ut.done)return l(S,at),Ot&&ql(S,Et),st;if(at===null){for(;!Ut.done;Et++,Ut=M.next())Ut=U(S,Ut.value,_),Ut!==null&&(b=u(Ut,b,Et),Rt===null?st=Ut:Rt.sibling=Ut,Rt=Ut);return Ot&&ql(S,Et),st}for(at=n(at);!Ut.done;Et++,Ut=M.next())Ut=j(at,S,Et,Ut.value,_),Ut!==null&&(t&&Ut.alternate!==null&&at.delete(Ut.key===null?Et:Ut.key),b=u(Ut,b,Et),Rt===null?st=Ut:Rt.sibling=Ut,Rt=Ut);return t&&at.forEach(function(Xh){return e(S,Xh)}),Ot&&ql(S,Et),st}function Qt(S,b,M,_){if(typeof M=="object"&&M!==null&&M.type===F&&M.key===null&&(M=M.props.children),typeof M=="object"&&M!==null){switch(M.$$typeof){case Y:t:{for(var st=M.key;b!==null;){if(b.key===st){if(st=M.type,st===F){if(b.tag===7){l(S,b.sibling),_=a(b,M.props.children),_.return=S,S=_;break t}}else if(b.elementType===st||typeof st=="object"&&st!==null&&st.$$typeof===nt&&Vn(st)===b.type){l(S,b.sibling),_=a(b,M.props),cu(_,M),_.return=S,S=_;break t}l(S,b);break}else e(S,b);b=b.sibling}M.type===F?(_=Gn(M.props.children,S.mode,_,M.key),_.return=S,S=_):(_=ti(M.type,M.key,M.props,null,S.mode,_),cu(_,M),_.return=S,S=_)}return i(S);case X:t:{for(st=M.key;b!==null;){if(b.key===st)if(b.tag===4&&b.stateNode.containerInfo===M.containerInfo&&b.stateNode.implementation===M.implementation){l(S,b.sibling),_=a(b,M.children||[]),_.return=S,S=_;break t}else{l(S,b);break}else e(S,b);b=b.sibling}_=Cc(M,S.mode,_),_.return=S,S=_}return i(S);case nt:return M=Vn(M),Qt(S,b,M,_)}if($t(M))return tt(S,b,M,_);if(gt(M)){if(st=gt(M),typeof st!="function")throw Error(f(150));return M=st.call(M),rt(S,b,M,_)}if(typeof M.then=="function")return Qt(S,b,ci(M),_);if(M.$$typeof===I)return Qt(S,b,ni(S,M),_);si(S,M)}return typeof M=="string"&&M!==""||typeof M=="number"||typeof M=="bigint"?(M=""+M,b!==null&&b.tag===6?(l(S,b.sibling),_=a(b,M),_.return=S,S=_):(l(S,b),_=Mc(M,S.mode,_),_.return=S,S=_),i(S)):l(S,b)}return function(S,b,M,_){try{iu=0;var st=Qt(S,b,M,_);return Ca=null,st}catch(at){if(at===Ma||at===ui)throw at;var Rt=Qe(29,at,null,S.mode);return Rt.lanes=_,Rt.return=S,Rt}}}var Jn=xf(!0),Sf=xf(!1),dn=!1;function Hc(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Bc(t,e){t=t.updateQueue,e.updateQueue===t&&(e.updateQueue={baseState:t.baseState,firstBaseUpdate:t.firstBaseUpdate,lastBaseUpdate:t.lastBaseUpdate,shared:t.shared,callbacks:null})}function hn(t){return{lane:t,tag:0,payload:null,callback:null,next:null}}function mn(t,e,l){var n=t.updateQueue;if(n===null)return null;if(n=n.shared,(Bt&2)!==0){var a=n.pending;return a===null?e.next=e:(e.next=a.next,a.next=e),n.pending=e,e=Pu(t),nf(t,null,l),e}return Iu(t,n,e,l),Pu(t)}function su(t,e,l){if(e=e.updateQueue,e!==null&&(e=e.shared,(l&4194048)!==0)){var n=e.lanes;n&=t.pendingLanes,l|=n,e.lanes=l,Cl(t,l)}}function qc(t,e){var l=t.updateQueue,n=t.alternate;if(n!==null&&(n=n.updateQueue,l===n)){var a=null,u=null;if(l=l.firstBaseUpdate,l!==null){do{var i={lane:l.lane,tag:l.tag,payload:l.payload,callback:null,next:null};u===null?a=u=i:u=u.next=i,l=l.next}while(l!==null);u===null?a=u=e:u=u.next=e}else a=u=e;l={baseState:n.baseState,firstBaseUpdate:a,lastBaseUpdate:u,shared:n.shared,callbacks:n.callbacks},t.updateQueue=l;return}t=l.lastBaseUpdate,t===null?l.firstBaseUpdate=e:t.next=e,l.lastBaseUpdate=e}var Lc=!1;function ou(){if(Lc){var t=Ea;if(t!==null)throw t}}function fu(t,e,l,n){Lc=!1;var a=t.updateQueue;dn=!1;var u=a.firstBaseUpdate,i=a.lastBaseUpdate,o=a.shared.pending;if(o!==null){a.shared.pending=null;var p=o,C=p.next;p.next=null,i===null?u=C:i.next=C,i=p;var w=t.alternate;w!==null&&(w=w.updateQueue,o=w.lastBaseUpdate,o!==i&&(o===null?w.firstBaseUpdate=C:o.next=C,w.lastBaseUpdate=p))}if(u!==null){var U=a.baseState;i=0,w=C=p=null,o=u;do{var T=o.lane&-536870913,j=T!==o.lane;if(j?(jt&T)===T:(n&T)===T){T!==0&&T===Sa&&(Lc=!0),w!==null&&(w=w.next={lane:0,tag:o.tag,payload:o.payload,callback:null,next:null});t:{var tt=t,rt=o;T=e;var Qt=l;switch(rt.tag){case 1:if(tt=rt.payload,typeof tt=="function"){U=tt.call(Qt,U,T);break t}U=tt;break t;case 3:tt.flags=tt.flags&-65537|128;case 0:if(tt=rt.payload,T=typeof tt=="function"?tt.call(Qt,U,T):tt,T==null)break t;U=H({},U,T);break t;case 2:dn=!0}}T=o.callback,T!==null&&(t.flags|=64,j&&(t.flags|=8192),j=a.callbacks,j===null?a.callbacks=[T]:j.push(T))}else j={lane:T,tag:o.tag,payload:o.payload,callback:o.callback,next:null},w===null?(C=w=j,p=U):w=w.next=j,i|=T;if(o=o.next,o===null){if(o=a.shared.pending,o===null)break;j=o,o=j.next,j.next=null,a.lastBaseUpdate=j,a.shared.pending=null}}while(!0);w===null&&(p=U),a.baseState=p,a.firstBaseUpdate=C,a.lastBaseUpdate=w,u===null&&(a.shared.lanes=0),bn|=i,t.lanes=i,t.memoizedState=U}}function Ef(t,e){if(typeof t!="function")throw Error(f(191,t));t.call(e)}function Mf(t,e){var l=t.callbacks;if(l!==null)for(t.callbacks=null,t=0;t<l.length;t++)Ef(l[t],e)}var Aa=v(null),oi=v(0);function Cf(t,e){t=$l,k(oi,t),k(Aa,e),$l=t|e.baseLanes}function Yc(){k(oi,$l),k(Aa,Aa.current)}function Gc(){$l=oi.current,N(Aa),N(oi)}var Ze=v(null),al=null;function gn(t){var e=t.alternate;k(ce,ce.current&1),k(Ze,t),al===null&&(e===null||Aa.current!==null||e.memoizedState!==null)&&(al=t)}function Xc(t){k(ce,ce.current),k(Ze,t),al===null&&(al=t)}function Af(t){t.tag===22?(k(ce,ce.current),k(Ze,t),al===null&&(al=t)):pn()}function pn(){k(ce,ce.current),k(Ze,Ze.current)}function Ve(t){N(Ze),al===t&&(al=null),N(ce)}var ce=v(0);function fi(t){for(var e=t;e!==null;){if(e.tag===13){var l=e.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||Js(l)||$s(l)))return e}else if(e.tag===19&&(e.memoizedProps.revealOrder==="forwards"||e.memoizedProps.revealOrder==="backwards"||e.memoizedProps.revealOrder==="unstable_legacy-backwards"||e.memoizedProps.revealOrder==="together")){if((e.flags&128)!==0)return e}else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)return null;e=e.return}e.sibling.return=e.return,e=e.sibling}return null}var Gl=0,bt=null,Xt=null,me=null,ri=!1,Ta=!1,$n=!1,di=0,ru=0,za=null,O1=0;function ae(){throw Error(f(321))}function kc(t,e){if(e===null)return!1;for(var l=0;l<e.length&&l<t.length;l++)if(!ke(t[l],e[l]))return!1;return!0}function Qc(t,e,l,n,a,u){return Gl=u,bt=e,e.memoizedState=null,e.updateQueue=null,e.lanes=0,z.H=t===null||t.memoizedState===null?sr:us,$n=!1,u=l(n,a),$n=!1,Ta&&(u=zf(e,l,n,a)),Tf(t),u}function Tf(t){z.H=mu;var e=Xt!==null&&Xt.next!==null;if(Gl=0,me=Xt=bt=null,ri=!1,ru=0,za=null,e)throw Error(f(300));t===null||ge||(t=t.dependencies,t!==null&&li(t)&&(ge=!0))}function zf(t,e,l,n){bt=t;var a=0;do{if(Ta&&(za=null),ru=0,Ta=!1,25<=a)throw Error(f(301));if(a+=1,me=Xt=null,t.updateQueue!=null){var u=t.updateQueue;u.lastEffect=null,u.events=null,u.stores=null,u.memoCache!=null&&(u.memoCache.index=0)}z.H=or,u=e(l,n)}while(Ta);return u}function _1(){var t=z.H,e=t.useState()[0];return e=typeof e.then=="function"?du(e):e,t=t.useState()[0],(Xt!==null?Xt.memoizedState:null)!==t&&(bt.flags|=1024),e}function Zc(){var t=di!==0;return di=0,t}function Vc(t,e,l){e.updateQueue=t.updateQueue,e.flags&=-2053,t.lanes&=~l}function Kc(t){if(ri){for(t=t.memoizedState;t!==null;){var e=t.queue;e!==null&&(e.pending=null),t=t.next}ri=!1}Gl=0,me=Xt=bt=null,Ta=!1,ru=di=0,za=null}function Ne(){var t={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return me===null?bt.memoizedState=me=t:me=me.next=t,me}function se(){if(Xt===null){var t=bt.alternate;t=t!==null?t.memoizedState:null}else t=Xt.next;var e=me===null?bt.memoizedState:me.next;if(e!==null)me=e,Xt=t;else{if(t===null)throw bt.alternate===null?Error(f(467)):Error(f(310));Xt=t,t={memoizedState:Xt.memoizedState,baseState:Xt.baseState,baseQueue:Xt.baseQueue,queue:Xt.queue,next:null},me===null?bt.memoizedState=me=t:me=me.next=t}return me}function hi(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function du(t){var e=ru;return ru+=1,za===null&&(za=[]),t=yf(za,t,e),e=bt,(me===null?e.memoizedState:me.next)===null&&(e=e.alternate,z.H=e===null||e.memoizedState===null?sr:us),t}function mi(t){if(t!==null&&typeof t=="object"){if(typeof t.then=="function")return du(t);if(t.$$typeof===I)return Ce(t)}throw Error(f(438,String(t)))}function Jc(t){var e=null,l=bt.updateQueue;if(l!==null&&(e=l.memoCache),e==null){var n=bt.alternate;n!==null&&(n=n.updateQueue,n!==null&&(n=n.memoCache,n!=null&&(e={data:n.data.map(function(a){return a.slice()}),index:0})))}if(e==null&&(e={data:[],index:0}),l===null&&(l=hi(),bt.updateQueue=l),l.memoCache=e,l=e.data[e.index],l===void 0)for(l=e.data[e.index]=Array(t),n=0;n<t;n++)l[n]=ut;return e.index++,l}function Xl(t,e){return typeof e=="function"?e(t):e}function gi(t){var e=se();return $c(e,Xt,t)}function $c(t,e,l){var n=t.queue;if(n===null)throw Error(f(311));n.lastRenderedReducer=l;var a=t.baseQueue,u=n.pending;if(u!==null){if(a!==null){var i=a.next;a.next=u.next,u.next=i}e.baseQueue=a=u,n.pending=null}if(u=t.baseState,a===null)t.memoizedState=u;else{e=a.next;var o=i=null,p=null,C=e,w=!1;do{var U=C.lane&-536870913;if(U!==C.lane?(jt&U)===U:(Gl&U)===U){var T=C.revertLane;if(T===0)p!==null&&(p=p.next={lane:0,revertLane:0,gesture:null,action:C.action,hasEagerState:C.hasEagerState,eagerState:C.eagerState,next:null}),U===Sa&&(w=!0);else if((Gl&T)===T){C=C.next,T===Sa&&(w=!0);continue}else U={lane:0,revertLane:C.revertLane,gesture:null,action:C.action,hasEagerState:C.hasEagerState,eagerState:C.eagerState,next:null},p===null?(o=p=U,i=u):p=p.next=U,bt.lanes|=T,bn|=T;U=C.action,$n&&l(u,U),u=C.hasEagerState?C.eagerState:l(u,U)}else T={lane:U,revertLane:C.revertLane,gesture:C.gesture,action:C.action,hasEagerState:C.hasEagerState,eagerState:C.eagerState,next:null},p===null?(o=p=T,i=u):p=p.next=T,bt.lanes|=U,bn|=U;C=C.next}while(C!==null&&C!==e);if(p===null?i=u:p.next=o,!ke(u,t.memoizedState)&&(ge=!0,w&&(l=Ea,l!==null)))throw l;t.memoizedState=u,t.baseState=i,t.baseQueue=p,n.lastRenderedState=u}return a===null&&(n.lanes=0),[t.memoizedState,n.dispatch]}function Wc(t){var e=se(),l=e.queue;if(l===null)throw Error(f(311));l.lastRenderedReducer=t;var n=l.dispatch,a=l.pending,u=e.memoizedState;if(a!==null){l.pending=null;var i=a=a.next;do u=t(u,i.action),i=i.next;while(i!==a);ke(u,e.memoizedState)||(ge=!0),e.memoizedState=u,e.baseQueue===null&&(e.baseState=u),l.lastRenderedState=u}return[u,n]}function Df(t,e,l){var n=bt,a=se(),u=Ot;if(u){if(l===void 0)throw Error(f(407));l=l()}else l=e();var i=!ke((Xt||a).memoizedState,l);if(i&&(a.memoizedState=l,ge=!0),a=a.queue,Pc(wf.bind(null,n,a,t),[t]),a.getSnapshot!==e||i||me!==null&&me.memoizedState.tag&1){if(n.flags|=2048,Da(9,{destroy:void 0},Nf.bind(null,n,a,l,e),null),Zt===null)throw Error(f(349));u||(Gl&127)!==0||jf(n,e,l)}return l}function jf(t,e,l){t.flags|=16384,t={getSnapshot:e,value:l},e=bt.updateQueue,e===null?(e=hi(),bt.updateQueue=e,e.stores=[t]):(l=e.stores,l===null?e.stores=[t]:l.push(t))}function Nf(t,e,l,n){e.value=l,e.getSnapshot=n,Of(e)&&_f(t)}function wf(t,e,l){return l(function(){Of(e)&&_f(t)})}function Of(t){var e=t.getSnapshot;t=t.value;try{var l=e();return!ke(t,l)}catch{return!0}}function _f(t){var e=Yn(t,2);e!==null&&Ye(e,t,2)}function Fc(t){var e=Ne();if(typeof t=="function"){var l=t;if(t=l(),$n){le(!0);try{l()}finally{le(!1)}}}return e.memoizedState=e.baseState=t,e.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Xl,lastRenderedState:t},e}function Rf(t,e,l,n){return t.baseState=l,$c(t,Xt,typeof n=="function"?n:Xl)}function R1(t,e,l,n,a){if(vi(t))throw Error(f(485));if(t=e.action,t!==null){var u={payload:a,action:t,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(i){u.listeners.push(i)}};z.T!==null?l(!0):u.isTransition=!1,n(u),l=e.pending,l===null?(u.next=e.pending=u,Uf(e,u)):(u.next=l.next,e.pending=l.next=u)}}function Uf(t,e){var l=e.action,n=e.payload,a=t.state;if(e.isTransition){var u=z.T,i={};z.T=i;try{var o=l(a,n),p=z.S;p!==null&&p(i,o),Hf(t,e,o)}catch(C){Ic(t,e,C)}finally{u!==null&&i.types!==null&&(u.types=i.types),z.T=u}}else try{u=l(a,n),Hf(t,e,u)}catch(C){Ic(t,e,C)}}function Hf(t,e,l){l!==null&&typeof l=="object"&&typeof l.then=="function"?l.then(function(n){Bf(t,e,n)},function(n){return Ic(t,e,n)}):Bf(t,e,l)}function Bf(t,e,l){e.status="fulfilled",e.value=l,qf(e),t.state=l,e=t.pending,e!==null&&(l=e.next,l===e?t.pending=null:(l=l.next,e.next=l,Uf(t,l)))}function Ic(t,e,l){var n=t.pending;if(t.pending=null,n!==null){n=n.next;do e.status="rejected",e.reason=l,qf(e),e=e.next;while(e!==n)}t.action=null}function qf(t){t=t.listeners;for(var e=0;e<t.length;e++)(0,t[e])()}function Lf(t,e){return e}function Yf(t,e){if(Ot){var l=Zt.formState;if(l!==null){t:{var n=bt;if(Ot){if(It){e:{for(var a=It,u=nl;a.nodeType!==8;){if(!u){a=null;break e}if(a=ul(a.nextSibling),a===null){a=null;break e}}u=a.data,a=u==="F!"||u==="F"?a:null}if(a){It=ul(a.nextSibling),n=a.data==="F!";break t}}fn(n)}n=!1}n&&(e=l[0])}}return l=Ne(),l.memoizedState=l.baseState=e,n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Lf,lastRenderedState:e},l.queue=n,l=ur.bind(null,bt,n),n.dispatch=l,n=Fc(!1),u=as.bind(null,bt,!1,n.queue),n=Ne(),a={state:e,dispatch:null,action:t,pending:null},n.queue=a,l=R1.bind(null,bt,a,u,l),a.dispatch=l,n.memoizedState=t,[e,l,!1]}function Gf(t){var e=se();return Xf(e,Xt,t)}function Xf(t,e,l){if(e=$c(t,e,Lf)[0],t=gi(Xl)[0],typeof e=="object"&&e!==null&&typeof e.then=="function")try{var n=du(e)}catch(i){throw i===Ma?ui:i}else n=e;e=se();var a=e.queue,u=a.dispatch;return l!==e.memoizedState&&(bt.flags|=2048,Da(9,{destroy:void 0},U1.bind(null,a,l),null)),[n,u,t]}function U1(t,e){t.action=e}function kf(t){var e=se(),l=Xt;if(l!==null)return Xf(e,l,t);se(),e=e.memoizedState,l=se();var n=l.queue.dispatch;return l.memoizedState=t,[e,n,!1]}function Da(t,e,l,n){return t={tag:t,create:l,deps:n,inst:e,next:null},e=bt.updateQueue,e===null&&(e=hi(),bt.updateQueue=e),l=e.lastEffect,l===null?e.lastEffect=t.next=t:(n=l.next,l.next=t,t.next=n,e.lastEffect=t),t}function Qf(){return se().memoizedState}function pi(t,e,l,n){var a=Ne();bt.flags|=t,a.memoizedState=Da(1|e,{destroy:void 0},l,n===void 0?null:n)}function yi(t,e,l,n){var a=se();n=n===void 0?null:n;var u=a.memoizedState.inst;Xt!==null&&n!==null&&kc(n,Xt.memoizedState.deps)?a.memoizedState=Da(e,u,l,n):(bt.flags|=t,a.memoizedState=Da(1|e,u,l,n))}function Zf(t,e){pi(8390656,8,t,e)}function Pc(t,e){yi(2048,8,t,e)}function H1(t){bt.flags|=4;var e=bt.updateQueue;if(e===null)e=hi(),bt.updateQueue=e,e.events=[t];else{var l=e.events;l===null?e.events=[t]:l.push(t)}}function Vf(t){var e=se().memoizedState;return H1({ref:e,nextImpl:t}),function(){if((Bt&2)!==0)throw Error(f(440));return e.impl.apply(void 0,arguments)}}function Kf(t,e){return yi(4,2,t,e)}function Jf(t,e){return yi(4,4,t,e)}function $f(t,e){if(typeof e=="function"){t=t();var l=e(t);return function(){typeof l=="function"?l():e(null)}}if(e!=null)return t=t(),e.current=t,function(){e.current=null}}function Wf(t,e,l){l=l!=null?l.concat([t]):null,yi(4,4,$f.bind(null,e,t),l)}function ts(){}function Ff(t,e){var l=se();e=e===void 0?null:e;var n=l.memoizedState;return e!==null&&kc(e,n[1])?n[0]:(l.memoizedState=[t,e],t)}function If(t,e){var l=se();e=e===void 0?null:e;var n=l.memoizedState;if(e!==null&&kc(e,n[1]))return n[0];if(n=t(),$n){le(!0);try{t()}finally{le(!1)}}return l.memoizedState=[n,e],n}function es(t,e,l){return l===void 0||(Gl&1073741824)!==0&&(jt&261930)===0?t.memoizedState=e:(t.memoizedState=l,t=Pr(),bt.lanes|=t,bn|=t,l)}function Pf(t,e,l,n){return ke(l,e)?l:Aa.current!==null?(t=es(t,l,n),ke(t,e)||(ge=!0),t):(Gl&42)===0||(Gl&1073741824)!==0&&(jt&261930)===0?(ge=!0,t.memoizedState=l):(t=Pr(),bt.lanes|=t,bn|=t,e)}function tr(t,e,l,n,a){var u=q.p;q.p=u!==0&&8>u?u:8;var i=z.T,o={};z.T=o,as(t,!1,e,l);try{var p=a(),C=z.S;if(C!==null&&C(o,p),p!==null&&typeof p=="object"&&typeof p.then=="function"){var w=w1(p,n);hu(t,e,w,$e(t))}else hu(t,e,n,$e(t))}catch(U){hu(t,e,{then:function(){},status:"rejected",reason:U},$e())}finally{q.p=u,i!==null&&o.types!==null&&(i.types=o.types),z.T=i}}function B1(){}function ls(t,e,l,n){if(t.tag!==5)throw Error(f(476));var a=er(t).queue;tr(t,a,e,$,l===null?B1:function(){return lr(t),l(n)})}function er(t){var e=t.memoizedState;if(e!==null)return e;e={memoizedState:$,baseState:$,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Xl,lastRenderedState:$},next:null};var l={};return e.next={memoizedState:l,baseState:l,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Xl,lastRenderedState:l},next:null},t.memoizedState=e,t=t.alternate,t!==null&&(t.memoizedState=e),e}function lr(t){var e=er(t);e.next===null&&(e=t.alternate.memoizedState),hu(t,e.next.queue,{},$e())}function ns(){return Ce(Nu)}function nr(){return se().memoizedState}function ar(){return se().memoizedState}function q1(t){for(var e=t.return;e!==null;){switch(e.tag){case 24:case 3:var l=$e();t=hn(l);var n=mn(e,t,l);n!==null&&(Ye(n,e,l),su(n,e,l)),e={cache:Oc()},t.payload=e;return}e=e.return}}function L1(t,e,l){var n=$e();l={lane:n,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null},vi(t)?ir(e,l):(l=Sc(t,e,l,n),l!==null&&(Ye(l,t,n),cr(l,e,n)))}function ur(t,e,l){var n=$e();hu(t,e,l,n)}function hu(t,e,l,n){var a={lane:n,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null};if(vi(t))ir(e,a);else{var u=t.alternate;if(t.lanes===0&&(u===null||u.lanes===0)&&(u=e.lastRenderedReducer,u!==null))try{var i=e.lastRenderedState,o=u(i,l);if(a.hasEagerState=!0,a.eagerState=o,ke(o,i))return Iu(t,e,a,0),Zt===null&&Fu(),!1}catch{}if(l=Sc(t,e,a,n),l!==null)return Ye(l,t,n),cr(l,e,n),!0}return!1}function as(t,e,l,n){if(n={lane:2,revertLane:Hs(),gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},vi(t)){if(e)throw Error(f(479))}else e=Sc(t,l,n,2),e!==null&&Ye(e,t,2)}function vi(t){var e=t.alternate;return t===bt||e!==null&&e===bt}function ir(t,e){Ta=ri=!0;var l=t.pending;l===null?e.next=e:(e.next=l.next,l.next=e),t.pending=e}function cr(t,e,l){if((l&4194048)!==0){var n=e.lanes;n&=t.pendingLanes,l|=n,e.lanes=l,Cl(t,l)}}var mu={readContext:Ce,use:mi,useCallback:ae,useContext:ae,useEffect:ae,useImperativeHandle:ae,useLayoutEffect:ae,useInsertionEffect:ae,useMemo:ae,useReducer:ae,useRef:ae,useState:ae,useDebugValue:ae,useDeferredValue:ae,useTransition:ae,useSyncExternalStore:ae,useId:ae,useHostTransitionStatus:ae,useFormState:ae,useActionState:ae,useOptimistic:ae,useMemoCache:ae,useCacheRefresh:ae};mu.useEffectEvent=ae;var sr={readContext:Ce,use:mi,useCallback:function(t,e){return Ne().memoizedState=[t,e===void 0?null:e],t},useContext:Ce,useEffect:Zf,useImperativeHandle:function(t,e,l){l=l!=null?l.concat([t]):null,pi(4194308,4,$f.bind(null,e,t),l)},useLayoutEffect:function(t,e){return pi(4194308,4,t,e)},useInsertionEffect:function(t,e){pi(4,2,t,e)},useMemo:function(t,e){var l=Ne();e=e===void 0?null:e;var n=t();if($n){le(!0);try{t()}finally{le(!1)}}return l.memoizedState=[n,e],n},useReducer:function(t,e,l){var n=Ne();if(l!==void 0){var a=l(e);if($n){le(!0);try{l(e)}finally{le(!1)}}}else a=e;return n.memoizedState=n.baseState=a,t={pending:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:a},n.queue=t,t=t.dispatch=L1.bind(null,bt,t),[n.memoizedState,t]},useRef:function(t){var e=Ne();return t={current:t},e.memoizedState=t},useState:function(t){t=Fc(t);var e=t.queue,l=ur.bind(null,bt,e);return e.dispatch=l,[t.memoizedState,l]},useDebugValue:ts,useDeferredValue:function(t,e){var l=Ne();return es(l,t,e)},useTransition:function(){var t=Fc(!1);return t=tr.bind(null,bt,t.queue,!0,!1),Ne().memoizedState=t,[!1,t]},useSyncExternalStore:function(t,e,l){var n=bt,a=Ne();if(Ot){if(l===void 0)throw Error(f(407));l=l()}else{if(l=e(),Zt===null)throw Error(f(349));(jt&127)!==0||jf(n,e,l)}a.memoizedState=l;var u={value:l,getSnapshot:e};return a.queue=u,Zf(wf.bind(null,n,u,t),[t]),n.flags|=2048,Da(9,{destroy:void 0},Nf.bind(null,n,u,l,e),null),l},useId:function(){var t=Ne(),e=Zt.identifierPrefix;if(Ot){var l=jl,n=Dl;l=(n&~(1<<32-xe(n)-1)).toString(32)+l,e="_"+e+"R_"+l,l=di++,0<l&&(e+="H"+l.toString(32)),e+="_"}else l=O1++,e="_"+e+"r_"+l.toString(32)+"_";return t.memoizedState=e},useHostTransitionStatus:ns,useFormState:Yf,useActionState:Yf,useOptimistic:function(t){var e=Ne();e.memoizedState=e.baseState=t;var l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return e.queue=l,e=as.bind(null,bt,!0,l),l.dispatch=e,[t,e]},useMemoCache:Jc,useCacheRefresh:function(){return Ne().memoizedState=q1.bind(null,bt)},useEffectEvent:function(t){var e=Ne(),l={impl:t};return e.memoizedState=l,function(){if((Bt&2)!==0)throw Error(f(440));return l.impl.apply(void 0,arguments)}}},us={readContext:Ce,use:mi,useCallback:Ff,useContext:Ce,useEffect:Pc,useImperativeHandle:Wf,useInsertionEffect:Kf,useLayoutEffect:Jf,useMemo:If,useReducer:gi,useRef:Qf,useState:function(){return gi(Xl)},useDebugValue:ts,useDeferredValue:function(t,e){var l=se();return Pf(l,Xt.memoizedState,t,e)},useTransition:function(){var t=gi(Xl)[0],e=se().memoizedState;return[typeof t=="boolean"?t:du(t),e]},useSyncExternalStore:Df,useId:nr,useHostTransitionStatus:ns,useFormState:Gf,useActionState:Gf,useOptimistic:function(t,e){var l=se();return Rf(l,Xt,t,e)},useMemoCache:Jc,useCacheRefresh:ar};us.useEffectEvent=Vf;var or={readContext:Ce,use:mi,useCallback:Ff,useContext:Ce,useEffect:Pc,useImperativeHandle:Wf,useInsertionEffect:Kf,useLayoutEffect:Jf,useMemo:If,useReducer:Wc,useRef:Qf,useState:function(){return Wc(Xl)},useDebugValue:ts,useDeferredValue:function(t,e){var l=se();return Xt===null?es(l,t,e):Pf(l,Xt.memoizedState,t,e)},useTransition:function(){var t=Wc(Xl)[0],e=se().memoizedState;return[typeof t=="boolean"?t:du(t),e]},useSyncExternalStore:Df,useId:nr,useHostTransitionStatus:ns,useFormState:kf,useActionState:kf,useOptimistic:function(t,e){var l=se();return Xt!==null?Rf(l,Xt,t,e):(l.baseState=t,[t,l.queue.dispatch])},useMemoCache:Jc,useCacheRefresh:ar};or.useEffectEvent=Vf;function is(t,e,l,n){e=t.memoizedState,l=l(n,e),l=l==null?e:H({},e,l),t.memoizedState=l,t.lanes===0&&(t.updateQueue.baseState=l)}var cs={enqueueSetState:function(t,e,l){t=t._reactInternals;var n=$e(),a=hn(n);a.payload=e,l!=null&&(a.callback=l),e=mn(t,a,n),e!==null&&(Ye(e,t,n),su(e,t,n))},enqueueReplaceState:function(t,e,l){t=t._reactInternals;var n=$e(),a=hn(n);a.tag=1,a.payload=e,l!=null&&(a.callback=l),e=mn(t,a,n),e!==null&&(Ye(e,t,n),su(e,t,n))},enqueueForceUpdate:function(t,e){t=t._reactInternals;var l=$e(),n=hn(l);n.tag=2,e!=null&&(n.callback=e),e=mn(t,n,l),e!==null&&(Ye(e,t,l),su(e,t,l))}};function fr(t,e,l,n,a,u,i){return t=t.stateNode,typeof t.shouldComponentUpdate=="function"?t.shouldComponentUpdate(n,u,i):e.prototype&&e.prototype.isPureReactComponent?!tu(l,n)||!tu(a,u):!0}function rr(t,e,l,n){t=e.state,typeof e.componentWillReceiveProps=="function"&&e.componentWillReceiveProps(l,n),typeof e.UNSAFE_componentWillReceiveProps=="function"&&e.UNSAFE_componentWillReceiveProps(l,n),e.state!==t&&cs.enqueueReplaceState(e,e.state,null)}function Wn(t,e){var l=e;if("ref"in e){l={};for(var n in e)n!=="ref"&&(l[n]=e[n])}if(t=t.defaultProps){l===e&&(l=H({},l));for(var a in t)l[a]===void 0&&(l[a]=t[a])}return l}function dr(t){Wu(t)}function hr(t){console.error(t)}function mr(t){Wu(t)}function bi(t,e){try{var l=t.onUncaughtError;l(e.value,{componentStack:e.stack})}catch(n){setTimeout(function(){throw n})}}function gr(t,e,l){try{var n=t.onCaughtError;n(l.value,{componentStack:l.stack,errorBoundary:e.tag===1?e.stateNode:null})}catch(a){setTimeout(function(){throw a})}}function ss(t,e,l){return l=hn(l),l.tag=3,l.payload={element:null},l.callback=function(){bi(t,e)},l}function pr(t){return t=hn(t),t.tag=3,t}function yr(t,e,l,n){var a=l.type.getDerivedStateFromError;if(typeof a=="function"){var u=n.value;t.payload=function(){return a(u)},t.callback=function(){gr(e,l,n)}}var i=l.stateNode;i!==null&&typeof i.componentDidCatch=="function"&&(t.callback=function(){gr(e,l,n),typeof a!="function"&&(xn===null?xn=new Set([this]):xn.add(this));var o=n.stack;this.componentDidCatch(n.value,{componentStack:o!==null?o:""})})}function Y1(t,e,l,n,a){if(l.flags|=32768,n!==null&&typeof n=="object"&&typeof n.then=="function"){if(e=l.alternate,e!==null&&xa(e,l,a,!0),l=Ze.current,l!==null){switch(l.tag){case 31:case 13:return al===null?wi():l.alternate===null&&ue===0&&(ue=3),l.flags&=-257,l.flags|=65536,l.lanes=a,n===ii?l.flags|=16384:(e=l.updateQueue,e===null?l.updateQueue=new Set([n]):e.add(n),_s(t,n,a)),!1;case 22:return l.flags|=65536,n===ii?l.flags|=16384:(e=l.updateQueue,e===null?(e={transitions:null,markerInstances:null,retryQueue:new Set([n])},l.updateQueue=e):(l=e.retryQueue,l===null?e.retryQueue=new Set([n]):l.add(n)),_s(t,n,a)),!1}throw Error(f(435,l.tag))}return _s(t,n,a),wi(),!1}if(Ot)return e=Ze.current,e!==null?((e.flags&65536)===0&&(e.flags|=256),e.flags|=65536,e.lanes=a,n!==zc&&(t=Error(f(422),{cause:n}),nu(tl(t,l)))):(n!==zc&&(e=Error(f(423),{cause:n}),nu(tl(e,l))),t=t.current.alternate,t.flags|=65536,a&=-a,t.lanes|=a,n=tl(n,l),a=ss(t.stateNode,n,a),qc(t,a),ue!==4&&(ue=2)),!1;var u=Error(f(520),{cause:n});if(u=tl(u,l),Eu===null?Eu=[u]:Eu.push(u),ue!==4&&(ue=2),e===null)return!0;n=tl(n,l),l=e;do{switch(l.tag){case 3:return l.flags|=65536,t=a&-a,l.lanes|=t,t=ss(l.stateNode,n,t),qc(l,t),!1;case 1:if(e=l.type,u=l.stateNode,(l.flags&128)===0&&(typeof e.getDerivedStateFromError=="function"||u!==null&&typeof u.componentDidCatch=="function"&&(xn===null||!xn.has(u))))return l.flags|=65536,a&=-a,l.lanes|=a,a=pr(a),yr(a,t,l,n),qc(l,a),!1}l=l.return}while(l!==null);return!1}var os=Error(f(461)),ge=!1;function Ae(t,e,l,n){e.child=t===null?Sf(e,null,l,n):Jn(e,t.child,l,n)}function vr(t,e,l,n,a){l=l.render;var u=e.ref;if("ref"in n){var i={};for(var o in n)o!=="ref"&&(i[o]=n[o])}else i=n;return Qn(e),n=Qc(t,e,l,i,u,a),o=Zc(),t!==null&&!ge?(Vc(t,e,a),kl(t,e,a)):(Ot&&o&&Ac(e),e.flags|=1,Ae(t,e,n,a),e.child)}function br(t,e,l,n,a){if(t===null){var u=l.type;return typeof u=="function"&&!Ec(u)&&u.defaultProps===void 0&&l.compare===null?(e.tag=15,e.type=u,xr(t,e,u,n,a)):(t=ti(l.type,null,n,e,e.mode,a),t.ref=e.ref,t.return=e,e.child=t)}if(u=t.child,!ys(t,a)){var i=u.memoizedProps;if(l=l.compare,l=l!==null?l:tu,l(i,n)&&t.ref===e.ref)return kl(t,e,a)}return e.flags|=1,t=Bl(u,n),t.ref=e.ref,t.return=e,e.child=t}function xr(t,e,l,n,a){if(t!==null){var u=t.memoizedProps;if(tu(u,n)&&t.ref===e.ref)if(ge=!1,e.pendingProps=n=u,ys(t,a))(t.flags&131072)!==0&&(ge=!0);else return e.lanes=t.lanes,kl(t,e,a)}return fs(t,e,l,n,a)}function Sr(t,e,l,n){var a=n.children,u=t!==null?t.memoizedState:null;if(t===null&&e.stateNode===null&&(e.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),n.mode==="hidden"){if((e.flags&128)!==0){if(u=u!==null?u.baseLanes|l:l,t!==null){for(n=e.child=t.child,a=0;n!==null;)a=a|n.lanes|n.childLanes,n=n.sibling;n=a&~u}else n=0,e.child=null;return Er(t,e,u,l,n)}if((l&536870912)!==0)e.memoizedState={baseLanes:0,cachePool:null},t!==null&&ai(e,u!==null?u.cachePool:null),u!==null?Cf(e,u):Yc(),Af(e);else return n=e.lanes=536870912,Er(t,e,u!==null?u.baseLanes|l:l,l,n)}else u!==null?(ai(e,u.cachePool),Cf(e,u),pn(),e.memoizedState=null):(t!==null&&ai(e,null),Yc(),pn());return Ae(t,e,a,l),e.child}function gu(t,e){return t!==null&&t.tag===22||e.stateNode!==null||(e.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),e.sibling}function Er(t,e,l,n,a){var u=Rc();return u=u===null?null:{parent:he._currentValue,pool:u},e.memoizedState={baseLanes:l,cachePool:u},t!==null&&ai(e,null),Yc(),Af(e),t!==null&&xa(t,e,n,!0),e.childLanes=a,null}function xi(t,e){return e=Ei({mode:e.mode,children:e.children},t.mode),e.ref=t.ref,t.child=e,e.return=t,e}function Mr(t,e,l){return Jn(e,t.child,null,l),t=xi(e,e.pendingProps),t.flags|=2,Ve(e),e.memoizedState=null,t}function G1(t,e,l){var n=e.pendingProps,a=(e.flags&128)!==0;if(e.flags&=-129,t===null){if(Ot){if(n.mode==="hidden")return t=xi(e,n),e.lanes=536870912,gu(null,t);if(Xc(e),(t=It)?(t=Ud(t,nl),t=t!==null&&t.data==="&"?t:null,t!==null&&(e.memoizedState={dehydrated:t,treeContext:sn!==null?{id:Dl,overflow:jl}:null,retryLane:536870912,hydrationErrors:null},l=uf(t),l.return=e,e.child=l,Me=e,It=null)):t=null,t===null)throw fn(e);return e.lanes=536870912,null}return xi(e,n)}var u=t.memoizedState;if(u!==null){var i=u.dehydrated;if(Xc(e),a)if(e.flags&256)e.flags&=-257,e=Mr(t,e,l);else if(e.memoizedState!==null)e.child=t.child,e.flags|=128,e=null;else throw Error(f(558));else if(ge||xa(t,e,l,!1),a=(l&t.childLanes)!==0,ge||a){if(n=Zt,n!==null&&(i=qu(n,l),i!==0&&i!==u.retryLane))throw u.retryLane=i,Yn(t,i),Ye(n,t,i),os;wi(),e=Mr(t,e,l)}else t=u.treeContext,It=ul(i.nextSibling),Me=e,Ot=!0,on=null,nl=!1,t!==null&&of(e,t),e=xi(e,n),e.flags|=4096;return e}return t=Bl(t.child,{mode:n.mode,children:n.children}),t.ref=e.ref,e.child=t,t.return=e,t}function Si(t,e){var l=e.ref;if(l===null)t!==null&&t.ref!==null&&(e.flags|=4194816);else{if(typeof l!="function"&&typeof l!="object")throw Error(f(284));(t===null||t.ref!==l)&&(e.flags|=4194816)}}function fs(t,e,l,n,a){return Qn(e),l=Qc(t,e,l,n,void 0,a),n=Zc(),t!==null&&!ge?(Vc(t,e,a),kl(t,e,a)):(Ot&&n&&Ac(e),e.flags|=1,Ae(t,e,l,a),e.child)}function Cr(t,e,l,n,a,u){return Qn(e),e.updateQueue=null,l=zf(e,n,l,a),Tf(t),n=Zc(),t!==null&&!ge?(Vc(t,e,u),kl(t,e,u)):(Ot&&n&&Ac(e),e.flags|=1,Ae(t,e,l,u),e.child)}function Ar(t,e,l,n,a){if(Qn(e),e.stateNode===null){var u=pa,i=l.contextType;typeof i=="object"&&i!==null&&(u=Ce(i)),u=new l(n,u),e.memoizedState=u.state!==null&&u.state!==void 0?u.state:null,u.updater=cs,e.stateNode=u,u._reactInternals=e,u=e.stateNode,u.props=n,u.state=e.memoizedState,u.refs={},Hc(e),i=l.contextType,u.context=typeof i=="object"&&i!==null?Ce(i):pa,u.state=e.memoizedState,i=l.getDerivedStateFromProps,typeof i=="function"&&(is(e,l,i,n),u.state=e.memoizedState),typeof l.getDerivedStateFromProps=="function"||typeof u.getSnapshotBeforeUpdate=="function"||typeof u.UNSAFE_componentWillMount!="function"&&typeof u.componentWillMount!="function"||(i=u.state,typeof u.componentWillMount=="function"&&u.componentWillMount(),typeof u.UNSAFE_componentWillMount=="function"&&u.UNSAFE_componentWillMount(),i!==u.state&&cs.enqueueReplaceState(u,u.state,null),fu(e,n,u,a),ou(),u.state=e.memoizedState),typeof u.componentDidMount=="function"&&(e.flags|=4194308),n=!0}else if(t===null){u=e.stateNode;var o=e.memoizedProps,p=Wn(l,o);u.props=p;var C=u.context,w=l.contextType;i=pa,typeof w=="object"&&w!==null&&(i=Ce(w));var U=l.getDerivedStateFromProps;w=typeof U=="function"||typeof u.getSnapshotBeforeUpdate=="function",o=e.pendingProps!==o,w||typeof u.UNSAFE_componentWillReceiveProps!="function"&&typeof u.componentWillReceiveProps!="function"||(o||C!==i)&&rr(e,u,n,i),dn=!1;var T=e.memoizedState;u.state=T,fu(e,n,u,a),ou(),C=e.memoizedState,o||T!==C||dn?(typeof U=="function"&&(is(e,l,U,n),C=e.memoizedState),(p=dn||fr(e,l,p,n,T,C,i))?(w||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"&&(e.flags|=4194308)):(typeof u.componentDidMount=="function"&&(e.flags|=4194308),e.memoizedProps=n,e.memoizedState=C),u.props=n,u.state=C,u.context=i,n=p):(typeof u.componentDidMount=="function"&&(e.flags|=4194308),n=!1)}else{u=e.stateNode,Bc(t,e),i=e.memoizedProps,w=Wn(l,i),u.props=w,U=e.pendingProps,T=u.context,C=l.contextType,p=pa,typeof C=="object"&&C!==null&&(p=Ce(C)),o=l.getDerivedStateFromProps,(C=typeof o=="function"||typeof u.getSnapshotBeforeUpdate=="function")||typeof u.UNSAFE_componentWillReceiveProps!="function"&&typeof u.componentWillReceiveProps!="function"||(i!==U||T!==p)&&rr(e,u,n,p),dn=!1,T=e.memoizedState,u.state=T,fu(e,n,u,a),ou();var j=e.memoizedState;i!==U||T!==j||dn||t!==null&&t.dependencies!==null&&li(t.dependencies)?(typeof o=="function"&&(is(e,l,o,n),j=e.memoizedState),(w=dn||fr(e,l,w,n,T,j,p)||t!==null&&t.dependencies!==null&&li(t.dependencies))?(C||typeof u.UNSAFE_componentWillUpdate!="function"&&typeof u.componentWillUpdate!="function"||(typeof u.componentWillUpdate=="function"&&u.componentWillUpdate(n,j,p),typeof u.UNSAFE_componentWillUpdate=="function"&&u.UNSAFE_componentWillUpdate(n,j,p)),typeof u.componentDidUpdate=="function"&&(e.flags|=4),typeof u.getSnapshotBeforeUpdate=="function"&&(e.flags|=1024)):(typeof u.componentDidUpdate!="function"||i===t.memoizedProps&&T===t.memoizedState||(e.flags|=4),typeof u.getSnapshotBeforeUpdate!="function"||i===t.memoizedProps&&T===t.memoizedState||(e.flags|=1024),e.memoizedProps=n,e.memoizedState=j),u.props=n,u.state=j,u.context=p,n=w):(typeof u.componentDidUpdate!="function"||i===t.memoizedProps&&T===t.memoizedState||(e.flags|=4),typeof u.getSnapshotBeforeUpdate!="function"||i===t.memoizedProps&&T===t.memoizedState||(e.flags|=1024),n=!1)}return u=n,Si(t,e),n=(e.flags&128)!==0,u||n?(u=e.stateNode,l=n&&typeof l.getDerivedStateFromError!="function"?null:u.render(),e.flags|=1,t!==null&&n?(e.child=Jn(e,t.child,null,a),e.child=Jn(e,null,l,a)):Ae(t,e,l,a),e.memoizedState=u.state,t=e.child):t=kl(t,e,a),t}function Tr(t,e,l,n){return Xn(),e.flags|=256,Ae(t,e,l,n),e.child}var rs={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function ds(t){return{baseLanes:t,cachePool:gf()}}function hs(t,e,l){return t=t!==null?t.childLanes&~l:0,e&&(t|=Je),t}function zr(t,e,l){var n=e.pendingProps,a=!1,u=(e.flags&128)!==0,i;if((i=u)||(i=t!==null&&t.memoizedState===null?!1:(ce.current&2)!==0),i&&(a=!0,e.flags&=-129),i=(e.flags&32)!==0,e.flags&=-33,t===null){if(Ot){if(a?gn(e):pn(),(t=It)?(t=Ud(t,nl),t=t!==null&&t.data!=="&"?t:null,t!==null&&(e.memoizedState={dehydrated:t,treeContext:sn!==null?{id:Dl,overflow:jl}:null,retryLane:536870912,hydrationErrors:null},l=uf(t),l.return=e,e.child=l,Me=e,It=null)):t=null,t===null)throw fn(e);return $s(t)?e.lanes=32:e.lanes=536870912,null}var o=n.children;return n=n.fallback,a?(pn(),a=e.mode,o=Ei({mode:"hidden",children:o},a),n=Gn(n,a,l,null),o.return=e,n.return=e,o.sibling=n,e.child=o,n=e.child,n.memoizedState=ds(l),n.childLanes=hs(t,i,l),e.memoizedState=rs,gu(null,n)):(gn(e),ms(e,o))}var p=t.memoizedState;if(p!==null&&(o=p.dehydrated,o!==null)){if(u)e.flags&256?(gn(e),e.flags&=-257,e=gs(t,e,l)):e.memoizedState!==null?(pn(),e.child=t.child,e.flags|=128,e=null):(pn(),o=n.fallback,a=e.mode,n=Ei({mode:"visible",children:n.children},a),o=Gn(o,a,l,null),o.flags|=2,n.return=e,o.return=e,n.sibling=o,e.child=n,Jn(e,t.child,null,l),n=e.child,n.memoizedState=ds(l),n.childLanes=hs(t,i,l),e.memoizedState=rs,e=gu(null,n));else if(gn(e),$s(o)){if(i=o.nextSibling&&o.nextSibling.dataset,i)var C=i.dgst;i=C,n=Error(f(419)),n.stack="",n.digest=i,nu({value:n,source:null,stack:null}),e=gs(t,e,l)}else if(ge||xa(t,e,l,!1),i=(l&t.childLanes)!==0,ge||i){if(i=Zt,i!==null&&(n=qu(i,l),n!==0&&n!==p.retryLane))throw p.retryLane=n,Yn(t,n),Ye(i,t,n),os;Js(o)||wi(),e=gs(t,e,l)}else Js(o)?(e.flags|=192,e.child=t.child,e=null):(t=p.treeContext,It=ul(o.nextSibling),Me=e,Ot=!0,on=null,nl=!1,t!==null&&of(e,t),e=ms(e,n.children),e.flags|=4096);return e}return a?(pn(),o=n.fallback,a=e.mode,p=t.child,C=p.sibling,n=Bl(p,{mode:"hidden",children:n.children}),n.subtreeFlags=p.subtreeFlags&65011712,C!==null?o=Bl(C,o):(o=Gn(o,a,l,null),o.flags|=2),o.return=e,n.return=e,n.sibling=o,e.child=n,gu(null,n),n=e.child,o=t.child.memoizedState,o===null?o=ds(l):(a=o.cachePool,a!==null?(p=he._currentValue,a=a.parent!==p?{parent:p,pool:p}:a):a=gf(),o={baseLanes:o.baseLanes|l,cachePool:a}),n.memoizedState=o,n.childLanes=hs(t,i,l),e.memoizedState=rs,gu(t.child,n)):(gn(e),l=t.child,t=l.sibling,l=Bl(l,{mode:"visible",children:n.children}),l.return=e,l.sibling=null,t!==null&&(i=e.deletions,i===null?(e.deletions=[t],e.flags|=16):i.push(t)),e.child=l,e.memoizedState=null,l)}function ms(t,e){return e=Ei({mode:"visible",children:e},t.mode),e.return=t,t.child=e}function Ei(t,e){return t=Qe(22,t,null,e),t.lanes=0,t}function gs(t,e,l){return Jn(e,t.child,null,l),t=ms(e,e.pendingProps.children),t.flags|=2,e.memoizedState=null,t}function Dr(t,e,l){t.lanes|=e;var n=t.alternate;n!==null&&(n.lanes|=e),Nc(t.return,e,l)}function ps(t,e,l,n,a,u){var i=t.memoizedState;i===null?t.memoizedState={isBackwards:e,rendering:null,renderingStartTime:0,last:n,tail:l,tailMode:a,treeForkCount:u}:(i.isBackwards=e,i.rendering=null,i.renderingStartTime=0,i.last=n,i.tail=l,i.tailMode=a,i.treeForkCount=u)}function jr(t,e,l){var n=e.pendingProps,a=n.revealOrder,u=n.tail;n=n.children;var i=ce.current,o=(i&2)!==0;if(o?(i=i&1|2,e.flags|=128):i&=1,k(ce,i),Ae(t,e,n,l),n=Ot?lu:0,!o&&t!==null&&(t.flags&128)!==0)t:for(t=e.child;t!==null;){if(t.tag===13)t.memoizedState!==null&&Dr(t,l,e);else if(t.tag===19)Dr(t,l,e);else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break t;for(;t.sibling===null;){if(t.return===null||t.return===e)break t;t=t.return}t.sibling.return=t.return,t=t.sibling}switch(a){case"forwards":for(l=e.child,a=null;l!==null;)t=l.alternate,t!==null&&fi(t)===null&&(a=l),l=l.sibling;l=a,l===null?(a=e.child,e.child=null):(a=l.sibling,l.sibling=null),ps(e,!1,a,l,u,n);break;case"backwards":case"unstable_legacy-backwards":for(l=null,a=e.child,e.child=null;a!==null;){if(t=a.alternate,t!==null&&fi(t)===null){e.child=a;break}t=a.sibling,a.sibling=l,l=a,a=t}ps(e,!0,l,null,u,n);break;case"together":ps(e,!1,null,null,void 0,n);break;default:e.memoizedState=null}return e.child}function kl(t,e,l){if(t!==null&&(e.dependencies=t.dependencies),bn|=e.lanes,(l&e.childLanes)===0)if(t!==null){if(xa(t,e,l,!1),(l&e.childLanes)===0)return null}else return null;if(t!==null&&e.child!==t.child)throw Error(f(153));if(e.child!==null){for(t=e.child,l=Bl(t,t.pendingProps),e.child=l,l.return=e;t.sibling!==null;)t=t.sibling,l=l.sibling=Bl(t,t.pendingProps),l.return=e;l.sibling=null}return e.child}function ys(t,e){return(t.lanes&e)!==0?!0:(t=t.dependencies,!!(t!==null&&li(t)))}function X1(t,e,l){switch(e.tag){case 3:Vt(e,e.stateNode.containerInfo),rn(e,he,t.memoizedState.cache),Xn();break;case 27:case 5:Oe(e);break;case 4:Vt(e,e.stateNode.containerInfo);break;case 10:rn(e,e.type,e.memoizedProps.value);break;case 31:if(e.memoizedState!==null)return e.flags|=128,Xc(e),null;break;case 13:var n=e.memoizedState;if(n!==null)return n.dehydrated!==null?(gn(e),e.flags|=128,null):(l&e.child.childLanes)!==0?zr(t,e,l):(gn(e),t=kl(t,e,l),t!==null?t.sibling:null);gn(e);break;case 19:var a=(t.flags&128)!==0;if(n=(l&e.childLanes)!==0,n||(xa(t,e,l,!1),n=(l&e.childLanes)!==0),a){if(n)return jr(t,e,l);e.flags|=128}if(a=e.memoizedState,a!==null&&(a.rendering=null,a.tail=null,a.lastEffect=null),k(ce,ce.current),n)break;return null;case 22:return e.lanes=0,Sr(t,e,l,e.pendingProps);case 24:rn(e,he,t.memoizedState.cache)}return kl(t,e,l)}function Nr(t,e,l){if(t!==null)if(t.memoizedProps!==e.pendingProps)ge=!0;else{if(!ys(t,l)&&(e.flags&128)===0)return ge=!1,X1(t,e,l);ge=(t.flags&131072)!==0}else ge=!1,Ot&&(e.flags&1048576)!==0&&sf(e,lu,e.index);switch(e.lanes=0,e.tag){case 16:t:{var n=e.pendingProps;if(t=Vn(e.elementType),e.type=t,typeof t=="function")Ec(t)?(n=Wn(t,n),e.tag=1,e=Ar(null,e,t,n,l)):(e.tag=0,e=fs(null,e,t,n,l));else{if(t!=null){var a=t.$$typeof;if(a===et){e.tag=11,e=vr(null,e,t,n,l);break t}else if(a===J){e.tag=14,e=br(null,e,t,n,l);break t}}throw e=pt(t)||t,Error(f(306,e,""))}}return e;case 0:return fs(t,e,e.type,e.pendingProps,l);case 1:return n=e.type,a=Wn(n,e.pendingProps),Ar(t,e,n,a,l);case 3:t:{if(Vt(e,e.stateNode.containerInfo),t===null)throw Error(f(387));n=e.pendingProps;var u=e.memoizedState;a=u.element,Bc(t,e),fu(e,n,null,l);var i=e.memoizedState;if(n=i.cache,rn(e,he,n),n!==u.cache&&wc(e,[he],l,!0),ou(),n=i.element,u.isDehydrated)if(u={element:n,isDehydrated:!1,cache:i.cache},e.updateQueue.baseState=u,e.memoizedState=u,e.flags&256){e=Tr(t,e,n,l);break t}else if(n!==a){a=tl(Error(f(424)),e),nu(a),e=Tr(t,e,n,l);break t}else for(t=e.stateNode.containerInfo,t.nodeType===9?t=t.body:t=t.nodeName==="HTML"?t.ownerDocument.body:t,It=ul(t.firstChild),Me=e,Ot=!0,on=null,nl=!0,l=Sf(e,null,n,l),e.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling;else{if(Xn(),n===a){e=kl(t,e,l);break t}Ae(t,e,n,l)}e=e.child}return e;case 26:return Si(t,e),t===null?(l=Gd(e.type,null,e.pendingProps,null))?e.memoizedState=l:Ot||(l=e.type,t=e.pendingProps,n=qi(ft.current).createElement(l),n[fe]=e,n[ze]=t,Te(n,l,t),re(n),e.stateNode=n):e.memoizedState=Gd(e.type,t.memoizedProps,e.pendingProps,t.memoizedState),null;case 27:return Oe(e),t===null&&Ot&&(n=e.stateNode=qd(e.type,e.pendingProps,ft.current),Me=e,nl=!0,a=It,Cn(e.type)?(Ws=a,It=ul(n.firstChild)):It=a),Ae(t,e,e.pendingProps.children,l),Si(t,e),t===null&&(e.flags|=4194304),e.child;case 5:return t===null&&Ot&&((a=n=It)&&(n=vh(n,e.type,e.pendingProps,nl),n!==null?(e.stateNode=n,Me=e,It=ul(n.firstChild),nl=!1,a=!0):a=!1),a||fn(e)),Oe(e),a=e.type,u=e.pendingProps,i=t!==null?t.memoizedProps:null,n=u.children,Zs(a,u)?n=null:i!==null&&Zs(a,i)&&(e.flags|=32),e.memoizedState!==null&&(a=Qc(t,e,_1,null,null,l),Nu._currentValue=a),Si(t,e),Ae(t,e,n,l),e.child;case 6:return t===null&&Ot&&((t=l=It)&&(l=bh(l,e.pendingProps,nl),l!==null?(e.stateNode=l,Me=e,It=null,t=!0):t=!1),t||fn(e)),null;case 13:return zr(t,e,l);case 4:return Vt(e,e.stateNode.containerInfo),n=e.pendingProps,t===null?e.child=Jn(e,null,n,l):Ae(t,e,n,l),e.child;case 11:return vr(t,e,e.type,e.pendingProps,l);case 7:return Ae(t,e,e.pendingProps,l),e.child;case 8:return Ae(t,e,e.pendingProps.children,l),e.child;case 12:return Ae(t,e,e.pendingProps.children,l),e.child;case 10:return n=e.pendingProps,rn(e,e.type,n.value),Ae(t,e,n.children,l),e.child;case 9:return a=e.type._context,n=e.pendingProps.children,Qn(e),a=Ce(a),n=n(a),e.flags|=1,Ae(t,e,n,l),e.child;case 14:return br(t,e,e.type,e.pendingProps,l);case 15:return xr(t,e,e.type,e.pendingProps,l);case 19:return jr(t,e,l);case 31:return G1(t,e,l);case 22:return Sr(t,e,l,e.pendingProps);case 24:return Qn(e),n=Ce(he),t===null?(a=Rc(),a===null&&(a=Zt,u=Oc(),a.pooledCache=u,u.refCount++,u!==null&&(a.pooledCacheLanes|=l),a=u),e.memoizedState={parent:n,cache:a},Hc(e),rn(e,he,a)):((t.lanes&l)!==0&&(Bc(t,e),fu(e,null,null,l),ou()),a=t.memoizedState,u=e.memoizedState,a.parent!==n?(a={parent:n,cache:n},e.memoizedState=a,e.lanes===0&&(e.memoizedState=e.updateQueue.baseState=a),rn(e,he,n)):(n=u.cache,rn(e,he,n),n!==a.cache&&wc(e,[he],l,!0))),Ae(t,e,e.pendingProps.children,l),e.child;case 29:throw e.pendingProps}throw Error(f(156,e.tag))}function Ql(t){t.flags|=4}function vs(t,e,l,n,a){if((e=(t.mode&32)!==0)&&(e=!1),e){if(t.flags|=16777216,(a&335544128)===a)if(t.stateNode.complete)t.flags|=8192;else if(nd())t.flags|=8192;else throw Kn=ii,Uc}else t.flags&=-16777217}function wr(t,e){if(e.type!=="stylesheet"||(e.state.loading&4)!==0)t.flags&=-16777217;else if(t.flags|=16777216,!Vd(e))if(nd())t.flags|=8192;else throw Kn=ii,Uc}function Mi(t,e){e!==null&&(t.flags|=4),t.flags&16384&&(e=t.tag!==22?Ee():536870912,t.lanes|=e,Oa|=e)}function pu(t,e){if(!Ot)switch(t.tailMode){case"hidden":e=t.tail;for(var l=null;e!==null;)e.alternate!==null&&(l=e),e=e.sibling;l===null?t.tail=null:l.sibling=null;break;case"collapsed":l=t.tail;for(var n=null;l!==null;)l.alternate!==null&&(n=l),l=l.sibling;n===null?e||t.tail===null?t.tail=null:t.tail.sibling=null:n.sibling=null}}function Pt(t){var e=t.alternate!==null&&t.alternate.child===t.child,l=0,n=0;if(e)for(var a=t.child;a!==null;)l|=a.lanes|a.childLanes,n|=a.subtreeFlags&65011712,n|=a.flags&65011712,a.return=t,a=a.sibling;else for(a=t.child;a!==null;)l|=a.lanes|a.childLanes,n|=a.subtreeFlags,n|=a.flags,a.return=t,a=a.sibling;return t.subtreeFlags|=n,t.childLanes=l,e}function k1(t,e,l){var n=e.pendingProps;switch(Tc(e),e.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Pt(e),null;case 1:return Pt(e),null;case 3:return l=e.stateNode,n=null,t!==null&&(n=t.memoizedState.cache),e.memoizedState.cache!==n&&(e.flags|=2048),Yl(he),wt(),l.pendingContext&&(l.context=l.pendingContext,l.pendingContext=null),(t===null||t.child===null)&&(ba(e)?Ql(e):t===null||t.memoizedState.isDehydrated&&(e.flags&256)===0||(e.flags|=1024,Dc())),Pt(e),null;case 26:var a=e.type,u=e.memoizedState;return t===null?(Ql(e),u!==null?(Pt(e),wr(e,u)):(Pt(e),vs(e,a,null,n,l))):u?u!==t.memoizedState?(Ql(e),Pt(e),wr(e,u)):(Pt(e),e.flags&=-16777217):(t=t.memoizedProps,t!==n&&Ql(e),Pt(e),vs(e,a,t,n,l)),null;case 27:if(xl(e),l=ft.current,a=e.type,t!==null&&e.stateNode!=null)t.memoizedProps!==n&&Ql(e);else{if(!n){if(e.stateNode===null)throw Error(f(166));return Pt(e),null}t=V.current,ba(e)?ff(e):(t=qd(a,n,l),e.stateNode=t,Ql(e))}return Pt(e),null;case 5:if(xl(e),a=e.type,t!==null&&e.stateNode!=null)t.memoizedProps!==n&&Ql(e);else{if(!n){if(e.stateNode===null)throw Error(f(166));return Pt(e),null}if(u=V.current,ba(e))ff(e);else{var i=qi(ft.current);switch(u){case 1:u=i.createElementNS("http://www.w3.org/2000/svg",a);break;case 2:u=i.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;default:switch(a){case"svg":u=i.createElementNS("http://www.w3.org/2000/svg",a);break;case"math":u=i.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;case"script":u=i.createElement("div"),u.innerHTML="<script><\/script>",u=u.removeChild(u.firstChild);break;case"select":u=typeof n.is=="string"?i.createElement("select",{is:n.is}):i.createElement("select"),n.multiple?u.multiple=!0:n.size&&(u.size=n.size);break;default:u=typeof n.is=="string"?i.createElement(a,{is:n.is}):i.createElement(a)}}u[fe]=e,u[ze]=n;t:for(i=e.child;i!==null;){if(i.tag===5||i.tag===6)u.appendChild(i.stateNode);else if(i.tag!==4&&i.tag!==27&&i.child!==null){i.child.return=i,i=i.child;continue}if(i===e)break t;for(;i.sibling===null;){if(i.return===null||i.return===e)break t;i=i.return}i.sibling.return=i.return,i=i.sibling}e.stateNode=u;t:switch(Te(u,a,n),a){case"button":case"input":case"select":case"textarea":n=!!n.autoFocus;break t;case"img":n=!0;break t;default:n=!1}n&&Ql(e)}}return Pt(e),vs(e,e.type,t===null?null:t.memoizedProps,e.pendingProps,l),null;case 6:if(t&&e.stateNode!=null)t.memoizedProps!==n&&Ql(e);else{if(typeof n!="string"&&e.stateNode===null)throw Error(f(166));if(t=ft.current,ba(e)){if(t=e.stateNode,l=e.memoizedProps,n=null,a=Me,a!==null)switch(a.tag){case 27:case 5:n=a.memoizedProps}t[fe]=e,t=!!(t.nodeValue===l||n!==null&&n.suppressHydrationWarning===!0||zd(t.nodeValue,l)),t||fn(e,!0)}else t=qi(t).createTextNode(n),t[fe]=e,e.stateNode=t}return Pt(e),null;case 31:if(l=e.memoizedState,t===null||t.memoizedState!==null){if(n=ba(e),l!==null){if(t===null){if(!n)throw Error(f(318));if(t=e.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(f(557));t[fe]=e}else Xn(),(e.flags&128)===0&&(e.memoizedState=null),e.flags|=4;Pt(e),t=!1}else l=Dc(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=l),t=!0;if(!t)return e.flags&256?(Ve(e),e):(Ve(e),null);if((e.flags&128)!==0)throw Error(f(558))}return Pt(e),null;case 13:if(n=e.memoizedState,t===null||t.memoizedState!==null&&t.memoizedState.dehydrated!==null){if(a=ba(e),n!==null&&n.dehydrated!==null){if(t===null){if(!a)throw Error(f(318));if(a=e.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(f(317));a[fe]=e}else Xn(),(e.flags&128)===0&&(e.memoizedState=null),e.flags|=4;Pt(e),a=!1}else a=Dc(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=a),a=!0;if(!a)return e.flags&256?(Ve(e),e):(Ve(e),null)}return Ve(e),(e.flags&128)!==0?(e.lanes=l,e):(l=n!==null,t=t!==null&&t.memoizedState!==null,l&&(n=e.child,a=null,n.alternate!==null&&n.alternate.memoizedState!==null&&n.alternate.memoizedState.cachePool!==null&&(a=n.alternate.memoizedState.cachePool.pool),u=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(u=n.memoizedState.cachePool.pool),u!==a&&(n.flags|=2048)),l!==t&&l&&(e.child.flags|=8192),Mi(e,e.updateQueue),Pt(e),null);case 4:return wt(),t===null&&Ys(e.stateNode.containerInfo),Pt(e),null;case 10:return Yl(e.type),Pt(e),null;case 19:if(N(ce),n=e.memoizedState,n===null)return Pt(e),null;if(a=(e.flags&128)!==0,u=n.rendering,u===null)if(a)pu(n,!1);else{if(ue!==0||t!==null&&(t.flags&128)!==0)for(t=e.child;t!==null;){if(u=fi(t),u!==null){for(e.flags|=128,pu(n,!1),t=u.updateQueue,e.updateQueue=t,Mi(e,t),e.subtreeFlags=0,t=l,l=e.child;l!==null;)af(l,t),l=l.sibling;return k(ce,ce.current&1|2),Ot&&ql(e,n.treeForkCount),e.child}t=t.sibling}n.tail!==null&&ye()>Di&&(e.flags|=128,a=!0,pu(n,!1),e.lanes=4194304)}else{if(!a)if(t=fi(u),t!==null){if(e.flags|=128,a=!0,t=t.updateQueue,e.updateQueue=t,Mi(e,t),pu(n,!0),n.tail===null&&n.tailMode==="hidden"&&!u.alternate&&!Ot)return Pt(e),null}else 2*ye()-n.renderingStartTime>Di&&l!==536870912&&(e.flags|=128,a=!0,pu(n,!1),e.lanes=4194304);n.isBackwards?(u.sibling=e.child,e.child=u):(t=n.last,t!==null?t.sibling=u:e.child=u,n.last=u)}return n.tail!==null?(t=n.tail,n.rendering=t,n.tail=t.sibling,n.renderingStartTime=ye(),t.sibling=null,l=ce.current,k(ce,a?l&1|2:l&1),Ot&&ql(e,n.treeForkCount),t):(Pt(e),null);case 22:case 23:return Ve(e),Gc(),n=e.memoizedState!==null,t!==null?t.memoizedState!==null!==n&&(e.flags|=8192):n&&(e.flags|=8192),n?(l&536870912)!==0&&(e.flags&128)===0&&(Pt(e),e.subtreeFlags&6&&(e.flags|=8192)):Pt(e),l=e.updateQueue,l!==null&&Mi(e,l.retryQueue),l=null,t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(l=t.memoizedState.cachePool.pool),n=null,e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),n!==l&&(e.flags|=2048),t!==null&&N(Zn),null;case 24:return l=null,t!==null&&(l=t.memoizedState.cache),e.memoizedState.cache!==l&&(e.flags|=2048),Yl(he),Pt(e),null;case 25:return null;case 30:return null}throw Error(f(156,e.tag))}function Q1(t,e){switch(Tc(e),e.tag){case 1:return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 3:return Yl(he),wt(),t=e.flags,(t&65536)!==0&&(t&128)===0?(e.flags=t&-65537|128,e):null;case 26:case 27:case 5:return xl(e),null;case 31:if(e.memoizedState!==null){if(Ve(e),e.alternate===null)throw Error(f(340));Xn()}return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 13:if(Ve(e),t=e.memoizedState,t!==null&&t.dehydrated!==null){if(e.alternate===null)throw Error(f(340));Xn()}return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 19:return N(ce),null;case 4:return wt(),null;case 10:return Yl(e.type),null;case 22:case 23:return Ve(e),Gc(),t!==null&&N(Zn),t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 24:return Yl(he),null;case 25:return null;default:return null}}function Or(t,e){switch(Tc(e),e.tag){case 3:Yl(he),wt();break;case 26:case 27:case 5:xl(e);break;case 4:wt();break;case 31:e.memoizedState!==null&&Ve(e);break;case 13:Ve(e);break;case 19:N(ce);break;case 10:Yl(e.type);break;case 22:case 23:Ve(e),Gc(),t!==null&&N(Zn);break;case 24:Yl(he)}}function yu(t,e){try{var l=e.updateQueue,n=l!==null?l.lastEffect:null;if(n!==null){var a=n.next;l=a;do{if((l.tag&t)===t){n=void 0;var u=l.create,i=l.inst;n=u(),i.destroy=n}l=l.next}while(l!==a)}}catch(o){Yt(e,e.return,o)}}function yn(t,e,l){try{var n=e.updateQueue,a=n!==null?n.lastEffect:null;if(a!==null){var u=a.next;n=u;do{if((n.tag&t)===t){var i=n.inst,o=i.destroy;if(o!==void 0){i.destroy=void 0,a=e;var p=l,C=o;try{C()}catch(w){Yt(a,p,w)}}}n=n.next}while(n!==u)}}catch(w){Yt(e,e.return,w)}}function _r(t){var e=t.updateQueue;if(e!==null){var l=t.stateNode;try{Mf(e,l)}catch(n){Yt(t,t.return,n)}}}function Rr(t,e,l){l.props=Wn(t.type,t.memoizedProps),l.state=t.memoizedState;try{l.componentWillUnmount()}catch(n){Yt(t,e,n)}}function vu(t,e){try{var l=t.ref;if(l!==null){switch(t.tag){case 26:case 27:case 5:var n=t.stateNode;break;case 30:n=t.stateNode;break;default:n=t.stateNode}typeof l=="function"?t.refCleanup=l(n):l.current=n}}catch(a){Yt(t,e,a)}}function Nl(t,e){var l=t.ref,n=t.refCleanup;if(l!==null)if(typeof n=="function")try{n()}catch(a){Yt(t,e,a)}finally{t.refCleanup=null,t=t.alternate,t!=null&&(t.refCleanup=null)}else if(typeof l=="function")try{l(null)}catch(a){Yt(t,e,a)}else l.current=null}function Ur(t){var e=t.type,l=t.memoizedProps,n=t.stateNode;try{t:switch(e){case"button":case"input":case"select":case"textarea":l.autoFocus&&n.focus();break t;case"img":l.src?n.src=l.src:l.srcSet&&(n.srcset=l.srcSet)}}catch(a){Yt(t,t.return,a)}}function bs(t,e,l){try{var n=t.stateNode;dh(n,t.type,l,e),n[ze]=e}catch(a){Yt(t,t.return,a)}}function Hr(t){return t.tag===5||t.tag===3||t.tag===26||t.tag===27&&Cn(t.type)||t.tag===4}function xs(t){t:for(;;){for(;t.sibling===null;){if(t.return===null||Hr(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.tag===27&&Cn(t.type)||t.flags&2||t.child===null||t.tag===4)continue t;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function Ss(t,e,l){var n=t.tag;if(n===5||n===6)t=t.stateNode,e?(l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l).insertBefore(t,e):(e=l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l,e.appendChild(t),l=l._reactRootContainer,l!=null||e.onclick!==null||(e.onclick=Ul));else if(n!==4&&(n===27&&Cn(t.type)&&(l=t.stateNode,e=null),t=t.child,t!==null))for(Ss(t,e,l),t=t.sibling;t!==null;)Ss(t,e,l),t=t.sibling}function Ci(t,e,l){var n=t.tag;if(n===5||n===6)t=t.stateNode,e?l.insertBefore(t,e):l.appendChild(t);else if(n!==4&&(n===27&&Cn(t.type)&&(l=t.stateNode),t=t.child,t!==null))for(Ci(t,e,l),t=t.sibling;t!==null;)Ci(t,e,l),t=t.sibling}function Br(t){var e=t.stateNode,l=t.memoizedProps;try{for(var n=t.type,a=e.attributes;a.length;)e.removeAttributeNode(a[0]);Te(e,n,l),e[fe]=t,e[ze]=l}catch(u){Yt(t,t.return,u)}}var Zl=!1,pe=!1,Es=!1,qr=typeof WeakSet=="function"?WeakSet:Set,Se=null;function Z1(t,e){if(t=t.containerInfo,ks=Zi,t=$o(t),gc(t)){if("selectionStart"in t)var l={start:t.selectionStart,end:t.selectionEnd};else t:{l=(l=t.ownerDocument)&&l.defaultView||window;var n=l.getSelection&&l.getSelection();if(n&&n.rangeCount!==0){l=n.anchorNode;var a=n.anchorOffset,u=n.focusNode;n=n.focusOffset;try{l.nodeType,u.nodeType}catch{l=null;break t}var i=0,o=-1,p=-1,C=0,w=0,U=t,T=null;e:for(;;){for(var j;U!==l||a!==0&&U.nodeType!==3||(o=i+a),U!==u||n!==0&&U.nodeType!==3||(p=i+n),U.nodeType===3&&(i+=U.nodeValue.length),(j=U.firstChild)!==null;)T=U,U=j;for(;;){if(U===t)break e;if(T===l&&++C===a&&(o=i),T===u&&++w===n&&(p=i),(j=U.nextSibling)!==null)break;U=T,T=U.parentNode}U=j}l=o===-1||p===-1?null:{start:o,end:p}}else l=null}l=l||{start:0,end:0}}else l=null;for(Qs={focusedElem:t,selectionRange:l},Zi=!1,Se=e;Se!==null;)if(e=Se,t=e.child,(e.subtreeFlags&1028)!==0&&t!==null)t.return=e,Se=t;else for(;Se!==null;){switch(e=Se,u=e.alternate,t=e.flags,e.tag){case 0:if((t&4)!==0&&(t=e.updateQueue,t=t!==null?t.events:null,t!==null))for(l=0;l<t.length;l++)a=t[l],a.ref.impl=a.nextImpl;break;case 11:case 15:break;case 1:if((t&1024)!==0&&u!==null){t=void 0,l=e,a=u.memoizedProps,u=u.memoizedState,n=l.stateNode;try{var tt=Wn(l.type,a);t=n.getSnapshotBeforeUpdate(tt,u),n.__reactInternalSnapshotBeforeUpdate=t}catch(rt){Yt(l,l.return,rt)}}break;case 3:if((t&1024)!==0){if(t=e.stateNode.containerInfo,l=t.nodeType,l===9)Ks(t);else if(l===1)switch(t.nodeName){case"HEAD":case"HTML":case"BODY":Ks(t);break;default:t.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((t&1024)!==0)throw Error(f(163))}if(t=e.sibling,t!==null){t.return=e.return,Se=t;break}Se=e.return}}function Lr(t,e,l){var n=l.flags;switch(l.tag){case 0:case 11:case 15:Kl(t,l),n&4&&yu(5,l);break;case 1:if(Kl(t,l),n&4)if(t=l.stateNode,e===null)try{t.componentDidMount()}catch(i){Yt(l,l.return,i)}else{var a=Wn(l.type,e.memoizedProps);e=e.memoizedState;try{t.componentDidUpdate(a,e,t.__reactInternalSnapshotBeforeUpdate)}catch(i){Yt(l,l.return,i)}}n&64&&_r(l),n&512&&vu(l,l.return);break;case 3:if(Kl(t,l),n&64&&(t=l.updateQueue,t!==null)){if(e=null,l.child!==null)switch(l.child.tag){case 27:case 5:e=l.child.stateNode;break;case 1:e=l.child.stateNode}try{Mf(t,e)}catch(i){Yt(l,l.return,i)}}break;case 27:e===null&&n&4&&Br(l);case 26:case 5:Kl(t,l),e===null&&n&4&&Ur(l),n&512&&vu(l,l.return);break;case 12:Kl(t,l);break;case 31:Kl(t,l),n&4&&Xr(t,l);break;case 13:Kl(t,l),n&4&&kr(t,l),n&64&&(t=l.memoizedState,t!==null&&(t=t.dehydrated,t!==null&&(l=th.bind(null,l),xh(t,l))));break;case 22:if(n=l.memoizedState!==null||Zl,!n){e=e!==null&&e.memoizedState!==null||pe,a=Zl;var u=pe;Zl=n,(pe=e)&&!u?Jl(t,l,(l.subtreeFlags&8772)!==0):Kl(t,l),Zl=a,pe=u}break;case 30:break;default:Kl(t,l)}}function Yr(t){var e=t.alternate;e!==null&&(t.alternate=null,Yr(e)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(e=t.stateNode,e!==null&&ia(e)),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}var ee=null,He=!1;function Vl(t,e,l){for(l=l.child;l!==null;)Gr(t,e,l),l=l.sibling}function Gr(t,e,l){if(ie&&typeof ie.onCommitFiberUnmount=="function")try{ie.onCommitFiberUnmount(ve,l)}catch{}switch(l.tag){case 26:pe||Nl(l,e),Vl(t,e,l),l.memoizedState?l.memoizedState.count--:l.stateNode&&(l=l.stateNode,l.parentNode.removeChild(l));break;case 27:pe||Nl(l,e);var n=ee,a=He;Cn(l.type)&&(ee=l.stateNode,He=!1),Vl(t,e,l),zu(l.stateNode),ee=n,He=a;break;case 5:pe||Nl(l,e);case 6:if(n=ee,a=He,ee=null,Vl(t,e,l),ee=n,He=a,ee!==null)if(He)try{(ee.nodeType===9?ee.body:ee.nodeName==="HTML"?ee.ownerDocument.body:ee).removeChild(l.stateNode)}catch(u){Yt(l,e,u)}else try{ee.removeChild(l.stateNode)}catch(u){Yt(l,e,u)}break;case 18:ee!==null&&(He?(t=ee,_d(t.nodeType===9?t.body:t.nodeName==="HTML"?t.ownerDocument.body:t,l.stateNode),Ya(t)):_d(ee,l.stateNode));break;case 4:n=ee,a=He,ee=l.stateNode.containerInfo,He=!0,Vl(t,e,l),ee=n,He=a;break;case 0:case 11:case 14:case 15:yn(2,l,e),pe||yn(4,l,e),Vl(t,e,l);break;case 1:pe||(Nl(l,e),n=l.stateNode,typeof n.componentWillUnmount=="function"&&Rr(l,e,n)),Vl(t,e,l);break;case 21:Vl(t,e,l);break;case 22:pe=(n=pe)||l.memoizedState!==null,Vl(t,e,l),pe=n;break;default:Vl(t,e,l)}}function Xr(t,e){if(e.memoizedState===null&&(t=e.alternate,t!==null&&(t=t.memoizedState,t!==null))){t=t.dehydrated;try{Ya(t)}catch(l){Yt(e,e.return,l)}}}function kr(t,e){if(e.memoizedState===null&&(t=e.alternate,t!==null&&(t=t.memoizedState,t!==null&&(t=t.dehydrated,t!==null))))try{Ya(t)}catch(l){Yt(e,e.return,l)}}function V1(t){switch(t.tag){case 31:case 13:case 19:var e=t.stateNode;return e===null&&(e=t.stateNode=new qr),e;case 22:return t=t.stateNode,e=t._retryCache,e===null&&(e=t._retryCache=new qr),e;default:throw Error(f(435,t.tag))}}function Ai(t,e){var l=V1(t);e.forEach(function(n){if(!l.has(n)){l.add(n);var a=eh.bind(null,t,n);n.then(a,a)}})}function Be(t,e){var l=e.deletions;if(l!==null)for(var n=0;n<l.length;n++){var a=l[n],u=t,i=e,o=i;t:for(;o!==null;){switch(o.tag){case 27:if(Cn(o.type)){ee=o.stateNode,He=!1;break t}break;case 5:ee=o.stateNode,He=!1;break t;case 3:case 4:ee=o.stateNode.containerInfo,He=!0;break t}o=o.return}if(ee===null)throw Error(f(160));Gr(u,i,a),ee=null,He=!1,u=a.alternate,u!==null&&(u.return=null),a.return=null}if(e.subtreeFlags&13886)for(e=e.child;e!==null;)Qr(e,t),e=e.sibling}var vl=null;function Qr(t,e){var l=t.alternate,n=t.flags;switch(t.tag){case 0:case 11:case 14:case 15:Be(e,t),qe(t),n&4&&(yn(3,t,t.return),yu(3,t),yn(5,t,t.return));break;case 1:Be(e,t),qe(t),n&512&&(pe||l===null||Nl(l,l.return)),n&64&&Zl&&(t=t.updateQueue,t!==null&&(n=t.callbacks,n!==null&&(l=t.shared.hiddenCallbacks,t.shared.hiddenCallbacks=l===null?n:l.concat(n))));break;case 26:var a=vl;if(Be(e,t),qe(t),n&512&&(pe||l===null||Nl(l,l.return)),n&4){var u=l!==null?l.memoizedState:null;if(n=t.memoizedState,l===null)if(n===null)if(t.stateNode===null){t:{n=t.type,l=t.memoizedProps,a=a.ownerDocument||a;e:switch(n){case"title":u=a.getElementsByTagName("title")[0],(!u||u[Un]||u[fe]||u.namespaceURI==="http://www.w3.org/2000/svg"||u.hasAttribute("itemprop"))&&(u=a.createElement(n),a.head.insertBefore(u,a.querySelector("head > title"))),Te(u,n,l),u[fe]=t,re(u),n=u;break t;case"link":var i=Qd("link","href",a).get(n+(l.href||""));if(i){for(var o=0;o<i.length;o++)if(u=i[o],u.getAttribute("href")===(l.href==null||l.href===""?null:l.href)&&u.getAttribute("rel")===(l.rel==null?null:l.rel)&&u.getAttribute("title")===(l.title==null?null:l.title)&&u.getAttribute("crossorigin")===(l.crossOrigin==null?null:l.crossOrigin)){i.splice(o,1);break e}}u=a.createElement(n),Te(u,n,l),a.head.appendChild(u);break;case"meta":if(i=Qd("meta","content",a).get(n+(l.content||""))){for(o=0;o<i.length;o++)if(u=i[o],u.getAttribute("content")===(l.content==null?null:""+l.content)&&u.getAttribute("name")===(l.name==null?null:l.name)&&u.getAttribute("property")===(l.property==null?null:l.property)&&u.getAttribute("http-equiv")===(l.httpEquiv==null?null:l.httpEquiv)&&u.getAttribute("charset")===(l.charSet==null?null:l.charSet)){i.splice(o,1);break e}}u=a.createElement(n),Te(u,n,l),a.head.appendChild(u);break;default:throw Error(f(468,n))}u[fe]=t,re(u),n=u}t.stateNode=n}else Zd(a,t.type,t.stateNode);else t.stateNode=kd(a,n,t.memoizedProps);else u!==n?(u===null?l.stateNode!==null&&(l=l.stateNode,l.parentNode.removeChild(l)):u.count--,n===null?Zd(a,t.type,t.stateNode):kd(a,n,t.memoizedProps)):n===null&&t.stateNode!==null&&bs(t,t.memoizedProps,l.memoizedProps)}break;case 27:Be(e,t),qe(t),n&512&&(pe||l===null||Nl(l,l.return)),l!==null&&n&4&&bs(t,t.memoizedProps,l.memoizedProps);break;case 5:if(Be(e,t),qe(t),n&512&&(pe||l===null||Nl(l,l.return)),t.flags&32){a=t.stateNode;try{ne(a,"")}catch(tt){Yt(t,t.return,tt)}}n&4&&t.stateNode!=null&&(a=t.memoizedProps,bs(t,a,l!==null?l.memoizedProps:a)),n&1024&&(Es=!0);break;case 6:if(Be(e,t),qe(t),n&4){if(t.stateNode===null)throw Error(f(162));n=t.memoizedProps,l=t.stateNode;try{l.nodeValue=n}catch(tt){Yt(t,t.return,tt)}}break;case 3:if(Gi=null,a=vl,vl=Li(e.containerInfo),Be(e,t),vl=a,qe(t),n&4&&l!==null&&l.memoizedState.isDehydrated)try{Ya(e.containerInfo)}catch(tt){Yt(t,t.return,tt)}Es&&(Es=!1,Zr(t));break;case 4:n=vl,vl=Li(t.stateNode.containerInfo),Be(e,t),qe(t),vl=n;break;case 12:Be(e,t),qe(t);break;case 31:Be(e,t),qe(t),n&4&&(n=t.updateQueue,n!==null&&(t.updateQueue=null,Ai(t,n)));break;case 13:Be(e,t),qe(t),t.child.flags&8192&&t.memoizedState!==null!=(l!==null&&l.memoizedState!==null)&&(zi=ye()),n&4&&(n=t.updateQueue,n!==null&&(t.updateQueue=null,Ai(t,n)));break;case 22:a=t.memoizedState!==null;var p=l!==null&&l.memoizedState!==null,C=Zl,w=pe;if(Zl=C||a,pe=w||p,Be(e,t),pe=w,Zl=C,qe(t),n&8192)t:for(e=t.stateNode,e._visibility=a?e._visibility&-2:e._visibility|1,a&&(l===null||p||Zl||pe||Fn(t)),l=null,e=t;;){if(e.tag===5||e.tag===26){if(l===null){p=l=e;try{if(u=p.stateNode,a)i=u.style,typeof i.setProperty=="function"?i.setProperty("display","none","important"):i.display="none";else{o=p.stateNode;var U=p.memoizedProps.style,T=U!=null&&U.hasOwnProperty("display")?U.display:null;o.style.display=T==null||typeof T=="boolean"?"":(""+T).trim()}}catch(tt){Yt(p,p.return,tt)}}}else if(e.tag===6){if(l===null){p=e;try{p.stateNode.nodeValue=a?"":p.memoizedProps}catch(tt){Yt(p,p.return,tt)}}}else if(e.tag===18){if(l===null){p=e;try{var j=p.stateNode;a?Rd(j,!0):Rd(p.stateNode,!1)}catch(tt){Yt(p,p.return,tt)}}}else if((e.tag!==22&&e.tag!==23||e.memoizedState===null||e===t)&&e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break t;for(;e.sibling===null;){if(e.return===null||e.return===t)break t;l===e&&(l=null),e=e.return}l===e&&(l=null),e.sibling.return=e.return,e=e.sibling}n&4&&(n=t.updateQueue,n!==null&&(l=n.retryQueue,l!==null&&(n.retryQueue=null,Ai(t,l))));break;case 19:Be(e,t),qe(t),n&4&&(n=t.updateQueue,n!==null&&(t.updateQueue=null,Ai(t,n)));break;case 30:break;case 21:break;default:Be(e,t),qe(t)}}function qe(t){var e=t.flags;if(e&2){try{for(var l,n=t.return;n!==null;){if(Hr(n)){l=n;break}n=n.return}if(l==null)throw Error(f(160));switch(l.tag){case 27:var a=l.stateNode,u=xs(t);Ci(t,u,a);break;case 5:var i=l.stateNode;l.flags&32&&(ne(i,""),l.flags&=-33);var o=xs(t);Ci(t,o,i);break;case 3:case 4:var p=l.stateNode.containerInfo,C=xs(t);Ss(t,C,p);break;default:throw Error(f(161))}}catch(w){Yt(t,t.return,w)}t.flags&=-3}e&4096&&(t.flags&=-4097)}function Zr(t){if(t.subtreeFlags&1024)for(t=t.child;t!==null;){var e=t;Zr(e),e.tag===5&&e.flags&1024&&e.stateNode.reset(),t=t.sibling}}function Kl(t,e){if(e.subtreeFlags&8772)for(e=e.child;e!==null;)Lr(t,e.alternate,e),e=e.sibling}function Fn(t){for(t=t.child;t!==null;){var e=t;switch(e.tag){case 0:case 11:case 14:case 15:yn(4,e,e.return),Fn(e);break;case 1:Nl(e,e.return);var l=e.stateNode;typeof l.componentWillUnmount=="function"&&Rr(e,e.return,l),Fn(e);break;case 27:zu(e.stateNode);case 26:case 5:Nl(e,e.return),Fn(e);break;case 22:e.memoizedState===null&&Fn(e);break;case 30:Fn(e);break;default:Fn(e)}t=t.sibling}}function Jl(t,e,l){for(l=l&&(e.subtreeFlags&8772)!==0,e=e.child;e!==null;){var n=e.alternate,a=t,u=e,i=u.flags;switch(u.tag){case 0:case 11:case 15:Jl(a,u,l),yu(4,u);break;case 1:if(Jl(a,u,l),n=u,a=n.stateNode,typeof a.componentDidMount=="function")try{a.componentDidMount()}catch(C){Yt(n,n.return,C)}if(n=u,a=n.updateQueue,a!==null){var o=n.stateNode;try{var p=a.shared.hiddenCallbacks;if(p!==null)for(a.shared.hiddenCallbacks=null,a=0;a<p.length;a++)Ef(p[a],o)}catch(C){Yt(n,n.return,C)}}l&&i&64&&_r(u),vu(u,u.return);break;case 27:Br(u);case 26:case 5:Jl(a,u,l),l&&n===null&&i&4&&Ur(u),vu(u,u.return);break;case 12:Jl(a,u,l);break;case 31:Jl(a,u,l),l&&i&4&&Xr(a,u);break;case 13:Jl(a,u,l),l&&i&4&&kr(a,u);break;case 22:u.memoizedState===null&&Jl(a,u,l),vu(u,u.return);break;case 30:break;default:Jl(a,u,l)}e=e.sibling}}function Ms(t,e){var l=null;t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(l=t.memoizedState.cachePool.pool),t=null,e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(t=e.memoizedState.cachePool.pool),t!==l&&(t!=null&&t.refCount++,l!=null&&au(l))}function Cs(t,e){t=null,e.alternate!==null&&(t=e.alternate.memoizedState.cache),e=e.memoizedState.cache,e!==t&&(e.refCount++,t!=null&&au(t))}function bl(t,e,l,n){if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Vr(t,e,l,n),e=e.sibling}function Vr(t,e,l,n){var a=e.flags;switch(e.tag){case 0:case 11:case 15:bl(t,e,l,n),a&2048&&yu(9,e);break;case 1:bl(t,e,l,n);break;case 3:bl(t,e,l,n),a&2048&&(t=null,e.alternate!==null&&(t=e.alternate.memoizedState.cache),e=e.memoizedState.cache,e!==t&&(e.refCount++,t!=null&&au(t)));break;case 12:if(a&2048){bl(t,e,l,n),t=e.stateNode;try{var u=e.memoizedProps,i=u.id,o=u.onPostCommit;typeof o=="function"&&o(i,e.alternate===null?"mount":"update",t.passiveEffectDuration,-0)}catch(p){Yt(e,e.return,p)}}else bl(t,e,l,n);break;case 31:bl(t,e,l,n);break;case 13:bl(t,e,l,n);break;case 23:break;case 22:u=e.stateNode,i=e.alternate,e.memoizedState!==null?u._visibility&2?bl(t,e,l,n):bu(t,e):u._visibility&2?bl(t,e,l,n):(u._visibility|=2,ja(t,e,l,n,(e.subtreeFlags&10256)!==0||!1)),a&2048&&Ms(i,e);break;case 24:bl(t,e,l,n),a&2048&&Cs(e.alternate,e);break;default:bl(t,e,l,n)}}function ja(t,e,l,n,a){for(a=a&&((e.subtreeFlags&10256)!==0||!1),e=e.child;e!==null;){var u=t,i=e,o=l,p=n,C=i.flags;switch(i.tag){case 0:case 11:case 15:ja(u,i,o,p,a),yu(8,i);break;case 23:break;case 22:var w=i.stateNode;i.memoizedState!==null?w._visibility&2?ja(u,i,o,p,a):bu(u,i):(w._visibility|=2,ja(u,i,o,p,a)),a&&C&2048&&Ms(i.alternate,i);break;case 24:ja(u,i,o,p,a),a&&C&2048&&Cs(i.alternate,i);break;default:ja(u,i,o,p,a)}e=e.sibling}}function bu(t,e){if(e.subtreeFlags&10256)for(e=e.child;e!==null;){var l=t,n=e,a=n.flags;switch(n.tag){case 22:bu(l,n),a&2048&&Ms(n.alternate,n);break;case 24:bu(l,n),a&2048&&Cs(n.alternate,n);break;default:bu(l,n)}e=e.sibling}}var xu=8192;function Na(t,e,l){if(t.subtreeFlags&xu)for(t=t.child;t!==null;)Kr(t,e,l),t=t.sibling}function Kr(t,e,l){switch(t.tag){case 26:Na(t,e,l),t.flags&xu&&t.memoizedState!==null&&Oh(l,vl,t.memoizedState,t.memoizedProps);break;case 5:Na(t,e,l);break;case 3:case 4:var n=vl;vl=Li(t.stateNode.containerInfo),Na(t,e,l),vl=n;break;case 22:t.memoizedState===null&&(n=t.alternate,n!==null&&n.memoizedState!==null?(n=xu,xu=16777216,Na(t,e,l),xu=n):Na(t,e,l));break;default:Na(t,e,l)}}function Jr(t){var e=t.alternate;if(e!==null&&(t=e.child,t!==null)){e.child=null;do e=t.sibling,t.sibling=null,t=e;while(t!==null)}}function Su(t){var e=t.deletions;if((t.flags&16)!==0){if(e!==null)for(var l=0;l<e.length;l++){var n=e[l];Se=n,Wr(n,t)}Jr(t)}if(t.subtreeFlags&10256)for(t=t.child;t!==null;)$r(t),t=t.sibling}function $r(t){switch(t.tag){case 0:case 11:case 15:Su(t),t.flags&2048&&yn(9,t,t.return);break;case 3:Su(t);break;case 12:Su(t);break;case 22:var e=t.stateNode;t.memoizedState!==null&&e._visibility&2&&(t.return===null||t.return.tag!==13)?(e._visibility&=-3,Ti(t)):Su(t);break;default:Su(t)}}function Ti(t){var e=t.deletions;if((t.flags&16)!==0){if(e!==null)for(var l=0;l<e.length;l++){var n=e[l];Se=n,Wr(n,t)}Jr(t)}for(t=t.child;t!==null;){switch(e=t,e.tag){case 0:case 11:case 15:yn(8,e,e.return),Ti(e);break;case 22:l=e.stateNode,l._visibility&2&&(l._visibility&=-3,Ti(e));break;default:Ti(e)}t=t.sibling}}function Wr(t,e){for(;Se!==null;){var l=Se;switch(l.tag){case 0:case 11:case 15:yn(8,l,e);break;case 23:case 22:if(l.memoizedState!==null&&l.memoizedState.cachePool!==null){var n=l.memoizedState.cachePool.pool;n!=null&&n.refCount++}break;case 24:au(l.memoizedState.cache)}if(n=l.child,n!==null)n.return=l,Se=n;else t:for(l=t;Se!==null;){n=Se;var a=n.sibling,u=n.return;if(Yr(n),n===l){Se=null;break t}if(a!==null){a.return=u,Se=a;break t}Se=u}}}var K1={getCacheForType:function(t){var e=Ce(he),l=e.data.get(t);return l===void 0&&(l=t(),e.data.set(t,l)),l},cacheSignal:function(){return Ce(he).controller.signal}},J1=typeof WeakMap=="function"?WeakMap:Map,Bt=0,Zt=null,zt=null,jt=0,Lt=0,Ke=null,vn=!1,wa=!1,As=!1,$l=0,ue=0,bn=0,In=0,Ts=0,Je=0,Oa=0,Eu=null,Le=null,zs=!1,zi=0,Fr=0,Di=1/0,ji=null,xn=null,be=0,Sn=null,_a=null,Wl=0,Ds=0,js=null,Ir=null,Mu=0,Ns=null;function $e(){return(Bt&2)!==0&&jt!==0?jt&-jt:z.T!==null?Hs():hl()}function Pr(){if(Je===0)if((jt&536870912)===0||Ot){var t=St;St<<=1,(St&3932160)===0&&(St=262144),Je=t}else Je=536870912;return t=Ze.current,t!==null&&(t.flags|=32),Je}function Ye(t,e,l){(t===Zt&&(Lt===2||Lt===9)||t.cancelPendingCommit!==null)&&(Ra(t,0),En(t,jt,Je,!1)),_n(t,l),((Bt&2)===0||t!==Zt)&&(t===Zt&&((Bt&2)===0&&(In|=l),ue===4&&En(t,jt,Je,!1)),wl(t))}function td(t,e,l){if((Bt&6)!==0)throw Error(f(327));var n=!l&&(e&127)===0&&(e&t.expiredLanes)===0||Gt(t,e),a=n?F1(t,e):Os(t,e,!0),u=n;do{if(a===0){wa&&!n&&En(t,e,0,!1);break}else{if(l=t.current.alternate,u&&!$1(l)){a=Os(t,e,!1),u=!1;continue}if(a===2){if(u=e,t.errorRecoveryDisabledLanes&u)var i=0;else i=t.pendingLanes&-536870913,i=i!==0?i:i&536870912?536870912:0;if(i!==0){e=i;t:{var o=t;a=Eu;var p=o.current.memoizedState.isDehydrated;if(p&&(Ra(o,i).flags|=256),i=Os(o,i,!1),i!==2){if(As&&!p){o.errorRecoveryDisabledLanes|=u,In|=u,a=4;break t}u=Le,Le=a,u!==null&&(Le===null?Le=u:Le.push.apply(Le,u))}a=i}if(u=!1,a!==2)continue}}if(a===1){Ra(t,0),En(t,e,0,!0);break}t:{switch(n=t,u=a,u){case 0:case 1:throw Error(f(345));case 4:if((e&4194048)!==e)break;case 6:En(n,e,Je,!vn);break t;case 2:Le=null;break;case 3:case 5:break;default:throw Error(f(329))}if((e&62914560)===e&&(a=zi+300-ye(),10<a)){if(En(n,e,Je,!vn),Wt(n,0,!0)!==0)break t;Wl=e,n.timeoutHandle=wd(ed.bind(null,n,l,Le,ji,zs,e,Je,In,Oa,vn,u,"Throttled",-0,0),a);break t}ed(n,l,Le,ji,zs,e,Je,In,Oa,vn,u,null,-0,0)}}break}while(!0);wl(t)}function ed(t,e,l,n,a,u,i,o,p,C,w,U,T,j){if(t.timeoutHandle=-1,U=e.subtreeFlags,U&8192||(U&16785408)===16785408){U={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Ul},Kr(e,u,U);var tt=(u&62914560)===u?zi-ye():(u&4194048)===u?Fr-ye():0;if(tt=_h(U,tt),tt!==null){Wl=u,t.cancelPendingCommit=tt(od.bind(null,t,e,u,l,n,a,i,o,p,w,U,null,T,j)),En(t,u,i,!C);return}}od(t,e,u,l,n,a,i,o,p)}function $1(t){for(var e=t;;){var l=e.tag;if((l===0||l===11||l===15)&&e.flags&16384&&(l=e.updateQueue,l!==null&&(l=l.stores,l!==null)))for(var n=0;n<l.length;n++){var a=l[n],u=a.getSnapshot;a=a.value;try{if(!ke(u(),a))return!1}catch{return!1}}if(l=e.child,e.subtreeFlags&16384&&l!==null)l.return=e,e=l;else{if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)return!0;e=e.return}e.sibling.return=e.return,e=e.sibling}}return!0}function En(t,e,l,n){e&=~Ts,e&=~In,t.suspendedLanes|=e,t.pingedLanes&=~e,n&&(t.warmLanes|=e),n=t.expirationTimes;for(var a=e;0<a;){var u=31-xe(a),i=1<<u;n[u]=-1,a&=~i}l!==0&&Xa(t,l,e)}function Ni(){return(Bt&6)===0?(Cu(0),!1):!0}function ws(){if(zt!==null){if(Lt===0)var t=zt.return;else t=zt,Ll=kn=null,Kc(t),Ca=null,iu=0,t=zt;for(;t!==null;)Or(t.alternate,t),t=t.return;zt=null}}function Ra(t,e){var l=t.timeoutHandle;l!==-1&&(t.timeoutHandle=-1,gh(l)),l=t.cancelPendingCommit,l!==null&&(t.cancelPendingCommit=null,l()),Wl=0,ws(),Zt=t,zt=l=Bl(t.current,null),jt=e,Lt=0,Ke=null,vn=!1,wa=Gt(t,e),As=!1,Oa=Je=Ts=In=bn=ue=0,Le=Eu=null,zs=!1,(e&8)!==0&&(e|=e&32);var n=t.entangledLanes;if(n!==0)for(t=t.entanglements,n&=e;0<n;){var a=31-xe(n),u=1<<a;e|=t[a],n&=~u}return $l=e,Fu(),l}function ld(t,e){bt=null,z.H=mu,e===Ma||e===ui?(e=vf(),Lt=3):e===Uc?(e=vf(),Lt=4):Lt=e===os?8:e!==null&&typeof e=="object"&&typeof e.then=="function"?6:1,Ke=e,zt===null&&(ue=1,bi(t,tl(e,t.current)))}function nd(){var t=Ze.current;return t===null?!0:(jt&4194048)===jt?al===null:(jt&62914560)===jt||(jt&536870912)!==0?t===al:!1}function ad(){var t=z.H;return z.H=mu,t===null?mu:t}function ud(){var t=z.A;return z.A=K1,t}function wi(){ue=4,vn||(jt&4194048)!==jt&&Ze.current!==null||(wa=!0),(bn&134217727)===0&&(In&134217727)===0||Zt===null||En(Zt,jt,Je,!1)}function Os(t,e,l){var n=Bt;Bt|=2;var a=ad(),u=ud();(Zt!==t||jt!==e)&&(ji=null,Ra(t,e)),e=!1;var i=ue;t:do try{if(Lt!==0&&zt!==null){var o=zt,p=Ke;switch(Lt){case 8:ws(),i=6;break t;case 3:case 2:case 9:case 6:Ze.current===null&&(e=!0);var C=Lt;if(Lt=0,Ke=null,Ua(t,o,p,C),l&&wa){i=0;break t}break;default:C=Lt,Lt=0,Ke=null,Ua(t,o,p,C)}}W1(),i=ue;break}catch(w){ld(t,w)}while(!0);return e&&t.shellSuspendCounter++,Ll=kn=null,Bt=n,z.H=a,z.A=u,zt===null&&(Zt=null,jt=0,Fu()),i}function W1(){for(;zt!==null;)id(zt)}function F1(t,e){var l=Bt;Bt|=2;var n=ad(),a=ud();Zt!==t||jt!==e?(ji=null,Di=ye()+500,Ra(t,e)):wa=Gt(t,e);t:do try{if(Lt!==0&&zt!==null){e=zt;var u=Ke;e:switch(Lt){case 1:Lt=0,Ke=null,Ua(t,e,u,1);break;case 2:case 9:if(pf(u)){Lt=0,Ke=null,cd(e);break}e=function(){Lt!==2&&Lt!==9||Zt!==t||(Lt=7),wl(t)},u.then(e,e);break t;case 3:Lt=7;break t;case 4:Lt=5;break t;case 7:pf(u)?(Lt=0,Ke=null,cd(e)):(Lt=0,Ke=null,Ua(t,e,u,7));break;case 5:var i=null;switch(zt.tag){case 26:i=zt.memoizedState;case 5:case 27:var o=zt;if(i?Vd(i):o.stateNode.complete){Lt=0,Ke=null;var p=o.sibling;if(p!==null)zt=p;else{var C=o.return;C!==null?(zt=C,Oi(C)):zt=null}break e}}Lt=0,Ke=null,Ua(t,e,u,5);break;case 6:Lt=0,Ke=null,Ua(t,e,u,6);break;case 8:ws(),ue=6;break t;default:throw Error(f(462))}}I1();break}catch(w){ld(t,w)}while(!0);return Ll=kn=null,z.H=n,z.A=a,Bt=l,zt!==null?0:(Zt=null,jt=0,Fu(),ue)}function I1(){for(;zt!==null&&!Fe();)id(zt)}function id(t){var e=Nr(t.alternate,t,$l);t.memoizedProps=t.pendingProps,e===null?Oi(t):zt=e}function cd(t){var e=t,l=e.alternate;switch(e.tag){case 15:case 0:e=Cr(l,e,e.pendingProps,e.type,void 0,jt);break;case 11:e=Cr(l,e,e.pendingProps,e.type.render,e.ref,jt);break;case 5:Kc(e);default:Or(l,e),e=zt=af(e,$l),e=Nr(l,e,$l)}t.memoizedProps=t.pendingProps,e===null?Oi(t):zt=e}function Ua(t,e,l,n){Ll=kn=null,Kc(e),Ca=null,iu=0;var a=e.return;try{if(Y1(t,a,e,l,jt)){ue=1,bi(t,tl(l,t.current)),zt=null;return}}catch(u){if(a!==null)throw zt=a,u;ue=1,bi(t,tl(l,t.current)),zt=null;return}e.flags&32768?(Ot||n===1?t=!0:wa||(jt&536870912)!==0?t=!1:(vn=t=!0,(n===2||n===9||n===3||n===6)&&(n=Ze.current,n!==null&&n.tag===13&&(n.flags|=16384))),sd(e,t)):Oi(e)}function Oi(t){var e=t;do{if((e.flags&32768)!==0){sd(e,vn);return}t=e.return;var l=k1(e.alternate,e,$l);if(l!==null){zt=l;return}if(e=e.sibling,e!==null){zt=e;return}zt=e=t}while(e!==null);ue===0&&(ue=5)}function sd(t,e){do{var l=Q1(t.alternate,t);if(l!==null){l.flags&=32767,zt=l;return}if(l=t.return,l!==null&&(l.flags|=32768,l.subtreeFlags=0,l.deletions=null),!e&&(t=t.sibling,t!==null)){zt=t;return}zt=t=l}while(t!==null);ue=6,zt=null}function od(t,e,l,n,a,u,i,o,p){t.cancelPendingCommit=null;do _i();while(be!==0);if((Bt&6)!==0)throw Error(f(327));if(e!==null){if(e===t.current)throw Error(f(177));if(u=e.lanes|e.childLanes,u|=xc,Xe(t,l,u,i,o,p),t===Zt&&(zt=Zt=null,jt=0),_a=e,Sn=t,Wl=l,Ds=u,js=a,Ir=n,(e.subtreeFlags&10256)!==0||(e.flags&10256)!==0?(t.callbackNode=null,t.callbackPriority=0,lh(Ml,function(){return md(),null})):(t.callbackNode=null,t.callbackPriority=0),n=(e.flags&13878)!==0,(e.subtreeFlags&13878)!==0||n){n=z.T,z.T=null,a=q.p,q.p=2,i=Bt,Bt|=4;try{Z1(t,e,l)}finally{Bt=i,q.p=a,z.T=n}}be=1,fd(),rd(),dd()}}function fd(){if(be===1){be=0;var t=Sn,e=_a,l=(e.flags&13878)!==0;if((e.subtreeFlags&13878)!==0||l){l=z.T,z.T=null;var n=q.p;q.p=2;var a=Bt;Bt|=4;try{Qr(e,t);var u=Qs,i=$o(t.containerInfo),o=u.focusedElem,p=u.selectionRange;if(i!==o&&o&&o.ownerDocument&&Jo(o.ownerDocument.documentElement,o)){if(p!==null&&gc(o)){var C=p.start,w=p.end;if(w===void 0&&(w=C),"selectionStart"in o)o.selectionStart=C,o.selectionEnd=Math.min(w,o.value.length);else{var U=o.ownerDocument||document,T=U&&U.defaultView||window;if(T.getSelection){var j=T.getSelection(),tt=o.textContent.length,rt=Math.min(p.start,tt),Qt=p.end===void 0?rt:Math.min(p.end,tt);!j.extend&&rt>Qt&&(i=Qt,Qt=rt,rt=i);var S=Ko(o,rt),b=Ko(o,Qt);if(S&&b&&(j.rangeCount!==1||j.anchorNode!==S.node||j.anchorOffset!==S.offset||j.focusNode!==b.node||j.focusOffset!==b.offset)){var M=U.createRange();M.setStart(S.node,S.offset),j.removeAllRanges(),rt>Qt?(j.addRange(M),j.extend(b.node,b.offset)):(M.setEnd(b.node,b.offset),j.addRange(M))}}}}for(U=[],j=o;j=j.parentNode;)j.nodeType===1&&U.push({element:j,left:j.scrollLeft,top:j.scrollTop});for(typeof o.focus=="function"&&o.focus(),o=0;o<U.length;o++){var _=U[o];_.element.scrollLeft=_.left,_.element.scrollTop=_.top}}Zi=!!ks,Qs=ks=null}finally{Bt=a,q.p=n,z.T=l}}t.current=e,be=2}}function rd(){if(be===2){be=0;var t=Sn,e=_a,l=(e.flags&8772)!==0;if((e.subtreeFlags&8772)!==0||l){l=z.T,z.T=null;var n=q.p;q.p=2;var a=Bt;Bt|=4;try{Lr(t,e.alternate,e)}finally{Bt=a,q.p=n,z.T=l}}be=3}}function dd(){if(be===4||be===3){be=0,la();var t=Sn,e=_a,l=Wl,n=Ir;(e.subtreeFlags&10256)!==0||(e.flags&10256)!==0?be=5:(be=0,_a=Sn=null,hd(t,t.pendingLanes));var a=t.pendingLanes;if(a===0&&(xn=null),ka(l),e=e.stateNode,ie&&typeof ie.onCommitFiberRoot=="function")try{ie.onCommitFiberRoot(ve,e,void 0,(e.current.flags&128)===128)}catch{}if(n!==null){e=z.T,a=q.p,q.p=2,z.T=null;try{for(var u=t.onRecoverableError,i=0;i<n.length;i++){var o=n[i];u(o.value,{componentStack:o.stack})}}finally{z.T=e,q.p=a}}(Wl&3)!==0&&_i(),wl(t),a=t.pendingLanes,(l&261930)!==0&&(a&42)!==0?t===Ns?Mu++:(Mu=0,Ns=t):Mu=0,Cu(0)}}function hd(t,e){(t.pooledCacheLanes&=e)===0&&(e=t.pooledCache,e!=null&&(t.pooledCache=null,au(e)))}function _i(){return fd(),rd(),dd(),md()}function md(){if(be!==5)return!1;var t=Sn,e=Ds;Ds=0;var l=ka(Wl),n=z.T,a=q.p;try{q.p=32>l?32:l,z.T=null,l=js,js=null;var u=Sn,i=Wl;if(be=0,_a=Sn=null,Wl=0,(Bt&6)!==0)throw Error(f(331));var o=Bt;if(Bt|=4,$r(u.current),Vr(u,u.current,i,l),Bt=o,Cu(0,!1),ie&&typeof ie.onPostCommitFiberRoot=="function")try{ie.onPostCommitFiberRoot(ve,u)}catch{}return!0}finally{q.p=a,z.T=n,hd(t,e)}}function gd(t,e,l){e=tl(l,e),e=ss(t.stateNode,e,2),t=mn(t,e,2),t!==null&&(_n(t,2),wl(t))}function Yt(t,e,l){if(t.tag===3)gd(t,t,l);else for(;e!==null;){if(e.tag===3){gd(e,t,l);break}else if(e.tag===1){var n=e.stateNode;if(typeof e.type.getDerivedStateFromError=="function"||typeof n.componentDidCatch=="function"&&(xn===null||!xn.has(n))){t=tl(l,t),l=pr(2),n=mn(e,l,2),n!==null&&(yr(l,n,e,t),_n(n,2),wl(n));break}}e=e.return}}function _s(t,e,l){var n=t.pingCache;if(n===null){n=t.pingCache=new J1;var a=new Set;n.set(e,a)}else a=n.get(e),a===void 0&&(a=new Set,n.set(e,a));a.has(l)||(As=!0,a.add(l),t=P1.bind(null,t,e,l),e.then(t,t))}function P1(t,e,l){var n=t.pingCache;n!==null&&n.delete(e),t.pingedLanes|=t.suspendedLanes&l,t.warmLanes&=~l,Zt===t&&(jt&l)===l&&(ue===4||ue===3&&(jt&62914560)===jt&&300>ye()-zi?(Bt&2)===0&&Ra(t,0):Ts|=l,Oa===jt&&(Oa=0)),wl(t)}function pd(t,e){e===0&&(e=Ee()),t=Yn(t,e),t!==null&&(_n(t,e),wl(t))}function th(t){var e=t.memoizedState,l=0;e!==null&&(l=e.retryLane),pd(t,l)}function eh(t,e){var l=0;switch(t.tag){case 31:case 13:var n=t.stateNode,a=t.memoizedState;a!==null&&(l=a.retryLane);break;case 19:n=t.stateNode;break;case 22:n=t.stateNode._retryCache;break;default:throw Error(f(314))}n!==null&&n.delete(e),pd(t,l)}function lh(t,e){return Sl(t,e)}var Ri=null,Ha=null,Rs=!1,Ui=!1,Us=!1,Mn=0;function wl(t){t!==Ha&&t.next===null&&(Ha===null?Ri=Ha=t:Ha=Ha.next=t),Ui=!0,Rs||(Rs=!0,ah())}function Cu(t,e){if(!Us&&Ui){Us=!0;do for(var l=!1,n=Ri;n!==null;){if(t!==0){var a=n.pendingLanes;if(a===0)var u=0;else{var i=n.suspendedLanes,o=n.pingedLanes;u=(1<<31-xe(42|t)+1)-1,u&=a&~(i&~o),u=u&201326741?u&201326741|1:u?u|2:0}u!==0&&(l=!0,xd(n,u))}else u=jt,u=Wt(n,n===Zt?u:0,n.cancelPendingCommit!==null||n.timeoutHandle!==-1),(u&3)===0||Gt(n,u)||(l=!0,xd(n,u));n=n.next}while(l);Us=!1}}function nh(){yd()}function yd(){Ui=Rs=!1;var t=0;Mn!==0&&mh()&&(t=Mn);for(var e=ye(),l=null,n=Ri;n!==null;){var a=n.next,u=vd(n,e);u===0?(n.next=null,l===null?Ri=a:l.next=a,a===null&&(Ha=l)):(l=n,(t!==0||(u&3)!==0)&&(Ui=!0)),n=a}be!==0&&be!==5||Cu(t),Mn!==0&&(Mn=0)}function vd(t,e){for(var l=t.suspendedLanes,n=t.pingedLanes,a=t.expirationTimes,u=t.pendingLanes&-62914561;0<u;){var i=31-xe(u),o=1<<i,p=a[i];p===-1?((o&l)===0||(o&n)!==0)&&(a[i]=oe(o,e)):p<=e&&(t.expiredLanes|=o),u&=~o}if(e=Zt,l=jt,l=Wt(t,t===e?l:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),n=t.callbackNode,l===0||t===e&&(Lt===2||Lt===9)||t.cancelPendingCommit!==null)return n!==null&&n!==null&&Pl(n),t.callbackNode=null,t.callbackPriority=0;if((l&3)===0||Gt(t,l)){if(e=l&-l,e===t.callbackPriority)return e;switch(n!==null&&Pl(n),ka(l)){case 2:case 8:l=wn;break;case 32:l=Ml;break;case 268435456:l=ln;break;default:l=Ml}return n=bd.bind(null,t),l=Sl(l,n),t.callbackPriority=e,t.callbackNode=l,e}return n!==null&&n!==null&&Pl(n),t.callbackPriority=2,t.callbackNode=null,2}function bd(t,e){if(be!==0&&be!==5)return t.callbackNode=null,t.callbackPriority=0,null;var l=t.callbackNode;if(_i()&&t.callbackNode!==l)return null;var n=jt;return n=Wt(t,t===Zt?n:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),n===0?null:(td(t,n,e),vd(t,ye()),t.callbackNode!=null&&t.callbackNode===l?bd.bind(null,t):null)}function xd(t,e){if(_i())return null;td(t,e,!0)}function ah(){ph(function(){(Bt&6)!==0?Sl(tn,nh):yd()})}function Hs(){if(Mn===0){var t=Sa;t===0&&(t=K,K<<=1,(K&261888)===0&&(K=256)),Mn=t}return Mn}function Sd(t){return t==null||typeof t=="symbol"||typeof t=="boolean"?null:typeof t=="function"?t:ku(""+t)}function Ed(t,e){var l=e.ownerDocument.createElement("input");return l.name=e.name,l.value=e.value,t.id&&l.setAttribute("form",t.id),e.parentNode.insertBefore(l,e),t=new FormData(t),l.parentNode.removeChild(l),t}function uh(t,e,l,n,a){if(e==="submit"&&l&&l.stateNode===a){var u=Sd((a[ze]||null).action),i=n.submitter;i&&(e=(e=i[ze]||null)?Sd(e.formAction):i.getAttribute("formAction"),e!==null&&(u=e,i=null));var o=new Ku("action","action",null,n,a);t.push({event:o,listeners:[{instance:null,listener:function(){if(n.defaultPrevented){if(Mn!==0){var p=i?Ed(a,i):new FormData(a);ls(l,{pending:!0,data:p,method:a.method,action:u},null,p)}}else typeof u=="function"&&(o.preventDefault(),p=i?Ed(a,i):new FormData(a),ls(l,{pending:!0,data:p,method:a.method,action:u},u,p))},currentTarget:a}]})}}for(var Bs=0;Bs<bc.length;Bs++){var qs=bc[Bs],ih=qs.toLowerCase(),ch=qs[0].toUpperCase()+qs.slice(1);yl(ih,"on"+ch)}yl(Io,"onAnimationEnd"),yl(Po,"onAnimationIteration"),yl(tf,"onAnimationStart"),yl("dblclick","onDoubleClick"),yl("focusin","onFocus"),yl("focusout","onBlur"),yl(M1,"onTransitionRun"),yl(C1,"onTransitionStart"),yl(A1,"onTransitionCancel"),yl(ef,"onTransitionEnd"),Ie("onMouseEnter",["mouseout","mouseover"]),Ie("onMouseLeave",["mouseout","mouseover"]),Ie("onPointerEnter",["pointerout","pointerover"]),Ie("onPointerLeave",["pointerout","pointerover"]),gl("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),gl("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),gl("onBeforeInput",["compositionend","keypress","textInput","paste"]),gl("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),gl("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),gl("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Au="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(" "),sh=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Au));function Md(t,e){e=(e&4)!==0;for(var l=0;l<t.length;l++){var n=t[l],a=n.event;n=n.listeners;t:{var u=void 0;if(e)for(var i=n.length-1;0<=i;i--){var o=n[i],p=o.instance,C=o.currentTarget;if(o=o.listener,p!==u&&a.isPropagationStopped())break t;u=o,a.currentTarget=C;try{u(a)}catch(w){Wu(w)}a.currentTarget=null,u=p}else for(i=0;i<n.length;i++){if(o=n[i],p=o.instance,C=o.currentTarget,o=o.listener,p!==u&&a.isPropagationStopped())break t;u=o,a.currentTarget=C;try{u(a)}catch(w){Wu(w)}a.currentTarget=null,u=p}}}}function Dt(t,e){var l=e[Jt];l===void 0&&(l=e[Jt]=new Set);var n=t+"__bubble";l.has(n)||(Cd(e,t,2,!1),l.add(n))}function Ls(t,e,l){var n=0;e&&(n|=4),Cd(l,t,n,e)}var Hi="_reactListening"+Math.random().toString(36).slice(2);function Ys(t){if(!t[Hi]){t[Hi]=!0,Qa.forEach(function(l){l!=="selectionchange"&&(sh.has(l)||Ls(l,!1,t),Ls(l,!0,t))});var e=t.nodeType===9?t:t.ownerDocument;e===null||e[Hi]||(e[Hi]=!0,Ls("selectionchange",!1,e))}}function Cd(t,e,l,n){switch(Pd(e)){case 2:var a=Hh;break;case 8:a=Bh;break;default:a=eo}l=a.bind(null,e,l,t),a=void 0,!ic||e!=="touchstart"&&e!=="touchmove"&&e!=="wheel"||(a=!0),n?a!==void 0?t.addEventListener(e,l,{capture:!0,passive:a}):t.addEventListener(e,l,!0):a!==void 0?t.addEventListener(e,l,{passive:a}):t.addEventListener(e,l,!1)}function Gs(t,e,l,n,a){var u=n;if((e&1)===0&&(e&2)===0&&n!==null)t:for(;;){if(n===null)return;var i=n.tag;if(i===3||i===4){var o=n.stateNode.containerInfo;if(o===a)break;if(i===4)for(i=n.return;i!==null;){var p=i.tag;if((p===3||p===4)&&i.stateNode.containerInfo===a)return;i=i.return}for(;o!==null;){if(i=Tl(o),i===null)return;if(p=i.tag,p===5||p===6||p===26||p===27){n=u=i;continue t}o=o.parentNode}}n=n.return}Do(function(){var C=u,w=ac(l),U=[];t:{var T=lf.get(t);if(T!==void 0){var j=Ku,tt=t;switch(t){case"keypress":if(Zu(l)===0)break t;case"keydown":case"keyup":j=e1;break;case"focusin":tt="focus",j=fc;break;case"focusout":tt="blur",j=fc;break;case"beforeblur":case"afterblur":j=fc;break;case"click":if(l.button===2)break t;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":j=wo;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":j=k0;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":j=a1;break;case Io:case Po:case tf:j=V0;break;case ef:j=i1;break;case"scroll":case"scrollend":j=G0;break;case"wheel":j=s1;break;case"copy":case"cut":case"paste":j=J0;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":j=_o;break;case"toggle":case"beforetoggle":j=f1}var rt=(e&4)!==0,Qt=!rt&&(t==="scroll"||t==="scrollend"),S=rt?T!==null?T+"Capture":null:T;rt=[];for(var b=C,M;b!==null;){var _=b;if(M=_.stateNode,_=_.tag,_!==5&&_!==26&&_!==27||M===null||S===null||(_=Ka(b,S),_!=null&&rt.push(Tu(b,_,M))),Qt)break;b=b.return}0<rt.length&&(T=new j(T,tt,null,l,w),U.push({event:T,listeners:rt}))}}if((e&7)===0){t:{if(T=t==="mouseover"||t==="pointerover",j=t==="mouseout"||t==="pointerout",T&&l!==nc&&(tt=l.relatedTarget||l.fromElement)&&(Tl(tt)||tt[ml]))break t;if((j||T)&&(T=w.window===w?w:(T=w.ownerDocument)?T.defaultView||T.parentWindow:window,j?(tt=l.relatedTarget||l.toElement,j=C,tt=tt?Tl(tt):null,tt!==null&&(Qt=y(tt),rt=tt.tag,tt!==Qt||rt!==5&&rt!==27&&rt!==6)&&(tt=null)):(j=null,tt=C),j!==tt)){if(rt=wo,_="onMouseLeave",S="onMouseEnter",b="mouse",(t==="pointerout"||t==="pointerover")&&(rt=_o,_="onPointerLeave",S="onPointerEnter",b="pointer"),Qt=j==null?T:Hn(j),M=tt==null?T:Hn(tt),T=new rt(_,b+"leave",j,l,w),T.target=Qt,T.relatedTarget=M,_=null,Tl(w)===C&&(rt=new rt(S,b+"enter",tt,l,w),rt.target=M,rt.relatedTarget=Qt,_=rt),Qt=_,j&&tt)e:{for(rt=oh,S=j,b=tt,M=0,_=S;_;_=rt(_))M++;_=0;for(var st=b;st;st=rt(st))_++;for(;0<M-_;)S=rt(S),M--;for(;0<_-M;)b=rt(b),_--;for(;M--;){if(S===b||b!==null&&S===b.alternate){rt=S;break e}S=rt(S),b=rt(b)}rt=null}else rt=null;j!==null&&Ad(U,T,j,rt,!1),tt!==null&&Qt!==null&&Ad(U,Qt,tt,rt,!0)}}t:{if(T=C?Hn(C):window,j=T.nodeName&&T.nodeName.toLowerCase(),j==="select"||j==="input"&&T.type==="file")var Rt=Go;else if(Lo(T))if(Xo)Rt=x1;else{Rt=v1;var at=y1}else j=T.nodeName,!j||j.toLowerCase()!=="input"||T.type!=="checkbox"&&T.type!=="radio"?C&&lc(C.elementType)&&(Rt=Go):Rt=b1;if(Rt&&(Rt=Rt(t,C))){Yo(U,Rt,l,w);break t}at&&at(t,T,C),t==="focusout"&&C&&T.type==="number"&&C.memoizedProps.value!=null&&Ct(T,"number",T.value)}switch(at=C?Hn(C):window,t){case"focusin":(Lo(at)||at.contentEditable==="true")&&(ha=at,pc=C,eu=null);break;case"focusout":eu=pc=ha=null;break;case"mousedown":yc=!0;break;case"contextmenu":case"mouseup":case"dragend":yc=!1,Wo(U,l,w);break;case"selectionchange":if(E1)break;case"keydown":case"keyup":Wo(U,l,w)}var Et;if(dc)t:{switch(t){case"compositionstart":var Nt="onCompositionStart";break t;case"compositionend":Nt="onCompositionEnd";break t;case"compositionupdate":Nt="onCompositionUpdate";break t}Nt=void 0}else da?Bo(t,l)&&(Nt="onCompositionEnd"):t==="keydown"&&l.keyCode===229&&(Nt="onCompositionStart");Nt&&(Ro&&l.locale!=="ko"&&(da||Nt!=="onCompositionStart"?Nt==="onCompositionEnd"&&da&&(Et=jo()):(cn=w,cc="value"in cn?cn.value:cn.textContent,da=!0)),at=Bi(C,Nt),0<at.length&&(Nt=new Oo(Nt,t,null,l,w),U.push({event:Nt,listeners:at}),Et?Nt.data=Et:(Et=qo(l),Et!==null&&(Nt.data=Et)))),(Et=d1?h1(t,l):m1(t,l))&&(Nt=Bi(C,"onBeforeInput"),0<Nt.length&&(at=new Oo("onBeforeInput","beforeinput",null,l,w),U.push({event:at,listeners:Nt}),at.data=Et)),uh(U,t,C,l,w)}Md(U,e)})}function Tu(t,e,l){return{instance:t,listener:e,currentTarget:l}}function Bi(t,e){for(var l=e+"Capture",n=[];t!==null;){var a=t,u=a.stateNode;if(a=a.tag,a!==5&&a!==26&&a!==27||u===null||(a=Ka(t,l),a!=null&&n.unshift(Tu(t,a,u)),a=Ka(t,e),a!=null&&n.push(Tu(t,a,u))),t.tag===3)return n;t=t.return}return[]}function oh(t){if(t===null)return null;do t=t.return;while(t&&t.tag!==5&&t.tag!==27);return t||null}function Ad(t,e,l,n,a){for(var u=e._reactName,i=[];l!==null&&l!==n;){var o=l,p=o.alternate,C=o.stateNode;if(o=o.tag,p!==null&&p===n)break;o!==5&&o!==26&&o!==27||C===null||(p=C,a?(C=Ka(l,u),C!=null&&i.unshift(Tu(l,C,p))):a||(C=Ka(l,u),C!=null&&i.push(Tu(l,C,p)))),l=l.return}i.length!==0&&t.push({event:e,listeners:i})}var fh=/\r\n?/g,rh=/\u0000|\uFFFD/g;function Td(t){return(typeof t=="string"?t:""+t).replace(fh,`
9
+ `).replace(rh,"")}function zd(t,e){return e=Td(e),Td(t)===e}function kt(t,e,l,n,a,u){switch(l){case"children":typeof n=="string"?e==="body"||e==="textarea"&&n===""||ne(t,n):(typeof n=="number"||typeof n=="bigint")&&e!=="body"&&ne(t,""+n);break;case"className":oa(t,"class",n);break;case"tabIndex":oa(t,"tabindex",n);break;case"dir":case"role":case"viewBox":case"width":case"height":oa(t,l,n);break;case"style":Xu(t,n,u);break;case"data":if(e!=="object"){oa(t,"data",n);break}case"src":case"href":if(n===""&&(e!=="a"||l!=="href")){t.removeAttribute(l);break}if(n==null||typeof n=="function"||typeof n=="symbol"||typeof n=="boolean"){t.removeAttribute(l);break}n=ku(""+n),t.setAttribute(l,n);break;case"action":case"formAction":if(typeof n=="function"){t.setAttribute(l,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof u=="function"&&(l==="formAction"?(e!=="input"&&kt(t,e,"name",a.name,a,null),kt(t,e,"formEncType",a.formEncType,a,null),kt(t,e,"formMethod",a.formMethod,a,null),kt(t,e,"formTarget",a.formTarget,a,null)):(kt(t,e,"encType",a.encType,a,null),kt(t,e,"method",a.method,a,null),kt(t,e,"target",a.target,a,null)));if(n==null||typeof n=="symbol"||typeof n=="boolean"){t.removeAttribute(l);break}n=ku(""+n),t.setAttribute(l,n);break;case"onClick":n!=null&&(t.onclick=Ul);break;case"onScroll":n!=null&&Dt("scroll",t);break;case"onScrollEnd":n!=null&&Dt("scrollend",t);break;case"dangerouslySetInnerHTML":if(n!=null){if(typeof n!="object"||!("__html"in n))throw Error(f(61));if(l=n.__html,l!=null){if(a.children!=null)throw Error(f(60));t.innerHTML=l}}break;case"multiple":t.multiple=n&&typeof n!="function"&&typeof n!="symbol";break;case"muted":t.muted=n&&typeof n!="function"&&typeof n!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(n==null||typeof n=="function"||typeof n=="boolean"||typeof n=="symbol"){t.removeAttribute("xlink:href");break}l=ku(""+n),t.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",l);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":n!=null&&typeof n!="function"&&typeof n!="symbol"?t.setAttribute(l,""+n):t.removeAttribute(l);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":n&&typeof n!="function"&&typeof n!="symbol"?t.setAttribute(l,""):t.removeAttribute(l);break;case"capture":case"download":n===!0?t.setAttribute(l,""):n!==!1&&n!=null&&typeof n!="function"&&typeof n!="symbol"?t.setAttribute(l,n):t.removeAttribute(l);break;case"cols":case"rows":case"size":case"span":n!=null&&typeof n!="function"&&typeof n!="symbol"&&!isNaN(n)&&1<=n?t.setAttribute(l,n):t.removeAttribute(l);break;case"rowSpan":case"start":n==null||typeof n=="function"||typeof n=="symbol"||isNaN(n)?t.removeAttribute(l):t.setAttribute(l,n);break;case"popover":Dt("beforetoggle",t),Dt("toggle",t),sa(t,"popover",n);break;case"xlinkActuate":pl(t,"http://www.w3.org/1999/xlink","xlink:actuate",n);break;case"xlinkArcrole":pl(t,"http://www.w3.org/1999/xlink","xlink:arcrole",n);break;case"xlinkRole":pl(t,"http://www.w3.org/1999/xlink","xlink:role",n);break;case"xlinkShow":pl(t,"http://www.w3.org/1999/xlink","xlink:show",n);break;case"xlinkTitle":pl(t,"http://www.w3.org/1999/xlink","xlink:title",n);break;case"xlinkType":pl(t,"http://www.w3.org/1999/xlink","xlink:type",n);break;case"xmlBase":pl(t,"http://www.w3.org/XML/1998/namespace","xml:base",n);break;case"xmlLang":pl(t,"http://www.w3.org/XML/1998/namespace","xml:lang",n);break;case"xmlSpace":pl(t,"http://www.w3.org/XML/1998/namespace","xml:space",n);break;case"is":sa(t,"is",n);break;case"innerText":case"textContent":break;default:(!(2<l.length)||l[0]!=="o"&&l[0]!=="O"||l[1]!=="n"&&l[1]!=="N")&&(l=L0.get(l)||l,sa(t,l,n))}}function Xs(t,e,l,n,a,u){switch(l){case"style":Xu(t,n,u);break;case"dangerouslySetInnerHTML":if(n!=null){if(typeof n!="object"||!("__html"in n))throw Error(f(61));if(l=n.__html,l!=null){if(a.children!=null)throw Error(f(60));t.innerHTML=l}}break;case"children":typeof n=="string"?ne(t,n):(typeof n=="number"||typeof n=="bigint")&&ne(t,""+n);break;case"onScroll":n!=null&&Dt("scroll",t);break;case"onScrollEnd":n!=null&&Dt("scrollend",t);break;case"onClick":n!=null&&(t.onclick=Ul);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!ca.hasOwnProperty(l))t:{if(l[0]==="o"&&l[1]==="n"&&(a=l.endsWith("Capture"),e=l.slice(2,a?l.length-7:void 0),u=t[ze]||null,u=u!=null?u[l]:null,typeof u=="function"&&t.removeEventListener(e,u,a),typeof n=="function")){typeof u!="function"&&u!==null&&(l in t?t[l]=null:t.hasAttribute(l)&&t.removeAttribute(l)),t.addEventListener(e,n,a);break t}l in t?t[l]=n:n===!0?t.setAttribute(l,""):sa(t,l,n)}}}function Te(t,e,l){switch(e){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":Dt("error",t),Dt("load",t);var n=!1,a=!1,u;for(u in l)if(l.hasOwnProperty(u)){var i=l[u];if(i!=null)switch(u){case"src":n=!0;break;case"srcSet":a=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(f(137,e));default:kt(t,e,u,i,l,null)}}a&&kt(t,e,"srcSet",l.srcSet,l,null),n&&kt(t,e,"src",l.src,l,null);return;case"input":Dt("invalid",t);var o=u=i=a=null,p=null,C=null;for(n in l)if(l.hasOwnProperty(n)){var w=l[n];if(w!=null)switch(n){case"name":a=w;break;case"type":i=w;break;case"checked":p=w;break;case"defaultChecked":C=w;break;case"value":u=w;break;case"defaultValue":o=w;break;case"children":case"dangerouslySetInnerHTML":if(w!=null)throw Error(f(137,e));break;default:kt(t,e,n,w,l,null)}}At(t,u,o,p,C,i,a,!1);return;case"select":Dt("invalid",t),n=i=u=null;for(a in l)if(l.hasOwnProperty(a)&&(o=l[a],o!=null))switch(a){case"value":u=o;break;case"defaultValue":i=o;break;case"multiple":n=o;default:kt(t,e,a,o,l,null)}e=u,l=i,t.multiple=!!n,e!=null?_t(t,!!n,e,!1):l!=null&&_t(t,!!n,l,!0);return;case"textarea":Dt("invalid",t),u=a=n=null;for(i in l)if(l.hasOwnProperty(i)&&(o=l[i],o!=null))switch(i){case"value":n=o;break;case"defaultValue":a=o;break;case"children":u=o;break;case"dangerouslySetInnerHTML":if(o!=null)throw Error(f(91));break;default:kt(t,e,i,o,l,null)}de(t,n,a,u);return;case"option":for(p in l)l.hasOwnProperty(p)&&(n=l[p],n!=null)&&(p==="selected"?t.selected=n&&typeof n!="function"&&typeof n!="symbol":kt(t,e,p,n,l,null));return;case"dialog":Dt("beforetoggle",t),Dt("toggle",t),Dt("cancel",t),Dt("close",t);break;case"iframe":case"object":Dt("load",t);break;case"video":case"audio":for(n=0;n<Au.length;n++)Dt(Au[n],t);break;case"image":Dt("error",t),Dt("load",t);break;case"details":Dt("toggle",t);break;case"embed":case"source":case"link":Dt("error",t),Dt("load",t);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(C in l)if(l.hasOwnProperty(C)&&(n=l[C],n!=null))switch(C){case"children":case"dangerouslySetInnerHTML":throw Error(f(137,e));default:kt(t,e,C,n,l,null)}return;default:if(lc(e)){for(w in l)l.hasOwnProperty(w)&&(n=l[w],n!==void 0&&Xs(t,e,w,n,l,void 0));return}}for(o in l)l.hasOwnProperty(o)&&(n=l[o],n!=null&&kt(t,e,o,n,l,null))}function dh(t,e,l,n){switch(e){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var a=null,u=null,i=null,o=null,p=null,C=null,w=null;for(j in l){var U=l[j];if(l.hasOwnProperty(j)&&U!=null)switch(j){case"checked":break;case"value":break;case"defaultValue":p=U;default:n.hasOwnProperty(j)||kt(t,e,j,null,n,U)}}for(var T in n){var j=n[T];if(U=l[T],n.hasOwnProperty(T)&&(j!=null||U!=null))switch(T){case"type":u=j;break;case"name":a=j;break;case"checked":C=j;break;case"defaultChecked":w=j;break;case"value":i=j;break;case"defaultValue":o=j;break;case"children":case"dangerouslySetInnerHTML":if(j!=null)throw Error(f(137,e));break;default:j!==U&&kt(t,e,T,j,n,U)}}ct(t,i,o,p,C,w,u,a);return;case"select":j=i=o=T=null;for(u in l)if(p=l[u],l.hasOwnProperty(u)&&p!=null)switch(u){case"value":break;case"multiple":j=p;default:n.hasOwnProperty(u)||kt(t,e,u,null,n,p)}for(a in n)if(u=n[a],p=l[a],n.hasOwnProperty(a)&&(u!=null||p!=null))switch(a){case"value":T=u;break;case"defaultValue":o=u;break;case"multiple":i=u;default:u!==p&&kt(t,e,a,u,n,p)}e=o,l=i,n=j,T!=null?_t(t,!!l,T,!1):!!n!=!!l&&(e!=null?_t(t,!!l,e,!0):_t(t,!!l,l?[]:"",!1));return;case"textarea":j=T=null;for(o in l)if(a=l[o],l.hasOwnProperty(o)&&a!=null&&!n.hasOwnProperty(o))switch(o){case"value":break;case"children":break;default:kt(t,e,o,null,n,a)}for(i in n)if(a=n[i],u=l[i],n.hasOwnProperty(i)&&(a!=null||u!=null))switch(i){case"value":T=a;break;case"defaultValue":j=a;break;case"children":break;case"dangerouslySetInnerHTML":if(a!=null)throw Error(f(91));break;default:a!==u&&kt(t,e,i,a,n,u)}te(t,T,j);return;case"option":for(var tt in l)T=l[tt],l.hasOwnProperty(tt)&&T!=null&&!n.hasOwnProperty(tt)&&(tt==="selected"?t.selected=!1:kt(t,e,tt,null,n,T));for(p in n)T=n[p],j=l[p],n.hasOwnProperty(p)&&T!==j&&(T!=null||j!=null)&&(p==="selected"?t.selected=T&&typeof T!="function"&&typeof T!="symbol":kt(t,e,p,T,n,j));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 rt in l)T=l[rt],l.hasOwnProperty(rt)&&T!=null&&!n.hasOwnProperty(rt)&&kt(t,e,rt,null,n,T);for(C in n)if(T=n[C],j=l[C],n.hasOwnProperty(C)&&T!==j&&(T!=null||j!=null))switch(C){case"children":case"dangerouslySetInnerHTML":if(T!=null)throw Error(f(137,e));break;default:kt(t,e,C,T,n,j)}return;default:if(lc(e)){for(var Qt in l)T=l[Qt],l.hasOwnProperty(Qt)&&T!==void 0&&!n.hasOwnProperty(Qt)&&Xs(t,e,Qt,void 0,n,T);for(w in n)T=n[w],j=l[w],!n.hasOwnProperty(w)||T===j||T===void 0&&j===void 0||Xs(t,e,w,T,n,j);return}}for(var S in l)T=l[S],l.hasOwnProperty(S)&&T!=null&&!n.hasOwnProperty(S)&&kt(t,e,S,null,n,T);for(U in n)T=n[U],j=l[U],!n.hasOwnProperty(U)||T===j||T==null&&j==null||kt(t,e,U,T,n,j)}function Dd(t){switch(t){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function hh(){if(typeof performance.getEntriesByType=="function"){for(var t=0,e=0,l=performance.getEntriesByType("resource"),n=0;n<l.length;n++){var a=l[n],u=a.transferSize,i=a.initiatorType,o=a.duration;if(u&&o&&Dd(i)){for(i=0,o=a.responseEnd,n+=1;n<l.length;n++){var p=l[n],C=p.startTime;if(C>o)break;var w=p.transferSize,U=p.initiatorType;w&&Dd(U)&&(p=p.responseEnd,i+=w*(p<o?1:(o-C)/(p-C)))}if(--n,e+=8*(u+i)/(a.duration/1e3),t++,10<t)break}}if(0<t)return e/t/1e6}return navigator.connection&&(t=navigator.connection.downlink,typeof t=="number")?t:5}var ks=null,Qs=null;function qi(t){return t.nodeType===9?t:t.ownerDocument}function jd(t){switch(t){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function Nd(t,e){if(t===0)switch(e){case"svg":return 1;case"math":return 2;default:return 0}return t===1&&e==="foreignObject"?0:t}function Zs(t,e){return t==="textarea"||t==="noscript"||typeof e.children=="string"||typeof e.children=="number"||typeof e.children=="bigint"||typeof e.dangerouslySetInnerHTML=="object"&&e.dangerouslySetInnerHTML!==null&&e.dangerouslySetInnerHTML.__html!=null}var Vs=null;function mh(){var t=window.event;return t&&t.type==="popstate"?t===Vs?!1:(Vs=t,!0):(Vs=null,!1)}var wd=typeof setTimeout=="function"?setTimeout:void 0,gh=typeof clearTimeout=="function"?clearTimeout:void 0,Od=typeof Promise=="function"?Promise:void 0,ph=typeof queueMicrotask=="function"?queueMicrotask:typeof Od<"u"?function(t){return Od.resolve(null).then(t).catch(yh)}:wd;function yh(t){setTimeout(function(){throw t})}function Cn(t){return t==="head"}function _d(t,e){var l=e,n=0;do{var a=l.nextSibling;if(t.removeChild(l),a&&a.nodeType===8)if(l=a.data,l==="/$"||l==="/&"){if(n===0){t.removeChild(a),Ya(e);return}n--}else if(l==="$"||l==="$?"||l==="$~"||l==="$!"||l==="&")n++;else if(l==="html")zu(t.ownerDocument.documentElement);else if(l==="head"){l=t.ownerDocument.head,zu(l);for(var u=l.firstChild;u;){var i=u.nextSibling,o=u.nodeName;u[Un]||o==="SCRIPT"||o==="STYLE"||o==="LINK"&&u.rel.toLowerCase()==="stylesheet"||l.removeChild(u),u=i}}else l==="body"&&zu(t.ownerDocument.body);l=a}while(l);Ya(e)}function Rd(t,e){var l=t;t=0;do{var n=l.nextSibling;if(l.nodeType===1?e?(l._stashedDisplay=l.style.display,l.style.display="none"):(l.style.display=l._stashedDisplay||"",l.getAttribute("style")===""&&l.removeAttribute("style")):l.nodeType===3&&(e?(l._stashedText=l.nodeValue,l.nodeValue=""):l.nodeValue=l._stashedText||""),n&&n.nodeType===8)if(l=n.data,l==="/$"){if(t===0)break;t--}else l!=="$"&&l!=="$?"&&l!=="$~"&&l!=="$!"||t++;l=n}while(l)}function Ks(t){var e=t.firstChild;for(e&&e.nodeType===10&&(e=e.nextSibling);e;){var l=e;switch(e=e.nextSibling,l.nodeName){case"HTML":case"HEAD":case"BODY":Ks(l),ia(l);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(l.rel.toLowerCase()==="stylesheet")continue}t.removeChild(l)}}function vh(t,e,l,n){for(;t.nodeType===1;){var a=l;if(t.nodeName.toLowerCase()!==e.toLowerCase()){if(!n&&(t.nodeName!=="INPUT"||t.type!=="hidden"))break}else if(n){if(!t[Un])switch(e){case"meta":if(!t.hasAttribute("itemprop"))break;return t;case"link":if(u=t.getAttribute("rel"),u==="stylesheet"&&t.hasAttribute("data-precedence"))break;if(u!==a.rel||t.getAttribute("href")!==(a.href==null||a.href===""?null:a.href)||t.getAttribute("crossorigin")!==(a.crossOrigin==null?null:a.crossOrigin)||t.getAttribute("title")!==(a.title==null?null:a.title))break;return t;case"style":if(t.hasAttribute("data-precedence"))break;return t;case"script":if(u=t.getAttribute("src"),(u!==(a.src==null?null:a.src)||t.getAttribute("type")!==(a.type==null?null:a.type)||t.getAttribute("crossorigin")!==(a.crossOrigin==null?null:a.crossOrigin))&&u&&t.hasAttribute("async")&&!t.hasAttribute("itemprop"))break;return t;default:return t}}else if(e==="input"&&t.type==="hidden"){var u=a.name==null?null:""+a.name;if(a.type==="hidden"&&t.getAttribute("name")===u)return t}else return t;if(t=ul(t.nextSibling),t===null)break}return null}function bh(t,e,l){if(e==="")return null;for(;t.nodeType!==3;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!l||(t=ul(t.nextSibling),t===null))return null;return t}function Ud(t,e){for(;t.nodeType!==8;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!e||(t=ul(t.nextSibling),t===null))return null;return t}function Js(t){return t.data==="$?"||t.data==="$~"}function $s(t){return t.data==="$!"||t.data==="$?"&&t.ownerDocument.readyState!=="loading"}function xh(t,e){var l=t.ownerDocument;if(t.data==="$~")t._reactRetry=e;else if(t.data!=="$?"||l.readyState!=="loading")e();else{var n=function(){e(),l.removeEventListener("DOMContentLoaded",n)};l.addEventListener("DOMContentLoaded",n),t._reactRetry=n}}function ul(t){for(;t!=null;t=t.nextSibling){var e=t.nodeType;if(e===1||e===3)break;if(e===8){if(e=t.data,e==="$"||e==="$!"||e==="$?"||e==="$~"||e==="&"||e==="F!"||e==="F")break;if(e==="/$"||e==="/&")return null}}return t}var Ws=null;function Hd(t){t=t.nextSibling;for(var e=0;t;){if(t.nodeType===8){var l=t.data;if(l==="/$"||l==="/&"){if(e===0)return ul(t.nextSibling);e--}else l!=="$"&&l!=="$!"&&l!=="$?"&&l!=="$~"&&l!=="&"||e++}t=t.nextSibling}return null}function Bd(t){t=t.previousSibling;for(var e=0;t;){if(t.nodeType===8){var l=t.data;if(l==="$"||l==="$!"||l==="$?"||l==="$~"||l==="&"){if(e===0)return t;e--}else l!=="/$"&&l!=="/&"||e++}t=t.previousSibling}return null}function qd(t,e,l){switch(e=qi(l),t){case"html":if(t=e.documentElement,!t)throw Error(f(452));return t;case"head":if(t=e.head,!t)throw Error(f(453));return t;case"body":if(t=e.body,!t)throw Error(f(454));return t;default:throw Error(f(451))}}function zu(t){for(var e=t.attributes;e.length;)t.removeAttributeNode(e[0]);ia(t)}var il=new Map,Ld=new Set;function Li(t){return typeof t.getRootNode=="function"?t.getRootNode():t.nodeType===9?t:t.ownerDocument}var Fl=q.d;q.d={f:Sh,r:Eh,D:Mh,C:Ch,L:Ah,m:Th,X:Dh,S:zh,M:jh};function Sh(){var t=Fl.f(),e=Ni();return t||e}function Eh(t){var e=an(t);e!==null&&e.tag===5&&e.type==="form"?lr(e):Fl.r(t)}var Ba=typeof document>"u"?null:document;function Yd(t,e,l){var n=Ba;if(n&&typeof e=="string"&&e){var a=W(e);a='link[rel="'+t+'"][href="'+a+'"]',typeof l=="string"&&(a+='[crossorigin="'+l+'"]'),Ld.has(a)||(Ld.add(a),t={rel:t,crossOrigin:l,href:e},n.querySelector(a)===null&&(e=n.createElement("link"),Te(e,"link",t),re(e),n.head.appendChild(e)))}}function Mh(t){Fl.D(t),Yd("dns-prefetch",t,null)}function Ch(t,e){Fl.C(t,e),Yd("preconnect",t,e)}function Ah(t,e,l){Fl.L(t,e,l);var n=Ba;if(n&&t&&e){var a='link[rel="preload"][as="'+W(e)+'"]';e==="image"&&l&&l.imageSrcSet?(a+='[imagesrcset="'+W(l.imageSrcSet)+'"]',typeof l.imageSizes=="string"&&(a+='[imagesizes="'+W(l.imageSizes)+'"]')):a+='[href="'+W(t)+'"]';var u=a;switch(e){case"style":u=qa(t);break;case"script":u=La(t)}il.has(u)||(t=H({rel:"preload",href:e==="image"&&l&&l.imageSrcSet?void 0:t,as:e},l),il.set(u,t),n.querySelector(a)!==null||e==="style"&&n.querySelector(Du(u))||e==="script"&&n.querySelector(ju(u))||(e=n.createElement("link"),Te(e,"link",t),re(e),n.head.appendChild(e)))}}function Th(t,e){Fl.m(t,e);var l=Ba;if(l&&t){var n=e&&typeof e.as=="string"?e.as:"script",a='link[rel="modulepreload"][as="'+W(n)+'"][href="'+W(t)+'"]',u=a;switch(n){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":u=La(t)}if(!il.has(u)&&(t=H({rel:"modulepreload",href:t},e),il.set(u,t),l.querySelector(a)===null)){switch(n){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(l.querySelector(ju(u)))return}n=l.createElement("link"),Te(n,"link",t),re(n),l.head.appendChild(n)}}}function zh(t,e,l){Fl.S(t,e,l);var n=Ba;if(n&&t){var a=Rl(n).hoistableStyles,u=qa(t);e=e||"default";var i=a.get(u);if(!i){var o={loading:0,preload:null};if(i=n.querySelector(Du(u)))o.loading=5;else{t=H({rel:"stylesheet",href:t,"data-precedence":e},l),(l=il.get(u))&&Fs(t,l);var p=i=n.createElement("link");re(p),Te(p,"link",t),p._p=new Promise(function(C,w){p.onload=C,p.onerror=w}),p.addEventListener("load",function(){o.loading|=1}),p.addEventListener("error",function(){o.loading|=2}),o.loading|=4,Yi(i,e,n)}i={type:"stylesheet",instance:i,count:1,state:o},a.set(u,i)}}}function Dh(t,e){Fl.X(t,e);var l=Ba;if(l&&t){var n=Rl(l).hoistableScripts,a=La(t),u=n.get(a);u||(u=l.querySelector(ju(a)),u||(t=H({src:t,async:!0},e),(e=il.get(a))&&Is(t,e),u=l.createElement("script"),re(u),Te(u,"link",t),l.head.appendChild(u)),u={type:"script",instance:u,count:1,state:null},n.set(a,u))}}function jh(t,e){Fl.M(t,e);var l=Ba;if(l&&t){var n=Rl(l).hoistableScripts,a=La(t),u=n.get(a);u||(u=l.querySelector(ju(a)),u||(t=H({src:t,async:!0,type:"module"},e),(e=il.get(a))&&Is(t,e),u=l.createElement("script"),re(u),Te(u,"link",t),l.head.appendChild(u)),u={type:"script",instance:u,count:1,state:null},n.set(a,u))}}function Gd(t,e,l,n){var a=(a=ft.current)?Li(a):null;if(!a)throw Error(f(446));switch(t){case"meta":case"title":return null;case"style":return typeof l.precedence=="string"&&typeof l.href=="string"?(e=qa(l.href),l=Rl(a).hoistableStyles,n=l.get(e),n||(n={type:"style",instance:null,count:0,state:null},l.set(e,n)),n):{type:"void",instance:null,count:0,state:null};case"link":if(l.rel==="stylesheet"&&typeof l.href=="string"&&typeof l.precedence=="string"){t=qa(l.href);var u=Rl(a).hoistableStyles,i=u.get(t);if(i||(a=a.ownerDocument||a,i={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},u.set(t,i),(u=a.querySelector(Du(t)))&&!u._p&&(i.instance=u,i.state.loading=5),il.has(t)||(l={rel:"preload",as:"style",href:l.href,crossOrigin:l.crossOrigin,integrity:l.integrity,media:l.media,hrefLang:l.hrefLang,referrerPolicy:l.referrerPolicy},il.set(t,l),u||Nh(a,t,l,i.state))),e&&n===null)throw Error(f(528,""));return i}if(e&&n!==null)throw Error(f(529,""));return null;case"script":return e=l.async,l=l.src,typeof l=="string"&&e&&typeof e!="function"&&typeof e!="symbol"?(e=La(l),l=Rl(a).hoistableScripts,n=l.get(e),n||(n={type:"script",instance:null,count:0,state:null},l.set(e,n)),n):{type:"void",instance:null,count:0,state:null};default:throw Error(f(444,t))}}function qa(t){return'href="'+W(t)+'"'}function Du(t){return'link[rel="stylesheet"]['+t+"]"}function Xd(t){return H({},t,{"data-precedence":t.precedence,precedence:null})}function Nh(t,e,l,n){t.querySelector('link[rel="preload"][as="style"]['+e+"]")?n.loading=1:(e=t.createElement("link"),n.preload=e,e.addEventListener("load",function(){return n.loading|=1}),e.addEventListener("error",function(){return n.loading|=2}),Te(e,"link",l),re(e),t.head.appendChild(e))}function La(t){return'[src="'+W(t)+'"]'}function ju(t){return"script[async]"+t}function kd(t,e,l){if(e.count++,e.instance===null)switch(e.type){case"style":var n=t.querySelector('style[data-href~="'+W(l.href)+'"]');if(n)return e.instance=n,re(n),n;var a=H({},l,{"data-href":l.href,"data-precedence":l.precedence,href:null,precedence:null});return n=(t.ownerDocument||t).createElement("style"),re(n),Te(n,"style",a),Yi(n,l.precedence,t),e.instance=n;case"stylesheet":a=qa(l.href);var u=t.querySelector(Du(a));if(u)return e.state.loading|=4,e.instance=u,re(u),u;n=Xd(l),(a=il.get(a))&&Fs(n,a),u=(t.ownerDocument||t).createElement("link"),re(u);var i=u;return i._p=new Promise(function(o,p){i.onload=o,i.onerror=p}),Te(u,"link",n),e.state.loading|=4,Yi(u,l.precedence,t),e.instance=u;case"script":return u=La(l.src),(a=t.querySelector(ju(u)))?(e.instance=a,re(a),a):(n=l,(a=il.get(u))&&(n=H({},l),Is(n,a)),t=t.ownerDocument||t,a=t.createElement("script"),re(a),Te(a,"link",n),t.head.appendChild(a),e.instance=a);case"void":return null;default:throw Error(f(443,e.type))}else e.type==="stylesheet"&&(e.state.loading&4)===0&&(n=e.instance,e.state.loading|=4,Yi(n,l.precedence,t));return e.instance}function Yi(t,e,l){for(var n=l.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),a=n.length?n[n.length-1]:null,u=a,i=0;i<n.length;i++){var o=n[i];if(o.dataset.precedence===e)u=o;else if(u!==a)break}u?u.parentNode.insertBefore(t,u.nextSibling):(e=l.nodeType===9?l.head:l,e.insertBefore(t,e.firstChild))}function Fs(t,e){t.crossOrigin==null&&(t.crossOrigin=e.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=e.referrerPolicy),t.title==null&&(t.title=e.title)}function Is(t,e){t.crossOrigin==null&&(t.crossOrigin=e.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=e.referrerPolicy),t.integrity==null&&(t.integrity=e.integrity)}var Gi=null;function Qd(t,e,l){if(Gi===null){var n=new Map,a=Gi=new Map;a.set(l,n)}else a=Gi,n=a.get(l),n||(n=new Map,a.set(l,n));if(n.has(t))return n;for(n.set(t,null),l=l.getElementsByTagName(t),a=0;a<l.length;a++){var u=l[a];if(!(u[Un]||u[fe]||t==="link"&&u.getAttribute("rel")==="stylesheet")&&u.namespaceURI!=="http://www.w3.org/2000/svg"){var i=u.getAttribute(e)||"";i=t+i;var o=n.get(i);o?o.push(u):n.set(i,[u])}}return n}function Zd(t,e,l){t=t.ownerDocument||t,t.head.insertBefore(l,e==="title"?t.querySelector("head > title"):null)}function wh(t,e,l){if(l===1||e.itemProp!=null)return!1;switch(t){case"meta":case"title":return!0;case"style":if(typeof e.precedence!="string"||typeof e.href!="string"||e.href==="")break;return!0;case"link":if(typeof e.rel!="string"||typeof e.href!="string"||e.href===""||e.onLoad||e.onError)break;return e.rel==="stylesheet"?(t=e.disabled,typeof e.precedence=="string"&&t==null):!0;case"script":if(e.async&&typeof e.async!="function"&&typeof e.async!="symbol"&&!e.onLoad&&!e.onError&&e.src&&typeof e.src=="string")return!0}return!1}function Vd(t){return!(t.type==="stylesheet"&&(t.state.loading&3)===0)}function Oh(t,e,l,n){if(l.type==="stylesheet"&&(typeof n.media!="string"||matchMedia(n.media).matches!==!1)&&(l.state.loading&4)===0){if(l.instance===null){var a=qa(n.href),u=e.querySelector(Du(a));if(u){e=u._p,e!==null&&typeof e=="object"&&typeof e.then=="function"&&(t.count++,t=Xi.bind(t),e.then(t,t)),l.state.loading|=4,l.instance=u,re(u);return}u=e.ownerDocument||e,n=Xd(n),(a=il.get(a))&&Fs(n,a),u=u.createElement("link"),re(u);var i=u;i._p=new Promise(function(o,p){i.onload=o,i.onerror=p}),Te(u,"link",n),l.instance=u}t.stylesheets===null&&(t.stylesheets=new Map),t.stylesheets.set(l,e),(e=l.state.preload)&&(l.state.loading&3)===0&&(t.count++,l=Xi.bind(t),e.addEventListener("load",l),e.addEventListener("error",l))}}var Ps=0;function _h(t,e){return t.stylesheets&&t.count===0&&Qi(t,t.stylesheets),0<t.count||0<t.imgCount?function(l){var n=setTimeout(function(){if(t.stylesheets&&Qi(t,t.stylesheets),t.unsuspend){var u=t.unsuspend;t.unsuspend=null,u()}},6e4+e);0<t.imgBytes&&Ps===0&&(Ps=62500*hh());var a=setTimeout(function(){if(t.waitingForImages=!1,t.count===0&&(t.stylesheets&&Qi(t,t.stylesheets),t.unsuspend)){var u=t.unsuspend;t.unsuspend=null,u()}},(t.imgBytes>Ps?50:800)+e);return t.unsuspend=l,function(){t.unsuspend=null,clearTimeout(n),clearTimeout(a)}}:null}function Xi(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Qi(this,this.stylesheets);else if(this.unsuspend){var t=this.unsuspend;this.unsuspend=null,t()}}}var ki=null;function Qi(t,e){t.stylesheets=null,t.unsuspend!==null&&(t.count++,ki=new Map,e.forEach(Rh,t),ki=null,Xi.call(t))}function Rh(t,e){if(!(e.state.loading&4)){var l=ki.get(t);if(l)var n=l.get(null);else{l=new Map,ki.set(t,l);for(var a=t.querySelectorAll("link[data-precedence],style[data-precedence]"),u=0;u<a.length;u++){var i=a[u];(i.nodeName==="LINK"||i.getAttribute("media")!=="not all")&&(l.set(i.dataset.precedence,i),n=i)}n&&l.set(null,n)}a=e.instance,i=a.getAttribute("data-precedence"),u=l.get(i)||n,u===n&&l.set(null,a),l.set(i,a),this.count++,n=Xi.bind(this),a.addEventListener("load",n),a.addEventListener("error",n),u?u.parentNode.insertBefore(a,u.nextSibling):(t=t.nodeType===9?t.head:t,t.insertBefore(a,t.firstChild)),e.state.loading|=4}}var Nu={$$typeof:I,Provider:null,Consumer:null,_currentValue:$,_currentValue2:$,_threadCount:0};function Uh(t,e,l,n,a,u,i,o,p){this.tag=1,this.containerInfo=t,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=Ga(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ga(0),this.hiddenUpdates=Ga(null),this.identifierPrefix=n,this.onUncaughtError=a,this.onCaughtError=u,this.onRecoverableError=i,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=p,this.incompleteTransitions=new Map}function Kd(t,e,l,n,a,u,i,o,p,C,w,U){return t=new Uh(t,e,l,i,p,C,w,U,o),e=1,u===!0&&(e|=24),u=Qe(3,null,null,e),t.current=u,u.stateNode=t,e=Oc(),e.refCount++,t.pooledCache=e,e.refCount++,u.memoizedState={element:n,isDehydrated:l,cache:e},Hc(u),t}function Jd(t){return t?(t=pa,t):pa}function $d(t,e,l,n,a,u){a=Jd(a),n.context===null?n.context=a:n.pendingContext=a,n=hn(e),n.payload={element:l},u=u===void 0?null:u,u!==null&&(n.callback=u),l=mn(t,n,e),l!==null&&(Ye(l,t,e),su(l,t,e))}function Wd(t,e){if(t=t.memoizedState,t!==null&&t.dehydrated!==null){var l=t.retryLane;t.retryLane=l!==0&&l<e?l:e}}function to(t,e){Wd(t,e),(t=t.alternate)&&Wd(t,e)}function Fd(t){if(t.tag===13||t.tag===31){var e=Yn(t,67108864);e!==null&&Ye(e,t,67108864),to(t,67108864)}}function Id(t){if(t.tag===13||t.tag===31){var e=$e();e=nn(e);var l=Yn(t,e);l!==null&&Ye(l,t,e),to(t,e)}}var Zi=!0;function Hh(t,e,l,n){var a=z.T;z.T=null;var u=q.p;try{q.p=2,eo(t,e,l,n)}finally{q.p=u,z.T=a}}function Bh(t,e,l,n){var a=z.T;z.T=null;var u=q.p;try{q.p=8,eo(t,e,l,n)}finally{q.p=u,z.T=a}}function eo(t,e,l,n){if(Zi){var a=lo(n);if(a===null)Gs(t,e,n,Vi,l),t0(t,n);else if(Lh(a,t,e,l,n))n.stopPropagation();else if(t0(t,n),e&4&&-1<qh.indexOf(t)){for(;a!==null;){var u=an(a);if(u!==null)switch(u.tag){case 3:if(u=u.stateNode,u.current.memoizedState.isDehydrated){var i=mt(u.pendingLanes);if(i!==0){var o=u;for(o.pendingLanes|=2,o.entangledLanes|=2;i;){var p=1<<31-xe(i);o.entanglements[1]|=p,i&=~p}wl(u),(Bt&6)===0&&(Di=ye()+500,Cu(0))}}break;case 31:case 13:o=Yn(u,2),o!==null&&Ye(o,u,2),Ni(),to(u,2)}if(u=lo(n),u===null&&Gs(t,e,n,Vi,l),u===a)break;a=u}a!==null&&n.stopPropagation()}else Gs(t,e,n,null,l)}}function lo(t){return t=ac(t),no(t)}var Vi=null;function no(t){if(Vi=null,t=Tl(t),t!==null){var e=y(t);if(e===null)t=null;else{var l=e.tag;if(l===13){if(t=E(e),t!==null)return t;t=null}else if(l===31){if(t=A(e),t!==null)return t;t=null}else if(l===3){if(e.stateNode.current.memoizedState.isDehydrated)return e.tag===3?e.stateNode.containerInfo:null;t=null}else e!==t&&(t=null)}}return Vi=t,null}function Pd(t){switch(t){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(El()){case tn:return 2;case wn:return 8;case Ml:case en:return 32;case ln:return 268435456;default:return 32}default:return 32}}var ao=!1,An=null,Tn=null,zn=null,wu=new Map,Ou=new Map,Dn=[],qh="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 t0(t,e){switch(t){case"focusin":case"focusout":An=null;break;case"dragenter":case"dragleave":Tn=null;break;case"mouseover":case"mouseout":zn=null;break;case"pointerover":case"pointerout":wu.delete(e.pointerId);break;case"gotpointercapture":case"lostpointercapture":Ou.delete(e.pointerId)}}function _u(t,e,l,n,a,u){return t===null||t.nativeEvent!==u?(t={blockedOn:e,domEventName:l,eventSystemFlags:n,nativeEvent:u,targetContainers:[a]},e!==null&&(e=an(e),e!==null&&Fd(e)),t):(t.eventSystemFlags|=n,e=t.targetContainers,a!==null&&e.indexOf(a)===-1&&e.push(a),t)}function Lh(t,e,l,n,a){switch(e){case"focusin":return An=_u(An,t,e,l,n,a),!0;case"dragenter":return Tn=_u(Tn,t,e,l,n,a),!0;case"mouseover":return zn=_u(zn,t,e,l,n,a),!0;case"pointerover":var u=a.pointerId;return wu.set(u,_u(wu.get(u)||null,t,e,l,n,a)),!0;case"gotpointercapture":return u=a.pointerId,Ou.set(u,_u(Ou.get(u)||null,t,e,l,n,a)),!0}return!1}function e0(t){var e=Tl(t.target);if(e!==null){var l=y(e);if(l!==null){if(e=l.tag,e===13){if(e=E(l),e!==null){t.blockedOn=e,Lu(t.priority,function(){Id(l)});return}}else if(e===31){if(e=A(l),e!==null){t.blockedOn=e,Lu(t.priority,function(){Id(l)});return}}else if(e===3&&l.stateNode.current.memoizedState.isDehydrated){t.blockedOn=l.tag===3?l.stateNode.containerInfo:null;return}}}t.blockedOn=null}function Ki(t){if(t.blockedOn!==null)return!1;for(var e=t.targetContainers;0<e.length;){var l=lo(t.nativeEvent);if(l===null){l=t.nativeEvent;var n=new l.constructor(l.type,l);nc=n,l.target.dispatchEvent(n),nc=null}else return e=an(l),e!==null&&Fd(e),t.blockedOn=l,!1;e.shift()}return!0}function l0(t,e,l){Ki(t)&&l.delete(e)}function Yh(){ao=!1,An!==null&&Ki(An)&&(An=null),Tn!==null&&Ki(Tn)&&(Tn=null),zn!==null&&Ki(zn)&&(zn=null),wu.forEach(l0),Ou.forEach(l0)}function Ji(t,e){t.blockedOn===e&&(t.blockedOn=null,ao||(ao=!0,c.unstable_scheduleCallback(c.unstable_NormalPriority,Yh)))}var $i=null;function n0(t){$i!==t&&($i=t,c.unstable_scheduleCallback(c.unstable_NormalPriority,function(){$i===t&&($i=null);for(var e=0;e<t.length;e+=3){var l=t[e],n=t[e+1],a=t[e+2];if(typeof n!="function"){if(no(n||l)===null)continue;break}var u=an(l);u!==null&&(t.splice(e,3),e-=3,ls(u,{pending:!0,data:a,method:l.method,action:n},n,a))}}))}function Ya(t){function e(p){return Ji(p,t)}An!==null&&Ji(An,t),Tn!==null&&Ji(Tn,t),zn!==null&&Ji(zn,t),wu.forEach(e),Ou.forEach(e);for(var l=0;l<Dn.length;l++){var n=Dn[l];n.blockedOn===t&&(n.blockedOn=null)}for(;0<Dn.length&&(l=Dn[0],l.blockedOn===null);)e0(l),l.blockedOn===null&&Dn.shift();if(l=(t.ownerDocument||t).$$reactFormReplay,l!=null)for(n=0;n<l.length;n+=3){var a=l[n],u=l[n+1],i=a[ze]||null;if(typeof u=="function")i||n0(l);else if(i){var o=null;if(u&&u.hasAttribute("formAction")){if(a=u,i=u[ze]||null)o=i.formAction;else if(no(a)!==null)continue}else o=i.action;typeof o=="function"?l[n+1]=o:(l.splice(n,3),n-=3),n0(l)}}}function a0(){function t(u){u.canIntercept&&u.info==="react-transition"&&u.intercept({handler:function(){return new Promise(function(i){return a=i})},focusReset:"manual",scroll:"manual"})}function e(){a!==null&&(a(),a=null),n||setTimeout(l,20)}function l(){if(!n&&!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 n=!1,a=null;return navigation.addEventListener("navigate",t),navigation.addEventListener("navigatesuccess",e),navigation.addEventListener("navigateerror",e),setTimeout(l,100),function(){n=!0,navigation.removeEventListener("navigate",t),navigation.removeEventListener("navigatesuccess",e),navigation.removeEventListener("navigateerror",e),a!==null&&(a(),a=null)}}}function uo(t){this._internalRoot=t}Wi.prototype.render=uo.prototype.render=function(t){var e=this._internalRoot;if(e===null)throw Error(f(409));var l=e.current,n=$e();$d(l,n,t,e,null,null)},Wi.prototype.unmount=uo.prototype.unmount=function(){var t=this._internalRoot;if(t!==null){this._internalRoot=null;var e=t.containerInfo;$d(t.current,2,null,t,null,null),Ni(),e[ml]=null}};function Wi(t){this._internalRoot=t}Wi.prototype.unstable_scheduleHydration=function(t){if(t){var e=hl();t={blockedOn:null,target:t,priority:e};for(var l=0;l<Dn.length&&e!==0&&e<Dn[l].priority;l++);Dn.splice(l,0,t),l===0&&e0(t)}};var u0=r.version;if(u0!=="19.2.8")throw Error(f(527,u0,"19.2.8"));q.findDOMNode=function(t){var e=t._reactInternals;if(e===void 0)throw typeof t.render=="function"?Error(f(188)):(t=Object.keys(t).join(","),Error(f(268,t)));return t=x(e),t=t!==null?L(t):null,t=t===null?null:t.stateNode,t};var Gh={bundleType:0,version:"19.2.8",rendererPackageName:"react-dom",currentDispatcherRef:z,reconcilerVersion:"19.2.8"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Fi=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Fi.isDisabled&&Fi.supportsFiber)try{ve=Fi.inject(Gh),ie=Fi}catch{}}return Uu.createRoot=function(t,e){if(!d(t))throw Error(f(299));var l=!1,n="",a=dr,u=hr,i=mr;return e!=null&&(e.unstable_strictMode===!0&&(l=!0),e.identifierPrefix!==void 0&&(n=e.identifierPrefix),e.onUncaughtError!==void 0&&(a=e.onUncaughtError),e.onCaughtError!==void 0&&(u=e.onCaughtError),e.onRecoverableError!==void 0&&(i=e.onRecoverableError)),e=Kd(t,1,!1,null,null,l,n,null,a,u,i,a0),t[ml]=e.current,Ys(t),new uo(e)},Uu.hydrateRoot=function(t,e,l){if(!d(t))throw Error(f(299));var n=!1,a="",u=dr,i=hr,o=mr,p=null;return l!=null&&(l.unstable_strictMode===!0&&(n=!0),l.identifierPrefix!==void 0&&(a=l.identifierPrefix),l.onUncaughtError!==void 0&&(u=l.onUncaughtError),l.onCaughtError!==void 0&&(i=l.onCaughtError),l.onRecoverableError!==void 0&&(o=l.onRecoverableError),l.formState!==void 0&&(p=l.formState)),e=Kd(t,1,!0,e,l??null,n,a,p,u,i,o,a0),e.context=Jd(null),l=e.current,n=$e(),n=nn(n),a=hn(n),a.callback=null,mn(l,a,n),l=n,e.current.lanes=l,_n(e,l),wl(e),t[ml]=e.current,Ys(t),new Wi(e)},Uu.version="19.2.8",Uu}var g0;function Fh(){if(g0)return so.exports;g0=1;function c(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(c)}catch(r){console.error(r)}}return c(),so.exports=Wh(),so.exports}var Ih=Fh();function ho(c,r,m){return c+(r-c)*m}function A0(c){return c-Math.floor(c)}function mo(c,r){const m=Math.floor(c),f=Math.floor(r);let d=c-m,y=r-f;d=d*d*(3-2*d),y=y*y*(3-2*y);const E=ol(m,f),A=ol(m+1,f),D=ol(m,f+1),x=ol(m+1,f+1);return E+(A-E)*d+(D-E)*y+(E-A-D+x)*d*y}function ol(c,r){const m=Math.sin(c*12.9898+r*78.233)*43758.5453;return m-Math.floor(m)}function To(c,r){const m=Math.PI*(3-Math.sqrt(5)),f=1-2*(c+.5)/r,d=Math.sqrt(1-f*f),y=c*m;return[d*Math.cos(y),f,d*Math.sin(y)]}function Ph(c,r){return Math.atan2(Math.sin(c-r),Math.cos(c-r))}function ta(c,r,m,f,d){const y=Math.sin(r),E=Math.cos(r),A=Math.sin(c),D=Math.cos(c);return(x,L,H)=>{const G=x*D+H*A,Y=-x*A+H*D,X=L*E-Y*y,F=L*y+Y*E;return[m+G*d,f-X*d,F]}}function Nn(c,r,m,f=.3){r.sort((d,y)=>d.z-y.z);for(const d of r){const y=d.a??1;if(y<.02)continue;const E=Math.min(1,Math.max(0,d.white)),A=Math.round((m?1-E:E)*255);c.fillStyle=`rgba(${A},${A},${A},${y})`,c.beginPath(),c.arc(d.x,d.y,Math.max(f,d.r),0,Math.PI*2),c.fill()}}function tm(c,r,m){for(const f of r){const d=f.a??1;if(d<.02)continue;const y=Math.min(1,Math.max(0,f.white)),E=Math.round((m?1-y:y)*255);c.strokeStyle=`rgba(${E},${E},${E},${d})`,c.lineWidth=f.w,c.beginPath(),c.moveTo(f.x1,f.y1),c.lineTo(f.x2,f.y2),c.stroke()}}function ea(c,r){return(c/300)**r}const em=(c,r,m,f,d)=>{const y=r/2,E=r/2,A=r/2*.76,D=ta(m*.4,.3,y,E,1),x=ea(r,d.rsPow??.6),L=[],H=d.ghostN??150;for(let X=0;X<H;X++){const F=To(X,H),[dt,g,Q]=D(F[0]*A,F[1]*A,F[2]*A),I=(Q/A+1)/2;L.push({x:dt,y:g,z:Q,r:.8*x,white:.78,a:.1+.22*I})}const G=d.strandN??52,Y=d.turns??3;for(let X=0;X<3;X++){const F=X/3*2*Math.PI;for(let dt=0;dt<G;dt++){const g=(A0(dt/G+m*.045)*2-1)*.96,Q=Math.sqrt(Math.max(0,1-g*g)),I=Math.min(1,(1-Math.abs(g))/.1),et=g*Math.PI*Y+F,lt=1+.075*Math.sin(g*Math.PI*Y*2+F*2+m*.8),P=Q*A*lt,[J,nt,it]=D(Math.cos(et)*P,g*A*lt,Math.sin(et)*P),ut=(it/A+1)/2;L.push({x:J,y:nt,z:it,r:((d.rBase??1.2)+(d.rDepth??1.8)*ut)*x,white:.55-.45*ut,a:I*(.45+.55*ut)})}}Nn(c,L,f,d.rMin)};function lm(c,r,m,f){const d=2*r*m+f,y=c%d,E=new Array(r).fill(0);let A=-1;if(y<2*r*m){const D=Math.floor(y/m),x=(y-D*m)/m,L=1-(1-Math.min(1,x/.7))**3;if(D<r){for(let H=0;H<D;H++)E[H]=1;E[D]=L,A=D}else{const H=2*r-1-D;for(let G=0;G<H;G++)E[G]=1;E[H]=1-L,A=H}}return{amount:E,active:A}}function nm(c,r,m){let[f,d,y]=c,E=!1;for(let A=0;A<r.length;A++){if(m.amount[A]<=0)continue;const D=r[A],x=D.axis===0?f:D.axis===1?d:y;if(x<D.lo||x>=D.hi)continue;A===m.active&&(E=!0);const L=D.ang*m.amount[A],H=Math.cos(L),G=Math.sin(L);if(D.axis===0){const Y=d*H-y*G;y=d*G+y*H,d=Y}else if(D.axis===1){const Y=f*H+y*G;y=-f*G+y*H,f=Y}else{const Y=f*H-d*G;d=f*G+d*H,f=Y}}return[f,d,y,E]}function am(c){const r=[];for(let m=0;m<c;m++){const f=Math.min(2,Math.floor(ol(m,2.3)*3)),d=-1+.5*Math.min(3,Math.floor(ol(m,5.9)*4)),y=ol(m,7.7)<.5?1:-1;r.push({axis:f,lo:d,hi:d+.5,ang:y*Math.PI/2})}return r}const um=(c,r,m,f,d)=>{const y=r/2,E=r/2,A=r/2*.82,D=.4+.06*Math.sin(m*.35),x=ta(m*.5,D,y,E,A),L=m*(.5+(1.7-.5)*(d.scanMul??1)),H=ea(r,d.rsPow??.6),G=d.dimBase??1,Y=[],X=d.latRings??17,F=d.lonDensity??44;for(let dt=0;dt<=X;dt++){const g=-Math.PI/2+dt/X*Math.PI,Q=Math.cos(g),I=Math.sin(g),et=Math.max(1,Math.round(Math.abs(Q)*F));for(let lt=0;lt<et;lt++){const P=lt/et*2*Math.PI,[J,nt,it]=x(Q*Math.cos(P),I,Q*Math.sin(P)),ut=(it+1)/2,xt=Ph(P+m*.5,L),gt=Math.exp(-(xt*xt)/.18)*Math.max(0,it);Y.push({x:J,y:nt,z:it,r:((d.rBase??.6)+(d.rDepth??1.7)*ut+(d.rBoost??1)*gt)*H,white:(d.inkFar??.62)-(d.inkSpan??.54)*ut,a:G+(1-G)*Math.min(1,gt)})}}Nn(c,Y,f,d.rMin)},im=(c,r,m,f,d)=>{const y=r/2,E=r/2,A=r/2*.82,D=ta(m*.55,.35+.1*Math.sin(m*.9),y,E,A),x=ea(r,d.rsPow??.6),L=d.moveCount??14,H=am(L),G=lm(m,L,.42,1.2),Y=[],X=d.latRings??15,F=d.lonDensity??40;for(let dt=0;dt<=X;dt++){const g=-Math.PI/2+dt/X*Math.PI,Q=Math.cos(g),I=Math.sin(g),et=Math.max(1,Math.round(Math.abs(Q)*F));for(let lt=0;lt<et;lt++){const P=lt/et*2*Math.PI,[J,nt,it,ut]=nm([Q*Math.cos(P),I,Q*Math.sin(P)],H,G),[xt,gt,Ht]=D(J,nt,it),pt=(Ht+1)/2;Y.push({x:xt,y:gt,z:Ht,r:((d.rBase??.6)+(d.rDepth??1.7)*pt+(ut?d.rActive??.3:0))*x,white:(d.inkFar??.62)-(d.inkSpan??.54)*pt-(ut?.14:0)})}}Nn(c,Y,f,d.rMin)},cm=(c,r,m,f,d)=>{const y=r/2,E=r/2,A=r/2*.874,D=ta(m*.18,.38,y,E,1),x=ea(r,d.rsPow??.6),L=[],H=d.rings??15,G=d.lonDensity??40;for(let Y=0;Y<=H;Y++){const X=-Math.PI/2+Y/H*Math.PI,F=Math.cos(X),dt=Math.sin(X),g=.62*Math.sin(m*2.1-Y*.52)+.38*Math.sin(m*1.27+Y*.83),Q=A*(.88+.105*g),I=Math.max(1,Math.round(Math.abs(F)*G));for(let et=0;et<I;et++){const lt=et/I*2*Math.PI,[P,J,nt]=D(F*Math.cos(lt)*Q,dt*Q,F*Math.sin(lt)*Q),it=(nt/A+1)/2,ut=Math.max(0,g);L.push({x:P,y:J,z:nt,r:((d.rBase??.6)+(d.rDepth??1.7)*it)*(1+.4*ut)*x,white:.66-.56*it-.1*ut})}}Nn(c,L,f,d.rMin)};function sm(c){return c*c*(3-2*c)}function T0(c){const r=c.length,m=[];let f=0;for(let d=0;d<r;d++){const y=c[d],E=c[(d+1)%r],A=Math.hypot(E[0]-y[0],E[1]-y[1]);m.push(A),f+=A}return d=>{let y=d*f,E=0;for(;y>m[E]&&E<r-1;)y-=m[E],E++;const A=c[E],D=c[(E+1)%r],x=m[E]?Math.min(1,y/m[E]):0;return[A[0]+(D[0]-A[0])*x,A[1]+(D[1]-A[1])*x]}}const om=c=>{const r=-Math.PI/2+c*2*Math.PI;return[Math.cos(r)*.24,Math.sin(r)*.24]},fm=T0([[0,-.26],[.24,.16],[-.24,.16]]),rm=T0([[0,-.2],[.2,-.2],[.2,.2],[-.2,.2],[-.2,-.2]]),go=[om,fm,rm];function dm(c){return Math.max(6,Math.round(34*c))}const Mo=1.4,z0=.9,po=Mo+z0,hm=(c,r,m,f,d)=>{const y=go.length,E=m%(po*y),A=Math.floor(E/po),D=E-A*po,x=D>Mo?sm((D-Mo)/z0):0,L=d.spread??1,H=go[A],G=go[(A+1)%y],Y=160,X=[];for(let nt=0;nt<Y;nt++){const it=nt/Y,ut=H(it),xt=G(it);X.push([(ut[0]+(xt[0]-ut[0])*x)*L,(ut[1]+(xt[1]-ut[1])*x)*L])}const F=[];let dt=0;for(let nt=0;nt<Y;nt++){const it=X[nt],ut=X[(nt+1)%Y],xt=Math.hypot(ut[0]-it[0],ut[1]-it[1]);F.push(xt),dt+=xt}const g=dm(d.iconD??1),Q=(d.rDot??.021)*1.35*L,I=1+.02*Math.sin(D*3.1),et=[],lt=r/2;let P=0,J=0;for(let nt=0;nt<g;nt++){const it=nt/g*dt;for(;J+F[P]<it&&P<Y-1;)J+=F[P],P++;const ut=X[P],xt=X[(P+1)%Y],gt=F[P]?Math.min(1,(it-J)/F[P]):0,Ht=(ut[0]+(xt[0]-ut[0])*gt)*I,pt=(ut[1]+(xt[1]-ut[1])*gt)*I;et.push({x:lt+Ht*r,y:lt+pt*r,z:0,r:Math.max(.35,Q*r),white:.1})}Nn(c,et,f,d.rMin)},mm=(c,r,m,f,d)=>{const y=r/2,E=r/2,A=r/2*.82,D=ta(m*.12,.3,y,E,1),x=ea(r,d.rsPow??.6),L=[],H=d.orbitN??12,G=d.ghostN??40,Y=d.particles??3;for(let X=0;X<H;X++){const F=ol(X,1.7),dt=ol(X,5.2),g=ol(X,8.9),Q=A*(.45+.52*F),I=F*2*Math.PI,et=Math.acos(2*dt-1),lt=Math.sin(et)*Math.cos(I),P=Math.cos(et),J=Math.sin(et)*Math.sin(I);let nt=-P,it=lt;const ut=0,xt=Math.max(1e-6,Math.sqrt(nt*nt+it*it));nt/=xt,it/=xt;const gt=P*ut-J*it,Ht=J*nt-lt*ut,pt=lt*it-P*nt,$t=(.25+.55*g)*(g>.5?1:-1);for(let z=0;z<G;z++){const q=z/G*2*Math.PI,[$,yt,Mt]=D((nt*Math.cos(q)+gt*Math.sin(q))*Q,(it*Math.cos(q)+Ht*Math.sin(q))*Q,(ut*Math.cos(q)+pt*Math.sin(q))*Q),v=(Mt/Q+1)/2;L.push({x:$,y:yt,z:Mt,r:(d.ghostR??.9)*x,white:.72,a:(d.ghostA??.5)*(.4+.6*v)})}for(let z=0;z<Y;z++){const q=m*$t+z/Y*2*Math.PI+dt*6,[$,yt,Mt]=D((nt*Math.cos(q)+gt*Math.sin(q))*Q,(it*Math.cos(q)+Ht*Math.sin(q))*Q,(ut*Math.cos(q)+pt*Math.sin(q))*Q),v=(Mt/Q+1)/2;L.push({x:$,y:yt,z:Mt,r:((d.partR??1.2)+(d.partRDepth??1.6)*v)*x,white:.3-.22*v})}}Nn(c,L,f,d.rMin)},p0=(c,r,m,f,d)=>{const y=r/2,E=r/2,A=r/2*.78,D=d.spin??1,x=.3,L=ta(m*.1*D,x,y,E,1),H=ea(r,d.rsPow??.6),G=[],Y=d.ghostN??150;for(let pt=0;pt<Y;pt++){const $t=To(pt,Y),[z,q,$]=L($t[0]*A,$t[1]*A,$t[2]*A),yt=($/A+1)/2;G.push({x:z,y:q,z:$,r:.8*H,white:.78,a:.1+.22*yt})}const X=m*.24*D,F=d.faceOn?-x:.55+.3*Math.sin(m*.18)*D,dt=Math.cos(X),g=0,Q=Math.sin(X),I=-Q*Math.sin(F),et=Math.cos(F),lt=dt*Math.sin(F),P=g*lt-Q*et,J=Q*I-dt*lt,nt=dt*et-g*I,it=.23*(d.wobMul??1),ut=d.faceOn?A/(1+.85*it):A,xt=d.lanes??5,gt=d.segs??88,Ht=Math.max(1,Math.round(xt*(d.bandMul??1)));for(let pt=0;pt<Ht;pt++){const $t=(pt-(Ht-1)/2)*.075,z=Math.abs(pt-(Ht-1)/2)/Math.max(1,(Ht-1)/2);for(let q=0;q<gt;q++){const $=q/gt*2*Math.PI,yt=(.16*Math.sin($*3-m*1.7+pt*.22)+.07*Math.sin($*5+m*1.1))*(d.wobMul??1),Mt=d.faceOn?1+yt:1,v=d.faceOn?$t:$t+yt,N=dt*Math.cos($)+I*Math.sin($)+P*v,k=g*Math.cos($)+et*Math.sin($)+J*v,V=Q*Math.cos($)+lt*Math.sin($)+nt*v,ot=Math.sqrt(N*N+k*k+V*V),ft=ut*Mt,[Tt,Vt,wt]=L(N/ot*ft,k/ot*ft,V/ot*ft),Oe=(wt/A+1)/2;G.push({x:Tt,y:Vt,z:wt,r:((d.rBase??1.1)+(d.rDepth??1.7)*Oe)*(1-.25*z)*H,white:.52-.44*Oe+.18*z,a:.4+.6*Oe})}}Nn(c,G,f,d.rMin)},gm=(c,r,m,f,d)=>{const y=r/2,E=r/2,A=r/2*.8*(d.spread??1),D=ta(m*.12,.32,y,E,A),x=ea(r,d.rsPow??.6),L=d.nodeN??30,H=d.thr??.72,G=d.nodeR??1.4,Y=d.nodeRDepth??1.8,X=[];for(let Q=0;Q<L;Q++){const I=To(Q,L),et=I[0]+.3*(mo(Q*.31+9,m*.24)-.5)*2,lt=I[1]+.3*(mo(Q*.53+27,m*.21)-.5)*2,P=I[2]+.3*(mo(Q*.77+55,m*.27)-.5)*2,J=Math.sqrt(et*et+lt*lt+P*P);X.push([et/J,lt/J,P/J])}const F=[],dt=[];for(let Q=0;Q<L;Q++)for(let I=Q+1;I<L;I++){const et=X[Q][0]-X[I][0],lt=X[Q][1]-X[I][1],P=X[Q][2]-X[I][2],J=Math.sqrt(et*et+lt*lt+P*P);if(J>=H)continue;const[nt,it,ut]=D(X[Q][0],X[Q][1],X[Q][2]),[xt,gt,Ht]=D(X[I][0],X[I][1],X[I][2]),pt=((ut+Ht)/2+1)/2;F.push({x1:nt,y1:it,x2:xt,y2:gt,white:.42,a:(1-J/H)*(.3+.55*pt),w:Math.max(.6,(d.lineW??.8)*x)})}for(let Q=0;Q<L;Q++){const[I,et,lt]=D(X[Q][0],X[Q][1],X[Q][2]),P=(lt+1)/2,J=1+.25*Math.sin(m*1.4+Q*2.7);dt.push({x:I,y:et,z:lt,r:(G+Y*P)*J*x,white:.55-.45*P})}const g=d.signals??5;for(let Q=0;Q<g;Q++){const I=Math.floor(m*.55+Q*7.31),et=Math.floor(ol(I,Q*3.1+1.7)*L),lt=Math.floor(ol(I,Q*5.7+4.2)*L);if(et===lt)continue;const P=A0(m*.55+Q*7.31),J=ho(X[et][0],X[lt][0],P),nt=ho(X[et][1],X[lt][1],P),it=ho(X[et][2],X[lt][2],P),ut=Math.max(1e-6,Math.sqrt(J*J+nt*nt+it*it)),[xt,gt,Ht]=D(J/ut,nt/ut,it/ut),pt=(Ht+1)/2;dt.push({x:xt,y:gt,z:Ht,r:(G*1.5+Y*pt)*x,white:.05,a:.5+.5*pt})}tm(c,F,f),Nn(c,dt,f,d.rMin)},pm={orbits:mm,globe:um,rubik:im,wave:cm,web:gm,braid:em,ribbon:p0,ring:p0,morph:hm},ym=[["latRings","lonDensity"],["rings","lonDensity"],["lanes","segs"]],vm=["orbitN","ghostN","nodeN","strandN","signals"],bm=["iconD"],xm=["rBase","rDepth","rActive","rDot","ghostR","partR","partRDepth","nodeR","nodeRDepth"];function Sm(c,r){const m={...c},f=new Set,d=Math.sqrt(r);for(const[y,E]of ym){const A=m[y],D=m[E];A!=null&&D!=null&&!f.has(y)&&!f.has(E)&&(m[y]=Math.max(2,Math.round(A*d)),m[E]=Math.max(2,Math.round(D*d)),f.add(y),f.add(E))}for(const y of vm){const E=m[y];E!=null&&E!==0&&!f.has(y)&&(m[y]=Math.max(1,Math.round(E*r)))}for(const y of bm){const E=m[y];E!=null&&(m[y]=Math.max(.02,E*r))}return m}function Em(c,r){const m={...c};for(const f of xm){const d=m[f];d!=null&&(m[f]=d*r)}return m.rSizeMul=(m.rSizeMul??1)*r,m}const Mm={globe:{latRings:17,lonDensity:44,rBase:.6,rDepth:1.7,rBoost:1,inkFar:.62,inkSpan:.54,rsPow:.6,rMin:.3},orbits:{orbitN:12,ghostN:40,ghostR:.9,ghostA:.5,particles:3,partR:1.2,partRDepth:1.6,rsPow:.6,rMin:.3},rubik:{latRings:15,lonDensity:40,moveCount:14,rBase:.6,rDepth:1.7,rActive:.3,inkFar:.62,inkSpan:.54,rsPow:.6,rMin:.3},wave:{rings:15,lonDensity:40,rBase:.6,rDepth:1.7,rsPow:.6,rMin:.3},web:{nodeN:30,thr:.72,signals:5,nodeR:1.4,nodeRDepth:1.8,lineW:.8,rsPow:.6,rMin:.3},braid:{strandN:52,turns:3,ghostN:150,rBase:1.2,rDepth:1.8,rsPow:.6,rMin:.3},ribbon:{lanes:5,segs:88,ghostN:150,rBase:1.1,rDepth:1.7,rsPow:.6,rMin:.3},ring:{lanes:5,segs:88,ghostN:0,faceOn:1,rBase:1.1,rDepth:1.7,rsPow:.6,rMin:.3},morph:{rDot:.021,iconD:1,rMin:.25}},Cm={working:"orbits",searching:"globe",solving:"rubik",listening:"wave",connecting:"web",weaving:"braid",composing:"ribbon",breathing:"ring",shaping:"morph"},Am={orbits:{64:{speed:1.885,count:1,size:1},20:{speed:3.9,count:.238,size:2.4}},globe:{64:{speed:2.015,count:.42,size:1.15,extra:{scanMul:4.08,dimBase:.45}},20:{speed:2.665,count:.105,size:1.75,extra:{scanMul:4.335,dimBase:.45}}},rubik:{64:{speed:1.82,count:.35,size:1.05},20:{speed:1.95,count:.088,size:1.9}},wave:{64:{speed:4.388,count:.341,size:1},20:{speed:3.998,count:.105,size:1.6}},web:{64:{speed:3.315,count:1.35,size:.95},20:{speed:6.63,count:.25,size:1.52}},braid:{64:{speed:1.625,count:.5,size:1},20:{speed:2.75,count:.1125,size:1.36}},ribbon:{64:{speed:2.34,count:.25,size:.85,extra:{spin:0,bandMul:3.9,wobMul:1}},20:{speed:3.12,count:.051,size:1.073,extra:{spin:0,bandMul:4.94,wobMul:1}}},ring:{64:{speed:3.24,count:.25,size:.956,extra:{spin:0,bandMul:3.627,wobMul:.368}},20:{speed:3.78,count:.028,size:1.622,extra:{spin:0,bandMul:3.968,wobMul:.565}}},morph:{64:{speed:2.405,count:.702,size:.395,extra:{spread:1.45}},20:{speed:2.08,count:.53,size:1.011,extra:{spread:1.45}}}},y0=new Map;function Tm(c,r){const m=`${c}-${r}`,f=y0.get(m);if(f)return f;const d=Cm[c],y=Am[d][r];let E={...Mm[d]};y.count!==1&&(E=Sm(E,y.count)),y.size!==1&&(E=Em(E,y.size)),y.extra&&(E={...E,...y.extra});const A={mode:d,speed:y.speed,opts:E};return y0.set(m,A),A}function zm(c){let r=c;for(;r;){const m=r.getAttribute("data-theme");if(m==="dark")return!0;if(m==="light")return!1;if(r.classList.contains("dark"))return!0;if(r.classList.contains("light"))return!1;r=r.parentElement}return null}function Dm(){return typeof matchMedia>"u"||matchMedia("(prefers-color-scheme: dark)").matches}function jm(c,r){const[m,f]=R.useState(!0);return R.useEffect(()=>{if(c==="dark"){f(!0);return}if(c==="light"){f(!1);return}const d=()=>{const D=zm(r.current);f(D??Dm())};d();const y=typeof matchMedia<"u"?matchMedia("(prefers-color-scheme: dark)"):null,E=()=>d();y?.addEventListener("change",E);let A=null;return typeof MutationObserver<"u"&&r.current&&(A=new MutationObserver(d),A.observe(document.documentElement,{attributes:!0,attributeFilter:["class","data-theme"],subtree:!0})),()=>{y?.removeEventListener("change",E),A?.disconnect()}},[c,r]),m}function Nm(){const[c,r]=R.useState(!1);return R.useEffect(()=>{if(typeof matchMedia>"u")return;const m=matchMedia("(prefers-reduced-motion: reduce)");r(m.matches);const f=d=>r(d.matches);return m.addEventListener("change",f),()=>m.removeEventListener("change",f)},[]),c}const wm={working:"Working…",searching:"Searching…",solving:"Solving…",listening:"Listening…",connecting:"Connecting…",weaving:"Weaving…",composing:"Composing…",breathing:"Thinking…",shaping:"Shaping…"};function D0({state:c="working",size:r=64,theme:m="auto",speed:f=1,paused:d=!1,style:y,"aria-label":E,...A}){const D=R.useRef(null),x=jm(m,D),L=Nm();return R.useEffect(()=>{const H=D.current;if(!H)return;const G=Math.min(2,typeof devicePixelRatio<"u"&&devicePixelRatio||1);H.width=Math.round(r*G),H.height=Math.round(r*G);const Y=H.getContext("2d");if(!Y)return;const{mode:X,speed:F,opts:dt}=Tm(c,r),g=pm[X],Q=F*f,I=gt=>{Y.setTransform(G,0,0,G,0,0),Y.clearRect(0,0,r,r),g(Y,r,gt,x,dt)};if(L){I(.6);return}let et=0,lt=!1;const P=()=>{I(performance.now()/1e3*Q),lt&&(et=requestAnimationFrame(P))},J=()=>{lt||d||(lt=!0,et=requestAnimationFrame(P))},nt=()=>{lt=!1,cancelAnimationFrame(et)};I(performance.now()/1e3*Q);let it=!0;const ut=typeof IntersectionObserver<"u"?new IntersectionObserver(([gt])=>{it=gt.isIntersecting,it&&document.visibilityState!=="hidden"?J():nt()}):null;ut?.observe(H);const xt=()=>{document.visibilityState==="hidden"?nt():it&&J()};return document.addEventListener("visibilitychange",xt),ut||J(),()=>{nt(),ut?.disconnect(),document.removeEventListener("visibilitychange",xt)}},[c,r,x,f,d,L]),s.jsx("canvas",{ref:D,role:"img","aria-label":E??wm[c],style:{width:r,height:r,display:"block",...y},...A})}const yo=["searching","solving","composing","breathing","shaping"];function Om(c){const r=Math.floor(c*yo.length);return yo[Math.min(yo.length-1,Math.max(0,r))]}const j0=Om(Math.random()),Pn="ease-[cubic-bezier(0.32,0.72,0,1)]",N0=274,w0=395,O0=368,_0=[{label:"Full",width:null},{label:"1440",width:1440},{label:"834",width:834},{label:"390",width:390}],Il={agentPickerDismissed:!1,collapsed:!1,collapsedFamilies:[],deleted:[],corner:"bottom-right",font:"satoshi",hidden:[],order:[],renames:{},scaleSplit:!0,showDevOverlays:!0,showWidget:!0,viewport:null,width:O0};function _m(c){return`leglas:${c}`}function Rm(c,r){const m=r.map(f=>f.title);try{if(!c)return{...Il,order:m};const f=JSON.parse(c),d={...Il,...f},y=(Array.isArray(d.deleted)?d.deleted:[]).filter(x=>m.includes(x)),E=m.filter(x=>!y.includes(x)),A=(Array.isArray(d.order)?d.order:[]).filter(x=>E.includes(x)),D=["bottom-left","bottom-right","top-left","top-right"];return{agentPickerDismissed:typeof f.agentPickerDismissed=="boolean"?f.agentPickerDismissed:Il.agentPickerDismissed,collapsed:!!d.collapsed,collapsedFamilies:(Array.isArray(d.collapsedFamilies)?d.collapsedFamilies:[]).filter(x=>E.includes(x)),corner:D.includes(d.corner)?d.corner:Il.corner,deleted:y,font:typeof d.font=="string"?d.font:Il.font,hidden:(Array.isArray(d.hidden)?d.hidden:[]).filter(x=>E.includes(x)),order:[...A,...E.filter(x=>!A.includes(x))],renames:Object.fromEntries(Object.entries(d.renames??{}).filter(([x])=>E.includes(x))),scaleSplit:typeof f.scaleSplit=="boolean"?f.scaleSplit:Il.scaleSplit,showDevOverlays:typeof f.showDevOverlays=="boolean"?f.showDevOverlays:Il.showDevOverlays,showWidget:typeof f.showWidget=="boolean"?f.showWidget:Il.showWidget,viewport:_0.some(x=>x.width===d.viewport)?d.viewport:null,width:Number.isFinite(d.width)?Math.round(Math.min(w0,Math.max(N0,d.width))):O0}}catch{return{...Il,order:m}}}function Um(c,r){const m=new Set(r),f=Object.fromEntries(Object.entries(c.renames).filter(([d])=>!m.has(d)));return{...c,collapsedFamilies:c.collapsedFamilies.filter(d=>!m.has(d)),deleted:[...new Set([...c.deleted,...r])],hidden:c.hidden.filter(d=>!m.has(d)),order:c.order.filter(d=>!m.has(d)),renames:f}}function Hm(c,r){if(c.length===0)return[...r];const m=new Set(r),f=c.filter(y=>m.has(y)),d=new Set(f);return[...f,...r.filter(y=>!d.has(y))]}function Bm(c,r,m,f){const d=r.map(x=>x.title),y=(c.order.length?c.order:d).filter(x=>x!==m),A=y.filter(x=>!c.hidden.includes(x))[f],D=A===void 0?y.length:y.indexOf(A);return y.splice(D,0,m),y}const R0=8,qm=8;function Lm(c,r,m=R0){return c.left<m?m-c.left:c.right>r-m?Math.max(m-c.left,r-m-c.right):0}function Ym(c,r,m,f=R0){if(c.top>=f)return!1;const d=c.bottom-c.top;return r.bottom+f+d<=m-f}function Gm(c,r,m,f){const d=c.at==="right"?c.x:c.x-r.width/2,y=c.at==="top"?c.y-r.height:c.at==="bottom"?c.y:c.y-r.height/2,E={bottom:y+r.height,left:d,right:d+r.width,top:y};if(c.at==="top"&&Ym(E,m,f.height))return{at:"bottom",shift:c.shift,y:m.bottom+qm};const A=Lm(E,f.width);return A===c.shift?null:{at:c.at,shift:A,y:c.y}}function Ii({size:c=18}){return s.jsxs("svg",{"aria-hidden":!0,height:c,strokeLinejoin:"round",strokeWidth:22,viewBox:"160 370 1050 1320",width:Math.round(c*(1050/1320)),children:[s.jsxs("defs",{children:[s.jsxs("linearGradient",{gradientUnits:"userSpaceOnUse",id:"lm-up",x1:"791.957",x2:"210",y1:"723.095",y2:"1010",children:[s.jsx("stop",{offset:"0",stopColor:"#7C38E8"}),s.jsx("stop",{offset:"0.68",stopColor:"#CDB6F1"}),s.jsx("stop",{offset:"1",stopColor:"#E9E0FA"})]}),s.jsxs("linearGradient",{gradientUnits:"userSpaceOnUse",id:"lm-down",x1:"789.954",x2:"210",y1:"1330.46",y2:"1035",children:[s.jsx("stop",{offset:"0",stopColor:"#3EC2A8"}),s.jsx("stop",{offset:"0.68",stopColor:"#9EDAE8"}),s.jsx("stop",{offset:"1",stopColor:"#E1F2F6"})]}),s.jsxs("linearGradient",{gradientUnits:"userSpaceOnUse",id:"lm-shaft",x1:"884.016",x2:"182",y1:"1023.26",y2:"1023.26",children:[s.jsx("stop",{offset:"0",stopColor:"#7E97DD"}),s.jsx("stop",{offset:"0.48",stopColor:"#5F7FD8"}),s.jsx("stop",{offset:"0.71",stopColor:"#9AABE2"}),s.jsx("stop",{offset:"1",stopColor:"#E2E8F6"})]}),s.jsxs("linearGradient",{gradientUnits:"userSpaceOnUse",id:"lm-head",x1:"1192",x2:"874.81",y1:"1021.57",y2:"1024.91",children:[s.jsx("stop",{offset:"0",stopColor:"#E8ECF7"}),s.jsx("stop",{offset:"1",stopColor:"#92A7E0"})]})]}),s.jsx("path",{d:"M 671.122 381.199 C 708.12 378.001 733.579 414.981 702.643 437.984 C 705.64 430.245 708.163 423.315 705.553 415.028 C 700.981 400.516 684.107 396.94 671.252 401.81 C 662.713 405.098 655.849 411.671 652.193 420.059 C 645.933 434.059 649.404 447.111 654.599 460.446 C 665.665 467.718 660.114 472.463 666.664 480.695 C 694.852 516.12 737.817 543.026 774.246 568.848 C 841.225 616.324 905.267 670.31 939.022 747.101 C 953.651 782.815 964.144 815.411 953.49 854.107 C 944.702 886.028 889.413 910.644 901.624 945.63 C 905.247 956.01 926.305 965.294 936.684 957.439 C 947.74 949.072 949.919 942.473 953.06 929.336 C 967.974 962.891 939.504 987.655 907.14 982.376 C 893.109 980.134 880.552 972.384 872.258 960.847 C 839.018 914.253 888.968 876.15 898.307 834.712 C 902.782 814.853 894.952 783.534 888.142 764.672 C 860.48 688.068 798.139 632.327 735.838 583.312 C 700.284 555.045 669.551 529.466 642.632 492.392 C 627.896 510.927 608.893 531.804 593.068 550.006 L 506.523 649.582 L 278.039 912.109 C 245.455 949.199 213.059 986.454 180.851 1023.87 C 231.765 1079.46 283.65 1142.04 333.374 1199.45 L 642.829 1555.74 C 666.446 1520.75 700.163 1494.07 732.424 1467.5 C 795.117 1417.7 858.256 1363.37 887.261 1286.25 C 898.113 1256.93 906.911 1217.89 889.705 1189.06 C 873.478 1161.87 852.143 1132.56 865.539 1099.12 C 871.003 1085.24 881.904 1074.2 895.712 1068.56 C 930.406 1054.52 970.704 1079.86 953.232 1118.88 C 950.548 1106.58 948.459 1099.64 937.837 1091.37 C 926.133 1082.27 907.942 1089.57 901.99 1101.66 C 890.169 1127.27 924.549 1151.85 939.219 1169.81 C 966.471 1203.18 959.658 1245.71 945.71 1284.44 C 914.285 1371.69 840.069 1433.7 765.809 1484.61 C 733.647 1506.66 698.091 1531.58 672.306 1561.08 C 665.933 1568.59 659.014 1581.87 653.634 1590.29 C 648.506 1598.32 647.787 1615.38 650.833 1624.56 C 653.881 1633.77 660.579 1641.32 669.359 1645.45 C 681.85 1651.27 699.281 1649.12 705.041 1634.65 C 708.705 1625.45 705.419 1617.29 701.581 1608.8 L 702.848 1609.85 C 737.88 1638.68 697.51 1681.47 657.106 1662.8 C 643.389 1656.45 632.826 1644.83 627.824 1630.56 C 619.064 1605.85 626.824 1585.32 637.489 1563.26 C 610.659 1534.07 581.755 1498.91 555.456 1468.66 L 383.745 1271.03 L 242.504 1108.25 C 219.223 1081.36 191.596 1051.06 169.707 1023.52 C 181.894 1007.58 201.352 986.522 215.082 970.737 L 301.342 871.646 L 539.659 597.67 C 572.041 560.265 605.914 522.417 637.6 484.482 C 616.356 444.192 617.849 392.637 671.122 381.199 z",fill:"#E8ECF7",stroke:"#E8ECF7"}),s.jsx("path",{d:"M 791.002 712.436 C 791.99 712.378 791.355 712.338 792.831 712.983 C 791.837 718.407 719.488 841.546 710.03 858.509 C 707.23 840.677 702.304 817.013 698.274 799.446 C 555 895 360 995 182 1023 C 355 963 525 870 674.863 761.103 C 659.702 748.905 644.649 736.575 629.704 724.113 C 681.16 722.084 738.984 715.793 791.002 712.436 z",fill:"url(#lm-up)",stroke:"url(#lm-up)"}),s.jsx("path",{d:"M 182 1023 C 360 1051 555 1151 698.326 1248.65 C 702.16 1232.41 707.425 1206.32 709.871 1189.79 C 737.246 1238.39 766.184 1286.55 793.713 1335.16 C 739.167 1331.05 684.598 1327.24 630.009 1323.75 C 644.462 1311.53 659.652 1298.21 674.331 1286.42 C 525 1176 355 1083 182 1023 z",fill:"url(#lm-down)",stroke:"url(#lm-down)"}),s.jsx("path",{d:"M 182 1023.5 L 884.044 1002.33 L 881.311 1004.34 C 882.15 1018.85 886.981 1021.89 881.356 1038.74 C 878.766 1040.79 876.225 1042.9 873.734 1045.08 z",fill:"url(#lm-shaft)",stroke:"url(#lm-shaft)"}),s.jsx("path",{d:"M 1005.63 925.199 L 1121.78 984.34 C 1142.45 994.767 1179.5 1012.52 1198.4 1023.72 L 1070.98 1089.03 C 1051.67 1098.95 1023.69 1114.54 1004.93 1122.53 C 1013.61 1097.65 1022.5 1072.85 1031.59 1048.12 L 873.734 1045.08 C 876.225 1042.9 878.766 1040.79 881.356 1038.74 C 886.981 1021.89 882.15 1018.85 881.311 1004.34 L 884.044 1002.33 L 1030.81 999.036 C 1023.04 976.689 1012.03 947.529 1005.63 925.199 z",fill:"url(#lm-head)",stroke:"url(#lm-head)"})]})}function Xm({height:c=16}){return s.jsxs("svg",{"aria-label":"Leglas",fill:"#E8ECF7",height:c,role:"img",viewBox:"1256 928 642 222",width:Math.round(c*(642/222)),children:[s.jsx("path",{d:"M 1532.93 979.19 C 1552.43 978.051 1561.54 979.865 1574.88 995.12 L 1575.07 981.036 L 1598.92 981.151 L 1598.96 1052.38 C 1598.98 1086.98 1603.87 1127.82 1557.89 1134.37 C 1533.59 1137.83 1517.6 1134.59 1498.35 1119.87 L 1504.96 1108.54 L 1508.69 1102.35 C 1525.04 1114.93 1548.42 1124.68 1566.62 1107.48 C 1575.66 1098.94 1575.05 1084.76 1574.99 1073.16 C 1568.8 1080.06 1562.18 1085.4 1553.24 1088.34 C 1542.19 1091.88 1530.17 1090.79 1519.94 1085.31 C 1486.94 1067.75 1484.12 1009.92 1513.66 987.847 C 1520.32 982.873 1525.18 981.186 1532.93 979.19 z M 1541.52 1000.13 C 1555.85 998.918 1566.45 1003.26 1574.9 1015.05 C 1575.09 1027.93 1574.91 1041.22 1574.89 1054.14 C 1567.52 1063.25 1562.65 1066.25 1551.25 1068.92 C 1511.01 1069.99 1505.34 1012.62 1541.52 1000.13 z",fillRule:"evenodd"}),s.jsx("path",{d:"M 1416.95 979.231 C 1461.09 974.139 1477.7 1004.91 1478.08 1043.29 L 1395.13 1043.56 C 1404.31 1072.49 1429.03 1082.58 1454.48 1064.74 C 1457.34 1062.33 1456.68 1062.04 1459.58 1062.05 C 1464.01 1065.22 1467.95 1071.97 1471.41 1076.59 C 1414.1 1122.22 1344.57 1064.4 1381 1001.64 C 1388.32 989.03 1403.12 982.109 1416.95 979.231 z M 1419.64 998.169 C 1442.21 996.072 1449.85 1006.61 1455.14 1026.51 C 1448.55 1026.96 1438.16 1026.58 1431.31 1026.54 C 1419.15 1026.65 1406.99 1026.63 1394.83 1026.48 C 1398.74 1009.86 1403.7 1003.36 1419.64 998.169 z",fillRule:"evenodd"}),s.jsx("path",{d:"M 1713.27 979.252 C 1728.04 977.573 1745.26 979.123 1756.3 989.97 C 1768.26 1001.72 1767.44 1017.49 1767.31 1032.81 C 1767.15 1051.82 1767.12 1070.77 1767.06 1089.74 L 1757.36 1089.93 C 1733.55 1090.35 1748.04 1086.51 1742.3 1080.97 C 1727.07 1089.66 1714.5 1096.6 1695.79 1090.38 C 1685.07 1086.81 1679.16 1079.18 1674.51 1069.31 C 1663.26 1025.76 1710.42 1008.22 1743.06 1033.45 C 1743.17 1029.64 1743.75 1021.08 1742.89 1017.76 C 1734.81 986.781 1704.35 998.377 1687.37 1012 C 1684.28 1006.47 1681.22 1000.93 1678.2 995.358 C 1689.81 985.727 1698.69 981.852 1713.27 979.252 z M 1714.53 1038.21 C 1726.37 1037.77 1733.38 1039.57 1742.94 1046.21 C 1743.21 1052.09 1743.05 1058.97 1743.05 1064.94 C 1736.15 1071.44 1733.92 1072.52 1724.6 1074.96 C 1709.1 1075.75 1690.77 1070.07 1698.16 1048.49 C 1700.08 1042.9 1708.94 1039.56 1714.53 1038.21 z",fillRule:"evenodd"}),s.jsx("path",{d:"M 1823.29 979.174 C 1843.68 977.649 1857.91 980.343 1873.82 993.561 L 1864.19 1010.31 C 1854.9 1002.37 1842.52 996.264 1830.29 997.499 C 1810.54 999.496 1804.87 1016.41 1827.99 1021.78 C 1853.42 1027.68 1886.98 1035.62 1875.05 1070.07 C 1869.31 1086.64 1852.8 1091.05 1837.21 1092.35 C 1816.02 1092.18 1803.14 1089.58 1786.76 1075.52 L 1797.03 1058.98 C 1810.81 1068.5 1823.36 1075.69 1840.97 1072.95 C 1848.65 1071.76 1856.31 1065.31 1853.69 1057.02 C 1850.58 1049.89 1837.32 1046.22 1830.02 1044.91 C 1802.77 1040.01 1777.57 1024.93 1796.42 994.719 C 1802.7 984.652 1812.04 981.686 1823.29 979.174 z"}),s.jsx("path",{d:"M 1266.98 939.821 L 1293.02 939.95 L 1293.03 1066.58 L 1358.72 1066.65 L 1358.8 1089.73 L 1266.88 1089.69 L 1266.98 939.821 z"}),s.jsx("path",{d:"M 1627.11 939.241 L 1650.97 939.358 L 1650.98 1089.81 L 1627.17 1089.88 C 1626.5 1040.3 1626.89 988.911 1627.11 939.241 z"})]})}const cl={copy:"M216,28H88A12,12,0,0,0,76,40V76H40A12,12,0,0,0,28,88V216a12,12,0,0,0,12,12H168a12,12,0,0,0,12-12V180h36a12,12,0,0,0,12-12V40A12,12,0,0,0,216,28ZM156,204H52V100H156Zm48-48H180V88a12,12,0,0,0-12-12H100V52H204Z",pencil:"M230.14,70.54,185.46,25.85a20,20,0,0,0-28.29,0L33.86,149.17A19.85,19.85,0,0,0,28,163.31V208a20,20,0,0,0,20,20H92.69a19.86,19.86,0,0,0,14.14-5.86L230.14,98.82a20,20,0,0,0,0-28.28ZM91,204H52V165l84-84,39,39ZM192,103,153,64l18.34-18.34,39,39Z",link:"M87.5,151.52l64-64a12,12,0,0,1,17,17l-64,64a12,12,0,0,1-17-17Zm131-114a60.08,60.08,0,0,0-84.87,0L103.51,67.61a12,12,0,0,0,17,17l30.07-30.06a36,36,0,0,1,50.93,50.92L171.4,135.52a12,12,0,1,0,17,17l30.08-30.06A60.09,60.09,0,0,0,218.45,37.55ZM135.52,171.4l-30.07,30.08a36,36,0,0,1-50.92-50.93l30.06-30.07a12,12,0,0,0-17-17L37.55,133.58a60,60,0,0,0,84.88,84.87l30.06-30.07a12,12,0,0,0-17-17Z",search:"M229.66,218.34l-50.07-50.06a88.11,88.11,0,1,0-11.31,11.31l50.06,50.07a8,8,0,0,0,11.32-11.32ZM40,112a72,72,0,1,1,72,72A72.08,72.08,0,0,1,40,112Z",split:"M216,36H40A20,20,0,0,0,20,56V200a20,20,0,0,0,20,20H216a20,20,0,0,0,20-20V56A20,20,0,0,0,216,36ZM44,60h72V196H44ZM212,196H140V60h72Z",sidebar:"M216,36H40A20,20,0,0,0,20,56V200a20,20,0,0,0,20,20H216a20,20,0,0,0,20-20V56A20,20,0,0,0,216,36ZM44,60H76V196H44ZM212,196H100V60H212Z",trash:"M216,48H40a12,12,0,0,0,0,24h4V208a20,20,0,0,0,20,20H192a20,20,0,0,0,20-20V72h4a12,12,0,0,0,0-24ZM188,204H68V72H188ZM76,20A12,12,0,0,1,88,8h80a12,12,0,0,1,0,24H88A12,12,0,0,1,76,20Z"},Hu="flex h-6 w-6 items-center justify-center rounded text-[#D1D5DB] hover:bg-[#2E2E2E] hover:text-white";function vo({on:c}){return s.jsx("span",{"aria-hidden":"true",className:`relative h-3.5 w-6 shrink-0 rounded-full transition-colors duration-150 motion-reduce:transition-none ${c?"bg-[#E6E8EC]":"bg-[#17181B]"}`,children:s.jsx("span",{className:`absolute left-0.5 top-0.5 size-2.5 rounded-full transition-transform duration-150 motion-reduce:transition-none ${c?"translate-x-2.5 bg-[#17181B]":"bg-[#84848C]"}`})})}function sl({d:c,size:r=13}){return s.jsx("svg",{"aria-hidden":!0,fill:"currentColor",height:r,viewBox:"0 0 256 256",width:r,children:s.jsx("path",{d:c})})}let v0=0;function Ge({children:c,label:r,side:m="top"}){const f=R.useRef(null),d=R.useRef(null),y=R.useRef(null),E=R.useRef(null),[A,D]=R.useState(null);R.useLayoutEffect(()=>{const G=d.current,Y=f.current?.firstElementChild;if(!A||A.out||!G||!Y)return;const X=Gm(A,{height:G.offsetHeight,width:G.offsetWidth},Y.getBoundingClientRect(),{height:window.innerHeight,width:window.innerWidth});X&&D(F=>F&&{...F,...X})},[r,A?.at,A?.out,A?.shift,A?.x,A?.y]),R.useEffect(()=>()=>{y.current&&clearTimeout(y.current),E.current&&clearTimeout(E.current)},[]);const x=()=>{const G=f.current?.firstElementChild;if(!G)return;const Y=G.getBoundingClientRect();E.current&&clearTimeout(E.current),D(m==="top"?{at:"top",out:!1,shift:0,x:Y.left+Y.width/2,y:Y.top-8}:{at:"right",out:!1,shift:0,x:Y.right+8,y:Y.top+Y.height/2})},L=()=>{y.current&&clearTimeout(y.current),y.current=setTimeout(x,Date.now()<v0?0:300)},H=()=>{y.current&&clearTimeout(y.current),v0=Date.now()+300,D(G=>G&&!G.out?{...G,out:!0}:G),E.current&&clearTimeout(E.current),E.current=setTimeout(()=>D(null),120)};return s.jsxs("span",{className:"contents",onBlur:H,onFocus:G=>{G.target.matches(":focus-visible")&&x()},onPointerDown:H,onPointerEnter:L,onPointerLeave:H,ref:f,children:[c,A&&s.jsx("span",{"aria-hidden":!0,className:"pointer-events-none fixed z-[60]",style:{left:A.x+A.shift,top:A.y},children:s.jsx("span",{className:`block ${{bottom:"-translate-x-1/2",right:"-translate-y-1/2",top:"-translate-x-1/2 -translate-y-full"}[A.at]}`,children:s.jsx("span",{className:`leglas-tip block whitespace-nowrap rounded-lg border border-white/10 bg-[#171717] px-2 py-1 text-xs font-medium text-white shadow-lg ${A.out?`leglas-tip-out-${A.at}`:`leglas-tip-in-${A.at}`}`,ref:d,children:r})})})]})}function km({error:c,initial:r,label:m,onCancel:f,onCommit:d}){const y=R.useRef(!1);return R.useEffect(()=>{c&&(y.current=!1)}),s.jsx("form",{className:"leglas-rename min-w-0 flex-1",onSubmit:E=>{E.preventDefault();const A=new FormData(E.currentTarget).get("name");y.current=!0,d(typeof A=="string"?A.trim():"","submit")},children:s.jsx("input",{"aria-describedby":c?"leglas-rename-error":void 0,"aria-invalid":c?!0:void 0,"aria-label":m,autoFocus:!0,className:`-mx-1 block w-[calc(100%+0.5rem)] rounded-[4px] bg-transparent px-1 py-0 text-sm font-medium leading-5 text-white outline-none ring-1 ${c?"ring-amber-400/60":"ring-[#D1D5DB]/45 focus:ring-[#D1D5DB]/70"}`,defaultValue:r,name:"name",onBlur:E=>{y.current||d(E.currentTarget.value.trim(),"blur")},onKeyDown:E=>{E.key==="Escape"&&(y.current=!0,f())},type:"text"})})}const Qm={danger:"bg-amber-300",info:"bg-[#9CA3AF]",success:"bg-emerald-300"},Zm=140;function Vm({onDismiss:c,toast:r}){const[m,f]=R.useState(!1),[d,y]=R.useState(!1),[E,A]=R.useState(!1),D=R.useRef(r.ttl),x=R.useRef(null),L=()=>{x.current||(f(!0),x.current=setTimeout(c,Zm))},H=d||E;return R.useEffect(()=>{if(m||H||D.current===null)return;const G=Date.now(),Y=setTimeout(L,D.current);return()=>{clearTimeout(Y),D.current!==null&&(D.current=Math.max(0,D.current-(Date.now()-G)))}},[m,H]),R.useEffect(()=>()=>{x.current&&clearTimeout(x.current)},[]),s.jsxs("li",{className:`pointer-events-auto flex items-start gap-2.5 rounded-lg border border-white/10 bg-[#2E2E2E] px-3 py-2.5 shadow-xl shadow-black/40 ${m?"leglas-toast-out":"leglas-toast-in"}`,onBlur:()=>A(!1),onFocus:()=>A(!0),onPointerEnter:()=>y(!0),onPointerLeave:()=>y(!1),children:[s.jsx("span",{"aria-hidden":!0,className:`mt-[5px] size-1.5 shrink-0 rounded-full ${Qm[r.tone]}`}),s.jsxs("span",{className:"min-w-0 flex-1",children:[s.jsx("span",{className:"block text-xs leading-snug text-[#E8E8EA]",children:r.message}),r.detail?s.jsx("span",{className:"mt-1 block cursor-text select-text break-all text-[10px] leading-snug text-[#9CA3AF]","data-selectable":"",style:{fontFamily:"var(--font-mono)"},children:r.detail}):null]}),r.action?s.jsx("button",{className:"shrink-0 rounded px-1 py-0.5 text-[11px] font-medium text-white underline decoration-white/30 underline-offset-2 transition-colors hover:decoration-white focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-[#D1D5DB]/60",onClick:()=>{r.action?.run(),L()},type:"button",children:r.action.label}):null,s.jsx("button",{"aria-label":"Dismiss",className:"-mr-1 flex size-5 shrink-0 items-center justify-center rounded text-[#84848C] transition-colors hover:bg-white/[0.06] hover:text-white focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-[#D1D5DB]/60",onClick:L,type:"button",children:s.jsx("svg",{className:"size-2.5",fill:"none",stroke:"currentColor",strokeWidth:2,viewBox:"0 0 10 10",children:s.jsx("path",{d:"M2.5 2.5 7.5 7.5M7.5 2.5 2.5 7.5",strokeLinecap:"round"})})})]})}function Km({bottom:c,left:r,onDismiss:m,toasts:f,width:d}){return s.jsx("ol",{"aria-live":"polite",className:`pointer-events-none fixed z-40 flex flex-col gap-2 transition-[bottom,left,width] duration-200 ${Pn} motion-reduce:transition-none`,style:{bottom:c,left:r,width:d},children:f.map(y=>s.jsx(Vm,{onDismiss:()=>m(y.id),toast:y},y.id))})}function Jm({loaded:c}){return s.jsxs("div",{"aria-hidden":!0,className:`absolute inset-0 overflow-hidden bg-white transition-opacity duration-700 ${Pn} ${c?"pointer-events-none opacity-0":"opacity-100"}`,children:[s.jsxs("div",{children:[s.jsx("div",{className:"mx-auto mt-6 h-12 w-[400px] max-w-[80%] rounded-full bg-neutral-200/80"}),s.jsxs("div",{className:"mx-auto mt-24 grid w-full max-w-5xl grid-cols-[1.05fr_0.95fr] items-start gap-16 px-12 max-[900px]:grid-cols-1",children:[s.jsxs("div",{children:[s.jsx("div",{className:"h-14 w-4/5 rounded-lg bg-neutral-200"}),s.jsx("div",{className:"mt-3 h-14 w-3/5 rounded-lg bg-neutral-200"}),s.jsx("div",{className:"mt-8 h-4 w-full max-w-[420px] rounded bg-neutral-200/80"}),s.jsx("div",{className:"mt-2 h-4 w-4/5 max-w-[360px] rounded bg-neutral-200/80"}),s.jsx("div",{className:"mt-10 h-12 w-44 rounded-full bg-neutral-200"})]}),s.jsx("div",{className:"h-[420px] w-60 justify-self-center rounded-[2.5rem] bg-neutral-200 max-[900px]:hidden"})]})]}),s.jsx("div",{className:"pointer-events-none absolute inset-0 overflow-hidden motion-reduce:hidden",children:s.jsx("div",{className:"absolute inset-0 -translate-x-full animate-[leglas-skeleton-sweep_1.6s_ease-in-out_infinite]",style:{background:"linear-gradient(100deg, transparent 32%, rgba(255,255,255,0.55) 50%, transparent 68%)"}})}),s.jsxs("span",{className:"absolute bottom-4 right-5 flex items-center gap-2",children:[s.jsx(D0,{"aria-label":"",size:20,state:j0,theme:"light"}),s.jsx("span",{className:"leglas-shimmer-text text-xs font-medium",children:"Loading preview…"})]})]})}function $m({onReload:c,reason:r}){return s.jsxs("div",{className:"absolute inset-0 flex flex-col items-center justify-center gap-3 bg-white p-6 text-center",role:"alert",children:[s.jsxs("div",{className:"max-w-xs",children:[s.jsx("p",{className:"text-sm font-medium text-neutral-800",children:"Preview didn’t load"}),s.jsx("p",{className:"mt-1 text-xs leading-snug text-neutral-500",children:r})]}),s.jsx("button",{className:"rounded-md bg-neutral-900 px-3 py-1.5 text-xs font-medium text-white transition-colors hover:bg-neutral-700",onClick:c,type:"button",children:"Reload"})]})}function bo({id:c,size:r=14}){const m=R.useId();return c==="claude"?s.jsx("svg",{"aria-hidden":"true",fill:"#D97757",height:r,viewBox:"0 0 24 24",width:r,children:s.jsx("path",{d:"m4.7144 15.9555 4.7174-2.6471.079-.2307-.079-.1275h-.2307l-.7893-.0486-2.6956-.0729-2.3375-.0971-2.2646-.1214-.5707-.1215-.5343-.7042.0546-.3522.4797-.3218.686.0608 1.5179.1032 2.2767.1578 1.6514.0972 2.4468.255h.3886l.0546-.1579-.1336-.0971-.1032-.0972L6.973 9.8356l-2.55-1.6879-1.3356-.9714-.7225-.4918-.3643-.4614-.1578-1.0078.6557-.7225.8803.0607.2246.0607.8925.686 1.9064 1.4754 2.4893 1.8336.3643.3035.1457-.1032.0182-.0728-.164-.2733-1.3539-2.4467-1.445-2.4893-.6435-1.032-.17-.6194c-.0607-.255-.1032-.4674-.1032-.7285L6.287.1335 6.6997 0l.9957.1336.419.3642.6192 1.4147 1.0018 2.2282 1.5543 3.0296.4553.8985.2429.8318.091.255h.1579v-.1457l.1275-1.706.2368-2.0947.2307-2.6957.0789-.7589.3764-.9107.7468-.4918.5828.2793.4797.686-.0668.4433-.2853 1.8517-.5586 2.9021-.3643 1.9429h.2125l.2429-.2429.9835-1.3053 1.6514-2.0643.7286-.8196.85-.9046.5464-.4311h1.0321l.759 1.1293-.34 1.1657-1.0625 1.3478-.8804 1.1414-1.2628 1.7-.7893 1.36.0729.1093.1882-.0183 2.8535-.607 1.5421-.2794 1.8396-.3157.8318.3886.091.3946-.3278.8075-1.967.4857-2.3072.4614-3.4364.8136-.0425.0304.0486.0607 1.5482.1457.6618.0364h1.621l3.0175.2247.7892.522.4736.6376-.079.4857-1.2142.6193-1.6393-.3886-3.825-.9107-1.3113-.3279h-.1822v.1093l1.0929 1.0686 2.0035 1.8092 2.5075 2.3314.1275.5768-.3218.4554-.34-.0486-2.2039-1.6575-.85-.7468-1.9246-1.621h-.1275v.17l.4432.6496 2.3436 3.5214.1214 1.0807-.17.3521-.6071.2125-.6679-.1214-1.3721-1.9246L14.38 17.959l-1.1414-1.9428-.1397.079-.674 7.2552-.3156.3703-.7286.2793-.6071-.4614-.3218-.7468.3218-1.4753.3886-1.9246.3157-1.53.2853-1.9004.17-.6314-.0121-.0425-.1397.0182-1.4328 1.9672-2.1796 2.9446-1.7243 1.8456-.4128.164-.7164-.3704.0667-.6618.4008-.5889 2.386-3.0357 1.4389-1.882.929-1.0868-.0062-.1579h-.0546l-6.3385 4.1164-1.1293.1457-.4857-.4554.0608-.7467.2307-.2429 1.9064-1.3114Z"})}):c==="cursor"?s.jsx("svg",{"aria-hidden":"true",fill:"currentColor",height:r,viewBox:"0 0 24 24",width:r,children:s.jsx("path",{d:"M11.503.131 1.891 5.678a.84.84 0 0 0-.42.726v11.188c0 .3.162.575.42.724l9.609 5.55a1 1 0 0 0 .998 0l9.61-5.55a.84.84 0 0 0 .42-.724V6.404a.84.84 0 0 0-.42-.726L12.497.131a1.01 1.01 0 0 0-.996 0M2.657 6.338h18.55c.263 0 .43.287.297.515L12.23 22.918c-.062.107-.229.064-.229-.06V12.335a.59.59 0 0 0-.295-.51l-9.11-5.257c-.109-.063-.064-.23.061-.23"})}):c==="codex"?s.jsxs("svg",{"aria-hidden":"true",height:r,viewBox:"0 0 24 24",width:r,children:[s.jsx("defs",{children:s.jsxs("linearGradient",{id:m,x1:"0",x2:"0",y1:"0",y2:"1",children:[s.jsx("stop",{offset:"0",stopColor:"#9B96F2"}),s.jsx("stop",{offset:"0.55",stopColor:"#5E6CF6"}),s.jsx("stop",{offset:"1",stopColor:"#3B32EF"})]})}),s.jsx("path",{d:"M8.086.457a6.105 6.105 0 013.046-.415c1.333.153 2.521.72 3.564 1.7a.117.117 0 00.107.029c1.408-.346 2.762-.224 4.061.366l.063.03.154.076c1.357.703 2.33 1.77 2.918 3.198.278.679.418 1.388.421 2.126a5.655 5.655 0 01-.18 1.631.167.167 0 00.04.155 5.982 5.982 0 011.578 2.891c.385 1.901-.01 3.615-1.183 5.14l-.182.22a6.063 6.063 0 01-2.934 1.851.162.162 0 00-.108.102c-.255.736-.511 1.364-.987 1.992-1.199 1.582-2.962 2.462-4.948 2.451-1.583-.008-2.986-.587-4.21-1.736a.145.145 0 00-.14-.032c-.518.167-1.04.191-1.604.185a5.924 5.924 0 01-2.595-.622 6.058 6.058 0 01-2.146-1.781c-.203-.269-.404-.522-.551-.821a7.74 7.74 0 01-.495-1.283 6.11 6.11 0 01-.017-3.064.166.166 0 00.008-.074.115.115 0 00-.037-.064 5.958 5.958 0 01-1.38-2.202 5.196 5.196 0 01-.333-1.589 6.915 6.915 0 01.188-2.132c.45-1.484 1.309-2.648 2.577-3.493.282-.188.55-.334.802-.438.286-.12.573-.22.861-.304a.129.129 0 00.087-.087A6.016 6.016 0 015.635 2.31C6.315 1.464 7.132.846 8.086.457z",fill:`url(#${m})`}),s.jsx("path",{d:"M7.282 8.307a.848.848 0 00-1.473.842l1.694 2.965-1.688 2.848a.849.849 0 001.46.864l1.94-3.272a.849.849 0 00.007-.854l-1.94-3.393zM12.728 14.547a.849.849 0 000 1.695h4.848a.849.849 0 000-1.696h-4.848z",fill:"#F4F4FE"})]}):c==="custom"?s.jsx("svg",{"aria-hidden":"true",fill:"none",height:r,stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",viewBox:"0 0 24 24",width:r,children:s.jsx("path",{d:"m5 6 6 6-6 6M13 18h6"})}):null}function Wm(c){const r=document.createElement("textarea");r.value=c,r.setAttribute("readonly",""),r.style.cssText="position:fixed;top:-1000px;opacity:0",document.body.append(r),r.select();try{return document.execCommand("copy")}finally{r.remove()}}function Fm(){return{clipboard:typeof navigator>"u"?void 0:navigator.clipboard,legacy:typeof document>"u"?void 0:Wm}}async function Co(c,r=Fm()){if(r.clipboard)try{return await r.clipboard.writeText(c),"copied"}catch{}try{if(r.legacy?.(c))return"copied"}catch{}return"blocked"}const Im=9;function Pm(c){if((c.metaKey||c.ctrlKey)&&!c.altKey&&!c.shiftKey&&c.key.toLowerCase()==="k")return{kind:"search"};if(c.typing||c.metaKey||c.ctrlKey||c.altKey)return null;const{key:r}=c;if(r==="?")return{kind:"help"};if(r==="ArrowDown")return{kind:"move",delta:1};if(r==="ArrowUp")return{kind:"move",delta:-1};const m=r.length===1?r.toLowerCase():"";return m==="c"?{kind:"split"}:m==="b"?{kind:"rail"}:m==="r"?{kind:"request"}:m==="t"?{kind:"tools"}:r.length===1&&r>="1"&&r<=String(Im)?{kind:"jump",index:Number(r)-1}:null}function U0(c){return c?"⌘Cmd+K":"Ctrl+K"}function t2(c){return[{keys:["↑","↓"],label:"Move between directions"},{keys:["1","9"],join:"to",label:"Jump straight to a direction"},{keys:["C"],label:"Compare against the direction you were last on"},{keys:["R"],label:"Ask for a change to this direction"},{keys:[U0(c)],label:"Search"},{keys:["B"],label:"Collapse or open the rail"},{keys:["T"],label:"Open or close the Leglas dev tool menu"},{keys:["?"],label:"This list"},{keys:["Esc"],label:"Clear the search, or close what is open"}]}function b0(c){return c.file===void 0&&c.branch===void 0&&c.url.startsWith("/")}const e2={reachable:!0,wasDown:!1};function l2(c,r){return r?{reachable:!0,wasDown:c.wasDown}:{reachable:!1,wasDown:!0}}function n2(c){const r=c.rows,m=f=>f!=null&&f!==c.active&&(r===void 0||r.includes(f));return m(c.pinned)?c.pinned:m(c.parent)?c.parent:m(c.previous)?c.previous:r?.find(f=>f!==c.active)??null}function a2(c){return!c.split||c.compare===null||c.compare===c.active?[c.active]:[c.active,c.compare]}const u2=.999,i2=.05;function c2(c){const{gutter:r,panes:m,scaleSplit:f,stageHeight:d,stageWidth:y,viewport:E}=c,A=m>1?(y-(m-1))/m:y,D=E??y,x=A-(E!==null?r:0),L=d-(E!==null?r:0),G=f&&m>1&&y>0&&D>0?Math.max(i2,Math.min(1,x/D)):1,Y=G<u2;return{boxHeight:L*G,boxWidth:D*G,designWidth:D,frameHeight:L,scale:G,scaling:Y}}const s2="#__next-build-watcher,#nuxt-devtools-anchor,astro-dev-toolbar{display:none!important}",o2="#devtools-indicator{display:none!important}",f2=12;function r2(c,r,m=[]){const f=c.replace(/\s+/g," ").trim().toLowerCase();return f.length<f2?null:`${r.join(">")} ${f} ${m.join("|")}`.trimEnd()}const d2=new Set(["LINK","META","NOSCRIPT","SCRIPT","STYLE","TEMPLATE"]);function h2(c,r){if(!c)return[];const m=[];let f=c;for(let d=0;d<4;d+=1){const y=r(f);m.push(`${y.backgroundColor};${y.backgroundImage};${y.color}`);const E=Array.from(f.children).filter(D=>!d2.has(D.tagName??"")),A=E.length===1?E[0]:void 0;if(A===void 0)break;f=A}return m}function m2(c){const r=new Map;for(const[f,d]of Object.entries(c)){if(d===null)continue;const y=r.get(d);y?y.push(f):r.set(d,[f])}const m={};for(const f of r.values())if(!(f.length<2))for(const d of f)m[d]=f.filter(y=>y!==d);return m}function g2(c,r,m){const f=new Set(m);return c.filter(d=>!(!d.url.startsWith("/")||d.title in r||f.has(d.title))).map(d=>d.title)}const x0=24,p2=10,S0=44;function y2(c,r){const m=(f,d)=>{const y=Math.min(x0,d/2),E=Math.max(y,d-x0);return Math.max(y,Math.min(E,f))};return{x:m(c.x,r.width),y:m(c.y,r.height)}}function v2(c){return{x:c.x-S0/2,y:c.y-S0/2}}function b2(c,r,m=p2){return Math.abs(r.x-c.x)>m||Math.abs(r.y-c.y)>m}function x2(c,r){const m=c.x<r.width/2,f=c.y<r.height/2;return f&&m?{corner:"top-left"}:f?{corner:"top-right"}:m?{corner:"bottom-left"}:{corner:"bottom-right"}}const S2=3,we={action:6e3,plain:2600};function E2(c,r,m=S2){return[...c.filter(d=>d.kind!==r.kind),r].slice(-m)}function M2(c,r){return c.filter(m=>m.id!==r)}const C2=10;function H0(c,r){let m=c;for(let f=0;f<C2;f+=1){const d=r.get(m);if(d===void 0||d===c)return m;m=d}return m}function A2(c,r){const m=new Set(c),f=new Map,d=[];for(const y of c){const E=H0(y,r);if(E===y||!m.has(E))d.push(y);else{const A=f.get(E);A?A.push(y):f.set(E,[y])}}return d.flatMap(y=>[{title:y,depth:0},...(f.get(y)??[]).map(E=>({title:E,depth:1}))])}function T2(c,r){if(r.size===0)return[...c];let m=null;return c.filter(f=>f.depth===0?(m=f.title,!0):m===null||!r.has(m))}const E0=c=>c.trim().replace(/\s+/g," ").toLowerCase();function z2(c,r,m){const f=c.trim().replace(/\s+/g," "),d=m.get(r)??r;if(f===""||f===r)return d===r?{kind:"same"}:{kind:"reset",value:r};if(f===d)return{kind:"same"};for(const[y,E]of m)if(y!==r&&E0(E)===E0(f))return{kind:"taken",by:E};return{kind:"set",value:f}}function D2(c,r){try{return new URL(c,r).toString()}catch{return c}}function j2({displayName:c,preview:r,previewUrl:m,title:f}){const d=c===f?"":` (shown as ${JSON.stringify(c)})`,y=r?.note?` — ${r.note}`:"",E=r?.tags.length?` [${r.tags.join(", ")}]`:"",A=[`Leglas direction ${JSON.stringify(f)}${d}${y}${E}`];return r?.file?A.push(`Source: ${r.file}`):r?.branch?A.push(`Branch: ${r.branch}`):r&&A.push(`Route: ${r.url}`),A.push(`Preview: ${m}`),r?.basedOn&&A.push(`A variant of: ${r.basedOn}`),A.push("","Inspect this direction in full:",` npx leglas show ${JSON.stringify(f)} --json`),A.join(`
10
+ `)}function N2({previews:c,project:r,searchRef:m,onToggleSplit:f,onToggleHelp:d,onToggleTools:y,suspended:E=!1}){const A=_m(r),D=()=>Rm(typeof window>"u"?null:window.localStorage.getItem(A),c),[x,L]=R.useState(D),H=new Map(c.map(O=>[O.title,O])),G=()=>{const O=D();return O.order.find(K=>!O.hidden.includes(K))??O.order[0]??""},[Y,X]=R.useState(G),F=typeof window<"u"&&window.self!==window.top,[dt,g]=R.useState(()=>[G()]),[Q,I]=R.useState(""),[et,lt]=R.useState([]),P=O=>{lt(K=>K.length?[]:K),I(O)},[J,nt]=R.useState(!1),[it,ut]=R.useState(null),[xt,gt]=R.useState(null),[Ht,pt]=R.useState(null),[$t,z]=R.useState(!1),[q,$]=R.useState({}),[yt,Mt]=R.useState([]),[v,N]=R.useState(null),k=R.useRef(1),V=R.useRef(null),ot=R.useRef(0),ft=O=>{ot.current+=1,Mt(K=>E2(K,{...O,id:ot.current}))},Tt=O=>Mt(K=>M2(K,O)),Vt=O=>{X(O),g(K=>K.includes(O)?K:[...K,O])};R.useEffect(()=>{window.localStorage.setItem(A,JSON.stringify(x))},[x,A]),R.useEffect(()=>()=>{V.current&&clearTimeout(V.current)},[]);const wt=O=>x.renames[O]??O,Oe=O=>H.get(O)?.url??"/",xl=O=>{if(!Q.trim())return!0;const K=Q.toLowerCase(),St=H.get(O);return wt(O).toLowerCase().includes(K)||O.toLowerCase().includes(K)||(St?.note??"").toLowerCase().includes(K)||(St?.tags??[]).some(ht=>ht.toLowerCase().includes(K))},fl=c.map(O=>O.title).filter(O=>!x.deleted.includes(O)),rl=Hm(x.order,fl),Kt=Q.trim()!=="",We=Kt?et:x.collapsedFamilies,Ol=new Map(c.flatMap(O=>O.basedOn===void 0?[]:[[O.title,O.basedOn]])),_l=A2(rl.filter(O=>!x.hidden.includes(O)&&xl(O)),Ol),je=T2(_l,new Set(We)),dl=je.map(O=>O.title),Sl=new Map(je.map(O=>{const K=O.depth===0?_l.filter(St=>St.depth===1&&H0(St.title,Ol)===O.title).length:0;return[O.title,{depth:O.depth,variants:K,folded:We.includes(O.title)}]})),Pl=(O,K)=>O.includes(K)?O.filter(St=>St!==K):[...O,K],Fe=O=>Kt?lt(K=>Pl(K,O)):L(K=>({...K,collapsedFamilies:Pl(K.collapsedFamilies,O)})),la=O=>H.get(O)?.basedOn??null,ye=rl.filter(O=>!x.hidden.includes(O)).length,El=(O,K)=>L(St=>({...St,order:Bm(St,c,O,K)})),tn=(O,K=!1)=>{L(St=>({...St,hidden:St.hidden.filter(ht=>ht!==O)})),K&&Vt(O)},wn=O=>{const K=wt(O),St=Y===O;if(L(ht=>({...ht,hidden:[...ht.hidden,O]})),St){const ht=rl.find(mt=>mt!==O&&!x.hidden.includes(mt));ht&&Vt(ht)}ft({action:{label:"Undo",run:()=>tn(O,St)},kind:`remove:${O}`,message:`${K} removed from the list`,tone:"info",ttl:we.action})},Ml=async O=>{const K=[...new Set(O)].filter(mt=>x.hidden.includes(mt)),St=K.filter(mt=>H.get(mt)?.local===!0);if(St.length>0){const mt=await fetch("/leglas/api/previews/delete",{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({titles:St})});if(!mt.ok){const Wt=await mt.json().catch(()=>null);throw new Error(Wt?.error??"The directions could not be deleted from Leglas.")}}const ht=new Set(K);if(L(mt=>Um(mt,K)),g(mt=>mt.filter(Wt=>!ht.has(Wt))),K.includes(Y)){const mt=rl.find(Wt=>!ht.has(Wt)&&!x.hidden.includes(Wt));X(mt??"")}x.hidden.every(mt=>ht.has(mt))&&nt(!1)},en=(O,K)=>L(St=>{const ht={...St.renames};return K===void 0?delete ht[O]:ht[O]=K,fetch("/leglas/api/renames",{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({renames:ht})}).catch(()=>{}),{...St,renames:ht}}),ln=O=>{ut(O),gt(null)},na=(O,K,St="submit")=>{const ht=new Map(fl.map(Gt=>[Gt,wt(Gt)])),mt=z2(K,O,ht);if(mt.kind==="taken"){if(St==="submit"){gt(`${mt.by} already goes by that name.`);return}ln(null),ft({kind:`rename:${O}`,message:`Still called ${wt(O)}. ${mt.by} already goes by that name.`,tone:"info",ttl:we.plain});return}if(ln(null),mt.kind==="same")return;const Wt=x.renames[O];en(O,mt.kind==="reset"?void 0:mt.value),ft({action:{label:"Undo",run:()=>en(O,Wt)},kind:`rename:${O}`,message:mt.kind==="reset"?`Name reset to ${mt.value}`:`Renamed to ${mt.value}`,tone:"success",ttl:we.action})};R.useEffect(()=>{const O=dl,K=ht=>{const mt=ht.target,Wt=mt?.tagName?.toLowerCase(),Gt=Pm({key:ht.key,altKey:ht.altKey,ctrlKey:ht.ctrlKey,metaKey:ht.metaKey,shiftKey:ht.shiftKey,typing:Wt==="input"||Wt==="textarea"||Wt==="select"||(mt?.isContentEditable??!1)});if(Gt&&!(E&&Gt.kind!=="help")){if(Gt.kind==="search"||Gt.kind==="request")ht.preventDefault(),L(oe=>oe.collapsed?{...oe,collapsed:!1}:oe),N({target:Gt.kind,nonce:k.current++});else if(Gt.kind==="split")ht.preventDefault(),f?.();else if(Gt.kind==="help")ht.preventDefault(),d?.();else if(Gt.kind==="tools")ht.preventDefault(),y?.();else if(Gt.kind==="rail")L(oe=>({...oe,collapsed:!oe.collapsed}));else if(Gt.kind==="jump"){const oe=O[Gt.index];oe&&(ht.preventDefault(),Vt(oe))}else if(Gt.kind==="move"){ht.preventDefault();const oe=O.indexOf(Y),Ee=Gt.delta===1?O[Math.min(O.length-1,oe+1)]:O[Math.max(0,oe-1)];Ee&&Vt(Ee)}}},St=[window];for(const ht of Array.from(document.querySelectorAll("iframe")))try{const mt=ht.contentDocument;mt&&St.push(mt)}catch{}for(const ht of St)ht.addEventListener("keydown",K);return()=>{for(const ht of St)ht.removeEventListener("keydown",K)}},[Y,dl.join("|"),f,d,y,E,dt.join("|"),Object.entries(q).filter(([,O])=>O).map(([O])=>O).join("|")]);const On=(O,K)=>{const St=D2(Oe(O),window.location.origin),ht=K==="link"?St:j2({displayName:wt(O),preview:H.get(O),previewUrl:St,title:O});Co(ht).then(mt=>{if(mt==="blocked"){pt(null),ft({detail:St,kind:"copy",message:"Your browser blocked the clipboard. The direction is at:",tone:"danger",ttl:null});return}pt({kind:K,title:O}),V.current&&clearTimeout(V.current),V.current=setTimeout(()=>pt(null),1200),ft({kind:"copy",message:K==="link"?`Link to ${wt(O)} copied`:`Reference to ${wt(O)} copied`,tone:"success",ttl:we.plain})})},ve=O=>On(O,"link"),ie=O=>On(O,"reference"),le=O=>{O.preventDefault();const K=O.currentTarget;K.setPointerCapture(O.pointerId);const St=O.clientX,ht=x.width;z(!0);const mt=Gt=>{const oe=Math.min(w0,Math.max(N0,ht+Gt.clientX-St));L(Ee=>Ee.width===oe?Ee:{...Ee,width:oe})},Wt=Gt=>{K.releasePointerCapture(Gt.pointerId),K.removeEventListener("pointermove",mt),K.removeEventListener("pointerup",Wt),K.removeEventListener("pointercancel",Wt),z(!1)};K.addEventListener("pointermove",mt),K.addEventListener("pointerup",Wt),K.addEventListener("pointercancel",Wt)},xe=O=>$(K=>K[O]?K:{...K,[O]:!0}),aa=O=>$(K=>K[O]?{...K,[O]:!1}:K),ua=F?[Y]:fl.filter(O=>dt.includes(O));return{active:Y,copied:Ht,copyLink:ve,copyReference:ie,deleteRemoved:Ml,displayName:wt,dismissToast:Tt,focusing:v,hiddenCount:x.hidden.length,hide:wn,loaded:q,markLoaded:xe,matches:xl,moveOption:El,nested:F,notify:ft,onHandlePointerDown:le,panes:ua,prefs:x,previewFor:O=>H.get(O),query:Q,rename:na,renameError:xt,renaming:it,parentOf:la,resetLoaded:aa,resizing:$t,restore:tn,rowMeta:Sl,rows:dl,toggleFamily:Fe,setActive:Vt,setPrefs:L,setQuery:P,setShowHidden:nt,showHidden:J,startRename:ln,toasts:yt,urlFor:Oe,visibleCount:ye,viewports:_0}}function w2(c,r,m,f=null){if(c==="custom"){const y=f?.trim().split(/\s+/)[0]??"";return{kind:"chosen",id:"custom",name:y===""?"Custom":y.split("/").pop()??"Custom"}}const d=c===null?void 0:r.find(y=>y.id===c);return d?.available?{kind:"chosen",id:d.id,name:d.name}:r.some(y=>y.available)?m?{kind:"manual"}:{kind:"choose"}:{kind:"none"}}function O2(c){const r=Math.max(0,Math.floor(c/1e3));return r<60?`${r}s`:`${Math.floor(r/60)}m ${String(r%60).padStart(2,"0")}s`}function _2(c,r,m){const f=c.find(E=>E.status==="running");if(r.running||f!==void 0)return{kind:"running",id:f?.id??null,name:r.name??"Your agent",activity:r.activity,startedAt:r.startedAt,title:f?.title??null};const d=c.filter(E=>E.status==="queued").length;if(d>0)return{kind:"queued",count:d,attended:m};if(c.some(E=>E.status==="picked-up"))return{kind:"picked-up"};const y=c.findLast(E=>E.status==="failed");return y!==void 0?{kind:"failed",id:y.id,title:y.title}:null}const Bu=(c,r)=>fetch(c,r);async function R2(c=Bu){const r=await c("/leglas/api/agents");if(!r.ok)throw new Error("Leglas refused the agent request.");return r.json()}async function Pi(c,r,m){const f=await m(c,{method:"POST",...r===null?{}:{headers:{"content-type":"application/json"},body:JSON.stringify(r)}});if(!f.ok)throw new Error("Leglas refused the agent request.");if((await f.json()).ok!==!0)throw new Error("Leglas refused the agent request.")}function U2(c,r,m=Bu){return Pi("/leglas/api/agent",r===void 0?{agent:c}:{agent:c,run:r},m)}function H2(c,r=Bu){return Pi("/leglas/api/requests/cancel",c==null?null:{id:c},r)}function B2(c,r=Bu){return Pi("/leglas/api/requests/retry",{id:c},r)}function q2(c,r=Bu){return Pi("/leglas/api/requests/dismiss",{id:c},r)}const xo=[{key:"satoshi",label:"Satoshi",stack:"var(--font-satoshi)"},{key:"outfit",label:"Outfit",stack:"var(--font-outfit)"},{key:"geist",label:"Geist",stack:"var(--font-geist)"}],So=["#34D399","#38BDF8","#818CF8","#C084FC","#FB7185","#FB923C"];function L2(c){let r=0;for(const f of c)r=r*31+f.charCodeAt(0)|0;const m=So[Math.abs(r)%So.length]??So[0];return{backgroundColor:`${m}22`,color:m}}const M0=15e3,Y2=96,G2="claude mcp add leglas -- npx leglas-mcp",X2=`{
11
+ "mcpServers": {
12
+ "leglas": { "command": "npx", "args": ["leglas-mcp"] }
13
+ }
14
+ }`,C0={attached:!1,running:!1,name:null,activity:null,startedAt:null},k2={agents:[],choice:null,customRun:null},B0=typeof navigator<"u"&&/Mac|iPhone|iPad|iPod/.test(navigator.userAgent),Q2=U0(B0);function Z2({mac:c,onClose:r}){const m=R.useRef(null),f=t2(c);return R.useEffect(()=>{const d=document.activeElement;m.current?.focus();const y=E=>{E.key==="Escape"&&(E.preventDefault(),r())};return window.addEventListener("keydown",y),()=>{window.removeEventListener("keydown",y),d?.focus?.()}},[r]),s.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/50 p-6 backdrop-blur-sm",onPointerDown:d=>{d.target===d.currentTarget&&r()},children:s.jsxs("div",{"aria-label":"Keyboard shortcuts","aria-modal":"true",className:"w-full max-w-sm rounded-lg border border-[#232328] bg-[#1E1E22] p-4 shadow-2xl focus:outline-none",ref:m,role:"dialog",tabIndex:-1,children:[s.jsx("span",{className:"block pb-3 text-[10px] uppercase tracking-[0.08em] text-[#84848C]",children:"Keyboard"}),s.jsx("dl",{className:"flex flex-col gap-2.5",children:f.map(d=>s.jsxs("div",{className:"flex items-baseline justify-between gap-4",children:[s.jsx("dt",{className:"flex shrink-0 items-baseline gap-1",children:d.keys.map((y,E)=>s.jsxs("span",{className:"flex items-baseline gap-1",children:[E>0&&d.join?s.jsx("span",{className:"text-[10px] text-[#84848C]",children:d.join}):null,s.jsx("kbd",{className:"rounded border border-[#232328] bg-[#2E2E2E]/60 px-1.5 py-0.5 font-sans text-[11px] text-[#E8E8EA]",children:y})]},y))}),s.jsx("dd",{className:"text-right text-xs leading-snug text-[#9CA3AF]",children:d.label})]},d.label))})]})})}function V2({busy:c,count:r,error:m,fallbackFocusRef:f,name:d,onCancel:y,onConfirm:E}){const A=R.useRef(null),D=R.useRef(null),x=R.useRef(y);x.current=y,R.useEffect(()=>{const Y=D.current;if(Y===null)return;const X=document.activeElement,F=g=>{g.preventDefault(),x.current()},dt=g=>{if(g.key!=="Tab")return;const Q=Array.from(Y.querySelectorAll("button:not(:disabled)")),I=Q[0],et=Q.at(-1);I===void 0||et===void 0?(g.preventDefault(),Y.focus()):g.shiftKey&&document.activeElement===I?(g.preventDefault(),et.focus()):!g.shiftKey&&document.activeElement===et&&(g.preventDefault(),I.focus())};return Y.addEventListener("cancel",F),Y.addEventListener("keydown",dt),Y.open||Y.showModal(),A.current?.focus(),()=>{Y.removeEventListener("cancel",F),Y.removeEventListener("keydown",dt),Y.open&&Y.close(),(X?.isConnected?X:f.current)?.focus()}},[]);const L=r===1,H=L?"Delete removed direction?":"Clear removed directions?",G=L?`This permanently removes “${d??"this direction"}” from Leglas.`:`This permanently removes all ${r} directions from Leglas.`;return s.jsx("dialog",{"aria-describedby":"delete-removed-description","aria-labelledby":"delete-removed-title","aria-modal":"true",className:"m-auto max-h-[calc(100dvh-3rem)] max-w-none overflow-visible border-0 bg-transparent p-0 text-left text-inherit backdrop:bg-black/50 backdrop:backdrop-blur-sm",onPointerDown:Y=>{Y.target===Y.currentTarget&&!c&&y()},ref:D,role:"alertdialog",tabIndex:-1,children:s.jsxs("div",{className:"w-[calc(100vw-3rem)] max-w-sm overscroll-contain rounded-lg border border-[#232328] bg-[#1E1E22] p-4 shadow-2xl",children:[s.jsx("h2",{className:"text-sm font-medium text-white",id:"delete-removed-title",children:H}),s.jsxs("div",{className:"mt-2 space-y-1 text-xs leading-relaxed text-[#9CA3AF]",id:"delete-removed-description",children:[s.jsx("p",{children:G}),s.jsx("p",{children:"Source files and shared project config stay untouched."})]}),m!==null?s.jsx("p",{className:"mt-3 text-xs leading-relaxed text-red-300",role:"alert",children:m}):null,s.jsxs("div",{className:"mt-4 flex justify-end gap-2",children:[s.jsx("button",{className:"rounded-md px-3 py-1.5 text-xs text-[#D1D5DB] transition-[background-color,color,scale] hover:bg-white/[0.06] hover:text-white active:scale-[0.96] disabled:opacity-50",disabled:c,onClick:y,ref:A,type:"button",children:"Cancel"}),s.jsx("button",{className:"rounded-md bg-red-500/90 px-3 py-1.5 text-xs font-medium text-white transition-[background-color,scale] hover:bg-red-500 active:scale-[0.96] disabled:opacity-60",disabled:c,onClick:E,type:"button",children:c?"Deleting…":L?"Delete":"Delete all"})]})]})})}function K2({previews:c,project:r}){const m=R.useRef(null),f=R.useRef(null),d=R.useRef(null),[y,E]=R.useState(!1),[A,D]=R.useState(null),[x,L]=R.useState(!1),H=R.useCallback(()=>d.current?.(),[]),G=R.useCallback(()=>E(h=>!h),[]),Y=R.useCallback(()=>E(!1),[]),[X,F]=R.useState(!1),dt=R.useCallback(()=>F(h=>!h),[]),g=N2({previews:c,project:r,searchRef:m,onToggleSplit:H,onToggleHelp:G,onToggleTools:dt,suspended:y||A!==null}),Q=()=>{x||D(null)},I=async()=>{if(A===null||x)return;const h=A;L(!0),D({...h,error:null});try{await g.deleteRemoved(h.titles),D(null),g.notify({kind:`delete:${h.titles.join("|")}`,message:h.titles.length===1?`${g.displayName(h.titles[0]??"")} permanently deleted`:`${h.titles.length} removed directions permanently deleted`,tone:"info",ttl:we.plain})}catch(B){D({...h,error:B instanceof Error?B.message:"The directions could not be deleted."})}finally{L(!1)}},[et,lt]=R.useState(!1),[P,J]=R.useState(null),nt=P!==null,it=R.useRef(!1),[ut,xt]=R.useState("");R.useEffect(()=>{const h=f.current;h!==null&&(h.style.height="0px",h.style.height=`${Math.min(h.scrollHeight,96)}px`)},[ut,g.prefs.width]);const[gt,Ht]=R.useState(!1),[pt,$t]=R.useState(null),[z,q]=R.useState(!1),[$,yt]=R.useState(null),[Mt,v]=R.useState(!1),[N,k]=R.useState(null),V=R.useRef(null),ot=R.useRef(null),ft=R.useRef(null),Tt=R.useRef(null),Vt=R.useRef(null),[wt,Oe]=R.useState(Y2);R.useEffect(()=>{const h=Vt.current;if(h===null||typeof ResizeObserver>"u")return;const B=()=>Oe(h.offsetHeight);B();const Z=new ResizeObserver(B);return Z.observe(h),()=>Z.disconnect()},[]);const xl=R.useRef(null),[fl,rl]=R.useState({height:0,on:!1,top:0});R.useEffect(()=>{rl(h=>h.on?{...h,on:!1}:h)},[g.rows.join("|")]);const[Kt,We]=R.useState(null),Ol=R.useRef(null),_l=R.useRef(null);R.useEffect(()=>{Ol.current=Kt},[Kt]),R.useEffect(()=>{if(!g.focusing)return;const h=g.focusing.target==="search"?m.current:f.current;h?.focus(),h?.select()},[g.focusing]),R.useEffect(()=>{if(!Kt)return;const h=_l.current;if(!h)return;const B=W=>{const ct=W.clientY-h.startY,At=W.clientX-h.startX;We(Ct=>{if(!Ct||Ct.settling)return Ct;if(!Ct.started){if(Math.abs(ct)<=4&&Math.abs(At)<=4)return{...Ct,dy:ct};if(Math.abs(At)>Math.abs(ct))return null;window.getSelection()?.removeAllRanges()}const _t=h.rows[Ct.from];if(!_t)return Ct;const te=Math.max(h.minDy,Math.min(h.maxDy,ct)),de=_t.mid+ct;let ne=0;return h.rows.forEach((Re,Ft)=>{Ft!==Ct.from&&de>Re.mid&&(ne+=1)}),{...Ct,dy:te,started:!0,to:ne}})},Z=()=>{const W=Ol.current;if(!W?.started){We(null);return}h.suppressed=!0;let ct=0;if(W.to>W.from)for(let At=W.from+1;At<=W.to;At+=1)ct+=(h.rows[At]?.height??0)+W.gap;else for(let At=W.to;At<W.from;At+=1)ct-=(h.rows[At]?.height??0)+W.gap;We({...W,dy:ct,settling:!0}),window.setTimeout(()=>{g.moveOption(W.title,W.to),We(null),window.setTimeout(()=>{h.suppressed=!1},0)},190)};return window.addEventListener("pointermove",B),window.addEventListener("pointerup",Z),window.addEventListener("pointercancel",Z),()=>{window.removeEventListener("pointermove",B),window.removeEventListener("pointerup",Z),window.removeEventListener("pointercancel",Z)}},[Kt!==null]),R.useEffect(()=>{if(!X)return;ot.current?.focus();const h=W=>{W.key==="Escape"&&(F(!1),V.current?.focus())},B=W=>{const ct=W.target;!ot.current?.contains(ct)&&!V.current?.contains(ct)&&F(!1)},Z=()=>F(!1);return window.addEventListener("keydown",h),window.addEventListener("pointerdown",B),window.addEventListener("blur",Z),()=>{window.removeEventListener("keydown",h),window.removeEventListener("pointerdown",B),window.removeEventListener("blur",Z)}},[X]);const je="flex h-7 w-full items-center justify-between gap-2 whitespace-nowrap rounded px-2 text-xs hover:bg-[#2E2E2E] hover:text-white disabled:cursor-not-allowed disabled:opacity-40",dl=xo.find(h=>h.key===g.prefs.font)??xo[0],Sl=g.prefs.viewport!==null,Pl=48,Fe=Kt?.started??!1,la=g.resizing||Fe||nt,[ye,El]=R.useState({}),[tn,wn]=R.useState({}),[Ml,en]=R.useState(!1),[ln,na]=R.useState(null),On=R.useRef(null);R.useEffect(()=>()=>{On.current=g.active},[g.active]),d.current=()=>{!Ml&&ve!==null&&na(ve),(ve!==null||Ml)&&en(h=>!h)};const ve=n2({active:g.active,previous:On.current,pinned:ln,parent:g.parentOf(g.active),rows:g.rows}),ie=a2({active:g.active,compare:ve,split:Ml}),le=ie.length>1,xe=[...new Set([...g.panes,...ie])],aa=R.useRef(null),ua=R.useRef(null),[O,K]=R.useState({height:0,width:0}),St=R.useCallback(h=>{if(aa.current=h,ua.current?.disconnect(),h===null)return;const B=h.getBoundingClientRect();K({height:B.height,width:B.width});const Z=new ResizeObserver(([W])=>{const ct=W?.contentRect;ct&&K({height:ct.height,width:ct.width})});Z.observe(h),ua.current=Z},[]),{boxHeight:ht,boxWidth:mt,designWidth:Wt,frameHeight:Gt,scale:oe,scaling:Ee}=c2({gutter:Pl,panes:ie.length,scaleSplit:g.prefs.scaleSplit,stageHeight:O.height,stageWidth:O.width,viewport:g.prefs.viewport}),Ga=P?(()=>{const{x:h,y:B}=v2(P);return{bottom:"auto",left:h,right:"auto",top:B}})():void 0,_n=h=>{if(h.button!==0)return;const B=aa.current?.getBoundingClientRect();if(!B)return;const Z=h.currentTarget;Z.setPointerCapture(h.pointerId),it.current=!1;const W={x:h.clientX,y:h.clientY};let ct=!1;const At=_t=>{!ct&&!b2(W,{x:_t.clientX,y:_t.clientY})||(ct=!0,J(y2({x:_t.clientX-B.left,y:_t.clientY-B.top},{width:B.width,height:B.height})))},Ct=_t=>{if(Z.hasPointerCapture(_t.pointerId)&&Z.releasePointerCapture(_t.pointerId),Z.removeEventListener("pointermove",At),Z.removeEventListener("pointerup",Ct),Z.removeEventListener("pointercancel",Ct),J(null),!ct)return;it.current=!0;const{corner:te}=x2({x:_t.clientX-B.left,y:_t.clientY-B.top},{width:B.width,height:B.height});g.setPrefs(de=>({...de,corner:te})),F(!1)};Z.addEventListener("pointermove",At),Z.addEventListener("pointerup",Ct),Z.addEventListener("pointercancel",Ct)},[Xe,Xa]=R.useState(e2),Cl=new Set(c.filter(b0).map(h=>h.title)),qu=Cl.size>0,[nn,ka]=R.useState({requests:[],agent:C0}),[hl,Lu]=R.useState(k2),[Al,fe]=R.useReducer(h=>h+1,0);R.useEffect(()=>{let h=!1;return R2().then(B=>{h||Lu(Z=>JSON.stringify(Z)===JSON.stringify(B)?Z:B)}).catch(()=>{}),()=>{h=!0}},[Al]);const[ze,ml]=R.useReducer(h=>h+1,0);R.useEffect(()=>{let h=!1;const B=()=>fetch("/leglas/api/requests").then(W=>W.json()).then(W=>{if(h)return;const ct={requests:W.requests,agent:W.agent??C0};ka(At=>JSON.stringify(At)===JSON.stringify(ct)?At:ct)}).catch(()=>{}),Z=window.setInterval(()=>{B()},2e3);return B(),()=>{h=!0,window.clearInterval(Z)}},[ze]);const Jt=w2(hl.choice,hl.agents,g.prefs.agentPickerDismissed,hl.customRun),tc=Jt.kind==="chosen"&&hl.agents.some(h=>h.id===Jt.id&&h.auth==="signed-out"),qt=_2(nn.requests,nn.agent,Jt.kind==="chosen"||nn.agent.attached),Rn=qt?.kind==="running"?qt.startedAt:null,[Un,ia]=R.useState(()=>Date.now());R.useEffect(()=>{if(Rn===null)return;ia(Date.now());const h=window.setInterval(()=>ia(Date.now()),1e3);return()=>window.clearInterval(h)},[Rn]),R.useEffect(()=>{Jt.kind==="none"&&q(!1)},[Jt.kind]),R.useEffect(()=>{z||(yt(null),v(!1))},[z]),R.useEffect(()=>{if(!z)return;ft.current?.focus();const h=W=>{W.key==="Escape"&&(q(!1),Tt.current?.focus())},B=W=>{const ct=W.target;!ft.current?.contains(ct)&&!Tt.current?.contains(ct)&&q(!1)},Z=()=>q(!1);return window.addEventListener("keydown",h),window.addEventListener("pointerdown",B),window.addEventListener("blur",Z),()=>{window.removeEventListener("keydown",h),window.removeEventListener("pointerdown",B),window.removeEventListener("blur",Z)}},[z]);const Tl=(h,B)=>{pt===null&&($t(h),U2(h,B).then(()=>{fe(),q(!1)}).catch(()=>{g.notify({kind:"agent-choice",message:h==="custom"?"That command could not be saved. Nothing changed.":"That agent could not be selected. No run started.",tone:"danger",ttl:we.action})}).finally(()=>$t(null)))},an=h=>{N===null&&(k("cancel"),H2(h).then(()=>ml()).catch(()=>{g.notify({kind:"agent-cancel",message:"Leglas could not stop that run.",tone:"danger",ttl:we.action})}).finally(()=>k(null)))},Hn=h=>{N===null&&(k("retry"),B2(h).then(()=>ml()).catch(()=>{g.notify({kind:"agent-retry",message:"That change could not be retried.",tone:"danger",ttl:we.action})}).finally(()=>k(null)))},Rl=(h,B)=>{Co(B).then(Z=>{g.notify({kind:"agent-connect",message:Z==="copied"?`${h} copied.`:"Your browser blocked the clipboard. The README carries the same snippet.",tone:Z==="copied"?"success":"danger",ttl:we.plain})})},re=h=>{N===null&&(k("dismiss"),q2(h).then(()=>ml()).catch(()=>{g.notify({kind:"agent-dismiss",message:"That change could not be dismissed.",tone:"danger",ttl:we.action})}).finally(()=>k(null)))},Qa=R.useRef(g.loaded);Qa.current=g.loaded,R.useEffect(()=>{let h=!1;const B=()=>fetch("/leglas/api/health").then(W=>W.json()).then(({reachable:W})=>{h||Xa(ct=>l2(ct,W))}).catch(()=>{}),Z=window.setInterval(B,3e3);return B(),()=>{h=!0,window.clearInterval(Z)}},[]),R.useEffect(()=>{!Xe.reachable||!Xe.wasDown||(El(h=>{const B={...h};for(const Z of Object.keys(B))Cl.has(Z)&&(B[Z]=!1);return B}),wn(h=>{const B={...h};for(const Z of Object.keys(Qa.current))Cl.has(Z)&&(B[Z]=(B[Z]??0)+1);return B}),Xa(h=>({...h,wasDown:!1})))},[Xe.reachable,Xe.wasDown]);const[ca,gl]=R.useState({}),Ie=m2(ca),un=(h,B)=>{let Z=null;try{Z=h.contentDocument}catch{return}if(!Z?.head)return;const W="leglas-hide-dev-overlays",ct=(At,Ct,_t)=>{const te=At.getElementById(W);if(!B){te?.remove();return}if(te)return;const de=Z.createElement("style");de.id=W,de.textContent=_t,Ct.appendChild(de)};ct(Z,Z.head,s2);for(const At of Z.querySelectorAll("nextjs-portal")){const Ct=At.shadowRoot;Ct&&ct(Ct,Ct,o2)}};R.useEffect(()=>{for(const h of document.querySelectorAll("iframe"))un(h,!g.prefs.showDevOverlays)});const Za=(h,B)=>{let Z=null;try{Z=B.contentDocument}catch{return}if(!Z?.body)return;const W=[...Z.body.querySelectorAll("*")].slice(0,400).map(_t=>_t.tagName),ct=Z.defaultView,At=ct?h2(Z.body,_t=>{const te=ct.getComputedStyle(_t);return{backgroundColor:te.backgroundColor,backgroundImage:te.backgroundImage,color:te.color}}):[],Ct=r2(Z.body.innerText??"",W,At);gl(_t=>_t[h]===Ct?_t:{..._t,[h]:Ct})},Yu=Xe.reachable?c:c.filter(h=>!b0(h)),zl=g2(Yu,ca,xe)[0]??null,sa=h=>(Xe.reachable||!Cl.has(h))&&!(h in ca)&&g.urlFor(h).startsWith("/");R.useEffect(()=>{if(zl===null)return;const h=window.setTimeout(()=>{gl(B=>zl in B?B:{...B,[zl]:null})},M0);return()=>clearTimeout(h)},[zl]);const oa=(h,B)=>{un(B,!g.prefs.showDevOverlays),window.setTimeout(()=>{un(B,!g.prefs.showDevOverlays);let Z=!1;try{Z=B.contentDocument!=null}catch{Z=!1}Z?Za(h,B):gl(W=>({...W,[h]:null}))},600)};R.useEffect(()=>{if(g.loaded[g.active]||ye[g.active])return;const h=Xe.reachable||!Cl.has(g.active)?M0:0,B=setTimeout(()=>El(Z=>({...Z,[g.active]:!0})),h);return()=>clearTimeout(B)},[g.active,g.loaded,ye,tn,Xe.reachable]);const pl=h=>{El(B=>({...B,[h]:!1})),g.resetLoaded(h),wn(B=>({...B,[h]:(B[h]??0)+1}))},_e=(h,B)=>Z=>{if(Z.button!==0||g.renaming||g.query.trim()||g.rows.length<2||Z.target.closest("button, [data-selectable]"))return;const W=xl.current,ct=W?.parentElement;if(!W||!ct)return;const At=[...W.querySelectorAll("li[data-title]")],Ct=At.map(Re=>({height:Re.offsetHeight,mid:Re.offsetTop+Re.offsetHeight/2,title:Re.dataset.title??"",top:Re.offsetTop})),_t=ct.getBoundingClientRect(),te=At[B]?.getBoundingClientRect();_l.current={maxDy:te?_t.bottom-te.bottom:0,minDy:te?_t.top-te.top:0,rows:Ct,startX:Z.clientX,startY:Z.clientY,suppressed:!1};const de=Ct[0],ne=Ct[1];We({dy:0,from:B,gap:de&&ne?ne.top-de.top-de.height:0,height:Ct[B]?.height??0,title:h,settling:!1,started:!1,to:B})},Gu=h=>{if(!Kt?.started)return 0;const B=Kt.height+Kt.gap;return h<Kt.from&&h>=Kt.to?B:h>Kt.from&&h<=Kt.to?-B:0},ec=h=>{window.open(g.urlFor(h),"_blank","noopener,noreferrer")},Va=(h,B)=>{const Z=h===g.active,W=g.previewFor(h),ct=Fe&&Kt?.title===h,At=Fe&&!ct?Gu(B):0,Ct=g.rowMeta.get(h),_t=Ct?.depth===1,te=Ct?.variants??0,de=Ct?.folded??!1,ne=g.renaming===h,Re=Fe||ne?"":"group-hover:hidden group-has-[button:focus-visible]:hidden";return s.jsxs("li",{className:`group relative ${ct?`z-30 rounded-md bg-white/[0.06] shadow-2xl ${Kt?.settling?`transition-transform duration-200 ${Pn} motion-reduce:transition-none`:""}`:"z-10"} ${Fe&&!ct?`transition-transform duration-200 ${Pn} motion-reduce:transition-none`:""}`,"data-title":h,onPointerEnter:Ft=>rl({height:Ft.currentTarget.offsetHeight,on:!0,top:Ft.currentTarget.offsetTop}),style:ct?{transform:`translateY(${Kt?.dy??0}px)`}:At?{transform:`translateY(${At}px)`}:void 0,children:[s.jsx("div",{"aria-pressed":Z,className:`relative flex w-full cursor-grab items-start gap-2 rounded-md py-2 pr-3 text-left transition-colors active:cursor-grabbing ${_t?"pl-11":"pl-3"} ${Z?"bg-[#2E2E2E] ring-1 ring-inset ring-[#D1D5DB]/40":""}`,onClick:()=>{if(!ne){if(_l.current?.suppressed){_l.current.suppressed=!1;return}g.setActive(h)}},onDoubleClick:Ft=>{ne||Ft.target.closest("button")||(window.getSelection()?.removeAllRanges(),ec(h))},onKeyDown:Ft=>{Ft.target===Ft.currentTarget&&(Ft.key==="Enter"||Ft.key===" ")&&(Ft.preventDefault(),g.setActive(h))},onPointerDown:_e(h,B),role:"button",tabIndex:0,children:s.jsxs("span",{className:"min-w-0 flex-1",children:[s.jsxs("span",{className:`flex items-center gap-2 ${Fe||ne?"":Z?"group-hover:pr-[72px] group-has-[button:focus-visible]:pr-[72px]":"group-hover:pr-[98px] group-has-[button:focus-visible]:pr-[98px]"}`,children:[te>0&&s.jsx(Ge,{label:de?`Show ${te} variant${te===1?"":"s"}`:"Fold the variants away",children:s.jsxs("button",{"aria-expanded":!de,"aria-label":`${de?"Show":"Hide"} the variants of ${g.displayName(h)}`,className:"-ml-1 flex shrink-0 items-center gap-1 rounded px-0.5 py-1 text-[#84848C] transition-colors hover:text-[#E8EAED]",onClick:Ft=>{Ft.stopPropagation(),g.toggleFamily(h)},onPointerDown:Ft=>Ft.stopPropagation(),type:"button",children:[s.jsx("svg",{className:`size-2.5 transition-transform duration-150 motion-reduce:transition-none ${de?"-rotate-90":""}`,fill:"none",stroke:"currentColor",strokeWidth:2,viewBox:"0 0 10 10",children:s.jsx("path",{d:"M2 3.5 5 6.5 8 3.5",strokeLinecap:"round",strokeLinejoin:"round"})}),de?s.jsx("span",{className:"text-[10px] leading-none tabular-nums",children:te}):null]})}),ne?s.jsx(km,{error:g.renameError,initial:g.displayName(h),label:`Rename the ${g.displayName(h)} direction`,onCancel:()=>g.startRename(null),onCommit:(Ft,Xu)=>g.rename(h,Ft,Xu)}):s.jsx("span",{className:`min-w-0 flex-1 text-sm font-medium leading-5 transition-colors duration-150 ${Z?"text-white":"text-[#D1D5DB] group-hover:text-[#E8EAED]"}`,children:s.jsx("span",{className:`block w-fit min-w-[70%] max-w-full cursor-text truncate -my-1 py-1 pr-2 ${te>0?"":"-ml-3 pl-3"}`,onDoubleClick:Ft=>{Ft.stopPropagation(),window.getSelection()?.removeAllRanges(),g.startRename(h)},children:g.displayName(h)})}),le&&h===ve?s.jsx("span",{className:`shrink-0 rounded bg-white/[0.08] px-1.5 py-0.5 text-[10px] font-medium leading-normal text-[#E8E8EA] ${Re}`,children:"Comparing"}):Ie[h]?s.jsx(Ge,{label:`Renders the same page as ${Ie[h]?.join(", ")}. Check the URL.`,children:s.jsxs("span",{className:`shrink-0 rounded bg-amber-400/10 px-1.5 py-0.5 text-[10px] font-medium leading-normal text-amber-300/90 ${Re}`,children:["Same as ",Ie[h]?.length===1?Ie[h]?.[0]:`${Ie[h]?.length} others`]})}):sa(h)?s.jsxs("span",{className:`flex h-5 shrink-0 items-center gap-1 rounded bg-white/[0.04] pl-0.5 pr-1.5 text-[10px] font-medium leading-none text-[#84848C]/80 ${Re}`,children:[s.jsx(D0,{"aria-label":"Checking for duplicates",size:20,state:j0,theme:"dark"}),"Cooking"]}):W?.tags[0]&&s.jsx("span",{className:`shrink-0 rounded px-1.5 py-0.5 text-[10px] font-medium leading-normal ${Re}`,style:L2(W.tags[0]),children:W.tags[0]})]}),s.jsx("span",{className:`mt-0.5 line-clamp-2 block cursor-text text-xs leading-snug transition-colors ${ne&&g.renameError?"text-amber-300/90":Z?"text-[#D1D5DB]":"text-[#84848C]"}`,id:ne&&g.renameError?"leglas-rename-error":void 0,children:ne&&g.renameError?g.renameError:W?.note??W?.url})]})}),s.jsxs("div",{className:`pointer-events-none absolute right-2 top-1.5 flex items-center gap-0.5 opacity-0 transition-opacity duration-150 ${ne?"invisible":""} ${Fe?"":"group-hover:pointer-events-auto group-hover:opacity-100 group-has-[button:focus-visible]:pointer-events-auto group-has-[button:focus-visible]:opacity-100"}`,children:[h!==g.active&&s.jsx(Ge,{label:le&&h===ve?"Stop comparing":`Compare with ${g.displayName(g.active)}`,children:s.jsx("button",{"aria-label":le&&h===ve?`Stop comparing ${g.displayName(h)}`:`Compare ${g.displayName(h)} with ${g.displayName(g.active)}`,"aria-pressed":le&&h===ve,className:`${Hu} ${le&&h===ve?"text-white":""}`,onClick:Ft=>{if(Ft.stopPropagation(),le&&h===ve){en(!1);return}na(h),en(!0)},type:"button",children:s.jsx(sl,{d:cl.split})})}),s.jsx(Ge,{label:g.copied?.kind==="link"&&g.copied.title===h?"Copied":"Copy preview link",children:s.jsx("button",{"aria-label":`Copy the preview link to the ${g.displayName(h)} direction`,className:Hu,onClick:()=>g.copyLink(h),type:"button",children:g.copied?.kind==="link"&&g.copied.title===h?s.jsx("span",{className:"text-[10px] text-emerald-300",children:"✓"}):s.jsx(sl,{d:cl.link})})}),s.jsx(Ge,{label:g.copied?.kind==="reference"&&g.copied.title===h?"Copied":s.jsxs(s.Fragment,{children:[s.jsx("span",{className:"block",children:"Copy a detailed reference."}),s.jsx("span",{className:"block",children:"For a teammate or an agent."})]}),children:s.jsx("button",{"aria-label":`Copy a detailed reference to the ${g.displayName(h)} direction`,className:Hu,onClick:()=>g.copyReference(h),type:"button",children:g.copied?.kind==="reference"&&g.copied.title===h?s.jsx("span",{className:"text-[10px] text-emerald-300",children:"✓"}):s.jsx(sl,{d:cl.copy,size:12})})}),s.jsx(Ge,{label:"Rename",children:s.jsx("button",{"aria-label":`Rename the ${g.displayName(h)} direction`,className:Hu,onClick:()=>g.startRename(h),type:"button",children:s.jsx(sl,{d:cl.pencil,size:12})})}),s.jsx(Ge,{label:"Remove from list",children:s.jsx("button",{"aria-label":`Remove the ${g.displayName(h)} direction from the list`,className:Hu,onClick:()=>g.hide(h),type:"button",children:s.jsx(sl,{d:cl.trash,size:12})})})]})]},h)};return s.jsxs("main",{className:`flex h-dvh bg-[#1C1C20] text-white antialiased selection:bg-[#E6E8EC] selection:text-[#17181B] ${g.resizing?"cursor-col-resize":""} ${la?"select-none":""}`,"data-leglas-shell":"",style:{fontFamily:dl.stack},children:[s.jsxs("aside",{className:`relative shrink-0 overflow-hidden border-r border-[#232328] ${g.prefs.collapsed?"":"shadow-2xl"} ${g.resizing?"":`transition-[width] duration-200 ${Pn} motion-reduce:transition-none`}`,style:{width:g.prefs.collapsed?48:g.prefs.width},children:[s.jsxs("div",{className:`flex h-full flex-col transition-opacity duration-150 ${g.prefs.collapsed?"pointer-events-none opacity-0":"opacity-100"}`,inert:g.prefs.collapsed,style:{width:g.prefs.width},children:[s.jsxs("div",{className:"z-10 flex shrink-0 items-center justify-between gap-2 border-b border-[#232328] bg-[#1E1E22] px-2.5 py-2.5",children:[s.jsxs("span",{className:"flex min-w-0 items-center gap-2",children:[s.jsx(Ii,{size:28}),s.jsx(Xm,{height:18})]}),s.jsx(Ge,{label:s.jsxs(s.Fragment,{children:["Collapse panel ",s.jsx("kbd",{className:"ml-1 text-[#9CA3AF]",children:"["})]}),side:"right",children:s.jsx("button",{"aria-label":"Collapse the directions panel",className:"flex h-6 w-6 shrink-0 items-center justify-center rounded p-1 text-[#9CA3AF] transition-colors hover:bg-[#2E2E2E] hover:text-white",onClick:()=>g.setPrefs(h=>({...h,collapsed:!0})),type:"button",children:s.jsx(sl,{d:cl.sidebar,size:16})})})]}),s.jsx("div",{className:"px-3 pb-1 pt-2",children:s.jsxs("div",{className:"relative",children:[s.jsx("span",{className:"pointer-events-none absolute left-2 top-1/2 -translate-y-1/2 text-[#D1D5DB]",children:s.jsx(sl,{d:cl.search})}),s.jsx("kbd",{className:`pointer-events-none absolute right-2 top-1/2 -translate-y-1/2 rounded border border-[#232328] bg-[#2E2E2E]/60 px-1.5 py-0.5 font-sans text-[10px] leading-none tracking-wide text-[#84848C] transition-opacity duration-150 motion-reduce:transition-none ${g.query||et?"opacity-0":"opacity-100"}`,children:Q2}),s.jsx("input",{"aria-label":"Search directions",className:"w-full rounded-md border border-[#232328] bg-[#2E2E2E]/40 py-1.5 pl-7 pr-16 text-xs text-white placeholder:text-[#E8EAED] focus:outline-none focus:ring-1 focus:ring-[#D1D5DB]/60",onBlur:()=>lt(!1),onFocus:()=>lt(!0),onChange:h=>g.setQuery(h.target.value),onKeyDown:h=>{h.key==="Escape"&&(g.query?g.setQuery(""):h.currentTarget.blur())},placeholder:"Search directions…",ref:m,type:"text",value:g.query})]})}),qu&&!Xe.reachable&&s.jsxs("div",{className:"mx-3 mb-1 mt-1 rounded-md border border-amber-400/20 bg-amber-400/[0.07] px-2.5 py-2",children:[s.jsx("p",{className:"text-xs font-medium text-amber-300/90",children:"Dev server not responding"}),s.jsx("p",{className:"mt-0.5 text-[11px] leading-snug text-[#9CA3AF]",children:"Anything on screen is from before it stopped. Previews return on their own once it is back."})]}),s.jsxs("div",{className:"flex-1 overflow-y-auto px-3 py-2 [scrollbar-width:none] [&::-webkit-scrollbar]:hidden",children:[s.jsxs("ul",{className:"relative flex flex-col gap-1",onPointerLeave:()=>rl(h=>({...h,on:!1})),ref:xl,children:[s.jsx("div",{"aria-hidden":!0,className:`pointer-events-none absolute left-0 right-0 z-0 rounded-md bg-white/[0.06] transition-[transform,height,opacity] duration-150 ${Pn} motion-reduce:transition-none`,style:{height:fl.height,opacity:fl.on&&!Fe?1:0,transform:`translateY(${fl.top}px)`}}),g.rows.map((h,B)=>Va(h,B))]}),g.rows.length===0&&s.jsx("div",{className:"px-3 py-2",children:g.query.trim()?s.jsxs(s.Fragment,{children:[s.jsxs("p",{className:"text-xs text-[#9CA3AF]",children:["Nothing matches “",g.query,"”."]}),s.jsx("button",{className:"mt-1 rounded text-xs text-[#84848C] underline underline-offset-2 transition-colors hover:text-[#D1D5DB]",onClick:()=>g.setQuery(""),type:"button",children:"Clear search"})]}):s.jsx("p",{className:"text-xs leading-snug text-[#9CA3AF]",children:g.visibleCount===0&&g.hiddenCount>0?"Every direction is removed. Restore one below.":"No directions yet. Add them to leglas.config.ts."})}),g.hiddenCount>0&&s.jsxs("div",{className:"mt-1 flex items-center justify-between gap-2",children:[s.jsxs("button",{className:"min-w-0 flex-1 rounded px-3 py-1.5 text-left text-[11px] text-[#84848C] transition-colors hover:text-[#D1D5DB]",onClick:()=>g.setShowHidden(h=>!h),type:"button",children:[g.showHidden?"Hide":"Show"," removed (",g.hiddenCount,")"]}),g.showHidden?s.jsx("button",{className:"rounded px-3 py-1.5 text-[11px] text-[#9CA3AF] transition-[color,scale] hover:text-red-300 active:scale-[0.96]",onClick:()=>D({error:null,titles:[...g.prefs.hidden]}),type:"button",children:"Clear all"}):null]}),g.showHidden&&s.jsx("ul",{className:"relative",children:g.prefs.hidden.filter(g.matches).map(h=>s.jsx("li",{className:"group relative",children:s.jsxs("div",{className:"flex items-center justify-between rounded-md px-3 py-2 transition-colors group-hover:bg-white/[0.04]",children:[s.jsx("span",{className:"truncate text-sm font-medium text-[#9CA3AF]",children:g.displayName(h)}),s.jsxs("div",{className:"flex shrink-0 items-center gap-3",children:[s.jsx("button",{className:"rounded text-[11px] text-[#9CA3AF] transition-colors hover:text-white",onClick:()=>{g.restore(h),g.notify({kind:`remove:${h}`,message:`${g.displayName(h)} is back in the list`,tone:"success",ttl:we.plain})},type:"button",children:"Restore"}),s.jsx("button",{className:"rounded text-[11px] text-[#84848C] transition-[color,scale] hover:text-red-300 active:scale-[0.96]",onClick:()=>D({error:null,titles:[h]}),type:"button",children:"Delete"})]})]})},h))})]}),s.jsxs("div",{ref:Vt,children:[qt!==null&&s.jsx("div",{className:"mx-3 mt-2 rounded-lg border border-[#232328] bg-[#1E1E22] px-2.5 py-2 shadow-lg",role:"status",children:s.jsxs("div",{className:"flex items-center gap-2",children:[qt.kind==="failed"?s.jsxs("svg",{"aria-hidden":"true",className:"shrink-0 text-amber-400/90",fill:"none",height:"14",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5",viewBox:"0 0 16 16",width:"14",children:[s.jsx("path",{d:"M8 2.6 14.6 13.4H1.4Z"}),s.jsx("path",{d:"M8 6.8v2.7"}),s.jsx("path",{d:"M8 11.6h.01"})]}):qt.kind==="queued"?s.jsx("span",{"aria-hidden":"true",className:"flex size-3.5 shrink-0 items-center justify-center",children:s.jsx("span",{className:"size-1.5 animate-pulse rounded-full bg-[#84848C] motion-reduce:animate-none"})}):s.jsx("span",{"aria-hidden":"true",className:"size-3.5 shrink-0 animate-spin rounded-full border-[1.5px] border-white/15 border-t-white/70 motion-reduce:animate-none"}),s.jsxs("div",{className:"min-w-0 flex-1",children:[s.jsx("p",{className:"truncate text-[11px] font-medium leading-tight text-[#D1D5DB]",children:qt.kind==="running"?`${qt.name} is on it`:qt.kind==="queued"?qt.count===1?"Change queued":`${qt.count} changes queued`:qt.kind==="picked-up"?"Your agent is on it":"That change failed"}),qt.kind==="running"&&(qt.activity??qt.title)!==null&&s.jsx("p",{className:"mt-0.5 truncate text-[10px] leading-tight text-[#84848C]",children:qt.activity??qt.title})||qt.kind==="queued"&&s.jsx("p",{className:"mt-0.5 truncate text-[10px] leading-tight text-[#84848C]",children:qt.attended?"your agent picks it up next":Jt.kind==="manual"?"waiting for your own agent":"pick who runs your changes"})||qt.kind==="failed"&&s.jsx("p",{className:"mt-0.5 truncate text-[10px] leading-tight text-[#84848C]",children:qt.title})]}),qt.kind==="running"&&Rn!==null&&s.jsx("span",{className:"shrink-0 text-[10px] tabular-nums text-[#84848C]",children:O2(Un-Rn)}),qt.kind==="running"&&s.jsx(Ge,{label:"Stop this run",children:s.jsx("button",{"aria-label":"Stop this run",className:"flex h-6 w-6 shrink-0 items-center justify-center rounded-md text-[#84848C] transition-[background-color,color,transform] duration-150 hover:bg-white/[0.06] hover:text-white active:scale-[0.96] disabled:cursor-wait disabled:opacity-40 motion-reduce:transition-none",disabled:N!==null,onClick:()=>an(qt.id),type:"button",children:N==="cancel"?s.jsx("span",{className:"size-3 animate-spin rounded-full border-[1.5px] border-current border-t-transparent motion-reduce:animate-none"}):s.jsx("span",{className:"block size-2 rounded-[2px] bg-current"})})}),qt.kind==="failed"&&s.jsxs("span",{className:"flex shrink-0 items-center",children:[s.jsx(Ge,{label:"Try it again",children:s.jsx("button",{"aria-label":"Retry this change",className:"flex h-6 w-6 items-center justify-center rounded-md text-[#84848C] transition-[background-color,color,transform] duration-150 hover:bg-white/[0.06] hover:text-white active:scale-[0.96] disabled:cursor-wait disabled:opacity-40 motion-reduce:transition-none",disabled:N!==null,onClick:()=>Hn(qt.id),type:"button",children:N==="retry"?s.jsx("span",{className:"size-3 animate-spin rounded-full border-[1.5px] border-current border-t-transparent motion-reduce:animate-none"}):s.jsxs("svg",{"aria-hidden":"true",fill:"none",height:"13",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.75",viewBox:"0 0 16 16",width:"13",children:[s.jsx("path",{d:"M13.5 8a5.5 5.5 0 1 1-1.6-3.9"}),s.jsx("path",{d:"M13.7 1.8v2.7H11"})]})})}),s.jsx(Ge,{label:"Let it go",children:s.jsx("button",{"aria-label":"Dismiss this failed change",className:"flex h-6 w-6 items-center justify-center rounded-md text-[#84848C] transition-[background-color,color,transform] duration-150 hover:bg-white/[0.06] hover:text-white active:scale-[0.96] disabled:cursor-wait disabled:opacity-40 motion-reduce:transition-none",disabled:N!==null,onClick:()=>re(qt.id),type:"button",children:N==="dismiss"?s.jsx("span",{className:"size-3 animate-spin rounded-full border-[1.5px] border-current border-t-transparent motion-reduce:animate-none"}):s.jsx("svg",{"aria-hidden":"true",fill:"none",height:"13",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.75",viewBox:"0 0 16 16",width:"13",children:s.jsx("path",{d:"m4 4 8 8M12 4l-8 8"})})})})]})]})}),s.jsx("form",{className:"relative px-3 pb-2.5 pt-2",onSubmit:h=>{h.preventDefault();const B=ut.trim(),Z=g.active;if(!B||!Z||gt)return;const W=g.displayName(Z);Ht(!0),fetch("/leglas/api/request",{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({title:Z,intent:B})}).then(ct=>ct.json()).then(ct=>{if(!ct.ok||!ct.prompt)throw new Error("refused");xt(""),Ht(!1),ml(),g.notify({kind:"request",message:`Asked for a change to ${W}.`,tone:"success",ttl:we.plain}),Co(ct.prompt).then(At=>{g.notify({kind:"request",message:At==="copied"?`Asked for a change to ${W}. Prompt copied.`:`Asked for a change to ${W}. Your browser blocked the clipboard, so read it with npx leglas requests.`,tone:"success",ttl:we.plain})})}).catch(()=>{Ht(!1),g.notify({kind:"request",message:`That request never reached Leglas. ${W} is unchanged.`,tone:"danger",ttl:we.action})})},children:s.jsxs("div",{className:"rounded-md border border-[#232328] bg-[#2E2E2E]/40 transition-colors focus-within:border-[#D1D5DB]/40 focus-within:ring-1 focus-within:ring-[#D1D5DB]/40",children:[s.jsx("textarea",{"aria-label":g.active?`Ask your agent to change the ${g.displayName(g.active)} direction`:"Ask your agent to change a direction",className:"block w-full resize-none overflow-y-auto bg-transparent px-2.5 pb-1 pt-2 text-xs leading-4 text-white placeholder:text-[#84848C] focus:outline-none disabled:cursor-not-allowed disabled:opacity-60",disabled:gt||!g.active,onChange:h=>xt(h.target.value),onKeyDown:h=>{h.key==="Enter"&&!h.shiftKey&&(h.preventDefault(),h.currentTarget.form?.requestSubmit())},placeholder:g.active?`Change ${g.displayName(g.active)}…`:"No direction to change yet",ref:f,rows:1,value:ut}),s.jsxs("div",{className:"flex items-center justify-end gap-1.5 p-1",children:[Jt.kind==="none"?s.jsxs("span",{className:"mr-auto min-w-0 truncate px-1.5 text-[10px] leading-snug text-[#84848C]",children:["Enter queues it for ",s.jsx("span",{className:"font-medium",children:"npx leglas requests"})]}):s.jsxs("div",{className:"relative flex min-w-0 items-center",children:[s.jsx("div",{"aria-hidden":!z,"aria-label":"Who runs your changes",className:`absolute bottom-full right-0 z-10 mb-1.5 w-max min-w-36 origin-bottom-right rounded-lg border border-[#232328] bg-[#1E1E22] p-1 text-[#D1D5DB] shadow-2xl transition-[opacity,transform] duration-150 ease-[cubic-bezier(0.165,0.84,0.44,1)] focus:outline-none motion-reduce:transition-none ${z?"translate-y-0 scale-100 opacity-100":"pointer-events-none translate-y-1 scale-95 opacity-0"}`,inert:!z,ref:ft,role:"dialog",tabIndex:-1,children:$!==null?s.jsxs("div",{className:"w-60 p-1",children:[s.jsx("label",{className:"block px-1 pb-1 text-[10px] leading-snug text-[#84848C]",htmlFor:"leglas-custom-run",children:"The command that runs your agent."}),s.jsx("input",{className:"w-full rounded border border-[#232328] bg-[#2E2E2E]/40 px-2 py-1 font-mono text-[11px] text-white transition-colors placeholder:text-[#84848C] focus:border-[#D1D5DB]/40 focus:outline-none",id:"leglas-custom-run",onChange:h=>yt(h.target.value),onKeyDown:h=>{h.key==="Enter"&&(h.preventDefault(),$.trim()!==""&&pt===null&&Tl("custom",$.trim()))},placeholder:"npx my-agent",value:$}),s.jsxs("p",{className:"px-1 pt-1 text-[9px] leading-snug text-[#84848C]/80",children:["Your request is added at the end. Put"," ",s.jsx("span",{className:"font-mono",children:"{prompt}"})," where it should go instead, if needed."]}),s.jsxs("div",{className:"flex items-center justify-between pt-1.5",children:[s.jsx("button",{className:"rounded px-1 text-[11px] text-[#84848C] transition-colors hover:text-[#D1D5DB]",onClick:()=>yt(null),type:"button",children:"Back"}),s.jsx("button",{className:"rounded px-1.5 py-0.5 text-[11px] text-[#D1D5DB] transition-colors hover:bg-white/[0.06] hover:text-white disabled:cursor-not-allowed disabled:opacity-40",disabled:$.trim()===""||pt!==null,onClick:()=>Tl("custom",$.trim()),type:"button",children:pt==="custom"?"Saving…":"Save"})]})]}):Mt?s.jsxs("div",{className:"w-64 p-1",children:[s.jsx("p",{className:"px-1 pb-1 text-[10px] leading-snug text-[#84848C]",children:"Give your agent the Leglas tools. Copy the one your agent understands:"}),s.jsxs("button",{className:je,onClick:()=>Rl("The Claude Code command",G2),type:"button",children:[s.jsx("span",{className:"truncate",children:"Claude Code command"}),s.jsx(sl,{d:cl.copy,size:12})]}),s.jsxs("button",{className:je,onClick:()=>Rl("The mcp.json entry",X2),type:"button",children:[s.jsx("span",{className:"truncate",children:"mcp.json for everything else"}),s.jsx(sl,{d:cl.copy,size:12})]}),s.jsx("p",{className:"px-1 pt-1 text-[9px] leading-snug text-[#84848C]/80",children:"Then ask it to handle your Leglas change requests. While it works, the built-in runner stays out of its way."}),s.jsx("div",{className:"flex items-center justify-between pt-1.5",children:s.jsx("button",{className:"rounded px-1 text-[11px] text-[#84848C] transition-colors hover:text-[#D1D5DB]",onClick:()=>v(!1),type:"button",children:"Back"})})]}):s.jsxs(s.Fragment,{children:[hl.agents.filter(h=>h.available).map(h=>{const B=Jt.kind==="chosen"&&h.id===Jt.id;return s.jsxs("button",{className:je,disabled:pt!==null,onClick:()=>B?q(!1):Tl(h.id),type:"button",children:[s.jsxs("span",{className:"flex min-w-0 items-center gap-2",children:[s.jsx(bo,{id:h.id}),s.jsx("span",{className:"truncate",children:h.name})]}),pt===h.id?s.jsx("span",{"aria-label":"selecting",className:"size-3 animate-spin rounded-full border-[1.5px] border-current border-t-transparent motion-reduce:animate-none"}):h.auth==="signed-out"?s.jsx("span",{className:"text-[10px] text-amber-400/80",children:"signed out"}):B&&s.jsx("span",{"aria-label":"current choice",children:"✓"})]},h.id)}),s.jsxs("button",{className:`${je} ${Jt.kind==="chosen"&&Jt.id==="custom"?"":"text-[#84848C]"}`,disabled:pt!==null,onClick:()=>yt(hl.customRun??""),type:"button",children:[s.jsxs("span",{className:"flex min-w-0 items-center gap-2",children:[s.jsx(bo,{id:"custom"}),s.jsx("span",{className:"truncate",children:Jt.kind==="chosen"&&Jt.id==="custom"?Jt.name:"Add your own…"})]}),Jt.kind==="chosen"&&Jt.id==="custom"&&s.jsx("span",{"aria-label":"current choice",children:"✓"})]}),s.jsx("button",{className:`${je} text-[#84848C]`,onClick:()=>v(!0),type:"button",children:s.jsxs("span",{className:"flex min-w-0 items-center gap-2",children:[s.jsx(sl,{d:cl.link,size:14}),s.jsx("span",{className:"truncate",children:"Connect another agent…"})]})}),hl.choice===null&&s.jsxs("button",{className:`${je} text-[#84848C]`,onClick:()=>{g.setPrefs(h=>({...h,agentPickerDismissed:!0})),q(!1)},type:"button",children:[s.jsx("span",{children:"I'll run my own"}),Jt.kind==="manual"&&s.jsx("span",{"aria-label":"current choice",children:"✓"})]}),hl.choice===null&&s.jsx("p",{className:"mt-1 max-w-48 border-t border-[#232328] px-1 pb-0.5 pt-1.5 text-[10px] leading-snug text-[#84848C]",children:"Runs in this project with write access, like in your terminal."})]})}),s.jsxs("button",{"aria-expanded":z,"aria-haspopup":"dialog",className:"flex min-w-0 items-center gap-1.5 rounded px-1.5 py-1 text-[11px] leading-none text-[#84848C] transition-colors hover:bg-white/[0.04] hover:text-[#D1D5DB]",onClick:()=>{z||fe(),q(h=>!h)},ref:Tt,type:"button",children:[Jt.kind==="chosen"&&s.jsx(bo,{id:Jt.id,size:12}),s.jsx("span",{className:"truncate",children:Jt.kind==="chosen"?Jt.name:Jt.kind==="manual"?"I'll run my own":"Choose an agent"}),tc&&s.jsx("span",{className:"size-1.5 shrink-0 rounded-full bg-amber-400",title:"This CLI is signed out. Sign in in your terminal.",children:s.jsx("span",{className:"sr-only",children:"signed out"})}),s.jsx("svg",{"aria-hidden":"true",className:`shrink-0 transition-transform duration-150 motion-reduce:transition-none ${z?"rotate-180":""}`,fill:"none",height:"12",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.75",viewBox:"0 0 16 16",width:"12",children:s.jsx("path",{d:"M4 6.5 8 10.5l4-4"})})]})]}),s.jsx("button",{"aria-label":g.active?`Send the change to ${g.displayName(g.active)}`:"Send the change",className:`flex h-6 w-6 shrink-0 items-center justify-center rounded-md transition-[background-color,color,transform] duration-150 active:scale-[0.96] motion-reduce:transition-none ${ut.trim()!==""&&g.active&&!gt?"bg-[#E8E8EA] text-[#1C1C20] hover:bg-white":"pointer-events-none text-[#84848C]/60"}`,disabled:ut.trim()===""||!g.active||gt,type:"submit",children:gt?s.jsx("span",{className:"size-3 animate-spin rounded-full border-[1.5px] border-current border-t-transparent motion-reduce:animate-none"}):s.jsx("svg",{"aria-hidden":"true",fill:"none",height:"13",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.75",viewBox:"0 0 16 16",width:"13",children:s.jsx("path",{d:"M8 13V3M3.5 7.5 8 3l4.5 4.5"})})})]})]})}),g.prefs.showWidget?nn.agent.attached&&qt===null?s.jsx("div",{className:"px-3 pb-2",children:s.jsx("p",{className:"min-w-0 truncate text-[10px] leading-snug text-[#84848C]",children:"Your agent is listening"})}):null:s.jsx("div",{className:"px-3 pb-2",children:s.jsxs("button",{className:"min-w-0 max-w-full truncate rounded text-left text-[10px] leading-snug text-[#84848C] transition-colors hover:text-[#D1D5DB]",onClick:()=>F(!0),type:"button",children:["Bring the tools back ",s.jsx("kbd",{className:"font-sans text-[#9CA3AF]",children:"T"})]})})]})]}),s.jsxs("div",{className:`absolute inset-y-0 left-0 z-30 flex w-12 flex-col items-center bg-[#1C1C20] py-3 transition-opacity duration-150 ${g.prefs.collapsed?"opacity-100":"pointer-events-none opacity-0"}`,inert:!g.prefs.collapsed,children:[s.jsx(Ii,{size:24}),s.jsx(Ge,{label:s.jsxs(s.Fragment,{children:["Open directions ",s.jsx("kbd",{className:"ml-1 text-[#9CA3AF]",children:"["})]}),side:"right",children:s.jsx("button",{"aria-label":"Open the directions panel",className:"mt-3 flex h-6 w-6 items-center justify-center rounded p-1 text-[#9CA3AF] transition-colors hover:bg-[#2E2E2E] hover:text-white",onClick:()=>g.setPrefs(h=>({...h,collapsed:!1})),type:"button",children:s.jsx(sl,{d:cl.sidebar,size:16})})})]}),!g.prefs.collapsed&&s.jsx("div",{"aria-hidden":!0,className:"group/resize absolute inset-y-0 right-0 z-20 flex w-3 cursor-col-resize touch-none justify-end",onPointerDown:g.onHandlePointerDown,children:s.jsx("span",{className:`h-full transition-all duration-150 ${g.resizing?"w-0.5 bg-[#9CA3AF]":"w-px bg-[#232328] group-hover/resize:w-0.5 group-hover/resize:bg-[#9CA3AF]"}`})})]}),s.jsx("span",{"aria-live":"polite",className:"sr-only",role:"status",children:g.copied===null?"":g.copied.kind==="link"?"Link copied":"Reference copied"}),s.jsxs("div",{className:`relative min-w-0 flex-1 ${le?"flex":"overflow-auto"}`,ref:St,children:[xe.map(h=>s.jsxs("div",{className:ie.includes(h)?le?`relative min-w-0 flex-1 overflow-auto ${h===ve?"border-l border-[#232328]":""} ${Ee?"flex flex-col items-center justify-center gap-2.5":Sl?"flex min-h-full justify-center p-6":""}`:Sl?"flex min-h-full justify-center p-6":"absolute inset-0":"hidden",style:le?{order:ie.indexOf(h)}:void 0,children:[le&&s.jsx("div",{className:Ee?"pointer-events-none z-10 flex justify-center":"pointer-events-none absolute inset-x-0 top-0 z-10 flex justify-center p-3",children:s.jsxs("span",{className:"rounded-full bg-[#1C1C20]/85 px-2.5 py-1 text-[11px] font-medium text-[#E8E8EA] shadow-lg backdrop-blur",children:[g.displayName(h),Ee&&s.jsxs("span",{className:"ml-1.5 font-normal text-[#8E8E96]",children:[Math.round(Wt),"px · ",Math.round(oe*100),"%"]})]})}),s.jsxs("div",{className:Ee?"relative shrink-0 overflow-hidden rounded-[10px] shadow-[0_0_0_1px_rgba(255,255,255,0.12)]":Sl?`relative h-[calc(100dvh-48px)] shrink-0 overflow-hidden rounded-[10px] shadow-[0_0_0_1px_rgba(255,255,255,0.10)] transition-[width] duration-200 ${Pn} motion-reduce:transition-none`:"relative size-full",style:Ee?{height:ht,width:mt}:Sl?{width:g.prefs.viewport??void 0}:void 0,children:[s.jsx("div",{className:Ee?"origin-top-left":"size-full",style:Ee?{height:Gt,transform:`scale(${oe})`,width:Wt}:void 0,children:s.jsx("iframe",{className:`size-full border-0 bg-white ${la?"pointer-events-none":""}`,onError:()=>El(B=>({...B,[h]:!0})),onLoad:B=>{const W=g.urlFor(h).startsWith("/");let ct=!0;if(W)try{ct=B.currentTarget.contentDocument!=null}catch{ct=!1}if(ct){g.markLoaded(h),El(Ct=>Ct[h]?{...Ct,[h]:!1}:Ct);const At=B.currentTarget;un(At,!g.prefs.showDevOverlays),window.setTimeout(()=>{un(At,!g.prefs.showDevOverlays),Za(h,At)},600)}else El(At=>({...At,[h]:!0}))},src:g.urlFor(h),title:`Preview: ${g.displayName(h)}`},tn[h]??0)}),ye[h]?s.jsx($m,{onReload:()=>pl(h),reason:Xe.reachable||!Cl.has(h)?`${g.urlFor(h)} didn’t respond.`:"Your dev server stopped. This returns on its own once it is back."}):s.jsx(Jm,{loaded:!!g.loaded[h]}),!Xe.reachable&&g.loaded[h]&&Cl.has(h)&&s.jsx("div",{className:"pointer-events-none absolute inset-x-0 top-0 flex justify-center p-3",children:s.jsx("span",{className:"rounded-full bg-[#1C1C20]/90 px-2.5 py-1 text-[11px] font-medium text-amber-300/90 shadow-lg",children:"Stale — dev server stopped"})})]})]},h)),s.jsxs("div",{className:`absolute z-50 flex gap-2 ${P?"flex-col items-start":{"bottom-right":"bottom-4 right-4 flex-col items-end","bottom-left":"bottom-4 left-4 flex-col items-start","top-right":"right-4 top-4 flex-col-reverse items-end","top-left":"left-4 top-4 flex-col-reverse items-start"}[g.prefs.corner]}`,style:Ga,children:[s.jsxs("div",{"aria-hidden":!X,"aria-label":"Leglas tools",className:`w-56 rounded-lg border border-[#232328] bg-[#1E1E22] p-1.5 shadow-2xl transition-[opacity,transform] duration-150 ease-[cubic-bezier(0.165,0.84,0.44,1)] focus:outline-none motion-reduce:transition-none ${P?"hidden ":""}${X?"translate-y-0 scale-100 opacity-100":"pointer-events-none translate-y-1 scale-95 opacity-0"}`,inert:!X,ref:ot,role:"dialog",tabIndex:-1,children:[s.jsx("span",{className:"block px-1 pb-1 pt-0.5 text-[10px] uppercase tracking-[0.08em] text-[#84848C]",children:"Typeface"}),s.jsx("div",{"aria-label":"Interface typeface",className:"flex items-center gap-0.5 rounded-md bg-[#2E2E2E]/40 p-0.5",role:"group",children:xo.map(h=>s.jsx("button",{"aria-pressed":dl.key===h.key,className:`flex-1 rounded px-2 py-1 text-xs transition-colors ${dl.key===h.key?"bg-[#2E2E2E] font-medium text-white":"text-[#9CA3AF] hover:text-[#D1D5DB]"}`,onClick:()=>g.setPrefs(B=>({...B,font:h.key})),style:{fontFamily:h.stack},type:"button",children:h.label},h.key))}),s.jsx("span",{className:"block px-1 pb-1 pt-2 text-[10px] uppercase tracking-[0.08em] text-[#84848C]",children:"Viewport"}),s.jsx("div",{"aria-label":"Viewport width",className:"flex items-center gap-0.5 rounded-md bg-[#2E2E2E]/40 p-0.5",role:"group",children:g.viewports.map(({label:h,width:B})=>s.jsx("button",{className:`flex-1 rounded px-2 py-1 text-xs transition-colors ${g.prefs.viewport===B?"bg-[#2E2E2E] font-medium text-white":"text-[#9CA3AF] hover:text-[#D1D5DB]"}`,onClick:()=>g.setPrefs(Z=>({...Z,viewport:B})),type:"button",children:h},h))}),le&&s.jsxs("button",{"aria-checked":g.prefs.scaleSplit,className:`${je} mt-1 ${g.prefs.scaleSplit?"text-white":"text-[#9CA3AF]"}`,onClick:()=>g.setPrefs(h=>({...h,scaleSplit:!h.scaleSplit})),role:"switch",type:"button",children:[s.jsx("span",{children:"Scale each side to fit"}),s.jsx(vo,{on:g.prefs.scaleSplit})]}),s.jsx("span",{className:"block px-1 pb-1 pt-2 text-[10px] uppercase tracking-[0.08em] text-[#84848C]",children:"Dev overlays"}),s.jsxs("button",{"aria-checked":g.prefs.showDevOverlays,className:`${je} ${g.prefs.showDevOverlays?"text-white":"text-[#9CA3AF]"}`,onClick:()=>{const h=!g.prefs.showDevOverlays;g.setPrefs(B=>({...B,showDevOverlays:h}));for(const B of document.querySelectorAll("iframe"))un(B,!h)},role:"switch",type:"button",children:[s.jsx("span",{children:"Show dev tool overlay"}),s.jsx(vo,{on:g.prefs.showDevOverlays})]}),s.jsxs("button",{"aria-checked":g.prefs.showWidget,className:`${je} ${g.prefs.showWidget?"text-white":"text-[#9CA3AF]"}`,onClick:()=>{const h=!g.prefs.showWidget;g.setPrefs(B=>({...B,showWidget:h})),h||g.notify({kind:"widget",message:"Press T to reopen the tools",tone:"info",ttl:we.plain+3e3})},role:"switch",type:"button",children:[s.jsx("span",{children:"Show Leglas overlay"}),s.jsx(vo,{on:g.prefs.showWidget})]}),s.jsxs("button",{className:"mt-1 flex w-full items-center gap-2 rounded-md px-2 py-1.5 text-left text-xs text-[#D1D5DB] transition-colors hover:bg-[#2E2E2E]/60 hover:text-white",onClick:()=>g.copyReference(g.active),type:"button",children:[s.jsx(sl,{d:cl.copy,size:12}),g.copied?.kind==="reference"&&g.copied.title===g.active?"Copied":"Copy reference"]}),s.jsx(Ge,{label:"Or double-click any direction in the rail",children:s.jsxs("a",{className:"flex w-full items-center gap-2 rounded-md px-2 py-1.5 text-left text-xs text-[#D1D5DB] transition-colors hover:bg-[#2E2E2E]/60 hover:text-white",href:g.urlFor(g.active),rel:"noreferrer",target:"_blank",children:[s.jsx("span",{className:"inline-block size-3 rounded-sm border border-current"}),"Open in new tab"]})}),s.jsxs("button",{className:"flex w-full items-center justify-between gap-2 rounded-md px-2 py-1.5 text-left text-xs text-[#D1D5DB] transition-colors hover:bg-[#2E2E2E]/60 hover:text-white",onClick:()=>{F(!1),E(!0)},type:"button",children:[s.jsx("span",{children:"Keyboard shortcuts"}),s.jsx("kbd",{className:"rounded border border-[#232328] bg-[#2E2E2E]/60 px-1 py-0.5 font-sans text-[10px] text-[#84848C]",children:"?"})]})]}),(g.prefs.showWidget||X)&&s.jsx(Ge,{label:"Leglas tools",children:s.jsxs("button",{"aria-expanded":X,"aria-haspopup":"dialog","aria-label":"Leglas tools",className:"relative flex h-11 w-11 items-center justify-center rounded-full border border-white/10 bg-[#1C1C20] shadow-lg transition-[border-color,transform] duration-150 hover:scale-[1.04] hover:border-white/20 active:scale-[0.95] motion-reduce:transform-none motion-reduce:hover:scale-100 motion-reduce:active:scale-100",onClick:()=>{if(it.current){it.current=!1;return}F(h=>!h)},onPointerDown:_n,ref:V,type:"button",children:[s.jsx(Ii,{size:30}),!g.loaded[g.active]&&s.jsx("span",{className:"absolute -right-0.5 -top-0.5 size-2 animate-pulse rounded-full bg-amber-400 motion-reduce:animate-none"})]})})]})]}),s.jsx(Km,{bottom:g.prefs.collapsed?12:wt+8,left:g.prefs.collapsed?60:12,onDismiss:g.dismissToast,toasts:g.toasts,width:(g.prefs.collapsed?320:g.prefs.width)-24}),zl!==null&&s.jsx("iframe",{"aria-hidden":!0,className:"pointer-events-none fixed border-0",onLoad:h=>oa(zl,h.currentTarget),src:g.urlFor(zl),style:{height:800,left:-2400,top:0,width:1280},tabIndex:-1,title:"Off-stage duplicate scan"},zl),y?s.jsx(Z2,{mac:B0,onClose:Y}):null,A!==null?s.jsx(V2,{busy:x,count:A.titles.length,error:A.error,fallbackFocusRef:m,name:A.titles.length===1?g.displayName(A.titles[0]??""):null,onCancel:Q,onConfirm:()=>{I()}}):null]})}function Eo({children:c,title:r}){return s.jsxs("div",{className:"flex h-dvh flex-col items-center justify-center gap-3 bg-[#1C1C20] px-6 text-center antialiased",style:{fontFamily:"var(--font-satoshi)"},children:[s.jsx(Ii,{size:22}),s.jsx("p",{className:"text-sm font-medium text-white",children:r}),s.jsx("div",{className:"max-w-md text-xs leading-relaxed text-[#84848C]",children:c})]})}function J2(){const[c,r]=R.useState({status:"loading"});return R.useEffect(()=>{let m=!1;const f=()=>fetch("/leglas/api/config").then(y=>{if(!y.ok)throw new Error(`the server answered ${y.status}`);return y.json()});f().then(y=>{m||r({status:"ready",config:y})}).catch(y=>{m||r({status:"failed",message:y instanceof Error?y.message:String(y)})});const d=setInterval(()=>{f().then(y=>{m||r(E=>E.status!=="ready"||JSON.stringify(E.config)===JSON.stringify(y)?E:{status:"ready",config:y})}).catch(()=>{})},3e3);return()=>{m=!0,clearInterval(d)}},[]),c.status==="loading"?s.jsx(Eo,{title:"Starting Leglas…",children:null}):c.status==="failed"?s.jsxs(Eo,{title:"Couldn’t reach the Leglas server",children:[c.message,". The interface is served by the same process that proxies your app, so this usually means it stopped."]}):c.config.errors.length>0?s.jsxs(Eo,{title:"Your config needs fixing",children:[s.jsx("ul",{className:"space-y-1 text-left",children:c.config.errors.map(m=>s.jsx("li",{children:m},m))}),s.jsx("p",{className:"mt-3",children:"Fix it and restart Leglas."})]}):s.jsx(K2,{previews:c.config.previews,project:c.config.project})}const q0=document.getElementById("root");if(!q0)throw new Error("Leglas: #root is missing from the document.");Ih.createRoot(q0).render(s.jsx(R.StrictMode,{children:s.jsx(J2,{})}));