@wrongstack/webui 0.1.9 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/index-C1jTV4WR.js +609 -0
- package/dist/assets/index-CRAjL4S_.css +1 -0
- package/dist/index.css +25 -0
- package/dist/index.css.map +1 -1
- package/dist/index.html +2 -2
- package/dist/index.js +4920 -4595
- package/dist/index.js.map +1 -1
- package/dist/server/entry.js +98 -33
- package/dist/server/entry.js.map +1 -1
- package/dist/server/index.js +98 -33
- package/dist/server/index.js.map +1 -1
- package/package.json +4 -4
- package/dist/assets/index-DfJLWoIU.css +0 -1
- package/dist/assets/index-Dt6Hlw_3.js +0 -607
|
@@ -1,607 +0,0 @@
|
|
|
1
|
-
var _S=Object.defineProperty;var LS=(t,r,l)=>r in t?_S(t,r,{enumerable:!0,configurable:!0,writable:!0,value:l}):t[r]=l;var en=(t,r,l)=>LS(t,typeof r!="symbol"?r+"":r,l);function US(t,r){for(var l=0;l<r.length;l++){const i=r[l];if(typeof i!="string"&&!Array.isArray(i)){for(const s in i)if(s!=="default"&&!(s in t)){const u=Object.getOwnPropertyDescriptor(i,s);u&&Object.defineProperty(t,s,u.get?u:{enumerable:!0,get:()=>i[s]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}(function(){const r=document.createElement("link").relList;if(r&&r.supports&&r.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))i(s);new MutationObserver(s=>{for(const u of s)if(u.type==="childList")for(const c of u.addedNodes)c.tagName==="LINK"&&c.rel==="modulepreload"&&i(c)}).observe(document,{childList:!0,subtree:!0});function l(s){const u={};return s.integrity&&(u.integrity=s.integrity),s.referrerPolicy&&(u.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?u.credentials="include":s.crossOrigin==="anonymous"?u.credentials="omit":u.credentials="same-origin",u}function i(s){if(s.ep)return;s.ep=!0;const u=l(s);fetch(s.href,u)}})();function Ri(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var Zc={exports:{}},mi={};/**
|
|
2
|
-
* @license React
|
|
3
|
-
* react-jsx-runtime.production.js
|
|
4
|
-
*
|
|
5
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
6
|
-
*
|
|
7
|
-
* This source code is licensed under the MIT license found in the
|
|
8
|
-
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/var Yg;function BS(){if(Yg)return mi;Yg=1;var t=Symbol.for("react.transitional.element"),r=Symbol.for("react.fragment");function l(i,s,u){var c=null;if(u!==void 0&&(c=""+u),s.key!==void 0&&(c=""+s.key),"key"in s){u={};for(var d in s)d!=="key"&&(u[d]=s[d])}else u=s;return s=u.ref,{$$typeof:t,type:i,key:c,ref:s!==void 0?s:null,props:u}}return mi.Fragment=r,mi.jsx=l,mi.jsxs=l,mi}var Gg;function HS(){return Gg||(Gg=1,Zc.exports=BS()),Zc.exports}var h=HS(),Jc={exports:{}},Me={};/**
|
|
10
|
-
* @license React
|
|
11
|
-
* react.production.js
|
|
12
|
-
*
|
|
13
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
14
|
-
*
|
|
15
|
-
* This source code is licensed under the MIT license found in the
|
|
16
|
-
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/var Pg;function qS(){if(Pg)return Me;Pg=1;var t=Symbol.for("react.transitional.element"),r=Symbol.for("react.portal"),l=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),u=Symbol.for("react.consumer"),c=Symbol.for("react.context"),d=Symbol.for("react.forward_ref"),p=Symbol.for("react.suspense"),m=Symbol.for("react.memo"),x=Symbol.for("react.lazy"),y=Symbol.for("react.activity"),b=Symbol.iterator;function S(T){return T===null||typeof T!="object"?null:(T=b&&T[b]||T["@@iterator"],typeof T=="function"?T:null)}var k={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},N=Object.assign,A={};function j(T,U,E){this.props=T,this.context=U,this.refs=A,this.updater=E||k}j.prototype.isReactComponent={},j.prototype.setState=function(T,U){if(typeof T!="object"&&typeof T!="function"&&T!=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,T,U,"setState")},j.prototype.forceUpdate=function(T){this.updater.enqueueForceUpdate(this,T,"forceUpdate")};function M(){}M.prototype=j.prototype;function z(T,U,E){this.props=T,this.context=U,this.refs=A,this.updater=E||k}var V=z.prototype=new M;V.constructor=z,N(V,j.prototype),V.isPureReactComponent=!0;var Q=Array.isArray;function B(){}var G={H:null,A:null,T:null,S:null},ae=Object.prototype.hasOwnProperty;function se(T,U,E){var O=E.ref;return{$$typeof:t,type:T,key:U,ref:O!==void 0?O:null,props:E}}function L(T,U){return se(T.type,U,T.props)}function P(T){return typeof T=="object"&&T!==null&&T.$$typeof===t}function X(T){var U={"=":"=0",":":"=2"};return"$"+T.replace(/[=:]/g,function(E){return U[E]})}var de=/\/+/g;function I(T,U){return typeof T=="object"&&T!==null&&T.key!=null?X(""+T.key):U.toString(36)}function J(T){switch(T.status){case"fulfilled":return T.value;case"rejected":throw T.reason;default:switch(typeof T.status=="string"?T.then(B,B):(T.status="pending",T.then(function(U){T.status==="pending"&&(T.status="fulfilled",T.value=U)},function(U){T.status==="pending"&&(T.status="rejected",T.reason=U)})),T.status){case"fulfilled":return T.value;case"rejected":throw T.reason}}throw T}function H(T,U,E,O,ee){var re=typeof T;(re==="undefined"||re==="boolean")&&(T=null);var W=!1;if(T===null)W=!0;else switch(re){case"bigint":case"string":case"number":W=!0;break;case"object":switch(T.$$typeof){case t:case r:W=!0;break;case x:return W=T._init,H(W(T._payload),U,E,O,ee)}}if(W)return ee=ee(T),W=O===""?"."+I(T,0):O,Q(ee)?(E="",W!=null&&(E=W.replace(de,"$&/")+"/"),H(ee,U,E,"",function(Ae){return Ae})):ee!=null&&(P(ee)&&(ee=L(ee,E+(ee.key==null||T&&T.key===ee.key?"":(""+ee.key).replace(de,"$&/")+"/")+W)),U.push(ee)),1;W=0;var be=O===""?".":O+":";if(Q(T))for(var we=0;we<T.length;we++)O=T[we],re=be+I(O,we),W+=H(O,U,E,re,ee);else if(we=S(T),typeof we=="function")for(T=we.call(T),we=0;!(O=T.next()).done;)O=O.value,re=be+I(O,we++),W+=H(O,U,E,re,ee);else if(re==="object"){if(typeof T.then=="function")return H(J(T),U,E,O,ee);throw U=String(T),Error("Objects are not valid as a React child (found: "+(U==="[object Object]"?"object with keys {"+Object.keys(T).join(", ")+"}":U)+"). If you meant to render a collection of children, use an array instead.")}return W}function ne(T,U,E){if(T==null)return T;var O=[],ee=0;return H(T,O,"","",function(re){return U.call(E,re,ee++)}),O}function oe(T){if(T._status===-1){var U=T._result;U=U(),U.then(function(E){(T._status===0||T._status===-1)&&(T._status=1,T._result=E)},function(E){(T._status===0||T._status===-1)&&(T._status=2,T._result=E)}),T._status===-1&&(T._status=0,T._result=U)}if(T._status===1)return T._result.default;throw T._result}var ye=typeof reportError=="function"?reportError:function(T){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var U=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(U))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",T);return}console.error(T)},D={map:ne,forEach:function(T,U,E){ne(T,function(){U.apply(this,arguments)},E)},count:function(T){var U=0;return ne(T,function(){U++}),U},toArray:function(T){return ne(T,function(U){return U})||[]},only:function(T){if(!P(T))throw Error("React.Children.only expected to receive a single React element child.");return T}};return Me.Activity=y,Me.Children=D,Me.Component=j,Me.Fragment=l,Me.Profiler=s,Me.PureComponent=z,Me.StrictMode=i,Me.Suspense=p,Me.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=G,Me.__COMPILER_RUNTIME={__proto__:null,c:function(T){return G.H.useMemoCache(T)}},Me.cache=function(T){return function(){return T.apply(null,arguments)}},Me.cacheSignal=function(){return null},Me.cloneElement=function(T,U,E){if(T==null)throw Error("The argument must be a React element, but you passed "+T+".");var O=N({},T.props),ee=T.key;if(U!=null)for(re in U.key!==void 0&&(ee=""+U.key),U)!ae.call(U,re)||re==="key"||re==="__self"||re==="__source"||re==="ref"&&U.ref===void 0||(O[re]=U[re]);var re=arguments.length-2;if(re===1)O.children=E;else if(1<re){for(var W=Array(re),be=0;be<re;be++)W[be]=arguments[be+2];O.children=W}return se(T.type,ee,O)},Me.createContext=function(T){return T={$$typeof:c,_currentValue:T,_currentValue2:T,_threadCount:0,Provider:null,Consumer:null},T.Provider=T,T.Consumer={$$typeof:u,_context:T},T},Me.createElement=function(T,U,E){var O,ee={},re=null;if(U!=null)for(O in U.key!==void 0&&(re=""+U.key),U)ae.call(U,O)&&O!=="key"&&O!=="__self"&&O!=="__source"&&(ee[O]=U[O]);var W=arguments.length-2;if(W===1)ee.children=E;else if(1<W){for(var be=Array(W),we=0;we<W;we++)be[we]=arguments[we+2];ee.children=be}if(T&&T.defaultProps)for(O in W=T.defaultProps,W)ee[O]===void 0&&(ee[O]=W[O]);return se(T,re,ee)},Me.createRef=function(){return{current:null}},Me.forwardRef=function(T){return{$$typeof:d,render:T}},Me.isValidElement=P,Me.lazy=function(T){return{$$typeof:x,_payload:{_status:-1,_result:T},_init:oe}},Me.memo=function(T,U){return{$$typeof:m,type:T,compare:U===void 0?null:U}},Me.startTransition=function(T){var U=G.T,E={};G.T=E;try{var O=T(),ee=G.S;ee!==null&&ee(E,O),typeof O=="object"&&O!==null&&typeof O.then=="function"&&O.then(B,ye)}catch(re){ye(re)}finally{U!==null&&E.types!==null&&(U.types=E.types),G.T=U}},Me.unstable_useCacheRefresh=function(){return G.H.useCacheRefresh()},Me.use=function(T){return G.H.use(T)},Me.useActionState=function(T,U,E){return G.H.useActionState(T,U,E)},Me.useCallback=function(T,U){return G.H.useCallback(T,U)},Me.useContext=function(T){return G.H.useContext(T)},Me.useDebugValue=function(){},Me.useDeferredValue=function(T,U){return G.H.useDeferredValue(T,U)},Me.useEffect=function(T,U){return G.H.useEffect(T,U)},Me.useEffectEvent=function(T){return G.H.useEffectEvent(T)},Me.useId=function(){return G.H.useId()},Me.useImperativeHandle=function(T,U,E){return G.H.useImperativeHandle(T,U,E)},Me.useInsertionEffect=function(T,U){return G.H.useInsertionEffect(T,U)},Me.useLayoutEffect=function(T,U){return G.H.useLayoutEffect(T,U)},Me.useMemo=function(T,U){return G.H.useMemo(T,U)},Me.useOptimistic=function(T,U){return G.H.useOptimistic(T,U)},Me.useReducer=function(T,U,E){return G.H.useReducer(T,U,E)},Me.useRef=function(T){return G.H.useRef(T)},Me.useState=function(T){return G.H.useState(T)},Me.useSyncExternalStore=function(T,U,E){return G.H.useSyncExternalStore(T,U,E)},Me.useTransition=function(){return G.H.useTransition()},Me.version="19.2.6",Me}var Xg;function id(){return Xg||(Xg=1,Jc.exports=qS()),Jc.exports}var w=id();const dn=Ri(w),od=US({__proto__:null,default:dn},[w]);var Wc={exports:{}},pi={},ef={exports:{}},tf={};/**
|
|
18
|
-
* @license React
|
|
19
|
-
* scheduler.production.js
|
|
20
|
-
*
|
|
21
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
22
|
-
*
|
|
23
|
-
* This source code is licensed under the MIT license found in the
|
|
24
|
-
* LICENSE file in the root directory of this source tree.
|
|
25
|
-
*/var Qg;function IS(){return Qg||(Qg=1,(function(t){function r(H,ne){var oe=H.length;H.push(ne);e:for(;0<oe;){var ye=oe-1>>>1,D=H[ye];if(0<s(D,ne))H[ye]=ne,H[oe]=D,oe=ye;else break e}}function l(H){return H.length===0?null:H[0]}function i(H){if(H.length===0)return null;var ne=H[0],oe=H.pop();if(oe!==ne){H[0]=oe;e:for(var ye=0,D=H.length,T=D>>>1;ye<T;){var U=2*(ye+1)-1,E=H[U],O=U+1,ee=H[O];if(0>s(E,oe))O<D&&0>s(ee,E)?(H[ye]=ee,H[O]=oe,ye=O):(H[ye]=E,H[U]=oe,ye=U);else if(O<D&&0>s(ee,oe))H[ye]=ee,H[O]=oe,ye=O;else break e}}return ne}function s(H,ne){var oe=H.sortIndex-ne.sortIndex;return oe!==0?oe:H.id-ne.id}if(t.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var u=performance;t.unstable_now=function(){return u.now()}}else{var c=Date,d=c.now();t.unstable_now=function(){return c.now()-d}}var p=[],m=[],x=1,y=null,b=3,S=!1,k=!1,N=!1,A=!1,j=typeof setTimeout=="function"?setTimeout:null,M=typeof clearTimeout=="function"?clearTimeout:null,z=typeof setImmediate<"u"?setImmediate:null;function V(H){for(var ne=l(m);ne!==null;){if(ne.callback===null)i(m);else if(ne.startTime<=H)i(m),ne.sortIndex=ne.expirationTime,r(p,ne);else break;ne=l(m)}}function Q(H){if(N=!1,V(H),!k)if(l(p)!==null)k=!0,B||(B=!0,X());else{var ne=l(m);ne!==null&&J(Q,ne.startTime-H)}}var B=!1,G=-1,ae=5,se=-1;function L(){return A?!0:!(t.unstable_now()-se<ae)}function P(){if(A=!1,B){var H=t.unstable_now();se=H;var ne=!0;try{e:{k=!1,N&&(N=!1,M(G),G=-1),S=!0;var oe=b;try{t:{for(V(H),y=l(p);y!==null&&!(y.expirationTime>H&&L());){var ye=y.callback;if(typeof ye=="function"){y.callback=null,b=y.priorityLevel;var D=ye(y.expirationTime<=H);if(H=t.unstable_now(),typeof D=="function"){y.callback=D,V(H),ne=!0;break t}y===l(p)&&i(p),V(H)}else i(p);y=l(p)}if(y!==null)ne=!0;else{var T=l(m);T!==null&&J(Q,T.startTime-H),ne=!1}}break e}finally{y=null,b=oe,S=!1}ne=void 0}}finally{ne?X():B=!1}}}var X;if(typeof z=="function")X=function(){z(P)};else if(typeof MessageChannel<"u"){var de=new MessageChannel,I=de.port2;de.port1.onmessage=P,X=function(){I.postMessage(null)}}else X=function(){j(P,0)};function J(H,ne){G=j(function(){H(t.unstable_now())},ne)}t.unstable_IdlePriority=5,t.unstable_ImmediatePriority=1,t.unstable_LowPriority=4,t.unstable_NormalPriority=3,t.unstable_Profiling=null,t.unstable_UserBlockingPriority=2,t.unstable_cancelCallback=function(H){H.callback=null},t.unstable_forceFrameRate=function(H){0>H||125<H?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):ae=0<H?Math.floor(1e3/H):5},t.unstable_getCurrentPriorityLevel=function(){return b},t.unstable_next=function(H){switch(b){case 1:case 2:case 3:var ne=3;break;default:ne=b}var oe=b;b=ne;try{return H()}finally{b=oe}},t.unstable_requestPaint=function(){A=!0},t.unstable_runWithPriority=function(H,ne){switch(H){case 1:case 2:case 3:case 4:case 5:break;default:H=3}var oe=b;b=H;try{return ne()}finally{b=oe}},t.unstable_scheduleCallback=function(H,ne,oe){var ye=t.unstable_now();switch(typeof oe=="object"&&oe!==null?(oe=oe.delay,oe=typeof oe=="number"&&0<oe?ye+oe:ye):oe=ye,H){case 1:var D=-1;break;case 2:D=250;break;case 5:D=1073741823;break;case 4:D=1e4;break;default:D=5e3}return D=oe+D,H={id:x++,callback:ne,priorityLevel:H,startTime:oe,expirationTime:D,sortIndex:-1},oe>ye?(H.sortIndex=oe,r(m,H),l(p)===null&&H===l(m)&&(N?(M(G),G=-1):N=!0,J(Q,oe-ye))):(H.sortIndex=D,r(p,H),k||S||(k=!0,B||(B=!0,X()))),H},t.unstable_shouldYield=L,t.unstable_wrapCallback=function(H){var ne=b;return function(){var oe=b;b=ne;try{return H.apply(this,arguments)}finally{b=oe}}}})(tf)),tf}var Kg;function VS(){return Kg||(Kg=1,ef.exports=IS()),ef.exports}var nf={exports:{}},Ht={};/**
|
|
26
|
-
* @license React
|
|
27
|
-
* react-dom.production.js
|
|
28
|
-
*
|
|
29
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
30
|
-
*
|
|
31
|
-
* This source code is licensed under the MIT license found in the
|
|
32
|
-
* LICENSE file in the root directory of this source tree.
|
|
33
|
-
*/var Zg;function $S(){if(Zg)return Ht;Zg=1;var t=id();function r(p){var m="https://react.dev/errors/"+p;if(1<arguments.length){m+="?args[]="+encodeURIComponent(arguments[1]);for(var x=2;x<arguments.length;x++)m+="&args[]="+encodeURIComponent(arguments[x])}return"Minified React error #"+p+"; visit "+m+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function l(){}var i={d:{f:l,r:function(){throw Error(r(522))},D:l,C:l,L:l,m:l,X:l,S:l,M:l},p:0,findDOMNode:null},s=Symbol.for("react.portal");function u(p,m,x){var y=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:s,key:y==null?null:""+y,children:p,containerInfo:m,implementation:x}}var c=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function d(p,m){if(p==="font")return"";if(typeof m=="string")return m==="use-credentials"?m:""}return Ht.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=i,Ht.createPortal=function(p,m){var x=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!m||m.nodeType!==1&&m.nodeType!==9&&m.nodeType!==11)throw Error(r(299));return u(p,m,null,x)},Ht.flushSync=function(p){var m=c.T,x=i.p;try{if(c.T=null,i.p=2,p)return p()}finally{c.T=m,i.p=x,i.d.f()}},Ht.preconnect=function(p,m){typeof p=="string"&&(m?(m=m.crossOrigin,m=typeof m=="string"?m==="use-credentials"?m:"":void 0):m=null,i.d.C(p,m))},Ht.prefetchDNS=function(p){typeof p=="string"&&i.d.D(p)},Ht.preinit=function(p,m){if(typeof p=="string"&&m&&typeof m.as=="string"){var x=m.as,y=d(x,m.crossOrigin),b=typeof m.integrity=="string"?m.integrity:void 0,S=typeof m.fetchPriority=="string"?m.fetchPriority:void 0;x==="style"?i.d.S(p,typeof m.precedence=="string"?m.precedence:void 0,{crossOrigin:y,integrity:b,fetchPriority:S}):x==="script"&&i.d.X(p,{crossOrigin:y,integrity:b,fetchPriority:S,nonce:typeof m.nonce=="string"?m.nonce:void 0})}},Ht.preinitModule=function(p,m){if(typeof p=="string")if(typeof m=="object"&&m!==null){if(m.as==null||m.as==="script"){var x=d(m.as,m.crossOrigin);i.d.M(p,{crossOrigin:x,integrity:typeof m.integrity=="string"?m.integrity:void 0,nonce:typeof m.nonce=="string"?m.nonce:void 0})}}else m==null&&i.d.M(p)},Ht.preload=function(p,m){if(typeof p=="string"&&typeof m=="object"&&m!==null&&typeof m.as=="string"){var x=m.as,y=d(x,m.crossOrigin);i.d.L(p,x,{crossOrigin:y,integrity:typeof m.integrity=="string"?m.integrity:void 0,nonce:typeof m.nonce=="string"?m.nonce:void 0,type:typeof m.type=="string"?m.type:void 0,fetchPriority:typeof m.fetchPriority=="string"?m.fetchPriority:void 0,referrerPolicy:typeof m.referrerPolicy=="string"?m.referrerPolicy:void 0,imageSrcSet:typeof m.imageSrcSet=="string"?m.imageSrcSet:void 0,imageSizes:typeof m.imageSizes=="string"?m.imageSizes:void 0,media:typeof m.media=="string"?m.media:void 0})}},Ht.preloadModule=function(p,m){if(typeof p=="string")if(m){var x=d(m.as,m.crossOrigin);i.d.m(p,{as:typeof m.as=="string"&&m.as!=="script"?m.as:void 0,crossOrigin:x,integrity:typeof m.integrity=="string"?m.integrity:void 0})}else i.d.m(p)},Ht.requestFormReset=function(p){i.d.r(p)},Ht.unstable_batchedUpdates=function(p,m){return p(m)},Ht.useFormState=function(p,m,x){return c.H.useFormState(p,m,x)},Ht.useFormStatus=function(){return c.H.useHostTransitionStatus()},Ht.version="19.2.6",Ht}var Jg;function vx(){if(Jg)return nf.exports;Jg=1;function t(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(t)}catch(r){console.error(r)}}return t(),nf.exports=$S(),nf.exports}/**
|
|
34
|
-
* @license React
|
|
35
|
-
* react-dom-client.production.js
|
|
36
|
-
*
|
|
37
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
38
|
-
*
|
|
39
|
-
* This source code is licensed under the MIT license found in the
|
|
40
|
-
* LICENSE file in the root directory of this source tree.
|
|
41
|
-
*/var Wg;function FS(){if(Wg)return pi;Wg=1;var t=VS(),r=id(),l=vx();function i(e){var n="https://react.dev/errors/"+e;if(1<arguments.length){n+="?args[]="+encodeURIComponent(arguments[1]);for(var a=2;a<arguments.length;a++)n+="&args[]="+encodeURIComponent(arguments[a])}return"Minified React error #"+e+"; visit "+n+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function s(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function u(e){var n=e,a=e;if(e.alternate)for(;n.return;)n=n.return;else{e=n;do n=e,(n.flags&4098)!==0&&(a=n.return),e=n.return;while(e)}return n.tag===3?a:null}function c(e){if(e.tag===13){var n=e.memoizedState;if(n===null&&(e=e.alternate,e!==null&&(n=e.memoizedState)),n!==null)return n.dehydrated}return null}function d(e){if(e.tag===31){var n=e.memoizedState;if(n===null&&(e=e.alternate,e!==null&&(n=e.memoizedState)),n!==null)return n.dehydrated}return null}function p(e){if(u(e)!==e)throw Error(i(188))}function m(e){var n=e.alternate;if(!n){if(n=u(e),n===null)throw Error(i(188));return n!==e?null:e}for(var a=e,o=n;;){var f=a.return;if(f===null)break;var g=f.alternate;if(g===null){if(o=f.return,o!==null){a=o;continue}break}if(f.child===g.child){for(g=f.child;g;){if(g===a)return p(f),e;if(g===o)return p(f),n;g=g.sibling}throw Error(i(188))}if(a.return!==o.return)a=f,o=g;else{for(var v=!1,C=f.child;C;){if(C===a){v=!0,a=f,o=g;break}if(C===o){v=!0,o=f,a=g;break}C=C.sibling}if(!v){for(C=g.child;C;){if(C===a){v=!0,a=g,o=f;break}if(C===o){v=!0,o=g,a=f;break}C=C.sibling}if(!v)throw Error(i(189))}}if(a.alternate!==o)throw Error(i(190))}if(a.tag!==3)throw Error(i(188));return a.stateNode.current===a?e:n}function x(e){var n=e.tag;if(n===5||n===26||n===27||n===6)return e;for(e=e.child;e!==null;){if(n=x(e),n!==null)return n;e=e.sibling}return null}var y=Object.assign,b=Symbol.for("react.element"),S=Symbol.for("react.transitional.element"),k=Symbol.for("react.portal"),N=Symbol.for("react.fragment"),A=Symbol.for("react.strict_mode"),j=Symbol.for("react.profiler"),M=Symbol.for("react.consumer"),z=Symbol.for("react.context"),V=Symbol.for("react.forward_ref"),Q=Symbol.for("react.suspense"),B=Symbol.for("react.suspense_list"),G=Symbol.for("react.memo"),ae=Symbol.for("react.lazy"),se=Symbol.for("react.activity"),L=Symbol.for("react.memo_cache_sentinel"),P=Symbol.iterator;function X(e){return e===null||typeof e!="object"?null:(e=P&&e[P]||e["@@iterator"],typeof e=="function"?e:null)}var de=Symbol.for("react.client.reference");function I(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===de?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case N:return"Fragment";case j:return"Profiler";case A:return"StrictMode";case Q:return"Suspense";case B:return"SuspenseList";case se:return"Activity"}if(typeof e=="object")switch(e.$$typeof){case k:return"Portal";case z:return e.displayName||"Context";case M:return(e._context.displayName||"Context")+".Consumer";case V:var n=e.render;return e=e.displayName,e||(e=n.displayName||n.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case G:return n=e.displayName||null,n!==null?n:I(e.type)||"Memo";case ae:n=e._payload,e=e._init;try{return I(e(n))}catch{}}return null}var J=Array.isArray,H=r.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,ne=l.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,oe={pending:!1,data:null,method:null,action:null},ye=[],D=-1;function T(e){return{current:e}}function U(e){0>D||(e.current=ye[D],ye[D]=null,D--)}function E(e,n){D++,ye[D]=e.current,e.current=n}var O=T(null),ee=T(null),re=T(null),W=T(null);function be(e,n){switch(E(re,n),E(ee,e),E(O,null),n.nodeType){case 9:case 11:e=(e=n.documentElement)&&(e=e.namespaceURI)?mg(e):0;break;default:if(e=n.tagName,n=n.namespaceURI)n=mg(n),e=pg(n,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}U(O),E(O,e)}function we(){U(O),U(ee),U(re)}function Ae(e){e.memoizedState!==null&&E(W,e);var n=O.current,a=pg(n,e.type);n!==a&&(E(ee,e),E(O,a))}function dt(e){ee.current===e&&(U(O),U(ee)),W.current===e&&(U(W),ci._currentValue=oe)}var st,Te;function xe(e){if(st===void 0)try{throw Error()}catch(a){var n=a.stack.trim().match(/\n( *(at )?)/);st=n&&n[1]||"",Te=-1<a.stack.indexOf(`
|
|
42
|
-
at`)?" (<anonymous>)":-1<a.stack.indexOf("@")?"@unknown:0:0":""}return`
|
|
43
|
-
`+st+e+Te}var De=!1;function at(e,n){if(!e||De)return"";De=!0;var a=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var o={DetermineComponentFrameRoot:function(){try{if(n){var ie=function(){throw Error()};if(Object.defineProperty(ie.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(ie,[])}catch(Z){var Y=Z}Reflect.construct(e,[],ie)}else{try{ie.call()}catch(Z){Y=Z}e.call(ie.prototype)}}else{try{throw Error()}catch(Z){Y=Z}(ie=e())&&typeof ie.catch=="function"&&ie.catch(function(){})}}catch(Z){if(Z&&Y&&typeof Z.stack=="string")return[Z.stack,Y.stack]}return[null,null]}};o.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var f=Object.getOwnPropertyDescriptor(o.DetermineComponentFrameRoot,"name");f&&f.configurable&&Object.defineProperty(o.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var g=o.DetermineComponentFrameRoot(),v=g[0],C=g[1];if(v&&C){var R=v.split(`
|
|
44
|
-
`),F=C.split(`
|
|
45
|
-
`);for(f=o=0;o<R.length&&!R[o].includes("DetermineComponentFrameRoot");)o++;for(;f<F.length&&!F[f].includes("DetermineComponentFrameRoot");)f++;if(o===R.length||f===F.length)for(o=R.length-1,f=F.length-1;1<=o&&0<=f&&R[o]!==F[f];)f--;for(;1<=o&&0<=f;o--,f--)if(R[o]!==F[f]){if(o!==1||f!==1)do if(o--,f--,0>f||R[o]!==F[f]){var te=`
|
|
46
|
-
`+R[o].replace(" at new "," at ");return e.displayName&&te.includes("<anonymous>")&&(te=te.replace("<anonymous>",e.displayName)),te}while(1<=o&&0<=f);break}}}finally{De=!1,Error.prepareStackTrace=a}return(a=e?e.displayName||e.name:"")?xe(a):""}function ht(e,n){switch(e.tag){case 26:case 27:case 5:return xe(e.type);case 16:return xe("Lazy");case 13:return e.child!==n&&n!==null?xe("Suspense Fallback"):xe("Suspense");case 19:return xe("SuspenseList");case 0:case 15:return at(e.type,!1);case 11:return at(e.type.render,!1);case 1:return at(e.type,!0);case 31:return xe("Activity");default:return""}}function $t(e){try{var n="",a=null;do n+=ht(e,a),a=e,e=e.return;while(e);return n}catch(o){return`
|
|
47
|
-
Error generating stack: `+o.message+`
|
|
48
|
-
`+o.stack}}var mt=Object.prototype.hasOwnProperty,Ft=t.unstable_scheduleCallback,cr=t.unstable_cancelCallback,wa=t.unstable_shouldYield,xl=t.unstable_requestPaint,ue=t.unstable_now,je=t.unstable_getCurrentPriorityLevel,K=t.unstable_ImmediatePriority,fe=t.unstable_UserBlockingPriority,ke=t.unstable_NormalPriority,ze=t.unstable_LowPriority,Fe=t.unstable_IdlePriority,zt=t.log,vt=t.unstable_setDisableYieldValue,yt=null,it=null;function Mt(e){if(typeof zt=="function"&&vt(e),it&&typeof it.setStrictMode=="function")try{it.setStrictMode(yt,e)}catch{}}var Ze=Math.clz32?Math.clz32:Sb,fr=Math.log,jn=Math.LN2;function Sb(e){return e>>>=0,e===0?32:31-(fr(e)/jn|0)|0}var Hi=256,qi=262144,Ii=4194304;function Yr(e){var n=e&42;if(n!==0)return n;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function Vi(e,n,a){var o=e.pendingLanes;if(o===0)return 0;var f=0,g=e.suspendedLanes,v=e.pingedLanes;e=e.warmLanes;var C=o&134217727;return C!==0?(o=C&~g,o!==0?f=Yr(o):(v&=C,v!==0?f=Yr(v):a||(a=C&~e,a!==0&&(f=Yr(a))))):(C=o&~g,C!==0?f=Yr(C):v!==0?f=Yr(v):a||(a=o&~e,a!==0&&(f=Yr(a)))),f===0?0:n!==0&&n!==f&&(n&g)===0&&(g=f&-f,a=n&-n,g>=a||g===32&&(a&4194048)!==0)?n:f}function ka(e,n){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&n)===0}function wb(e,n){switch(e){case 1:case 2:case 4:case 8:case 64:return n+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 n+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 Qd(){var e=Ii;return Ii<<=1,(Ii&62914560)===0&&(Ii=4194304),e}function Hs(e){for(var n=[],a=0;31>a;a++)n.push(e);return n}function Ca(e,n){e.pendingLanes|=n,n!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function kb(e,n,a,o,f,g){var v=e.pendingLanes;e.pendingLanes=a,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=a,e.entangledLanes&=a,e.errorRecoveryDisabledLanes&=a,e.shellSuspendCounter=0;var C=e.entanglements,R=e.expirationTimes,F=e.hiddenUpdates;for(a=v&~a;0<a;){var te=31-Ze(a),ie=1<<te;C[te]=0,R[te]=-1;var Y=F[te];if(Y!==null)for(F[te]=null,te=0;te<Y.length;te++){var Z=Y[te];Z!==null&&(Z.lane&=-536870913)}a&=~ie}o!==0&&Kd(e,o,0),g!==0&&f===0&&e.tag!==0&&(e.suspendedLanes|=g&~(v&~n))}function Kd(e,n,a){e.pendingLanes|=n,e.suspendedLanes&=~n;var o=31-Ze(n);e.entangledLanes|=n,e.entanglements[o]=e.entanglements[o]|1073741824|a&261930}function Zd(e,n){var a=e.entangledLanes|=n;for(e=e.entanglements;a;){var o=31-Ze(a),f=1<<o;f&n|e[o]&n&&(e[o]|=n),a&=~f}}function Jd(e,n){var a=n&-n;return a=(a&42)!==0?1:qs(a),(a&(e.suspendedLanes|n))!==0?0:a}function qs(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function Is(e){return e&=-e,2<e?8<e?(e&134217727)!==0?32:268435456:8:2}function Wd(){var e=ne.p;return e!==0?e:(e=window.event,e===void 0?32:Bg(e.type))}function eh(e,n){var a=ne.p;try{return ne.p=e,n()}finally{ne.p=a}}var dr=Math.random().toString(36).slice(2),Ot="__reactFiber$"+dr,Pt="__reactProps$"+dr,bl="__reactContainer$"+dr,Vs="__reactEvents$"+dr,Cb="__reactListeners$"+dr,Nb="__reactHandles$"+dr,th="__reactResources$"+dr,Na="__reactMarker$"+dr;function $s(e){delete e[Ot],delete e[Pt],delete e[Vs],delete e[Cb],delete e[Nb]}function vl(e){var n=e[Ot];if(n)return n;for(var a=e.parentNode;a;){if(n=a[bl]||a[Ot]){if(a=n.alternate,n.child!==null||a!==null&&a.child!==null)for(e=wg(e);e!==null;){if(a=e[Ot])return a;e=wg(e)}return n}e=a,a=e.parentNode}return null}function Sl(e){if(e=e[Ot]||e[bl]){var n=e.tag;if(n===5||n===6||n===13||n===31||n===26||n===27||n===3)return e}return null}function Ea(e){var n=e.tag;if(n===5||n===26||n===27||n===6)return e.stateNode;throw Error(i(33))}function wl(e){var n=e[th];return n||(n=e[th]={hoistableStyles:new Map,hoistableScripts:new Map}),n}function Dt(e){e[Na]=!0}var nh=new Set,rh={};function Gr(e,n){kl(e,n),kl(e+"Capture",n)}function kl(e,n){for(rh[e]=n,e=0;e<n.length;e++)nh.add(n[e])}var Eb=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]*$"),lh={},ah={};function jb(e){return mt.call(ah,e)?!0:mt.call(lh,e)?!1:Eb.test(e)?ah[e]=!0:(lh[e]=!0,!1)}function $i(e,n,a){if(jb(n))if(a===null)e.removeAttribute(n);else{switch(typeof a){case"undefined":case"function":case"symbol":e.removeAttribute(n);return;case"boolean":var o=n.toLowerCase().slice(0,5);if(o!=="data-"&&o!=="aria-"){e.removeAttribute(n);return}}e.setAttribute(n,""+a)}}function Fi(e,n,a){if(a===null)e.removeAttribute(n);else{switch(typeof a){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(n);return}e.setAttribute(n,""+a)}}function $n(e,n,a,o){if(o===null)e.removeAttribute(a);else{switch(typeof o){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(a);return}e.setAttributeNS(n,a,""+o)}}function pn(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function ih(e){var n=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(n==="checkbox"||n==="radio")}function Tb(e,n,a){var o=Object.getOwnPropertyDescriptor(e.constructor.prototype,n);if(!e.hasOwnProperty(n)&&typeof o<"u"&&typeof o.get=="function"&&typeof o.set=="function"){var f=o.get,g=o.set;return Object.defineProperty(e,n,{configurable:!0,get:function(){return f.call(this)},set:function(v){a=""+v,g.call(this,v)}}),Object.defineProperty(e,n,{enumerable:o.enumerable}),{getValue:function(){return a},setValue:function(v){a=""+v},stopTracking:function(){e._valueTracker=null,delete e[n]}}}}function Fs(e){if(!e._valueTracker){var n=ih(e)?"checked":"value";e._valueTracker=Tb(e,n,""+e[n])}}function oh(e){if(!e)return!1;var n=e._valueTracker;if(!n)return!0;var a=n.getValue(),o="";return e&&(o=ih(e)?e.checked?"true":"false":e.value),e=o,e!==a?(n.setValue(e),!0):!1}function Yi(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}var Ab=/[\n"\\]/g;function gn(e){return e.replace(Ab,function(n){return"\\"+n.charCodeAt(0).toString(16)+" "})}function Ys(e,n,a,o,f,g,v,C){e.name="",v!=null&&typeof v!="function"&&typeof v!="symbol"&&typeof v!="boolean"?e.type=v:e.removeAttribute("type"),n!=null?v==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+pn(n)):e.value!==""+pn(n)&&(e.value=""+pn(n)):v!=="submit"&&v!=="reset"||e.removeAttribute("value"),n!=null?Gs(e,v,pn(n)):a!=null?Gs(e,v,pn(a)):o!=null&&e.removeAttribute("value"),f==null&&g!=null&&(e.defaultChecked=!!g),f!=null&&(e.checked=f&&typeof f!="function"&&typeof f!="symbol"),C!=null&&typeof C!="function"&&typeof C!="symbol"&&typeof C!="boolean"?e.name=""+pn(C):e.removeAttribute("name")}function sh(e,n,a,o,f,g,v,C){if(g!=null&&typeof g!="function"&&typeof g!="symbol"&&typeof g!="boolean"&&(e.type=g),n!=null||a!=null){if(!(g!=="submit"&&g!=="reset"||n!=null)){Fs(e);return}a=a!=null?""+pn(a):"",n=n!=null?""+pn(n):a,C||n===e.value||(e.value=n),e.defaultValue=n}o=o??f,o=typeof o!="function"&&typeof o!="symbol"&&!!o,e.checked=C?e.checked:!!o,e.defaultChecked=!!o,v!=null&&typeof v!="function"&&typeof v!="symbol"&&typeof v!="boolean"&&(e.name=v),Fs(e)}function Gs(e,n,a){n==="number"&&Yi(e.ownerDocument)===e||e.defaultValue===""+a||(e.defaultValue=""+a)}function Cl(e,n,a,o){if(e=e.options,n){n={};for(var f=0;f<a.length;f++)n["$"+a[f]]=!0;for(a=0;a<e.length;a++)f=n.hasOwnProperty("$"+e[a].value),e[a].selected!==f&&(e[a].selected=f),f&&o&&(e[a].defaultSelected=!0)}else{for(a=""+pn(a),n=null,f=0;f<e.length;f++){if(e[f].value===a){e[f].selected=!0,o&&(e[f].defaultSelected=!0);return}n!==null||e[f].disabled||(n=e[f])}n!==null&&(n.selected=!0)}}function uh(e,n,a){if(n!=null&&(n=""+pn(n),n!==e.value&&(e.value=n),a==null)){e.defaultValue!==n&&(e.defaultValue=n);return}e.defaultValue=a!=null?""+pn(a):""}function ch(e,n,a,o){if(n==null){if(o!=null){if(a!=null)throw Error(i(92));if(J(o)){if(1<o.length)throw Error(i(93));o=o[0]}a=o}a==null&&(a=""),n=a}a=pn(n),e.defaultValue=a,o=e.textContent,o===a&&o!==""&&o!==null&&(e.value=o),Fs(e)}function Nl(e,n){if(n){var a=e.firstChild;if(a&&a===e.lastChild&&a.nodeType===3){a.nodeValue=n;return}}e.textContent=n}var Mb=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 fh(e,n,a){var o=n.indexOf("--")===0;a==null||typeof a=="boolean"||a===""?o?e.setProperty(n,""):n==="float"?e.cssFloat="":e[n]="":o?e.setProperty(n,a):typeof a!="number"||a===0||Mb.has(n)?n==="float"?e.cssFloat=a:e[n]=(""+a).trim():e[n]=a+"px"}function dh(e,n,a){if(n!=null&&typeof n!="object")throw Error(i(62));if(e=e.style,a!=null){for(var o in a)!a.hasOwnProperty(o)||n!=null&&n.hasOwnProperty(o)||(o.indexOf("--")===0?e.setProperty(o,""):o==="float"?e.cssFloat="":e[o]="");for(var f in n)o=n[f],n.hasOwnProperty(f)&&a[f]!==o&&fh(e,f,o)}else for(var g in n)n.hasOwnProperty(g)&&fh(e,g,n[g])}function Ps(e){if(e.indexOf("-")===-1)return!1;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Db=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"]]),Rb=/^[\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 Gi(e){return Rb.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}function Fn(){}var Xs=null;function Qs(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var El=null,jl=null;function hh(e){var n=Sl(e);if(n&&(e=n.stateNode)){var a=e[Pt]||null;e:switch(e=n.stateNode,n.type){case"input":if(Ys(e,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name),n=a.name,a.type==="radio"&&n!=null){for(a=e;a.parentNode;)a=a.parentNode;for(a=a.querySelectorAll('input[name="'+gn(""+n)+'"][type="radio"]'),n=0;n<a.length;n++){var o=a[n];if(o!==e&&o.form===e.form){var f=o[Pt]||null;if(!f)throw Error(i(90));Ys(o,f.value,f.defaultValue,f.defaultValue,f.checked,f.defaultChecked,f.type,f.name)}}for(n=0;n<a.length;n++)o=a[n],o.form===e.form&&oh(o)}break e;case"textarea":uh(e,a.value,a.defaultValue);break e;case"select":n=a.value,n!=null&&Cl(e,!!a.multiple,n,!1)}}}var Ks=!1;function mh(e,n,a){if(Ks)return e(n,a);Ks=!0;try{var o=e(n);return o}finally{if(Ks=!1,(El!==null||jl!==null)&&(Oo(),El&&(n=El,e=jl,jl=El=null,hh(n),e)))for(n=0;n<e.length;n++)hh(e[n])}}function ja(e,n){var a=e.stateNode;if(a===null)return null;var o=a[Pt]||null;if(o===null)return null;a=o[n];e:switch(n){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(o=!o.disabled)||(e=e.type,o=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!o;break e;default:e=!1}if(e)return null;if(a&&typeof a!="function")throw Error(i(231,n,typeof a));return a}var Yn=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Zs=!1;if(Yn)try{var Ta={};Object.defineProperty(Ta,"passive",{get:function(){Zs=!0}}),window.addEventListener("test",Ta,Ta),window.removeEventListener("test",Ta,Ta)}catch{Zs=!1}var hr=null,Js=null,Pi=null;function ph(){if(Pi)return Pi;var e,n=Js,a=n.length,o,f="value"in hr?hr.value:hr.textContent,g=f.length;for(e=0;e<a&&n[e]===f[e];e++);var v=a-e;for(o=1;o<=v&&n[a-o]===f[g-o];o++);return Pi=f.slice(e,1<o?1-o:void 0)}function Xi(e){var n=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&n===13&&(e=13)):e=n,e===10&&(e=13),32<=e||e===13?e:0}function Qi(){return!0}function gh(){return!1}function Xt(e){function n(a,o,f,g,v){this._reactName=a,this._targetInst=f,this.type=o,this.nativeEvent=g,this.target=v,this.currentTarget=null;for(var C in e)e.hasOwnProperty(C)&&(a=e[C],this[C]=a?a(g):g[C]);return this.isDefaultPrevented=(g.defaultPrevented!=null?g.defaultPrevented:g.returnValue===!1)?Qi:gh,this.isPropagationStopped=gh,this}return y(n.prototype,{preventDefault:function(){this.defaultPrevented=!0;var a=this.nativeEvent;a&&(a.preventDefault?a.preventDefault():typeof a.returnValue!="unknown"&&(a.returnValue=!1),this.isDefaultPrevented=Qi)},stopPropagation:function(){var a=this.nativeEvent;a&&(a.stopPropagation?a.stopPropagation():typeof a.cancelBubble!="unknown"&&(a.cancelBubble=!0),this.isPropagationStopped=Qi)},persist:function(){},isPersistent:Qi}),n}var Pr={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Ki=Xt(Pr),Aa=y({},Pr,{view:0,detail:0}),zb=Xt(Aa),Ws,eu,Ma,Zi=y({},Aa,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:nu,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==Ma&&(Ma&&e.type==="mousemove"?(Ws=e.screenX-Ma.screenX,eu=e.screenY-Ma.screenY):eu=Ws=0,Ma=e),Ws)},movementY:function(e){return"movementY"in e?e.movementY:eu}}),yh=Xt(Zi),Ob=y({},Zi,{dataTransfer:0}),_b=Xt(Ob),Lb=y({},Aa,{relatedTarget:0}),tu=Xt(Lb),Ub=y({},Pr,{animationName:0,elapsedTime:0,pseudoElement:0}),Bb=Xt(Ub),Hb=y({},Pr,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),qb=Xt(Hb),Ib=y({},Pr,{data:0}),xh=Xt(Ib),Vb={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},$b={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"},Fb={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Yb(e){var n=this.nativeEvent;return n.getModifierState?n.getModifierState(e):(e=Fb[e])?!!n[e]:!1}function nu(){return Yb}var Gb=y({},Aa,{key:function(e){if(e.key){var n=Vb[e.key]||e.key;if(n!=="Unidentified")return n}return e.type==="keypress"?(e=Xi(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?$b[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:nu,charCode:function(e){return e.type==="keypress"?Xi(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Xi(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),Pb=Xt(Gb),Xb=y({},Zi,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),bh=Xt(Xb),Qb=y({},Aa,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:nu}),Kb=Xt(Qb),Zb=y({},Pr,{propertyName:0,elapsedTime:0,pseudoElement:0}),Jb=Xt(Zb),Wb=y({},Zi,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),ev=Xt(Wb),tv=y({},Pr,{newState:0,oldState:0}),nv=Xt(tv),rv=[9,13,27,32],ru=Yn&&"CompositionEvent"in window,Da=null;Yn&&"documentMode"in document&&(Da=document.documentMode);var lv=Yn&&"TextEvent"in window&&!Da,vh=Yn&&(!ru||Da&&8<Da&&11>=Da),Sh=" ",wh=!1;function kh(e,n){switch(e){case"keyup":return rv.indexOf(n.keyCode)!==-1;case"keydown":return n.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Ch(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Tl=!1;function av(e,n){switch(e){case"compositionend":return Ch(n);case"keypress":return n.which!==32?null:(wh=!0,Sh);case"textInput":return e=n.data,e===Sh&&wh?null:e;default:return null}}function iv(e,n){if(Tl)return e==="compositionend"||!ru&&kh(e,n)?(e=ph(),Pi=Js=hr=null,Tl=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(n.ctrlKey||n.altKey||n.metaKey)||n.ctrlKey&&n.altKey){if(n.char&&1<n.char.length)return n.char;if(n.which)return String.fromCharCode(n.which)}return null;case"compositionend":return vh&&n.locale!=="ko"?null:n.data;default:return null}}var ov={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 Nh(e){var n=e&&e.nodeName&&e.nodeName.toLowerCase();return n==="input"?!!ov[e.type]:n==="textarea"}function Eh(e,n,a,o){El?jl?jl.push(o):jl=[o]:El=o,n=Io(n,"onChange"),0<n.length&&(a=new Ki("onChange","change",null,a,o),e.push({event:a,listeners:n}))}var Ra=null,za=null;function sv(e){sg(e,0)}function Ji(e){var n=Ea(e);if(oh(n))return e}function jh(e,n){if(e==="change")return n}var Th=!1;if(Yn){var lu;if(Yn){var au="oninput"in document;if(!au){var Ah=document.createElement("div");Ah.setAttribute("oninput","return;"),au=typeof Ah.oninput=="function"}lu=au}else lu=!1;Th=lu&&(!document.documentMode||9<document.documentMode)}function Mh(){Ra&&(Ra.detachEvent("onpropertychange",Dh),za=Ra=null)}function Dh(e){if(e.propertyName==="value"&&Ji(za)){var n=[];Eh(n,za,e,Qs(e)),mh(sv,n)}}function uv(e,n,a){e==="focusin"?(Mh(),Ra=n,za=a,Ra.attachEvent("onpropertychange",Dh)):e==="focusout"&&Mh()}function cv(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Ji(za)}function fv(e,n){if(e==="click")return Ji(n)}function dv(e,n){if(e==="input"||e==="change")return Ji(n)}function hv(e,n){return e===n&&(e!==0||1/e===1/n)||e!==e&&n!==n}var rn=typeof Object.is=="function"?Object.is:hv;function Oa(e,n){if(rn(e,n))return!0;if(typeof e!="object"||e===null||typeof n!="object"||n===null)return!1;var a=Object.keys(e),o=Object.keys(n);if(a.length!==o.length)return!1;for(o=0;o<a.length;o++){var f=a[o];if(!mt.call(n,f)||!rn(e[f],n[f]))return!1}return!0}function Rh(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function zh(e,n){var a=Rh(e);e=0;for(var o;a;){if(a.nodeType===3){if(o=e+a.textContent.length,e<=n&&o>=n)return{node:a,offset:n-e};e=o}e:{for(;a;){if(a.nextSibling){a=a.nextSibling;break e}a=a.parentNode}a=void 0}a=Rh(a)}}function Oh(e,n){return e&&n?e===n?!0:e&&e.nodeType===3?!1:n&&n.nodeType===3?Oh(e,n.parentNode):"contains"in e?e.contains(n):e.compareDocumentPosition?!!(e.compareDocumentPosition(n)&16):!1:!1}function _h(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var n=Yi(e.document);n instanceof e.HTMLIFrameElement;){try{var a=typeof n.contentWindow.location.href=="string"}catch{a=!1}if(a)e=n.contentWindow;else break;n=Yi(e.document)}return n}function iu(e){var n=e&&e.nodeName&&e.nodeName.toLowerCase();return n&&(n==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||n==="textarea"||e.contentEditable==="true")}var mv=Yn&&"documentMode"in document&&11>=document.documentMode,Al=null,ou=null,_a=null,su=!1;function Lh(e,n,a){var o=a.window===a?a.document:a.nodeType===9?a:a.ownerDocument;su||Al==null||Al!==Yi(o)||(o=Al,"selectionStart"in o&&iu(o)?o={start:o.selectionStart,end:o.selectionEnd}:(o=(o.ownerDocument&&o.ownerDocument.defaultView||window).getSelection(),o={anchorNode:o.anchorNode,anchorOffset:o.anchorOffset,focusNode:o.focusNode,focusOffset:o.focusOffset}),_a&&Oa(_a,o)||(_a=o,o=Io(ou,"onSelect"),0<o.length&&(n=new Ki("onSelect","select",null,n,a),e.push({event:n,listeners:o}),n.target=Al)))}function Xr(e,n){var a={};return a[e.toLowerCase()]=n.toLowerCase(),a["Webkit"+e]="webkit"+n,a["Moz"+e]="moz"+n,a}var Ml={animationend:Xr("Animation","AnimationEnd"),animationiteration:Xr("Animation","AnimationIteration"),animationstart:Xr("Animation","AnimationStart"),transitionrun:Xr("Transition","TransitionRun"),transitionstart:Xr("Transition","TransitionStart"),transitioncancel:Xr("Transition","TransitionCancel"),transitionend:Xr("Transition","TransitionEnd")},uu={},Uh={};Yn&&(Uh=document.createElement("div").style,"AnimationEvent"in window||(delete Ml.animationend.animation,delete Ml.animationiteration.animation,delete Ml.animationstart.animation),"TransitionEvent"in window||delete Ml.transitionend.transition);function Qr(e){if(uu[e])return uu[e];if(!Ml[e])return e;var n=Ml[e],a;for(a in n)if(n.hasOwnProperty(a)&&a in Uh)return uu[e]=n[a];return e}var Bh=Qr("animationend"),Hh=Qr("animationiteration"),qh=Qr("animationstart"),pv=Qr("transitionrun"),gv=Qr("transitionstart"),yv=Qr("transitioncancel"),Ih=Qr("transitionend"),Vh=new Map,cu="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(" ");cu.push("scrollEnd");function Tn(e,n){Vh.set(e,n),Gr(n,[e])}var Wi=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var n=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(n))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)},yn=[],Dl=0,fu=0;function eo(){for(var e=Dl,n=fu=Dl=0;n<e;){var a=yn[n];yn[n++]=null;var o=yn[n];yn[n++]=null;var f=yn[n];yn[n++]=null;var g=yn[n];if(yn[n++]=null,o!==null&&f!==null){var v=o.pending;v===null?f.next=f:(f.next=v.next,v.next=f),o.pending=f}g!==0&&$h(a,f,g)}}function to(e,n,a,o){yn[Dl++]=e,yn[Dl++]=n,yn[Dl++]=a,yn[Dl++]=o,fu|=o,e.lanes|=o,e=e.alternate,e!==null&&(e.lanes|=o)}function du(e,n,a,o){return to(e,n,a,o),no(e)}function Kr(e,n){return to(e,null,null,n),no(e)}function $h(e,n,a){e.lanes|=a;var o=e.alternate;o!==null&&(o.lanes|=a);for(var f=!1,g=e.return;g!==null;)g.childLanes|=a,o=g.alternate,o!==null&&(o.childLanes|=a),g.tag===22&&(e=g.stateNode,e===null||e._visibility&1||(f=!0)),e=g,g=g.return;return e.tag===3?(g=e.stateNode,f&&n!==null&&(f=31-Ze(a),e=g.hiddenUpdates,o=e[f],o===null?e[f]=[n]:o.push(n),n.lane=a|536870912),g):null}function no(e){if(50<ri)throw ri=0,Sc=null,Error(i(185));for(var n=e.return;n!==null;)e=n,n=e.return;return e.tag===3?e.stateNode:null}var Rl={};function xv(e,n,a,o){this.tag=e,this.key=a,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=n,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=o,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function ln(e,n,a,o){return new xv(e,n,a,o)}function hu(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Gn(e,n){var a=e.alternate;return a===null?(a=ln(e.tag,n,e.key,e.mode),a.elementType=e.elementType,a.type=e.type,a.stateNode=e.stateNode,a.alternate=e,e.alternate=a):(a.pendingProps=n,a.type=e.type,a.flags=0,a.subtreeFlags=0,a.deletions=null),a.flags=e.flags&65011712,a.childLanes=e.childLanes,a.lanes=e.lanes,a.child=e.child,a.memoizedProps=e.memoizedProps,a.memoizedState=e.memoizedState,a.updateQueue=e.updateQueue,n=e.dependencies,a.dependencies=n===null?null:{lanes:n.lanes,firstContext:n.firstContext},a.sibling=e.sibling,a.index=e.index,a.ref=e.ref,a.refCleanup=e.refCleanup,a}function Fh(e,n){e.flags&=65011714;var a=e.alternate;return a===null?(e.childLanes=0,e.lanes=n,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=a.childLanes,e.lanes=a.lanes,e.child=a.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=a.memoizedProps,e.memoizedState=a.memoizedState,e.updateQueue=a.updateQueue,e.type=a.type,n=a.dependencies,e.dependencies=n===null?null:{lanes:n.lanes,firstContext:n.firstContext}),e}function ro(e,n,a,o,f,g){var v=0;if(o=e,typeof e=="function")hu(e)&&(v=1);else if(typeof e=="string")v=kS(e,a,O.current)?26:e==="html"||e==="head"||e==="body"?27:5;else e:switch(e){case se:return e=ln(31,a,n,f),e.elementType=se,e.lanes=g,e;case N:return Zr(a.children,f,g,n);case A:v=8,f|=24;break;case j:return e=ln(12,a,n,f|2),e.elementType=j,e.lanes=g,e;case Q:return e=ln(13,a,n,f),e.elementType=Q,e.lanes=g,e;case B:return e=ln(19,a,n,f),e.elementType=B,e.lanes=g,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case z:v=10;break e;case M:v=9;break e;case V:v=11;break e;case G:v=14;break e;case ae:v=16,o=null;break e}v=29,a=Error(i(130,e===null?"null":typeof e,"")),o=null}return n=ln(v,a,n,f),n.elementType=e,n.type=o,n.lanes=g,n}function Zr(e,n,a,o){return e=ln(7,e,o,n),e.lanes=a,e}function mu(e,n,a){return e=ln(6,e,null,n),e.lanes=a,e}function Yh(e){var n=ln(18,null,null,0);return n.stateNode=e,n}function pu(e,n,a){return n=ln(4,e.children!==null?e.children:[],e.key,n),n.lanes=a,n.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},n}var Gh=new WeakMap;function xn(e,n){if(typeof e=="object"&&e!==null){var a=Gh.get(e);return a!==void 0?a:(n={value:e,source:n,stack:$t(n)},Gh.set(e,n),n)}return{value:e,source:n,stack:$t(n)}}var zl=[],Ol=0,lo=null,La=0,bn=[],vn=0,mr=null,zn=1,On="";function Pn(e,n){zl[Ol++]=La,zl[Ol++]=lo,lo=e,La=n}function Ph(e,n,a){bn[vn++]=zn,bn[vn++]=On,bn[vn++]=mr,mr=e;var o=zn;e=On;var f=32-Ze(o)-1;o&=~(1<<f),a+=1;var g=32-Ze(n)+f;if(30<g){var v=f-f%5;g=(o&(1<<v)-1).toString(32),o>>=v,f-=v,zn=1<<32-Ze(n)+f|a<<f|o,On=g+e}else zn=1<<g|a<<f|o,On=e}function gu(e){e.return!==null&&(Pn(e,1),Ph(e,1,0))}function yu(e){for(;e===lo;)lo=zl[--Ol],zl[Ol]=null,La=zl[--Ol],zl[Ol]=null;for(;e===mr;)mr=bn[--vn],bn[vn]=null,On=bn[--vn],bn[vn]=null,zn=bn[--vn],bn[vn]=null}function Xh(e,n){bn[vn++]=zn,bn[vn++]=On,bn[vn++]=mr,zn=n.id,On=n.overflow,mr=e}var _t=null,ut=null,$e=!1,pr=null,Sn=!1,xu=Error(i(519));function gr(e){var n=Error(i(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw Ua(xn(n,e)),xu}function Qh(e){var n=e.stateNode,a=e.type,o=e.memoizedProps;switch(n[Ot]=e,n[Pt]=o,a){case"dialog":Be("cancel",n),Be("close",n);break;case"iframe":case"object":case"embed":Be("load",n);break;case"video":case"audio":for(a=0;a<ai.length;a++)Be(ai[a],n);break;case"source":Be("error",n);break;case"img":case"image":case"link":Be("error",n),Be("load",n);break;case"details":Be("toggle",n);break;case"input":Be("invalid",n),sh(n,o.value,o.defaultValue,o.checked,o.defaultChecked,o.type,o.name,!0);break;case"select":Be("invalid",n);break;case"textarea":Be("invalid",n),ch(n,o.value,o.defaultValue,o.children)}a=o.children,typeof a!="string"&&typeof a!="number"&&typeof a!="bigint"||n.textContent===""+a||o.suppressHydrationWarning===!0||dg(n.textContent,a)?(o.popover!=null&&(Be("beforetoggle",n),Be("toggle",n)),o.onScroll!=null&&Be("scroll",n),o.onScrollEnd!=null&&Be("scrollend",n),o.onClick!=null&&(n.onclick=Fn),n=!0):n=!1,n||gr(e,!0)}function Kh(e){for(_t=e.return;_t;)switch(_t.tag){case 5:case 31:case 13:Sn=!1;return;case 27:case 3:Sn=!0;return;default:_t=_t.return}}function _l(e){if(e!==_t)return!1;if(!$e)return Kh(e),$e=!0,!1;var n=e.tag,a;if((a=n!==3&&n!==27)&&((a=n===5)&&(a=e.type,a=!(a!=="form"&&a!=="button")||Lc(e.type,e.memoizedProps)),a=!a),a&&ut&&gr(e),Kh(e),n===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(i(317));ut=Sg(e)}else if(n===31){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(i(317));ut=Sg(e)}else n===27?(n=ut,Mr(e.type)?(e=Ic,Ic=null,ut=e):ut=n):ut=_t?kn(e.stateNode.nextSibling):null;return!0}function Jr(){ut=_t=null,$e=!1}function bu(){var e=pr;return e!==null&&(Jt===null?Jt=e:Jt.push.apply(Jt,e),pr=null),e}function Ua(e){pr===null?pr=[e]:pr.push(e)}var vu=T(null),Wr=null,Xn=null;function yr(e,n,a){E(vu,n._currentValue),n._currentValue=a}function Qn(e){e._currentValue=vu.current,U(vu)}function Su(e,n,a){for(;e!==null;){var o=e.alternate;if((e.childLanes&n)!==n?(e.childLanes|=n,o!==null&&(o.childLanes|=n)):o!==null&&(o.childLanes&n)!==n&&(o.childLanes|=n),e===a)break;e=e.return}}function wu(e,n,a,o){var f=e.child;for(f!==null&&(f.return=e);f!==null;){var g=f.dependencies;if(g!==null){var v=f.child;g=g.firstContext;e:for(;g!==null;){var C=g;g=f;for(var R=0;R<n.length;R++)if(C.context===n[R]){g.lanes|=a,C=g.alternate,C!==null&&(C.lanes|=a),Su(g.return,a,e),o||(v=null);break e}g=C.next}}else if(f.tag===18){if(v=f.return,v===null)throw Error(i(341));v.lanes|=a,g=v.alternate,g!==null&&(g.lanes|=a),Su(v,a,e),v=null}else v=f.child;if(v!==null)v.return=f;else for(v=f;v!==null;){if(v===e){v=null;break}if(f=v.sibling,f!==null){f.return=v.return,v=f;break}v=v.return}f=v}}function Ll(e,n,a,o){e=null;for(var f=n,g=!1;f!==null;){if(!g){if((f.flags&524288)!==0)g=!0;else if((f.flags&262144)!==0)break}if(f.tag===10){var v=f.alternate;if(v===null)throw Error(i(387));if(v=v.memoizedProps,v!==null){var C=f.type;rn(f.pendingProps.value,v.value)||(e!==null?e.push(C):e=[C])}}else if(f===W.current){if(v=f.alternate,v===null)throw Error(i(387));v.memoizedState.memoizedState!==f.memoizedState.memoizedState&&(e!==null?e.push(ci):e=[ci])}f=f.return}e!==null&&wu(n,e,a,o),n.flags|=262144}function ao(e){for(e=e.firstContext;e!==null;){if(!rn(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function el(e){Wr=e,Xn=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function Lt(e){return Zh(Wr,e)}function io(e,n){return Wr===null&&el(e),Zh(e,n)}function Zh(e,n){var a=n._currentValue;if(n={context:n,memoizedValue:a,next:null},Xn===null){if(e===null)throw Error(i(308));Xn=n,e.dependencies={lanes:0,firstContext:n},e.flags|=524288}else Xn=Xn.next=n;return a}var bv=typeof AbortController<"u"?AbortController:function(){var e=[],n=this.signal={aborted:!1,addEventListener:function(a,o){e.push(o)}};this.abort=function(){n.aborted=!0,e.forEach(function(a){return a()})}},vv=t.unstable_scheduleCallback,Sv=t.unstable_NormalPriority,kt={$$typeof:z,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function ku(){return{controller:new bv,data:new Map,refCount:0}}function Ba(e){e.refCount--,e.refCount===0&&vv(Sv,function(){e.controller.abort()})}var Ha=null,Cu=0,Ul=0,Bl=null;function wv(e,n){if(Ha===null){var a=Ha=[];Cu=0,Ul=jc(),Bl={status:"pending",value:void 0,then:function(o){a.push(o)}}}return Cu++,n.then(Jh,Jh),n}function Jh(){if(--Cu===0&&Ha!==null){Bl!==null&&(Bl.status="fulfilled");var e=Ha;Ha=null,Ul=0,Bl=null;for(var n=0;n<e.length;n++)(0,e[n])()}}function kv(e,n){var a=[],o={status:"pending",value:null,reason:null,then:function(f){a.push(f)}};return e.then(function(){o.status="fulfilled",o.value=n;for(var f=0;f<a.length;f++)(0,a[f])(n)},function(f){for(o.status="rejected",o.reason=f,f=0;f<a.length;f++)(0,a[f])(void 0)}),o}var Wh=H.S;H.S=function(e,n){Lp=ue(),typeof n=="object"&&n!==null&&typeof n.then=="function"&&wv(e,n),Wh!==null&&Wh(e,n)};var tl=T(null);function Nu(){var e=tl.current;return e!==null?e:rt.pooledCache}function oo(e,n){n===null?E(tl,tl.current):E(tl,n.pool)}function em(){var e=Nu();return e===null?null:{parent:kt._currentValue,pool:e}}var Hl=Error(i(460)),Eu=Error(i(474)),so=Error(i(542)),uo={then:function(){}};function tm(e){return e=e.status,e==="fulfilled"||e==="rejected"}function nm(e,n,a){switch(a=e[a],a===void 0?e.push(n):a!==n&&(n.then(Fn,Fn),n=a),n.status){case"fulfilled":return n.value;case"rejected":throw e=n.reason,lm(e),e;default:if(typeof n.status=="string")n.then(Fn,Fn);else{if(e=rt,e!==null&&100<e.shellSuspendCounter)throw Error(i(482));e=n,e.status="pending",e.then(function(o){if(n.status==="pending"){var f=n;f.status="fulfilled",f.value=o}},function(o){if(n.status==="pending"){var f=n;f.status="rejected",f.reason=o}})}switch(n.status){case"fulfilled":return n.value;case"rejected":throw e=n.reason,lm(e),e}throw rl=n,Hl}}function nl(e){try{var n=e._init;return n(e._payload)}catch(a){throw a!==null&&typeof a=="object"&&typeof a.then=="function"?(rl=a,Hl):a}}var rl=null;function rm(){if(rl===null)throw Error(i(459));var e=rl;return rl=null,e}function lm(e){if(e===Hl||e===so)throw Error(i(483))}var ql=null,qa=0;function co(e){var n=qa;return qa+=1,ql===null&&(ql=[]),nm(ql,e,n)}function Ia(e,n){n=n.props.ref,e.ref=n!==void 0?n:null}function fo(e,n){throw n.$$typeof===b?Error(i(525)):(e=Object.prototype.toString.call(n),Error(i(31,e==="[object Object]"?"object with keys {"+Object.keys(n).join(", ")+"}":e)))}function am(e){function n(q,_){if(e){var $=q.deletions;$===null?(q.deletions=[_],q.flags|=16):$.push(_)}}function a(q,_){if(!e)return null;for(;_!==null;)n(q,_),_=_.sibling;return null}function o(q){for(var _=new Map;q!==null;)q.key!==null?_.set(q.key,q):_.set(q.index,q),q=q.sibling;return _}function f(q,_){return q=Gn(q,_),q.index=0,q.sibling=null,q}function g(q,_,$){return q.index=$,e?($=q.alternate,$!==null?($=$.index,$<_?(q.flags|=67108866,_):$):(q.flags|=67108866,_)):(q.flags|=1048576,_)}function v(q){return e&&q.alternate===null&&(q.flags|=67108866),q}function C(q,_,$,le){return _===null||_.tag!==6?(_=mu($,q.mode,le),_.return=q,_):(_=f(_,$),_.return=q,_)}function R(q,_,$,le){var Se=$.type;return Se===N?te(q,_,$.props.children,le,$.key):_!==null&&(_.elementType===Se||typeof Se=="object"&&Se!==null&&Se.$$typeof===ae&&nl(Se)===_.type)?(_=f(_,$.props),Ia(_,$),_.return=q,_):(_=ro($.type,$.key,$.props,null,q.mode,le),Ia(_,$),_.return=q,_)}function F(q,_,$,le){return _===null||_.tag!==4||_.stateNode.containerInfo!==$.containerInfo||_.stateNode.implementation!==$.implementation?(_=pu($,q.mode,le),_.return=q,_):(_=f(_,$.children||[]),_.return=q,_)}function te(q,_,$,le,Se){return _===null||_.tag!==7?(_=Zr($,q.mode,le,Se),_.return=q,_):(_=f(_,$),_.return=q,_)}function ie(q,_,$){if(typeof _=="string"&&_!==""||typeof _=="number"||typeof _=="bigint")return _=mu(""+_,q.mode,$),_.return=q,_;if(typeof _=="object"&&_!==null){switch(_.$$typeof){case S:return $=ro(_.type,_.key,_.props,null,q.mode,$),Ia($,_),$.return=q,$;case k:return _=pu(_,q.mode,$),_.return=q,_;case ae:return _=nl(_),ie(q,_,$)}if(J(_)||X(_))return _=Zr(_,q.mode,$,null),_.return=q,_;if(typeof _.then=="function")return ie(q,co(_),$);if(_.$$typeof===z)return ie(q,io(q,_),$);fo(q,_)}return null}function Y(q,_,$,le){var Se=_!==null?_.key:null;if(typeof $=="string"&&$!==""||typeof $=="number"||typeof $=="bigint")return Se!==null?null:C(q,_,""+$,le);if(typeof $=="object"&&$!==null){switch($.$$typeof){case S:return $.key===Se?R(q,_,$,le):null;case k:return $.key===Se?F(q,_,$,le):null;case ae:return $=nl($),Y(q,_,$,le)}if(J($)||X($))return Se!==null?null:te(q,_,$,le,null);if(typeof $.then=="function")return Y(q,_,co($),le);if($.$$typeof===z)return Y(q,_,io(q,$),le);fo(q,$)}return null}function Z(q,_,$,le,Se){if(typeof le=="string"&&le!==""||typeof le=="number"||typeof le=="bigint")return q=q.get($)||null,C(_,q,""+le,Se);if(typeof le=="object"&&le!==null){switch(le.$$typeof){case S:return q=q.get(le.key===null?$:le.key)||null,R(_,q,le,Se);case k:return q=q.get(le.key===null?$:le.key)||null,F(_,q,le,Se);case ae:return le=nl(le),Z(q,_,$,le,Se)}if(J(le)||X(le))return q=q.get($)||null,te(_,q,le,Se,null);if(typeof le.then=="function")return Z(q,_,$,co(le),Se);if(le.$$typeof===z)return Z(q,_,$,io(_,le),Se);fo(_,le)}return null}function ge(q,_,$,le){for(var Se=null,Xe=null,ve=_,Oe=_=0,Ie=null;ve!==null&&Oe<$.length;Oe++){ve.index>Oe?(Ie=ve,ve=null):Ie=ve.sibling;var Qe=Y(q,ve,$[Oe],le);if(Qe===null){ve===null&&(ve=Ie);break}e&&ve&&Qe.alternate===null&&n(q,ve),_=g(Qe,_,Oe),Xe===null?Se=Qe:Xe.sibling=Qe,Xe=Qe,ve=Ie}if(Oe===$.length)return a(q,ve),$e&&Pn(q,Oe),Se;if(ve===null){for(;Oe<$.length;Oe++)ve=ie(q,$[Oe],le),ve!==null&&(_=g(ve,_,Oe),Xe===null?Se=ve:Xe.sibling=ve,Xe=ve);return $e&&Pn(q,Oe),Se}for(ve=o(ve);Oe<$.length;Oe++)Ie=Z(ve,q,Oe,$[Oe],le),Ie!==null&&(e&&Ie.alternate!==null&&ve.delete(Ie.key===null?Oe:Ie.key),_=g(Ie,_,Oe),Xe===null?Se=Ie:Xe.sibling=Ie,Xe=Ie);return e&&ve.forEach(function(_r){return n(q,_r)}),$e&&Pn(q,Oe),Se}function Ee(q,_,$,le){if($==null)throw Error(i(151));for(var Se=null,Xe=null,ve=_,Oe=_=0,Ie=null,Qe=$.next();ve!==null&&!Qe.done;Oe++,Qe=$.next()){ve.index>Oe?(Ie=ve,ve=null):Ie=ve.sibling;var _r=Y(q,ve,Qe.value,le);if(_r===null){ve===null&&(ve=Ie);break}e&&ve&&_r.alternate===null&&n(q,ve),_=g(_r,_,Oe),Xe===null?Se=_r:Xe.sibling=_r,Xe=_r,ve=Ie}if(Qe.done)return a(q,ve),$e&&Pn(q,Oe),Se;if(ve===null){for(;!Qe.done;Oe++,Qe=$.next())Qe=ie(q,Qe.value,le),Qe!==null&&(_=g(Qe,_,Oe),Xe===null?Se=Qe:Xe.sibling=Qe,Xe=Qe);return $e&&Pn(q,Oe),Se}for(ve=o(ve);!Qe.done;Oe++,Qe=$.next())Qe=Z(ve,q,Oe,Qe.value,le),Qe!==null&&(e&&Qe.alternate!==null&&ve.delete(Qe.key===null?Oe:Qe.key),_=g(Qe,_,Oe),Xe===null?Se=Qe:Xe.sibling=Qe,Xe=Qe);return e&&ve.forEach(function(OS){return n(q,OS)}),$e&&Pn(q,Oe),Se}function nt(q,_,$,le){if(typeof $=="object"&&$!==null&&$.type===N&&$.key===null&&($=$.props.children),typeof $=="object"&&$!==null){switch($.$$typeof){case S:e:{for(var Se=$.key;_!==null;){if(_.key===Se){if(Se=$.type,Se===N){if(_.tag===7){a(q,_.sibling),le=f(_,$.props.children),le.return=q,q=le;break e}}else if(_.elementType===Se||typeof Se=="object"&&Se!==null&&Se.$$typeof===ae&&nl(Se)===_.type){a(q,_.sibling),le=f(_,$.props),Ia(le,$),le.return=q,q=le;break e}a(q,_);break}else n(q,_);_=_.sibling}$.type===N?(le=Zr($.props.children,q.mode,le,$.key),le.return=q,q=le):(le=ro($.type,$.key,$.props,null,q.mode,le),Ia(le,$),le.return=q,q=le)}return v(q);case k:e:{for(Se=$.key;_!==null;){if(_.key===Se)if(_.tag===4&&_.stateNode.containerInfo===$.containerInfo&&_.stateNode.implementation===$.implementation){a(q,_.sibling),le=f(_,$.children||[]),le.return=q,q=le;break e}else{a(q,_);break}else n(q,_);_=_.sibling}le=pu($,q.mode,le),le.return=q,q=le}return v(q);case ae:return $=nl($),nt(q,_,$,le)}if(J($))return ge(q,_,$,le);if(X($)){if(Se=X($),typeof Se!="function")throw Error(i(150));return $=Se.call($),Ee(q,_,$,le)}if(typeof $.then=="function")return nt(q,_,co($),le);if($.$$typeof===z)return nt(q,_,io(q,$),le);fo(q,$)}return typeof $=="string"&&$!==""||typeof $=="number"||typeof $=="bigint"?($=""+$,_!==null&&_.tag===6?(a(q,_.sibling),le=f(_,$),le.return=q,q=le):(a(q,_),le=mu($,q.mode,le),le.return=q,q=le),v(q)):a(q,_)}return function(q,_,$,le){try{qa=0;var Se=nt(q,_,$,le);return ql=null,Se}catch(ve){if(ve===Hl||ve===so)throw ve;var Xe=ln(29,ve,null,q.mode);return Xe.lanes=le,Xe.return=q,Xe}finally{}}}var ll=am(!0),im=am(!1),xr=!1;function ju(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Tu(e,n){e=e.updateQueue,n.updateQueue===e&&(n.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function br(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function vr(e,n,a){var o=e.updateQueue;if(o===null)return null;if(o=o.shared,(Ke&2)!==0){var f=o.pending;return f===null?n.next=n:(n.next=f.next,f.next=n),o.pending=n,n=no(e),$h(e,null,a),n}return to(e,o,n,a),no(e)}function Va(e,n,a){if(n=n.updateQueue,n!==null&&(n=n.shared,(a&4194048)!==0)){var o=n.lanes;o&=e.pendingLanes,a|=o,n.lanes=a,Zd(e,a)}}function Au(e,n){var a=e.updateQueue,o=e.alternate;if(o!==null&&(o=o.updateQueue,a===o)){var f=null,g=null;if(a=a.firstBaseUpdate,a!==null){do{var v={lane:a.lane,tag:a.tag,payload:a.payload,callback:null,next:null};g===null?f=g=v:g=g.next=v,a=a.next}while(a!==null);g===null?f=g=n:g=g.next=n}else f=g=n;a={baseState:o.baseState,firstBaseUpdate:f,lastBaseUpdate:g,shared:o.shared,callbacks:o.callbacks},e.updateQueue=a;return}e=a.lastBaseUpdate,e===null?a.firstBaseUpdate=n:e.next=n,a.lastBaseUpdate=n}var Mu=!1;function $a(){if(Mu){var e=Bl;if(e!==null)throw e}}function Fa(e,n,a,o){Mu=!1;var f=e.updateQueue;xr=!1;var g=f.firstBaseUpdate,v=f.lastBaseUpdate,C=f.shared.pending;if(C!==null){f.shared.pending=null;var R=C,F=R.next;R.next=null,v===null?g=F:v.next=F,v=R;var te=e.alternate;te!==null&&(te=te.updateQueue,C=te.lastBaseUpdate,C!==v&&(C===null?te.firstBaseUpdate=F:C.next=F,te.lastBaseUpdate=R))}if(g!==null){var ie=f.baseState;v=0,te=F=R=null,C=g;do{var Y=C.lane&-536870913,Z=Y!==C.lane;if(Z?(qe&Y)===Y:(o&Y)===Y){Y!==0&&Y===Ul&&(Mu=!0),te!==null&&(te=te.next={lane:0,tag:C.tag,payload:C.payload,callback:null,next:null});e:{var ge=e,Ee=C;Y=n;var nt=a;switch(Ee.tag){case 1:if(ge=Ee.payload,typeof ge=="function"){ie=ge.call(nt,ie,Y);break e}ie=ge;break e;case 3:ge.flags=ge.flags&-65537|128;case 0:if(ge=Ee.payload,Y=typeof ge=="function"?ge.call(nt,ie,Y):ge,Y==null)break e;ie=y({},ie,Y);break e;case 2:xr=!0}}Y=C.callback,Y!==null&&(e.flags|=64,Z&&(e.flags|=8192),Z=f.callbacks,Z===null?f.callbacks=[Y]:Z.push(Y))}else Z={lane:Y,tag:C.tag,payload:C.payload,callback:C.callback,next:null},te===null?(F=te=Z,R=ie):te=te.next=Z,v|=Y;if(C=C.next,C===null){if(C=f.shared.pending,C===null)break;Z=C,C=Z.next,Z.next=null,f.lastBaseUpdate=Z,f.shared.pending=null}}while(!0);te===null&&(R=ie),f.baseState=R,f.firstBaseUpdate=F,f.lastBaseUpdate=te,g===null&&(f.shared.lanes=0),Nr|=v,e.lanes=v,e.memoizedState=ie}}function om(e,n){if(typeof e!="function")throw Error(i(191,e));e.call(n)}function sm(e,n){var a=e.callbacks;if(a!==null)for(e.callbacks=null,e=0;e<a.length;e++)om(a[e],n)}var Il=T(null),ho=T(0);function um(e,n){e=lr,E(ho,e),E(Il,n),lr=e|n.baseLanes}function Du(){E(ho,lr),E(Il,Il.current)}function Ru(){lr=ho.current,U(Il),U(ho)}var an=T(null),wn=null;function Sr(e){var n=e.alternate;E(St,St.current&1),E(an,e),wn===null&&(n===null||Il.current!==null||n.memoizedState!==null)&&(wn=e)}function zu(e){E(St,St.current),E(an,e),wn===null&&(wn=e)}function cm(e){e.tag===22?(E(St,St.current),E(an,e),wn===null&&(wn=e)):wr()}function wr(){E(St,St.current),E(an,an.current)}function on(e){U(an),wn===e&&(wn=null),U(St)}var St=T(0);function mo(e){for(var n=e;n!==null;){if(n.tag===13){var a=n.memoizedState;if(a!==null&&(a=a.dehydrated,a===null||Hc(a)||qc(a)))return n}else if(n.tag===19&&(n.memoizedProps.revealOrder==="forwards"||n.memoizedProps.revealOrder==="backwards"||n.memoizedProps.revealOrder==="unstable_legacy-backwards"||n.memoizedProps.revealOrder==="together")){if((n.flags&128)!==0)return n}else if(n.child!==null){n.child.return=n,n=n.child;continue}if(n===e)break;for(;n.sibling===null;){if(n.return===null||n.return===e)return null;n=n.return}n.sibling.return=n.return,n=n.sibling}return null}var Kn=0,Re=null,et=null,Ct=null,po=!1,Vl=!1,al=!1,go=0,Ya=0,$l=null,Cv=0;function xt(){throw Error(i(321))}function Ou(e,n){if(n===null)return!1;for(var a=0;a<n.length&&a<e.length;a++)if(!rn(e[a],n[a]))return!1;return!0}function _u(e,n,a,o,f,g){return Kn=g,Re=n,n.memoizedState=null,n.updateQueue=null,n.lanes=0,H.H=e===null||e.memoizedState===null?Pm:Ku,al=!1,g=a(o,f),al=!1,Vl&&(g=dm(n,a,o,f)),fm(e),g}function fm(e){H.H=Xa;var n=et!==null&&et.next!==null;if(Kn=0,Ct=et=Re=null,po=!1,Ya=0,$l=null,n)throw Error(i(300));e===null||Nt||(e=e.dependencies,e!==null&&ao(e)&&(Nt=!0))}function dm(e,n,a,o){Re=e;var f=0;do{if(Vl&&($l=null),Ya=0,Vl=!1,25<=f)throw Error(i(301));if(f+=1,Ct=et=null,e.updateQueue!=null){var g=e.updateQueue;g.lastEffect=null,g.events=null,g.stores=null,g.memoCache!=null&&(g.memoCache.index=0)}H.H=Xm,g=n(a,o)}while(Vl);return g}function Nv(){var e=H.H,n=e.useState()[0];return n=typeof n.then=="function"?Ga(n):n,e=e.useState()[0],(et!==null?et.memoizedState:null)!==e&&(Re.flags|=1024),n}function Lu(){var e=go!==0;return go=0,e}function Uu(e,n,a){n.updateQueue=e.updateQueue,n.flags&=-2053,e.lanes&=~a}function Bu(e){if(po){for(e=e.memoizedState;e!==null;){var n=e.queue;n!==null&&(n.pending=null),e=e.next}po=!1}Kn=0,Ct=et=Re=null,Vl=!1,Ya=go=0,$l=null}function Yt(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Ct===null?Re.memoizedState=Ct=e:Ct=Ct.next=e,Ct}function wt(){if(et===null){var e=Re.alternate;e=e!==null?e.memoizedState:null}else e=et.next;var n=Ct===null?Re.memoizedState:Ct.next;if(n!==null)Ct=n,et=e;else{if(e===null)throw Re.alternate===null?Error(i(467)):Error(i(310));et=e,e={memoizedState:et.memoizedState,baseState:et.baseState,baseQueue:et.baseQueue,queue:et.queue,next:null},Ct===null?Re.memoizedState=Ct=e:Ct=Ct.next=e}return Ct}function yo(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Ga(e){var n=Ya;return Ya+=1,$l===null&&($l=[]),e=nm($l,e,n),n=Re,(Ct===null?n.memoizedState:Ct.next)===null&&(n=n.alternate,H.H=n===null||n.memoizedState===null?Pm:Ku),e}function xo(e){if(e!==null&&typeof e=="object"){if(typeof e.then=="function")return Ga(e);if(e.$$typeof===z)return Lt(e)}throw Error(i(438,String(e)))}function Hu(e){var n=null,a=Re.updateQueue;if(a!==null&&(n=a.memoCache),n==null){var o=Re.alternate;o!==null&&(o=o.updateQueue,o!==null&&(o=o.memoCache,o!=null&&(n={data:o.data.map(function(f){return f.slice()}),index:0})))}if(n==null&&(n={data:[],index:0}),a===null&&(a=yo(),Re.updateQueue=a),a.memoCache=n,a=n.data[n.index],a===void 0)for(a=n.data[n.index]=Array(e),o=0;o<e;o++)a[o]=L;return n.index++,a}function Zn(e,n){return typeof n=="function"?n(e):n}function bo(e){var n=wt();return qu(n,et,e)}function qu(e,n,a){var o=e.queue;if(o===null)throw Error(i(311));o.lastRenderedReducer=a;var f=e.baseQueue,g=o.pending;if(g!==null){if(f!==null){var v=f.next;f.next=g.next,g.next=v}n.baseQueue=f=g,o.pending=null}if(g=e.baseState,f===null)e.memoizedState=g;else{n=f.next;var C=v=null,R=null,F=n,te=!1;do{var ie=F.lane&-536870913;if(ie!==F.lane?(qe&ie)===ie:(Kn&ie)===ie){var Y=F.revertLane;if(Y===0)R!==null&&(R=R.next={lane:0,revertLane:0,gesture:null,action:F.action,hasEagerState:F.hasEagerState,eagerState:F.eagerState,next:null}),ie===Ul&&(te=!0);else if((Kn&Y)===Y){F=F.next,Y===Ul&&(te=!0);continue}else ie={lane:0,revertLane:F.revertLane,gesture:null,action:F.action,hasEagerState:F.hasEagerState,eagerState:F.eagerState,next:null},R===null?(C=R=ie,v=g):R=R.next=ie,Re.lanes|=Y,Nr|=Y;ie=F.action,al&&a(g,ie),g=F.hasEagerState?F.eagerState:a(g,ie)}else Y={lane:ie,revertLane:F.revertLane,gesture:F.gesture,action:F.action,hasEagerState:F.hasEagerState,eagerState:F.eagerState,next:null},R===null?(C=R=Y,v=g):R=R.next=Y,Re.lanes|=ie,Nr|=ie;F=F.next}while(F!==null&&F!==n);if(R===null?v=g:R.next=C,!rn(g,e.memoizedState)&&(Nt=!0,te&&(a=Bl,a!==null)))throw a;e.memoizedState=g,e.baseState=v,e.baseQueue=R,o.lastRenderedState=g}return f===null&&(o.lanes=0),[e.memoizedState,o.dispatch]}function Iu(e){var n=wt(),a=n.queue;if(a===null)throw Error(i(311));a.lastRenderedReducer=e;var o=a.dispatch,f=a.pending,g=n.memoizedState;if(f!==null){a.pending=null;var v=f=f.next;do g=e(g,v.action),v=v.next;while(v!==f);rn(g,n.memoizedState)||(Nt=!0),n.memoizedState=g,n.baseQueue===null&&(n.baseState=g),a.lastRenderedState=g}return[g,o]}function hm(e,n,a){var o=Re,f=wt(),g=$e;if(g){if(a===void 0)throw Error(i(407));a=a()}else a=n();var v=!rn((et||f).memoizedState,a);if(v&&(f.memoizedState=a,Nt=!0),f=f.queue,Fu(gm.bind(null,o,f,e),[e]),f.getSnapshot!==n||v||Ct!==null&&Ct.memoizedState.tag&1){if(o.flags|=2048,Fl(9,{destroy:void 0},pm.bind(null,o,f,a,n),null),rt===null)throw Error(i(349));g||(Kn&127)!==0||mm(o,n,a)}return a}function mm(e,n,a){e.flags|=16384,e={getSnapshot:n,value:a},n=Re.updateQueue,n===null?(n=yo(),Re.updateQueue=n,n.stores=[e]):(a=n.stores,a===null?n.stores=[e]:a.push(e))}function pm(e,n,a,o){n.value=a,n.getSnapshot=o,ym(n)&&xm(e)}function gm(e,n,a){return a(function(){ym(n)&&xm(e)})}function ym(e){var n=e.getSnapshot;e=e.value;try{var a=n();return!rn(e,a)}catch{return!0}}function xm(e){var n=Kr(e,2);n!==null&&Wt(n,e,2)}function Vu(e){var n=Yt();if(typeof e=="function"){var a=e;if(e=a(),al){Mt(!0);try{a()}finally{Mt(!1)}}}return n.memoizedState=n.baseState=e,n.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Zn,lastRenderedState:e},n}function bm(e,n,a,o){return e.baseState=a,qu(e,et,typeof o=="function"?o:Zn)}function Ev(e,n,a,o,f){if(wo(e))throw Error(i(485));if(e=n.action,e!==null){var g={payload:f,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(v){g.listeners.push(v)}};H.T!==null?a(!0):g.isTransition=!1,o(g),a=n.pending,a===null?(g.next=n.pending=g,vm(n,g)):(g.next=a.next,n.pending=a.next=g)}}function vm(e,n){var a=n.action,o=n.payload,f=e.state;if(n.isTransition){var g=H.T,v={};H.T=v;try{var C=a(f,o),R=H.S;R!==null&&R(v,C),Sm(e,n,C)}catch(F){$u(e,n,F)}finally{g!==null&&v.types!==null&&(g.types=v.types),H.T=g}}else try{g=a(f,o),Sm(e,n,g)}catch(F){$u(e,n,F)}}function Sm(e,n,a){a!==null&&typeof a=="object"&&typeof a.then=="function"?a.then(function(o){wm(e,n,o)},function(o){return $u(e,n,o)}):wm(e,n,a)}function wm(e,n,a){n.status="fulfilled",n.value=a,km(n),e.state=a,n=e.pending,n!==null&&(a=n.next,a===n?e.pending=null:(a=a.next,n.next=a,vm(e,a)))}function $u(e,n,a){var o=e.pending;if(e.pending=null,o!==null){o=o.next;do n.status="rejected",n.reason=a,km(n),n=n.next;while(n!==o)}e.action=null}function km(e){e=e.listeners;for(var n=0;n<e.length;n++)(0,e[n])()}function Cm(e,n){return n}function Nm(e,n){if($e){var a=rt.formState;if(a!==null){e:{var o=Re;if($e){if(ut){t:{for(var f=ut,g=Sn;f.nodeType!==8;){if(!g){f=null;break t}if(f=kn(f.nextSibling),f===null){f=null;break t}}g=f.data,f=g==="F!"||g==="F"?f:null}if(f){ut=kn(f.nextSibling),o=f.data==="F!";break e}}gr(o)}o=!1}o&&(n=a[0])}}return a=Yt(),a.memoizedState=a.baseState=n,o={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Cm,lastRenderedState:n},a.queue=o,a=Fm.bind(null,Re,o),o.dispatch=a,o=Vu(!1),g=Qu.bind(null,Re,!1,o.queue),o=Yt(),f={state:n,dispatch:null,action:e,pending:null},o.queue=f,a=Ev.bind(null,Re,f,g,a),f.dispatch=a,o.memoizedState=e,[n,a,!1]}function Em(e){var n=wt();return jm(n,et,e)}function jm(e,n,a){if(n=qu(e,n,Cm)[0],e=bo(Zn)[0],typeof n=="object"&&n!==null&&typeof n.then=="function")try{var o=Ga(n)}catch(v){throw v===Hl?so:v}else o=n;n=wt();var f=n.queue,g=f.dispatch;return a!==n.memoizedState&&(Re.flags|=2048,Fl(9,{destroy:void 0},jv.bind(null,f,a),null)),[o,g,e]}function jv(e,n){e.action=n}function Tm(e){var n=wt(),a=et;if(a!==null)return jm(n,a,e);wt(),n=n.memoizedState,a=wt();var o=a.queue.dispatch;return a.memoizedState=e,[n,o,!1]}function Fl(e,n,a,o){return e={tag:e,create:a,deps:o,inst:n,next:null},n=Re.updateQueue,n===null&&(n=yo(),Re.updateQueue=n),a=n.lastEffect,a===null?n.lastEffect=e.next=e:(o=a.next,a.next=e,e.next=o,n.lastEffect=e),e}function Am(){return wt().memoizedState}function vo(e,n,a,o){var f=Yt();Re.flags|=e,f.memoizedState=Fl(1|n,{destroy:void 0},a,o===void 0?null:o)}function So(e,n,a,o){var f=wt();o=o===void 0?null:o;var g=f.memoizedState.inst;et!==null&&o!==null&&Ou(o,et.memoizedState.deps)?f.memoizedState=Fl(n,g,a,o):(Re.flags|=e,f.memoizedState=Fl(1|n,g,a,o))}function Mm(e,n){vo(8390656,8,e,n)}function Fu(e,n){So(2048,8,e,n)}function Tv(e){Re.flags|=4;var n=Re.updateQueue;if(n===null)n=yo(),Re.updateQueue=n,n.events=[e];else{var a=n.events;a===null?n.events=[e]:a.push(e)}}function Dm(e){var n=wt().memoizedState;return Tv({ref:n,nextImpl:e}),function(){if((Ke&2)!==0)throw Error(i(440));return n.impl.apply(void 0,arguments)}}function Rm(e,n){return So(4,2,e,n)}function zm(e,n){return So(4,4,e,n)}function Om(e,n){if(typeof n=="function"){e=e();var a=n(e);return function(){typeof a=="function"?a():n(null)}}if(n!=null)return e=e(),n.current=e,function(){n.current=null}}function _m(e,n,a){a=a!=null?a.concat([e]):null,So(4,4,Om.bind(null,n,e),a)}function Yu(){}function Lm(e,n){var a=wt();n=n===void 0?null:n;var o=a.memoizedState;return n!==null&&Ou(n,o[1])?o[0]:(a.memoizedState=[e,n],e)}function Um(e,n){var a=wt();n=n===void 0?null:n;var o=a.memoizedState;if(n!==null&&Ou(n,o[1]))return o[0];if(o=e(),al){Mt(!0);try{e()}finally{Mt(!1)}}return a.memoizedState=[o,n],o}function Gu(e,n,a){return a===void 0||(Kn&1073741824)!==0&&(qe&261930)===0?e.memoizedState=n:(e.memoizedState=a,e=Bp(),Re.lanes|=e,Nr|=e,a)}function Bm(e,n,a,o){return rn(a,n)?a:Il.current!==null?(e=Gu(e,a,o),rn(e,n)||(Nt=!0),e):(Kn&42)===0||(Kn&1073741824)!==0&&(qe&261930)===0?(Nt=!0,e.memoizedState=a):(e=Bp(),Re.lanes|=e,Nr|=e,n)}function Hm(e,n,a,o,f){var g=ne.p;ne.p=g!==0&&8>g?g:8;var v=H.T,C={};H.T=C,Qu(e,!1,n,a);try{var R=f(),F=H.S;if(F!==null&&F(C,R),R!==null&&typeof R=="object"&&typeof R.then=="function"){var te=kv(R,o);Pa(e,n,te,cn(e))}else Pa(e,n,o,cn(e))}catch(ie){Pa(e,n,{then:function(){},status:"rejected",reason:ie},cn())}finally{ne.p=g,v!==null&&C.types!==null&&(v.types=C.types),H.T=v}}function Av(){}function Pu(e,n,a,o){if(e.tag!==5)throw Error(i(476));var f=qm(e).queue;Hm(e,f,n,oe,a===null?Av:function(){return Im(e),a(o)})}function qm(e){var n=e.memoizedState;if(n!==null)return n;n={memoizedState:oe,baseState:oe,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Zn,lastRenderedState:oe},next:null};var a={};return n.next={memoizedState:a,baseState:a,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Zn,lastRenderedState:a},next:null},e.memoizedState=n,e=e.alternate,e!==null&&(e.memoizedState=n),n}function Im(e){var n=qm(e);n.next===null&&(n=e.alternate.memoizedState),Pa(e,n.next.queue,{},cn())}function Xu(){return Lt(ci)}function Vm(){return wt().memoizedState}function $m(){return wt().memoizedState}function Mv(e){for(var n=e.return;n!==null;){switch(n.tag){case 24:case 3:var a=cn();e=br(a);var o=vr(n,e,a);o!==null&&(Wt(o,n,a),Va(o,n,a)),n={cache:ku()},e.payload=n;return}n=n.return}}function Dv(e,n,a){var o=cn();a={lane:o,revertLane:0,gesture:null,action:a,hasEagerState:!1,eagerState:null,next:null},wo(e)?Ym(n,a):(a=du(e,n,a,o),a!==null&&(Wt(a,e,o),Gm(a,n,o)))}function Fm(e,n,a){var o=cn();Pa(e,n,a,o)}function Pa(e,n,a,o){var f={lane:o,revertLane:0,gesture:null,action:a,hasEagerState:!1,eagerState:null,next:null};if(wo(e))Ym(n,f);else{var g=e.alternate;if(e.lanes===0&&(g===null||g.lanes===0)&&(g=n.lastRenderedReducer,g!==null))try{var v=n.lastRenderedState,C=g(v,a);if(f.hasEagerState=!0,f.eagerState=C,rn(C,v))return to(e,n,f,0),rt===null&&eo(),!1}catch{}finally{}if(a=du(e,n,f,o),a!==null)return Wt(a,e,o),Gm(a,n,o),!0}return!1}function Qu(e,n,a,o){if(o={lane:2,revertLane:jc(),gesture:null,action:o,hasEagerState:!1,eagerState:null,next:null},wo(e)){if(n)throw Error(i(479))}else n=du(e,a,o,2),n!==null&&Wt(n,e,2)}function wo(e){var n=e.alternate;return e===Re||n!==null&&n===Re}function Ym(e,n){Vl=po=!0;var a=e.pending;a===null?n.next=n:(n.next=a.next,a.next=n),e.pending=n}function Gm(e,n,a){if((a&4194048)!==0){var o=n.lanes;o&=e.pendingLanes,a|=o,n.lanes=a,Zd(e,a)}}var Xa={readContext:Lt,use:xo,useCallback:xt,useContext:xt,useEffect:xt,useImperativeHandle:xt,useLayoutEffect:xt,useInsertionEffect:xt,useMemo:xt,useReducer:xt,useRef:xt,useState:xt,useDebugValue:xt,useDeferredValue:xt,useTransition:xt,useSyncExternalStore:xt,useId:xt,useHostTransitionStatus:xt,useFormState:xt,useActionState:xt,useOptimistic:xt,useMemoCache:xt,useCacheRefresh:xt};Xa.useEffectEvent=xt;var Pm={readContext:Lt,use:xo,useCallback:function(e,n){return Yt().memoizedState=[e,n===void 0?null:n],e},useContext:Lt,useEffect:Mm,useImperativeHandle:function(e,n,a){a=a!=null?a.concat([e]):null,vo(4194308,4,Om.bind(null,n,e),a)},useLayoutEffect:function(e,n){return vo(4194308,4,e,n)},useInsertionEffect:function(e,n){vo(4,2,e,n)},useMemo:function(e,n){var a=Yt();n=n===void 0?null:n;var o=e();if(al){Mt(!0);try{e()}finally{Mt(!1)}}return a.memoizedState=[o,n],o},useReducer:function(e,n,a){var o=Yt();if(a!==void 0){var f=a(n);if(al){Mt(!0);try{a(n)}finally{Mt(!1)}}}else f=n;return o.memoizedState=o.baseState=f,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:f},o.queue=e,e=e.dispatch=Dv.bind(null,Re,e),[o.memoizedState,e]},useRef:function(e){var n=Yt();return e={current:e},n.memoizedState=e},useState:function(e){e=Vu(e);var n=e.queue,a=Fm.bind(null,Re,n);return n.dispatch=a,[e.memoizedState,a]},useDebugValue:Yu,useDeferredValue:function(e,n){var a=Yt();return Gu(a,e,n)},useTransition:function(){var e=Vu(!1);return e=Hm.bind(null,Re,e.queue,!0,!1),Yt().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,n,a){var o=Re,f=Yt();if($e){if(a===void 0)throw Error(i(407));a=a()}else{if(a=n(),rt===null)throw Error(i(349));(qe&127)!==0||mm(o,n,a)}f.memoizedState=a;var g={value:a,getSnapshot:n};return f.queue=g,Mm(gm.bind(null,o,g,e),[e]),o.flags|=2048,Fl(9,{destroy:void 0},pm.bind(null,o,g,a,n),null),a},useId:function(){var e=Yt(),n=rt.identifierPrefix;if($e){var a=On,o=zn;a=(o&~(1<<32-Ze(o)-1)).toString(32)+a,n="_"+n+"R_"+a,a=go++,0<a&&(n+="H"+a.toString(32)),n+="_"}else a=Cv++,n="_"+n+"r_"+a.toString(32)+"_";return e.memoizedState=n},useHostTransitionStatus:Xu,useFormState:Nm,useActionState:Nm,useOptimistic:function(e){var n=Yt();n.memoizedState=n.baseState=e;var a={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return n.queue=a,n=Qu.bind(null,Re,!0,a),a.dispatch=n,[e,n]},useMemoCache:Hu,useCacheRefresh:function(){return Yt().memoizedState=Mv.bind(null,Re)},useEffectEvent:function(e){var n=Yt(),a={impl:e};return n.memoizedState=a,function(){if((Ke&2)!==0)throw Error(i(440));return a.impl.apply(void 0,arguments)}}},Ku={readContext:Lt,use:xo,useCallback:Lm,useContext:Lt,useEffect:Fu,useImperativeHandle:_m,useInsertionEffect:Rm,useLayoutEffect:zm,useMemo:Um,useReducer:bo,useRef:Am,useState:function(){return bo(Zn)},useDebugValue:Yu,useDeferredValue:function(e,n){var a=wt();return Bm(a,et.memoizedState,e,n)},useTransition:function(){var e=bo(Zn)[0],n=wt().memoizedState;return[typeof e=="boolean"?e:Ga(e),n]},useSyncExternalStore:hm,useId:Vm,useHostTransitionStatus:Xu,useFormState:Em,useActionState:Em,useOptimistic:function(e,n){var a=wt();return bm(a,et,e,n)},useMemoCache:Hu,useCacheRefresh:$m};Ku.useEffectEvent=Dm;var Xm={readContext:Lt,use:xo,useCallback:Lm,useContext:Lt,useEffect:Fu,useImperativeHandle:_m,useInsertionEffect:Rm,useLayoutEffect:zm,useMemo:Um,useReducer:Iu,useRef:Am,useState:function(){return Iu(Zn)},useDebugValue:Yu,useDeferredValue:function(e,n){var a=wt();return et===null?Gu(a,e,n):Bm(a,et.memoizedState,e,n)},useTransition:function(){var e=Iu(Zn)[0],n=wt().memoizedState;return[typeof e=="boolean"?e:Ga(e),n]},useSyncExternalStore:hm,useId:Vm,useHostTransitionStatus:Xu,useFormState:Tm,useActionState:Tm,useOptimistic:function(e,n){var a=wt();return et!==null?bm(a,et,e,n):(a.baseState=e,[e,a.queue.dispatch])},useMemoCache:Hu,useCacheRefresh:$m};Xm.useEffectEvent=Dm;function Zu(e,n,a,o){n=e.memoizedState,a=a(o,n),a=a==null?n:y({},n,a),e.memoizedState=a,e.lanes===0&&(e.updateQueue.baseState=a)}var Ju={enqueueSetState:function(e,n,a){e=e._reactInternals;var o=cn(),f=br(o);f.payload=n,a!=null&&(f.callback=a),n=vr(e,f,o),n!==null&&(Wt(n,e,o),Va(n,e,o))},enqueueReplaceState:function(e,n,a){e=e._reactInternals;var o=cn(),f=br(o);f.tag=1,f.payload=n,a!=null&&(f.callback=a),n=vr(e,f,o),n!==null&&(Wt(n,e,o),Va(n,e,o))},enqueueForceUpdate:function(e,n){e=e._reactInternals;var a=cn(),o=br(a);o.tag=2,n!=null&&(o.callback=n),n=vr(e,o,a),n!==null&&(Wt(n,e,a),Va(n,e,a))}};function Qm(e,n,a,o,f,g,v){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(o,g,v):n.prototype&&n.prototype.isPureReactComponent?!Oa(a,o)||!Oa(f,g):!0}function Km(e,n,a,o){e=n.state,typeof n.componentWillReceiveProps=="function"&&n.componentWillReceiveProps(a,o),typeof n.UNSAFE_componentWillReceiveProps=="function"&&n.UNSAFE_componentWillReceiveProps(a,o),n.state!==e&&Ju.enqueueReplaceState(n,n.state,null)}function il(e,n){var a=n;if("ref"in n){a={};for(var o in n)o!=="ref"&&(a[o]=n[o])}if(e=e.defaultProps){a===n&&(a=y({},a));for(var f in e)a[f]===void 0&&(a[f]=e[f])}return a}function Zm(e){Wi(e)}function Jm(e){console.error(e)}function Wm(e){Wi(e)}function ko(e,n){try{var a=e.onUncaughtError;a(n.value,{componentStack:n.stack})}catch(o){setTimeout(function(){throw o})}}function ep(e,n,a){try{var o=e.onCaughtError;o(a.value,{componentStack:a.stack,errorBoundary:n.tag===1?n.stateNode:null})}catch(f){setTimeout(function(){throw f})}}function Wu(e,n,a){return a=br(a),a.tag=3,a.payload={element:null},a.callback=function(){ko(e,n)},a}function tp(e){return e=br(e),e.tag=3,e}function np(e,n,a,o){var f=a.type.getDerivedStateFromError;if(typeof f=="function"){var g=o.value;e.payload=function(){return f(g)},e.callback=function(){ep(n,a,o)}}var v=a.stateNode;v!==null&&typeof v.componentDidCatch=="function"&&(e.callback=function(){ep(n,a,o),typeof f!="function"&&(Er===null?Er=new Set([this]):Er.add(this));var C=o.stack;this.componentDidCatch(o.value,{componentStack:C!==null?C:""})})}function Rv(e,n,a,o,f){if(a.flags|=32768,o!==null&&typeof o=="object"&&typeof o.then=="function"){if(n=a.alternate,n!==null&&Ll(n,a,f,!0),a=an.current,a!==null){switch(a.tag){case 31:case 13:return wn===null?_o():a.alternate===null&&bt===0&&(bt=3),a.flags&=-257,a.flags|=65536,a.lanes=f,o===uo?a.flags|=16384:(n=a.updateQueue,n===null?a.updateQueue=new Set([o]):n.add(o),Cc(e,o,f)),!1;case 22:return a.flags|=65536,o===uo?a.flags|=16384:(n=a.updateQueue,n===null?(n={transitions:null,markerInstances:null,retryQueue:new Set([o])},a.updateQueue=n):(a=n.retryQueue,a===null?n.retryQueue=new Set([o]):a.add(o)),Cc(e,o,f)),!1}throw Error(i(435,a.tag))}return Cc(e,o,f),_o(),!1}if($e)return n=an.current,n!==null?((n.flags&65536)===0&&(n.flags|=256),n.flags|=65536,n.lanes=f,o!==xu&&(e=Error(i(422),{cause:o}),Ua(xn(e,a)))):(o!==xu&&(n=Error(i(423),{cause:o}),Ua(xn(n,a))),e=e.current.alternate,e.flags|=65536,f&=-f,e.lanes|=f,o=xn(o,a),f=Wu(e.stateNode,o,f),Au(e,f),bt!==4&&(bt=2)),!1;var g=Error(i(520),{cause:o});if(g=xn(g,a),ni===null?ni=[g]:ni.push(g),bt!==4&&(bt=2),n===null)return!0;o=xn(o,a),a=n;do{switch(a.tag){case 3:return a.flags|=65536,e=f&-f,a.lanes|=e,e=Wu(a.stateNode,o,e),Au(a,e),!1;case 1:if(n=a.type,g=a.stateNode,(a.flags&128)===0&&(typeof n.getDerivedStateFromError=="function"||g!==null&&typeof g.componentDidCatch=="function"&&(Er===null||!Er.has(g))))return a.flags|=65536,f&=-f,a.lanes|=f,f=tp(f),np(f,e,a,o),Au(a,f),!1}a=a.return}while(a!==null);return!1}var ec=Error(i(461)),Nt=!1;function Ut(e,n,a,o){n.child=e===null?im(n,null,a,o):ll(n,e.child,a,o)}function rp(e,n,a,o,f){a=a.render;var g=n.ref;if("ref"in o){var v={};for(var C in o)C!=="ref"&&(v[C]=o[C])}else v=o;return el(n),o=_u(e,n,a,v,g,f),C=Lu(),e!==null&&!Nt?(Uu(e,n,f),Jn(e,n,f)):($e&&C&&gu(n),n.flags|=1,Ut(e,n,o,f),n.child)}function lp(e,n,a,o,f){if(e===null){var g=a.type;return typeof g=="function"&&!hu(g)&&g.defaultProps===void 0&&a.compare===null?(n.tag=15,n.type=g,ap(e,n,g,o,f)):(e=ro(a.type,null,o,n,n.mode,f),e.ref=n.ref,e.return=n,n.child=e)}if(g=e.child,!sc(e,f)){var v=g.memoizedProps;if(a=a.compare,a=a!==null?a:Oa,a(v,o)&&e.ref===n.ref)return Jn(e,n,f)}return n.flags|=1,e=Gn(g,o),e.ref=n.ref,e.return=n,n.child=e}function ap(e,n,a,o,f){if(e!==null){var g=e.memoizedProps;if(Oa(g,o)&&e.ref===n.ref)if(Nt=!1,n.pendingProps=o=g,sc(e,f))(e.flags&131072)!==0&&(Nt=!0);else return n.lanes=e.lanes,Jn(e,n,f)}return tc(e,n,a,o,f)}function ip(e,n,a,o){var f=o.children,g=e!==null?e.memoizedState:null;if(e===null&&n.stateNode===null&&(n.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),o.mode==="hidden"){if((n.flags&128)!==0){if(g=g!==null?g.baseLanes|a:a,e!==null){for(o=n.child=e.child,f=0;o!==null;)f=f|o.lanes|o.childLanes,o=o.sibling;o=f&~g}else o=0,n.child=null;return op(e,n,g,a,o)}if((a&536870912)!==0)n.memoizedState={baseLanes:0,cachePool:null},e!==null&&oo(n,g!==null?g.cachePool:null),g!==null?um(n,g):Du(),cm(n);else return o=n.lanes=536870912,op(e,n,g!==null?g.baseLanes|a:a,a,o)}else g!==null?(oo(n,g.cachePool),um(n,g),wr(),n.memoizedState=null):(e!==null&&oo(n,null),Du(),wr());return Ut(e,n,f,a),n.child}function Qa(e,n){return e!==null&&e.tag===22||n.stateNode!==null||(n.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),n.sibling}function op(e,n,a,o,f){var g=Nu();return g=g===null?null:{parent:kt._currentValue,pool:g},n.memoizedState={baseLanes:a,cachePool:g},e!==null&&oo(n,null),Du(),cm(n),e!==null&&Ll(e,n,o,!0),n.childLanes=f,null}function Co(e,n){return n=Eo({mode:n.mode,children:n.children},e.mode),n.ref=e.ref,e.child=n,n.return=e,n}function sp(e,n,a){return ll(n,e.child,null,a),e=Co(n,n.pendingProps),e.flags|=2,on(n),n.memoizedState=null,e}function zv(e,n,a){var o=n.pendingProps,f=(n.flags&128)!==0;if(n.flags&=-129,e===null){if($e){if(o.mode==="hidden")return e=Co(n,o),n.lanes=536870912,Qa(null,e);if(zu(n),(e=ut)?(e=vg(e,Sn),e=e!==null&&e.data==="&"?e:null,e!==null&&(n.memoizedState={dehydrated:e,treeContext:mr!==null?{id:zn,overflow:On}:null,retryLane:536870912,hydrationErrors:null},a=Yh(e),a.return=n,n.child=a,_t=n,ut=null)):e=null,e===null)throw gr(n);return n.lanes=536870912,null}return Co(n,o)}var g=e.memoizedState;if(g!==null){var v=g.dehydrated;if(zu(n),f)if(n.flags&256)n.flags&=-257,n=sp(e,n,a);else if(n.memoizedState!==null)n.child=e.child,n.flags|=128,n=null;else throw Error(i(558));else if(Nt||Ll(e,n,a,!1),f=(a&e.childLanes)!==0,Nt||f){if(o=rt,o!==null&&(v=Jd(o,a),v!==0&&v!==g.retryLane))throw g.retryLane=v,Kr(e,v),Wt(o,e,v),ec;_o(),n=sp(e,n,a)}else e=g.treeContext,ut=kn(v.nextSibling),_t=n,$e=!0,pr=null,Sn=!1,e!==null&&Xh(n,e),n=Co(n,o),n.flags|=4096;return n}return e=Gn(e.child,{mode:o.mode,children:o.children}),e.ref=n.ref,n.child=e,e.return=n,e}function No(e,n){var a=n.ref;if(a===null)e!==null&&e.ref!==null&&(n.flags|=4194816);else{if(typeof a!="function"&&typeof a!="object")throw Error(i(284));(e===null||e.ref!==a)&&(n.flags|=4194816)}}function tc(e,n,a,o,f){return el(n),a=_u(e,n,a,o,void 0,f),o=Lu(),e!==null&&!Nt?(Uu(e,n,f),Jn(e,n,f)):($e&&o&&gu(n),n.flags|=1,Ut(e,n,a,f),n.child)}function up(e,n,a,o,f,g){return el(n),n.updateQueue=null,a=dm(n,o,a,f),fm(e),o=Lu(),e!==null&&!Nt?(Uu(e,n,g),Jn(e,n,g)):($e&&o&&gu(n),n.flags|=1,Ut(e,n,a,g),n.child)}function cp(e,n,a,o,f){if(el(n),n.stateNode===null){var g=Rl,v=a.contextType;typeof v=="object"&&v!==null&&(g=Lt(v)),g=new a(o,g),n.memoizedState=g.state!==null&&g.state!==void 0?g.state:null,g.updater=Ju,n.stateNode=g,g._reactInternals=n,g=n.stateNode,g.props=o,g.state=n.memoizedState,g.refs={},ju(n),v=a.contextType,g.context=typeof v=="object"&&v!==null?Lt(v):Rl,g.state=n.memoizedState,v=a.getDerivedStateFromProps,typeof v=="function"&&(Zu(n,a,v,o),g.state=n.memoizedState),typeof a.getDerivedStateFromProps=="function"||typeof g.getSnapshotBeforeUpdate=="function"||typeof g.UNSAFE_componentWillMount!="function"&&typeof g.componentWillMount!="function"||(v=g.state,typeof g.componentWillMount=="function"&&g.componentWillMount(),typeof g.UNSAFE_componentWillMount=="function"&&g.UNSAFE_componentWillMount(),v!==g.state&&Ju.enqueueReplaceState(g,g.state,null),Fa(n,o,g,f),$a(),g.state=n.memoizedState),typeof g.componentDidMount=="function"&&(n.flags|=4194308),o=!0}else if(e===null){g=n.stateNode;var C=n.memoizedProps,R=il(a,C);g.props=R;var F=g.context,te=a.contextType;v=Rl,typeof te=="object"&&te!==null&&(v=Lt(te));var ie=a.getDerivedStateFromProps;te=typeof ie=="function"||typeof g.getSnapshotBeforeUpdate=="function",C=n.pendingProps!==C,te||typeof g.UNSAFE_componentWillReceiveProps!="function"&&typeof g.componentWillReceiveProps!="function"||(C||F!==v)&&Km(n,g,o,v),xr=!1;var Y=n.memoizedState;g.state=Y,Fa(n,o,g,f),$a(),F=n.memoizedState,C||Y!==F||xr?(typeof ie=="function"&&(Zu(n,a,ie,o),F=n.memoizedState),(R=xr||Qm(n,a,R,o,Y,F,v))?(te||typeof g.UNSAFE_componentWillMount!="function"&&typeof g.componentWillMount!="function"||(typeof g.componentWillMount=="function"&&g.componentWillMount(),typeof g.UNSAFE_componentWillMount=="function"&&g.UNSAFE_componentWillMount()),typeof g.componentDidMount=="function"&&(n.flags|=4194308)):(typeof g.componentDidMount=="function"&&(n.flags|=4194308),n.memoizedProps=o,n.memoizedState=F),g.props=o,g.state=F,g.context=v,o=R):(typeof g.componentDidMount=="function"&&(n.flags|=4194308),o=!1)}else{g=n.stateNode,Tu(e,n),v=n.memoizedProps,te=il(a,v),g.props=te,ie=n.pendingProps,Y=g.context,F=a.contextType,R=Rl,typeof F=="object"&&F!==null&&(R=Lt(F)),C=a.getDerivedStateFromProps,(F=typeof C=="function"||typeof g.getSnapshotBeforeUpdate=="function")||typeof g.UNSAFE_componentWillReceiveProps!="function"&&typeof g.componentWillReceiveProps!="function"||(v!==ie||Y!==R)&&Km(n,g,o,R),xr=!1,Y=n.memoizedState,g.state=Y,Fa(n,o,g,f),$a();var Z=n.memoizedState;v!==ie||Y!==Z||xr||e!==null&&e.dependencies!==null&&ao(e.dependencies)?(typeof C=="function"&&(Zu(n,a,C,o),Z=n.memoizedState),(te=xr||Qm(n,a,te,o,Y,Z,R)||e!==null&&e.dependencies!==null&&ao(e.dependencies))?(F||typeof g.UNSAFE_componentWillUpdate!="function"&&typeof g.componentWillUpdate!="function"||(typeof g.componentWillUpdate=="function"&&g.componentWillUpdate(o,Z,R),typeof g.UNSAFE_componentWillUpdate=="function"&&g.UNSAFE_componentWillUpdate(o,Z,R)),typeof g.componentDidUpdate=="function"&&(n.flags|=4),typeof g.getSnapshotBeforeUpdate=="function"&&(n.flags|=1024)):(typeof g.componentDidUpdate!="function"||v===e.memoizedProps&&Y===e.memoizedState||(n.flags|=4),typeof g.getSnapshotBeforeUpdate!="function"||v===e.memoizedProps&&Y===e.memoizedState||(n.flags|=1024),n.memoizedProps=o,n.memoizedState=Z),g.props=o,g.state=Z,g.context=R,o=te):(typeof g.componentDidUpdate!="function"||v===e.memoizedProps&&Y===e.memoizedState||(n.flags|=4),typeof g.getSnapshotBeforeUpdate!="function"||v===e.memoizedProps&&Y===e.memoizedState||(n.flags|=1024),o=!1)}return g=o,No(e,n),o=(n.flags&128)!==0,g||o?(g=n.stateNode,a=o&&typeof a.getDerivedStateFromError!="function"?null:g.render(),n.flags|=1,e!==null&&o?(n.child=ll(n,e.child,null,f),n.child=ll(n,null,a,f)):Ut(e,n,a,f),n.memoizedState=g.state,e=n.child):e=Jn(e,n,f),e}function fp(e,n,a,o){return Jr(),n.flags|=256,Ut(e,n,a,o),n.child}var nc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function rc(e){return{baseLanes:e,cachePool:em()}}function lc(e,n,a){return e=e!==null?e.childLanes&~a:0,n&&(e|=un),e}function dp(e,n,a){var o=n.pendingProps,f=!1,g=(n.flags&128)!==0,v;if((v=g)||(v=e!==null&&e.memoizedState===null?!1:(St.current&2)!==0),v&&(f=!0,n.flags&=-129),v=(n.flags&32)!==0,n.flags&=-33,e===null){if($e){if(f?Sr(n):wr(),(e=ut)?(e=vg(e,Sn),e=e!==null&&e.data!=="&"?e:null,e!==null&&(n.memoizedState={dehydrated:e,treeContext:mr!==null?{id:zn,overflow:On}:null,retryLane:536870912,hydrationErrors:null},a=Yh(e),a.return=n,n.child=a,_t=n,ut=null)):e=null,e===null)throw gr(n);return qc(e)?n.lanes=32:n.lanes=536870912,null}var C=o.children;return o=o.fallback,f?(wr(),f=n.mode,C=Eo({mode:"hidden",children:C},f),o=Zr(o,f,a,null),C.return=n,o.return=n,C.sibling=o,n.child=C,o=n.child,o.memoizedState=rc(a),o.childLanes=lc(e,v,a),n.memoizedState=nc,Qa(null,o)):(Sr(n),ac(n,C))}var R=e.memoizedState;if(R!==null&&(C=R.dehydrated,C!==null)){if(g)n.flags&256?(Sr(n),n.flags&=-257,n=ic(e,n,a)):n.memoizedState!==null?(wr(),n.child=e.child,n.flags|=128,n=null):(wr(),C=o.fallback,f=n.mode,o=Eo({mode:"visible",children:o.children},f),C=Zr(C,f,a,null),C.flags|=2,o.return=n,C.return=n,o.sibling=C,n.child=o,ll(n,e.child,null,a),o=n.child,o.memoizedState=rc(a),o.childLanes=lc(e,v,a),n.memoizedState=nc,n=Qa(null,o));else if(Sr(n),qc(C)){if(v=C.nextSibling&&C.nextSibling.dataset,v)var F=v.dgst;v=F,o=Error(i(419)),o.stack="",o.digest=v,Ua({value:o,source:null,stack:null}),n=ic(e,n,a)}else if(Nt||Ll(e,n,a,!1),v=(a&e.childLanes)!==0,Nt||v){if(v=rt,v!==null&&(o=Jd(v,a),o!==0&&o!==R.retryLane))throw R.retryLane=o,Kr(e,o),Wt(v,e,o),ec;Hc(C)||_o(),n=ic(e,n,a)}else Hc(C)?(n.flags|=192,n.child=e.child,n=null):(e=R.treeContext,ut=kn(C.nextSibling),_t=n,$e=!0,pr=null,Sn=!1,e!==null&&Xh(n,e),n=ac(n,o.children),n.flags|=4096);return n}return f?(wr(),C=o.fallback,f=n.mode,R=e.child,F=R.sibling,o=Gn(R,{mode:"hidden",children:o.children}),o.subtreeFlags=R.subtreeFlags&65011712,F!==null?C=Gn(F,C):(C=Zr(C,f,a,null),C.flags|=2),C.return=n,o.return=n,o.sibling=C,n.child=o,Qa(null,o),o=n.child,C=e.child.memoizedState,C===null?C=rc(a):(f=C.cachePool,f!==null?(R=kt._currentValue,f=f.parent!==R?{parent:R,pool:R}:f):f=em(),C={baseLanes:C.baseLanes|a,cachePool:f}),o.memoizedState=C,o.childLanes=lc(e,v,a),n.memoizedState=nc,Qa(e.child,o)):(Sr(n),a=e.child,e=a.sibling,a=Gn(a,{mode:"visible",children:o.children}),a.return=n,a.sibling=null,e!==null&&(v=n.deletions,v===null?(n.deletions=[e],n.flags|=16):v.push(e)),n.child=a,n.memoizedState=null,a)}function ac(e,n){return n=Eo({mode:"visible",children:n},e.mode),n.return=e,e.child=n}function Eo(e,n){return e=ln(22,e,null,n),e.lanes=0,e}function ic(e,n,a){return ll(n,e.child,null,a),e=ac(n,n.pendingProps.children),e.flags|=2,n.memoizedState=null,e}function hp(e,n,a){e.lanes|=n;var o=e.alternate;o!==null&&(o.lanes|=n),Su(e.return,n,a)}function oc(e,n,a,o,f,g){var v=e.memoizedState;v===null?e.memoizedState={isBackwards:n,rendering:null,renderingStartTime:0,last:o,tail:a,tailMode:f,treeForkCount:g}:(v.isBackwards=n,v.rendering=null,v.renderingStartTime=0,v.last=o,v.tail=a,v.tailMode=f,v.treeForkCount=g)}function mp(e,n,a){var o=n.pendingProps,f=o.revealOrder,g=o.tail;o=o.children;var v=St.current,C=(v&2)!==0;if(C?(v=v&1|2,n.flags|=128):v&=1,E(St,v),Ut(e,n,o,a),o=$e?La:0,!C&&e!==null&&(e.flags&128)!==0)e:for(e=n.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&hp(e,a,n);else if(e.tag===19)hp(e,a,n);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===n)break e;for(;e.sibling===null;){if(e.return===null||e.return===n)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(f){case"forwards":for(a=n.child,f=null;a!==null;)e=a.alternate,e!==null&&mo(e)===null&&(f=a),a=a.sibling;a=f,a===null?(f=n.child,n.child=null):(f=a.sibling,a.sibling=null),oc(n,!1,f,a,g,o);break;case"backwards":case"unstable_legacy-backwards":for(a=null,f=n.child,n.child=null;f!==null;){if(e=f.alternate,e!==null&&mo(e)===null){n.child=f;break}e=f.sibling,f.sibling=a,a=f,f=e}oc(n,!0,a,null,g,o);break;case"together":oc(n,!1,null,null,void 0,o);break;default:n.memoizedState=null}return n.child}function Jn(e,n,a){if(e!==null&&(n.dependencies=e.dependencies),Nr|=n.lanes,(a&n.childLanes)===0)if(e!==null){if(Ll(e,n,a,!1),(a&n.childLanes)===0)return null}else return null;if(e!==null&&n.child!==e.child)throw Error(i(153));if(n.child!==null){for(e=n.child,a=Gn(e,e.pendingProps),n.child=a,a.return=n;e.sibling!==null;)e=e.sibling,a=a.sibling=Gn(e,e.pendingProps),a.return=n;a.sibling=null}return n.child}function sc(e,n){return(e.lanes&n)!==0?!0:(e=e.dependencies,!!(e!==null&&ao(e)))}function Ov(e,n,a){switch(n.tag){case 3:be(n,n.stateNode.containerInfo),yr(n,kt,e.memoizedState.cache),Jr();break;case 27:case 5:Ae(n);break;case 4:be(n,n.stateNode.containerInfo);break;case 10:yr(n,n.type,n.memoizedProps.value);break;case 31:if(n.memoizedState!==null)return n.flags|=128,zu(n),null;break;case 13:var o=n.memoizedState;if(o!==null)return o.dehydrated!==null?(Sr(n),n.flags|=128,null):(a&n.child.childLanes)!==0?dp(e,n,a):(Sr(n),e=Jn(e,n,a),e!==null?e.sibling:null);Sr(n);break;case 19:var f=(e.flags&128)!==0;if(o=(a&n.childLanes)!==0,o||(Ll(e,n,a,!1),o=(a&n.childLanes)!==0),f){if(o)return mp(e,n,a);n.flags|=128}if(f=n.memoizedState,f!==null&&(f.rendering=null,f.tail=null,f.lastEffect=null),E(St,St.current),o)break;return null;case 22:return n.lanes=0,ip(e,n,a,n.pendingProps);case 24:yr(n,kt,e.memoizedState.cache)}return Jn(e,n,a)}function pp(e,n,a){if(e!==null)if(e.memoizedProps!==n.pendingProps)Nt=!0;else{if(!sc(e,a)&&(n.flags&128)===0)return Nt=!1,Ov(e,n,a);Nt=(e.flags&131072)!==0}else Nt=!1,$e&&(n.flags&1048576)!==0&&Ph(n,La,n.index);switch(n.lanes=0,n.tag){case 16:e:{var o=n.pendingProps;if(e=nl(n.elementType),n.type=e,typeof e=="function")hu(e)?(o=il(e,o),n.tag=1,n=cp(null,n,e,o,a)):(n.tag=0,n=tc(null,n,e,o,a));else{if(e!=null){var f=e.$$typeof;if(f===V){n.tag=11,n=rp(null,n,e,o,a);break e}else if(f===G){n.tag=14,n=lp(null,n,e,o,a);break e}}throw n=I(e)||e,Error(i(306,n,""))}}return n;case 0:return tc(e,n,n.type,n.pendingProps,a);case 1:return o=n.type,f=il(o,n.pendingProps),cp(e,n,o,f,a);case 3:e:{if(be(n,n.stateNode.containerInfo),e===null)throw Error(i(387));o=n.pendingProps;var g=n.memoizedState;f=g.element,Tu(e,n),Fa(n,o,null,a);var v=n.memoizedState;if(o=v.cache,yr(n,kt,o),o!==g.cache&&wu(n,[kt],a,!0),$a(),o=v.element,g.isDehydrated)if(g={element:o,isDehydrated:!1,cache:v.cache},n.updateQueue.baseState=g,n.memoizedState=g,n.flags&256){n=fp(e,n,o,a);break e}else if(o!==f){f=xn(Error(i(424)),n),Ua(f),n=fp(e,n,o,a);break e}else{switch(e=n.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName==="HTML"?e.ownerDocument.body:e}for(ut=kn(e.firstChild),_t=n,$e=!0,pr=null,Sn=!0,a=im(n,null,o,a),n.child=a;a;)a.flags=a.flags&-3|4096,a=a.sibling}else{if(Jr(),o===f){n=Jn(e,n,a);break e}Ut(e,n,o,a)}n=n.child}return n;case 26:return No(e,n),e===null?(a=Eg(n.type,null,n.pendingProps,null))?n.memoizedState=a:$e||(a=n.type,e=n.pendingProps,o=Vo(re.current).createElement(a),o[Ot]=n,o[Pt]=e,Bt(o,a,e),Dt(o),n.stateNode=o):n.memoizedState=Eg(n.type,e.memoizedProps,n.pendingProps,e.memoizedState),null;case 27:return Ae(n),e===null&&$e&&(o=n.stateNode=kg(n.type,n.pendingProps,re.current),_t=n,Sn=!0,f=ut,Mr(n.type)?(Ic=f,ut=kn(o.firstChild)):ut=f),Ut(e,n,n.pendingProps.children,a),No(e,n),e===null&&(n.flags|=4194304),n.child;case 5:return e===null&&$e&&((f=o=ut)&&(o=cS(o,n.type,n.pendingProps,Sn),o!==null?(n.stateNode=o,_t=n,ut=kn(o.firstChild),Sn=!1,f=!0):f=!1),f||gr(n)),Ae(n),f=n.type,g=n.pendingProps,v=e!==null?e.memoizedProps:null,o=g.children,Lc(f,g)?o=null:v!==null&&Lc(f,v)&&(n.flags|=32),n.memoizedState!==null&&(f=_u(e,n,Nv,null,null,a),ci._currentValue=f),No(e,n),Ut(e,n,o,a),n.child;case 6:return e===null&&$e&&((e=a=ut)&&(a=fS(a,n.pendingProps,Sn),a!==null?(n.stateNode=a,_t=n,ut=null,e=!0):e=!1),e||gr(n)),null;case 13:return dp(e,n,a);case 4:return be(n,n.stateNode.containerInfo),o=n.pendingProps,e===null?n.child=ll(n,null,o,a):Ut(e,n,o,a),n.child;case 11:return rp(e,n,n.type,n.pendingProps,a);case 7:return Ut(e,n,n.pendingProps,a),n.child;case 8:return Ut(e,n,n.pendingProps.children,a),n.child;case 12:return Ut(e,n,n.pendingProps.children,a),n.child;case 10:return o=n.pendingProps,yr(n,n.type,o.value),Ut(e,n,o.children,a),n.child;case 9:return f=n.type._context,o=n.pendingProps.children,el(n),f=Lt(f),o=o(f),n.flags|=1,Ut(e,n,o,a),n.child;case 14:return lp(e,n,n.type,n.pendingProps,a);case 15:return ap(e,n,n.type,n.pendingProps,a);case 19:return mp(e,n,a);case 31:return zv(e,n,a);case 22:return ip(e,n,a,n.pendingProps);case 24:return el(n),o=Lt(kt),e===null?(f=Nu(),f===null&&(f=rt,g=ku(),f.pooledCache=g,g.refCount++,g!==null&&(f.pooledCacheLanes|=a),f=g),n.memoizedState={parent:o,cache:f},ju(n),yr(n,kt,f)):((e.lanes&a)!==0&&(Tu(e,n),Fa(n,null,null,a),$a()),f=e.memoizedState,g=n.memoizedState,f.parent!==o?(f={parent:o,cache:o},n.memoizedState=f,n.lanes===0&&(n.memoizedState=n.updateQueue.baseState=f),yr(n,kt,o)):(o=g.cache,yr(n,kt,o),o!==f.cache&&wu(n,[kt],a,!0))),Ut(e,n,n.pendingProps.children,a),n.child;case 29:throw n.pendingProps}throw Error(i(156,n.tag))}function Wn(e){e.flags|=4}function uc(e,n,a,o,f){if((n=(e.mode&32)!==0)&&(n=!1),n){if(e.flags|=16777216,(f&335544128)===f)if(e.stateNode.complete)e.flags|=8192;else if(Vp())e.flags|=8192;else throw rl=uo,Eu}else e.flags&=-16777217}function gp(e,n){if(n.type!=="stylesheet"||(n.state.loading&4)!==0)e.flags&=-16777217;else if(e.flags|=16777216,!Dg(n))if(Vp())e.flags|=8192;else throw rl=uo,Eu}function jo(e,n){n!==null&&(e.flags|=4),e.flags&16384&&(n=e.tag!==22?Qd():536870912,e.lanes|=n,Xl|=n)}function Ka(e,n){if(!$e)switch(e.tailMode){case"hidden":n=e.tail;for(var a=null;n!==null;)n.alternate!==null&&(a=n),n=n.sibling;a===null?e.tail=null:a.sibling=null;break;case"collapsed":a=e.tail;for(var o=null;a!==null;)a.alternate!==null&&(o=a),a=a.sibling;o===null?n||e.tail===null?e.tail=null:e.tail.sibling=null:o.sibling=null}}function ct(e){var n=e.alternate!==null&&e.alternate.child===e.child,a=0,o=0;if(n)for(var f=e.child;f!==null;)a|=f.lanes|f.childLanes,o|=f.subtreeFlags&65011712,o|=f.flags&65011712,f.return=e,f=f.sibling;else for(f=e.child;f!==null;)a|=f.lanes|f.childLanes,o|=f.subtreeFlags,o|=f.flags,f.return=e,f=f.sibling;return e.subtreeFlags|=o,e.childLanes=a,n}function _v(e,n,a){var o=n.pendingProps;switch(yu(n),n.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return ct(n),null;case 1:return ct(n),null;case 3:return a=n.stateNode,o=null,e!==null&&(o=e.memoizedState.cache),n.memoizedState.cache!==o&&(n.flags|=2048),Qn(kt),we(),a.pendingContext&&(a.context=a.pendingContext,a.pendingContext=null),(e===null||e.child===null)&&(_l(n)?Wn(n):e===null||e.memoizedState.isDehydrated&&(n.flags&256)===0||(n.flags|=1024,bu())),ct(n),null;case 26:var f=n.type,g=n.memoizedState;return e===null?(Wn(n),g!==null?(ct(n),gp(n,g)):(ct(n),uc(n,f,null,o,a))):g?g!==e.memoizedState?(Wn(n),ct(n),gp(n,g)):(ct(n),n.flags&=-16777217):(e=e.memoizedProps,e!==o&&Wn(n),ct(n),uc(n,f,e,o,a)),null;case 27:if(dt(n),a=re.current,f=n.type,e!==null&&n.stateNode!=null)e.memoizedProps!==o&&Wn(n);else{if(!o){if(n.stateNode===null)throw Error(i(166));return ct(n),null}e=O.current,_l(n)?Qh(n):(e=kg(f,o,a),n.stateNode=e,Wn(n))}return ct(n),null;case 5:if(dt(n),f=n.type,e!==null&&n.stateNode!=null)e.memoizedProps!==o&&Wn(n);else{if(!o){if(n.stateNode===null)throw Error(i(166));return ct(n),null}if(g=O.current,_l(n))Qh(n);else{var v=Vo(re.current);switch(g){case 1:g=v.createElementNS("http://www.w3.org/2000/svg",f);break;case 2:g=v.createElementNS("http://www.w3.org/1998/Math/MathML",f);break;default:switch(f){case"svg":g=v.createElementNS("http://www.w3.org/2000/svg",f);break;case"math":g=v.createElementNS("http://www.w3.org/1998/Math/MathML",f);break;case"script":g=v.createElement("div"),g.innerHTML="<script><\/script>",g=g.removeChild(g.firstChild);break;case"select":g=typeof o.is=="string"?v.createElement("select",{is:o.is}):v.createElement("select"),o.multiple?g.multiple=!0:o.size&&(g.size=o.size);break;default:g=typeof o.is=="string"?v.createElement(f,{is:o.is}):v.createElement(f)}}g[Ot]=n,g[Pt]=o;e:for(v=n.child;v!==null;){if(v.tag===5||v.tag===6)g.appendChild(v.stateNode);else if(v.tag!==4&&v.tag!==27&&v.child!==null){v.child.return=v,v=v.child;continue}if(v===n)break e;for(;v.sibling===null;){if(v.return===null||v.return===n)break e;v=v.return}v.sibling.return=v.return,v=v.sibling}n.stateNode=g;e:switch(Bt(g,f,o),f){case"button":case"input":case"select":case"textarea":o=!!o.autoFocus;break e;case"img":o=!0;break e;default:o=!1}o&&Wn(n)}}return ct(n),uc(n,n.type,e===null?null:e.memoizedProps,n.pendingProps,a),null;case 6:if(e&&n.stateNode!=null)e.memoizedProps!==o&&Wn(n);else{if(typeof o!="string"&&n.stateNode===null)throw Error(i(166));if(e=re.current,_l(n)){if(e=n.stateNode,a=n.memoizedProps,o=null,f=_t,f!==null)switch(f.tag){case 27:case 5:o=f.memoizedProps}e[Ot]=n,e=!!(e.nodeValue===a||o!==null&&o.suppressHydrationWarning===!0||dg(e.nodeValue,a)),e||gr(n,!0)}else e=Vo(e).createTextNode(o),e[Ot]=n,n.stateNode=e}return ct(n),null;case 31:if(a=n.memoizedState,e===null||e.memoizedState!==null){if(o=_l(n),a!==null){if(e===null){if(!o)throw Error(i(318));if(e=n.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(i(557));e[Ot]=n}else Jr(),(n.flags&128)===0&&(n.memoizedState=null),n.flags|=4;ct(n),e=!1}else a=bu(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),e=!0;if(!e)return n.flags&256?(on(n),n):(on(n),null);if((n.flags&128)!==0)throw Error(i(558))}return ct(n),null;case 13:if(o=n.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(f=_l(n),o!==null&&o.dehydrated!==null){if(e===null){if(!f)throw Error(i(318));if(f=n.memoizedState,f=f!==null?f.dehydrated:null,!f)throw Error(i(317));f[Ot]=n}else Jr(),(n.flags&128)===0&&(n.memoizedState=null),n.flags|=4;ct(n),f=!1}else f=bu(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=f),f=!0;if(!f)return n.flags&256?(on(n),n):(on(n),null)}return on(n),(n.flags&128)!==0?(n.lanes=a,n):(a=o!==null,e=e!==null&&e.memoizedState!==null,a&&(o=n.child,f=null,o.alternate!==null&&o.alternate.memoizedState!==null&&o.alternate.memoizedState.cachePool!==null&&(f=o.alternate.memoizedState.cachePool.pool),g=null,o.memoizedState!==null&&o.memoizedState.cachePool!==null&&(g=o.memoizedState.cachePool.pool),g!==f&&(o.flags|=2048)),a!==e&&a&&(n.child.flags|=8192),jo(n,n.updateQueue),ct(n),null);case 4:return we(),e===null&&Dc(n.stateNode.containerInfo),ct(n),null;case 10:return Qn(n.type),ct(n),null;case 19:if(U(St),o=n.memoizedState,o===null)return ct(n),null;if(f=(n.flags&128)!==0,g=o.rendering,g===null)if(f)Ka(o,!1);else{if(bt!==0||e!==null&&(e.flags&128)!==0)for(e=n.child;e!==null;){if(g=mo(e),g!==null){for(n.flags|=128,Ka(o,!1),e=g.updateQueue,n.updateQueue=e,jo(n,e),n.subtreeFlags=0,e=a,a=n.child;a!==null;)Fh(a,e),a=a.sibling;return E(St,St.current&1|2),$e&&Pn(n,o.treeForkCount),n.child}e=e.sibling}o.tail!==null&&ue()>Ro&&(n.flags|=128,f=!0,Ka(o,!1),n.lanes=4194304)}else{if(!f)if(e=mo(g),e!==null){if(n.flags|=128,f=!0,e=e.updateQueue,n.updateQueue=e,jo(n,e),Ka(o,!0),o.tail===null&&o.tailMode==="hidden"&&!g.alternate&&!$e)return ct(n),null}else 2*ue()-o.renderingStartTime>Ro&&a!==536870912&&(n.flags|=128,f=!0,Ka(o,!1),n.lanes=4194304);o.isBackwards?(g.sibling=n.child,n.child=g):(e=o.last,e!==null?e.sibling=g:n.child=g,o.last=g)}return o.tail!==null?(e=o.tail,o.rendering=e,o.tail=e.sibling,o.renderingStartTime=ue(),e.sibling=null,a=St.current,E(St,f?a&1|2:a&1),$e&&Pn(n,o.treeForkCount),e):(ct(n),null);case 22:case 23:return on(n),Ru(),o=n.memoizedState!==null,e!==null?e.memoizedState!==null!==o&&(n.flags|=8192):o&&(n.flags|=8192),o?(a&536870912)!==0&&(n.flags&128)===0&&(ct(n),n.subtreeFlags&6&&(n.flags|=8192)):ct(n),a=n.updateQueue,a!==null&&jo(n,a.retryQueue),a=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(a=e.memoizedState.cachePool.pool),o=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(o=n.memoizedState.cachePool.pool),o!==a&&(n.flags|=2048),e!==null&&U(tl),null;case 24:return a=null,e!==null&&(a=e.memoizedState.cache),n.memoizedState.cache!==a&&(n.flags|=2048),Qn(kt),ct(n),null;case 25:return null;case 30:return null}throw Error(i(156,n.tag))}function Lv(e,n){switch(yu(n),n.tag){case 1:return e=n.flags,e&65536?(n.flags=e&-65537|128,n):null;case 3:return Qn(kt),we(),e=n.flags,(e&65536)!==0&&(e&128)===0?(n.flags=e&-65537|128,n):null;case 26:case 27:case 5:return dt(n),null;case 31:if(n.memoizedState!==null){if(on(n),n.alternate===null)throw Error(i(340));Jr()}return e=n.flags,e&65536?(n.flags=e&-65537|128,n):null;case 13:if(on(n),e=n.memoizedState,e!==null&&e.dehydrated!==null){if(n.alternate===null)throw Error(i(340));Jr()}return e=n.flags,e&65536?(n.flags=e&-65537|128,n):null;case 19:return U(St),null;case 4:return we(),null;case 10:return Qn(n.type),null;case 22:case 23:return on(n),Ru(),e!==null&&U(tl),e=n.flags,e&65536?(n.flags=e&-65537|128,n):null;case 24:return Qn(kt),null;case 25:return null;default:return null}}function yp(e,n){switch(yu(n),n.tag){case 3:Qn(kt),we();break;case 26:case 27:case 5:dt(n);break;case 4:we();break;case 31:n.memoizedState!==null&&on(n);break;case 13:on(n);break;case 19:U(St);break;case 10:Qn(n.type);break;case 22:case 23:on(n),Ru(),e!==null&&U(tl);break;case 24:Qn(kt)}}function Za(e,n){try{var a=n.updateQueue,o=a!==null?a.lastEffect:null;if(o!==null){var f=o.next;a=f;do{if((a.tag&e)===e){o=void 0;var g=a.create,v=a.inst;o=g(),v.destroy=o}a=a.next}while(a!==f)}}catch(C){We(n,n.return,C)}}function kr(e,n,a){try{var o=n.updateQueue,f=o!==null?o.lastEffect:null;if(f!==null){var g=f.next;o=g;do{if((o.tag&e)===e){var v=o.inst,C=v.destroy;if(C!==void 0){v.destroy=void 0,f=n;var R=a,F=C;try{F()}catch(te){We(f,R,te)}}}o=o.next}while(o!==g)}}catch(te){We(n,n.return,te)}}function xp(e){var n=e.updateQueue;if(n!==null){var a=e.stateNode;try{sm(n,a)}catch(o){We(e,e.return,o)}}}function bp(e,n,a){a.props=il(e.type,e.memoizedProps),a.state=e.memoizedState;try{a.componentWillUnmount()}catch(o){We(e,n,o)}}function Ja(e,n){try{var a=e.ref;if(a!==null){switch(e.tag){case 26:case 27:case 5:var o=e.stateNode;break;case 30:o=e.stateNode;break;default:o=e.stateNode}typeof a=="function"?e.refCleanup=a(o):a.current=o}}catch(f){We(e,n,f)}}function _n(e,n){var a=e.ref,o=e.refCleanup;if(a!==null)if(typeof o=="function")try{o()}catch(f){We(e,n,f)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof a=="function")try{a(null)}catch(f){We(e,n,f)}else a.current=null}function vp(e){var n=e.type,a=e.memoizedProps,o=e.stateNode;try{e:switch(n){case"button":case"input":case"select":case"textarea":a.autoFocus&&o.focus();break e;case"img":a.src?o.src=a.src:a.srcSet&&(o.srcset=a.srcSet)}}catch(f){We(e,e.return,f)}}function cc(e,n,a){try{var o=e.stateNode;lS(o,e.type,a,n),o[Pt]=n}catch(f){We(e,e.return,f)}}function Sp(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Mr(e.type)||e.tag===4}function fc(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Sp(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&Mr(e.type)||e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function dc(e,n,a){var o=e.tag;if(o===5||o===6)e=e.stateNode,n?(a.nodeType===9?a.body:a.nodeName==="HTML"?a.ownerDocument.body:a).insertBefore(e,n):(n=a.nodeType===9?a.body:a.nodeName==="HTML"?a.ownerDocument.body:a,n.appendChild(e),a=a._reactRootContainer,a!=null||n.onclick!==null||(n.onclick=Fn));else if(o!==4&&(o===27&&Mr(e.type)&&(a=e.stateNode,n=null),e=e.child,e!==null))for(dc(e,n,a),e=e.sibling;e!==null;)dc(e,n,a),e=e.sibling}function To(e,n,a){var o=e.tag;if(o===5||o===6)e=e.stateNode,n?a.insertBefore(e,n):a.appendChild(e);else if(o!==4&&(o===27&&Mr(e.type)&&(a=e.stateNode),e=e.child,e!==null))for(To(e,n,a),e=e.sibling;e!==null;)To(e,n,a),e=e.sibling}function wp(e){var n=e.stateNode,a=e.memoizedProps;try{for(var o=e.type,f=n.attributes;f.length;)n.removeAttributeNode(f[0]);Bt(n,o,a),n[Ot]=e,n[Pt]=a}catch(g){We(e,e.return,g)}}var er=!1,Et=!1,hc=!1,kp=typeof WeakSet=="function"?WeakSet:Set,Rt=null;function Uv(e,n){if(e=e.containerInfo,Oc=Qo,e=_h(e),iu(e)){if("selectionStart"in e)var a={start:e.selectionStart,end:e.selectionEnd};else e:{a=(a=e.ownerDocument)&&a.defaultView||window;var o=a.getSelection&&a.getSelection();if(o&&o.rangeCount!==0){a=o.anchorNode;var f=o.anchorOffset,g=o.focusNode;o=o.focusOffset;try{a.nodeType,g.nodeType}catch{a=null;break e}var v=0,C=-1,R=-1,F=0,te=0,ie=e,Y=null;t:for(;;){for(var Z;ie!==a||f!==0&&ie.nodeType!==3||(C=v+f),ie!==g||o!==0&&ie.nodeType!==3||(R=v+o),ie.nodeType===3&&(v+=ie.nodeValue.length),(Z=ie.firstChild)!==null;)Y=ie,ie=Z;for(;;){if(ie===e)break t;if(Y===a&&++F===f&&(C=v),Y===g&&++te===o&&(R=v),(Z=ie.nextSibling)!==null)break;ie=Y,Y=ie.parentNode}ie=Z}a=C===-1||R===-1?null:{start:C,end:R}}else a=null}a=a||{start:0,end:0}}else a=null;for(_c={focusedElem:e,selectionRange:a},Qo=!1,Rt=n;Rt!==null;)if(n=Rt,e=n.child,(n.subtreeFlags&1028)!==0&&e!==null)e.return=n,Rt=e;else for(;Rt!==null;){switch(n=Rt,g=n.alternate,e=n.flags,n.tag){case 0:if((e&4)!==0&&(e=n.updateQueue,e=e!==null?e.events:null,e!==null))for(a=0;a<e.length;a++)f=e[a],f.ref.impl=f.nextImpl;break;case 11:case 15:break;case 1:if((e&1024)!==0&&g!==null){e=void 0,a=n,f=g.memoizedProps,g=g.memoizedState,o=a.stateNode;try{var ge=il(a.type,f);e=o.getSnapshotBeforeUpdate(ge,g),o.__reactInternalSnapshotBeforeUpdate=e}catch(Ee){We(a,a.return,Ee)}}break;case 3:if((e&1024)!==0){if(e=n.stateNode.containerInfo,a=e.nodeType,a===9)Bc(e);else if(a===1)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":Bc(e);break;default:e.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((e&1024)!==0)throw Error(i(163))}if(e=n.sibling,e!==null){e.return=n.return,Rt=e;break}Rt=n.return}}function Cp(e,n,a){var o=a.flags;switch(a.tag){case 0:case 11:case 15:nr(e,a),o&4&&Za(5,a);break;case 1:if(nr(e,a),o&4)if(e=a.stateNode,n===null)try{e.componentDidMount()}catch(v){We(a,a.return,v)}else{var f=il(a.type,n.memoizedProps);n=n.memoizedState;try{e.componentDidUpdate(f,n,e.__reactInternalSnapshotBeforeUpdate)}catch(v){We(a,a.return,v)}}o&64&&xp(a),o&512&&Ja(a,a.return);break;case 3:if(nr(e,a),o&64&&(e=a.updateQueue,e!==null)){if(n=null,a.child!==null)switch(a.child.tag){case 27:case 5:n=a.child.stateNode;break;case 1:n=a.child.stateNode}try{sm(e,n)}catch(v){We(a,a.return,v)}}break;case 27:n===null&&o&4&&wp(a);case 26:case 5:nr(e,a),n===null&&o&4&&vp(a),o&512&&Ja(a,a.return);break;case 12:nr(e,a);break;case 31:nr(e,a),o&4&&jp(e,a);break;case 13:nr(e,a),o&4&&Tp(e,a),o&64&&(e=a.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(a=Gv.bind(null,a),dS(e,a))));break;case 22:if(o=a.memoizedState!==null||er,!o){n=n!==null&&n.memoizedState!==null||Et,f=er;var g=Et;er=o,(Et=n)&&!g?rr(e,a,(a.subtreeFlags&8772)!==0):nr(e,a),er=f,Et=g}break;case 30:break;default:nr(e,a)}}function Np(e){var n=e.alternate;n!==null&&(e.alternate=null,Np(n)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(n=e.stateNode,n!==null&&$s(n)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var pt=null,Qt=!1;function tr(e,n,a){for(a=a.child;a!==null;)Ep(e,n,a),a=a.sibling}function Ep(e,n,a){if(it&&typeof it.onCommitFiberUnmount=="function")try{it.onCommitFiberUnmount(yt,a)}catch{}switch(a.tag){case 26:Et||_n(a,n),tr(e,n,a),a.memoizedState?a.memoizedState.count--:a.stateNode&&(a=a.stateNode,a.parentNode.removeChild(a));break;case 27:Et||_n(a,n);var o=pt,f=Qt;Mr(a.type)&&(pt=a.stateNode,Qt=!1),tr(e,n,a),oi(a.stateNode),pt=o,Qt=f;break;case 5:Et||_n(a,n);case 6:if(o=pt,f=Qt,pt=null,tr(e,n,a),pt=o,Qt=f,pt!==null)if(Qt)try{(pt.nodeType===9?pt.body:pt.nodeName==="HTML"?pt.ownerDocument.body:pt).removeChild(a.stateNode)}catch(g){We(a,n,g)}else try{pt.removeChild(a.stateNode)}catch(g){We(a,n,g)}break;case 18:pt!==null&&(Qt?(e=pt,xg(e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,a.stateNode),na(e)):xg(pt,a.stateNode));break;case 4:o=pt,f=Qt,pt=a.stateNode.containerInfo,Qt=!0,tr(e,n,a),pt=o,Qt=f;break;case 0:case 11:case 14:case 15:kr(2,a,n),Et||kr(4,a,n),tr(e,n,a);break;case 1:Et||(_n(a,n),o=a.stateNode,typeof o.componentWillUnmount=="function"&&bp(a,n,o)),tr(e,n,a);break;case 21:tr(e,n,a);break;case 22:Et=(o=Et)||a.memoizedState!==null,tr(e,n,a),Et=o;break;default:tr(e,n,a)}}function jp(e,n){if(n.memoizedState===null&&(e=n.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{na(e)}catch(a){We(n,n.return,a)}}}function Tp(e,n){if(n.memoizedState===null&&(e=n.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{na(e)}catch(a){We(n,n.return,a)}}function Bv(e){switch(e.tag){case 31:case 13:case 19:var n=e.stateNode;return n===null&&(n=e.stateNode=new kp),n;case 22:return e=e.stateNode,n=e._retryCache,n===null&&(n=e._retryCache=new kp),n;default:throw Error(i(435,e.tag))}}function Ao(e,n){var a=Bv(e);n.forEach(function(o){if(!a.has(o)){a.add(o);var f=Pv.bind(null,e,o);o.then(f,f)}})}function Kt(e,n){var a=n.deletions;if(a!==null)for(var o=0;o<a.length;o++){var f=a[o],g=e,v=n,C=v;e:for(;C!==null;){switch(C.tag){case 27:if(Mr(C.type)){pt=C.stateNode,Qt=!1;break e}break;case 5:pt=C.stateNode,Qt=!1;break e;case 3:case 4:pt=C.stateNode.containerInfo,Qt=!0;break e}C=C.return}if(pt===null)throw Error(i(160));Ep(g,v,f),pt=null,Qt=!1,g=f.alternate,g!==null&&(g.return=null),f.return=null}if(n.subtreeFlags&13886)for(n=n.child;n!==null;)Ap(n,e),n=n.sibling}var An=null;function Ap(e,n){var a=e.alternate,o=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:Kt(n,e),Zt(e),o&4&&(kr(3,e,e.return),Za(3,e),kr(5,e,e.return));break;case 1:Kt(n,e),Zt(e),o&512&&(Et||a===null||_n(a,a.return)),o&64&&er&&(e=e.updateQueue,e!==null&&(o=e.callbacks,o!==null&&(a=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=a===null?o:a.concat(o))));break;case 26:var f=An;if(Kt(n,e),Zt(e),o&512&&(Et||a===null||_n(a,a.return)),o&4){var g=a!==null?a.memoizedState:null;if(o=e.memoizedState,a===null)if(o===null)if(e.stateNode===null){e:{o=e.type,a=e.memoizedProps,f=f.ownerDocument||f;t:switch(o){case"title":g=f.getElementsByTagName("title")[0],(!g||g[Na]||g[Ot]||g.namespaceURI==="http://www.w3.org/2000/svg"||g.hasAttribute("itemprop"))&&(g=f.createElement(o),f.head.insertBefore(g,f.querySelector("head > title"))),Bt(g,o,a),g[Ot]=e,Dt(g),o=g;break e;case"link":var v=Ag("link","href",f).get(o+(a.href||""));if(v){for(var C=0;C<v.length;C++)if(g=v[C],g.getAttribute("href")===(a.href==null||a.href===""?null:a.href)&&g.getAttribute("rel")===(a.rel==null?null:a.rel)&&g.getAttribute("title")===(a.title==null?null:a.title)&&g.getAttribute("crossorigin")===(a.crossOrigin==null?null:a.crossOrigin)){v.splice(C,1);break t}}g=f.createElement(o),Bt(g,o,a),f.head.appendChild(g);break;case"meta":if(v=Ag("meta","content",f).get(o+(a.content||""))){for(C=0;C<v.length;C++)if(g=v[C],g.getAttribute("content")===(a.content==null?null:""+a.content)&&g.getAttribute("name")===(a.name==null?null:a.name)&&g.getAttribute("property")===(a.property==null?null:a.property)&&g.getAttribute("http-equiv")===(a.httpEquiv==null?null:a.httpEquiv)&&g.getAttribute("charset")===(a.charSet==null?null:a.charSet)){v.splice(C,1);break t}}g=f.createElement(o),Bt(g,o,a),f.head.appendChild(g);break;default:throw Error(i(468,o))}g[Ot]=e,Dt(g),o=g}e.stateNode=o}else Mg(f,e.type,e.stateNode);else e.stateNode=Tg(f,o,e.memoizedProps);else g!==o?(g===null?a.stateNode!==null&&(a=a.stateNode,a.parentNode.removeChild(a)):g.count--,o===null?Mg(f,e.type,e.stateNode):Tg(f,o,e.memoizedProps)):o===null&&e.stateNode!==null&&cc(e,e.memoizedProps,a.memoizedProps)}break;case 27:Kt(n,e),Zt(e),o&512&&(Et||a===null||_n(a,a.return)),a!==null&&o&4&&cc(e,e.memoizedProps,a.memoizedProps);break;case 5:if(Kt(n,e),Zt(e),o&512&&(Et||a===null||_n(a,a.return)),e.flags&32){f=e.stateNode;try{Nl(f,"")}catch(ge){We(e,e.return,ge)}}o&4&&e.stateNode!=null&&(f=e.memoizedProps,cc(e,f,a!==null?a.memoizedProps:f)),o&1024&&(hc=!0);break;case 6:if(Kt(n,e),Zt(e),o&4){if(e.stateNode===null)throw Error(i(162));o=e.memoizedProps,a=e.stateNode;try{a.nodeValue=o}catch(ge){We(e,e.return,ge)}}break;case 3:if(Yo=null,f=An,An=$o(n.containerInfo),Kt(n,e),An=f,Zt(e),o&4&&a!==null&&a.memoizedState.isDehydrated)try{na(n.containerInfo)}catch(ge){We(e,e.return,ge)}hc&&(hc=!1,Mp(e));break;case 4:o=An,An=$o(e.stateNode.containerInfo),Kt(n,e),Zt(e),An=o;break;case 12:Kt(n,e),Zt(e);break;case 31:Kt(n,e),Zt(e),o&4&&(o=e.updateQueue,o!==null&&(e.updateQueue=null,Ao(e,o)));break;case 13:Kt(n,e),Zt(e),e.child.flags&8192&&e.memoizedState!==null!=(a!==null&&a.memoizedState!==null)&&(Do=ue()),o&4&&(o=e.updateQueue,o!==null&&(e.updateQueue=null,Ao(e,o)));break;case 22:f=e.memoizedState!==null;var R=a!==null&&a.memoizedState!==null,F=er,te=Et;if(er=F||f,Et=te||R,Kt(n,e),Et=te,er=F,Zt(e),o&8192)e:for(n=e.stateNode,n._visibility=f?n._visibility&-2:n._visibility|1,f&&(a===null||R||er||Et||ol(e)),a=null,n=e;;){if(n.tag===5||n.tag===26){if(a===null){R=a=n;try{if(g=R.stateNode,f)v=g.style,typeof v.setProperty=="function"?v.setProperty("display","none","important"):v.display="none";else{C=R.stateNode;var ie=R.memoizedProps.style,Y=ie!=null&&ie.hasOwnProperty("display")?ie.display:null;C.style.display=Y==null||typeof Y=="boolean"?"":(""+Y).trim()}}catch(ge){We(R,R.return,ge)}}}else if(n.tag===6){if(a===null){R=n;try{R.stateNode.nodeValue=f?"":R.memoizedProps}catch(ge){We(R,R.return,ge)}}}else if(n.tag===18){if(a===null){R=n;try{var Z=R.stateNode;f?bg(Z,!0):bg(R.stateNode,!1)}catch(ge){We(R,R.return,ge)}}}else if((n.tag!==22&&n.tag!==23||n.memoizedState===null||n===e)&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===e)break e;for(;n.sibling===null;){if(n.return===null||n.return===e)break e;a===n&&(a=null),n=n.return}a===n&&(a=null),n.sibling.return=n.return,n=n.sibling}o&4&&(o=e.updateQueue,o!==null&&(a=o.retryQueue,a!==null&&(o.retryQueue=null,Ao(e,a))));break;case 19:Kt(n,e),Zt(e),o&4&&(o=e.updateQueue,o!==null&&(e.updateQueue=null,Ao(e,o)));break;case 30:break;case 21:break;default:Kt(n,e),Zt(e)}}function Zt(e){var n=e.flags;if(n&2){try{for(var a,o=e.return;o!==null;){if(Sp(o)){a=o;break}o=o.return}if(a==null)throw Error(i(160));switch(a.tag){case 27:var f=a.stateNode,g=fc(e);To(e,g,f);break;case 5:var v=a.stateNode;a.flags&32&&(Nl(v,""),a.flags&=-33);var C=fc(e);To(e,C,v);break;case 3:case 4:var R=a.stateNode.containerInfo,F=fc(e);dc(e,F,R);break;default:throw Error(i(161))}}catch(te){We(e,e.return,te)}e.flags&=-3}n&4096&&(e.flags&=-4097)}function Mp(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var n=e;Mp(n),n.tag===5&&n.flags&1024&&n.stateNode.reset(),e=e.sibling}}function nr(e,n){if(n.subtreeFlags&8772)for(n=n.child;n!==null;)Cp(e,n.alternate,n),n=n.sibling}function ol(e){for(e=e.child;e!==null;){var n=e;switch(n.tag){case 0:case 11:case 14:case 15:kr(4,n,n.return),ol(n);break;case 1:_n(n,n.return);var a=n.stateNode;typeof a.componentWillUnmount=="function"&&bp(n,n.return,a),ol(n);break;case 27:oi(n.stateNode);case 26:case 5:_n(n,n.return),ol(n);break;case 22:n.memoizedState===null&&ol(n);break;case 30:ol(n);break;default:ol(n)}e=e.sibling}}function rr(e,n,a){for(a=a&&(n.subtreeFlags&8772)!==0,n=n.child;n!==null;){var o=n.alternate,f=e,g=n,v=g.flags;switch(g.tag){case 0:case 11:case 15:rr(f,g,a),Za(4,g);break;case 1:if(rr(f,g,a),o=g,f=o.stateNode,typeof f.componentDidMount=="function")try{f.componentDidMount()}catch(F){We(o,o.return,F)}if(o=g,f=o.updateQueue,f!==null){var C=o.stateNode;try{var R=f.shared.hiddenCallbacks;if(R!==null)for(f.shared.hiddenCallbacks=null,f=0;f<R.length;f++)om(R[f],C)}catch(F){We(o,o.return,F)}}a&&v&64&&xp(g),Ja(g,g.return);break;case 27:wp(g);case 26:case 5:rr(f,g,a),a&&o===null&&v&4&&vp(g),Ja(g,g.return);break;case 12:rr(f,g,a);break;case 31:rr(f,g,a),a&&v&4&&jp(f,g);break;case 13:rr(f,g,a),a&&v&4&&Tp(f,g);break;case 22:g.memoizedState===null&&rr(f,g,a),Ja(g,g.return);break;case 30:break;default:rr(f,g,a)}n=n.sibling}}function mc(e,n){var a=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(a=e.memoizedState.cachePool.pool),e=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(e=n.memoizedState.cachePool.pool),e!==a&&(e!=null&&e.refCount++,a!=null&&Ba(a))}function pc(e,n){e=null,n.alternate!==null&&(e=n.alternate.memoizedState.cache),n=n.memoizedState.cache,n!==e&&(n.refCount++,e!=null&&Ba(e))}function Mn(e,n,a,o){if(n.subtreeFlags&10256)for(n=n.child;n!==null;)Dp(e,n,a,o),n=n.sibling}function Dp(e,n,a,o){var f=n.flags;switch(n.tag){case 0:case 11:case 15:Mn(e,n,a,o),f&2048&&Za(9,n);break;case 1:Mn(e,n,a,o);break;case 3:Mn(e,n,a,o),f&2048&&(e=null,n.alternate!==null&&(e=n.alternate.memoizedState.cache),n=n.memoizedState.cache,n!==e&&(n.refCount++,e!=null&&Ba(e)));break;case 12:if(f&2048){Mn(e,n,a,o),e=n.stateNode;try{var g=n.memoizedProps,v=g.id,C=g.onPostCommit;typeof C=="function"&&C(v,n.alternate===null?"mount":"update",e.passiveEffectDuration,-0)}catch(R){We(n,n.return,R)}}else Mn(e,n,a,o);break;case 31:Mn(e,n,a,o);break;case 13:Mn(e,n,a,o);break;case 23:break;case 22:g=n.stateNode,v=n.alternate,n.memoizedState!==null?g._visibility&2?Mn(e,n,a,o):Wa(e,n):g._visibility&2?Mn(e,n,a,o):(g._visibility|=2,Yl(e,n,a,o,(n.subtreeFlags&10256)!==0||!1)),f&2048&&mc(v,n);break;case 24:Mn(e,n,a,o),f&2048&&pc(n.alternate,n);break;default:Mn(e,n,a,o)}}function Yl(e,n,a,o,f){for(f=f&&((n.subtreeFlags&10256)!==0||!1),n=n.child;n!==null;){var g=e,v=n,C=a,R=o,F=v.flags;switch(v.tag){case 0:case 11:case 15:Yl(g,v,C,R,f),Za(8,v);break;case 23:break;case 22:var te=v.stateNode;v.memoizedState!==null?te._visibility&2?Yl(g,v,C,R,f):Wa(g,v):(te._visibility|=2,Yl(g,v,C,R,f)),f&&F&2048&&mc(v.alternate,v);break;case 24:Yl(g,v,C,R,f),f&&F&2048&&pc(v.alternate,v);break;default:Yl(g,v,C,R,f)}n=n.sibling}}function Wa(e,n){if(n.subtreeFlags&10256)for(n=n.child;n!==null;){var a=e,o=n,f=o.flags;switch(o.tag){case 22:Wa(a,o),f&2048&&mc(o.alternate,o);break;case 24:Wa(a,o),f&2048&&pc(o.alternate,o);break;default:Wa(a,o)}n=n.sibling}}var ei=8192;function Gl(e,n,a){if(e.subtreeFlags&ei)for(e=e.child;e!==null;)Rp(e,n,a),e=e.sibling}function Rp(e,n,a){switch(e.tag){case 26:Gl(e,n,a),e.flags&ei&&e.memoizedState!==null&&CS(a,An,e.memoizedState,e.memoizedProps);break;case 5:Gl(e,n,a);break;case 3:case 4:var o=An;An=$o(e.stateNode.containerInfo),Gl(e,n,a),An=o;break;case 22:e.memoizedState===null&&(o=e.alternate,o!==null&&o.memoizedState!==null?(o=ei,ei=16777216,Gl(e,n,a),ei=o):Gl(e,n,a));break;default:Gl(e,n,a)}}function zp(e){var n=e.alternate;if(n!==null&&(e=n.child,e!==null)){n.child=null;do n=e.sibling,e.sibling=null,e=n;while(e!==null)}}function ti(e){var n=e.deletions;if((e.flags&16)!==0){if(n!==null)for(var a=0;a<n.length;a++){var o=n[a];Rt=o,_p(o,e)}zp(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Op(e),e=e.sibling}function Op(e){switch(e.tag){case 0:case 11:case 15:ti(e),e.flags&2048&&kr(9,e,e.return);break;case 3:ti(e);break;case 12:ti(e);break;case 22:var n=e.stateNode;e.memoizedState!==null&&n._visibility&2&&(e.return===null||e.return.tag!==13)?(n._visibility&=-3,Mo(e)):ti(e);break;default:ti(e)}}function Mo(e){var n=e.deletions;if((e.flags&16)!==0){if(n!==null)for(var a=0;a<n.length;a++){var o=n[a];Rt=o,_p(o,e)}zp(e)}for(e=e.child;e!==null;){switch(n=e,n.tag){case 0:case 11:case 15:kr(8,n,n.return),Mo(n);break;case 22:a=n.stateNode,a._visibility&2&&(a._visibility&=-3,Mo(n));break;default:Mo(n)}e=e.sibling}}function _p(e,n){for(;Rt!==null;){var a=Rt;switch(a.tag){case 0:case 11:case 15:kr(8,a,n);break;case 23:case 22:if(a.memoizedState!==null&&a.memoizedState.cachePool!==null){var o=a.memoizedState.cachePool.pool;o!=null&&o.refCount++}break;case 24:Ba(a.memoizedState.cache)}if(o=a.child,o!==null)o.return=a,Rt=o;else e:for(a=e;Rt!==null;){o=Rt;var f=o.sibling,g=o.return;if(Np(o),o===a){Rt=null;break e}if(f!==null){f.return=g,Rt=f;break e}Rt=g}}}var Hv={getCacheForType:function(e){var n=Lt(kt),a=n.data.get(e);return a===void 0&&(a=e(),n.data.set(e,a)),a},cacheSignal:function(){return Lt(kt).controller.signal}},qv=typeof WeakMap=="function"?WeakMap:Map,Ke=0,rt=null,Ue=null,qe=0,Je=0,sn=null,Cr=!1,Pl=!1,gc=!1,lr=0,bt=0,Nr=0,sl=0,yc=0,un=0,Xl=0,ni=null,Jt=null,xc=!1,Do=0,Lp=0,Ro=1/0,zo=null,Er=null,At=0,jr=null,Ql=null,ar=0,bc=0,vc=null,Up=null,ri=0,Sc=null;function cn(){return(Ke&2)!==0&&qe!==0?qe&-qe:H.T!==null?jc():Wd()}function Bp(){if(un===0)if((qe&536870912)===0||$e){var e=qi;qi<<=1,(qi&3932160)===0&&(qi=262144),un=e}else un=536870912;return e=an.current,e!==null&&(e.flags|=32),un}function Wt(e,n,a){(e===rt&&(Je===2||Je===9)||e.cancelPendingCommit!==null)&&(Kl(e,0),Tr(e,qe,un,!1)),Ca(e,a),((Ke&2)===0||e!==rt)&&(e===rt&&((Ke&2)===0&&(sl|=a),bt===4&&Tr(e,qe,un,!1)),Ln(e))}function Hp(e,n,a){if((Ke&6)!==0)throw Error(i(327));var o=!a&&(n&127)===0&&(n&e.expiredLanes)===0||ka(e,n),f=o?$v(e,n):kc(e,n,!0),g=o;do{if(f===0){Pl&&!o&&Tr(e,n,0,!1);break}else{if(a=e.current.alternate,g&&!Iv(a)){f=kc(e,n,!1),g=!1;continue}if(f===2){if(g=n,e.errorRecoveryDisabledLanes&g)var v=0;else v=e.pendingLanes&-536870913,v=v!==0?v:v&536870912?536870912:0;if(v!==0){n=v;e:{var C=e;f=ni;var R=C.current.memoizedState.isDehydrated;if(R&&(Kl(C,v).flags|=256),v=kc(C,v,!1),v!==2){if(gc&&!R){C.errorRecoveryDisabledLanes|=g,sl|=g,f=4;break e}g=Jt,Jt=f,g!==null&&(Jt===null?Jt=g:Jt.push.apply(Jt,g))}f=v}if(g=!1,f!==2)continue}}if(f===1){Kl(e,0),Tr(e,n,0,!0);break}e:{switch(o=e,g=f,g){case 0:case 1:throw Error(i(345));case 4:if((n&4194048)!==n)break;case 6:Tr(o,n,un,!Cr);break e;case 2:Jt=null;break;case 3:case 5:break;default:throw Error(i(329))}if((n&62914560)===n&&(f=Do+300-ue(),10<f)){if(Tr(o,n,un,!Cr),Vi(o,0,!0)!==0)break e;ar=n,o.timeoutHandle=gg(qp.bind(null,o,a,Jt,zo,xc,n,un,sl,Xl,Cr,g,"Throttled",-0,0),f);break e}qp(o,a,Jt,zo,xc,n,un,sl,Xl,Cr,g,null,-0,0)}}break}while(!0);Ln(e)}function qp(e,n,a,o,f,g,v,C,R,F,te,ie,Y,Z){if(e.timeoutHandle=-1,ie=n.subtreeFlags,ie&8192||(ie&16785408)===16785408){ie={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Fn},Rp(n,g,ie);var ge=(g&62914560)===g?Do-ue():(g&4194048)===g?Lp-ue():0;if(ge=NS(ie,ge),ge!==null){ar=g,e.cancelPendingCommit=ge(Xp.bind(null,e,n,g,a,o,f,v,C,R,te,ie,null,Y,Z)),Tr(e,g,v,!F);return}}Xp(e,n,g,a,o,f,v,C,R)}function Iv(e){for(var n=e;;){var a=n.tag;if((a===0||a===11||a===15)&&n.flags&16384&&(a=n.updateQueue,a!==null&&(a=a.stores,a!==null)))for(var o=0;o<a.length;o++){var f=a[o],g=f.getSnapshot;f=f.value;try{if(!rn(g(),f))return!1}catch{return!1}}if(a=n.child,n.subtreeFlags&16384&&a!==null)a.return=n,n=a;else{if(n===e)break;for(;n.sibling===null;){if(n.return===null||n.return===e)return!0;n=n.return}n.sibling.return=n.return,n=n.sibling}}return!0}function Tr(e,n,a,o){n&=~yc,n&=~sl,e.suspendedLanes|=n,e.pingedLanes&=~n,o&&(e.warmLanes|=n),o=e.expirationTimes;for(var f=n;0<f;){var g=31-Ze(f),v=1<<g;o[g]=-1,f&=~v}a!==0&&Kd(e,a,n)}function Oo(){return(Ke&6)===0?(li(0),!1):!0}function wc(){if(Ue!==null){if(Je===0)var e=Ue.return;else e=Ue,Xn=Wr=null,Bu(e),ql=null,qa=0,e=Ue;for(;e!==null;)yp(e.alternate,e),e=e.return;Ue=null}}function Kl(e,n){var a=e.timeoutHandle;a!==-1&&(e.timeoutHandle=-1,oS(a)),a=e.cancelPendingCommit,a!==null&&(e.cancelPendingCommit=null,a()),ar=0,wc(),rt=e,Ue=a=Gn(e.current,null),qe=n,Je=0,sn=null,Cr=!1,Pl=ka(e,n),gc=!1,Xl=un=yc=sl=Nr=bt=0,Jt=ni=null,xc=!1,(n&8)!==0&&(n|=n&32);var o=e.entangledLanes;if(o!==0)for(e=e.entanglements,o&=n;0<o;){var f=31-Ze(o),g=1<<f;n|=e[f],o&=~g}return lr=n,eo(),a}function Ip(e,n){Re=null,H.H=Xa,n===Hl||n===so?(n=rm(),Je=3):n===Eu?(n=rm(),Je=4):Je=n===ec?8:n!==null&&typeof n=="object"&&typeof n.then=="function"?6:1,sn=n,Ue===null&&(bt=1,ko(e,xn(n,e.current)))}function Vp(){var e=an.current;return e===null?!0:(qe&4194048)===qe?wn===null:(qe&62914560)===qe||(qe&536870912)!==0?e===wn:!1}function $p(){var e=H.H;return H.H=Xa,e===null?Xa:e}function Fp(){var e=H.A;return H.A=Hv,e}function _o(){bt=4,Cr||(qe&4194048)!==qe&&an.current!==null||(Pl=!0),(Nr&134217727)===0&&(sl&134217727)===0||rt===null||Tr(rt,qe,un,!1)}function kc(e,n,a){var o=Ke;Ke|=2;var f=$p(),g=Fp();(rt!==e||qe!==n)&&(zo=null,Kl(e,n)),n=!1;var v=bt;e:do try{if(Je!==0&&Ue!==null){var C=Ue,R=sn;switch(Je){case 8:wc(),v=6;break e;case 3:case 2:case 9:case 6:an.current===null&&(n=!0);var F=Je;if(Je=0,sn=null,Zl(e,C,R,F),a&&Pl){v=0;break e}break;default:F=Je,Je=0,sn=null,Zl(e,C,R,F)}}Vv(),v=bt;break}catch(te){Ip(e,te)}while(!0);return n&&e.shellSuspendCounter++,Xn=Wr=null,Ke=o,H.H=f,H.A=g,Ue===null&&(rt=null,qe=0,eo()),v}function Vv(){for(;Ue!==null;)Yp(Ue)}function $v(e,n){var a=Ke;Ke|=2;var o=$p(),f=Fp();rt!==e||qe!==n?(zo=null,Ro=ue()+500,Kl(e,n)):Pl=ka(e,n);e:do try{if(Je!==0&&Ue!==null){n=Ue;var g=sn;t:switch(Je){case 1:Je=0,sn=null,Zl(e,n,g,1);break;case 2:case 9:if(tm(g)){Je=0,sn=null,Gp(n);break}n=function(){Je!==2&&Je!==9||rt!==e||(Je=7),Ln(e)},g.then(n,n);break e;case 3:Je=7;break e;case 4:Je=5;break e;case 7:tm(g)?(Je=0,sn=null,Gp(n)):(Je=0,sn=null,Zl(e,n,g,7));break;case 5:var v=null;switch(Ue.tag){case 26:v=Ue.memoizedState;case 5:case 27:var C=Ue;if(v?Dg(v):C.stateNode.complete){Je=0,sn=null;var R=C.sibling;if(R!==null)Ue=R;else{var F=C.return;F!==null?(Ue=F,Lo(F)):Ue=null}break t}}Je=0,sn=null,Zl(e,n,g,5);break;case 6:Je=0,sn=null,Zl(e,n,g,6);break;case 8:wc(),bt=6;break e;default:throw Error(i(462))}}Fv();break}catch(te){Ip(e,te)}while(!0);return Xn=Wr=null,H.H=o,H.A=f,Ke=a,Ue!==null?0:(rt=null,qe=0,eo(),bt)}function Fv(){for(;Ue!==null&&!wa();)Yp(Ue)}function Yp(e){var n=pp(e.alternate,e,lr);e.memoizedProps=e.pendingProps,n===null?Lo(e):Ue=n}function Gp(e){var n=e,a=n.alternate;switch(n.tag){case 15:case 0:n=up(a,n,n.pendingProps,n.type,void 0,qe);break;case 11:n=up(a,n,n.pendingProps,n.type.render,n.ref,qe);break;case 5:Bu(n);default:yp(a,n),n=Ue=Fh(n,lr),n=pp(a,n,lr)}e.memoizedProps=e.pendingProps,n===null?Lo(e):Ue=n}function Zl(e,n,a,o){Xn=Wr=null,Bu(n),ql=null,qa=0;var f=n.return;try{if(Rv(e,f,n,a,qe)){bt=1,ko(e,xn(a,e.current)),Ue=null;return}}catch(g){if(f!==null)throw Ue=f,g;bt=1,ko(e,xn(a,e.current)),Ue=null;return}n.flags&32768?($e||o===1?e=!0:Pl||(qe&536870912)!==0?e=!1:(Cr=e=!0,(o===2||o===9||o===3||o===6)&&(o=an.current,o!==null&&o.tag===13&&(o.flags|=16384))),Pp(n,e)):Lo(n)}function Lo(e){var n=e;do{if((n.flags&32768)!==0){Pp(n,Cr);return}e=n.return;var a=_v(n.alternate,n,lr);if(a!==null){Ue=a;return}if(n=n.sibling,n!==null){Ue=n;return}Ue=n=e}while(n!==null);bt===0&&(bt=5)}function Pp(e,n){do{var a=Lv(e.alternate,e);if(a!==null){a.flags&=32767,Ue=a;return}if(a=e.return,a!==null&&(a.flags|=32768,a.subtreeFlags=0,a.deletions=null),!n&&(e=e.sibling,e!==null)){Ue=e;return}Ue=e=a}while(e!==null);bt=6,Ue=null}function Xp(e,n,a,o,f,g,v,C,R){e.cancelPendingCommit=null;do Uo();while(At!==0);if((Ke&6)!==0)throw Error(i(327));if(n!==null){if(n===e.current)throw Error(i(177));if(g=n.lanes|n.childLanes,g|=fu,kb(e,a,g,v,C,R),e===rt&&(Ue=rt=null,qe=0),Ql=n,jr=e,ar=a,bc=g,vc=f,Up=o,(n.subtreeFlags&10256)!==0||(n.flags&10256)!==0?(e.callbackNode=null,e.callbackPriority=0,Xv(ke,function(){return Wp(),null})):(e.callbackNode=null,e.callbackPriority=0),o=(n.flags&13878)!==0,(n.subtreeFlags&13878)!==0||o){o=H.T,H.T=null,f=ne.p,ne.p=2,v=Ke,Ke|=4;try{Uv(e,n,a)}finally{Ke=v,ne.p=f,H.T=o}}At=1,Qp(),Kp(),Zp()}}function Qp(){if(At===1){At=0;var e=jr,n=Ql,a=(n.flags&13878)!==0;if((n.subtreeFlags&13878)!==0||a){a=H.T,H.T=null;var o=ne.p;ne.p=2;var f=Ke;Ke|=4;try{Ap(n,e);var g=_c,v=_h(e.containerInfo),C=g.focusedElem,R=g.selectionRange;if(v!==C&&C&&C.ownerDocument&&Oh(C.ownerDocument.documentElement,C)){if(R!==null&&iu(C)){var F=R.start,te=R.end;if(te===void 0&&(te=F),"selectionStart"in C)C.selectionStart=F,C.selectionEnd=Math.min(te,C.value.length);else{var ie=C.ownerDocument||document,Y=ie&&ie.defaultView||window;if(Y.getSelection){var Z=Y.getSelection(),ge=C.textContent.length,Ee=Math.min(R.start,ge),nt=R.end===void 0?Ee:Math.min(R.end,ge);!Z.extend&&Ee>nt&&(v=nt,nt=Ee,Ee=v);var q=zh(C,Ee),_=zh(C,nt);if(q&&_&&(Z.rangeCount!==1||Z.anchorNode!==q.node||Z.anchorOffset!==q.offset||Z.focusNode!==_.node||Z.focusOffset!==_.offset)){var $=ie.createRange();$.setStart(q.node,q.offset),Z.removeAllRanges(),Ee>nt?(Z.addRange($),Z.extend(_.node,_.offset)):($.setEnd(_.node,_.offset),Z.addRange($))}}}}for(ie=[],Z=C;Z=Z.parentNode;)Z.nodeType===1&&ie.push({element:Z,left:Z.scrollLeft,top:Z.scrollTop});for(typeof C.focus=="function"&&C.focus(),C=0;C<ie.length;C++){var le=ie[C];le.element.scrollLeft=le.left,le.element.scrollTop=le.top}}Qo=!!Oc,_c=Oc=null}finally{Ke=f,ne.p=o,H.T=a}}e.current=n,At=2}}function Kp(){if(At===2){At=0;var e=jr,n=Ql,a=(n.flags&8772)!==0;if((n.subtreeFlags&8772)!==0||a){a=H.T,H.T=null;var o=ne.p;ne.p=2;var f=Ke;Ke|=4;try{Cp(e,n.alternate,n)}finally{Ke=f,ne.p=o,H.T=a}}At=3}}function Zp(){if(At===4||At===3){At=0,xl();var e=jr,n=Ql,a=ar,o=Up;(n.subtreeFlags&10256)!==0||(n.flags&10256)!==0?At=5:(At=0,Ql=jr=null,Jp(e,e.pendingLanes));var f=e.pendingLanes;if(f===0&&(Er=null),Is(a),n=n.stateNode,it&&typeof it.onCommitFiberRoot=="function")try{it.onCommitFiberRoot(yt,n,void 0,(n.current.flags&128)===128)}catch{}if(o!==null){n=H.T,f=ne.p,ne.p=2,H.T=null;try{for(var g=e.onRecoverableError,v=0;v<o.length;v++){var C=o[v];g(C.value,{componentStack:C.stack})}}finally{H.T=n,ne.p=f}}(ar&3)!==0&&Uo(),Ln(e),f=e.pendingLanes,(a&261930)!==0&&(f&42)!==0?e===Sc?ri++:(ri=0,Sc=e):ri=0,li(0)}}function Jp(e,n){(e.pooledCacheLanes&=n)===0&&(n=e.pooledCache,n!=null&&(e.pooledCache=null,Ba(n)))}function Uo(){return Qp(),Kp(),Zp(),Wp()}function Wp(){if(At!==5)return!1;var e=jr,n=bc;bc=0;var a=Is(ar),o=H.T,f=ne.p;try{ne.p=32>a?32:a,H.T=null,a=vc,vc=null;var g=jr,v=ar;if(At=0,Ql=jr=null,ar=0,(Ke&6)!==0)throw Error(i(331));var C=Ke;if(Ke|=4,Op(g.current),Dp(g,g.current,v,a),Ke=C,li(0,!1),it&&typeof it.onPostCommitFiberRoot=="function")try{it.onPostCommitFiberRoot(yt,g)}catch{}return!0}finally{ne.p=f,H.T=o,Jp(e,n)}}function eg(e,n,a){n=xn(a,n),n=Wu(e.stateNode,n,2),e=vr(e,n,2),e!==null&&(Ca(e,2),Ln(e))}function We(e,n,a){if(e.tag===3)eg(e,e,a);else for(;n!==null;){if(n.tag===3){eg(n,e,a);break}else if(n.tag===1){var o=n.stateNode;if(typeof n.type.getDerivedStateFromError=="function"||typeof o.componentDidCatch=="function"&&(Er===null||!Er.has(o))){e=xn(a,e),a=tp(2),o=vr(n,a,2),o!==null&&(np(a,o,n,e),Ca(o,2),Ln(o));break}}n=n.return}}function Cc(e,n,a){var o=e.pingCache;if(o===null){o=e.pingCache=new qv;var f=new Set;o.set(n,f)}else f=o.get(n),f===void 0&&(f=new Set,o.set(n,f));f.has(a)||(gc=!0,f.add(a),e=Yv.bind(null,e,n,a),n.then(e,e))}function Yv(e,n,a){var o=e.pingCache;o!==null&&o.delete(n),e.pingedLanes|=e.suspendedLanes&a,e.warmLanes&=~a,rt===e&&(qe&a)===a&&(bt===4||bt===3&&(qe&62914560)===qe&&300>ue()-Do?(Ke&2)===0&&Kl(e,0):yc|=a,Xl===qe&&(Xl=0)),Ln(e)}function tg(e,n){n===0&&(n=Qd()),e=Kr(e,n),e!==null&&(Ca(e,n),Ln(e))}function Gv(e){var n=e.memoizedState,a=0;n!==null&&(a=n.retryLane),tg(e,a)}function Pv(e,n){var a=0;switch(e.tag){case 31:case 13:var o=e.stateNode,f=e.memoizedState;f!==null&&(a=f.retryLane);break;case 19:o=e.stateNode;break;case 22:o=e.stateNode._retryCache;break;default:throw Error(i(314))}o!==null&&o.delete(n),tg(e,a)}function Xv(e,n){return Ft(e,n)}var Bo=null,Jl=null,Nc=!1,Ho=!1,Ec=!1,Ar=0;function Ln(e){e!==Jl&&e.next===null&&(Jl===null?Bo=Jl=e:Jl=Jl.next=e),Ho=!0,Nc||(Nc=!0,Kv())}function li(e,n){if(!Ec&&Ho){Ec=!0;do for(var a=!1,o=Bo;o!==null;){if(e!==0){var f=o.pendingLanes;if(f===0)var g=0;else{var v=o.suspendedLanes,C=o.pingedLanes;g=(1<<31-Ze(42|e)+1)-1,g&=f&~(v&~C),g=g&201326741?g&201326741|1:g?g|2:0}g!==0&&(a=!0,ag(o,g))}else g=qe,g=Vi(o,o===rt?g:0,o.cancelPendingCommit!==null||o.timeoutHandle!==-1),(g&3)===0||ka(o,g)||(a=!0,ag(o,g));o=o.next}while(a);Ec=!1}}function Qv(){ng()}function ng(){Ho=Nc=!1;var e=0;Ar!==0&&iS()&&(e=Ar);for(var n=ue(),a=null,o=Bo;o!==null;){var f=o.next,g=rg(o,n);g===0?(o.next=null,a===null?Bo=f:a.next=f,f===null&&(Jl=a)):(a=o,(e!==0||(g&3)!==0)&&(Ho=!0)),o=f}At!==0&&At!==5||li(e),Ar!==0&&(Ar=0)}function rg(e,n){for(var a=e.suspendedLanes,o=e.pingedLanes,f=e.expirationTimes,g=e.pendingLanes&-62914561;0<g;){var v=31-Ze(g),C=1<<v,R=f[v];R===-1?((C&a)===0||(C&o)!==0)&&(f[v]=wb(C,n)):R<=n&&(e.expiredLanes|=C),g&=~C}if(n=rt,a=qe,a=Vi(e,e===n?a:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),o=e.callbackNode,a===0||e===n&&(Je===2||Je===9)||e.cancelPendingCommit!==null)return o!==null&&o!==null&&cr(o),e.callbackNode=null,e.callbackPriority=0;if((a&3)===0||ka(e,a)){if(n=a&-a,n===e.callbackPriority)return n;switch(o!==null&&cr(o),Is(a)){case 2:case 8:a=fe;break;case 32:a=ke;break;case 268435456:a=Fe;break;default:a=ke}return o=lg.bind(null,e),a=Ft(a,o),e.callbackPriority=n,e.callbackNode=a,n}return o!==null&&o!==null&&cr(o),e.callbackPriority=2,e.callbackNode=null,2}function lg(e,n){if(At!==0&&At!==5)return e.callbackNode=null,e.callbackPriority=0,null;var a=e.callbackNode;if(Uo()&&e.callbackNode!==a)return null;var o=qe;return o=Vi(e,e===rt?o:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),o===0?null:(Hp(e,o,n),rg(e,ue()),e.callbackNode!=null&&e.callbackNode===a?lg.bind(null,e):null)}function ag(e,n){if(Uo())return null;Hp(e,n,!0)}function Kv(){sS(function(){(Ke&6)!==0?Ft(K,Qv):ng()})}function jc(){if(Ar===0){var e=Ul;e===0&&(e=Hi,Hi<<=1,(Hi&261888)===0&&(Hi=256)),Ar=e}return Ar}function ig(e){return e==null||typeof e=="symbol"||typeof e=="boolean"?null:typeof e=="function"?e:Gi(""+e)}function og(e,n){var a=n.ownerDocument.createElement("input");return a.name=n.name,a.value=n.value,e.id&&a.setAttribute("form",e.id),n.parentNode.insertBefore(a,n),e=new FormData(e),a.parentNode.removeChild(a),e}function Zv(e,n,a,o,f){if(n==="submit"&&a&&a.stateNode===f){var g=ig((f[Pt]||null).action),v=o.submitter;v&&(n=(n=v[Pt]||null)?ig(n.formAction):v.getAttribute("formAction"),n!==null&&(g=n,v=null));var C=new Ki("action","action",null,o,f);e.push({event:C,listeners:[{instance:null,listener:function(){if(o.defaultPrevented){if(Ar!==0){var R=v?og(f,v):new FormData(f);Pu(a,{pending:!0,data:R,method:f.method,action:g},null,R)}}else typeof g=="function"&&(C.preventDefault(),R=v?og(f,v):new FormData(f),Pu(a,{pending:!0,data:R,method:f.method,action:g},g,R))},currentTarget:f}]})}}for(var Tc=0;Tc<cu.length;Tc++){var Ac=cu[Tc],Jv=Ac.toLowerCase(),Wv=Ac[0].toUpperCase()+Ac.slice(1);Tn(Jv,"on"+Wv)}Tn(Bh,"onAnimationEnd"),Tn(Hh,"onAnimationIteration"),Tn(qh,"onAnimationStart"),Tn("dblclick","onDoubleClick"),Tn("focusin","onFocus"),Tn("focusout","onBlur"),Tn(pv,"onTransitionRun"),Tn(gv,"onTransitionStart"),Tn(yv,"onTransitionCancel"),Tn(Ih,"onTransitionEnd"),kl("onMouseEnter",["mouseout","mouseover"]),kl("onMouseLeave",["mouseout","mouseover"]),kl("onPointerEnter",["pointerout","pointerover"]),kl("onPointerLeave",["pointerout","pointerover"]),Gr("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Gr("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Gr("onBeforeInput",["compositionend","keypress","textInput","paste"]),Gr("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Gr("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Gr("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var ai="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(" "),eS=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(ai));function sg(e,n){n=(n&4)!==0;for(var a=0;a<e.length;a++){var o=e[a],f=o.event;o=o.listeners;e:{var g=void 0;if(n)for(var v=o.length-1;0<=v;v--){var C=o[v],R=C.instance,F=C.currentTarget;if(C=C.listener,R!==g&&f.isPropagationStopped())break e;g=C,f.currentTarget=F;try{g(f)}catch(te){Wi(te)}f.currentTarget=null,g=R}else for(v=0;v<o.length;v++){if(C=o[v],R=C.instance,F=C.currentTarget,C=C.listener,R!==g&&f.isPropagationStopped())break e;g=C,f.currentTarget=F;try{g(f)}catch(te){Wi(te)}f.currentTarget=null,g=R}}}}function Be(e,n){var a=n[Vs];a===void 0&&(a=n[Vs]=new Set);var o=e+"__bubble";a.has(o)||(ug(n,e,2,!1),a.add(o))}function Mc(e,n,a){var o=0;n&&(o|=4),ug(a,e,o,n)}var qo="_reactListening"+Math.random().toString(36).slice(2);function Dc(e){if(!e[qo]){e[qo]=!0,nh.forEach(function(a){a!=="selectionchange"&&(eS.has(a)||Mc(a,!1,e),Mc(a,!0,e))});var n=e.nodeType===9?e:e.ownerDocument;n===null||n[qo]||(n[qo]=!0,Mc("selectionchange",!1,n))}}function ug(e,n,a,o){switch(Bg(n)){case 2:var f=TS;break;case 8:f=AS;break;default:f=Gc}a=f.bind(null,n,a,e),f=void 0,!Zs||n!=="touchstart"&&n!=="touchmove"&&n!=="wheel"||(f=!0),o?f!==void 0?e.addEventListener(n,a,{capture:!0,passive:f}):e.addEventListener(n,a,!0):f!==void 0?e.addEventListener(n,a,{passive:f}):e.addEventListener(n,a,!1)}function Rc(e,n,a,o,f){var g=o;if((n&1)===0&&(n&2)===0&&o!==null)e:for(;;){if(o===null)return;var v=o.tag;if(v===3||v===4){var C=o.stateNode.containerInfo;if(C===f)break;if(v===4)for(v=o.return;v!==null;){var R=v.tag;if((R===3||R===4)&&v.stateNode.containerInfo===f)return;v=v.return}for(;C!==null;){if(v=vl(C),v===null)return;if(R=v.tag,R===5||R===6||R===26||R===27){o=g=v;continue e}C=C.parentNode}}o=o.return}mh(function(){var F=g,te=Qs(a),ie=[];e:{var Y=Vh.get(e);if(Y!==void 0){var Z=Ki,ge=e;switch(e){case"keypress":if(Xi(a)===0)break e;case"keydown":case"keyup":Z=Pb;break;case"focusin":ge="focus",Z=tu;break;case"focusout":ge="blur",Z=tu;break;case"beforeblur":case"afterblur":Z=tu;break;case"click":if(a.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":Z=yh;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":Z=_b;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":Z=Kb;break;case Bh:case Hh:case qh:Z=Bb;break;case Ih:Z=Jb;break;case"scroll":case"scrollend":Z=zb;break;case"wheel":Z=ev;break;case"copy":case"cut":case"paste":Z=qb;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":Z=bh;break;case"toggle":case"beforetoggle":Z=nv}var Ee=(n&4)!==0,nt=!Ee&&(e==="scroll"||e==="scrollend"),q=Ee?Y!==null?Y+"Capture":null:Y;Ee=[];for(var _=F,$;_!==null;){var le=_;if($=le.stateNode,le=le.tag,le!==5&&le!==26&&le!==27||$===null||q===null||(le=ja(_,q),le!=null&&Ee.push(ii(_,le,$))),nt)break;_=_.return}0<Ee.length&&(Y=new Z(Y,ge,null,a,te),ie.push({event:Y,listeners:Ee}))}}if((n&7)===0){e:{if(Y=e==="mouseover"||e==="pointerover",Z=e==="mouseout"||e==="pointerout",Y&&a!==Xs&&(ge=a.relatedTarget||a.fromElement)&&(vl(ge)||ge[bl]))break e;if((Z||Y)&&(Y=te.window===te?te:(Y=te.ownerDocument)?Y.defaultView||Y.parentWindow:window,Z?(ge=a.relatedTarget||a.toElement,Z=F,ge=ge?vl(ge):null,ge!==null&&(nt=u(ge),Ee=ge.tag,ge!==nt||Ee!==5&&Ee!==27&&Ee!==6)&&(ge=null)):(Z=null,ge=F),Z!==ge)){if(Ee=yh,le="onMouseLeave",q="onMouseEnter",_="mouse",(e==="pointerout"||e==="pointerover")&&(Ee=bh,le="onPointerLeave",q="onPointerEnter",_="pointer"),nt=Z==null?Y:Ea(Z),$=ge==null?Y:Ea(ge),Y=new Ee(le,_+"leave",Z,a,te),Y.target=nt,Y.relatedTarget=$,le=null,vl(te)===F&&(Ee=new Ee(q,_+"enter",ge,a,te),Ee.target=$,Ee.relatedTarget=nt,le=Ee),nt=le,Z&&ge)t:{for(Ee=tS,q=Z,_=ge,$=0,le=q;le;le=Ee(le))$++;le=0;for(var Se=_;Se;Se=Ee(Se))le++;for(;0<$-le;)q=Ee(q),$--;for(;0<le-$;)_=Ee(_),le--;for(;$--;){if(q===_||_!==null&&q===_.alternate){Ee=q;break t}q=Ee(q),_=Ee(_)}Ee=null}else Ee=null;Z!==null&&cg(ie,Y,Z,Ee,!1),ge!==null&&nt!==null&&cg(ie,nt,ge,Ee,!0)}}e:{if(Y=F?Ea(F):window,Z=Y.nodeName&&Y.nodeName.toLowerCase(),Z==="select"||Z==="input"&&Y.type==="file")var Xe=jh;else if(Nh(Y))if(Th)Xe=dv;else{Xe=cv;var ve=uv}else Z=Y.nodeName,!Z||Z.toLowerCase()!=="input"||Y.type!=="checkbox"&&Y.type!=="radio"?F&&Ps(F.elementType)&&(Xe=jh):Xe=fv;if(Xe&&(Xe=Xe(e,F))){Eh(ie,Xe,a,te);break e}ve&&ve(e,Y,F),e==="focusout"&&F&&Y.type==="number"&&F.memoizedProps.value!=null&&Gs(Y,"number",Y.value)}switch(ve=F?Ea(F):window,e){case"focusin":(Nh(ve)||ve.contentEditable==="true")&&(Al=ve,ou=F,_a=null);break;case"focusout":_a=ou=Al=null;break;case"mousedown":su=!0;break;case"contextmenu":case"mouseup":case"dragend":su=!1,Lh(ie,a,te);break;case"selectionchange":if(mv)break;case"keydown":case"keyup":Lh(ie,a,te)}var Oe;if(ru)e:{switch(e){case"compositionstart":var Ie="onCompositionStart";break e;case"compositionend":Ie="onCompositionEnd";break e;case"compositionupdate":Ie="onCompositionUpdate";break e}Ie=void 0}else Tl?kh(e,a)&&(Ie="onCompositionEnd"):e==="keydown"&&a.keyCode===229&&(Ie="onCompositionStart");Ie&&(vh&&a.locale!=="ko"&&(Tl||Ie!=="onCompositionStart"?Ie==="onCompositionEnd"&&Tl&&(Oe=ph()):(hr=te,Js="value"in hr?hr.value:hr.textContent,Tl=!0)),ve=Io(F,Ie),0<ve.length&&(Ie=new xh(Ie,e,null,a,te),ie.push({event:Ie,listeners:ve}),Oe?Ie.data=Oe:(Oe=Ch(a),Oe!==null&&(Ie.data=Oe)))),(Oe=lv?av(e,a):iv(e,a))&&(Ie=Io(F,"onBeforeInput"),0<Ie.length&&(ve=new xh("onBeforeInput","beforeinput",null,a,te),ie.push({event:ve,listeners:Ie}),ve.data=Oe)),Zv(ie,e,F,a,te)}sg(ie,n)})}function ii(e,n,a){return{instance:e,listener:n,currentTarget:a}}function Io(e,n){for(var a=n+"Capture",o=[];e!==null;){var f=e,g=f.stateNode;if(f=f.tag,f!==5&&f!==26&&f!==27||g===null||(f=ja(e,a),f!=null&&o.unshift(ii(e,f,g)),f=ja(e,n),f!=null&&o.push(ii(e,f,g))),e.tag===3)return o;e=e.return}return[]}function tS(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function cg(e,n,a,o,f){for(var g=n._reactName,v=[];a!==null&&a!==o;){var C=a,R=C.alternate,F=C.stateNode;if(C=C.tag,R!==null&&R===o)break;C!==5&&C!==26&&C!==27||F===null||(R=F,f?(F=ja(a,g),F!=null&&v.unshift(ii(a,F,R))):f||(F=ja(a,g),F!=null&&v.push(ii(a,F,R)))),a=a.return}v.length!==0&&e.push({event:n,listeners:v})}var nS=/\r\n?/g,rS=/\u0000|\uFFFD/g;function fg(e){return(typeof e=="string"?e:""+e).replace(nS,`
|
|
49
|
-
`).replace(rS,"")}function dg(e,n){return n=fg(n),fg(e)===n}function tt(e,n,a,o,f,g){switch(a){case"children":typeof o=="string"?n==="body"||n==="textarea"&&o===""||Nl(e,o):(typeof o=="number"||typeof o=="bigint")&&n!=="body"&&Nl(e,""+o);break;case"className":Fi(e,"class",o);break;case"tabIndex":Fi(e,"tabindex",o);break;case"dir":case"role":case"viewBox":case"width":case"height":Fi(e,a,o);break;case"style":dh(e,o,g);break;case"data":if(n!=="object"){Fi(e,"data",o);break}case"src":case"href":if(o===""&&(n!=="a"||a!=="href")){e.removeAttribute(a);break}if(o==null||typeof o=="function"||typeof o=="symbol"||typeof o=="boolean"){e.removeAttribute(a);break}o=Gi(""+o),e.setAttribute(a,o);break;case"action":case"formAction":if(typeof o=="function"){e.setAttribute(a,"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 g=="function"&&(a==="formAction"?(n!=="input"&&tt(e,n,"name",f.name,f,null),tt(e,n,"formEncType",f.formEncType,f,null),tt(e,n,"formMethod",f.formMethod,f,null),tt(e,n,"formTarget",f.formTarget,f,null)):(tt(e,n,"encType",f.encType,f,null),tt(e,n,"method",f.method,f,null),tt(e,n,"target",f.target,f,null)));if(o==null||typeof o=="symbol"||typeof o=="boolean"){e.removeAttribute(a);break}o=Gi(""+o),e.setAttribute(a,o);break;case"onClick":o!=null&&(e.onclick=Fn);break;case"onScroll":o!=null&&Be("scroll",e);break;case"onScrollEnd":o!=null&&Be("scrollend",e);break;case"dangerouslySetInnerHTML":if(o!=null){if(typeof o!="object"||!("__html"in o))throw Error(i(61));if(a=o.__html,a!=null){if(f.children!=null)throw Error(i(60));e.innerHTML=a}}break;case"multiple":e.multiple=o&&typeof o!="function"&&typeof o!="symbol";break;case"muted":e.muted=o&&typeof o!="function"&&typeof o!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(o==null||typeof o=="function"||typeof o=="boolean"||typeof o=="symbol"){e.removeAttribute("xlink:href");break}a=Gi(""+o),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",a);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":o!=null&&typeof o!="function"&&typeof o!="symbol"?e.setAttribute(a,""+o):e.removeAttribute(a);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":o&&typeof o!="function"&&typeof o!="symbol"?e.setAttribute(a,""):e.removeAttribute(a);break;case"capture":case"download":o===!0?e.setAttribute(a,""):o!==!1&&o!=null&&typeof o!="function"&&typeof o!="symbol"?e.setAttribute(a,o):e.removeAttribute(a);break;case"cols":case"rows":case"size":case"span":o!=null&&typeof o!="function"&&typeof o!="symbol"&&!isNaN(o)&&1<=o?e.setAttribute(a,o):e.removeAttribute(a);break;case"rowSpan":case"start":o==null||typeof o=="function"||typeof o=="symbol"||isNaN(o)?e.removeAttribute(a):e.setAttribute(a,o);break;case"popover":Be("beforetoggle",e),Be("toggle",e),$i(e,"popover",o);break;case"xlinkActuate":$n(e,"http://www.w3.org/1999/xlink","xlink:actuate",o);break;case"xlinkArcrole":$n(e,"http://www.w3.org/1999/xlink","xlink:arcrole",o);break;case"xlinkRole":$n(e,"http://www.w3.org/1999/xlink","xlink:role",o);break;case"xlinkShow":$n(e,"http://www.w3.org/1999/xlink","xlink:show",o);break;case"xlinkTitle":$n(e,"http://www.w3.org/1999/xlink","xlink:title",o);break;case"xlinkType":$n(e,"http://www.w3.org/1999/xlink","xlink:type",o);break;case"xmlBase":$n(e,"http://www.w3.org/XML/1998/namespace","xml:base",o);break;case"xmlLang":$n(e,"http://www.w3.org/XML/1998/namespace","xml:lang",o);break;case"xmlSpace":$n(e,"http://www.w3.org/XML/1998/namespace","xml:space",o);break;case"is":$i(e,"is",o);break;case"innerText":case"textContent":break;default:(!(2<a.length)||a[0]!=="o"&&a[0]!=="O"||a[1]!=="n"&&a[1]!=="N")&&(a=Db.get(a)||a,$i(e,a,o))}}function zc(e,n,a,o,f,g){switch(a){case"style":dh(e,o,g);break;case"dangerouslySetInnerHTML":if(o!=null){if(typeof o!="object"||!("__html"in o))throw Error(i(61));if(a=o.__html,a!=null){if(f.children!=null)throw Error(i(60));e.innerHTML=a}}break;case"children":typeof o=="string"?Nl(e,o):(typeof o=="number"||typeof o=="bigint")&&Nl(e,""+o);break;case"onScroll":o!=null&&Be("scroll",e);break;case"onScrollEnd":o!=null&&Be("scrollend",e);break;case"onClick":o!=null&&(e.onclick=Fn);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!rh.hasOwnProperty(a))e:{if(a[0]==="o"&&a[1]==="n"&&(f=a.endsWith("Capture"),n=a.slice(2,f?a.length-7:void 0),g=e[Pt]||null,g=g!=null?g[a]:null,typeof g=="function"&&e.removeEventListener(n,g,f),typeof o=="function")){typeof g!="function"&&g!==null&&(a in e?e[a]=null:e.hasAttribute(a)&&e.removeAttribute(a)),e.addEventListener(n,o,f);break e}a in e?e[a]=o:o===!0?e.setAttribute(a,""):$i(e,a,o)}}}function Bt(e,n,a){switch(n){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":Be("error",e),Be("load",e);var o=!1,f=!1,g;for(g in a)if(a.hasOwnProperty(g)){var v=a[g];if(v!=null)switch(g){case"src":o=!0;break;case"srcSet":f=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(i(137,n));default:tt(e,n,g,v,a,null)}}f&&tt(e,n,"srcSet",a.srcSet,a,null),o&&tt(e,n,"src",a.src,a,null);return;case"input":Be("invalid",e);var C=g=v=f=null,R=null,F=null;for(o in a)if(a.hasOwnProperty(o)){var te=a[o];if(te!=null)switch(o){case"name":f=te;break;case"type":v=te;break;case"checked":R=te;break;case"defaultChecked":F=te;break;case"value":g=te;break;case"defaultValue":C=te;break;case"children":case"dangerouslySetInnerHTML":if(te!=null)throw Error(i(137,n));break;default:tt(e,n,o,te,a,null)}}sh(e,g,C,R,F,v,f,!1);return;case"select":Be("invalid",e),o=v=g=null;for(f in a)if(a.hasOwnProperty(f)&&(C=a[f],C!=null))switch(f){case"value":g=C;break;case"defaultValue":v=C;break;case"multiple":o=C;default:tt(e,n,f,C,a,null)}n=g,a=v,e.multiple=!!o,n!=null?Cl(e,!!o,n,!1):a!=null&&Cl(e,!!o,a,!0);return;case"textarea":Be("invalid",e),g=f=o=null;for(v in a)if(a.hasOwnProperty(v)&&(C=a[v],C!=null))switch(v){case"value":o=C;break;case"defaultValue":f=C;break;case"children":g=C;break;case"dangerouslySetInnerHTML":if(C!=null)throw Error(i(91));break;default:tt(e,n,v,C,a,null)}ch(e,o,f,g);return;case"option":for(R in a)if(a.hasOwnProperty(R)&&(o=a[R],o!=null))switch(R){case"selected":e.selected=o&&typeof o!="function"&&typeof o!="symbol";break;default:tt(e,n,R,o,a,null)}return;case"dialog":Be("beforetoggle",e),Be("toggle",e),Be("cancel",e),Be("close",e);break;case"iframe":case"object":Be("load",e);break;case"video":case"audio":for(o=0;o<ai.length;o++)Be(ai[o],e);break;case"image":Be("error",e),Be("load",e);break;case"details":Be("toggle",e);break;case"embed":case"source":case"link":Be("error",e),Be("load",e);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(F in a)if(a.hasOwnProperty(F)&&(o=a[F],o!=null))switch(F){case"children":case"dangerouslySetInnerHTML":throw Error(i(137,n));default:tt(e,n,F,o,a,null)}return;default:if(Ps(n)){for(te in a)a.hasOwnProperty(te)&&(o=a[te],o!==void 0&&zc(e,n,te,o,a,void 0));return}}for(C in a)a.hasOwnProperty(C)&&(o=a[C],o!=null&&tt(e,n,C,o,a,null))}function lS(e,n,a,o){switch(n){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var f=null,g=null,v=null,C=null,R=null,F=null,te=null;for(Z in a){var ie=a[Z];if(a.hasOwnProperty(Z)&&ie!=null)switch(Z){case"checked":break;case"value":break;case"defaultValue":R=ie;default:o.hasOwnProperty(Z)||tt(e,n,Z,null,o,ie)}}for(var Y in o){var Z=o[Y];if(ie=a[Y],o.hasOwnProperty(Y)&&(Z!=null||ie!=null))switch(Y){case"type":g=Z;break;case"name":f=Z;break;case"checked":F=Z;break;case"defaultChecked":te=Z;break;case"value":v=Z;break;case"defaultValue":C=Z;break;case"children":case"dangerouslySetInnerHTML":if(Z!=null)throw Error(i(137,n));break;default:Z!==ie&&tt(e,n,Y,Z,o,ie)}}Ys(e,v,C,R,F,te,g,f);return;case"select":Z=v=C=Y=null;for(g in a)if(R=a[g],a.hasOwnProperty(g)&&R!=null)switch(g){case"value":break;case"multiple":Z=R;default:o.hasOwnProperty(g)||tt(e,n,g,null,o,R)}for(f in o)if(g=o[f],R=a[f],o.hasOwnProperty(f)&&(g!=null||R!=null))switch(f){case"value":Y=g;break;case"defaultValue":C=g;break;case"multiple":v=g;default:g!==R&&tt(e,n,f,g,o,R)}n=C,a=v,o=Z,Y!=null?Cl(e,!!a,Y,!1):!!o!=!!a&&(n!=null?Cl(e,!!a,n,!0):Cl(e,!!a,a?[]:"",!1));return;case"textarea":Z=Y=null;for(C in a)if(f=a[C],a.hasOwnProperty(C)&&f!=null&&!o.hasOwnProperty(C))switch(C){case"value":break;case"children":break;default:tt(e,n,C,null,o,f)}for(v in o)if(f=o[v],g=a[v],o.hasOwnProperty(v)&&(f!=null||g!=null))switch(v){case"value":Y=f;break;case"defaultValue":Z=f;break;case"children":break;case"dangerouslySetInnerHTML":if(f!=null)throw Error(i(91));break;default:f!==g&&tt(e,n,v,f,o,g)}uh(e,Y,Z);return;case"option":for(var ge in a)if(Y=a[ge],a.hasOwnProperty(ge)&&Y!=null&&!o.hasOwnProperty(ge))switch(ge){case"selected":e.selected=!1;break;default:tt(e,n,ge,null,o,Y)}for(R in o)if(Y=o[R],Z=a[R],o.hasOwnProperty(R)&&Y!==Z&&(Y!=null||Z!=null))switch(R){case"selected":e.selected=Y&&typeof Y!="function"&&typeof Y!="symbol";break;default:tt(e,n,R,Y,o,Z)}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 Ee in a)Y=a[Ee],a.hasOwnProperty(Ee)&&Y!=null&&!o.hasOwnProperty(Ee)&&tt(e,n,Ee,null,o,Y);for(F in o)if(Y=o[F],Z=a[F],o.hasOwnProperty(F)&&Y!==Z&&(Y!=null||Z!=null))switch(F){case"children":case"dangerouslySetInnerHTML":if(Y!=null)throw Error(i(137,n));break;default:tt(e,n,F,Y,o,Z)}return;default:if(Ps(n)){for(var nt in a)Y=a[nt],a.hasOwnProperty(nt)&&Y!==void 0&&!o.hasOwnProperty(nt)&&zc(e,n,nt,void 0,o,Y);for(te in o)Y=o[te],Z=a[te],!o.hasOwnProperty(te)||Y===Z||Y===void 0&&Z===void 0||zc(e,n,te,Y,o,Z);return}}for(var q in a)Y=a[q],a.hasOwnProperty(q)&&Y!=null&&!o.hasOwnProperty(q)&&tt(e,n,q,null,o,Y);for(ie in o)Y=o[ie],Z=a[ie],!o.hasOwnProperty(ie)||Y===Z||Y==null&&Z==null||tt(e,n,ie,Y,o,Z)}function hg(e){switch(e){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function aS(){if(typeof performance.getEntriesByType=="function"){for(var e=0,n=0,a=performance.getEntriesByType("resource"),o=0;o<a.length;o++){var f=a[o],g=f.transferSize,v=f.initiatorType,C=f.duration;if(g&&C&&hg(v)){for(v=0,C=f.responseEnd,o+=1;o<a.length;o++){var R=a[o],F=R.startTime;if(F>C)break;var te=R.transferSize,ie=R.initiatorType;te&&hg(ie)&&(R=R.responseEnd,v+=te*(R<C?1:(C-F)/(R-F)))}if(--o,n+=8*(g+v)/(f.duration/1e3),e++,10<e)break}}if(0<e)return n/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e=="number")?e:5}var Oc=null,_c=null;function Vo(e){return e.nodeType===9?e:e.ownerDocument}function mg(e){switch(e){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function pg(e,n){if(e===0)switch(n){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&n==="foreignObject"?0:e}function Lc(e,n){return e==="textarea"||e==="noscript"||typeof n.children=="string"||typeof n.children=="number"||typeof n.children=="bigint"||typeof n.dangerouslySetInnerHTML=="object"&&n.dangerouslySetInnerHTML!==null&&n.dangerouslySetInnerHTML.__html!=null}var Uc=null;function iS(){var e=window.event;return e&&e.type==="popstate"?e===Uc?!1:(Uc=e,!0):(Uc=null,!1)}var gg=typeof setTimeout=="function"?setTimeout:void 0,oS=typeof clearTimeout=="function"?clearTimeout:void 0,yg=typeof Promise=="function"?Promise:void 0,sS=typeof queueMicrotask=="function"?queueMicrotask:typeof yg<"u"?function(e){return yg.resolve(null).then(e).catch(uS)}:gg;function uS(e){setTimeout(function(){throw e})}function Mr(e){return e==="head"}function xg(e,n){var a=n,o=0;do{var f=a.nextSibling;if(e.removeChild(a),f&&f.nodeType===8)if(a=f.data,a==="/$"||a==="/&"){if(o===0){e.removeChild(f),na(n);return}o--}else if(a==="$"||a==="$?"||a==="$~"||a==="$!"||a==="&")o++;else if(a==="html")oi(e.ownerDocument.documentElement);else if(a==="head"){a=e.ownerDocument.head,oi(a);for(var g=a.firstChild;g;){var v=g.nextSibling,C=g.nodeName;g[Na]||C==="SCRIPT"||C==="STYLE"||C==="LINK"&&g.rel.toLowerCase()==="stylesheet"||a.removeChild(g),g=v}}else a==="body"&&oi(e.ownerDocument.body);a=f}while(a);na(n)}function bg(e,n){var a=e;e=0;do{var o=a.nextSibling;if(a.nodeType===1?n?(a._stashedDisplay=a.style.display,a.style.display="none"):(a.style.display=a._stashedDisplay||"",a.getAttribute("style")===""&&a.removeAttribute("style")):a.nodeType===3&&(n?(a._stashedText=a.nodeValue,a.nodeValue=""):a.nodeValue=a._stashedText||""),o&&o.nodeType===8)if(a=o.data,a==="/$"){if(e===0)break;e--}else a!=="$"&&a!=="$?"&&a!=="$~"&&a!=="$!"||e++;a=o}while(a)}function Bc(e){var n=e.firstChild;for(n&&n.nodeType===10&&(n=n.nextSibling);n;){var a=n;switch(n=n.nextSibling,a.nodeName){case"HTML":case"HEAD":case"BODY":Bc(a),$s(a);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(a.rel.toLowerCase()==="stylesheet")continue}e.removeChild(a)}}function cS(e,n,a,o){for(;e.nodeType===1;){var f=a;if(e.nodeName.toLowerCase()!==n.toLowerCase()){if(!o&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(o){if(!e[Na])switch(n){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if(g=e.getAttribute("rel"),g==="stylesheet"&&e.hasAttribute("data-precedence"))break;if(g!==f.rel||e.getAttribute("href")!==(f.href==null||f.href===""?null:f.href)||e.getAttribute("crossorigin")!==(f.crossOrigin==null?null:f.crossOrigin)||e.getAttribute("title")!==(f.title==null?null:f.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(g=e.getAttribute("src"),(g!==(f.src==null?null:f.src)||e.getAttribute("type")!==(f.type==null?null:f.type)||e.getAttribute("crossorigin")!==(f.crossOrigin==null?null:f.crossOrigin))&&g&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else if(n==="input"&&e.type==="hidden"){var g=f.name==null?null:""+f.name;if(f.type==="hidden"&&e.getAttribute("name")===g)return e}else return e;if(e=kn(e.nextSibling),e===null)break}return null}function fS(e,n,a){if(n==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!a||(e=kn(e.nextSibling),e===null))return null;return e}function vg(e,n){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!n||(e=kn(e.nextSibling),e===null))return null;return e}function Hc(e){return e.data==="$?"||e.data==="$~"}function qc(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState!=="loading"}function dS(e,n){var a=e.ownerDocument;if(e.data==="$~")e._reactRetry=n;else if(e.data!=="$?"||a.readyState!=="loading")n();else{var o=function(){n(),a.removeEventListener("DOMContentLoaded",o)};a.addEventListener("DOMContentLoaded",o),e._reactRetry=o}}function kn(e){for(;e!=null;e=e.nextSibling){var n=e.nodeType;if(n===1||n===3)break;if(n===8){if(n=e.data,n==="$"||n==="$!"||n==="$?"||n==="$~"||n==="&"||n==="F!"||n==="F")break;if(n==="/$"||n==="/&")return null}}return e}var Ic=null;function Sg(e){e=e.nextSibling;for(var n=0;e;){if(e.nodeType===8){var a=e.data;if(a==="/$"||a==="/&"){if(n===0)return kn(e.nextSibling);n--}else a!=="$"&&a!=="$!"&&a!=="$?"&&a!=="$~"&&a!=="&"||n++}e=e.nextSibling}return null}function wg(e){e=e.previousSibling;for(var n=0;e;){if(e.nodeType===8){var a=e.data;if(a==="$"||a==="$!"||a==="$?"||a==="$~"||a==="&"){if(n===0)return e;n--}else a!=="/$"&&a!=="/&"||n++}e=e.previousSibling}return null}function kg(e,n,a){switch(n=Vo(a),e){case"html":if(e=n.documentElement,!e)throw Error(i(452));return e;case"head":if(e=n.head,!e)throw Error(i(453));return e;case"body":if(e=n.body,!e)throw Error(i(454));return e;default:throw Error(i(451))}}function oi(e){for(var n=e.attributes;n.length;)e.removeAttributeNode(n[0]);$s(e)}var Cn=new Map,Cg=new Set;function $o(e){return typeof e.getRootNode=="function"?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var ir=ne.d;ne.d={f:hS,r:mS,D:pS,C:gS,L:yS,m:xS,X:vS,S:bS,M:SS};function hS(){var e=ir.f(),n=Oo();return e||n}function mS(e){var n=Sl(e);n!==null&&n.tag===5&&n.type==="form"?Im(n):ir.r(e)}var Wl=typeof document>"u"?null:document;function Ng(e,n,a){var o=Wl;if(o&&typeof n=="string"&&n){var f=gn(n);f='link[rel="'+e+'"][href="'+f+'"]',typeof a=="string"&&(f+='[crossorigin="'+a+'"]'),Cg.has(f)||(Cg.add(f),e={rel:e,crossOrigin:a,href:n},o.querySelector(f)===null&&(n=o.createElement("link"),Bt(n,"link",e),Dt(n),o.head.appendChild(n)))}}function pS(e){ir.D(e),Ng("dns-prefetch",e,null)}function gS(e,n){ir.C(e,n),Ng("preconnect",e,n)}function yS(e,n,a){ir.L(e,n,a);var o=Wl;if(o&&e&&n){var f='link[rel="preload"][as="'+gn(n)+'"]';n==="image"&&a&&a.imageSrcSet?(f+='[imagesrcset="'+gn(a.imageSrcSet)+'"]',typeof a.imageSizes=="string"&&(f+='[imagesizes="'+gn(a.imageSizes)+'"]')):f+='[href="'+gn(e)+'"]';var g=f;switch(n){case"style":g=ea(e);break;case"script":g=ta(e)}Cn.has(g)||(e=y({rel:"preload",href:n==="image"&&a&&a.imageSrcSet?void 0:e,as:n},a),Cn.set(g,e),o.querySelector(f)!==null||n==="style"&&o.querySelector(si(g))||n==="script"&&o.querySelector(ui(g))||(n=o.createElement("link"),Bt(n,"link",e),Dt(n),o.head.appendChild(n)))}}function xS(e,n){ir.m(e,n);var a=Wl;if(a&&e){var o=n&&typeof n.as=="string"?n.as:"script",f='link[rel="modulepreload"][as="'+gn(o)+'"][href="'+gn(e)+'"]',g=f;switch(o){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":g=ta(e)}if(!Cn.has(g)&&(e=y({rel:"modulepreload",href:e},n),Cn.set(g,e),a.querySelector(f)===null)){switch(o){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(a.querySelector(ui(g)))return}o=a.createElement("link"),Bt(o,"link",e),Dt(o),a.head.appendChild(o)}}}function bS(e,n,a){ir.S(e,n,a);var o=Wl;if(o&&e){var f=wl(o).hoistableStyles,g=ea(e);n=n||"default";var v=f.get(g);if(!v){var C={loading:0,preload:null};if(v=o.querySelector(si(g)))C.loading=5;else{e=y({rel:"stylesheet",href:e,"data-precedence":n},a),(a=Cn.get(g))&&Vc(e,a);var R=v=o.createElement("link");Dt(R),Bt(R,"link",e),R._p=new Promise(function(F,te){R.onload=F,R.onerror=te}),R.addEventListener("load",function(){C.loading|=1}),R.addEventListener("error",function(){C.loading|=2}),C.loading|=4,Fo(v,n,o)}v={type:"stylesheet",instance:v,count:1,state:C},f.set(g,v)}}}function vS(e,n){ir.X(e,n);var a=Wl;if(a&&e){var o=wl(a).hoistableScripts,f=ta(e),g=o.get(f);g||(g=a.querySelector(ui(f)),g||(e=y({src:e,async:!0},n),(n=Cn.get(f))&&$c(e,n),g=a.createElement("script"),Dt(g),Bt(g,"link",e),a.head.appendChild(g)),g={type:"script",instance:g,count:1,state:null},o.set(f,g))}}function SS(e,n){ir.M(e,n);var a=Wl;if(a&&e){var o=wl(a).hoistableScripts,f=ta(e),g=o.get(f);g||(g=a.querySelector(ui(f)),g||(e=y({src:e,async:!0,type:"module"},n),(n=Cn.get(f))&&$c(e,n),g=a.createElement("script"),Dt(g),Bt(g,"link",e),a.head.appendChild(g)),g={type:"script",instance:g,count:1,state:null},o.set(f,g))}}function Eg(e,n,a,o){var f=(f=re.current)?$o(f):null;if(!f)throw Error(i(446));switch(e){case"meta":case"title":return null;case"style":return typeof a.precedence=="string"&&typeof a.href=="string"?(n=ea(a.href),a=wl(f).hoistableStyles,o=a.get(n),o||(o={type:"style",instance:null,count:0,state:null},a.set(n,o)),o):{type:"void",instance:null,count:0,state:null};case"link":if(a.rel==="stylesheet"&&typeof a.href=="string"&&typeof a.precedence=="string"){e=ea(a.href);var g=wl(f).hoistableStyles,v=g.get(e);if(v||(f=f.ownerDocument||f,v={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},g.set(e,v),(g=f.querySelector(si(e)))&&!g._p&&(v.instance=g,v.state.loading=5),Cn.has(e)||(a={rel:"preload",as:"style",href:a.href,crossOrigin:a.crossOrigin,integrity:a.integrity,media:a.media,hrefLang:a.hrefLang,referrerPolicy:a.referrerPolicy},Cn.set(e,a),g||wS(f,e,a,v.state))),n&&o===null)throw Error(i(528,""));return v}if(n&&o!==null)throw Error(i(529,""));return null;case"script":return n=a.async,a=a.src,typeof a=="string"&&n&&typeof n!="function"&&typeof n!="symbol"?(n=ta(a),a=wl(f).hoistableScripts,o=a.get(n),o||(o={type:"script",instance:null,count:0,state:null},a.set(n,o)),o):{type:"void",instance:null,count:0,state:null};default:throw Error(i(444,e))}}function ea(e){return'href="'+gn(e)+'"'}function si(e){return'link[rel="stylesheet"]['+e+"]"}function jg(e){return y({},e,{"data-precedence":e.precedence,precedence:null})}function wS(e,n,a,o){e.querySelector('link[rel="preload"][as="style"]['+n+"]")?o.loading=1:(n=e.createElement("link"),o.preload=n,n.addEventListener("load",function(){return o.loading|=1}),n.addEventListener("error",function(){return o.loading|=2}),Bt(n,"link",a),Dt(n),e.head.appendChild(n))}function ta(e){return'[src="'+gn(e)+'"]'}function ui(e){return"script[async]"+e}function Tg(e,n,a){if(n.count++,n.instance===null)switch(n.type){case"style":var o=e.querySelector('style[data-href~="'+gn(a.href)+'"]');if(o)return n.instance=o,Dt(o),o;var f=y({},a,{"data-href":a.href,"data-precedence":a.precedence,href:null,precedence:null});return o=(e.ownerDocument||e).createElement("style"),Dt(o),Bt(o,"style",f),Fo(o,a.precedence,e),n.instance=o;case"stylesheet":f=ea(a.href);var g=e.querySelector(si(f));if(g)return n.state.loading|=4,n.instance=g,Dt(g),g;o=jg(a),(f=Cn.get(f))&&Vc(o,f),g=(e.ownerDocument||e).createElement("link"),Dt(g);var v=g;return v._p=new Promise(function(C,R){v.onload=C,v.onerror=R}),Bt(g,"link",o),n.state.loading|=4,Fo(g,a.precedence,e),n.instance=g;case"script":return g=ta(a.src),(f=e.querySelector(ui(g)))?(n.instance=f,Dt(f),f):(o=a,(f=Cn.get(g))&&(o=y({},a),$c(o,f)),e=e.ownerDocument||e,f=e.createElement("script"),Dt(f),Bt(f,"link",o),e.head.appendChild(f),n.instance=f);case"void":return null;default:throw Error(i(443,n.type))}else n.type==="stylesheet"&&(n.state.loading&4)===0&&(o=n.instance,n.state.loading|=4,Fo(o,a.precedence,e));return n.instance}function Fo(e,n,a){for(var o=a.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),f=o.length?o[o.length-1]:null,g=f,v=0;v<o.length;v++){var C=o[v];if(C.dataset.precedence===n)g=C;else if(g!==f)break}g?g.parentNode.insertBefore(e,g.nextSibling):(n=a.nodeType===9?a.head:a,n.insertBefore(e,n.firstChild))}function Vc(e,n){e.crossOrigin==null&&(e.crossOrigin=n.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=n.referrerPolicy),e.title==null&&(e.title=n.title)}function $c(e,n){e.crossOrigin==null&&(e.crossOrigin=n.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=n.referrerPolicy),e.integrity==null&&(e.integrity=n.integrity)}var Yo=null;function Ag(e,n,a){if(Yo===null){var o=new Map,f=Yo=new Map;f.set(a,o)}else f=Yo,o=f.get(a),o||(o=new Map,f.set(a,o));if(o.has(e))return o;for(o.set(e,null),a=a.getElementsByTagName(e),f=0;f<a.length;f++){var g=a[f];if(!(g[Na]||g[Ot]||e==="link"&&g.getAttribute("rel")==="stylesheet")&&g.namespaceURI!=="http://www.w3.org/2000/svg"){var v=g.getAttribute(n)||"";v=e+v;var C=o.get(v);C?C.push(g):o.set(v,[g])}}return o}function Mg(e,n,a){e=e.ownerDocument||e,e.head.insertBefore(a,n==="title"?e.querySelector("head > title"):null)}function kS(e,n,a){if(a===1||n.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof n.precedence!="string"||typeof n.href!="string"||n.href==="")break;return!0;case"link":if(typeof n.rel!="string"||typeof n.href!="string"||n.href===""||n.onLoad||n.onError)break;switch(n.rel){case"stylesheet":return e=n.disabled,typeof n.precedence=="string"&&e==null;default:return!0}case"script":if(n.async&&typeof n.async!="function"&&typeof n.async!="symbol"&&!n.onLoad&&!n.onError&&n.src&&typeof n.src=="string")return!0}return!1}function Dg(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}function CS(e,n,a,o){if(a.type==="stylesheet"&&(typeof o.media!="string"||matchMedia(o.media).matches!==!1)&&(a.state.loading&4)===0){if(a.instance===null){var f=ea(o.href),g=n.querySelector(si(f));if(g){n=g._p,n!==null&&typeof n=="object"&&typeof n.then=="function"&&(e.count++,e=Go.bind(e),n.then(e,e)),a.state.loading|=4,a.instance=g,Dt(g);return}g=n.ownerDocument||n,o=jg(o),(f=Cn.get(f))&&Vc(o,f),g=g.createElement("link"),Dt(g);var v=g;v._p=new Promise(function(C,R){v.onload=C,v.onerror=R}),Bt(g,"link",o),a.instance=g}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(a,n),(n=a.state.preload)&&(a.state.loading&3)===0&&(e.count++,a=Go.bind(e),n.addEventListener("load",a),n.addEventListener("error",a))}}var Fc=0;function NS(e,n){return e.stylesheets&&e.count===0&&Xo(e,e.stylesheets),0<e.count||0<e.imgCount?function(a){var o=setTimeout(function(){if(e.stylesheets&&Xo(e,e.stylesheets),e.unsuspend){var g=e.unsuspend;e.unsuspend=null,g()}},6e4+n);0<e.imgBytes&&Fc===0&&(Fc=62500*aS());var f=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&Xo(e,e.stylesheets),e.unsuspend)){var g=e.unsuspend;e.unsuspend=null,g()}},(e.imgBytes>Fc?50:800)+n);return e.unsuspend=a,function(){e.unsuspend=null,clearTimeout(o),clearTimeout(f)}}:null}function Go(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Xo(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Po=null;function Xo(e,n){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Po=new Map,n.forEach(ES,e),Po=null,Go.call(e))}function ES(e,n){if(!(n.state.loading&4)){var a=Po.get(e);if(a)var o=a.get(null);else{a=new Map,Po.set(e,a);for(var f=e.querySelectorAll("link[data-precedence],style[data-precedence]"),g=0;g<f.length;g++){var v=f[g];(v.nodeName==="LINK"||v.getAttribute("media")!=="not all")&&(a.set(v.dataset.precedence,v),o=v)}o&&a.set(null,o)}f=n.instance,v=f.getAttribute("data-precedence"),g=a.get(v)||o,g===o&&a.set(null,f),a.set(v,f),this.count++,o=Go.bind(this),f.addEventListener("load",o),f.addEventListener("error",o),g?g.parentNode.insertBefore(f,g.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(f,e.firstChild)),n.state.loading|=4}}var ci={$$typeof:z,Provider:null,Consumer:null,_currentValue:oe,_currentValue2:oe,_threadCount:0};function jS(e,n,a,o,f,g,v,C,R){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Hs(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Hs(0),this.hiddenUpdates=Hs(null),this.identifierPrefix=o,this.onUncaughtError=f,this.onCaughtError=g,this.onRecoverableError=v,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=R,this.incompleteTransitions=new Map}function Rg(e,n,a,o,f,g,v,C,R,F,te,ie){return e=new jS(e,n,a,v,R,F,te,ie,C),n=1,g===!0&&(n|=24),g=ln(3,null,null,n),e.current=g,g.stateNode=e,n=ku(),n.refCount++,e.pooledCache=n,n.refCount++,g.memoizedState={element:o,isDehydrated:a,cache:n},ju(g),e}function zg(e){return e?(e=Rl,e):Rl}function Og(e,n,a,o,f,g){f=zg(f),o.context===null?o.context=f:o.pendingContext=f,o=br(n),o.payload={element:a},g=g===void 0?null:g,g!==null&&(o.callback=g),a=vr(e,o,n),a!==null&&(Wt(a,e,n),Va(a,e,n))}function _g(e,n){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var a=e.retryLane;e.retryLane=a!==0&&a<n?a:n}}function Yc(e,n){_g(e,n),(e=e.alternate)&&_g(e,n)}function Lg(e){if(e.tag===13||e.tag===31){var n=Kr(e,67108864);n!==null&&Wt(n,e,67108864),Yc(e,67108864)}}function Ug(e){if(e.tag===13||e.tag===31){var n=cn();n=qs(n);var a=Kr(e,n);a!==null&&Wt(a,e,n),Yc(e,n)}}var Qo=!0;function TS(e,n,a,o){var f=H.T;H.T=null;var g=ne.p;try{ne.p=2,Gc(e,n,a,o)}finally{ne.p=g,H.T=f}}function AS(e,n,a,o){var f=H.T;H.T=null;var g=ne.p;try{ne.p=8,Gc(e,n,a,o)}finally{ne.p=g,H.T=f}}function Gc(e,n,a,o){if(Qo){var f=Pc(o);if(f===null)Rc(e,n,o,Ko,a),Hg(e,o);else if(DS(f,e,n,a,o))o.stopPropagation();else if(Hg(e,o),n&4&&-1<MS.indexOf(e)){for(;f!==null;){var g=Sl(f);if(g!==null)switch(g.tag){case 3:if(g=g.stateNode,g.current.memoizedState.isDehydrated){var v=Yr(g.pendingLanes);if(v!==0){var C=g;for(C.pendingLanes|=2,C.entangledLanes|=2;v;){var R=1<<31-Ze(v);C.entanglements[1]|=R,v&=~R}Ln(g),(Ke&6)===0&&(Ro=ue()+500,li(0))}}break;case 31:case 13:C=Kr(g,2),C!==null&&Wt(C,g,2),Oo(),Yc(g,2)}if(g=Pc(o),g===null&&Rc(e,n,o,Ko,a),g===f)break;f=g}f!==null&&o.stopPropagation()}else Rc(e,n,o,null,a)}}function Pc(e){return e=Qs(e),Xc(e)}var Ko=null;function Xc(e){if(Ko=null,e=vl(e),e!==null){var n=u(e);if(n===null)e=null;else{var a=n.tag;if(a===13){if(e=c(n),e!==null)return e;e=null}else if(a===31){if(e=d(n),e!==null)return e;e=null}else if(a===3){if(n.stateNode.current.memoizedState.isDehydrated)return n.tag===3?n.stateNode.containerInfo:null;e=null}else n!==e&&(e=null)}}return Ko=e,null}function Bg(e){switch(e){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(je()){case K:return 2;case fe:return 8;case ke:case ze:return 32;case Fe:return 268435456;default:return 32}default:return 32}}var Qc=!1,Dr=null,Rr=null,zr=null,fi=new Map,di=new Map,Or=[],MS="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 Hg(e,n){switch(e){case"focusin":case"focusout":Dr=null;break;case"dragenter":case"dragleave":Rr=null;break;case"mouseover":case"mouseout":zr=null;break;case"pointerover":case"pointerout":fi.delete(n.pointerId);break;case"gotpointercapture":case"lostpointercapture":di.delete(n.pointerId)}}function hi(e,n,a,o,f,g){return e===null||e.nativeEvent!==g?(e={blockedOn:n,domEventName:a,eventSystemFlags:o,nativeEvent:g,targetContainers:[f]},n!==null&&(n=Sl(n),n!==null&&Lg(n)),e):(e.eventSystemFlags|=o,n=e.targetContainers,f!==null&&n.indexOf(f)===-1&&n.push(f),e)}function DS(e,n,a,o,f){switch(n){case"focusin":return Dr=hi(Dr,e,n,a,o,f),!0;case"dragenter":return Rr=hi(Rr,e,n,a,o,f),!0;case"mouseover":return zr=hi(zr,e,n,a,o,f),!0;case"pointerover":var g=f.pointerId;return fi.set(g,hi(fi.get(g)||null,e,n,a,o,f)),!0;case"gotpointercapture":return g=f.pointerId,di.set(g,hi(di.get(g)||null,e,n,a,o,f)),!0}return!1}function qg(e){var n=vl(e.target);if(n!==null){var a=u(n);if(a!==null){if(n=a.tag,n===13){if(n=c(a),n!==null){e.blockedOn=n,eh(e.priority,function(){Ug(a)});return}}else if(n===31){if(n=d(a),n!==null){e.blockedOn=n,eh(e.priority,function(){Ug(a)});return}}else if(n===3&&a.stateNode.current.memoizedState.isDehydrated){e.blockedOn=a.tag===3?a.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Zo(e){if(e.blockedOn!==null)return!1;for(var n=e.targetContainers;0<n.length;){var a=Pc(e.nativeEvent);if(a===null){a=e.nativeEvent;var o=new a.constructor(a.type,a);Xs=o,a.target.dispatchEvent(o),Xs=null}else return n=Sl(a),n!==null&&Lg(n),e.blockedOn=a,!1;n.shift()}return!0}function Ig(e,n,a){Zo(e)&&a.delete(n)}function RS(){Qc=!1,Dr!==null&&Zo(Dr)&&(Dr=null),Rr!==null&&Zo(Rr)&&(Rr=null),zr!==null&&Zo(zr)&&(zr=null),fi.forEach(Ig),di.forEach(Ig)}function Jo(e,n){e.blockedOn===n&&(e.blockedOn=null,Qc||(Qc=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,RS)))}var Wo=null;function Vg(e){Wo!==e&&(Wo=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){Wo===e&&(Wo=null);for(var n=0;n<e.length;n+=3){var a=e[n],o=e[n+1],f=e[n+2];if(typeof o!="function"){if(Xc(o||a)===null)continue;break}var g=Sl(a);g!==null&&(e.splice(n,3),n-=3,Pu(g,{pending:!0,data:f,method:a.method,action:o},o,f))}}))}function na(e){function n(R){return Jo(R,e)}Dr!==null&&Jo(Dr,e),Rr!==null&&Jo(Rr,e),zr!==null&&Jo(zr,e),fi.forEach(n),di.forEach(n);for(var a=0;a<Or.length;a++){var o=Or[a];o.blockedOn===e&&(o.blockedOn=null)}for(;0<Or.length&&(a=Or[0],a.blockedOn===null);)qg(a),a.blockedOn===null&&Or.shift();if(a=(e.ownerDocument||e).$$reactFormReplay,a!=null)for(o=0;o<a.length;o+=3){var f=a[o],g=a[o+1],v=f[Pt]||null;if(typeof g=="function")v||Vg(a);else if(v){var C=null;if(g&&g.hasAttribute("formAction")){if(f=g,v=g[Pt]||null)C=v.formAction;else if(Xc(f)!==null)continue}else C=v.action;typeof C=="function"?a[o+1]=C:(a.splice(o,3),o-=3),Vg(a)}}}function $g(){function e(g){g.canIntercept&&g.info==="react-transition"&&g.intercept({handler:function(){return new Promise(function(v){return f=v})},focusReset:"manual",scroll:"manual"})}function n(){f!==null&&(f(),f=null),o||setTimeout(a,20)}function a(){if(!o&&!navigation.transition){var g=navigation.currentEntry;g&&g.url!=null&&navigation.navigate(g.url,{state:g.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var o=!1,f=null;return navigation.addEventListener("navigate",e),navigation.addEventListener("navigatesuccess",n),navigation.addEventListener("navigateerror",n),setTimeout(a,100),function(){o=!0,navigation.removeEventListener("navigate",e),navigation.removeEventListener("navigatesuccess",n),navigation.removeEventListener("navigateerror",n),f!==null&&(f(),f=null)}}}function Kc(e){this._internalRoot=e}es.prototype.render=Kc.prototype.render=function(e){var n=this._internalRoot;if(n===null)throw Error(i(409));var a=n.current,o=cn();Og(a,o,e,n,null,null)},es.prototype.unmount=Kc.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var n=e.containerInfo;Og(e.current,2,null,e,null,null),Oo(),n[bl]=null}};function es(e){this._internalRoot=e}es.prototype.unstable_scheduleHydration=function(e){if(e){var n=Wd();e={blockedOn:null,target:e,priority:n};for(var a=0;a<Or.length&&n!==0&&n<Or[a].priority;a++);Or.splice(a,0,e),a===0&&qg(e)}};var Fg=r.version;if(Fg!=="19.2.6")throw Error(i(527,Fg,"19.2.6"));ne.findDOMNode=function(e){var n=e._reactInternals;if(n===void 0)throw typeof e.render=="function"?Error(i(188)):(e=Object.keys(e).join(","),Error(i(268,e)));return e=m(n),e=e!==null?x(e):null,e=e===null?null:e.stateNode,e};var zS={bundleType:0,version:"19.2.6",rendererPackageName:"react-dom",currentDispatcherRef:H,reconcilerVersion:"19.2.6"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var ts=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!ts.isDisabled&&ts.supportsFiber)try{yt=ts.inject(zS),it=ts}catch{}}return pi.createRoot=function(e,n){if(!s(e))throw Error(i(299));var a=!1,o="",f=Zm,g=Jm,v=Wm;return n!=null&&(n.unstable_strictMode===!0&&(a=!0),n.identifierPrefix!==void 0&&(o=n.identifierPrefix),n.onUncaughtError!==void 0&&(f=n.onUncaughtError),n.onCaughtError!==void 0&&(g=n.onCaughtError),n.onRecoverableError!==void 0&&(v=n.onRecoverableError)),n=Rg(e,1,!1,null,null,a,o,null,f,g,v,$g),e[bl]=n.current,Dc(e),new Kc(n)},pi.hydrateRoot=function(e,n,a){if(!s(e))throw Error(i(299));var o=!1,f="",g=Zm,v=Jm,C=Wm,R=null;return a!=null&&(a.unstable_strictMode===!0&&(o=!0),a.identifierPrefix!==void 0&&(f=a.identifierPrefix),a.onUncaughtError!==void 0&&(g=a.onUncaughtError),a.onCaughtError!==void 0&&(v=a.onCaughtError),a.onRecoverableError!==void 0&&(C=a.onRecoverableError),a.formState!==void 0&&(R=a.formState)),n=Rg(e,1,!0,n,a??null,o,f,R,g,v,C,$g),n.context=zg(null),a=n.current,o=cn(),o=qs(o),f=br(o),f.callback=null,vr(a,f,o),a=o,n.current.lanes=a,Ca(n,a),Ln(n),e[bl]=n.current,Dc(e),new es(n)},pi.version="19.2.6",pi}var ey;function YS(){if(ey)return Wc.exports;ey=1;function t(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(t)}catch(r){console.error(r)}}return t(),Wc.exports=FS(),Wc.exports}var GS=YS();const PS=Ri(GS),ty=t=>{let r;const l=new Set,i=(m,x)=>{const y=typeof m=="function"?m(r):m;if(!Object.is(y,r)){const b=r;r=x??(typeof y!="object"||y===null)?y:Object.assign({},r,y),l.forEach(S=>S(r,b))}},s=()=>r,d={setState:i,getState:s,getInitialState:()=>p,subscribe:m=>(l.add(m),()=>l.delete(m))},p=r=t(i,s,d);return d},XS=(t=>t?ty(t):ty),QS=t=>t;function KS(t,r=QS){const l=dn.useSyncExternalStore(t.subscribe,dn.useCallback(()=>r(t.getState()),[t,r]),dn.useCallback(()=>r(t.getInitialState()),[t,r]));return dn.useDebugValue(l),l}const ny=t=>{const r=XS(t),l=i=>KS(r,i);return Object.assign(l,r),l},xa=(t=>t?ny(t):ny);function ZS(t,r){let l;try{l=t()}catch{return}return{getItem:s=>{var u;const c=p=>p===null?null:JSON.parse(p,void 0),d=(u=l.getItem(s))!=null?u:null;return d instanceof Promise?d.then(c):c(d)},setItem:(s,u)=>l.setItem(s,JSON.stringify(u,void 0)),removeItem:s=>l.removeItem(s)}}const Lf=t=>r=>{try{const l=t(r);return l instanceof Promise?l:{then(i){return Lf(i)(l)},catch(i){return this}}}catch(l){return{then(i){return this},catch(i){return Lf(i)(l)}}}},JS=(t,r)=>(l,i,s)=>{let u={storage:ZS(()=>window.localStorage),partialize:A=>A,version:0,merge:(A,j)=>({...j,...A}),...r},c=!1,d=0;const p=new Set,m=new Set;let x=u.storage;if(!x)return t((...A)=>{console.warn(`[zustand persist middleware] Unable to update item '${u.name}', the given storage is currently unavailable.`),l(...A)},i,s);const y=()=>{const A=u.partialize({...i()});return x.setItem(u.name,{state:A,version:u.version})},b=s.setState;s.setState=(A,j)=>(b(A,j),y());const S=t((...A)=>(l(...A),y()),i,s);s.getInitialState=()=>S;let k;const N=()=>{var A,j;if(!x)return;const M=++d;c=!1,p.forEach(V=>{var Q;return V((Q=i())!=null?Q:S)});const z=((j=u.onRehydrateStorage)==null?void 0:j.call(u,(A=i())!=null?A:S))||void 0;return Lf(x.getItem.bind(x))(u.name).then(V=>{if(V)if(typeof V.version=="number"&&V.version!==u.version){if(u.migrate){const Q=u.migrate(V.state,V.version);return Q instanceof Promise?Q.then(B=>[!0,B]):[!0,Q]}console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}else return[!1,V.state];return[!1,void 0]}).then(V=>{var Q;if(M!==d)return;const[B,G]=V;if(k=u.merge(G,(Q=i())!=null?Q:S),l(k,!0),B)return y()}).then(()=>{M===d&&(z==null||z(i(),void 0),k=i(),c=!0,m.forEach(V=>V(k)))}).catch(V=>{M===d&&(z==null||z(void 0,V))})};return s.persist={setOptions:A=>{u={...u,...A},A.storage&&(x=A.storage)},clearStorage:()=>{x==null||x.removeItem(u.name)},getOptions:()=>u,rehydrate:()=>N(),hasHydrated:()=>c,onHydrate:A=>(p.add(A),()=>{p.delete(A)}),onFinishHydration:A=>(m.add(A),()=>{m.delete(A)})},u.skipHydration||N(),k||S},Es=JS;function WS(t){if(!t)return t;const r=t.split(/\n{2,}/),l=[];for(const s of r)l.length>0&&l[l.length-1].trim()===s.trim()||l.push(s);return l.map(s=>{const u=s.split(`
|
|
50
|
-
`),c=[];for(const d of u)c.length>0&&d.trim().length>0&&c[c.length-1].trim()===d.trim()||c.push(d);return c.join(`
|
|
51
|
-
`)}).join(`
|
|
52
|
-
|
|
53
|
-
`)}const pe=xa()(Es((t,r)=>({messages:[],currentAssistantMessageId:null,currentToolId:null,isLoading:!1,abortController:null,executions:new Map,queue:[],runStart:null,addMessage:l=>{const i=`msg_${Date.now()}_${Math.random().toString(36).slice(2,9)}`,s={...l,id:i,timestamp:Date.now()};return t(u=>({messages:[...u.messages,s],currentAssistantMessageId:l.role==="assistant"?i:u.currentAssistantMessageId})),i},updateMessage:(l,i)=>{t(s=>({messages:s.messages.map(u=>u.id===l?{...u,...i}:u)}))},appendToMessage:(l,i)=>{t(s=>({messages:s.messages.map(u=>u.id===l?{...u,content:u.content+i}:u)}))},finalizeMessage:l=>{t(i=>({messages:i.messages.map(s=>s.id===l?{...s,content:WS(s.content),streaming:!1}:s)}))},setToolResult:(l,i,s)=>{t(u=>({messages:u.messages.map(c=>c.id===l?{...c,toolResult:i,isError:!s,progressLines:void 0}:c)}))},appendToolProgress:(l,i)=>{t(s=>({messages:s.messages.map(u=>{if(u.id!==l)return u;const d=[...u.progressLines??[],i],p=d.length>30?d.slice(d.length-30):d;return{...u,progressLines:p}})}))},setLoading:l=>t({isLoading:l}),setAbortController:l=>t({abortController:l}),clearMessages:()=>t({messages:[],currentAssistantMessageId:null,currentToolId:null,executions:new Map}),setCurrentAssistantMessage:l=>t({currentAssistantMessageId:l}),setCurrentToolId:l=>t({currentToolId:l}),truncateAfter:l=>t(i=>{const s=i.messages.findIndex(u=>u.id===l);return s===-1?i:{messages:i.messages.slice(0,s),currentAssistantMessageId:null,currentToolId:null}}),addExecution:l=>{t(i=>{const s=new Map(i.executions);return s.set(l.id,l),{executions:s}})},updateExecution:(l,i)=>{t(s=>{const u=new Map(s.executions),c=u.get(l);return c&&u.set(l,{...c,...i}),{executions:u}})},enqueue:l=>t(i=>({queue:[...i.queue,l]})),dequeue:()=>{const l=r().queue;if(l.length===0)return null;const[i,...s]=l;return t({queue:s}),i},removeQueued:l=>t(i=>({queue:i.queue.filter((s,u)=>u!==l)})),clearQueue:()=>t({queue:[]}),setRunStart:l=>t({runStart:l})}),{name:"wrongstack-chat",partialize:()=>({})})),Ge=xa()(Es(t=>({provider:"anthropic",model:"claude-sonnet-4-20250514",wsUrl:(()=>{var l;if(typeof window>"u"||!((l=window.location)!=null&&l.hostname))return"ws://127.0.0.1:3457";const r=window.location.hostname.toLowerCase();return r==="localhost"||r==="127.0.0.1"||r==="[::1]"||r==="::1"?"ws://127.0.0.1:3457":`ws://${window.location.hostname}:3457`})(),wsConnected:!1,wsStatus:{state:"connecting"},theme:"system",autoConnect:!0,soundOnComplete:!1,setProvider:r=>t({provider:r}),setModel:r=>t({model:r}),setConfig:r=>t(r),setTheme:r=>t({theme:r}),setWsConnected:r=>t({wsConnected:r}),setWsStatus:r=>t({wsStatus:r,wsConnected:r.state==="open"}),setSoundOnComplete:r=>t({soundOnComplete:r})}),{name:"wrongstack-config"})),Ye=xa()(Es(t=>({session:null,totalTokens:{input:0,output:0,cacheRead:0,cacheWrite:0},lastInputTokens:0,cost:0,startTime:null,maxContext:0,inputCost:0,outputCost:0,cacheReadCost:0,projectName:"",mode:"default",modes:[],iteration:null,todos:[],setSession:r=>t({session:r}),updateUsage:r=>t(l=>({totalTokens:{input:l.totalTokens.input+r.input,output:l.totalTokens.output+r.output,cacheRead:(l.totalTokens.cacheRead??0)+(r.cacheRead??0),cacheWrite:(l.totalTokens.cacheWrite??0)+(r.cacheWrite??0)},lastInputTokens:r.input||l.lastInputTokens})),addCost:r=>t(l=>({cost:l.cost+r})),startSession:r=>t({session:r,startTime:Date.now(),iteration:null,lastInputTokens:0,totalTokens:{input:0,output:0,cacheRead:0,cacheWrite:0},cost:0}),endSession:()=>t({session:null,startTime:null,iteration:null}),setEnv:r=>t(l=>({maxContext:r.maxContext??l.maxContext,projectName:r.projectName??l.projectName,mode:r.mode??l.mode,inputCost:r.inputCost??l.inputCost,outputCost:r.outputCost??l.outputCost,cacheReadCost:r.cacheReadCost??l.cacheReadCost})),setIteration:r=>t({iteration:r}),setModes:r=>t({modes:r}),setTodos:r=>t({todos:r})}),{name:"wrongstack-session",partialize:()=>({})})),Ce=xa()(Es(t=>({sidebarOpen:!0,settingsOpen:!1,currentView:"chat",showConfirmDialog:!1,confirmInfo:null,paletteOpen:!1,shortcutsOpen:!1,searchOpen:!1,searchQuery:"",promptHistory:[],sidebarWidth:288,pinnedIds:[],compactMode:!1,modelSwitcherOpen:!1,favoriteSessionIds:[],sessionNicknames:{},toggleSidebar:()=>t(r=>({sidebarOpen:!r.sidebarOpen})),setSidebarOpen:r=>t({sidebarOpen:r}),setSettingsOpen:r=>t({settingsOpen:r}),setCurrentView:r=>t({currentView:r}),showConfirm:r=>t({showConfirmDialog:!0,confirmInfo:r}),hideConfirm:()=>t({showConfirmDialog:!1,confirmInfo:null}),setPaletteOpen:r=>t({paletteOpen:r}),setShortcutsOpen:r=>t({shortcutsOpen:r}),setSearchOpen:r=>t({searchOpen:r,searchQuery:""}),setSearchQuery:r=>t({searchQuery:r}),pushPrompt:r=>t(l=>{const i=r.trim();if(!i)return l;const s=l.promptHistory.filter(u=>u!==i);return{promptHistory:[i,...s].slice(0,50)}}),setSidebarWidth:r=>t({sidebarWidth:Math.max(200,Math.min(480,Math.round(r)))}),togglePin:r=>t(l=>({pinnedIds:l.pinnedIds.includes(r)?l.pinnedIds.filter(s=>s!==r):[...l.pinnedIds,r]})),unpinAll:()=>t({pinnedIds:[]}),toggleCompactMode:()=>t(r=>({compactMode:!r.compactMode})),setModelSwitcherOpen:r=>t({modelSwitcherOpen:r}),toggleFavoriteSession:r=>t(l=>({favoriteSessionIds:l.favoriteSessionIds.includes(r)?l.favoriteSessionIds.filter(s=>s!==r):[...l.favoriteSessionIds,r]})),setSessionNickname:(r,l)=>t(i=>{const s=l.trim(),u={...i.sessionNicknames};return s?u[r]=s:delete u[r],{sessionNicknames:u}})}),{name:"wrongstack-ui",partialize:t=>({sidebarOpen:t.sidebarOpen,sidebarWidth:t.sidebarWidth,promptHistory:t.promptHistory,pinnedIds:t.pinnedIds,compactMode:t.compactMode,favoriteSessionIds:t.favoriteSessionIds,sessionNicknames:t.sessionNicknames})})),da=xa()(t=>({entries:[],loading:!1,error:null,setEntries:(r,l=null)=>t({entries:r,error:l,loading:!1}),setLoading:r=>t({loading:r}),removeEntry:r=>t(l=>({entries:l.entries.filter(i=>i.id!==r)})),clearHistory:()=>t({entries:[]})})),Sx=w.createContext(void 0);function ew({children:t,defaultTheme:r="system",storageKey:l="wrongstack-theme"}){const{theme:i,setTheme:s}=Ge(),[u,c]=w.useState(()=>typeof window<"u"&&localStorage.getItem(l)||r);w.useEffect(()=>{const p=window.document.documentElement;if(p.classList.remove("light","dark"),u==="system"){const m=window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light";p.classList.add(m)}else p.classList.add(u)},[u]);const d={theme:u,setTheme:p=>{localStorage.setItem(l,p),c(p),s(p)}};return h.jsx(Sx.Provider,{value:d,children:t})}function wx(){const t=w.useContext(Sx);if(t===void 0)throw new Error("useTheme must be used within a ThemeProvider");return t}var kx=vx();const tw=Ri(kx);function ry(t,r){if(typeof t=="function")return t(r);t!=null&&(t.current=r)}function sd(...t){return r=>{let l=!1;const i=t.map(s=>{const u=ry(s,r);return!l&&typeof u=="function"&&(l=!0),u});if(l)return()=>{for(let s=0;s<i.length;s++){const u=i[s];typeof u=="function"?u():ry(t[s],null)}}}}function It(...t){return w.useCallback(sd(...t),t)}function ys(t){const r=nw(t),l=w.forwardRef((i,s)=>{const{children:u,...c}=i,d=w.Children.toArray(u),p=d.find(lw);if(p){const m=p.props.children,x=d.map(y=>y===p?w.Children.count(m)>1?w.Children.only(null):w.isValidElement(m)?m.props.children:null:y);return h.jsx(r,{...c,ref:s,children:w.isValidElement(m)?w.cloneElement(m,void 0,x):null})}return h.jsx(r,{...c,ref:s,children:u})});return l.displayName=`${t}.Slot`,l}function nw(t){const r=w.forwardRef((l,i)=>{const{children:s,...u}=l;if(w.isValidElement(s)){const c=iw(s),d=aw(u,s.props);return s.type!==w.Fragment&&(d.ref=i?sd(i,c):c),w.cloneElement(s,d)}return w.Children.count(s)>1?w.Children.only(null):null});return r.displayName=`${t}.SlotClone`,r}var rw=Symbol("radix.slottable");function lw(t){return w.isValidElement(t)&&typeof t.type=="function"&&"__radixId"in t.type&&t.type.__radixId===rw}function aw(t,r){const l={...r};for(const i in r){const s=t[i],u=r[i];/^on[A-Z]/.test(i)?s&&u?l[i]=(...d)=>{const p=u(...d);return s(...d),p}:s&&(l[i]=s):i==="style"?l[i]={...s,...u}:i==="className"&&(l[i]=[s,u].filter(Boolean).join(" "))}return{...t,...l}}function iw(t){var i,s;let r=(i=Object.getOwnPropertyDescriptor(t.props,"ref"))==null?void 0:i.get,l=r&&"isReactWarning"in r&&r.isReactWarning;return l?t.ref:(r=(s=Object.getOwnPropertyDescriptor(t,"ref"))==null?void 0:s.get,l=r&&"isReactWarning"in r&&r.isReactWarning,l?t.props.ref:t.props.ref||t.ref)}var ow=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Tt=ow.reduce((t,r)=>{const l=ys(`Primitive.${r}`),i=w.forwardRef((s,u)=>{const{asChild:c,...d}=s,p=c?l:r;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),h.jsx(p,{...d,ref:u})});return i.displayName=`Primitive.${r}`,{...t,[r]:i}},{});function sw(t,r){t&&kx.flushSync(()=>t.dispatchEvent(r))}var ha=globalThis!=null&&globalThis.document?w.useLayoutEffect:()=>{};function uw(t,r){return w.useReducer((l,i)=>r[l][i]??l,t)}var sr=t=>{const{present:r,children:l}=t,i=cw(r),s=typeof l=="function"?l({present:i.isPresent}):w.Children.only(l),u=It(i.ref,fw(s));return typeof l=="function"||i.isPresent?w.cloneElement(s,{ref:u}):null};sr.displayName="Presence";function cw(t){const[r,l]=w.useState(),i=w.useRef(null),s=w.useRef(t),u=w.useRef("none"),c=t?"mounted":"unmounted",[d,p]=uw(c,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return w.useEffect(()=>{const m=ns(i.current);u.current=d==="mounted"?m:"none"},[d]),ha(()=>{const m=i.current,x=s.current;if(x!==t){const b=u.current,S=ns(m);t?p("MOUNT"):S==="none"||(m==null?void 0:m.display)==="none"?p("UNMOUNT"):p(x&&b!==S?"ANIMATION_OUT":"UNMOUNT"),s.current=t}},[t,p]),ha(()=>{if(r){let m;const x=r.ownerDocument.defaultView??window,y=S=>{const N=ns(i.current).includes(CSS.escape(S.animationName));if(S.target===r&&N&&(p("ANIMATION_END"),!s.current)){const A=r.style.animationFillMode;r.style.animationFillMode="forwards",m=x.setTimeout(()=>{r.style.animationFillMode==="forwards"&&(r.style.animationFillMode=A)})}},b=S=>{S.target===r&&(u.current=ns(i.current))};return r.addEventListener("animationstart",b),r.addEventListener("animationcancel",y),r.addEventListener("animationend",y),()=>{x.clearTimeout(m),r.removeEventListener("animationstart",b),r.removeEventListener("animationcancel",y),r.removeEventListener("animationend",y)}}else p("ANIMATION_END")},[r,p]),{isPresent:["mounted","unmountSuspended"].includes(d),ref:w.useCallback(m=>{i.current=m?getComputedStyle(m):null,l(m)},[])}}function ns(t){return(t==null?void 0:t.animationName)||"none"}function fw(t){var i,s;let r=(i=Object.getOwnPropertyDescriptor(t.props,"ref"))==null?void 0:i.get,l=r&&"isReactWarning"in r&&r.isReactWarning;return l?t.ref:(r=(s=Object.getOwnPropertyDescriptor(t,"ref"))==null?void 0:s.get,l=r&&"isReactWarning"in r&&r.isReactWarning,l?t.props.ref:t.props.ref||t.ref)}function dw(t,r){const l=w.createContext(r),i=u=>{const{children:c,...d}=u,p=w.useMemo(()=>d,Object.values(d));return h.jsx(l.Provider,{value:p,children:c})};i.displayName=t+"Provider";function s(u){const c=w.useContext(l);if(c)return c;if(r!==void 0)return r;throw new Error(`\`${u}\` must be used within \`${t}\``)}return[i,s]}function zi(t,r=[]){let l=[];function i(u,c){const d=w.createContext(c),p=l.length;l=[...l,c];const m=y=>{var j;const{scope:b,children:S,...k}=y,N=((j=b==null?void 0:b[t])==null?void 0:j[p])||d,A=w.useMemo(()=>k,Object.values(k));return h.jsx(N.Provider,{value:A,children:S})};m.displayName=u+"Provider";function x(y,b){var N;const S=((N=b==null?void 0:b[t])==null?void 0:N[p])||d,k=w.useContext(S);if(k)return k;if(c!==void 0)return c;throw new Error(`\`${y}\` must be used within \`${u}\``)}return[m,x]}const s=()=>{const u=l.map(c=>w.createContext(c));return function(d){const p=(d==null?void 0:d[t])||u;return w.useMemo(()=>({[`__scope${t}`]:{...d,[t]:p}}),[d,p])}};return s.scopeName=t,[i,hw(s,...r)]}function hw(...t){const r=t[0];if(t.length===1)return r;const l=()=>{const i=t.map(s=>({useScope:s(),scopeName:s.scopeName}));return function(u){const c=i.reduce((d,{useScope:p,scopeName:m})=>{const y=p(u)[`__scope${m}`];return{...d,...y}},{});return w.useMemo(()=>({[`__scope${r.scopeName}`]:c}),[c])}};return l.scopeName=r.scopeName,l}function hn(t){const r=w.useRef(t);return w.useEffect(()=>{r.current=t}),w.useMemo(()=>(...l)=>{var i;return(i=r.current)==null?void 0:i.call(r,...l)},[])}var mw=w.createContext(void 0);function ud(t){const r=w.useContext(mw);return t||r||"ltr"}function pw(t,[r,l]){return Math.min(l,Math.max(r,t))}function gt(t,r,{checkForDefaultPrevented:l=!0}={}){return function(s){if(t==null||t(s),l===!1||!s.defaultPrevented)return r==null?void 0:r(s)}}function gw(t,r){return w.useReducer((l,i)=>r[l][i]??l,t)}var cd="ScrollArea",[Cx]=zi(cd),[yw,En]=Cx(cd),Nx=w.forwardRef((t,r)=>{const{__scopeScrollArea:l,type:i="hover",dir:s,scrollHideDelay:u=600,...c}=t,[d,p]=w.useState(null),[m,x]=w.useState(null),[y,b]=w.useState(null),[S,k]=w.useState(null),[N,A]=w.useState(null),[j,M]=w.useState(0),[z,V]=w.useState(0),[Q,B]=w.useState(!1),[G,ae]=w.useState(!1),se=It(r,P=>p(P)),L=ud(s);return h.jsx(yw,{scope:l,type:i,dir:L,scrollHideDelay:u,scrollArea:d,viewport:m,onViewportChange:x,content:y,onContentChange:b,scrollbarX:S,onScrollbarXChange:k,scrollbarXEnabled:Q,onScrollbarXEnabledChange:B,scrollbarY:N,onScrollbarYChange:A,scrollbarYEnabled:G,onScrollbarYEnabledChange:ae,onCornerWidthChange:M,onCornerHeightChange:V,children:h.jsx(Tt.div,{dir:L,...c,ref:se,style:{position:"relative","--radix-scroll-area-corner-width":j+"px","--radix-scroll-area-corner-height":z+"px",...t.style}})})});Nx.displayName=cd;var Ex="ScrollAreaViewport",jx=w.forwardRef((t,r)=>{const{__scopeScrollArea:l,children:i,nonce:s,...u}=t,c=En(Ex,l),d=w.useRef(null),p=It(r,d,c.onViewportChange);return h.jsxs(h.Fragment,{children:[h.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}"},nonce:s}),h.jsx(Tt.div,{"data-radix-scroll-area-viewport":"",...u,ref:p,style:{overflowX:c.scrollbarXEnabled?"scroll":"hidden",overflowY:c.scrollbarYEnabled?"scroll":"hidden",...t.style},children:h.jsx("div",{ref:c.onContentChange,style:{minWidth:"100%",display:"table"},children:i})})]})});jx.displayName=Ex;var qn="ScrollAreaScrollbar",fd=w.forwardRef((t,r)=>{const{forceMount:l,...i}=t,s=En(qn,t.__scopeScrollArea),{onScrollbarXEnabledChange:u,onScrollbarYEnabledChange:c}=s,d=t.orientation==="horizontal";return w.useEffect(()=>(d?u(!0):c(!0),()=>{d?u(!1):c(!1)}),[d,u,c]),s.type==="hover"?h.jsx(xw,{...i,ref:r,forceMount:l}):s.type==="scroll"?h.jsx(bw,{...i,ref:r,forceMount:l}):s.type==="auto"?h.jsx(Tx,{...i,ref:r,forceMount:l}):s.type==="always"?h.jsx(dd,{...i,ref:r}):null});fd.displayName=qn;var xw=w.forwardRef((t,r)=>{const{forceMount:l,...i}=t,s=En(qn,t.__scopeScrollArea),[u,c]=w.useState(!1);return w.useEffect(()=>{const d=s.scrollArea;let p=0;if(d){const m=()=>{window.clearTimeout(p),c(!0)},x=()=>{p=window.setTimeout(()=>c(!1),s.scrollHideDelay)};return d.addEventListener("pointerenter",m),d.addEventListener("pointerleave",x),()=>{window.clearTimeout(p),d.removeEventListener("pointerenter",m),d.removeEventListener("pointerleave",x)}}},[s.scrollArea,s.scrollHideDelay]),h.jsx(sr,{present:l||u,children:h.jsx(Tx,{"data-state":u?"visible":"hidden",...i,ref:r})})}),bw=w.forwardRef((t,r)=>{const{forceMount:l,...i}=t,s=En(qn,t.__scopeScrollArea),u=t.orientation==="horizontal",c=Ts(()=>p("SCROLL_END"),100),[d,p]=gw("hidden",{hidden:{SCROLL:"scrolling"},scrolling:{SCROLL_END:"idle",POINTER_ENTER:"interacting"},interacting:{SCROLL:"interacting",POINTER_LEAVE:"idle"},idle:{HIDE:"hidden",SCROLL:"scrolling",POINTER_ENTER:"interacting"}});return w.useEffect(()=>{if(d==="idle"){const m=window.setTimeout(()=>p("HIDE"),s.scrollHideDelay);return()=>window.clearTimeout(m)}},[d,s.scrollHideDelay,p]),w.useEffect(()=>{const m=s.viewport,x=u?"scrollLeft":"scrollTop";if(m){let y=m[x];const b=()=>{const S=m[x];y!==S&&(p("SCROLL"),c()),y=S};return m.addEventListener("scroll",b),()=>m.removeEventListener("scroll",b)}},[s.viewport,u,p,c]),h.jsx(sr,{present:l||d!=="hidden",children:h.jsx(dd,{"data-state":d==="hidden"?"hidden":"visible",...i,ref:r,onPointerEnter:gt(t.onPointerEnter,()=>p("POINTER_ENTER")),onPointerLeave:gt(t.onPointerLeave,()=>p("POINTER_LEAVE"))})})}),Tx=w.forwardRef((t,r)=>{const l=En(qn,t.__scopeScrollArea),{forceMount:i,...s}=t,[u,c]=w.useState(!1),d=t.orientation==="horizontal",p=Ts(()=>{if(l.viewport){const m=l.viewport.offsetWidth<l.viewport.scrollWidth,x=l.viewport.offsetHeight<l.viewport.scrollHeight;c(d?m:x)}},10);return ma(l.viewport,p),ma(l.content,p),h.jsx(sr,{present:i||u,children:h.jsx(dd,{"data-state":u?"visible":"hidden",...s,ref:r})})}),dd=w.forwardRef((t,r)=>{const{orientation:l="vertical",...i}=t,s=En(qn,t.__scopeScrollArea),u=w.useRef(null),c=w.useRef(0),[d,p]=w.useState({content:0,viewport:0,scrollbar:{size:0,paddingStart:0,paddingEnd:0}}),m=zx(d.viewport,d.content),x={...i,sizes:d,onSizesChange:p,hasThumb:m>0&&m<1,onThumbChange:b=>u.current=b,onThumbPointerUp:()=>c.current=0,onThumbPointerDown:b=>c.current=b};function y(b,S){return Nw(b,c.current,d,S)}return l==="horizontal"?h.jsx(vw,{...x,ref:r,onThumbPositionChange:()=>{if(s.viewport&&u.current){const b=s.viewport.scrollLeft,S=ly(b,d,s.dir);u.current.style.transform=`translate3d(${S}px, 0, 0)`}},onWheelScroll:b=>{s.viewport&&(s.viewport.scrollLeft=b)},onDragScroll:b=>{s.viewport&&(s.viewport.scrollLeft=y(b,s.dir))}}):l==="vertical"?h.jsx(Sw,{...x,ref:r,onThumbPositionChange:()=>{if(s.viewport&&u.current){const b=s.viewport.scrollTop,S=ly(b,d);u.current.style.transform=`translate3d(0, ${S}px, 0)`}},onWheelScroll:b=>{s.viewport&&(s.viewport.scrollTop=b)},onDragScroll:b=>{s.viewport&&(s.viewport.scrollTop=y(b))}}):null}),vw=w.forwardRef((t,r)=>{const{sizes:l,onSizesChange:i,...s}=t,u=En(qn,t.__scopeScrollArea),[c,d]=w.useState(),p=w.useRef(null),m=It(r,p,u.onScrollbarXChange);return w.useEffect(()=>{p.current&&d(getComputedStyle(p.current))},[p]),h.jsx(Mx,{"data-orientation":"horizontal",...s,ref:m,sizes:l,style:{bottom:0,left:u.dir==="rtl"?"var(--radix-scroll-area-corner-width)":0,right:u.dir==="ltr"?"var(--radix-scroll-area-corner-width)":0,"--radix-scroll-area-thumb-width":js(l)+"px",...t.style},onThumbPointerDown:x=>t.onThumbPointerDown(x.x),onDragScroll:x=>t.onDragScroll(x.x),onWheelScroll:(x,y)=>{if(u.viewport){const b=u.viewport.scrollLeft+x.deltaX;t.onWheelScroll(b),_x(b,y)&&x.preventDefault()}},onResize:()=>{p.current&&u.viewport&&c&&i({content:u.viewport.scrollWidth,viewport:u.viewport.offsetWidth,scrollbar:{size:p.current.clientWidth,paddingStart:bs(c.paddingLeft),paddingEnd:bs(c.paddingRight)}})}})}),Sw=w.forwardRef((t,r)=>{const{sizes:l,onSizesChange:i,...s}=t,u=En(qn,t.__scopeScrollArea),[c,d]=w.useState(),p=w.useRef(null),m=It(r,p,u.onScrollbarYChange);return w.useEffect(()=>{p.current&&d(getComputedStyle(p.current))},[p]),h.jsx(Mx,{"data-orientation":"vertical",...s,ref:m,sizes:l,style:{top:0,right:u.dir==="ltr"?0:void 0,left:u.dir==="rtl"?0:void 0,bottom:"var(--radix-scroll-area-corner-height)","--radix-scroll-area-thumb-height":js(l)+"px",...t.style},onThumbPointerDown:x=>t.onThumbPointerDown(x.y),onDragScroll:x=>t.onDragScroll(x.y),onWheelScroll:(x,y)=>{if(u.viewport){const b=u.viewport.scrollTop+x.deltaY;t.onWheelScroll(b),_x(b,y)&&x.preventDefault()}},onResize:()=>{p.current&&u.viewport&&c&&i({content:u.viewport.scrollHeight,viewport:u.viewport.offsetHeight,scrollbar:{size:p.current.clientHeight,paddingStart:bs(c.paddingTop),paddingEnd:bs(c.paddingBottom)}})}})}),[ww,Ax]=Cx(qn),Mx=w.forwardRef((t,r)=>{const{__scopeScrollArea:l,sizes:i,hasThumb:s,onThumbChange:u,onThumbPointerUp:c,onThumbPointerDown:d,onThumbPositionChange:p,onDragScroll:m,onWheelScroll:x,onResize:y,...b}=t,S=En(qn,l),[k,N]=w.useState(null),A=It(r,se=>N(se)),j=w.useRef(null),M=w.useRef(""),z=S.viewport,V=i.content-i.viewport,Q=hn(x),B=hn(p),G=Ts(y,10);function ae(se){if(j.current){const L=se.clientX-j.current.left,P=se.clientY-j.current.top;m({x:L,y:P})}}return w.useEffect(()=>{const se=L=>{const P=L.target;(k==null?void 0:k.contains(P))&&Q(L,V)};return document.addEventListener("wheel",se,{passive:!1}),()=>document.removeEventListener("wheel",se,{passive:!1})},[z,k,V,Q]),w.useEffect(B,[i,B]),ma(k,G),ma(S.content,G),h.jsx(ww,{scope:l,scrollbar:k,hasThumb:s,onThumbChange:hn(u),onThumbPointerUp:hn(c),onThumbPositionChange:B,onThumbPointerDown:hn(d),children:h.jsx(Tt.div,{...b,ref:A,style:{position:"absolute",...b.style},onPointerDown:gt(t.onPointerDown,se=>{se.button===0&&(se.target.setPointerCapture(se.pointerId),j.current=k.getBoundingClientRect(),M.current=document.body.style.webkitUserSelect,document.body.style.webkitUserSelect="none",S.viewport&&(S.viewport.style.scrollBehavior="auto"),ae(se))}),onPointerMove:gt(t.onPointerMove,ae),onPointerUp:gt(t.onPointerUp,se=>{const L=se.target;L.hasPointerCapture(se.pointerId)&&L.releasePointerCapture(se.pointerId),document.body.style.webkitUserSelect=M.current,S.viewport&&(S.viewport.style.scrollBehavior=""),j.current=null})})})}),xs="ScrollAreaThumb",Dx=w.forwardRef((t,r)=>{const{forceMount:l,...i}=t,s=Ax(xs,t.__scopeScrollArea);return h.jsx(sr,{present:l||s.hasThumb,children:h.jsx(kw,{ref:r,...i})})}),kw=w.forwardRef((t,r)=>{const{__scopeScrollArea:l,style:i,...s}=t,u=En(xs,l),c=Ax(xs,l),{onThumbPositionChange:d}=c,p=It(r,y=>c.onThumbChange(y)),m=w.useRef(void 0),x=Ts(()=>{m.current&&(m.current(),m.current=void 0)},100);return w.useEffect(()=>{const y=u.viewport;if(y){const b=()=>{if(x(),!m.current){const S=Ew(y,d);m.current=S,d()}};return d(),y.addEventListener("scroll",b),()=>y.removeEventListener("scroll",b)}},[u.viewport,x,d]),h.jsx(Tt.div,{"data-state":c.hasThumb?"visible":"hidden",...s,ref:p,style:{width:"var(--radix-scroll-area-thumb-width)",height:"var(--radix-scroll-area-thumb-height)",...i},onPointerDownCapture:gt(t.onPointerDownCapture,y=>{const S=y.target.getBoundingClientRect(),k=y.clientX-S.left,N=y.clientY-S.top;c.onThumbPointerDown({x:k,y:N})}),onPointerUp:gt(t.onPointerUp,c.onThumbPointerUp)})});Dx.displayName=xs;var hd="ScrollAreaCorner",Rx=w.forwardRef((t,r)=>{const l=En(hd,t.__scopeScrollArea),i=!!(l.scrollbarX&&l.scrollbarY);return l.type!=="scroll"&&i?h.jsx(Cw,{...t,ref:r}):null});Rx.displayName=hd;var Cw=w.forwardRef((t,r)=>{const{__scopeScrollArea:l,...i}=t,s=En(hd,l),[u,c]=w.useState(0),[d,p]=w.useState(0),m=!!(u&&d);return ma(s.scrollbarX,()=>{var y;const x=((y=s.scrollbarX)==null?void 0:y.offsetHeight)||0;s.onCornerHeightChange(x),p(x)}),ma(s.scrollbarY,()=>{var y;const x=((y=s.scrollbarY)==null?void 0:y.offsetWidth)||0;s.onCornerWidthChange(x),c(x)}),m?h.jsx(Tt.div,{...i,ref:r,style:{width:u,height:d,position:"absolute",right:s.dir==="ltr"?0:void 0,left:s.dir==="rtl"?0:void 0,bottom:0,...t.style}}):null});function bs(t){return t?parseInt(t,10):0}function zx(t,r){const l=t/r;return isNaN(l)?0:l}function js(t){const r=zx(t.viewport,t.content),l=t.scrollbar.paddingStart+t.scrollbar.paddingEnd,i=(t.scrollbar.size-l)*r;return Math.max(i,18)}function Nw(t,r,l,i="ltr"){const s=js(l),u=s/2,c=r||u,d=s-c,p=l.scrollbar.paddingStart+c,m=l.scrollbar.size-l.scrollbar.paddingEnd-d,x=l.content-l.viewport,y=i==="ltr"?[0,x]:[x*-1,0];return Ox([p,m],y)(t)}function ly(t,r,l="ltr"){const i=js(r),s=r.scrollbar.paddingStart+r.scrollbar.paddingEnd,u=r.scrollbar.size-s,c=r.content-r.viewport,d=u-i,p=l==="ltr"?[0,c]:[c*-1,0],m=pw(t,p);return Ox([0,c],[0,d])(m)}function Ox(t,r){return l=>{if(t[0]===t[1]||r[0]===r[1])return r[0];const i=(r[1]-r[0])/(t[1]-t[0]);return r[0]+i*(l-t[0])}}function _x(t,r){return t>0&&t<r}var Ew=(t,r=()=>{})=>{let l={left:t.scrollLeft,top:t.scrollTop},i=0;return(function s(){const u={left:t.scrollLeft,top:t.scrollTop},c=l.left!==u.left,d=l.top!==u.top;(c||d)&&r(),l=u,i=window.requestAnimationFrame(s)})(),()=>window.cancelAnimationFrame(i)};function Ts(t,r){const l=hn(t),i=w.useRef(0);return w.useEffect(()=>()=>window.clearTimeout(i.current),[]),w.useCallback(()=>{window.clearTimeout(i.current),i.current=window.setTimeout(l,r)},[l,r])}function ma(t,r){const l=hn(r);ha(()=>{let i=0;if(t){const s=new ResizeObserver(()=>{cancelAnimationFrame(i),i=window.requestAnimationFrame(l)});return s.observe(t),()=>{window.cancelAnimationFrame(i),s.unobserve(t)}}},[t,l])}var Lx=Nx,jw=jx,Tw=Rx;function Ux(t){var r,l,i="";if(typeof t=="string"||typeof t=="number")i+=t;else if(typeof t=="object")if(Array.isArray(t)){var s=t.length;for(r=0;r<s;r++)t[r]&&(l=Ux(t[r]))&&(i&&(i+=" "),i+=l)}else for(l in t)t[l]&&(i&&(i+=" "),i+=l);return i}function Bx(){for(var t,r,l=0,i="",s=arguments.length;l<s;l++)(t=arguments[l])&&(r=Ux(t))&&(i&&(i+=" "),i+=r);return i}const md="-",Aw=t=>{const r=Dw(t),{conflictingClassGroups:l,conflictingClassGroupModifiers:i}=t;return{getClassGroupId:c=>{const d=c.split(md);return d[0]===""&&d.length!==1&&d.shift(),Hx(d,r)||Mw(c)},getConflictingClassGroupIds:(c,d)=>{const p=l[c]||[];return d&&i[c]?[...p,...i[c]]:p}}},Hx=(t,r)=>{var c;if(t.length===0)return r.classGroupId;const l=t[0],i=r.nextPart.get(l),s=i?Hx(t.slice(1),i):void 0;if(s)return s;if(r.validators.length===0)return;const u=t.join(md);return(c=r.validators.find(({validator:d})=>d(u)))==null?void 0:c.classGroupId},ay=/^\[(.+)\]$/,Mw=t=>{if(ay.test(t)){const r=ay.exec(t)[1],l=r==null?void 0:r.substring(0,r.indexOf(":"));if(l)return"arbitrary.."+l}},Dw=t=>{const{theme:r,prefix:l}=t,i={nextPart:new Map,validators:[]};return zw(Object.entries(t.classGroups),l).forEach(([u,c])=>{Uf(c,i,u,r)}),i},Uf=(t,r,l,i)=>{t.forEach(s=>{if(typeof s=="string"){const u=s===""?r:iy(r,s);u.classGroupId=l;return}if(typeof s=="function"){if(Rw(s)){Uf(s(i),r,l,i);return}r.validators.push({validator:s,classGroupId:l});return}Object.entries(s).forEach(([u,c])=>{Uf(c,iy(r,u),l,i)})})},iy=(t,r)=>{let l=t;return r.split(md).forEach(i=>{l.nextPart.has(i)||l.nextPart.set(i,{nextPart:new Map,validators:[]}),l=l.nextPart.get(i)}),l},Rw=t=>t.isThemeGetter,zw=(t,r)=>r?t.map(([l,i])=>{const s=i.map(u=>typeof u=="string"?r+u:typeof u=="object"?Object.fromEntries(Object.entries(u).map(([c,d])=>[r+c,d])):u);return[l,s]}):t,Ow=t=>{if(t<1)return{get:()=>{},set:()=>{}};let r=0,l=new Map,i=new Map;const s=(u,c)=>{l.set(u,c),r++,r>t&&(r=0,i=l,l=new Map)};return{get(u){let c=l.get(u);if(c!==void 0)return c;if((c=i.get(u))!==void 0)return s(u,c),c},set(u,c){l.has(u)?l.set(u,c):s(u,c)}}},qx="!",_w=t=>{const{separator:r,experimentalParseClassName:l}=t,i=r.length===1,s=r[0],u=r.length,c=d=>{const p=[];let m=0,x=0,y;for(let A=0;A<d.length;A++){let j=d[A];if(m===0){if(j===s&&(i||d.slice(A,A+u)===r)){p.push(d.slice(x,A)),x=A+u;continue}if(j==="/"){y=A;continue}}j==="["?m++:j==="]"&&m--}const b=p.length===0?d:d.substring(x),S=b.startsWith(qx),k=S?b.substring(1):b,N=y&&y>x?y-x:void 0;return{modifiers:p,hasImportantModifier:S,baseClassName:k,maybePostfixModifierPosition:N}};return l?d=>l({className:d,parseClassName:c}):c},Lw=t=>{if(t.length<=1)return t;const r=[];let l=[];return t.forEach(i=>{i[0]==="["?(r.push(...l.sort(),i),l=[]):l.push(i)}),r.push(...l.sort()),r},Uw=t=>({cache:Ow(t.cacheSize),parseClassName:_w(t),...Aw(t)}),Bw=/\s+/,Hw=(t,r)=>{const{parseClassName:l,getClassGroupId:i,getConflictingClassGroupIds:s}=r,u=[],c=t.trim().split(Bw);let d="";for(let p=c.length-1;p>=0;p-=1){const m=c[p],{modifiers:x,hasImportantModifier:y,baseClassName:b,maybePostfixModifierPosition:S}=l(m);let k=!!S,N=i(k?b.substring(0,S):b);if(!N){if(!k){d=m+(d.length>0?" "+d:d);continue}if(N=i(b),!N){d=m+(d.length>0?" "+d:d);continue}k=!1}const A=Lw(x).join(":"),j=y?A+qx:A,M=j+N;if(u.includes(M))continue;u.push(M);const z=s(N,k);for(let V=0;V<z.length;++V){const Q=z[V];u.push(j+Q)}d=m+(d.length>0?" "+d:d)}return d};function qw(){let t=0,r,l,i="";for(;t<arguments.length;)(r=arguments[t++])&&(l=Ix(r))&&(i&&(i+=" "),i+=l);return i}const Ix=t=>{if(typeof t=="string")return t;let r,l="";for(let i=0;i<t.length;i++)t[i]&&(r=Ix(t[i]))&&(l&&(l+=" "),l+=r);return l};function Iw(t,...r){let l,i,s,u=c;function c(p){const m=r.reduce((x,y)=>y(x),t());return l=Uw(m),i=l.cache.get,s=l.cache.set,u=d,d(p)}function d(p){const m=i(p);if(m)return m;const x=Hw(p,l);return s(p,x),x}return function(){return u(qw.apply(null,arguments))}}const ft=t=>{const r=l=>l[t]||[];return r.isThemeGetter=!0,r},Vx=/^\[(?:([a-z-]+):)?(.+)\]$/i,Vw=/^\d+\/\d+$/,$w=new Set(["px","full","screen"]),Fw=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Yw=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Gw=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,Pw=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Xw=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,or=t=>ua(t)||$w.has(t)||Vw.test(t),Lr=t=>ba(t,"length",n2),ua=t=>!!t&&!Number.isNaN(Number(t)),rf=t=>ba(t,"number",ua),gi=t=>!!t&&Number.isInteger(Number(t)),Qw=t=>t.endsWith("%")&&ua(t.slice(0,-1)),_e=t=>Vx.test(t),Ur=t=>Fw.test(t),Kw=new Set(["length","size","percentage"]),Zw=t=>ba(t,Kw,$x),Jw=t=>ba(t,"position",$x),Ww=new Set(["image","url"]),e2=t=>ba(t,Ww,l2),t2=t=>ba(t,"",r2),yi=()=>!0,ba=(t,r,l)=>{const i=Vx.exec(t);return i?i[1]?typeof r=="string"?i[1]===r:r.has(i[1]):l(i[2]):!1},n2=t=>Yw.test(t)&&!Gw.test(t),$x=()=>!1,r2=t=>Pw.test(t),l2=t=>Xw.test(t),a2=()=>{const t=ft("colors"),r=ft("spacing"),l=ft("blur"),i=ft("brightness"),s=ft("borderColor"),u=ft("borderRadius"),c=ft("borderSpacing"),d=ft("borderWidth"),p=ft("contrast"),m=ft("grayscale"),x=ft("hueRotate"),y=ft("invert"),b=ft("gap"),S=ft("gradientColorStops"),k=ft("gradientColorStopPositions"),N=ft("inset"),A=ft("margin"),j=ft("opacity"),M=ft("padding"),z=ft("saturate"),V=ft("scale"),Q=ft("sepia"),B=ft("skew"),G=ft("space"),ae=ft("translate"),se=()=>["auto","contain","none"],L=()=>["auto","hidden","clip","visible","scroll"],P=()=>["auto",_e,r],X=()=>[_e,r],de=()=>["",or,Lr],I=()=>["auto",ua,_e],J=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],H=()=>["solid","dashed","dotted","double","none"],ne=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],oe=()=>["start","end","center","between","around","evenly","stretch"],ye=()=>["","0",_e],D=()=>["auto","avoid","all","avoid-page","page","left","right","column"],T=()=>[ua,_e];return{cacheSize:500,separator:":",theme:{colors:[yi],spacing:[or,Lr],blur:["none","",Ur,_e],brightness:T(),borderColor:[t],borderRadius:["none","","full",Ur,_e],borderSpacing:X(),borderWidth:de(),contrast:T(),grayscale:ye(),hueRotate:T(),invert:ye(),gap:X(),gradientColorStops:[t],gradientColorStopPositions:[Qw,Lr],inset:P(),margin:P(),opacity:T(),padding:X(),saturate:T(),scale:T(),sepia:ye(),skew:T(),space:X(),translate:X()},classGroups:{aspect:[{aspect:["auto","square","video",_e]}],container:["container"],columns:[{columns:[Ur]}],"break-after":[{"break-after":D()}],"break-before":[{"break-before":D()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...J(),_e]}],overflow:[{overflow:L()}],"overflow-x":[{"overflow-x":L()}],"overflow-y":[{"overflow-y":L()}],overscroll:[{overscroll:se()}],"overscroll-x":[{"overscroll-x":se()}],"overscroll-y":[{"overscroll-y":se()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[N]}],"inset-x":[{"inset-x":[N]}],"inset-y":[{"inset-y":[N]}],start:[{start:[N]}],end:[{end:[N]}],top:[{top:[N]}],right:[{right:[N]}],bottom:[{bottom:[N]}],left:[{left:[N]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",gi,_e]}],basis:[{basis:P()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",_e]}],grow:[{grow:ye()}],shrink:[{shrink:ye()}],order:[{order:["first","last","none",gi,_e]}],"grid-cols":[{"grid-cols":[yi]}],"col-start-end":[{col:["auto",{span:["full",gi,_e]},_e]}],"col-start":[{"col-start":I()}],"col-end":[{"col-end":I()}],"grid-rows":[{"grid-rows":[yi]}],"row-start-end":[{row:["auto",{span:[gi,_e]},_e]}],"row-start":[{"row-start":I()}],"row-end":[{"row-end":I()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",_e]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",_e]}],gap:[{gap:[b]}],"gap-x":[{"gap-x":[b]}],"gap-y":[{"gap-y":[b]}],"justify-content":[{justify:["normal",...oe()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...oe(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...oe(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[M]}],px:[{px:[M]}],py:[{py:[M]}],ps:[{ps:[M]}],pe:[{pe:[M]}],pt:[{pt:[M]}],pr:[{pr:[M]}],pb:[{pb:[M]}],pl:[{pl:[M]}],m:[{m:[A]}],mx:[{mx:[A]}],my:[{my:[A]}],ms:[{ms:[A]}],me:[{me:[A]}],mt:[{mt:[A]}],mr:[{mr:[A]}],mb:[{mb:[A]}],ml:[{ml:[A]}],"space-x":[{"space-x":[G]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[G]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",_e,r]}],"min-w":[{"min-w":[_e,r,"min","max","fit"]}],"max-w":[{"max-w":[_e,r,"none","full","min","max","fit","prose",{screen:[Ur]},Ur]}],h:[{h:[_e,r,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[_e,r,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[_e,r,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[_e,r,"auto","min","max","fit"]}],"font-size":[{text:["base",Ur,Lr]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",rf]}],"font-family":[{font:[yi]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",_e]}],"line-clamp":[{"line-clamp":["none",ua,rf]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",or,_e]}],"list-image":[{"list-image":["none",_e]}],"list-style-type":[{list:["none","disc","decimal",_e]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[t]}],"placeholder-opacity":[{"placeholder-opacity":[j]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[t]}],"text-opacity":[{"text-opacity":[j]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...H(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",or,Lr]}],"underline-offset":[{"underline-offset":["auto",or,_e]}],"text-decoration-color":[{decoration:[t]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:X()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",_e]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",_e]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[j]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...J(),Jw]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",Zw]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},e2]}],"bg-color":[{bg:[t]}],"gradient-from-pos":[{from:[k]}],"gradient-via-pos":[{via:[k]}],"gradient-to-pos":[{to:[k]}],"gradient-from":[{from:[S]}],"gradient-via":[{via:[S]}],"gradient-to":[{to:[S]}],rounded:[{rounded:[u]}],"rounded-s":[{"rounded-s":[u]}],"rounded-e":[{"rounded-e":[u]}],"rounded-t":[{"rounded-t":[u]}],"rounded-r":[{"rounded-r":[u]}],"rounded-b":[{"rounded-b":[u]}],"rounded-l":[{"rounded-l":[u]}],"rounded-ss":[{"rounded-ss":[u]}],"rounded-se":[{"rounded-se":[u]}],"rounded-ee":[{"rounded-ee":[u]}],"rounded-es":[{"rounded-es":[u]}],"rounded-tl":[{"rounded-tl":[u]}],"rounded-tr":[{"rounded-tr":[u]}],"rounded-br":[{"rounded-br":[u]}],"rounded-bl":[{"rounded-bl":[u]}],"border-w":[{border:[d]}],"border-w-x":[{"border-x":[d]}],"border-w-y":[{"border-y":[d]}],"border-w-s":[{"border-s":[d]}],"border-w-e":[{"border-e":[d]}],"border-w-t":[{"border-t":[d]}],"border-w-r":[{"border-r":[d]}],"border-w-b":[{"border-b":[d]}],"border-w-l":[{"border-l":[d]}],"border-opacity":[{"border-opacity":[j]}],"border-style":[{border:[...H(),"hidden"]}],"divide-x":[{"divide-x":[d]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[d]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[j]}],"divide-style":[{divide:H()}],"border-color":[{border:[s]}],"border-color-x":[{"border-x":[s]}],"border-color-y":[{"border-y":[s]}],"border-color-s":[{"border-s":[s]}],"border-color-e":[{"border-e":[s]}],"border-color-t":[{"border-t":[s]}],"border-color-r":[{"border-r":[s]}],"border-color-b":[{"border-b":[s]}],"border-color-l":[{"border-l":[s]}],"divide-color":[{divide:[s]}],"outline-style":[{outline:["",...H()]}],"outline-offset":[{"outline-offset":[or,_e]}],"outline-w":[{outline:[or,Lr]}],"outline-color":[{outline:[t]}],"ring-w":[{ring:de()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[t]}],"ring-opacity":[{"ring-opacity":[j]}],"ring-offset-w":[{"ring-offset":[or,Lr]}],"ring-offset-color":[{"ring-offset":[t]}],shadow:[{shadow:["","inner","none",Ur,t2]}],"shadow-color":[{shadow:[yi]}],opacity:[{opacity:[j]}],"mix-blend":[{"mix-blend":[...ne(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":ne()}],filter:[{filter:["","none"]}],blur:[{blur:[l]}],brightness:[{brightness:[i]}],contrast:[{contrast:[p]}],"drop-shadow":[{"drop-shadow":["","none",Ur,_e]}],grayscale:[{grayscale:[m]}],"hue-rotate":[{"hue-rotate":[x]}],invert:[{invert:[y]}],saturate:[{saturate:[z]}],sepia:[{sepia:[Q]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[l]}],"backdrop-brightness":[{"backdrop-brightness":[i]}],"backdrop-contrast":[{"backdrop-contrast":[p]}],"backdrop-grayscale":[{"backdrop-grayscale":[m]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[x]}],"backdrop-invert":[{"backdrop-invert":[y]}],"backdrop-opacity":[{"backdrop-opacity":[j]}],"backdrop-saturate":[{"backdrop-saturate":[z]}],"backdrop-sepia":[{"backdrop-sepia":[Q]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[c]}],"border-spacing-x":[{"border-spacing-x":[c]}],"border-spacing-y":[{"border-spacing-y":[c]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",_e]}],duration:[{duration:T()}],ease:[{ease:["linear","in","out","in-out",_e]}],delay:[{delay:T()}],animate:[{animate:["none","spin","ping","pulse","bounce",_e]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[V]}],"scale-x":[{"scale-x":[V]}],"scale-y":[{"scale-y":[V]}],rotate:[{rotate:[gi,_e]}],"translate-x":[{"translate-x":[ae]}],"translate-y":[{"translate-y":[ae]}],"skew-x":[{"skew-x":[B]}],"skew-y":[{"skew-y":[B]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",_e]}],accent:[{accent:["auto",t]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",_e]}],"caret-color":[{caret:[t]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":X()}],"scroll-mx":[{"scroll-mx":X()}],"scroll-my":[{"scroll-my":X()}],"scroll-ms":[{"scroll-ms":X()}],"scroll-me":[{"scroll-me":X()}],"scroll-mt":[{"scroll-mt":X()}],"scroll-mr":[{"scroll-mr":X()}],"scroll-mb":[{"scroll-mb":X()}],"scroll-ml":[{"scroll-ml":X()}],"scroll-p":[{"scroll-p":X()}],"scroll-px":[{"scroll-px":X()}],"scroll-py":[{"scroll-py":X()}],"scroll-ps":[{"scroll-ps":X()}],"scroll-pe":[{"scroll-pe":X()}],"scroll-pt":[{"scroll-pt":X()}],"scroll-pr":[{"scroll-pr":X()}],"scroll-pb":[{"scroll-pb":X()}],"scroll-pl":[{"scroll-pl":X()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",_e]}],fill:[{fill:[t,"none"]}],"stroke-w":[{stroke:[or,Lr,rf]}],stroke:[{stroke:[t,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},i2=Iw(a2);function he(...t){return i2(Bx(t))}const As=w.forwardRef(({className:t,children:r,...l},i)=>h.jsxs(Lx,{ref:i,className:he("relative overflow-hidden",t),...l,children:[h.jsx(jw,{className:"h-full w-full rounded-[inherit]",children:r}),h.jsx(Fx,{}),h.jsx(Tw,{})]}));As.displayName=Lx.displayName;const Fx=w.forwardRef(({className:t,orientation:r="vertical",...l},i)=>h.jsx(fd,{ref:i,orientation:r,className:he("flex touch-none select-none transition-colors",r==="vertical"&&"h-full w-2.5 border-l border-l-transparent p-[1px]",r==="horizontal"&&"h-2.5 flex-col border-t border-t-transparent p-[1px]",t),...l,children:h.jsx(Dx,{className:"relative flex-1 rounded-full bg-border"})}));Fx.displayName=fd.displayName;/**
|
|
54
|
-
* @license lucide-react v0.469.0 - ISC
|
|
55
|
-
*
|
|
56
|
-
* This source code is licensed under the ISC license.
|
|
57
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
58
|
-
*/const o2=t=>t.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Yx=(...t)=>t.filter((r,l,i)=>!!r&&r.trim()!==""&&i.indexOf(r)===l).join(" ").trim();/**
|
|
59
|
-
* @license lucide-react v0.469.0 - ISC
|
|
60
|
-
*
|
|
61
|
-
* This source code is licensed under the ISC license.
|
|
62
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
63
|
-
*/var s2={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
|
|
64
|
-
* @license lucide-react v0.469.0 - ISC
|
|
65
|
-
*
|
|
66
|
-
* This source code is licensed under the ISC license.
|
|
67
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
68
|
-
*/const u2=w.forwardRef(({color:t="currentColor",size:r=24,strokeWidth:l=2,absoluteStrokeWidth:i,className:s="",children:u,iconNode:c,...d},p)=>w.createElement("svg",{ref:p,...s2,width:r,height:r,stroke:t,strokeWidth:i?Number(l)*24/Number(r):l,className:Yx("lucide",s),...d},[...c.map(([m,x])=>w.createElement(m,x)),...Array.isArray(u)?u:[u]]));/**
|
|
69
|
-
* @license lucide-react v0.469.0 - ISC
|
|
70
|
-
*
|
|
71
|
-
* This source code is licensed under the ISC license.
|
|
72
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
73
|
-
*/const me=(t,r)=>{const l=w.forwardRef(({className:i,...s},u)=>w.createElement(u2,{ref:u,iconNode:r,className:Yx(`lucide-${o2(t)}`,i),...s}));return l.displayName=`${t}`,l};/**
|
|
74
|
-
* @license lucide-react v0.469.0 - ISC
|
|
75
|
-
*
|
|
76
|
-
* This source code is licensed under the ISC license.
|
|
77
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
78
|
-
*/const c2=me("Activity",[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]]);/**
|
|
79
|
-
* @license lucide-react v0.469.0 - ISC
|
|
80
|
-
*
|
|
81
|
-
* This source code is licensed under the ISC license.
|
|
82
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
83
|
-
*/const Gx=me("ArchiveRestore",[["rect",{width:"20",height:"5",x:"2",y:"3",rx:"1",key:"1wp1u1"}],["path",{d:"M4 8v11a2 2 0 0 0 2 2h2",key:"tvwodi"}],["path",{d:"M20 8v11a2 2 0 0 1-2 2h-2",key:"1gkqxj"}],["path",{d:"m9 15 3-3 3 3",key:"1pd0qc"}],["path",{d:"M12 12v9",key:"192myk"}]]);/**
|
|
84
|
-
* @license lucide-react v0.469.0 - ISC
|
|
85
|
-
*
|
|
86
|
-
* This source code is licensed under the ISC license.
|
|
87
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
88
|
-
*/const Px=me("ArrowDown",[["path",{d:"M12 5v14",key:"s699le"}],["path",{d:"m19 12-7 7-7-7",key:"1idqje"}]]);/**
|
|
89
|
-
* @license lucide-react v0.469.0 - ISC
|
|
90
|
-
*
|
|
91
|
-
* This source code is licensed under the ISC license.
|
|
92
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
93
|
-
*/const Xx=me("ArrowRight",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]]);/**
|
|
94
|
-
* @license lucide-react v0.469.0 - ISC
|
|
95
|
-
*
|
|
96
|
-
* This source code is licensed under the ISC license.
|
|
97
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
98
|
-
*/const Qx=me("ArrowUp",[["path",{d:"m5 12 7-7 7 7",key:"hav0vg"}],["path",{d:"M12 19V5",key:"x0mq9r"}]]);/**
|
|
99
|
-
* @license lucide-react v0.469.0 - ISC
|
|
100
|
-
*
|
|
101
|
-
* This source code is licensed under the ISC license.
|
|
102
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
103
|
-
*/const Kx=me("Bot",[["path",{d:"M12 8V4H8",key:"hb8ula"}],["rect",{width:"16",height:"12",x:"4",y:"8",rx:"2",key:"enze0r"}],["path",{d:"M2 14h2",key:"vft8re"}],["path",{d:"M20 14h2",key:"4cs60a"}],["path",{d:"M15 13v2",key:"1xurst"}],["path",{d:"M9 13v2",key:"rq6x2g"}]]);/**
|
|
104
|
-
* @license lucide-react v0.469.0 - ISC
|
|
105
|
-
*
|
|
106
|
-
* This source code is licensed under the ISC license.
|
|
107
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
108
|
-
*/const f2=me("Brain",[["path",{d:"M12 5a3 3 0 1 0-5.997.125 4 4 0 0 0-2.526 5.77 4 4 0 0 0 .556 6.588A4 4 0 1 0 12 18Z",key:"l5xja"}],["path",{d:"M12 5a3 3 0 1 1 5.997.125 4 4 0 0 1 2.526 5.77 4 4 0 0 1-.556 6.588A4 4 0 1 1 12 18Z",key:"ep3f8r"}],["path",{d:"M15 13a4.5 4.5 0 0 1-3-4 4.5 4.5 0 0 1-3 4",key:"1p4c4q"}],["path",{d:"M17.599 6.5a3 3 0 0 0 .399-1.375",key:"tmeiqw"}],["path",{d:"M6.003 5.125A3 3 0 0 0 6.401 6.5",key:"105sqy"}],["path",{d:"M3.477 10.896a4 4 0 0 1 .585-.396",key:"ql3yin"}],["path",{d:"M19.938 10.5a4 4 0 0 1 .585.396",key:"1qfode"}],["path",{d:"M6 18a4 4 0 0 1-1.967-.516",key:"2e4loj"}],["path",{d:"M19.967 17.484A4 4 0 0 1 18 18",key:"159ez6"}]]);/**
|
|
109
|
-
* @license lucide-react v0.469.0 - ISC
|
|
110
|
-
*
|
|
111
|
-
* This source code is licensed under the ISC license.
|
|
112
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
113
|
-
*/const d2=me("Bug",[["path",{d:"m8 2 1.88 1.88",key:"fmnt4t"}],["path",{d:"M14.12 3.88 16 2",key:"qol33r"}],["path",{d:"M9 7.13v-1a3.003 3.003 0 1 1 6 0v1",key:"d7y7pr"}],["path",{d:"M12 20c-3.3 0-6-2.7-6-6v-3a4 4 0 0 1 4-4h4a4 4 0 0 1 4 4v3c0 3.3-2.7 6-6 6",key:"xs1cw7"}],["path",{d:"M12 20v-9",key:"1qisl0"}],["path",{d:"M6.53 9C4.6 8.8 3 7.1 3 5",key:"32zzws"}],["path",{d:"M6 13H2",key:"82j7cp"}],["path",{d:"M3 21c0-2.1 1.7-3.9 3.8-4",key:"4p0ekp"}],["path",{d:"M20.97 5c0 2.1-1.6 3.8-3.5 4",key:"18gb23"}],["path",{d:"M22 13h-4",key:"1jl80f"}],["path",{d:"M17.2 17c2.1.1 3.8 1.9 3.8 4",key:"k3fwyw"}]]);/**
|
|
114
|
-
* @license lucide-react v0.469.0 - ISC
|
|
115
|
-
*
|
|
116
|
-
* This source code is licensed under the ISC license.
|
|
117
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
118
|
-
*/const h2=me("ChartColumn",[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"M18 17V9",key:"2bz60n"}],["path",{d:"M13 17V5",key:"1frdt8"}],["path",{d:"M8 17v-3",key:"17ska0"}]]);/**
|
|
119
|
-
* @license lucide-react v0.469.0 - ISC
|
|
120
|
-
*
|
|
121
|
-
* This source code is licensed under the ISC license.
|
|
122
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
123
|
-
*/const Zx=me("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
|
|
124
|
-
* @license lucide-react v0.469.0 - ISC
|
|
125
|
-
*
|
|
126
|
-
* This source code is licensed under the ISC license.
|
|
127
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
128
|
-
*/const Ms=me("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/**
|
|
129
|
-
* @license lucide-react v0.469.0 - ISC
|
|
130
|
-
*
|
|
131
|
-
* This source code is licensed under the ISC license.
|
|
132
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
133
|
-
*/const pd=me("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/**
|
|
134
|
-
* @license lucide-react v0.469.0 - ISC
|
|
135
|
-
*
|
|
136
|
-
* This source code is licensed under the ISC license.
|
|
137
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
138
|
-
*/const m2=me("ChevronsDown",[["path",{d:"m7 6 5 5 5-5",key:"1lc07p"}],["path",{d:"m7 13 5 5 5-5",key:"1d48rs"}]]);/**
|
|
139
|
-
* @license lucide-react v0.469.0 - ISC
|
|
140
|
-
*
|
|
141
|
-
* This source code is licensed under the ISC license.
|
|
142
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
143
|
-
*/const p2=me("ChevronsUp",[["path",{d:"m17 11-5-5-5 5",key:"e8nh98"}],["path",{d:"m17 18-5-5-5 5",key:"2avn1x"}]]);/**
|
|
144
|
-
* @license lucide-react v0.469.0 - ISC
|
|
145
|
-
*
|
|
146
|
-
* This source code is licensed under the ISC license.
|
|
147
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
148
|
-
*/const g2=me("CircleAlert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);/**
|
|
149
|
-
* @license lucide-react v0.469.0 - ISC
|
|
150
|
-
*
|
|
151
|
-
* This source code is licensed under the ISC license.
|
|
152
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
153
|
-
*/const hl=me("CircleCheck",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/**
|
|
154
|
-
* @license lucide-react v0.469.0 - ISC
|
|
155
|
-
*
|
|
156
|
-
* This source code is licensed under the ISC license.
|
|
157
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
158
|
-
*/const y2=me("CircleDot",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}]]);/**
|
|
159
|
-
* @license lucide-react v0.469.0 - ISC
|
|
160
|
-
*
|
|
161
|
-
* This source code is licensed under the ISC license.
|
|
162
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
163
|
-
*/const gd=me("CircleX",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]);/**
|
|
164
|
-
* @license lucide-react v0.469.0 - ISC
|
|
165
|
-
*
|
|
166
|
-
* This source code is licensed under the ISC license.
|
|
167
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
168
|
-
*/const x2=me("Circle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);/**
|
|
169
|
-
* @license lucide-react v0.469.0 - ISC
|
|
170
|
-
*
|
|
171
|
-
* This source code is licensed under the ISC license.
|
|
172
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
173
|
-
*/const Jx=me("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/**
|
|
174
|
-
* @license lucide-react v0.469.0 - ISC
|
|
175
|
-
*
|
|
176
|
-
* This source code is licensed under the ISC license.
|
|
177
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
178
|
-
*/const b2=me("Command",[["path",{d:"M15 6v12a3 3 0 1 0 3-3H6a3 3 0 1 0 3 3V6a3 3 0 1 0-3 3h12a3 3 0 1 0-3-3",key:"11bfej"}]]);/**
|
|
179
|
-
* @license lucide-react v0.469.0 - ISC
|
|
180
|
-
*
|
|
181
|
-
* This source code is licensed under the ISC license.
|
|
182
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
183
|
-
*/const v2=me("Copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);/**
|
|
184
|
-
* @license lucide-react v0.469.0 - ISC
|
|
185
|
-
*
|
|
186
|
-
* This source code is licensed under the ISC license.
|
|
187
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
188
|
-
*/const Ti=me("Cpu",[["rect",{width:"16",height:"16",x:"4",y:"4",rx:"2",key:"14l7u7"}],["rect",{width:"6",height:"6",x:"9",y:"9",rx:"1",key:"5aljv4"}],["path",{d:"M15 2v2",key:"13l42r"}],["path",{d:"M15 20v2",key:"15mkzm"}],["path",{d:"M2 15h2",key:"1gxd5l"}],["path",{d:"M2 9h2",key:"1bbxkp"}],["path",{d:"M20 15h2",key:"19e6y8"}],["path",{d:"M20 9h2",key:"19tzq7"}],["path",{d:"M9 2v2",key:"165o2o"}],["path",{d:"M9 20v2",key:"i2bqo8"}]]);/**
|
|
189
|
-
* @license lucide-react v0.469.0 - ISC
|
|
190
|
-
*
|
|
191
|
-
* This source code is licensed under the ISC license.
|
|
192
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
193
|
-
*/const Bf=me("Database",[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]]);/**
|
|
194
|
-
* @license lucide-react v0.469.0 - ISC
|
|
195
|
-
*
|
|
196
|
-
* This source code is licensed under the ISC license.
|
|
197
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
198
|
-
*/const Hf=me("Download",[["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["polyline",{points:"7 10 12 15 17 10",key:"2ggqvy"}],["line",{x1:"12",x2:"12",y1:"15",y2:"3",key:"1vk2je"}]]);/**
|
|
199
|
-
* @license lucide-react v0.469.0 - ISC
|
|
200
|
-
*
|
|
201
|
-
* This source code is licensed under the ISC license.
|
|
202
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
203
|
-
*/const S2=me("EyeOff",[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]]);/**
|
|
204
|
-
* @license lucide-react v0.469.0 - ISC
|
|
205
|
-
*
|
|
206
|
-
* This source code is licensed under the ISC license.
|
|
207
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
208
|
-
*/const w2=me("Eye",[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
|
|
209
|
-
* @license lucide-react v0.469.0 - ISC
|
|
210
|
-
*
|
|
211
|
-
* This source code is licensed under the ISC license.
|
|
212
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
213
|
-
*/const k2=me("FileCode2",[["path",{d:"M4 22h14a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v4",key:"1pf5j1"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"m5 12-3 3 3 3",key:"oke12k"}],["path",{d:"m9 18 3-3-3-3",key:"112psh"}]]);/**
|
|
214
|
-
* @license lucide-react v0.469.0 - ISC
|
|
215
|
-
*
|
|
216
|
-
* This source code is licensed under the ISC license.
|
|
217
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
218
|
-
*/const C2=me("FilePen",[["path",{d:"M12.5 22H18a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v9.5",key:"1couwa"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M13.378 15.626a1 1 0 1 0-3.004-3.004l-5.01 5.012a2 2 0 0 0-.506.854l-.837 2.87a.5.5 0 0 0 .62.62l2.87-.837a2 2 0 0 0 .854-.506z",key:"1y4qbx"}]]);/**
|
|
219
|
-
* @license lucide-react v0.469.0 - ISC
|
|
220
|
-
*
|
|
221
|
-
* This source code is licensed under the ISC license.
|
|
222
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
223
|
-
*/const N2=me("FileText",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);/**
|
|
224
|
-
* @license lucide-react v0.469.0 - ISC
|
|
225
|
-
*
|
|
226
|
-
* This source code is licensed under the ISC license.
|
|
227
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
228
|
-
*/const E2=me("FolderOpen",[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]]);/**
|
|
229
|
-
* @license lucide-react v0.469.0 - ISC
|
|
230
|
-
*
|
|
231
|
-
* This source code is licensed under the ISC license.
|
|
232
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
233
|
-
*/const j2=me("Folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]);/**
|
|
234
|
-
* @license lucide-react v0.469.0 - ISC
|
|
235
|
-
*
|
|
236
|
-
* This source code is licensed under the ISC license.
|
|
237
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
238
|
-
*/const ki=me("Globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]]);/**
|
|
239
|
-
* @license lucide-react v0.469.0 - ISC
|
|
240
|
-
*
|
|
241
|
-
* This source code is licensed under the ISC license.
|
|
242
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
243
|
-
*/const T2=me("Hash",[["line",{x1:"4",x2:"20",y1:"9",y2:"9",key:"4lhtct"}],["line",{x1:"4",x2:"20",y1:"15",y2:"15",key:"vyu0kd"}],["line",{x1:"10",x2:"8",y1:"3",y2:"21",key:"1ggp8o"}],["line",{x1:"16",x2:"14",y1:"3",y2:"21",key:"weycgp"}]]);/**
|
|
244
|
-
* @license lucide-react v0.469.0 - ISC
|
|
245
|
-
*
|
|
246
|
-
* This source code is licensed under the ISC license.
|
|
247
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
248
|
-
*/const qf=me("History",[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}],["path",{d:"M12 7v5l4 2",key:"1fdv2h"}]]);/**
|
|
249
|
-
* @license lucide-react v0.469.0 - ISC
|
|
250
|
-
*
|
|
251
|
-
* This source code is licensed under the ISC license.
|
|
252
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
253
|
-
*/const A2=me("Info",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]]);/**
|
|
254
|
-
* @license lucide-react v0.469.0 - ISC
|
|
255
|
-
*
|
|
256
|
-
* This source code is licensed under the ISC license.
|
|
257
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
258
|
-
*/const M2=me("KeyRound",[["path",{d:"M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z",key:"1s6t7t"}],["circle",{cx:"16.5",cy:"7.5",r:".5",fill:"currentColor",key:"w0ekpg"}]]);/**
|
|
259
|
-
* @license lucide-react v0.469.0 - ISC
|
|
260
|
-
*
|
|
261
|
-
* This source code is licensed under the ISC license.
|
|
262
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
263
|
-
*/const lf=me("Key",[["path",{d:"m15.5 7.5 2.3 2.3a1 1 0 0 0 1.4 0l2.1-2.1a1 1 0 0 0 0-1.4L19 4",key:"g0fldk"}],["path",{d:"m21 2-9.6 9.6",key:"1j0ho8"}],["circle",{cx:"7.5",cy:"15.5",r:"5.5",key:"yqb3hr"}]]);/**
|
|
264
|
-
* @license lucide-react v0.469.0 - ISC
|
|
265
|
-
*
|
|
266
|
-
* This source code is licensed under the ISC license.
|
|
267
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
268
|
-
*/const Wx=me("Keyboard",[["path",{d:"M10 8h.01",key:"1r9ogq"}],["path",{d:"M12 12h.01",key:"1mp3jc"}],["path",{d:"M14 8h.01",key:"1primd"}],["path",{d:"M16 12h.01",key:"1l6xoz"}],["path",{d:"M18 8h.01",key:"emo2bl"}],["path",{d:"M6 8h.01",key:"x9i8wu"}],["path",{d:"M7 16h10",key:"wp8him"}],["path",{d:"M8 12h.01",key:"czm47f"}],["rect",{width:"20",height:"16",x:"2",y:"4",rx:"2",key:"18n3k1"}]]);/**
|
|
269
|
-
* @license lucide-react v0.469.0 - ISC
|
|
270
|
-
*
|
|
271
|
-
* This source code is licensed under the ISC license.
|
|
272
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
273
|
-
*/const D2=me("ListTodo",[["rect",{x:"3",y:"5",width:"6",height:"6",rx:"1",key:"1defrl"}],["path",{d:"m3 17 2 2 4-4",key:"1jhpwq"}],["path",{d:"M13 6h8",key:"15sg57"}],["path",{d:"M13 12h8",key:"h98zly"}],["path",{d:"M13 18h8",key:"oe0vm4"}]]);/**
|
|
274
|
-
* @license lucide-react v0.469.0 - ISC
|
|
275
|
-
*
|
|
276
|
-
* This source code is licensed under the ISC license.
|
|
277
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
278
|
-
*/const $r=me("LoaderCircle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);/**
|
|
279
|
-
* @license lucide-react v0.469.0 - ISC
|
|
280
|
-
*
|
|
281
|
-
* This source code is licensed under the ISC license.
|
|
282
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
283
|
-
*/const R2=me("Maximize2",[["polyline",{points:"15 3 21 3 21 9",key:"mznyad"}],["polyline",{points:"9 21 3 21 3 15",key:"1avn1i"}],["line",{x1:"21",x2:"14",y1:"3",y2:"10",key:"ota7mn"}],["line",{x1:"3",x2:"10",y1:"21",y2:"14",key:"1atl0r"}]]);/**
|
|
284
|
-
* @license lucide-react v0.469.0 - ISC
|
|
285
|
-
*
|
|
286
|
-
* This source code is licensed under the ISC license.
|
|
287
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
288
|
-
*/const z2=me("MessageSquare",[["path",{d:"M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z",key:"1lielz"}]]);/**
|
|
289
|
-
* @license lucide-react v0.469.0 - ISC
|
|
290
|
-
*
|
|
291
|
-
* This source code is licensed under the ISC license.
|
|
292
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
293
|
-
*/const yd=me("Monitor",[["rect",{width:"20",height:"14",x:"2",y:"3",rx:"2",key:"48i651"}],["line",{x1:"8",x2:"16",y1:"21",y2:"21",key:"1svkeh"}],["line",{x1:"12",x2:"12",y1:"17",y2:"21",key:"vw1qmm"}]]);/**
|
|
294
|
-
* @license lucide-react v0.469.0 - ISC
|
|
295
|
-
*
|
|
296
|
-
* This source code is licensed under the ISC license.
|
|
297
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
298
|
-
*/const xd=me("Moon",[["path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z",key:"a7tn18"}]]);/**
|
|
299
|
-
* @license lucide-react v0.469.0 - ISC
|
|
300
|
-
*
|
|
301
|
-
* This source code is licensed under the ISC license.
|
|
302
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
303
|
-
*/const O2=me("Network",[["rect",{x:"16",y:"16",width:"6",height:"6",rx:"1",key:"4q2zg0"}],["rect",{x:"2",y:"16",width:"6",height:"6",rx:"1",key:"8cvhb9"}],["rect",{x:"9",y:"2",width:"6",height:"6",rx:"1",key:"1egb70"}],["path",{d:"M5 16v-3a1 1 0 0 1 1-1h12a1 1 0 0 1 1 1v3",key:"1jsf9p"}],["path",{d:"M12 12V8",key:"2874zd"}]]);/**
|
|
304
|
-
* @license lucide-react v0.469.0 - ISC
|
|
305
|
-
*
|
|
306
|
-
* This source code is licensed under the ISC license.
|
|
307
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
308
|
-
*/const _2=me("Palette",[["circle",{cx:"13.5",cy:"6.5",r:".5",fill:"currentColor",key:"1okk4w"}],["circle",{cx:"17.5",cy:"10.5",r:".5",fill:"currentColor",key:"f64h9f"}],["circle",{cx:"8.5",cy:"7.5",r:".5",fill:"currentColor",key:"fotxhn"}],["circle",{cx:"6.5",cy:"12.5",r:".5",fill:"currentColor",key:"qy21gx"}],["path",{d:"M12 2C6.5 2 2 6.5 2 12s4.5 10 10 10c.926 0 1.648-.746 1.648-1.688 0-.437-.18-.835-.437-1.125-.29-.289-.438-.652-.438-1.125a1.64 1.64 0 0 1 1.668-1.668h1.996c3.051 0 5.555-2.503 5.555-5.554C21.965 6.012 17.461 2 12 2z",key:"12rzf8"}]]);/**
|
|
309
|
-
* @license lucide-react v0.469.0 - ISC
|
|
310
|
-
*
|
|
311
|
-
* This source code is licensed under the ISC license.
|
|
312
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
313
|
-
*/const L2=me("PanelLeftClose",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}],["path",{d:"m16 15-3-3 3-3",key:"14y99z"}]]);/**
|
|
314
|
-
* @license lucide-react v0.469.0 - ISC
|
|
315
|
-
*
|
|
316
|
-
* This source code is licensed under the ISC license.
|
|
317
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
318
|
-
*/const U2=me("PanelLeftOpen",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}],["path",{d:"m14 9 3 3-3 3",key:"8010ee"}]]);/**
|
|
319
|
-
* @license lucide-react v0.469.0 - ISC
|
|
320
|
-
*
|
|
321
|
-
* This source code is licensed under the ISC license.
|
|
322
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
323
|
-
*/const e0=me("Pencil",[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]]);/**
|
|
324
|
-
* @license lucide-react v0.469.0 - ISC
|
|
325
|
-
*
|
|
326
|
-
* This source code is licensed under the ISC license.
|
|
327
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
328
|
-
*/const B2=me("PinOff",[["path",{d:"M12 17v5",key:"bb1du9"}],["path",{d:"M15 9.34V7a1 1 0 0 1 1-1 2 2 0 0 0 0-4H7.89",key:"znwnzq"}],["path",{d:"m2 2 20 20",key:"1ooewy"}],["path",{d:"M9 9v1.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24V16a1 1 0 0 0 1 1h11",key:"c9qhm2"}]]);/**
|
|
329
|
-
* @license lucide-react v0.469.0 - ISC
|
|
330
|
-
*
|
|
331
|
-
* This source code is licensed under the ISC license.
|
|
332
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
333
|
-
*/const t0=me("Pin",[["path",{d:"M12 17v5",key:"bb1du9"}],["path",{d:"M9 10.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24V16a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-.76a2 2 0 0 0-1.11-1.79l-1.78-.9A2 2 0 0 1 15 10.76V7a1 1 0 0 1 1-1 2 2 0 0 0 0-4H8a2 2 0 0 0 0 4 1 1 0 0 1 1 1z",key:"1nkz8b"}]]);/**
|
|
334
|
-
* @license lucide-react v0.469.0 - ISC
|
|
335
|
-
*
|
|
336
|
-
* This source code is licensed under the ISC license.
|
|
337
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
338
|
-
*/const oy=me("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);/**
|
|
339
|
-
* @license lucide-react v0.469.0 - ISC
|
|
340
|
-
*
|
|
341
|
-
* This source code is licensed under the ISC license.
|
|
342
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
343
|
-
*/const n0=me("RefreshCw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]);/**
|
|
344
|
-
* @license lucide-react v0.469.0 - ISC
|
|
345
|
-
*
|
|
346
|
-
* This source code is licensed under the ISC license.
|
|
347
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
348
|
-
*/const Oi=me("RotateCcw",[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}]]);/**
|
|
349
|
-
* @license lucide-react v0.469.0 - ISC
|
|
350
|
-
*
|
|
351
|
-
* This source code is licensed under the ISC license.
|
|
352
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
353
|
-
*/const pa=me("Search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]);/**
|
|
354
|
-
* @license lucide-react v0.469.0 - ISC
|
|
355
|
-
*
|
|
356
|
-
* This source code is licensed under the ISC license.
|
|
357
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
358
|
-
*/const H2=me("Send",[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]]);/**
|
|
359
|
-
* @license lucide-react v0.469.0 - ISC
|
|
360
|
-
*
|
|
361
|
-
* This source code is licensed under the ISC license.
|
|
362
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
363
|
-
*/const bd=me("Settings",[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
|
|
364
|
-
* @license lucide-react v0.469.0 - ISC
|
|
365
|
-
*
|
|
366
|
-
* This source code is licensed under the ISC license.
|
|
367
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
368
|
-
*/const q2=me("ShieldAlert",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"M12 8v4",key:"1got3b"}],["path",{d:"M12 16h.01",key:"1drbdi"}]]);/**
|
|
369
|
-
* @license lucide-react v0.469.0 - ISC
|
|
370
|
-
*
|
|
371
|
-
* This source code is licensed under the ISC license.
|
|
372
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
373
|
-
*/const r0=me("Sparkles",[["path",{d:"M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z",key:"4pj2yx"}],["path",{d:"M20 3v4",key:"1olli1"}],["path",{d:"M22 5h-4",key:"1gvqau"}],["path",{d:"M4 17v2",key:"vumght"}],["path",{d:"M5 18H3",key:"zchphs"}]]);/**
|
|
374
|
-
* @license lucide-react v0.469.0 - ISC
|
|
375
|
-
*
|
|
376
|
-
* This source code is licensed under the ISC license.
|
|
377
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
378
|
-
*/const I2=me("Square",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}]]);/**
|
|
379
|
-
* @license lucide-react v0.469.0 - ISC
|
|
380
|
-
*
|
|
381
|
-
* This source code is licensed under the ISC license.
|
|
382
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
383
|
-
*/const sy=me("Star",[["path",{d:"M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",key:"r04s7s"}]]);/**
|
|
384
|
-
* @license lucide-react v0.469.0 - ISC
|
|
385
|
-
*
|
|
386
|
-
* This source code is licensed under the ISC license.
|
|
387
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
388
|
-
*/const V2=me("Stethoscope",[["path",{d:"M11 2v2",key:"1539x4"}],["path",{d:"M5 2v2",key:"1yf1q8"}],["path",{d:"M5 3H4a2 2 0 0 0-2 2v4a6 6 0 0 0 12 0V5a2 2 0 0 0-2-2h-1",key:"rb5t3r"}],["path",{d:"M8 15a6 6 0 0 0 12 0v-3",key:"x18d4x"}],["circle",{cx:"20",cy:"10",r:"2",key:"ts1r5v"}]]);/**
|
|
389
|
-
* @license lucide-react v0.469.0 - ISC
|
|
390
|
-
*
|
|
391
|
-
* This source code is licensed under the ISC license.
|
|
392
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
393
|
-
*/const vd=me("Sun",[["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m4.93 4.93 1.41 1.41",key:"149t6j"}],["path",{d:"m17.66 17.66 1.41 1.41",key:"ptbguv"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"m6.34 17.66-1.41 1.41",key:"1m8zz5"}],["path",{d:"m19.07 4.93-1.41 1.41",key:"1shlcs"}]]);/**
|
|
394
|
-
* @license lucide-react v0.469.0 - ISC
|
|
395
|
-
*
|
|
396
|
-
* This source code is licensed under the ISC license.
|
|
397
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
398
|
-
*/const ga=me("Terminal",[["polyline",{points:"4 17 10 11 4 5",key:"akl6gq"}],["line",{x1:"12",x2:"20",y1:"19",y2:"19",key:"q2wloq"}]]);/**
|
|
399
|
-
* @license lucide-react v0.469.0 - ISC
|
|
400
|
-
*
|
|
401
|
-
* This source code is licensed under the ISC license.
|
|
402
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
403
|
-
*/const Ai=me("Trash2",[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]]);/**
|
|
404
|
-
* @license lucide-react v0.469.0 - ISC
|
|
405
|
-
*
|
|
406
|
-
* This source code is licensed under the ISC license.
|
|
407
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
408
|
-
*/const l0=me("TriangleAlert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);/**
|
|
409
|
-
* @license lucide-react v0.469.0 - ISC
|
|
410
|
-
*
|
|
411
|
-
* This source code is licensed under the ISC license.
|
|
412
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
413
|
-
*/const $2=me("User",[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]]);/**
|
|
414
|
-
* @license lucide-react v0.469.0 - ISC
|
|
415
|
-
*
|
|
416
|
-
* This source code is licensed under the ISC license.
|
|
417
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
418
|
-
*/const F2=me("Volume2",[["path",{d:"M11 4.702a.705.705 0 0 0-1.203-.498L6.413 7.587A1.4 1.4 0 0 1 5.416 8H3a1 1 0 0 0-1 1v6a1 1 0 0 0 1 1h2.416a1.4 1.4 0 0 1 .997.413l3.383 3.384A.705.705 0 0 0 11 19.298z",key:"uqj9uw"}],["path",{d:"M16 9a5 5 0 0 1 0 6",key:"1q6k2b"}],["path",{d:"M19.364 18.364a9 9 0 0 0 0-12.728",key:"ijwkga"}]]);/**
|
|
419
|
-
* @license lucide-react v0.469.0 - ISC
|
|
420
|
-
*
|
|
421
|
-
* This source code is licensed under the ISC license.
|
|
422
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
423
|
-
*/const Y2=me("VolumeX",[["path",{d:"M11 4.702a.705.705 0 0 0-1.203-.498L6.413 7.587A1.4 1.4 0 0 1 5.416 8H3a1 1 0 0 0-1 1v6a1 1 0 0 0 1 1h2.416a1.4 1.4 0 0 1 .997.413l3.383 3.384A.705.705 0 0 0 11 19.298z",key:"uqj9uw"}],["line",{x1:"22",x2:"16",y1:"9",y2:"15",key:"1ewh16"}],["line",{x1:"16",x2:"22",y1:"9",y2:"15",key:"5ykzw1"}]]);/**
|
|
424
|
-
* @license lucide-react v0.469.0 - ISC
|
|
425
|
-
*
|
|
426
|
-
* This source code is licensed under the ISC license.
|
|
427
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
428
|
-
*/const Sd=me("WifiOff",[["path",{d:"M12 20h.01",key:"zekei9"}],["path",{d:"M8.5 16.429a5 5 0 0 1 7 0",key:"1bycff"}],["path",{d:"M5 12.859a10 10 0 0 1 5.17-2.69",key:"1dl1wf"}],["path",{d:"M19 12.859a10 10 0 0 0-2.007-1.523",key:"4k23kn"}],["path",{d:"M2 8.82a15 15 0 0 1 4.177-2.643",key:"1grhjp"}],["path",{d:"M22 8.82a15 15 0 0 0-11.288-3.764",key:"z3jwby"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]]);/**
|
|
429
|
-
* @license lucide-react v0.469.0 - ISC
|
|
430
|
-
*
|
|
431
|
-
* This source code is licensed under the ISC license.
|
|
432
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
433
|
-
*/const a0=me("Wifi",[["path",{d:"M12 20h.01",key:"zekei9"}],["path",{d:"M2 8.82a15 15 0 0 1 20 0",key:"dnpr2z"}],["path",{d:"M5 12.859a10 10 0 0 1 14 0",key:"1x1e6c"}],["path",{d:"M8.5 16.429a5 5 0 0 1 7 0",key:"1bycff"}]]);/**
|
|
434
|
-
* @license lucide-react v0.469.0 - ISC
|
|
435
|
-
*
|
|
436
|
-
* This source code is licensed under the ISC license.
|
|
437
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
438
|
-
*/const wd=me("Wrench",[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.77-3.77a6 6 0 0 1-7.94 7.94l-6.91 6.91a2.12 2.12 0 0 1-3-3l6.91-6.91a6 6 0 0 1 7.94-7.94l-3.76 3.76z",key:"cbrjhi"}]]);/**
|
|
439
|
-
* @license lucide-react v0.469.0 - ISC
|
|
440
|
-
*
|
|
441
|
-
* This source code is licensed under the ISC license.
|
|
442
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
443
|
-
*/const gl=me("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);/**
|
|
444
|
-
* @license lucide-react v0.469.0 - ISC
|
|
445
|
-
*
|
|
446
|
-
* This source code is licensed under the ISC license.
|
|
447
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
448
|
-
*/const kd=me("Zap",[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]]);var G2=Symbol.for("react.lazy"),vs=od[" use ".trim().toString()];function P2(t){return typeof t=="object"&&t!==null&&"then"in t}function i0(t){return t!=null&&typeof t=="object"&&"$$typeof"in t&&t.$$typeof===G2&&"_payload"in t&&P2(t._payload)}function X2(t){const r=K2(t),l=w.forwardRef((i,s)=>{let{children:u,...c}=i;i0(u)&&typeof vs=="function"&&(u=vs(u._payload));const d=w.Children.toArray(u),p=d.find(J2);if(p){const m=p.props.children,x=d.map(y=>y===p?w.Children.count(m)>1?w.Children.only(null):w.isValidElement(m)?m.props.children:null:y);return h.jsx(r,{...c,ref:s,children:w.isValidElement(m)?w.cloneElement(m,void 0,x):null})}return h.jsx(r,{...c,ref:s,children:u})});return l.displayName=`${t}.Slot`,l}var Q2=X2("Slot");function K2(t){const r=w.forwardRef((l,i)=>{let{children:s,...u}=l;if(i0(s)&&typeof vs=="function"&&(s=vs(s._payload)),w.isValidElement(s)){const c=ek(s),d=W2(u,s.props);return s.type!==w.Fragment&&(d.ref=i?sd(i,c):c),w.cloneElement(s,d)}return w.Children.count(s)>1?w.Children.only(null):null});return r.displayName=`${t}.SlotClone`,r}var Z2=Symbol("radix.slottable");function J2(t){return w.isValidElement(t)&&typeof t.type=="function"&&"__radixId"in t.type&&t.type.__radixId===Z2}function W2(t,r){const l={...r};for(const i in r){const s=t[i],u=r[i];/^on[A-Z]/.test(i)?s&&u?l[i]=(...d)=>{const p=u(...d);return s(...d),p}:s&&(l[i]=s):i==="style"?l[i]={...s,...u}:i==="className"&&(l[i]=[s,u].filter(Boolean).join(" "))}return{...t,...l}}function ek(t){var i,s;let r=(i=Object.getOwnPropertyDescriptor(t.props,"ref"))==null?void 0:i.get,l=r&&"isReactWarning"in r&&r.isReactWarning;return l?t.ref:(r=(s=Object.getOwnPropertyDescriptor(t,"ref"))==null?void 0:s.get,l=r&&"isReactWarning"in r&&r.isReactWarning,l?t.props.ref:t.props.ref||t.ref)}const uy=t=>typeof t=="boolean"?`${t}`:t===0?"0":t,cy=Bx,tk=(t,r)=>l=>{var i;if((r==null?void 0:r.variants)==null)return cy(t,l==null?void 0:l.class,l==null?void 0:l.className);const{variants:s,defaultVariants:u}=r,c=Object.keys(s).map(m=>{const x=l==null?void 0:l[m],y=u==null?void 0:u[m];if(x===null)return null;const b=uy(x)||uy(y);return s[m][b]}),d=l&&Object.entries(l).reduce((m,x)=>{let[y,b]=x;return b===void 0||(m[y]=b),m},{}),p=r==null||(i=r.compoundVariants)===null||i===void 0?void 0:i.reduce((m,x)=>{let{class:y,className:b,...S}=x;return Object.entries(S).every(k=>{let[N,A]=k;return Array.isArray(A)?A.includes({...u,...d}[N]):{...u,...d}[N]===A})?[...m,y,b]:m},[]);return cy(t,c,p,l==null?void 0:l.class,l==null?void 0:l.className)},nk=tk("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",outline:"border border-input bg-background hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"h-9 rounded-md px-3",lg:"h-11 rounded-md px-8",icon:"h-10 w-10"}},defaultVariants:{variant:"default",size:"default"}}),Ve=w.forwardRef(({className:t,variant:r,size:l,asChild:i=!1,...s},u)=>{const c=i?Q2:"button";return h.jsx(c,{className:he(nk({variant:r,size:l,className:t})),ref:u,...s})});Ve.displayName="Button";class rk{constructor(r){en(this,"ws",null);en(this,"url");en(this,"handlers",new Map);en(this,"reconnectAttempts",0);en(this,"maxReconnectAttempts",10);en(this,"reconnectDelay",1e3);en(this,"shouldReconnect",!0);en(this,"messageQueue",[]);en(this,"pendingConfirms",new Map);en(this,"sessionId",null);en(this,"lastErrorText");en(this,"statusListeners",new Set);en(this,"currentStatus",{state:"connecting"});this.url=r??lk()}onStatus(r){return this.statusListeners.add(r),r(this.currentStatus),()=>this.statusListeners.delete(r)}get status(){return this.currentStatus}setStatus(r){this.currentStatus=r;for(const l of this.statusListeners)try{l(r)}catch{}}async connect(){return new Promise((r,l)=>{var i;if(((i=this.ws)==null?void 0:i.readyState)===WebSocket.OPEN){r();return}this.setStatus({state:"connecting"});try{this.ws=new WebSocket(this.url),this.ws.binaryType="arraybuffer";const s=setTimeout(()=>{l(new Error("Connection timeout"))},1e4);this.ws.onopen=()=>{clearTimeout(s),console.log("[WS Client] Connected"),this.reconnectAttempts=0,this.lastErrorText=void 0,this.setStatus({state:"open"}),this.flushMessageQueue(),r()},this.ws.onmessage=u=>{try{const c=JSON.parse(u.data);this.handleMessage(c)}catch(c){console.error("[WS Client] Failed to parse message",c)}},this.ws.onerror=u=>{console.error("[WS Client] Error",u),this.lastErrorText="Connection error (see browser devtools)"},this.ws.onclose=u=>{console.log("[WS Client] Disconnected",u.code,u.reason),u.reason&&!this.lastErrorText?this.lastErrorText=`${u.reason} (code ${u.code})`:!this.lastErrorText&&u.code!==1e3&&(this.lastErrorText=`Closed with code ${u.code}`),this.attemptReconnect()}}catch(s){clearTimeout(globalThis.connectTimeout),this.lastErrorText=s instanceof Error?s.message:String(s),this.setStatus({state:"closed",error:this.lastErrorText}),l(s)}})}attemptReconnect(){if(!this.shouldReconnect||this.reconnectAttempts>=this.maxReconnectAttempts){console.log("[WS Client] Not reconnecting"),this.setStatus({state:"closed",error:this.lastErrorText??"Disconnected"});return}this.reconnectAttempts++;const r=Math.min(this.reconnectDelay*2**(this.reconnectAttempts-1),3e4),l=Date.now()+r;console.log(`[WS Client] Reconnecting in ${r}ms (attempt ${this.reconnectAttempts})`),this.setStatus({state:"reconnecting",attempt:this.reconnectAttempts,nextRetryAt:l,lastError:this.lastErrorText}),setTimeout(async()=>{if(this.shouldReconnect)try{await this.connect()}catch(i){console.error("[WS Client] Reconnect failed",i)}},r)}retryNow(){this.currentStatus.state!=="open"&&(this.reconnectAttempts=0,this.connect().catch(()=>{}))}flushMessageQueue(){for(;this.messageQueue.length>0;){const r=this.messageQueue.shift();r&&this.send(r)}}handleMessage(r){if(r.type==="tool.confirm_needed"){const l=r.payload;this.pendingConfirms.set(l.id,{resolve:l.resolve});const i={...r,payload:{...l,resolve:()=>{}}};this.emit(i);return}if(r.type==="session.start"){const l=r.payload;this.sessionId=l.sessionId}this.emit(r)}emit(r){const l=this.handlers.get(r.type);if(l)for(const i of l)try{i(r)}catch(s){console.error(`[WS Client] Handler error for ${r.type}`,s)}}send(r){var l;((l=this.ws)==null?void 0:l.readyState)===WebSocket.OPEN?this.ws.send(JSON.stringify(r)):this.messageQueue.push(r)}on(r,l){let i=this.handlers.get(r);return i||(i=new Set,this.handlers.set(r,i)),i.add(l),()=>i==null?void 0:i.delete(l)}off(r,l){var i;(i=this.handlers.get(r))==null||i.delete(l)}sendMessage(r){const l=`msg_${Date.now()}_${Math.random().toString(36).slice(2,9)}`;return this.send({type:"user_message",payload:{id:l,content:r,timestamp:Date.now()}}),l}sendAbort(){this.send({type:"abort",payload:{}})}sendConfirm(r,l){const i=this.pendingConfirms.get(r);i&&(i.resolve(l),this.pendingConfirms.delete(r)),this.send({type:"tool.confirm_result",payload:{id:r,decision:l}})}switchModel(r,l){this.send({type:"model.switch",payload:{provider:r,model:l}})}listProviders(){this.send({type:"providers.list"})}listProviderModels(r){this.send({type:"provider.models",payload:{providerId:r}})}listSavedProviders(){this.send({type:"providers.saved"})}addKey(r,l,i){this.send({type:"key.add",payload:{providerId:r,label:l,apiKey:i}})}updateKey(r,l,i){this.send({type:"key.update",payload:{providerId:r,label:l,apiKey:i}})}deleteKey(r,l){this.send({type:"key.delete",payload:{providerId:r,label:l}})}setActiveKey(r,l){this.send({type:"key.set_active",payload:{providerId:r,label:l}})}addProvider(r,l,i,s){this.send({type:"provider.add",payload:{id:r,family:l,baseUrl:i,apiKey:s}})}removeProvider(r){this.send({type:"provider.remove",payload:{providerId:r}})}newSession(){this.send({type:"session.new"})}clearContext(){this.send({type:"context.clear"})}compactContext(r=!1){this.send({type:"context.compact",payload:{aggressive:r}})}debugContext(){this.send({type:"context.debug"})}listTools(){this.send({type:"tools.list"})}listMemory(){this.send({type:"memory.list"})}remember(r,l){this.send({type:"memory.remember",payload:{text:r,scope:l}})}forget(r,l){this.send({type:"memory.forget",payload:{text:r,scope:l}})}listSkills(){this.send({type:"skills.list"})}getDiag(){this.send({type:"diag.get"})}getStats(){this.send({type:"stats.get"})}saveSession(){this.send({type:"session.save"})}resumeSessionById(r){this.send({type:"session.resume",payload:{id:r}})}listModes(){this.send({type:"modes.list"})}switchMode(r){this.send({type:"mode.switch",payload:{id:r}})}listFiles(r,l){this.send({type:"files.list",payload:{query:r,limit:l}})}getTodos(){this.send({type:"todos.get"})}clearTodos(){this.send({type:"todos.clear"})}listSessions(r=50){this.send({type:"sessions.list",payload:{limit:r}})}deleteSession(r){this.send({type:"session.delete",payload:{id:r}})}resumeSession(r){this.send({type:"session.resume",payload:{id:r}})}ping(){this.send({type:"ping"})}disconnect(){var r;this.shouldReconnect=!1,(r=this.ws)==null||r.close(),this.ws=null}get isConnected(){var r;return((r=this.ws)==null?void 0:r.readyState)===WebSocket.OPEN}get currentSessionId(){return this.sessionId}}let af=null;function lk(){var l;if(typeof window>"u"||!((l=window.location)!=null&&l.hostname))return"ws://127.0.0.1:3457";const r=window.location.hostname.toLowerCase();return r==="localhost"||r==="127.0.0.1"||r==="[::1]"||r==="::1"?"ws://127.0.0.1:3457":`ws://${window.location.hostname}:3457`}function Hn(t){return af||(af=new rk(t)),af}const cl=xa(t=>({toasts:[],push:r=>{const l=`toast_${Date.now()}_${Math.random().toString(36).slice(2,7)}`;return t(i=>({toasts:[...i.toasts,{...r,id:l}]})),l},dismiss:r=>t(l=>({toasts:l.toasts.filter(i=>i.id!==r)}))})),rs={success:(t,r=3500)=>cl.getState().push({message:t,variant:"success",ttl:r}),error:(t,r=6e3)=>cl.getState().push({message:t,variant:"error",ttl:r}),warn:(t,r=4500)=>cl.getState().push({message:t,variant:"warn",ttl:r}),info:(t,r=3500)=>cl.getState().push({message:t,variant:"info",ttl:r}),dismiss:t=>cl.getState().dismiss(t)};function ak({variant:t}){return t==="success"?h.jsx(hl,{className:"h-4 w-4 text-green-500"}):t==="error"?h.jsx(gd,{className:"h-4 w-4 text-destructive"}):t==="warn"?h.jsx(l0,{className:"h-4 w-4 text-amber-500"}):h.jsx(A2,{className:"h-4 w-4 text-blue-500"})}function ik({entry:t}){const r=cl(l=>l.dismiss);return w.useEffect(()=>{const l=setTimeout(()=>r(t.id),t.ttl);return()=>clearTimeout(l)},[t.id,t.ttl,r]),h.jsxs("div",{className:he("flex items-start gap-2 rounded-lg border bg-popover shadow-lg px-3 py-2 text-sm max-w-sm","animate-message",t.variant==="error"&&"border-destructive/40",t.variant==="warn"&&"border-amber-500/40",t.variant==="success"&&"border-green-500/40"),role:"status",children:[h.jsx(ak,{variant:t.variant}),h.jsx("div",{className:"flex-1 min-w-0 whitespace-pre-wrap break-words leading-snug",children:t.message}),h.jsx("button",{type:"button",onClick:()=>r(t.id),className:"text-muted-foreground hover:text-foreground",title:"Dismiss",children:h.jsx(gl,{className:"h-3.5 w-3.5"})})]})}function ok(){const t=cl(r=>r.toasts);return t.length===0?null:h.jsx("div",{className:"fixed bottom-4 right-4 z-[60] flex flex-col gap-2 pointer-events-auto",children:t.map(r=>h.jsx(ik,{entry:r},r.id))})}let Vr="default";typeof window<"u"&&"Notification"in window?Vr=Notification.permission:Vr="unsupported";async function sk(){if(Vr==="unsupported"||Vr==="granted"||Vr==="denied")return Vr;try{const t=await Notification.requestPermission();return Vr=t,t}catch{return"denied"}}function fy(t,r){if(!(typeof document>"u"||!document.hidden)&&Vr==="granted")try{const l=new Notification(t,{body:r,icon:"/favicon.ico",tag:"wrongstack-run"});l.onclick=()=>{window.focus(),l.close()}}catch{}}let ls=null;function uk(){if(typeof window>"u")return null;if(ls)return ls;const t=window.AudioContext||window.webkitAudioContext;if(!t)return null;try{ls=new t}catch{return null}return ls}function dy(t,r,l){const i=uk();if(!i)return;const s=i.currentTime+r,u=i.createOscillator(),c=i.createGain();u.type="sine",u.frequency.value=t,c.gain.setValueAtTime(0,s),c.gain.linearRampToValueAtTime(.18,s+.01),c.gain.exponentialRampToValueAtTime(1e-4,s+l),u.connect(c).connect(i.destination),u.start(s),u.stop(s+l+.02)}function o0(){dy(659.25,0,.18),dy(880,.12,.24)}const s0=Object.freeze(Object.defineProperty({__proto__:null,playCompletionChime:o0},Symbol.toStringTag,{value:"Module"})),ck="#4f46e5";function fk(t){return`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64">
|
|
449
|
-
<rect x="2" y="2" width="60" height="60" rx="14" fill="${ck}" />
|
|
450
|
-
<text x="32" y="44" text-anchor="middle" font-family="-apple-system,Segoe UI,Roboto,sans-serif" font-size="38" font-weight="700" fill="#fff">W</text>
|
|
451
|
-
${t==="ready"?'<circle cx="50" cy="14" r="14" fill="#22c55e" stroke="#fff" stroke-width="3" />':t==="error"?'<circle cx="50" cy="14" r="14" fill="#ef4444" stroke="#fff" stroke-width="3" />':t==="running"?'<circle cx="50" cy="14" r="14" fill="#f59e0b" stroke="#fff" stroke-width="3" />':""}
|
|
452
|
-
</svg>`}function dk(t){return`data:image/svg+xml;charset=utf-8,${encodeURIComponent(t)}`}function hk(){if(typeof document>"u")return null;let t=document.querySelector('link[rel="icon"]');return t||(t=document.createElement("link"),t.rel="icon",t.type="image/svg+xml",document.head.appendChild(t)),t}let If="idle";function hs(t){If=t;const r=hk();r&&(r.href=dk(fk(t)))}let hy=!1;function mk(){hy||typeof document>"u"||(hy=!0,document.addEventListener("visibilitychange",()=>{!document.hidden&&(If==="ready"||If==="error")&&hs("idle")}))}function pk(t){const r=[],l=(i,s)=>{r.push(t.on(i,s))};return l("session.start",i=>{var p;const s=i.payload,u=(p=Ye.getState().session)==null?void 0:p.id,c=!u||u!==s.sessionId;Ye.getState().startSession({id:s.sessionId,startedAt:Date.now(),model:s.model,provider:s.provider}),Ye.getState().setEnv({maxContext:s.maxContext,projectName:s.projectName,mode:s.mode,inputCost:s.inputCost,outputCost:s.outputCost,cacheReadCost:s.cacheReadCost}),Ge.getState().setConfig({provider:s.provider,model:s.model}),(c||s.reset)&&pe.getState().clearMessages();const d=s.replayMessages;if(d&&d.length>0){const m=pe.getState();for(const x of d)if(x.role==="user"||x.role==="assistant"||x.role==="system"){let y="";if(typeof x.content=="string")y=x.content;else if(Array.isArray(x.content)){for(const b of x.content)if(b.type==="text"&&typeof b.text=="string")y+=(y?`
|
|
453
|
-
`:"")+b.text;else if(b.type==="tool_use")m.addMessage({role:"tool",content:"",toolName:String(b.name??"tool"),toolInput:b.input,toolUseId:String(b.id??"")}),y="";else if(b.type==="tool_result"){const S=pe.getState().messages;let k;for(let N=S.length-1;N>=0;N--)if(S[N].toolUseId===String(b.tool_use_id??"")){k=S[N];break}k&&m.setToolResult(k.id,typeof b.content=="string"?b.content:JSON.stringify(b.content),!b.is_error)}}y&&m.addMessage({role:x.role,content:y})}}}),l("context.debug",i=>{const s=i.payload,u=m=>m.toLocaleString(),c=[...s.tools.breakdown].sort((m,x)=>x.tokens-m.tokens).slice(0,8),d=[...s.messages.breakdown].sort((m,x)=>x.tokens-m.tokens).slice(0,8),p=["📊 **Context breakdown** (heuristic — 4 chars/token)","",`**Total estimate:** ${u(s.total)} tokens`,`• System prompt: ${u(s.systemPrompt)}`,`• Tool schemas: ${u(s.tools.total)} (${s.tools.count} tools)`,`• Messages: ${u(s.messages.total)} (${s.messages.count} messages)`,"","**Top tool schemas:**",...c.map(m=>` · ${m.name}: ${u(m.tokens)}`),"","**Top messages:**",...d.map(m=>` · #${m.index} ${m.role}: ${u(m.tokens)} — ${m.preview||"(empty)"}`)];pe.getState().addMessage({role:"assistant",content:p.join(`
|
|
454
|
-
`)})}),l("key.operation_result",i=>{const s=i.payload;s.success?rs.success(s.message):rs.error(s.message)}),l("context.compacted",i=>{const s=i.payload,u=s.reductions.length?s.reductions.map(c=>`${c.phase}: ${c.saved}`).join(", "):"no-op";pe.getState().addMessage({role:"assistant",content:`🗜️ Context compacted: ${s.before} → ${s.after} tokens (saved ~${s.saved}). ${u}`}),Ye.setState({lastInputTokens:s.after})}),l("session.end",()=>{Ge.getState().setWsConnected(!1)}),l("iteration.started",i=>{const s=i.payload;Ye.getState().setIteration({index:s.index,max:s.maxIterations??0}),pe.getState().setLoading(!0),typeof document<"u"&&document.hidden&&hs("running"),pe.getState().runStart===null&&pe.getState().setRunStart({at:Date.now(),cost:Ye.getState().cost}),pe.getState().setCurrentAssistantMessage(null)}),l("provider.text_delta",i=>{const s=i.payload;let u=pe.getState().currentAssistantMessageId;u||(u=pe.getState().addMessage({role:"assistant",content:"",streaming:!0}),pe.getState().setCurrentAssistantMessage(u)),pe.getState().appendToMessage(u,s.text)}),l("tool.started",i=>{const s=i.payload,u=pe.getState().messages.find(d=>d.toolUseId===s.id);if(u){pe.getState().setCurrentToolId(u.id);return}pe.getState().setCurrentAssistantMessage(null);const c=pe.getState().addMessage({role:"tool",content:"",toolName:s.name,toolInput:s.input,toolUseId:s.id});pe.getState().setCurrentToolId(c),pe.getState().addExecution({id:s.id,name:s.name,input:s.input,ok:!0,startedAt:Date.now()})}),l("tool.progress",i=>{const s=i.payload,u=(s.text??"").trim();if(!u)return;const d=pe.getState().messages.find(m=>m.toolUseId===s.id);if(!d)return;const p=s.eventType==="warning"?"⚠ ":"";pe.getState().appendToolProgress(d.id,p+u)}),l("tool.executed",i=>{const s=i.payload,{messages:u,currentToolId:c}=pe.getState(),d=s.id?u.find(p=>p.toolUseId===s.id):c?u.find(p=>p.id===c):void 0;d&&(pe.getState().setToolResult(d.id,s.output??"",s.ok),pe.getState().updateMessage(d.id,{toolDurationMs:s.durationMs})),s.id&&pe.getState().updateExecution(s.id,{completedAt:Date.now(),durationMs:s.durationMs,output:s.output,ok:s.ok}),c&&d&&d.id===c&&pe.getState().setCurrentToolId(null)}),l("provider.response",i=>{const s=i.payload;Ye.getState().updateUsage(s.usage);const{inputCost:u,outputCost:c,cacheReadCost:d}=Ye.getState(),p=(s.usage.input*u+s.usage.output*c+(s.usage.cacheRead??0)*d)/1e6;p>0&&Ye.getState().addCost(p),s.stopReason!=="tool_use"&&s.stopReason!=="tool_call"&&pe.getState().setLoading(!1);const m=pe.getState().currentAssistantMessageId;m&&(pe.getState().finalizeMessage(m),s.usage.output>0&&pe.getState().updateMessage(m,{usage:s.usage})),pe.getState().setCurrentAssistantMessage(null)}),l("tool.confirm_needed",i=>{const s=i.payload;Ce.getState().showConfirm({id:s.id,toolName:s.toolName,input:s.input,suggestedPattern:s.suggestedPattern})}),l("run.result",i=>{const s=i.payload;Ye.getState().setIteration(null),pe.getState().setLoading(!1),pe.getState().setCurrentAssistantMessage(null);const u=pe.getState().runStart;if(u&&s.status==="done"){const d=pe.getState().messages;let p=-1,m=0;for(let x=d.length-1;x>=0;x--){const y=d[x];if(y.role==="assistant"&&p===-1&&y.content&&(p=x),y.role==="tool"&&y.timestamp>=u.at&&(m+=1),y.role==="user"&&y.timestamp<=u.at)break}if(p!==-1){const x=Ye.getState().cost;pe.getState().updateMessage(d[p].id,{runSummary:{iterations:s.iterations,tools:m,durationMs:Date.now()-u.at,costDelta:Math.max(0,x-u.cost)}})}}if(pe.getState().setRunStart(null),s.status!=="done"&&s.error)pe.getState().addMessage({role:"assistant",content:`Error: ${s.error.message}`,isError:!0}),rs.error(`Run ended: ${s.error.message}`),fy("WrongStack run failed",s.error.message),typeof document<"u"&&document.hidden&&hs("error");else if(s.status==="done"&&(typeof document<"u"&&document.hidden&&(rs.success(`Run completed in ${s.iterations} iteration${s.iterations===1?"":"s"}`),fy("WrongStack run finished",`Completed in ${s.iterations} iteration${s.iterations===1?"":"s"}.`),hs("ready")),sk(),Ge.getState().soundOnComplete))try{o0()}catch{}const c=pe.getState().dequeue();if(c){const d=Hn(Ge.getState().wsUrl);pe.getState().addMessage({role:"user",content:c}),pe.getState().setLoading(!0),d.sendMessage(c)}}),l("tools.list",i=>{const s=i.payload,u=[`🛠️ **Registered tools** (${s.tools.length})`,"",...s.tools.map(c=>`• \`${c.name}\`${c.params.length?` (${c.params.join(", ")})`:""} — ${c.description||"_no description_"}`)];pe.getState().addMessage({role:"assistant",content:u.join(`
|
|
455
|
-
`)})}),l("memory.list",i=>{var c;const s=i.payload,u=(c=s.text)==null?void 0:c.trim();pe.getState().addMessage({role:"assistant",content:s.error?`Memory read failed: ${s.error}`:u?`🧠 **Memory**
|
|
456
|
-
|
|
457
|
-
${u}`:`🧠 **Memory**
|
|
458
|
-
|
|
459
|
-
_empty — nothing remembered yet_`})}),l("skills.list",i=>{const s=i.payload;if(!s.enabled){pe.getState().addMessage({role:"assistant",content:`🎯 **Skills**
|
|
460
|
-
|
|
461
|
-
_disabled (config.features.skills = false)_`});return}const u=[`🎯 **Skills** (${s.skills.length})`,"",...s.skills.length===0?["_none registered_"]:s.skills.map(c=>`• \`${c.name}\`${c.version?` v${c.version}`:""} _(${c.source})_ — ${c.description||c.trigger||"_no description_"}`)];s.error&&u.push("",`⚠ ${s.error}`),pe.getState().addMessage({role:"assistant",content:u.join(`
|
|
462
|
-
`)})}),l("diag.get",i=>{const s=i.payload,u=["🩺 **Runtime diagnostics**","",`**Provider:** \`${s.provider}\` / \`${s.model}\``,`**Mode:** \`${s.mode}\``,`**Session:** \`${s.sessionId}\``,`**CWD:** \`${s.cwd}\``,"",`**Tools:** ${s.tools.count}`,`**Messages:** ${s.messages} · **Todos:** ${s.todos}`,`**Usage:** ${s.usage.input.toLocaleString()} in · ${s.usage.output.toLocaleString()} out${s.usage.cacheRead?` · ${s.usage.cacheRead.toLocaleString()} cache`:""}`,"",`**Features:** memory=${s.features.memory?"✓":"✗"} · skills=${s.features.skills?"✓":"✗"} · modelsRegistry=${s.features.modelsRegistry?"✓":"✗"}`];pe.getState().addMessage({role:"assistant",content:u.join(`
|
|
463
|
-
`)})}),l("stats.get",i=>{const s=i.payload,u=Math.floor(s.elapsedMs/1e3),c=u<60?`${u}s`:u<3600?`${Math.floor(u/60)}m ${u%60}s`:`${Math.floor(u/3600)}h ${Math.floor(u%3600/60)}m`,d=["📈 **Session stats**","",`**Session:** \`${s.sessionId}\``,`**Provider/Model:** \`${s.provider}\` / \`${s.model}\``,`**Elapsed:** ${c}`,"",`**Usage:** ${s.usage.input.toLocaleString()} in · ${s.usage.output.toLocaleString()} out`,...s.cache&&s.cache.readTokens>0?[`**Cache:** ${s.cache.readTokens.toLocaleString()} read · ${s.cache.writeTokens.toLocaleString()} write · hit ratio ${(s.cache.hitRatio*100).toFixed(1)}%`]:[],`**Cost:** $${s.cost.toFixed(4)}`,"",`**Messages:** ${s.messages} · **Files read:** ${s.readFiles} · **Tools available:** ${s.tools}`];pe.getState().addMessage({role:"assistant",content:d.join(`
|
|
464
|
-
`)})}),l("todos.updated",i=>{const s=i.payload;Ye.getState().setTodos(s.todos??[])}),l("modes.list",i=>{const s=i.payload;Ye.getState().setModes(s.modes.map(u=>({id:u.id,name:u.name,description:u.description}))),Ye.getState().setEnv({mode:s.activeId})}),l("sessions.list",i=>{const s=i.payload;da.getState().setEntries(s.sessions??[],s.error??null)}),l("error",i=>{const s=i.payload;pe.getState().addMessage({role:"assistant",content:`[${s.phase}] ${s.message}`,isError:!0}),pe.getState().setLoading(!1)}),()=>{for(const i of r)i()}}function gk(){const{autoConnect:t,wsUrl:r}=Ge(),l=Ge(s=>s.setWsStatus),i=w.useRef(!1);w.useEffect(()=>{if(!t)return;mk();const s=Hn(r),u=s.onStatus(d=>l(d));if(s.connect().catch(d=>{console.error("[WS] Connection failed:",d)}),i.current)return()=>{u()};i.current=!0;const c=pk(s);return()=>{c(),u(),i.current=!1}},[t,r,l])}function In(){const{wsUrl:t}=Ge(),r=Hn(t),l=w.useCallback(P=>r.isConnected?r.sendMessage(P):null,[r]),i=w.useCallback(()=>r.sendAbort(),[r]),{hideConfirm:s}=Ce(),u=w.useCallback((P,X)=>{r.sendConfirm(P,X),s()},[r,s]),c=w.useCallback((P,X)=>r.switchModel(P,X),[r]),d=w.useCallback(()=>r.listProviders(),[r]),p=w.useCallback(P=>r.listProviderModels(P),[r]),m=w.useCallback(()=>r.listSavedProviders(),[r]),x=w.useCallback((P,X,de)=>r.addKey(P,X,de),[r]),y=w.useCallback((P,X,de)=>r.updateKey(P,X,de),[r]),b=w.useCallback((P,X)=>r.deleteKey(P,X),[r]),S=w.useCallback((P,X)=>r.setActiveKey(P,X),[r]),k=w.useCallback((P,X,de,I)=>r.addProvider(P,X,de,I),[r]),N=w.useCallback(P=>r.removeProvider(P),[r]),A=w.useCallback(P=>{da.getState().setLoading(!0),r.listSessions(P)},[r]),j=w.useCallback(P=>{da.getState().removeEntry(P),r.deleteSession(P)},[r]),M=w.useCallback(P=>r.resumeSessionById(P),[r]),z=w.useCallback(()=>r.saveSession(),[r]),V=w.useCallback(()=>r.listTools(),[r]),Q=w.useCallback(()=>r.listMemory(),[r]),B=w.useCallback(()=>r.listSkills(),[r]),G=w.useCallback(()=>r.getDiag(),[r]),ae=w.useCallback(()=>r.getStats(),[r]),se=w.useCallback(()=>r.listModes(),[r]),L=w.useCallback(P=>r.switchMode(P),[r]);return{client:r,sendMessage:l,sendAbort:i,sendConfirm:u,switchModel:c,listProviders:d,listProviderModels:p,listSavedProviders:m,addKey:x,updateKey:y,deleteKey:b,setActiveKey:S,addProvider:k,removeProvider:N,listSessions:A,deleteSession:j,resumeSession:M,saveSession:z,listTools:V,listMemory:Q,listSkills:B,getDiag:G,getStats:ae,listModes:se,switchMode:L}}const yk="modulepreload",xk=function(t){return"/"+t},my={},u0=function(r,l,i){let s=Promise.resolve();if(l&&l.length>0){let c=function(m){return Promise.all(m.map(x=>Promise.resolve(x).then(y=>({status:"fulfilled",value:y}),y=>({status:"rejected",reason:y}))))};document.getElementsByTagName("link");const d=document.querySelector("meta[property=csp-nonce]"),p=(d==null?void 0:d.nonce)||(d==null?void 0:d.getAttribute("nonce"));s=c(l.map(m=>{if(m=xk(m),m in my)return;my[m]=!0;const x=m.endsWith(".css"),y=x?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${m}"]${y}`))return;const b=document.createElement("link");if(b.rel=x?"stylesheet":yk,x||(b.as="script"),b.crossOrigin="",b.href=m,p&&b.setAttribute("nonce",p),document.head.appendChild(b),x)return new Promise((S,k)=>{b.addEventListener("load",S),b.addEventListener("error",()=>k(new Error(`Unable to preload CSS for ${m}`)))})}))}function u(c){const d=new Event("vite:preloadError",{cancelable:!0});if(d.payload=c,window.dispatchEvent(d),!d.defaultPrevented)throw c}return s.then(c=>{for(const d of c||[])d.status==="rejected"&&u(d.reason);return r().catch(u)})};function bk(){const t=Ce(A=>A.paletteOpen),r=Ce(A=>A.setPaletteOpen),l=Ce(A=>A.setCurrentView),i=Ge(A=>A.setTheme),{entries:s}=da(),{addMessage:u,clearMessages:c}=pe(),d=In(),[p,m]=w.useState(""),[x,y]=w.useState(0),b=w.useRef(null);w.useEffect(()=>{t&&(m(""),y(0),requestAnimationFrame(()=>{var A;return(A=b.current)==null?void 0:A.focus()}))},[t]),w.useEffect(()=>{const A=j=>{if((j.ctrlKey||j.metaKey)&&j.key.toLowerCase()==="k"){j.preventDefault(),r(!Ce.getState().paletteOpen);return}j.key==="Escape"&&Ce.getState().paletteOpen&&(j.preventDefault(),r(!1))};return window.addEventListener("keydown",A),()=>window.removeEventListener("keydown",A)},[r]);const S=w.useMemo(()=>{const A=[{id:"help",category:"Command",label:"Show slash commands",icon:T2,keywords:["help","commands","?"],run:()=>{u({role:"assistant",content:"Type `/` in the message box to see every slash command."})}},{id:"tools",category:"Command",label:"List tools",icon:wd,keywords:["tools","list"],run:()=>d.listTools()},{id:"memory",category:"Command",label:"Show memory",icon:f2,keywords:["memory","remember","notes"],run:()=>d.listMemory()},{id:"skills",category:"Command",label:"List skills",icon:r0,keywords:["skills"],run:()=>d.listSkills()},{id:"diag",category:"Command",label:"Runtime diagnostics",icon:V2,keywords:["diag","diagnostics","debug"],run:()=>d.getDiag()},{id:"stats",category:"Command",label:"Session stats (tokens, cache, cost)",icon:h2,keywords:["stats","tokens","cost","cache"],run:()=>d.getStats()},{id:"clear",category:"Session",label:"Clear context",hint:"Wipe in-memory context, keep session id",icon:Ai,keywords:["clear","reset","wipe"],run:()=>{var j,M;c(),(M=(j=d.client)==null?void 0:j.clearContext)==null||M.call(j)}},{id:"new",category:"Session",label:"New session",hint:"Brand-new on disk + memory",icon:Oi,keywords:["new","fresh","session"],run:()=>{var j,M;return(M=(j=d.client)==null?void 0:j.newSession)==null?void 0:M.call(j)}},{id:"compact",category:"Session",label:"Compact context",icon:Bf,keywords:["compact","shrink","context"],run:()=>{var j,M;return(M=(j=d.client)==null?void 0:j.compactContext)==null?void 0:M.call(j)}},{id:"export",category:"Session",label:"Export chat as markdown",icon:Hf,keywords:["export","save","markdown","download"],run:()=>Cd()},{id:"export-html",category:"Session",label:"Export chat as HTML",hint:"Self-contained, opens in any browser",icon:Hf,keywords:["export","html","download","archive"],run:()=>Sk()},{id:"history",category:"Command",label:"Open history",icon:qf,keywords:["history","sessions"],run:()=>l("history")},{id:"settings",category:"Command",label:"Open settings",icon:bd,keywords:["settings","config"],run:()=>l("settings")},{id:"model",category:"Command",label:"Change provider/model",icon:Ti,keywords:["model","provider","change"],run:()=>l("settings")},{id:"theme-light",category:"Theme",label:"Theme: Light",icon:vd,keywords:["theme","light","mode"],run:()=>i("light")},{id:"theme-dark",category:"Theme",label:"Theme: Dark",icon:xd,keywords:["theme","dark","mode"],run:()=>i("dark")},{id:"theme-system",category:"Theme",label:"Theme: Follow system",icon:yd,keywords:["theme","system","auto"],run:()=>i("system")},{id:"compact-toggle",category:"Command",label:"Toggle compact density",icon:R2,hint:"Ctrl+Shift+D",keywords:["compact","dense","density","size"],run:()=>Ce.getState().toggleCompactMode()},{id:"sound-toggle",category:"Command",label:Ge.getState().soundOnComplete?"Sound on completion: ON — turn off":"Sound on completion: OFF — turn on",icon:Ge.getState().soundOnComplete?F2:Y2,hint:"Chime when a run finishes",keywords:["sound","audio","chime","notify","beep"],run:()=>{const j=!Ge.getState().soundOnComplete;Ge.getState().setSoundOnComplete(j),j&&u0(()=>Promise.resolve().then(()=>s0),void 0).then(M=>M.playCompletionChime()).catch(()=>{})}}];for(const j of s.slice(0,10))j.isCurrent||A.push({id:`resume-${j.id}`,category:"Session",label:`Resume: ${j.title||"(empty)"}`,hint:`${j.provider}/${j.model}`,icon:Gx,keywords:["resume",j.title,j.id,j.provider,j.model],run:()=>d.resumeSession(j.id)});return A},[s,d,l,i,u,c]),k=w.useMemo(()=>{const A=p.toLowerCase().trim();return A?S.filter(j=>[j.label,j.hint??"",j.category,...j.keywords??[]].join(" ").toLowerCase().includes(A)):S},[S,p]);if(w.useEffect(()=>{x>=k.length&&y(0)},[k.length,x]),!t)return null;const N=A=>{A&&(r(!1),A.run())};return h.jsx("div",{className:"fixed inset-0 z-50 bg-background/60 backdrop-blur-sm flex items-start justify-center pt-[14vh] px-4",onClick:()=>r(!1),children:h.jsxs("div",{onClick:A=>A.stopPropagation(),className:"w-full max-w-2xl rounded-xl border bg-popover shadow-2xl overflow-hidden flex flex-col",children:[h.jsxs("div",{className:"flex items-center gap-2 px-4 py-3 border-b",children:[h.jsx(pa,{className:"h-4 w-4 text-muted-foreground"}),h.jsx("input",{ref:b,value:p,onChange:A=>m(A.target.value),placeholder:"Search commands, sessions, settings…",className:"flex-1 bg-transparent outline-none text-sm placeholder:text-muted-foreground",onKeyDown:A=>{A.key==="ArrowDown"?(A.preventDefault(),y(j=>(j+1)%Math.max(1,k.length))):A.key==="ArrowUp"?(A.preventDefault(),y(j=>(j-1+Math.max(1,k.length))%Math.max(1,k.length))):A.key==="Enter"&&(A.preventDefault(),N(k[x]))}}),h.jsx("kbd",{className:"text-[10px] text-muted-foreground border rounded px-1.5 py-0.5",children:"Esc"})]}),h.jsx("div",{className:"max-h-[60vh] overflow-y-auto",children:k.length===0?h.jsxs("div",{className:"px-4 py-8 text-center text-sm text-muted-foreground",children:['No matches for "',p,'"']}):vk(k,x,N,y)}),h.jsxs("div",{className:"border-t px-4 py-2 text-[10px] uppercase tracking-wider text-muted-foreground flex items-center gap-3",children:[h.jsx("span",{children:"↑↓ navigate"}),h.jsx("span",{children:"↵ select"}),h.jsx("span",{children:"Esc dismiss"})]})]})})}function vk(t,r,l,i){const s={};return t.forEach((u,c)=>{var d;(s[d=u.category]??(s[d]=[])).push({item:u,globalIdx:c})}),h.jsx("div",{className:"p-1",children:Object.entries(s).map(([u,c])=>h.jsxs("div",{children:[h.jsx("div",{className:"px-3 pt-2 pb-1 text-[10px] uppercase tracking-wider text-muted-foreground",children:u}),c.map(({item:d,globalIdx:p})=>{const m=d.icon,x=p===r;return h.jsxs("button",{onMouseEnter:()=>i(p),onClick:()=>l(d),className:he("w-full flex items-center gap-3 px-3 py-2 rounded text-left text-sm transition-colors",x?"bg-accent text-accent-foreground":"hover:bg-accent/40"),children:[h.jsx(m,{className:"h-4 w-4 text-muted-foreground shrink-0"}),h.jsxs("div",{className:"flex-1 min-w-0",children:[h.jsx("div",{className:"truncate",children:d.label}),d.hint&&h.jsx("div",{className:"text-xs text-muted-foreground truncate",children:d.hint})]}),x&&h.jsx("span",{className:"text-[10px] text-muted-foreground",children:"↵"})]},d.id)})]},u))})}function Cd(){const t=pe.getState().messages;pe.getState();const r=[],l=new Date().toISOString().slice(0,19).replace(/[:T]/g,"-");r.push("# WrongStack chat export"),r.push(`*Exported: ${new Date().toISOString()}*`),r.push("");for(const c of t)if(c.role==="user")r.push("## 👤 User"),r.push(""),r.push(c.content),r.push("");else if(c.role==="assistant")r.push("## 🤖 Assistant"),r.push(""),r.push(c.content),r.push("");else if(c.role==="tool"){const d=c.isError?"❌":c.toolResult!==void 0?"✅":"⏳";r.push(`### 🔧 Tool: \`${c.toolName??"unknown"}\` ${d}`),c.toolInput!==void 0&&(r.push("```json"),r.push(JSON.stringify(c.toolInput,null,2)),r.push("```")),c.toolResult&&(r.push("<details><summary>Output</summary>"),r.push(""),r.push("```"),r.push(c.toolResult),r.push("```"),r.push("</details>")),r.push("")}const i=new Blob([r.join(`
|
|
465
|
-
`)],{type:"text/markdown"}),s=URL.createObjectURL(i),u=document.createElement("a");u.href=s,u.download=`wrongstack-chat-${l}.md`,document.body.appendChild(u),u.click(),document.body.removeChild(u),URL.revokeObjectURL(s)}function Sk(){var m,x,y;const t=pe.getState().messages,r=Ye.getState(),l=new Date().toISOString().slice(0,19).replace(/[:T]/g,"-"),i=b=>b.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'"),s=t.map(b=>{if(b.role==="tool"){const A=b.isError?"❌":b.toolResult!==void 0?"✅":"⏳";return`
|
|
466
|
-
<section class="bubble tool ${b.isError?"error":""}">
|
|
467
|
-
<header><span class="icon">🔧</span><code>${i(b.toolName??"tool")}</code> ${A}</header>
|
|
468
|
-
${b.toolInput!==void 0?`<details><summary>Input</summary><pre>${i(JSON.stringify(b.toolInput,null,2))}</pre></details>`:""}
|
|
469
|
-
${b.toolResult?`<details><summary>Output</summary><pre>${i(b.toolResult)}</pre></details>`:""}
|
|
470
|
-
</section>`}const S=b.role==="user"?"user":"assistant",k=b.role==="user"?"👤":"🤖",N=b.role==="user"?"User":"Assistant";return`
|
|
471
|
-
<section class="bubble ${S}">
|
|
472
|
-
<header><span class="icon">${k}</span><strong>${N}</strong></header>
|
|
473
|
-
<pre class="content">${i(b.content)}</pre>
|
|
474
|
-
</section>`}),u=`<!doctype html>
|
|
475
|
-
<html lang="en"><head>
|
|
476
|
-
<meta charset="utf-8">
|
|
477
|
-
<title>WrongStack chat — ${i(((m=r.session)==null?void 0:m.title)||r.projectName||"export")}</title>
|
|
478
|
-
<style>
|
|
479
|
-
:root { color-scheme: light dark; }
|
|
480
|
-
body { font: 14px/1.55 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; max-width: 920px; margin: 24px auto; padding: 0 16px; }
|
|
481
|
-
h1 { font-size: 20px; margin-bottom: 4px; }
|
|
482
|
-
.meta { color: #666; font-size: 12px; margin-bottom: 24px; }
|
|
483
|
-
.bubble { margin: 12px 0; padding: 10px 14px; border-radius: 10px; border: 1px solid #ddd; }
|
|
484
|
-
.bubble header { font-size: 11px; text-transform: uppercase; letter-spacing: .05em; color: #666; margin-bottom: 6px; }
|
|
485
|
-
.bubble header .icon { margin-right: 4px; }
|
|
486
|
-
.bubble.user { background: #eef4ff; border-color: #c8d8f5; }
|
|
487
|
-
.bubble.assistant { background: #fff; }
|
|
488
|
-
.bubble.tool { background: #fafafa; }
|
|
489
|
-
.bubble.tool.error { background: #fff5f5; border-color: #f5c8c8; }
|
|
490
|
-
pre.content, .bubble pre { white-space: pre-wrap; word-break: break-word; font: 12px/1.5 ui-monospace, Menlo, Consolas, monospace; margin: 0; }
|
|
491
|
-
details summary { cursor: pointer; color: #555; font-size: 12px; }
|
|
492
|
-
details pre { margin-top: 6px; background: #f4f4f4; padding: 8px; border-radius: 6px; max-height: 360px; overflow: auto; }
|
|
493
|
-
@media (prefers-color-scheme: dark) {
|
|
494
|
-
body { background: #0d0d0f; color: #e6e6e6; }
|
|
495
|
-
.bubble { border-color: #2a2a2e; }
|
|
496
|
-
.bubble.user { background: #16213a; border-color: #2a3d6b; }
|
|
497
|
-
.bubble.assistant { background: #161618; }
|
|
498
|
-
.bubble.tool { background: #131315; }
|
|
499
|
-
.bubble.tool.error { background: #2a1717; border-color: #5c2a2a; }
|
|
500
|
-
details pre { background: #1a1a1c; }
|
|
501
|
-
.meta, .bubble header, details summary { color: #999; }
|
|
502
|
-
}
|
|
503
|
-
</style>
|
|
504
|
-
</head><body>
|
|
505
|
-
<h1>WrongStack chat — ${i(((x=r.session)==null?void 0:x.title)||r.projectName||"export")}</h1>
|
|
506
|
-
<div class="meta">
|
|
507
|
-
Exported ${new Date().toISOString()}${(y=r.session)!=null&&y.provider?` · ${i(r.session.provider)}/${i(r.session.model)}`:""} · ${t.length} message${t.length===1?"":"s"}
|
|
508
|
-
</div>
|
|
509
|
-
${s.join("")}
|
|
510
|
-
</body></html>`,c=new Blob([u],{type:"text/html;charset=utf-8"}),d=URL.createObjectURL(c),p=document.createElement("a");p.href=d,p.download=`wrongstack-chat-${l}.html`,document.body.appendChild(p),p.click(),document.body.removeChild(p),URL.revokeObjectURL(d)}function wk({query:t,onPick:r,onClose:l}){const i=In(),s=Ge(y=>y.wsUrl),[u,c]=w.useState([]),[d,p]=w.useState(0),m=w.useRef(null),x=w.useRef(null);return w.useEffect(()=>{const b=Hn(s).on("files.list",S=>{var N;const k=S.payload;c(k.files??[]),p(0),(N=x.current)==null||N.resolve(k.files??[]),x.current=null});return()=>b()},[s]),w.useEffect(()=>(m.current&&clearTimeout(m.current),m.current=setTimeout(()=>{i.client.listFiles(t,50)},80),()=>{m.current&&clearTimeout(m.current)}),[t,i.client]),w.useEffect(()=>{const y=b=>{if(b.key==="ArrowDown")b.preventDefault(),p(S=>(S+1)%Math.max(1,u.length));else if(b.key==="ArrowUp")b.preventDefault(),p(S=>(S-1+Math.max(1,u.length))%Math.max(1,u.length));else if(b.key==="Enter"||b.key==="Tab"){if(u.length===0)return;b.preventDefault(),r(u[d])}else b.key==="Escape"&&(b.preventDefault(),l())};return window.addEventListener("keydown",y,!0),()=>window.removeEventListener("keydown",y,!0)},[u,d,r,l]),h.jsxs("div",{className:"absolute bottom-full left-0 right-0 mb-2 rounded-lg border bg-popover shadow-md p-1 text-sm max-h-72 overflow-auto",children:[h.jsxs("div",{className:"px-3 py-1 text-[10px] uppercase tracking-wider text-muted-foreground border-b mb-1 flex items-center justify-between",children:[h.jsxs("span",{children:["@ Files ",t&&`· "${t}"`]}),h.jsx("span",{children:"↑/↓ select · ↵ insert · Esc dismiss"})]}),u.length===0?h.jsx("div",{className:"px-3 py-2 text-xs text-muted-foreground italic",children:t?`No files match "${t}"`:"Searching project…"}):u.map((y,b)=>h.jsxs("button",{type:"button",onClick:()=>r(y),onMouseEnter:()=>p(b),className:he("w-full text-left px-3 py-1.5 rounded transition-colors flex items-center gap-2 font-mono text-xs",b===d?"bg-accent text-accent-foreground":"hover:bg-accent/40"),children:[y.includes("/")?h.jsx(j2,{className:"h-3.5 w-3.5 text-muted-foreground shrink-0"}):h.jsx(N2,{className:"h-3.5 w-3.5 text-muted-foreground shrink-0"}),h.jsx("span",{className:"truncate",children:y})]},y))]})}const Vf=[{name:"/help",category:"App",description:"Show every slash command and what it does"},{name:"/export",category:"Session",description:"Download the current chat as markdown"},{name:"/todos",category:"Inspect",description:"List current todos (try `/todos clear` to reset)"},{name:"/clear",category:"Session",description:"Wipe current context (keeps session id, disk record stays)"},{name:"/new",category:"Session",description:"Start a brand-new session (fresh on disk and in memory)"},{name:"/compact",category:"Session",description:"Shrink context — elide ancient tool output"},{name:"/debug",category:"Inspect",aliases:["/context"],description:"Per-section context size breakdown"},{name:"/tools",category:"Inspect",description:"List every registered tool the model can call"},{name:"/memory",category:"Inspect",description:"Show all remembered notes (project + user scope)"},{name:"/skill",category:"Inspect",aliases:["/skills"],description:"List active skills"},{name:"/diag",category:"Inspect",description:"Runtime diagnostics (provider, tools, features, mode, usage)"},{name:"/stats",category:"Inspect",description:"Session stats: tokens, cache hit ratio, cost, elapsed"},{name:"/save",category:"Session",description:"Force-flush the session (auto-saved already)"},{name:"/abort",category:"Run",aliases:["/stop"],description:"Abort the current run"},{name:"/settings",category:"App",aliases:["/model"],description:"Open settings (provider/model/keys)"}],kk=["Run","Session","Inspect","App"];function py(t,r){let l=r-1;for(;l>=0;){const i=t[l];if(i==="@"){const s=l>0?t[l-1]:"";return l===0||/\s/.test(s??"")?{start:l,query:t.slice(l+1,r)}:null}if(/\s/.test(i))return null;l--}return null}function Ck(t){const r=t.toLowerCase();return r==="/"||r===""?Vf:Vf.filter(l=>{var i;return l.name.startsWith(r)||(((i=l.aliases)==null?void 0:i.some(s=>s.startsWith(r)))??!1)})}function Nk(){const{isLoading:t,setLoading:r,addMessage:l,clearMessages:i}=pe(),s=pe(T=>T.queue),u=pe(T=>T.enqueue),c=pe(T=>T.removeQueued),d=pe(T=>T.clearQueue),{setCurrentView:p}=Ce(),m=Ce(T=>T.pushPrompt),x=Ce(T=>T.promptHistory),y=In(),{sendMessage:b,sendAbort:S,client:k}=y,N=Ye(T=>T.lastInputTokens),A=Ye(T=>T.maxContext),[j,M]=w.useState(""),[z,V]=w.useState(0),[Q,B]=w.useState(-1),[G,ae]=w.useState(null),[se,L]=w.useState(null),[P,X]=w.useState(!1),de=w.useRef(null),I=w.useCallback(T=>{var W,be,we,Ae,dt;const U=T.trim(),E=U.indexOf(" "),O=(E===-1?U:U.slice(0,E)).toLowerCase(),ee=E===-1?"":U.slice(E+1).trim(),re=O;switch(re){case"/help":{const st=["📖 **Slash commands**","",...Vf.map(Te=>{var xe;return`• \`${Te.name}\`${(xe=Te.aliases)!=null&&xe.length?` (${Te.aliases.map(De=>`\`${De}\``).join(", ")})`:""} — ${Te.description}`})];return l({role:"assistant",content:st.join(`
|
|
511
|
-
`)}),!0}case"/clear":return i(),(W=k==null?void 0:k.clearContext)==null||W.call(k),!0;case"/new":return(be=k==null?void 0:k.newSession)==null||be.call(k),!0;case"/compact":case"/compact!":return(we=k==null?void 0:k.compactContext)==null||we.call(k,re==="/compact!"),!0;case"/debug":case"/context":return(Ae=k==null?void 0:k.debugContext)==null||Ae.call(k),!0;case"/tools":return y.listTools(),!0;case"/memory":return y.listMemory(),!0;case"/skill":case"/skills":return y.listSkills(),!0;case"/diag":return y.getDiag(),!0;case"/stats":return y.getStats(),!0;case"/save":return y.saveSession(),!0;case"/todos":{if(ee.toLowerCase()==="clear")return(dt=k==null?void 0:k.clearTodos)==null||dt.call(k),!0;const Te=Ye.getState().todos;if(Te.length===0)return l({role:"assistant",content:"✅ **Todos** — _empty. Ask the agent to plan something and they'll show up here._"}),!0;const xe=[`✅ **Todos** (${Te.filter(De=>De.status==="completed").length}/${Te.length} done)`,""];for(const De of Te){const at=De.status==="completed"?"[x]":De.status==="in_progress"?"[~]":"[ ]",ht=De.status==="in_progress"&&De.activeForm?De.activeForm:De.content;xe.push(`- ${at} ${ht}`)}return xe.push("","_Use `/todos clear` to wipe the list._"),l({role:"assistant",content:xe.join(`
|
|
512
|
-
`)}),!0}case"/export":return Cd(),l({role:"assistant",content:"📥 Chat exported to your downloads folder."}),!0;case"/abort":case"/stop":return S(),r(!1),!0;case"/settings":case"/model":return p("settings"),!0;default:return!1}},[l,i,k,S,r,p,y]),J=j.startsWith("/")&&!j.includes(" ")?Ck(j):[];w.useEffect(()=>{z>=J.length&&V(0)},[J.length,z]);const H=w.useCallback(async T=>{if(T.preventDefault(),!j.trim())return;const U=j.trim();if(U.startsWith("/")&&I(U)){m(U),M(""),B(-1);return}if(M(""),B(-1),m(U),t){u(U);return}try{k!=null&&k.isConnected?(l({role:"user",content:U}),r(!0),b(U)):console.error("WebSocket not connected")}catch(E){console.error("Failed to send:",E),r(!1)}},[j,t,u,k,b,r,l,I,m]),ne=w.useCallback(()=>{S(),r(!1)},[S,r]),oe=w.useCallback(()=>{S(),r(!1);const T=pe.getState().messages;for(let U=T.length-1;U>=0;U--){const E=T[U];if(E.role==="user"&&E.content){M(E.content),requestAnimationFrame(()=>{const O=de.current;O&&(O.style.height="auto",O.style.height=`${Math.min(O.scrollHeight,200)}px`,O.focus(),O.setSelectionRange(E.content.length,E.content.length))});return}}},[S,r]),ye=T=>{if(J.length===0&&!G&&x.length>0){if(T.key==="ArrowUp"){const U=T.currentTarget,E=U.value.slice(0,U.selectionStart);if(Q>=0||E.indexOf(`
|
|
513
|
-
`)===-1){T.preventDefault();const O=Math.min(x.length-1,Q+1);B(O);const ee=x[O]??"";M(ee),requestAnimationFrame(()=>{const re=de.current;re&&(re.style.height="auto",re.style.height=`${Math.min(re.scrollHeight,200)}px`,re.setSelectionRange(ee.length,ee.length))});return}}if(T.key==="ArrowDown"&&Q>=0){T.preventDefault();const U=Q-1;if(U<0)B(-1),M("");else{B(U);const E=x[U]??"";M(E),requestAnimationFrame(()=>{const O=de.current;O&&(O.style.height="auto",O.style.height=`${Math.min(O.scrollHeight,200)}px`,O.setSelectionRange(E.length,E.length))})}return}}if(J.length>0){if(T.key==="ArrowDown"){T.preventDefault(),V(U=>(U+1)%J.length);return}if(T.key==="ArrowUp"){T.preventDefault(),V(U=>(U-1+J.length)%J.length);return}if(T.key==="Tab"){T.preventDefault();const U=J[z];U&&(M(U.name+" "),V(0));return}if(T.key==="Enter"&&!T.shiftKey){const U=J[z];if(U&&U.name!==j.toLowerCase().trim()){T.preventDefault(),M(""),I(U.name);return}}if(T.key==="Escape"){T.preventDefault(),M("");return}}T.key==="Enter"&&!T.shiftKey&&(T.preventDefault(),H(T))},D=()=>{const T=de.current;T&&(T.style.height="auto",T.style.height=`${Math.min(T.scrollHeight,200)}px`)};return h.jsxs("div",{className:"flex flex-col gap-2",children:[se&&h.jsxs("div",{className:"rounded-md border border-amber-500/30 bg-amber-500/5 text-amber-700 dark:text-amber-300 px-2.5 py-1.5 text-xs flex items-center justify-between gap-2 animate-message",children:[h.jsxs("span",{children:["Pasted ",h.jsx("span",{className:"font-mono tabular-nums",children:se.chars.toLocaleString()})," chars (",h.jsx("span",{className:"font-mono tabular-nums",children:se.lines})," lines) — fenced code blocks render best with"," ",h.jsx("span",{className:"font-mono",children:"```"}),"."]}),h.jsx("button",{type:"button",onClick:()=>L(null),className:"text-amber-600/70 hover:text-amber-600 dark:text-amber-300/70 dark:hover:text-amber-300 shrink-0",title:"Dismiss",children:"×"})]}),s.length>0&&h.jsxs("div",{className:"rounded-lg border bg-muted/30 p-2 text-xs",children:[h.jsxs("div",{className:"flex items-center justify-between mb-1.5",children:[h.jsxs("span",{className:"text-[10px] uppercase tracking-wider text-muted-foreground font-medium",children:["Queued (",s.length,")"]}),h.jsx("button",{type:"button",onClick:d,className:"text-muted-foreground hover:text-destructive text-xs",children:"Clear all"})]}),h.jsx("ul",{className:"space-y-1",children:s.map((T,U)=>h.jsxs("li",{className:"flex items-start justify-between gap-2 rounded bg-background/60 border px-2 py-1",children:[h.jsx("span",{className:"truncate flex-1 min-w-0",children:T}),h.jsx("button",{type:"button",onClick:()=>c(U),className:"text-muted-foreground hover:text-destructive shrink-0",title:"Remove from queue",children:"×"})]},U))})]}),h.jsxs("form",{onSubmit:H,onDragEnter:T=>{!T.dataTransfer||!Array.from(T.dataTransfer.types).includes("Files")||(T.preventDefault(),X(!0))},onDragOver:T=>{!T.dataTransfer||!Array.from(T.dataTransfer.types).includes("Files")||(T.preventDefault(),T.dataTransfer.dropEffect="copy")},onDragLeave:T=>{T.currentTarget.contains(T.relatedTarget)||X(!1)},onDrop:T=>{if(!T.dataTransfer)return;const U=Array.from(T.dataTransfer.files??[]);if(U.length===0){X(!1);return}T.preventDefault(),X(!1);const E=de.current,O=(E==null?void 0:E.selectionStart)??j.length,ee=j.slice(0,O),re=j.slice(O),be=ee.length>0&&!/\s$/.test(ee)?" ":"",we=U.map(ht=>`@${ht.name}`),Ae=we.join(" "),st=re.length===0||!/^\s/.test(re)?" ":"",Te=`${be}${Ae}${st}`,xe=ee+Te+re;M(xe);const De=ee.length+be.length+we.slice(0,-1).join(" ").length+(we.length>1?1:0),at=U[U.length-1].name;requestAnimationFrame(()=>{if(E){const ht=ee.length+Te.length-st.length;E.focus(),E.setSelectionRange(ht,ht),E.style.height="auto",E.style.height=`${Math.min(E.scrollHeight,200)}px`}ae({start:De,query:at})})},className:he("flex items-end gap-2 relative rounded-lg transition-colors",P&&"ring-2 ring-primary ring-offset-2 ring-offset-background bg-primary/5"),children:[P&&h.jsxs("div",{className:"absolute inset-0 z-20 flex items-center justify-center pointer-events-none rounded-lg bg-primary/10 text-primary text-sm font-medium",children:["Drop file","(s)"," to attach as @-mention"]}),h.jsxs("div",{className:"relative flex-1",children:[G&&h.jsx(wk,{query:G.query,onClose:()=>ae(null),onPick:T=>{const U=j.slice(0,G.start),E=j.slice(G.start+1+G.query.length),O=`@${T} `,ee=U+O+E;M(ee),ae(null),requestAnimationFrame(()=>{const re=de.current;if(re){const W=U.length+O.length;re.focus(),re.setSelectionRange(W,W),re.style.height="auto",re.style.height=`${Math.min(re.scrollHeight,200)}px`}})}}),!G&&J.length>0&&(()=>{const T={};J.forEach((E,O)=>{var ee;(T[ee=E.category]??(T[ee]=[])).push({cmd:E,idx:O})});const U=kk.filter(E=>{var O;return(O=T[E])==null?void 0:O.length});return h.jsxs("div",{className:"absolute bottom-full left-0 right-0 mb-2 rounded-lg border bg-popover shadow-md p-1 text-sm max-h-72 overflow-auto",children:[h.jsx("div",{className:"px-3 py-1 text-[10px] uppercase tracking-wider text-muted-foreground border-b mb-1",children:"↑/↓ select · Tab complete · Enter dispatch · Esc dismiss"}),U.map(E=>h.jsxs("div",{className:"mb-1",children:[h.jsx("div",{className:"px-3 pt-1 pb-0.5 text-[10px] uppercase tracking-wider text-muted-foreground/70 font-semibold",children:E}),T[E].map(({cmd:O,idx:ee})=>{var re;return h.jsxs("button",{type:"button",onClick:()=>{M(""),I(O.name)},onMouseEnter:()=>V(ee),className:he("w-full text-left px-3 py-1.5 rounded transition-colors flex items-center gap-3",ee===z?"bg-accent text-accent-foreground":"hover:bg-accent/40"),children:[h.jsx("span",{className:"font-mono shrink-0",children:O.name}),(re=O.aliases)!=null&&re.length?h.jsxs("span",{className:"text-xs text-muted-foreground/70 font-mono shrink-0",children:["(",O.aliases.join(", "),")"]}):null,h.jsxs("span",{className:"text-xs text-muted-foreground truncate",children:["— ",O.description]})]},O.name)})]},E))]})})(),h.jsx("textarea",{ref:de,value:j,onChange:T=>{const U=T.target.value;M(U),D(),Q>=0&&B(-1);const E=T.target.selectionStart??U.length;ae(py(U,E))},onSelect:T=>{const U=T.currentTarget;ae(py(U.value,U.selectionStart))},onKeyDown:ye,onPaste:T=>{var E;const U=((E=T.clipboardData)==null?void 0:E.getData("text"))??"";if(U.length>800){const O=U.split(`
|
|
514
|
-
`).length;L({chars:U.length,lines:O}),setTimeout(()=>L(null),4e3)}},placeholder:k!=null&&k.isConnected?t?"Agent is running — type to queue a follow-up…":"Message WrongStack… (type / for commands, @ for files)":"Connect to server first…",className:he("flex min-h-[44px] w-full resize-none rounded-lg border border-input bg-background px-4 py-3 pr-12","text-sm ring-offset-background placeholder:text-muted-foreground","focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2","disabled:cursor-not-allowed disabled:opacity-50","scrollbar-thin"),rows:1,disabled:!(k!=null&&k.isConnected)}),j.length>0&&(()=>{const T=j.length>=400,U=Math.ceil(j.length/4);let E="text-muted-foreground",O;if(A>0&&T){const re=(N+U+64)/A*100;re>=100?(E="text-red-600 dark:text-red-400 font-medium",O=`Projected ${Math.round(re)}% of ${A.toLocaleString()} ctx — will likely error or compact.`):re>=85?(E="text-amber-600 dark:text-amber-400 font-medium",O=`Projected ${Math.round(re)}% of ${A.toLocaleString()} ctx — getting tight.`):O=`≈ ${U.toLocaleString()} tokens · projected ${Math.round(re)}% of ${A.toLocaleString()} ctx.`}else T&&(O=`≈ ${U.toLocaleString()} tokens (4-char heuristic)`);return h.jsxs("span",{className:he("absolute bottom-1.5 right-12 text-xs tabular-nums",E),title:O,children:[j.length,T&&h.jsxs("span",{className:"ml-1 opacity-70",children:["· ≈",U>=1e3?`${(U/1e3).toFixed(1)}k`:U,"t"]})]})})()]}),h.jsx("div",{className:"flex gap-1",children:t?h.jsxs(h.Fragment,{children:[h.jsx(Ve,{type:"button",size:"icon",variant:"outline",onClick:oe,className:"h-[44px] w-[44px] rounded-lg",title:"Stop run and edit the last prompt (reuse + rewrite)",children:h.jsx(e0,{className:"h-4 w-4"})}),h.jsx(Ve,{type:"button",size:"icon",variant:"destructive",onClick:ne,className:"h-[44px] w-[44px] rounded-lg",title:"Abort the current run",children:h.jsx(I2,{className:"h-4 w-4 fill-current"})})]}):h.jsx(Ve,{type:"submit",size:"icon",disabled:!j.trim()||!(k!=null&&k.isConnected),className:"h-[44px] w-[44px] rounded-lg",children:h.jsx(H2,{className:"h-4 w-4"})})})]})]})}function Ek(t,r){const l={};return(t[t.length-1]===""?[...t,""]:t).join((l.padRight?" ":"")+","+(l.padLeft===!1?"":" ")).trim()}const jk=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,Tk=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,Ak={};function gy(t,r){return(Ak.jsx?Tk:jk).test(t)}const Mk=/[ \t\n\f\r]/g;function Dk(t){return typeof t=="object"?t.type==="text"?yy(t.value):!1:yy(t)}function yy(t){return t.replace(Mk,"")===""}class _i{constructor(r,l,i){this.normal=l,this.property=r,i&&(this.space=i)}}_i.prototype.normal={};_i.prototype.property={};_i.prototype.space=void 0;function c0(t,r){const l={},i={};for(const s of t)Object.assign(l,s.property),Object.assign(i,s.normal);return new _i(l,i,r)}function $f(t){return t.toLowerCase()}class nn{constructor(r,l){this.attribute=l,this.property=r}}nn.prototype.attribute="";nn.prototype.booleanish=!1;nn.prototype.boolean=!1;nn.prototype.commaOrSpaceSeparated=!1;nn.prototype.commaSeparated=!1;nn.prototype.defined=!1;nn.prototype.mustUseProperty=!1;nn.prototype.number=!1;nn.prototype.overloadedBoolean=!1;nn.prototype.property="";nn.prototype.spaceSeparated=!1;nn.prototype.space=void 0;let Rk=0;const Le=yl(),jt=yl(),Ff=yl(),ce=yl(),ot=yl(),ca=yl(),fn=yl();function yl(){return 2**++Rk}const Yf=Object.freeze(Object.defineProperty({__proto__:null,boolean:Le,booleanish:jt,commaOrSpaceSeparated:fn,commaSeparated:ca,number:ce,overloadedBoolean:Ff,spaceSeparated:ot},Symbol.toStringTag,{value:"Module"})),of=Object.keys(Yf);class Nd extends nn{constructor(r,l,i,s){let u=-1;if(super(r,l),xy(this,"space",s),typeof i=="number")for(;++u<of.length;){const c=of[u];xy(this,of[u],(i&Yf[c])===Yf[c])}}}Nd.prototype.defined=!0;function xy(t,r,l){l&&(t[r]=l)}function va(t){const r={},l={};for(const[i,s]of Object.entries(t.properties)){const u=new Nd(i,t.transform(t.attributes||{},i),s,t.space);t.mustUseProperty&&t.mustUseProperty.includes(i)&&(u.mustUseProperty=!0),r[i]=u,l[$f(i)]=i,l[$f(u.attribute)]=i}return new _i(r,l,t.space)}const f0=va({properties:{ariaActiveDescendant:null,ariaAtomic:jt,ariaAutoComplete:null,ariaBusy:jt,ariaChecked:jt,ariaColCount:ce,ariaColIndex:ce,ariaColSpan:ce,ariaControls:ot,ariaCurrent:null,ariaDescribedBy:ot,ariaDetails:null,ariaDisabled:jt,ariaDropEffect:ot,ariaErrorMessage:null,ariaExpanded:jt,ariaFlowTo:ot,ariaGrabbed:jt,ariaHasPopup:null,ariaHidden:jt,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:ot,ariaLevel:ce,ariaLive:null,ariaModal:jt,ariaMultiLine:jt,ariaMultiSelectable:jt,ariaOrientation:null,ariaOwns:ot,ariaPlaceholder:null,ariaPosInSet:ce,ariaPressed:jt,ariaReadOnly:jt,ariaRelevant:null,ariaRequired:jt,ariaRoleDescription:ot,ariaRowCount:ce,ariaRowIndex:ce,ariaRowSpan:ce,ariaSelected:jt,ariaSetSize:ce,ariaSort:null,ariaValueMax:ce,ariaValueMin:ce,ariaValueNow:ce,ariaValueText:null,role:null},transform(t,r){return r==="role"?r:"aria-"+r.slice(4).toLowerCase()}});function d0(t,r){return r in t?t[r]:r}function h0(t,r){return d0(t,r.toLowerCase())}const zk=va({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:ca,acceptCharset:ot,accessKey:ot,action:null,allow:null,allowFullScreen:Le,allowPaymentRequest:Le,allowUserMedia:Le,alt:null,as:null,async:Le,autoCapitalize:null,autoComplete:ot,autoFocus:Le,autoPlay:Le,blocking:ot,capture:null,charSet:null,checked:Le,cite:null,className:ot,cols:ce,colSpan:null,content:null,contentEditable:jt,controls:Le,controlsList:ot,coords:ce|ca,crossOrigin:null,data:null,dateTime:null,decoding:null,default:Le,defer:Le,dir:null,dirName:null,disabled:Le,download:Ff,draggable:jt,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:Le,formTarget:null,headers:ot,height:ce,hidden:Ff,high:ce,href:null,hrefLang:null,htmlFor:ot,httpEquiv:ot,id:null,imageSizes:null,imageSrcSet:null,inert:Le,inputMode:null,integrity:null,is:null,isMap:Le,itemId:null,itemProp:ot,itemRef:ot,itemScope:Le,itemType:ot,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:Le,low:ce,manifest:null,max:null,maxLength:ce,media:null,method:null,min:null,minLength:ce,multiple:Le,muted:Le,name:null,nonce:null,noModule:Le,noValidate:Le,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:Le,optimum:ce,pattern:null,ping:ot,placeholder:null,playsInline:Le,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:Le,referrerPolicy:null,rel:ot,required:Le,reversed:Le,rows:ce,rowSpan:ce,sandbox:ot,scope:null,scoped:Le,seamless:Le,selected:Le,shadowRootClonable:Le,shadowRootDelegatesFocus:Le,shadowRootMode:null,shape:null,size:ce,sizes:null,slot:null,span:ce,spellCheck:jt,src:null,srcDoc:null,srcLang:null,srcSet:null,start:ce,step:null,style:null,tabIndex:ce,target:null,title:null,translate:null,type:null,typeMustMatch:Le,useMap:null,value:jt,width:ce,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:ot,axis:null,background:null,bgColor:null,border:ce,borderColor:null,bottomMargin:ce,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:Le,declare:Le,event:null,face:null,frame:null,frameBorder:null,hSpace:ce,leftMargin:ce,link:null,longDesc:null,lowSrc:null,marginHeight:ce,marginWidth:ce,noResize:Le,noHref:Le,noShade:Le,noWrap:Le,object:null,profile:null,prompt:null,rev:null,rightMargin:ce,rules:null,scheme:null,scrolling:jt,standby:null,summary:null,text:null,topMargin:ce,valueType:null,version:null,vAlign:null,vLink:null,vSpace:ce,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:Le,disableRemotePlayback:Le,prefix:null,property:null,results:ce,security:null,unselectable:null},space:"html",transform:h0}),Ok=va({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",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",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",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",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",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",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:fn,accentHeight:ce,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:ce,amplitude:ce,arabicForm:null,ascent:ce,attributeName:null,attributeType:null,azimuth:ce,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:ce,by:null,calcMode:null,capHeight:ce,className:ot,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:ce,diffuseConstant:ce,direction:null,display:null,dur:null,divisor:ce,dominantBaseline:null,download:Le,dx:null,dy:null,edgeMode:null,editable:null,elevation:ce,enableBackground:null,end:null,event:null,exponent:ce,externalResourcesRequired:null,fill:null,fillOpacity:ce,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:ca,g2:ca,glyphName:ca,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:ce,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:ce,horizOriginX:ce,horizOriginY:ce,id:null,ideographic:ce,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:ce,k:ce,k1:ce,k2:ce,k3:ce,k4:ce,kernelMatrix:fn,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:ce,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:ce,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:ce,overlineThickness:ce,paintOrder:null,panose1:null,path:null,pathLength:ce,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:ot,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:ce,pointsAtY:ce,pointsAtZ:ce,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:fn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:fn,rev:fn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:fn,requiredFeatures:fn,requiredFonts:fn,requiredFormats:fn,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:ce,specularExponent:ce,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:ce,strikethroughThickness:ce,string:null,stroke:null,strokeDashArray:fn,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:ce,strokeOpacity:ce,strokeWidth:null,style:null,surfaceScale:ce,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:fn,tabIndex:ce,tableValues:null,target:null,targetX:ce,targetY:ce,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:fn,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:ce,underlineThickness:ce,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:ce,values:null,vAlphabetic:ce,vMathematical:ce,vectorEffect:null,vHanging:ce,vIdeographic:ce,version:null,vertAdvY:ce,vertOriginX:ce,vertOriginY:ce,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:ce,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:d0}),m0=va({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(t,r){return"xlink:"+r.slice(5).toLowerCase()}}),p0=va({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:h0}),g0=va({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(t,r){return"xml:"+r.slice(3).toLowerCase()}}),_k={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},Lk=/[A-Z]/g,by=/-[a-z]/g,Uk=/^data[-\w.:]+$/i;function Bk(t,r){const l=$f(r);let i=r,s=nn;if(l in t.normal)return t.property[t.normal[l]];if(l.length>4&&l.slice(0,4)==="data"&&Uk.test(r)){if(r.charAt(4)==="-"){const u=r.slice(5).replace(by,qk);i="data"+u.charAt(0).toUpperCase()+u.slice(1)}else{const u=r.slice(4);if(!by.test(u)){let c=u.replace(Lk,Hk);c.charAt(0)!=="-"&&(c="-"+c),r="data"+c}}s=Nd}return new s(i,r)}function Hk(t){return"-"+t.toLowerCase()}function qk(t){return t.charAt(1).toUpperCase()}const Ik=c0([f0,zk,m0,p0,g0],"html"),Ed=c0([f0,Ok,m0,p0,g0],"svg");function Vk(t){return t.join(" ").trim()}var ra={},sf,vy;function $k(){if(vy)return sf;vy=1;var t=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,r=/\n/g,l=/^\s*/,i=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,s=/^:\s*/,u=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,c=/^[;\s]*/,d=/^\s+|\s+$/g,p=`
|
|
515
|
-
`,m="/",x="*",y="",b="comment",S="declaration";function k(A,j){if(typeof A!="string")throw new TypeError("First argument must be a string");if(!A)return[];j=j||{};var M=1,z=1;function V(I){var J=I.match(r);J&&(M+=J.length);var H=I.lastIndexOf(p);z=~H?I.length-H:z+I.length}function Q(){var I={line:M,column:z};return function(J){return J.position=new B(I),se(),J}}function B(I){this.start=I,this.end={line:M,column:z},this.source=j.source}B.prototype.content=A;function G(I){var J=new Error(j.source+":"+M+":"+z+": "+I);if(J.reason=I,J.filename=j.source,J.line=M,J.column=z,J.source=A,!j.silent)throw J}function ae(I){var J=I.exec(A);if(J){var H=J[0];return V(H),A=A.slice(H.length),J}}function se(){ae(l)}function L(I){var J;for(I=I||[];J=P();)J!==!1&&I.push(J);return I}function P(){var I=Q();if(!(m!=A.charAt(0)||x!=A.charAt(1))){for(var J=2;y!=A.charAt(J)&&(x!=A.charAt(J)||m!=A.charAt(J+1));)++J;if(J+=2,y===A.charAt(J-1))return G("End of comment missing");var H=A.slice(2,J-2);return z+=2,V(H),A=A.slice(J),z+=2,I({type:b,comment:H})}}function X(){var I=Q(),J=ae(i);if(J){if(P(),!ae(s))return G("property missing ':'");var H=ae(u),ne=I({type:S,property:N(J[0].replace(t,y)),value:H?N(H[0].replace(t,y)):y});return ae(c),ne}}function de(){var I=[];L(I);for(var J;J=X();)J!==!1&&(I.push(J),L(I));return I}return se(),de()}function N(A){return A?A.replace(d,y):y}return sf=k,sf}var Sy;function Fk(){if(Sy)return ra;Sy=1;var t=ra&&ra.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(ra,"__esModule",{value:!0}),ra.default=l;const r=t($k());function l(i,s){let u=null;if(!i||typeof i!="string")return u;const c=(0,r.default)(i),d=typeof s=="function";return c.forEach(p=>{if(p.type!=="declaration")return;const{property:m,value:x}=p;d?s(m,x,p):x&&(u=u||{},u[m]=x)}),u}return ra}var xi={},wy;function Yk(){if(wy)return xi;wy=1,Object.defineProperty(xi,"__esModule",{value:!0}),xi.camelCase=void 0;var t=/^--[a-zA-Z0-9_-]+$/,r=/-([a-z])/g,l=/^[^-]+$/,i=/^-(webkit|moz|ms|o|khtml)-/,s=/^-(ms)-/,u=function(m){return!m||l.test(m)||t.test(m)},c=function(m,x){return x.toUpperCase()},d=function(m,x){return"".concat(x,"-")},p=function(m,x){return x===void 0&&(x={}),u(m)?m:(m=m.toLowerCase(),x.reactCompat?m=m.replace(s,d):m=m.replace(i,d),m.replace(r,c))};return xi.camelCase=p,xi}var bi,ky;function Gk(){if(ky)return bi;ky=1;var t=bi&&bi.__importDefault||function(s){return s&&s.__esModule?s:{default:s}},r=t(Fk()),l=Yk();function i(s,u){var c={};return!s||typeof s!="string"||(0,r.default)(s,function(d,p){d&&p&&(c[(0,l.camelCase)(d,u)]=p)}),c}return i.default=i,bi=i,bi}var Pk=Gk();const Xk=Ri(Pk),y0=x0("end"),jd=x0("start");function x0(t){return r;function r(l){const i=l&&l.position&&l.position[t]||{};if(typeof i.line=="number"&&i.line>0&&typeof i.column=="number"&&i.column>0)return{line:i.line,column:i.column,offset:typeof i.offset=="number"&&i.offset>-1?i.offset:void 0}}}function Qk(t){const r=jd(t),l=y0(t);if(r&&l)return{start:r,end:l}}function Ci(t){return!t||typeof t!="object"?"":"position"in t||"type"in t?Cy(t.position):"start"in t||"end"in t?Cy(t):"line"in t||"column"in t?Gf(t):""}function Gf(t){return Ny(t&&t.line)+":"+Ny(t&&t.column)}function Cy(t){return Gf(t&&t.start)+"-"+Gf(t&&t.end)}function Ny(t){return t&&typeof t=="number"?t:1}class Vt extends Error{constructor(r,l,i){super(),typeof l=="string"&&(i=l,l=void 0);let s="",u={},c=!1;if(l&&("line"in l&&"column"in l?u={place:l}:"start"in l&&"end"in l?u={place:l}:"type"in l?u={ancestors:[l],place:l.position}:u={...l}),typeof r=="string"?s=r:!u.cause&&r&&(c=!0,s=r.message,u.cause=r),!u.ruleId&&!u.source&&typeof i=="string"){const p=i.indexOf(":");p===-1?u.ruleId=i:(u.source=i.slice(0,p),u.ruleId=i.slice(p+1))}if(!u.place&&u.ancestors&&u.ancestors){const p=u.ancestors[u.ancestors.length-1];p&&(u.place=p.position)}const d=u.place&&"start"in u.place?u.place.start:u.place;this.ancestors=u.ancestors||void 0,this.cause=u.cause||void 0,this.column=d?d.column:void 0,this.fatal=void 0,this.file="",this.message=s,this.line=d?d.line:void 0,this.name=Ci(u.place)||"1:1",this.place=u.place||void 0,this.reason=this.message,this.ruleId=u.ruleId||void 0,this.source=u.source||void 0,this.stack=c&&u.cause&&typeof u.cause.stack=="string"?u.cause.stack:"",this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}}Vt.prototype.file="";Vt.prototype.name="";Vt.prototype.reason="";Vt.prototype.message="";Vt.prototype.stack="";Vt.prototype.column=void 0;Vt.prototype.line=void 0;Vt.prototype.ancestors=void 0;Vt.prototype.cause=void 0;Vt.prototype.fatal=void 0;Vt.prototype.place=void 0;Vt.prototype.ruleId=void 0;Vt.prototype.source=void 0;const Td={}.hasOwnProperty,Kk=new Map,Zk=/[A-Z]/g,Jk=new Set(["table","tbody","thead","tfoot","tr"]),Wk=new Set(["td","th"]),b0="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function eC(t,r){if(!r||r.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const l=r.filePath||void 0;let i;if(r.development){if(typeof r.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");i=sC(l,r.jsxDEV)}else{if(typeof r.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof r.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");i=oC(l,r.jsx,r.jsxs)}const s={Fragment:r.Fragment,ancestors:[],components:r.components||{},create:i,elementAttributeNameCase:r.elementAttributeNameCase||"react",evaluater:r.createEvaluater?r.createEvaluater():void 0,filePath:l,ignoreInvalidStyle:r.ignoreInvalidStyle||!1,passKeys:r.passKeys!==!1,passNode:r.passNode||!1,schema:r.space==="svg"?Ed:Ik,stylePropertyNameCase:r.stylePropertyNameCase||"dom",tableCellAlignToStyle:r.tableCellAlignToStyle!==!1},u=v0(s,t,void 0);return u&&typeof u!="string"?u:s.create(t,s.Fragment,{children:u||void 0},void 0)}function v0(t,r,l){if(r.type==="element")return tC(t,r,l);if(r.type==="mdxFlowExpression"||r.type==="mdxTextExpression")return nC(t,r);if(r.type==="mdxJsxFlowElement"||r.type==="mdxJsxTextElement")return lC(t,r,l);if(r.type==="mdxjsEsm")return rC(t,r);if(r.type==="root")return aC(t,r,l);if(r.type==="text")return iC(t,r)}function tC(t,r,l){const i=t.schema;let s=i;r.tagName.toLowerCase()==="svg"&&i.space==="html"&&(s=Ed,t.schema=s),t.ancestors.push(r);const u=w0(t,r.tagName,!1),c=uC(t,r);let d=Md(t,r);return Jk.has(r.tagName)&&(d=d.filter(function(p){return typeof p=="string"?!Dk(p):!0})),S0(t,c,u,r),Ad(c,d),t.ancestors.pop(),t.schema=i,t.create(r,u,c,l)}function nC(t,r){if(r.data&&r.data.estree&&t.evaluater){const i=r.data.estree.body[0];return i.type,t.evaluater.evaluateExpression(i.expression)}Mi(t,r.position)}function rC(t,r){if(r.data&&r.data.estree&&t.evaluater)return t.evaluater.evaluateProgram(r.data.estree);Mi(t,r.position)}function lC(t,r,l){const i=t.schema;let s=i;r.name==="svg"&&i.space==="html"&&(s=Ed,t.schema=s),t.ancestors.push(r);const u=r.name===null?t.Fragment:w0(t,r.name,!0),c=cC(t,r),d=Md(t,r);return S0(t,c,u,r),Ad(c,d),t.ancestors.pop(),t.schema=i,t.create(r,u,c,l)}function aC(t,r,l){const i={};return Ad(i,Md(t,r)),t.create(r,t.Fragment,i,l)}function iC(t,r){return r.value}function S0(t,r,l,i){typeof l!="string"&&l!==t.Fragment&&t.passNode&&(r.node=i)}function Ad(t,r){if(r.length>0){const l=r.length>1?r:r[0];l&&(t.children=l)}}function oC(t,r,l){return i;function i(s,u,c,d){const m=Array.isArray(c.children)?l:r;return d?m(u,c,d):m(u,c)}}function sC(t,r){return l;function l(i,s,u,c){const d=Array.isArray(u.children),p=jd(i);return r(s,u,c,d,{columnNumber:p?p.column-1:void 0,fileName:t,lineNumber:p?p.line:void 0},void 0)}}function uC(t,r){const l={};let i,s;for(s in r.properties)if(s!=="children"&&Td.call(r.properties,s)){const u=fC(t,s,r.properties[s]);if(u){const[c,d]=u;t.tableCellAlignToStyle&&c==="align"&&typeof d=="string"&&Wk.has(r.tagName)?i=d:l[c]=d}}if(i){const u=l.style||(l.style={});u[t.stylePropertyNameCase==="css"?"text-align":"textAlign"]=i}return l}function cC(t,r){const l={};for(const i of r.attributes)if(i.type==="mdxJsxExpressionAttribute")if(i.data&&i.data.estree&&t.evaluater){const u=i.data.estree.body[0];u.type;const c=u.expression;c.type;const d=c.properties[0];d.type,Object.assign(l,t.evaluater.evaluateExpression(d.argument))}else Mi(t,r.position);else{const s=i.name;let u;if(i.value&&typeof i.value=="object")if(i.value.data&&i.value.data.estree&&t.evaluater){const d=i.value.data.estree.body[0];d.type,u=t.evaluater.evaluateExpression(d.expression)}else Mi(t,r.position);else u=i.value===null?!0:i.value;l[s]=u}return l}function Md(t,r){const l=[];let i=-1;const s=t.passKeys?new Map:Kk;for(;++i<r.children.length;){const u=r.children[i];let c;if(t.passKeys){const p=u.type==="element"?u.tagName:u.type==="mdxJsxFlowElement"||u.type==="mdxJsxTextElement"?u.name:void 0;if(p){const m=s.get(p)||0;c=p+"-"+m,s.set(p,m+1)}}const d=v0(t,u,c);d!==void 0&&l.push(d)}return l}function fC(t,r,l){const i=Bk(t.schema,r);if(!(l==null||typeof l=="number"&&Number.isNaN(l))){if(Array.isArray(l)&&(l=i.commaSeparated?Ek(l):Vk(l)),i.property==="style"){let s=typeof l=="object"?l:dC(t,String(l));return t.stylePropertyNameCase==="css"&&(s=hC(s)),["style",s]}return[t.elementAttributeNameCase==="react"&&i.space?_k[i.property]||i.property:i.attribute,l]}}function dC(t,r){try{return Xk(r,{reactCompat:!0})}catch(l){if(t.ignoreInvalidStyle)return{};const i=l,s=new Vt("Cannot parse `style` attribute",{ancestors:t.ancestors,cause:i,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw s.file=t.filePath||void 0,s.url=b0+"#cannot-parse-style-attribute",s}}function w0(t,r,l){let i;if(!l)i={type:"Literal",value:r};else if(r.includes(".")){const s=r.split(".");let u=-1,c;for(;++u<s.length;){const d=gy(s[u])?{type:"Identifier",name:s[u]}:{type:"Literal",value:s[u]};c=c?{type:"MemberExpression",object:c,property:d,computed:!!(u&&d.type==="Literal"),optional:!1}:d}i=c}else i=gy(r)&&!/^[a-z]/.test(r)?{type:"Identifier",name:r}:{type:"Literal",value:r};if(i.type==="Literal"){const s=i.value;return Td.call(t.components,s)?t.components[s]:s}if(t.evaluater)return t.evaluater.evaluateExpression(i);Mi(t)}function Mi(t,r){const l=new Vt("Cannot handle MDX estrees without `createEvaluater`",{ancestors:t.ancestors,place:r,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw l.file=t.filePath||void 0,l.url=b0+"#cannot-handle-mdx-estrees-without-createevaluater",l}function hC(t){const r={};let l;for(l in t)Td.call(t,l)&&(r[mC(l)]=t[l]);return r}function mC(t){let r=t.replace(Zk,pC);return r.slice(0,3)==="ms-"&&(r="-"+r),r}function pC(t){return"-"+t.toLowerCase()}const uf={action:["form"],cite:["blockquote","del","ins","q"],data:["object"],formAction:["button","input"],href:["a","area","base","link"],icon:["menuitem"],itemId:null,manifest:["html"],ping:["a","area"],poster:["video"],src:["audio","embed","iframe","img","input","script","source","track","video"]},gC={};function Dd(t,r){const l=gC,i=typeof l.includeImageAlt=="boolean"?l.includeImageAlt:!0,s=typeof l.includeHtml=="boolean"?l.includeHtml:!0;return k0(t,i,s)}function k0(t,r,l){if(yC(t)){if("value"in t)return t.type==="html"&&!l?"":t.value;if(r&&"alt"in t&&t.alt)return t.alt;if("children"in t)return Ey(t.children,r,l)}return Array.isArray(t)?Ey(t,r,l):""}function Ey(t,r,l){const i=[];let s=-1;for(;++s<t.length;)i[s]=k0(t[s],r,l);return i.join("")}function yC(t){return!!(t&&typeof t=="object")}const jy=document.createElement("i");function Rd(t){const r="&"+t+";";jy.innerHTML=r;const l=jy.textContent;return l.charCodeAt(l.length-1)===59&&t!=="semi"||l===r?!1:l}function mn(t,r,l,i){const s=t.length;let u=0,c;if(r<0?r=-r>s?0:s+r:r=r>s?s:r,l=l>0?l:0,i.length<1e4)c=Array.from(i),c.unshift(r,l),t.splice(...c);else for(l&&t.splice(r,l);u<i.length;)c=i.slice(u,u+1e4),c.unshift(r,0),t.splice(...c),u+=1e4,r+=1e4}function Nn(t,r){return t.length>0?(mn(t,t.length,0,r),t):r}const Ty={}.hasOwnProperty;function C0(t){const r={};let l=-1;for(;++l<t.length;)xC(r,t[l]);return r}function xC(t,r){let l;for(l in r){const s=(Ty.call(t,l)?t[l]:void 0)||(t[l]={}),u=r[l];let c;if(u)for(c in u){Ty.call(s,c)||(s[c]=[]);const d=u[c];bC(s[c],Array.isArray(d)?d:d?[d]:[])}}}function bC(t,r){let l=-1;const i=[];for(;++l<r.length;)(r[l].add==="after"?t:i).push(r[l]);mn(t,0,0,i)}function N0(t,r){const l=Number.parseInt(t,r);return l<9||l===11||l>13&&l<32||l>126&&l<160||l>55295&&l<57344||l>64975&&l<65008||(l&65535)===65535||(l&65535)===65534||l>1114111?"�":String.fromCodePoint(l)}function Dn(t){return t.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const Gt=Fr(/[A-Za-z]/),qt=Fr(/[\dA-Za-z]/),vC=Fr(/[#-'*+\--9=?A-Z^-~]/);function Ss(t){return t!==null&&(t<32||t===127)}const Pf=Fr(/\d/),SC=Fr(/[\dA-Fa-f]/),wC=Fr(/[!-/:-@[-`{-~]/);function Ne(t){return t!==null&&t<-2}function lt(t){return t!==null&&(t<0||t===32)}function He(t){return t===-2||t===-1||t===32}const Ds=Fr(new RegExp("\\p{P}|\\p{S}","u")),ml=Fr(/\s/);function Fr(t){return r;function r(l){return l!==null&&l>-1&&t.test(String.fromCharCode(l))}}function Sa(t){const r=[];let l=-1,i=0,s=0;for(;++l<t.length;){const u=t.charCodeAt(l);let c="";if(u===37&&qt(t.charCodeAt(l+1))&&qt(t.charCodeAt(l+2)))s=2;else if(u<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(u))||(c=String.fromCharCode(u));else if(u>55295&&u<57344){const d=t.charCodeAt(l+1);u<56320&&d>56319&&d<57344?(c=String.fromCharCode(u,d),s=1):c="�"}else c=String.fromCharCode(u);c&&(r.push(t.slice(i,l),encodeURIComponent(c)),i=l+s+1,c=""),s&&(l+=s,s=0)}return r.join("")+t.slice(i)}function Pe(t,r,l,i){const s=i?i-1:Number.POSITIVE_INFINITY;let u=0;return c;function c(p){return He(p)?(t.enter(l),d(p)):r(p)}function d(p){return He(p)&&u++<s?(t.consume(p),d):(t.exit(l),r(p))}}const kC={tokenize:CC};function CC(t){const r=t.attempt(this.parser.constructs.contentInitial,i,s);let l;return r;function i(d){if(d===null){t.consume(d);return}return t.enter("lineEnding"),t.consume(d),t.exit("lineEnding"),Pe(t,r,"linePrefix")}function s(d){return t.enter("paragraph"),u(d)}function u(d){const p=t.enter("chunkText",{contentType:"text",previous:l});return l&&(l.next=p),l=p,c(d)}function c(d){if(d===null){t.exit("chunkText"),t.exit("paragraph"),t.consume(d);return}return Ne(d)?(t.consume(d),t.exit("chunkText"),u):(t.consume(d),c)}}const NC={tokenize:EC},Ay={tokenize:jC};function EC(t){const r=this,l=[];let i=0,s,u,c;return d;function d(z){if(i<l.length){const V=l[i];return r.containerState=V[1],t.attempt(V[0].continuation,p,m)(z)}return m(z)}function p(z){if(i++,r.containerState._closeFlow){r.containerState._closeFlow=void 0,s&&M();const V=r.events.length;let Q=V,B;for(;Q--;)if(r.events[Q][0]==="exit"&&r.events[Q][1].type==="chunkFlow"){B=r.events[Q][1].end;break}j(i);let G=V;for(;G<r.events.length;)r.events[G][1].end={...B},G++;return mn(r.events,Q+1,0,r.events.slice(V)),r.events.length=G,m(z)}return d(z)}function m(z){if(i===l.length){if(!s)return b(z);if(s.currentConstruct&&s.currentConstruct.concrete)return k(z);r.interrupt=!!(s.currentConstruct&&!s._gfmTableDynamicInterruptHack)}return r.containerState={},t.check(Ay,x,y)(z)}function x(z){return s&&M(),j(i),b(z)}function y(z){return r.parser.lazy[r.now().line]=i!==l.length,c=r.now().offset,k(z)}function b(z){return r.containerState={},t.attempt(Ay,S,k)(z)}function S(z){return i++,l.push([r.currentConstruct,r.containerState]),b(z)}function k(z){if(z===null){s&&M(),j(0),t.consume(z);return}return s=s||r.parser.flow(r.now()),t.enter("chunkFlow",{_tokenizer:s,contentType:"flow",previous:u}),N(z)}function N(z){if(z===null){A(t.exit("chunkFlow"),!0),j(0),t.consume(z);return}return Ne(z)?(t.consume(z),A(t.exit("chunkFlow")),i=0,r.interrupt=void 0,d):(t.consume(z),N)}function A(z,V){const Q=r.sliceStream(z);if(V&&Q.push(null),z.previous=u,u&&(u.next=z),u=z,s.defineSkip(z.start),s.write(Q),r.parser.lazy[z.start.line]){let B=s.events.length;for(;B--;)if(s.events[B][1].start.offset<c&&(!s.events[B][1].end||s.events[B][1].end.offset>c))return;const G=r.events.length;let ae=G,se,L;for(;ae--;)if(r.events[ae][0]==="exit"&&r.events[ae][1].type==="chunkFlow"){if(se){L=r.events[ae][1].end;break}se=!0}for(j(i),B=G;B<r.events.length;)r.events[B][1].end={...L},B++;mn(r.events,ae+1,0,r.events.slice(G)),r.events.length=B}}function j(z){let V=l.length;for(;V-- >z;){const Q=l[V];r.containerState=Q[1],Q[0].exit.call(r,t)}l.length=z}function M(){s.write([null]),u=void 0,s=void 0,r.containerState._closeFlow=void 0}}function jC(t,r,l){return Pe(t,t.attempt(this.parser.constructs.document,r,l),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function ya(t){if(t===null||lt(t)||ml(t))return 1;if(Ds(t))return 2}function Rs(t,r,l){const i=[];let s=-1;for(;++s<t.length;){const u=t[s].resolveAll;u&&!i.includes(u)&&(r=u(r,l),i.push(u))}return r}const Xf={name:"attention",resolveAll:TC,tokenize:AC};function TC(t,r){let l=-1,i,s,u,c,d,p,m,x;for(;++l<t.length;)if(t[l][0]==="enter"&&t[l][1].type==="attentionSequence"&&t[l][1]._close){for(i=l;i--;)if(t[i][0]==="exit"&&t[i][1].type==="attentionSequence"&&t[i][1]._open&&r.sliceSerialize(t[i][1]).charCodeAt(0)===r.sliceSerialize(t[l][1]).charCodeAt(0)){if((t[i][1]._close||t[l][1]._open)&&(t[l][1].end.offset-t[l][1].start.offset)%3&&!((t[i][1].end.offset-t[i][1].start.offset+t[l][1].end.offset-t[l][1].start.offset)%3))continue;p=t[i][1].end.offset-t[i][1].start.offset>1&&t[l][1].end.offset-t[l][1].start.offset>1?2:1;const y={...t[i][1].end},b={...t[l][1].start};My(y,-p),My(b,p),c={type:p>1?"strongSequence":"emphasisSequence",start:y,end:{...t[i][1].end}},d={type:p>1?"strongSequence":"emphasisSequence",start:{...t[l][1].start},end:b},u={type:p>1?"strongText":"emphasisText",start:{...t[i][1].end},end:{...t[l][1].start}},s={type:p>1?"strong":"emphasis",start:{...c.start},end:{...d.end}},t[i][1].end={...c.start},t[l][1].start={...d.end},m=[],t[i][1].end.offset-t[i][1].start.offset&&(m=Nn(m,[["enter",t[i][1],r],["exit",t[i][1],r]])),m=Nn(m,[["enter",s,r],["enter",c,r],["exit",c,r],["enter",u,r]]),m=Nn(m,Rs(r.parser.constructs.insideSpan.null,t.slice(i+1,l),r)),m=Nn(m,[["exit",u,r],["enter",d,r],["exit",d,r],["exit",s,r]]),t[l][1].end.offset-t[l][1].start.offset?(x=2,m=Nn(m,[["enter",t[l][1],r],["exit",t[l][1],r]])):x=0,mn(t,i-1,l-i+3,m),l=i+m.length-x-2;break}}for(l=-1;++l<t.length;)t[l][1].type==="attentionSequence"&&(t[l][1].type="data");return t}function AC(t,r){const l=this.parser.constructs.attentionMarkers.null,i=this.previous,s=ya(i);let u;return c;function c(p){return u=p,t.enter("attentionSequence"),d(p)}function d(p){if(p===u)return t.consume(p),d;const m=t.exit("attentionSequence"),x=ya(p),y=!x||x===2&&s||l.includes(p),b=!s||s===2&&x||l.includes(i);return m._open=!!(u===42?y:y&&(s||!b)),m._close=!!(u===42?b:b&&(x||!y)),r(p)}}function My(t,r){t.column+=r,t.offset+=r,t._bufferIndex+=r}const MC={name:"autolink",tokenize:DC};function DC(t,r,l){let i=0;return s;function s(S){return t.enter("autolink"),t.enter("autolinkMarker"),t.consume(S),t.exit("autolinkMarker"),t.enter("autolinkProtocol"),u}function u(S){return Gt(S)?(t.consume(S),c):S===64?l(S):m(S)}function c(S){return S===43||S===45||S===46||qt(S)?(i=1,d(S)):m(S)}function d(S){return S===58?(t.consume(S),i=0,p):(S===43||S===45||S===46||qt(S))&&i++<32?(t.consume(S),d):(i=0,m(S))}function p(S){return S===62?(t.exit("autolinkProtocol"),t.enter("autolinkMarker"),t.consume(S),t.exit("autolinkMarker"),t.exit("autolink"),r):S===null||S===32||S===60||Ss(S)?l(S):(t.consume(S),p)}function m(S){return S===64?(t.consume(S),x):vC(S)?(t.consume(S),m):l(S)}function x(S){return qt(S)?y(S):l(S)}function y(S){return S===46?(t.consume(S),i=0,x):S===62?(t.exit("autolinkProtocol").type="autolinkEmail",t.enter("autolinkMarker"),t.consume(S),t.exit("autolinkMarker"),t.exit("autolink"),r):b(S)}function b(S){if((S===45||qt(S))&&i++<63){const k=S===45?b:y;return t.consume(S),k}return l(S)}}const Li={partial:!0,tokenize:RC};function RC(t,r,l){return i;function i(u){return He(u)?Pe(t,s,"linePrefix")(u):s(u)}function s(u){return u===null||Ne(u)?r(u):l(u)}}const E0={continuation:{tokenize:OC},exit:_C,name:"blockQuote",tokenize:zC};function zC(t,r,l){const i=this;return s;function s(c){if(c===62){const d=i.containerState;return d.open||(t.enter("blockQuote",{_container:!0}),d.open=!0),t.enter("blockQuotePrefix"),t.enter("blockQuoteMarker"),t.consume(c),t.exit("blockQuoteMarker"),u}return l(c)}function u(c){return He(c)?(t.enter("blockQuotePrefixWhitespace"),t.consume(c),t.exit("blockQuotePrefixWhitespace"),t.exit("blockQuotePrefix"),r):(t.exit("blockQuotePrefix"),r(c))}}function OC(t,r,l){const i=this;return s;function s(c){return He(c)?Pe(t,u,"linePrefix",i.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(c):u(c)}function u(c){return t.attempt(E0,r,l)(c)}}function _C(t){t.exit("blockQuote")}const j0={name:"characterEscape",tokenize:LC};function LC(t,r,l){return i;function i(u){return t.enter("characterEscape"),t.enter("escapeMarker"),t.consume(u),t.exit("escapeMarker"),s}function s(u){return wC(u)?(t.enter("characterEscapeValue"),t.consume(u),t.exit("characterEscapeValue"),t.exit("characterEscape"),r):l(u)}}const T0={name:"characterReference",tokenize:UC};function UC(t,r,l){const i=this;let s=0,u,c;return d;function d(y){return t.enter("characterReference"),t.enter("characterReferenceMarker"),t.consume(y),t.exit("characterReferenceMarker"),p}function p(y){return y===35?(t.enter("characterReferenceMarkerNumeric"),t.consume(y),t.exit("characterReferenceMarkerNumeric"),m):(t.enter("characterReferenceValue"),u=31,c=qt,x(y))}function m(y){return y===88||y===120?(t.enter("characterReferenceMarkerHexadecimal"),t.consume(y),t.exit("characterReferenceMarkerHexadecimal"),t.enter("characterReferenceValue"),u=6,c=SC,x):(t.enter("characterReferenceValue"),u=7,c=Pf,x(y))}function x(y){if(y===59&&s){const b=t.exit("characterReferenceValue");return c===qt&&!Rd(i.sliceSerialize(b))?l(y):(t.enter("characterReferenceMarker"),t.consume(y),t.exit("characterReferenceMarker"),t.exit("characterReference"),r)}return c(y)&&s++<u?(t.consume(y),x):l(y)}}const Dy={partial:!0,tokenize:HC},Ry={concrete:!0,name:"codeFenced",tokenize:BC};function BC(t,r,l){const i=this,s={partial:!0,tokenize:Q};let u=0,c=0,d;return p;function p(B){return m(B)}function m(B){const G=i.events[i.events.length-1];return u=G&&G[1].type==="linePrefix"?G[2].sliceSerialize(G[1],!0).length:0,d=B,t.enter("codeFenced"),t.enter("codeFencedFence"),t.enter("codeFencedFenceSequence"),x(B)}function x(B){return B===d?(c++,t.consume(B),x):c<3?l(B):(t.exit("codeFencedFenceSequence"),He(B)?Pe(t,y,"whitespace")(B):y(B))}function y(B){return B===null||Ne(B)?(t.exit("codeFencedFence"),i.interrupt?r(B):t.check(Dy,N,V)(B)):(t.enter("codeFencedFenceInfo"),t.enter("chunkString",{contentType:"string"}),b(B))}function b(B){return B===null||Ne(B)?(t.exit("chunkString"),t.exit("codeFencedFenceInfo"),y(B)):He(B)?(t.exit("chunkString"),t.exit("codeFencedFenceInfo"),Pe(t,S,"whitespace")(B)):B===96&&B===d?l(B):(t.consume(B),b)}function S(B){return B===null||Ne(B)?y(B):(t.enter("codeFencedFenceMeta"),t.enter("chunkString",{contentType:"string"}),k(B))}function k(B){return B===null||Ne(B)?(t.exit("chunkString"),t.exit("codeFencedFenceMeta"),y(B)):B===96&&B===d?l(B):(t.consume(B),k)}function N(B){return t.attempt(s,V,A)(B)}function A(B){return t.enter("lineEnding"),t.consume(B),t.exit("lineEnding"),j}function j(B){return u>0&&He(B)?Pe(t,M,"linePrefix",u+1)(B):M(B)}function M(B){return B===null||Ne(B)?t.check(Dy,N,V)(B):(t.enter("codeFlowValue"),z(B))}function z(B){return B===null||Ne(B)?(t.exit("codeFlowValue"),M(B)):(t.consume(B),z)}function V(B){return t.exit("codeFenced"),r(B)}function Q(B,G,ae){let se=0;return L;function L(J){return B.enter("lineEnding"),B.consume(J),B.exit("lineEnding"),P}function P(J){return B.enter("codeFencedFence"),He(J)?Pe(B,X,"linePrefix",i.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(J):X(J)}function X(J){return J===d?(B.enter("codeFencedFenceSequence"),de(J)):ae(J)}function de(J){return J===d?(se++,B.consume(J),de):se>=c?(B.exit("codeFencedFenceSequence"),He(J)?Pe(B,I,"whitespace")(J):I(J)):ae(J)}function I(J){return J===null||Ne(J)?(B.exit("codeFencedFence"),G(J)):ae(J)}}}function HC(t,r,l){const i=this;return s;function s(c){return c===null?l(c):(t.enter("lineEnding"),t.consume(c),t.exit("lineEnding"),u)}function u(c){return i.parser.lazy[i.now().line]?l(c):r(c)}}const cf={name:"codeIndented",tokenize:IC},qC={partial:!0,tokenize:VC};function IC(t,r,l){const i=this;return s;function s(m){return t.enter("codeIndented"),Pe(t,u,"linePrefix",5)(m)}function u(m){const x=i.events[i.events.length-1];return x&&x[1].type==="linePrefix"&&x[2].sliceSerialize(x[1],!0).length>=4?c(m):l(m)}function c(m){return m===null?p(m):Ne(m)?t.attempt(qC,c,p)(m):(t.enter("codeFlowValue"),d(m))}function d(m){return m===null||Ne(m)?(t.exit("codeFlowValue"),c(m)):(t.consume(m),d)}function p(m){return t.exit("codeIndented"),r(m)}}function VC(t,r,l){const i=this;return s;function s(c){return i.parser.lazy[i.now().line]?l(c):Ne(c)?(t.enter("lineEnding"),t.consume(c),t.exit("lineEnding"),s):Pe(t,u,"linePrefix",5)(c)}function u(c){const d=i.events[i.events.length-1];return d&&d[1].type==="linePrefix"&&d[2].sliceSerialize(d[1],!0).length>=4?r(c):Ne(c)?s(c):l(c)}}const $C={name:"codeText",previous:YC,resolve:FC,tokenize:GC};function FC(t){let r=t.length-4,l=3,i,s;if((t[l][1].type==="lineEnding"||t[l][1].type==="space")&&(t[r][1].type==="lineEnding"||t[r][1].type==="space")){for(i=l;++i<r;)if(t[i][1].type==="codeTextData"){t[l][1].type="codeTextPadding",t[r][1].type="codeTextPadding",l+=2,r-=2;break}}for(i=l-1,r++;++i<=r;)s===void 0?i!==r&&t[i][1].type!=="lineEnding"&&(s=i):(i===r||t[i][1].type==="lineEnding")&&(t[s][1].type="codeTextData",i!==s+2&&(t[s][1].end=t[i-1][1].end,t.splice(s+2,i-s-2),r-=i-s-2,i=s+2),s=void 0);return t}function YC(t){return t!==96||this.events[this.events.length-1][1].type==="characterEscape"}function GC(t,r,l){let i=0,s,u;return c;function c(y){return t.enter("codeText"),t.enter("codeTextSequence"),d(y)}function d(y){return y===96?(t.consume(y),i++,d):(t.exit("codeTextSequence"),p(y))}function p(y){return y===null?l(y):y===32?(t.enter("space"),t.consume(y),t.exit("space"),p):y===96?(u=t.enter("codeTextSequence"),s=0,x(y)):Ne(y)?(t.enter("lineEnding"),t.consume(y),t.exit("lineEnding"),p):(t.enter("codeTextData"),m(y))}function m(y){return y===null||y===32||y===96||Ne(y)?(t.exit("codeTextData"),p(y)):(t.consume(y),m)}function x(y){return y===96?(t.consume(y),s++,x):s===i?(t.exit("codeTextSequence"),t.exit("codeText"),r(y)):(u.type="codeTextData",m(y))}}class PC{constructor(r){this.left=r?[...r]:[],this.right=[]}get(r){if(r<0||r>=this.left.length+this.right.length)throw new RangeError("Cannot access index `"+r+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return r<this.left.length?this.left[r]:this.right[this.right.length-r+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(r,l){const i=l??Number.POSITIVE_INFINITY;return i<this.left.length?this.left.slice(r,i):r>this.left.length?this.right.slice(this.right.length-i+this.left.length,this.right.length-r+this.left.length).reverse():this.left.slice(r).concat(this.right.slice(this.right.length-i+this.left.length).reverse())}splice(r,l,i){const s=l||0;this.setCursor(Math.trunc(r));const u=this.right.splice(this.right.length-s,Number.POSITIVE_INFINITY);return i&&vi(this.left,i),u.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(r){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(r)}pushMany(r){this.setCursor(Number.POSITIVE_INFINITY),vi(this.left,r)}unshift(r){this.setCursor(0),this.right.push(r)}unshiftMany(r){this.setCursor(0),vi(this.right,r.reverse())}setCursor(r){if(!(r===this.left.length||r>this.left.length&&this.right.length===0||r<0&&this.left.length===0))if(r<this.left.length){const l=this.left.splice(r,Number.POSITIVE_INFINITY);vi(this.right,l.reverse())}else{const l=this.right.splice(this.left.length+this.right.length-r,Number.POSITIVE_INFINITY);vi(this.left,l.reverse())}}}function vi(t,r){let l=0;if(r.length<1e4)t.push(...r);else for(;l<r.length;)t.push(...r.slice(l,l+1e4)),l+=1e4}function A0(t){const r={};let l=-1,i,s,u,c,d,p,m;const x=new PC(t);for(;++l<x.length;){for(;l in r;)l=r[l];if(i=x.get(l),l&&i[1].type==="chunkFlow"&&x.get(l-1)[1].type==="listItemPrefix"&&(p=i[1]._tokenizer.events,u=0,u<p.length&&p[u][1].type==="lineEndingBlank"&&(u+=2),u<p.length&&p[u][1].type==="content"))for(;++u<p.length&&p[u][1].type!=="content";)p[u][1].type==="chunkText"&&(p[u][1]._isInFirstContentOfListItem=!0,u++);if(i[0]==="enter")i[1].contentType&&(Object.assign(r,XC(x,l)),l=r[l],m=!0);else if(i[1]._container){for(u=l,s=void 0;u--;)if(c=x.get(u),c[1].type==="lineEnding"||c[1].type==="lineEndingBlank")c[0]==="enter"&&(s&&(x.get(s)[1].type="lineEndingBlank"),c[1].type="lineEnding",s=u);else if(!(c[1].type==="linePrefix"||c[1].type==="listItemIndent"))break;s&&(i[1].end={...x.get(s)[1].start},d=x.slice(s,l),d.unshift(i),x.splice(s,l-s+1,d))}}return mn(t,0,Number.POSITIVE_INFINITY,x.slice(0)),!m}function XC(t,r){const l=t.get(r)[1],i=t.get(r)[2];let s=r-1;const u=[];let c=l._tokenizer;c||(c=i.parser[l.contentType](l.start),l._contentTypeTextTrailing&&(c._contentTypeTextTrailing=!0));const d=c.events,p=[],m={};let x,y,b=-1,S=l,k=0,N=0;const A=[N];for(;S;){for(;t.get(++s)[1]!==S;);u.push(s),S._tokenizer||(x=i.sliceStream(S),S.next||x.push(null),y&&c.defineSkip(S.start),S._isInFirstContentOfListItem&&(c._gfmTasklistFirstContentOfListItem=!0),c.write(x),S._isInFirstContentOfListItem&&(c._gfmTasklistFirstContentOfListItem=void 0)),y=S,S=S.next}for(S=l;++b<d.length;)d[b][0]==="exit"&&d[b-1][0]==="enter"&&d[b][1].type===d[b-1][1].type&&d[b][1].start.line!==d[b][1].end.line&&(N=b+1,A.push(N),S._tokenizer=void 0,S.previous=void 0,S=S.next);for(c.events=[],S?(S._tokenizer=void 0,S.previous=void 0):A.pop(),b=A.length;b--;){const j=d.slice(A[b],A[b+1]),M=u.pop();p.push([M,M+j.length-1]),t.splice(M,2,j)}for(p.reverse(),b=-1;++b<p.length;)m[k+p[b][0]]=k+p[b][1],k+=p[b][1]-p[b][0]-1;return m}const QC={resolve:ZC,tokenize:JC},KC={partial:!0,tokenize:WC};function ZC(t){return A0(t),t}function JC(t,r){let l;return i;function i(d){return t.enter("content"),l=t.enter("chunkContent",{contentType:"content"}),s(d)}function s(d){return d===null?u(d):Ne(d)?t.check(KC,c,u)(d):(t.consume(d),s)}function u(d){return t.exit("chunkContent"),t.exit("content"),r(d)}function c(d){return t.consume(d),t.exit("chunkContent"),l.next=t.enter("chunkContent",{contentType:"content",previous:l}),l=l.next,s}}function WC(t,r,l){const i=this;return s;function s(c){return t.exit("chunkContent"),t.enter("lineEnding"),t.consume(c),t.exit("lineEnding"),Pe(t,u,"linePrefix")}function u(c){if(c===null||Ne(c))return l(c);const d=i.events[i.events.length-1];return!i.parser.constructs.disable.null.includes("codeIndented")&&d&&d[1].type==="linePrefix"&&d[2].sliceSerialize(d[1],!0).length>=4?r(c):t.interrupt(i.parser.constructs.flow,l,r)(c)}}function M0(t,r,l,i,s,u,c,d,p){const m=p||Number.POSITIVE_INFINITY;let x=0;return y;function y(j){return j===60?(t.enter(i),t.enter(s),t.enter(u),t.consume(j),t.exit(u),b):j===null||j===32||j===41||Ss(j)?l(j):(t.enter(i),t.enter(c),t.enter(d),t.enter("chunkString",{contentType:"string"}),N(j))}function b(j){return j===62?(t.enter(u),t.consume(j),t.exit(u),t.exit(s),t.exit(i),r):(t.enter(d),t.enter("chunkString",{contentType:"string"}),S(j))}function S(j){return j===62?(t.exit("chunkString"),t.exit(d),b(j)):j===null||j===60||Ne(j)?l(j):(t.consume(j),j===92?k:S)}function k(j){return j===60||j===62||j===92?(t.consume(j),S):S(j)}function N(j){return!x&&(j===null||j===41||lt(j))?(t.exit("chunkString"),t.exit(d),t.exit(c),t.exit(i),r(j)):x<m&&j===40?(t.consume(j),x++,N):j===41?(t.consume(j),x--,N):j===null||j===32||j===40||Ss(j)?l(j):(t.consume(j),j===92?A:N)}function A(j){return j===40||j===41||j===92?(t.consume(j),N):N(j)}}function D0(t,r,l,i,s,u){const c=this;let d=0,p;return m;function m(S){return t.enter(i),t.enter(s),t.consume(S),t.exit(s),t.enter(u),x}function x(S){return d>999||S===null||S===91||S===93&&!p||S===94&&!d&&"_hiddenFootnoteSupport"in c.parser.constructs?l(S):S===93?(t.exit(u),t.enter(s),t.consume(S),t.exit(s),t.exit(i),r):Ne(S)?(t.enter("lineEnding"),t.consume(S),t.exit("lineEnding"),x):(t.enter("chunkString",{contentType:"string"}),y(S))}function y(S){return S===null||S===91||S===93||Ne(S)||d++>999?(t.exit("chunkString"),x(S)):(t.consume(S),p||(p=!He(S)),S===92?b:y)}function b(S){return S===91||S===92||S===93?(t.consume(S),d++,y):y(S)}}function R0(t,r,l,i,s,u){let c;return d;function d(b){return b===34||b===39||b===40?(t.enter(i),t.enter(s),t.consume(b),t.exit(s),c=b===40?41:b,p):l(b)}function p(b){return b===c?(t.enter(s),t.consume(b),t.exit(s),t.exit(i),r):(t.enter(u),m(b))}function m(b){return b===c?(t.exit(u),p(c)):b===null?l(b):Ne(b)?(t.enter("lineEnding"),t.consume(b),t.exit("lineEnding"),Pe(t,m,"linePrefix")):(t.enter("chunkString",{contentType:"string"}),x(b))}function x(b){return b===c||b===null||Ne(b)?(t.exit("chunkString"),m(b)):(t.consume(b),b===92?y:x)}function y(b){return b===c||b===92?(t.consume(b),x):x(b)}}function Ni(t,r){let l;return i;function i(s){return Ne(s)?(t.enter("lineEnding"),t.consume(s),t.exit("lineEnding"),l=!0,i):He(s)?Pe(t,i,l?"linePrefix":"lineSuffix")(s):r(s)}}const eN={name:"definition",tokenize:nN},tN={partial:!0,tokenize:rN};function nN(t,r,l){const i=this;let s;return u;function u(S){return t.enter("definition"),c(S)}function c(S){return D0.call(i,t,d,l,"definitionLabel","definitionLabelMarker","definitionLabelString")(S)}function d(S){return s=Dn(i.sliceSerialize(i.events[i.events.length-1][1]).slice(1,-1)),S===58?(t.enter("definitionMarker"),t.consume(S),t.exit("definitionMarker"),p):l(S)}function p(S){return lt(S)?Ni(t,m)(S):m(S)}function m(S){return M0(t,x,l,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(S)}function x(S){return t.attempt(tN,y,y)(S)}function y(S){return He(S)?Pe(t,b,"whitespace")(S):b(S)}function b(S){return S===null||Ne(S)?(t.exit("definition"),i.parser.defined.push(s),r(S)):l(S)}}function rN(t,r,l){return i;function i(d){return lt(d)?Ni(t,s)(d):l(d)}function s(d){return R0(t,u,l,"definitionTitle","definitionTitleMarker","definitionTitleString")(d)}function u(d){return He(d)?Pe(t,c,"whitespace")(d):c(d)}function c(d){return d===null||Ne(d)?r(d):l(d)}}const lN={name:"hardBreakEscape",tokenize:aN};function aN(t,r,l){return i;function i(u){return t.enter("hardBreakEscape"),t.consume(u),s}function s(u){return Ne(u)?(t.exit("hardBreakEscape"),r(u)):l(u)}}const iN={name:"headingAtx",resolve:oN,tokenize:sN};function oN(t,r){let l=t.length-2,i=3,s,u;return t[i][1].type==="whitespace"&&(i+=2),l-2>i&&t[l][1].type==="whitespace"&&(l-=2),t[l][1].type==="atxHeadingSequence"&&(i===l-1||l-4>i&&t[l-2][1].type==="whitespace")&&(l-=i+1===l?2:4),l>i&&(s={type:"atxHeadingText",start:t[i][1].start,end:t[l][1].end},u={type:"chunkText",start:t[i][1].start,end:t[l][1].end,contentType:"text"},mn(t,i,l-i+1,[["enter",s,r],["enter",u,r],["exit",u,r],["exit",s,r]])),t}function sN(t,r,l){let i=0;return s;function s(x){return t.enter("atxHeading"),u(x)}function u(x){return t.enter("atxHeadingSequence"),c(x)}function c(x){return x===35&&i++<6?(t.consume(x),c):x===null||lt(x)?(t.exit("atxHeadingSequence"),d(x)):l(x)}function d(x){return x===35?(t.enter("atxHeadingSequence"),p(x)):x===null||Ne(x)?(t.exit("atxHeading"),r(x)):He(x)?Pe(t,d,"whitespace")(x):(t.enter("atxHeadingText"),m(x))}function p(x){return x===35?(t.consume(x),p):(t.exit("atxHeadingSequence"),d(x))}function m(x){return x===null||x===35||lt(x)?(t.exit("atxHeadingText"),d(x)):(t.consume(x),m)}}const uN=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],zy=["pre","script","style","textarea"],cN={concrete:!0,name:"htmlFlow",resolveTo:hN,tokenize:mN},fN={partial:!0,tokenize:gN},dN={partial:!0,tokenize:pN};function hN(t){let r=t.length;for(;r--&&!(t[r][0]==="enter"&&t[r][1].type==="htmlFlow"););return r>1&&t[r-2][1].type==="linePrefix"&&(t[r][1].start=t[r-2][1].start,t[r+1][1].start=t[r-2][1].start,t.splice(r-2,2)),t}function mN(t,r,l){const i=this;let s,u,c,d,p;return m;function m(E){return x(E)}function x(E){return t.enter("htmlFlow"),t.enter("htmlFlowData"),t.consume(E),y}function y(E){return E===33?(t.consume(E),b):E===47?(t.consume(E),u=!0,N):E===63?(t.consume(E),s=3,i.interrupt?r:D):Gt(E)?(t.consume(E),c=String.fromCharCode(E),A):l(E)}function b(E){return E===45?(t.consume(E),s=2,S):E===91?(t.consume(E),s=5,d=0,k):Gt(E)?(t.consume(E),s=4,i.interrupt?r:D):l(E)}function S(E){return E===45?(t.consume(E),i.interrupt?r:D):l(E)}function k(E){const O="CDATA[";return E===O.charCodeAt(d++)?(t.consume(E),d===O.length?i.interrupt?r:X:k):l(E)}function N(E){return Gt(E)?(t.consume(E),c=String.fromCharCode(E),A):l(E)}function A(E){if(E===null||E===47||E===62||lt(E)){const O=E===47,ee=c.toLowerCase();return!O&&!u&&zy.includes(ee)?(s=1,i.interrupt?r(E):X(E)):uN.includes(c.toLowerCase())?(s=6,O?(t.consume(E),j):i.interrupt?r(E):X(E)):(s=7,i.interrupt&&!i.parser.lazy[i.now().line]?l(E):u?M(E):z(E))}return E===45||qt(E)?(t.consume(E),c+=String.fromCharCode(E),A):l(E)}function j(E){return E===62?(t.consume(E),i.interrupt?r:X):l(E)}function M(E){return He(E)?(t.consume(E),M):L(E)}function z(E){return E===47?(t.consume(E),L):E===58||E===95||Gt(E)?(t.consume(E),V):He(E)?(t.consume(E),z):L(E)}function V(E){return E===45||E===46||E===58||E===95||qt(E)?(t.consume(E),V):Q(E)}function Q(E){return E===61?(t.consume(E),B):He(E)?(t.consume(E),Q):z(E)}function B(E){return E===null||E===60||E===61||E===62||E===96?l(E):E===34||E===39?(t.consume(E),p=E,G):He(E)?(t.consume(E),B):ae(E)}function G(E){return E===p?(t.consume(E),p=null,se):E===null||Ne(E)?l(E):(t.consume(E),G)}function ae(E){return E===null||E===34||E===39||E===47||E===60||E===61||E===62||E===96||lt(E)?Q(E):(t.consume(E),ae)}function se(E){return E===47||E===62||He(E)?z(E):l(E)}function L(E){return E===62?(t.consume(E),P):l(E)}function P(E){return E===null||Ne(E)?X(E):He(E)?(t.consume(E),P):l(E)}function X(E){return E===45&&s===2?(t.consume(E),H):E===60&&s===1?(t.consume(E),ne):E===62&&s===4?(t.consume(E),T):E===63&&s===3?(t.consume(E),D):E===93&&s===5?(t.consume(E),ye):Ne(E)&&(s===6||s===7)?(t.exit("htmlFlowData"),t.check(fN,U,de)(E)):E===null||Ne(E)?(t.exit("htmlFlowData"),de(E)):(t.consume(E),X)}function de(E){return t.check(dN,I,U)(E)}function I(E){return t.enter("lineEnding"),t.consume(E),t.exit("lineEnding"),J}function J(E){return E===null||Ne(E)?de(E):(t.enter("htmlFlowData"),X(E))}function H(E){return E===45?(t.consume(E),D):X(E)}function ne(E){return E===47?(t.consume(E),c="",oe):X(E)}function oe(E){if(E===62){const O=c.toLowerCase();return zy.includes(O)?(t.consume(E),T):X(E)}return Gt(E)&&c.length<8?(t.consume(E),c+=String.fromCharCode(E),oe):X(E)}function ye(E){return E===93?(t.consume(E),D):X(E)}function D(E){return E===62?(t.consume(E),T):E===45&&s===2?(t.consume(E),D):X(E)}function T(E){return E===null||Ne(E)?(t.exit("htmlFlowData"),U(E)):(t.consume(E),T)}function U(E){return t.exit("htmlFlow"),r(E)}}function pN(t,r,l){const i=this;return s;function s(c){return Ne(c)?(t.enter("lineEnding"),t.consume(c),t.exit("lineEnding"),u):l(c)}function u(c){return i.parser.lazy[i.now().line]?l(c):r(c)}}function gN(t,r,l){return i;function i(s){return t.enter("lineEnding"),t.consume(s),t.exit("lineEnding"),t.attempt(Li,r,l)}}const yN={name:"htmlText",tokenize:xN};function xN(t,r,l){const i=this;let s,u,c;return d;function d(D){return t.enter("htmlText"),t.enter("htmlTextData"),t.consume(D),p}function p(D){return D===33?(t.consume(D),m):D===47?(t.consume(D),Q):D===63?(t.consume(D),z):Gt(D)?(t.consume(D),ae):l(D)}function m(D){return D===45?(t.consume(D),x):D===91?(t.consume(D),u=0,k):Gt(D)?(t.consume(D),M):l(D)}function x(D){return D===45?(t.consume(D),S):l(D)}function y(D){return D===null?l(D):D===45?(t.consume(D),b):Ne(D)?(c=y,ne(D)):(t.consume(D),y)}function b(D){return D===45?(t.consume(D),S):y(D)}function S(D){return D===62?H(D):D===45?b(D):y(D)}function k(D){const T="CDATA[";return D===T.charCodeAt(u++)?(t.consume(D),u===T.length?N:k):l(D)}function N(D){return D===null?l(D):D===93?(t.consume(D),A):Ne(D)?(c=N,ne(D)):(t.consume(D),N)}function A(D){return D===93?(t.consume(D),j):N(D)}function j(D){return D===62?H(D):D===93?(t.consume(D),j):N(D)}function M(D){return D===null||D===62?H(D):Ne(D)?(c=M,ne(D)):(t.consume(D),M)}function z(D){return D===null?l(D):D===63?(t.consume(D),V):Ne(D)?(c=z,ne(D)):(t.consume(D),z)}function V(D){return D===62?H(D):z(D)}function Q(D){return Gt(D)?(t.consume(D),B):l(D)}function B(D){return D===45||qt(D)?(t.consume(D),B):G(D)}function G(D){return Ne(D)?(c=G,ne(D)):He(D)?(t.consume(D),G):H(D)}function ae(D){return D===45||qt(D)?(t.consume(D),ae):D===47||D===62||lt(D)?se(D):l(D)}function se(D){return D===47?(t.consume(D),H):D===58||D===95||Gt(D)?(t.consume(D),L):Ne(D)?(c=se,ne(D)):He(D)?(t.consume(D),se):H(D)}function L(D){return D===45||D===46||D===58||D===95||qt(D)?(t.consume(D),L):P(D)}function P(D){return D===61?(t.consume(D),X):Ne(D)?(c=P,ne(D)):He(D)?(t.consume(D),P):se(D)}function X(D){return D===null||D===60||D===61||D===62||D===96?l(D):D===34||D===39?(t.consume(D),s=D,de):Ne(D)?(c=X,ne(D)):He(D)?(t.consume(D),X):(t.consume(D),I)}function de(D){return D===s?(t.consume(D),s=void 0,J):D===null?l(D):Ne(D)?(c=de,ne(D)):(t.consume(D),de)}function I(D){return D===null||D===34||D===39||D===60||D===61||D===96?l(D):D===47||D===62||lt(D)?se(D):(t.consume(D),I)}function J(D){return D===47||D===62||lt(D)?se(D):l(D)}function H(D){return D===62?(t.consume(D),t.exit("htmlTextData"),t.exit("htmlText"),r):l(D)}function ne(D){return t.exit("htmlTextData"),t.enter("lineEnding"),t.consume(D),t.exit("lineEnding"),oe}function oe(D){return He(D)?Pe(t,ye,"linePrefix",i.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(D):ye(D)}function ye(D){return t.enter("htmlTextData"),c(D)}}const zd={name:"labelEnd",resolveAll:wN,resolveTo:kN,tokenize:CN},bN={tokenize:NN},vN={tokenize:EN},SN={tokenize:jN};function wN(t){let r=-1;const l=[];for(;++r<t.length;){const i=t[r][1];if(l.push(t[r]),i.type==="labelImage"||i.type==="labelLink"||i.type==="labelEnd"){const s=i.type==="labelImage"?4:2;i.type="data",r+=s}}return t.length!==l.length&&mn(t,0,t.length,l),t}function kN(t,r){let l=t.length,i=0,s,u,c,d;for(;l--;)if(s=t[l][1],u){if(s.type==="link"||s.type==="labelLink"&&s._inactive)break;t[l][0]==="enter"&&s.type==="labelLink"&&(s._inactive=!0)}else if(c){if(t[l][0]==="enter"&&(s.type==="labelImage"||s.type==="labelLink")&&!s._balanced&&(u=l,s.type!=="labelLink")){i=2;break}}else s.type==="labelEnd"&&(c=l);const p={type:t[u][1].type==="labelLink"?"link":"image",start:{...t[u][1].start},end:{...t[t.length-1][1].end}},m={type:"label",start:{...t[u][1].start},end:{...t[c][1].end}},x={type:"labelText",start:{...t[u+i+2][1].end},end:{...t[c-2][1].start}};return d=[["enter",p,r],["enter",m,r]],d=Nn(d,t.slice(u+1,u+i+3)),d=Nn(d,[["enter",x,r]]),d=Nn(d,Rs(r.parser.constructs.insideSpan.null,t.slice(u+i+4,c-3),r)),d=Nn(d,[["exit",x,r],t[c-2],t[c-1],["exit",m,r]]),d=Nn(d,t.slice(c+1)),d=Nn(d,[["exit",p,r]]),mn(t,u,t.length,d),t}function CN(t,r,l){const i=this;let s=i.events.length,u,c;for(;s--;)if((i.events[s][1].type==="labelImage"||i.events[s][1].type==="labelLink")&&!i.events[s][1]._balanced){u=i.events[s][1];break}return d;function d(b){return u?u._inactive?y(b):(c=i.parser.defined.includes(Dn(i.sliceSerialize({start:u.end,end:i.now()}))),t.enter("labelEnd"),t.enter("labelMarker"),t.consume(b),t.exit("labelMarker"),t.exit("labelEnd"),p):l(b)}function p(b){return b===40?t.attempt(bN,x,c?x:y)(b):b===91?t.attempt(vN,x,c?m:y)(b):c?x(b):y(b)}function m(b){return t.attempt(SN,x,y)(b)}function x(b){return r(b)}function y(b){return u._balanced=!0,l(b)}}function NN(t,r,l){return i;function i(y){return t.enter("resource"),t.enter("resourceMarker"),t.consume(y),t.exit("resourceMarker"),s}function s(y){return lt(y)?Ni(t,u)(y):u(y)}function u(y){return y===41?x(y):M0(t,c,d,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(y)}function c(y){return lt(y)?Ni(t,p)(y):x(y)}function d(y){return l(y)}function p(y){return y===34||y===39||y===40?R0(t,m,l,"resourceTitle","resourceTitleMarker","resourceTitleString")(y):x(y)}function m(y){return lt(y)?Ni(t,x)(y):x(y)}function x(y){return y===41?(t.enter("resourceMarker"),t.consume(y),t.exit("resourceMarker"),t.exit("resource"),r):l(y)}}function EN(t,r,l){const i=this;return s;function s(d){return D0.call(i,t,u,c,"reference","referenceMarker","referenceString")(d)}function u(d){return i.parser.defined.includes(Dn(i.sliceSerialize(i.events[i.events.length-1][1]).slice(1,-1)))?r(d):l(d)}function c(d){return l(d)}}function jN(t,r,l){return i;function i(u){return t.enter("reference"),t.enter("referenceMarker"),t.consume(u),t.exit("referenceMarker"),s}function s(u){return u===93?(t.enter("referenceMarker"),t.consume(u),t.exit("referenceMarker"),t.exit("reference"),r):l(u)}}const TN={name:"labelStartImage",resolveAll:zd.resolveAll,tokenize:AN};function AN(t,r,l){const i=this;return s;function s(d){return t.enter("labelImage"),t.enter("labelImageMarker"),t.consume(d),t.exit("labelImageMarker"),u}function u(d){return d===91?(t.enter("labelMarker"),t.consume(d),t.exit("labelMarker"),t.exit("labelImage"),c):l(d)}function c(d){return d===94&&"_hiddenFootnoteSupport"in i.parser.constructs?l(d):r(d)}}const MN={name:"labelStartLink",resolveAll:zd.resolveAll,tokenize:DN};function DN(t,r,l){const i=this;return s;function s(c){return t.enter("labelLink"),t.enter("labelMarker"),t.consume(c),t.exit("labelMarker"),t.exit("labelLink"),u}function u(c){return c===94&&"_hiddenFootnoteSupport"in i.parser.constructs?l(c):r(c)}}const ff={name:"lineEnding",tokenize:RN};function RN(t,r){return l;function l(i){return t.enter("lineEnding"),t.consume(i),t.exit("lineEnding"),Pe(t,r,"linePrefix")}}const ms={name:"thematicBreak",tokenize:zN};function zN(t,r,l){let i=0,s;return u;function u(m){return t.enter("thematicBreak"),c(m)}function c(m){return s=m,d(m)}function d(m){return m===s?(t.enter("thematicBreakSequence"),p(m)):i>=3&&(m===null||Ne(m))?(t.exit("thematicBreak"),r(m)):l(m)}function p(m){return m===s?(t.consume(m),i++,p):(t.exit("thematicBreakSequence"),He(m)?Pe(t,d,"whitespace")(m):d(m))}}const tn={continuation:{tokenize:UN},exit:HN,name:"list",tokenize:LN},ON={partial:!0,tokenize:qN},_N={partial:!0,tokenize:BN};function LN(t,r,l){const i=this,s=i.events[i.events.length-1];let u=s&&s[1].type==="linePrefix"?s[2].sliceSerialize(s[1],!0).length:0,c=0;return d;function d(S){const k=i.containerState.type||(S===42||S===43||S===45?"listUnordered":"listOrdered");if(k==="listUnordered"?!i.containerState.marker||S===i.containerState.marker:Pf(S)){if(i.containerState.type||(i.containerState.type=k,t.enter(k,{_container:!0})),k==="listUnordered")return t.enter("listItemPrefix"),S===42||S===45?t.check(ms,l,m)(S):m(S);if(!i.interrupt||S===49)return t.enter("listItemPrefix"),t.enter("listItemValue"),p(S)}return l(S)}function p(S){return Pf(S)&&++c<10?(t.consume(S),p):(!i.interrupt||c<2)&&(i.containerState.marker?S===i.containerState.marker:S===41||S===46)?(t.exit("listItemValue"),m(S)):l(S)}function m(S){return t.enter("listItemMarker"),t.consume(S),t.exit("listItemMarker"),i.containerState.marker=i.containerState.marker||S,t.check(Li,i.interrupt?l:x,t.attempt(ON,b,y))}function x(S){return i.containerState.initialBlankLine=!0,u++,b(S)}function y(S){return He(S)?(t.enter("listItemPrefixWhitespace"),t.consume(S),t.exit("listItemPrefixWhitespace"),b):l(S)}function b(S){return i.containerState.size=u+i.sliceSerialize(t.exit("listItemPrefix"),!0).length,r(S)}}function UN(t,r,l){const i=this;return i.containerState._closeFlow=void 0,t.check(Li,s,u);function s(d){return i.containerState.furtherBlankLines=i.containerState.furtherBlankLines||i.containerState.initialBlankLine,Pe(t,r,"listItemIndent",i.containerState.size+1)(d)}function u(d){return i.containerState.furtherBlankLines||!He(d)?(i.containerState.furtherBlankLines=void 0,i.containerState.initialBlankLine=void 0,c(d)):(i.containerState.furtherBlankLines=void 0,i.containerState.initialBlankLine=void 0,t.attempt(_N,r,c)(d))}function c(d){return i.containerState._closeFlow=!0,i.interrupt=void 0,Pe(t,t.attempt(tn,r,l),"linePrefix",i.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(d)}}function BN(t,r,l){const i=this;return Pe(t,s,"listItemIndent",i.containerState.size+1);function s(u){const c=i.events[i.events.length-1];return c&&c[1].type==="listItemIndent"&&c[2].sliceSerialize(c[1],!0).length===i.containerState.size?r(u):l(u)}}function HN(t){t.exit(this.containerState.type)}function qN(t,r,l){const i=this;return Pe(t,s,"listItemPrefixWhitespace",i.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function s(u){const c=i.events[i.events.length-1];return!He(u)&&c&&c[1].type==="listItemPrefixWhitespace"?r(u):l(u)}}const Oy={name:"setextUnderline",resolveTo:IN,tokenize:VN};function IN(t,r){let l=t.length,i,s,u;for(;l--;)if(t[l][0]==="enter"){if(t[l][1].type==="content"){i=l;break}t[l][1].type==="paragraph"&&(s=l)}else t[l][1].type==="content"&&t.splice(l,1),!u&&t[l][1].type==="definition"&&(u=l);const c={type:"setextHeading",start:{...t[i][1].start},end:{...t[t.length-1][1].end}};return t[s][1].type="setextHeadingText",u?(t.splice(s,0,["enter",c,r]),t.splice(u+1,0,["exit",t[i][1],r]),t[i][1].end={...t[u][1].end}):t[i][1]=c,t.push(["exit",c,r]),t}function VN(t,r,l){const i=this;let s;return u;function u(m){let x=i.events.length,y;for(;x--;)if(i.events[x][1].type!=="lineEnding"&&i.events[x][1].type!=="linePrefix"&&i.events[x][1].type!=="content"){y=i.events[x][1].type==="paragraph";break}return!i.parser.lazy[i.now().line]&&(i.interrupt||y)?(t.enter("setextHeadingLine"),s=m,c(m)):l(m)}function c(m){return t.enter("setextHeadingLineSequence"),d(m)}function d(m){return m===s?(t.consume(m),d):(t.exit("setextHeadingLineSequence"),He(m)?Pe(t,p,"lineSuffix")(m):p(m))}function p(m){return m===null||Ne(m)?(t.exit("setextHeadingLine"),r(m)):l(m)}}const $N={tokenize:FN};function FN(t){const r=this,l=t.attempt(Li,i,t.attempt(this.parser.constructs.flowInitial,s,Pe(t,t.attempt(this.parser.constructs.flow,s,t.attempt(QC,s)),"linePrefix")));return l;function i(u){if(u===null){t.consume(u);return}return t.enter("lineEndingBlank"),t.consume(u),t.exit("lineEndingBlank"),r.currentConstruct=void 0,l}function s(u){if(u===null){t.consume(u);return}return t.enter("lineEnding"),t.consume(u),t.exit("lineEnding"),r.currentConstruct=void 0,l}}const YN={resolveAll:O0()},GN=z0("string"),PN=z0("text");function z0(t){return{resolveAll:O0(t==="text"?XN:void 0),tokenize:r};function r(l){const i=this,s=this.parser.constructs[t],u=l.attempt(s,c,d);return c;function c(x){return m(x)?u(x):d(x)}function d(x){if(x===null){l.consume(x);return}return l.enter("data"),l.consume(x),p}function p(x){return m(x)?(l.exit("data"),u(x)):(l.consume(x),p)}function m(x){if(x===null)return!0;const y=s[x];let b=-1;if(y)for(;++b<y.length;){const S=y[b];if(!S.previous||S.previous.call(i,i.previous))return!0}return!1}}}function O0(t){return r;function r(l,i){let s=-1,u;for(;++s<=l.length;)u===void 0?l[s]&&l[s][1].type==="data"&&(u=s,s++):(!l[s]||l[s][1].type!=="data")&&(s!==u+2&&(l[u][1].end=l[s-1][1].end,l.splice(u+2,s-u-2),s=u+2),u=void 0);return t?t(l,i):l}}function XN(t,r){let l=0;for(;++l<=t.length;)if((l===t.length||t[l][1].type==="lineEnding")&&t[l-1][1].type==="data"){const i=t[l-1][1],s=r.sliceStream(i);let u=s.length,c=-1,d=0,p;for(;u--;){const m=s[u];if(typeof m=="string"){for(c=m.length;m.charCodeAt(c-1)===32;)d++,c--;if(c)break;c=-1}else if(m===-2)p=!0,d++;else if(m!==-1){u++;break}}if(r._contentTypeTextTrailing&&l===t.length&&(d=0),d){const m={type:l===t.length||p||d<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:u?c:i.start._bufferIndex+c,_index:i.start._index+u,line:i.end.line,column:i.end.column-d,offset:i.end.offset-d},end:{...i.end}};i.end={...m.start},i.start.offset===i.end.offset?Object.assign(i,m):(t.splice(l,0,["enter",m,r],["exit",m,r]),l+=2)}l++}return t}const QN={42:tn,43:tn,45:tn,48:tn,49:tn,50:tn,51:tn,52:tn,53:tn,54:tn,55:tn,56:tn,57:tn,62:E0},KN={91:eN},ZN={[-2]:cf,[-1]:cf,32:cf},JN={35:iN,42:ms,45:[Oy,ms],60:cN,61:Oy,95:ms,96:Ry,126:Ry},WN={38:T0,92:j0},eE={[-5]:ff,[-4]:ff,[-3]:ff,33:TN,38:T0,42:Xf,60:[MC,yN],91:MN,92:[lN,j0],93:zd,95:Xf,96:$C},tE={null:[Xf,YN]},nE={null:[42,95]},rE={null:[]},lE=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:nE,contentInitial:KN,disable:rE,document:QN,flow:JN,flowInitial:ZN,insideSpan:tE,string:WN,text:eE},Symbol.toStringTag,{value:"Module"}));function aE(t,r,l){let i={_bufferIndex:-1,_index:0,line:l&&l.line||1,column:l&&l.column||1,offset:l&&l.offset||0};const s={},u=[];let c=[],d=[];const p={attempt:G(Q),check:G(B),consume:M,enter:z,exit:V,interrupt:G(B,{interrupt:!0})},m={code:null,containerState:{},defineSkip:N,events:[],now:k,parser:t,previous:null,sliceSerialize:b,sliceStream:S,write:y};let x=r.tokenize.call(m,p);return r.resolveAll&&u.push(r),m;function y(P){return c=Nn(c,P),A(),c[c.length-1]!==null?[]:(ae(r,0),m.events=Rs(u,m.events,m),m.events)}function b(P,X){return oE(S(P),X)}function S(P){return iE(c,P)}function k(){const{_bufferIndex:P,_index:X,line:de,column:I,offset:J}=i;return{_bufferIndex:P,_index:X,line:de,column:I,offset:J}}function N(P){s[P.line]=P.column,L()}function A(){let P;for(;i._index<c.length;){const X=c[i._index];if(typeof X=="string")for(P=i._index,i._bufferIndex<0&&(i._bufferIndex=0);i._index===P&&i._bufferIndex<X.length;)j(X.charCodeAt(i._bufferIndex));else j(X)}}function j(P){x=x(P)}function M(P){Ne(P)?(i.line++,i.column=1,i.offset+=P===-3?2:1,L()):P!==-1&&(i.column++,i.offset++),i._bufferIndex<0?i._index++:(i._bufferIndex++,i._bufferIndex===c[i._index].length&&(i._bufferIndex=-1,i._index++)),m.previous=P}function z(P,X){const de=X||{};return de.type=P,de.start=k(),m.events.push(["enter",de,m]),d.push(de),de}function V(P){const X=d.pop();return X.end=k(),m.events.push(["exit",X,m]),X}function Q(P,X){ae(P,X.from)}function B(P,X){X.restore()}function G(P,X){return de;function de(I,J,H){let ne,oe,ye,D;return Array.isArray(I)?U(I):"tokenize"in I?U([I]):T(I);function T(re){return W;function W(be){const we=be!==null&&re[be],Ae=be!==null&&re.null,dt=[...Array.isArray(we)?we:we?[we]:[],...Array.isArray(Ae)?Ae:Ae?[Ae]:[]];return U(dt)(be)}}function U(re){return ne=re,oe=0,re.length===0?H:E(re[oe])}function E(re){return W;function W(be){return D=se(),ye=re,re.partial||(m.currentConstruct=re),re.name&&m.parser.constructs.disable.null.includes(re.name)?ee():re.tokenize.call(X?Object.assign(Object.create(m),X):m,p,O,ee)(be)}}function O(re){return P(ye,D),J}function ee(re){return D.restore(),++oe<ne.length?E(ne[oe]):H}}}function ae(P,X){P.resolveAll&&!u.includes(P)&&u.push(P),P.resolve&&mn(m.events,X,m.events.length-X,P.resolve(m.events.slice(X),m)),P.resolveTo&&(m.events=P.resolveTo(m.events,m))}function se(){const P=k(),X=m.previous,de=m.currentConstruct,I=m.events.length,J=Array.from(d);return{from:I,restore:H};function H(){i=P,m.previous=X,m.currentConstruct=de,m.events.length=I,d=J,L()}}function L(){i.line in s&&i.column<2&&(i.column=s[i.line],i.offset+=s[i.line]-1)}}function iE(t,r){const l=r.start._index,i=r.start._bufferIndex,s=r.end._index,u=r.end._bufferIndex;let c;if(l===s)c=[t[l].slice(i,u)];else{if(c=t.slice(l,s),i>-1){const d=c[0];typeof d=="string"?c[0]=d.slice(i):c.shift()}u>0&&c.push(t[s].slice(0,u))}return c}function oE(t,r){let l=-1;const i=[];let s;for(;++l<t.length;){const u=t[l];let c;if(typeof u=="string")c=u;else switch(u){case-5:{c="\r";break}case-4:{c=`
|
|
516
|
-
`;break}case-3:{c=`\r
|
|
517
|
-
`;break}case-2:{c=r?" ":" ";break}case-1:{if(!r&&s)continue;c=" ";break}default:c=String.fromCharCode(u)}s=u===-2,i.push(c)}return i.join("")}function sE(t){const i={constructs:C0([lE,...(t||{}).extensions||[]]),content:s(kC),defined:[],document:s(NC),flow:s($N),lazy:{},string:s(GN),text:s(PN)};return i;function s(u){return c;function c(d){return aE(i,u,d)}}}function uE(t){for(;!A0(t););return t}const _y=/[\0\t\n\r]/g;function cE(){let t=1,r="",l=!0,i;return s;function s(u,c,d){const p=[];let m,x,y,b,S;for(u=r+(typeof u=="string"?u.toString():new TextDecoder(c||void 0).decode(u)),y=0,r="",l&&(u.charCodeAt(0)===65279&&y++,l=void 0);y<u.length;){if(_y.lastIndex=y,m=_y.exec(u),b=m&&m.index!==void 0?m.index:u.length,S=u.charCodeAt(b),!m){r=u.slice(y);break}if(S===10&&y===b&&i)p.push(-3),i=void 0;else switch(i&&(p.push(-5),i=void 0),y<b&&(p.push(u.slice(y,b)),t+=b-y),S){case 0:{p.push(65533),t++;break}case 9:{for(x=Math.ceil(t/4)*4,p.push(-2);t++<x;)p.push(-1);break}case 10:{p.push(-4),t=1;break}default:i=!0,t=1}y=b+1}return d&&(i&&p.push(-5),r&&p.push(r),p.push(null)),p}}const fE=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function dE(t){return t.replace(fE,hE)}function hE(t,r,l){if(r)return r;if(l.charCodeAt(0)===35){const s=l.charCodeAt(1),u=s===120||s===88;return N0(l.slice(u?2:1),u?16:10)}return Rd(l)||t}const _0={}.hasOwnProperty;function mE(t,r,l){return r&&typeof r=="object"&&(l=r,r=void 0),pE(l)(uE(sE(l).document().write(cE()(t,r,!0))))}function pE(t){const r={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:u(mt),autolinkProtocol:se,autolinkEmail:se,atxHeading:u(De),blockQuote:u(Ae),characterEscape:se,characterReference:se,codeFenced:u(dt),codeFencedFenceInfo:c,codeFencedFenceMeta:c,codeIndented:u(dt,c),codeText:u(st,c),codeTextData:se,data:se,codeFlowValue:se,definition:u(Te),definitionDestinationString:c,definitionLabelString:c,definitionTitleString:c,emphasis:u(xe),hardBreakEscape:u(at),hardBreakTrailing:u(at),htmlFlow:u(ht,c),htmlFlowData:se,htmlText:u(ht,c),htmlTextData:se,image:u($t),label:c,link:u(mt),listItem:u(cr),listItemValue:b,listOrdered:u(Ft,y),listUnordered:u(Ft),paragraph:u(wa),reference:E,referenceString:c,resourceDestinationString:c,resourceTitleString:c,setextHeading:u(De),strong:u(xl),thematicBreak:u(je)},exit:{atxHeading:p(),atxHeadingSequence:Q,autolink:p(),autolinkEmail:we,autolinkProtocol:be,blockQuote:p(),characterEscapeValue:L,characterReferenceMarkerHexadecimal:ee,characterReferenceMarkerNumeric:ee,characterReferenceValue:re,characterReference:W,codeFenced:p(A),codeFencedFence:N,codeFencedFenceInfo:S,codeFencedFenceMeta:k,codeFlowValue:L,codeIndented:p(j),codeText:p(J),codeTextData:L,data:L,definition:p(),definitionDestinationString:V,definitionLabelString:M,definitionTitleString:z,emphasis:p(),hardBreakEscape:p(X),hardBreakTrailing:p(X),htmlFlow:p(de),htmlFlowData:L,htmlText:p(I),htmlTextData:L,image:p(ne),label:ye,labelText:oe,lineEnding:P,link:p(H),listItem:p(),listOrdered:p(),listUnordered:p(),paragraph:p(),referenceString:O,resourceDestinationString:D,resourceTitleString:T,resource:U,setextHeading:p(ae),setextHeadingLineSequence:G,setextHeadingText:B,strong:p(),thematicBreak:p()}};L0(r,(t||{}).mdastExtensions||[]);const l={};return i;function i(K){let fe={type:"root",children:[]};const ke={stack:[fe],tokenStack:[],config:r,enter:d,exit:m,buffer:c,resume:x,data:l},ze=[];let Fe=-1;for(;++Fe<K.length;)if(K[Fe][1].type==="listOrdered"||K[Fe][1].type==="listUnordered")if(K[Fe][0]==="enter")ze.push(Fe);else{const zt=ze.pop();Fe=s(K,zt,Fe)}for(Fe=-1;++Fe<K.length;){const zt=r[K[Fe][0]];_0.call(zt,K[Fe][1].type)&&zt[K[Fe][1].type].call(Object.assign({sliceSerialize:K[Fe][2].sliceSerialize},ke),K[Fe][1])}if(ke.tokenStack.length>0){const zt=ke.tokenStack[ke.tokenStack.length-1];(zt[1]||Ly).call(ke,void 0,zt[0])}for(fe.position={start:Br(K.length>0?K[0][1].start:{line:1,column:1,offset:0}),end:Br(K.length>0?K[K.length-2][1].end:{line:1,column:1,offset:0})},Fe=-1;++Fe<r.transforms.length;)fe=r.transforms[Fe](fe)||fe;return fe}function s(K,fe,ke){let ze=fe-1,Fe=-1,zt=!1,vt,yt,it,Mt;for(;++ze<=ke;){const Ze=K[ze];switch(Ze[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{Ze[0]==="enter"?Fe++:Fe--,Mt=void 0;break}case"lineEndingBlank":{Ze[0]==="enter"&&(vt&&!Mt&&!Fe&&!it&&(it=ze),Mt=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Mt=void 0}if(!Fe&&Ze[0]==="enter"&&Ze[1].type==="listItemPrefix"||Fe===-1&&Ze[0]==="exit"&&(Ze[1].type==="listUnordered"||Ze[1].type==="listOrdered")){if(vt){let fr=ze;for(yt=void 0;fr--;){const jn=K[fr];if(jn[1].type==="lineEnding"||jn[1].type==="lineEndingBlank"){if(jn[0]==="exit")continue;yt&&(K[yt][1].type="lineEndingBlank",zt=!0),jn[1].type="lineEnding",yt=fr}else if(!(jn[1].type==="linePrefix"||jn[1].type==="blockQuotePrefix"||jn[1].type==="blockQuotePrefixWhitespace"||jn[1].type==="blockQuoteMarker"||jn[1].type==="listItemIndent"))break}it&&(!yt||it<yt)&&(vt._spread=!0),vt.end=Object.assign({},yt?K[yt][1].start:Ze[1].end),K.splice(yt||ze,0,["exit",vt,Ze[2]]),ze++,ke++}if(Ze[1].type==="listItemPrefix"){const fr={type:"listItem",_spread:!1,start:Object.assign({},Ze[1].start),end:void 0};vt=fr,K.splice(ze,0,["enter",fr,Ze[2]]),ze++,ke++,it=void 0,Mt=!0}}}return K[fe][1]._spread=zt,ke}function u(K,fe){return ke;function ke(ze){d.call(this,K(ze),ze),fe&&fe.call(this,ze)}}function c(){this.stack.push({type:"fragment",children:[]})}function d(K,fe,ke){this.stack[this.stack.length-1].children.push(K),this.stack.push(K),this.tokenStack.push([fe,ke||void 0]),K.position={start:Br(fe.start),end:void 0}}function p(K){return fe;function fe(ke){K&&K.call(this,ke),m.call(this,ke)}}function m(K,fe){const ke=this.stack.pop(),ze=this.tokenStack.pop();if(ze)ze[0].type!==K.type&&(fe?fe.call(this,K,ze[0]):(ze[1]||Ly).call(this,K,ze[0]));else throw new Error("Cannot close `"+K.type+"` ("+Ci({start:K.start,end:K.end})+"): it’s not open");ke.position.end=Br(K.end)}function x(){return Dd(this.stack.pop())}function y(){this.data.expectingFirstListItemValue=!0}function b(K){if(this.data.expectingFirstListItemValue){const fe=this.stack[this.stack.length-2];fe.start=Number.parseInt(this.sliceSerialize(K),10),this.data.expectingFirstListItemValue=void 0}}function S(){const K=this.resume(),fe=this.stack[this.stack.length-1];fe.lang=K}function k(){const K=this.resume(),fe=this.stack[this.stack.length-1];fe.meta=K}function N(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function A(){const K=this.resume(),fe=this.stack[this.stack.length-1];fe.value=K.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function j(){const K=this.resume(),fe=this.stack[this.stack.length-1];fe.value=K.replace(/(\r?\n|\r)$/g,"")}function M(K){const fe=this.resume(),ke=this.stack[this.stack.length-1];ke.label=fe,ke.identifier=Dn(this.sliceSerialize(K)).toLowerCase()}function z(){const K=this.resume(),fe=this.stack[this.stack.length-1];fe.title=K}function V(){const K=this.resume(),fe=this.stack[this.stack.length-1];fe.url=K}function Q(K){const fe=this.stack[this.stack.length-1];if(!fe.depth){const ke=this.sliceSerialize(K).length;fe.depth=ke}}function B(){this.data.setextHeadingSlurpLineEnding=!0}function G(K){const fe=this.stack[this.stack.length-1];fe.depth=this.sliceSerialize(K).codePointAt(0)===61?1:2}function ae(){this.data.setextHeadingSlurpLineEnding=void 0}function se(K){const ke=this.stack[this.stack.length-1].children;let ze=ke[ke.length-1];(!ze||ze.type!=="text")&&(ze=ue(),ze.position={start:Br(K.start),end:void 0},ke.push(ze)),this.stack.push(ze)}function L(K){const fe=this.stack.pop();fe.value+=this.sliceSerialize(K),fe.position.end=Br(K.end)}function P(K){const fe=this.stack[this.stack.length-1];if(this.data.atHardBreak){const ke=fe.children[fe.children.length-1];ke.position.end=Br(K.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&r.canContainEols.includes(fe.type)&&(se.call(this,K),L.call(this,K))}function X(){this.data.atHardBreak=!0}function de(){const K=this.resume(),fe=this.stack[this.stack.length-1];fe.value=K}function I(){const K=this.resume(),fe=this.stack[this.stack.length-1];fe.value=K}function J(){const K=this.resume(),fe=this.stack[this.stack.length-1];fe.value=K}function H(){const K=this.stack[this.stack.length-1];if(this.data.inReference){const fe=this.data.referenceType||"shortcut";K.type+="Reference",K.referenceType=fe,delete K.url,delete K.title}else delete K.identifier,delete K.label;this.data.referenceType=void 0}function ne(){const K=this.stack[this.stack.length-1];if(this.data.inReference){const fe=this.data.referenceType||"shortcut";K.type+="Reference",K.referenceType=fe,delete K.url,delete K.title}else delete K.identifier,delete K.label;this.data.referenceType=void 0}function oe(K){const fe=this.sliceSerialize(K),ke=this.stack[this.stack.length-2];ke.label=dE(fe),ke.identifier=Dn(fe).toLowerCase()}function ye(){const K=this.stack[this.stack.length-1],fe=this.resume(),ke=this.stack[this.stack.length-1];if(this.data.inReference=!0,ke.type==="link"){const ze=K.children;ke.children=ze}else ke.alt=fe}function D(){const K=this.resume(),fe=this.stack[this.stack.length-1];fe.url=K}function T(){const K=this.resume(),fe=this.stack[this.stack.length-1];fe.title=K}function U(){this.data.inReference=void 0}function E(){this.data.referenceType="collapsed"}function O(K){const fe=this.resume(),ke=this.stack[this.stack.length-1];ke.label=fe,ke.identifier=Dn(this.sliceSerialize(K)).toLowerCase(),this.data.referenceType="full"}function ee(K){this.data.characterReferenceType=K.type}function re(K){const fe=this.sliceSerialize(K),ke=this.data.characterReferenceType;let ze;ke?(ze=N0(fe,ke==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):ze=Rd(fe);const Fe=this.stack[this.stack.length-1];Fe.value+=ze}function W(K){const fe=this.stack.pop();fe.position.end=Br(K.end)}function be(K){L.call(this,K);const fe=this.stack[this.stack.length-1];fe.url=this.sliceSerialize(K)}function we(K){L.call(this,K);const fe=this.stack[this.stack.length-1];fe.url="mailto:"+this.sliceSerialize(K)}function Ae(){return{type:"blockquote",children:[]}}function dt(){return{type:"code",lang:null,meta:null,value:""}}function st(){return{type:"inlineCode",value:""}}function Te(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function xe(){return{type:"emphasis",children:[]}}function De(){return{type:"heading",depth:0,children:[]}}function at(){return{type:"break"}}function ht(){return{type:"html",value:""}}function $t(){return{type:"image",title:null,url:"",alt:null}}function mt(){return{type:"link",title:null,url:"",children:[]}}function Ft(K){return{type:"list",ordered:K.type==="listOrdered",start:null,spread:K._spread,children:[]}}function cr(K){return{type:"listItem",spread:K._spread,checked:null,children:[]}}function wa(){return{type:"paragraph",children:[]}}function xl(){return{type:"strong",children:[]}}function ue(){return{type:"text",value:""}}function je(){return{type:"thematicBreak"}}}function Br(t){return{line:t.line,column:t.column,offset:t.offset}}function L0(t,r){let l=-1;for(;++l<r.length;){const i=r[l];Array.isArray(i)?L0(t,i):gE(t,i)}}function gE(t,r){let l;for(l in r)if(_0.call(r,l))switch(l){case"canContainEols":{const i=r[l];i&&t[l].push(...i);break}case"transforms":{const i=r[l];i&&t[l].push(...i);break}case"enter":case"exit":{const i=r[l];i&&Object.assign(t[l],i);break}}}function Ly(t,r){throw t?new Error("Cannot close `"+t.type+"` ("+Ci({start:t.start,end:t.end})+"): a different token (`"+r.type+"`, "+Ci({start:r.start,end:r.end})+") is open"):new Error("Cannot close document, a token (`"+r.type+"`, "+Ci({start:r.start,end:r.end})+") is still open")}function yE(t){const r=this;r.parser=l;function l(i){return mE(i,{...r.data("settings"),...t,extensions:r.data("micromarkExtensions")||[],mdastExtensions:r.data("fromMarkdownExtensions")||[]})}}function xE(t,r){const l={type:"element",tagName:"blockquote",properties:{},children:t.wrap(t.all(r),!0)};return t.patch(r,l),t.applyData(r,l)}function bE(t,r){const l={type:"element",tagName:"br",properties:{},children:[]};return t.patch(r,l),[t.applyData(r,l),{type:"text",value:`
|
|
518
|
-
`}]}function vE(t,r){const l=r.value?r.value+`
|
|
519
|
-
`:"",i={},s=r.lang?r.lang.split(/\s+/):[];s.length>0&&(i.className=["language-"+s[0]]);let u={type:"element",tagName:"code",properties:i,children:[{type:"text",value:l}]};return r.meta&&(u.data={meta:r.meta}),t.patch(r,u),u=t.applyData(r,u),u={type:"element",tagName:"pre",properties:{},children:[u]},t.patch(r,u),u}function SE(t,r){const l={type:"element",tagName:"del",properties:{},children:t.all(r)};return t.patch(r,l),t.applyData(r,l)}function wE(t,r){const l={type:"element",tagName:"em",properties:{},children:t.all(r)};return t.patch(r,l),t.applyData(r,l)}function kE(t,r){const l=typeof t.options.clobberPrefix=="string"?t.options.clobberPrefix:"user-content-",i=String(r.identifier).toUpperCase(),s=Sa(i.toLowerCase()),u=t.footnoteOrder.indexOf(i);let c,d=t.footnoteCounts.get(i);d===void 0?(d=0,t.footnoteOrder.push(i),c=t.footnoteOrder.length):c=u+1,d+=1,t.footnoteCounts.set(i,d);const p={type:"element",tagName:"a",properties:{href:"#"+l+"fn-"+s,id:l+"fnref-"+s+(d>1?"-"+d:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(c)}]};t.patch(r,p);const m={type:"element",tagName:"sup",properties:{},children:[p]};return t.patch(r,m),t.applyData(r,m)}function CE(t,r){const l={type:"element",tagName:"h"+r.depth,properties:{},children:t.all(r)};return t.patch(r,l),t.applyData(r,l)}function NE(t,r){if(t.options.allowDangerousHtml){const l={type:"raw",value:r.value};return t.patch(r,l),t.applyData(r,l)}}function U0(t,r){const l=r.referenceType;let i="]";if(l==="collapsed"?i+="[]":l==="full"&&(i+="["+(r.label||r.identifier)+"]"),r.type==="imageReference")return[{type:"text",value:"!["+r.alt+i}];const s=t.all(r),u=s[0];u&&u.type==="text"?u.value="["+u.value:s.unshift({type:"text",value:"["});const c=s[s.length-1];return c&&c.type==="text"?c.value+=i:s.push({type:"text",value:i}),s}function EE(t,r){const l=String(r.identifier).toUpperCase(),i=t.definitionById.get(l);if(!i)return U0(t,r);const s={src:Sa(i.url||""),alt:r.alt};i.title!==null&&i.title!==void 0&&(s.title=i.title);const u={type:"element",tagName:"img",properties:s,children:[]};return t.patch(r,u),t.applyData(r,u)}function jE(t,r){const l={src:Sa(r.url)};r.alt!==null&&r.alt!==void 0&&(l.alt=r.alt),r.title!==null&&r.title!==void 0&&(l.title=r.title);const i={type:"element",tagName:"img",properties:l,children:[]};return t.patch(r,i),t.applyData(r,i)}function TE(t,r){const l={type:"text",value:r.value.replace(/\r?\n|\r/g," ")};t.patch(r,l);const i={type:"element",tagName:"code",properties:{},children:[l]};return t.patch(r,i),t.applyData(r,i)}function AE(t,r){const l=String(r.identifier).toUpperCase(),i=t.definitionById.get(l);if(!i)return U0(t,r);const s={href:Sa(i.url||"")};i.title!==null&&i.title!==void 0&&(s.title=i.title);const u={type:"element",tagName:"a",properties:s,children:t.all(r)};return t.patch(r,u),t.applyData(r,u)}function ME(t,r){const l={href:Sa(r.url)};r.title!==null&&r.title!==void 0&&(l.title=r.title);const i={type:"element",tagName:"a",properties:l,children:t.all(r)};return t.patch(r,i),t.applyData(r,i)}function DE(t,r,l){const i=t.all(r),s=l?RE(l):B0(r),u={},c=[];if(typeof r.checked=="boolean"){const x=i[0];let y;x&&x.type==="element"&&x.tagName==="p"?y=x:(y={type:"element",tagName:"p",properties:{},children:[]},i.unshift(y)),y.children.length>0&&y.children.unshift({type:"text",value:" "}),y.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:r.checked,disabled:!0},children:[]}),u.className=["task-list-item"]}let d=-1;for(;++d<i.length;){const x=i[d];(s||d!==0||x.type!=="element"||x.tagName!=="p")&&c.push({type:"text",value:`
|
|
520
|
-
`}),x.type==="element"&&x.tagName==="p"&&!s?c.push(...x.children):c.push(x)}const p=i[i.length-1];p&&(s||p.type!=="element"||p.tagName!=="p")&&c.push({type:"text",value:`
|
|
521
|
-
`});const m={type:"element",tagName:"li",properties:u,children:c};return t.patch(r,m),t.applyData(r,m)}function RE(t){let r=!1;if(t.type==="list"){r=t.spread||!1;const l=t.children;let i=-1;for(;!r&&++i<l.length;)r=B0(l[i])}return r}function B0(t){const r=t.spread;return r??t.children.length>1}function zE(t,r){const l={},i=t.all(r);let s=-1;for(typeof r.start=="number"&&r.start!==1&&(l.start=r.start);++s<i.length;){const c=i[s];if(c.type==="element"&&c.tagName==="li"&&c.properties&&Array.isArray(c.properties.className)&&c.properties.className.includes("task-list-item")){l.className=["contains-task-list"];break}}const u={type:"element",tagName:r.ordered?"ol":"ul",properties:l,children:t.wrap(i,!0)};return t.patch(r,u),t.applyData(r,u)}function OE(t,r){const l={type:"element",tagName:"p",properties:{},children:t.all(r)};return t.patch(r,l),t.applyData(r,l)}function _E(t,r){const l={type:"root",children:t.wrap(t.all(r))};return t.patch(r,l),t.applyData(r,l)}function LE(t,r){const l={type:"element",tagName:"strong",properties:{},children:t.all(r)};return t.patch(r,l),t.applyData(r,l)}function UE(t,r){const l=t.all(r),i=l.shift(),s=[];if(i){const c={type:"element",tagName:"thead",properties:{},children:t.wrap([i],!0)};t.patch(r.children[0],c),s.push(c)}if(l.length>0){const c={type:"element",tagName:"tbody",properties:{},children:t.wrap(l,!0)},d=jd(r.children[1]),p=y0(r.children[r.children.length-1]);d&&p&&(c.position={start:d,end:p}),s.push(c)}const u={type:"element",tagName:"table",properties:{},children:t.wrap(s,!0)};return t.patch(r,u),t.applyData(r,u)}function BE(t,r,l){const i=l?l.children:void 0,u=(i?i.indexOf(r):1)===0?"th":"td",c=l&&l.type==="table"?l.align:void 0,d=c?c.length:r.children.length;let p=-1;const m=[];for(;++p<d;){const y=r.children[p],b={},S=c?c[p]:void 0;S&&(b.align=S);let k={type:"element",tagName:u,properties:b,children:[]};y&&(k.children=t.all(y),t.patch(y,k),k=t.applyData(y,k)),m.push(k)}const x={type:"element",tagName:"tr",properties:{},children:t.wrap(m,!0)};return t.patch(r,x),t.applyData(r,x)}function HE(t,r){const l={type:"element",tagName:"td",properties:{},children:t.all(r)};return t.patch(r,l),t.applyData(r,l)}const Uy=9,By=32;function qE(t){const r=String(t),l=/\r?\n|\r/g;let i=l.exec(r),s=0;const u=[];for(;i;)u.push(Hy(r.slice(s,i.index),s>0,!0),i[0]),s=i.index+i[0].length,i=l.exec(r);return u.push(Hy(r.slice(s),s>0,!1)),u.join("")}function Hy(t,r,l){let i=0,s=t.length;if(r){let u=t.codePointAt(i);for(;u===Uy||u===By;)i++,u=t.codePointAt(i)}if(l){let u=t.codePointAt(s-1);for(;u===Uy||u===By;)s--,u=t.codePointAt(s-1)}return s>i?t.slice(i,s):""}function IE(t,r){const l={type:"text",value:qE(String(r.value))};return t.patch(r,l),t.applyData(r,l)}function VE(t,r){const l={type:"element",tagName:"hr",properties:{},children:[]};return t.patch(r,l),t.applyData(r,l)}const $E={blockquote:xE,break:bE,code:vE,delete:SE,emphasis:wE,footnoteReference:kE,heading:CE,html:NE,imageReference:EE,image:jE,inlineCode:TE,linkReference:AE,link:ME,listItem:DE,list:zE,paragraph:OE,root:_E,strong:LE,table:UE,tableCell:HE,tableRow:BE,text:IE,thematicBreak:VE,toml:as,yaml:as,definition:as,footnoteDefinition:as};function as(){}const H0=-1,zs=0,Ei=1,ws=2,Od=3,_d=4,Ld=5,Ud=6,q0=7,I0=8,FE=typeof self=="object"?self:globalThis,qy=(t,r)=>{switch(t){case"Function":case"SharedWorker":case"Worker":case"eval":case"setInterval":case"setTimeout":throw new TypeError("unable to deserialize "+t)}return new FE[t](r)},YE=(t,r)=>{const l=(s,u)=>(t.set(u,s),s),i=s=>{if(t.has(s))return t.get(s);const[u,c]=r[s];switch(u){case zs:case H0:return l(c,s);case Ei:{const d=l([],s);for(const p of c)d.push(i(p));return d}case ws:{const d=l({},s);for(const[p,m]of c)d[i(p)]=i(m);return d}case Od:return l(new Date(c),s);case _d:{const{source:d,flags:p}=c;return l(new RegExp(d,p),s)}case Ld:{const d=l(new Map,s);for(const[p,m]of c)d.set(i(p),i(m));return d}case Ud:{const d=l(new Set,s);for(const p of c)d.add(i(p));return d}case q0:{const{name:d,message:p}=c;return l(qy(d,p),s)}case I0:return l(BigInt(c),s);case"BigInt":return l(Object(BigInt(c)),s);case"ArrayBuffer":return l(new Uint8Array(c).buffer,c);case"DataView":{const{buffer:d}=new Uint8Array(c);return l(new DataView(d),c)}}return l(qy(u,c),s)};return i},Iy=t=>YE(new Map,t)(0),la="",{toString:GE}={},{keys:PE}=Object,Si=t=>{const r=typeof t;if(r!=="object"||!t)return[zs,r];const l=GE.call(t).slice(8,-1);switch(l){case"Array":return[Ei,la];case"Object":return[ws,la];case"Date":return[Od,la];case"RegExp":return[_d,la];case"Map":return[Ld,la];case"Set":return[Ud,la];case"DataView":return[Ei,l]}return l.includes("Array")?[Ei,l]:l.includes("Error")?[q0,l]:[ws,l]},is=([t,r])=>t===zs&&(r==="function"||r==="symbol"),XE=(t,r,l,i)=>{const s=(c,d)=>{const p=i.push(c)-1;return l.set(d,p),p},u=c=>{if(l.has(c))return l.get(c);let[d,p]=Si(c);switch(d){case zs:{let x=c;switch(p){case"bigint":d=I0,x=c.toString();break;case"function":case"symbol":if(t)throw new TypeError("unable to serialize "+p);x=null;break;case"undefined":return s([H0],c)}return s([d,x],c)}case Ei:{if(p){let b=c;return p==="DataView"?b=new Uint8Array(c.buffer):p==="ArrayBuffer"&&(b=new Uint8Array(c)),s([p,[...b]],c)}const x=[],y=s([d,x],c);for(const b of c)x.push(u(b));return y}case ws:{if(p)switch(p){case"BigInt":return s([p,c.toString()],c);case"Boolean":case"Number":case"String":return s([p,c.valueOf()],c)}if(r&&"toJSON"in c)return u(c.toJSON());const x=[],y=s([d,x],c);for(const b of PE(c))(t||!is(Si(c[b])))&&x.push([u(b),u(c[b])]);return y}case Od:return s([d,c.toISOString()],c);case _d:{const{source:x,flags:y}=c;return s([d,{source:x,flags:y}],c)}case Ld:{const x=[],y=s([d,x],c);for(const[b,S]of c)(t||!(is(Si(b))||is(Si(S))))&&x.push([u(b),u(S)]);return y}case Ud:{const x=[],y=s([d,x],c);for(const b of c)(t||!is(Si(b)))&&x.push(u(b));return y}}const{message:m}=c;return s([d,{name:p,message:m}],c)};return u},Vy=(t,{json:r,lossy:l}={})=>{const i=[];return XE(!(r||l),!!r,new Map,i)(t),i},ks=typeof structuredClone=="function"?(t,r)=>r&&("json"in r||"lossy"in r)?Iy(Vy(t,r)):structuredClone(t):(t,r)=>Iy(Vy(t,r));function QE(t,r){const l=[{type:"text",value:"↩"}];return r>1&&l.push({type:"element",tagName:"sup",properties:{},children:[{type:"text",value:String(r)}]}),l}function KE(t,r){return"Back to reference "+(t+1)+(r>1?"-"+r:"")}function ZE(t){const r=typeof t.options.clobberPrefix=="string"?t.options.clobberPrefix:"user-content-",l=t.options.footnoteBackContent||QE,i=t.options.footnoteBackLabel||KE,s=t.options.footnoteLabel||"Footnotes",u=t.options.footnoteLabelTagName||"h2",c=t.options.footnoteLabelProperties||{className:["sr-only"]},d=[];let p=-1;for(;++p<t.footnoteOrder.length;){const m=t.footnoteById.get(t.footnoteOrder[p]);if(!m)continue;const x=t.all(m),y=String(m.identifier).toUpperCase(),b=Sa(y.toLowerCase());let S=0;const k=[],N=t.footnoteCounts.get(y);for(;N!==void 0&&++S<=N;){k.length>0&&k.push({type:"text",value:" "});let M=typeof l=="string"?l:l(p,S);typeof M=="string"&&(M={type:"text",value:M}),k.push({type:"element",tagName:"a",properties:{href:"#"+r+"fnref-"+b+(S>1?"-"+S:""),dataFootnoteBackref:"",ariaLabel:typeof i=="string"?i:i(p,S),className:["data-footnote-backref"]},children:Array.isArray(M)?M:[M]})}const A=x[x.length-1];if(A&&A.type==="element"&&A.tagName==="p"){const M=A.children[A.children.length-1];M&&M.type==="text"?M.value+=" ":A.children.push({type:"text",value:" "}),A.children.push(...k)}else x.push(...k);const j={type:"element",tagName:"li",properties:{id:r+"fn-"+b},children:t.wrap(x,!0)};t.patch(m,j),d.push(j)}if(d.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:u,properties:{...ks(c),id:"footnote-label"},children:[{type:"text",value:s}]},{type:"text",value:`
|
|
522
|
-
`},{type:"element",tagName:"ol",properties:{},children:t.wrap(d,!0)},{type:"text",value:`
|
|
523
|
-
`}]}}const Os=(function(t){if(t==null)return tj;if(typeof t=="function")return _s(t);if(typeof t=="object")return Array.isArray(t)?JE(t):WE(t);if(typeof t=="string")return ej(t);throw new Error("Expected function, string, or object as test")});function JE(t){const r=[];let l=-1;for(;++l<t.length;)r[l]=Os(t[l]);return _s(i);function i(...s){let u=-1;for(;++u<r.length;)if(r[u].apply(this,s))return!0;return!1}}function WE(t){const r=t;return _s(l);function l(i){const s=i;let u;for(u in t)if(s[u]!==r[u])return!1;return!0}}function ej(t){return _s(r);function r(l){return l&&l.type===t}}function _s(t){return r;function r(l,i,s){return!!(nj(l)&&t.call(this,l,typeof i=="number"?i:void 0,s||void 0))}}function tj(){return!0}function nj(t){return t!==null&&typeof t=="object"&&"type"in t}const V0=[],rj=!0,Qf=!1,lj="skip";function $0(t,r,l,i){let s;typeof r=="function"&&typeof l!="function"?(i=l,l=r):s=r;const u=Os(s),c=i?-1:1;d(t,void 0,[])();function d(p,m,x){const y=p&&typeof p=="object"?p:{};if(typeof y.type=="string"){const S=typeof y.tagName=="string"?y.tagName:typeof y.name=="string"?y.name:void 0;Object.defineProperty(b,"name",{value:"node ("+(p.type+(S?"<"+S+">":""))+")"})}return b;function b(){let S=V0,k,N,A;if((!r||u(p,m,x[x.length-1]||void 0))&&(S=aj(l(p,x)),S[0]===Qf))return S;if("children"in p&&p.children){const j=p;if(j.children&&S[0]!==lj)for(N=(i?j.children.length:-1)+c,A=x.concat(j);N>-1&&N<j.children.length;){const M=j.children[N];if(k=d(M,N,A)(),k[0]===Qf)return k;N=typeof k[1]=="number"?k[1]:N+c}}return S}}}function aj(t){return Array.isArray(t)?t:typeof t=="number"?[rj,t]:t==null?V0:[t]}function Bd(t,r,l,i){let s,u,c;typeof r=="function"&&typeof l!="function"?(u=void 0,c=r,s=l):(u=r,c=l,s=i),$0(t,u,d,s);function d(p,m){const x=m[m.length-1],y=x?x.children.indexOf(p):void 0;return c(p,y,x)}}const Kf={}.hasOwnProperty,ij={};function oj(t,r){const l=r||ij,i=new Map,s=new Map,u=new Map,c={...$E,...l.handlers},d={all:m,applyData:uj,definitionById:i,footnoteById:s,footnoteCounts:u,footnoteOrder:[],handlers:c,one:p,options:l,patch:sj,wrap:fj};return Bd(t,function(x){if(x.type==="definition"||x.type==="footnoteDefinition"){const y=x.type==="definition"?i:s,b=String(x.identifier).toUpperCase();y.has(b)||y.set(b,x)}}),d;function p(x,y){const b=x.type,S=d.handlers[b];if(Kf.call(d.handlers,b)&&S)return S(d,x,y);if(d.options.passThrough&&d.options.passThrough.includes(b)){if("children"in x){const{children:N,...A}=x,j=ks(A);return j.children=d.all(x),j}return ks(x)}return(d.options.unknownHandler||cj)(d,x,y)}function m(x){const y=[];if("children"in x){const b=x.children;let S=-1;for(;++S<b.length;){const k=d.one(b[S],x);if(k){if(S&&b[S-1].type==="break"&&(!Array.isArray(k)&&k.type==="text"&&(k.value=$y(k.value)),!Array.isArray(k)&&k.type==="element")){const N=k.children[0];N&&N.type==="text"&&(N.value=$y(N.value))}Array.isArray(k)?y.push(...k):y.push(k)}}}return y}}function sj(t,r){t.position&&(r.position=Qk(t))}function uj(t,r){let l=r;if(t&&t.data){const i=t.data.hName,s=t.data.hChildren,u=t.data.hProperties;if(typeof i=="string")if(l.type==="element")l.tagName=i;else{const c="children"in l?l.children:[l];l={type:"element",tagName:i,properties:{},children:c}}l.type==="element"&&u&&Object.assign(l.properties,ks(u)),"children"in l&&l.children&&s!==null&&s!==void 0&&(l.children=s)}return l}function cj(t,r){const l=r.data||{},i="value"in r&&!(Kf.call(l,"hProperties")||Kf.call(l,"hChildren"))?{type:"text",value:r.value}:{type:"element",tagName:"div",properties:{},children:t.all(r)};return t.patch(r,i),t.applyData(r,i)}function fj(t,r){const l=[];let i=-1;for(r&&l.push({type:"text",value:`
|
|
524
|
-
`});++i<t.length;)i&&l.push({type:"text",value:`
|
|
525
|
-
`}),l.push(t[i]);return r&&t.length>0&&l.push({type:"text",value:`
|
|
526
|
-
`}),l}function $y(t){let r=0,l=t.charCodeAt(r);for(;l===9||l===32;)r++,l=t.charCodeAt(r);return t.slice(r)}function Fy(t,r){const l=oj(t,r),i=l.one(t,void 0),s=ZE(l),u=Array.isArray(i)?{type:"root",children:i}:i||{type:"root",children:[]};return s&&u.children.push({type:"text",value:`
|
|
527
|
-
`},s),u}function dj(t,r){return t&&"run"in t?async function(l,i){const s=Fy(l,{file:i,...r});await t.run(s,i)}:function(l,i){return Fy(l,{file:i,...t||r})}}function Yy(t){if(t)throw t}var df,Gy;function hj(){if(Gy)return df;Gy=1;var t=Object.prototype.hasOwnProperty,r=Object.prototype.toString,l=Object.defineProperty,i=Object.getOwnPropertyDescriptor,s=function(m){return typeof Array.isArray=="function"?Array.isArray(m):r.call(m)==="[object Array]"},u=function(m){if(!m||r.call(m)!=="[object Object]")return!1;var x=t.call(m,"constructor"),y=m.constructor&&m.constructor.prototype&&t.call(m.constructor.prototype,"isPrototypeOf");if(m.constructor&&!x&&!y)return!1;var b;for(b in m);return typeof b>"u"||t.call(m,b)},c=function(m,x){l&&x.name==="__proto__"?l(m,x.name,{enumerable:!0,configurable:!0,value:x.newValue,writable:!0}):m[x.name]=x.newValue},d=function(m,x){if(x==="__proto__")if(t.call(m,x)){if(i)return i(m,x).value}else return;return m[x]};return df=function p(){var m,x,y,b,S,k,N=arguments[0],A=1,j=arguments.length,M=!1;for(typeof N=="boolean"&&(M=N,N=arguments[1]||{},A=2),(N==null||typeof N!="object"&&typeof N!="function")&&(N={});A<j;++A)if(m=arguments[A],m!=null)for(x in m)y=d(N,x),b=d(m,x),N!==b&&(M&&b&&(u(b)||(S=s(b)))?(S?(S=!1,k=y&&s(y)?y:[]):k=y&&u(y)?y:{},c(N,{name:x,newValue:p(M,k,b)})):typeof b<"u"&&c(N,{name:x,newValue:b}));return N},df}var mj=hj();const hf=Ri(mj);function Zf(t){if(typeof t!="object"||t===null)return!1;const r=Object.getPrototypeOf(t);return(r===null||r===Object.prototype||Object.getPrototypeOf(r)===null)&&!(Symbol.toStringTag in t)&&!(Symbol.iterator in t)}function pj(){const t=[],r={run:l,use:i};return r;function l(...s){let u=-1;const c=s.pop();if(typeof c!="function")throw new TypeError("Expected function as last argument, not "+c);d(null,...s);function d(p,...m){const x=t[++u];let y=-1;if(p){c(p);return}for(;++y<s.length;)(m[y]===null||m[y]===void 0)&&(m[y]=s[y]);s=m,x?gj(x,d)(...m):c(null,...m)}}function i(s){if(typeof s!="function")throw new TypeError("Expected `middelware` to be a function, not "+s);return t.push(s),r}}function gj(t,r){let l;return i;function i(...c){const d=t.length>c.length;let p;d&&c.push(s);try{p=t.apply(this,c)}catch(m){const x=m;if(d&&l)throw x;return s(x)}d||(p&&p.then&&typeof p.then=="function"?p.then(u,s):p instanceof Error?s(p):u(p))}function s(c,...d){l||(l=!0,r(c,...d))}function u(c){s(null,c)}}const Un={basename:yj,dirname:xj,extname:bj,join:vj,sep:"/"};function yj(t,r){if(r!==void 0&&typeof r!="string")throw new TypeError('"ext" argument must be a string');Ui(t);let l=0,i=-1,s=t.length,u;if(r===void 0||r.length===0||r.length>t.length){for(;s--;)if(t.codePointAt(s)===47){if(u){l=s+1;break}}else i<0&&(u=!0,i=s+1);return i<0?"":t.slice(l,i)}if(r===t)return"";let c=-1,d=r.length-1;for(;s--;)if(t.codePointAt(s)===47){if(u){l=s+1;break}}else c<0&&(u=!0,c=s+1),d>-1&&(t.codePointAt(s)===r.codePointAt(d--)?d<0&&(i=s):(d=-1,i=c));return l===i?i=c:i<0&&(i=t.length),t.slice(l,i)}function xj(t){if(Ui(t),t.length===0)return".";let r=-1,l=t.length,i;for(;--l;)if(t.codePointAt(l)===47){if(i){r=l;break}}else i||(i=!0);return r<0?t.codePointAt(0)===47?"/":".":r===1&&t.codePointAt(0)===47?"//":t.slice(0,r)}function bj(t){Ui(t);let r=t.length,l=-1,i=0,s=-1,u=0,c;for(;r--;){const d=t.codePointAt(r);if(d===47){if(c){i=r+1;break}continue}l<0&&(c=!0,l=r+1),d===46?s<0?s=r:u!==1&&(u=1):s>-1&&(u=-1)}return s<0||l<0||u===0||u===1&&s===l-1&&s===i+1?"":t.slice(s,l)}function vj(...t){let r=-1,l;for(;++r<t.length;)Ui(t[r]),t[r]&&(l=l===void 0?t[r]:l+"/"+t[r]);return l===void 0?".":Sj(l)}function Sj(t){Ui(t);const r=t.codePointAt(0)===47;let l=wj(t,!r);return l.length===0&&!r&&(l="."),l.length>0&&t.codePointAt(t.length-1)===47&&(l+="/"),r?"/"+l:l}function wj(t,r){let l="",i=0,s=-1,u=0,c=-1,d,p;for(;++c<=t.length;){if(c<t.length)d=t.codePointAt(c);else{if(d===47)break;d=47}if(d===47){if(!(s===c-1||u===1))if(s!==c-1&&u===2){if(l.length<2||i!==2||l.codePointAt(l.length-1)!==46||l.codePointAt(l.length-2)!==46){if(l.length>2){if(p=l.lastIndexOf("/"),p!==l.length-1){p<0?(l="",i=0):(l=l.slice(0,p),i=l.length-1-l.lastIndexOf("/")),s=c,u=0;continue}}else if(l.length>0){l="",i=0,s=c,u=0;continue}}r&&(l=l.length>0?l+"/..":"..",i=2)}else l.length>0?l+="/"+t.slice(s+1,c):l=t.slice(s+1,c),i=c-s-1;s=c,u=0}else d===46&&u>-1?u++:u=-1}return l}function Ui(t){if(typeof t!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(t))}const kj={cwd:Cj};function Cj(){return"/"}function Jf(t){return!!(t!==null&&typeof t=="object"&&"href"in t&&t.href&&"protocol"in t&&t.protocol&&t.auth===void 0)}function Nj(t){if(typeof t=="string")t=new URL(t);else if(!Jf(t)){const r=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+t+"`");throw r.code="ERR_INVALID_ARG_TYPE",r}if(t.protocol!=="file:"){const r=new TypeError("The URL must be of scheme file");throw r.code="ERR_INVALID_URL_SCHEME",r}return Ej(t)}function Ej(t){if(t.hostname!==""){const i=new TypeError('File URL host must be "localhost" or empty on darwin');throw i.code="ERR_INVALID_FILE_URL_HOST",i}const r=t.pathname;let l=-1;for(;++l<r.length;)if(r.codePointAt(l)===37&&r.codePointAt(l+1)===50){const i=r.codePointAt(l+2);if(i===70||i===102){const s=new TypeError("File URL path must not include encoded / characters");throw s.code="ERR_INVALID_FILE_URL_PATH",s}}return decodeURIComponent(r)}const mf=["history","path","basename","stem","extname","dirname"];class F0{constructor(r){let l;r?Jf(r)?l={path:r}:typeof r=="string"||jj(r)?l={value:r}:l=r:l={},this.cwd="cwd"in l?"":kj.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let i=-1;for(;++i<mf.length;){const u=mf[i];u in l&&l[u]!==void 0&&l[u]!==null&&(this[u]=u==="history"?[...l[u]]:l[u])}let s;for(s in l)mf.includes(s)||(this[s]=l[s])}get basename(){return typeof this.path=="string"?Un.basename(this.path):void 0}set basename(r){gf(r,"basename"),pf(r,"basename"),this.path=Un.join(this.dirname||"",r)}get dirname(){return typeof this.path=="string"?Un.dirname(this.path):void 0}set dirname(r){Py(this.basename,"dirname"),this.path=Un.join(r||"",this.basename)}get extname(){return typeof this.path=="string"?Un.extname(this.path):void 0}set extname(r){if(pf(r,"extname"),Py(this.dirname,"extname"),r){if(r.codePointAt(0)!==46)throw new Error("`extname` must start with `.`");if(r.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=Un.join(this.dirname,this.stem+(r||""))}get path(){return this.history[this.history.length-1]}set path(r){Jf(r)&&(r=Nj(r)),gf(r,"path"),this.path!==r&&this.history.push(r)}get stem(){return typeof this.path=="string"?Un.basename(this.path,this.extname):void 0}set stem(r){gf(r,"stem"),pf(r,"stem"),this.path=Un.join(this.dirname||"",r+(this.extname||""))}fail(r,l,i){const s=this.message(r,l,i);throw s.fatal=!0,s}info(r,l,i){const s=this.message(r,l,i);return s.fatal=void 0,s}message(r,l,i){const s=new Vt(r,l,i);return this.path&&(s.name=this.path+":"+s.name,s.file=this.path),s.fatal=!1,this.messages.push(s),s}toString(r){return this.value===void 0?"":typeof this.value=="string"?this.value:new TextDecoder(r||void 0).decode(this.value)}}function pf(t,r){if(t&&t.includes(Un.sep))throw new Error("`"+r+"` cannot be a path: did not expect `"+Un.sep+"`")}function gf(t,r){if(!t)throw new Error("`"+r+"` cannot be empty")}function Py(t,r){if(!t)throw new Error("Setting `"+r+"` requires `path` to be set too")}function jj(t){return!!(t&&typeof t=="object"&&"byteLength"in t&&"byteOffset"in t)}const Tj=(function(t){const i=this.constructor.prototype,s=i[t],u=function(){return s.apply(u,arguments)};return Object.setPrototypeOf(u,i),u}),Aj={}.hasOwnProperty;class Hd extends Tj{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=pj()}copy(){const r=new Hd;let l=-1;for(;++l<this.attachers.length;){const i=this.attachers[l];r.use(...i)}return r.data(hf(!0,{},this.namespace)),r}data(r,l){return typeof r=="string"?arguments.length===2?(bf("data",this.frozen),this.namespace[r]=l,this):Aj.call(this.namespace,r)&&this.namespace[r]||void 0:r?(bf("data",this.frozen),this.namespace=r,this):this.namespace}freeze(){if(this.frozen)return this;const r=this;for(;++this.freezeIndex<this.attachers.length;){const[l,...i]=this.attachers[this.freezeIndex];if(i[0]===!1)continue;i[0]===!0&&(i[0]=void 0);const s=l.call(r,...i);typeof s=="function"&&this.transformers.use(s)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(r){this.freeze();const l=os(r),i=this.parser||this.Parser;return yf("parse",i),i(String(l),l)}process(r,l){const i=this;return this.freeze(),yf("process",this.parser||this.Parser),xf("process",this.compiler||this.Compiler),l?s(void 0,l):new Promise(s);function s(u,c){const d=os(r),p=i.parse(d);i.run(p,d,function(x,y,b){if(x||!y||!b)return m(x);const S=y,k=i.stringify(S,b);Rj(k)?b.value=k:b.result=k,m(x,b)});function m(x,y){x||!y?c(x):u?u(y):l(void 0,y)}}}processSync(r){let l=!1,i;return this.freeze(),yf("processSync",this.parser||this.Parser),xf("processSync",this.compiler||this.Compiler),this.process(r,s),Qy("processSync","process",l),i;function s(u,c){l=!0,Yy(u),i=c}}run(r,l,i){Xy(r),this.freeze();const s=this.transformers;return!i&&typeof l=="function"&&(i=l,l=void 0),i?u(void 0,i):new Promise(u);function u(c,d){const p=os(l);s.run(r,p,m);function m(x,y,b){const S=y||r;x?d(x):c?c(S):i(void 0,S,b)}}}runSync(r,l){let i=!1,s;return this.run(r,l,u),Qy("runSync","run",i),s;function u(c,d){Yy(c),s=d,i=!0}}stringify(r,l){this.freeze();const i=os(l),s=this.compiler||this.Compiler;return xf("stringify",s),Xy(r),s(r,i)}use(r,...l){const i=this.attachers,s=this.namespace;if(bf("use",this.frozen),r!=null)if(typeof r=="function")p(r,l);else if(typeof r=="object")Array.isArray(r)?d(r):c(r);else throw new TypeError("Expected usable value, not `"+r+"`");return this;function u(m){if(typeof m=="function")p(m,[]);else if(typeof m=="object")if(Array.isArray(m)){const[x,...y]=m;p(x,y)}else c(m);else throw new TypeError("Expected usable value, not `"+m+"`")}function c(m){if(!("plugins"in m)&&!("settings"in m))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");d(m.plugins),m.settings&&(s.settings=hf(!0,s.settings,m.settings))}function d(m){let x=-1;if(m!=null)if(Array.isArray(m))for(;++x<m.length;){const y=m[x];u(y)}else throw new TypeError("Expected a list of plugins, not `"+m+"`")}function p(m,x){let y=-1,b=-1;for(;++y<i.length;)if(i[y][0]===m){b=y;break}if(b===-1)i.push([m,...x]);else if(x.length>0){let[S,...k]=x;const N=i[b][1];Zf(N)&&Zf(S)&&(S=hf(!0,N,S)),i[b]=[m,S,...k]}}}}const Mj=new Hd().freeze();function yf(t,r){if(typeof r!="function")throw new TypeError("Cannot `"+t+"` without `parser`")}function xf(t,r){if(typeof r!="function")throw new TypeError("Cannot `"+t+"` without `compiler`")}function bf(t,r){if(r)throw new Error("Cannot call `"+t+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function Xy(t){if(!Zf(t)||typeof t.type!="string")throw new TypeError("Expected node, got `"+t+"`")}function Qy(t,r,l){if(!l)throw new Error("`"+t+"` finished async. Use `"+r+"` instead")}function os(t){return Dj(t)?t:new F0(t)}function Dj(t){return!!(t&&typeof t=="object"&&"message"in t&&"messages"in t)}function Rj(t){return typeof t=="string"||zj(t)}function zj(t){return!!(t&&typeof t=="object"&&"byteLength"in t&&"byteOffset"in t)}const Oj="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",Ky=[],Zy={allowDangerousHtml:!0},_j=/^(https?|ircs?|mailto|xmpp)$/i,Lj=[{from:"astPlugins",id:"remove-buggy-html-in-markdown-parser"},{from:"allowDangerousHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"allowNode",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowElement"},{from:"allowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowedElements"},{from:"disallowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"disallowedElements"},{from:"escapeHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"includeElementIndex",id:"#remove-includeelementindex"},{from:"includeNodeIndex",id:"change-includenodeindex-to-includeelementindex"},{from:"linkTarget",id:"remove-linktarget"},{from:"plugins",id:"change-plugins-to-remarkplugins",to:"remarkPlugins"},{from:"rawSourcePos",id:"#remove-rawsourcepos"},{from:"renderers",id:"change-renderers-to-components",to:"components"},{from:"source",id:"change-source-to-children",to:"children"},{from:"sourcePos",id:"#remove-sourcepos"},{from:"transformImageUri",id:"#add-urltransform",to:"urlTransform"},{from:"transformLinkUri",id:"#add-urltransform",to:"urlTransform"}];function Uj(t){const r=Bj(t),l=Hj(t);return qj(r.runSync(r.parse(l),l),t)}function Bj(t){const r=t.rehypePlugins||Ky,l=t.remarkPlugins||Ky,i=t.remarkRehypeOptions?{...t.remarkRehypeOptions,...Zy}:Zy;return Mj().use(yE).use(l).use(dj,i).use(r)}function Hj(t){const r=t.children||"",l=new F0;return typeof r=="string"&&(l.value=r),l}function qj(t,r){const l=r.allowedElements,i=r.allowElement,s=r.components,u=r.disallowedElements,c=r.skipHtml,d=r.unwrapDisallowed,p=r.urlTransform||Ij;for(const x of Lj)Object.hasOwn(r,x.from)&&(""+x.from+(x.to?"use `"+x.to+"` instead":"remove it")+Oj+x.id,void 0);return r.className&&(t={type:"element",tagName:"div",properties:{className:r.className},children:t.type==="root"?t.children:[t]}),Bd(t,m),eC(t,{Fragment:h.Fragment,components:s,ignoreInvalidStyle:!0,jsx:h.jsx,jsxs:h.jsxs,passKeys:!0,passNode:!0});function m(x,y,b){if(x.type==="raw"&&b&&typeof y=="number")return c?b.children.splice(y,1):b.children[y]={type:"text",value:x.value},y;if(x.type==="element"){let S;for(S in uf)if(Object.hasOwn(uf,S)&&Object.hasOwn(x.properties,S)){const k=x.properties[S],N=uf[S];(N===null||N.includes(x.tagName))&&(x.properties[S]=p(String(k||""),S,x))}}if(x.type==="element"){let S=l?!l.includes(x.tagName):u?u.includes(x.tagName):!1;if(!S&&i&&typeof y=="number"&&(S=!i(x,y,b)),S&&b&&typeof y=="number")return d&&x.children?b.children.splice(y,1,...x.children):b.children.splice(y,1),y}}}function Ij(t){const r=t.indexOf(":"),l=t.indexOf("?"),i=t.indexOf("#"),s=t.indexOf("/");return r===-1||s!==-1&&r>s||l!==-1&&r>l||i!==-1&&r>i||_j.test(t.slice(0,r))?t:""}function Jy(t,r){const l=String(t);if(typeof r!="string")throw new TypeError("Expected character");let i=0,s=l.indexOf(r);for(;s!==-1;)i++,s=l.indexOf(r,s+r.length);return i}function Vj(t){if(typeof t!="string")throw new TypeError("Expected a string");return t.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function $j(t,r,l){const s=Os((l||{}).ignore||[]),u=Fj(r);let c=-1;for(;++c<u.length;)$0(t,"text",d);function d(m,x){let y=-1,b;for(;++y<x.length;){const S=x[y],k=b?b.children:void 0;if(s(S,k?k.indexOf(S):void 0,b))return;b=S}if(b)return p(m,x)}function p(m,x){const y=x[x.length-1],b=u[c][0],S=u[c][1];let k=0;const A=y.children.indexOf(m);let j=!1,M=[];b.lastIndex=0;let z=b.exec(m.value);for(;z;){const V=z.index,Q={index:z.index,input:z.input,stack:[...x,m]};let B=S(...z,Q);if(typeof B=="string"&&(B=B.length>0?{type:"text",value:B}:void 0),B===!1?b.lastIndex=V+1:(k!==V&&M.push({type:"text",value:m.value.slice(k,V)}),Array.isArray(B)?M.push(...B):B&&M.push(B),k=V+z[0].length,j=!0),!b.global)break;z=b.exec(m.value)}return j?(k<m.value.length&&M.push({type:"text",value:m.value.slice(k)}),y.children.splice(A,1,...M)):M=[m],A+M.length}}function Fj(t){const r=[];if(!Array.isArray(t))throw new TypeError("Expected find and replace tuple or list of tuples");const l=!t[0]||Array.isArray(t[0])?t:[t];let i=-1;for(;++i<l.length;){const s=l[i];r.push([Yj(s[0]),Gj(s[1])])}return r}function Yj(t){return typeof t=="string"?new RegExp(Vj(t),"g"):t}function Gj(t){return typeof t=="function"?t:function(){return t}}const vf="phrasing",Sf=["autolink","link","image","label"];function Pj(){return{transforms:[e4],enter:{literalAutolink:Qj,literalAutolinkEmail:wf,literalAutolinkHttp:wf,literalAutolinkWww:wf},exit:{literalAutolink:Wj,literalAutolinkEmail:Jj,literalAutolinkHttp:Kj,literalAutolinkWww:Zj}}}function Xj(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:vf,notInConstruct:Sf},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:vf,notInConstruct:Sf},{character:":",before:"[ps]",after:"\\/",inConstruct:vf,notInConstruct:Sf}]}}function Qj(t){this.enter({type:"link",title:null,url:"",children:[]},t)}function wf(t){this.config.enter.autolinkProtocol.call(this,t)}function Kj(t){this.config.exit.autolinkProtocol.call(this,t)}function Zj(t){this.config.exit.data.call(this,t);const r=this.stack[this.stack.length-1];r.type,r.url="http://"+this.sliceSerialize(t)}function Jj(t){this.config.exit.autolinkEmail.call(this,t)}function Wj(t){this.exit(t)}function e4(t){$j(t,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,t4],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),n4]],{ignore:["link","linkReference"]})}function t4(t,r,l,i,s){let u="";if(!Y0(s)||(/^w/i.test(r)&&(l=r+l,r="",u="http://"),!r4(l)))return!1;const c=l4(l+i);if(!c[0])return!1;const d={type:"link",title:null,url:u+r+c[0],children:[{type:"text",value:r+c[0]}]};return c[1]?[d,{type:"text",value:c[1]}]:d}function n4(t,r,l,i){return!Y0(i,!0)||/[-\d_]$/.test(l)?!1:{type:"link",title:null,url:"mailto:"+r+"@"+l,children:[{type:"text",value:r+"@"+l}]}}function r4(t){const r=t.split(".");return!(r.length<2||r[r.length-1]&&(/_/.test(r[r.length-1])||!/[a-zA-Z\d]/.test(r[r.length-1]))||r[r.length-2]&&(/_/.test(r[r.length-2])||!/[a-zA-Z\d]/.test(r[r.length-2])))}function l4(t){const r=/[!"&'),.:;<>?\]}]+$/.exec(t);if(!r)return[t,void 0];t=t.slice(0,r.index);let l=r[0],i=l.indexOf(")");const s=Jy(t,"(");let u=Jy(t,")");for(;i!==-1&&s>u;)t+=l.slice(0,i+1),l=l.slice(i+1),i=l.indexOf(")"),u++;return[t,l]}function Y0(t,r){const l=t.input.charCodeAt(t.index-1);return(t.index===0||ml(l)||Ds(l))&&(!r||l!==47)}G0.peek=h4;function a4(){this.buffer()}function i4(t){this.enter({type:"footnoteReference",identifier:"",label:""},t)}function o4(){this.buffer()}function s4(t){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},t)}function u4(t){const r=this.resume(),l=this.stack[this.stack.length-1];l.type,l.identifier=Dn(this.sliceSerialize(t)).toLowerCase(),l.label=r}function c4(t){this.exit(t)}function f4(t){const r=this.resume(),l=this.stack[this.stack.length-1];l.type,l.identifier=Dn(this.sliceSerialize(t)).toLowerCase(),l.label=r}function d4(t){this.exit(t)}function h4(){return"["}function G0(t,r,l,i){const s=l.createTracker(i);let u=s.move("[^");const c=l.enter("footnoteReference"),d=l.enter("reference");return u+=s.move(l.safe(l.associationId(t),{after:"]",before:u})),d(),c(),u+=s.move("]"),u}function m4(){return{enter:{gfmFootnoteCallString:a4,gfmFootnoteCall:i4,gfmFootnoteDefinitionLabelString:o4,gfmFootnoteDefinition:s4},exit:{gfmFootnoteCallString:u4,gfmFootnoteCall:c4,gfmFootnoteDefinitionLabelString:f4,gfmFootnoteDefinition:d4}}}function p4(t){let r=!1;return t&&t.firstLineBlank&&(r=!0),{handlers:{footnoteDefinition:l,footnoteReference:G0},unsafe:[{character:"[",inConstruct:["label","phrasing","reference"]}]};function l(i,s,u,c){const d=u.createTracker(c);let p=d.move("[^");const m=u.enter("footnoteDefinition"),x=u.enter("label");return p+=d.move(u.safe(u.associationId(i),{before:p,after:"]"})),x(),p+=d.move("]:"),i.children&&i.children.length>0&&(d.shift(4),p+=d.move((r?`
|
|
528
|
-
`:" ")+u.indentLines(u.containerFlow(i,d.current()),r?P0:g4))),m(),p}}function g4(t,r,l){return r===0?t:P0(t,r,l)}function P0(t,r,l){return(l?"":" ")+t}const y4=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];X0.peek=w4;function x4(){return{canContainEols:["delete"],enter:{strikethrough:v4},exit:{strikethrough:S4}}}function b4(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:y4}],handlers:{delete:X0}}}function v4(t){this.enter({type:"delete",children:[]},t)}function S4(t){this.exit(t)}function X0(t,r,l,i){const s=l.createTracker(i),u=l.enter("strikethrough");let c=s.move("~~");return c+=l.containerPhrasing(t,{...s.current(),before:c,after:"~"}),c+=s.move("~~"),u(),c}function w4(){return"~"}function k4(t){return t.length}function C4(t,r){const l=r||{},i=(l.align||[]).concat(),s=l.stringLength||k4,u=[],c=[],d=[],p=[];let m=0,x=-1;for(;++x<t.length;){const N=[],A=[];let j=-1;for(t[x].length>m&&(m=t[x].length);++j<t[x].length;){const M=N4(t[x][j]);if(l.alignDelimiters!==!1){const z=s(M);A[j]=z,(p[j]===void 0||z>p[j])&&(p[j]=z)}N.push(M)}c[x]=N,d[x]=A}let y=-1;if(typeof i=="object"&&"length"in i)for(;++y<m;)u[y]=Wy(i[y]);else{const N=Wy(i);for(;++y<m;)u[y]=N}y=-1;const b=[],S=[];for(;++y<m;){const N=u[y];let A="",j="";N===99?(A=":",j=":"):N===108?A=":":N===114&&(j=":");let M=l.alignDelimiters===!1?1:Math.max(1,p[y]-A.length-j.length);const z=A+"-".repeat(M)+j;l.alignDelimiters!==!1&&(M=A.length+M+j.length,M>p[y]&&(p[y]=M),S[y]=M),b[y]=z}c.splice(1,0,b),d.splice(1,0,S),x=-1;const k=[];for(;++x<c.length;){const N=c[x],A=d[x];y=-1;const j=[];for(;++y<m;){const M=N[y]||"";let z="",V="";if(l.alignDelimiters!==!1){const Q=p[y]-(A[y]||0),B=u[y];B===114?z=" ".repeat(Q):B===99?Q%2?(z=" ".repeat(Q/2+.5),V=" ".repeat(Q/2-.5)):(z=" ".repeat(Q/2),V=z):V=" ".repeat(Q)}l.delimiterStart!==!1&&!y&&j.push("|"),l.padding!==!1&&!(l.alignDelimiters===!1&&M==="")&&(l.delimiterStart!==!1||y)&&j.push(" "),l.alignDelimiters!==!1&&j.push(z),j.push(M),l.alignDelimiters!==!1&&j.push(V),l.padding!==!1&&j.push(" "),(l.delimiterEnd!==!1||y!==m-1)&&j.push("|")}k.push(l.delimiterEnd===!1?j.join("").replace(/ +$/,""):j.join(""))}return k.join(`
|
|
529
|
-
`)}function N4(t){return t==null?"":String(t)}function Wy(t){const r=typeof t=="string"?t.codePointAt(0):0;return r===67||r===99?99:r===76||r===108?108:r===82||r===114?114:0}function E4(t,r,l,i){const s=l.enter("blockquote"),u=l.createTracker(i);u.move("> "),u.shift(2);const c=l.indentLines(l.containerFlow(t,u.current()),j4);return s(),c}function j4(t,r,l){return">"+(l?"":" ")+t}function T4(t,r){return ex(t,r.inConstruct,!0)&&!ex(t,r.notInConstruct,!1)}function ex(t,r,l){if(typeof r=="string"&&(r=[r]),!r||r.length===0)return l;let i=-1;for(;++i<r.length;)if(t.includes(r[i]))return!0;return!1}function tx(t,r,l,i){let s=-1;for(;++s<l.unsafe.length;)if(l.unsafe[s].character===`
|
|
530
|
-
`&&T4(l.stack,l.unsafe[s]))return/[ \t]/.test(i.before)?"":" ";return`\\
|
|
531
|
-
`}function A4(t,r){const l=String(t);let i=l.indexOf(r),s=i,u=0,c=0;if(typeof r!="string")throw new TypeError("Expected substring");for(;i!==-1;)i===s?++u>c&&(c=u):u=1,s=i+r.length,i=l.indexOf(r,s);return c}function M4(t,r){return!!(r.options.fences===!1&&t.value&&!t.lang&&/[^ \r\n]/.test(t.value)&&!/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test(t.value))}function D4(t){const r=t.options.fence||"`";if(r!=="`"&&r!=="~")throw new Error("Cannot serialize code with `"+r+"` for `options.fence`, expected `` ` `` or `~`");return r}function R4(t,r,l,i){const s=D4(l),u=t.value||"",c=s==="`"?"GraveAccent":"Tilde";if(M4(t,l)){const y=l.enter("codeIndented"),b=l.indentLines(u,z4);return y(),b}const d=l.createTracker(i),p=s.repeat(Math.max(A4(u,s)+1,3)),m=l.enter("codeFenced");let x=d.move(p);if(t.lang){const y=l.enter(`codeFencedLang${c}`);x+=d.move(l.safe(t.lang,{before:x,after:" ",encode:["`"],...d.current()})),y()}if(t.lang&&t.meta){const y=l.enter(`codeFencedMeta${c}`);x+=d.move(" "),x+=d.move(l.safe(t.meta,{before:x,after:`
|
|
532
|
-
`,encode:["`"],...d.current()})),y()}return x+=d.move(`
|
|
533
|
-
`),u&&(x+=d.move(u+`
|
|
534
|
-
`)),x+=d.move(p),m(),x}function z4(t,r,l){return(l?"":" ")+t}function qd(t){const r=t.options.quote||'"';if(r!=='"'&&r!=="'")throw new Error("Cannot serialize title with `"+r+"` for `options.quote`, expected `\"`, or `'`");return r}function O4(t,r,l,i){const s=qd(l),u=s==='"'?"Quote":"Apostrophe",c=l.enter("definition");let d=l.enter("label");const p=l.createTracker(i);let m=p.move("[");return m+=p.move(l.safe(l.associationId(t),{before:m,after:"]",...p.current()})),m+=p.move("]: "),d(),!t.url||/[\0- \u007F]/.test(t.url)?(d=l.enter("destinationLiteral"),m+=p.move("<"),m+=p.move(l.safe(t.url,{before:m,after:">",...p.current()})),m+=p.move(">")):(d=l.enter("destinationRaw"),m+=p.move(l.safe(t.url,{before:m,after:t.title?" ":`
|
|
535
|
-
`,...p.current()}))),d(),t.title&&(d=l.enter(`title${u}`),m+=p.move(" "+s),m+=p.move(l.safe(t.title,{before:m,after:s,...p.current()})),m+=p.move(s),d()),c(),m}function _4(t){const r=t.options.emphasis||"*";if(r!=="*"&&r!=="_")throw new Error("Cannot serialize emphasis with `"+r+"` for `options.emphasis`, expected `*`, or `_`");return r}function Di(t){return"&#x"+t.toString(16).toUpperCase()+";"}function Cs(t,r,l){const i=ya(t),s=ya(r);return i===void 0?s===void 0?l==="_"?{inside:!0,outside:!0}:{inside:!1,outside:!1}:s===1?{inside:!0,outside:!0}:{inside:!1,outside:!0}:i===1?s===void 0?{inside:!1,outside:!1}:s===1?{inside:!0,outside:!0}:{inside:!1,outside:!1}:s===void 0?{inside:!1,outside:!1}:s===1?{inside:!0,outside:!1}:{inside:!1,outside:!1}}Q0.peek=L4;function Q0(t,r,l,i){const s=_4(l),u=l.enter("emphasis"),c=l.createTracker(i),d=c.move(s);let p=c.move(l.containerPhrasing(t,{after:s,before:d,...c.current()}));const m=p.charCodeAt(0),x=Cs(i.before.charCodeAt(i.before.length-1),m,s);x.inside&&(p=Di(m)+p.slice(1));const y=p.charCodeAt(p.length-1),b=Cs(i.after.charCodeAt(0),y,s);b.inside&&(p=p.slice(0,-1)+Di(y));const S=c.move(s);return u(),l.attentionEncodeSurroundingInfo={after:b.outside,before:x.outside},d+p+S}function L4(t,r,l){return l.options.emphasis||"*"}function U4(t,r){let l=!1;return Bd(t,function(i){if("value"in i&&/\r?\n|\r/.test(i.value)||i.type==="break")return l=!0,Qf}),!!((!t.depth||t.depth<3)&&Dd(t)&&(r.options.setext||l))}function B4(t,r,l,i){const s=Math.max(Math.min(6,t.depth||1),1),u=l.createTracker(i);if(U4(t,l)){const x=l.enter("headingSetext"),y=l.enter("phrasing"),b=l.containerPhrasing(t,{...u.current(),before:`
|
|
536
|
-
`,after:`
|
|
537
|
-
`});return y(),x(),b+`
|
|
538
|
-
`+(s===1?"=":"-").repeat(b.length-(Math.max(b.lastIndexOf("\r"),b.lastIndexOf(`
|
|
539
|
-
`))+1))}const c="#".repeat(s),d=l.enter("headingAtx"),p=l.enter("phrasing");u.move(c+" ");let m=l.containerPhrasing(t,{before:"# ",after:`
|
|
540
|
-
`,...u.current()});return/^[\t ]/.test(m)&&(m=Di(m.charCodeAt(0))+m.slice(1)),m=m?c+" "+m:c,l.options.closeAtx&&(m+=" "+c),p(),d(),m}K0.peek=H4;function K0(t){return t.value||""}function H4(){return"<"}Z0.peek=q4;function Z0(t,r,l,i){const s=qd(l),u=s==='"'?"Quote":"Apostrophe",c=l.enter("image");let d=l.enter("label");const p=l.createTracker(i);let m=p.move("![");return m+=p.move(l.safe(t.alt,{before:m,after:"]",...p.current()})),m+=p.move("]("),d(),!t.url&&t.title||/[\0- \u007F]/.test(t.url)?(d=l.enter("destinationLiteral"),m+=p.move("<"),m+=p.move(l.safe(t.url,{before:m,after:">",...p.current()})),m+=p.move(">")):(d=l.enter("destinationRaw"),m+=p.move(l.safe(t.url,{before:m,after:t.title?" ":")",...p.current()}))),d(),t.title&&(d=l.enter(`title${u}`),m+=p.move(" "+s),m+=p.move(l.safe(t.title,{before:m,after:s,...p.current()})),m+=p.move(s),d()),m+=p.move(")"),c(),m}function q4(){return"!"}J0.peek=I4;function J0(t,r,l,i){const s=t.referenceType,u=l.enter("imageReference");let c=l.enter("label");const d=l.createTracker(i);let p=d.move("![");const m=l.safe(t.alt,{before:p,after:"]",...d.current()});p+=d.move(m+"]["),c();const x=l.stack;l.stack=[],c=l.enter("reference");const y=l.safe(l.associationId(t),{before:p,after:"]",...d.current()});return c(),l.stack=x,u(),s==="full"||!m||m!==y?p+=d.move(y+"]"):s==="shortcut"?p=p.slice(0,-1):p+=d.move("]"),p}function I4(){return"!"}W0.peek=V4;function W0(t,r,l){let i=t.value||"",s="`",u=-1;for(;new RegExp("(^|[^`])"+s+"([^`]|$)").test(i);)s+="`";for(/[^ \r\n]/.test(i)&&(/^[ \r\n]/.test(i)&&/[ \r\n]$/.test(i)||/^`|`$/.test(i))&&(i=" "+i+" ");++u<l.unsafe.length;){const c=l.unsafe[u],d=l.compilePattern(c);let p;if(c.atBreak)for(;p=d.exec(i);){let m=p.index;i.charCodeAt(m)===10&&i.charCodeAt(m-1)===13&&m--,i=i.slice(0,m)+" "+i.slice(p.index+1)}}return s+i+s}function V4(){return"`"}function e1(t,r){const l=Dd(t);return!!(!r.options.resourceLink&&t.url&&!t.title&&t.children&&t.children.length===1&&t.children[0].type==="text"&&(l===t.url||"mailto:"+l===t.url)&&/^[a-z][a-z+.-]+:/i.test(t.url)&&!/[\0- <>\u007F]/.test(t.url))}t1.peek=$4;function t1(t,r,l,i){const s=qd(l),u=s==='"'?"Quote":"Apostrophe",c=l.createTracker(i);let d,p;if(e1(t,l)){const x=l.stack;l.stack=[],d=l.enter("autolink");let y=c.move("<");return y+=c.move(l.containerPhrasing(t,{before:y,after:">",...c.current()})),y+=c.move(">"),d(),l.stack=x,y}d=l.enter("link"),p=l.enter("label");let m=c.move("[");return m+=c.move(l.containerPhrasing(t,{before:m,after:"](",...c.current()})),m+=c.move("]("),p(),!t.url&&t.title||/[\0- \u007F]/.test(t.url)?(p=l.enter("destinationLiteral"),m+=c.move("<"),m+=c.move(l.safe(t.url,{before:m,after:">",...c.current()})),m+=c.move(">")):(p=l.enter("destinationRaw"),m+=c.move(l.safe(t.url,{before:m,after:t.title?" ":")",...c.current()}))),p(),t.title&&(p=l.enter(`title${u}`),m+=c.move(" "+s),m+=c.move(l.safe(t.title,{before:m,after:s,...c.current()})),m+=c.move(s),p()),m+=c.move(")"),d(),m}function $4(t,r,l){return e1(t,l)?"<":"["}n1.peek=F4;function n1(t,r,l,i){const s=t.referenceType,u=l.enter("linkReference");let c=l.enter("label");const d=l.createTracker(i);let p=d.move("[");const m=l.containerPhrasing(t,{before:p,after:"]",...d.current()});p+=d.move(m+"]["),c();const x=l.stack;l.stack=[],c=l.enter("reference");const y=l.safe(l.associationId(t),{before:p,after:"]",...d.current()});return c(),l.stack=x,u(),s==="full"||!m||m!==y?p+=d.move(y+"]"):s==="shortcut"?p=p.slice(0,-1):p+=d.move("]"),p}function F4(){return"["}function Id(t){const r=t.options.bullet||"*";if(r!=="*"&&r!=="+"&&r!=="-")throw new Error("Cannot serialize items with `"+r+"` for `options.bullet`, expected `*`, `+`, or `-`");return r}function Y4(t){const r=Id(t),l=t.options.bulletOther;if(!l)return r==="*"?"-":"*";if(l!=="*"&&l!=="+"&&l!=="-")throw new Error("Cannot serialize items with `"+l+"` for `options.bulletOther`, expected `*`, `+`, or `-`");if(l===r)throw new Error("Expected `bullet` (`"+r+"`) and `bulletOther` (`"+l+"`) to be different");return l}function G4(t){const r=t.options.bulletOrdered||".";if(r!=="."&&r!==")")throw new Error("Cannot serialize items with `"+r+"` for `options.bulletOrdered`, expected `.` or `)`");return r}function r1(t){const r=t.options.rule||"*";if(r!=="*"&&r!=="-"&&r!=="_")throw new Error("Cannot serialize rules with `"+r+"` for `options.rule`, expected `*`, `-`, or `_`");return r}function P4(t,r,l,i){const s=l.enter("list"),u=l.bulletCurrent;let c=t.ordered?G4(l):Id(l);const d=t.ordered?c==="."?")":".":Y4(l);let p=r&&l.bulletLastUsed?c===l.bulletLastUsed:!1;if(!t.ordered){const x=t.children?t.children[0]:void 0;if((c==="*"||c==="-")&&x&&(!x.children||!x.children[0])&&l.stack[l.stack.length-1]==="list"&&l.stack[l.stack.length-2]==="listItem"&&l.stack[l.stack.length-3]==="list"&&l.stack[l.stack.length-4]==="listItem"&&l.indexStack[l.indexStack.length-1]===0&&l.indexStack[l.indexStack.length-2]===0&&l.indexStack[l.indexStack.length-3]===0&&(p=!0),r1(l)===c&&x){let y=-1;for(;++y<t.children.length;){const b=t.children[y];if(b&&b.type==="listItem"&&b.children&&b.children[0]&&b.children[0].type==="thematicBreak"){p=!0;break}}}}p&&(c=d),l.bulletCurrent=c;const m=l.containerFlow(t,i);return l.bulletLastUsed=c,l.bulletCurrent=u,s(),m}function X4(t){const r=t.options.listItemIndent||"one";if(r!=="tab"&&r!=="one"&&r!=="mixed")throw new Error("Cannot serialize items with `"+r+"` for `options.listItemIndent`, expected `tab`, `one`, or `mixed`");return r}function Q4(t,r,l,i){const s=X4(l);let u=l.bulletCurrent||Id(l);r&&r.type==="list"&&r.ordered&&(u=(typeof r.start=="number"&&r.start>-1?r.start:1)+(l.options.incrementListMarker===!1?0:r.children.indexOf(t))+u);let c=u.length+1;(s==="tab"||s==="mixed"&&(r&&r.type==="list"&&r.spread||t.spread))&&(c=Math.ceil(c/4)*4);const d=l.createTracker(i);d.move(u+" ".repeat(c-u.length)),d.shift(c);const p=l.enter("listItem"),m=l.indentLines(l.containerFlow(t,d.current()),x);return p(),m;function x(y,b,S){return b?(S?"":" ".repeat(c))+y:(S?u:u+" ".repeat(c-u.length))+y}}function K4(t,r,l,i){const s=l.enter("paragraph"),u=l.enter("phrasing"),c=l.containerPhrasing(t,i);return u(),s(),c}const Z4=Os(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function J4(t,r,l,i){return(t.children.some(function(c){return Z4(c)})?l.containerPhrasing:l.containerFlow).call(l,t,i)}function W4(t){const r=t.options.strong||"*";if(r!=="*"&&r!=="_")throw new Error("Cannot serialize strong with `"+r+"` for `options.strong`, expected `*`, or `_`");return r}l1.peek=e3;function l1(t,r,l,i){const s=W4(l),u=l.enter("strong"),c=l.createTracker(i),d=c.move(s+s);let p=c.move(l.containerPhrasing(t,{after:s,before:d,...c.current()}));const m=p.charCodeAt(0),x=Cs(i.before.charCodeAt(i.before.length-1),m,s);x.inside&&(p=Di(m)+p.slice(1));const y=p.charCodeAt(p.length-1),b=Cs(i.after.charCodeAt(0),y,s);b.inside&&(p=p.slice(0,-1)+Di(y));const S=c.move(s+s);return u(),l.attentionEncodeSurroundingInfo={after:b.outside,before:x.outside},d+p+S}function e3(t,r,l){return l.options.strong||"*"}function t3(t,r,l,i){return l.safe(t.value,i)}function n3(t){const r=t.options.ruleRepetition||3;if(r<3)throw new Error("Cannot serialize rules with repetition `"+r+"` for `options.ruleRepetition`, expected `3` or more");return r}function r3(t,r,l){const i=(r1(l)+(l.options.ruleSpaces?" ":"")).repeat(n3(l));return l.options.ruleSpaces?i.slice(0,-1):i}const a1={blockquote:E4,break:tx,code:R4,definition:O4,emphasis:Q0,hardBreak:tx,heading:B4,html:K0,image:Z0,imageReference:J0,inlineCode:W0,link:t1,linkReference:n1,list:P4,listItem:Q4,paragraph:K4,root:J4,strong:l1,text:t3,thematicBreak:r3};function l3(){return{enter:{table:a3,tableData:nx,tableHeader:nx,tableRow:o3},exit:{codeText:s3,table:i3,tableData:kf,tableHeader:kf,tableRow:kf}}}function a3(t){const r=t._align;this.enter({type:"table",align:r.map(function(l){return l==="none"?null:l}),children:[]},t),this.data.inTable=!0}function i3(t){this.exit(t),this.data.inTable=void 0}function o3(t){this.enter({type:"tableRow",children:[]},t)}function kf(t){this.exit(t)}function nx(t){this.enter({type:"tableCell",children:[]},t)}function s3(t){let r=this.resume();this.data.inTable&&(r=r.replace(/\\([\\|])/g,u3));const l=this.stack[this.stack.length-1];l.type,l.value=r,this.exit(t)}function u3(t,r){return r==="|"?r:t}function c3(t){const r=t||{},l=r.tableCellPadding,i=r.tablePipeAlign,s=r.stringLength,u=l?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:`
|
|
541
|
-
`,inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[ :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{inlineCode:b,table:c,tableCell:p,tableRow:d}};function c(S,k,N,A){return m(x(S,N,A),S.align)}function d(S,k,N,A){const j=y(S,N,A),M=m([j]);return M.slice(0,M.indexOf(`
|
|
542
|
-
`))}function p(S,k,N,A){const j=N.enter("tableCell"),M=N.enter("phrasing"),z=N.containerPhrasing(S,{...A,before:u,after:u});return M(),j(),z}function m(S,k){return C4(S,{align:k,alignDelimiters:i,padding:l,stringLength:s})}function x(S,k,N){const A=S.children;let j=-1;const M=[],z=k.enter("table");for(;++j<A.length;)M[j]=y(A[j],k,N);return z(),M}function y(S,k,N){const A=S.children;let j=-1;const M=[],z=k.enter("tableRow");for(;++j<A.length;)M[j]=p(A[j],S,k,N);return z(),M}function b(S,k,N){let A=a1.inlineCode(S,k,N);return N.stack.includes("tableCell")&&(A=A.replace(/\|/g,"\\$&")),A}}function f3(){return{exit:{taskListCheckValueChecked:rx,taskListCheckValueUnchecked:rx,paragraph:h3}}}function d3(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:m3}}}function rx(t){const r=this.stack[this.stack.length-2];r.type,r.checked=t.type==="taskListCheckValueChecked"}function h3(t){const r=this.stack[this.stack.length-2];if(r&&r.type==="listItem"&&typeof r.checked=="boolean"){const l=this.stack[this.stack.length-1];l.type;const i=l.children[0];if(i&&i.type==="text"){const s=r.children;let u=-1,c;for(;++u<s.length;){const d=s[u];if(d.type==="paragraph"){c=d;break}}c===l&&(i.value=i.value.slice(1),i.value.length===0?l.children.shift():l.position&&i.position&&typeof i.position.start.offset=="number"&&(i.position.start.column++,i.position.start.offset++,l.position.start=Object.assign({},i.position.start)))}}this.exit(t)}function m3(t,r,l,i){const s=t.children[0],u=typeof t.checked=="boolean"&&s&&s.type==="paragraph",c="["+(t.checked?"x":" ")+"] ",d=l.createTracker(i);u&&d.move(c);let p=a1.listItem(t,r,l,{...i,...d.current()});return u&&(p=p.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,m)),p;function m(x){return x+c}}function p3(){return[Pj(),m4(),x4(),l3(),f3()]}function g3(t){return{extensions:[Xj(),p4(t),b4(),c3(t),d3()]}}const y3={tokenize:k3,partial:!0},i1={tokenize:C3,partial:!0},o1={tokenize:N3,partial:!0},s1={tokenize:E3,partial:!0},x3={tokenize:j3,partial:!0},u1={name:"wwwAutolink",tokenize:S3,previous:f1},c1={name:"protocolAutolink",tokenize:w3,previous:d1},ur={name:"emailAutolink",tokenize:v3,previous:h1},Vn={};function b3(){return{text:Vn}}let ul=48;for(;ul<123;)Vn[ul]=ur,ul++,ul===58?ul=65:ul===91&&(ul=97);Vn[43]=ur;Vn[45]=ur;Vn[46]=ur;Vn[95]=ur;Vn[72]=[ur,c1];Vn[104]=[ur,c1];Vn[87]=[ur,u1];Vn[119]=[ur,u1];function v3(t,r,l){const i=this;let s,u;return c;function c(y){return!Wf(y)||!h1.call(i,i.previous)||Vd(i.events)?l(y):(t.enter("literalAutolink"),t.enter("literalAutolinkEmail"),d(y))}function d(y){return Wf(y)?(t.consume(y),d):y===64?(t.consume(y),p):l(y)}function p(y){return y===46?t.check(x3,x,m)(y):y===45||y===95||qt(y)?(u=!0,t.consume(y),p):x(y)}function m(y){return t.consume(y),s=!0,p}function x(y){return u&&s&&Gt(i.previous)?(t.exit("literalAutolinkEmail"),t.exit("literalAutolink"),r(y)):l(y)}}function S3(t,r,l){const i=this;return s;function s(c){return c!==87&&c!==119||!f1.call(i,i.previous)||Vd(i.events)?l(c):(t.enter("literalAutolink"),t.enter("literalAutolinkWww"),t.check(y3,t.attempt(i1,t.attempt(o1,u),l),l)(c))}function u(c){return t.exit("literalAutolinkWww"),t.exit("literalAutolink"),r(c)}}function w3(t,r,l){const i=this;let s="",u=!1;return c;function c(y){return(y===72||y===104)&&d1.call(i,i.previous)&&!Vd(i.events)?(t.enter("literalAutolink"),t.enter("literalAutolinkHttp"),s+=String.fromCodePoint(y),t.consume(y),d):l(y)}function d(y){if(Gt(y)&&s.length<5)return s+=String.fromCodePoint(y),t.consume(y),d;if(y===58){const b=s.toLowerCase();if(b==="http"||b==="https")return t.consume(y),p}return l(y)}function p(y){return y===47?(t.consume(y),u?m:(u=!0,p)):l(y)}function m(y){return y===null||Ss(y)||lt(y)||ml(y)||Ds(y)?l(y):t.attempt(i1,t.attempt(o1,x),l)(y)}function x(y){return t.exit("literalAutolinkHttp"),t.exit("literalAutolink"),r(y)}}function k3(t,r,l){let i=0;return s;function s(c){return(c===87||c===119)&&i<3?(i++,t.consume(c),s):c===46&&i===3?(t.consume(c),u):l(c)}function u(c){return c===null?l(c):r(c)}}function C3(t,r,l){let i,s,u;return c;function c(m){return m===46||m===95?t.check(s1,p,d)(m):m===null||lt(m)||ml(m)||m!==45&&Ds(m)?p(m):(u=!0,t.consume(m),c)}function d(m){return m===95?i=!0:(s=i,i=void 0),t.consume(m),c}function p(m){return s||i||!u?l(m):r(m)}}function N3(t,r){let l=0,i=0;return s;function s(c){return c===40?(l++,t.consume(c),s):c===41&&i<l?u(c):c===33||c===34||c===38||c===39||c===41||c===42||c===44||c===46||c===58||c===59||c===60||c===63||c===93||c===95||c===126?t.check(s1,r,u)(c):c===null||lt(c)||ml(c)?r(c):(t.consume(c),s)}function u(c){return c===41&&i++,t.consume(c),s}}function E3(t,r,l){return i;function i(d){return d===33||d===34||d===39||d===41||d===42||d===44||d===46||d===58||d===59||d===63||d===95||d===126?(t.consume(d),i):d===38?(t.consume(d),u):d===93?(t.consume(d),s):d===60||d===null||lt(d)||ml(d)?r(d):l(d)}function s(d){return d===null||d===40||d===91||lt(d)||ml(d)?r(d):i(d)}function u(d){return Gt(d)?c(d):l(d)}function c(d){return d===59?(t.consume(d),i):Gt(d)?(t.consume(d),c):l(d)}}function j3(t,r,l){return i;function i(u){return t.consume(u),s}function s(u){return qt(u)?l(u):r(u)}}function f1(t){return t===null||t===40||t===42||t===95||t===91||t===93||t===126||lt(t)}function d1(t){return!Gt(t)}function h1(t){return!(t===47||Wf(t))}function Wf(t){return t===43||t===45||t===46||t===95||qt(t)}function Vd(t){let r=t.length,l=!1;for(;r--;){const i=t[r][1];if((i.type==="labelLink"||i.type==="labelImage")&&!i._balanced){l=!0;break}if(i._gfmAutolinkLiteralWalkedInto){l=!1;break}}return t.length>0&&!l&&(t[t.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),l}const T3={tokenize:L3,partial:!0};function A3(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:z3,continuation:{tokenize:O3},exit:_3}},text:{91:{name:"gfmFootnoteCall",tokenize:R3},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:M3,resolveTo:D3}}}}function M3(t,r,l){const i=this;let s=i.events.length;const u=i.parser.gfmFootnotes||(i.parser.gfmFootnotes=[]);let c;for(;s--;){const p=i.events[s][1];if(p.type==="labelImage"){c=p;break}if(p.type==="gfmFootnoteCall"||p.type==="labelLink"||p.type==="label"||p.type==="image"||p.type==="link")break}return d;function d(p){if(!c||!c._balanced)return l(p);const m=Dn(i.sliceSerialize({start:c.end,end:i.now()}));return m.codePointAt(0)!==94||!u.includes(m.slice(1))?l(p):(t.enter("gfmFootnoteCallLabelMarker"),t.consume(p),t.exit("gfmFootnoteCallLabelMarker"),r(p))}}function D3(t,r){let l=t.length;for(;l--;)if(t[l][1].type==="labelImage"&&t[l][0]==="enter"){t[l][1];break}t[l+1][1].type="data",t[l+3][1].type="gfmFootnoteCallLabelMarker";const i={type:"gfmFootnoteCall",start:Object.assign({},t[l+3][1].start),end:Object.assign({},t[t.length-1][1].end)},s={type:"gfmFootnoteCallMarker",start:Object.assign({},t[l+3][1].end),end:Object.assign({},t[l+3][1].end)};s.end.column++,s.end.offset++,s.end._bufferIndex++;const u={type:"gfmFootnoteCallString",start:Object.assign({},s.end),end:Object.assign({},t[t.length-1][1].start)},c={type:"chunkString",contentType:"string",start:Object.assign({},u.start),end:Object.assign({},u.end)},d=[t[l+1],t[l+2],["enter",i,r],t[l+3],t[l+4],["enter",s,r],["exit",s,r],["enter",u,r],["enter",c,r],["exit",c,r],["exit",u,r],t[t.length-2],t[t.length-1],["exit",i,r]];return t.splice(l,t.length-l+1,...d),t}function R3(t,r,l){const i=this,s=i.parser.gfmFootnotes||(i.parser.gfmFootnotes=[]);let u=0,c;return d;function d(y){return t.enter("gfmFootnoteCall"),t.enter("gfmFootnoteCallLabelMarker"),t.consume(y),t.exit("gfmFootnoteCallLabelMarker"),p}function p(y){return y!==94?l(y):(t.enter("gfmFootnoteCallMarker"),t.consume(y),t.exit("gfmFootnoteCallMarker"),t.enter("gfmFootnoteCallString"),t.enter("chunkString").contentType="string",m)}function m(y){if(u>999||y===93&&!c||y===null||y===91||lt(y))return l(y);if(y===93){t.exit("chunkString");const b=t.exit("gfmFootnoteCallString");return s.includes(Dn(i.sliceSerialize(b)))?(t.enter("gfmFootnoteCallLabelMarker"),t.consume(y),t.exit("gfmFootnoteCallLabelMarker"),t.exit("gfmFootnoteCall"),r):l(y)}return lt(y)||(c=!0),u++,t.consume(y),y===92?x:m}function x(y){return y===91||y===92||y===93?(t.consume(y),u++,m):m(y)}}function z3(t,r,l){const i=this,s=i.parser.gfmFootnotes||(i.parser.gfmFootnotes=[]);let u,c=0,d;return p;function p(k){return t.enter("gfmFootnoteDefinition")._container=!0,t.enter("gfmFootnoteDefinitionLabel"),t.enter("gfmFootnoteDefinitionLabelMarker"),t.consume(k),t.exit("gfmFootnoteDefinitionLabelMarker"),m}function m(k){return k===94?(t.enter("gfmFootnoteDefinitionMarker"),t.consume(k),t.exit("gfmFootnoteDefinitionMarker"),t.enter("gfmFootnoteDefinitionLabelString"),t.enter("chunkString").contentType="string",x):l(k)}function x(k){if(c>999||k===93&&!d||k===null||k===91||lt(k))return l(k);if(k===93){t.exit("chunkString");const N=t.exit("gfmFootnoteDefinitionLabelString");return u=Dn(i.sliceSerialize(N)),t.enter("gfmFootnoteDefinitionLabelMarker"),t.consume(k),t.exit("gfmFootnoteDefinitionLabelMarker"),t.exit("gfmFootnoteDefinitionLabel"),b}return lt(k)||(d=!0),c++,t.consume(k),k===92?y:x}function y(k){return k===91||k===92||k===93?(t.consume(k),c++,x):x(k)}function b(k){return k===58?(t.enter("definitionMarker"),t.consume(k),t.exit("definitionMarker"),s.includes(u)||s.push(u),Pe(t,S,"gfmFootnoteDefinitionWhitespace")):l(k)}function S(k){return r(k)}}function O3(t,r,l){return t.check(Li,r,t.attempt(T3,r,l))}function _3(t){t.exit("gfmFootnoteDefinition")}function L3(t,r,l){const i=this;return Pe(t,s,"gfmFootnoteDefinitionIndent",5);function s(u){const c=i.events[i.events.length-1];return c&&c[1].type==="gfmFootnoteDefinitionIndent"&&c[2].sliceSerialize(c[1],!0).length===4?r(u):l(u)}}function U3(t){let l=(t||{}).singleTilde;const i={name:"strikethrough",tokenize:u,resolveAll:s};return l==null&&(l=!0),{text:{126:i},insideSpan:{null:[i]},attentionMarkers:{null:[126]}};function s(c,d){let p=-1;for(;++p<c.length;)if(c[p][0]==="enter"&&c[p][1].type==="strikethroughSequenceTemporary"&&c[p][1]._close){let m=p;for(;m--;)if(c[m][0]==="exit"&&c[m][1].type==="strikethroughSequenceTemporary"&&c[m][1]._open&&c[p][1].end.offset-c[p][1].start.offset===c[m][1].end.offset-c[m][1].start.offset){c[p][1].type="strikethroughSequence",c[m][1].type="strikethroughSequence";const x={type:"strikethrough",start:Object.assign({},c[m][1].start),end:Object.assign({},c[p][1].end)},y={type:"strikethroughText",start:Object.assign({},c[m][1].end),end:Object.assign({},c[p][1].start)},b=[["enter",x,d],["enter",c[m][1],d],["exit",c[m][1],d],["enter",y,d]],S=d.parser.constructs.insideSpan.null;S&&mn(b,b.length,0,Rs(S,c.slice(m+1,p),d)),mn(b,b.length,0,[["exit",y,d],["enter",c[p][1],d],["exit",c[p][1],d],["exit",x,d]]),mn(c,m-1,p-m+3,b),p=m+b.length-2;break}}for(p=-1;++p<c.length;)c[p][1].type==="strikethroughSequenceTemporary"&&(c[p][1].type="data");return c}function u(c,d,p){const m=this.previous,x=this.events;let y=0;return b;function b(k){return m===126&&x[x.length-1][1].type!=="characterEscape"?p(k):(c.enter("strikethroughSequenceTemporary"),S(k))}function S(k){const N=ya(m);if(k===126)return y>1?p(k):(c.consume(k),y++,S);if(y<2&&!l)return p(k);const A=c.exit("strikethroughSequenceTemporary"),j=ya(k);return A._open=!j||j===2&&!!N,A._close=!N||N===2&&!!j,d(k)}}}class B3{constructor(){this.map=[]}add(r,l,i){H3(this,r,l,i)}consume(r){if(this.map.sort(function(u,c){return u[0]-c[0]}),this.map.length===0)return;let l=this.map.length;const i=[];for(;l>0;)l-=1,i.push(r.slice(this.map[l][0]+this.map[l][1]),this.map[l][2]),r.length=this.map[l][0];i.push(r.slice()),r.length=0;let s=i.pop();for(;s;){for(const u of s)r.push(u);s=i.pop()}this.map.length=0}}function H3(t,r,l,i){let s=0;if(!(l===0&&i.length===0)){for(;s<t.map.length;){if(t.map[s][0]===r){t.map[s][1]+=l,t.map[s][2].push(...i);return}s+=1}t.map.push([r,l,i])}}function q3(t,r){let l=!1;const i=[];for(;r<t.length;){const s=t[r];if(l){if(s[0]==="enter")s[1].type==="tableContent"&&i.push(t[r+1][1].type==="tableDelimiterMarker"?"left":"none");else if(s[1].type==="tableContent"){if(t[r-1][1].type==="tableDelimiterMarker"){const u=i.length-1;i[u]=i[u]==="left"?"center":"right"}}else if(s[1].type==="tableDelimiterRow")break}else s[0]==="enter"&&s[1].type==="tableDelimiterRow"&&(l=!0);r+=1}return i}function I3(){return{flow:{null:{name:"table",tokenize:V3,resolveAll:$3}}}}function V3(t,r,l){const i=this;let s=0,u=0,c;return d;function d(L){let P=i.events.length-1;for(;P>-1;){const I=i.events[P][1].type;if(I==="lineEnding"||I==="linePrefix")P--;else break}const X=P>-1?i.events[P][1].type:null,de=X==="tableHead"||X==="tableRow"?B:p;return de===B&&i.parser.lazy[i.now().line]?l(L):de(L)}function p(L){return t.enter("tableHead"),t.enter("tableRow"),m(L)}function m(L){return L===124||(c=!0,u+=1),x(L)}function x(L){return L===null?l(L):Ne(L)?u>1?(u=0,i.interrupt=!0,t.exit("tableRow"),t.enter("lineEnding"),t.consume(L),t.exit("lineEnding"),S):l(L):He(L)?Pe(t,x,"whitespace")(L):(u+=1,c&&(c=!1,s+=1),L===124?(t.enter("tableCellDivider"),t.consume(L),t.exit("tableCellDivider"),c=!0,x):(t.enter("data"),y(L)))}function y(L){return L===null||L===124||lt(L)?(t.exit("data"),x(L)):(t.consume(L),L===92?b:y)}function b(L){return L===92||L===124?(t.consume(L),y):y(L)}function S(L){return i.interrupt=!1,i.parser.lazy[i.now().line]?l(L):(t.enter("tableDelimiterRow"),c=!1,He(L)?Pe(t,k,"linePrefix",i.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(L):k(L))}function k(L){return L===45||L===58?A(L):L===124?(c=!0,t.enter("tableCellDivider"),t.consume(L),t.exit("tableCellDivider"),N):Q(L)}function N(L){return He(L)?Pe(t,A,"whitespace")(L):A(L)}function A(L){return L===58?(u+=1,c=!0,t.enter("tableDelimiterMarker"),t.consume(L),t.exit("tableDelimiterMarker"),j):L===45?(u+=1,j(L)):L===null||Ne(L)?V(L):Q(L)}function j(L){return L===45?(t.enter("tableDelimiterFiller"),M(L)):Q(L)}function M(L){return L===45?(t.consume(L),M):L===58?(c=!0,t.exit("tableDelimiterFiller"),t.enter("tableDelimiterMarker"),t.consume(L),t.exit("tableDelimiterMarker"),z):(t.exit("tableDelimiterFiller"),z(L))}function z(L){return He(L)?Pe(t,V,"whitespace")(L):V(L)}function V(L){return L===124?k(L):L===null||Ne(L)?!c||s!==u?Q(L):(t.exit("tableDelimiterRow"),t.exit("tableHead"),r(L)):Q(L)}function Q(L){return l(L)}function B(L){return t.enter("tableRow"),G(L)}function G(L){return L===124?(t.enter("tableCellDivider"),t.consume(L),t.exit("tableCellDivider"),G):L===null||Ne(L)?(t.exit("tableRow"),r(L)):He(L)?Pe(t,G,"whitespace")(L):(t.enter("data"),ae(L))}function ae(L){return L===null||L===124||lt(L)?(t.exit("data"),G(L)):(t.consume(L),L===92?se:ae)}function se(L){return L===92||L===124?(t.consume(L),ae):ae(L)}}function $3(t,r){let l=-1,i=!0,s=0,u=[0,0,0,0],c=[0,0,0,0],d=!1,p=0,m,x,y;const b=new B3;for(;++l<t.length;){const S=t[l],k=S[1];S[0]==="enter"?k.type==="tableHead"?(d=!1,p!==0&&(lx(b,r,p,m,x),x=void 0,p=0),m={type:"table",start:Object.assign({},k.start),end:Object.assign({},k.end)},b.add(l,0,[["enter",m,r]])):k.type==="tableRow"||k.type==="tableDelimiterRow"?(i=!0,y=void 0,u=[0,0,0,0],c=[0,l+1,0,0],d&&(d=!1,x={type:"tableBody",start:Object.assign({},k.start),end:Object.assign({},k.end)},b.add(l,0,[["enter",x,r]])),s=k.type==="tableDelimiterRow"?2:x?3:1):s&&(k.type==="data"||k.type==="tableDelimiterMarker"||k.type==="tableDelimiterFiller")?(i=!1,c[2]===0&&(u[1]!==0&&(c[0]=c[1],y=ss(b,r,u,s,void 0,y),u=[0,0,0,0]),c[2]=l)):k.type==="tableCellDivider"&&(i?i=!1:(u[1]!==0&&(c[0]=c[1],y=ss(b,r,u,s,void 0,y)),u=c,c=[u[1],l,0,0])):k.type==="tableHead"?(d=!0,p=l):k.type==="tableRow"||k.type==="tableDelimiterRow"?(p=l,u[1]!==0?(c[0]=c[1],y=ss(b,r,u,s,l,y)):c[1]!==0&&(y=ss(b,r,c,s,l,y)),s=0):s&&(k.type==="data"||k.type==="tableDelimiterMarker"||k.type==="tableDelimiterFiller")&&(c[3]=l)}for(p!==0&&lx(b,r,p,m,x),b.consume(r.events),l=-1;++l<r.events.length;){const S=r.events[l];S[0]==="enter"&&S[1].type==="table"&&(S[1]._align=q3(r.events,l))}return t}function ss(t,r,l,i,s,u){const c=i===1?"tableHeader":i===2?"tableDelimiter":"tableData",d="tableContent";l[0]!==0&&(u.end=Object.assign({},sa(r.events,l[0])),t.add(l[0],0,[["exit",u,r]]));const p=sa(r.events,l[1]);if(u={type:c,start:Object.assign({},p),end:Object.assign({},p)},t.add(l[1],0,[["enter",u,r]]),l[2]!==0){const m=sa(r.events,l[2]),x=sa(r.events,l[3]),y={type:d,start:Object.assign({},m),end:Object.assign({},x)};if(t.add(l[2],0,[["enter",y,r]]),i!==2){const b=r.events[l[2]],S=r.events[l[3]];if(b[1].end=Object.assign({},S[1].end),b[1].type="chunkText",b[1].contentType="text",l[3]>l[2]+1){const k=l[2]+1,N=l[3]-l[2]-1;t.add(k,N,[])}}t.add(l[3]+1,0,[["exit",y,r]])}return s!==void 0&&(u.end=Object.assign({},sa(r.events,s)),t.add(s,0,[["exit",u,r]]),u=void 0),u}function lx(t,r,l,i,s){const u=[],c=sa(r.events,l);s&&(s.end=Object.assign({},c),u.push(["exit",s,r])),i.end=Object.assign({},c),u.push(["exit",i,r]),t.add(l+1,0,u)}function sa(t,r){const l=t[r],i=l[0]==="enter"?"start":"end";return l[1][i]}const F3={name:"tasklistCheck",tokenize:G3};function Y3(){return{text:{91:F3}}}function G3(t,r,l){const i=this;return s;function s(p){return i.previous!==null||!i._gfmTasklistFirstContentOfListItem?l(p):(t.enter("taskListCheck"),t.enter("taskListCheckMarker"),t.consume(p),t.exit("taskListCheckMarker"),u)}function u(p){return lt(p)?(t.enter("taskListCheckValueUnchecked"),t.consume(p),t.exit("taskListCheckValueUnchecked"),c):p===88||p===120?(t.enter("taskListCheckValueChecked"),t.consume(p),t.exit("taskListCheckValueChecked"),c):l(p)}function c(p){return p===93?(t.enter("taskListCheckMarker"),t.consume(p),t.exit("taskListCheckMarker"),t.exit("taskListCheck"),d):l(p)}function d(p){return Ne(p)?r(p):He(p)?t.check({tokenize:P3},r,l)(p):l(p)}}function P3(t,r,l){return Pe(t,i,"whitespace");function i(s){return s===null?l(s):r(s)}}function X3(t){return C0([b3(),A3(),U3(t),I3(),Y3()])}const Q3={};function K3(t){const r=this,l=t||Q3,i=r.data(),s=i.micromarkExtensions||(i.micromarkExtensions=[]),u=i.fromMarkdownExtensions||(i.fromMarkdownExtensions=[]),c=i.toMarkdownExtensions||(i.toMarkdownExtensions=[]);s.push(X3(l)),u.push(p3()),c.push(g3(l))}function m1({oldText:t,newText:r,caption:l}){const i=w.useMemo(()=>Z3(t,r),[t,r]);if(i===null)return h.jsx("div",{className:"text-xs text-muted-foreground italic px-3 py-2",children:"Diff omitted (file too large to render inline)."});const s=i.filter(c=>c.kind==="add").length,u=i.filter(c=>c.kind==="del").length;return h.jsxs("div",{className:"rounded-lg border bg-background/40 overflow-hidden text-xs",children:[h.jsxs("div",{className:"flex items-center justify-between px-3 py-1.5 border-b bg-muted/40",children:[h.jsx("span",{className:"font-mono text-muted-foreground truncate",children:l??"diff"}),h.jsxs("span",{className:"font-mono shrink-0",children:[h.jsxs("span",{className:"text-emerald-600 dark:text-emerald-400",children:["+",s]}),h.jsx("span",{className:"text-muted-foreground mx-1",children:"·"}),h.jsxs("span",{className:"text-rose-600 dark:text-rose-400",children:["-",u]})]})]}),h.jsx("div",{className:"font-mono leading-relaxed max-h-96 overflow-auto",children:i.map((c,d)=>h.jsxs("div",{className:he("flex",c.kind==="add"&&"bg-emerald-500/10",c.kind==="del"&&"bg-rose-500/10"),children:[h.jsx("span",{className:he("w-6 shrink-0 text-center select-none",c.kind==="add"&&"text-emerald-600 dark:text-emerald-400",c.kind==="del"&&"text-rose-600 dark:text-rose-400",c.kind==="ctx"&&"text-muted-foreground/40"),children:c.kind==="add"?"+":c.kind==="del"?"-":" "}),h.jsx("pre",{className:he("whitespace-pre-wrap break-all flex-1 px-2",c.kind==="ctx"&&"text-muted-foreground/70"),children:c.text||" "})]},d))})]})}const ax=5e3;function Z3(t,r){const l=t.split(`
|
|
543
|
-
`),i=r.split(`
|
|
544
|
-
`);if(l.length>ax||i.length>ax)return null;const s=l.length,u=i.length,c=Array.from({length:s+1},()=>new Array(u+1).fill(0));for(let x=s-1;x>=0;x--)for(let y=u-1;y>=0;y--)l[x]===i[y]?c[x][y]=c[x+1][y+1]+1:c[x][y]=Math.max(c[x+1][y],c[x][y+1]);const d=[];let p=0,m=0;for(;p<s&&m<u;)l[p]===i[m]?(d.push({kind:"ctx",text:l[p]}),p++,m++):c[p+1][m]>=c[p][m+1]?(d.push({kind:"del",text:l[p]}),p++):(d.push({kind:"add",text:i[m]}),m++);for(;p<s;)d.push({kind:"del",text:l[p++]});for(;m<u;)d.push({kind:"add",text:i[m++]});return d}function p1(t,r){if(!t||typeof r!="object"||r===null)return null;const l=r,i=String(l.file_path??l.path??"");switch(t){case"edit":case"str_replace":case"edit_file":{const s=typeof l.old_string=="string"?l.old_string:"",u=typeof l.new_string=="string"?l.new_string:"";return!s&&!u?null:{oldText:s,newText:u,caption:`edit ${i}`}}case"write":case"write_file":case"create_file":return{oldText:"",newText:typeof l.content=="string"?l.content:"",caption:`write ${i} (new)`};default:return null}}const J3=25,Cf=12;function Nf({text:t,isError:r,className:l,wrapClass:i,showLineNumbers:s}){const u=w.useMemo(()=>t.split(`
|
|
545
|
-
`),[t]),c=u.length>J3,[d,p]=w.useState(!c),m=d?t:u.slice(0,Cf).join(`
|
|
546
|
-
`),x=!!s&&c&&d;return h.jsxs("div",{className:he("rounded-md border bg-background/40 overflow-hidden",l),children:[x?h.jsxs("div",{className:"flex max-h-96 overflow-auto",children:[h.jsx("pre",{"aria-hidden":!0,className:"text-xs font-mono leading-[1.4] py-2 pl-2 pr-2 text-muted-foreground/50 select-none border-r border-border/40 bg-muted/20 tabular-nums text-right whitespace-pre shrink-0",children:u.map((y,b)=>`${b+1}`).join(`
|
|
547
|
-
`)}),h.jsx("pre",{className:he("text-xs font-mono leading-[1.4] py-2 px-2 flex-1 whitespace-pre",r?"text-destructive":"text-foreground"),children:m})]}):h.jsx("pre",{className:he("text-xs font-mono p-2 max-h-96 overflow-auto",i,r?"text-destructive":"text-foreground"),children:m}),c&&h.jsx("button",{type:"button",onClick:()=>p(y=>!y),className:"w-full flex items-center justify-center gap-1 px-2 py-1 border-t bg-muted/30 text-[11px] text-muted-foreground hover:text-foreground transition-colors",children:d?h.jsxs(h.Fragment,{children:[h.jsx(p2,{className:"h-3 w-3"}),"Collapse to first ",Cf," lines"]}):h.jsxs(h.Fragment,{children:[h.jsx(m2,{className:"h-3 w-3"}),"Show all ",u.length," lines (",u.length-Cf," more)"]})})]})}function W3({toolName:t,result:r,isError:l,className:i}){const s=w.useMemo(()=>eT(t,r),[t,r]);return s.kind==="json"?h.jsx(tT,{value:s.value,isError:l,className:i}):s.kind==="numbered"?h.jsx(Nf,{text:r,isError:l,className:i,wrapClass:"whitespace-pre"}):s.kind==="bash"?h.jsxs("div",{className:he("rounded-md border bg-background/40 overflow-hidden",i),children:[s.stdout&&h.jsx(Nf,{text:s.stdout,isError:l,className:"border-0 rounded-none bg-transparent",wrapClass:"whitespace-pre-wrap break-all",showLineNumbers:!0}),(s.exitCode!==void 0||s.duration)&&h.jsxs("div",{className:he("flex items-center gap-3 text-[11px] px-2 py-1 border-t bg-muted/30 tabular-nums",s.exitCode&&s.exitCode!==0?"text-destructive":"text-muted-foreground"),children:[s.exitCode!==void 0&&h.jsxs("span",{children:["exit code: ",h.jsx("span",{className:"font-mono",children:s.exitCode})]}),s.duration&&h.jsx("span",{children:s.duration})]})]}):h.jsx(Nf,{text:r,isError:l,className:i,wrapClass:"whitespace-pre-wrap break-all",showLineNumbers:!0})}function eT(t,r){const l=r.trim();if(/^\s*\d+→/m.test(r.slice(0,200)))return{kind:"numbered"};if(l.startsWith("{")&&l.endsWith("}")||l.startsWith("[")&&l.endsWith("]"))try{const c=JSON.parse(l);if(typeof c=="object"&&c!==null)return{kind:"json",value:c}}catch{}const i=!!t&&/^(bash|shell|exec|run)/i.test(t),s=r.match(/(?:^|\n)\s*(?:\[?exit(?:\s*code)?\]?\s*[:=]?\s*)(\d+)\s*$/i),u=r.match(/(?:^|\s)(\d+\s*ms|\d+\.\d+s)\s*$/i);if(i||s){let c=r;return s&&(c=r.slice(0,s.index).trimEnd()),{kind:"bash",stdout:c,exitCode:s?Number(s[1]):void 0,duration:u==null?void 0:u[1]}}return{kind:"plain"}}function tT({value:t,isError:r,className:l}){const i=w.useMemo(()=>{try{return JSON.stringify(t,null,2)}catch{return String(t)}},[t]),s=i.split(`
|
|
548
|
-
`).length,[u,c]=w.useState(s<30);return h.jsxs("div",{className:he("rounded-md border bg-background/40 overflow-hidden",r&&"border-destructive/40",l),children:[h.jsxs("button",{type:"button",onClick:()=>c(d=>!d),className:"w-full flex items-center justify-between px-2 py-1 border-b bg-muted/30 text-[11px] text-muted-foreground hover:text-foreground",children:[h.jsxs("span",{className:"flex items-center gap-1",children:[u?h.jsx(Ms,{className:"h-3 w-3"}):h.jsx(pd,{className:"h-3 w-3"}),h.jsxs("span",{className:"font-mono",children:["JSON · ",s," lines"]})]}),h.jsx("span",{children:u?"collapse":"expand"})]}),u&&h.jsx("pre",{className:he("text-xs font-mono whitespace-pre p-2 max-h-96 overflow-auto",r?"text-destructive":"text-foreground"),children:i})]})}const nT=["path","file_path","pattern","command","cmd","url","query","description","content"];function rT(t,r){if(r==null)return"";if(typeof r!="object")return Hr(String(r),120);const l=r,i=(t??"").toLowerCase();if(/^todo(_?write)?$|^todos$/i.test(i)||Array.isArray(l.todos)){const u=l.todos??[];if(Array.isArray(u)){const c=u.filter(m=>m.status==="completed").length,d=u.filter(m=>m.status==="in_progress").length,p=[`${u.length} todo${u.length===1?"":"s"}`];return c>0&&p.push(`${c} done`),d>0&&p.push(`${d} in-progress`),p.join(" · ")}}if(/batch|parallel/.test(i)||Array.isArray(l.tool_uses)||Array.isArray(l.calls)){const u=l.tool_uses??l.calls??l.batch;if(Array.isArray(u)){const c=new Set;for(const m of u)m&&typeof m=="object"&&"name"in m&&c.add(String(m.name));const d=[...c].slice(0,3).join(", "),p=c.size>3?` +${c.size-3}`:"";return`${u.length} sub-tool${u.length===1?"":"s"}${d?` · ${d}${p}`:""}`}}if(/^(edit|str_replace|edit_file|patch)$/.test(i)){const u=Ef(l),c=typeof l.old_string=="string"?l.old_string:"",d=typeof l.new_string=="string"?l.new_string:"",p=c?c.split(`
|
|
549
|
-
`).length:0,m=d?d.split(`
|
|
550
|
-
`).length:0;return`edit ${u||"(file)"}${p||m?` (${p} → ${m} lines)`:""}`}if(/^(write|write_file|create_file|new_file)$/.test(i)){const u=Ef(l),c=typeof l.content=="string"?l.content:"",d=c?c.split(`
|
|
551
|
-
`).length:0;return`write ${u||"(file)"}${d?` · ${d} lines`:""}`}if(/^(bash|shell|exec|run|run_command|run_shell)$/.test(i)){const u=l.command??l.cmd??l.script;if(typeof u=="string")return`$ ${Hr(u,110)}`}if(/^(fetch|http|web|webfetch|curl|request)$/.test(i)){const u=l.url;if(typeof u=="string")return`${(l.method??"GET").toUpperCase()} ${Hr(u,100)}`}if(/^(grep|search|ripgrep)$/.test(i)){const u=l.pattern,c=l.path??l.glob??l.type;if(typeof u=="string")return c?`grep ${Hr(u,60)} in ${c}`:`grep ${Hr(u,100)}`}if(/^(glob|find)$/.test(i)){const u=l.pattern??l.glob;if(typeof u=="string")return`glob ${Hr(u,100)}`}if(/^(read|read_file|cat)$/.test(i)){const u=Ef(l),c=l.offset,d=l.limit;if(u&&(typeof c=="number"||typeof d=="number")){const p=c??0,m=typeof d=="number"?p+d:"";return`read ${u} (${p}…${m})`}if(u)return`read ${u}`}for(const u of nT){const c=l[u];if(typeof c=="string"&&c.length>0)return`${u}: ${Hr(c,100)}`}const s=lT(r);return Hr(s,120)}function Hr(t,r){return t.length>r?`${t.slice(0,r-1)}…`:t}function Ef(t){const r=t.file_path??t.path??t.filepath;return typeof r=="string"?r:""}function lT(t){try{return JSON.stringify(t)}catch{return String(t)}}async function aT(t){var r;try{if(typeof navigator<"u"&&((r=navigator.clipboard)!=null&&r.writeText))return await navigator.clipboard.writeText(t),!0}catch{}try{const l=document.createElement("textarea");l.value=t,l.style.position="fixed",l.style.opacity="0",document.body.appendChild(l),l.select();const i=document.execCommand("copy");return document.body.removeChild(l),i}catch{return!1}}const iT={code({inline:t,className:r,children:l,...i}){const s=/language-(\w+)/.exec(r??""),u=String(l??"").replace(/\n$/,"");return t||!s?h.jsx("code",{className:he("rounded bg-muted/60 px-1.5 py-0.5 text-[0.85em] font-mono",r),...i,children:l}):h.jsxs("div",{className:"not-prose relative my-3 rounded-lg border bg-muted/30 overflow-hidden",children:[h.jsxs("div",{className:"flex items-center justify-between px-3 py-1.5 border-b bg-muted/40 text-xs",children:[h.jsx("span",{className:"font-mono text-muted-foreground",children:s[1]}),h.jsx(ed,{text:u,label:""})]}),h.jsx("pre",{className:"overflow-x-auto p-3 text-xs leading-relaxed font-mono max-h-[40rem]",children:h.jsx("code",{children:u})})]})}};function ed({text:t,className:r,label:l="Copy"}){const[i,s]=w.useState(!1);return h.jsx("button",{type:"button",onClick:async u=>{u.stopPropagation(),await aT(t)&&(s(!0),setTimeout(()=>s(!1),1400))},className:he("inline-flex items-center gap-1 text-xs text-muted-foreground hover:text-foreground transition-colors",r),title:l,children:i?h.jsxs(h.Fragment,{children:[h.jsx(Zx,{className:"h-3 w-3 text-green-500"}),h.jsx("span",{children:"Copied"})]}):h.jsxs(h.Fragment,{children:[h.jsx(v2,{className:"h-3 w-3"}),h.jsx("span",{children:l})]})})}function oT(t,r){if(typeof document>"u")return;const l=new Blob([r],{type:"text/plain;charset=utf-8"}),i=URL.createObjectURL(l),s=document.createElement("a");s.href=i,s.download=t,document.body.appendChild(s),s.click(),document.body.removeChild(s),setTimeout(()=>URL.revokeObjectURL(i),1e3)}function sT(t){const r=(t??"").toLowerCase();return/bash|shell|exec|run/.test(r)?"log":(/grep|search|find/.test(r),"txt")}function uT(t){const r=t.split(`
|
|
552
|
-
`);for(let l=0;l<r.length;l++){const i=r[l];if(/^\s*at\s+\S+.*\(.*:\d+:\d+\)\s*$/.test(i)||/^\s*at\s+\S+\.\S+\(\S+\.java:\d+\)\s*$/.test(i)||/^\s+File "[^"]+", line \d+/.test(i))return l}return-1}function cT({text:t}){const r=uT(t),[l,i]=w.useState(!1);if(r===-1)return h.jsx("pre",{className:"whitespace-pre-wrap break-words font-mono text-xs leading-relaxed",children:t});const s=t.split(`
|
|
553
|
-
`),u=s.slice(0,r).join(`
|
|
554
|
-
`).trim(),c=s.slice(r).join(`
|
|
555
|
-
`),d=c.split(`
|
|
556
|
-
`).filter(p=>p.trim().length>0).length;return h.jsxs("div",{className:"space-y-2",children:[u&&h.jsx("pre",{className:"whitespace-pre-wrap break-words font-mono text-xs leading-relaxed",children:u}),h.jsxs("button",{type:"button",onClick:()=>i(p=>!p),className:"inline-flex items-center gap-1 text-xs text-destructive hover:text-destructive/80 font-medium",children:[l?"▾":"▸"," ",l?"Hide":"Show"," stack trace (",d," frame",d===1?"":"s",")"]}),l&&h.jsx("pre",{className:"whitespace-pre-wrap break-words font-mono text-[11px] leading-snug bg-destructive/5 border border-destructive/20 rounded p-2 max-h-80 overflow-auto",children:c})]})}function fT({input:t}){const[r,l]=w.useState({});if(t==null||typeof t!="object"||Array.isArray(t))return h.jsx("pre",{className:"whitespace-pre-wrap break-all text-xs font-mono",children:JSON.stringify(t,null,2)});const i=Object.entries(t);return i.length===0?h.jsx("span",{className:"text-xs text-muted-foreground italic",children:"(no params)"}):h.jsx("div",{className:"text-xs font-mono",children:i.map(([s,u])=>{if(u==null||typeof u=="string"||typeof u=="number"||typeof u=="boolean"){const m=u===null?"null":u===void 0?"undefined":typeof u=="string"?u:String(u),x=typeof u=="string"&&(m.length>80||m.includes(`
|
|
557
|
-
`));return h.jsxs("div",{className:he("py-0.5",x?"flex flex-col gap-0.5":"flex items-baseline gap-2"),children:[h.jsxs("span",{className:"text-muted-foreground shrink-0",children:[s,":"]}),h.jsx("span",{className:he("text-foreground",x?"whitespace-pre-wrap break-all bg-muted/40 rounded px-1.5 py-1":"truncate",typeof u=="string"?"":"text-amber-600 dark:text-amber-400"),title:typeof u=="string"&&!x?m:void 0,children:m})]},s)}const d=!!r[s],p=Array.isArray(u)?`[${u.length} item${u.length===1?"":"s"}]`:`{${Object.keys(u).length} key${Object.keys(u).length===1?"":"s"}}`;return h.jsxs("div",{className:"py-0.5",children:[h.jsxs("button",{type:"button",onClick:()=>l(m=>({...m,[s]:!m[s]})),className:"flex items-baseline gap-2 hover:bg-muted/30 rounded px-1 -mx-1",children:[h.jsx("span",{className:"text-muted-foreground/60 text-[10px]",children:d?"▾":"▸"}),h.jsxs("span",{className:"text-muted-foreground",children:[s,":"]}),h.jsx("span",{className:"text-violet-600 dark:text-violet-400",children:p})]}),d&&h.jsx("pre",{className:"ml-3 mt-1 whitespace-pre-wrap break-all text-[11px] bg-muted/40 rounded px-2 py-1.5",children:JSON.stringify(u,null,2)})]},s)})})}function dT(t){if(t<1e3)return`${t} ms`;if(t<6e4)return`${(t/1e3).toFixed(t<1e4?2:1)}s`;const r=Math.floor(t/6e4),l=Math.floor(t%6e4/1e3);return`${r}m ${l}s`}function td({message:t,isFirst:r=!1}){const[l,i]=w.useState({}),[s,u]=w.useState(!1),[c,d]=w.useState(""),[p,m]=w.useState(!1),x=t.role==="user",y=t.role==="tool";t.role;const b=pe(I=>I.truncateAfter),S=pe(I=>I.addMessage),k=pe(I=>I.setLoading),N=pe(I=>I.isLoading),A=Ge(I=>I.wsUrl),j=Ce(I=>I.pinnedIds),M=Ce(I=>I.togglePin),z=Ce(I=>I.compactMode),V=j.includes(t.id),Q=Ye(I=>I.inputCost),B=Ye(I=>I.outputCost),G=Ye(I=>I.cacheReadCost),ae=(()=>{if(t.role!=="assistant"||N)return!1;const I=pe.getState().messages;for(let J=I.length-1;J>=0;J--){const H=I[J];if(H.role==="assistant")return H.id===t.id}return!1})(),se=()=>{const I=pe.getState().messages,J=I.findIndex(ye=>ye.id===t.id);if(J===-1)return;let H=-1;for(let ye=J-1;ye>=0;ye--)if(I[ye].role==="user"){H=ye;break}if(H===-1)return;const ne=I[H];b(ne.id),S({role:"user",content:ne.content}),k(!0),Hn(A).sendMessage(ne.content)},L=I=>{i(J=>({...J,[I]:!J[I]}))},P=()=>{d(t.content),u(!0)},X=()=>{u(!1),d("")},de=()=>{const I=c.trim();if(!I){X();return}b(t.id),S({role:"user",content:I}),k(!0),Hn(A).sendMessage(I),u(!1),d("")};return h.jsxs("div",{"data-message-id":t.id,"data-pinned":V?"1":void 0,className:he("group flex animate-message rounded-lg transition-shadow",z?"gap-2":"gap-3",x?"flex-row-reverse":"flex-row",V&&"ring-1 ring-amber-500/30 bg-amber-500/[0.02] px-1 -mx-1"),children:[h.jsx("div",{className:he("flex-shrink-0 w-8 h-8 rounded-full flex items-center justify-center","ring-2 ring-offset-2 ring-offset-background",x?"bg-primary text-primary-foreground ring-primary/20":y?"bg-secondary text-secondary-foreground ring-secondary/20":"bg-accent text-accent-foreground ring-accent/20"),children:x?h.jsx($2,{className:"h-4 w-4"}):y?h.jsx(ga,{className:"h-4 w-4"}):h.jsx(Kx,{className:"h-4 w-4"})}),h.jsxs("div",{className:he("flex flex-col gap-1.5 max-w-[85%]",x&&"items-end"),children:[r&&h.jsx("span",{className:he("text-xs font-medium px-1",x?"text-primary":y?"text-secondary":"text-muted-foreground"),children:x?"You":y?"Tool":"Assistant"}),y&&t.toolName&&h.jsxs("button",{type:"button",onClick:()=>L(t.id),className:he("flex items-center gap-2 text-sm font-medium cursor-pointer select-none","hover:bg-muted/50 rounded-lg px-2 py-1 -mx-2 transition-colors",t.isError?"text-destructive":"text-foreground"),children:[h.jsx("span",{className:"text-muted-foreground/50",children:l[t.id]?h.jsx(Ms,{className:"h-3 w-3"}):h.jsx(pd,{className:"h-3 w-3"})}),h.jsx(ga,{className:"h-3 w-3"}),h.jsx("span",{className:"font-mono",children:t.toolName}),t.toolResult===void 0?h.jsx("span",{className:"h-1.5 w-1.5 rounded-full bg-amber-500 animate-pulse","aria-hidden":!0}):t.isError?h.jsx(gd,{className:"h-3 w-3 text-destructive"}):h.jsx(hl,{className:"h-3 w-3 text-green-500"}),typeof t.toolDurationMs=="number"&&h.jsx("span",{className:"text-xs text-muted-foreground tabular-nums font-normal",children:dT(t.toolDurationMs)})]}),h.jsx("div",{className:he("rounded-2xl",z?"px-3 py-1.5":"px-4 py-3",x?"bg-primary text-primary-foreground rounded-br-md":y?t.isError?"bg-destructive/5 border border-destructive/20 text-destructive":"bg-muted/80 text-foreground":"bg-card border text-foreground",t.isError&&!y&&"border-destructive/20"),children:y?(()=>{const I=!!l[t.id],J=t.toolInput!==void 0?rT(t.toolName,t.toolInput):"",H=t.toolResult?t.toolResult.split(`
|
|
558
|
-
`).length:0;return h.jsxs("div",{className:"space-y-1",children:[J&&!I&&h.jsx("div",{className:"text-xs text-muted-foreground font-mono truncate",children:J}),t.toolResult===void 0&&t.progressLines&&t.progressLines.length>0&&h.jsx("div",{className:"mt-1 rounded-md border border-amber-500/20 bg-amber-500/5 p-1.5 text-[11px] font-mono leading-snug max-h-32 overflow-auto",children:t.progressLines.slice(-6).map((ne,oe)=>h.jsx("div",{className:"truncate text-muted-foreground",children:ne},oe))}),I&&t.toolInput!==void 0&&(()=>{const ne=p1(t.toolName,t.toolInput);return ne?h.jsx(m1,{oldText:ne.oldText,newText:ne.newText,caption:ne.caption}):h.jsxs("div",{className:"p-3 bg-muted/50 rounded-lg overflow-x-auto",children:[h.jsxs("div",{className:"flex items-center gap-1 text-muted-foreground mb-2 text-xs",children:[h.jsx(Jx,{className:"h-3 w-3"}),h.jsx("span",{children:"Input"})]}),h.jsx(fT,{input:t.toolInput})]})})(),I&&t.toolResult!==void 0&&t.toolResult.length>0&&h.jsxs("div",{className:"relative group/tool",children:[h.jsx(W3,{toolName:t.toolName,result:t.toolResult,isError:t.isError}),h.jsxs("div",{className:"absolute top-1.5 right-1.5 flex items-center gap-1 opacity-0 group-hover/tool:opacity-100 transition-opacity",children:[h.jsx(ed,{text:t.toolResult,label:"",className:"bg-background/80 border rounded px-1.5 py-0.5"}),t.toolResult.split(`
|
|
559
|
-
`).length>5&&h.jsx("button",{type:"button",onClick:ne=>{ne.stopPropagation();const oe=sT(t.toolName),ye=(t.toolName??"output").replace(/[^a-z0-9_-]+/gi,"-").toLowerCase();oT(`${ye}-${new Date().toISOString().replace(/[:.]/g,"-")}.${oe}`,t.toolResult??"")},className:"inline-flex items-center gap-1 text-xs text-muted-foreground hover:text-foreground bg-background/80 border rounded px-1.5 py-0.5",title:"Download as file",children:h.jsx(Hf,{className:"h-3 w-3"})})]})]}),I&&t.toolResult!==void 0&&t.toolResult.length===0&&h.jsx("span",{className:"text-xs text-muted-foreground italic",children:"(empty)"}),!I&&t.isError&&t.toolResult&&h.jsx("div",{className:"text-xs font-mono text-destructive truncate",children:t.toolResult.split(`
|
|
560
|
-
`)[0]}),(t.toolResult!==void 0&&t.toolResult.length>0||t.toolInput!==void 0&&Object.keys(t.toolInput??{}).length>0)&&h.jsx("button",{type:"button",onClick:()=>L(t.id),className:"text-xs text-muted-foreground hover:text-foreground transition-colors",children:I?"Hide details":`Show details${H>0?` (${H} line${H===1?"":"s"})`:""}`})]})})():s&&x?h.jsxs("div",{className:"flex flex-col gap-2 min-w-[280px]",children:[h.jsx("textarea",{autoFocus:!0,value:c,onChange:I=>d(I.target.value),onKeyDown:I=>{I.key==="Escape"?(I.preventDefault(),X()):I.key==="Enter"&&(I.metaKey||I.ctrlKey)&&(I.preventDefault(),de())},rows:Math.min(8,Math.max(2,c.split(`
|
|
561
|
-
`).length)),className:"w-full resize-none rounded-md border bg-background text-foreground px-2 py-1.5 text-sm font-mono focus:outline-none focus:ring-2 focus:ring-ring"}),h.jsxs("div",{className:"flex items-center justify-between gap-2",children:[h.jsx("span",{className:"text-[10px] text-primary-foreground/60",children:"⌘/Ctrl+Enter to save · Esc to cancel"}),h.jsxs("div",{className:"flex gap-1",children:[h.jsx("button",{type:"button",onClick:X,className:"text-xs px-2 py-0.5 rounded border border-primary-foreground/30 hover:bg-primary-foreground/10",children:"Cancel"}),h.jsx("button",{type:"button",onClick:de,disabled:!c.trim(),className:"text-xs px-2 py-0.5 rounded bg-primary-foreground text-primary disabled:opacity-50",children:"Save & resend"})]})]})]}):h.jsx("div",{className:"text-sm leading-relaxed markdown-content",children:t.content?p&&t.role==="assistant"?h.jsx("pre",{className:"whitespace-pre-wrap break-words font-mono text-xs leading-relaxed text-foreground/90 max-h-[40rem] overflow-auto",children:t.content}):t.role==="assistant"&&t.isError?h.jsx(cT,{text:t.content}):h.jsx(Uj,{remarkPlugins:[K3],components:iT,children:t.content}):t.streaming?h.jsx("span",{className:"inline-block animate-pulse text-muted-foreground",children:"Typing..."}):h.jsx("span",{className:"text-muted-foreground italic",children:"No content"})})}),h.jsxs("div",{className:he("flex items-center gap-2 px-1",x?"flex-row-reverse":"flex-row"),children:[h.jsx("span",{className:"text-xs text-muted-foreground/50",children:new Date(t.timestamp).toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"})}),t.runSummary&&h.jsxs("span",{className:"text-[10px] text-muted-foreground/60 font-mono tabular-nums",title:[`Iterations: ${t.runSummary.iterations}`,`Tool calls: ${t.runSummary.tools}`,`Elapsed: ${(t.runSummary.durationMs/1e3).toFixed(2)}s`,t.runSummary.costDelta>0?`Cost: $${t.runSummary.costDelta.toFixed(4)}`:""].filter(Boolean).join(" · "),children:[t.runSummary.iterations," iter",t.runSummary.tools>0?` · ${t.runSummary.tools} tool${t.runSummary.tools===1?"":"s"}`:""," · ",t.runSummary.durationMs<6e4?`${(t.runSummary.durationMs/1e3).toFixed(1)}s`:`${Math.floor(t.runSummary.durationMs/6e4)}m ${Math.floor(t.runSummary.durationMs%6e4/1e3)}s`,t.runSummary.costDelta>0?` · $${t.runSummary.costDelta>=.01?t.runSummary.costDelta.toFixed(4):t.runSummary.costDelta.toFixed(6).replace(/0+$/,"").replace(/\.$/,"")}`:""]}),t.usage&&(t.usage.input>0||t.usage.output>0)&&(()=>{const I=t.usage,J=(I.input*Q+I.output*B+(I.cacheRead??0)*G)/1e6,H=Q>0||B>0,ne=J>=.01?`$${J.toFixed(4)}`:J>0?`$${J.toFixed(6).replace(/0+$/,"").replace(/\.$/,"")}`:"";return h.jsxs("span",{className:"text-[10px] text-muted-foreground/60 font-mono tabular-nums",title:[`Input: ${I.input.toLocaleString()}`,`Output: ${I.output.toLocaleString()}`,I.cacheRead?`Cache read: ${I.cacheRead.toLocaleString()}`:"",H?`Cost: ${ne}`:""].filter(Boolean).join(" · "),children:[I.input.toLocaleString(),"→",I.output.toLocaleString(),I.cacheRead?` · ${I.cacheRead.toLocaleString()} ↺`:"",H&&ne?` · ${ne}`:""]})})(),!y&&t.content&&!t.streaming&&h.jsx(ed,{text:t.content,label:"",className:"opacity-0 group-hover:opacity-100 transition-opacity"}),t.role==="assistant"&&t.content&&!t.streaming&&h.jsxs("button",{type:"button",onClick:()=>m(I=>!I),title:p?"Show rendered markdown":"Show raw markdown source",className:he("text-xs inline-flex items-center gap-1 transition-opacity",p?"text-primary hover:text-primary/80 opacity-100":"opacity-0 group-hover:opacity-100 text-muted-foreground hover:text-foreground"),children:[h.jsx(k2,{className:"h-3 w-3"}),h.jsx("span",{children:p?"Rendered":"Raw"})]}),x&&!s&&!N&&t.content&&h.jsxs("button",{type:"button",onClick:P,title:"Edit & resend this prompt",className:"opacity-0 group-hover:opacity-100 transition-opacity text-xs text-muted-foreground hover:text-foreground inline-flex items-center gap-1",children:[h.jsx(e0,{className:"h-3 w-3"}),h.jsx("span",{children:"Edit"})]}),t.role==="assistant"&&t.content&&!t.streaming&&h.jsxs("button",{type:"button",onClick:()=>M(t.id),title:V?"Unpin":"Pin this answer",className:he("text-xs inline-flex items-center gap-1 transition-opacity",V?"text-amber-500 hover:text-amber-600 opacity-100":"opacity-0 group-hover:opacity-100 text-muted-foreground hover:text-foreground"),children:[V?h.jsx(B2,{className:"h-3 w-3"}):h.jsx(t0,{className:"h-3 w-3"}),h.jsx("span",{children:V?"Pinned":"Pin"})]}),ae&&t.content&&!t.streaming&&h.jsxs("button",{type:"button",onClick:se,title:"Regenerate this response",className:"opacity-0 group-hover:opacity-100 transition-opacity text-xs text-muted-foreground hover:text-foreground inline-flex items-center gap-1",children:[h.jsx(Oi,{className:"h-3 w-3"}),h.jsx("span",{children:"Retry"})]})]})]})]})}function hT(t){if(t<1e3)return`${t}ms`;if(t<6e4)return`${(t/1e3).toFixed(t<1e4?2:1)}s`;const r=Math.floor(t/6e4),l=Math.floor(t%6e4/1e3);return`${r}m${l}s`}function mT({tools:t,defaultOpen:r=!1}){const[l,i]=w.useState(r);if(t.length===1)return h.jsx(td,{message:t[0],isFirst:!0});const s=t.filter(x=>x.toolResult===void 0).length,u=t.filter(x=>x.isError).length,c=t.reduce((x,y)=>x+(y.toolDurationMs??0),0),d=Array.from(new Set(t.map(x=>x.toolName).filter(Boolean))),p=d.slice(0,3).join(", "),m=d.length>3?` +${d.length-3}`:"";return h.jsxs("div",{className:"flex gap-3 animate-message",children:[h.jsx("div",{className:"flex-shrink-0 w-8 h-8 rounded-full flex items-center justify-center bg-secondary text-secondary-foreground ring-2 ring-offset-2 ring-offset-background ring-secondary/20",children:h.jsx(ga,{className:"h-4 w-4"})}),h.jsxs("div",{className:"flex flex-col gap-1.5 max-w-[85%] flex-1 min-w-0",children:[h.jsxs("button",{type:"button",onClick:()=>i(x=>!x),className:he("flex items-center gap-2 text-sm font-medium cursor-pointer select-none","hover:bg-muted/50 rounded-lg px-2 py-1.5 -mx-2 transition-colors","border border-border/40 bg-muted/30"),children:[l?h.jsx(Ms,{className:"h-3.5 w-3.5 text-muted-foreground"}):h.jsx(pd,{className:"h-3.5 w-3.5 text-muted-foreground"}),h.jsx(ga,{className:"h-3.5 w-3.5 text-muted-foreground"}),h.jsxs("span",{className:"font-mono text-xs",children:[t.length," tool call",t.length===1?"":"s"]}),s>0?h.jsx($r,{className:"h-3 w-3 animate-spin text-amber-500"}):u>0?h.jsx(gd,{className:"h-3 w-3 text-destructive"}):h.jsx(hl,{className:"h-3 w-3 text-green-500"}),c>0&&h.jsx("span",{className:"text-xs text-muted-foreground tabular-nums font-normal",children:hT(c)}),p&&h.jsxs("span",{className:"text-xs text-muted-foreground/80 font-mono truncate",children:["· ",p,m]})]}),l&&h.jsx("div",{className:"space-y-2 pl-3 border-l-2 border-border/40 ml-2",children:t.map(x=>h.jsx(td,{message:x,isFirst:!1},x.id))})]})]})}const pT=[{icon:pa,title:"Explore",hint:"Understand the code before changing it",tone:"text-blue-600 dark:text-blue-400 bg-blue-500/10 border-blue-500/20",prompts:["Walk me through this codebase: list the top-level packages, the role of each, and how they depend on one another. Highlight any cross-cutting abstractions I should understand first.","Find every place where the WebSocket protocol is defined or consumed (server handlers, client send/receive, type contracts). Show me the message-type table and any gaps where the type isn't enforced.","Locate the entrypoint that boots the agent for normal runs. Trace the call chain from CLI launch all the way to the first model call — what middleware, hooks, and tools are wired along the way?"]},{icon:wd,title:"Build",hint:"Add a feature end-to-end",tone:"text-emerald-600 dark:text-emerald-400 bg-emerald-500/10 border-emerald-500/20",prompts:["Add a slash command `/export` that dumps the current chat (messages + tool calls + usage) as a markdown file to ~/.wrongstack/exports/ and surfaces a 'saved to X' toast. Wire backend + ws-client + slash menu entry.","Create a notification toast system (Zustand store + portal-rendered <Toast/> component) and migrate every existing `key.operation_result` success/failure message to use it instead of dropping into chat.","Add structured JSON logging to the WebSocket server: each handler logs `{ts, level, type, payload}` to ~/.wrongstack/logs/webui.jsonl. Make it tail-friendly and respect the existing log.level config."]},{icon:d2,title:"Debug",hint:"Track a problem to its root cause",tone:"text-amber-600 dark:text-amber-400 bg-amber-500/10 border-amber-500/20",prompts:["Something feels off with token accounting — the cost chip and the per-message tally drift apart over a long session. Reproduce locally if you can, then propose a fix. Start by reading the TokenCounter + provider.response handler.","The WebSocket sometimes silently stops streaming text mid-response on lossy networks. Check the reconnect logic, message queue, and how we handle a half-completed text_delta stream after a reconnect.","I want to know why ctx % climbs so fast in long sessions. Use the existing /debug context breakdown to identify the largest contributors and propose three concrete pruning strategies (with token savings estimates)."]},{icon:r0,title:"Refactor",hint:"Clean up without breaking behavior",tone:"text-violet-600 dark:text-violet-400 bg-violet-500/10 border-violet-500/20",prompts:["Find duplicated logic between packages/cli/src/webui-server.ts and packages/webui/src/server/index.ts. Extract the shared bits into a single source of truth (likely the webui package) and update the CLI to import it.","Look at the Zustand stores in packages/webui/src/stores/index.ts — anything that should be a derived selector instead of stored state? Anything persisted that shouldn't be? Propose a leaner shape and migration plan.","Audit the slash command dispatcher: pull each command's run logic into its own module under packages/webui/src/commands/, make the registry data-driven, and ensure /help auto-generates from the registry (not a hardcoded list)."]}],gT=[{name:"/help",hint:"list every slash command"},{name:"/diag",hint:"runtime diagnostics"},{name:"/stats",hint:"tokens · cache · cost · elapsed"},{name:"/tools",hint:"show registered tools"},{name:"/memory",hint:"show remembered notes"},{name:"/compact",hint:"shrink context"},{name:"/clear",hint:"wipe current context"},{name:"/new",hint:"fresh session"}];function jf(t){var i;const r=document.querySelector("textarea");if(!r)return;const l=(i=Object.getOwnPropertyDescriptor(window.HTMLTextAreaElement.prototype,"value"))==null?void 0:i.set;l==null||l.call(r,t),r.dispatchEvent(new Event("input",{bubbles:!0})),r.focus()}function yT(){const{projectName:t}=Ye(),{provider:r,model:l}=Ge(),i=Ge(N=>N.wsConnected),s=Ge(N=>N.wsUrl),u=Ce(N=>N.setCurrentView),[c,d]=w.useState(void 0);w.useEffect(()=>{if(!i)return;const N=Hn(s),A=N.on("providers.saved",j=>{var z;const M=j.payload;d(((z=M.providers)==null?void 0:z.length)??0)});return N.listSavedProviders(),()=>{A()}},[i,s]);const m=Ce(N=>N.promptHistory).slice(0,6),{listSessions:x,resumeSession:y}=In(),b=da(N=>N.entries);w.useEffect(()=>{i&&b.length===0&&x(10)},[i]);const S=Ce(N=>N.sessionNicknames),k=b.filter(N=>!N.isCurrent).slice(0,4);return h.jsxs("div",{className:"flex flex-col gap-8 py-8 px-2 max-w-5xl mx-auto w-full",children:[h.jsxs("div",{className:"flex flex-col items-center text-center gap-3",children:[h.jsxs("div",{className:"relative",children:[h.jsx("div",{className:"w-14 h-14 rounded-2xl bg-gradient-to-br from-primary via-primary to-primary/60 flex items-center justify-center shadow-lg shadow-primary/20",children:h.jsx(kd,{className:"h-7 w-7 text-primary-foreground"})}),h.jsx("div",{className:"absolute -inset-3 bg-gradient-to-r from-transparent via-primary/10 to-transparent animate-pulse rounded-full -z-10"})]}),h.jsxs("div",{children:[h.jsxs("h2",{className:"text-2xl font-semibold tracking-tight",children:["Where do you want to start",t?h.jsxs(h.Fragment,{children:[" in ",h.jsx("span",{className:"text-primary",children:t})]}):"","?"]}),h.jsxs("p",{className:"text-sm text-muted-foreground mt-2 max-w-2xl mx-auto leading-relaxed",children:["WrongStack is connected to your project and ready to read, edit, run commands, search the codebase, track todos, and remember context across sessions. Pick a starting prompt below, write your own, or type ",h.jsx("span",{className:"font-mono text-foreground/80",children:"/"})," for the full command palette."]}),r&&l&&h.jsxs("p",{className:"text-xs text-muted-foreground/70 mt-2 font-mono",children:[r," / ",l]})]})]}),i&&c===0&&h.jsxs("button",{type:"button",onClick:()=>u("settings"),className:he("group rounded-xl border bg-gradient-to-br from-amber-500/10 via-amber-500/5 to-transparent","border-amber-500/30 hover:border-amber-500/50 transition-colors","p-4 flex items-center gap-4 text-left"),children:[h.jsx("span",{className:"flex items-center justify-center w-12 h-12 rounded-lg bg-amber-500/15 text-amber-600 dark:text-amber-400 shrink-0",children:h.jsx(M2,{className:"h-6 w-6"})}),h.jsxs("div",{className:"flex-1 min-w-0",children:[h.jsx("h3",{className:"text-base font-semibold mb-1",children:"No API key configured yet"}),h.jsx("p",{className:"text-sm text-muted-foreground leading-relaxed",children:"Register a provider in Settings before sending a message — otherwise the agent has nothing to talk to. Anthropic, OpenAI, Google, and any OpenAI-compatible endpoint all work."})]}),h.jsxs("span",{className:"flex items-center gap-1 text-xs text-amber-600 dark:text-amber-400 font-medium shrink-0 group-hover:translate-x-0.5 transition-transform",children:["Open Settings ",h.jsx(Xx,{className:"h-3.5 w-3.5"})]})]}),h.jsx("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-4",children:pT.map(N=>{const A=N.icon;return h.jsxs("div",{className:"rounded-xl border bg-card/40 backdrop-blur-sm p-4 flex flex-col gap-3",children:[h.jsxs("div",{className:"flex items-center gap-2",children:[h.jsx("span",{className:he("flex items-center justify-center w-8 h-8 rounded-lg border",N.tone),children:h.jsx(A,{className:"h-4 w-4"})}),h.jsxs("div",{children:[h.jsx("h3",{className:"text-sm font-semibold",children:N.title}),h.jsx("p",{className:"text-xs text-muted-foreground",children:N.hint})]})]}),h.jsx("div",{className:"flex flex-col gap-1.5",children:N.prompts.map((j,M)=>h.jsx("button",{type:"button",onClick:()=>jf(j),className:"text-left text-xs leading-relaxed text-foreground/80 hover:text-foreground border border-transparent hover:border-border/60 rounded-lg px-3 py-2 hover:bg-muted/40 transition-colors line-clamp-3",title:j,children:j},M))})]},N.title)})}),k.length>0&&h.jsxs("div",{className:"rounded-xl border bg-muted/20 p-4",children:[h.jsxs("div",{className:"flex items-center gap-2 mb-3",children:[h.jsx(Gx,{className:"h-4 w-4 text-muted-foreground"}),h.jsx("span",{className:"text-xs uppercase tracking-wider text-muted-foreground font-medium",children:"Pick back up"})]}),h.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-2",children:k.map(N=>h.jsxs("button",{type:"button",onClick:()=>y(N.id),className:"text-left rounded-lg border border-border/40 bg-background/60 hover:border-primary/40 hover:bg-accent/30 px-3 py-2 transition-colors group/sess",title:N.title,children:[h.jsx("div",{className:"text-sm font-medium truncate text-foreground group-hover/sess:text-primary",children:S[N.id]||N.title||"(empty)"}),h.jsxs("div",{className:"text-[10px] text-muted-foreground font-mono truncate mt-0.5",children:[N.provider,"/",N.model,N.tokenTotal>0&&h.jsxs("span",{className:"ml-2",children:["· ",N.tokenTotal.toLocaleString()," tok"]})]})]},N.id))})]}),m.length>0&&h.jsxs("div",{className:"rounded-xl border bg-muted/20 p-4",children:[h.jsxs("div",{className:"flex items-center gap-2 mb-3",children:[h.jsx(Jx,{className:"h-4 w-4 text-muted-foreground"}),h.jsx("span",{className:"text-xs uppercase tracking-wider text-muted-foreground font-medium",children:"Recent prompts"})]}),h.jsx("div",{className:"flex flex-col gap-1.5",children:m.filter(N=>!N.startsWith("/")).slice(0,5).map((N,A)=>h.jsx("button",{type:"button",onClick:()=>jf(N),className:"text-left text-xs leading-relaxed text-muted-foreground hover:text-foreground border border-transparent hover:border-border/60 rounded-lg px-3 py-2 hover:bg-background/60 transition-colors line-clamp-2",title:N,children:N},A))})]}),h.jsxs("div",{className:"rounded-xl border bg-muted/20 p-4",children:[h.jsxs("div",{className:"flex items-center gap-2 mb-3",children:[h.jsx(Wx,{className:"h-4 w-4 text-muted-foreground"}),h.jsx("span",{className:"text-xs uppercase tracking-wider text-muted-foreground font-medium",children:"Quick commands"})]}),h.jsx("div",{className:"grid grid-cols-2 md:grid-cols-4 gap-2",children:gT.map(N=>h.jsxs("button",{type:"button",onClick:()=>jf(N.name),className:"text-left flex flex-col gap-0.5 rounded-md border border-border/40 bg-background/60 px-3 py-2 hover:border-primary/40 hover:bg-accent/40 transition-colors",children:[h.jsx("span",{className:"font-mono text-xs text-foreground",children:N.name}),h.jsx("span",{className:"text-[11px] text-muted-foreground truncate",children:N.hint})]},N.name))})]})]})}function xT(){const t=Ce(x=>x.searchOpen),r=Ce(x=>x.setSearchOpen),l=Ce(x=>x.searchQuery),i=Ce(x=>x.setSearchQuery),s=pe(x=>x.messages),u=w.useRef(null),[c,d]=w.useState(0);w.useEffect(()=>{t&&requestAnimationFrame(()=>{var x;return(x=u.current)==null?void 0:x.focus()})},[t]);const p=w.useMemo(()=>{const x=l.trim().toLowerCase();return x?s.filter(y=>y.role==="tool"?(y.toolName??"").toLowerCase().includes(x)||(y.toolResult??"").toLowerCase().includes(x)||JSON.stringify(y.toolInput??"").toLowerCase().includes(x):y.content.toLowerCase().includes(x)).map(y=>y.id):[]},[s,l]);if(w.useEffect(()=>{c>=p.length&&d(0)},[p,c]),w.useEffect(()=>{var z;const x=window,y=(z=x.CSS)==null?void 0:z.highlights,b=x.Highlight;if(!y||!b)return;const S=()=>{y.delete("chat-search"),y.delete("chat-search-active")},k=l.trim();if(!k||!t){S();return}const N=k.toLowerCase(),A=[],j=[],M=p[c];return document.querySelectorAll("[data-message-id]").forEach(V=>{const B=V.dataset.messageId===M,G=document.createTreeWalker(V,NodeFilter.SHOW_TEXT);let ae=G.nextNode();for(;ae;){const se=ae.nodeValue??"";if(se.length>0){const L=se.toLowerCase();let P=0;for(;P<=L.length-N.length;){const X=L.indexOf(N,P);if(X===-1)break;const de=document.createRange();de.setStart(ae,X),de.setEnd(ae,X+N.length),A.push(de),B&&j.push(de),P=X+N.length}}ae=G.nextNode()}}),A.length>0?y.set("chat-search",new b(...A)):y.delete("chat-search"),j.length>0?y.set("chat-search-active",new b(...j)):y.delete("chat-search-active"),S},[l,p,c,t]),w.useEffect(()=>{const x=p[c];if(!x)return;const y=document.querySelector(`[data-message-id="${x}"]`);y&&y.scrollIntoView({behavior:"smooth",block:"center"})},[p,c]),!t)return null;const m=x=>{p.length!==0&&d(y=>(y+x+p.length)%p.length)};return h.jsx("div",{className:"absolute top-2 right-4 z-30 w-[28rem] max-w-[calc(100%-2rem)] rounded-lg border bg-popover shadow-xl",children:h.jsxs("div",{className:"flex items-center gap-2 px-3 py-2",children:[h.jsx(pa,{className:"h-4 w-4 text-muted-foreground shrink-0"}),h.jsx("input",{ref:u,value:l,onChange:x=>i(x.target.value),onKeyDown:x=>{x.key==="Escape"?(x.preventDefault(),r(!1)):x.key==="Enter"?(x.preventDefault(),m(x.shiftKey?-1:1)):x.key==="ArrowDown"?(x.preventDefault(),m(1)):x.key==="ArrowUp"&&(x.preventDefault(),m(-1))},placeholder:"Search in chat…",className:"flex-1 bg-transparent outline-none text-sm placeholder:text-muted-foreground"}),h.jsx("span",{className:"text-xs text-muted-foreground tabular-nums shrink-0",children:p.length===0?l?"0":"":`${c+1} / ${p.length}`}),h.jsx("button",{type:"button",onClick:()=>m(-1),disabled:p.length===0,className:he("p-1 rounded hover:bg-muted disabled:opacity-30 disabled:cursor-not-allowed"),title:"Previous hit",children:h.jsx(Qx,{className:"h-3.5 w-3.5"})}),h.jsx("button",{type:"button",onClick:()=>m(1),disabled:p.length===0,className:he("p-1 rounded hover:bg-muted disabled:opacity-30 disabled:cursor-not-allowed"),title:"Next hit",children:h.jsx(Px,{className:"h-3.5 w-3.5"})}),h.jsx("button",{type:"button",onClick:()=>r(!1),className:"p-1 rounded hover:bg-muted text-muted-foreground",title:"Close (Esc)",children:h.jsx(gl,{className:"h-3.5 w-3.5"})})]})})}function bT(){const t=Ye(p=>p.mode),r=Ye(p=>p.modes),{listModes:l,switchMode:i}=In(),[s,u]=w.useState(!1),c=w.useRef(null);w.useEffect(()=>{s&&l()},[s,l]),w.useEffect(()=>{if(!s)return;const p=x=>{var y;(y=c.current)!=null&&y.contains(x.target)||u(!1)},m=x=>{x.key==="Escape"&&u(!1)};return document.addEventListener("mousedown",p),document.addEventListener("keydown",m),()=>{document.removeEventListener("mousedown",p),document.removeEventListener("keydown",m)}},[s]);const d=r.length>0?r:[{id:"default",name:"Default",description:"Standard agent behaviour"}];return h.jsxs("div",{ref:c,className:"relative shrink-0",children:[h.jsxs("button",{type:"button",onClick:()=>u(p=>!p),className:he("flex items-center gap-1 px-2 py-0.5 rounded-full text-xs font-medium","bg-accent/40 text-foreground hover:bg-accent transition-colors border border-transparent hover:border-primary/30"),title:"Active mode",children:["mode: ",h.jsx("span",{className:"font-mono",children:t||"default"}),h.jsx(Ms,{className:"h-3 w-3 opacity-60"})]}),s&&h.jsxs("div",{className:"absolute top-full left-0 mt-1 w-64 rounded-md border bg-popover shadow-lg z-30 py-1",children:[h.jsx("div",{className:"px-3 py-1.5 text-[10px] uppercase tracking-wider text-muted-foreground border-b",children:"Mode"}),d.map(p=>h.jsxs("button",{type:"button",onClick:()=>{i(p.id),u(!1)},className:he("w-full text-left px-3 py-2 hover:bg-accent/40 flex items-start gap-2",p.id===t&&"bg-accent/30"),children:[h.jsx(Zx,{className:he("h-3.5 w-3.5 mt-0.5 shrink-0",p.id===t?"opacity-100 text-primary":"opacity-0")}),h.jsxs("div",{className:"min-w-0 flex-1",children:[h.jsx("div",{className:"text-xs font-mono",children:p.id}),p.description&&h.jsx("div",{className:"text-[11px] text-muted-foreground leading-snug",children:p.description})]})]},p.id))]})]})}function vT({wsStatus:t,wsConnected:r}){const l=Ge(c=>c.wsUrl),[i,s]=w.useState(Date.now());w.useEffect(()=>{if(t.state!=="reconnecting")return;const c=setInterval(()=>s(Date.now()),500);return()=>clearInterval(c)},[t.state]);const u=()=>Hn(l).retryNow();if(t.state==="open"&&r)return h.jsx("div",{className:"flex items-center gap-1 px-1.5 py-0.5 rounded-full text-[11px] font-medium shrink-0 bg-green-500/10 text-green-600 dark:text-green-400",title:"Backend connected",children:h.jsx(a0,{className:"h-3 w-3"})});if(t.state==="connecting")return h.jsxs("div",{className:"flex items-center gap-1 px-1.5 py-0.5 rounded-full text-[11px] font-medium shrink-0 bg-yellow-500/10 text-yellow-600 dark:text-yellow-400",title:"Connecting to backend",children:[h.jsx($r,{className:"h-3 w-3 animate-spin"}),h.jsx("span",{children:"connecting"})]});if(t.state==="reconnecting"){const c=Math.max(0,Math.ceil((t.nextRetryAt-i)/1e3));return h.jsxs("button",{type:"button",onClick:u,className:he("flex items-center gap-1 px-1.5 py-0.5 rounded-full text-[11px] font-medium shrink-0","bg-orange-500/10 text-orange-600 dark:text-orange-400 hover:bg-orange-500/20","transition-colors"),title:t.lastError?`Reconnecting — last error: ${t.lastError}. Click to retry now.`:"Reconnecting — click to retry now.",children:[h.jsx($r,{className:"h-3 w-3 animate-spin"}),h.jsxs("span",{children:["retry #",t.attempt," in ",c,"s"]})]})}return h.jsxs("button",{type:"button",onClick:u,className:"flex items-center gap-1 px-1.5 py-0.5 rounded-full text-[11px] font-medium shrink-0 bg-red-500/10 text-red-600 dark:text-red-400 hover:bg-red-500/20 transition-colors",title:t.state==="closed"&&t.error?`Disconnected: ${t.error}. Click to retry.`:"Disconnected. Click to retry.",children:[h.jsx(Sd,{className:"h-3 w-3"}),h.jsxs("span",{className:"flex items-center gap-0.5",children:["offline",h.jsx(Oi,{className:"h-3 w-3 opacity-70"})]})]})}function ST(){const t=Ye(y=>y.cost),r=Ye(y=>y.inputCost),l=Ye(y=>y.outputCost),i=Ye(y=>y.cacheReadCost),s=pe(y=>y.messages),[u,c]=w.useState(!1),d=w.useRef(null);w.useEffect(()=>{if(!u)return;const y=S=>{var k;(k=d.current)!=null&&k.contains(S.target)||c(!1)},b=S=>{S.key==="Escape"&&c(!1)};return document.addEventListener("mousedown",y),document.addEventListener("keydown",b),()=>{document.removeEventListener("mousedown",y),document.removeEventListener("keydown",b)}},[u]);const p=(()=>{const y=[];for(const b of s)b.role==="assistant"&&b.runSummary&&b.runSummary.costDelta>0&&y.push({id:b.id,preview:b.content.slice(0,80).replace(/\s+/g," ").trim()||"(empty)",cost:b.runSummary.costDelta,tools:b.runSummary.tools,ms:b.runSummary.durationMs,ts:b.timestamp});return y.sort((b,S)=>S.cost-b.cost),y.slice(0,5)})(),m=y=>y>=.01?`$${y.toFixed(4)}`:y>0?`$${y.toFixed(6).replace(/0+$/,"").replace(/\.$/,"")}`:"$0",x=r>0||l>0;return h.jsxs("div",{ref:d,className:"relative inline-block",children:[h.jsxs("button",{type:"button",onClick:()=>c(y=>!y),className:he("font-medium text-green-600 dark:text-green-400 hover:underline tabular-nums"),title:"Click for per-turn cost breakdown",children:["$",t.toFixed(4)]}),u&&h.jsxs("div",{className:"absolute right-0 top-full mt-1 z-30 w-80 rounded-md border bg-popover shadow-lg p-3 text-foreground",children:[h.jsxs("div",{className:"flex items-center justify-between mb-2",children:[h.jsx("span",{className:"text-xs uppercase tracking-wider text-muted-foreground font-medium",children:"Cost breakdown"}),h.jsx("span",{className:"font-mono tabular-nums text-sm font-semibold text-green-600 dark:text-green-400",children:m(t)})]}),x?h.jsxs("div",{className:"text-[11px] text-muted-foreground font-mono mb-3 border-b pb-2",children:[h.jsxs("div",{className:"flex justify-between",children:[h.jsx("span",{children:"input /1M"}),h.jsxs("span",{children:["$",r.toFixed(2)]})]}),h.jsxs("div",{className:"flex justify-between",children:[h.jsx("span",{children:"output /1M"}),h.jsxs("span",{children:["$",l.toFixed(2)]})]}),i>0&&h.jsxs("div",{className:"flex justify-between",children:[h.jsx("span",{children:"cache /1M"}),h.jsxs("span",{children:["$",i.toFixed(2)]})]})]}):h.jsx("div",{className:"text-[11px] text-muted-foreground italic mb-3 border-b pb-2",children:"No pricing for the current model — cost figures are zero."}),p.length===0?h.jsx("div",{className:"text-xs text-muted-foreground italic",children:"No completed turns yet. Run a prompt to see per-turn cost here."}):h.jsxs(h.Fragment,{children:[h.jsxs("div",{className:"text-[10px] uppercase tracking-wider text-muted-foreground/80 mb-1",children:["Top ",p.length," expensive turn",p.length===1?"":"s"]}),h.jsx("ul",{className:"space-y-1",children:p.map(y=>h.jsx("li",{children:h.jsxs("button",{type:"button",onClick:()=>{const b=document.querySelector(`[data-message-id="${y.id}"]`);b&&b.scrollIntoView({behavior:"smooth",block:"center"}),c(!1)},className:"w-full text-left rounded px-2 py-1.5 hover:bg-accent/40 transition-colors",children:[h.jsxs("div",{className:"flex items-baseline justify-between gap-2",children:[h.jsx("span",{className:"text-xs truncate",children:y.preview}),h.jsx("span",{className:"text-xs font-mono tabular-nums text-green-600 dark:text-green-400 shrink-0",children:m(y.cost)})]}),h.jsxs("div",{className:"text-[10px] text-muted-foreground font-mono mt-0.5",children:[y.tools," tool",y.tools===1?"":"s"," · ",(y.ms/1e3).toFixed(1),"s"]})]})},y.id))})]})]})]})}function wi(t){return t>=1e6?`${(t/1e6).toFixed(1)}M`:t>=1e3?`${(t/1e3).toFixed(t>=1e4?0:1)}k`:String(t)}function wT(){const{messages:t,isLoading:r}=pe(),l=Ce(W=>W.setPaletteOpen),i=Ce(W=>W.setShortcutsOpen),s=Ce(W=>W.sidebarOpen),u=Ce(W=>W.toggleSidebar),c=Ce(W=>W.compactMode),d=Ge(W=>W.setTheme),p=Ge(W=>W.theme),{totalTokens:m,cost:x,startTime:y,lastInputTokens:b,maxContext:S,projectName:k,iteration:N}=Ye(),{wsConnected:A,wsStatus:j,provider:M,model:z}=Ge(),{setCurrentView:V}=Ce(),Q=w.useRef(null),B=S>0&&b>0?Math.min(100,Math.round(b/S*100)):0,G=B>=85?"bg-red-500/15 text-red-600 dark:text-red-400":B>=70?"bg-amber-500/15 text-amber-600 dark:text-amber-400":"bg-muted text-muted-foreground",[ae,se]=w.useState(!0),[L,P]=w.useState(0),[X,de]=w.useState(!1),I=w.useRef(t.length),J=w.useCallback(()=>{var W;return((W=Q.current)==null?void 0:W.querySelector("[data-radix-scroll-area-viewport]"))??null},[]);w.useEffect(()=>{const W=J();if(!W)return;const be=()=>{const Ae=W.scrollHeight-W.scrollTop-W.clientHeight<120;se(Ae),Ae&&(P(0),I.current=t.length);const dt=W.scrollTop>W.clientHeight&&W.scrollHeight>W.clientHeight*2.5;de(dt)};return W.addEventListener("scroll",be,{passive:!0}),()=>W.removeEventListener("scroll",be)},[J,t.length]),w.useEffect(()=>{const W=J();if(W)if(ae)W.scrollTop=W.scrollHeight,I.current=t.length;else{const be=t.length-I.current;be>0&&P(be)}},[t,ae,J]);const H=w.useCallback(()=>{const W=J();W&&(W.scrollTo({top:W.scrollHeight,behavior:"smooth"}),se(!0),P(0),I.current=t.length)},[J,t.length]),ne=w.useCallback(()=>{const W=J();W&&W.scrollTo({top:0,behavior:"smooth"})},[J]),[oe,ye]=w.useState(null),[D,T]=w.useState(()=>Date.now()),U=w.useRef(null);w.useEffect(()=>{r&&oe===null&&ye(Date.now()),!r&&oe!==null&&ye(null)},[r,oe]),w.useEffect(()=>{if(!r)return;const W=setInterval(()=>T(Date.now()),500);return()=>clearInterval(W)},[r]);const E=W=>{if(!W)return"--";const be=Math.floor((Date.now()-W)/1e3);if(be<60)return`${be}s`;const we=Math.floor(be/60),Ae=be%60;return`${we}m ${Ae}s`},O=(()=>{if(!r)return"idle";const W=t[t.length-1];return(W==null?void 0:W.role)==="assistant"&&!!W.content&&W.streaming?"streaming":"thinking"})(),ee=O==="idle"?"bg-muted text-muted-foreground":O==="streaming"?"bg-blue-500/10 text-blue-600 dark:text-blue-400":"bg-amber-500/10 text-amber-600 dark:text-amber-400",re=S>0&&b>0||m.input>0||!!y;return h.jsxs("div",{className:"flex flex-col h-full",children:[h.jsxs("header",{className:"flex flex-col border-b bg-card shrink-0",children:[h.jsxs("div",{className:"flex items-center justify-between gap-2 px-3 py-2",children:[h.jsxs("div",{className:"flex items-center gap-1.5 min-w-0 flex-1",children:[!s&&h.jsx(Ve,{variant:"ghost",size:"icon",className:"h-7 w-7 shrink-0",onClick:u,title:"Open sidebar (Ctrl+\\\\)",children:h.jsx(U2,{className:"h-4 w-4"})}),!s&&h.jsx("div",{className:"flex items-center gap-1.5 shrink-0 mr-1",children:h.jsx("div",{className:"w-5 h-5 rounded bg-primary flex items-center justify-center",children:h.jsx(kd,{className:"h-3 w-3 text-primary-foreground"})})}),h.jsx(vT,{wsStatus:j,wsConnected:A}),h.jsxs("span",{className:he("flex items-center gap-1 px-1.5 py-0.5 rounded-full text-[11px] font-medium shrink-0 tabular-nums",ee),title:`Agent state: ${O}`,children:[O!=="idle"&&h.jsx("span",{className:"h-1.5 w-1.5 rounded-full bg-current animate-pulse"}),h.jsx("span",{children:O})]}),k&&h.jsxs("span",{className:"flex items-center gap-1 text-[11px] text-muted-foreground shrink-0 min-w-0",title:`Project: ${k}`,children:[h.jsx(E2,{className:"h-3 w-3 shrink-0"}),h.jsx("span",{className:"truncate max-w-[12rem]",children:k})]}),h.jsxs("button",{type:"button",onClick:()=>Ce.getState().setModelSwitcherOpen(!0),className:"group flex items-center gap-1 px-2 py-0.5 rounded-md border bg-background/50 hover:bg-accent hover:border-primary/40 transition-colors text-[11px] min-w-0 shrink-0",title:"Change provider / model (Ctrl+M)",children:[h.jsx(Ti,{className:"h-3 w-3 text-muted-foreground group-hover:text-foreground shrink-0"}),h.jsxs("span",{className:"font-mono truncate max-w-[16rem]",children:[h.jsx("span",{className:"text-muted-foreground",children:M||"no-provider"}),h.jsx("span",{className:"text-muted-foreground/40 mx-0.5",children:"/"}),h.jsx("span",{className:"font-medium",children:z||"no-model"})]})]}),h.jsx(bT,{}),N&&h.jsxs("span",{className:"flex items-center gap-1 px-1.5 py-0.5 rounded-full text-[11px] font-medium bg-primary/10 text-primary shrink-0",title:"Agent iteration",children:[h.jsx(c2,{className:"h-3 w-3 animate-pulse"}),"iter ",N.index,N.max>0?`/${N.max}`:""]})]}),h.jsxs("div",{className:"flex items-center gap-0.5 shrink-0",children:[h.jsx(Ve,{variant:"ghost",size:"icon",className:"h-7 w-7",onClick:()=>l(!0),title:"Command palette (Ctrl+K)",children:h.jsx(b2,{className:"h-4 w-4"})}),h.jsx(Ve,{variant:"ghost",size:"icon",className:"h-7 w-7",onClick:()=>{d(p==="light"?"dark":p==="dark"?"system":"light")},title:`Theme: ${p} (click to cycle)`,children:p==="light"?h.jsx(vd,{className:"h-4 w-4"}):p==="dark"?h.jsx(xd,{className:"h-4 w-4"}):h.jsx(yd,{className:"h-4 w-4"})}),h.jsx(Ve,{variant:"ghost",size:"icon",className:"h-7 w-7 font-mono text-xs",onClick:()=>i(!0),title:"Keyboard shortcuts (?)",children:"?"}),h.jsx(Ve,{variant:"ghost",size:"icon",className:"h-7 w-7",onClick:()=>V("settings"),title:"Settings",children:h.jsx(bd,{className:"h-4 w-4"})})]})]}),re&&h.jsxs("div",{className:"flex items-center justify-between gap-3 px-3 py-1 border-t bg-muted/20 text-[11px] text-muted-foreground",children:[h.jsxs("div",{className:"flex items-center gap-3 min-w-0 flex-1 tabular-nums",children:[S>0&&b>0&&h.jsxs("span",{className:he("flex items-center gap-1 px-1.5 py-0.5 rounded-full font-medium shrink-0",G),title:`Last input: ${b.toLocaleString()} / ${S.toLocaleString()} tokens`,children:["ctx ",B,"% · ",wi(b),"/",wi(S)]}),m.input>0&&h.jsxs(h.Fragment,{children:[h.jsxs("span",{className:"flex items-center gap-1",children:[h.jsx("span",{className:"font-medium text-foreground",children:wi(m.input)}),h.jsx("span",{children:"in"})]}),h.jsxs("span",{className:"flex items-center gap-1",children:[h.jsx("span",{className:"font-medium text-foreground",children:wi(m.output)}),h.jsx("span",{children:"out"})]}),m.cacheRead&&m.cacheRead>0&&(()=>{const W=(m.cacheRead??0)+m.input,be=W>0?Math.round((m.cacheRead??0)/W*100):0;return h.jsxs("span",{className:"flex items-center gap-1",title:`Cache hit ratio: ${be}%`,children:[h.jsx("span",{className:"font-medium text-foreground",children:wi(m.cacheRead)}),h.jsxs("span",{children:["cache (",be,"%)"]})]})})(),h.jsx(ST,{})]})]}),y&&h.jsx("span",{className:"text-muted-foreground/70 tabular-nums shrink-0",children:E(y)})]})]}),h.jsxs("div",{className:"flex-1 relative overflow-hidden",children:[h.jsx(xT,{}),!ae&&h.jsxs("button",{type:"button",onClick:H,className:he("absolute bottom-4 left-1/2 -translate-x-1/2 z-10","flex items-center gap-2 px-4 py-2 rounded-full shadow-lg","bg-primary text-primary-foreground text-xs font-medium","hover:bg-primary/90 transition-colors animate-message"),children:[h.jsx(Px,{className:"h-3.5 w-3.5"}),L>0?`${L} new message${L===1?"":"s"}`:"Jump to latest"]}),X&&h.jsxs("button",{type:"button",onClick:ne,title:"Scroll to top (oldest)",className:he("absolute top-3 right-3 z-10","flex items-center gap-1 px-2.5 py-1 rounded-full shadow-md border","bg-background/90 backdrop-blur-sm text-[11px] text-muted-foreground","hover:text-foreground hover:bg-background transition-colors animate-message"),children:[h.jsx(Qx,{className:"h-3 w-3"}),h.jsx("span",{children:"Top"})]}),h.jsx(As,{className:"h-full",ref:Q,children:h.jsxs("div",{className:he("mx-auto pb-8",c?"max-w-5xl p-3 space-y-3":"max-w-5xl p-4 space-y-6"),children:[t.length===0&&!r&&h.jsx(yT,{}),(()=>{const W=[];for(let Te=0;Te<t.length;Te++){const xe=t[Te];if(xe.role==="tool"){const De=W[W.length-1];De&&De.kind==="tools"?De.tools.push(xe):W.push({kind:"tools",tools:[xe],key:xe.id})}else{const De=t[Te-1];W.push({kind:"msg",message:xe,isFirst:!De||De.role!==xe.role})}}const be=W.length-1;let we=null;const Ae=Te=>{const xe=new Date(Te);return`${xe.getFullYear()}-${xe.getMonth()}-${xe.getDate()}`},dt=Te=>{const xe=new Date(Te),De=new Date,at=new Date(Date.now()-864e5);return Ae(Te)===Ae(De.getTime())?"Today":Ae(Te)===Ae(at.getTime())?"Yesterday":xe.toLocaleDateString(void 0,{weekday:"short",month:"short",day:"numeric",year:xe.getFullYear()===De.getFullYear()?void 0:"numeric"})},st=[];for(let Te=0;Te<W.length;Te++){const xe=W[Te],De=xe.kind==="msg"?xe.message.timestamp:xe.tools[0].timestamp,at=Ae(De);if(at!==we&&(st.push(h.jsxs("div",{className:"flex items-center gap-3 py-1 text-[11px] text-muted-foreground/70 uppercase tracking-wider font-medium",children:[h.jsx("div",{className:"flex-1 h-px bg-border/50"}),h.jsx("span",{children:dt(De)}),h.jsx("div",{className:"flex-1 h-px bg-border/50"})]},`day-${at}-${Te}`)),we=at),xe.kind==="msg")st.push(h.jsx(td,{message:xe.message,isFirst:xe.isFirst},xe.message.id));else{const ht=Te===be&&r&&xe.tools.some($t=>$t.toolResult===void 0);st.push(h.jsx(mT,{tools:xe.tools,defaultOpen:ht},xe.key))}}return st})(),r&&(()=>{const W=t[t.length-1],be=t.filter(xe=>xe.role==="tool"&&xe.toolResult===void 0);let we="Thinking…";if(be.length>0){const xe=Array.from(new Set(be.map(ht=>ht.toolName).filter(Boolean))),De=xe.slice(0,2).join(", "),at=xe.length>2?` +${xe.length-2}`:"";we=be.length===1?`Running ${De||"tool"}…`:`Running ${be.length} tools (${De}${at})…`}else(W==null?void 0:W.role)==="assistant"&&W.content?we="Writing reply…":(W==null?void 0:W.role)==="tool"&&W.toolResult!==void 0&&(we="Thinking about the next step…");const Ae=oe?Math.max(0,Math.floor((D-oe)/1e3)):0,dt=Ae<60?`${Ae}s`:`${Math.floor(Ae/60)}m ${Ae%60}s`;let st="";const Te=(W==null?void 0:W.role)==="assistant"&&W.streaming&&W.content?W:null;if(Te){const xe=U.current;if(!xe||xe.id!==Te.id)U.current={id:Te.id,at:Date.now(),len:Te.content.length};else{const De=Math.max(1,D-xe.at),at=Math.max(0,Te.content.length-xe.len);if(De>500&&at>0){const ht=at*1e3/De;st=ht>=1e3?`${(ht/1e3).toFixed(1)}k ch/s`:`${Math.round(ht)} ch/s`}}}else U.current&&(U.current=null);return h.jsxs("div",{className:"flex gap-3 animate-message",children:[h.jsx("div",{className:"flex-shrink-0 w-8 h-8 rounded-full flex items-center justify-center bg-accent text-accent-foreground ring-2 ring-offset-2 ring-offset-background ring-accent/20",children:h.jsx(Kx,{className:"h-4 w-4"})}),h.jsx("div",{className:"flex flex-col gap-1.5",children:h.jsx("div",{className:"rounded-2xl px-4 py-3 bg-card border text-foreground",children:h.jsxs("div",{className:"flex items-center gap-3 text-sm",children:[h.jsxs("span",{className:"flex gap-1",children:[h.jsx("span",{className:"h-1.5 w-1.5 rounded-full bg-primary/70 animate-bounce [animation-delay:-0.3s]"}),h.jsx("span",{className:"h-1.5 w-1.5 rounded-full bg-primary/70 animate-bounce [animation-delay:-0.15s]"}),h.jsx("span",{className:"h-1.5 w-1.5 rounded-full bg-primary/70 animate-bounce"})]}),h.jsx("span",{className:"text-foreground/90",children:we}),h.jsx("span",{className:"text-xs text-muted-foreground tabular-nums",children:dt}),N&&h.jsxs("span",{className:"text-xs text-muted-foreground tabular-nums",children:["· iter ",N.index,N.max>0?`/${N.max}`:""]}),st&&h.jsxs("span",{className:"text-xs text-muted-foreground/80 tabular-nums",children:["· ",st]})]})})})]})})()]})})]}),h.jsx("div",{className:"border-t bg-card/50 backdrop-blur supports-[backdrop-filter]:bg-card/50 p-4 shrink-0",children:h.jsxs("div",{className:"max-w-5xl mx-auto",children:[h.jsx(Nk,{}),h.jsx("p",{className:"text-xs text-center text-muted-foreground/50 mt-2",children:"Press Enter to send, Shift+Enter for new line"})]})})]})}function kT(t){const r=t+"CollectionProvider",[l,i]=zi(r),[s,u]=l(r,{collectionRef:{current:null},itemMap:new Map}),c=N=>{const{scope:A,children:j}=N,M=dn.useRef(null),z=dn.useRef(new Map).current;return h.jsx(s,{scope:A,itemMap:z,collectionRef:M,children:j})};c.displayName=r;const d=t+"CollectionSlot",p=ys(d),m=dn.forwardRef((N,A)=>{const{scope:j,children:M}=N,z=u(d,j),V=It(A,z.collectionRef);return h.jsx(p,{ref:V,children:M})});m.displayName=d;const x=t+"CollectionItemSlot",y="data-radix-collection-item",b=ys(x),S=dn.forwardRef((N,A)=>{const{scope:j,children:M,...z}=N,V=dn.useRef(null),Q=It(A,V),B=u(x,j);return dn.useEffect(()=>(B.itemMap.set(V,{ref:V,...z}),()=>void B.itemMap.delete(V))),h.jsx(b,{[y]:"",ref:Q,children:M})});S.displayName=x;function k(N){const A=u(t+"CollectionConsumer",N);return dn.useCallback(()=>{const M=A.collectionRef.current;if(!M)return[];const z=Array.from(M.querySelectorAll(`[${y}]`));return Array.from(A.itemMap.values()).sort((B,G)=>z.indexOf(B.ref.current)-z.indexOf(G.ref.current))},[A.collectionRef,A.itemMap])}return[{Provider:c,Slot:m,ItemSlot:S},k,i]}var CT=od[" useId ".trim().toString()]||(()=>{}),NT=0;function ji(t){const[r,l]=w.useState(CT());return ha(()=>{l(i=>i??String(NT++))},[t]),r?`radix-${r}`:""}var ET=od[" useInsertionEffect ".trim().toString()]||ha;function $d({prop:t,defaultProp:r,onChange:l=()=>{},caller:i}){const[s,u,c]=jT({defaultProp:r,onChange:l}),d=t!==void 0,p=d?t:s;{const x=w.useRef(t!==void 0);w.useEffect(()=>{const y=x.current;y!==d&&console.warn(`${i} is changing from ${y?"controlled":"uncontrolled"} to ${d?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),x.current=d},[d,i])}const m=w.useCallback(x=>{var y;if(d){const b=TT(x)?x(t):x;b!==t&&((y=c.current)==null||y.call(c,b))}else u(x)},[d,t,u,c]);return[p,m]}function jT({defaultProp:t,onChange:r}){const[l,i]=w.useState(t),s=w.useRef(l),u=w.useRef(r);return ET(()=>{u.current=r},[r]),w.useEffect(()=>{var c;s.current!==l&&((c=u.current)==null||c.call(u,l),s.current=l)},[l,s]),[l,i,u]}function TT(t){return typeof t=="function"}var Tf="rovingFocusGroup.onEntryFocus",AT={bubbles:!1,cancelable:!0},Bi="RovingFocusGroup",[nd,g1,MT]=kT(Bi),[DT,y1]=zi(Bi,[MT]),[RT,zT]=DT(Bi),x1=w.forwardRef((t,r)=>h.jsx(nd.Provider,{scope:t.__scopeRovingFocusGroup,children:h.jsx(nd.Slot,{scope:t.__scopeRovingFocusGroup,children:h.jsx(OT,{...t,ref:r})})}));x1.displayName=Bi;var OT=w.forwardRef((t,r)=>{const{__scopeRovingFocusGroup:l,orientation:i,loop:s=!1,dir:u,currentTabStopId:c,defaultCurrentTabStopId:d,onCurrentTabStopIdChange:p,onEntryFocus:m,preventScrollOnEntryFocus:x=!1,...y}=t,b=w.useRef(null),S=It(r,b),k=ud(u),[N,A]=$d({prop:c,defaultProp:d??null,onChange:p,caller:Bi}),[j,M]=w.useState(!1),z=hn(m),V=g1(l),Q=w.useRef(!1),[B,G]=w.useState(0);return w.useEffect(()=>{const ae=b.current;if(ae)return ae.addEventListener(Tf,z),()=>ae.removeEventListener(Tf,z)},[z]),h.jsx(RT,{scope:l,orientation:i,dir:k,loop:s,currentTabStopId:N,onItemFocus:w.useCallback(ae=>A(ae),[A]),onItemShiftTab:w.useCallback(()=>M(!0),[]),onFocusableItemAdd:w.useCallback(()=>G(ae=>ae+1),[]),onFocusableItemRemove:w.useCallback(()=>G(ae=>ae-1),[]),children:h.jsx(Tt.div,{tabIndex:j||B===0?-1:0,"data-orientation":i,...y,ref:S,style:{outline:"none",...t.style},onMouseDown:gt(t.onMouseDown,()=>{Q.current=!0}),onFocus:gt(t.onFocus,ae=>{const se=!Q.current;if(ae.target===ae.currentTarget&&se&&!j){const L=new CustomEvent(Tf,AT);if(ae.currentTarget.dispatchEvent(L),!L.defaultPrevented){const P=V().filter(H=>H.focusable),X=P.find(H=>H.active),de=P.find(H=>H.id===N),J=[X,de,...P].filter(Boolean).map(H=>H.ref.current);S1(J,x)}}Q.current=!1}),onBlur:gt(t.onBlur,()=>M(!1))})})}),b1="RovingFocusGroupItem",v1=w.forwardRef((t,r)=>{const{__scopeRovingFocusGroup:l,focusable:i=!0,active:s=!1,tabStopId:u,children:c,...d}=t,p=ji(),m=u||p,x=zT(b1,l),y=x.currentTabStopId===m,b=g1(l),{onFocusableItemAdd:S,onFocusableItemRemove:k,currentTabStopId:N}=x;return w.useEffect(()=>{if(i)return S(),()=>k()},[i,S,k]),h.jsx(nd.ItemSlot,{scope:l,id:m,focusable:i,active:s,children:h.jsx(Tt.span,{tabIndex:y?0:-1,"data-orientation":x.orientation,...d,ref:r,onMouseDown:gt(t.onMouseDown,A=>{i?x.onItemFocus(m):A.preventDefault()}),onFocus:gt(t.onFocus,()=>x.onItemFocus(m)),onKeyDown:gt(t.onKeyDown,A=>{if(A.key==="Tab"&&A.shiftKey){x.onItemShiftTab();return}if(A.target!==A.currentTarget)return;const j=UT(A,x.orientation,x.dir);if(j!==void 0){if(A.metaKey||A.ctrlKey||A.altKey||A.shiftKey)return;A.preventDefault();let z=b().filter(V=>V.focusable).map(V=>V.ref.current);if(j==="last")z.reverse();else if(j==="prev"||j==="next"){j==="prev"&&z.reverse();const V=z.indexOf(A.currentTarget);z=x.loop?BT(z,V+1):z.slice(V+1)}setTimeout(()=>S1(z))}}),children:typeof c=="function"?c({isCurrentTabStop:y,hasTabStop:N!=null}):c})})});v1.displayName=b1;var _T={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function LT(t,r){return r!=="rtl"?t:t==="ArrowLeft"?"ArrowRight":t==="ArrowRight"?"ArrowLeft":t}function UT(t,r,l){const i=LT(t.key,l);if(!(r==="vertical"&&["ArrowLeft","ArrowRight"].includes(i))&&!(r==="horizontal"&&["ArrowUp","ArrowDown"].includes(i)))return _T[i]}function S1(t,r=!1){const l=document.activeElement;for(const i of t)if(i===l||(i.focus({preventScroll:r}),document.activeElement!==l))return}function BT(t,r){return t.map((l,i)=>t[(r+i)%t.length])}var HT=x1,qT=v1,Ls="Tabs",[IT]=zi(Ls,[y1]),w1=y1(),[VT,Fd]=IT(Ls),k1=w.forwardRef((t,r)=>{const{__scopeTabs:l,value:i,onValueChange:s,defaultValue:u,orientation:c="horizontal",dir:d,activationMode:p="automatic",...m}=t,x=ud(d),[y,b]=$d({prop:i,onChange:s,defaultProp:u??"",caller:Ls});return h.jsx(VT,{scope:l,baseId:ji(),value:y,onValueChange:b,orientation:c,dir:x,activationMode:p,children:h.jsx(Tt.div,{dir:x,"data-orientation":c,...m,ref:r})})});k1.displayName=Ls;var C1="TabsList",N1=w.forwardRef((t,r)=>{const{__scopeTabs:l,loop:i=!0,...s}=t,u=Fd(C1,l),c=w1(l);return h.jsx(HT,{asChild:!0,...c,orientation:u.orientation,dir:u.dir,loop:i,children:h.jsx(Tt.div,{role:"tablist","aria-orientation":u.orientation,...s,ref:r})})});N1.displayName=C1;var E1="TabsTrigger",j1=w.forwardRef((t,r)=>{const{__scopeTabs:l,value:i,disabled:s=!1,...u}=t,c=Fd(E1,l),d=w1(l),p=M1(c.baseId,i),m=D1(c.baseId,i),x=i===c.value;return h.jsx(qT,{asChild:!0,...d,focusable:!s,active:x,children:h.jsx(Tt.button,{type:"button",role:"tab","aria-selected":x,"aria-controls":m,"data-state":x?"active":"inactive","data-disabled":s?"":void 0,disabled:s,id:p,...u,ref:r,onMouseDown:gt(t.onMouseDown,y=>{!s&&y.button===0&&y.ctrlKey===!1?c.onValueChange(i):y.preventDefault()}),onKeyDown:gt(t.onKeyDown,y=>{[" ","Enter"].includes(y.key)&&c.onValueChange(i)}),onFocus:gt(t.onFocus,()=>{const y=c.activationMode!=="manual";!x&&!s&&y&&c.onValueChange(i)})})})});j1.displayName=E1;var T1="TabsContent",A1=w.forwardRef((t,r)=>{const{__scopeTabs:l,value:i,forceMount:s,children:u,...c}=t,d=Fd(T1,l),p=M1(d.baseId,i),m=D1(d.baseId,i),x=i===d.value,y=w.useRef(x);return w.useEffect(()=>{const b=requestAnimationFrame(()=>y.current=!1);return()=>cancelAnimationFrame(b)},[]),h.jsx(sr,{present:s||x,children:({present:b})=>h.jsx(Tt.div,{"data-state":x?"active":"inactive","data-orientation":d.orientation,role:"tabpanel","aria-labelledby":p,hidden:!b,id:m,tabIndex:0,...c,ref:r,style:{...t.style,animationDuration:y.current?"0s":void 0},children:b&&u})})});A1.displayName=T1;function M1(t,r){return`${t}-trigger-${r}`}function D1(t,r){return`${t}-content-${r}`}var $T=k1,R1=N1,z1=j1,O1=A1;const _1=$T,Yd=w.forwardRef(({className:t,...r},l)=>h.jsx(R1,{ref:l,className:he("inline-flex h-10 items-center justify-center rounded-md bg-muted p-1 text-muted-foreground",t),...r}));Yd.displayName=R1.displayName;const fl=w.forwardRef(({className:t,...r},l)=>h.jsx(z1,{ref:l,className:he("inline-flex items-center justify-center whitespace-nowrap rounded-sm px-3 py-1.5 text-sm font-medium ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm",t),...r}));fl.displayName=z1.displayName;const dl=w.forwardRef(({className:t,...r},l)=>h.jsx(O1,{ref:l,className:he("mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",t),...r}));dl.displayName=O1.displayName;function FT(){const{toggleSidebar:t,currentView:r,setCurrentView:l}=Ce(),i=Ce(O=>O.sidebarWidth),s=Ce(O=>O.setSidebarWidth),{totalTokens:u,cost:c,session:d,todos:p}=Ye(),{messages:m,clearMessages:x}=pe(),y=Ce(O=>O.pinnedIds),b=Ce(O=>O.unpinAll),[S,k]=w.useState(""),N=Ce(O=>O.favoriteSessionIds),A=Ce(O=>O.toggleFavoriteSession),j=Ce(O=>O.sessionNicknames),M=Ce(O=>O.setSessionNickname),[z,V]=w.useState(null),[Q,B]=w.useState(""),G=y.map(O=>m.find(ee=>ee.id===O)).filter(O=>!!O&&O.content.length>0),{wsConnected:ae,wsUrl:se,provider:L,model:P}=Ge(),{entries:X,loading:de,error:I}=da(),{listSessions:J,deleteSession:H,resumeSession:ne,client:oe}=In();w.useEffect(()=>{var O;ae&&((O=oe==null?void 0:oe.getTodos)==null||O.call(oe))},[ae,oe]);const ye=d==null?void 0:d.id;w.useEffect(()=>{r==="history"&&ae&&J(50)},[r,ae,ye,J]);const D=O=>{if(!O)return"--";const ee=Math.floor((Date.now()-O)/1e3);return ee<60?`${ee}s`:`${Math.floor(ee/60)}m`},T=O=>{const ee=Date.parse(O);if(Number.isNaN(ee))return"";const re=Date.now()-ee;if(re<6e4)return"just now";if(re<36e5)return`${Math.floor(re/6e4)}m ago`;if(re<864e5)return`${Math.floor(re/36e5)}h ago`;const W=Math.floor(re/864e5);return W<7?`${W}d ago`:new Date(ee).toLocaleDateString()},U=(()=>{const O=S.trim().toLowerCase(),ee=O?X.filter(mt=>mt.title.toLowerCase().includes(O)||mt.model.toLowerCase().includes(O)||mt.provider.toLowerCase().includes(O)||mt.id.toLowerCase().includes(O)):X,re=new Date;re.setHours(0,0,0,0);const W=re.getTime(),be=W-864e5,we=W-6*864e5,Ae={today:[],yesterday:[],week:[],older:[]};for(const mt of ee){const Ft=Date.parse(mt.startedAt);if(Number.isNaN(Ft)){Ae.older.push(mt);continue}Ft>=W?Ae.today.push(mt):Ft>=be?Ae.yesterday.push(mt):Ft>=we?Ae.week.push(mt):Ae.older.push(mt)}const dt=new Set(N),st=ee.filter(mt=>dt.has(mt.id)),Te=[];st.length&&Te.push({label:"Favorites",rows:st,star:!0});const xe=mt=>mt.filter(Ft=>!dt.has(Ft.id)),De=xe(Ae.today),at=xe(Ae.yesterday),ht=xe(Ae.week),$t=xe(Ae.older);return De.length&&Te.push({label:"Today",rows:De}),at.length&&Te.push({label:"Yesterday",rows:at}),ht.length&&Te.push({label:"This week",rows:ht}),$t.length&&Te.push({label:"Earlier",rows:$t}),Te})(),E=O=>{O.preventDefault();const ee=O.clientX,re=i,W=we=>{s(re+(we.clientX-ee))},be=()=>{window.removeEventListener("mousemove",W),window.removeEventListener("mouseup",be),document.body.style.cursor="",document.body.style.userSelect=""};window.addEventListener("mousemove",W),window.addEventListener("mouseup",be),document.body.style.cursor="col-resize",document.body.style.userSelect="none"};return h.jsxs("aside",{style:{width:`${i}px`},className:"relative border-r bg-card flex flex-col shrink-0",children:[h.jsxs("div",{onMouseDown:E,onDoubleClick:()=>s(288),className:"group/handle absolute top-0 right-0 h-full w-2 cursor-col-resize z-10 flex items-center justify-end",title:"Drag to resize · double-click to reset",children:[h.jsx("div",{className:"h-full w-px bg-border group-hover/handle:bg-primary/60 group-hover/handle:w-0.5 transition-all"}),h.jsxs("div",{className:"absolute right-0 top-1/2 -translate-y-1/2 flex flex-col gap-0.5 opacity-0 group-hover/handle:opacity-100 transition-opacity pr-0.5",children:[h.jsx("span",{className:"h-1 w-1 rounded-full bg-primary/70"}),h.jsx("span",{className:"h-1 w-1 rounded-full bg-primary/70"}),h.jsx("span",{className:"h-1 w-1 rounded-full bg-primary/70"})]})]}),h.jsxs("div",{className:"flex items-center justify-between px-4 py-3 border-b",children:[h.jsxs("div",{className:"flex items-center gap-2",children:[h.jsx("div",{className:"w-6 h-6 rounded bg-primary flex items-center justify-center",children:h.jsx(kd,{className:"h-4 w-4 text-primary-foreground"})}),h.jsx("span",{className:"text-sm font-semibold tracking-tight",children:"WrongStack"})]}),h.jsx(Ve,{variant:"ghost",size:"icon",onClick:t,children:h.jsx(L2,{className:"h-4 w-4"})})]}),h.jsxs(_1,{value:r==="settings"?"chat":r,onValueChange:O=>l(O),className:"flex-1 flex flex-col",children:[h.jsxs(Yd,{className:"w-full rounded-none bg-transparent p-2 h-auto grid grid-cols-2",children:[h.jsxs(fl,{value:"chat",className:"flex-col gap-1.5 py-2 data-[state=active]:bg-primary/10",children:[h.jsx(z2,{className:"h-4 w-4"}),h.jsx("span",{className:"text-xs",children:"Chat"})]}),h.jsxs(fl,{value:"history",className:"flex-col gap-1.5 py-2 data-[state=active]:bg-primary/10",children:[h.jsx(qf,{className:"h-4 w-4"}),h.jsx("span",{className:"text-xs",children:"History"})]})]}),h.jsxs(dl,{value:"chat",className:"flex-1 flex flex-col m-0 overflow-hidden",children:[h.jsxs("div",{className:"px-4 py-3 border-b",children:[h.jsxs("div",{className:he("flex items-center gap-2 px-3 py-2 rounded-lg text-sm",ae?"bg-green-500/10 text-green-600 dark:text-green-400":"bg-yellow-500/10 text-yellow-600 dark:text-yellow-400"),children:[ae?h.jsx(a0,{className:"h-4 w-4"}):h.jsx(Sd,{className:"h-4 w-4"}),h.jsx("span",{className:"font-medium",children:ae?"Connected":"Disconnected"})]}),h.jsx("div",{className:"text-xs text-muted-foreground mt-2 px-1 font-mono",children:se})]}),h.jsxs("button",{type:"button",onClick:()=>l("settings"),className:"px-4 py-3 border-b text-left hover:bg-muted/40 transition-colors",children:[h.jsx("div",{className:"text-[10px] uppercase tracking-wider text-muted-foreground mb-1",children:"Active model"}),h.jsxs("div",{className:"font-mono text-xs truncate",children:[h.jsx("span",{className:"text-muted-foreground",children:L||"—"}),h.jsx("span",{className:"text-muted-foreground/40 mx-1",children:"/"}),h.jsx("span",{className:"font-medium",children:P||"—"})]})]}),h.jsxs("div",{className:"px-4 py-3 border-b space-y-3",children:[h.jsxs("h3",{className:"text-sm font-medium flex items-center gap-2",children:[h.jsx(Bf,{className:"h-4 w-4 text-muted-foreground"}),"Session"]}),h.jsxs("div",{className:"grid grid-cols-2 gap-2 text-xs",children:[h.jsxs("div",{className:"flex flex-col p-2 rounded-lg bg-muted/50",children:[h.jsx("span",{className:"text-muted-foreground",children:"Messages"}),h.jsx("span",{className:"text-lg font-semibold",children:m.length})]}),h.jsxs("div",{className:"flex flex-col p-2 rounded-lg bg-muted/50",children:[h.jsx("span",{className:"text-muted-foreground",children:"Duration"}),h.jsx("span",{className:"text-lg font-semibold",children:D((d==null?void 0:d.startedAt)??null)})]}),h.jsxs("div",{className:"flex flex-col p-2 rounded-lg bg-muted/50",children:[h.jsx("span",{className:"text-muted-foreground",children:"Input"}),h.jsx("span",{className:"text-lg font-semibold",children:u.input.toLocaleString()})]}),h.jsxs("div",{className:"flex flex-col p-2 rounded-lg bg-muted/50",children:[h.jsx("span",{className:"text-muted-foreground",children:"Output"}),h.jsx("span",{className:"text-lg font-semibold",children:u.output.toLocaleString()})]})]}),c>0&&h.jsxs("div",{className:"flex justify-between items-center p-2 rounded-lg bg-green-500/10",children:[h.jsx("span",{className:"text-sm text-muted-foreground",children:"Cost"}),h.jsxs("span",{className:"text-lg font-semibold text-green-600 dark:text-green-400",children:["$",c.toFixed(4)]})]})]}),p.length>0&&h.jsxs("div",{className:"px-4 py-3 border-b space-y-2",children:[h.jsxs("h3",{className:"text-sm font-medium flex items-center justify-between",children:[h.jsxs("span",{className:"flex items-center gap-2",children:[h.jsx(D2,{className:"h-4 w-4 text-muted-foreground"}),"Todos"]}),h.jsxs("span",{className:"text-[10px] text-muted-foreground tabular-nums",children:[p.filter(O=>O.status==="completed").length,"/",p.length]})]}),h.jsx("ul",{className:"space-y-1 max-h-48 overflow-y-auto pr-1",children:p.map(O=>{const ee=O.status==="completed"?hl:O.status==="in_progress"?y2:x2,re=O.status==="completed"?"text-green-600 dark:text-green-400 line-through opacity-70":O.status==="in_progress"?"text-amber-600 dark:text-amber-400":"text-muted-foreground";return h.jsxs("li",{className:he("flex items-start gap-2 text-xs leading-snug",re),children:[h.jsx(ee,{className:"h-3.5 w-3.5 mt-0.5 shrink-0"}),h.jsx("span",{className:"break-words",children:O.status==="in_progress"&&O.activeForm?O.activeForm:O.content})]},O.id)})})]}),G.length>0&&h.jsxs("div",{className:"px-4 py-3 border-b space-y-2",children:[h.jsxs("h3",{className:"text-sm font-medium flex items-center justify-between",children:[h.jsxs("span",{className:"flex items-center gap-2",children:[h.jsx(t0,{className:"h-4 w-4 text-amber-500"}),"Pinned"]}),h.jsx("button",{type:"button",onClick:b,className:"text-[10px] text-muted-foreground hover:text-destructive",children:"Clear"})]}),h.jsx("ul",{className:"space-y-1 max-h-48 overflow-y-auto pr-1",children:G.map(O=>{const ee=O.content.replace(/\s+/g," ").slice(0,80);return h.jsx("li",{children:h.jsxs("button",{type:"button",onClick:()=>{const re=document.querySelector(`[data-message-id="${O.id}"]`);re&&(re.scrollIntoView({behavior:"smooth",block:"center"}),re.classList.add("ring-2","ring-amber-500/60"),setTimeout(()=>{re.classList.remove("ring-2","ring-amber-500/60")},1600))},className:"w-full text-left text-xs px-2 py-1.5 rounded bg-muted/40 hover:bg-muted/70 border border-amber-500/20 leading-snug",title:O.content.slice(0,400),children:[ee,O.content.length>80?"…":""]})},O.id)})})]}),h.jsxs("div",{className:"px-4 py-3 border-b space-y-2",children:[h.jsxs(Ve,{variant:"outline",size:"sm",className:"w-full justify-start text-destructive hover:text-destructive",onClick:()=>{var O;x(),(O=oe==null?void 0:oe.clearContext)==null||O.call(oe)},children:[h.jsx(Ai,{className:"h-4 w-4 mr-2"}),"Clear context"]}),h.jsxs(Ve,{variant:"outline",size:"sm",className:"w-full justify-start",onClick:()=>{var O;return(O=oe==null?void 0:oe.newSession)==null?void 0:O.call(oe)},disabled:!ae,children:[h.jsx(Oi,{className:"h-4 w-4 mr-2"}),"New session"]}),h.jsxs(Ve,{variant:"outline",size:"sm",className:"w-full justify-start",onClick:()=>{var O;return(O=oe==null?void 0:oe.compactContext)==null?void 0:O.call(oe)},disabled:!ae,children:[h.jsx(Bf,{className:"h-4 w-4 mr-2"}),"Compact context"]})]}),h.jsx("div",{className:"flex-1"}),h.jsx("div",{className:"px-3 py-3 border-t",children:h.jsxs(Ve,{variant:"ghost",size:"sm",className:"w-full justify-start",onClick:()=>l("settings"),children:[h.jsx(bd,{className:"h-4 w-4 mr-2"}),"Settings"]})})]}),h.jsxs(dl,{value:"history",className:"flex-1 m-0 flex flex-col overflow-hidden",children:[h.jsxs("div",{className:"flex items-center justify-between px-4 py-2 border-b",children:[h.jsx("span",{className:"text-xs uppercase tracking-wider text-muted-foreground",children:"Recent sessions"}),h.jsx(Ve,{variant:"ghost",size:"icon",className:"h-6 w-6",onClick:()=>J(50),disabled:!ae,title:"Refresh",children:de?h.jsx($r,{className:"h-3.5 w-3.5 animate-spin"}):h.jsx(n0,{className:"h-3.5 w-3.5"})})]}),X.length>3&&h.jsx("div",{className:"px-3 py-2 border-b",children:h.jsxs("div",{className:"relative",children:[h.jsx(pa,{className:"absolute left-2 top-1/2 -translate-y-1/2 h-3.5 w-3.5 text-muted-foreground/60"}),h.jsx("input",{type:"text",value:S,onChange:O=>k(O.target.value),placeholder:"Filter title, model, provider…",className:"w-full pl-7 pr-7 py-1 text-xs rounded-md bg-muted/40 border border-transparent focus:bg-background focus:border-input focus:outline-none focus:ring-1 focus:ring-ring placeholder:text-muted-foreground/50"}),S&&h.jsx("button",{type:"button",onClick:()=>k(""),className:"absolute right-1 top-1/2 -translate-y-1/2 text-muted-foreground/60 hover:text-foreground p-0.5",title:"Clear filter",children:h.jsx(gl,{className:"h-3 w-3"})})]})}),I&&h.jsx("div",{className:"px-4 py-2 text-xs text-destructive bg-destructive/5 border-b",children:I}),h.jsx(As,{className:"flex-1",children:X.length===0&&!de?h.jsxs("div",{className:"text-center text-muted-foreground py-8 px-4",children:[h.jsx(qf,{className:"h-8 w-8 mx-auto mb-3 opacity-20"}),h.jsx("p",{className:"text-sm font-medium",children:"No history yet"}),h.jsx("p",{className:"text-xs mt-1",children:"Your conversations will appear here"})]}):U.length===0?h.jsxs("div",{className:"text-center text-muted-foreground py-8 px-4",children:[h.jsx(pa,{className:"h-8 w-8 mx-auto mb-3 opacity-20"}),h.jsx("p",{className:"text-sm font-medium",children:"No matches"}),h.jsx("p",{className:"text-xs mt-1",children:"Try a different filter"})]}):h.jsx("div",{className:"p-2 space-y-3",children:U.map(O=>h.jsxs("div",{className:"space-y-1",children:[h.jsxs("div",{className:he("sticky top-0 z-[1] px-1 pb-1 text-[10px] uppercase tracking-wider font-semibold bg-card/90 backdrop-blur-sm flex items-center gap-1",O.star?"text-amber-500":"text-muted-foreground/80"),children:[O.star&&h.jsx(sy,{className:"h-3 w-3 fill-current"}),O.label," ",h.jsxs("span",{className:"text-muted-foreground/50 font-normal normal-case ml-1",children:["(",O.rows.length,")"]})]}),O.rows.map(ee=>h.jsxs("div",{className:he("group relative rounded-md border text-sm transition-colors",ee.isCurrent?"bg-primary/5 border-primary/40":"bg-card border-border/60 hover:bg-muted/40 hover:border-primary/40"),children:[h.jsx("button",{type:"button",disabled:ee.isCurrent||z===ee.id,onClick:()=>ne(ee.id),onDoubleClick:re=>{re.stopPropagation(),V(ee.id),B(j[ee.id]??ee.title??"")},className:"block w-full rounded-md px-3 py-2 pr-16 text-left disabled:cursor-default focus:outline-none focus-visible:ring-2 focus-visible:ring-ring",children:h.jsxs("div",{className:"min-w-0 flex-1",children:[z===ee.id?h.jsx("input",{autoFocus:!0,value:Q,onChange:re=>B(re.target.value),onClick:re=>re.stopPropagation(),onBlur:()=>{M(ee.id,Q),V(null)},onKeyDown:re=>{re.key==="Enter"?(re.preventDefault(),M(ee.id,Q),V(null)):re.key==="Escape"&&(re.preventDefault(),V(null))},placeholder:ee.title||"Nickname",className:"w-full text-sm bg-background border border-input rounded px-1.5 py-0.5 focus:outline-none focus:ring-1 focus:ring-ring"}):h.jsx("div",{className:"font-medium truncate text-foreground",title:j[ee.id]?`${j[ee.id]} — original: ${ee.title}`:`${ee.title}
|
|
562
|
-
|
|
563
|
-
Double-click to rename`,children:j[ee.id]||ee.title||"(empty)"}),h.jsxs("div",{className:"text-[10px] text-muted-foreground font-mono truncate mt-0.5",children:[ee.provider,"/",ee.model]}),h.jsxs("div",{className:"flex items-center gap-2 text-[10px] text-muted-foreground/80 mt-0.5",children:[h.jsx("span",{children:T(ee.startedAt)}),ee.tokenTotal>0&&h.jsxs(h.Fragment,{children:[h.jsx("span",{children:"·"}),h.jsxs("span",{className:"tabular-nums",children:[ee.tokenTotal.toLocaleString()," tok"]})]}),ee.isCurrent&&h.jsxs(h.Fragment,{children:[h.jsx("span",{children:"·"}),h.jsx("span",{className:"text-primary font-medium",children:"active"})]})]})]})}),h.jsxs("div",{className:"absolute right-2 top-2 flex items-center gap-1",children:[h.jsx("button",{type:"button",onClick:()=>A(ee.id),className:he("transition-opacity hover:text-amber-500",N.includes(ee.id)?"opacity-100 text-amber-500":"opacity-0 group-hover:opacity-100 text-muted-foreground"),title:N.includes(ee.id)?"Unfavorite":"Mark as favorite",children:h.jsx(sy,{className:he("h-3.5 w-3.5",N.includes(ee.id)&&"fill-current")})}),!ee.isCurrent&&h.jsx("button",{type:"button",onClick:()=>{window.confirm(`Delete session "${ee.title}"?`)&&H(ee.id)},className:"opacity-0 group-hover:opacity-100 transition-opacity text-muted-foreground hover:text-destructive",title:"Delete session",children:h.jsx(Ai,{className:"h-3.5 w-3.5"})})]})]},ee.id))]},O.label))})})]})]})]})}const qr=w.forwardRef(({className:t,type:r,...l},i)=>h.jsx("input",{type:r,className:he("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",t),ref:i,...l}));qr.displayName="Input";function YT(){var xl;const{setCurrentView:t}=Ce(),{provider:r,model:l,setProvider:i,setModel:s,wsConnected:u}=Ge(),{theme:c,setTheme:d}=wx(),p=In(),m=p.client,x=p.listProviders,y=p.listSavedProviders,[b,S]=w.useState([]),[k,N]=w.useState({}),[A,j]=w.useState([]),[M,z]=w.useState(!1),[V,Q]=w.useState(!1),[B,G]=w.useState(!1),[ae,se]=w.useState(null),[L,P]=w.useState("catalog"),[X,de]=w.useState(null),[I,J]=w.useState(""),[H,ne]=w.useState(""),[oe,ye]=w.useState(!1),[D,T]=w.useState(!1),[U,E]=w.useState(""),[O,ee]=w.useState("openai-compatible"),[re,W]=w.useState(""),[be,we]=w.useState(""),Ae=b.find(ue=>ue.id===r);w.useEffect(()=>{const ue=vt=>{if(vt.type==="provider.catalog"){const yt=vt.payload;S(yt.providers.sort((it,Mt)=>it.id.localeCompare(Mt.id))),z(!1)}},je=vt=>{if(vt.type==="provider.models"){const yt=vt.payload;N(it=>({...it,[yt.provider]:yt.models})),Q(!1)}},K=vt=>{if(vt.type==="providers.saved"){const it=vt.payload.providers.sort((Mt,Ze)=>Mt.id.localeCompare(Ze.id));j(it),G(!1),it.length>0&&P("saved")}},fe=vt=>{if(vt.type==="key.operation_result"){const yt=vt.payload;se(yt),setTimeout(()=>se(null),3e3),y==null||y()}};if(!u||!m)return;const ke=m.on("provider.catalog",ue),ze=m.on("provider.models",je),Fe=m.on("providers.saved",K),zt=m.on("key.operation_result",fe);return z(!0),G(!0),x==null||x(),y==null||y(),()=>{ke==null||ke(),ze==null||ze(),Fe==null||Fe(),zt==null||zt()}},[u,m,x,y]);const dt=w.useCallback(ue=>{var je;i(ue),k[ue]||(Q(!0),(je=p.listProviderModels)==null||je.call(p,ue))},[k,i,p]),st=w.useCallback(ue=>{var je;s(ue),(je=p.switchModel)==null||je.call(p,r,ue),se({success:!0,message:`Switching to ${r} / ${ue}…`})},[s,p,r]),Te=w.useCallback(ue=>{var je;!I.trim()||!H.trim()||((je=p.addKey)==null||je.call(p,ue,I.trim(),H.trim()),J(""),ne(""),de(null))},[p,I,H]),xe=w.useCallback((ue,je)=>{var K;(K=p.deleteKey)==null||K.call(p,ue,je)},[p]),De=w.useCallback((ue,je)=>{var K;(K=p.setActiveKey)==null||K.call(p,ue,je)},[p]),at=w.useCallback(()=>{var ue;U.trim()&&((ue=p.addProvider)==null||ue.call(p,U.trim(),O,re||void 0,be||void 0),E(""),ee("openai-compatible"),W(""),we(""),T(!1))},[p,U,O,re,be]),ht=w.useCallback(ue=>{var je;(je=p.removeProvider)==null||je.call(p,ue)},[p]),[$t,mt]=w.useState(""),Ft=["anthropic","openai","google","openai-compatible"],cr=$t.trim()?b.filter(ue=>{const je=$t.trim().toLowerCase();return ue.id.toLowerCase().includes(je)||ue.name.toLowerCase().includes(je)||ue.family.toLowerCase().includes(je)}):b,wa=cr.reduce((ue,je)=>(ue[je.family]||(ue[je.family]=[]),ue[je.family].push(je),ue),{});return h.jsxs("div",{className:"flex flex-col h-full",children:[h.jsxs("header",{className:"flex items-center justify-between px-4 py-3 border-b bg-card shrink-0",children:[h.jsx("h1",{className:"text-lg font-semibold",children:"Settings"}),h.jsx(Ve,{variant:"ghost",size:"icon",onClick:()=>t("chat"),children:h.jsx(gl,{className:"h-4 w-4"})})]}),h.jsx(As,{className:"flex-1",children:h.jsx("div",{className:"p-6 max-w-2xl mx-auto",children:h.jsxs(_1,{defaultValue:"provider",children:[h.jsxs(Yd,{className:"w-full justify-start mb-6 grid grid-cols-4",children:[h.jsxs(fl,{value:"provider",className:"gap-2",children:[h.jsx(O2,{className:"h-4 w-4"}),"Provider"]}),h.jsxs(fl,{value:"model",className:"gap-2",children:[h.jsx(Ti,{className:"h-4 w-4"}),"Model"]}),h.jsxs(fl,{value:"connection",className:"gap-2",children:[h.jsx(ki,{className:"h-4 w-4"}),"Connection"]}),h.jsxs(fl,{value:"appearance",className:"gap-2",children:[h.jsx(_2,{className:"h-4 w-4"}),"Appearance"]})]}),h.jsxs(dl,{value:"provider",className:"space-y-4",children:[h.jsxs("div",{className:"flex gap-2 mb-4",children:[h.jsxs(Ve,{variant:L==="catalog"?"default":"outline",size:"sm",onClick:()=>P("catalog"),children:[h.jsx(ki,{className:"h-4 w-4 mr-1"}),"Catalog"]}),h.jsxs(Ve,{variant:L==="saved"?"default":"outline",size:"sm",onClick:()=>P("saved"),children:[h.jsx(lf,{className:"h-4 w-4 mr-1"}),"Saved (",A.length,")"]})]}),ae&&h.jsxs("div",{className:he("p-3 rounded-lg mb-4 flex items-center gap-2",ae.success?"bg-green-500/10 text-green-600":"bg-red-500/10 text-red-600"),children:[ae.success?h.jsx(hl,{className:"h-4 w-4"}):h.jsx(g2,{className:"h-4 w-4"}),ae.message]}),L==="catalog"&&h.jsxs("div",{className:"space-y-4",children:[h.jsx(qr,{placeholder:`Search ${b.length} providers (name / id / family)…`,value:$t,onChange:ue=>mt(ue.target.value),className:"text-sm"}),M&&b.length===0?h.jsxs("div",{className:"flex items-center justify-center py-8",children:[h.jsx($r,{className:"h-6 w-6 animate-spin text-muted-foreground"}),h.jsx("span",{className:"ml-2 text-muted-foreground",children:"Loading catalog..."})]}):cr.length===0&&$t?h.jsxs("div",{className:"text-center py-8 text-muted-foreground text-sm",children:['No providers match "',h.jsx("span",{className:"font-mono",children:$t}),'".']}):h.jsx(h.Fragment,{children:Ft.map(ue=>{const je=wa[ue];return je!=null&&je.length?h.jsxs("div",{className:"space-y-2",children:[h.jsx("h3",{className:"text-sm font-semibold text-muted-foreground uppercase tracking-wider",children:ue}),h.jsx("div",{className:"grid grid-cols-1 gap-2",children:je.map(K=>h.jsxs("button",{type:"button",onClick:()=>dt(K.id),className:he("flex flex-col items-start p-3 rounded-lg border text-left transition-all",r===K.id?"border-primary bg-primary/5 ring-2 ring-primary/20":"border-border hover:bg-muted"),children:[h.jsxs("div",{className:"flex w-full justify-between items-start",children:[h.jsxs("div",{children:[h.jsx("span",{className:"font-medium",children:K.name}),h.jsxs("span",{className:"ml-2 text-xs text-muted-foreground",children:["(",K.id,")"]})]}),h.jsxs("div",{className:"flex items-center gap-2",children:[K.hasApiKey&&h.jsxs("span",{className:"text-xs bg-green-500/10 text-green-600 px-2 py-0.5 rounded",children:[h.jsx(lf,{className:"h-3 w-3 inline mr-1"}),"Configured"]}),K.envVars[0]&&h.jsxs("span",{className:"text-xs text-muted-foreground",children:["ENV: ",K.envVars[0]]}),r===K.id&&h.jsx(hl,{className:"h-4 w-4 text-primary"})]})]}),h.jsxs("div",{className:"text-xs text-muted-foreground mt-1",children:[K.modelCount," models",K.apiBase&&` · ${K.apiBase}`]})]},K.id))})]},ue):null})})]}),L==="saved"&&h.jsxs("div",{className:"space-y-4",children:[h.jsxs("div",{className:"flex justify-between items-center",children:[h.jsx("p",{className:"text-sm text-muted-foreground",children:"Manage your API keys and provider configurations"}),h.jsxs(Ve,{size:"sm",variant:"outline",onClick:()=>T(!D),children:[h.jsx(oy,{className:"h-4 w-4 mr-1"}),"Add Provider"]})]}),D&&h.jsxs("div",{className:"p-4 border rounded-lg space-y-3 bg-muted/50",children:[h.jsx("h4",{className:"font-medium",children:"Add Custom Provider"}),h.jsx(qr,{placeholder:"Provider ID (e.g. my-llm-server)",value:U,onChange:ue=>E(ue.target.value)}),h.jsxs("select",{className:"flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-sm",value:O,onChange:ue=>ee(ue.target.value),children:[h.jsx("option",{value:"anthropic",children:"Anthropic"}),h.jsx("option",{value:"openai",children:"OpenAI"}),h.jsx("option",{value:"openai-compatible",children:"OpenAI Compatible"}),h.jsx("option",{value:"google",children:"Google"})]}),h.jsx(qr,{placeholder:"Base URL (optional, e.g. http://localhost:11434/v1)",value:re,onChange:ue=>W(ue.target.value)}),h.jsx(qr,{type:"password",placeholder:"API Key (optional)",value:be,onChange:ue=>we(ue.target.value)}),h.jsxs("div",{className:"flex gap-2",children:[h.jsx(Ve,{size:"sm",onClick:at,disabled:!U.trim(),children:"Add"}),h.jsx(Ve,{size:"sm",variant:"ghost",onClick:()=>T(!1),children:"Cancel"})]})]}),B?h.jsx("div",{className:"flex items-center justify-center py-8",children:h.jsx($r,{className:"h-6 w-6 animate-spin text-muted-foreground"})}):A.length===0?h.jsxs("div",{className:"text-center py-8 text-muted-foreground",children:[h.jsx(lf,{className:"h-8 w-8 mx-auto mb-2 opacity-50"}),h.jsx("p",{children:"No saved providers yet"}),h.jsx("p",{className:"text-sm",children:"Add a provider to get started"})]}):A.map(ue=>h.jsxs("div",{className:"border rounded-lg p-4 space-y-3",children:[h.jsxs("div",{className:"flex justify-between items-start",children:[h.jsxs("div",{children:[h.jsx("h4",{className:"font-medium",children:ue.id}),ue.family&&h.jsx("span",{className:"text-xs text-muted-foreground",children:ue.family})]}),h.jsx("div",{className:"flex gap-2",children:h.jsx(Ve,{size:"icon",variant:"ghost",onClick:()=>ht(ue.id),children:h.jsx(Ai,{className:"h-4 w-4 text-destructive"})})})]}),ue.baseUrl&&h.jsxs("div",{className:"text-xs text-muted-foreground",children:[h.jsx(ki,{className:"h-3 w-3 inline mr-1"}),ue.baseUrl]}),h.jsxs("div",{className:"space-y-2",children:[h.jsxs("div",{className:"flex justify-between items-center",children:[h.jsx("span",{className:"text-sm font-medium",children:"API Keys"}),h.jsxs(Ve,{size:"sm",variant:"ghost",onClick:()=>de(X===ue.id?null:ue.id),children:[h.jsx(oy,{className:"h-3 w-3 mr-1"}),"Add Key"]})]}),ue.apiKeys.length===0&&!X&&h.jsx("p",{className:"text-xs text-muted-foreground",children:"No keys configured"}),ue.apiKeys.map(je=>h.jsxs("div",{className:"flex items-center justify-between p-2 bg-muted/50 rounded",children:[h.jsxs("div",{children:[h.jsx("span",{className:"text-sm font-medium",children:je.label}),je.isActive&&h.jsx("span",{className:"ml-2 text-xs bg-green-500/10 text-green-600 px-1.5 py-0.5 rounded",children:"Active"}),h.jsx("div",{className:"text-xs text-muted-foreground font-mono",children:je.maskedKey})]}),h.jsxs("div",{className:"flex gap-1",children:[!je.isActive&&h.jsx(Ve,{size:"sm",variant:"ghost",onClick:()=>De(ue.id,je.label),children:"Set Active"}),h.jsx(Ve,{size:"icon",variant:"ghost",onClick:()=>xe(ue.id,je.label),children:h.jsx(Ai,{className:"h-3 w-3 text-destructive"})})]})]},je.label)),X===ue.id&&h.jsxs("div",{className:"p-3 border rounded space-y-2 bg-background",children:[h.jsx(qr,{placeholder:"Key label (e.g. default, production)",value:I,onChange:je=>J(je.target.value)}),h.jsxs("div",{className:"flex gap-2",children:[h.jsx(qr,{type:oe?"text":"password",placeholder:"API key",value:H,onChange:je=>ne(je.target.value)}),h.jsx(Ve,{size:"icon",variant:"ghost",onClick:()=>ye(!oe),children:oe?h.jsx(S2,{className:"h-4 w-4"}):h.jsx(w2,{className:"h-4 w-4"})})]}),h.jsxs("div",{className:"flex gap-2",children:[h.jsx(Ve,{size:"sm",onClick:()=>Te(ue.id),disabled:!I.trim()||!H.trim(),children:"Save Key"}),h.jsx(Ve,{size:"sm",variant:"ghost",onClick:()=>{de(null),J(""),ne("")},children:"Cancel"})]})]})]})]},ue.id))]})]}),h.jsx(dl,{value:"model",className:"space-y-4",children:r?h.jsxs(h.Fragment,{children:[h.jsxs("div",{className:"flex items-center justify-between",children:[h.jsxs("div",{children:[h.jsx("p",{className:"text-sm font-medium",children:(Ae==null?void 0:Ae.name)||r}),h.jsx("p",{className:"text-xs text-muted-foreground",children:r})]}),h.jsx(Ve,{variant:"ghost",size:"sm",onClick:()=>{var ue;Q(!0),(ue=p.listProviderModels)==null||ue.call(p,r)},children:h.jsx(n0,{className:he("h-4 w-4",V&&"animate-spin")})})]}),V&&!k[r]?h.jsxs("div",{className:"flex items-center justify-center py-8",children:[h.jsx($r,{className:"h-6 w-6 animate-spin text-muted-foreground"}),h.jsx("span",{className:"ml-2 text-muted-foreground",children:"Loading models..."})]}):h.jsxs("div",{className:"space-y-1",children:[(k[r]||[]).map(ue=>h.jsxs("button",{type:"button",onClick:()=>st(ue.id),className:he("w-full flex items-center justify-between p-3 rounded-lg border text-left transition-all",l===ue.id?"border-primary bg-primary/5 ring-2 ring-primary/20":"border-border hover:bg-muted"),children:[h.jsxs("div",{children:[h.jsx("span",{className:"font-medium",children:ue.name||ue.id}),h.jsx("div",{className:"flex gap-2 mt-1",children:ue.capabilities.map(je=>h.jsx("span",{className:"text-xs bg-muted px-1.5 py-0.5 rounded",children:je},je))})]}),h.jsxs("div",{className:"text-right text-xs text-muted-foreground",children:[ue.contextWindow&&h.jsxs("div",{children:[ue.contextWindow/1e3,"k context"]}),ue.inputCost&&ue.outputCost&&h.jsxs("div",{children:["$",ue.inputCost,"/$",ue.outputCost]}),l===ue.id&&h.jsx(hl,{className:"h-4 w-4 text-primary mt-1"})]})]},ue.id)),((xl=k[r])==null?void 0:xl.length)===0&&h.jsx("p",{className:"text-sm text-muted-foreground text-center py-4",children:"No models found for this provider. The catalog might be empty or still loading."})]})]}):h.jsxs("div",{className:"text-center py-8 text-muted-foreground",children:[h.jsx(Ti,{className:"h-8 w-8 mx-auto mb-2 opacity-50"}),h.jsx("p",{children:"Select a provider first"})]})}),h.jsxs(dl,{value:"connection",className:"space-y-4",children:[h.jsxs("div",{className:"space-y-3",children:[h.jsxs("label",{htmlFor:"websocket-url",className:"text-sm font-medium flex items-center gap-2",children:[h.jsx(ki,{className:"h-4 w-4 text-muted-foreground"}),"WebSocket Server URL"]}),h.jsx(qr,{id:"websocket-url",value:Ge.getState().wsUrl,onChange:ue=>Ge.getState().setConfig({wsUrl:ue.target.value}),placeholder:"ws://localhost:3457",className:"font-mono text-sm"}),h.jsx("p",{className:"text-xs text-muted-foreground",children:"URL of the WrongStack WebSocket server. The server runs alongside the CLI."})]}),h.jsxs("div",{className:"p-4 rounded-lg border bg-muted/50",children:[h.jsx("h4",{className:"text-sm font-medium mb-2",children:"Starting the WebSocket Server"}),h.jsxs("p",{className:"text-xs text-muted-foreground mb-3",children:["Standalone: run ",h.jsx("code",{className:"bg-muted px-1 py-0.5 rounded",children:"./dev.ps1"})," from the repo root, or set WS_HOST/WS_PORT before launching"," ",h.jsx("code",{className:"bg-muted px-1 py-0.5 rounded",children:"node packages/webui/dist/server/entry.js"}),". Or alongside the CLI: ",h.jsx("code",{className:"bg-muted px-1 py-0.5 rounded",children:"wstack --webui"}),"."]})]})]}),h.jsxs(dl,{value:"appearance",className:"space-y-4",children:[h.jsxs("div",{children:[h.jsx("h3",{className:"text-sm font-semibold mb-3",children:"Theme"}),h.jsxs("div",{className:"grid grid-cols-3 gap-2 max-w-md",children:[h.jsxs(Ve,{variant:c==="light"?"default":"outline",size:"sm",onClick:()=>d("light"),children:[h.jsx(vd,{className:"h-4 w-4 mr-1"}),"Light"]}),h.jsxs(Ve,{variant:c==="dark"?"default":"outline",size:"sm",onClick:()=>d("dark"),children:[h.jsx(xd,{className:"h-4 w-4 mr-1"}),"Dark"]}),h.jsxs(Ve,{variant:c==="system"?"default":"outline",size:"sm",onClick:()=>d("system"),children:[h.jsx(yd,{className:"h-4 w-4 mr-1"}),"System"]})]}),h.jsx("p",{className:"text-xs text-muted-foreground mt-2",children:"System follows your OS-level light/dark preference."})]}),h.jsxs("div",{className:"pt-2 border-t",children:[h.jsx("h3",{className:"text-sm font-semibold mb-3 mt-3",children:"Preferences"}),h.jsx(ix,{label:"Compact density",hint:"Tighter spacing throughout the chat. Toggle anywhere with Ctrl+Shift+D.",selector:ue=>ue.compactMode,onChange:()=>Ce.getState().toggleCompactMode()}),h.jsx(ix,{label:"Sound on completion",hint:"Play a soft chime when a run finishes — useful when working in another tab.",selector:null,configKey:"soundOnComplete"})]})]})]})})})]})}function ix({label:t,hint:r,selector:l,onChange:i,configKey:s}){const u=Ce(m=>l?l(m):!1),c=Ge(m=>s?m[s]:!1),d=l?u:c,p=()=>{if(l)i==null||i();else if(s==="soundOnComplete"){const m=!Ge.getState().soundOnComplete;Ge.getState().setSoundOnComplete(m),m&&u0(()=>Promise.resolve().then(()=>s0),void 0).then(x=>x.playCompletionChime()).catch(()=>{})}};return h.jsxs("div",{className:"flex items-start justify-between gap-3 py-2",children:[h.jsxs("div",{className:"min-w-0 flex-1",children:[h.jsx("div",{className:"text-sm font-medium",children:t}),r&&h.jsx("div",{className:"text-xs text-muted-foreground mt-0.5",children:r})]}),h.jsx("button",{type:"button",role:"switch","aria-checked":d,onClick:p,className:he("shrink-0 relative inline-flex h-5 w-9 rounded-full border transition-colors",d?"bg-primary border-primary":"bg-muted border-input hover:bg-muted/80"),children:h.jsx("span",{className:he("absolute top-0.5 left-0.5 h-3.5 w-3.5 rounded-full bg-background shadow transition-transform",d&&"translate-x-4")})})]})}function GT(t,r=globalThis==null?void 0:globalThis.document){const l=hn(t);w.useEffect(()=>{const i=s=>{s.key==="Escape"&&l(s)};return r.addEventListener("keydown",i,{capture:!0}),()=>r.removeEventListener("keydown",i,{capture:!0})},[l,r])}var PT="DismissableLayer",rd="dismissableLayer.update",XT="dismissableLayer.pointerDownOutside",QT="dismissableLayer.focusOutside",ox,L1=w.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),U1=w.forwardRef((t,r)=>{const{disableOutsidePointerEvents:l=!1,onEscapeKeyDown:i,onPointerDownOutside:s,onFocusOutside:u,onInteractOutside:c,onDismiss:d,...p}=t,m=w.useContext(L1),[x,y]=w.useState(null),b=(x==null?void 0:x.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,S]=w.useState({}),k=It(r,G=>y(G)),N=Array.from(m.layers),[A]=[...m.layersWithOutsidePointerEventsDisabled].slice(-1),j=N.indexOf(A),M=x?N.indexOf(x):-1,z=m.layersWithOutsidePointerEventsDisabled.size>0,V=M>=j,Q=JT(G=>{const ae=G.target,se=[...m.branches].some(L=>L.contains(ae));!V||se||(s==null||s(G),c==null||c(G),G.defaultPrevented||d==null||d())},b),B=WT(G=>{const ae=G.target;[...m.branches].some(L=>L.contains(ae))||(u==null||u(G),c==null||c(G),G.defaultPrevented||d==null||d())},b);return GT(G=>{M===m.layers.size-1&&(i==null||i(G),!G.defaultPrevented&&d&&(G.preventDefault(),d()))},b),w.useEffect(()=>{if(x)return l&&(m.layersWithOutsidePointerEventsDisabled.size===0&&(ox=b.body.style.pointerEvents,b.body.style.pointerEvents="none"),m.layersWithOutsidePointerEventsDisabled.add(x)),m.layers.add(x),sx(),()=>{l&&m.layersWithOutsidePointerEventsDisabled.size===1&&(b.body.style.pointerEvents=ox)}},[x,b,l,m]),w.useEffect(()=>()=>{x&&(m.layers.delete(x),m.layersWithOutsidePointerEventsDisabled.delete(x),sx())},[x,m]),w.useEffect(()=>{const G=()=>S({});return document.addEventListener(rd,G),()=>document.removeEventListener(rd,G)},[]),h.jsx(Tt.div,{...p,ref:k,style:{pointerEvents:z?V?"auto":"none":void 0,...t.style},onFocusCapture:gt(t.onFocusCapture,B.onFocusCapture),onBlurCapture:gt(t.onBlurCapture,B.onBlurCapture),onPointerDownCapture:gt(t.onPointerDownCapture,Q.onPointerDownCapture)})});U1.displayName=PT;var KT="DismissableLayerBranch",ZT=w.forwardRef((t,r)=>{const l=w.useContext(L1),i=w.useRef(null),s=It(r,i);return w.useEffect(()=>{const u=i.current;if(u)return l.branches.add(u),()=>{l.branches.delete(u)}},[l.branches]),h.jsx(Tt.div,{...t,ref:s})});ZT.displayName=KT;function JT(t,r=globalThis==null?void 0:globalThis.document){const l=hn(t),i=w.useRef(!1),s=w.useRef(()=>{});return w.useEffect(()=>{const u=d=>{if(d.target&&!i.current){let p=function(){B1(XT,l,m,{discrete:!0})};const m={originalEvent:d};d.pointerType==="touch"?(r.removeEventListener("click",s.current),s.current=p,r.addEventListener("click",s.current,{once:!0})):p()}else r.removeEventListener("click",s.current);i.current=!1},c=window.setTimeout(()=>{r.addEventListener("pointerdown",u)},0);return()=>{window.clearTimeout(c),r.removeEventListener("pointerdown",u),r.removeEventListener("click",s.current)}},[r,l]),{onPointerDownCapture:()=>i.current=!0}}function WT(t,r=globalThis==null?void 0:globalThis.document){const l=hn(t),i=w.useRef(!1);return w.useEffect(()=>{const s=u=>{u.target&&!i.current&&B1(QT,l,{originalEvent:u},{discrete:!1})};return r.addEventListener("focusin",s),()=>r.removeEventListener("focusin",s)},[r,l]),{onFocusCapture:()=>i.current=!0,onBlurCapture:()=>i.current=!1}}function sx(){const t=new CustomEvent(rd);document.dispatchEvent(t)}function B1(t,r,l,{discrete:i}){const s=l.originalEvent.target,u=new CustomEvent(t,{bubbles:!1,cancelable:!0,detail:l});r&&s.addEventListener(t,r,{once:!0}),i?sw(s,u):s.dispatchEvent(u)}var Af="focusScope.autoFocusOnMount",Mf="focusScope.autoFocusOnUnmount",ux={bubbles:!1,cancelable:!0},eA="FocusScope",H1=w.forwardRef((t,r)=>{const{loop:l=!1,trapped:i=!1,onMountAutoFocus:s,onUnmountAutoFocus:u,...c}=t,[d,p]=w.useState(null),m=hn(s),x=hn(u),y=w.useRef(null),b=It(r,N=>p(N)),S=w.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;w.useEffect(()=>{if(i){let N=function(z){if(S.paused||!d)return;const V=z.target;d.contains(V)?y.current=V:Ir(y.current,{select:!0})},A=function(z){if(S.paused||!d)return;const V=z.relatedTarget;V!==null&&(d.contains(V)||Ir(y.current,{select:!0}))},j=function(z){if(document.activeElement===document.body)for(const Q of z)Q.removedNodes.length>0&&Ir(d)};document.addEventListener("focusin",N),document.addEventListener("focusout",A);const M=new MutationObserver(j);return d&&M.observe(d,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",N),document.removeEventListener("focusout",A),M.disconnect()}}},[i,d,S.paused]),w.useEffect(()=>{if(d){fx.add(S);const N=document.activeElement;if(!d.contains(N)){const j=new CustomEvent(Af,ux);d.addEventListener(Af,m),d.dispatchEvent(j),j.defaultPrevented||(tA(iA(q1(d)),{select:!0}),document.activeElement===N&&Ir(d))}return()=>{d.removeEventListener(Af,m),setTimeout(()=>{const j=new CustomEvent(Mf,ux);d.addEventListener(Mf,x),d.dispatchEvent(j),j.defaultPrevented||Ir(N??document.body,{select:!0}),d.removeEventListener(Mf,x),fx.remove(S)},0)}}},[d,m,x,S]);const k=w.useCallback(N=>{if(!l&&!i||S.paused)return;const A=N.key==="Tab"&&!N.altKey&&!N.ctrlKey&&!N.metaKey,j=document.activeElement;if(A&&j){const M=N.currentTarget,[z,V]=nA(M);z&&V?!N.shiftKey&&j===V?(N.preventDefault(),l&&Ir(z,{select:!0})):N.shiftKey&&j===z&&(N.preventDefault(),l&&Ir(V,{select:!0})):j===M&&N.preventDefault()}},[l,i,S.paused]);return h.jsx(Tt.div,{tabIndex:-1,...c,ref:b,onKeyDown:k})});H1.displayName=eA;function tA(t,{select:r=!1}={}){const l=document.activeElement;for(const i of t)if(Ir(i,{select:r}),document.activeElement!==l)return}function nA(t){const r=q1(t),l=cx(r,t),i=cx(r.reverse(),t);return[l,i]}function q1(t){const r=[],l=document.createTreeWalker(t,NodeFilter.SHOW_ELEMENT,{acceptNode:i=>{const s=i.tagName==="INPUT"&&i.type==="hidden";return i.disabled||i.hidden||s?NodeFilter.FILTER_SKIP:i.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;l.nextNode();)r.push(l.currentNode);return r}function cx(t,r){for(const l of t)if(!rA(l,{upTo:r}))return l}function rA(t,{upTo:r}){if(getComputedStyle(t).visibility==="hidden")return!0;for(;t;){if(r!==void 0&&t===r)return!1;if(getComputedStyle(t).display==="none")return!0;t=t.parentElement}return!1}function lA(t){return t instanceof HTMLInputElement&&"select"in t}function Ir(t,{select:r=!1}={}){if(t&&t.focus){const l=document.activeElement;t.focus({preventScroll:!0}),t!==l&&lA(t)&&r&&t.select()}}var fx=aA();function aA(){let t=[];return{add(r){const l=t[0];r!==l&&(l==null||l.pause()),t=dx(t,r),t.unshift(r)},remove(r){var l;t=dx(t,r),(l=t[0])==null||l.resume()}}}function dx(t,r){const l=[...t],i=l.indexOf(r);return i!==-1&&l.splice(i,1),l}function iA(t){return t.filter(r=>r.tagName!=="A")}var oA="Portal",I1=w.forwardRef((t,r)=>{var d;const{container:l,...i}=t,[s,u]=w.useState(!1);ha(()=>u(!0),[]);const c=l||s&&((d=globalThis==null?void 0:globalThis.document)==null?void 0:d.body);return c?tw.createPortal(h.jsx(Tt.div,{...i,ref:r}),c):null});I1.displayName=oA;var Df=0;function sA(){w.useEffect(()=>{const t=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",t[0]??hx()),document.body.insertAdjacentElement("beforeend",t[1]??hx()),Df++,()=>{Df===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(r=>r.remove()),Df--}},[])}function hx(){const t=document.createElement("span");return t.setAttribute("data-radix-focus-guard",""),t.tabIndex=0,t.style.outline="none",t.style.opacity="0",t.style.position="fixed",t.style.pointerEvents="none",t}var Bn=function(){return Bn=Object.assign||function(r){for(var l,i=1,s=arguments.length;i<s;i++){l=arguments[i];for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(r[u]=l[u])}return r},Bn.apply(this,arguments)};function V1(t,r){var l={};for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&r.indexOf(i)<0&&(l[i]=t[i]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(t);s<i.length;s++)r.indexOf(i[s])<0&&Object.prototype.propertyIsEnumerable.call(t,i[s])&&(l[i[s]]=t[i[s]]);return l}function uA(t,r,l){if(l||arguments.length===2)for(var i=0,s=r.length,u;i<s;i++)(u||!(i in r))&&(u||(u=Array.prototype.slice.call(r,0,i)),u[i]=r[i]);return t.concat(u||Array.prototype.slice.call(r))}var ps="right-scroll-bar-position",gs="width-before-scroll-bar",cA="with-scroll-bars-hidden",fA="--removed-body-scroll-bar-size";function Rf(t,r){return typeof t=="function"?t(r):t&&(t.current=r),t}function dA(t,r){var l=w.useState(function(){return{value:t,callback:r,facade:{get current(){return l.value},set current(i){var s=l.value;s!==i&&(l.value=i,l.callback(i,s))}}}})[0];return l.callback=r,l.facade}var hA=typeof window<"u"?w.useLayoutEffect:w.useEffect,mx=new WeakMap;function mA(t,r){var l=dA(null,function(i){return t.forEach(function(s){return Rf(s,i)})});return hA(function(){var i=mx.get(l);if(i){var s=new Set(i),u=new Set(t),c=l.current;s.forEach(function(d){u.has(d)||Rf(d,null)}),u.forEach(function(d){s.has(d)||Rf(d,c)})}mx.set(l,t)},[t]),l}function pA(t){return t}function gA(t,r){r===void 0&&(r=pA);var l=[],i=!1,s={read:function(){if(i)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return l.length?l[l.length-1]:t},useMedium:function(u){var c=r(u,i);return l.push(c),function(){l=l.filter(function(d){return d!==c})}},assignSyncMedium:function(u){for(i=!0;l.length;){var c=l;l=[],c.forEach(u)}l={push:function(d){return u(d)},filter:function(){return l}}},assignMedium:function(u){i=!0;var c=[];if(l.length){var d=l;l=[],d.forEach(u),c=l}var p=function(){var x=c;c=[],x.forEach(u)},m=function(){return Promise.resolve().then(p)};m(),l={push:function(x){c.push(x),m()},filter:function(x){return c=c.filter(x),l}}}};return s}function yA(t){t===void 0&&(t={});var r=gA(null);return r.options=Bn({async:!0,ssr:!1},t),r}var $1=function(t){var r=t.sideCar,l=V1(t,["sideCar"]);if(!r)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var i=r.read();if(!i)throw new Error("Sidecar medium not found");return w.createElement(i,Bn({},l))};$1.isSideCarExport=!0;function xA(t,r){return t.useMedium(r),$1}var F1=yA(),zf=function(){},Us=w.forwardRef(function(t,r){var l=w.useRef(null),i=w.useState({onScrollCapture:zf,onWheelCapture:zf,onTouchMoveCapture:zf}),s=i[0],u=i[1],c=t.forwardProps,d=t.children,p=t.className,m=t.removeScrollBar,x=t.enabled,y=t.shards,b=t.sideCar,S=t.noRelative,k=t.noIsolation,N=t.inert,A=t.allowPinchZoom,j=t.as,M=j===void 0?"div":j,z=t.gapMode,V=V1(t,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),Q=b,B=mA([l,r]),G=Bn(Bn({},V),s);return w.createElement(w.Fragment,null,x&&w.createElement(Q,{sideCar:F1,removeScrollBar:m,shards:y,noRelative:S,noIsolation:k,inert:N,setCallbacks:u,allowPinchZoom:!!A,lockRef:l,gapMode:z}),c?w.cloneElement(w.Children.only(d),Bn(Bn({},G),{ref:B})):w.createElement(M,Bn({},G,{className:p,ref:B}),d))});Us.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};Us.classNames={fullWidth:gs,zeroRight:ps};var bA=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function vA(){if(!document)return null;var t=document.createElement("style");t.type="text/css";var r=bA();return r&&t.setAttribute("nonce",r),t}function SA(t,r){t.styleSheet?t.styleSheet.cssText=r:t.appendChild(document.createTextNode(r))}function wA(t){var r=document.head||document.getElementsByTagName("head")[0];r.appendChild(t)}var kA=function(){var t=0,r=null;return{add:function(l){t==0&&(r=vA())&&(SA(r,l),wA(r)),t++},remove:function(){t--,!t&&r&&(r.parentNode&&r.parentNode.removeChild(r),r=null)}}},CA=function(){var t=kA();return function(r,l){w.useEffect(function(){return t.add(r),function(){t.remove()}},[r&&l])}},Y1=function(){var t=CA(),r=function(l){var i=l.styles,s=l.dynamic;return t(i,s),null};return r},NA={left:0,top:0,right:0,gap:0},Of=function(t){return parseInt(t||"",10)||0},EA=function(t){var r=window.getComputedStyle(document.body),l=r[t==="padding"?"paddingLeft":"marginLeft"],i=r[t==="padding"?"paddingTop":"marginTop"],s=r[t==="padding"?"paddingRight":"marginRight"];return[Of(l),Of(i),Of(s)]},jA=function(t){if(t===void 0&&(t="margin"),typeof window>"u")return NA;var r=EA(t),l=document.documentElement.clientWidth,i=window.innerWidth;return{left:r[0],top:r[1],right:r[2],gap:Math.max(0,i-l+r[2]-r[0])}},TA=Y1(),fa="data-scroll-locked",AA=function(t,r,l,i){var s=t.left,u=t.top,c=t.right,d=t.gap;return l===void 0&&(l="margin"),`
|
|
564
|
-
.`.concat(cA,` {
|
|
565
|
-
overflow: hidden `).concat(i,`;
|
|
566
|
-
padding-right: `).concat(d,"px ").concat(i,`;
|
|
567
|
-
}
|
|
568
|
-
body[`).concat(fa,`] {
|
|
569
|
-
overflow: hidden `).concat(i,`;
|
|
570
|
-
overscroll-behavior: contain;
|
|
571
|
-
`).concat([r&&"position: relative ".concat(i,";"),l==="margin"&&`
|
|
572
|
-
padding-left: `.concat(s,`px;
|
|
573
|
-
padding-top: `).concat(u,`px;
|
|
574
|
-
padding-right: `).concat(c,`px;
|
|
575
|
-
margin-left:0;
|
|
576
|
-
margin-top:0;
|
|
577
|
-
margin-right: `).concat(d,"px ").concat(i,`;
|
|
578
|
-
`),l==="padding"&&"padding-right: ".concat(d,"px ").concat(i,";")].filter(Boolean).join(""),`
|
|
579
|
-
}
|
|
580
|
-
|
|
581
|
-
.`).concat(ps,` {
|
|
582
|
-
right: `).concat(d,"px ").concat(i,`;
|
|
583
|
-
}
|
|
584
|
-
|
|
585
|
-
.`).concat(gs,` {
|
|
586
|
-
margin-right: `).concat(d,"px ").concat(i,`;
|
|
587
|
-
}
|
|
588
|
-
|
|
589
|
-
.`).concat(ps," .").concat(ps,` {
|
|
590
|
-
right: 0 `).concat(i,`;
|
|
591
|
-
}
|
|
592
|
-
|
|
593
|
-
.`).concat(gs," .").concat(gs,` {
|
|
594
|
-
margin-right: 0 `).concat(i,`;
|
|
595
|
-
}
|
|
596
|
-
|
|
597
|
-
body[`).concat(fa,`] {
|
|
598
|
-
`).concat(fA,": ").concat(d,`px;
|
|
599
|
-
}
|
|
600
|
-
`)},px=function(){var t=parseInt(document.body.getAttribute(fa)||"0",10);return isFinite(t)?t:0},MA=function(){w.useEffect(function(){return document.body.setAttribute(fa,(px()+1).toString()),function(){var t=px()-1;t<=0?document.body.removeAttribute(fa):document.body.setAttribute(fa,t.toString())}},[])},DA=function(t){var r=t.noRelative,l=t.noImportant,i=t.gapMode,s=i===void 0?"margin":i;MA();var u=w.useMemo(function(){return jA(s)},[s]);return w.createElement(TA,{styles:AA(u,!r,s,l?"":"!important")})},ld=!1;if(typeof window<"u")try{var us=Object.defineProperty({},"passive",{get:function(){return ld=!0,!0}});window.addEventListener("test",us,us),window.removeEventListener("test",us,us)}catch{ld=!1}var aa=ld?{passive:!1}:!1,RA=function(t){return t.tagName==="TEXTAREA"},G1=function(t,r){if(!(t instanceof Element))return!1;var l=window.getComputedStyle(t);return l[r]!=="hidden"&&!(l.overflowY===l.overflowX&&!RA(t)&&l[r]==="visible")},zA=function(t){return G1(t,"overflowY")},OA=function(t){return G1(t,"overflowX")},gx=function(t,r){var l=r.ownerDocument,i=r;do{typeof ShadowRoot<"u"&&i instanceof ShadowRoot&&(i=i.host);var s=P1(t,i);if(s){var u=X1(t,i),c=u[1],d=u[2];if(c>d)return!0}i=i.parentNode}while(i&&i!==l.body);return!1},_A=function(t){var r=t.scrollTop,l=t.scrollHeight,i=t.clientHeight;return[r,l,i]},LA=function(t){var r=t.scrollLeft,l=t.scrollWidth,i=t.clientWidth;return[r,l,i]},P1=function(t,r){return t==="v"?zA(r):OA(r)},X1=function(t,r){return t==="v"?_A(r):LA(r)},UA=function(t,r){return t==="h"&&r==="rtl"?-1:1},BA=function(t,r,l,i,s){var u=UA(t,window.getComputedStyle(r).direction),c=u*i,d=l.target,p=r.contains(d),m=!1,x=c>0,y=0,b=0;do{if(!d)break;var S=X1(t,d),k=S[0],N=S[1],A=S[2],j=N-A-u*k;(k||j)&&P1(t,d)&&(y+=j,b+=k);var M=d.parentNode;d=M&&M.nodeType===Node.DOCUMENT_FRAGMENT_NODE?M.host:M}while(!p&&d!==document.body||p&&(r.contains(d)||r===d));return(x&&Math.abs(y)<1||!x&&Math.abs(b)<1)&&(m=!0),m},cs=function(t){return"changedTouches"in t?[t.changedTouches[0].clientX,t.changedTouches[0].clientY]:[0,0]},yx=function(t){return[t.deltaX,t.deltaY]},xx=function(t){return t&&"current"in t?t.current:t},HA=function(t,r){return t[0]===r[0]&&t[1]===r[1]},qA=function(t){return`
|
|
601
|
-
.block-interactivity-`.concat(t,` {pointer-events: none;}
|
|
602
|
-
.allow-interactivity-`).concat(t,` {pointer-events: all;}
|
|
603
|
-
`)},IA=0,ia=[];function VA(t){var r=w.useRef([]),l=w.useRef([0,0]),i=w.useRef(),s=w.useState(IA++)[0],u=w.useState(Y1)[0],c=w.useRef(t);w.useEffect(function(){c.current=t},[t]),w.useEffect(function(){if(t.inert){document.body.classList.add("block-interactivity-".concat(s));var N=uA([t.lockRef.current],(t.shards||[]).map(xx),!0).filter(Boolean);return N.forEach(function(A){return A.classList.add("allow-interactivity-".concat(s))}),function(){document.body.classList.remove("block-interactivity-".concat(s)),N.forEach(function(A){return A.classList.remove("allow-interactivity-".concat(s))})}}},[t.inert,t.lockRef.current,t.shards]);var d=w.useCallback(function(N,A){if("touches"in N&&N.touches.length===2||N.type==="wheel"&&N.ctrlKey)return!c.current.allowPinchZoom;var j=cs(N),M=l.current,z="deltaX"in N?N.deltaX:M[0]-j[0],V="deltaY"in N?N.deltaY:M[1]-j[1],Q,B=N.target,G=Math.abs(z)>Math.abs(V)?"h":"v";if("touches"in N&&G==="h"&&B.type==="range")return!1;var ae=window.getSelection(),se=ae&&ae.anchorNode,L=se?se===B||se.contains(B):!1;if(L)return!1;var P=gx(G,B);if(!P)return!0;if(P?Q=G:(Q=G==="v"?"h":"v",P=gx(G,B)),!P)return!1;if(!i.current&&"changedTouches"in N&&(z||V)&&(i.current=Q),!Q)return!0;var X=i.current||Q;return BA(X,A,N,X==="h"?z:V)},[]),p=w.useCallback(function(N){var A=N;if(!(!ia.length||ia[ia.length-1]!==u)){var j="deltaY"in A?yx(A):cs(A),M=r.current.filter(function(Q){return Q.name===A.type&&(Q.target===A.target||A.target===Q.shadowParent)&&HA(Q.delta,j)})[0];if(M&&M.should){A.cancelable&&A.preventDefault();return}if(!M){var z=(c.current.shards||[]).map(xx).filter(Boolean).filter(function(Q){return Q.contains(A.target)}),V=z.length>0?d(A,z[0]):!c.current.noIsolation;V&&A.cancelable&&A.preventDefault()}}},[]),m=w.useCallback(function(N,A,j,M){var z={name:N,delta:A,target:j,should:M,shadowParent:$A(j)};r.current.push(z),setTimeout(function(){r.current=r.current.filter(function(V){return V!==z})},1)},[]),x=w.useCallback(function(N){l.current=cs(N),i.current=void 0},[]),y=w.useCallback(function(N){m(N.type,yx(N),N.target,d(N,t.lockRef.current))},[]),b=w.useCallback(function(N){m(N.type,cs(N),N.target,d(N,t.lockRef.current))},[]);w.useEffect(function(){return ia.push(u),t.setCallbacks({onScrollCapture:y,onWheelCapture:y,onTouchMoveCapture:b}),document.addEventListener("wheel",p,aa),document.addEventListener("touchmove",p,aa),document.addEventListener("touchstart",x,aa),function(){ia=ia.filter(function(N){return N!==u}),document.removeEventListener("wheel",p,aa),document.removeEventListener("touchmove",p,aa),document.removeEventListener("touchstart",x,aa)}},[]);var S=t.removeScrollBar,k=t.inert;return w.createElement(w.Fragment,null,k?w.createElement(u,{styles:qA(s)}):null,S?w.createElement(DA,{noRelative:t.noRelative,gapMode:t.gapMode}):null)}function $A(t){for(var r=null;t!==null;)t instanceof ShadowRoot&&(r=t.host,t=t.host),t=t.parentNode;return r}const FA=xA(F1,VA);var Q1=w.forwardRef(function(t,r){return w.createElement(Us,Bn({},t,{ref:r,sideCar:FA}))});Q1.classNames=Us.classNames;var YA=function(t){if(typeof document>"u")return null;var r=Array.isArray(t)?t[0]:t;return r.ownerDocument.body},oa=new WeakMap,fs=new WeakMap,ds={},_f=0,K1=function(t){return t&&(t.host||K1(t.parentNode))},GA=function(t,r){return r.map(function(l){if(t.contains(l))return l;var i=K1(l);return i&&t.contains(i)?i:(console.error("aria-hidden",l,"in not contained inside",t,". Doing nothing"),null)}).filter(function(l){return!!l})},PA=function(t,r,l,i){var s=GA(r,Array.isArray(t)?t:[t]);ds[l]||(ds[l]=new WeakMap);var u=ds[l],c=[],d=new Set,p=new Set(s),m=function(y){!y||d.has(y)||(d.add(y),m(y.parentNode))};s.forEach(m);var x=function(y){!y||p.has(y)||Array.prototype.forEach.call(y.children,function(b){if(d.has(b))x(b);else try{var S=b.getAttribute(i),k=S!==null&&S!=="false",N=(oa.get(b)||0)+1,A=(u.get(b)||0)+1;oa.set(b,N),u.set(b,A),c.push(b),N===1&&k&&fs.set(b,!0),A===1&&b.setAttribute(l,"true"),k||b.setAttribute(i,"true")}catch(j){console.error("aria-hidden: cannot operate on ",b,j)}})};return x(r),d.clear(),_f++,function(){c.forEach(function(y){var b=oa.get(y)-1,S=u.get(y)-1;oa.set(y,b),u.set(y,S),b||(fs.has(y)||y.removeAttribute(i),fs.delete(y)),S||y.removeAttribute(l)}),_f--,_f||(oa=new WeakMap,oa=new WeakMap,fs=new WeakMap,ds={})}},XA=function(t,r,l){l===void 0&&(l="data-aria-hidden");var i=Array.from(Array.isArray(t)?t:[t]),s=YA(t);return s?(i.push.apply(i,Array.from(s.querySelectorAll("[aria-live], script"))),PA(i,s,l,"aria-hidden")):function(){return null}},Bs="Dialog",[Z1]=zi(Bs),[QA,Rn]=Z1(Bs),J1=t=>{const{__scopeDialog:r,children:l,open:i,defaultOpen:s,onOpenChange:u,modal:c=!0}=t,d=w.useRef(null),p=w.useRef(null),[m,x]=$d({prop:i,defaultProp:s??!1,onChange:u,caller:Bs});return h.jsx(QA,{scope:r,triggerRef:d,contentRef:p,contentId:ji(),titleId:ji(),descriptionId:ji(),open:m,onOpenChange:x,onOpenToggle:w.useCallback(()=>x(y=>!y),[x]),modal:c,children:l})};J1.displayName=Bs;var W1="DialogTrigger",KA=w.forwardRef((t,r)=>{const{__scopeDialog:l,...i}=t,s=Rn(W1,l),u=It(r,s.triggerRef);return h.jsx(Tt.button,{type:"button","aria-haspopup":"dialog","aria-expanded":s.open,"aria-controls":s.contentId,"data-state":Xd(s.open),...i,ref:u,onClick:gt(t.onClick,s.onOpenToggle)})});KA.displayName=W1;var Gd="DialogPortal",[ZA,eb]=Z1(Gd,{forceMount:void 0}),tb=t=>{const{__scopeDialog:r,forceMount:l,children:i,container:s}=t,u=Rn(Gd,r);return h.jsx(ZA,{scope:r,forceMount:l,children:w.Children.map(i,c=>h.jsx(sr,{present:l||u.open,children:h.jsx(I1,{asChild:!0,container:s,children:c})}))})};tb.displayName=Gd;var Ns="DialogOverlay",nb=w.forwardRef((t,r)=>{const l=eb(Ns,t.__scopeDialog),{forceMount:i=l.forceMount,...s}=t,u=Rn(Ns,t.__scopeDialog);return u.modal?h.jsx(sr,{present:i||u.open,children:h.jsx(WA,{...s,ref:r})}):null});nb.displayName=Ns;var JA=ys("DialogOverlay.RemoveScroll"),WA=w.forwardRef((t,r)=>{const{__scopeDialog:l,...i}=t,s=Rn(Ns,l);return h.jsx(Q1,{as:JA,allowPinchZoom:!0,shards:[s.contentRef],children:h.jsx(Tt.div,{"data-state":Xd(s.open),...i,ref:r,style:{pointerEvents:"auto",...i.style}})})}),pl="DialogContent",rb=w.forwardRef((t,r)=>{const l=eb(pl,t.__scopeDialog),{forceMount:i=l.forceMount,...s}=t,u=Rn(pl,t.__scopeDialog);return h.jsx(sr,{present:i||u.open,children:u.modal?h.jsx(e5,{...s,ref:r}):h.jsx(t5,{...s,ref:r})})});rb.displayName=pl;var e5=w.forwardRef((t,r)=>{const l=Rn(pl,t.__scopeDialog),i=w.useRef(null),s=It(r,l.contentRef,i);return w.useEffect(()=>{const u=i.current;if(u)return XA(u)},[]),h.jsx(lb,{...t,ref:s,trapFocus:l.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:gt(t.onCloseAutoFocus,u=>{var c;u.preventDefault(),(c=l.triggerRef.current)==null||c.focus()}),onPointerDownOutside:gt(t.onPointerDownOutside,u=>{const c=u.detail.originalEvent,d=c.button===0&&c.ctrlKey===!0;(c.button===2||d)&&u.preventDefault()}),onFocusOutside:gt(t.onFocusOutside,u=>u.preventDefault())})}),t5=w.forwardRef((t,r)=>{const l=Rn(pl,t.__scopeDialog),i=w.useRef(!1),s=w.useRef(!1);return h.jsx(lb,{...t,ref:r,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:u=>{var c,d;(c=t.onCloseAutoFocus)==null||c.call(t,u),u.defaultPrevented||(i.current||(d=l.triggerRef.current)==null||d.focus(),u.preventDefault()),i.current=!1,s.current=!1},onInteractOutside:u=>{var p,m;(p=t.onInteractOutside)==null||p.call(t,u),u.defaultPrevented||(i.current=!0,u.detail.originalEvent.type==="pointerdown"&&(s.current=!0));const c=u.target;((m=l.triggerRef.current)==null?void 0:m.contains(c))&&u.preventDefault(),u.detail.originalEvent.type==="focusin"&&s.current&&u.preventDefault()}})}),lb=w.forwardRef((t,r)=>{const{__scopeDialog:l,trapFocus:i,onOpenAutoFocus:s,onCloseAutoFocus:u,...c}=t,d=Rn(pl,l),p=w.useRef(null),m=It(r,p);return sA(),h.jsxs(h.Fragment,{children:[h.jsx(H1,{asChild:!0,loop:!0,trapped:i,onMountAutoFocus:s,onUnmountAutoFocus:u,children:h.jsx(U1,{role:"dialog",id:d.contentId,"aria-describedby":d.descriptionId,"aria-labelledby":d.titleId,"data-state":Xd(d.open),...c,ref:m,onDismiss:()=>d.onOpenChange(!1)})}),h.jsxs(h.Fragment,{children:[h.jsx(n5,{titleId:d.titleId}),h.jsx(l5,{contentRef:p,descriptionId:d.descriptionId})]})]})}),Pd="DialogTitle",ab=w.forwardRef((t,r)=>{const{__scopeDialog:l,...i}=t,s=Rn(Pd,l);return h.jsx(Tt.h2,{id:s.titleId,...i,ref:r})});ab.displayName=Pd;var ib="DialogDescription",ob=w.forwardRef((t,r)=>{const{__scopeDialog:l,...i}=t,s=Rn(ib,l);return h.jsx(Tt.p,{id:s.descriptionId,...i,ref:r})});ob.displayName=ib;var sb="DialogClose",ub=w.forwardRef((t,r)=>{const{__scopeDialog:l,...i}=t,s=Rn(sb,l);return h.jsx(Tt.button,{type:"button",...i,ref:r,onClick:gt(t.onClick,()=>s.onOpenChange(!1))})});ub.displayName=sb;function Xd(t){return t?"open":"closed"}var cb="DialogTitleWarning",[b5,fb]=dw(cb,{contentName:pl,titleName:Pd,docsSlug:"dialog"}),n5=({titleId:t})=>{const r=fb(cb),l=`\`${r.contentName}\` requires a \`${r.titleName}\` for the component to be accessible for screen reader users.
|
|
604
|
-
|
|
605
|
-
If you want to hide the \`${r.titleName}\`, you can wrap it with our VisuallyHidden component.
|
|
606
|
-
|
|
607
|
-
For more information, see https://radix-ui.com/primitives/docs/components/${r.docsSlug}`;return w.useEffect(()=>{t&&(document.getElementById(t)||console.error(l))},[l,t]),null},r5="DialogDescriptionWarning",l5=({contentRef:t,descriptionId:r})=>{const i=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${fb(r5).contentName}}.`;return w.useEffect(()=>{var u;const s=(u=t.current)==null?void 0:u.getAttribute("aria-describedby");r&&s&&(document.getElementById(r)||console.warn(i))},[i,t,r]),null},a5=J1,i5=tb,db=nb,hb=rb,mb=ab,pb=ob,o5=ub;const bx=a5,s5=i5,gb=w.forwardRef(({className:t,...r},l)=>h.jsx(db,{ref:l,className:he("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",t),...r}));gb.displayName=db.displayName;const ad=w.forwardRef(({className:t,children:r,...l},i)=>h.jsxs(s5,{children:[h.jsx(gb,{}),h.jsxs(hb,{ref:i,className:he("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",t),...l,children:[r,h.jsxs(o5,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground",children:[h.jsx(gl,{className:"h-4 w-4"}),h.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));ad.displayName=hb.displayName;const yb=({className:t,...r})=>h.jsx("div",{className:he("flex flex-col space-y-1.5 text-center sm:text-left",t),...r});yb.displayName="DialogHeader";const xb=({className:t,...r})=>h.jsx("div",{className:he("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",t),...r});xb.displayName="DialogFooter";const bb=w.forwardRef(({className:t,...r},l)=>h.jsx(mb,{ref:l,className:he("text-lg font-semibold leading-none tracking-tight",t),...r}));bb.displayName=mb.displayName;const vb=w.forwardRef(({className:t,...r},l)=>h.jsx(pb,{ref:l,className:he("text-sm text-muted-foreground",t),...r}));vb.displayName=pb.displayName;function u5(t){return/edit|write|create|patch/i.test(t)?C2:/bash|shell|exec|run|command/i.test(t)?ga:/fetch|http|web|curl|request/i.test(t)?ki:wd}function c5({toolName:t,input:r}){const l=p1(t,r);if(l)return h.jsx("div",{className:"rounded-lg overflow-hidden border",children:h.jsx(m1,{oldText:l.oldText,newText:l.newText,caption:l.caption})});if(typeof r=="object"&&r!==null){const i=r,s=i.command??i.cmd??i.script;if(typeof s=="string"&&s.trim().length>0)return h.jsxs("div",{className:"rounded-lg border bg-background/40 overflow-hidden",children:[h.jsxs("div",{className:"px-3 py-1.5 text-[10px] uppercase tracking-wider text-muted-foreground border-b bg-muted/40 flex items-center gap-1.5",children:[h.jsx(ga,{className:"h-3 w-3"}),h.jsx("span",{children:"Command"})]}),h.jsxs("pre",{className:"px-3 py-2 text-xs font-mono whitespace-pre-wrap break-all max-h-40 overflow-auto",children:["$",s]})]});const u=i.url;if(typeof u=="string"){const c=i.method??"GET";return h.jsxs("div",{className:"rounded-lg border bg-background/40 px-3 py-2 text-xs font-mono",children:[h.jsx("span",{className:"text-muted-foreground",children:c.toUpperCase()})," ",h.jsx("span",{className:"break-all",children:u})]})}}return h.jsxs("div",{className:"p-3 rounded-lg bg-muted/50 border text-xs font-mono",children:[h.jsx("div",{className:"text-muted-foreground mb-2",children:"Input:"}),h.jsx("pre",{className:"whitespace-pre-wrap break-all max-h-60 overflow-auto",children:JSON.stringify(r,null,2)})]})}function f5(){const{showConfirmDialog:t,confirmInfo:r,hideConfirm:l}=Ce(),{sendConfirm:i}=In(),s=d=>{r&&i(r.id,d),l()};if(w.useEffect(()=>{if(!t)return;const d=p=>{var y;const m=p.target,x=(y=m==null?void 0:m.tagName)==null?void 0:y.toLowerCase();x==="input"||x==="textarea"||(p.key==="y"||p.key==="Y"?(p.preventDefault(),s("yes")):p.key==="n"||p.key==="N"||p.key==="Escape"?(p.preventDefault(),s("no")):(p.key==="a"||p.key==="A")&&(p.preventDefault(),s("always")))};return window.addEventListener("keydown",d),()=>window.removeEventListener("keydown",d)},[t,r==null?void 0:r.id]),!r)return h.jsx(bx,{open:t,onOpenChange:()=>l(),children:h.jsx(ad,{})});const u=u5(r.toolName),c=/edit|write/i.test(r.toolName);return h.jsx(bx,{open:t,onOpenChange:()=>l(),children:h.jsxs(ad,{className:"sm:max-w-2xl",children:[h.jsxs(yb,{children:[h.jsxs(bb,{className:"flex items-center gap-2",children:[h.jsx(q2,{className:"h-5 w-5 text-yellow-500"}),"Confirm: ",r.toolName]}),h.jsxs(vb,{children:["The agent wants to ",c?"modify a file":"run this tool",". Review the request below and decide whether to proceed."]})]}),h.jsxs("div",{className:"py-2 space-y-3",children:[h.jsxs("div",{className:"flex items-center gap-3 p-3 rounded-lg bg-muted",children:[h.jsx(u,{className:"h-5 w-5 text-muted-foreground"}),h.jsxs("div",{className:"min-w-0",children:[h.jsx("div",{className:"font-medium font-mono truncate",children:r.toolName}),h.jsxs("div",{className:"text-xs text-muted-foreground",children:[c?"File modification":"Tool execution"," — preview below"]})]})]}),r.input!==void 0&&h.jsx(c5,{toolName:r.toolName,input:r.input}),r.suggestedPattern&&h.jsxs("div",{className:"flex items-start gap-2 p-3 rounded-lg bg-yellow-500/10 border border-yellow-500/20",children:[h.jsx(l0,{className:"h-4 w-4 text-yellow-600 mt-0.5 shrink-0"}),h.jsxs("div",{className:"text-sm min-w-0",children:[h.jsx("div",{className:"font-medium text-yellow-800 dark:text-yellow-200",children:"Trust pattern suggestion"}),h.jsx("div",{className:"font-mono text-xs mt-1 break-all",children:r.suggestedPattern}),h.jsxs("div",{className:"text-xs text-muted-foreground mt-1",children:["Picking ",h.jsx("span",{className:"font-medium",children:"Always"})," will whitelist matching calls for this project."]})]})]})]}),h.jsxs(xb,{className:"gap-2 sm:gap-2 flex-wrap",children:[h.jsx(Ve,{variant:"outline",size:"sm",onClick:()=>s("deny"),title:"Reject this and all future calls matching the pattern",children:"Deny always"}),h.jsxs(Ve,{variant:"outline",size:"sm",onClick:()=>s("no"),title:"Reject this single call (Esc / n)",children:["No ",h.jsx("kbd",{className:"ml-1 text-[10px] border rounded px-1 bg-background",children:"n"})]}),h.jsxs(Ve,{variant:"outline",size:"sm",onClick:()=>s("always"),title:"Approve and remember the pattern for the project (a)",children:["Always ",h.jsx("kbd",{className:"ml-1 text-[10px] border rounded px-1 bg-background",children:"a"})]}),h.jsxs(Ve,{size:"sm",onClick:()=>s("yes"),title:"Approve this single call (y)",children:["Yes ",h.jsx("kbd",{className:"ml-1 text-[10px] border rounded px-1 bg-background/80",children:"y"})]})]})]})})}const d5=[{section:"Global",items:[{keys:["Ctrl","K"],description:"Open command palette"},{keys:["?"],description:"Show this shortcuts overlay"},{keys:["Ctrl","\\"],description:"Toggle sidebar"},{keys:["Ctrl","/"],description:"Focus the message input"}]},{section:"Chat input",items:[{keys:["Enter"],description:"Send message"},{keys:["Shift","Enter"],description:"Insert a newline"},{keys:["↑"],description:"Recall previous prompt (in empty input)"},{keys:["↓"],description:"Recall next prompt"},{keys:["/"],description:"Open slash command popup"},{keys:["Tab"],description:"Autocomplete highlighted command"},{keys:["Esc"],description:"Dismiss popup / clear input"}]},{section:"Chat",items:[{keys:["Ctrl","F"],description:"Search within current chat"},{keys:["Ctrl","L"],description:"Clear context (same as /clear)"},{keys:["Ctrl","N"],description:"Start a new session (same as /new)"},{keys:["Ctrl","E"],description:"Export chat as markdown"},{keys:["Ctrl","M"],description:"Quick model switcher overlay"},{keys:["Ctrl","Shift","D"],description:"Toggle compact UI density"},{keys:["Esc"],description:"Abort the current run (when running)"}]},{section:"Chat navigation (when not typing)",items:[{keys:["j"],description:"Focus next message (alias: ↓)"},{keys:["k"],description:"Focus previous message (alias: ↑)"},{keys:["g"],description:"Jump to first message"},{keys:["Shift","G"],description:"Jump to last message"},{keys:["c"],description:"Copy focused message text"},{keys:["Esc"],description:"Clear focused message"}]}];function h5(){const t=Ce(l=>l.shortcutsOpen),r=Ce(l=>l.setShortcutsOpen);return w.useEffect(()=>{const l=i=>{var d;const s=i.target,u=(d=s==null?void 0:s.tagName)==null?void 0:d.toLowerCase();if(!(u==="input"||u==="textarea"||(s==null?void 0:s.isContentEditable))&&i.key==="?"&&!i.ctrlKey&&!i.metaKey&&!i.altKey){i.preventDefault(),r(!Ce.getState().shortcutsOpen);return}i.key==="Escape"&&Ce.getState().shortcutsOpen&&(i.preventDefault(),r(!1))};return window.addEventListener("keydown",l),()=>window.removeEventListener("keydown",l)},[r]),t?h.jsx("div",{className:"fixed inset-0 z-50 bg-background/60 backdrop-blur-sm flex items-center justify-center px-4",onClick:()=>r(!1),children:h.jsxs("div",{onClick:l=>l.stopPropagation(),className:"w-full max-w-2xl rounded-xl border bg-popover shadow-2xl overflow-hidden flex flex-col max-h-[80vh]",children:[h.jsxs("div",{className:"flex items-center justify-between px-5 py-4 border-b",children:[h.jsxs("div",{className:"flex items-center gap-2",children:[h.jsx(Wx,{className:"h-4 w-4 text-muted-foreground"}),h.jsx("h2",{className:"text-sm font-semibold",children:"Keyboard shortcuts"})]}),h.jsx("button",{type:"button",onClick:()=>r(!1),className:"text-muted-foreground hover:text-foreground p-1 rounded hover:bg-muted",children:h.jsx(gl,{className:"h-4 w-4"})})]}),h.jsx("div",{className:"overflow-y-auto px-5 py-4 space-y-6",children:d5.map(l=>h.jsxs("div",{children:[h.jsx("div",{className:"text-[10px] uppercase tracking-wider text-muted-foreground mb-2",children:l.section}),h.jsx("div",{className:"grid grid-cols-1 gap-1.5",children:l.items.map(i=>h.jsxs("div",{className:"flex items-center justify-between gap-3 text-sm px-2 py-1.5 rounded hover:bg-muted/40",children:[h.jsx("span",{className:"text-foreground/80",children:i.description}),h.jsx("span",{className:"flex items-center gap-1 shrink-0",children:i.keys.map((s,u)=>h.jsxs("span",{className:"flex items-center gap-1",children:[u>0&&h.jsx("span",{className:"text-muted-foreground/40 text-xs",children:"+"}),h.jsx("kbd",{className:"font-mono text-[10px] border rounded px-1.5 py-0.5 bg-background",children:s})]},u))})]},i.description))})]},l.section))}),h.jsxs("div",{className:"border-t px-5 py-3 text-xs text-muted-foreground",children:["Press ",h.jsx("kbd",{className:"font-mono text-[10px] border rounded px-1 py-0.5 bg-background",children:"?"})," any time to reopen this list."]})]})}):null}function m5(){const t=Ce(M=>M.modelSwitcherOpen),r=Ce(M=>M.setModelSwitcherOpen),[l,i]=w.useState(""),[s,u]=w.useState(0),[c,d]=w.useState([]),[p,m]=w.useState({}),x=w.useRef(null),y=Ge(M=>M.wsUrl),b=Ge(M=>M.provider),S=Ge(M=>M.model),k=Ce(M=>M.paletteOpen),N=In();w.useEffect(()=>{const M=z=>{if((z.ctrlKey||z.metaKey)&&z.key.toLowerCase()==="m"&&!z.shiftKey&&!z.altKey){if(k)return;z.preventDefault(),r(!t);return}z.key==="Escape"&&t&&(z.preventDefault(),r(!1))};return window.addEventListener("keydown",M),()=>window.removeEventListener("keydown",M)},[t,k]),w.useEffect(()=>{const M=Hn(y),z=M.on("providers.saved",Q=>{const B=Q.payload;d(B.providers??[])}),V=M.on("provider.models",Q=>{const B=Q.payload;m(G=>({...G,[B.provider]:B.models}))});return()=>{z(),V()}},[y]),w.useEffect(()=>{t&&(i(""),u(0),N.listSavedProviders(),requestAnimationFrame(()=>{var M;return(M=x.current)==null?void 0:M.focus()}))},[t,N]),w.useEffect(()=>{if(t)for(const M of c)p[M.id]||N.listProviderModels(M.id)},[t,c,p,N]);const A=w.useMemo(()=>{const M=[];for(const Q of c){const B=p[Q.id]??[];for(const G of B)M.push({provider:Q.id,model:G.id,modelName:G.name||G.id,contextWindow:G.contextWindow,isCurrent:Q.id===b&&G.id===S})}const z=l.toLowerCase().trim();return(z?M.filter(Q=>Q.provider.toLowerCase().includes(z)||Q.model.toLowerCase().includes(z)||Q.modelName.toLowerCase().includes(z)):M).sort((Q,B)=>Q.isCurrent!==B.isCurrent?Q.isCurrent?-1:1:Q.provider.localeCompare(B.provider)||Q.model.localeCompare(B.model))},[c,p,l,b,S]);w.useEffect(()=>{s>=A.length&&u(0)},[A.length,s]);const j=M=>{const z=A[M];z&&(N.switchModel(z.provider,z.model),r(!1))};return t?h.jsx("div",{className:"fixed inset-0 z-50 flex items-start justify-center bg-background/60 backdrop-blur-sm pt-[15vh]",onClick:M=>{M.target===M.currentTarget&&r(!1)},children:h.jsxs("div",{className:"w-full max-w-xl rounded-xl border bg-popover shadow-2xl overflow-hidden",children:[h.jsxs("div",{className:"flex items-center gap-2 border-b px-3 py-2",children:[h.jsx(pa,{className:"h-4 w-4 text-muted-foreground"}),h.jsx("input",{ref:x,value:l,onChange:M=>{i(M.target.value),u(0)},onKeyDown:M=>{M.key==="ArrowDown"?(M.preventDefault(),u(z=>Math.min(A.length-1,z+1))):M.key==="ArrowUp"?(M.preventDefault(),u(z=>Math.max(0,z-1))):M.key==="Enter"?(M.preventDefault(),j(s)):M.key==="Escape"&&(M.preventDefault(),r(!1))},placeholder:"Filter providers and models…",className:"flex-1 bg-transparent outline-none text-sm placeholder:text-muted-foreground"}),h.jsx("span",{className:"text-[10px] text-muted-foreground font-mono",children:"↑↓ · Enter · Esc"})]}),h.jsx("div",{className:"max-h-[50vh] overflow-y-auto py-1",children:A.length===0?h.jsx("div",{className:"px-4 py-8 text-center text-sm text-muted-foreground",children:c.length===0?"No saved providers — register a key in Settings first.":"Loading models…"}):A.map((M,z)=>h.jsxs("button",{type:"button",onClick:()=>j(z),onMouseEnter:()=>u(z),className:he("w-full flex items-center gap-3 px-3 py-2 text-left text-sm transition-colors",z===s?"bg-accent text-accent-foreground":"hover:bg-accent/40",M.isCurrent&&"font-medium"),children:[h.jsx(Ti,{className:he("h-4 w-4 shrink-0",M.isCurrent?"text-primary":"text-muted-foreground")}),h.jsxs("div",{className:"min-w-0 flex-1",children:[h.jsxs("div",{className:"truncate",children:[h.jsx("span",{className:"text-muted-foreground",children:M.provider}),h.jsx("span",{className:"mx-1 text-muted-foreground/40",children:"·"}),h.jsx("span",{children:M.modelName})]}),M.contextWindow&&h.jsxs("div",{className:"text-[10px] text-muted-foreground font-mono",children:[M.model," · ctx ",M.contextWindow.toLocaleString()]})]}),M.isCurrent?h.jsx("span",{className:"text-[10px] uppercase tracking-wide text-primary font-semibold",children:"active"}):h.jsx(Xx,{className:"h-3.5 w-3.5 text-muted-foreground opacity-0 group-hover:opacity-100"})]},`${M.provider}:${M.model}`))})]})}):null}function p5(){const t=Ge(x=>x.wsStatus),r=Ge(x=>x.wsUrl),[l,i]=w.useState(!1),[s,u]=w.useState(Date.now());if(w.useEffect(()=>{if(t.state!=="reconnecting")return;const x=setInterval(()=>u(Date.now()),500);return()=>clearInterval(x)},[t.state]),w.useEffect(()=>{t.state==="open"&&i(!1)},[t.state]),t.state==="open"||t.state==="connecting"||l)return null;const c=()=>Hn(r).retryNow(),d=t.state==="reconnecting",p=t.state==="closed"?t.error:t.state==="reconnecting"?t.lastError:void 0,m=d?Math.max(0,Math.ceil((t.nextRetryAt-s)/1e3)):0;return h.jsxs("div",{className:he("flex items-center gap-3 px-4 py-2 border-b text-sm",d?"bg-orange-500/10 text-orange-700 dark:text-orange-300 border-orange-500/30":"bg-red-500/10 text-red-700 dark:text-red-300 border-red-500/30"),children:[d?h.jsx($r,{className:"h-4 w-4 animate-spin shrink-0"}):h.jsx(Sd,{className:"h-4 w-4 shrink-0"}),h.jsxs("div",{className:"flex-1 min-w-0",children:[h.jsx("div",{className:"font-medium",children:d?`Reconnecting to backend (attempt ${t.attempt}) — retrying in ${m}s`:"Disconnected from backend"}),p&&h.jsx("div",{className:"text-xs opacity-80 truncate",children:p})]}),h.jsxs("button",{type:"button",onClick:c,className:he("inline-flex items-center gap-1 px-2.5 py-1 rounded-md border text-xs font-medium","hover:bg-background/30 transition-colors shrink-0",d?"border-orange-500/40":"border-red-500/40"),title:"Retry connection now",children:[h.jsx(Oi,{className:"h-3 w-3"}),"Retry now"]}),h.jsx("button",{type:"button",onClick:()=>i(!0),className:"text-current/60 hover:text-current shrink-0",title:"Dismiss (chip in topbar still shows status)",children:h.jsx(gl,{className:"h-4 w-4"})})]})}function g5(){const{theme:t}=wx(),{currentView:r,sidebarOpen:l,toggleSidebar:i,setSearchOpen:s,setSidebarOpen:u}=Ce(),c=pe(S=>S.isLoading),d=Ye(S=>S.iteration),p=Ye(S=>S.projectName),m=Ye(S=>{var k;return(k=S.session)==null?void 0:k.title}),x=Ye(S=>{var k;return(k=S.session)==null?void 0:k.id}),y=Ce(S=>x?S.sessionNicknames[x]:void 0),b=In();return w.useEffect(()=>{if(typeof window>"u")return;const S=window.matchMedia("(max-width: 768px)"),k=()=>{S.matches&&Ce.getState().sidebarOpen&&u(!1)};return k(),S.addEventListener("change",k),()=>S.removeEventListener("change",k)},[u]),gk(),w.useEffect(()=>{const S=[];if(c){const j=d?` iter ${d.index}${d.max?`/${d.max}`:""}`:"";S.push(`●${j}`)}const k=(y==null?void 0:y.trim())||(m==null?void 0:m.trim()),N=p==null?void 0:p.trim();k&&S.push(k),N&&S.push(N),S.push("WrongStack");const A=S.filter(Boolean).join(" · ");return document.title=A,()=>{document.title="WrongStack"}},[c,d,p,m,y]),w.useEffect(()=>{const S=k=>{var z,V,Q,B,G,ae,se;const N=k.target,A=(z=N==null?void 0:N.tagName)==null?void 0:z.toLowerCase(),j=A==="input"||A==="textarea"||(N==null?void 0:N.isContentEditable),M=k.ctrlKey||k.metaKey;if(M&&k.key==="\\"){k.preventDefault(),i();return}if(M&&k.key.toLowerCase()==="f"){k.preventDefault(),s(!0);return}if(M&&k.key.toLowerCase()==="/"){k.preventDefault();const L=document.querySelector("textarea");L==null||L.focus();return}if(M&&!j&&(k.key.toLowerCase()==="l"?(k.preventDefault(),pe.getState().clearMessages(),(Q=(V=b.client)==null?void 0:V.clearContext)==null||Q.call(V)):k.key.toLowerCase()==="n"?(k.preventDefault(),(G=(B=b.client)==null?void 0:B.newSession)==null||G.call(B)):k.key.toLowerCase()==="e"&&(k.preventDefault(),Cd())),M&&k.shiftKey&&k.key.toLowerCase()==="d"&&(k.preventDefault(),Ce.getState().toggleCompactMode()),!j&&!M&&!k.altKey){const L=Array.from(document.querySelectorAll("[data-message-id]"));if(L.length===0)return;const P=document.querySelector('[data-message-id][data-focused="true"]'),X=P?L.indexOf(P):-1,de=I=>{L.forEach(J=>J.removeAttribute("data-focused")),I.setAttribute("data-focused","true"),I.scrollIntoView({behavior:"smooth",block:"center"})};if(k.key==="j"||k.key==="ArrowDown"){const I=L[Math.min(L.length-1,Math.max(0,X+1))];I&&(k.preventDefault(),de(I));return}if(k.key==="k"||k.key==="ArrowUp"){const I=L[Math.max(0,X<=0?0:X-1)];I&&(k.preventDefault(),de(I));return}if(k.key==="g"&&!k.shiftKey){k.preventDefault(),de(L[0]);return}if(k.key==="G"||k.key==="g"&&k.shiftKey){k.preventDefault(),de(L[L.length-1]);return}if(k.key==="Escape"&&P){k.preventDefault(),P.removeAttribute("data-focused");return}if(k.key==="c"&&P){const I=((ae=P.querySelector(".markdown-content"))==null?void 0:ae.innerText)??P.innerText;I&&((se=navigator.clipboard)==null||se.writeText(I).catch(()=>{}),k.preventDefault());return}}};return window.addEventListener("keydown",S),()=>window.removeEventListener("keydown",S)},[i,s,b]),h.jsxs("div",{className:he("flex h-screen",t),children:[l&&h.jsx(FT,{}),h.jsxs("main",{className:"flex-1 flex flex-col overflow-hidden",children:[h.jsx(p5,{}),r==="chat"&&h.jsx(wT,{}),r==="settings"&&h.jsx(YT,{})]}),h.jsx(f5,{}),h.jsx(bk,{}),h.jsx(h5,{}),h.jsx(m5,{}),h.jsx(ok,{})]})}function y5(){return h.jsx(ew,{defaultTheme:"system",children:h.jsx(g5,{})})}PS.createRoot(document.getElementById("root")).render(h.jsx(dn.StrictMode,{children:h.jsx(y5,{})}));
|