@jean2/client 0.2.1 → 0.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,444 +0,0 @@
1
- function jA(e,r){for(var a=0;a<r.length;a++){const l=r[a];if(typeof l!="string"&&!Array.isArray(l)){for(const o in l)if(o!=="default"&&!(o in e)){const s=Object.getOwnPropertyDescriptor(l,o);s&&Object.defineProperty(e,o,s.get?s:{enumerable:!0,get:()=>l[o]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const r=document.createElement("link").relList;if(r&&r.supports&&r.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))l(o);new MutationObserver(o=>{for(const s of o)if(s.type==="childList")for(const c of s.addedNodes)c.tagName==="LINK"&&c.rel==="modulepreload"&&l(c)}).observe(document,{childList:!0,subtree:!0});function a(o){const s={};return o.integrity&&(s.integrity=o.integrity),o.referrerPolicy&&(s.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?s.credentials="include":o.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function l(o){if(o.ep)return;o.ep=!0;const s=a(o);fetch(o.href,s)}})();function Rc(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Rp={exports:{}},jo={};/**
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 rv;function TA(){if(rv)return jo;rv=1;var e=Symbol.for("react.transitional.element"),r=Symbol.for("react.fragment");function a(l,o,s){var c=null;if(s!==void 0&&(c=""+s),o.key!==void 0&&(c=""+o.key),"key"in o){s={};for(var d in o)d!=="key"&&(s[d]=o[d])}else s=o;return o=s.ref,{$$typeof:e,type:l,key:c,ref:o!==void 0?o:null,props:s}}return jo.Fragment=r,jo.jsx=a,jo.jsxs=a,jo}var av;function _A(){return av||(av=1,Rp.exports=TA()),Rp.exports}var f=_A(),Mp={exports:{}},Le={};/**
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 lv;function RA(){if(lv)return Le;lv=1;var e=Symbol.for("react.transitional.element"),r=Symbol.for("react.portal"),a=Symbol.for("react.fragment"),l=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.consumer"),c=Symbol.for("react.context"),d=Symbol.for("react.forward_ref"),p=Symbol.for("react.suspense"),h=Symbol.for("react.memo"),y=Symbol.for("react.lazy"),g=Symbol.for("react.activity"),b=Symbol.iterator;function w(z){return z===null||typeof z!="object"?null:(z=b&&z[b]||z["@@iterator"],typeof z=="function"?z:null)}var k={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},S=Object.assign,C={};function A(z,L,_){this.props=z,this.context=L,this.refs=C,this.updater=_||k}A.prototype.isReactComponent={},A.prototype.setState=function(z,L){if(typeof z!="object"&&typeof z!="function"&&z!=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,z,L,"setState")},A.prototype.forceUpdate=function(z){this.updater.enqueueForceUpdate(this,z,"forceUpdate")};function N(){}N.prototype=A.prototype;function j(z,L,_){this.props=z,this.context=L,this.refs=C,this.updater=_||k}var O=j.prototype=new N;O.constructor=j,S(O,A.prototype),O.isPureReactComponent=!0;var D=Array.isArray;function M(){}var U={H:null,A:null,T:null,S:null},F=Object.prototype.hasOwnProperty;function Q(z,L,_){var re=_.ref;return{$$typeof:e,type:z,key:L,ref:re!==void 0?re:null,props:_}}function I(z,L){return Q(z.type,L,z.props)}function Y(z){return typeof z=="object"&&z!==null&&z.$$typeof===e}function V(z){var L={"=":"=0",":":"=2"};return"$"+z.replace(/[=:]/g,function(_){return L[_]})}var ue=/\/+/g;function W(z,L){return typeof z=="object"&&z!==null&&z.key!=null?V(""+z.key):L.toString(36)}function J(z){switch(z.status){case"fulfilled":return z.value;case"rejected":throw z.reason;default:switch(typeof z.status=="string"?z.then(M,M):(z.status="pending",z.then(function(L){z.status==="pending"&&(z.status="fulfilled",z.value=L)},function(L){z.status==="pending"&&(z.status="rejected",z.reason=L)})),z.status){case"fulfilled":return z.value;case"rejected":throw z.reason}}throw z}function B(z,L,_,re,ne){var ie=typeof z;(ie==="undefined"||ie==="boolean")&&(z=null);var le=!1;if(z===null)le=!0;else switch(ie){case"bigint":case"string":case"number":le=!0;break;case"object":switch(z.$$typeof){case e:case r:le=!0;break;case y:return le=z._init,B(le(z._payload),L,_,re,ne)}}if(le)return ne=ne(z),le=re===""?"."+W(z,0):re,D(ne)?(_="",le!=null&&(_=le.replace(ue,"$&/")+"/"),B(ne,L,_,"",function(Ne){return Ne})):ne!=null&&(Y(ne)&&(ne=I(ne,_+(ne.key==null||z&&z.key===ne.key?"":(""+ne.key).replace(ue,"$&/")+"/")+le)),L.push(ne)),1;le=0;var be=re===""?".":re+":";if(D(z))for(var he=0;he<z.length;he++)re=z[he],ie=be+W(re,he),le+=B(re,L,_,ie,ne);else if(he=w(z),typeof he=="function")for(z=he.call(z),he=0;!(re=z.next()).done;)re=re.value,ie=be+W(re,he++),le+=B(re,L,_,ie,ne);else if(ie==="object"){if(typeof z.then=="function")return B(J(z),L,_,re,ne);throw L=String(z),Error("Objects are not valid as a React child (found: "+(L==="[object Object]"?"object with keys {"+Object.keys(z).join(", ")+"}":L)+"). If you meant to render a collection of children, use an array instead.")}return le}function G(z,L,_){if(z==null)return z;var re=[],ne=0;return B(z,re,"","",function(ie){return L.call(_,ie,ne++)}),re}function te(z){if(z._status===-1){var L=z._result;L=L(),L.then(function(_){(z._status===0||z._status===-1)&&(z._status=1,z._result=_)},function(_){(z._status===0||z._status===-1)&&(z._status=2,z._result=_)}),z._status===-1&&(z._status=0,z._result=L)}if(z._status===1)return z._result.default;throw z._result}var ce=typeof reportError=="function"?reportError:function(z){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var L=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof z=="object"&&z!==null&&typeof z.message=="string"?String(z.message):String(z),error:z});if(!window.dispatchEvent(L))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",z);return}console.error(z)},R={map:G,forEach:function(z,L,_){G(z,function(){L.apply(this,arguments)},_)},count:function(z){var L=0;return G(z,function(){L++}),L},toArray:function(z){return G(z,function(L){return L})||[]},only:function(z){if(!Y(z))throw Error("React.Children.only expected to receive a single React element child.");return z}};return Le.Activity=g,Le.Children=R,Le.Component=A,Le.Fragment=a,Le.Profiler=o,Le.PureComponent=j,Le.StrictMode=l,Le.Suspense=p,Le.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=U,Le.__COMPILER_RUNTIME={__proto__:null,c:function(z){return U.H.useMemoCache(z)}},Le.cache=function(z){return function(){return z.apply(null,arguments)}},Le.cacheSignal=function(){return null},Le.cloneElement=function(z,L,_){if(z==null)throw Error("The argument must be a React element, but you passed "+z+".");var re=S({},z.props),ne=z.key;if(L!=null)for(ie in L.key!==void 0&&(ne=""+L.key),L)!F.call(L,ie)||ie==="key"||ie==="__self"||ie==="__source"||ie==="ref"&&L.ref===void 0||(re[ie]=L[ie]);var ie=arguments.length-2;if(ie===1)re.children=_;else if(1<ie){for(var le=Array(ie),be=0;be<ie;be++)le[be]=arguments[be+2];re.children=le}return Q(z.type,ne,re)},Le.createContext=function(z){return z={$$typeof:c,_currentValue:z,_currentValue2:z,_threadCount:0,Provider:null,Consumer:null},z.Provider=z,z.Consumer={$$typeof:s,_context:z},z},Le.createElement=function(z,L,_){var re,ne={},ie=null;if(L!=null)for(re in L.key!==void 0&&(ie=""+L.key),L)F.call(L,re)&&re!=="key"&&re!=="__self"&&re!=="__source"&&(ne[re]=L[re]);var le=arguments.length-2;if(le===1)ne.children=_;else if(1<le){for(var be=Array(le),he=0;he<le;he++)be[he]=arguments[he+2];ne.children=be}if(z&&z.defaultProps)for(re in le=z.defaultProps,le)ne[re]===void 0&&(ne[re]=le[re]);return Q(z,ie,ne)},Le.createRef=function(){return{current:null}},Le.forwardRef=function(z){return{$$typeof:d,render:z}},Le.isValidElement=Y,Le.lazy=function(z){return{$$typeof:y,_payload:{_status:-1,_result:z},_init:te}},Le.memo=function(z,L){return{$$typeof:h,type:z,compare:L===void 0?null:L}},Le.startTransition=function(z){var L=U.T,_={};U.T=_;try{var re=z(),ne=U.S;ne!==null&&ne(_,re),typeof re=="object"&&re!==null&&typeof re.then=="function"&&re.then(M,ce)}catch(ie){ce(ie)}finally{L!==null&&_.types!==null&&(L.types=_.types),U.T=L}},Le.unstable_useCacheRefresh=function(){return U.H.useCacheRefresh()},Le.use=function(z){return U.H.use(z)},Le.useActionState=function(z,L,_){return U.H.useActionState(z,L,_)},Le.useCallback=function(z,L){return U.H.useCallback(z,L)},Le.useContext=function(z){return U.H.useContext(z)},Le.useDebugValue=function(){},Le.useDeferredValue=function(z,L){return U.H.useDeferredValue(z,L)},Le.useEffect=function(z,L){return U.H.useEffect(z,L)},Le.useEffectEvent=function(z){return U.H.useEffectEvent(z)},Le.useId=function(){return U.H.useId()},Le.useImperativeHandle=function(z,L,_){return U.H.useImperativeHandle(z,L,_)},Le.useInsertionEffect=function(z,L){return U.H.useInsertionEffect(z,L)},Le.useLayoutEffect=function(z,L){return U.H.useLayoutEffect(z,L)},Le.useMemo=function(z,L){return U.H.useMemo(z,L)},Le.useOptimistic=function(z,L){return U.H.useOptimistic(z,L)},Le.useReducer=function(z,L,_){return U.H.useReducer(z,L,_)},Le.useRef=function(z){return U.H.useRef(z)},Le.useState=function(z){return U.H.useState(z)},Le.useSyncExternalStore=function(z,L,_){return U.H.useSyncExternalStore(z,L,_)},Le.useTransition=function(){return U.H.useTransition()},Le.version="19.2.4",Le}var iv;function Jh(){return iv||(iv=1,Mp.exports=RA()),Mp.exports}var v=Jh();const er=Rc(v),f1=jA({__proto__:null,default:er},[v]);var Op={exports:{}},To={},Dp={exports:{}},zp={};/**
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 ov;function MA(){return ov||(ov=1,(function(e){function r(B,G){var te=B.length;B.push(G);e:for(;0<te;){var ce=te-1>>>1,R=B[ce];if(0<o(R,G))B[ce]=G,B[te]=R,te=ce;else break e}}function a(B){return B.length===0?null:B[0]}function l(B){if(B.length===0)return null;var G=B[0],te=B.pop();if(te!==G){B[0]=te;e:for(var ce=0,R=B.length,z=R>>>1;ce<z;){var L=2*(ce+1)-1,_=B[L],re=L+1,ne=B[re];if(0>o(_,te))re<R&&0>o(ne,_)?(B[ce]=ne,B[re]=te,ce=re):(B[ce]=_,B[L]=te,ce=L);else if(re<R&&0>o(ne,te))B[ce]=ne,B[re]=te,ce=re;else break e}}return G}function o(B,G){var te=B.sortIndex-G.sortIndex;return te!==0?te:B.id-G.id}if(e.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var s=performance;e.unstable_now=function(){return s.now()}}else{var c=Date,d=c.now();e.unstable_now=function(){return c.now()-d}}var p=[],h=[],y=1,g=null,b=3,w=!1,k=!1,S=!1,C=!1,A=typeof setTimeout=="function"?setTimeout:null,N=typeof clearTimeout=="function"?clearTimeout:null,j=typeof setImmediate<"u"?setImmediate:null;function O(B){for(var G=a(h);G!==null;){if(G.callback===null)l(h);else if(G.startTime<=B)l(h),G.sortIndex=G.expirationTime,r(p,G);else break;G=a(h)}}function D(B){if(S=!1,O(B),!k)if(a(p)!==null)k=!0,M||(M=!0,V());else{var G=a(h);G!==null&&J(D,G.startTime-B)}}var M=!1,U=-1,F=5,Q=-1;function I(){return C?!0:!(e.unstable_now()-Q<F)}function Y(){if(C=!1,M){var B=e.unstable_now();Q=B;var G=!0;try{e:{k=!1,S&&(S=!1,N(U),U=-1),w=!0;var te=b;try{t:{for(O(B),g=a(p);g!==null&&!(g.expirationTime>B&&I());){var ce=g.callback;if(typeof ce=="function"){g.callback=null,b=g.priorityLevel;var R=ce(g.expirationTime<=B);if(B=e.unstable_now(),typeof R=="function"){g.callback=R,O(B),G=!0;break t}g===a(p)&&l(p),O(B)}else l(p);g=a(p)}if(g!==null)G=!0;else{var z=a(h);z!==null&&J(D,z.startTime-B),G=!1}}break e}finally{g=null,b=te,w=!1}G=void 0}}finally{G?V():M=!1}}}var V;if(typeof j=="function")V=function(){j(Y)};else if(typeof MessageChannel<"u"){var ue=new MessageChannel,W=ue.port2;ue.port1.onmessage=Y,V=function(){W.postMessage(null)}}else V=function(){A(Y,0)};function J(B,G){U=A(function(){B(e.unstable_now())},G)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(B){B.callback=null},e.unstable_forceFrameRate=function(B){0>B||125<B?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):F=0<B?Math.floor(1e3/B):5},e.unstable_getCurrentPriorityLevel=function(){return b},e.unstable_next=function(B){switch(b){case 1:case 2:case 3:var G=3;break;default:G=b}var te=b;b=G;try{return B()}finally{b=te}},e.unstable_requestPaint=function(){C=!0},e.unstable_runWithPriority=function(B,G){switch(B){case 1:case 2:case 3:case 4:case 5:break;default:B=3}var te=b;b=B;try{return G()}finally{b=te}},e.unstable_scheduleCallback=function(B,G,te){var ce=e.unstable_now();switch(typeof te=="object"&&te!==null?(te=te.delay,te=typeof te=="number"&&0<te?ce+te:ce):te=ce,B){case 1:var R=-1;break;case 2:R=250;break;case 5:R=1073741823;break;case 4:R=1e4;break;default:R=5e3}return R=te+R,B={id:y++,callback:G,priorityLevel:B,startTime:te,expirationTime:R,sortIndex:-1},te>ce?(B.sortIndex=te,r(h,B),a(p)===null&&B===a(h)&&(S?(N(U),U=-1):S=!0,J(D,te-ce))):(B.sortIndex=R,r(p,B),k||w||(k=!0,M||(M=!0,V()))),B},e.unstable_shouldYield=I,e.unstable_wrapCallback=function(B){var G=b;return function(){var te=b;b=G;try{return B.apply(this,arguments)}finally{b=te}}}})(zp)),zp}var sv;function OA(){return sv||(sv=1,Dp.exports=MA()),Dp.exports}var Lp={exports:{}},Qt={};/**
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 uv;function DA(){if(uv)return Qt;uv=1;var e=Jh();function r(p){var h="https://react.dev/errors/"+p;if(1<arguments.length){h+="?args[]="+encodeURIComponent(arguments[1]);for(var y=2;y<arguments.length;y++)h+="&args[]="+encodeURIComponent(arguments[y])}return"Minified React error #"+p+"; visit "+h+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function a(){}var l={d:{f:a,r:function(){throw Error(r(522))},D:a,C:a,L:a,m:a,X:a,S:a,M:a},p:0,findDOMNode:null},o=Symbol.for("react.portal");function s(p,h,y){var g=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:o,key:g==null?null:""+g,children:p,containerInfo:h,implementation:y}}var c=e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function d(p,h){if(p==="font")return"";if(typeof h=="string")return h==="use-credentials"?h:""}return Qt.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=l,Qt.createPortal=function(p,h){var y=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!h||h.nodeType!==1&&h.nodeType!==9&&h.nodeType!==11)throw Error(r(299));return s(p,h,null,y)},Qt.flushSync=function(p){var h=c.T,y=l.p;try{if(c.T=null,l.p=2,p)return p()}finally{c.T=h,l.p=y,l.d.f()}},Qt.preconnect=function(p,h){typeof p=="string"&&(h?(h=h.crossOrigin,h=typeof h=="string"?h==="use-credentials"?h:"":void 0):h=null,l.d.C(p,h))},Qt.prefetchDNS=function(p){typeof p=="string"&&l.d.D(p)},Qt.preinit=function(p,h){if(typeof p=="string"&&h&&typeof h.as=="string"){var y=h.as,g=d(y,h.crossOrigin),b=typeof h.integrity=="string"?h.integrity:void 0,w=typeof h.fetchPriority=="string"?h.fetchPriority:void 0;y==="style"?l.d.S(p,typeof h.precedence=="string"?h.precedence:void 0,{crossOrigin:g,integrity:b,fetchPriority:w}):y==="script"&&l.d.X(p,{crossOrigin:g,integrity:b,fetchPriority:w,nonce:typeof h.nonce=="string"?h.nonce:void 0})}},Qt.preinitModule=function(p,h){if(typeof p=="string")if(typeof h=="object"&&h!==null){if(h.as==null||h.as==="script"){var y=d(h.as,h.crossOrigin);l.d.M(p,{crossOrigin:y,integrity:typeof h.integrity=="string"?h.integrity:void 0,nonce:typeof h.nonce=="string"?h.nonce:void 0})}}else h==null&&l.d.M(p)},Qt.preload=function(p,h){if(typeof p=="string"&&typeof h=="object"&&h!==null&&typeof h.as=="string"){var y=h.as,g=d(y,h.crossOrigin);l.d.L(p,y,{crossOrigin:g,integrity:typeof h.integrity=="string"?h.integrity:void 0,nonce:typeof h.nonce=="string"?h.nonce:void 0,type:typeof h.type=="string"?h.type:void 0,fetchPriority:typeof h.fetchPriority=="string"?h.fetchPriority:void 0,referrerPolicy:typeof h.referrerPolicy=="string"?h.referrerPolicy:void 0,imageSrcSet:typeof h.imageSrcSet=="string"?h.imageSrcSet:void 0,imageSizes:typeof h.imageSizes=="string"?h.imageSizes:void 0,media:typeof h.media=="string"?h.media:void 0})}},Qt.preloadModule=function(p,h){if(typeof p=="string")if(h){var y=d(h.as,h.crossOrigin);l.d.m(p,{as:typeof h.as=="string"&&h.as!=="script"?h.as:void 0,crossOrigin:y,integrity:typeof h.integrity=="string"?h.integrity:void 0})}else l.d.m(p)},Qt.requestFormReset=function(p){l.d.r(p)},Qt.unstable_batchedUpdates=function(p,h){return p(h)},Qt.useFormState=function(p,h,y){return c.H.useFormState(p,h,y)},Qt.useFormStatus=function(){return c.H.useHostTransitionStatus()},Qt.version="19.2.4",Qt}var cv;function p1(){if(cv)return Lp.exports;cv=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(r){console.error(r)}}return e(),Lp.exports=DA(),Lp.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 dv;function zA(){if(dv)return To;dv=1;var e=OA(),r=Jh(),a=p1();function l(t){var n="https://react.dev/errors/"+t;if(1<arguments.length){n+="?args[]="+encodeURIComponent(arguments[1]);for(var i=2;i<arguments.length;i++)n+="&args[]="+encodeURIComponent(arguments[i])}return"Minified React error #"+t+"; visit "+n+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function o(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)}function s(t){var n=t,i=t;if(t.alternate)for(;n.return;)n=n.return;else{t=n;do n=t,(n.flags&4098)!==0&&(i=n.return),t=n.return;while(t)}return n.tag===3?i:null}function c(t){if(t.tag===13){var n=t.memoizedState;if(n===null&&(t=t.alternate,t!==null&&(n=t.memoizedState)),n!==null)return n.dehydrated}return null}function d(t){if(t.tag===31){var n=t.memoizedState;if(n===null&&(t=t.alternate,t!==null&&(n=t.memoizedState)),n!==null)return n.dehydrated}return null}function p(t){if(s(t)!==t)throw Error(l(188))}function h(t){var n=t.alternate;if(!n){if(n=s(t),n===null)throw Error(l(188));return n!==t?null:t}for(var i=t,u=n;;){var m=i.return;if(m===null)break;var x=m.alternate;if(x===null){if(u=m.return,u!==null){i=u;continue}break}if(m.child===x.child){for(x=m.child;x;){if(x===i)return p(m),t;if(x===u)return p(m),n;x=x.sibling}throw Error(l(188))}if(i.return!==u.return)i=m,u=x;else{for(var E=!1,T=m.child;T;){if(T===i){E=!0,i=m,u=x;break}if(T===u){E=!0,u=m,i=x;break}T=T.sibling}if(!E){for(T=x.child;T;){if(T===i){E=!0,i=x,u=m;break}if(T===u){E=!0,u=x,i=m;break}T=T.sibling}if(!E)throw Error(l(189))}}if(i.alternate!==u)throw Error(l(190))}if(i.tag!==3)throw Error(l(188));return i.stateNode.current===i?t:n}function y(t){var n=t.tag;if(n===5||n===26||n===27||n===6)return t;for(t=t.child;t!==null;){if(n=y(t),n!==null)return n;t=t.sibling}return null}var g=Object.assign,b=Symbol.for("react.element"),w=Symbol.for("react.transitional.element"),k=Symbol.for("react.portal"),S=Symbol.for("react.fragment"),C=Symbol.for("react.strict_mode"),A=Symbol.for("react.profiler"),N=Symbol.for("react.consumer"),j=Symbol.for("react.context"),O=Symbol.for("react.forward_ref"),D=Symbol.for("react.suspense"),M=Symbol.for("react.suspense_list"),U=Symbol.for("react.memo"),F=Symbol.for("react.lazy"),Q=Symbol.for("react.activity"),I=Symbol.for("react.memo_cache_sentinel"),Y=Symbol.iterator;function V(t){return t===null||typeof t!="object"?null:(t=Y&&t[Y]||t["@@iterator"],typeof t=="function"?t:null)}var ue=Symbol.for("react.client.reference");function W(t){if(t==null)return null;if(typeof t=="function")return t.$$typeof===ue?null:t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case S:return"Fragment";case A:return"Profiler";case C:return"StrictMode";case D:return"Suspense";case M:return"SuspenseList";case Q:return"Activity"}if(typeof t=="object")switch(t.$$typeof){case k:return"Portal";case j:return t.displayName||"Context";case N:return(t._context.displayName||"Context")+".Consumer";case O:var n=t.render;return t=t.displayName,t||(t=n.displayName||n.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case U:return n=t.displayName||null,n!==null?n:W(t.type)||"Memo";case F:n=t._payload,t=t._init;try{return W(t(n))}catch{}}return null}var J=Array.isArray,B=r.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,G=a.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,te={pending:!1,data:null,method:null,action:null},ce=[],R=-1;function z(t){return{current:t}}function L(t){0>R||(t.current=ce[R],ce[R]=null,R--)}function _(t,n){R++,ce[R]=t.current,t.current=n}var re=z(null),ne=z(null),ie=z(null),le=z(null);function be(t,n){switch(_(ie,n),_(ne,t),_(re,null),n.nodeType){case 9:case 11:t=(t=n.documentElement)&&(t=t.namespaceURI)?Ab(t):0;break;default:if(t=n.tagName,n=n.namespaceURI)n=Ab(n),t=Nb(n,t);else switch(t){case"svg":t=1;break;case"math":t=2;break;default:t=0}}L(re),_(re,t)}function he(){L(re),L(ne),L(ie)}function Ne(t){t.memoizedState!==null&&_(le,t);var n=re.current,i=Nb(n,t.type);n!==i&&(_(ne,t),_(re,i))}function De(t){ne.current===t&&(L(re),L(ne)),le.current===t&&(L(le),Eo._currentValue=te)}var ze,gt;function nt(t){if(ze===void 0)try{throw Error()}catch(i){var n=i.stack.trim().match(/\n( *(at )?)/);ze=n&&n[1]||"",gt=-1<i.stack.indexOf(`
42
- at`)?" (<anonymous>)":-1<i.stack.indexOf("@")?"@unknown:0:0":""}return`
43
- `+ze+t+gt}var Ot=!1;function Jt(t,n){if(!t||Ot)return"";Ot=!0;var i=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var u={DetermineComponentFrameRoot:function(){try{if(n){var de=function(){throw Error()};if(Object.defineProperty(de.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(de,[])}catch(ee){var Z=ee}Reflect.construct(t,[],de)}else{try{de.call()}catch(ee){Z=ee}t.call(de.prototype)}}else{try{throw Error()}catch(ee){Z=ee}(de=t())&&typeof de.catch=="function"&&de.catch(function(){})}}catch(ee){if(ee&&Z&&typeof ee.stack=="string")return[ee.stack,Z.stack]}return[null,null]}};u.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var m=Object.getOwnPropertyDescriptor(u.DetermineComponentFrameRoot,"name");m&&m.configurable&&Object.defineProperty(u.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var x=u.DetermineComponentFrameRoot(),E=x[0],T=x[1];if(E&&T){var P=E.split(`
44
- `),K=T.split(`
45
- `);for(m=u=0;u<P.length&&!P[u].includes("DetermineComponentFrameRoot");)u++;for(;m<K.length&&!K[m].includes("DetermineComponentFrameRoot");)m++;if(u===P.length||m===K.length)for(u=P.length-1,m=K.length-1;1<=u&&0<=m&&P[u]!==K[m];)m--;for(;1<=u&&0<=m;u--,m--)if(P[u]!==K[m]){if(u!==1||m!==1)do if(u--,m--,0>m||P[u]!==K[m]){var ae=`
46
- `+P[u].replace(" at new "," at ");return t.displayName&&ae.includes("<anonymous>")&&(ae=ae.replace("<anonymous>",t.displayName)),ae}while(1<=u&&0<=m);break}}}finally{Ot=!1,Error.prepareStackTrace=i}return(i=t?t.displayName||t.name:"")?nt(i):""}function Gt(t,n){switch(t.tag){case 26:case 27:case 5:return nt(t.type);case 16:return nt("Lazy");case 13:return t.child!==n&&n!==null?nt("Suspense Fallback"):nt("Suspense");case 19:return nt("SuspenseList");case 0:case 15:return Jt(t.type,!1);case 11:return Jt(t.type.render,!1);case 1:return Jt(t.type,!0);case 31:return nt("Activity");default:return""}}function Rn(t){try{var n="",i=null;do n+=Gt(t,i),i=t,t=t.return;while(t);return n}catch(u){return`
47
- Error generating stack: `+u.message+`
48
- `+u.stack}}var Mn=Object.prototype.hasOwnProperty,an=e.unstable_scheduleCallback,On=e.unstable_cancelCallback,br=e.unstable_shouldYield,Oi=e.unstable_requestPaint,Dt=e.unstable_now,Di=e.unstable_getCurrentPriorityLevel,oe=e.unstable_ImmediatePriority,xe=e.unstable_UserBlockingPriority,Te=e.unstable_NormalPriority,Ie=e.unstable_LowPriority,rt=e.unstable_IdlePriority,Pt=e.log,Je=e.unstable_setDisableYieldValue,He=null,yt=null;function zt(t){if(typeof Pt=="function"&&Je(t),yt&&typeof yt.setStrictMode=="function")try{yt.setStrictMode(He,t)}catch{}}var lt=Math.clz32?Math.clz32:zi,Yt=Math.log,mn=Math.LN2;function zi(t){return t>>>=0,t===0?32:31-(Yt(t)/mn|0)|0}var Dn=256,Sl=262144,Ia=4194304;function vr(t){var n=t&42;if(n!==0)return n;switch(t&-t){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return t&261888;case 262144:case 524288:case 1048576:case 2097152:return t&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return t&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return t}}function Ba(t,n,i){var u=t.pendingLanes;if(u===0)return 0;var m=0,x=t.suspendedLanes,E=t.pingedLanes;t=t.warmLanes;var T=u&134217727;return T!==0?(u=T&~x,u!==0?m=vr(u):(E&=T,E!==0?m=vr(E):i||(i=T&~t,i!==0&&(m=vr(i))))):(T=u&~x,T!==0?m=vr(T):E!==0?m=vr(E):i||(i=u&~t,i!==0&&(m=vr(i)))),m===0?0:n!==0&&n!==m&&(n&x)===0&&(x=m&-m,i=n&-n,x>=i||x===32&&(i&4194048)!==0)?n:m}function Pa(t,n){return(t.pendingLanes&~(t.suspendedLanes&~t.pingedLanes)&n)===0}function bd(t,n){switch(t){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 As(){var t=Ia;return Ia<<=1,(Ia&62914560)===0&&(Ia=4194304),t}function kl(t){for(var n=[],i=0;31>i;i++)n.push(t);return n}function Ye(t,n){t.pendingLanes|=n,n!==268435456&&(t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0)}function vd(t,n,i,u,m,x){var E=t.pendingLanes;t.pendingLanes=i,t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0,t.expiredLanes&=i,t.entangledLanes&=i,t.errorRecoveryDisabledLanes&=i,t.shellSuspendCounter=0;var T=t.entanglements,P=t.expirationTimes,K=t.hiddenUpdates;for(i=E&~i;0<i;){var ae=31-lt(i),de=1<<ae;T[ae]=0,P[ae]=-1;var Z=K[ae];if(Z!==null)for(K[ae]=null,ae=0;ae<Z.length;ae++){var ee=Z[ae];ee!==null&&(ee.lane&=-536870913)}i&=~de}u!==0&&Fa(t,u,0),x!==0&&m===0&&t.tag!==0&&(t.suspendedLanes|=x&~(E&~n))}function Fa(t,n,i){t.pendingLanes|=n,t.suspendedLanes&=~n;var u=31-lt(n);t.entangledLanes|=n,t.entanglements[u]=t.entanglements[u]|1073741824|i&261930}function Ns(t,n){var i=t.entangledLanes|=n;for(t=t.entanglements;i;){var u=31-lt(i),m=1<<u;m&n|t[u]&n&&(t[u]|=n),i&=~m}}function js(t,n){var i=n&-n;return i=(i&42)!==0?1:Li(i),(i&(t.suspendedLanes|n))!==0?0:i}function Li(t){switch(t){case 2:t=1;break;case 8:t=4;break;case 32:t=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:t=128;break;case 268435456:t=134217728;break;default:t=0}return t}function Ii(t){return t&=-t,2<t?8<t?(t&134217727)!==0?32:268435456:8:2}function Ts(){var t=G.p;return t!==0?t:(t=window.event,t===void 0?32:Qb(t.type))}function _s(t,n){var i=G.p;try{return G.p=t,n()}finally{G.p=i}}var lr=Math.random().toString(36).slice(2),Et="__reactFiber$"+lr,Xt="__reactProps$"+lr,Qr="__reactContainer$"+lr,Bi="__reactEvents$"+lr,wd="__reactListeners$"+lr,Sd="__reactHandles$"+lr,Rs="__reactResources$"+lr,Ua="__reactMarker$"+lr;function El(t){delete t[Et],delete t[Xt],delete t[Bi],delete t[wd],delete t[Sd]}function Zr(t){var n=t[Et];if(n)return n;for(var i=t.parentNode;i;){if(n=i[Qr]||i[Et]){if(i=n.alternate,n.child!==null||i!==null&&i.child!==null)for(t=Db(t);t!==null;){if(i=t[Et])return i;t=Db(t)}return n}t=i,i=t.parentNode}return null}function en(t){if(t=t[Et]||t[Qr]){var n=t.tag;if(n===5||n===6||n===13||n===31||n===26||n===27||n===3)return t}return null}function Ha(t){var n=t.tag;if(n===5||n===26||n===27||n===6)return t.stateNode;throw Error(l(33))}function wr(t){var n=t[Rs];return n||(n=t[Rs]={hoistableStyles:new Map,hoistableScripts:new Map}),n}function wt(t){t[Ua]=!0}var Pi=new Set,$={};function Ae(t,n){pe(t,n),pe(t+"Capture",n)}function pe(t,n){for($[t]=n,t=0;t<n.length;t++)Pi.add(n[t])}var me=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]*$"),We={},Ft={};function Sr(t){return Mn.call(Ft,t)?!0:Mn.call(We,t)?!1:me.test(t)?Ft[t]=!0:(We[t]=!0,!1)}function Kt(t,n,i){if(Sr(n))if(i===null)t.removeAttribute(n);else{switch(typeof i){case"undefined":case"function":case"symbol":t.removeAttribute(n);return;case"boolean":var u=n.toLowerCase().slice(0,5);if(u!=="data-"&&u!=="aria-"){t.removeAttribute(n);return}}t.setAttribute(n,""+i)}}function zn(t,n,i){if(i===null)t.removeAttribute(n);else{switch(typeof i){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(n);return}t.setAttribute(n,""+i)}}function gn(t,n,i,u){if(u===null)t.removeAttribute(i);else{switch(typeof u){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(i);return}t.setAttributeNS(n,i,""+u)}}function ln(t){switch(typeof t){case"bigint":case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function xg(t){var n=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(n==="checkbox"||n==="radio")}function wC(t,n,i){var u=Object.getOwnPropertyDescriptor(t.constructor.prototype,n);if(!t.hasOwnProperty(n)&&typeof u<"u"&&typeof u.get=="function"&&typeof u.set=="function"){var m=u.get,x=u.set;return Object.defineProperty(t,n,{configurable:!0,get:function(){return m.call(this)},set:function(E){i=""+E,x.call(this,E)}}),Object.defineProperty(t,n,{enumerable:u.enumerable}),{getValue:function(){return i},setValue:function(E){i=""+E},stopTracking:function(){t._valueTracker=null,delete t[n]}}}}function kd(t){if(!t._valueTracker){var n=xg(t)?"checked":"value";t._valueTracker=wC(t,n,""+t[n])}}function bg(t){if(!t)return!1;var n=t._valueTracker;if(!n)return!0;var i=n.getValue(),u="";return t&&(u=xg(t)?t.checked?"true":"false":t.value),t=u,t!==i?(n.setValue(t),!0):!1}function Ms(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}var SC=/[\n"\\]/g;function Ln(t){return t.replace(SC,function(n){return"\\"+n.charCodeAt(0).toString(16)+" "})}function Ed(t,n,i,u,m,x,E,T){t.name="",E!=null&&typeof E!="function"&&typeof E!="symbol"&&typeof E!="boolean"?t.type=E:t.removeAttribute("type"),n!=null?E==="number"?(n===0&&t.value===""||t.value!=n)&&(t.value=""+ln(n)):t.value!==""+ln(n)&&(t.value=""+ln(n)):E!=="submit"&&E!=="reset"||t.removeAttribute("value"),n!=null?Cd(t,E,ln(n)):i!=null?Cd(t,E,ln(i)):u!=null&&t.removeAttribute("value"),m==null&&x!=null&&(t.defaultChecked=!!x),m!=null&&(t.checked=m&&typeof m!="function"&&typeof m!="symbol"),T!=null&&typeof T!="function"&&typeof T!="symbol"&&typeof T!="boolean"?t.name=""+ln(T):t.removeAttribute("name")}function vg(t,n,i,u,m,x,E,T){if(x!=null&&typeof x!="function"&&typeof x!="symbol"&&typeof x!="boolean"&&(t.type=x),n!=null||i!=null){if(!(x!=="submit"&&x!=="reset"||n!=null)){kd(t);return}i=i!=null?""+ln(i):"",n=n!=null?""+ln(n):i,T||n===t.value||(t.value=n),t.defaultValue=n}u=u!=null?u:m,u=typeof u!="function"&&typeof u!="symbol"&&!!u,t.checked=T?t.checked:!!u,t.defaultChecked=!!u,E!=null&&typeof E!="function"&&typeof E!="symbol"&&typeof E!="boolean"&&(t.name=E),kd(t)}function Cd(t,n,i){n==="number"&&Ms(t.ownerDocument)===t||t.defaultValue===""+i||(t.defaultValue=""+i)}function Cl(t,n,i,u){if(t=t.options,n){n={};for(var m=0;m<i.length;m++)n["$"+i[m]]=!0;for(i=0;i<t.length;i++)m=n.hasOwnProperty("$"+t[i].value),t[i].selected!==m&&(t[i].selected=m),m&&u&&(t[i].defaultSelected=!0)}else{for(i=""+ln(i),n=null,m=0;m<t.length;m++){if(t[m].value===i){t[m].selected=!0,u&&(t[m].defaultSelected=!0);return}n!==null||t[m].disabled||(n=t[m])}n!==null&&(n.selected=!0)}}function wg(t,n,i){if(n!=null&&(n=""+ln(n),n!==t.value&&(t.value=n),i==null)){t.defaultValue!==n&&(t.defaultValue=n);return}t.defaultValue=i!=null?""+ln(i):""}function Sg(t,n,i,u){if(n==null){if(u!=null){if(i!=null)throw Error(l(92));if(J(u)){if(1<u.length)throw Error(l(93));u=u[0]}i=u}i==null&&(i=""),n=i}i=ln(n),t.defaultValue=i,u=t.textContent,u===i&&u!==""&&u!==null&&(t.value=u),kd(t)}function Al(t,n){if(n){var i=t.firstChild;if(i&&i===t.lastChild&&i.nodeType===3){i.nodeValue=n;return}}t.textContent=n}var kC=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 kg(t,n,i){var u=n.indexOf("--")===0;i==null||typeof i=="boolean"||i===""?u?t.setProperty(n,""):n==="float"?t.cssFloat="":t[n]="":u?t.setProperty(n,i):typeof i!="number"||i===0||kC.has(n)?n==="float"?t.cssFloat=i:t[n]=(""+i).trim():t[n]=i+"px"}function Eg(t,n,i){if(n!=null&&typeof n!="object")throw Error(l(62));if(t=t.style,i!=null){for(var u in i)!i.hasOwnProperty(u)||n!=null&&n.hasOwnProperty(u)||(u.indexOf("--")===0?t.setProperty(u,""):u==="float"?t.cssFloat="":t[u]="");for(var m in n)u=n[m],n.hasOwnProperty(m)&&i[m]!==u&&kg(t,m,u)}else for(var x in n)n.hasOwnProperty(x)&&kg(t,x,n[x])}function Ad(t){if(t.indexOf("-")===-1)return!1;switch(t){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var EC=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"]]),CC=/^[\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 Os(t){return CC.test(""+t)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":t}function kr(){}var Nd=null;function jd(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var Nl=null,jl=null;function Cg(t){var n=en(t);if(n&&(t=n.stateNode)){var i=t[Xt]||null;e:switch(t=n.stateNode,n.type){case"input":if(Ed(t,i.value,i.defaultValue,i.defaultValue,i.checked,i.defaultChecked,i.type,i.name),n=i.name,i.type==="radio"&&n!=null){for(i=t;i.parentNode;)i=i.parentNode;for(i=i.querySelectorAll('input[name="'+Ln(""+n)+'"][type="radio"]'),n=0;n<i.length;n++){var u=i[n];if(u!==t&&u.form===t.form){var m=u[Xt]||null;if(!m)throw Error(l(90));Ed(u,m.value,m.defaultValue,m.defaultValue,m.checked,m.defaultChecked,m.type,m.name)}}for(n=0;n<i.length;n++)u=i[n],u.form===t.form&&bg(u)}break e;case"textarea":wg(t,i.value,i.defaultValue);break e;case"select":n=i.value,n!=null&&Cl(t,!!i.multiple,n,!1)}}}var Td=!1;function Ag(t,n,i){if(Td)return t(n,i);Td=!0;try{var u=t(n);return u}finally{if(Td=!1,(Nl!==null||jl!==null)&&(vu(),Nl&&(n=Nl,t=jl,jl=Nl=null,Cg(n),t)))for(n=0;n<t.length;n++)Cg(t[n])}}function Fi(t,n){var i=t.stateNode;if(i===null)return null;var u=i[Xt]||null;if(u===null)return null;i=u[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":(u=!u.disabled)||(t=t.type,u=!(t==="button"||t==="input"||t==="select"||t==="textarea")),t=!u;break e;default:t=!1}if(t)return null;if(i&&typeof i!="function")throw Error(l(231,n,typeof i));return i}var Er=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),_d=!1;if(Er)try{var Ui={};Object.defineProperty(Ui,"passive",{get:function(){_d=!0}}),window.addEventListener("test",Ui,Ui),window.removeEventListener("test",Ui,Ui)}catch{_d=!1}var Wr=null,Rd=null,Ds=null;function Ng(){if(Ds)return Ds;var t,n=Rd,i=n.length,u,m="value"in Wr?Wr.value:Wr.textContent,x=m.length;for(t=0;t<i&&n[t]===m[t];t++);var E=i-t;for(u=1;u<=E&&n[i-u]===m[x-u];u++);return Ds=m.slice(t,1<u?1-u:void 0)}function zs(t){var n=t.keyCode;return"charCode"in t?(t=t.charCode,t===0&&n===13&&(t=13)):t=n,t===10&&(t=13),32<=t||t===13?t:0}function Ls(){return!0}function jg(){return!1}function on(t){function n(i,u,m,x,E){this._reactName=i,this._targetInst=m,this.type=u,this.nativeEvent=x,this.target=E,this.currentTarget=null;for(var T in t)t.hasOwnProperty(T)&&(i=t[T],this[T]=i?i(x):x[T]);return this.isDefaultPrevented=(x.defaultPrevented!=null?x.defaultPrevented:x.returnValue===!1)?Ls:jg,this.isPropagationStopped=jg,this}return g(n.prototype,{preventDefault:function(){this.defaultPrevented=!0;var i=this.nativeEvent;i&&(i.preventDefault?i.preventDefault():typeof i.returnValue!="unknown"&&(i.returnValue=!1),this.isDefaultPrevented=Ls)},stopPropagation:function(){var i=this.nativeEvent;i&&(i.stopPropagation?i.stopPropagation():typeof i.cancelBubble!="unknown"&&(i.cancelBubble=!0),this.isPropagationStopped=Ls)},persist:function(){},isPersistent:Ls}),n}var Va={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(t){return t.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Is=on(Va),Hi=g({},Va,{view:0,detail:0}),AC=on(Hi),Md,Od,Vi,Bs=g({},Hi,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:zd,button:0,buttons:0,relatedTarget:function(t){return t.relatedTarget===void 0?t.fromElement===t.srcElement?t.toElement:t.fromElement:t.relatedTarget},movementX:function(t){return"movementX"in t?t.movementX:(t!==Vi&&(Vi&&t.type==="mousemove"?(Md=t.screenX-Vi.screenX,Od=t.screenY-Vi.screenY):Od=Md=0,Vi=t),Md)},movementY:function(t){return"movementY"in t?t.movementY:Od}}),Tg=on(Bs),NC=g({},Bs,{dataTransfer:0}),jC=on(NC),TC=g({},Hi,{relatedTarget:0}),Dd=on(TC),_C=g({},Va,{animationName:0,elapsedTime:0,pseudoElement:0}),RC=on(_C),MC=g({},Va,{clipboardData:function(t){return"clipboardData"in t?t.clipboardData:window.clipboardData}}),OC=on(MC),DC=g({},Va,{data:0}),_g=on(DC),zC={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},LC={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"},IC={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function BC(t){var n=this.nativeEvent;return n.getModifierState?n.getModifierState(t):(t=IC[t])?!!n[t]:!1}function zd(){return BC}var PC=g({},Hi,{key:function(t){if(t.key){var n=zC[t.key]||t.key;if(n!=="Unidentified")return n}return t.type==="keypress"?(t=zs(t),t===13?"Enter":String.fromCharCode(t)):t.type==="keydown"||t.type==="keyup"?LC[t.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:zd,charCode:function(t){return t.type==="keypress"?zs(t):0},keyCode:function(t){return t.type==="keydown"||t.type==="keyup"?t.keyCode:0},which:function(t){return t.type==="keypress"?zs(t):t.type==="keydown"||t.type==="keyup"?t.keyCode:0}}),FC=on(PC),UC=g({},Bs,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Rg=on(UC),HC=g({},Hi,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:zd}),VC=on(HC),$C=g({},Va,{propertyName:0,elapsedTime:0,pseudoElement:0}),qC=on($C),GC=g({},Bs,{deltaX:function(t){return"deltaX"in t?t.deltaX:"wheelDeltaX"in t?-t.wheelDeltaX:0},deltaY:function(t){return"deltaY"in t?t.deltaY:"wheelDeltaY"in t?-t.wheelDeltaY:"wheelDelta"in t?-t.wheelDelta:0},deltaZ:0,deltaMode:0}),YC=on(GC),XC=g({},Va,{newState:0,oldState:0}),KC=on(XC),QC=[9,13,27,32],Ld=Er&&"CompositionEvent"in window,$i=null;Er&&"documentMode"in document&&($i=document.documentMode);var ZC=Er&&"TextEvent"in window&&!$i,Mg=Er&&(!Ld||$i&&8<$i&&11>=$i),Og=" ",Dg=!1;function zg(t,n){switch(t){case"keyup":return QC.indexOf(n.keyCode)!==-1;case"keydown":return n.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Lg(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var Tl=!1;function WC(t,n){switch(t){case"compositionend":return Lg(n);case"keypress":return n.which!==32?null:(Dg=!0,Og);case"textInput":return t=n.data,t===Og&&Dg?null:t;default:return null}}function JC(t,n){if(Tl)return t==="compositionend"||!Ld&&zg(t,n)?(t=Ng(),Ds=Rd=Wr=null,Tl=!1,t):null;switch(t){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 Mg&&n.locale!=="ko"?null:n.data;default:return null}}var e2={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 Ig(t){var n=t&&t.nodeName&&t.nodeName.toLowerCase();return n==="input"?!!e2[t.type]:n==="textarea"}function Bg(t,n,i,u){Nl?jl?jl.push(u):jl=[u]:Nl=u,n=Nu(n,"onChange"),0<n.length&&(i=new Is("onChange","change",null,i,u),t.push({event:i,listeners:n}))}var qi=null,Gi=null;function t2(t){vb(t,0)}function Ps(t){var n=Ha(t);if(bg(n))return t}function Pg(t,n){if(t==="change")return n}var Fg=!1;if(Er){var Id;if(Er){var Bd="oninput"in document;if(!Bd){var Ug=document.createElement("div");Ug.setAttribute("oninput","return;"),Bd=typeof Ug.oninput=="function"}Id=Bd}else Id=!1;Fg=Id&&(!document.documentMode||9<document.documentMode)}function Hg(){qi&&(qi.detachEvent("onpropertychange",Vg),Gi=qi=null)}function Vg(t){if(t.propertyName==="value"&&Ps(Gi)){var n=[];Bg(n,Gi,t,jd(t)),Ag(t2,n)}}function n2(t,n,i){t==="focusin"?(Hg(),qi=n,Gi=i,qi.attachEvent("onpropertychange",Vg)):t==="focusout"&&Hg()}function r2(t){if(t==="selectionchange"||t==="keyup"||t==="keydown")return Ps(Gi)}function a2(t,n){if(t==="click")return Ps(n)}function l2(t,n){if(t==="input"||t==="change")return Ps(n)}function i2(t,n){return t===n&&(t!==0||1/t===1/n)||t!==t&&n!==n}var yn=typeof Object.is=="function"?Object.is:i2;function Yi(t,n){if(yn(t,n))return!0;if(typeof t!="object"||t===null||typeof n!="object"||n===null)return!1;var i=Object.keys(t),u=Object.keys(n);if(i.length!==u.length)return!1;for(u=0;u<i.length;u++){var m=i[u];if(!Mn.call(n,m)||!yn(t[m],n[m]))return!1}return!0}function $g(t){for(;t&&t.firstChild;)t=t.firstChild;return t}function qg(t,n){var i=$g(t);t=0;for(var u;i;){if(i.nodeType===3){if(u=t+i.textContent.length,t<=n&&u>=n)return{node:i,offset:n-t};t=u}e:{for(;i;){if(i.nextSibling){i=i.nextSibling;break e}i=i.parentNode}i=void 0}i=$g(i)}}function Gg(t,n){return t&&n?t===n?!0:t&&t.nodeType===3?!1:n&&n.nodeType===3?Gg(t,n.parentNode):"contains"in t?t.contains(n):t.compareDocumentPosition?!!(t.compareDocumentPosition(n)&16):!1:!1}function Yg(t){t=t!=null&&t.ownerDocument!=null&&t.ownerDocument.defaultView!=null?t.ownerDocument.defaultView:window;for(var n=Ms(t.document);n instanceof t.HTMLIFrameElement;){try{var i=typeof n.contentWindow.location.href=="string"}catch{i=!1}if(i)t=n.contentWindow;else break;n=Ms(t.document)}return n}function Pd(t){var n=t&&t.nodeName&&t.nodeName.toLowerCase();return n&&(n==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||n==="textarea"||t.contentEditable==="true")}var o2=Er&&"documentMode"in document&&11>=document.documentMode,_l=null,Fd=null,Xi=null,Ud=!1;function Xg(t,n,i){var u=i.window===i?i.document:i.nodeType===9?i:i.ownerDocument;Ud||_l==null||_l!==Ms(u)||(u=_l,"selectionStart"in u&&Pd(u)?u={start:u.selectionStart,end:u.selectionEnd}:(u=(u.ownerDocument&&u.ownerDocument.defaultView||window).getSelection(),u={anchorNode:u.anchorNode,anchorOffset:u.anchorOffset,focusNode:u.focusNode,focusOffset:u.focusOffset}),Xi&&Yi(Xi,u)||(Xi=u,u=Nu(Fd,"onSelect"),0<u.length&&(n=new Is("onSelect","select",null,n,i),t.push({event:n,listeners:u}),n.target=_l)))}function $a(t,n){var i={};return i[t.toLowerCase()]=n.toLowerCase(),i["Webkit"+t]="webkit"+n,i["Moz"+t]="moz"+n,i}var Rl={animationend:$a("Animation","AnimationEnd"),animationiteration:$a("Animation","AnimationIteration"),animationstart:$a("Animation","AnimationStart"),transitionrun:$a("Transition","TransitionRun"),transitionstart:$a("Transition","TransitionStart"),transitioncancel:$a("Transition","TransitionCancel"),transitionend:$a("Transition","TransitionEnd")},Hd={},Kg={};Er&&(Kg=document.createElement("div").style,"AnimationEvent"in window||(delete Rl.animationend.animation,delete Rl.animationiteration.animation,delete Rl.animationstart.animation),"TransitionEvent"in window||delete Rl.transitionend.transition);function qa(t){if(Hd[t])return Hd[t];if(!Rl[t])return t;var n=Rl[t],i;for(i in n)if(n.hasOwnProperty(i)&&i in Kg)return Hd[t]=n[i];return t}var Qg=qa("animationend"),Zg=qa("animationiteration"),Wg=qa("animationstart"),s2=qa("transitionrun"),u2=qa("transitionstart"),c2=qa("transitioncancel"),Jg=qa("transitionend"),ey=new Map,Vd="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(" ");Vd.push("scrollEnd");function Qn(t,n){ey.set(t,n),Ae(n,[t])}var Fs=typeof reportError=="function"?reportError:function(t){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var n=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(n))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",t);return}console.error(t)},In=[],Ml=0,$d=0;function Us(){for(var t=Ml,n=$d=Ml=0;n<t;){var i=In[n];In[n++]=null;var u=In[n];In[n++]=null;var m=In[n];In[n++]=null;var x=In[n];if(In[n++]=null,u!==null&&m!==null){var E=u.pending;E===null?m.next=m:(m.next=E.next,E.next=m),u.pending=m}x!==0&&ty(i,m,x)}}function Hs(t,n,i,u){In[Ml++]=t,In[Ml++]=n,In[Ml++]=i,In[Ml++]=u,$d|=u,t.lanes|=u,t=t.alternate,t!==null&&(t.lanes|=u)}function qd(t,n,i,u){return Hs(t,n,i,u),Vs(t)}function Ga(t,n){return Hs(t,null,null,n),Vs(t)}function ty(t,n,i){t.lanes|=i;var u=t.alternate;u!==null&&(u.lanes|=i);for(var m=!1,x=t.return;x!==null;)x.childLanes|=i,u=x.alternate,u!==null&&(u.childLanes|=i),x.tag===22&&(t=x.stateNode,t===null||t._visibility&1||(m=!0)),t=x,x=x.return;return t.tag===3?(x=t.stateNode,m&&n!==null&&(m=31-lt(i),t=x.hiddenUpdates,u=t[m],u===null?t[m]=[n]:u.push(n),n.lane=i|536870912),x):null}function Vs(t){if(50<yo)throw yo=0,tp=null,Error(l(185));for(var n=t.return;n!==null;)t=n,n=t.return;return t.tag===3?t.stateNode:null}var Ol={};function d2(t,n,i,u){this.tag=t,this.key=i,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=u,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function xn(t,n,i,u){return new d2(t,n,i,u)}function Gd(t){return t=t.prototype,!(!t||!t.isReactComponent)}function Cr(t,n){var i=t.alternate;return i===null?(i=xn(t.tag,n,t.key,t.mode),i.elementType=t.elementType,i.type=t.type,i.stateNode=t.stateNode,i.alternate=t,t.alternate=i):(i.pendingProps=n,i.type=t.type,i.flags=0,i.subtreeFlags=0,i.deletions=null),i.flags=t.flags&65011712,i.childLanes=t.childLanes,i.lanes=t.lanes,i.child=t.child,i.memoizedProps=t.memoizedProps,i.memoizedState=t.memoizedState,i.updateQueue=t.updateQueue,n=t.dependencies,i.dependencies=n===null?null:{lanes:n.lanes,firstContext:n.firstContext},i.sibling=t.sibling,i.index=t.index,i.ref=t.ref,i.refCleanup=t.refCleanup,i}function ny(t,n){t.flags&=65011714;var i=t.alternate;return i===null?(t.childLanes=0,t.lanes=n,t.child=null,t.subtreeFlags=0,t.memoizedProps=null,t.memoizedState=null,t.updateQueue=null,t.dependencies=null,t.stateNode=null):(t.childLanes=i.childLanes,t.lanes=i.lanes,t.child=i.child,t.subtreeFlags=0,t.deletions=null,t.memoizedProps=i.memoizedProps,t.memoizedState=i.memoizedState,t.updateQueue=i.updateQueue,t.type=i.type,n=i.dependencies,t.dependencies=n===null?null:{lanes:n.lanes,firstContext:n.firstContext}),t}function $s(t,n,i,u,m,x){var E=0;if(u=t,typeof t=="function")Gd(t)&&(E=1);else if(typeof t=="string")E=gA(t,i,re.current)?26:t==="html"||t==="head"||t==="body"?27:5;else e:switch(t){case Q:return t=xn(31,i,n,m),t.elementType=Q,t.lanes=x,t;case S:return Ya(i.children,m,x,n);case C:E=8,m|=24;break;case A:return t=xn(12,i,n,m|2),t.elementType=A,t.lanes=x,t;case D:return t=xn(13,i,n,m),t.elementType=D,t.lanes=x,t;case M:return t=xn(19,i,n,m),t.elementType=M,t.lanes=x,t;default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case j:E=10;break e;case N:E=9;break e;case O:E=11;break e;case U:E=14;break e;case F:E=16,u=null;break e}E=29,i=Error(l(130,t===null?"null":typeof t,"")),u=null}return n=xn(E,i,n,m),n.elementType=t,n.type=u,n.lanes=x,n}function Ya(t,n,i,u){return t=xn(7,t,u,n),t.lanes=i,t}function Yd(t,n,i){return t=xn(6,t,null,n),t.lanes=i,t}function ry(t){var n=xn(18,null,null,0);return n.stateNode=t,n}function Xd(t,n,i){return n=xn(4,t.children!==null?t.children:[],t.key,n),n.lanes=i,n.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},n}var ay=new WeakMap;function Bn(t,n){if(typeof t=="object"&&t!==null){var i=ay.get(t);return i!==void 0?i:(n={value:t,source:n,stack:Rn(n)},ay.set(t,n),n)}return{value:t,source:n,stack:Rn(n)}}var Dl=[],zl=0,qs=null,Ki=0,Pn=[],Fn=0,Jr=null,ir=1,or="";function Ar(t,n){Dl[zl++]=Ki,Dl[zl++]=qs,qs=t,Ki=n}function ly(t,n,i){Pn[Fn++]=ir,Pn[Fn++]=or,Pn[Fn++]=Jr,Jr=t;var u=ir;t=or;var m=32-lt(u)-1;u&=~(1<<m),i+=1;var x=32-lt(n)+m;if(30<x){var E=m-m%5;x=(u&(1<<E)-1).toString(32),u>>=E,m-=E,ir=1<<32-lt(n)+m|i<<m|u,or=x+t}else ir=1<<x|i<<m|u,or=t}function Kd(t){t.return!==null&&(Ar(t,1),ly(t,1,0))}function Qd(t){for(;t===qs;)qs=Dl[--zl],Dl[zl]=null,Ki=Dl[--zl],Dl[zl]=null;for(;t===Jr;)Jr=Pn[--Fn],Pn[Fn]=null,or=Pn[--Fn],Pn[Fn]=null,ir=Pn[--Fn],Pn[Fn]=null}function iy(t,n){Pn[Fn++]=ir,Pn[Fn++]=or,Pn[Fn++]=Jr,ir=n.id,or=n.overflow,Jr=t}var Ut=null,ht=null,Qe=!1,ea=null,Un=!1,Zd=Error(l(519));function ta(t){var n=Error(l(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw Qi(Bn(n,t)),Zd}function oy(t){var n=t.stateNode,i=t.type,u=t.memoizedProps;switch(n[Et]=t,n[Xt]=u,i){case"dialog":qe("cancel",n),qe("close",n);break;case"iframe":case"object":case"embed":qe("load",n);break;case"video":case"audio":for(i=0;i<bo.length;i++)qe(bo[i],n);break;case"source":qe("error",n);break;case"img":case"image":case"link":qe("error",n),qe("load",n);break;case"details":qe("toggle",n);break;case"input":qe("invalid",n),vg(n,u.value,u.defaultValue,u.checked,u.defaultChecked,u.type,u.name,!0);break;case"select":qe("invalid",n);break;case"textarea":qe("invalid",n),Sg(n,u.value,u.defaultValue,u.children)}i=u.children,typeof i!="string"&&typeof i!="number"&&typeof i!="bigint"||n.textContent===""+i||u.suppressHydrationWarning===!0||Eb(n.textContent,i)?(u.popover!=null&&(qe("beforetoggle",n),qe("toggle",n)),u.onScroll!=null&&qe("scroll",n),u.onScrollEnd!=null&&qe("scrollend",n),u.onClick!=null&&(n.onclick=kr),n=!0):n=!1,n||ta(t,!0)}function sy(t){for(Ut=t.return;Ut;)switch(Ut.tag){case 5:case 31:case 13:Un=!1;return;case 27:case 3:Un=!0;return;default:Ut=Ut.return}}function Ll(t){if(t!==Ut)return!1;if(!Qe)return sy(t),Qe=!0,!1;var n=t.tag,i;if((i=n!==3&&n!==27)&&((i=n===5)&&(i=t.type,i=!(i!=="form"&&i!=="button")||gp(t.type,t.memoizedProps)),i=!i),i&&ht&&ta(t),sy(t),n===13){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(l(317));ht=Ob(t)}else if(n===31){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(l(317));ht=Ob(t)}else n===27?(n=ht,ma(t.type)?(t=wp,wp=null,ht=t):ht=n):ht=Ut?Vn(t.stateNode.nextSibling):null;return!0}function Xa(){ht=Ut=null,Qe=!1}function Wd(){var t=ea;return t!==null&&(dn===null?dn=t:dn.push.apply(dn,t),ea=null),t}function Qi(t){ea===null?ea=[t]:ea.push(t)}var Jd=z(null),Ka=null,Nr=null;function na(t,n,i){_(Jd,n._currentValue),n._currentValue=i}function jr(t){t._currentValue=Jd.current,L(Jd)}function ef(t,n,i){for(;t!==null;){var u=t.alternate;if((t.childLanes&n)!==n?(t.childLanes|=n,u!==null&&(u.childLanes|=n)):u!==null&&(u.childLanes&n)!==n&&(u.childLanes|=n),t===i)break;t=t.return}}function tf(t,n,i,u){var m=t.child;for(m!==null&&(m.return=t);m!==null;){var x=m.dependencies;if(x!==null){var E=m.child;x=x.firstContext;e:for(;x!==null;){var T=x;x=m;for(var P=0;P<n.length;P++)if(T.context===n[P]){x.lanes|=i,T=x.alternate,T!==null&&(T.lanes|=i),ef(x.return,i,t),u||(E=null);break e}x=T.next}}else if(m.tag===18){if(E=m.return,E===null)throw Error(l(341));E.lanes|=i,x=E.alternate,x!==null&&(x.lanes|=i),ef(E,i,t),E=null}else E=m.child;if(E!==null)E.return=m;else for(E=m;E!==null;){if(E===t){E=null;break}if(m=E.sibling,m!==null){m.return=E.return,E=m;break}E=E.return}m=E}}function Il(t,n,i,u){t=null;for(var m=n,x=!1;m!==null;){if(!x){if((m.flags&524288)!==0)x=!0;else if((m.flags&262144)!==0)break}if(m.tag===10){var E=m.alternate;if(E===null)throw Error(l(387));if(E=E.memoizedProps,E!==null){var T=m.type;yn(m.pendingProps.value,E.value)||(t!==null?t.push(T):t=[T])}}else if(m===le.current){if(E=m.alternate,E===null)throw Error(l(387));E.memoizedState.memoizedState!==m.memoizedState.memoizedState&&(t!==null?t.push(Eo):t=[Eo])}m=m.return}t!==null&&tf(n,t,i,u),n.flags|=262144}function Gs(t){for(t=t.firstContext;t!==null;){if(!yn(t.context._currentValue,t.memoizedValue))return!0;t=t.next}return!1}function Qa(t){Ka=t,Nr=null,t=t.dependencies,t!==null&&(t.firstContext=null)}function Ht(t){return uy(Ka,t)}function Ys(t,n){return Ka===null&&Qa(t),uy(t,n)}function uy(t,n){var i=n._currentValue;if(n={context:n,memoizedValue:i,next:null},Nr===null){if(t===null)throw Error(l(308));Nr=n,t.dependencies={lanes:0,firstContext:n},t.flags|=524288}else Nr=Nr.next=n;return i}var f2=typeof AbortController<"u"?AbortController:function(){var t=[],n=this.signal={aborted:!1,addEventListener:function(i,u){t.push(u)}};this.abort=function(){n.aborted=!0,t.forEach(function(i){return i()})}},p2=e.unstable_scheduleCallback,h2=e.unstable_NormalPriority,Ct={$$typeof:j,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function nf(){return{controller:new f2,data:new Map,refCount:0}}function Zi(t){t.refCount--,t.refCount===0&&p2(h2,function(){t.controller.abort()})}var Wi=null,rf=0,Bl=0,Pl=null;function m2(t,n){if(Wi===null){var i=Wi=[];rf=0,Bl=op(),Pl={status:"pending",value:void 0,then:function(u){i.push(u)}}}return rf++,n.then(cy,cy),n}function cy(){if(--rf===0&&Wi!==null){Pl!==null&&(Pl.status="fulfilled");var t=Wi;Wi=null,Bl=0,Pl=null;for(var n=0;n<t.length;n++)(0,t[n])()}}function g2(t,n){var i=[],u={status:"pending",value:null,reason:null,then:function(m){i.push(m)}};return t.then(function(){u.status="fulfilled",u.value=n;for(var m=0;m<i.length;m++)(0,i[m])(n)},function(m){for(u.status="rejected",u.reason=m,m=0;m<i.length;m++)(0,i[m])(void 0)}),u}var dy=B.S;B.S=function(t,n){Xx=Dt(),typeof n=="object"&&n!==null&&typeof n.then=="function"&&m2(t,n),dy!==null&&dy(t,n)};var Za=z(null);function af(){var t=Za.current;return t!==null?t:dt.pooledCache}function Xs(t,n){n===null?_(Za,Za.current):_(Za,n.pool)}function fy(){var t=af();return t===null?null:{parent:Ct._currentValue,pool:t}}var Fl=Error(l(460)),lf=Error(l(474)),Ks=Error(l(542)),Qs={then:function(){}};function py(t){return t=t.status,t==="fulfilled"||t==="rejected"}function hy(t,n,i){switch(i=t[i],i===void 0?t.push(n):i!==n&&(n.then(kr,kr),n=i),n.status){case"fulfilled":return n.value;case"rejected":throw t=n.reason,gy(t),t;default:if(typeof n.status=="string")n.then(kr,kr);else{if(t=dt,t!==null&&100<t.shellSuspendCounter)throw Error(l(482));t=n,t.status="pending",t.then(function(u){if(n.status==="pending"){var m=n;m.status="fulfilled",m.value=u}},function(u){if(n.status==="pending"){var m=n;m.status="rejected",m.reason=u}})}switch(n.status){case"fulfilled":return n.value;case"rejected":throw t=n.reason,gy(t),t}throw Ja=n,Fl}}function Wa(t){try{var n=t._init;return n(t._payload)}catch(i){throw i!==null&&typeof i=="object"&&typeof i.then=="function"?(Ja=i,Fl):i}}var Ja=null;function my(){if(Ja===null)throw Error(l(459));var t=Ja;return Ja=null,t}function gy(t){if(t===Fl||t===Ks)throw Error(l(483))}var Ul=null,Ji=0;function Zs(t){var n=Ji;return Ji+=1,Ul===null&&(Ul=[]),hy(Ul,t,n)}function eo(t,n){n=n.props.ref,t.ref=n!==void 0?n:null}function Ws(t,n){throw n.$$typeof===b?Error(l(525)):(t=Object.prototype.toString.call(n),Error(l(31,t==="[object Object]"?"object with keys {"+Object.keys(n).join(", ")+"}":t)))}function yy(t){function n(q,H){if(t){var X=q.deletions;X===null?(q.deletions=[H],q.flags|=16):X.push(H)}}function i(q,H){if(!t)return null;for(;H!==null;)n(q,H),H=H.sibling;return null}function u(q){for(var H=new Map;q!==null;)q.key!==null?H.set(q.key,q):H.set(q.index,q),q=q.sibling;return H}function m(q,H){return q=Cr(q,H),q.index=0,q.sibling=null,q}function x(q,H,X){return q.index=X,t?(X=q.alternate,X!==null?(X=X.index,X<H?(q.flags|=67108866,H):X):(q.flags|=67108866,H)):(q.flags|=1048576,H)}function E(q){return t&&q.alternate===null&&(q.flags|=67108866),q}function T(q,H,X,se){return H===null||H.tag!==6?(H=Yd(X,q.mode,se),H.return=q,H):(H=m(H,X),H.return=q,H)}function P(q,H,X,se){var je=X.type;return je===S?ae(q,H,X.props.children,se,X.key):H!==null&&(H.elementType===je||typeof je=="object"&&je!==null&&je.$$typeof===F&&Wa(je)===H.type)?(H=m(H,X.props),eo(H,X),H.return=q,H):(H=$s(X.type,X.key,X.props,null,q.mode,se),eo(H,X),H.return=q,H)}function K(q,H,X,se){return H===null||H.tag!==4||H.stateNode.containerInfo!==X.containerInfo||H.stateNode.implementation!==X.implementation?(H=Xd(X,q.mode,se),H.return=q,H):(H=m(H,X.children||[]),H.return=q,H)}function ae(q,H,X,se,je){return H===null||H.tag!==7?(H=Ya(X,q.mode,se,je),H.return=q,H):(H=m(H,X),H.return=q,H)}function de(q,H,X){if(typeof H=="string"&&H!==""||typeof H=="number"||typeof H=="bigint")return H=Yd(""+H,q.mode,X),H.return=q,H;if(typeof H=="object"&&H!==null){switch(H.$$typeof){case w:return X=$s(H.type,H.key,H.props,null,q.mode,X),eo(X,H),X.return=q,X;case k:return H=Xd(H,q.mode,X),H.return=q,H;case F:return H=Wa(H),de(q,H,X)}if(J(H)||V(H))return H=Ya(H,q.mode,X,null),H.return=q,H;if(typeof H.then=="function")return de(q,Zs(H),X);if(H.$$typeof===j)return de(q,Ys(q,H),X);Ws(q,H)}return null}function Z(q,H,X,se){var je=H!==null?H.key:null;if(typeof X=="string"&&X!==""||typeof X=="number"||typeof X=="bigint")return je!==null?null:T(q,H,""+X,se);if(typeof X=="object"&&X!==null){switch(X.$$typeof){case w:return X.key===je?P(q,H,X,se):null;case k:return X.key===je?K(q,H,X,se):null;case F:return X=Wa(X),Z(q,H,X,se)}if(J(X)||V(X))return je!==null?null:ae(q,H,X,se,null);if(typeof X.then=="function")return Z(q,H,Zs(X),se);if(X.$$typeof===j)return Z(q,H,Ys(q,X),se);Ws(q,X)}return null}function ee(q,H,X,se,je){if(typeof se=="string"&&se!==""||typeof se=="number"||typeof se=="bigint")return q=q.get(X)||null,T(H,q,""+se,je);if(typeof se=="object"&&se!==null){switch(se.$$typeof){case w:return q=q.get(se.key===null?X:se.key)||null,P(H,q,se,je);case k:return q=q.get(se.key===null?X:se.key)||null,K(H,q,se,je);case F:return se=Wa(se),ee(q,H,X,se,je)}if(J(se)||V(se))return q=q.get(X)||null,ae(H,q,se,je,null);if(typeof se.then=="function")return ee(q,H,X,Zs(se),je);if(se.$$typeof===j)return ee(q,H,X,Ys(H,se),je);Ws(H,se)}return null}function we(q,H,X,se){for(var je=null,et=null,Ee=H,Pe=H=0,Ke=null;Ee!==null&&Pe<X.length;Pe++){Ee.index>Pe?(Ke=Ee,Ee=null):Ke=Ee.sibling;var tt=Z(q,Ee,X[Pe],se);if(tt===null){Ee===null&&(Ee=Ke);break}t&&Ee&&tt.alternate===null&&n(q,Ee),H=x(tt,H,Pe),et===null?je=tt:et.sibling=tt,et=tt,Ee=Ke}if(Pe===X.length)return i(q,Ee),Qe&&Ar(q,Pe),je;if(Ee===null){for(;Pe<X.length;Pe++)Ee=de(q,X[Pe],se),Ee!==null&&(H=x(Ee,H,Pe),et===null?je=Ee:et.sibling=Ee,et=Ee);return Qe&&Ar(q,Pe),je}for(Ee=u(Ee);Pe<X.length;Pe++)Ke=ee(Ee,q,Pe,X[Pe],se),Ke!==null&&(t&&Ke.alternate!==null&&Ee.delete(Ke.key===null?Pe:Ke.key),H=x(Ke,H,Pe),et===null?je=Ke:et.sibling=Ke,et=Ke);return t&&Ee.forEach(function(va){return n(q,va)}),Qe&&Ar(q,Pe),je}function Oe(q,H,X,se){if(X==null)throw Error(l(151));for(var je=null,et=null,Ee=H,Pe=H=0,Ke=null,tt=X.next();Ee!==null&&!tt.done;Pe++,tt=X.next()){Ee.index>Pe?(Ke=Ee,Ee=null):Ke=Ee.sibling;var va=Z(q,Ee,tt.value,se);if(va===null){Ee===null&&(Ee=Ke);break}t&&Ee&&va.alternate===null&&n(q,Ee),H=x(va,H,Pe),et===null?je=va:et.sibling=va,et=va,Ee=Ke}if(tt.done)return i(q,Ee),Qe&&Ar(q,Pe),je;if(Ee===null){for(;!tt.done;Pe++,tt=X.next())tt=de(q,tt.value,se),tt!==null&&(H=x(tt,H,Pe),et===null?je=tt:et.sibling=tt,et=tt);return Qe&&Ar(q,Pe),je}for(Ee=u(Ee);!tt.done;Pe++,tt=X.next())tt=ee(Ee,q,Pe,tt.value,se),tt!==null&&(t&&tt.alternate!==null&&Ee.delete(tt.key===null?Pe:tt.key),H=x(tt,H,Pe),et===null?je=tt:et.sibling=tt,et=tt);return t&&Ee.forEach(function(NA){return n(q,NA)}),Qe&&Ar(q,Pe),je}function ct(q,H,X,se){if(typeof X=="object"&&X!==null&&X.type===S&&X.key===null&&(X=X.props.children),typeof X=="object"&&X!==null){switch(X.$$typeof){case w:e:{for(var je=X.key;H!==null;){if(H.key===je){if(je=X.type,je===S){if(H.tag===7){i(q,H.sibling),se=m(H,X.props.children),se.return=q,q=se;break e}}else if(H.elementType===je||typeof je=="object"&&je!==null&&je.$$typeof===F&&Wa(je)===H.type){i(q,H.sibling),se=m(H,X.props),eo(se,X),se.return=q,q=se;break e}i(q,H);break}else n(q,H);H=H.sibling}X.type===S?(se=Ya(X.props.children,q.mode,se,X.key),se.return=q,q=se):(se=$s(X.type,X.key,X.props,null,q.mode,se),eo(se,X),se.return=q,q=se)}return E(q);case k:e:{for(je=X.key;H!==null;){if(H.key===je)if(H.tag===4&&H.stateNode.containerInfo===X.containerInfo&&H.stateNode.implementation===X.implementation){i(q,H.sibling),se=m(H,X.children||[]),se.return=q,q=se;break e}else{i(q,H);break}else n(q,H);H=H.sibling}se=Xd(X,q.mode,se),se.return=q,q=se}return E(q);case F:return X=Wa(X),ct(q,H,X,se)}if(J(X))return we(q,H,X,se);if(V(X)){if(je=V(X),typeof je!="function")throw Error(l(150));return X=je.call(X),Oe(q,H,X,se)}if(typeof X.then=="function")return ct(q,H,Zs(X),se);if(X.$$typeof===j)return ct(q,H,Ys(q,X),se);Ws(q,X)}return typeof X=="string"&&X!==""||typeof X=="number"||typeof X=="bigint"?(X=""+X,H!==null&&H.tag===6?(i(q,H.sibling),se=m(H,X),se.return=q,q=se):(i(q,H),se=Yd(X,q.mode,se),se.return=q,q=se),E(q)):i(q,H)}return function(q,H,X,se){try{Ji=0;var je=ct(q,H,X,se);return Ul=null,je}catch(Ee){if(Ee===Fl||Ee===Ks)throw Ee;var et=xn(29,Ee,null,q.mode);return et.lanes=se,et.return=q,et}finally{}}}var el=yy(!0),xy=yy(!1),ra=!1;function of(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function sf(t,n){t=t.updateQueue,n.updateQueue===t&&(n.updateQueue={baseState:t.baseState,firstBaseUpdate:t.firstBaseUpdate,lastBaseUpdate:t.lastBaseUpdate,shared:t.shared,callbacks:null})}function aa(t){return{lane:t,tag:0,payload:null,callback:null,next:null}}function la(t,n,i){var u=t.updateQueue;if(u===null)return null;if(u=u.shared,(at&2)!==0){var m=u.pending;return m===null?n.next=n:(n.next=m.next,m.next=n),u.pending=n,n=Vs(t),ty(t,null,i),n}return Hs(t,u,n,i),Vs(t)}function to(t,n,i){if(n=n.updateQueue,n!==null&&(n=n.shared,(i&4194048)!==0)){var u=n.lanes;u&=t.pendingLanes,i|=u,n.lanes=i,Ns(t,i)}}function uf(t,n){var i=t.updateQueue,u=t.alternate;if(u!==null&&(u=u.updateQueue,i===u)){var m=null,x=null;if(i=i.firstBaseUpdate,i!==null){do{var E={lane:i.lane,tag:i.tag,payload:i.payload,callback:null,next:null};x===null?m=x=E:x=x.next=E,i=i.next}while(i!==null);x===null?m=x=n:x=x.next=n}else m=x=n;i={baseState:u.baseState,firstBaseUpdate:m,lastBaseUpdate:x,shared:u.shared,callbacks:u.callbacks},t.updateQueue=i;return}t=i.lastBaseUpdate,t===null?i.firstBaseUpdate=n:t.next=n,i.lastBaseUpdate=n}var cf=!1;function no(){if(cf){var t=Pl;if(t!==null)throw t}}function ro(t,n,i,u){cf=!1;var m=t.updateQueue;ra=!1;var x=m.firstBaseUpdate,E=m.lastBaseUpdate,T=m.shared.pending;if(T!==null){m.shared.pending=null;var P=T,K=P.next;P.next=null,E===null?x=K:E.next=K,E=P;var ae=t.alternate;ae!==null&&(ae=ae.updateQueue,T=ae.lastBaseUpdate,T!==E&&(T===null?ae.firstBaseUpdate=K:T.next=K,ae.lastBaseUpdate=P))}if(x!==null){var de=m.baseState;E=0,ae=K=P=null,T=x;do{var Z=T.lane&-536870913,ee=Z!==T.lane;if(ee?(Xe&Z)===Z:(u&Z)===Z){Z!==0&&Z===Bl&&(cf=!0),ae!==null&&(ae=ae.next={lane:0,tag:T.tag,payload:T.payload,callback:null,next:null});e:{var we=t,Oe=T;Z=n;var ct=i;switch(Oe.tag){case 1:if(we=Oe.payload,typeof we=="function"){de=we.call(ct,de,Z);break e}de=we;break e;case 3:we.flags=we.flags&-65537|128;case 0:if(we=Oe.payload,Z=typeof we=="function"?we.call(ct,de,Z):we,Z==null)break e;de=g({},de,Z);break e;case 2:ra=!0}}Z=T.callback,Z!==null&&(t.flags|=64,ee&&(t.flags|=8192),ee=m.callbacks,ee===null?m.callbacks=[Z]:ee.push(Z))}else ee={lane:Z,tag:T.tag,payload:T.payload,callback:T.callback,next:null},ae===null?(K=ae=ee,P=de):ae=ae.next=ee,E|=Z;if(T=T.next,T===null){if(T=m.shared.pending,T===null)break;ee=T,T=ee.next,ee.next=null,m.lastBaseUpdate=ee,m.shared.pending=null}}while(!0);ae===null&&(P=de),m.baseState=P,m.firstBaseUpdate=K,m.lastBaseUpdate=ae,x===null&&(m.shared.lanes=0),ca|=E,t.lanes=E,t.memoizedState=de}}function by(t,n){if(typeof t!="function")throw Error(l(191,t));t.call(n)}function vy(t,n){var i=t.callbacks;if(i!==null)for(t.callbacks=null,t=0;t<i.length;t++)by(i[t],n)}var Hl=z(null),Js=z(0);function wy(t,n){t=Ir,_(Js,t),_(Hl,n),Ir=t|n.baseLanes}function df(){_(Js,Ir),_(Hl,Hl.current)}function ff(){Ir=Js.current,L(Hl),L(Js)}var bn=z(null),Hn=null;function ia(t){var n=t.alternate;_(St,St.current&1),_(bn,t),Hn===null&&(n===null||Hl.current!==null||n.memoizedState!==null)&&(Hn=t)}function pf(t){_(St,St.current),_(bn,t),Hn===null&&(Hn=t)}function Sy(t){t.tag===22?(_(St,St.current),_(bn,t),Hn===null&&(Hn=t)):oa()}function oa(){_(St,St.current),_(bn,bn.current)}function vn(t){L(bn),Hn===t&&(Hn=null),L(St)}var St=z(0);function eu(t){for(var n=t;n!==null;){if(n.tag===13){var i=n.memoizedState;if(i!==null&&(i=i.dehydrated,i===null||bp(i)||vp(i)))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===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return null;n=n.return}n.sibling.return=n.return,n=n.sibling}return null}var Tr=0,Be=null,st=null,At=null,tu=!1,Vl=!1,tl=!1,nu=0,ao=0,$l=null,y2=0;function bt(){throw Error(l(321))}function hf(t,n){if(n===null)return!1;for(var i=0;i<n.length&&i<t.length;i++)if(!yn(t[i],n[i]))return!1;return!0}function mf(t,n,i,u,m,x){return Tr=x,Be=n,n.memoizedState=null,n.updateQueue=null,n.lanes=0,B.H=t===null||t.memoizedState===null?lx:_f,tl=!1,x=i(u,m),tl=!1,Vl&&(x=Ey(n,i,u,m)),ky(t),x}function ky(t){B.H=oo;var n=st!==null&&st.next!==null;if(Tr=0,At=st=Be=null,tu=!1,ao=0,$l=null,n)throw Error(l(300));t===null||Nt||(t=t.dependencies,t!==null&&Gs(t)&&(Nt=!0))}function Ey(t,n,i,u){Be=t;var m=0;do{if(Vl&&($l=null),ao=0,Vl=!1,25<=m)throw Error(l(301));if(m+=1,At=st=null,t.updateQueue!=null){var x=t.updateQueue;x.lastEffect=null,x.events=null,x.stores=null,x.memoCache!=null&&(x.memoCache.index=0)}B.H=ix,x=n(i,u)}while(Vl);return x}function x2(){var t=B.H,n=t.useState()[0];return n=typeof n.then=="function"?lo(n):n,t=t.useState()[0],(st!==null?st.memoizedState:null)!==t&&(Be.flags|=1024),n}function gf(){var t=nu!==0;return nu=0,t}function yf(t,n,i){n.updateQueue=t.updateQueue,n.flags&=-2053,t.lanes&=~i}function xf(t){if(tu){for(t=t.memoizedState;t!==null;){var n=t.queue;n!==null&&(n.pending=null),t=t.next}tu=!1}Tr=0,At=st=Be=null,Vl=!1,ao=nu=0,$l=null}function tn(){var t={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return At===null?Be.memoizedState=At=t:At=At.next=t,At}function kt(){if(st===null){var t=Be.alternate;t=t!==null?t.memoizedState:null}else t=st.next;var n=At===null?Be.memoizedState:At.next;if(n!==null)At=n,st=t;else{if(t===null)throw Be.alternate===null?Error(l(467)):Error(l(310));st=t,t={memoizedState:st.memoizedState,baseState:st.baseState,baseQueue:st.baseQueue,queue:st.queue,next:null},At===null?Be.memoizedState=At=t:At=At.next=t}return At}function ru(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function lo(t){var n=ao;return ao+=1,$l===null&&($l=[]),t=hy($l,t,n),n=Be,(At===null?n.memoizedState:At.next)===null&&(n=n.alternate,B.H=n===null||n.memoizedState===null?lx:_f),t}function au(t){if(t!==null&&typeof t=="object"){if(typeof t.then=="function")return lo(t);if(t.$$typeof===j)return Ht(t)}throw Error(l(438,String(t)))}function bf(t){var n=null,i=Be.updateQueue;if(i!==null&&(n=i.memoCache),n==null){var u=Be.alternate;u!==null&&(u=u.updateQueue,u!==null&&(u=u.memoCache,u!=null&&(n={data:u.data.map(function(m){return m.slice()}),index:0})))}if(n==null&&(n={data:[],index:0}),i===null&&(i=ru(),Be.updateQueue=i),i.memoCache=n,i=n.data[n.index],i===void 0)for(i=n.data[n.index]=Array(t),u=0;u<t;u++)i[u]=I;return n.index++,i}function _r(t,n){return typeof n=="function"?n(t):n}function lu(t){var n=kt();return vf(n,st,t)}function vf(t,n,i){var u=t.queue;if(u===null)throw Error(l(311));u.lastRenderedReducer=i;var m=t.baseQueue,x=u.pending;if(x!==null){if(m!==null){var E=m.next;m.next=x.next,x.next=E}n.baseQueue=m=x,u.pending=null}if(x=t.baseState,m===null)t.memoizedState=x;else{n=m.next;var T=E=null,P=null,K=n,ae=!1;do{var de=K.lane&-536870913;if(de!==K.lane?(Xe&de)===de:(Tr&de)===de){var Z=K.revertLane;if(Z===0)P!==null&&(P=P.next={lane:0,revertLane:0,gesture:null,action:K.action,hasEagerState:K.hasEagerState,eagerState:K.eagerState,next:null}),de===Bl&&(ae=!0);else if((Tr&Z)===Z){K=K.next,Z===Bl&&(ae=!0);continue}else de={lane:0,revertLane:K.revertLane,gesture:null,action:K.action,hasEagerState:K.hasEagerState,eagerState:K.eagerState,next:null},P===null?(T=P=de,E=x):P=P.next=de,Be.lanes|=Z,ca|=Z;de=K.action,tl&&i(x,de),x=K.hasEagerState?K.eagerState:i(x,de)}else Z={lane:de,revertLane:K.revertLane,gesture:K.gesture,action:K.action,hasEagerState:K.hasEagerState,eagerState:K.eagerState,next:null},P===null?(T=P=Z,E=x):P=P.next=Z,Be.lanes|=de,ca|=de;K=K.next}while(K!==null&&K!==n);if(P===null?E=x:P.next=T,!yn(x,t.memoizedState)&&(Nt=!0,ae&&(i=Pl,i!==null)))throw i;t.memoizedState=x,t.baseState=E,t.baseQueue=P,u.lastRenderedState=x}return m===null&&(u.lanes=0),[t.memoizedState,u.dispatch]}function wf(t){var n=kt(),i=n.queue;if(i===null)throw Error(l(311));i.lastRenderedReducer=t;var u=i.dispatch,m=i.pending,x=n.memoizedState;if(m!==null){i.pending=null;var E=m=m.next;do x=t(x,E.action),E=E.next;while(E!==m);yn(x,n.memoizedState)||(Nt=!0),n.memoizedState=x,n.baseQueue===null&&(n.baseState=x),i.lastRenderedState=x}return[x,u]}function Cy(t,n,i){var u=Be,m=kt(),x=Qe;if(x){if(i===void 0)throw Error(l(407));i=i()}else i=n();var E=!yn((st||m).memoizedState,i);if(E&&(m.memoizedState=i,Nt=!0),m=m.queue,Ef(jy.bind(null,u,m,t),[t]),m.getSnapshot!==n||E||At!==null&&At.memoizedState.tag&1){if(u.flags|=2048,ql(9,{destroy:void 0},Ny.bind(null,u,m,i,n),null),dt===null)throw Error(l(349));x||(Tr&127)!==0||Ay(u,n,i)}return i}function Ay(t,n,i){t.flags|=16384,t={getSnapshot:n,value:i},n=Be.updateQueue,n===null?(n=ru(),Be.updateQueue=n,n.stores=[t]):(i=n.stores,i===null?n.stores=[t]:i.push(t))}function Ny(t,n,i,u){n.value=i,n.getSnapshot=u,Ty(n)&&_y(t)}function jy(t,n,i){return i(function(){Ty(n)&&_y(t)})}function Ty(t){var n=t.getSnapshot;t=t.value;try{var i=n();return!yn(t,i)}catch{return!0}}function _y(t){var n=Ga(t,2);n!==null&&fn(n,t,2)}function Sf(t){var n=tn();if(typeof t=="function"){var i=t;if(t=i(),tl){zt(!0);try{i()}finally{zt(!1)}}}return n.memoizedState=n.baseState=t,n.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:_r,lastRenderedState:t},n}function Ry(t,n,i,u){return t.baseState=i,vf(t,st,typeof u=="function"?u:_r)}function b2(t,n,i,u,m){if(su(t))throw Error(l(485));if(t=n.action,t!==null){var x={payload:m,action:t,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(E){x.listeners.push(E)}};B.T!==null?i(!0):x.isTransition=!1,u(x),i=n.pending,i===null?(x.next=n.pending=x,My(n,x)):(x.next=i.next,n.pending=i.next=x)}}function My(t,n){var i=n.action,u=n.payload,m=t.state;if(n.isTransition){var x=B.T,E={};B.T=E;try{var T=i(m,u),P=B.S;P!==null&&P(E,T),Oy(t,n,T)}catch(K){kf(t,n,K)}finally{x!==null&&E.types!==null&&(x.types=E.types),B.T=x}}else try{x=i(m,u),Oy(t,n,x)}catch(K){kf(t,n,K)}}function Oy(t,n,i){i!==null&&typeof i=="object"&&typeof i.then=="function"?i.then(function(u){Dy(t,n,u)},function(u){return kf(t,n,u)}):Dy(t,n,i)}function Dy(t,n,i){n.status="fulfilled",n.value=i,zy(n),t.state=i,n=t.pending,n!==null&&(i=n.next,i===n?t.pending=null:(i=i.next,n.next=i,My(t,i)))}function kf(t,n,i){var u=t.pending;if(t.pending=null,u!==null){u=u.next;do n.status="rejected",n.reason=i,zy(n),n=n.next;while(n!==u)}t.action=null}function zy(t){t=t.listeners;for(var n=0;n<t.length;n++)(0,t[n])()}function Ly(t,n){return n}function Iy(t,n){if(Qe){var i=dt.formState;if(i!==null){e:{var u=Be;if(Qe){if(ht){t:{for(var m=ht,x=Un;m.nodeType!==8;){if(!x){m=null;break t}if(m=Vn(m.nextSibling),m===null){m=null;break t}}x=m.data,m=x==="F!"||x==="F"?m:null}if(m){ht=Vn(m.nextSibling),u=m.data==="F!";break e}}ta(u)}u=!1}u&&(n=i[0])}}return i=tn(),i.memoizedState=i.baseState=n,u={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ly,lastRenderedState:n},i.queue=u,i=nx.bind(null,Be,u),u.dispatch=i,u=Sf(!1),x=Tf.bind(null,Be,!1,u.queue),u=tn(),m={state:n,dispatch:null,action:t,pending:null},u.queue=m,i=b2.bind(null,Be,m,x,i),m.dispatch=i,u.memoizedState=t,[n,i,!1]}function By(t){var n=kt();return Py(n,st,t)}function Py(t,n,i){if(n=vf(t,n,Ly)[0],t=lu(_r)[0],typeof n=="object"&&n!==null&&typeof n.then=="function")try{var u=lo(n)}catch(E){throw E===Fl?Ks:E}else u=n;n=kt();var m=n.queue,x=m.dispatch;return i!==n.memoizedState&&(Be.flags|=2048,ql(9,{destroy:void 0},v2.bind(null,m,i),null)),[u,x,t]}function v2(t,n){t.action=n}function Fy(t){var n=kt(),i=st;if(i!==null)return Py(n,i,t);kt(),n=n.memoizedState,i=kt();var u=i.queue.dispatch;return i.memoizedState=t,[n,u,!1]}function ql(t,n,i,u){return t={tag:t,create:i,deps:u,inst:n,next:null},n=Be.updateQueue,n===null&&(n=ru(),Be.updateQueue=n),i=n.lastEffect,i===null?n.lastEffect=t.next=t:(u=i.next,i.next=t,t.next=u,n.lastEffect=t),t}function Uy(){return kt().memoizedState}function iu(t,n,i,u){var m=tn();Be.flags|=t,m.memoizedState=ql(1|n,{destroy:void 0},i,u===void 0?null:u)}function ou(t,n,i,u){var m=kt();u=u===void 0?null:u;var x=m.memoizedState.inst;st!==null&&u!==null&&hf(u,st.memoizedState.deps)?m.memoizedState=ql(n,x,i,u):(Be.flags|=t,m.memoizedState=ql(1|n,x,i,u))}function Hy(t,n){iu(8390656,8,t,n)}function Ef(t,n){ou(2048,8,t,n)}function w2(t){Be.flags|=4;var n=Be.updateQueue;if(n===null)n=ru(),Be.updateQueue=n,n.events=[t];else{var i=n.events;i===null?n.events=[t]:i.push(t)}}function Vy(t){var n=kt().memoizedState;return w2({ref:n,nextImpl:t}),function(){if((at&2)!==0)throw Error(l(440));return n.impl.apply(void 0,arguments)}}function $y(t,n){return ou(4,2,t,n)}function qy(t,n){return ou(4,4,t,n)}function Gy(t,n){if(typeof n=="function"){t=t();var i=n(t);return function(){typeof i=="function"?i():n(null)}}if(n!=null)return t=t(),n.current=t,function(){n.current=null}}function Yy(t,n,i){i=i!=null?i.concat([t]):null,ou(4,4,Gy.bind(null,n,t),i)}function Cf(){}function Xy(t,n){var i=kt();n=n===void 0?null:n;var u=i.memoizedState;return n!==null&&hf(n,u[1])?u[0]:(i.memoizedState=[t,n],t)}function Ky(t,n){var i=kt();n=n===void 0?null:n;var u=i.memoizedState;if(n!==null&&hf(n,u[1]))return u[0];if(u=t(),tl){zt(!0);try{t()}finally{zt(!1)}}return i.memoizedState=[u,n],u}function Af(t,n,i){return i===void 0||(Tr&1073741824)!==0&&(Xe&261930)===0?t.memoizedState=n:(t.memoizedState=i,t=Qx(),Be.lanes|=t,ca|=t,i)}function Qy(t,n,i,u){return yn(i,n)?i:Hl.current!==null?(t=Af(t,i,u),yn(t,n)||(Nt=!0),t):(Tr&42)===0||(Tr&1073741824)!==0&&(Xe&261930)===0?(Nt=!0,t.memoizedState=i):(t=Qx(),Be.lanes|=t,ca|=t,n)}function Zy(t,n,i,u,m){var x=G.p;G.p=x!==0&&8>x?x:8;var E=B.T,T={};B.T=T,Tf(t,!1,n,i);try{var P=m(),K=B.S;if(K!==null&&K(T,P),P!==null&&typeof P=="object"&&typeof P.then=="function"){var ae=g2(P,u);io(t,n,ae,kn(t))}else io(t,n,u,kn(t))}catch(de){io(t,n,{then:function(){},status:"rejected",reason:de},kn())}finally{G.p=x,E!==null&&T.types!==null&&(E.types=T.types),B.T=E}}function S2(){}function Nf(t,n,i,u){if(t.tag!==5)throw Error(l(476));var m=Wy(t).queue;Zy(t,m,n,te,i===null?S2:function(){return Jy(t),i(u)})}function Wy(t){var n=t.memoizedState;if(n!==null)return n;n={memoizedState:te,baseState:te,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:_r,lastRenderedState:te},next:null};var i={};return n.next={memoizedState:i,baseState:i,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:_r,lastRenderedState:i},next:null},t.memoizedState=n,t=t.alternate,t!==null&&(t.memoizedState=n),n}function Jy(t){var n=Wy(t);n.next===null&&(n=t.alternate.memoizedState),io(t,n.next.queue,{},kn())}function jf(){return Ht(Eo)}function ex(){return kt().memoizedState}function tx(){return kt().memoizedState}function k2(t){for(var n=t.return;n!==null;){switch(n.tag){case 24:case 3:var i=kn();t=aa(i);var u=la(n,t,i);u!==null&&(fn(u,n,i),to(u,n,i)),n={cache:nf()},t.payload=n;return}n=n.return}}function E2(t,n,i){var u=kn();i={lane:u,revertLane:0,gesture:null,action:i,hasEagerState:!1,eagerState:null,next:null},su(t)?rx(n,i):(i=qd(t,n,i,u),i!==null&&(fn(i,t,u),ax(i,n,u)))}function nx(t,n,i){var u=kn();io(t,n,i,u)}function io(t,n,i,u){var m={lane:u,revertLane:0,gesture:null,action:i,hasEagerState:!1,eagerState:null,next:null};if(su(t))rx(n,m);else{var x=t.alternate;if(t.lanes===0&&(x===null||x.lanes===0)&&(x=n.lastRenderedReducer,x!==null))try{var E=n.lastRenderedState,T=x(E,i);if(m.hasEagerState=!0,m.eagerState=T,yn(T,E))return Hs(t,n,m,0),dt===null&&Us(),!1}catch{}finally{}if(i=qd(t,n,m,u),i!==null)return fn(i,t,u),ax(i,n,u),!0}return!1}function Tf(t,n,i,u){if(u={lane:2,revertLane:op(),gesture:null,action:u,hasEagerState:!1,eagerState:null,next:null},su(t)){if(n)throw Error(l(479))}else n=qd(t,i,u,2),n!==null&&fn(n,t,2)}function su(t){var n=t.alternate;return t===Be||n!==null&&n===Be}function rx(t,n){Vl=tu=!0;var i=t.pending;i===null?n.next=n:(n.next=i.next,i.next=n),t.pending=n}function ax(t,n,i){if((i&4194048)!==0){var u=n.lanes;u&=t.pendingLanes,i|=u,n.lanes=i,Ns(t,i)}}var oo={readContext:Ht,use:au,useCallback:bt,useContext:bt,useEffect:bt,useImperativeHandle:bt,useLayoutEffect:bt,useInsertionEffect:bt,useMemo:bt,useReducer:bt,useRef:bt,useState:bt,useDebugValue:bt,useDeferredValue:bt,useTransition:bt,useSyncExternalStore:bt,useId:bt,useHostTransitionStatus:bt,useFormState:bt,useActionState:bt,useOptimistic:bt,useMemoCache:bt,useCacheRefresh:bt};oo.useEffectEvent=bt;var lx={readContext:Ht,use:au,useCallback:function(t,n){return tn().memoizedState=[t,n===void 0?null:n],t},useContext:Ht,useEffect:Hy,useImperativeHandle:function(t,n,i){i=i!=null?i.concat([t]):null,iu(4194308,4,Gy.bind(null,n,t),i)},useLayoutEffect:function(t,n){return iu(4194308,4,t,n)},useInsertionEffect:function(t,n){iu(4,2,t,n)},useMemo:function(t,n){var i=tn();n=n===void 0?null:n;var u=t();if(tl){zt(!0);try{t()}finally{zt(!1)}}return i.memoizedState=[u,n],u},useReducer:function(t,n,i){var u=tn();if(i!==void 0){var m=i(n);if(tl){zt(!0);try{i(n)}finally{zt(!1)}}}else m=n;return u.memoizedState=u.baseState=m,t={pending:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:m},u.queue=t,t=t.dispatch=E2.bind(null,Be,t),[u.memoizedState,t]},useRef:function(t){var n=tn();return t={current:t},n.memoizedState=t},useState:function(t){t=Sf(t);var n=t.queue,i=nx.bind(null,Be,n);return n.dispatch=i,[t.memoizedState,i]},useDebugValue:Cf,useDeferredValue:function(t,n){var i=tn();return Af(i,t,n)},useTransition:function(){var t=Sf(!1);return t=Zy.bind(null,Be,t.queue,!0,!1),tn().memoizedState=t,[!1,t]},useSyncExternalStore:function(t,n,i){var u=Be,m=tn();if(Qe){if(i===void 0)throw Error(l(407));i=i()}else{if(i=n(),dt===null)throw Error(l(349));(Xe&127)!==0||Ay(u,n,i)}m.memoizedState=i;var x={value:i,getSnapshot:n};return m.queue=x,Hy(jy.bind(null,u,x,t),[t]),u.flags|=2048,ql(9,{destroy:void 0},Ny.bind(null,u,x,i,n),null),i},useId:function(){var t=tn(),n=dt.identifierPrefix;if(Qe){var i=or,u=ir;i=(u&~(1<<32-lt(u)-1)).toString(32)+i,n="_"+n+"R_"+i,i=nu++,0<i&&(n+="H"+i.toString(32)),n+="_"}else i=y2++,n="_"+n+"r_"+i.toString(32)+"_";return t.memoizedState=n},useHostTransitionStatus:jf,useFormState:Iy,useActionState:Iy,useOptimistic:function(t){var n=tn();n.memoizedState=n.baseState=t;var i={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return n.queue=i,n=Tf.bind(null,Be,!0,i),i.dispatch=n,[t,n]},useMemoCache:bf,useCacheRefresh:function(){return tn().memoizedState=k2.bind(null,Be)},useEffectEvent:function(t){var n=tn(),i={impl:t};return n.memoizedState=i,function(){if((at&2)!==0)throw Error(l(440));return i.impl.apply(void 0,arguments)}}},_f={readContext:Ht,use:au,useCallback:Xy,useContext:Ht,useEffect:Ef,useImperativeHandle:Yy,useInsertionEffect:$y,useLayoutEffect:qy,useMemo:Ky,useReducer:lu,useRef:Uy,useState:function(){return lu(_r)},useDebugValue:Cf,useDeferredValue:function(t,n){var i=kt();return Qy(i,st.memoizedState,t,n)},useTransition:function(){var t=lu(_r)[0],n=kt().memoizedState;return[typeof t=="boolean"?t:lo(t),n]},useSyncExternalStore:Cy,useId:ex,useHostTransitionStatus:jf,useFormState:By,useActionState:By,useOptimistic:function(t,n){var i=kt();return Ry(i,st,t,n)},useMemoCache:bf,useCacheRefresh:tx};_f.useEffectEvent=Vy;var ix={readContext:Ht,use:au,useCallback:Xy,useContext:Ht,useEffect:Ef,useImperativeHandle:Yy,useInsertionEffect:$y,useLayoutEffect:qy,useMemo:Ky,useReducer:wf,useRef:Uy,useState:function(){return wf(_r)},useDebugValue:Cf,useDeferredValue:function(t,n){var i=kt();return st===null?Af(i,t,n):Qy(i,st.memoizedState,t,n)},useTransition:function(){var t=wf(_r)[0],n=kt().memoizedState;return[typeof t=="boolean"?t:lo(t),n]},useSyncExternalStore:Cy,useId:ex,useHostTransitionStatus:jf,useFormState:Fy,useActionState:Fy,useOptimistic:function(t,n){var i=kt();return st!==null?Ry(i,st,t,n):(i.baseState=t,[t,i.queue.dispatch])},useMemoCache:bf,useCacheRefresh:tx};ix.useEffectEvent=Vy;function Rf(t,n,i,u){n=t.memoizedState,i=i(u,n),i=i==null?n:g({},n,i),t.memoizedState=i,t.lanes===0&&(t.updateQueue.baseState=i)}var Mf={enqueueSetState:function(t,n,i){t=t._reactInternals;var u=kn(),m=aa(u);m.payload=n,i!=null&&(m.callback=i),n=la(t,m,u),n!==null&&(fn(n,t,u),to(n,t,u))},enqueueReplaceState:function(t,n,i){t=t._reactInternals;var u=kn(),m=aa(u);m.tag=1,m.payload=n,i!=null&&(m.callback=i),n=la(t,m,u),n!==null&&(fn(n,t,u),to(n,t,u))},enqueueForceUpdate:function(t,n){t=t._reactInternals;var i=kn(),u=aa(i);u.tag=2,n!=null&&(u.callback=n),n=la(t,u,i),n!==null&&(fn(n,t,i),to(n,t,i))}};function ox(t,n,i,u,m,x,E){return t=t.stateNode,typeof t.shouldComponentUpdate=="function"?t.shouldComponentUpdate(u,x,E):n.prototype&&n.prototype.isPureReactComponent?!Yi(i,u)||!Yi(m,x):!0}function sx(t,n,i,u){t=n.state,typeof n.componentWillReceiveProps=="function"&&n.componentWillReceiveProps(i,u),typeof n.UNSAFE_componentWillReceiveProps=="function"&&n.UNSAFE_componentWillReceiveProps(i,u),n.state!==t&&Mf.enqueueReplaceState(n,n.state,null)}function nl(t,n){var i=n;if("ref"in n){i={};for(var u in n)u!=="ref"&&(i[u]=n[u])}if(t=t.defaultProps){i===n&&(i=g({},i));for(var m in t)i[m]===void 0&&(i[m]=t[m])}return i}function ux(t){Fs(t)}function cx(t){console.error(t)}function dx(t){Fs(t)}function uu(t,n){try{var i=t.onUncaughtError;i(n.value,{componentStack:n.stack})}catch(u){setTimeout(function(){throw u})}}function fx(t,n,i){try{var u=t.onCaughtError;u(i.value,{componentStack:i.stack,errorBoundary:n.tag===1?n.stateNode:null})}catch(m){setTimeout(function(){throw m})}}function Of(t,n,i){return i=aa(i),i.tag=3,i.payload={element:null},i.callback=function(){uu(t,n)},i}function px(t){return t=aa(t),t.tag=3,t}function hx(t,n,i,u){var m=i.type.getDerivedStateFromError;if(typeof m=="function"){var x=u.value;t.payload=function(){return m(x)},t.callback=function(){fx(n,i,u)}}var E=i.stateNode;E!==null&&typeof E.componentDidCatch=="function"&&(t.callback=function(){fx(n,i,u),typeof m!="function"&&(da===null?da=new Set([this]):da.add(this));var T=u.stack;this.componentDidCatch(u.value,{componentStack:T!==null?T:""})})}function C2(t,n,i,u,m){if(i.flags|=32768,u!==null&&typeof u=="object"&&typeof u.then=="function"){if(n=i.alternate,n!==null&&Il(n,i,m,!0),i=bn.current,i!==null){switch(i.tag){case 31:case 13:return Hn===null?wu():i.alternate===null&&vt===0&&(vt=3),i.flags&=-257,i.flags|=65536,i.lanes=m,u===Qs?i.flags|=16384:(n=i.updateQueue,n===null?i.updateQueue=new Set([u]):n.add(u),ap(t,u,m)),!1;case 22:return i.flags|=65536,u===Qs?i.flags|=16384:(n=i.updateQueue,n===null?(n={transitions:null,markerInstances:null,retryQueue:new Set([u])},i.updateQueue=n):(i=n.retryQueue,i===null?n.retryQueue=new Set([u]):i.add(u)),ap(t,u,m)),!1}throw Error(l(435,i.tag))}return ap(t,u,m),wu(),!1}if(Qe)return n=bn.current,n!==null?((n.flags&65536)===0&&(n.flags|=256),n.flags|=65536,n.lanes=m,u!==Zd&&(t=Error(l(422),{cause:u}),Qi(Bn(t,i)))):(u!==Zd&&(n=Error(l(423),{cause:u}),Qi(Bn(n,i))),t=t.current.alternate,t.flags|=65536,m&=-m,t.lanes|=m,u=Bn(u,i),m=Of(t.stateNode,u,m),uf(t,m),vt!==4&&(vt=2)),!1;var x=Error(l(520),{cause:u});if(x=Bn(x,i),go===null?go=[x]:go.push(x),vt!==4&&(vt=2),n===null)return!0;u=Bn(u,i),i=n;do{switch(i.tag){case 3:return i.flags|=65536,t=m&-m,i.lanes|=t,t=Of(i.stateNode,u,t),uf(i,t),!1;case 1:if(n=i.type,x=i.stateNode,(i.flags&128)===0&&(typeof n.getDerivedStateFromError=="function"||x!==null&&typeof x.componentDidCatch=="function"&&(da===null||!da.has(x))))return i.flags|=65536,m&=-m,i.lanes|=m,m=px(m),hx(m,t,i,u),uf(i,m),!1}i=i.return}while(i!==null);return!1}var Df=Error(l(461)),Nt=!1;function Vt(t,n,i,u){n.child=t===null?xy(n,null,i,u):el(n,t.child,i,u)}function mx(t,n,i,u,m){i=i.render;var x=n.ref;if("ref"in u){var E={};for(var T in u)T!=="ref"&&(E[T]=u[T])}else E=u;return Qa(n),u=mf(t,n,i,E,x,m),T=gf(),t!==null&&!Nt?(yf(t,n,m),Rr(t,n,m)):(Qe&&T&&Kd(n),n.flags|=1,Vt(t,n,u,m),n.child)}function gx(t,n,i,u,m){if(t===null){var x=i.type;return typeof x=="function"&&!Gd(x)&&x.defaultProps===void 0&&i.compare===null?(n.tag=15,n.type=x,yx(t,n,x,u,m)):(t=$s(i.type,null,u,n,n.mode,m),t.ref=n.ref,t.return=n,n.child=t)}if(x=t.child,!Hf(t,m)){var E=x.memoizedProps;if(i=i.compare,i=i!==null?i:Yi,i(E,u)&&t.ref===n.ref)return Rr(t,n,m)}return n.flags|=1,t=Cr(x,u),t.ref=n.ref,t.return=n,n.child=t}function yx(t,n,i,u,m){if(t!==null){var x=t.memoizedProps;if(Yi(x,u)&&t.ref===n.ref)if(Nt=!1,n.pendingProps=u=x,Hf(t,m))(t.flags&131072)!==0&&(Nt=!0);else return n.lanes=t.lanes,Rr(t,n,m)}return zf(t,n,i,u,m)}function xx(t,n,i,u){var m=u.children,x=t!==null?t.memoizedState:null;if(t===null&&n.stateNode===null&&(n.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),u.mode==="hidden"){if((n.flags&128)!==0){if(x=x!==null?x.baseLanes|i:i,t!==null){for(u=n.child=t.child,m=0;u!==null;)m=m|u.lanes|u.childLanes,u=u.sibling;u=m&~x}else u=0,n.child=null;return bx(t,n,x,i,u)}if((i&536870912)!==0)n.memoizedState={baseLanes:0,cachePool:null},t!==null&&Xs(n,x!==null?x.cachePool:null),x!==null?wy(n,x):df(),Sy(n);else return u=n.lanes=536870912,bx(t,n,x!==null?x.baseLanes|i:i,i,u)}else x!==null?(Xs(n,x.cachePool),wy(n,x),oa(),n.memoizedState=null):(t!==null&&Xs(n,null),df(),oa());return Vt(t,n,m,i),n.child}function so(t,n){return t!==null&&t.tag===22||n.stateNode!==null||(n.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),n.sibling}function bx(t,n,i,u,m){var x=af();return x=x===null?null:{parent:Ct._currentValue,pool:x},n.memoizedState={baseLanes:i,cachePool:x},t!==null&&Xs(n,null),df(),Sy(n),t!==null&&Il(t,n,u,!0),n.childLanes=m,null}function cu(t,n){return n=fu({mode:n.mode,children:n.children},t.mode),n.ref=t.ref,t.child=n,n.return=t,n}function vx(t,n,i){return el(n,t.child,null,i),t=cu(n,n.pendingProps),t.flags|=2,vn(n),n.memoizedState=null,t}function A2(t,n,i){var u=n.pendingProps,m=(n.flags&128)!==0;if(n.flags&=-129,t===null){if(Qe){if(u.mode==="hidden")return t=cu(n,u),n.lanes=536870912,so(null,t);if(pf(n),(t=ht)?(t=Mb(t,Un),t=t!==null&&t.data==="&"?t:null,t!==null&&(n.memoizedState={dehydrated:t,treeContext:Jr!==null?{id:ir,overflow:or}:null,retryLane:536870912,hydrationErrors:null},i=ry(t),i.return=n,n.child=i,Ut=n,ht=null)):t=null,t===null)throw ta(n);return n.lanes=536870912,null}return cu(n,u)}var x=t.memoizedState;if(x!==null){var E=x.dehydrated;if(pf(n),m)if(n.flags&256)n.flags&=-257,n=vx(t,n,i);else if(n.memoizedState!==null)n.child=t.child,n.flags|=128,n=null;else throw Error(l(558));else if(Nt||Il(t,n,i,!1),m=(i&t.childLanes)!==0,Nt||m){if(u=dt,u!==null&&(E=js(u,i),E!==0&&E!==x.retryLane))throw x.retryLane=E,Ga(t,E),fn(u,t,E),Df;wu(),n=vx(t,n,i)}else t=x.treeContext,ht=Vn(E.nextSibling),Ut=n,Qe=!0,ea=null,Un=!1,t!==null&&iy(n,t),n=cu(n,u),n.flags|=4096;return n}return t=Cr(t.child,{mode:u.mode,children:u.children}),t.ref=n.ref,n.child=t,t.return=n,t}function du(t,n){var i=n.ref;if(i===null)t!==null&&t.ref!==null&&(n.flags|=4194816);else{if(typeof i!="function"&&typeof i!="object")throw Error(l(284));(t===null||t.ref!==i)&&(n.flags|=4194816)}}function zf(t,n,i,u,m){return Qa(n),i=mf(t,n,i,u,void 0,m),u=gf(),t!==null&&!Nt?(yf(t,n,m),Rr(t,n,m)):(Qe&&u&&Kd(n),n.flags|=1,Vt(t,n,i,m),n.child)}function wx(t,n,i,u,m,x){return Qa(n),n.updateQueue=null,i=Ey(n,u,i,m),ky(t),u=gf(),t!==null&&!Nt?(yf(t,n,x),Rr(t,n,x)):(Qe&&u&&Kd(n),n.flags|=1,Vt(t,n,i,x),n.child)}function Sx(t,n,i,u,m){if(Qa(n),n.stateNode===null){var x=Ol,E=i.contextType;typeof E=="object"&&E!==null&&(x=Ht(E)),x=new i(u,x),n.memoizedState=x.state!==null&&x.state!==void 0?x.state:null,x.updater=Mf,n.stateNode=x,x._reactInternals=n,x=n.stateNode,x.props=u,x.state=n.memoizedState,x.refs={},of(n),E=i.contextType,x.context=typeof E=="object"&&E!==null?Ht(E):Ol,x.state=n.memoizedState,E=i.getDerivedStateFromProps,typeof E=="function"&&(Rf(n,i,E,u),x.state=n.memoizedState),typeof i.getDerivedStateFromProps=="function"||typeof x.getSnapshotBeforeUpdate=="function"||typeof x.UNSAFE_componentWillMount!="function"&&typeof x.componentWillMount!="function"||(E=x.state,typeof x.componentWillMount=="function"&&x.componentWillMount(),typeof x.UNSAFE_componentWillMount=="function"&&x.UNSAFE_componentWillMount(),E!==x.state&&Mf.enqueueReplaceState(x,x.state,null),ro(n,u,x,m),no(),x.state=n.memoizedState),typeof x.componentDidMount=="function"&&(n.flags|=4194308),u=!0}else if(t===null){x=n.stateNode;var T=n.memoizedProps,P=nl(i,T);x.props=P;var K=x.context,ae=i.contextType;E=Ol,typeof ae=="object"&&ae!==null&&(E=Ht(ae));var de=i.getDerivedStateFromProps;ae=typeof de=="function"||typeof x.getSnapshotBeforeUpdate=="function",T=n.pendingProps!==T,ae||typeof x.UNSAFE_componentWillReceiveProps!="function"&&typeof x.componentWillReceiveProps!="function"||(T||K!==E)&&sx(n,x,u,E),ra=!1;var Z=n.memoizedState;x.state=Z,ro(n,u,x,m),no(),K=n.memoizedState,T||Z!==K||ra?(typeof de=="function"&&(Rf(n,i,de,u),K=n.memoizedState),(P=ra||ox(n,i,P,u,Z,K,E))?(ae||typeof x.UNSAFE_componentWillMount!="function"&&typeof x.componentWillMount!="function"||(typeof x.componentWillMount=="function"&&x.componentWillMount(),typeof x.UNSAFE_componentWillMount=="function"&&x.UNSAFE_componentWillMount()),typeof x.componentDidMount=="function"&&(n.flags|=4194308)):(typeof x.componentDidMount=="function"&&(n.flags|=4194308),n.memoizedProps=u,n.memoizedState=K),x.props=u,x.state=K,x.context=E,u=P):(typeof x.componentDidMount=="function"&&(n.flags|=4194308),u=!1)}else{x=n.stateNode,sf(t,n),E=n.memoizedProps,ae=nl(i,E),x.props=ae,de=n.pendingProps,Z=x.context,K=i.contextType,P=Ol,typeof K=="object"&&K!==null&&(P=Ht(K)),T=i.getDerivedStateFromProps,(K=typeof T=="function"||typeof x.getSnapshotBeforeUpdate=="function")||typeof x.UNSAFE_componentWillReceiveProps!="function"&&typeof x.componentWillReceiveProps!="function"||(E!==de||Z!==P)&&sx(n,x,u,P),ra=!1,Z=n.memoizedState,x.state=Z,ro(n,u,x,m),no();var ee=n.memoizedState;E!==de||Z!==ee||ra||t!==null&&t.dependencies!==null&&Gs(t.dependencies)?(typeof T=="function"&&(Rf(n,i,T,u),ee=n.memoizedState),(ae=ra||ox(n,i,ae,u,Z,ee,P)||t!==null&&t.dependencies!==null&&Gs(t.dependencies))?(K||typeof x.UNSAFE_componentWillUpdate!="function"&&typeof x.componentWillUpdate!="function"||(typeof x.componentWillUpdate=="function"&&x.componentWillUpdate(u,ee,P),typeof x.UNSAFE_componentWillUpdate=="function"&&x.UNSAFE_componentWillUpdate(u,ee,P)),typeof x.componentDidUpdate=="function"&&(n.flags|=4),typeof x.getSnapshotBeforeUpdate=="function"&&(n.flags|=1024)):(typeof x.componentDidUpdate!="function"||E===t.memoizedProps&&Z===t.memoizedState||(n.flags|=4),typeof x.getSnapshotBeforeUpdate!="function"||E===t.memoizedProps&&Z===t.memoizedState||(n.flags|=1024),n.memoizedProps=u,n.memoizedState=ee),x.props=u,x.state=ee,x.context=P,u=ae):(typeof x.componentDidUpdate!="function"||E===t.memoizedProps&&Z===t.memoizedState||(n.flags|=4),typeof x.getSnapshotBeforeUpdate!="function"||E===t.memoizedProps&&Z===t.memoizedState||(n.flags|=1024),u=!1)}return x=u,du(t,n),u=(n.flags&128)!==0,x||u?(x=n.stateNode,i=u&&typeof i.getDerivedStateFromError!="function"?null:x.render(),n.flags|=1,t!==null&&u?(n.child=el(n,t.child,null,m),n.child=el(n,null,i,m)):Vt(t,n,i,m),n.memoizedState=x.state,t=n.child):t=Rr(t,n,m),t}function kx(t,n,i,u){return Xa(),n.flags|=256,Vt(t,n,i,u),n.child}var Lf={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function If(t){return{baseLanes:t,cachePool:fy()}}function Bf(t,n,i){return t=t!==null?t.childLanes&~i:0,n&&(t|=Sn),t}function Ex(t,n,i){var u=n.pendingProps,m=!1,x=(n.flags&128)!==0,E;if((E=x)||(E=t!==null&&t.memoizedState===null?!1:(St.current&2)!==0),E&&(m=!0,n.flags&=-129),E=(n.flags&32)!==0,n.flags&=-33,t===null){if(Qe){if(m?ia(n):oa(),(t=ht)?(t=Mb(t,Un),t=t!==null&&t.data!=="&"?t:null,t!==null&&(n.memoizedState={dehydrated:t,treeContext:Jr!==null?{id:ir,overflow:or}:null,retryLane:536870912,hydrationErrors:null},i=ry(t),i.return=n,n.child=i,Ut=n,ht=null)):t=null,t===null)throw ta(n);return vp(t)?n.lanes=32:n.lanes=536870912,null}var T=u.children;return u=u.fallback,m?(oa(),m=n.mode,T=fu({mode:"hidden",children:T},m),u=Ya(u,m,i,null),T.return=n,u.return=n,T.sibling=u,n.child=T,u=n.child,u.memoizedState=If(i),u.childLanes=Bf(t,E,i),n.memoizedState=Lf,so(null,u)):(ia(n),Pf(n,T))}var P=t.memoizedState;if(P!==null&&(T=P.dehydrated,T!==null)){if(x)n.flags&256?(ia(n),n.flags&=-257,n=Ff(t,n,i)):n.memoizedState!==null?(oa(),n.child=t.child,n.flags|=128,n=null):(oa(),T=u.fallback,m=n.mode,u=fu({mode:"visible",children:u.children},m),T=Ya(T,m,i,null),T.flags|=2,u.return=n,T.return=n,u.sibling=T,n.child=u,el(n,t.child,null,i),u=n.child,u.memoizedState=If(i),u.childLanes=Bf(t,E,i),n.memoizedState=Lf,n=so(null,u));else if(ia(n),vp(T)){if(E=T.nextSibling&&T.nextSibling.dataset,E)var K=E.dgst;E=K,u=Error(l(419)),u.stack="",u.digest=E,Qi({value:u,source:null,stack:null}),n=Ff(t,n,i)}else if(Nt||Il(t,n,i,!1),E=(i&t.childLanes)!==0,Nt||E){if(E=dt,E!==null&&(u=js(E,i),u!==0&&u!==P.retryLane))throw P.retryLane=u,Ga(t,u),fn(E,t,u),Df;bp(T)||wu(),n=Ff(t,n,i)}else bp(T)?(n.flags|=192,n.child=t.child,n=null):(t=P.treeContext,ht=Vn(T.nextSibling),Ut=n,Qe=!0,ea=null,Un=!1,t!==null&&iy(n,t),n=Pf(n,u.children),n.flags|=4096);return n}return m?(oa(),T=u.fallback,m=n.mode,P=t.child,K=P.sibling,u=Cr(P,{mode:"hidden",children:u.children}),u.subtreeFlags=P.subtreeFlags&65011712,K!==null?T=Cr(K,T):(T=Ya(T,m,i,null),T.flags|=2),T.return=n,u.return=n,u.sibling=T,n.child=u,so(null,u),u=n.child,T=t.child.memoizedState,T===null?T=If(i):(m=T.cachePool,m!==null?(P=Ct._currentValue,m=m.parent!==P?{parent:P,pool:P}:m):m=fy(),T={baseLanes:T.baseLanes|i,cachePool:m}),u.memoizedState=T,u.childLanes=Bf(t,E,i),n.memoizedState=Lf,so(t.child,u)):(ia(n),i=t.child,t=i.sibling,i=Cr(i,{mode:"visible",children:u.children}),i.return=n,i.sibling=null,t!==null&&(E=n.deletions,E===null?(n.deletions=[t],n.flags|=16):E.push(t)),n.child=i,n.memoizedState=null,i)}function Pf(t,n){return n=fu({mode:"visible",children:n},t.mode),n.return=t,t.child=n}function fu(t,n){return t=xn(22,t,null,n),t.lanes=0,t}function Ff(t,n,i){return el(n,t.child,null,i),t=Pf(n,n.pendingProps.children),t.flags|=2,n.memoizedState=null,t}function Cx(t,n,i){t.lanes|=n;var u=t.alternate;u!==null&&(u.lanes|=n),ef(t.return,n,i)}function Uf(t,n,i,u,m,x){var E=t.memoizedState;E===null?t.memoizedState={isBackwards:n,rendering:null,renderingStartTime:0,last:u,tail:i,tailMode:m,treeForkCount:x}:(E.isBackwards=n,E.rendering=null,E.renderingStartTime=0,E.last=u,E.tail=i,E.tailMode=m,E.treeForkCount=x)}function Ax(t,n,i){var u=n.pendingProps,m=u.revealOrder,x=u.tail;u=u.children;var E=St.current,T=(E&2)!==0;if(T?(E=E&1|2,n.flags|=128):E&=1,_(St,E),Vt(t,n,u,i),u=Qe?Ki:0,!T&&t!==null&&(t.flags&128)!==0)e:for(t=n.child;t!==null;){if(t.tag===13)t.memoizedState!==null&&Cx(t,i,n);else if(t.tag===19)Cx(t,i,n);else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===n)break e;for(;t.sibling===null;){if(t.return===null||t.return===n)break e;t=t.return}t.sibling.return=t.return,t=t.sibling}switch(m){case"forwards":for(i=n.child,m=null;i!==null;)t=i.alternate,t!==null&&eu(t)===null&&(m=i),i=i.sibling;i=m,i===null?(m=n.child,n.child=null):(m=i.sibling,i.sibling=null),Uf(n,!1,m,i,x,u);break;case"backwards":case"unstable_legacy-backwards":for(i=null,m=n.child,n.child=null;m!==null;){if(t=m.alternate,t!==null&&eu(t)===null){n.child=m;break}t=m.sibling,m.sibling=i,i=m,m=t}Uf(n,!0,i,null,x,u);break;case"together":Uf(n,!1,null,null,void 0,u);break;default:n.memoizedState=null}return n.child}function Rr(t,n,i){if(t!==null&&(n.dependencies=t.dependencies),ca|=n.lanes,(i&n.childLanes)===0)if(t!==null){if(Il(t,n,i,!1),(i&n.childLanes)===0)return null}else return null;if(t!==null&&n.child!==t.child)throw Error(l(153));if(n.child!==null){for(t=n.child,i=Cr(t,t.pendingProps),n.child=i,i.return=n;t.sibling!==null;)t=t.sibling,i=i.sibling=Cr(t,t.pendingProps),i.return=n;i.sibling=null}return n.child}function Hf(t,n){return(t.lanes&n)!==0?!0:(t=t.dependencies,!!(t!==null&&Gs(t)))}function N2(t,n,i){switch(n.tag){case 3:be(n,n.stateNode.containerInfo),na(n,Ct,t.memoizedState.cache),Xa();break;case 27:case 5:Ne(n);break;case 4:be(n,n.stateNode.containerInfo);break;case 10:na(n,n.type,n.memoizedProps.value);break;case 31:if(n.memoizedState!==null)return n.flags|=128,pf(n),null;break;case 13:var u=n.memoizedState;if(u!==null)return u.dehydrated!==null?(ia(n),n.flags|=128,null):(i&n.child.childLanes)!==0?Ex(t,n,i):(ia(n),t=Rr(t,n,i),t!==null?t.sibling:null);ia(n);break;case 19:var m=(t.flags&128)!==0;if(u=(i&n.childLanes)!==0,u||(Il(t,n,i,!1),u=(i&n.childLanes)!==0),m){if(u)return Ax(t,n,i);n.flags|=128}if(m=n.memoizedState,m!==null&&(m.rendering=null,m.tail=null,m.lastEffect=null),_(St,St.current),u)break;return null;case 22:return n.lanes=0,xx(t,n,i,n.pendingProps);case 24:na(n,Ct,t.memoizedState.cache)}return Rr(t,n,i)}function Nx(t,n,i){if(t!==null)if(t.memoizedProps!==n.pendingProps)Nt=!0;else{if(!Hf(t,i)&&(n.flags&128)===0)return Nt=!1,N2(t,n,i);Nt=(t.flags&131072)!==0}else Nt=!1,Qe&&(n.flags&1048576)!==0&&ly(n,Ki,n.index);switch(n.lanes=0,n.tag){case 16:e:{var u=n.pendingProps;if(t=Wa(n.elementType),n.type=t,typeof t=="function")Gd(t)?(u=nl(t,u),n.tag=1,n=Sx(null,n,t,u,i)):(n.tag=0,n=zf(null,n,t,u,i));else{if(t!=null){var m=t.$$typeof;if(m===O){n.tag=11,n=mx(null,n,t,u,i);break e}else if(m===U){n.tag=14,n=gx(null,n,t,u,i);break e}}throw n=W(t)||t,Error(l(306,n,""))}}return n;case 0:return zf(t,n,n.type,n.pendingProps,i);case 1:return u=n.type,m=nl(u,n.pendingProps),Sx(t,n,u,m,i);case 3:e:{if(be(n,n.stateNode.containerInfo),t===null)throw Error(l(387));u=n.pendingProps;var x=n.memoizedState;m=x.element,sf(t,n),ro(n,u,null,i);var E=n.memoizedState;if(u=E.cache,na(n,Ct,u),u!==x.cache&&tf(n,[Ct],i,!0),no(),u=E.element,x.isDehydrated)if(x={element:u,isDehydrated:!1,cache:E.cache},n.updateQueue.baseState=x,n.memoizedState=x,n.flags&256){n=kx(t,n,u,i);break e}else if(u!==m){m=Bn(Error(l(424)),n),Qi(m),n=kx(t,n,u,i);break e}else{switch(t=n.stateNode.containerInfo,t.nodeType){case 9:t=t.body;break;default:t=t.nodeName==="HTML"?t.ownerDocument.body:t}for(ht=Vn(t.firstChild),Ut=n,Qe=!0,ea=null,Un=!0,i=xy(n,null,u,i),n.child=i;i;)i.flags=i.flags&-3|4096,i=i.sibling}else{if(Xa(),u===m){n=Rr(t,n,i);break e}Vt(t,n,u,i)}n=n.child}return n;case 26:return du(t,n),t===null?(i=Bb(n.type,null,n.pendingProps,null))?n.memoizedState=i:Qe||(i=n.type,t=n.pendingProps,u=ju(ie.current).createElement(i),u[Et]=n,u[Xt]=t,$t(u,i,t),wt(u),n.stateNode=u):n.memoizedState=Bb(n.type,t.memoizedProps,n.pendingProps,t.memoizedState),null;case 27:return Ne(n),t===null&&Qe&&(u=n.stateNode=zb(n.type,n.pendingProps,ie.current),Ut=n,Un=!0,m=ht,ma(n.type)?(wp=m,ht=Vn(u.firstChild)):ht=m),Vt(t,n,n.pendingProps.children,i),du(t,n),t===null&&(n.flags|=4194304),n.child;case 5:return t===null&&Qe&&((m=u=ht)&&(u=rA(u,n.type,n.pendingProps,Un),u!==null?(n.stateNode=u,Ut=n,ht=Vn(u.firstChild),Un=!1,m=!0):m=!1),m||ta(n)),Ne(n),m=n.type,x=n.pendingProps,E=t!==null?t.memoizedProps:null,u=x.children,gp(m,x)?u=null:E!==null&&gp(m,E)&&(n.flags|=32),n.memoizedState!==null&&(m=mf(t,n,x2,null,null,i),Eo._currentValue=m),du(t,n),Vt(t,n,u,i),n.child;case 6:return t===null&&Qe&&((t=i=ht)&&(i=aA(i,n.pendingProps,Un),i!==null?(n.stateNode=i,Ut=n,ht=null,t=!0):t=!1),t||ta(n)),null;case 13:return Ex(t,n,i);case 4:return be(n,n.stateNode.containerInfo),u=n.pendingProps,t===null?n.child=el(n,null,u,i):Vt(t,n,u,i),n.child;case 11:return mx(t,n,n.type,n.pendingProps,i);case 7:return Vt(t,n,n.pendingProps,i),n.child;case 8:return Vt(t,n,n.pendingProps.children,i),n.child;case 12:return Vt(t,n,n.pendingProps.children,i),n.child;case 10:return u=n.pendingProps,na(n,n.type,u.value),Vt(t,n,u.children,i),n.child;case 9:return m=n.type._context,u=n.pendingProps.children,Qa(n),m=Ht(m),u=u(m),n.flags|=1,Vt(t,n,u,i),n.child;case 14:return gx(t,n,n.type,n.pendingProps,i);case 15:return yx(t,n,n.type,n.pendingProps,i);case 19:return Ax(t,n,i);case 31:return A2(t,n,i);case 22:return xx(t,n,i,n.pendingProps);case 24:return Qa(n),u=Ht(Ct),t===null?(m=af(),m===null&&(m=dt,x=nf(),m.pooledCache=x,x.refCount++,x!==null&&(m.pooledCacheLanes|=i),m=x),n.memoizedState={parent:u,cache:m},of(n),na(n,Ct,m)):((t.lanes&i)!==0&&(sf(t,n),ro(n,null,null,i),no()),m=t.memoizedState,x=n.memoizedState,m.parent!==u?(m={parent:u,cache:u},n.memoizedState=m,n.lanes===0&&(n.memoizedState=n.updateQueue.baseState=m),na(n,Ct,u)):(u=x.cache,na(n,Ct,u),u!==m.cache&&tf(n,[Ct],i,!0))),Vt(t,n,n.pendingProps.children,i),n.child;case 29:throw n.pendingProps}throw Error(l(156,n.tag))}function Mr(t){t.flags|=4}function Vf(t,n,i,u,m){if((n=(t.mode&32)!==0)&&(n=!1),n){if(t.flags|=16777216,(m&335544128)===m)if(t.stateNode.complete)t.flags|=8192;else if(eb())t.flags|=8192;else throw Ja=Qs,lf}else t.flags&=-16777217}function jx(t,n){if(n.type!=="stylesheet"||(n.state.loading&4)!==0)t.flags&=-16777217;else if(t.flags|=16777216,!Vb(n))if(eb())t.flags|=8192;else throw Ja=Qs,lf}function pu(t,n){n!==null&&(t.flags|=4),t.flags&16384&&(n=t.tag!==22?As():536870912,t.lanes|=n,Kl|=n)}function uo(t,n){if(!Qe)switch(t.tailMode){case"hidden":n=t.tail;for(var i=null;n!==null;)n.alternate!==null&&(i=n),n=n.sibling;i===null?t.tail=null:i.sibling=null;break;case"collapsed":i=t.tail;for(var u=null;i!==null;)i.alternate!==null&&(u=i),i=i.sibling;u===null?n||t.tail===null?t.tail=null:t.tail.sibling=null:u.sibling=null}}function mt(t){var n=t.alternate!==null&&t.alternate.child===t.child,i=0,u=0;if(n)for(var m=t.child;m!==null;)i|=m.lanes|m.childLanes,u|=m.subtreeFlags&65011712,u|=m.flags&65011712,m.return=t,m=m.sibling;else for(m=t.child;m!==null;)i|=m.lanes|m.childLanes,u|=m.subtreeFlags,u|=m.flags,m.return=t,m=m.sibling;return t.subtreeFlags|=u,t.childLanes=i,n}function j2(t,n,i){var u=n.pendingProps;switch(Qd(n),n.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return mt(n),null;case 1:return mt(n),null;case 3:return i=n.stateNode,u=null,t!==null&&(u=t.memoizedState.cache),n.memoizedState.cache!==u&&(n.flags|=2048),jr(Ct),he(),i.pendingContext&&(i.context=i.pendingContext,i.pendingContext=null),(t===null||t.child===null)&&(Ll(n)?Mr(n):t===null||t.memoizedState.isDehydrated&&(n.flags&256)===0||(n.flags|=1024,Wd())),mt(n),null;case 26:var m=n.type,x=n.memoizedState;return t===null?(Mr(n),x!==null?(mt(n),jx(n,x)):(mt(n),Vf(n,m,null,u,i))):x?x!==t.memoizedState?(Mr(n),mt(n),jx(n,x)):(mt(n),n.flags&=-16777217):(t=t.memoizedProps,t!==u&&Mr(n),mt(n),Vf(n,m,t,u,i)),null;case 27:if(De(n),i=ie.current,m=n.type,t!==null&&n.stateNode!=null)t.memoizedProps!==u&&Mr(n);else{if(!u){if(n.stateNode===null)throw Error(l(166));return mt(n),null}t=re.current,Ll(n)?oy(n):(t=zb(m,u,i),n.stateNode=t,Mr(n))}return mt(n),null;case 5:if(De(n),m=n.type,t!==null&&n.stateNode!=null)t.memoizedProps!==u&&Mr(n);else{if(!u){if(n.stateNode===null)throw Error(l(166));return mt(n),null}if(x=re.current,Ll(n))oy(n);else{var E=ju(ie.current);switch(x){case 1:x=E.createElementNS("http://www.w3.org/2000/svg",m);break;case 2:x=E.createElementNS("http://www.w3.org/1998/Math/MathML",m);break;default:switch(m){case"svg":x=E.createElementNS("http://www.w3.org/2000/svg",m);break;case"math":x=E.createElementNS("http://www.w3.org/1998/Math/MathML",m);break;case"script":x=E.createElement("div"),x.innerHTML="<script><\/script>",x=x.removeChild(x.firstChild);break;case"select":x=typeof u.is=="string"?E.createElement("select",{is:u.is}):E.createElement("select"),u.multiple?x.multiple=!0:u.size&&(x.size=u.size);break;default:x=typeof u.is=="string"?E.createElement(m,{is:u.is}):E.createElement(m)}}x[Et]=n,x[Xt]=u;e:for(E=n.child;E!==null;){if(E.tag===5||E.tag===6)x.appendChild(E.stateNode);else if(E.tag!==4&&E.tag!==27&&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}n.stateNode=x;e:switch($t(x,m,u),m){case"button":case"input":case"select":case"textarea":u=!!u.autoFocus;break e;case"img":u=!0;break e;default:u=!1}u&&Mr(n)}}return mt(n),Vf(n,n.type,t===null?null:t.memoizedProps,n.pendingProps,i),null;case 6:if(t&&n.stateNode!=null)t.memoizedProps!==u&&Mr(n);else{if(typeof u!="string"&&n.stateNode===null)throw Error(l(166));if(t=ie.current,Ll(n)){if(t=n.stateNode,i=n.memoizedProps,u=null,m=Ut,m!==null)switch(m.tag){case 27:case 5:u=m.memoizedProps}t[Et]=n,t=!!(t.nodeValue===i||u!==null&&u.suppressHydrationWarning===!0||Eb(t.nodeValue,i)),t||ta(n,!0)}else t=ju(t).createTextNode(u),t[Et]=n,n.stateNode=t}return mt(n),null;case 31:if(i=n.memoizedState,t===null||t.memoizedState!==null){if(u=Ll(n),i!==null){if(t===null){if(!u)throw Error(l(318));if(t=n.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(l(557));t[Et]=n}else Xa(),(n.flags&128)===0&&(n.memoizedState=null),n.flags|=4;mt(n),t=!1}else i=Wd(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=i),t=!0;if(!t)return n.flags&256?(vn(n),n):(vn(n),null);if((n.flags&128)!==0)throw Error(l(558))}return mt(n),null;case 13:if(u=n.memoizedState,t===null||t.memoizedState!==null&&t.memoizedState.dehydrated!==null){if(m=Ll(n),u!==null&&u.dehydrated!==null){if(t===null){if(!m)throw Error(l(318));if(m=n.memoizedState,m=m!==null?m.dehydrated:null,!m)throw Error(l(317));m[Et]=n}else Xa(),(n.flags&128)===0&&(n.memoizedState=null),n.flags|=4;mt(n),m=!1}else m=Wd(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=m),m=!0;if(!m)return n.flags&256?(vn(n),n):(vn(n),null)}return vn(n),(n.flags&128)!==0?(n.lanes=i,n):(i=u!==null,t=t!==null&&t.memoizedState!==null,i&&(u=n.child,m=null,u.alternate!==null&&u.alternate.memoizedState!==null&&u.alternate.memoizedState.cachePool!==null&&(m=u.alternate.memoizedState.cachePool.pool),x=null,u.memoizedState!==null&&u.memoizedState.cachePool!==null&&(x=u.memoizedState.cachePool.pool),x!==m&&(u.flags|=2048)),i!==t&&i&&(n.child.flags|=8192),pu(n,n.updateQueue),mt(n),null);case 4:return he(),t===null&&dp(n.stateNode.containerInfo),mt(n),null;case 10:return jr(n.type),mt(n),null;case 19:if(L(St),u=n.memoizedState,u===null)return mt(n),null;if(m=(n.flags&128)!==0,x=u.rendering,x===null)if(m)uo(u,!1);else{if(vt!==0||t!==null&&(t.flags&128)!==0)for(t=n.child;t!==null;){if(x=eu(t),x!==null){for(n.flags|=128,uo(u,!1),t=x.updateQueue,n.updateQueue=t,pu(n,t),n.subtreeFlags=0,t=i,i=n.child;i!==null;)ny(i,t),i=i.sibling;return _(St,St.current&1|2),Qe&&Ar(n,u.treeForkCount),n.child}t=t.sibling}u.tail!==null&&Dt()>xu&&(n.flags|=128,m=!0,uo(u,!1),n.lanes=4194304)}else{if(!m)if(t=eu(x),t!==null){if(n.flags|=128,m=!0,t=t.updateQueue,n.updateQueue=t,pu(n,t),uo(u,!0),u.tail===null&&u.tailMode==="hidden"&&!x.alternate&&!Qe)return mt(n),null}else 2*Dt()-u.renderingStartTime>xu&&i!==536870912&&(n.flags|=128,m=!0,uo(u,!1),n.lanes=4194304);u.isBackwards?(x.sibling=n.child,n.child=x):(t=u.last,t!==null?t.sibling=x:n.child=x,u.last=x)}return u.tail!==null?(t=u.tail,u.rendering=t,u.tail=t.sibling,u.renderingStartTime=Dt(),t.sibling=null,i=St.current,_(St,m?i&1|2:i&1),Qe&&Ar(n,u.treeForkCount),t):(mt(n),null);case 22:case 23:return vn(n),ff(),u=n.memoizedState!==null,t!==null?t.memoizedState!==null!==u&&(n.flags|=8192):u&&(n.flags|=8192),u?(i&536870912)!==0&&(n.flags&128)===0&&(mt(n),n.subtreeFlags&6&&(n.flags|=8192)):mt(n),i=n.updateQueue,i!==null&&pu(n,i.retryQueue),i=null,t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(i=t.memoizedState.cachePool.pool),u=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(u=n.memoizedState.cachePool.pool),u!==i&&(n.flags|=2048),t!==null&&L(Za),null;case 24:return i=null,t!==null&&(i=t.memoizedState.cache),n.memoizedState.cache!==i&&(n.flags|=2048),jr(Ct),mt(n),null;case 25:return null;case 30:return null}throw Error(l(156,n.tag))}function T2(t,n){switch(Qd(n),n.tag){case 1:return t=n.flags,t&65536?(n.flags=t&-65537|128,n):null;case 3:return jr(Ct),he(),t=n.flags,(t&65536)!==0&&(t&128)===0?(n.flags=t&-65537|128,n):null;case 26:case 27:case 5:return De(n),null;case 31:if(n.memoizedState!==null){if(vn(n),n.alternate===null)throw Error(l(340));Xa()}return t=n.flags,t&65536?(n.flags=t&-65537|128,n):null;case 13:if(vn(n),t=n.memoizedState,t!==null&&t.dehydrated!==null){if(n.alternate===null)throw Error(l(340));Xa()}return t=n.flags,t&65536?(n.flags=t&-65537|128,n):null;case 19:return L(St),null;case 4:return he(),null;case 10:return jr(n.type),null;case 22:case 23:return vn(n),ff(),t!==null&&L(Za),t=n.flags,t&65536?(n.flags=t&-65537|128,n):null;case 24:return jr(Ct),null;case 25:return null;default:return null}}function Tx(t,n){switch(Qd(n),n.tag){case 3:jr(Ct),he();break;case 26:case 27:case 5:De(n);break;case 4:he();break;case 31:n.memoizedState!==null&&vn(n);break;case 13:vn(n);break;case 19:L(St);break;case 10:jr(n.type);break;case 22:case 23:vn(n),ff(),t!==null&&L(Za);break;case 24:jr(Ct)}}function co(t,n){try{var i=n.updateQueue,u=i!==null?i.lastEffect:null;if(u!==null){var m=u.next;i=m;do{if((i.tag&t)===t){u=void 0;var x=i.create,E=i.inst;u=x(),E.destroy=u}i=i.next}while(i!==m)}}catch(T){ot(n,n.return,T)}}function sa(t,n,i){try{var u=n.updateQueue,m=u!==null?u.lastEffect:null;if(m!==null){var x=m.next;u=x;do{if((u.tag&t)===t){var E=u.inst,T=E.destroy;if(T!==void 0){E.destroy=void 0,m=n;var P=i,K=T;try{K()}catch(ae){ot(m,P,ae)}}}u=u.next}while(u!==x)}}catch(ae){ot(n,n.return,ae)}}function _x(t){var n=t.updateQueue;if(n!==null){var i=t.stateNode;try{vy(n,i)}catch(u){ot(t,t.return,u)}}}function Rx(t,n,i){i.props=nl(t.type,t.memoizedProps),i.state=t.memoizedState;try{i.componentWillUnmount()}catch(u){ot(t,n,u)}}function fo(t,n){try{var i=t.ref;if(i!==null){switch(t.tag){case 26:case 27:case 5:var u=t.stateNode;break;case 30:u=t.stateNode;break;default:u=t.stateNode}typeof i=="function"?t.refCleanup=i(u):i.current=u}}catch(m){ot(t,n,m)}}function sr(t,n){var i=t.ref,u=t.refCleanup;if(i!==null)if(typeof u=="function")try{u()}catch(m){ot(t,n,m)}finally{t.refCleanup=null,t=t.alternate,t!=null&&(t.refCleanup=null)}else if(typeof i=="function")try{i(null)}catch(m){ot(t,n,m)}else i.current=null}function Mx(t){var n=t.type,i=t.memoizedProps,u=t.stateNode;try{e:switch(n){case"button":case"input":case"select":case"textarea":i.autoFocus&&u.focus();break e;case"img":i.src?u.src=i.src:i.srcSet&&(u.srcset=i.srcSet)}}catch(m){ot(t,t.return,m)}}function $f(t,n,i){try{var u=t.stateNode;Z2(u,t.type,i,n),u[Xt]=n}catch(m){ot(t,t.return,m)}}function Ox(t){return t.tag===5||t.tag===3||t.tag===26||t.tag===27&&ma(t.type)||t.tag===4}function qf(t){e:for(;;){for(;t.sibling===null;){if(t.return===null||Ox(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.tag===27&&ma(t.type)||t.flags&2||t.child===null||t.tag===4)continue e;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function Gf(t,n,i){var u=t.tag;if(u===5||u===6)t=t.stateNode,n?(i.nodeType===9?i.body:i.nodeName==="HTML"?i.ownerDocument.body:i).insertBefore(t,n):(n=i.nodeType===9?i.body:i.nodeName==="HTML"?i.ownerDocument.body:i,n.appendChild(t),i=i._reactRootContainer,i!=null||n.onclick!==null||(n.onclick=kr));else if(u!==4&&(u===27&&ma(t.type)&&(i=t.stateNode,n=null),t=t.child,t!==null))for(Gf(t,n,i),t=t.sibling;t!==null;)Gf(t,n,i),t=t.sibling}function hu(t,n,i){var u=t.tag;if(u===5||u===6)t=t.stateNode,n?i.insertBefore(t,n):i.appendChild(t);else if(u!==4&&(u===27&&ma(t.type)&&(i=t.stateNode),t=t.child,t!==null))for(hu(t,n,i),t=t.sibling;t!==null;)hu(t,n,i),t=t.sibling}function Dx(t){var n=t.stateNode,i=t.memoizedProps;try{for(var u=t.type,m=n.attributes;m.length;)n.removeAttributeNode(m[0]);$t(n,u,i),n[Et]=t,n[Xt]=i}catch(x){ot(t,t.return,x)}}var Or=!1,jt=!1,Yf=!1,zx=typeof WeakSet=="function"?WeakSet:Set,Lt=null;function _2(t,n){if(t=t.containerInfo,hp=zu,t=Yg(t),Pd(t)){if("selectionStart"in t)var i={start:t.selectionStart,end:t.selectionEnd};else e:{i=(i=t.ownerDocument)&&i.defaultView||window;var u=i.getSelection&&i.getSelection();if(u&&u.rangeCount!==0){i=u.anchorNode;var m=u.anchorOffset,x=u.focusNode;u=u.focusOffset;try{i.nodeType,x.nodeType}catch{i=null;break e}var E=0,T=-1,P=-1,K=0,ae=0,de=t,Z=null;t:for(;;){for(var ee;de!==i||m!==0&&de.nodeType!==3||(T=E+m),de!==x||u!==0&&de.nodeType!==3||(P=E+u),de.nodeType===3&&(E+=de.nodeValue.length),(ee=de.firstChild)!==null;)Z=de,de=ee;for(;;){if(de===t)break t;if(Z===i&&++K===m&&(T=E),Z===x&&++ae===u&&(P=E),(ee=de.nextSibling)!==null)break;de=Z,Z=de.parentNode}de=ee}i=T===-1||P===-1?null:{start:T,end:P}}else i=null}i=i||{start:0,end:0}}else i=null;for(mp={focusedElem:t,selectionRange:i},zu=!1,Lt=n;Lt!==null;)if(n=Lt,t=n.child,(n.subtreeFlags&1028)!==0&&t!==null)t.return=n,Lt=t;else for(;Lt!==null;){switch(n=Lt,x=n.alternate,t=n.flags,n.tag){case 0:if((t&4)!==0&&(t=n.updateQueue,t=t!==null?t.events:null,t!==null))for(i=0;i<t.length;i++)m=t[i],m.ref.impl=m.nextImpl;break;case 11:case 15:break;case 1:if((t&1024)!==0&&x!==null){t=void 0,i=n,m=x.memoizedProps,x=x.memoizedState,u=i.stateNode;try{var we=nl(i.type,m);t=u.getSnapshotBeforeUpdate(we,x),u.__reactInternalSnapshotBeforeUpdate=t}catch(Oe){ot(i,i.return,Oe)}}break;case 3:if((t&1024)!==0){if(t=n.stateNode.containerInfo,i=t.nodeType,i===9)xp(t);else if(i===1)switch(t.nodeName){case"HEAD":case"HTML":case"BODY":xp(t);break;default:t.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((t&1024)!==0)throw Error(l(163))}if(t=n.sibling,t!==null){t.return=n.return,Lt=t;break}Lt=n.return}}function Lx(t,n,i){var u=i.flags;switch(i.tag){case 0:case 11:case 15:zr(t,i),u&4&&co(5,i);break;case 1:if(zr(t,i),u&4)if(t=i.stateNode,n===null)try{t.componentDidMount()}catch(E){ot(i,i.return,E)}else{var m=nl(i.type,n.memoizedProps);n=n.memoizedState;try{t.componentDidUpdate(m,n,t.__reactInternalSnapshotBeforeUpdate)}catch(E){ot(i,i.return,E)}}u&64&&_x(i),u&512&&fo(i,i.return);break;case 3:if(zr(t,i),u&64&&(t=i.updateQueue,t!==null)){if(n=null,i.child!==null)switch(i.child.tag){case 27:case 5:n=i.child.stateNode;break;case 1:n=i.child.stateNode}try{vy(t,n)}catch(E){ot(i,i.return,E)}}break;case 27:n===null&&u&4&&Dx(i);case 26:case 5:zr(t,i),n===null&&u&4&&Mx(i),u&512&&fo(i,i.return);break;case 12:zr(t,i);break;case 31:zr(t,i),u&4&&Px(t,i);break;case 13:zr(t,i),u&4&&Fx(t,i),u&64&&(t=i.memoizedState,t!==null&&(t=t.dehydrated,t!==null&&(i=P2.bind(null,i),lA(t,i))));break;case 22:if(u=i.memoizedState!==null||Or,!u){n=n!==null&&n.memoizedState!==null||jt,m=Or;var x=jt;Or=u,(jt=n)&&!x?Lr(t,i,(i.subtreeFlags&8772)!==0):zr(t,i),Or=m,jt=x}break;case 30:break;default:zr(t,i)}}function Ix(t){var n=t.alternate;n!==null&&(t.alternate=null,Ix(n)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(n=t.stateNode,n!==null&&El(n)),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}var xt=null,sn=!1;function Dr(t,n,i){for(i=i.child;i!==null;)Bx(t,n,i),i=i.sibling}function Bx(t,n,i){if(yt&&typeof yt.onCommitFiberUnmount=="function")try{yt.onCommitFiberUnmount(He,i)}catch{}switch(i.tag){case 26:jt||sr(i,n),Dr(t,n,i),i.memoizedState?i.memoizedState.count--:i.stateNode&&(i=i.stateNode,i.parentNode.removeChild(i));break;case 27:jt||sr(i,n);var u=xt,m=sn;ma(i.type)&&(xt=i.stateNode,sn=!1),Dr(t,n,i),wo(i.stateNode),xt=u,sn=m;break;case 5:jt||sr(i,n);case 6:if(u=xt,m=sn,xt=null,Dr(t,n,i),xt=u,sn=m,xt!==null)if(sn)try{(xt.nodeType===9?xt.body:xt.nodeName==="HTML"?xt.ownerDocument.body:xt).removeChild(i.stateNode)}catch(x){ot(i,n,x)}else try{xt.removeChild(i.stateNode)}catch(x){ot(i,n,x)}break;case 18:xt!==null&&(sn?(t=xt,_b(t.nodeType===9?t.body:t.nodeName==="HTML"?t.ownerDocument.body:t,i.stateNode),ri(t)):_b(xt,i.stateNode));break;case 4:u=xt,m=sn,xt=i.stateNode.containerInfo,sn=!0,Dr(t,n,i),xt=u,sn=m;break;case 0:case 11:case 14:case 15:sa(2,i,n),jt||sa(4,i,n),Dr(t,n,i);break;case 1:jt||(sr(i,n),u=i.stateNode,typeof u.componentWillUnmount=="function"&&Rx(i,n,u)),Dr(t,n,i);break;case 21:Dr(t,n,i);break;case 22:jt=(u=jt)||i.memoizedState!==null,Dr(t,n,i),jt=u;break;default:Dr(t,n,i)}}function Px(t,n){if(n.memoizedState===null&&(t=n.alternate,t!==null&&(t=t.memoizedState,t!==null))){t=t.dehydrated;try{ri(t)}catch(i){ot(n,n.return,i)}}}function Fx(t,n){if(n.memoizedState===null&&(t=n.alternate,t!==null&&(t=t.memoizedState,t!==null&&(t=t.dehydrated,t!==null))))try{ri(t)}catch(i){ot(n,n.return,i)}}function R2(t){switch(t.tag){case 31:case 13:case 19:var n=t.stateNode;return n===null&&(n=t.stateNode=new zx),n;case 22:return t=t.stateNode,n=t._retryCache,n===null&&(n=t._retryCache=new zx),n;default:throw Error(l(435,t.tag))}}function mu(t,n){var i=R2(t);n.forEach(function(u){if(!i.has(u)){i.add(u);var m=F2.bind(null,t,u);u.then(m,m)}})}function un(t,n){var i=n.deletions;if(i!==null)for(var u=0;u<i.length;u++){var m=i[u],x=t,E=n,T=E;e:for(;T!==null;){switch(T.tag){case 27:if(ma(T.type)){xt=T.stateNode,sn=!1;break e}break;case 5:xt=T.stateNode,sn=!1;break e;case 3:case 4:xt=T.stateNode.containerInfo,sn=!0;break e}T=T.return}if(xt===null)throw Error(l(160));Bx(x,E,m),xt=null,sn=!1,x=m.alternate,x!==null&&(x.return=null),m.return=null}if(n.subtreeFlags&13886)for(n=n.child;n!==null;)Ux(n,t),n=n.sibling}var Zn=null;function Ux(t,n){var i=t.alternate,u=t.flags;switch(t.tag){case 0:case 11:case 14:case 15:un(n,t),cn(t),u&4&&(sa(3,t,t.return),co(3,t),sa(5,t,t.return));break;case 1:un(n,t),cn(t),u&512&&(jt||i===null||sr(i,i.return)),u&64&&Or&&(t=t.updateQueue,t!==null&&(u=t.callbacks,u!==null&&(i=t.shared.hiddenCallbacks,t.shared.hiddenCallbacks=i===null?u:i.concat(u))));break;case 26:var m=Zn;if(un(n,t),cn(t),u&512&&(jt||i===null||sr(i,i.return)),u&4){var x=i!==null?i.memoizedState:null;if(u=t.memoizedState,i===null)if(u===null)if(t.stateNode===null){e:{u=t.type,i=t.memoizedProps,m=m.ownerDocument||m;t:switch(u){case"title":x=m.getElementsByTagName("title")[0],(!x||x[Ua]||x[Et]||x.namespaceURI==="http://www.w3.org/2000/svg"||x.hasAttribute("itemprop"))&&(x=m.createElement(u),m.head.insertBefore(x,m.querySelector("head > title"))),$t(x,u,i),x[Et]=t,wt(x),u=x;break e;case"link":var E=Ub("link","href",m).get(u+(i.href||""));if(E){for(var T=0;T<E.length;T++)if(x=E[T],x.getAttribute("href")===(i.href==null||i.href===""?null:i.href)&&x.getAttribute("rel")===(i.rel==null?null:i.rel)&&x.getAttribute("title")===(i.title==null?null:i.title)&&x.getAttribute("crossorigin")===(i.crossOrigin==null?null:i.crossOrigin)){E.splice(T,1);break t}}x=m.createElement(u),$t(x,u,i),m.head.appendChild(x);break;case"meta":if(E=Ub("meta","content",m).get(u+(i.content||""))){for(T=0;T<E.length;T++)if(x=E[T],x.getAttribute("content")===(i.content==null?null:""+i.content)&&x.getAttribute("name")===(i.name==null?null:i.name)&&x.getAttribute("property")===(i.property==null?null:i.property)&&x.getAttribute("http-equiv")===(i.httpEquiv==null?null:i.httpEquiv)&&x.getAttribute("charset")===(i.charSet==null?null:i.charSet)){E.splice(T,1);break t}}x=m.createElement(u),$t(x,u,i),m.head.appendChild(x);break;default:throw Error(l(468,u))}x[Et]=t,wt(x),u=x}t.stateNode=u}else Hb(m,t.type,t.stateNode);else t.stateNode=Fb(m,u,t.memoizedProps);else x!==u?(x===null?i.stateNode!==null&&(i=i.stateNode,i.parentNode.removeChild(i)):x.count--,u===null?Hb(m,t.type,t.stateNode):Fb(m,u,t.memoizedProps)):u===null&&t.stateNode!==null&&$f(t,t.memoizedProps,i.memoizedProps)}break;case 27:un(n,t),cn(t),u&512&&(jt||i===null||sr(i,i.return)),i!==null&&u&4&&$f(t,t.memoizedProps,i.memoizedProps);break;case 5:if(un(n,t),cn(t),u&512&&(jt||i===null||sr(i,i.return)),t.flags&32){m=t.stateNode;try{Al(m,"")}catch(we){ot(t,t.return,we)}}u&4&&t.stateNode!=null&&(m=t.memoizedProps,$f(t,m,i!==null?i.memoizedProps:m)),u&1024&&(Yf=!0);break;case 6:if(un(n,t),cn(t),u&4){if(t.stateNode===null)throw Error(l(162));u=t.memoizedProps,i=t.stateNode;try{i.nodeValue=u}catch(we){ot(t,t.return,we)}}break;case 3:if(Ru=null,m=Zn,Zn=Tu(n.containerInfo),un(n,t),Zn=m,cn(t),u&4&&i!==null&&i.memoizedState.isDehydrated)try{ri(n.containerInfo)}catch(we){ot(t,t.return,we)}Yf&&(Yf=!1,Hx(t));break;case 4:u=Zn,Zn=Tu(t.stateNode.containerInfo),un(n,t),cn(t),Zn=u;break;case 12:un(n,t),cn(t);break;case 31:un(n,t),cn(t),u&4&&(u=t.updateQueue,u!==null&&(t.updateQueue=null,mu(t,u)));break;case 13:un(n,t),cn(t),t.child.flags&8192&&t.memoizedState!==null!=(i!==null&&i.memoizedState!==null)&&(yu=Dt()),u&4&&(u=t.updateQueue,u!==null&&(t.updateQueue=null,mu(t,u)));break;case 22:m=t.memoizedState!==null;var P=i!==null&&i.memoizedState!==null,K=Or,ae=jt;if(Or=K||m,jt=ae||P,un(n,t),jt=ae,Or=K,cn(t),u&8192)e:for(n=t.stateNode,n._visibility=m?n._visibility&-2:n._visibility|1,m&&(i===null||P||Or||jt||rl(t)),i=null,n=t;;){if(n.tag===5||n.tag===26){if(i===null){P=i=n;try{if(x=P.stateNode,m)E=x.style,typeof E.setProperty=="function"?E.setProperty("display","none","important"):E.display="none";else{T=P.stateNode;var de=P.memoizedProps.style,Z=de!=null&&de.hasOwnProperty("display")?de.display:null;T.style.display=Z==null||typeof Z=="boolean"?"":(""+Z).trim()}}catch(we){ot(P,P.return,we)}}}else if(n.tag===6){if(i===null){P=n;try{P.stateNode.nodeValue=m?"":P.memoizedProps}catch(we){ot(P,P.return,we)}}}else if(n.tag===18){if(i===null){P=n;try{var ee=P.stateNode;m?Rb(ee,!0):Rb(P.stateNode,!1)}catch(we){ot(P,P.return,we)}}}else if((n.tag!==22&&n.tag!==23||n.memoizedState===null||n===t)&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break e;for(;n.sibling===null;){if(n.return===null||n.return===t)break e;i===n&&(i=null),n=n.return}i===n&&(i=null),n.sibling.return=n.return,n=n.sibling}u&4&&(u=t.updateQueue,u!==null&&(i=u.retryQueue,i!==null&&(u.retryQueue=null,mu(t,i))));break;case 19:un(n,t),cn(t),u&4&&(u=t.updateQueue,u!==null&&(t.updateQueue=null,mu(t,u)));break;case 30:break;case 21:break;default:un(n,t),cn(t)}}function cn(t){var n=t.flags;if(n&2){try{for(var i,u=t.return;u!==null;){if(Ox(u)){i=u;break}u=u.return}if(i==null)throw Error(l(160));switch(i.tag){case 27:var m=i.stateNode,x=qf(t);hu(t,x,m);break;case 5:var E=i.stateNode;i.flags&32&&(Al(E,""),i.flags&=-33);var T=qf(t);hu(t,T,E);break;case 3:case 4:var P=i.stateNode.containerInfo,K=qf(t);Gf(t,K,P);break;default:throw Error(l(161))}}catch(ae){ot(t,t.return,ae)}t.flags&=-3}n&4096&&(t.flags&=-4097)}function Hx(t){if(t.subtreeFlags&1024)for(t=t.child;t!==null;){var n=t;Hx(n),n.tag===5&&n.flags&1024&&n.stateNode.reset(),t=t.sibling}}function zr(t,n){if(n.subtreeFlags&8772)for(n=n.child;n!==null;)Lx(t,n.alternate,n),n=n.sibling}function rl(t){for(t=t.child;t!==null;){var n=t;switch(n.tag){case 0:case 11:case 14:case 15:sa(4,n,n.return),rl(n);break;case 1:sr(n,n.return);var i=n.stateNode;typeof i.componentWillUnmount=="function"&&Rx(n,n.return,i),rl(n);break;case 27:wo(n.stateNode);case 26:case 5:sr(n,n.return),rl(n);break;case 22:n.memoizedState===null&&rl(n);break;case 30:rl(n);break;default:rl(n)}t=t.sibling}}function Lr(t,n,i){for(i=i&&(n.subtreeFlags&8772)!==0,n=n.child;n!==null;){var u=n.alternate,m=t,x=n,E=x.flags;switch(x.tag){case 0:case 11:case 15:Lr(m,x,i),co(4,x);break;case 1:if(Lr(m,x,i),u=x,m=u.stateNode,typeof m.componentDidMount=="function")try{m.componentDidMount()}catch(K){ot(u,u.return,K)}if(u=x,m=u.updateQueue,m!==null){var T=u.stateNode;try{var P=m.shared.hiddenCallbacks;if(P!==null)for(m.shared.hiddenCallbacks=null,m=0;m<P.length;m++)by(P[m],T)}catch(K){ot(u,u.return,K)}}i&&E&64&&_x(x),fo(x,x.return);break;case 27:Dx(x);case 26:case 5:Lr(m,x,i),i&&u===null&&E&4&&Mx(x),fo(x,x.return);break;case 12:Lr(m,x,i);break;case 31:Lr(m,x,i),i&&E&4&&Px(m,x);break;case 13:Lr(m,x,i),i&&E&4&&Fx(m,x);break;case 22:x.memoizedState===null&&Lr(m,x,i),fo(x,x.return);break;case 30:break;default:Lr(m,x,i)}n=n.sibling}}function Xf(t,n){var i=null;t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(i=t.memoizedState.cachePool.pool),t=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(t=n.memoizedState.cachePool.pool),t!==i&&(t!=null&&t.refCount++,i!=null&&Zi(i))}function Kf(t,n){t=null,n.alternate!==null&&(t=n.alternate.memoizedState.cache),n=n.memoizedState.cache,n!==t&&(n.refCount++,t!=null&&Zi(t))}function Wn(t,n,i,u){if(n.subtreeFlags&10256)for(n=n.child;n!==null;)Vx(t,n,i,u),n=n.sibling}function Vx(t,n,i,u){var m=n.flags;switch(n.tag){case 0:case 11:case 15:Wn(t,n,i,u),m&2048&&co(9,n);break;case 1:Wn(t,n,i,u);break;case 3:Wn(t,n,i,u),m&2048&&(t=null,n.alternate!==null&&(t=n.alternate.memoizedState.cache),n=n.memoizedState.cache,n!==t&&(n.refCount++,t!=null&&Zi(t)));break;case 12:if(m&2048){Wn(t,n,i,u),t=n.stateNode;try{var x=n.memoizedProps,E=x.id,T=x.onPostCommit;typeof T=="function"&&T(E,n.alternate===null?"mount":"update",t.passiveEffectDuration,-0)}catch(P){ot(n,n.return,P)}}else Wn(t,n,i,u);break;case 31:Wn(t,n,i,u);break;case 13:Wn(t,n,i,u);break;case 23:break;case 22:x=n.stateNode,E=n.alternate,n.memoizedState!==null?x._visibility&2?Wn(t,n,i,u):po(t,n):x._visibility&2?Wn(t,n,i,u):(x._visibility|=2,Gl(t,n,i,u,(n.subtreeFlags&10256)!==0||!1)),m&2048&&Xf(E,n);break;case 24:Wn(t,n,i,u),m&2048&&Kf(n.alternate,n);break;default:Wn(t,n,i,u)}}function Gl(t,n,i,u,m){for(m=m&&((n.subtreeFlags&10256)!==0||!1),n=n.child;n!==null;){var x=t,E=n,T=i,P=u,K=E.flags;switch(E.tag){case 0:case 11:case 15:Gl(x,E,T,P,m),co(8,E);break;case 23:break;case 22:var ae=E.stateNode;E.memoizedState!==null?ae._visibility&2?Gl(x,E,T,P,m):po(x,E):(ae._visibility|=2,Gl(x,E,T,P,m)),m&&K&2048&&Xf(E.alternate,E);break;case 24:Gl(x,E,T,P,m),m&&K&2048&&Kf(E.alternate,E);break;default:Gl(x,E,T,P,m)}n=n.sibling}}function po(t,n){if(n.subtreeFlags&10256)for(n=n.child;n!==null;){var i=t,u=n,m=u.flags;switch(u.tag){case 22:po(i,u),m&2048&&Xf(u.alternate,u);break;case 24:po(i,u),m&2048&&Kf(u.alternate,u);break;default:po(i,u)}n=n.sibling}}var ho=8192;function Yl(t,n,i){if(t.subtreeFlags&ho)for(t=t.child;t!==null;)$x(t,n,i),t=t.sibling}function $x(t,n,i){switch(t.tag){case 26:Yl(t,n,i),t.flags&ho&&t.memoizedState!==null&&yA(i,Zn,t.memoizedState,t.memoizedProps);break;case 5:Yl(t,n,i);break;case 3:case 4:var u=Zn;Zn=Tu(t.stateNode.containerInfo),Yl(t,n,i),Zn=u;break;case 22:t.memoizedState===null&&(u=t.alternate,u!==null&&u.memoizedState!==null?(u=ho,ho=16777216,Yl(t,n,i),ho=u):Yl(t,n,i));break;default:Yl(t,n,i)}}function qx(t){var n=t.alternate;if(n!==null&&(t=n.child,t!==null)){n.child=null;do n=t.sibling,t.sibling=null,t=n;while(t!==null)}}function mo(t){var n=t.deletions;if((t.flags&16)!==0){if(n!==null)for(var i=0;i<n.length;i++){var u=n[i];Lt=u,Yx(u,t)}qx(t)}if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Gx(t),t=t.sibling}function Gx(t){switch(t.tag){case 0:case 11:case 15:mo(t),t.flags&2048&&sa(9,t,t.return);break;case 3:mo(t);break;case 12:mo(t);break;case 22:var n=t.stateNode;t.memoizedState!==null&&n._visibility&2&&(t.return===null||t.return.tag!==13)?(n._visibility&=-3,gu(t)):mo(t);break;default:mo(t)}}function gu(t){var n=t.deletions;if((t.flags&16)!==0){if(n!==null)for(var i=0;i<n.length;i++){var u=n[i];Lt=u,Yx(u,t)}qx(t)}for(t=t.child;t!==null;){switch(n=t,n.tag){case 0:case 11:case 15:sa(8,n,n.return),gu(n);break;case 22:i=n.stateNode,i._visibility&2&&(i._visibility&=-3,gu(n));break;default:gu(n)}t=t.sibling}}function Yx(t,n){for(;Lt!==null;){var i=Lt;switch(i.tag){case 0:case 11:case 15:sa(8,i,n);break;case 23:case 22:if(i.memoizedState!==null&&i.memoizedState.cachePool!==null){var u=i.memoizedState.cachePool.pool;u!=null&&u.refCount++}break;case 24:Zi(i.memoizedState.cache)}if(u=i.child,u!==null)u.return=i,Lt=u;else e:for(i=t;Lt!==null;){u=Lt;var m=u.sibling,x=u.return;if(Ix(u),u===i){Lt=null;break e}if(m!==null){m.return=x,Lt=m;break e}Lt=x}}}var M2={getCacheForType:function(t){var n=Ht(Ct),i=n.data.get(t);return i===void 0&&(i=t(),n.data.set(t,i)),i},cacheSignal:function(){return Ht(Ct).controller.signal}},O2=typeof WeakMap=="function"?WeakMap:Map,at=0,dt=null,$e=null,Xe=0,it=0,wn=null,ua=!1,Xl=!1,Qf=!1,Ir=0,vt=0,ca=0,al=0,Zf=0,Sn=0,Kl=0,go=null,dn=null,Wf=!1,yu=0,Xx=0,xu=1/0,bu=null,da=null,_t=0,fa=null,Ql=null,Br=0,Jf=0,ep=null,Kx=null,yo=0,tp=null;function kn(){return(at&2)!==0&&Xe!==0?Xe&-Xe:B.T!==null?op():Ts()}function Qx(){if(Sn===0)if((Xe&536870912)===0||Qe){var t=Sl;Sl<<=1,(Sl&3932160)===0&&(Sl=262144),Sn=t}else Sn=536870912;return t=bn.current,t!==null&&(t.flags|=32),Sn}function fn(t,n,i){(t===dt&&(it===2||it===9)||t.cancelPendingCommit!==null)&&(Zl(t,0),pa(t,Xe,Sn,!1)),Ye(t,i),((at&2)===0||t!==dt)&&(t===dt&&((at&2)===0&&(al|=i),vt===4&&pa(t,Xe,Sn,!1)),ur(t))}function Zx(t,n,i){if((at&6)!==0)throw Error(l(327));var u=!i&&(n&127)===0&&(n&t.expiredLanes)===0||Pa(t,n),m=u?L2(t,n):rp(t,n,!0),x=u;do{if(m===0){Xl&&!u&&pa(t,n,0,!1);break}else{if(i=t.current.alternate,x&&!D2(i)){m=rp(t,n,!1),x=!1;continue}if(m===2){if(x=n,t.errorRecoveryDisabledLanes&x)var E=0;else E=t.pendingLanes&-536870913,E=E!==0?E:E&536870912?536870912:0;if(E!==0){n=E;e:{var T=t;m=go;var P=T.current.memoizedState.isDehydrated;if(P&&(Zl(T,E).flags|=256),E=rp(T,E,!1),E!==2){if(Qf&&!P){T.errorRecoveryDisabledLanes|=x,al|=x,m=4;break e}x=dn,dn=m,x!==null&&(dn===null?dn=x:dn.push.apply(dn,x))}m=E}if(x=!1,m!==2)continue}}if(m===1){Zl(t,0),pa(t,n,0,!0);break}e:{switch(u=t,x=m,x){case 0:case 1:throw Error(l(345));case 4:if((n&4194048)!==n)break;case 6:pa(u,n,Sn,!ua);break e;case 2:dn=null;break;case 3:case 5:break;default:throw Error(l(329))}if((n&62914560)===n&&(m=yu+300-Dt(),10<m)){if(pa(u,n,Sn,!ua),Ba(u,0,!0)!==0)break e;Br=n,u.timeoutHandle=jb(Wx.bind(null,u,i,dn,bu,Wf,n,Sn,al,Kl,ua,x,"Throttled",-0,0),m);break e}Wx(u,i,dn,bu,Wf,n,Sn,al,Kl,ua,x,null,-0,0)}}break}while(!0);ur(t)}function Wx(t,n,i,u,m,x,E,T,P,K,ae,de,Z,ee){if(t.timeoutHandle=-1,de=n.subtreeFlags,de&8192||(de&16785408)===16785408){de={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:kr},$x(n,x,de);var we=(x&62914560)===x?yu-Dt():(x&4194048)===x?Xx-Dt():0;if(we=xA(de,we),we!==null){Br=x,t.cancelPendingCommit=we(ib.bind(null,t,n,x,i,u,m,E,T,P,ae,de,null,Z,ee)),pa(t,x,E,!K);return}}ib(t,n,x,i,u,m,E,T,P)}function D2(t){for(var n=t;;){var i=n.tag;if((i===0||i===11||i===15)&&n.flags&16384&&(i=n.updateQueue,i!==null&&(i=i.stores,i!==null)))for(var u=0;u<i.length;u++){var m=i[u],x=m.getSnapshot;m=m.value;try{if(!yn(x(),m))return!1}catch{return!1}}if(i=n.child,n.subtreeFlags&16384&&i!==null)i.return=n,n=i;else{if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return!0;n=n.return}n.sibling.return=n.return,n=n.sibling}}return!0}function pa(t,n,i,u){n&=~Zf,n&=~al,t.suspendedLanes|=n,t.pingedLanes&=~n,u&&(t.warmLanes|=n),u=t.expirationTimes;for(var m=n;0<m;){var x=31-lt(m),E=1<<x;u[x]=-1,m&=~E}i!==0&&Fa(t,i,n)}function vu(){return(at&6)===0?(xo(0),!1):!0}function np(){if($e!==null){if(it===0)var t=$e.return;else t=$e,Nr=Ka=null,xf(t),Ul=null,Ji=0,t=$e;for(;t!==null;)Tx(t.alternate,t),t=t.return;$e=null}}function Zl(t,n){var i=t.timeoutHandle;i!==-1&&(t.timeoutHandle=-1,eA(i)),i=t.cancelPendingCommit,i!==null&&(t.cancelPendingCommit=null,i()),Br=0,np(),dt=t,$e=i=Cr(t.current,null),Xe=n,it=0,wn=null,ua=!1,Xl=Pa(t,n),Qf=!1,Kl=Sn=Zf=al=ca=vt=0,dn=go=null,Wf=!1,(n&8)!==0&&(n|=n&32);var u=t.entangledLanes;if(u!==0)for(t=t.entanglements,u&=n;0<u;){var m=31-lt(u),x=1<<m;n|=t[m],u&=~x}return Ir=n,Us(),i}function Jx(t,n){Be=null,B.H=oo,n===Fl||n===Ks?(n=my(),it=3):n===lf?(n=my(),it=4):it=n===Df?8:n!==null&&typeof n=="object"&&typeof n.then=="function"?6:1,wn=n,$e===null&&(vt=1,uu(t,Bn(n,t.current)))}function eb(){var t=bn.current;return t===null?!0:(Xe&4194048)===Xe?Hn===null:(Xe&62914560)===Xe||(Xe&536870912)!==0?t===Hn:!1}function tb(){var t=B.H;return B.H=oo,t===null?oo:t}function nb(){var t=B.A;return B.A=M2,t}function wu(){vt=4,ua||(Xe&4194048)!==Xe&&bn.current!==null||(Xl=!0),(ca&134217727)===0&&(al&134217727)===0||dt===null||pa(dt,Xe,Sn,!1)}function rp(t,n,i){var u=at;at|=2;var m=tb(),x=nb();(dt!==t||Xe!==n)&&(bu=null,Zl(t,n)),n=!1;var E=vt;e:do try{if(it!==0&&$e!==null){var T=$e,P=wn;switch(it){case 8:np(),E=6;break e;case 3:case 2:case 9:case 6:bn.current===null&&(n=!0);var K=it;if(it=0,wn=null,Wl(t,T,P,K),i&&Xl){E=0;break e}break;default:K=it,it=0,wn=null,Wl(t,T,P,K)}}z2(),E=vt;break}catch(ae){Jx(t,ae)}while(!0);return n&&t.shellSuspendCounter++,Nr=Ka=null,at=u,B.H=m,B.A=x,$e===null&&(dt=null,Xe=0,Us()),E}function z2(){for(;$e!==null;)rb($e)}function L2(t,n){var i=at;at|=2;var u=tb(),m=nb();dt!==t||Xe!==n?(bu=null,xu=Dt()+500,Zl(t,n)):Xl=Pa(t,n);e:do try{if(it!==0&&$e!==null){n=$e;var x=wn;t:switch(it){case 1:it=0,wn=null,Wl(t,n,x,1);break;case 2:case 9:if(py(x)){it=0,wn=null,ab(n);break}n=function(){it!==2&&it!==9||dt!==t||(it=7),ur(t)},x.then(n,n);break e;case 3:it=7;break e;case 4:it=5;break e;case 7:py(x)?(it=0,wn=null,ab(n)):(it=0,wn=null,Wl(t,n,x,7));break;case 5:var E=null;switch($e.tag){case 26:E=$e.memoizedState;case 5:case 27:var T=$e;if(E?Vb(E):T.stateNode.complete){it=0,wn=null;var P=T.sibling;if(P!==null)$e=P;else{var K=T.return;K!==null?($e=K,Su(K)):$e=null}break t}}it=0,wn=null,Wl(t,n,x,5);break;case 6:it=0,wn=null,Wl(t,n,x,6);break;case 8:np(),vt=6;break e;default:throw Error(l(462))}}I2();break}catch(ae){Jx(t,ae)}while(!0);return Nr=Ka=null,B.H=u,B.A=m,at=i,$e!==null?0:(dt=null,Xe=0,Us(),vt)}function I2(){for(;$e!==null&&!br();)rb($e)}function rb(t){var n=Nx(t.alternate,t,Ir);t.memoizedProps=t.pendingProps,n===null?Su(t):$e=n}function ab(t){var n=t,i=n.alternate;switch(n.tag){case 15:case 0:n=wx(i,n,n.pendingProps,n.type,void 0,Xe);break;case 11:n=wx(i,n,n.pendingProps,n.type.render,n.ref,Xe);break;case 5:xf(n);default:Tx(i,n),n=$e=ny(n,Ir),n=Nx(i,n,Ir)}t.memoizedProps=t.pendingProps,n===null?Su(t):$e=n}function Wl(t,n,i,u){Nr=Ka=null,xf(n),Ul=null,Ji=0;var m=n.return;try{if(C2(t,m,n,i,Xe)){vt=1,uu(t,Bn(i,t.current)),$e=null;return}}catch(x){if(m!==null)throw $e=m,x;vt=1,uu(t,Bn(i,t.current)),$e=null;return}n.flags&32768?(Qe||u===1?t=!0:Xl||(Xe&536870912)!==0?t=!1:(ua=t=!0,(u===2||u===9||u===3||u===6)&&(u=bn.current,u!==null&&u.tag===13&&(u.flags|=16384))),lb(n,t)):Su(n)}function Su(t){var n=t;do{if((n.flags&32768)!==0){lb(n,ua);return}t=n.return;var i=j2(n.alternate,n,Ir);if(i!==null){$e=i;return}if(n=n.sibling,n!==null){$e=n;return}$e=n=t}while(n!==null);vt===0&&(vt=5)}function lb(t,n){do{var i=T2(t.alternate,t);if(i!==null){i.flags&=32767,$e=i;return}if(i=t.return,i!==null&&(i.flags|=32768,i.subtreeFlags=0,i.deletions=null),!n&&(t=t.sibling,t!==null)){$e=t;return}$e=t=i}while(t!==null);vt=6,$e=null}function ib(t,n,i,u,m,x,E,T,P){t.cancelPendingCommit=null;do ku();while(_t!==0);if((at&6)!==0)throw Error(l(327));if(n!==null){if(n===t.current)throw Error(l(177));if(x=n.lanes|n.childLanes,x|=$d,vd(t,i,x,E,T,P),t===dt&&($e=dt=null,Xe=0),Ql=n,fa=t,Br=i,Jf=x,ep=m,Kx=u,(n.subtreeFlags&10256)!==0||(n.flags&10256)!==0?(t.callbackNode=null,t.callbackPriority=0,U2(Te,function(){return db(),null})):(t.callbackNode=null,t.callbackPriority=0),u=(n.flags&13878)!==0,(n.subtreeFlags&13878)!==0||u){u=B.T,B.T=null,m=G.p,G.p=2,E=at,at|=4;try{_2(t,n,i)}finally{at=E,G.p=m,B.T=u}}_t=1,ob(),sb(),ub()}}function ob(){if(_t===1){_t=0;var t=fa,n=Ql,i=(n.flags&13878)!==0;if((n.subtreeFlags&13878)!==0||i){i=B.T,B.T=null;var u=G.p;G.p=2;var m=at;at|=4;try{Ux(n,t);var x=mp,E=Yg(t.containerInfo),T=x.focusedElem,P=x.selectionRange;if(E!==T&&T&&T.ownerDocument&&Gg(T.ownerDocument.documentElement,T)){if(P!==null&&Pd(T)){var K=P.start,ae=P.end;if(ae===void 0&&(ae=K),"selectionStart"in T)T.selectionStart=K,T.selectionEnd=Math.min(ae,T.value.length);else{var de=T.ownerDocument||document,Z=de&&de.defaultView||window;if(Z.getSelection){var ee=Z.getSelection(),we=T.textContent.length,Oe=Math.min(P.start,we),ct=P.end===void 0?Oe:Math.min(P.end,we);!ee.extend&&Oe>ct&&(E=ct,ct=Oe,Oe=E);var q=qg(T,Oe),H=qg(T,ct);if(q&&H&&(ee.rangeCount!==1||ee.anchorNode!==q.node||ee.anchorOffset!==q.offset||ee.focusNode!==H.node||ee.focusOffset!==H.offset)){var X=de.createRange();X.setStart(q.node,q.offset),ee.removeAllRanges(),Oe>ct?(ee.addRange(X),ee.extend(H.node,H.offset)):(X.setEnd(H.node,H.offset),ee.addRange(X))}}}}for(de=[],ee=T;ee=ee.parentNode;)ee.nodeType===1&&de.push({element:ee,left:ee.scrollLeft,top:ee.scrollTop});for(typeof T.focus=="function"&&T.focus(),T=0;T<de.length;T++){var se=de[T];se.element.scrollLeft=se.left,se.element.scrollTop=se.top}}zu=!!hp,mp=hp=null}finally{at=m,G.p=u,B.T=i}}t.current=n,_t=2}}function sb(){if(_t===2){_t=0;var t=fa,n=Ql,i=(n.flags&8772)!==0;if((n.subtreeFlags&8772)!==0||i){i=B.T,B.T=null;var u=G.p;G.p=2;var m=at;at|=4;try{Lx(t,n.alternate,n)}finally{at=m,G.p=u,B.T=i}}_t=3}}function ub(){if(_t===4||_t===3){_t=0,Oi();var t=fa,n=Ql,i=Br,u=Kx;(n.subtreeFlags&10256)!==0||(n.flags&10256)!==0?_t=5:(_t=0,Ql=fa=null,cb(t,t.pendingLanes));var m=t.pendingLanes;if(m===0&&(da=null),Ii(i),n=n.stateNode,yt&&typeof yt.onCommitFiberRoot=="function")try{yt.onCommitFiberRoot(He,n,void 0,(n.current.flags&128)===128)}catch{}if(u!==null){n=B.T,m=G.p,G.p=2,B.T=null;try{for(var x=t.onRecoverableError,E=0;E<u.length;E++){var T=u[E];x(T.value,{componentStack:T.stack})}}finally{B.T=n,G.p=m}}(Br&3)!==0&&ku(),ur(t),m=t.pendingLanes,(i&261930)!==0&&(m&42)!==0?t===tp?yo++:(yo=0,tp=t):yo=0,xo(0)}}function cb(t,n){(t.pooledCacheLanes&=n)===0&&(n=t.pooledCache,n!=null&&(t.pooledCache=null,Zi(n)))}function ku(){return ob(),sb(),ub(),db()}function db(){if(_t!==5)return!1;var t=fa,n=Jf;Jf=0;var i=Ii(Br),u=B.T,m=G.p;try{G.p=32>i?32:i,B.T=null,i=ep,ep=null;var x=fa,E=Br;if(_t=0,Ql=fa=null,Br=0,(at&6)!==0)throw Error(l(331));var T=at;if(at|=4,Gx(x.current),Vx(x,x.current,E,i),at=T,xo(0,!1),yt&&typeof yt.onPostCommitFiberRoot=="function")try{yt.onPostCommitFiberRoot(He,x)}catch{}return!0}finally{G.p=m,B.T=u,cb(t,n)}}function fb(t,n,i){n=Bn(i,n),n=Of(t.stateNode,n,2),t=la(t,n,2),t!==null&&(Ye(t,2),ur(t))}function ot(t,n,i){if(t.tag===3)fb(t,t,i);else for(;n!==null;){if(n.tag===3){fb(n,t,i);break}else if(n.tag===1){var u=n.stateNode;if(typeof n.type.getDerivedStateFromError=="function"||typeof u.componentDidCatch=="function"&&(da===null||!da.has(u))){t=Bn(i,t),i=px(2),u=la(n,i,2),u!==null&&(hx(i,u,n,t),Ye(u,2),ur(u));break}}n=n.return}}function ap(t,n,i){var u=t.pingCache;if(u===null){u=t.pingCache=new O2;var m=new Set;u.set(n,m)}else m=u.get(n),m===void 0&&(m=new Set,u.set(n,m));m.has(i)||(Qf=!0,m.add(i),t=B2.bind(null,t,n,i),n.then(t,t))}function B2(t,n,i){var u=t.pingCache;u!==null&&u.delete(n),t.pingedLanes|=t.suspendedLanes&i,t.warmLanes&=~i,dt===t&&(Xe&i)===i&&(vt===4||vt===3&&(Xe&62914560)===Xe&&300>Dt()-yu?(at&2)===0&&Zl(t,0):Zf|=i,Kl===Xe&&(Kl=0)),ur(t)}function pb(t,n){n===0&&(n=As()),t=Ga(t,n),t!==null&&(Ye(t,n),ur(t))}function P2(t){var n=t.memoizedState,i=0;n!==null&&(i=n.retryLane),pb(t,i)}function F2(t,n){var i=0;switch(t.tag){case 31:case 13:var u=t.stateNode,m=t.memoizedState;m!==null&&(i=m.retryLane);break;case 19:u=t.stateNode;break;case 22:u=t.stateNode._retryCache;break;default:throw Error(l(314))}u!==null&&u.delete(n),pb(t,i)}function U2(t,n){return an(t,n)}var Eu=null,Jl=null,lp=!1,Cu=!1,ip=!1,ha=0;function ur(t){t!==Jl&&t.next===null&&(Jl===null?Eu=Jl=t:Jl=Jl.next=t),Cu=!0,lp||(lp=!0,V2())}function xo(t,n){if(!ip&&Cu){ip=!0;do for(var i=!1,u=Eu;u!==null;){if(t!==0){var m=u.pendingLanes;if(m===0)var x=0;else{var E=u.suspendedLanes,T=u.pingedLanes;x=(1<<31-lt(42|t)+1)-1,x&=m&~(E&~T),x=x&201326741?x&201326741|1:x?x|2:0}x!==0&&(i=!0,yb(u,x))}else x=Xe,x=Ba(u,u===dt?x:0,u.cancelPendingCommit!==null||u.timeoutHandle!==-1),(x&3)===0||Pa(u,x)||(i=!0,yb(u,x));u=u.next}while(i);ip=!1}}function H2(){hb()}function hb(){Cu=lp=!1;var t=0;ha!==0&&J2()&&(t=ha);for(var n=Dt(),i=null,u=Eu;u!==null;){var m=u.next,x=mb(u,n);x===0?(u.next=null,i===null?Eu=m:i.next=m,m===null&&(Jl=i)):(i=u,(t!==0||(x&3)!==0)&&(Cu=!0)),u=m}_t!==0&&_t!==5||xo(t),ha!==0&&(ha=0)}function mb(t,n){for(var i=t.suspendedLanes,u=t.pingedLanes,m=t.expirationTimes,x=t.pendingLanes&-62914561;0<x;){var E=31-lt(x),T=1<<E,P=m[E];P===-1?((T&i)===0||(T&u)!==0)&&(m[E]=bd(T,n)):P<=n&&(t.expiredLanes|=T),x&=~T}if(n=dt,i=Xe,i=Ba(t,t===n?i:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),u=t.callbackNode,i===0||t===n&&(it===2||it===9)||t.cancelPendingCommit!==null)return u!==null&&u!==null&&On(u),t.callbackNode=null,t.callbackPriority=0;if((i&3)===0||Pa(t,i)){if(n=i&-i,n===t.callbackPriority)return n;switch(u!==null&&On(u),Ii(i)){case 2:case 8:i=xe;break;case 32:i=Te;break;case 268435456:i=rt;break;default:i=Te}return u=gb.bind(null,t),i=an(i,u),t.callbackPriority=n,t.callbackNode=i,n}return u!==null&&u!==null&&On(u),t.callbackPriority=2,t.callbackNode=null,2}function gb(t,n){if(_t!==0&&_t!==5)return t.callbackNode=null,t.callbackPriority=0,null;var i=t.callbackNode;if(ku()&&t.callbackNode!==i)return null;var u=Xe;return u=Ba(t,t===dt?u:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),u===0?null:(Zx(t,u,n),mb(t,Dt()),t.callbackNode!=null&&t.callbackNode===i?gb.bind(null,t):null)}function yb(t,n){if(ku())return null;Zx(t,n,!0)}function V2(){tA(function(){(at&6)!==0?an(oe,H2):hb()})}function op(){if(ha===0){var t=Bl;t===0&&(t=Dn,Dn<<=1,(Dn&261888)===0&&(Dn=256)),ha=t}return ha}function xb(t){return t==null||typeof t=="symbol"||typeof t=="boolean"?null:typeof t=="function"?t:Os(""+t)}function bb(t,n){var i=n.ownerDocument.createElement("input");return i.name=n.name,i.value=n.value,t.id&&i.setAttribute("form",t.id),n.parentNode.insertBefore(i,n),t=new FormData(t),i.parentNode.removeChild(i),t}function $2(t,n,i,u,m){if(n==="submit"&&i&&i.stateNode===m){var x=xb((m[Xt]||null).action),E=u.submitter;E&&(n=(n=E[Xt]||null)?xb(n.formAction):E.getAttribute("formAction"),n!==null&&(x=n,E=null));var T=new Is("action","action",null,u,m);t.push({event:T,listeners:[{instance:null,listener:function(){if(u.defaultPrevented){if(ha!==0){var P=E?bb(m,E):new FormData(m);Nf(i,{pending:!0,data:P,method:m.method,action:x},null,P)}}else typeof x=="function"&&(T.preventDefault(),P=E?bb(m,E):new FormData(m),Nf(i,{pending:!0,data:P,method:m.method,action:x},x,P))},currentTarget:m}]})}}for(var sp=0;sp<Vd.length;sp++){var up=Vd[sp],q2=up.toLowerCase(),G2=up[0].toUpperCase()+up.slice(1);Qn(q2,"on"+G2)}Qn(Qg,"onAnimationEnd"),Qn(Zg,"onAnimationIteration"),Qn(Wg,"onAnimationStart"),Qn("dblclick","onDoubleClick"),Qn("focusin","onFocus"),Qn("focusout","onBlur"),Qn(s2,"onTransitionRun"),Qn(u2,"onTransitionStart"),Qn(c2,"onTransitionCancel"),Qn(Jg,"onTransitionEnd"),pe("onMouseEnter",["mouseout","mouseover"]),pe("onMouseLeave",["mouseout","mouseover"]),pe("onPointerEnter",["pointerout","pointerover"]),pe("onPointerLeave",["pointerout","pointerover"]),Ae("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Ae("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Ae("onBeforeInput",["compositionend","keypress","textInput","paste"]),Ae("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Ae("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Ae("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var bo="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(" "),Y2=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(bo));function vb(t,n){n=(n&4)!==0;for(var i=0;i<t.length;i++){var u=t[i],m=u.event;u=u.listeners;e:{var x=void 0;if(n)for(var E=u.length-1;0<=E;E--){var T=u[E],P=T.instance,K=T.currentTarget;if(T=T.listener,P!==x&&m.isPropagationStopped())break e;x=T,m.currentTarget=K;try{x(m)}catch(ae){Fs(ae)}m.currentTarget=null,x=P}else for(E=0;E<u.length;E++){if(T=u[E],P=T.instance,K=T.currentTarget,T=T.listener,P!==x&&m.isPropagationStopped())break e;x=T,m.currentTarget=K;try{x(m)}catch(ae){Fs(ae)}m.currentTarget=null,x=P}}}}function qe(t,n){var i=n[Bi];i===void 0&&(i=n[Bi]=new Set);var u=t+"__bubble";i.has(u)||(wb(n,t,2,!1),i.add(u))}function cp(t,n,i){var u=0;n&&(u|=4),wb(i,t,u,n)}var Au="_reactListening"+Math.random().toString(36).slice(2);function dp(t){if(!t[Au]){t[Au]=!0,Pi.forEach(function(i){i!=="selectionchange"&&(Y2.has(i)||cp(i,!1,t),cp(i,!0,t))});var n=t.nodeType===9?t:t.ownerDocument;n===null||n[Au]||(n[Au]=!0,cp("selectionchange",!1,n))}}function wb(t,n,i,u){switch(Qb(n)){case 2:var m=wA;break;case 8:m=SA;break;default:m=Ap}i=m.bind(null,n,i,t),m=void 0,!_d||n!=="touchstart"&&n!=="touchmove"&&n!=="wheel"||(m=!0),u?m!==void 0?t.addEventListener(n,i,{capture:!0,passive:m}):t.addEventListener(n,i,!0):m!==void 0?t.addEventListener(n,i,{passive:m}):t.addEventListener(n,i,!1)}function fp(t,n,i,u,m){var x=u;if((n&1)===0&&(n&2)===0&&u!==null)e:for(;;){if(u===null)return;var E=u.tag;if(E===3||E===4){var T=u.stateNode.containerInfo;if(T===m)break;if(E===4)for(E=u.return;E!==null;){var P=E.tag;if((P===3||P===4)&&E.stateNode.containerInfo===m)return;E=E.return}for(;T!==null;){if(E=Zr(T),E===null)return;if(P=E.tag,P===5||P===6||P===26||P===27){u=x=E;continue e}T=T.parentNode}}u=u.return}Ag(function(){var K=x,ae=jd(i),de=[];e:{var Z=ey.get(t);if(Z!==void 0){var ee=Is,we=t;switch(t){case"keypress":if(zs(i)===0)break e;case"keydown":case"keyup":ee=FC;break;case"focusin":we="focus",ee=Dd;break;case"focusout":we="blur",ee=Dd;break;case"beforeblur":case"afterblur":ee=Dd;break;case"click":if(i.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":ee=Tg;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":ee=jC;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":ee=VC;break;case Qg:case Zg:case Wg:ee=RC;break;case Jg:ee=qC;break;case"scroll":case"scrollend":ee=AC;break;case"wheel":ee=YC;break;case"copy":case"cut":case"paste":ee=OC;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":ee=Rg;break;case"toggle":case"beforetoggle":ee=KC}var Oe=(n&4)!==0,ct=!Oe&&(t==="scroll"||t==="scrollend"),q=Oe?Z!==null?Z+"Capture":null:Z;Oe=[];for(var H=K,X;H!==null;){var se=H;if(X=se.stateNode,se=se.tag,se!==5&&se!==26&&se!==27||X===null||q===null||(se=Fi(H,q),se!=null&&Oe.push(vo(H,se,X))),ct)break;H=H.return}0<Oe.length&&(Z=new ee(Z,we,null,i,ae),de.push({event:Z,listeners:Oe}))}}if((n&7)===0){e:{if(Z=t==="mouseover"||t==="pointerover",ee=t==="mouseout"||t==="pointerout",Z&&i!==Nd&&(we=i.relatedTarget||i.fromElement)&&(Zr(we)||we[Qr]))break e;if((ee||Z)&&(Z=ae.window===ae?ae:(Z=ae.ownerDocument)?Z.defaultView||Z.parentWindow:window,ee?(we=i.relatedTarget||i.toElement,ee=K,we=we?Zr(we):null,we!==null&&(ct=s(we),Oe=we.tag,we!==ct||Oe!==5&&Oe!==27&&Oe!==6)&&(we=null)):(ee=null,we=K),ee!==we)){if(Oe=Tg,se="onMouseLeave",q="onMouseEnter",H="mouse",(t==="pointerout"||t==="pointerover")&&(Oe=Rg,se="onPointerLeave",q="onPointerEnter",H="pointer"),ct=ee==null?Z:Ha(ee),X=we==null?Z:Ha(we),Z=new Oe(se,H+"leave",ee,i,ae),Z.target=ct,Z.relatedTarget=X,se=null,Zr(ae)===K&&(Oe=new Oe(q,H+"enter",we,i,ae),Oe.target=X,Oe.relatedTarget=ct,se=Oe),ct=se,ee&&we)t:{for(Oe=X2,q=ee,H=we,X=0,se=q;se;se=Oe(se))X++;se=0;for(var je=H;je;je=Oe(je))se++;for(;0<X-se;)q=Oe(q),X--;for(;0<se-X;)H=Oe(H),se--;for(;X--;){if(q===H||H!==null&&q===H.alternate){Oe=q;break t}q=Oe(q),H=Oe(H)}Oe=null}else Oe=null;ee!==null&&Sb(de,Z,ee,Oe,!1),we!==null&&ct!==null&&Sb(de,ct,we,Oe,!0)}}e:{if(Z=K?Ha(K):window,ee=Z.nodeName&&Z.nodeName.toLowerCase(),ee==="select"||ee==="input"&&Z.type==="file")var et=Pg;else if(Ig(Z))if(Fg)et=l2;else{et=r2;var Ee=n2}else ee=Z.nodeName,!ee||ee.toLowerCase()!=="input"||Z.type!=="checkbox"&&Z.type!=="radio"?K&&Ad(K.elementType)&&(et=Pg):et=a2;if(et&&(et=et(t,K))){Bg(de,et,i,ae);break e}Ee&&Ee(t,Z,K),t==="focusout"&&K&&Z.type==="number"&&K.memoizedProps.value!=null&&Cd(Z,"number",Z.value)}switch(Ee=K?Ha(K):window,t){case"focusin":(Ig(Ee)||Ee.contentEditable==="true")&&(_l=Ee,Fd=K,Xi=null);break;case"focusout":Xi=Fd=_l=null;break;case"mousedown":Ud=!0;break;case"contextmenu":case"mouseup":case"dragend":Ud=!1,Xg(de,i,ae);break;case"selectionchange":if(o2)break;case"keydown":case"keyup":Xg(de,i,ae)}var Pe;if(Ld)e:{switch(t){case"compositionstart":var Ke="onCompositionStart";break e;case"compositionend":Ke="onCompositionEnd";break e;case"compositionupdate":Ke="onCompositionUpdate";break e}Ke=void 0}else Tl?zg(t,i)&&(Ke="onCompositionEnd"):t==="keydown"&&i.keyCode===229&&(Ke="onCompositionStart");Ke&&(Mg&&i.locale!=="ko"&&(Tl||Ke!=="onCompositionStart"?Ke==="onCompositionEnd"&&Tl&&(Pe=Ng()):(Wr=ae,Rd="value"in Wr?Wr.value:Wr.textContent,Tl=!0)),Ee=Nu(K,Ke),0<Ee.length&&(Ke=new _g(Ke,t,null,i,ae),de.push({event:Ke,listeners:Ee}),Pe?Ke.data=Pe:(Pe=Lg(i),Pe!==null&&(Ke.data=Pe)))),(Pe=ZC?WC(t,i):JC(t,i))&&(Ke=Nu(K,"onBeforeInput"),0<Ke.length&&(Ee=new _g("onBeforeInput","beforeinput",null,i,ae),de.push({event:Ee,listeners:Ke}),Ee.data=Pe)),$2(de,t,K,i,ae)}vb(de,n)})}function vo(t,n,i){return{instance:t,listener:n,currentTarget:i}}function Nu(t,n){for(var i=n+"Capture",u=[];t!==null;){var m=t,x=m.stateNode;if(m=m.tag,m!==5&&m!==26&&m!==27||x===null||(m=Fi(t,i),m!=null&&u.unshift(vo(t,m,x)),m=Fi(t,n),m!=null&&u.push(vo(t,m,x))),t.tag===3)return u;t=t.return}return[]}function X2(t){if(t===null)return null;do t=t.return;while(t&&t.tag!==5&&t.tag!==27);return t||null}function Sb(t,n,i,u,m){for(var x=n._reactName,E=[];i!==null&&i!==u;){var T=i,P=T.alternate,K=T.stateNode;if(T=T.tag,P!==null&&P===u)break;T!==5&&T!==26&&T!==27||K===null||(P=K,m?(K=Fi(i,x),K!=null&&E.unshift(vo(i,K,P))):m||(K=Fi(i,x),K!=null&&E.push(vo(i,K,P)))),i=i.return}E.length!==0&&t.push({event:n,listeners:E})}var K2=/\r\n?/g,Q2=/\u0000|\uFFFD/g;function kb(t){return(typeof t=="string"?t:""+t).replace(K2,`
49
- `).replace(Q2,"")}function Eb(t,n){return n=kb(n),kb(t)===n}function ut(t,n,i,u,m,x){switch(i){case"children":typeof u=="string"?n==="body"||n==="textarea"&&u===""||Al(t,u):(typeof u=="number"||typeof u=="bigint")&&n!=="body"&&Al(t,""+u);break;case"className":zn(t,"class",u);break;case"tabIndex":zn(t,"tabindex",u);break;case"dir":case"role":case"viewBox":case"width":case"height":zn(t,i,u);break;case"style":Eg(t,u,x);break;case"data":if(n!=="object"){zn(t,"data",u);break}case"src":case"href":if(u===""&&(n!=="a"||i!=="href")){t.removeAttribute(i);break}if(u==null||typeof u=="function"||typeof u=="symbol"||typeof u=="boolean"){t.removeAttribute(i);break}u=Os(""+u),t.setAttribute(i,u);break;case"action":case"formAction":if(typeof u=="function"){t.setAttribute(i,"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 x=="function"&&(i==="formAction"?(n!=="input"&&ut(t,n,"name",m.name,m,null),ut(t,n,"formEncType",m.formEncType,m,null),ut(t,n,"formMethod",m.formMethod,m,null),ut(t,n,"formTarget",m.formTarget,m,null)):(ut(t,n,"encType",m.encType,m,null),ut(t,n,"method",m.method,m,null),ut(t,n,"target",m.target,m,null)));if(u==null||typeof u=="symbol"||typeof u=="boolean"){t.removeAttribute(i);break}u=Os(""+u),t.setAttribute(i,u);break;case"onClick":u!=null&&(t.onclick=kr);break;case"onScroll":u!=null&&qe("scroll",t);break;case"onScrollEnd":u!=null&&qe("scrollend",t);break;case"dangerouslySetInnerHTML":if(u!=null){if(typeof u!="object"||!("__html"in u))throw Error(l(61));if(i=u.__html,i!=null){if(m.children!=null)throw Error(l(60));t.innerHTML=i}}break;case"multiple":t.multiple=u&&typeof u!="function"&&typeof u!="symbol";break;case"muted":t.muted=u&&typeof u!="function"&&typeof u!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(u==null||typeof u=="function"||typeof u=="boolean"||typeof u=="symbol"){t.removeAttribute("xlink:href");break}i=Os(""+u),t.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",i);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":u!=null&&typeof u!="function"&&typeof u!="symbol"?t.setAttribute(i,""+u):t.removeAttribute(i);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":u&&typeof u!="function"&&typeof u!="symbol"?t.setAttribute(i,""):t.removeAttribute(i);break;case"capture":case"download":u===!0?t.setAttribute(i,""):u!==!1&&u!=null&&typeof u!="function"&&typeof u!="symbol"?t.setAttribute(i,u):t.removeAttribute(i);break;case"cols":case"rows":case"size":case"span":u!=null&&typeof u!="function"&&typeof u!="symbol"&&!isNaN(u)&&1<=u?t.setAttribute(i,u):t.removeAttribute(i);break;case"rowSpan":case"start":u==null||typeof u=="function"||typeof u=="symbol"||isNaN(u)?t.removeAttribute(i):t.setAttribute(i,u);break;case"popover":qe("beforetoggle",t),qe("toggle",t),Kt(t,"popover",u);break;case"xlinkActuate":gn(t,"http://www.w3.org/1999/xlink","xlink:actuate",u);break;case"xlinkArcrole":gn(t,"http://www.w3.org/1999/xlink","xlink:arcrole",u);break;case"xlinkRole":gn(t,"http://www.w3.org/1999/xlink","xlink:role",u);break;case"xlinkShow":gn(t,"http://www.w3.org/1999/xlink","xlink:show",u);break;case"xlinkTitle":gn(t,"http://www.w3.org/1999/xlink","xlink:title",u);break;case"xlinkType":gn(t,"http://www.w3.org/1999/xlink","xlink:type",u);break;case"xmlBase":gn(t,"http://www.w3.org/XML/1998/namespace","xml:base",u);break;case"xmlLang":gn(t,"http://www.w3.org/XML/1998/namespace","xml:lang",u);break;case"xmlSpace":gn(t,"http://www.w3.org/XML/1998/namespace","xml:space",u);break;case"is":Kt(t,"is",u);break;case"innerText":case"textContent":break;default:(!(2<i.length)||i[0]!=="o"&&i[0]!=="O"||i[1]!=="n"&&i[1]!=="N")&&(i=EC.get(i)||i,Kt(t,i,u))}}function pp(t,n,i,u,m,x){switch(i){case"style":Eg(t,u,x);break;case"dangerouslySetInnerHTML":if(u!=null){if(typeof u!="object"||!("__html"in u))throw Error(l(61));if(i=u.__html,i!=null){if(m.children!=null)throw Error(l(60));t.innerHTML=i}}break;case"children":typeof u=="string"?Al(t,u):(typeof u=="number"||typeof u=="bigint")&&Al(t,""+u);break;case"onScroll":u!=null&&qe("scroll",t);break;case"onScrollEnd":u!=null&&qe("scrollend",t);break;case"onClick":u!=null&&(t.onclick=kr);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!$.hasOwnProperty(i))e:{if(i[0]==="o"&&i[1]==="n"&&(m=i.endsWith("Capture"),n=i.slice(2,m?i.length-7:void 0),x=t[Xt]||null,x=x!=null?x[i]:null,typeof x=="function"&&t.removeEventListener(n,x,m),typeof u=="function")){typeof x!="function"&&x!==null&&(i in t?t[i]=null:t.hasAttribute(i)&&t.removeAttribute(i)),t.addEventListener(n,u,m);break e}i in t?t[i]=u:u===!0?t.setAttribute(i,""):Kt(t,i,u)}}}function $t(t,n,i){switch(n){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":qe("error",t),qe("load",t);var u=!1,m=!1,x;for(x in i)if(i.hasOwnProperty(x)){var E=i[x];if(E!=null)switch(x){case"src":u=!0;break;case"srcSet":m=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(l(137,n));default:ut(t,n,x,E,i,null)}}m&&ut(t,n,"srcSet",i.srcSet,i,null),u&&ut(t,n,"src",i.src,i,null);return;case"input":qe("invalid",t);var T=x=E=m=null,P=null,K=null;for(u in i)if(i.hasOwnProperty(u)){var ae=i[u];if(ae!=null)switch(u){case"name":m=ae;break;case"type":E=ae;break;case"checked":P=ae;break;case"defaultChecked":K=ae;break;case"value":x=ae;break;case"defaultValue":T=ae;break;case"children":case"dangerouslySetInnerHTML":if(ae!=null)throw Error(l(137,n));break;default:ut(t,n,u,ae,i,null)}}vg(t,x,T,P,K,E,m,!1);return;case"select":qe("invalid",t),u=E=x=null;for(m in i)if(i.hasOwnProperty(m)&&(T=i[m],T!=null))switch(m){case"value":x=T;break;case"defaultValue":E=T;break;case"multiple":u=T;default:ut(t,n,m,T,i,null)}n=x,i=E,t.multiple=!!u,n!=null?Cl(t,!!u,n,!1):i!=null&&Cl(t,!!u,i,!0);return;case"textarea":qe("invalid",t),x=m=u=null;for(E in i)if(i.hasOwnProperty(E)&&(T=i[E],T!=null))switch(E){case"value":u=T;break;case"defaultValue":m=T;break;case"children":x=T;break;case"dangerouslySetInnerHTML":if(T!=null)throw Error(l(91));break;default:ut(t,n,E,T,i,null)}Sg(t,u,m,x);return;case"option":for(P in i)if(i.hasOwnProperty(P)&&(u=i[P],u!=null))switch(P){case"selected":t.selected=u&&typeof u!="function"&&typeof u!="symbol";break;default:ut(t,n,P,u,i,null)}return;case"dialog":qe("beforetoggle",t),qe("toggle",t),qe("cancel",t),qe("close",t);break;case"iframe":case"object":qe("load",t);break;case"video":case"audio":for(u=0;u<bo.length;u++)qe(bo[u],t);break;case"image":qe("error",t),qe("load",t);break;case"details":qe("toggle",t);break;case"embed":case"source":case"link":qe("error",t),qe("load",t);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(K in i)if(i.hasOwnProperty(K)&&(u=i[K],u!=null))switch(K){case"children":case"dangerouslySetInnerHTML":throw Error(l(137,n));default:ut(t,n,K,u,i,null)}return;default:if(Ad(n)){for(ae in i)i.hasOwnProperty(ae)&&(u=i[ae],u!==void 0&&pp(t,n,ae,u,i,void 0));return}}for(T in i)i.hasOwnProperty(T)&&(u=i[T],u!=null&&ut(t,n,T,u,i,null))}function Z2(t,n,i,u){switch(n){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var m=null,x=null,E=null,T=null,P=null,K=null,ae=null;for(ee in i){var de=i[ee];if(i.hasOwnProperty(ee)&&de!=null)switch(ee){case"checked":break;case"value":break;case"defaultValue":P=de;default:u.hasOwnProperty(ee)||ut(t,n,ee,null,u,de)}}for(var Z in u){var ee=u[Z];if(de=i[Z],u.hasOwnProperty(Z)&&(ee!=null||de!=null))switch(Z){case"type":x=ee;break;case"name":m=ee;break;case"checked":K=ee;break;case"defaultChecked":ae=ee;break;case"value":E=ee;break;case"defaultValue":T=ee;break;case"children":case"dangerouslySetInnerHTML":if(ee!=null)throw Error(l(137,n));break;default:ee!==de&&ut(t,n,Z,ee,u,de)}}Ed(t,E,T,P,K,ae,x,m);return;case"select":ee=E=T=Z=null;for(x in i)if(P=i[x],i.hasOwnProperty(x)&&P!=null)switch(x){case"value":break;case"multiple":ee=P;default:u.hasOwnProperty(x)||ut(t,n,x,null,u,P)}for(m in u)if(x=u[m],P=i[m],u.hasOwnProperty(m)&&(x!=null||P!=null))switch(m){case"value":Z=x;break;case"defaultValue":T=x;break;case"multiple":E=x;default:x!==P&&ut(t,n,m,x,u,P)}n=T,i=E,u=ee,Z!=null?Cl(t,!!i,Z,!1):!!u!=!!i&&(n!=null?Cl(t,!!i,n,!0):Cl(t,!!i,i?[]:"",!1));return;case"textarea":ee=Z=null;for(T in i)if(m=i[T],i.hasOwnProperty(T)&&m!=null&&!u.hasOwnProperty(T))switch(T){case"value":break;case"children":break;default:ut(t,n,T,null,u,m)}for(E in u)if(m=u[E],x=i[E],u.hasOwnProperty(E)&&(m!=null||x!=null))switch(E){case"value":Z=m;break;case"defaultValue":ee=m;break;case"children":break;case"dangerouslySetInnerHTML":if(m!=null)throw Error(l(91));break;default:m!==x&&ut(t,n,E,m,u,x)}wg(t,Z,ee);return;case"option":for(var we in i)if(Z=i[we],i.hasOwnProperty(we)&&Z!=null&&!u.hasOwnProperty(we))switch(we){case"selected":t.selected=!1;break;default:ut(t,n,we,null,u,Z)}for(P in u)if(Z=u[P],ee=i[P],u.hasOwnProperty(P)&&Z!==ee&&(Z!=null||ee!=null))switch(P){case"selected":t.selected=Z&&typeof Z!="function"&&typeof Z!="symbol";break;default:ut(t,n,P,Z,u,ee)}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 Oe in i)Z=i[Oe],i.hasOwnProperty(Oe)&&Z!=null&&!u.hasOwnProperty(Oe)&&ut(t,n,Oe,null,u,Z);for(K in u)if(Z=u[K],ee=i[K],u.hasOwnProperty(K)&&Z!==ee&&(Z!=null||ee!=null))switch(K){case"children":case"dangerouslySetInnerHTML":if(Z!=null)throw Error(l(137,n));break;default:ut(t,n,K,Z,u,ee)}return;default:if(Ad(n)){for(var ct in i)Z=i[ct],i.hasOwnProperty(ct)&&Z!==void 0&&!u.hasOwnProperty(ct)&&pp(t,n,ct,void 0,u,Z);for(ae in u)Z=u[ae],ee=i[ae],!u.hasOwnProperty(ae)||Z===ee||Z===void 0&&ee===void 0||pp(t,n,ae,Z,u,ee);return}}for(var q in i)Z=i[q],i.hasOwnProperty(q)&&Z!=null&&!u.hasOwnProperty(q)&&ut(t,n,q,null,u,Z);for(de in u)Z=u[de],ee=i[de],!u.hasOwnProperty(de)||Z===ee||Z==null&&ee==null||ut(t,n,de,Z,u,ee)}function Cb(t){switch(t){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function W2(){if(typeof performance.getEntriesByType=="function"){for(var t=0,n=0,i=performance.getEntriesByType("resource"),u=0;u<i.length;u++){var m=i[u],x=m.transferSize,E=m.initiatorType,T=m.duration;if(x&&T&&Cb(E)){for(E=0,T=m.responseEnd,u+=1;u<i.length;u++){var P=i[u],K=P.startTime;if(K>T)break;var ae=P.transferSize,de=P.initiatorType;ae&&Cb(de)&&(P=P.responseEnd,E+=ae*(P<T?1:(T-K)/(P-K)))}if(--u,n+=8*(x+E)/(m.duration/1e3),t++,10<t)break}}if(0<t)return n/t/1e6}return navigator.connection&&(t=navigator.connection.downlink,typeof t=="number")?t:5}var hp=null,mp=null;function ju(t){return t.nodeType===9?t:t.ownerDocument}function Ab(t){switch(t){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function Nb(t,n){if(t===0)switch(n){case"svg":return 1;case"math":return 2;default:return 0}return t===1&&n==="foreignObject"?0:t}function gp(t,n){return t==="textarea"||t==="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 yp=null;function J2(){var t=window.event;return t&&t.type==="popstate"?t===yp?!1:(yp=t,!0):(yp=null,!1)}var jb=typeof setTimeout=="function"?setTimeout:void 0,eA=typeof clearTimeout=="function"?clearTimeout:void 0,Tb=typeof Promise=="function"?Promise:void 0,tA=typeof queueMicrotask=="function"?queueMicrotask:typeof Tb<"u"?function(t){return Tb.resolve(null).then(t).catch(nA)}:jb;function nA(t){setTimeout(function(){throw t})}function ma(t){return t==="head"}function _b(t,n){var i=n,u=0;do{var m=i.nextSibling;if(t.removeChild(i),m&&m.nodeType===8)if(i=m.data,i==="/$"||i==="/&"){if(u===0){t.removeChild(m),ri(n);return}u--}else if(i==="$"||i==="$?"||i==="$~"||i==="$!"||i==="&")u++;else if(i==="html")wo(t.ownerDocument.documentElement);else if(i==="head"){i=t.ownerDocument.head,wo(i);for(var x=i.firstChild;x;){var E=x.nextSibling,T=x.nodeName;x[Ua]||T==="SCRIPT"||T==="STYLE"||T==="LINK"&&x.rel.toLowerCase()==="stylesheet"||i.removeChild(x),x=E}}else i==="body"&&wo(t.ownerDocument.body);i=m}while(i);ri(n)}function Rb(t,n){var i=t;t=0;do{var u=i.nextSibling;if(i.nodeType===1?n?(i._stashedDisplay=i.style.display,i.style.display="none"):(i.style.display=i._stashedDisplay||"",i.getAttribute("style")===""&&i.removeAttribute("style")):i.nodeType===3&&(n?(i._stashedText=i.nodeValue,i.nodeValue=""):i.nodeValue=i._stashedText||""),u&&u.nodeType===8)if(i=u.data,i==="/$"){if(t===0)break;t--}else i!=="$"&&i!=="$?"&&i!=="$~"&&i!=="$!"||t++;i=u}while(i)}function xp(t){var n=t.firstChild;for(n&&n.nodeType===10&&(n=n.nextSibling);n;){var i=n;switch(n=n.nextSibling,i.nodeName){case"HTML":case"HEAD":case"BODY":xp(i),El(i);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(i.rel.toLowerCase()==="stylesheet")continue}t.removeChild(i)}}function rA(t,n,i,u){for(;t.nodeType===1;){var m=i;if(t.nodeName.toLowerCase()!==n.toLowerCase()){if(!u&&(t.nodeName!=="INPUT"||t.type!=="hidden"))break}else if(u){if(!t[Ua])switch(n){case"meta":if(!t.hasAttribute("itemprop"))break;return t;case"link":if(x=t.getAttribute("rel"),x==="stylesheet"&&t.hasAttribute("data-precedence"))break;if(x!==m.rel||t.getAttribute("href")!==(m.href==null||m.href===""?null:m.href)||t.getAttribute("crossorigin")!==(m.crossOrigin==null?null:m.crossOrigin)||t.getAttribute("title")!==(m.title==null?null:m.title))break;return t;case"style":if(t.hasAttribute("data-precedence"))break;return t;case"script":if(x=t.getAttribute("src"),(x!==(m.src==null?null:m.src)||t.getAttribute("type")!==(m.type==null?null:m.type)||t.getAttribute("crossorigin")!==(m.crossOrigin==null?null:m.crossOrigin))&&x&&t.hasAttribute("async")&&!t.hasAttribute("itemprop"))break;return t;default:return t}}else if(n==="input"&&t.type==="hidden"){var x=m.name==null?null:""+m.name;if(m.type==="hidden"&&t.getAttribute("name")===x)return t}else return t;if(t=Vn(t.nextSibling),t===null)break}return null}function aA(t,n,i){if(n==="")return null;for(;t.nodeType!==3;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!i||(t=Vn(t.nextSibling),t===null))return null;return t}function Mb(t,n){for(;t.nodeType!==8;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!n||(t=Vn(t.nextSibling),t===null))return null;return t}function bp(t){return t.data==="$?"||t.data==="$~"}function vp(t){return t.data==="$!"||t.data==="$?"&&t.ownerDocument.readyState!=="loading"}function lA(t,n){var i=t.ownerDocument;if(t.data==="$~")t._reactRetry=n;else if(t.data!=="$?"||i.readyState!=="loading")n();else{var u=function(){n(),i.removeEventListener("DOMContentLoaded",u)};i.addEventListener("DOMContentLoaded",u),t._reactRetry=u}}function Vn(t){for(;t!=null;t=t.nextSibling){var n=t.nodeType;if(n===1||n===3)break;if(n===8){if(n=t.data,n==="$"||n==="$!"||n==="$?"||n==="$~"||n==="&"||n==="F!"||n==="F")break;if(n==="/$"||n==="/&")return null}}return t}var wp=null;function Ob(t){t=t.nextSibling;for(var n=0;t;){if(t.nodeType===8){var i=t.data;if(i==="/$"||i==="/&"){if(n===0)return Vn(t.nextSibling);n--}else i!=="$"&&i!=="$!"&&i!=="$?"&&i!=="$~"&&i!=="&"||n++}t=t.nextSibling}return null}function Db(t){t=t.previousSibling;for(var n=0;t;){if(t.nodeType===8){var i=t.data;if(i==="$"||i==="$!"||i==="$?"||i==="$~"||i==="&"){if(n===0)return t;n--}else i!=="/$"&&i!=="/&"||n++}t=t.previousSibling}return null}function zb(t,n,i){switch(n=ju(i),t){case"html":if(t=n.documentElement,!t)throw Error(l(452));return t;case"head":if(t=n.head,!t)throw Error(l(453));return t;case"body":if(t=n.body,!t)throw Error(l(454));return t;default:throw Error(l(451))}}function wo(t){for(var n=t.attributes;n.length;)t.removeAttributeNode(n[0]);El(t)}var $n=new Map,Lb=new Set;function Tu(t){return typeof t.getRootNode=="function"?t.getRootNode():t.nodeType===9?t:t.ownerDocument}var Pr=G.d;G.d={f:iA,r:oA,D:sA,C:uA,L:cA,m:dA,X:pA,S:fA,M:hA};function iA(){var t=Pr.f(),n=vu();return t||n}function oA(t){var n=en(t);n!==null&&n.tag===5&&n.type==="form"?Jy(n):Pr.r(t)}var ei=typeof document>"u"?null:document;function Ib(t,n,i){var u=ei;if(u&&typeof n=="string"&&n){var m=Ln(n);m='link[rel="'+t+'"][href="'+m+'"]',typeof i=="string"&&(m+='[crossorigin="'+i+'"]'),Lb.has(m)||(Lb.add(m),t={rel:t,crossOrigin:i,href:n},u.querySelector(m)===null&&(n=u.createElement("link"),$t(n,"link",t),wt(n),u.head.appendChild(n)))}}function sA(t){Pr.D(t),Ib("dns-prefetch",t,null)}function uA(t,n){Pr.C(t,n),Ib("preconnect",t,n)}function cA(t,n,i){Pr.L(t,n,i);var u=ei;if(u&&t&&n){var m='link[rel="preload"][as="'+Ln(n)+'"]';n==="image"&&i&&i.imageSrcSet?(m+='[imagesrcset="'+Ln(i.imageSrcSet)+'"]',typeof i.imageSizes=="string"&&(m+='[imagesizes="'+Ln(i.imageSizes)+'"]')):m+='[href="'+Ln(t)+'"]';var x=m;switch(n){case"style":x=ti(t);break;case"script":x=ni(t)}$n.has(x)||(t=g({rel:"preload",href:n==="image"&&i&&i.imageSrcSet?void 0:t,as:n},i),$n.set(x,t),u.querySelector(m)!==null||n==="style"&&u.querySelector(So(x))||n==="script"&&u.querySelector(ko(x))||(n=u.createElement("link"),$t(n,"link",t),wt(n),u.head.appendChild(n)))}}function dA(t,n){Pr.m(t,n);var i=ei;if(i&&t){var u=n&&typeof n.as=="string"?n.as:"script",m='link[rel="modulepreload"][as="'+Ln(u)+'"][href="'+Ln(t)+'"]',x=m;switch(u){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":x=ni(t)}if(!$n.has(x)&&(t=g({rel:"modulepreload",href:t},n),$n.set(x,t),i.querySelector(m)===null)){switch(u){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(i.querySelector(ko(x)))return}u=i.createElement("link"),$t(u,"link",t),wt(u),i.head.appendChild(u)}}}function fA(t,n,i){Pr.S(t,n,i);var u=ei;if(u&&t){var m=wr(u).hoistableStyles,x=ti(t);n=n||"default";var E=m.get(x);if(!E){var T={loading:0,preload:null};if(E=u.querySelector(So(x)))T.loading=5;else{t=g({rel:"stylesheet",href:t,"data-precedence":n},i),(i=$n.get(x))&&Sp(t,i);var P=E=u.createElement("link");wt(P),$t(P,"link",t),P._p=new Promise(function(K,ae){P.onload=K,P.onerror=ae}),P.addEventListener("load",function(){T.loading|=1}),P.addEventListener("error",function(){T.loading|=2}),T.loading|=4,_u(E,n,u)}E={type:"stylesheet",instance:E,count:1,state:T},m.set(x,E)}}}function pA(t,n){Pr.X(t,n);var i=ei;if(i&&t){var u=wr(i).hoistableScripts,m=ni(t),x=u.get(m);x||(x=i.querySelector(ko(m)),x||(t=g({src:t,async:!0},n),(n=$n.get(m))&&kp(t,n),x=i.createElement("script"),wt(x),$t(x,"link",t),i.head.appendChild(x)),x={type:"script",instance:x,count:1,state:null},u.set(m,x))}}function hA(t,n){Pr.M(t,n);var i=ei;if(i&&t){var u=wr(i).hoistableScripts,m=ni(t),x=u.get(m);x||(x=i.querySelector(ko(m)),x||(t=g({src:t,async:!0,type:"module"},n),(n=$n.get(m))&&kp(t,n),x=i.createElement("script"),wt(x),$t(x,"link",t),i.head.appendChild(x)),x={type:"script",instance:x,count:1,state:null},u.set(m,x))}}function Bb(t,n,i,u){var m=(m=ie.current)?Tu(m):null;if(!m)throw Error(l(446));switch(t){case"meta":case"title":return null;case"style":return typeof i.precedence=="string"&&typeof i.href=="string"?(n=ti(i.href),i=wr(m).hoistableStyles,u=i.get(n),u||(u={type:"style",instance:null,count:0,state:null},i.set(n,u)),u):{type:"void",instance:null,count:0,state:null};case"link":if(i.rel==="stylesheet"&&typeof i.href=="string"&&typeof i.precedence=="string"){t=ti(i.href);var x=wr(m).hoistableStyles,E=x.get(t);if(E||(m=m.ownerDocument||m,E={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},x.set(t,E),(x=m.querySelector(So(t)))&&!x._p&&(E.instance=x,E.state.loading=5),$n.has(t)||(i={rel:"preload",as:"style",href:i.href,crossOrigin:i.crossOrigin,integrity:i.integrity,media:i.media,hrefLang:i.hrefLang,referrerPolicy:i.referrerPolicy},$n.set(t,i),x||mA(m,t,i,E.state))),n&&u===null)throw Error(l(528,""));return E}if(n&&u!==null)throw Error(l(529,""));return null;case"script":return n=i.async,i=i.src,typeof i=="string"&&n&&typeof n!="function"&&typeof n!="symbol"?(n=ni(i),i=wr(m).hoistableScripts,u=i.get(n),u||(u={type:"script",instance:null,count:0,state:null},i.set(n,u)),u):{type:"void",instance:null,count:0,state:null};default:throw Error(l(444,t))}}function ti(t){return'href="'+Ln(t)+'"'}function So(t){return'link[rel="stylesheet"]['+t+"]"}function Pb(t){return g({},t,{"data-precedence":t.precedence,precedence:null})}function mA(t,n,i,u){t.querySelector('link[rel="preload"][as="style"]['+n+"]")?u.loading=1:(n=t.createElement("link"),u.preload=n,n.addEventListener("load",function(){return u.loading|=1}),n.addEventListener("error",function(){return u.loading|=2}),$t(n,"link",i),wt(n),t.head.appendChild(n))}function ni(t){return'[src="'+Ln(t)+'"]'}function ko(t){return"script[async]"+t}function Fb(t,n,i){if(n.count++,n.instance===null)switch(n.type){case"style":var u=t.querySelector('style[data-href~="'+Ln(i.href)+'"]');if(u)return n.instance=u,wt(u),u;var m=g({},i,{"data-href":i.href,"data-precedence":i.precedence,href:null,precedence:null});return u=(t.ownerDocument||t).createElement("style"),wt(u),$t(u,"style",m),_u(u,i.precedence,t),n.instance=u;case"stylesheet":m=ti(i.href);var x=t.querySelector(So(m));if(x)return n.state.loading|=4,n.instance=x,wt(x),x;u=Pb(i),(m=$n.get(m))&&Sp(u,m),x=(t.ownerDocument||t).createElement("link"),wt(x);var E=x;return E._p=new Promise(function(T,P){E.onload=T,E.onerror=P}),$t(x,"link",u),n.state.loading|=4,_u(x,i.precedence,t),n.instance=x;case"script":return x=ni(i.src),(m=t.querySelector(ko(x)))?(n.instance=m,wt(m),m):(u=i,(m=$n.get(x))&&(u=g({},i),kp(u,m)),t=t.ownerDocument||t,m=t.createElement("script"),wt(m),$t(m,"link",u),t.head.appendChild(m),n.instance=m);case"void":return null;default:throw Error(l(443,n.type))}else n.type==="stylesheet"&&(n.state.loading&4)===0&&(u=n.instance,n.state.loading|=4,_u(u,i.precedence,t));return n.instance}function _u(t,n,i){for(var u=i.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),m=u.length?u[u.length-1]:null,x=m,E=0;E<u.length;E++){var T=u[E];if(T.dataset.precedence===n)x=T;else if(x!==m)break}x?x.parentNode.insertBefore(t,x.nextSibling):(n=i.nodeType===9?i.head:i,n.insertBefore(t,n.firstChild))}function Sp(t,n){t.crossOrigin==null&&(t.crossOrigin=n.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=n.referrerPolicy),t.title==null&&(t.title=n.title)}function kp(t,n){t.crossOrigin==null&&(t.crossOrigin=n.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=n.referrerPolicy),t.integrity==null&&(t.integrity=n.integrity)}var Ru=null;function Ub(t,n,i){if(Ru===null){var u=new Map,m=Ru=new Map;m.set(i,u)}else m=Ru,u=m.get(i),u||(u=new Map,m.set(i,u));if(u.has(t))return u;for(u.set(t,null),i=i.getElementsByTagName(t),m=0;m<i.length;m++){var x=i[m];if(!(x[Ua]||x[Et]||t==="link"&&x.getAttribute("rel")==="stylesheet")&&x.namespaceURI!=="http://www.w3.org/2000/svg"){var E=x.getAttribute(n)||"";E=t+E;var T=u.get(E);T?T.push(x):u.set(E,[x])}}return u}function Hb(t,n,i){t=t.ownerDocument||t,t.head.insertBefore(i,n==="title"?t.querySelector("head > title"):null)}function gA(t,n,i){if(i===1||n.itemProp!=null)return!1;switch(t){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 t=n.disabled,typeof n.precedence=="string"&&t==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 Vb(t){return!(t.type==="stylesheet"&&(t.state.loading&3)===0)}function yA(t,n,i,u){if(i.type==="stylesheet"&&(typeof u.media!="string"||matchMedia(u.media).matches!==!1)&&(i.state.loading&4)===0){if(i.instance===null){var m=ti(u.href),x=n.querySelector(So(m));if(x){n=x._p,n!==null&&typeof n=="object"&&typeof n.then=="function"&&(t.count++,t=Mu.bind(t),n.then(t,t)),i.state.loading|=4,i.instance=x,wt(x);return}x=n.ownerDocument||n,u=Pb(u),(m=$n.get(m))&&Sp(u,m),x=x.createElement("link"),wt(x);var E=x;E._p=new Promise(function(T,P){E.onload=T,E.onerror=P}),$t(x,"link",u),i.instance=x}t.stylesheets===null&&(t.stylesheets=new Map),t.stylesheets.set(i,n),(n=i.state.preload)&&(i.state.loading&3)===0&&(t.count++,i=Mu.bind(t),n.addEventListener("load",i),n.addEventListener("error",i))}}var Ep=0;function xA(t,n){return t.stylesheets&&t.count===0&&Du(t,t.stylesheets),0<t.count||0<t.imgCount?function(i){var u=setTimeout(function(){if(t.stylesheets&&Du(t,t.stylesheets),t.unsuspend){var x=t.unsuspend;t.unsuspend=null,x()}},6e4+n);0<t.imgBytes&&Ep===0&&(Ep=62500*W2());var m=setTimeout(function(){if(t.waitingForImages=!1,t.count===0&&(t.stylesheets&&Du(t,t.stylesheets),t.unsuspend)){var x=t.unsuspend;t.unsuspend=null,x()}},(t.imgBytes>Ep?50:800)+n);return t.unsuspend=i,function(){t.unsuspend=null,clearTimeout(u),clearTimeout(m)}}:null}function Mu(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Du(this,this.stylesheets);else if(this.unsuspend){var t=this.unsuspend;this.unsuspend=null,t()}}}var Ou=null;function Du(t,n){t.stylesheets=null,t.unsuspend!==null&&(t.count++,Ou=new Map,n.forEach(bA,t),Ou=null,Mu.call(t))}function bA(t,n){if(!(n.state.loading&4)){var i=Ou.get(t);if(i)var u=i.get(null);else{i=new Map,Ou.set(t,i);for(var m=t.querySelectorAll("link[data-precedence],style[data-precedence]"),x=0;x<m.length;x++){var E=m[x];(E.nodeName==="LINK"||E.getAttribute("media")!=="not all")&&(i.set(E.dataset.precedence,E),u=E)}u&&i.set(null,u)}m=n.instance,E=m.getAttribute("data-precedence"),x=i.get(E)||u,x===u&&i.set(null,m),i.set(E,m),this.count++,u=Mu.bind(this),m.addEventListener("load",u),m.addEventListener("error",u),x?x.parentNode.insertBefore(m,x.nextSibling):(t=t.nodeType===9?t.head:t,t.insertBefore(m,t.firstChild)),n.state.loading|=4}}var Eo={$$typeof:j,Provider:null,Consumer:null,_currentValue:te,_currentValue2:te,_threadCount:0};function vA(t,n,i,u,m,x,E,T,P){this.tag=1,this.containerInfo=t,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=kl(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=kl(0),this.hiddenUpdates=kl(null),this.identifierPrefix=u,this.onUncaughtError=m,this.onCaughtError=x,this.onRecoverableError=E,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=P,this.incompleteTransitions=new Map}function $b(t,n,i,u,m,x,E,T,P,K,ae,de){return t=new vA(t,n,i,E,P,K,ae,de,T),n=1,x===!0&&(n|=24),x=xn(3,null,null,n),t.current=x,x.stateNode=t,n=nf(),n.refCount++,t.pooledCache=n,n.refCount++,x.memoizedState={element:u,isDehydrated:i,cache:n},of(x),t}function qb(t){return t?(t=Ol,t):Ol}function Gb(t,n,i,u,m,x){m=qb(m),u.context===null?u.context=m:u.pendingContext=m,u=aa(n),u.payload={element:i},x=x===void 0?null:x,x!==null&&(u.callback=x),i=la(t,u,n),i!==null&&(fn(i,t,n),to(i,t,n))}function Yb(t,n){if(t=t.memoizedState,t!==null&&t.dehydrated!==null){var i=t.retryLane;t.retryLane=i!==0&&i<n?i:n}}function Cp(t,n){Yb(t,n),(t=t.alternate)&&Yb(t,n)}function Xb(t){if(t.tag===13||t.tag===31){var n=Ga(t,67108864);n!==null&&fn(n,t,67108864),Cp(t,67108864)}}function Kb(t){if(t.tag===13||t.tag===31){var n=kn();n=Li(n);var i=Ga(t,n);i!==null&&fn(i,t,n),Cp(t,n)}}var zu=!0;function wA(t,n,i,u){var m=B.T;B.T=null;var x=G.p;try{G.p=2,Ap(t,n,i,u)}finally{G.p=x,B.T=m}}function SA(t,n,i,u){var m=B.T;B.T=null;var x=G.p;try{G.p=8,Ap(t,n,i,u)}finally{G.p=x,B.T=m}}function Ap(t,n,i,u){if(zu){var m=Np(u);if(m===null)fp(t,n,u,Lu,i),Zb(t,u);else if(EA(m,t,n,i,u))u.stopPropagation();else if(Zb(t,u),n&4&&-1<kA.indexOf(t)){for(;m!==null;){var x=en(m);if(x!==null)switch(x.tag){case 3:if(x=x.stateNode,x.current.memoizedState.isDehydrated){var E=vr(x.pendingLanes);if(E!==0){var T=x;for(T.pendingLanes|=2,T.entangledLanes|=2;E;){var P=1<<31-lt(E);T.entanglements[1]|=P,E&=~P}ur(x),(at&6)===0&&(xu=Dt()+500,xo(0))}}break;case 31:case 13:T=Ga(x,2),T!==null&&fn(T,x,2),vu(),Cp(x,2)}if(x=Np(u),x===null&&fp(t,n,u,Lu,i),x===m)break;m=x}m!==null&&u.stopPropagation()}else fp(t,n,u,null,i)}}function Np(t){return t=jd(t),jp(t)}var Lu=null;function jp(t){if(Lu=null,t=Zr(t),t!==null){var n=s(t);if(n===null)t=null;else{var i=n.tag;if(i===13){if(t=c(n),t!==null)return t;t=null}else if(i===31){if(t=d(n),t!==null)return t;t=null}else if(i===3){if(n.stateNode.current.memoizedState.isDehydrated)return n.tag===3?n.stateNode.containerInfo:null;t=null}else n!==t&&(t=null)}}return Lu=t,null}function Qb(t){switch(t){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(Di()){case oe:return 2;case xe:return 8;case Te:case Ie:return 32;case rt:return 268435456;default:return 32}default:return 32}}var Tp=!1,ga=null,ya=null,xa=null,Co=new Map,Ao=new Map,ba=[],kA="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 Zb(t,n){switch(t){case"focusin":case"focusout":ga=null;break;case"dragenter":case"dragleave":ya=null;break;case"mouseover":case"mouseout":xa=null;break;case"pointerover":case"pointerout":Co.delete(n.pointerId);break;case"gotpointercapture":case"lostpointercapture":Ao.delete(n.pointerId)}}function No(t,n,i,u,m,x){return t===null||t.nativeEvent!==x?(t={blockedOn:n,domEventName:i,eventSystemFlags:u,nativeEvent:x,targetContainers:[m]},n!==null&&(n=en(n),n!==null&&Xb(n)),t):(t.eventSystemFlags|=u,n=t.targetContainers,m!==null&&n.indexOf(m)===-1&&n.push(m),t)}function EA(t,n,i,u,m){switch(n){case"focusin":return ga=No(ga,t,n,i,u,m),!0;case"dragenter":return ya=No(ya,t,n,i,u,m),!0;case"mouseover":return xa=No(xa,t,n,i,u,m),!0;case"pointerover":var x=m.pointerId;return Co.set(x,No(Co.get(x)||null,t,n,i,u,m)),!0;case"gotpointercapture":return x=m.pointerId,Ao.set(x,No(Ao.get(x)||null,t,n,i,u,m)),!0}return!1}function Wb(t){var n=Zr(t.target);if(n!==null){var i=s(n);if(i!==null){if(n=i.tag,n===13){if(n=c(i),n!==null){t.blockedOn=n,_s(t.priority,function(){Kb(i)});return}}else if(n===31){if(n=d(i),n!==null){t.blockedOn=n,_s(t.priority,function(){Kb(i)});return}}else if(n===3&&i.stateNode.current.memoizedState.isDehydrated){t.blockedOn=i.tag===3?i.stateNode.containerInfo:null;return}}}t.blockedOn=null}function Iu(t){if(t.blockedOn!==null)return!1;for(var n=t.targetContainers;0<n.length;){var i=Np(t.nativeEvent);if(i===null){i=t.nativeEvent;var u=new i.constructor(i.type,i);Nd=u,i.target.dispatchEvent(u),Nd=null}else return n=en(i),n!==null&&Xb(n),t.blockedOn=i,!1;n.shift()}return!0}function Jb(t,n,i){Iu(t)&&i.delete(n)}function CA(){Tp=!1,ga!==null&&Iu(ga)&&(ga=null),ya!==null&&Iu(ya)&&(ya=null),xa!==null&&Iu(xa)&&(xa=null),Co.forEach(Jb),Ao.forEach(Jb)}function Bu(t,n){t.blockedOn===n&&(t.blockedOn=null,Tp||(Tp=!0,e.unstable_scheduleCallback(e.unstable_NormalPriority,CA)))}var Pu=null;function ev(t){Pu!==t&&(Pu=t,e.unstable_scheduleCallback(e.unstable_NormalPriority,function(){Pu===t&&(Pu=null);for(var n=0;n<t.length;n+=3){var i=t[n],u=t[n+1],m=t[n+2];if(typeof u!="function"){if(jp(u||i)===null)continue;break}var x=en(i);x!==null&&(t.splice(n,3),n-=3,Nf(x,{pending:!0,data:m,method:i.method,action:u},u,m))}}))}function ri(t){function n(P){return Bu(P,t)}ga!==null&&Bu(ga,t),ya!==null&&Bu(ya,t),xa!==null&&Bu(xa,t),Co.forEach(n),Ao.forEach(n);for(var i=0;i<ba.length;i++){var u=ba[i];u.blockedOn===t&&(u.blockedOn=null)}for(;0<ba.length&&(i=ba[0],i.blockedOn===null);)Wb(i),i.blockedOn===null&&ba.shift();if(i=(t.ownerDocument||t).$$reactFormReplay,i!=null)for(u=0;u<i.length;u+=3){var m=i[u],x=i[u+1],E=m[Xt]||null;if(typeof x=="function")E||ev(i);else if(E){var T=null;if(x&&x.hasAttribute("formAction")){if(m=x,E=x[Xt]||null)T=E.formAction;else if(jp(m)!==null)continue}else T=E.action;typeof T=="function"?i[u+1]=T:(i.splice(u,3),u-=3),ev(i)}}}function tv(){function t(x){x.canIntercept&&x.info==="react-transition"&&x.intercept({handler:function(){return new Promise(function(E){return m=E})},focusReset:"manual",scroll:"manual"})}function n(){m!==null&&(m(),m=null),u||setTimeout(i,20)}function i(){if(!u&&!navigation.transition){var x=navigation.currentEntry;x&&x.url!=null&&navigation.navigate(x.url,{state:x.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var u=!1,m=null;return navigation.addEventListener("navigate",t),navigation.addEventListener("navigatesuccess",n),navigation.addEventListener("navigateerror",n),setTimeout(i,100),function(){u=!0,navigation.removeEventListener("navigate",t),navigation.removeEventListener("navigatesuccess",n),navigation.removeEventListener("navigateerror",n),m!==null&&(m(),m=null)}}}function _p(t){this._internalRoot=t}Fu.prototype.render=_p.prototype.render=function(t){var n=this._internalRoot;if(n===null)throw Error(l(409));var i=n.current,u=kn();Gb(i,u,t,n,null,null)},Fu.prototype.unmount=_p.prototype.unmount=function(){var t=this._internalRoot;if(t!==null){this._internalRoot=null;var n=t.containerInfo;Gb(t.current,2,null,t,null,null),vu(),n[Qr]=null}};function Fu(t){this._internalRoot=t}Fu.prototype.unstable_scheduleHydration=function(t){if(t){var n=Ts();t={blockedOn:null,target:t,priority:n};for(var i=0;i<ba.length&&n!==0&&n<ba[i].priority;i++);ba.splice(i,0,t),i===0&&Wb(t)}};var nv=r.version;if(nv!=="19.2.4")throw Error(l(527,nv,"19.2.4"));G.findDOMNode=function(t){var n=t._reactInternals;if(n===void 0)throw typeof t.render=="function"?Error(l(188)):(t=Object.keys(t).join(","),Error(l(268,t)));return t=h(n),t=t!==null?y(t):null,t=t===null?null:t.stateNode,t};var AA={bundleType:0,version:"19.2.4",rendererPackageName:"react-dom",currentDispatcherRef:B,reconcilerVersion:"19.2.4"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Uu=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Uu.isDisabled&&Uu.supportsFiber)try{He=Uu.inject(AA),yt=Uu}catch{}}return To.createRoot=function(t,n){if(!o(t))throw Error(l(299));var i=!1,u="",m=ux,x=cx,E=dx;return n!=null&&(n.unstable_strictMode===!0&&(i=!0),n.identifierPrefix!==void 0&&(u=n.identifierPrefix),n.onUncaughtError!==void 0&&(m=n.onUncaughtError),n.onCaughtError!==void 0&&(x=n.onCaughtError),n.onRecoverableError!==void 0&&(E=n.onRecoverableError)),n=$b(t,1,!1,null,null,i,u,null,m,x,E,tv),t[Qr]=n.current,dp(t),new _p(n)},To.hydrateRoot=function(t,n,i){if(!o(t))throw Error(l(299));var u=!1,m="",x=ux,E=cx,T=dx,P=null;return i!=null&&(i.unstable_strictMode===!0&&(u=!0),i.identifierPrefix!==void 0&&(m=i.identifierPrefix),i.onUncaughtError!==void 0&&(x=i.onUncaughtError),i.onCaughtError!==void 0&&(E=i.onCaughtError),i.onRecoverableError!==void 0&&(T=i.onRecoverableError),i.formState!==void 0&&(P=i.formState)),n=$b(t,1,!0,n,i!=null?i:null,u,m,P,x,E,T,tv),n.context=qb(null),i=n.current,u=kn(),u=Li(u),m=aa(u),m.callback=null,la(i,m,u),i=u,n.current.lanes=i,Ye(n,i),ur(n),t[Qr]=n.current,dp(t),new Fu(n)},To.version="19.2.4",To}var fv;function LA(){if(fv)return Op.exports;fv=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(r){console.error(r)}}return e(),Op.exports=zA(),Op.exports}var IA=LA();const BA={theme:"system",setTheme:()=>null,resolvedTheme:"dark"},h1=v.createContext(BA);function PA({children:e,defaultTheme:r="system",storageKey:a="jean2-theme",...l}){const[o,s]=v.useState(()=>localStorage.getItem(a)||r),[c,d]=v.useState("dark");v.useEffect(()=>{const h=window.document.documentElement;if(h.classList.remove("light","dark"),o==="system"){const y=window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light";h.classList.add(y),d(y);return}h.classList.add(o),d(o)},[o]);const p={theme:o,setTheme:h=>{localStorage.setItem(a,h),s(h)},resolvedTheme:c};return f.jsx(h1.Provider,{...l,value:p,children:e})}const FA=()=>{const e=v.useContext(h1);if(e===void 0)throw new Error("useTheme must be used within a ThemeProvider");return e};async function UA(e,r={},a){return window.__TAURI_INTERNALS__.invoke(e,r,a)}/**
50
- * @license lucide-react v0.577.0 - ISC
51
- *
52
- * This source code is licensed under the ISC license.
53
- * See the LICENSE file in the root directory of this source tree.
54
- */const m1=(...e)=>e.filter((r,a,l)=>!!r&&r.trim()!==""&&l.indexOf(r)===a).join(" ").trim();/**
55
- * @license lucide-react v0.577.0 - ISC
56
- *
57
- * This source code is licensed under the ISC license.
58
- * See the LICENSE file in the root directory of this source tree.
59
- */const HA=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase();/**
60
- * @license lucide-react v0.577.0 - ISC
61
- *
62
- * This source code is licensed under the ISC license.
63
- * See the LICENSE file in the root directory of this source tree.
64
- */const VA=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(r,a,l)=>l?l.toUpperCase():a.toLowerCase());/**
65
- * @license lucide-react v0.577.0 - ISC
66
- *
67
- * This source code is licensed under the ISC license.
68
- * See the LICENSE file in the root directory of this source tree.
69
- */const pv=e=>{const r=VA(e);return r.charAt(0).toUpperCase()+r.slice(1)};/**
70
- * @license lucide-react v0.577.0 - ISC
71
- *
72
- * This source code is licensed under the ISC license.
73
- * See the LICENSE file in the root directory of this source tree.
74
- */var $A={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"};/**
75
- * @license lucide-react v0.577.0 - ISC
76
- *
77
- * This source code is licensed under the ISC license.
78
- * See the LICENSE file in the root directory of this source tree.
79
- */const qA=e=>{for(const r in e)if(r.startsWith("aria-")||r==="role"||r==="title")return!0;return!1};/**
80
- * @license lucide-react v0.577.0 - ISC
81
- *
82
- * This source code is licensed under the ISC license.
83
- * See the LICENSE file in the root directory of this source tree.
84
- */const GA=v.forwardRef(({color:e="currentColor",size:r=24,strokeWidth:a=2,absoluteStrokeWidth:l,className:o="",children:s,iconNode:c,...d},p)=>v.createElement("svg",{ref:p,...$A,width:r,height:r,stroke:e,strokeWidth:l?Number(a)*24/Number(r):a,className:m1("lucide",o),...!s&&!qA(d)&&{"aria-hidden":"true"},...d},[...c.map(([h,y])=>v.createElement(h,y)),...Array.isArray(s)?s:[s]]));/**
85
- * @license lucide-react v0.577.0 - ISC
86
- *
87
- * This source code is licensed under the ISC license.
88
- * See the LICENSE file in the root directory of this source tree.
89
- */const _e=(e,r)=>{const a=v.forwardRef(({className:l,...o},s)=>v.createElement(GA,{ref:s,iconNode:r,className:m1(`lucide-${HA(pv(e))}`,`lucide-${e}`,l),...o}));return a.displayName=pv(e),a};/**
90
- * @license lucide-react v0.577.0 - ISC
91
- *
92
- * This source code is licensed under the ISC license.
93
- * See the LICENSE file in the root directory of this source tree.
94
- */const YA=[["rect",{width:"20",height:"5",x:"2",y:"3",rx:"1",key:"1wp1u1"}],["path",{d:"M4 8v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8",key:"1s80jp"}],["path",{d:"M10 12h4",key:"a56b0p"}]],XA=_e("archive",YA);/**
95
- * @license lucide-react v0.577.0 - ISC
96
- *
97
- * This source code is licensed under the ISC license.
98
- * See the LICENSE file in the root directory of this source tree.
99
- */const KA=[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]],QA=_e("arrow-left",KA);/**
100
- * @license lucide-react v0.577.0 - ISC
101
- *
102
- * This source code is licensed under the ISC license.
103
- * See the LICENSE file in the root directory of this source tree.
104
- */const ZA=[["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"}]],WA=_e("bot",ZA);/**
105
- * @license lucide-react v0.577.0 - ISC
106
- *
107
- * This source code is licensed under the ISC license.
108
- * See the LICENSE file in the root directory of this source tree.
109
- */const JA=[["path",{d:"M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",key:"hh9hay"}],["path",{d:"m3.3 7 8.7 5 8.7-5",key:"g66t2b"}],["path",{d:"M12 22V12",key:"d0xqtd"}]],hv=_e("box",JA);/**
110
- * @license lucide-react v0.577.0 - ISC
111
- *
112
- * This source code is licensed under the ISC license.
113
- * See the LICENSE file in the root directory of this source tree.
114
- */const eN=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],Vr=_e("check",eN);/**
115
- * @license lucide-react v0.577.0 - ISC
116
- *
117
- * This source code is licensed under the ISC license.
118
- * See the LICENSE file in the root directory of this source tree.
119
- */const tN=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],ns=_e("chevron-down",tN);/**
120
- * @license lucide-react v0.577.0 - ISC
121
- *
122
- * This source code is licensed under the ISC license.
123
- * See the LICENSE file in the root directory of this source tree.
124
- */const nN=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],rN=_e("chevron-left",nN);/**
125
- * @license lucide-react v0.577.0 - ISC
126
- *
127
- * This source code is licensed under the ISC license.
128
- * See the LICENSE file in the root directory of this source tree.
129
- */const aN=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],cl=_e("chevron-right",aN);/**
130
- * @license lucide-react v0.577.0 - ISC
131
- *
132
- * This source code is licensed under the ISC license.
133
- * See the LICENSE file in the root directory of this source tree.
134
- */const lN=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],iN=_e("chevron-up",lN);/**
135
- * @license lucide-react v0.577.0 - ISC
136
- *
137
- * This source code is licensed under the ISC license.
138
- * See the LICENSE file in the root directory of this source tree.
139
- */const oN=[["path",{d:"m7 15 5 5 5-5",key:"1hf1tw"}],["path",{d:"m7 9 5-5 5 5",key:"sgt6xg"}]],g1=_e("chevrons-up-down",oN);/**
140
- * @license lucide-react v0.577.0 - ISC
141
- *
142
- * This source code is licensed under the ISC license.
143
- * See the LICENSE file in the root directory of this source tree.
144
- */const sN=[["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"}]],Bo=_e("circle-alert",sN);/**
145
- * @license lucide-react v0.577.0 - ISC
146
- *
147
- * This source code is licensed under the ISC license.
148
- * See the LICENSE file in the root directory of this source tree.
149
- */const uN=[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]],rs=_e("circle-check-big",uN);/**
150
- * @license lucide-react v0.577.0 - ISC
151
- *
152
- * This source code is licensed under the ISC license.
153
- * See the LICENSE file in the root directory of this source tree.
154
- */const cN=[["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"}]],Mc=_e("circle-x",cN);/**
155
- * @license lucide-react v0.577.0 - ISC
156
- *
157
- * This source code is licensed under the ISC license.
158
- * See the LICENSE file in the root directory of this source tree.
159
- */const dN=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],fN=_e("circle",dN);/**
160
- * @license lucide-react v0.577.0 - ISC
161
- *
162
- * This source code is licensed under the ISC license.
163
- * See the LICENSE file in the root directory of this source tree.
164
- */const pN=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 6v6l4 2",key:"mmk7yg"}]],y1=_e("clock",pN);/**
165
- * @license lucide-react v0.577.0 - ISC
166
- *
167
- * This source code is licensed under the ISC license.
168
- * See the LICENSE file in the root directory of this source tree.
169
- */const hN=[["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"}]],cc=_e("copy",hN);/**
170
- * @license lucide-react v0.577.0 - ISC
171
- *
172
- * This source code is licensed under the ISC license.
173
- * See the LICENSE file in the root directory of this source tree.
174
- */const mN=[["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M17 20v2",key:"1rnc9c"}],["path",{d:"M17 2v2",key:"11trls"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M2 17h2",key:"7oei6x"}],["path",{d:"M2 7h2",key:"asdhe0"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"M20 17h2",key:"1fpfkl"}],["path",{d:"M20 7h2",key:"1o8tra"}],["path",{d:"M7 20v2",key:"4gnj0m"}],["path",{d:"M7 2v2",key:"1i4yhu"}],["rect",{x:"4",y:"4",width:"16",height:"16",rx:"2",key:"1vbyd7"}],["rect",{x:"8",y:"8",width:"8",height:"8",rx:"1",key:"z9xiuo"}]],gN=_e("cpu",mN);/**
175
- * @license lucide-react v0.577.0 - ISC
176
- *
177
- * This source code is licensed under the ISC license.
178
- * See the LICENSE file in the root directory of this source tree.
179
- */const yN=[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]],xN=_e("ellipsis",yN);/**
180
- * @license lucide-react v0.577.0 - ISC
181
- *
182
- * This source code is licensed under the ISC license.
183
- * See the LICENSE file in the root directory of this source tree.
184
- */const bN=[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]],Sh=_e("external-link",bN);/**
185
- * @license lucide-react v0.577.0 - ISC
186
- *
187
- * This source code is licensed under the ISC license.
188
- * See the LICENSE file in the root directory of this source tree.
189
- */const vN=[["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"}]],wN=_e("eye-off",vN);/**
190
- * @license lucide-react v0.577.0 - ISC
191
- *
192
- * This source code is licensed under the ISC license.
193
- * See the LICENSE file in the root directory of this source tree.
194
- */const SN=[["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"}]],kN=_e("eye",SN);/**
195
- * @license lucide-react v0.577.0 - ISC
196
- *
197
- * This source code is licensed under the ISC license.
198
- * See the LICENSE file in the root directory of this source tree.
199
- */const EN=[["path",{d:"M12.659 22H18a2 2 0 0 0 2-2V8a2.4 2.4 0 0 0-.706-1.706l-3.588-3.588A2.4 2.4 0 0 0 14 2H6a2 2 0 0 0-2 2v9.34",key:"o6klzx"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10.378 12.622a1 1 0 0 1 3 3.003L8.36 20.637a2 2 0 0 1-.854.506l-2.867.837a.5.5 0 0 1-.62-.62l.836-2.869a2 2 0 0 1 .506-.853z",key:"zhnas1"}]],CN=_e("file-pen",EN);/**
200
- * @license lucide-react v0.577.0 - ISC
201
- *
202
- * This source code is licensed under the ISC license.
203
- * See the LICENSE file in the root directory of this source tree.
204
- */const AN=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]],em=_e("file-text",AN);/**
205
- * @license lucide-react v0.577.0 - ISC
206
- *
207
- * This source code is licensed under the ISC license.
208
- * See the LICENSE file in the root directory of this source tree.
209
- */const NN=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}]],cr=_e("file",NN);/**
210
- * @license lucide-react v0.577.0 - ISC
211
- *
212
- * This source code is licensed under the ISC license.
213
- * See the LICENSE file in the root directory of this source tree.
214
- */const jN=[["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"}]],kh=_e("folder-open",jN);/**
215
- * @license lucide-react v0.577.0 - ISC
216
- *
217
- * This source code is licensed under the ISC license.
218
- * See the LICENSE file in the root directory of this source tree.
219
- */const TN=[["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"}]],sl=_e("folder",TN);/**
220
- * @license lucide-react v0.577.0 - ISC
221
- *
222
- * This source code is licensed under the ISC license.
223
- * See the LICENSE file in the root directory of this source tree.
224
- */const _N=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]],mv=_e("info",_N);/**
225
- * @license lucide-react v0.577.0 - ISC
226
- *
227
- * This source code is licensed under the ISC license.
228
- * See the LICENSE file in the root directory of this source tree.
229
- */const RN=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],Gn=_e("loader-circle",RN);/**
230
- * @license lucide-react v0.577.0 - ISC
231
- *
232
- * This source code is licensed under the ISC license.
233
- * See the LICENSE file in the root directory of this source tree.
234
- */const MN=[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]],ON=_e("lock",MN);/**
235
- * @license lucide-react v0.577.0 - ISC
236
- *
237
- * This source code is licensed under the ISC license.
238
- * See the LICENSE file in the root directory of this source tree.
239
- */const DN=[["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"}]],zN=_e("monitor",DN);/**
240
- * @license lucide-react v0.577.0 - ISC
241
- *
242
- * This source code is licensed under the ISC license.
243
- * See the LICENSE file in the root directory of this source tree.
244
- */const LN=[["path",{d:"M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401",key:"kfwtm"}]],IN=_e("moon",LN);/**
245
- * @license lucide-react v0.577.0 - ISC
246
- *
247
- * This source code is licensed under the ISC license.
248
- * See the LICENSE file in the root directory of this source tree.
249
- */const BN=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}]],PN=_e("panel-left",BN);/**
250
- * @license lucide-react v0.577.0 - ISC
251
- *
252
- * This source code is licensed under the ISC license.
253
- * See the LICENSE file in the root directory of this source tree.
254
- */const FN=[["path",{d:"M6.3 20.3a2.4 2.4 0 0 0 3.4 0L12 18l-6-6-2.3 2.3a2.4 2.4 0 0 0 0 3.4Z",key:"goz73y"}],["path",{d:"m2 22 3-3",key:"19mgm9"}],["path",{d:"M7.5 13.5 10 11",key:"7xgeeb"}],["path",{d:"M10.5 16.5 13 14",key:"10btkg"}],["path",{d:"m18 3-4 4h6l-4 4",key:"16psg9"}]],UN=_e("plug-zap",FN);/**
255
- * @license lucide-react v0.577.0 - ISC
256
- *
257
- * This source code is licensed under the ISC license.
258
- * See the LICENSE file in the root directory of this source tree.
259
- */const HN=[["path",{d:"M12 22v-5",key:"1ega77"}],["path",{d:"M15 8V2",key:"18g5xt"}],["path",{d:"M17 8a1 1 0 0 1 1 1v4a4 4 0 0 1-4 4h-4a4 4 0 0 1-4-4V9a1 1 0 0 1 1-1z",key:"1xoxul"}],["path",{d:"M9 8V2",key:"14iosj"}]],VN=_e("plug",HN);/**
260
- * @license lucide-react v0.577.0 - ISC
261
- *
262
- * This source code is licensed under the ISC license.
263
- * See the LICENSE file in the root directory of this source tree.
264
- */const $N=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],Oc=_e("plus",$N);/**
265
- * @license lucide-react v0.577.0 - ISC
266
- *
267
- * This source code is licensed under the ISC license.
268
- * See the LICENSE file in the root directory of this source tree.
269
- */const qN=[["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"}]],pi=_e("refresh-cw",qN);/**
270
- * @license lucide-react v0.577.0 - ISC
271
- *
272
- * This source code is licensed under the ISC license.
273
- * See the LICENSE file in the root directory of this source tree.
274
- */const GN=[["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"}]],YN=_e("rotate-ccw",GN);/**
275
- * @license lucide-react v0.577.0 - ISC
276
- *
277
- * This source code is licensed under the ISC license.
278
- * See the LICENSE file in the root directory of this source tree.
279
- */const XN=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],tm=_e("search",XN);/**
280
- * @license lucide-react v0.577.0 - ISC
281
- *
282
- * This source code is licensed under the ISC license.
283
- * See the LICENSE file in the root directory of this source tree.
284
- */const KN=[["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"}]],QN=_e("send",KN);/**
285
- * @license lucide-react v0.577.0 - ISC
286
- *
287
- * This source code is licensed under the ISC license.
288
- * See the LICENSE file in the root directory of this source tree.
289
- */const ZN=[["rect",{width:"20",height:"8",x:"2",y:"2",rx:"2",ry:"2",key:"ngkwjq"}],["rect",{width:"20",height:"8",x:"2",y:"14",rx:"2",ry:"2",key:"iecqi9"}],["line",{x1:"6",x2:"6.01",y1:"6",y2:"6",key:"16zg32"}],["line",{x1:"6",x2:"6.01",y1:"18",y2:"18",key:"nzw8ys"}]],ul=_e("server",ZN);/**
290
- * @license lucide-react v0.577.0 - ISC
291
- *
292
- * This source code is licensed under the ISC license.
293
- * See the LICENSE file in the root directory of this source tree.
294
- */const WN=[["path",{d:"M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915",key:"1i5ecw"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],x1=_e("settings",WN);/**
295
- * @license lucide-react v0.577.0 - ISC
296
- *
297
- * This source code is licensed under the ISC license.
298
- * See the LICENSE file in the root directory of this source tree.
299
- */const JN=[["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"}]],b1=_e("shield",JN);/**
300
- * @license lucide-react v0.577.0 - ISC
301
- *
302
- * This source code is licensed under the ISC license.
303
- * See the LICENSE file in the root directory of this source tree.
304
- */const ej=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}]],v1=_e("square",ej);/**
305
- * @license lucide-react v0.577.0 - ISC
306
- *
307
- * This source code is licensed under the ISC license.
308
- * See the LICENSE file in the root directory of this source tree.
309
- */const tj=[["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"}]],gv=_e("star",tj);/**
310
- * @license lucide-react v0.577.0 - ISC
311
- *
312
- * This source code is licensed under the ISC license.
313
- * See the LICENSE file in the root directory of this source tree.
314
- */const nj=[["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"}]],rj=_e("sun",nj);/**
315
- * @license lucide-react v0.577.0 - ISC
316
- *
317
- * This source code is licensed under the ISC license.
318
- * See the LICENSE file in the root directory of this source tree.
319
- */const aj=[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]],as=_e("trash-2",aj);/**
320
- * @license lucide-react v0.577.0 - ISC
321
- *
322
- * This source code is licensed under the ISC license.
323
- * See the LICENSE file in the root directory of this source tree.
324
- */const lj=[["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"}]],yv=_e("triangle-alert",lj);/**
325
- * @license lucide-react v0.577.0 - ISC
326
- *
327
- * This source code is licensed under the ISC license.
328
- * See the LICENSE file in the root directory of this source tree.
329
- */const ij=[["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"}]],oj=_e("user",ij);/**
330
- * @license lucide-react v0.577.0 - ISC
331
- *
332
- * This source code is licensed under the ISC license.
333
- * See the LICENSE file in the root directory of this source tree.
334
- */const sj=[["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"}]],w1=_e("wifi-off",sj);/**
335
- * @license lucide-react v0.577.0 - ISC
336
- *
337
- * This source code is licensed under the ISC license.
338
- * See the LICENSE file in the root directory of this source tree.
339
- */const uj=[["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"}]],cj=_e("wifi",uj);/**
340
- * @license lucide-react v0.577.0 - ISC
341
- *
342
- * This source code is licensed under the ISC license.
343
- * See the LICENSE file in the root directory of this source tree.
344
- */const dj=[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z",key:"1ngwbx"}]],fj=_e("wrench",dj);/**
345
- * @license lucide-react v0.577.0 - ISC
346
- *
347
- * This source code is licensed under the ISC license.
348
- * See the LICENSE file in the root directory of this source tree.
349
- */const pj=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],xi=_e("x",pj);/**
350
- * @license lucide-react v0.577.0 - ISC
351
- *
352
- * This source code is licensed under the ISC license.
353
- * See the LICENSE file in the root directory of this source tree.
354
- */const hj=[["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"}]],Ip=_e("zap",hj),Yn={SERVERS:"jean2_servers",ACTIVE_SERVER_ID:"jean2_active_server_id",QUICK_CONNECTIONS:"jean2_quick_connections"};function Ur(){try{const e=localStorage.getItem(Yn.SERVERS);return e?JSON.parse(e):[]}catch(e){return console.error("Error reading saved servers from localStorage:",e),[]}}function mj(e){return Ur().find(a=>a.id===e)||null}function gj(e){try{const r=Ur();r.push(e),localStorage.setItem(Yn.SERVERS,JSON.stringify(r))}catch(r){console.error("Error saving server to localStorage:",r)}}function yj(e,r){try{const a=Ur(),l=a.findIndex(o=>o.id===e);if(l===-1){console.error("Server not found:",e);return}a[l]={...a[l],...r},localStorage.setItem(Yn.SERVERS,JSON.stringify(a))}catch(a){console.error("Error updating server in localStorage:",a)}}function xj(e){try{const a=Ur().filter(c=>c.id!==e);localStorage.setItem(Yn.SERVERS,JSON.stringify(a));const o=Hr().filter(c=>c.serverId!==e);localStorage.setItem(Yn.QUICK_CONNECTIONS,JSON.stringify(o)),S1()===e&&localStorage.removeItem(Yn.ACTIVE_SERVER_ID)}catch(r){console.error("Error deleting server from localStorage:",r)}}function S1(){try{return localStorage.getItem(Yn.ACTIVE_SERVER_ID)}catch(e){return console.error("Error reading active server ID from localStorage:",e),null}}function Bp(e){try{localStorage.setItem(Yn.ACTIVE_SERVER_ID,e)}catch(r){console.error("Error setting active server ID in localStorage:",r)}}function xv(){const e=S1();return e?mj(e):null}function Hr(){try{const e=localStorage.getItem(Yn.QUICK_CONNECTIONS);return e?JSON.parse(e):[]}catch(e){return console.error("Error reading quick connections from localStorage:",e),[]}}function bj(e){const r=Hr(),a=r.reduce((o,s)=>Math.max(o,s.order),-1),l={...e,id:crypto.randomUUID(),order:a+1};r.push(l);try{localStorage.setItem(Yn.QUICK_CONNECTIONS,JSON.stringify(r))}catch(o){console.error("Error saving quick connection to localStorage:",o)}return l}function vj(e){try{const a=Hr().filter(l=>l.id!==e);localStorage.setItem(Yn.QUICK_CONNECTIONS,JSON.stringify(a))}catch(r){console.error("Error removing quick connection from localStorage:",r)}}function wj(e){try{const r=Hr(),a=new Map(r.map(l=>[l.id,l]));e.forEach((l,o)=>{const s=a.get(l);s&&(s.order=o)}),localStorage.setItem(Yn.QUICK_CONNECTIONS,JSON.stringify(r))}catch(r){console.error("Error reordering quick connections in localStorage:",r)}}function k1(e){return/^[a-f0-9]{64}$/.test(e)}function Sj(e){return e.length<12?e:`${e.slice(0,4)}...${e.slice(-4)}`}function dc(e){let r=e.trim();return r=r.replace(/^(https?:\/\/|wss?:\/\/)/i,""),r=r.replace(/\/+$/,""),r}const E1=v.createContext(null),kj=({children:e})=>{const[r,a]=v.useState([]),[l,o]=v.useState(null),[s,c]=v.useState([]),[d,p]=v.useState(!1),h=v.useRef(null);v.useEffect(()=>{const j=Ur(),O=xv(),D=Hr();a(j),o(O),c(D)},[]);const y=(j,O,D)=>{const M=dc(O),U={id:crypto.randomUUID(),name:j,url:M,token:D,createdAt:new Date().toISOString()};return gj(U),a(Ur()),r.length===0&&(Bp(U.id),o(U)),U},g=(j,O)=>{const D={...O,...O.url&&{url:dc(O.url)}};yj(j,D),a(Ur()),(l==null?void 0:l.id)===j&&o(xv())},b=j=>{const O=(l==null?void 0:l.id)===j;if(xj(j),a(Ur()),O){const D=Ur(),M=D.length>0?D[0]:null;M?(Bp(M.id),o(M)):o(null)}c(Hr())},w=v.useCallback(j=>(h.current&&(clearTimeout(h.current),h.current=null),d&&(l==null?void 0:l.id)===j?!1:(d&&p(!1),p(!0),h.current=setTimeout(()=>{Bp(j);const O=r.find(D=>D.id===j)||null;o(O),p(!1)},100),!0)),[d,l,r]),k=v.useCallback(()=>{p(!1)},[]),N={servers:r,activeServer:l,quickConnections:s,isSwitching:d,addServer:y,editServer:g,removeServer:b,switchServer:w,clearSwitchingState:k,addToQuickConnections:(j,O,D,M)=>{bj({serverId:j,serverName:O,workspaceId:D,workspaceName:M}),c(Hr())},removeFromQuickConnections:j=>{vj(j),c(Hr())},reorderQuick:j=>{wj(j),c(Hr())}};return f.jsx(E1.Provider,{value:N,children:e})},Ei=()=>{const e=v.useContext(E1);if(e===null)throw new Error("useServerContext must be used within a ServerProvider");return e};function C1(e){var r,a,l="";if(typeof e=="string"||typeof e=="number")l+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(r=0;r<o;r++)e[r]&&(a=C1(e[r]))&&(l&&(l+=" "),l+=a)}else for(a in e)e[a]&&(l&&(l+=" "),l+=a);return l}function Dc(){for(var e,r,a=0,l="",o=arguments.length;a<o;a++)(e=arguments[a])&&(r=C1(e))&&(l&&(l+=" "),l+=r);return l}const bv=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,vv=Dc,Ci=(e,r)=>a=>{var l;if((r==null?void 0:r.variants)==null)return vv(e,a==null?void 0:a.class,a==null?void 0:a.className);const{variants:o,defaultVariants:s}=r,c=Object.keys(o).map(h=>{const y=a==null?void 0:a[h],g=s==null?void 0:s[h];if(y===null)return null;const b=bv(y)||bv(g);return o[h][b]}),d=a&&Object.entries(a).reduce((h,y)=>{let[g,b]=y;return b===void 0||(h[g]=b),h},{}),p=r==null||(l=r.compoundVariants)===null||l===void 0?void 0:l.reduce((h,y)=>{let{class:g,className:b,...w}=y;return Object.entries(w).every(k=>{let[S,C]=k;return Array.isArray(C)?C.includes({...s,...d}[S]):{...s,...d}[S]===C})?[...h,g,b]:h},[]);return vv(e,c,p,a==null?void 0:a.class,a==null?void 0:a.className)};var ls=p1();const Ej=Rc(ls);function wv(e,r){if(typeof e=="function")return e(r);e!=null&&(e.current=r)}function $r(...e){return r=>{let a=!1;const l=e.map(o=>{const s=wv(o,r);return!a&&typeof s=="function"&&(a=!0),s});if(a)return()=>{for(let o=0;o<l.length;o++){const s=l[o];typeof s=="function"?s():wv(e[o],null)}}}}function Ve(...e){return v.useCallback($r(...e),e)}function Aa(e){const r=Cj(e),a=v.forwardRef((l,o)=>{const{children:s,...c}=l,d=v.Children.toArray(s),p=d.find(Nj);if(p){const h=p.props.children,y=d.map(g=>g===p?v.Children.count(h)>1?v.Children.only(null):v.isValidElement(h)?h.props.children:null:g);return f.jsx(r,{...c,ref:o,children:v.isValidElement(h)?v.cloneElement(h,void 0,y):null})}return f.jsx(r,{...c,ref:o,children:s})});return a.displayName=`${e}.Slot`,a}var is=Aa("Slot");function Cj(e){const r=v.forwardRef((a,l)=>{const{children:o,...s}=a;if(v.isValidElement(o)){const c=Tj(o),d=jj(s,o.props);return o.type!==v.Fragment&&(d.ref=l?$r(l,c):c),v.cloneElement(o,d)}return v.Children.count(o)>1?v.Children.only(null):null});return r.displayName=`${e}.SlotClone`,r}var A1=Symbol("radix.slottable");function Aj(e){const r=({children:a})=>f.jsx(f.Fragment,{children:a});return r.displayName=`${e}.Slottable`,r.__radixId=A1,r}function Nj(e){return v.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===A1}function jj(e,r){const a={...r};for(const l in r){const o=e[l],s=r[l];/^on[A-Z]/.test(l)?o&&s?a[l]=(...d)=>{const p=s(...d);return o(...d),p}:o&&(a[l]=o):l==="style"?a[l]={...o,...s}:l==="className"&&(a[l]=[o,s].filter(Boolean).join(" "))}return{...e,...a}}function Tj(e){var l,o;let r=(l=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:l.get,a=r&&"isReactWarning"in r&&r.isReactWarning;return a?e.ref:(r=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,a=r&&"isReactWarning"in r&&r.isReactWarning,a?e.props.ref:e.props.ref||e.ref)}var _j=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Ce=_j.reduce((e,r)=>{const a=Aa(`Primitive.${r}`),l=v.forwardRef((o,s)=>{const{asChild:c,...d}=o,p=c?a:r;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),f.jsx(p,{...d,ref:s})});return l.displayName=`Primitive.${r}`,{...e,[r]:l}},{});function N1(e,r){e&&ls.flushSync(()=>e.dispatchEvent(r))}var j1=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),Rj="VisuallyHidden",T1=v.forwardRef((e,r)=>f.jsx(Ce.span,{...e,ref:r,style:{...j1,...e.style}}));T1.displayName=Rj;var Mj=T1;function Oj(e,r){const a=v.createContext(r),l=s=>{const{children:c,...d}=s,p=v.useMemo(()=>d,Object.values(d));return f.jsx(a.Provider,{value:p,children:c})};l.displayName=e+"Provider";function o(s){const c=v.useContext(a);if(c)return c;if(r!==void 0)return r;throw new Error(`\`${s}\` must be used within \`${e}\``)}return[l,o]}function _n(e,r=[]){let a=[];function l(s,c){const d=v.createContext(c),p=a.length;a=[...a,c];const h=g=>{var A;const{scope:b,children:w,...k}=g,S=((A=b==null?void 0:b[e])==null?void 0:A[p])||d,C=v.useMemo(()=>k,Object.values(k));return f.jsx(S.Provider,{value:C,children:w})};h.displayName=s+"Provider";function y(g,b){var S;const w=((S=b==null?void 0:b[e])==null?void 0:S[p])||d,k=v.useContext(w);if(k)return k;if(c!==void 0)return c;throw new Error(`\`${g}\` must be used within \`${s}\``)}return[h,y]}const o=()=>{const s=a.map(c=>v.createContext(c));return function(d){const p=(d==null?void 0:d[e])||s;return v.useMemo(()=>({[`__scope${e}`]:{...d,[e]:p}}),[d,p])}};return o.scopeName=e,[l,Dj(o,...r)]}function Dj(...e){const r=e[0];if(e.length===1)return r;const a=()=>{const l=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(s){const c=l.reduce((d,{useScope:p,scopeName:h})=>{const g=p(s)[`__scope${h}`];return{...d,...g}},{});return v.useMemo(()=>({[`__scope${r.scopeName}`]:c}),[c])}};return a.scopeName=r.scopeName,a}function nm(e){const r=e+"CollectionProvider",[a,l]=_n(r),[o,s]=a(r,{collectionRef:{current:null},itemMap:new Map}),c=S=>{const{scope:C,children:A}=S,N=er.useRef(null),j=er.useRef(new Map).current;return f.jsx(o,{scope:C,itemMap:j,collectionRef:N,children:A})};c.displayName=r;const d=e+"CollectionSlot",p=Aa(d),h=er.forwardRef((S,C)=>{const{scope:A,children:N}=S,j=s(d,A),O=Ve(C,j.collectionRef);return f.jsx(p,{ref:O,children:N})});h.displayName=d;const y=e+"CollectionItemSlot",g="data-radix-collection-item",b=Aa(y),w=er.forwardRef((S,C)=>{const{scope:A,children:N,...j}=S,O=er.useRef(null),D=Ve(C,O),M=s(y,A);return er.useEffect(()=>(M.itemMap.set(O,{ref:O,...j}),()=>void M.itemMap.delete(O))),f.jsx(b,{[g]:"",ref:D,children:N})});w.displayName=y;function k(S){const C=s(e+"CollectionConsumer",S);return er.useCallback(()=>{const N=C.collectionRef.current;if(!N)return[];const j=Array.from(N.querySelectorAll(`[${g}]`));return Array.from(C.itemMap.values()).sort((M,U)=>j.indexOf(M.ref.current)-j.indexOf(U.ref.current))},[C.collectionRef,C.itemMap])}return[{Provider:c,Slot:h,ItemSlot:w},k,l]}function ve(e,r,{checkForDefaultPrevented:a=!0}={}){return function(o){if(e==null||e(o),a===!1||!o.defaultPrevented)return r==null?void 0:r(o)}}var It=globalThis!=null&&globalThis.document?v.useLayoutEffect:()=>{},zj=f1[" useInsertionEffect ".trim().toString()]||It;function qr({prop:e,defaultProp:r,onChange:a=()=>{},caller:l}){const[o,s,c]=Lj({defaultProp:r,onChange:a}),d=e!==void 0,p=d?e:o;{const y=v.useRef(e!==void 0);v.useEffect(()=>{const g=y.current;g!==d&&console.warn(`${l} is changing from ${g?"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.`),y.current=d},[d,l])}const h=v.useCallback(y=>{var g;if(d){const b=Ij(y)?y(e):y;b!==e&&((g=c.current)==null||g.call(c,b))}else s(y)},[d,e,s,c]);return[p,h]}function Lj({defaultProp:e,onChange:r}){const[a,l]=v.useState(e),o=v.useRef(a),s=v.useRef(r);return zj(()=>{s.current=r},[r]),v.useEffect(()=>{var c;o.current!==a&&((c=s.current)==null||c.call(s,a),o.current=a)},[a,o]),[a,l,s]}function Ij(e){return typeof e=="function"}function Bj(e,r){return v.useReducer((a,l)=>{const o=r[a][l];return o!=null?o:a},e)}var Bt=e=>{const{present:r,children:a}=e,l=Pj(r),o=typeof a=="function"?a({present:l.isPresent}):v.Children.only(a),s=Ve(l.ref,Fj(o));return typeof a=="function"||l.isPresent?v.cloneElement(o,{ref:s}):null};Bt.displayName="Presence";function Pj(e){const[r,a]=v.useState(),l=v.useRef(null),o=v.useRef(e),s=v.useRef("none"),c=e?"mounted":"unmounted",[d,p]=Bj(c,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return v.useEffect(()=>{const h=Hu(l.current);s.current=d==="mounted"?h:"none"},[d]),It(()=>{const h=l.current,y=o.current;if(y!==e){const b=s.current,w=Hu(h);e?p("MOUNT"):w==="none"||(h==null?void 0:h.display)==="none"?p("UNMOUNT"):p(y&&b!==w?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,p]),It(()=>{var h;if(r){let y;const g=(h=r.ownerDocument.defaultView)!=null?h:window,b=k=>{const C=Hu(l.current).includes(CSS.escape(k.animationName));if(k.target===r&&C&&(p("ANIMATION_END"),!o.current)){const A=r.style.animationFillMode;r.style.animationFillMode="forwards",y=g.setTimeout(()=>{r.style.animationFillMode==="forwards"&&(r.style.animationFillMode=A)})}},w=k=>{k.target===r&&(s.current=Hu(l.current))};return r.addEventListener("animationstart",w),r.addEventListener("animationcancel",b),r.addEventListener("animationend",b),()=>{g.clearTimeout(y),r.removeEventListener("animationstart",w),r.removeEventListener("animationcancel",b),r.removeEventListener("animationend",b)}}else p("ANIMATION_END")},[r,p]),{isPresent:["mounted","unmountSuspended"].includes(d),ref:v.useCallback(h=>{l.current=h?getComputedStyle(h):null,a(h)},[])}}function Hu(e){return(e==null?void 0:e.animationName)||"none"}function Fj(e){var l,o;let r=(l=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:l.get,a=r&&"isReactWarning"in r&&r.isReactWarning;return a?e.ref:(r=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,a=r&&"isReactWarning"in r&&r.isReactWarning,a?e.props.ref:e.props.ref||e.ref)}var Uj=f1[" useId ".trim().toString()]||(()=>{}),Hj=0;function Mt(e){const[r,a]=v.useState(Uj());return It(()=>{a(l=>l!=null?l:String(Hj++))},[e]),e||(r?`radix-${r}`:"")}var zc="Collapsible",[Vj]=_n(zc),[$j,rm]=Vj(zc),_1=v.forwardRef((e,r)=>{const{__scopeCollapsible:a,open:l,defaultOpen:o,disabled:s,onOpenChange:c,...d}=e,[p,h]=qr({prop:l,defaultProp:o!=null?o:!1,onChange:c,caller:zc});return f.jsx($j,{scope:a,disabled:s,contentId:Mt(),open:p,onOpenToggle:v.useCallback(()=>h(y=>!y),[h]),children:f.jsx(Ce.div,{"data-state":lm(p),"data-disabled":s?"":void 0,...d,ref:r})})});_1.displayName=zc;var R1="CollapsibleTrigger",M1=v.forwardRef((e,r)=>{const{__scopeCollapsible:a,...l}=e,o=rm(R1,a);return f.jsx(Ce.button,{type:"button","aria-controls":o.contentId,"aria-expanded":o.open||!1,"data-state":lm(o.open),"data-disabled":o.disabled?"":void 0,disabled:o.disabled,...l,ref:r,onClick:ve(e.onClick,o.onOpenToggle)})});M1.displayName=R1;var am="CollapsibleContent",O1=v.forwardRef((e,r)=>{const{forceMount:a,...l}=e,o=rm(am,e.__scopeCollapsible);return f.jsx(Bt,{present:a||o.open,children:({present:s})=>f.jsx(qj,{...l,ref:r,present:s})})});O1.displayName=am;var qj=v.forwardRef((e,r)=>{const{__scopeCollapsible:a,present:l,children:o,...s}=e,c=rm(am,a),[d,p]=v.useState(l),h=v.useRef(null),y=Ve(r,h),g=v.useRef(0),b=g.current,w=v.useRef(0),k=w.current,S=c.open||d,C=v.useRef(S),A=v.useRef(void 0);return v.useEffect(()=>{const N=requestAnimationFrame(()=>C.current=!1);return()=>cancelAnimationFrame(N)},[]),It(()=>{const N=h.current;if(N){A.current=A.current||{transitionDuration:N.style.transitionDuration,animationName:N.style.animationName},N.style.transitionDuration="0s",N.style.animationName="none";const j=N.getBoundingClientRect();g.current=j.height,w.current=j.width,C.current||(N.style.transitionDuration=A.current.transitionDuration,N.style.animationName=A.current.animationName),p(l)}},[c.open,l]),f.jsx(Ce.div,{"data-state":lm(c.open),"data-disabled":c.disabled?"":void 0,id:c.contentId,hidden:!S,...s,ref:y,style:{"--radix-collapsible-content-height":b?`${b}px`:void 0,"--radix-collapsible-content-width":k?`${k}px`:void 0,...e.style},children:S&&o})});function lm(e){return e?"open":"closed"}var Gj=_1,Yj=v.createContext(void 0);function os(e){const r=v.useContext(Yj);return e||r||"ltr"}function qt(e){const r=v.useRef(e);return v.useEffect(()=>{r.current=e}),v.useMemo(()=>(...a)=>{var l;return(l=r.current)==null?void 0:l.call(r,...a)},[])}function Xj(e,r=globalThis==null?void 0:globalThis.document){const a=qt(e);v.useEffect(()=>{const l=o=>{o.key==="Escape"&&a(o)};return r.addEventListener("keydown",l,{capture:!0}),()=>r.removeEventListener("keydown",l,{capture:!0})},[a,r])}var Kj="DismissableLayer",Eh="dismissableLayer.update",Qj="dismissableLayer.pointerDownOutside",Zj="dismissableLayer.focusOutside",Sv,D1=v.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Ai=v.forwardRef((e,r)=>{var U;const{disableOutsidePointerEvents:a=!1,onEscapeKeyDown:l,onPointerDownOutside:o,onFocusOutside:s,onInteractOutside:c,onDismiss:d,...p}=e,h=v.useContext(D1),[y,g]=v.useState(null),b=(U=y==null?void 0:y.ownerDocument)!=null?U:globalThis==null?void 0:globalThis.document,[,w]=v.useState({}),k=Ve(r,F=>g(F)),S=Array.from(h.layers),[C]=[...h.layersWithOutsidePointerEventsDisabled].slice(-1),A=S.indexOf(C),N=y?S.indexOf(y):-1,j=h.layersWithOutsidePointerEventsDisabled.size>0,O=N>=A,D=eT(F=>{const Q=F.target,I=[...h.branches].some(Y=>Y.contains(Q));!O||I||(o==null||o(F),c==null||c(F),F.defaultPrevented||d==null||d())},b),M=tT(F=>{const Q=F.target;[...h.branches].some(Y=>Y.contains(Q))||(s==null||s(F),c==null||c(F),F.defaultPrevented||d==null||d())},b);return Xj(F=>{N===h.layers.size-1&&(l==null||l(F),!F.defaultPrevented&&d&&(F.preventDefault(),d()))},b),v.useEffect(()=>{if(y)return a&&(h.layersWithOutsidePointerEventsDisabled.size===0&&(Sv=b.body.style.pointerEvents,b.body.style.pointerEvents="none"),h.layersWithOutsidePointerEventsDisabled.add(y)),h.layers.add(y),kv(),()=>{a&&h.layersWithOutsidePointerEventsDisabled.size===1&&(b.body.style.pointerEvents=Sv)}},[y,b,a,h]),v.useEffect(()=>()=>{y&&(h.layers.delete(y),h.layersWithOutsidePointerEventsDisabled.delete(y),kv())},[y,h]),v.useEffect(()=>{const F=()=>w({});return document.addEventListener(Eh,F),()=>document.removeEventListener(Eh,F)},[]),f.jsx(Ce.div,{...p,ref:k,style:{pointerEvents:j?O?"auto":"none":void 0,...e.style},onFocusCapture:ve(e.onFocusCapture,M.onFocusCapture),onBlurCapture:ve(e.onBlurCapture,M.onBlurCapture),onPointerDownCapture:ve(e.onPointerDownCapture,D.onPointerDownCapture)})});Ai.displayName=Kj;var Wj="DismissableLayerBranch",Jj=v.forwardRef((e,r)=>{const a=v.useContext(D1),l=v.useRef(null),o=Ve(r,l);return v.useEffect(()=>{const s=l.current;if(s)return a.branches.add(s),()=>{a.branches.delete(s)}},[a.branches]),f.jsx(Ce.div,{...e,ref:o})});Jj.displayName=Wj;function eT(e,r=globalThis==null?void 0:globalThis.document){const a=qt(e),l=v.useRef(!1),o=v.useRef(()=>{});return v.useEffect(()=>{const s=d=>{if(d.target&&!l.current){let p=function(){z1(Qj,a,h,{discrete:!0})};const h={originalEvent:d};d.pointerType==="touch"?(r.removeEventListener("click",o.current),o.current=p,r.addEventListener("click",o.current,{once:!0})):p()}else r.removeEventListener("click",o.current);l.current=!1},c=window.setTimeout(()=>{r.addEventListener("pointerdown",s)},0);return()=>{window.clearTimeout(c),r.removeEventListener("pointerdown",s),r.removeEventListener("click",o.current)}},[r,a]),{onPointerDownCapture:()=>l.current=!0}}function tT(e,r=globalThis==null?void 0:globalThis.document){const a=qt(e),l=v.useRef(!1);return v.useEffect(()=>{const o=s=>{s.target&&!l.current&&z1(Zj,a,{originalEvent:s},{discrete:!1})};return r.addEventListener("focusin",o),()=>r.removeEventListener("focusin",o)},[r,a]),{onFocusCapture:()=>l.current=!0,onBlurCapture:()=>l.current=!1}}function kv(){const e=new CustomEvent(Eh);document.dispatchEvent(e)}function z1(e,r,a,{discrete:l}){const o=a.originalEvent.target,s=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:a});r&&o.addEventListener(e,r,{once:!0}),l?N1(o,s):o.dispatchEvent(s)}var Pp="focusScope.autoFocusOnMount",Fp="focusScope.autoFocusOnUnmount",Ev={bubbles:!1,cancelable:!0},nT="FocusScope",ss=v.forwardRef((e,r)=>{const{loop:a=!1,trapped:l=!1,onMountAutoFocus:o,onUnmountAutoFocus:s,...c}=e,[d,p]=v.useState(null),h=qt(o),y=qt(s),g=v.useRef(null),b=Ve(r,S=>p(S)),w=v.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;v.useEffect(()=>{if(l){let S=function(j){if(w.paused||!d)return;const O=j.target;d.contains(O)?g.current=O:Ea(g.current,{select:!0})},C=function(j){if(w.paused||!d)return;const O=j.relatedTarget;O!==null&&(d.contains(O)||Ea(g.current,{select:!0}))},A=function(j){if(document.activeElement===document.body)for(const D of j)D.removedNodes.length>0&&Ea(d)};document.addEventListener("focusin",S),document.addEventListener("focusout",C);const N=new MutationObserver(A);return d&&N.observe(d,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",S),document.removeEventListener("focusout",C),N.disconnect()}}},[l,d,w.paused]),v.useEffect(()=>{if(d){Av.add(w);const S=document.activeElement;if(!d.contains(S)){const A=new CustomEvent(Pp,Ev);d.addEventListener(Pp,h),d.dispatchEvent(A),A.defaultPrevented||(rT(sT(L1(d)),{select:!0}),document.activeElement===S&&Ea(d))}return()=>{d.removeEventListener(Pp,h),setTimeout(()=>{const A=new CustomEvent(Fp,Ev);d.addEventListener(Fp,y),d.dispatchEvent(A),A.defaultPrevented||Ea(S!=null?S:document.body,{select:!0}),d.removeEventListener(Fp,y),Av.remove(w)},0)}}},[d,h,y,w]);const k=v.useCallback(S=>{if(!a&&!l||w.paused)return;const C=S.key==="Tab"&&!S.altKey&&!S.ctrlKey&&!S.metaKey,A=document.activeElement;if(C&&A){const N=S.currentTarget,[j,O]=aT(N);j&&O?!S.shiftKey&&A===O?(S.preventDefault(),a&&Ea(j,{select:!0})):S.shiftKey&&A===j&&(S.preventDefault(),a&&Ea(O,{select:!0})):A===N&&S.preventDefault()}},[a,l,w.paused]);return f.jsx(Ce.div,{tabIndex:-1,...c,ref:b,onKeyDown:k})});ss.displayName=nT;function rT(e,{select:r=!1}={}){const a=document.activeElement;for(const l of e)if(Ea(l,{select:r}),document.activeElement!==a)return}function aT(e){const r=L1(e),a=Cv(r,e),l=Cv(r.reverse(),e);return[a,l]}function L1(e){const r=[],a=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:l=>{const o=l.tagName==="INPUT"&&l.type==="hidden";return l.disabled||l.hidden||o?NodeFilter.FILTER_SKIP:l.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;a.nextNode();)r.push(a.currentNode);return r}function Cv(e,r){for(const a of e)if(!lT(a,{upTo:r}))return a}function lT(e,{upTo:r}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(r!==void 0&&e===r)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function iT(e){return e instanceof HTMLInputElement&&"select"in e}function Ea(e,{select:r=!1}={}){if(e&&e.focus){const a=document.activeElement;e.focus({preventScroll:!0}),e!==a&&iT(e)&&r&&e.select()}}var Av=oT();function oT(){let e=[];return{add(r){const a=e[0];r!==a&&(a==null||a.pause()),e=Nv(e,r),e.unshift(r)},remove(r){var a;e=Nv(e,r),(a=e[0])==null||a.resume()}}}function Nv(e,r){const a=[...e],l=a.indexOf(r);return l!==-1&&a.splice(l,1),a}function sT(e){return e.filter(r=>r.tagName!=="A")}var uT="Portal",Ni=v.forwardRef((e,r)=>{var d;const{container:a,...l}=e,[o,s]=v.useState(!1);It(()=>s(!0),[]);const c=a||o&&((d=globalThis==null?void 0:globalThis.document)==null?void 0:d.body);return c?Ej.createPortal(f.jsx(Ce.div,{...l,ref:r}),c):null});Ni.displayName=uT;var Up=0;function Lc(){v.useEffect(()=>{var r,a;const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",(r=e[0])!=null?r:jv()),document.body.insertAdjacentElement("beforeend",(a=e[1])!=null?a:jv()),Up++,()=>{Up===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(l=>l.remove()),Up--}},[])}function jv(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var fr=function(){return fr=Object.assign||function(r){for(var a,l=1,o=arguments.length;l<o;l++){a=arguments[l];for(var s in a)Object.prototype.hasOwnProperty.call(a,s)&&(r[s]=a[s])}return r},fr.apply(this,arguments)};function I1(e,r){var a={};for(var l in e)Object.prototype.hasOwnProperty.call(e,l)&&r.indexOf(l)<0&&(a[l]=e[l]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,l=Object.getOwnPropertySymbols(e);o<l.length;o++)r.indexOf(l[o])<0&&Object.prototype.propertyIsEnumerable.call(e,l[o])&&(a[l[o]]=e[l[o]]);return a}function cT(e,r,a){if(a||arguments.length===2)for(var l=0,o=r.length,s;l<o;l++)(s||!(l in r))&&(s||(s=Array.prototype.slice.call(r,0,l)),s[l]=r[l]);return e.concat(s||Array.prototype.slice.call(r))}var nc="right-scroll-bar-position",rc="width-before-scroll-bar",dT="with-scroll-bars-hidden",fT="--removed-body-scroll-bar-size";function Hp(e,r){return typeof e=="function"?e(r):e&&(e.current=r),e}function pT(e,r){var a=v.useState(function(){return{value:e,callback:r,facade:{get current(){return a.value},set current(l){var o=a.value;o!==l&&(a.value=l,a.callback(l,o))}}}})[0];return a.callback=r,a.facade}var hT=typeof window<"u"?v.useLayoutEffect:v.useEffect,Tv=new WeakMap;function mT(e,r){var a=pT(null,function(l){return e.forEach(function(o){return Hp(o,l)})});return hT(function(){var l=Tv.get(a);if(l){var o=new Set(l),s=new Set(e),c=a.current;o.forEach(function(d){s.has(d)||Hp(d,null)}),s.forEach(function(d){o.has(d)||Hp(d,c)})}Tv.set(a,e)},[e]),a}function gT(e){return e}function yT(e,r){r===void 0&&(r=gT);var a=[],l=!1,o={read:function(){if(l)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return a.length?a[a.length-1]:e},useMedium:function(s){var c=r(s,l);return a.push(c),function(){a=a.filter(function(d){return d!==c})}},assignSyncMedium:function(s){for(l=!0;a.length;){var c=a;a=[],c.forEach(s)}a={push:function(d){return s(d)},filter:function(){return a}}},assignMedium:function(s){l=!0;var c=[];if(a.length){var d=a;a=[],d.forEach(s),c=a}var p=function(){var y=c;c=[],y.forEach(s)},h=function(){return Promise.resolve().then(p)};h(),a={push:function(y){c.push(y),h()},filter:function(y){return c=c.filter(y),a}}}};return o}function xT(e){e===void 0&&(e={});var r=yT(null);return r.options=fr({async:!0,ssr:!1},e),r}var B1=function(e){var r=e.sideCar,a=I1(e,["sideCar"]);if(!r)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var l=r.read();if(!l)throw new Error("Sidecar medium not found");return v.createElement(l,fr({},a))};B1.isSideCarExport=!0;function bT(e,r){return e.useMedium(r),B1}var P1=xT(),Vp=function(){},Ic=v.forwardRef(function(e,r){var a=v.useRef(null),l=v.useState({onScrollCapture:Vp,onWheelCapture:Vp,onTouchMoveCapture:Vp}),o=l[0],s=l[1],c=e.forwardProps,d=e.children,p=e.className,h=e.removeScrollBar,y=e.enabled,g=e.shards,b=e.sideCar,w=e.noRelative,k=e.noIsolation,S=e.inert,C=e.allowPinchZoom,A=e.as,N=A===void 0?"div":A,j=e.gapMode,O=I1(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),D=b,M=mT([a,r]),U=fr(fr({},O),o);return v.createElement(v.Fragment,null,y&&v.createElement(D,{sideCar:P1,removeScrollBar:h,shards:g,noRelative:w,noIsolation:k,inert:S,setCallbacks:s,allowPinchZoom:!!C,lockRef:a,gapMode:j}),c?v.cloneElement(v.Children.only(d),fr(fr({},U),{ref:M})):v.createElement(N,fr({},U,{className:p,ref:M}),d))});Ic.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};Ic.classNames={fullWidth:rc,zeroRight:nc};var vT=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function wT(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var r=vT();return r&&e.setAttribute("nonce",r),e}function ST(e,r){e.styleSheet?e.styleSheet.cssText=r:e.appendChild(document.createTextNode(r))}function kT(e){var r=document.head||document.getElementsByTagName("head")[0];r.appendChild(e)}var ET=function(){var e=0,r=null;return{add:function(a){e==0&&(r=wT())&&(ST(r,a),kT(r)),e++},remove:function(){e--,!e&&r&&(r.parentNode&&r.parentNode.removeChild(r),r=null)}}},CT=function(){var e=ET();return function(r,a){v.useEffect(function(){return e.add(r),function(){e.remove()}},[r&&a])}},F1=function(){var e=CT(),r=function(a){var l=a.styles,o=a.dynamic;return e(l,o),null};return r},AT={left:0,top:0,right:0,gap:0},$p=function(e){return parseInt(e||"",10)||0},NT=function(e){var r=window.getComputedStyle(document.body),a=r[e==="padding"?"paddingLeft":"marginLeft"],l=r[e==="padding"?"paddingTop":"marginTop"],o=r[e==="padding"?"paddingRight":"marginRight"];return[$p(a),$p(l),$p(o)]},jT=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return AT;var r=NT(e),a=document.documentElement.clientWidth,l=window.innerWidth;return{left:r[0],top:r[1],right:r[2],gap:Math.max(0,l-a+r[2]-r[0])}},TT=F1(),hi="data-scroll-locked",_T=function(e,r,a,l){var o=e.left,s=e.top,c=e.right,d=e.gap;return a===void 0&&(a="margin"),`
355
- .`.concat(dT,` {
356
- overflow: hidden `).concat(l,`;
357
- padding-right: `).concat(d,"px ").concat(l,`;
358
- }
359
- body[`).concat(hi,`] {
360
- overflow: hidden `).concat(l,`;
361
- overscroll-behavior: contain;
362
- `).concat([r&&"position: relative ".concat(l,";"),a==="margin"&&`
363
- padding-left: `.concat(o,`px;
364
- padding-top: `).concat(s,`px;
365
- padding-right: `).concat(c,`px;
366
- margin-left:0;
367
- margin-top:0;
368
- margin-right: `).concat(d,"px ").concat(l,`;
369
- `),a==="padding"&&"padding-right: ".concat(d,"px ").concat(l,";")].filter(Boolean).join(""),`
370
- }
371
-
372
- .`).concat(nc,` {
373
- right: `).concat(d,"px ").concat(l,`;
374
- }
375
-
376
- .`).concat(rc,` {
377
- margin-right: `).concat(d,"px ").concat(l,`;
378
- }
379
-
380
- .`).concat(nc," .").concat(nc,` {
381
- right: 0 `).concat(l,`;
382
- }
383
-
384
- .`).concat(rc," .").concat(rc,` {
385
- margin-right: 0 `).concat(l,`;
386
- }
387
-
388
- body[`).concat(hi,`] {
389
- `).concat(fT,": ").concat(d,`px;
390
- }
391
- `)},_v=function(){var e=parseInt(document.body.getAttribute(hi)||"0",10);return isFinite(e)?e:0},RT=function(){v.useEffect(function(){return document.body.setAttribute(hi,(_v()+1).toString()),function(){var e=_v()-1;e<=0?document.body.removeAttribute(hi):document.body.setAttribute(hi,e.toString())}},[])},MT=function(e){var r=e.noRelative,a=e.noImportant,l=e.gapMode,o=l===void 0?"margin":l;RT();var s=v.useMemo(function(){return jT(o)},[o]);return v.createElement(TT,{styles:_T(s,!r,o,a?"":"!important")})},Ch=!1;if(typeof window<"u")try{var Vu=Object.defineProperty({},"passive",{get:function(){return Ch=!0,!0}});window.addEventListener("test",Vu,Vu),window.removeEventListener("test",Vu,Vu)}catch{Ch=!1}var ai=Ch?{passive:!1}:!1,OT=function(e){return e.tagName==="TEXTAREA"},U1=function(e,r){if(!(e instanceof Element))return!1;var a=window.getComputedStyle(e);return a[r]!=="hidden"&&!(a.overflowY===a.overflowX&&!OT(e)&&a[r]==="visible")},DT=function(e){return U1(e,"overflowY")},zT=function(e){return U1(e,"overflowX")},Rv=function(e,r){var a=r.ownerDocument,l=r;do{typeof ShadowRoot<"u"&&l instanceof ShadowRoot&&(l=l.host);var o=H1(e,l);if(o){var s=V1(e,l),c=s[1],d=s[2];if(c>d)return!0}l=l.parentNode}while(l&&l!==a.body);return!1},LT=function(e){var r=e.scrollTop,a=e.scrollHeight,l=e.clientHeight;return[r,a,l]},IT=function(e){var r=e.scrollLeft,a=e.scrollWidth,l=e.clientWidth;return[r,a,l]},H1=function(e,r){return e==="v"?DT(r):zT(r)},V1=function(e,r){return e==="v"?LT(r):IT(r)},BT=function(e,r){return e==="h"&&r==="rtl"?-1:1},PT=function(e,r,a,l,o){var s=BT(e,window.getComputedStyle(r).direction),c=s*l,d=a.target,p=r.contains(d),h=!1,y=c>0,g=0,b=0;do{if(!d)break;var w=V1(e,d),k=w[0],S=w[1],C=w[2],A=S-C-s*k;(k||A)&&H1(e,d)&&(g+=A,b+=k);var N=d.parentNode;d=N&&N.nodeType===Node.DOCUMENT_FRAGMENT_NODE?N.host:N}while(!p&&d!==document.body||p&&(r.contains(d)||r===d));return(y&&Math.abs(g)<1||!y&&Math.abs(b)<1)&&(h=!0),h},$u=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Mv=function(e){return[e.deltaX,e.deltaY]},Ov=function(e){return e&&"current"in e?e.current:e},FT=function(e,r){return e[0]===r[0]&&e[1]===r[1]},UT=function(e){return`
392
- .block-interactivity-`.concat(e,` {pointer-events: none;}
393
- .allow-interactivity-`).concat(e,` {pointer-events: all;}
394
- `)},HT=0,li=[];function VT(e){var r=v.useRef([]),a=v.useRef([0,0]),l=v.useRef(),o=v.useState(HT++)[0],s=v.useState(F1)[0],c=v.useRef(e);v.useEffect(function(){c.current=e},[e]),v.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var S=cT([e.lockRef.current],(e.shards||[]).map(Ov),!0).filter(Boolean);return S.forEach(function(C){return C.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),S.forEach(function(C){return C.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var d=v.useCallback(function(S,C){if("touches"in S&&S.touches.length===2||S.type==="wheel"&&S.ctrlKey)return!c.current.allowPinchZoom;var A=$u(S),N=a.current,j="deltaX"in S?S.deltaX:N[0]-A[0],O="deltaY"in S?S.deltaY:N[1]-A[1],D,M=S.target,U=Math.abs(j)>Math.abs(O)?"h":"v";if("touches"in S&&U==="h"&&M.type==="range")return!1;var F=window.getSelection(),Q=F&&F.anchorNode,I=Q?Q===M||Q.contains(M):!1;if(I)return!1;var Y=Rv(U,M);if(!Y)return!0;if(Y?D=U:(D=U==="v"?"h":"v",Y=Rv(U,M)),!Y)return!1;if(!l.current&&"changedTouches"in S&&(j||O)&&(l.current=D),!D)return!0;var V=l.current||D;return PT(V,C,S,V==="h"?j:O)},[]),p=v.useCallback(function(S){var C=S;if(!(!li.length||li[li.length-1]!==s)){var A="deltaY"in C?Mv(C):$u(C),N=r.current.filter(function(D){return D.name===C.type&&(D.target===C.target||C.target===D.shadowParent)&&FT(D.delta,A)})[0];if(N&&N.should){C.cancelable&&C.preventDefault();return}if(!N){var j=(c.current.shards||[]).map(Ov).filter(Boolean).filter(function(D){return D.contains(C.target)}),O=j.length>0?d(C,j[0]):!c.current.noIsolation;O&&C.cancelable&&C.preventDefault()}}},[]),h=v.useCallback(function(S,C,A,N){var j={name:S,delta:C,target:A,should:N,shadowParent:$T(A)};r.current.push(j),setTimeout(function(){r.current=r.current.filter(function(O){return O!==j})},1)},[]),y=v.useCallback(function(S){a.current=$u(S),l.current=void 0},[]),g=v.useCallback(function(S){h(S.type,Mv(S),S.target,d(S,e.lockRef.current))},[]),b=v.useCallback(function(S){h(S.type,$u(S),S.target,d(S,e.lockRef.current))},[]);v.useEffect(function(){return li.push(s),e.setCallbacks({onScrollCapture:g,onWheelCapture:g,onTouchMoveCapture:b}),document.addEventListener("wheel",p,ai),document.addEventListener("touchmove",p,ai),document.addEventListener("touchstart",y,ai),function(){li=li.filter(function(S){return S!==s}),document.removeEventListener("wheel",p,ai),document.removeEventListener("touchmove",p,ai),document.removeEventListener("touchstart",y,ai)}},[]);var w=e.removeScrollBar,k=e.inert;return v.createElement(v.Fragment,null,k?v.createElement(s,{styles:UT(o)}):null,w?v.createElement(MT,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function $T(e){for(var r=null;e!==null;)e instanceof ShadowRoot&&(r=e.host,e=e.host),e=e.parentNode;return r}const qT=bT(P1,VT);var us=v.forwardRef(function(e,r){return v.createElement(Ic,fr({},e,{ref:r,sideCar:qT}))});us.classNames=Ic.classNames;var GT=function(e){if(typeof document>"u")return null;var r=Array.isArray(e)?e[0]:e;return r.ownerDocument.body},ii=new WeakMap,qu=new WeakMap,Gu={},qp=0,$1=function(e){return e&&(e.host||$1(e.parentNode))},YT=function(e,r){return r.map(function(a){if(e.contains(a))return a;var l=$1(a);return l&&e.contains(l)?l:(console.error("aria-hidden",a,"in not contained inside",e,". Doing nothing"),null)}).filter(function(a){return!!a})},XT=function(e,r,a,l){var o=YT(r,Array.isArray(e)?e:[e]);Gu[a]||(Gu[a]=new WeakMap);var s=Gu[a],c=[],d=new Set,p=new Set(o),h=function(g){!g||d.has(g)||(d.add(g),h(g.parentNode))};o.forEach(h);var y=function(g){!g||p.has(g)||Array.prototype.forEach.call(g.children,function(b){if(d.has(b))y(b);else try{var w=b.getAttribute(l),k=w!==null&&w!=="false",S=(ii.get(b)||0)+1,C=(s.get(b)||0)+1;ii.set(b,S),s.set(b,C),c.push(b),S===1&&k&&qu.set(b,!0),C===1&&b.setAttribute(a,"true"),k||b.setAttribute(l,"true")}catch(A){console.error("aria-hidden: cannot operate on ",b,A)}})};return y(r),d.clear(),qp++,function(){c.forEach(function(g){var b=ii.get(g)-1,w=s.get(g)-1;ii.set(g,b),s.set(g,w),b||(qu.has(g)||g.removeAttribute(l),qu.delete(g)),w||g.removeAttribute(a)}),qp--,qp||(ii=new WeakMap,ii=new WeakMap,qu=new WeakMap,Gu={})}},Bc=function(e,r,a){a===void 0&&(a="data-aria-hidden");var l=Array.from(Array.isArray(e)?e:[e]),o=GT(e);return o?(l.push.apply(l,Array.from(o.querySelectorAll("[aria-live], script"))),XT(l,o,a,"aria-hidden")):function(){return null}},Pc="Dialog",[q1]=_n(Pc),[KT,ar]=q1(Pc),G1=e=>{const{__scopeDialog:r,children:a,open:l,defaultOpen:o,onOpenChange:s,modal:c=!0}=e,d=v.useRef(null),p=v.useRef(null),[h,y]=qr({prop:l,defaultProp:o!=null?o:!1,onChange:s,caller:Pc});return f.jsx(KT,{scope:r,triggerRef:d,contentRef:p,contentId:Mt(),titleId:Mt(),descriptionId:Mt(),open:h,onOpenChange:y,onOpenToggle:v.useCallback(()=>y(g=>!g),[y]),modal:c,children:a})};G1.displayName=Pc;var Y1="DialogTrigger",X1=v.forwardRef((e,r)=>{const{__scopeDialog:a,...l}=e,o=ar(Y1,a),s=Ve(r,o.triggerRef);return f.jsx(Ce.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":sm(o.open),...l,ref:s,onClick:ve(e.onClick,o.onOpenToggle)})});X1.displayName=Y1;var im="DialogPortal",[QT,K1]=q1(im,{forceMount:void 0}),Q1=e=>{const{__scopeDialog:r,forceMount:a,children:l,container:o}=e,s=ar(im,r);return f.jsx(QT,{scope:r,forceMount:a,children:v.Children.map(l,c=>f.jsx(Bt,{present:a||s.open,children:f.jsx(Ni,{asChild:!0,container:o,children:c})}))})};Q1.displayName=im;var fc="DialogOverlay",Z1=v.forwardRef((e,r)=>{const a=K1(fc,e.__scopeDialog),{forceMount:l=a.forceMount,...o}=e,s=ar(fc,e.__scopeDialog);return s.modal?f.jsx(Bt,{present:l||s.open,children:f.jsx(WT,{...o,ref:r})}):null});Z1.displayName=fc;var ZT=Aa("DialogOverlay.RemoveScroll"),WT=v.forwardRef((e,r)=>{const{__scopeDialog:a,...l}=e,o=ar(fc,a);return f.jsx(us,{as:ZT,allowPinchZoom:!0,shards:[o.contentRef],children:f.jsx(Ce.div,{"data-state":sm(o.open),...l,ref:r,style:{pointerEvents:"auto",...l.style}})})}),dl="DialogContent",W1=v.forwardRef((e,r)=>{const a=K1(dl,e.__scopeDialog),{forceMount:l=a.forceMount,...o}=e,s=ar(dl,e.__scopeDialog);return f.jsx(Bt,{present:l||s.open,children:s.modal?f.jsx(JT,{...o,ref:r}):f.jsx(e_,{...o,ref:r})})});W1.displayName=dl;var JT=v.forwardRef((e,r)=>{const a=ar(dl,e.__scopeDialog),l=v.useRef(null),o=Ve(r,a.contentRef,l);return v.useEffect(()=>{const s=l.current;if(s)return Bc(s)},[]),f.jsx(J1,{...e,ref:o,trapFocus:a.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:ve(e.onCloseAutoFocus,s=>{var c;s.preventDefault(),(c=a.triggerRef.current)==null||c.focus()}),onPointerDownOutside:ve(e.onPointerDownOutside,s=>{const c=s.detail.originalEvent,d=c.button===0&&c.ctrlKey===!0;(c.button===2||d)&&s.preventDefault()}),onFocusOutside:ve(e.onFocusOutside,s=>s.preventDefault())})}),e_=v.forwardRef((e,r)=>{const a=ar(dl,e.__scopeDialog),l=v.useRef(!1),o=v.useRef(!1);return f.jsx(J1,{...e,ref:r,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{var c,d;(c=e.onCloseAutoFocus)==null||c.call(e,s),s.defaultPrevented||(l.current||(d=a.triggerRef.current)==null||d.focus(),s.preventDefault()),l.current=!1,o.current=!1},onInteractOutside:s=>{var p,h;(p=e.onInteractOutside)==null||p.call(e,s),s.defaultPrevented||(l.current=!0,s.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const c=s.target;((h=a.triggerRef.current)==null?void 0:h.contains(c))&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&o.current&&s.preventDefault()}})}),J1=v.forwardRef((e,r)=>{const{__scopeDialog:a,trapFocus:l,onOpenAutoFocus:o,onCloseAutoFocus:s,...c}=e,d=ar(dl,a),p=v.useRef(null),h=Ve(r,p);return Lc(),f.jsxs(f.Fragment,{children:[f.jsx(ss,{asChild:!0,loop:!0,trapped:l,onMountAutoFocus:o,onUnmountAutoFocus:s,children:f.jsx(Ai,{role:"dialog",id:d.contentId,"aria-describedby":d.descriptionId,"aria-labelledby":d.titleId,"data-state":sm(d.open),...c,ref:h,onDismiss:()=>d.onOpenChange(!1)})}),f.jsxs(f.Fragment,{children:[f.jsx(t_,{titleId:d.titleId}),f.jsx(r_,{contentRef:p,descriptionId:d.descriptionId})]})]})}),om="DialogTitle",ew=v.forwardRef((e,r)=>{const{__scopeDialog:a,...l}=e,o=ar(om,a);return f.jsx(Ce.h2,{id:o.titleId,...l,ref:r})});ew.displayName=om;var tw="DialogDescription",nw=v.forwardRef((e,r)=>{const{__scopeDialog:a,...l}=e,o=ar(tw,a);return f.jsx(Ce.p,{id:o.descriptionId,...l,ref:r})});nw.displayName=tw;var rw="DialogClose",aw=v.forwardRef((e,r)=>{const{__scopeDialog:a,...l}=e,o=ar(rw,a);return f.jsx(Ce.button,{type:"button",...l,ref:r,onClick:ve(e.onClick,()=>o.onOpenChange(!1))})});aw.displayName=rw;function sm(e){return e?"open":"closed"}var lw="DialogTitleWarning",[uP,iw]=Oj(lw,{contentName:dl,titleName:om,docsSlug:"dialog"}),t_=({titleId:e})=>{const r=iw(lw),a=`\`${r.contentName}\` requires a \`${r.titleName}\` for the component to be accessible for screen reader users.
395
-
396
- If you want to hide the \`${r.titleName}\`, you can wrap it with our VisuallyHidden component.
397
-
398
- For more information, see https://radix-ui.com/primitives/docs/components/${r.docsSlug}`;return v.useEffect(()=>{e&&(document.getElementById(e)||console.error(a))},[a,e]),null},n_="DialogDescriptionWarning",r_=({contentRef:e,descriptionId:r})=>{const l=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${iw(n_).contentName}}.`;return v.useEffect(()=>{var s;const o=(s=e.current)==null?void 0:s.getAttribute("aria-describedby");r&&o&&(document.getElementById(r)||console.warn(l))},[l,e,r]),null},um=G1,a_=X1,cm=Q1,dm=Z1,fm=W1,ow=ew,sw=nw,pm=aw;function l_(e){const r=v.useRef({value:e,previous:e});return v.useMemo(()=>(r.current.value!==e&&(r.current.previous=r.current.value,r.current.value=e),r.current.previous),[e])}function i_(e){const[r,a]=v.useState(void 0);return It(()=>{if(e){a({width:e.offsetWidth,height:e.offsetHeight});const l=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const s=o[0];let c,d;if("borderBoxSize"in s){const p=s.borderBoxSize,h=Array.isArray(p)?p[0]:p;c=h.inlineSize,d=h.blockSize}else c=e.offsetWidth,d=e.offsetHeight;a({width:c,height:d})});return l.observe(e,{box:"border-box"}),()=>l.unobserve(e)}else a(void 0)},[e]),r}const o_=["top","right","bottom","left"],Na=Math.min,An=Math.max,pc=Math.round,Yu=Math.floor,hr=e=>({x:e,y:e}),s_={left:"right",right:"left",bottom:"top",top:"bottom"};function Ah(e,r,a){return An(e,Na(r,a))}function Gr(e,r){return typeof e=="function"?e(r):e}function Yr(e){return e.split("-")[0]}function ji(e){return e.split("-")[1]}function hm(e){return e==="x"?"y":"x"}function mm(e){return e==="y"?"height":"width"}function pr(e){const r=e[0];return r==="t"||r==="b"?"y":"x"}function gm(e){return hm(pr(e))}function u_(e,r,a){a===void 0&&(a=!1);const l=ji(e),o=gm(e),s=mm(o);let c=o==="x"?l===(a?"end":"start")?"right":"left":l==="start"?"bottom":"top";return r.reference[s]>r.floating[s]&&(c=hc(c)),[c,hc(c)]}function c_(e){const r=hc(e);return[Nh(e),r,Nh(r)]}function Nh(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}const Dv=["left","right"],zv=["right","left"],d_=["top","bottom"],f_=["bottom","top"];function p_(e,r,a){switch(e){case"top":case"bottom":return a?r?zv:Dv:r?Dv:zv;case"left":case"right":return r?d_:f_;default:return[]}}function h_(e,r,a,l){const o=ji(e);let s=p_(Yr(e),a==="start",l);return o&&(s=s.map(c=>c+"-"+o),r&&(s=s.concat(s.map(Nh)))),s}function hc(e){const r=Yr(e);return s_[r]+e.slice(r.length)}function m_(e){return{top:0,right:0,bottom:0,left:0,...e}}function uw(e){return typeof e!="number"?m_(e):{top:e,right:e,bottom:e,left:e}}function mc(e){const{x:r,y:a,width:l,height:o}=e;return{width:l,height:o,top:a,left:r,right:r+l,bottom:a+o,x:r,y:a}}function Lv(e,r,a){let{reference:l,floating:o}=e;const s=pr(r),c=gm(r),d=mm(c),p=Yr(r),h=s==="y",y=l.x+l.width/2-o.width/2,g=l.y+l.height/2-o.height/2,b=l[d]/2-o[d]/2;let w;switch(p){case"top":w={x:y,y:l.y-o.height};break;case"bottom":w={x:y,y:l.y+l.height};break;case"right":w={x:l.x+l.width,y:g};break;case"left":w={x:l.x-o.width,y:g};break;default:w={x:l.x,y:l.y}}switch(ji(r)){case"start":w[c]-=b*(a&&h?-1:1);break;case"end":w[c]+=b*(a&&h?-1:1);break}return w}async function g_(e,r){var a;r===void 0&&(r={});const{x:l,y:o,platform:s,rects:c,elements:d,strategy:p}=e,{boundary:h="clippingAncestors",rootBoundary:y="viewport",elementContext:g="floating",altBoundary:b=!1,padding:w=0}=Gr(r,e),k=uw(w),C=d[b?g==="floating"?"reference":"floating":g],A=mc(await s.getClippingRect({element:(a=await(s.isElement==null?void 0:s.isElement(C)))==null||a?C:C.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(d.floating)),boundary:h,rootBoundary:y,strategy:p})),N=g==="floating"?{x:l,y:o,width:c.floating.width,height:c.floating.height}:c.reference,j=await(s.getOffsetParent==null?void 0:s.getOffsetParent(d.floating)),O=await(s.isElement==null?void 0:s.isElement(j))?await(s.getScale==null?void 0:s.getScale(j))||{x:1,y:1}:{x:1,y:1},D=mc(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:d,rect:N,offsetParent:j,strategy:p}):N);return{top:(A.top-D.top+k.top)/O.y,bottom:(D.bottom-A.bottom+k.bottom)/O.y,left:(A.left-D.left+k.left)/O.x,right:(D.right-A.right+k.right)/O.x}}const y_=50,x_=async(e,r,a)=>{const{placement:l="bottom",strategy:o="absolute",middleware:s=[],platform:c}=a,d=c.detectOverflow?c:{...c,detectOverflow:g_},p=await(c.isRTL==null?void 0:c.isRTL(r));let h=await c.getElementRects({reference:e,floating:r,strategy:o}),{x:y,y:g}=Lv(h,l,p),b=l,w=0;const k={};for(let S=0;S<s.length;S++){const C=s[S];if(!C)continue;const{name:A,fn:N}=C,{x:j,y:O,data:D,reset:M}=await N({x:y,y:g,initialPlacement:l,placement:b,strategy:o,middlewareData:k,rects:h,platform:d,elements:{reference:e,floating:r}});y=j!=null?j:y,g=O!=null?O:g,k[A]={...k[A],...D},M&&w<y_&&(w++,typeof M=="object"&&(M.placement&&(b=M.placement),M.rects&&(h=M.rects===!0?await c.getElementRects({reference:e,floating:r,strategy:o}):M.rects),{x:y,y:g}=Lv(h,b,p)),S=-1)}return{x:y,y:g,placement:b,strategy:o,middlewareData:k}},b_=e=>({name:"arrow",options:e,async fn(r){const{x:a,y:l,placement:o,rects:s,platform:c,elements:d,middlewareData:p}=r,{element:h,padding:y=0}=Gr(e,r)||{};if(h==null)return{};const g=uw(y),b={x:a,y:l},w=gm(o),k=mm(w),S=await c.getDimensions(h),C=w==="y",A=C?"top":"left",N=C?"bottom":"right",j=C?"clientHeight":"clientWidth",O=s.reference[k]+s.reference[w]-b[w]-s.floating[k],D=b[w]-s.reference[w],M=await(c.getOffsetParent==null?void 0:c.getOffsetParent(h));let U=M?M[j]:0;(!U||!await(c.isElement==null?void 0:c.isElement(M)))&&(U=d.floating[j]||s.floating[k]);const F=O/2-D/2,Q=U/2-S[k]/2-1,I=Na(g[A],Q),Y=Na(g[N],Q),V=I,ue=U-S[k]-Y,W=U/2-S[k]/2+F,J=Ah(V,W,ue),B=!p.arrow&&ji(o)!=null&&W!==J&&s.reference[k]/2-(W<V?I:Y)-S[k]/2<0,G=B?W<V?W-V:W-ue:0;return{[w]:b[w]+G,data:{[w]:J,centerOffset:W-J-G,...B&&{alignmentOffset:G}},reset:B}}}),v_=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(r){var a,l;const{placement:o,middlewareData:s,rects:c,initialPlacement:d,platform:p,elements:h}=r,{mainAxis:y=!0,crossAxis:g=!0,fallbackPlacements:b,fallbackStrategy:w="bestFit",fallbackAxisSideDirection:k="none",flipAlignment:S=!0,...C}=Gr(e,r);if((a=s.arrow)!=null&&a.alignmentOffset)return{};const A=Yr(o),N=pr(d),j=Yr(d)===d,O=await(p.isRTL==null?void 0:p.isRTL(h.floating)),D=b||(j||!S?[hc(d)]:c_(d)),M=k!=="none";!b&&M&&D.push(...h_(d,S,k,O));const U=[d,...D],F=await p.detectOverflow(r,C),Q=[];let I=((l=s.flip)==null?void 0:l.overflows)||[];if(y&&Q.push(F[A]),g){const W=u_(o,c,O);Q.push(F[W[0]],F[W[1]])}if(I=[...I,{placement:o,overflows:Q}],!Q.every(W=>W<=0)){var Y,V;const W=(((Y=s.flip)==null?void 0:Y.index)||0)+1,J=U[W];if(J&&(!(g==="alignment"?N!==pr(J):!1)||I.every(te=>pr(te.placement)===N?te.overflows[0]>0:!0)))return{data:{index:W,overflows:I},reset:{placement:J}};let B=(V=I.filter(G=>G.overflows[0]<=0).sort((G,te)=>G.overflows[1]-te.overflows[1])[0])==null?void 0:V.placement;if(!B)switch(w){case"bestFit":{var ue;const G=(ue=I.filter(te=>{if(M){const ce=pr(te.placement);return ce===N||ce==="y"}return!0}).map(te=>[te.placement,te.overflows.filter(ce=>ce>0).reduce((ce,R)=>ce+R,0)]).sort((te,ce)=>te[1]-ce[1])[0])==null?void 0:ue[0];G&&(B=G);break}case"initialPlacement":B=d;break}if(o!==B)return{reset:{placement:B}}}return{}}}};function Iv(e,r){return{top:e.top-r.height,right:e.right-r.width,bottom:e.bottom-r.height,left:e.left-r.width}}function Bv(e){return o_.some(r=>e[r]>=0)}const w_=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(r){const{rects:a,platform:l}=r,{strategy:o="referenceHidden",...s}=Gr(e,r);switch(o){case"referenceHidden":{const c=await l.detectOverflow(r,{...s,elementContext:"reference"}),d=Iv(c,a.reference);return{data:{referenceHiddenOffsets:d,referenceHidden:Bv(d)}}}case"escaped":{const c=await l.detectOverflow(r,{...s,altBoundary:!0}),d=Iv(c,a.floating);return{data:{escapedOffsets:d,escaped:Bv(d)}}}default:return{}}}}},cw=new Set(["left","top"]);async function S_(e,r){const{placement:a,platform:l,elements:o}=e,s=await(l.isRTL==null?void 0:l.isRTL(o.floating)),c=Yr(a),d=ji(a),p=pr(a)==="y",h=cw.has(c)?-1:1,y=s&&p?-1:1,g=Gr(r,e);let{mainAxis:b,crossAxis:w,alignmentAxis:k}=typeof g=="number"?{mainAxis:g,crossAxis:0,alignmentAxis:null}:{mainAxis:g.mainAxis||0,crossAxis:g.crossAxis||0,alignmentAxis:g.alignmentAxis};return d&&typeof k=="number"&&(w=d==="end"?k*-1:k),p?{x:w*y,y:b*h}:{x:b*h,y:w*y}}const k_=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(r){var a,l;const{x:o,y:s,placement:c,middlewareData:d}=r,p=await S_(r,e);return c===((a=d.offset)==null?void 0:a.placement)&&(l=d.arrow)!=null&&l.alignmentOffset?{}:{x:o+p.x,y:s+p.y,data:{...p,placement:c}}}}},E_=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(r){const{x:a,y:l,placement:o,platform:s}=r,{mainAxis:c=!0,crossAxis:d=!1,limiter:p={fn:A=>{let{x:N,y:j}=A;return{x:N,y:j}}},...h}=Gr(e,r),y={x:a,y:l},g=await s.detectOverflow(r,h),b=pr(Yr(o)),w=hm(b);let k=y[w],S=y[b];if(c){const A=w==="y"?"top":"left",N=w==="y"?"bottom":"right",j=k+g[A],O=k-g[N];k=Ah(j,k,O)}if(d){const A=b==="y"?"top":"left",N=b==="y"?"bottom":"right",j=S+g[A],O=S-g[N];S=Ah(j,S,O)}const C=p.fn({...r,[w]:k,[b]:S});return{...C,data:{x:C.x-a,y:C.y-l,enabled:{[w]:c,[b]:d}}}}}},C_=function(e){return e===void 0&&(e={}),{options:e,fn(r){const{x:a,y:l,placement:o,rects:s,middlewareData:c}=r,{offset:d=0,mainAxis:p=!0,crossAxis:h=!0}=Gr(e,r),y={x:a,y:l},g=pr(o),b=hm(g);let w=y[b],k=y[g];const S=Gr(d,r),C=typeof S=="number"?{mainAxis:S,crossAxis:0}:{mainAxis:0,crossAxis:0,...S};if(p){const j=b==="y"?"height":"width",O=s.reference[b]-s.floating[j]+C.mainAxis,D=s.reference[b]+s.reference[j]-C.mainAxis;w<O?w=O:w>D&&(w=D)}if(h){var A,N;const j=b==="y"?"width":"height",O=cw.has(Yr(o)),D=s.reference[g]-s.floating[j]+(O&&((A=c.offset)==null?void 0:A[g])||0)+(O?0:C.crossAxis),M=s.reference[g]+s.reference[j]+(O?0:((N=c.offset)==null?void 0:N[g])||0)-(O?C.crossAxis:0);k<D?k=D:k>M&&(k=M)}return{[b]:w,[g]:k}}}},A_=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(r){var a,l;const{placement:o,rects:s,platform:c,elements:d}=r,{apply:p=()=>{},...h}=Gr(e,r),y=await c.detectOverflow(r,h),g=Yr(o),b=ji(o),w=pr(o)==="y",{width:k,height:S}=s.floating;let C,A;g==="top"||g==="bottom"?(C=g,A=b===(await(c.isRTL==null?void 0:c.isRTL(d.floating))?"start":"end")?"left":"right"):(A=g,C=b==="end"?"top":"bottom");const N=S-y.top-y.bottom,j=k-y.left-y.right,O=Na(S-y[C],N),D=Na(k-y[A],j),M=!r.middlewareData.shift;let U=O,F=D;if((a=r.middlewareData.shift)!=null&&a.enabled.x&&(F=j),(l=r.middlewareData.shift)!=null&&l.enabled.y&&(U=N),M&&!b){const I=An(y.left,0),Y=An(y.right,0),V=An(y.top,0),ue=An(y.bottom,0);w?F=k-2*(I!==0||Y!==0?I+Y:An(y.left,y.right)):U=S-2*(V!==0||ue!==0?V+ue:An(y.top,y.bottom))}await p({...r,availableWidth:F,availableHeight:U});const Q=await c.getDimensions(d.floating);return k!==Q.width||S!==Q.height?{reset:{rects:!0}}:{}}}};function Fc(){return typeof window<"u"}function Ti(e){return dw(e)?(e.nodeName||"").toLowerCase():"#document"}function jn(e){var r;return(e==null||(r=e.ownerDocument)==null?void 0:r.defaultView)||window}function gr(e){var r;return(r=(dw(e)?e.ownerDocument:e.document)||window.document)==null?void 0:r.documentElement}function dw(e){return Fc()?e instanceof Node||e instanceof jn(e).Node:!1}function nr(e){return Fc()?e instanceof Element||e instanceof jn(e).Element:!1}function Xr(e){return Fc()?e instanceof HTMLElement||e instanceof jn(e).HTMLElement:!1}function Pv(e){return!Fc()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof jn(e).ShadowRoot}function cs(e){const{overflow:r,overflowX:a,overflowY:l,display:o}=rr(e);return/auto|scroll|overlay|hidden|clip/.test(r+l+a)&&o!=="inline"&&o!=="contents"}function N_(e){return/^(table|td|th)$/.test(Ti(e))}function Uc(e){try{if(e.matches(":popover-open"))return!0}catch{}try{return e.matches(":modal")}catch{return!1}}const j_=/transform|translate|scale|rotate|perspective|filter/,T_=/paint|layout|strict|content/,ll=e=>!!e&&e!=="none";let Gp;function ym(e){const r=nr(e)?rr(e):e;return ll(r.transform)||ll(r.translate)||ll(r.scale)||ll(r.rotate)||ll(r.perspective)||!xm()&&(ll(r.backdropFilter)||ll(r.filter))||j_.test(r.willChange||"")||T_.test(r.contain||"")}function __(e){let r=ja(e);for(;Xr(r)&&!bi(r);){if(ym(r))return r;if(Uc(r))return null;r=ja(r)}return null}function xm(){return Gp==null&&(Gp=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),Gp}function bi(e){return/^(html|body|#document)$/.test(Ti(e))}function rr(e){return jn(e).getComputedStyle(e)}function Hc(e){return nr(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function ja(e){if(Ti(e)==="html")return e;const r=e.assignedSlot||e.parentNode||Pv(e)&&e.host||gr(e);return Pv(r)?r.host:r}function fw(e){const r=ja(e);return bi(r)?e.ownerDocument?e.ownerDocument.body:e.body:Xr(r)&&cs(r)?r:fw(r)}function Vo(e,r,a){var l;r===void 0&&(r=[]),a===void 0&&(a=!0);const o=fw(e),s=o===((l=e.ownerDocument)==null?void 0:l.body),c=jn(o);if(s){const d=jh(c);return r.concat(c,c.visualViewport||[],cs(o)?o:[],d&&a?Vo(d):[])}else return r.concat(o,Vo(o,[],a))}function jh(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function pw(e){const r=rr(e);let a=parseFloat(r.width)||0,l=parseFloat(r.height)||0;const o=Xr(e),s=o?e.offsetWidth:a,c=o?e.offsetHeight:l,d=pc(a)!==s||pc(l)!==c;return d&&(a=s,l=c),{width:a,height:l,$:d}}function bm(e){return nr(e)?e:e.contextElement}function mi(e){const r=bm(e);if(!Xr(r))return hr(1);const a=r.getBoundingClientRect(),{width:l,height:o,$:s}=pw(r);let c=(s?pc(a.width):a.width)/l,d=(s?pc(a.height):a.height)/o;return(!c||!Number.isFinite(c))&&(c=1),(!d||!Number.isFinite(d))&&(d=1),{x:c,y:d}}const R_=hr(0);function hw(e){const r=jn(e);return!xm()||!r.visualViewport?R_:{x:r.visualViewport.offsetLeft,y:r.visualViewport.offsetTop}}function M_(e,r,a){return r===void 0&&(r=!1),!a||r&&a!==jn(e)?!1:r}function fl(e,r,a,l){r===void 0&&(r=!1),a===void 0&&(a=!1);const o=e.getBoundingClientRect(),s=bm(e);let c=hr(1);r&&(l?nr(l)&&(c=mi(l)):c=mi(e));const d=M_(s,a,l)?hw(s):hr(0);let p=(o.left+d.x)/c.x,h=(o.top+d.y)/c.y,y=o.width/c.x,g=o.height/c.y;if(s){const b=jn(s),w=l&&nr(l)?jn(l):l;let k=b,S=jh(k);for(;S&&l&&w!==k;){const C=mi(S),A=S.getBoundingClientRect(),N=rr(S),j=A.left+(S.clientLeft+parseFloat(N.paddingLeft))*C.x,O=A.top+(S.clientTop+parseFloat(N.paddingTop))*C.y;p*=C.x,h*=C.y,y*=C.x,g*=C.y,p+=j,h+=O,k=jn(S),S=jh(k)}}return mc({width:y,height:g,x:p,y:h})}function Vc(e,r){const a=Hc(e).scrollLeft;return r?r.left+a:fl(gr(e)).left+a}function mw(e,r){const a=e.getBoundingClientRect(),l=a.left+r.scrollLeft-Vc(e,a),o=a.top+r.scrollTop;return{x:l,y:o}}function O_(e){let{elements:r,rect:a,offsetParent:l,strategy:o}=e;const s=o==="fixed",c=gr(l),d=r?Uc(r.floating):!1;if(l===c||d&&s)return a;let p={scrollLeft:0,scrollTop:0},h=hr(1);const y=hr(0),g=Xr(l);if((g||!g&&!s)&&((Ti(l)!=="body"||cs(c))&&(p=Hc(l)),g)){const w=fl(l);h=mi(l),y.x=w.x+l.clientLeft,y.y=w.y+l.clientTop}const b=c&&!g&&!s?mw(c,p):hr(0);return{width:a.width*h.x,height:a.height*h.y,x:a.x*h.x-p.scrollLeft*h.x+y.x+b.x,y:a.y*h.y-p.scrollTop*h.y+y.y+b.y}}function D_(e){return Array.from(e.getClientRects())}function z_(e){const r=gr(e),a=Hc(e),l=e.ownerDocument.body,o=An(r.scrollWidth,r.clientWidth,l.scrollWidth,l.clientWidth),s=An(r.scrollHeight,r.clientHeight,l.scrollHeight,l.clientHeight);let c=-a.scrollLeft+Vc(e);const d=-a.scrollTop;return rr(l).direction==="rtl"&&(c+=An(r.clientWidth,l.clientWidth)-o),{width:o,height:s,x:c,y:d}}const Fv=25;function L_(e,r){const a=jn(e),l=gr(e),o=a.visualViewport;let s=l.clientWidth,c=l.clientHeight,d=0,p=0;if(o){s=o.width,c=o.height;const y=xm();(!y||y&&r==="fixed")&&(d=o.offsetLeft,p=o.offsetTop)}const h=Vc(l);if(h<=0){const y=l.ownerDocument,g=y.body,b=getComputedStyle(g),w=y.compatMode==="CSS1Compat"&&parseFloat(b.marginLeft)+parseFloat(b.marginRight)||0,k=Math.abs(l.clientWidth-g.clientWidth-w);k<=Fv&&(s-=k)}else h<=Fv&&(s+=h);return{width:s,height:c,x:d,y:p}}function I_(e,r){const a=fl(e,!0,r==="fixed"),l=a.top+e.clientTop,o=a.left+e.clientLeft,s=Xr(e)?mi(e):hr(1),c=e.clientWidth*s.x,d=e.clientHeight*s.y,p=o*s.x,h=l*s.y;return{width:c,height:d,x:p,y:h}}function Uv(e,r,a){let l;if(r==="viewport")l=L_(e,a);else if(r==="document")l=z_(gr(e));else if(nr(r))l=I_(r,a);else{const o=hw(e);l={x:r.x-o.x,y:r.y-o.y,width:r.width,height:r.height}}return mc(l)}function gw(e,r){const a=ja(e);return a===r||!nr(a)||bi(a)?!1:rr(a).position==="fixed"||gw(a,r)}function B_(e,r){const a=r.get(e);if(a)return a;let l=Vo(e,[],!1).filter(d=>nr(d)&&Ti(d)!=="body"),o=null;const s=rr(e).position==="fixed";let c=s?ja(e):e;for(;nr(c)&&!bi(c);){const d=rr(c),p=ym(c);!p&&d.position==="fixed"&&(o=null),(s?!p&&!o:!p&&d.position==="static"&&!!o&&(o.position==="absolute"||o.position==="fixed")||cs(c)&&!p&&gw(e,c))?l=l.filter(y=>y!==c):o=d,c=ja(c)}return r.set(e,l),l}function P_(e){let{element:r,boundary:a,rootBoundary:l,strategy:o}=e;const c=[...a==="clippingAncestors"?Uc(r)?[]:B_(r,this._c):[].concat(a),l],d=Uv(r,c[0],o);let p=d.top,h=d.right,y=d.bottom,g=d.left;for(let b=1;b<c.length;b++){const w=Uv(r,c[b],o);p=An(w.top,p),h=Na(w.right,h),y=Na(w.bottom,y),g=An(w.left,g)}return{width:h-g,height:y-p,x:g,y:p}}function F_(e){const{width:r,height:a}=pw(e);return{width:r,height:a}}function U_(e,r,a){const l=Xr(r),o=gr(r),s=a==="fixed",c=fl(e,!0,s,r);let d={scrollLeft:0,scrollTop:0};const p=hr(0);function h(){p.x=Vc(o)}if(l||!l&&!s)if((Ti(r)!=="body"||cs(o))&&(d=Hc(r)),l){const w=fl(r,!0,s,r);p.x=w.x+r.clientLeft,p.y=w.y+r.clientTop}else o&&h();s&&!l&&o&&h();const y=o&&!l&&!s?mw(o,d):hr(0),g=c.left+d.scrollLeft-p.x-y.x,b=c.top+d.scrollTop-p.y-y.y;return{x:g,y:b,width:c.width,height:c.height}}function Yp(e){return rr(e).position==="static"}function Hv(e,r){if(!Xr(e)||rr(e).position==="fixed")return null;if(r)return r(e);let a=e.offsetParent;return gr(e)===a&&(a=a.ownerDocument.body),a}function yw(e,r){const a=jn(e);if(Uc(e))return a;if(!Xr(e)){let o=ja(e);for(;o&&!bi(o);){if(nr(o)&&!Yp(o))return o;o=ja(o)}return a}let l=Hv(e,r);for(;l&&N_(l)&&Yp(l);)l=Hv(l,r);return l&&bi(l)&&Yp(l)&&!ym(l)?a:l||__(e)||a}const H_=async function(e){const r=this.getOffsetParent||yw,a=this.getDimensions,l=await a(e.floating);return{reference:U_(e.reference,await r(e.floating),e.strategy),floating:{x:0,y:0,width:l.width,height:l.height}}};function V_(e){return rr(e).direction==="rtl"}const $_={convertOffsetParentRelativeRectToViewportRelativeRect:O_,getDocumentElement:gr,getClippingRect:P_,getOffsetParent:yw,getElementRects:H_,getClientRects:D_,getDimensions:F_,getScale:mi,isElement:nr,isRTL:V_};function xw(e,r){return e.x===r.x&&e.y===r.y&&e.width===r.width&&e.height===r.height}function q_(e,r){let a=null,l;const o=gr(e);function s(){var d;clearTimeout(l),(d=a)==null||d.disconnect(),a=null}function c(d,p){d===void 0&&(d=!1),p===void 0&&(p=1),s();const h=e.getBoundingClientRect(),{left:y,top:g,width:b,height:w}=h;if(d||r(),!b||!w)return;const k=Yu(g),S=Yu(o.clientWidth-(y+b)),C=Yu(o.clientHeight-(g+w)),A=Yu(y),j={rootMargin:-k+"px "+-S+"px "+-C+"px "+-A+"px",threshold:An(0,Na(1,p))||1};let O=!0;function D(M){const U=M[0].intersectionRatio;if(U!==p){if(!O)return c();U?c(!1,U):l=setTimeout(()=>{c(!1,1e-7)},1e3)}U===1&&!xw(h,e.getBoundingClientRect())&&c(),O=!1}try{a=new IntersectionObserver(D,{...j,root:o.ownerDocument})}catch{a=new IntersectionObserver(D,j)}a.observe(e)}return c(!0),s}function G_(e,r,a,l){l===void 0&&(l={});const{ancestorScroll:o=!0,ancestorResize:s=!0,elementResize:c=typeof ResizeObserver=="function",layoutShift:d=typeof IntersectionObserver=="function",animationFrame:p=!1}=l,h=bm(e),y=o||s?[...h?Vo(h):[],...r?Vo(r):[]]:[];y.forEach(A=>{o&&A.addEventListener("scroll",a,{passive:!0}),s&&A.addEventListener("resize",a)});const g=h&&d?q_(h,a):null;let b=-1,w=null;c&&(w=new ResizeObserver(A=>{let[N]=A;N&&N.target===h&&w&&r&&(w.unobserve(r),cancelAnimationFrame(b),b=requestAnimationFrame(()=>{var j;(j=w)==null||j.observe(r)})),a()}),h&&!p&&w.observe(h),r&&w.observe(r));let k,S=p?fl(e):null;p&&C();function C(){const A=fl(e);S&&!xw(S,A)&&a(),S=A,k=requestAnimationFrame(C)}return a(),()=>{var A;y.forEach(N=>{o&&N.removeEventListener("scroll",a),s&&N.removeEventListener("resize",a)}),g==null||g(),(A=w)==null||A.disconnect(),w=null,p&&cancelAnimationFrame(k)}}const Y_=k_,X_=E_,K_=v_,Q_=A_,Z_=w_,Vv=b_,W_=C_,J_=(e,r,a)=>{const l=new Map,o={platform:$_,...a},s={...o.platform,_c:l};return x_(e,r,{...o,platform:s})};var eR=typeof document<"u",tR=function(){},ac=eR?v.useLayoutEffect:tR;function gc(e,r){if(e===r)return!0;if(typeof e!=typeof r)return!1;if(typeof e=="function"&&e.toString()===r.toString())return!0;let a,l,o;if(e&&r&&typeof e=="object"){if(Array.isArray(e)){if(a=e.length,a!==r.length)return!1;for(l=a;l--!==0;)if(!gc(e[l],r[l]))return!1;return!0}if(o=Object.keys(e),a=o.length,a!==Object.keys(r).length)return!1;for(l=a;l--!==0;)if(!{}.hasOwnProperty.call(r,o[l]))return!1;for(l=a;l--!==0;){const s=o[l];if(!(s==="_owner"&&e.$$typeof)&&!gc(e[s],r[s]))return!1}return!0}return e!==e&&r!==r}function bw(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function $v(e,r){const a=bw(e);return Math.round(r*a)/a}function Xp(e){const r=v.useRef(e);return ac(()=>{r.current=e}),r}function nR(e){e===void 0&&(e={});const{placement:r="bottom",strategy:a="absolute",middleware:l=[],platform:o,elements:{reference:s,floating:c}={},transform:d=!0,whileElementsMounted:p,open:h}=e,[y,g]=v.useState({x:0,y:0,strategy:a,placement:r,middlewareData:{},isPositioned:!1}),[b,w]=v.useState(l);gc(b,l)||w(l);const[k,S]=v.useState(null),[C,A]=v.useState(null),N=v.useCallback(te=>{te!==M.current&&(M.current=te,S(te))},[]),j=v.useCallback(te=>{te!==U.current&&(U.current=te,A(te))},[]),O=s||k,D=c||C,M=v.useRef(null),U=v.useRef(null),F=v.useRef(y),Q=p!=null,I=Xp(p),Y=Xp(o),V=Xp(h),ue=v.useCallback(()=>{if(!M.current||!U.current)return;const te={placement:r,strategy:a,middleware:b};Y.current&&(te.platform=Y.current),J_(M.current,U.current,te).then(ce=>{const R={...ce,isPositioned:V.current!==!1};W.current&&!gc(F.current,R)&&(F.current=R,ls.flushSync(()=>{g(R)}))})},[b,r,a,Y,V]);ac(()=>{h===!1&&F.current.isPositioned&&(F.current.isPositioned=!1,g(te=>({...te,isPositioned:!1})))},[h]);const W=v.useRef(!1);ac(()=>(W.current=!0,()=>{W.current=!1}),[]),ac(()=>{if(O&&(M.current=O),D&&(U.current=D),O&&D){if(I.current)return I.current(O,D,ue);ue()}},[O,D,ue,I,Q]);const J=v.useMemo(()=>({reference:M,floating:U,setReference:N,setFloating:j}),[N,j]),B=v.useMemo(()=>({reference:O,floating:D}),[O,D]),G=v.useMemo(()=>{const te={position:a,left:0,top:0};if(!B.floating)return te;const ce=$v(B.floating,y.x),R=$v(B.floating,y.y);return d?{...te,transform:"translate("+ce+"px, "+R+"px)",...bw(B.floating)>=1.5&&{willChange:"transform"}}:{position:a,left:ce,top:R}},[a,d,B.floating,y.x,y.y]);return v.useMemo(()=>({...y,update:ue,refs:J,elements:B,floatingStyles:G}),[y,ue,J,B,G])}const rR=e=>{function r(a){return{}.hasOwnProperty.call(a,"current")}return{name:"arrow",options:e,fn(a){const{element:l,padding:o}=typeof e=="function"?e(a):e;return l&&r(l)?l.current!=null?Vv({element:l.current,padding:o}).fn(a):{}:l?Vv({element:l,padding:o}).fn(a):{}}}},aR=(e,r)=>{const a=Y_(e);return{name:a.name,fn:a.fn,options:[e,r]}},lR=(e,r)=>{const a=X_(e);return{name:a.name,fn:a.fn,options:[e,r]}},iR=(e,r)=>({fn:W_(e).fn,options:[e,r]}),oR=(e,r)=>{const a=K_(e);return{name:a.name,fn:a.fn,options:[e,r]}},sR=(e,r)=>{const a=Q_(e);return{name:a.name,fn:a.fn,options:[e,r]}},uR=(e,r)=>{const a=Z_(e);return{name:a.name,fn:a.fn,options:[e,r]}},cR=(e,r)=>{const a=rR(e);return{name:a.name,fn:a.fn,options:[e,r]}};var dR="Arrow",vw=v.forwardRef((e,r)=>{const{children:a,width:l=10,height:o=5,...s}=e;return f.jsx(Ce.svg,{...s,ref:r,width:l,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?a:f.jsx("polygon",{points:"0,0 30,0 15,10"})})});vw.displayName=dR;var fR=vw,vm="Popper",[ww,Ra]=_n(vm),[pR,Sw]=ww(vm),kw=e=>{const{__scopePopper:r,children:a}=e,[l,o]=v.useState(null);return f.jsx(pR,{scope:r,anchor:l,onAnchorChange:o,children:a})};kw.displayName=vm;var Ew="PopperAnchor",Cw=v.forwardRef((e,r)=>{const{__scopePopper:a,virtualRef:l,...o}=e,s=Sw(Ew,a),c=v.useRef(null),d=Ve(r,c),p=v.useRef(null);return v.useEffect(()=>{const h=p.current;p.current=(l==null?void 0:l.current)||c.current,h!==p.current&&s.onAnchorChange(p.current)}),l?null:f.jsx(Ce.div,{...o,ref:d})});Cw.displayName=Ew;var wm="PopperContent",[hR,mR]=ww(wm),Aw=v.forwardRef((e,r)=>{var le,be,he,Ne,De,ze,gt,nt;const{__scopePopper:a,side:l="bottom",sideOffset:o=0,align:s="center",alignOffset:c=0,arrowPadding:d=0,avoidCollisions:p=!0,collisionBoundary:h=[],collisionPadding:y=0,sticky:g="partial",hideWhenDetached:b=!1,updatePositionStrategy:w="optimized",onPlaced:k,...S}=e,C=Sw(wm,a),[A,N]=v.useState(null),j=Ve(r,Ot=>N(Ot)),[O,D]=v.useState(null),M=i_(O),U=(le=M==null?void 0:M.width)!=null?le:0,F=(be=M==null?void 0:M.height)!=null?be:0,Q=l+(s!=="center"?"-"+s:""),I=typeof y=="number"?y:{top:0,right:0,bottom:0,left:0,...y},Y=Array.isArray(h)?h:[h],V=Y.length>0,ue={padding:I,boundary:Y.filter(yR),altBoundary:V},{refs:W,floatingStyles:J,placement:B,isPositioned:G,middlewareData:te}=nR({strategy:"fixed",placement:Q,whileElementsMounted:(...Ot)=>G_(...Ot,{animationFrame:w==="always"}),elements:{reference:C.anchor},middleware:[aR({mainAxis:o+F,alignmentAxis:c}),p&&lR({mainAxis:!0,crossAxis:!1,limiter:g==="partial"?iR():void 0,...ue}),p&&oR({...ue}),sR({...ue,apply:({elements:Ot,rects:Jt,availableWidth:Gt,availableHeight:Rn})=>{const{width:Mn,height:an}=Jt.reference,On=Ot.floating.style;On.setProperty("--radix-popper-available-width",`${Gt}px`),On.setProperty("--radix-popper-available-height",`${Rn}px`),On.setProperty("--radix-popper-anchor-width",`${Mn}px`),On.setProperty("--radix-popper-anchor-height",`${an}px`)}}),O&&cR({element:O,padding:d}),xR({arrowWidth:U,arrowHeight:F}),b&&uR({strategy:"referenceHidden",...ue})]}),[ce,R]=Tw(B),z=qt(k);It(()=>{G&&(z==null||z())},[G,z]);const L=(he=te.arrow)==null?void 0:he.x,_=(Ne=te.arrow)==null?void 0:Ne.y,re=((De=te.arrow)==null?void 0:De.centerOffset)!==0,[ne,ie]=v.useState();return It(()=>{A&&ie(window.getComputedStyle(A).zIndex)},[A]),f.jsx("div",{ref:W.setFloating,"data-radix-popper-content-wrapper":"",style:{...J,transform:G?J.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:ne,"--radix-popper-transform-origin":[(ze=te.transformOrigin)==null?void 0:ze.x,(gt=te.transformOrigin)==null?void 0:gt.y].join(" "),...((nt=te.hide)==null?void 0:nt.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:f.jsx(hR,{scope:a,placedSide:ce,onArrowChange:D,arrowX:L,arrowY:_,shouldHideArrow:re,children:f.jsx(Ce.div,{"data-side":ce,"data-align":R,...S,ref:j,style:{...S.style,animation:G?void 0:"none"}})})})});Aw.displayName=wm;var Nw="PopperArrow",gR={top:"bottom",right:"left",bottom:"top",left:"right"},jw=v.forwardRef(function(r,a){const{__scopePopper:l,...o}=r,s=mR(Nw,l),c=gR[s.placedSide];return f.jsx("span",{ref:s.onArrowChange,style:{position:"absolute",left:s.arrowX,top:s.arrowY,[c]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[s.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[s.placedSide],visibility:s.shouldHideArrow?"hidden":void 0},children:f.jsx(fR,{...o,ref:a,style:{...o.style,display:"block"}})})});jw.displayName=Nw;function yR(e){return e!==null}var xR=e=>({name:"transformOrigin",options:e,fn(r){var C,A,N,j,O;const{placement:a,rects:l,middlewareData:o}=r,c=((C=o.arrow)==null?void 0:C.centerOffset)!==0,d=c?0:e.arrowWidth,p=c?0:e.arrowHeight,[h,y]=Tw(a),g={start:"0%",center:"50%",end:"100%"}[y],b=((N=(A=o.arrow)==null?void 0:A.x)!=null?N:0)+d/2,w=((O=(j=o.arrow)==null?void 0:j.y)!=null?O:0)+p/2;let k="",S="";return h==="bottom"?(k=c?g:`${b}px`,S=`${-p}px`):h==="top"?(k=c?g:`${b}px`,S=`${l.floating.height+p}px`):h==="right"?(k=`${-p}px`,S=c?g:`${w}px`):h==="left"&&(k=`${l.floating.width+p}px`,S=c?g:`${w}px`),{data:{x:k,y:S}}}});function Tw(e){const[r,a="center"]=e.split("-");return[r,a]}var $c=kw,ds=Cw,qc=Aw,Gc=jw,Kp="rovingFocusGroup.onEntryFocus",bR={bubbles:!1,cancelable:!0},fs="RovingFocusGroup",[Th,_w,vR]=nm(fs),[wR,Yc]=_n(fs,[vR]),[SR,kR]=wR(fs),Rw=v.forwardRef((e,r)=>f.jsx(Th.Provider,{scope:e.__scopeRovingFocusGroup,children:f.jsx(Th.Slot,{scope:e.__scopeRovingFocusGroup,children:f.jsx(ER,{...e,ref:r})})}));Rw.displayName=fs;var ER=v.forwardRef((e,r)=>{const{__scopeRovingFocusGroup:a,orientation:l,loop:o=!1,dir:s,currentTabStopId:c,defaultCurrentTabStopId:d,onCurrentTabStopIdChange:p,onEntryFocus:h,preventScrollOnEntryFocus:y=!1,...g}=e,b=v.useRef(null),w=Ve(r,b),k=os(s),[S,C]=qr({prop:c,defaultProp:d!=null?d:null,onChange:p,caller:fs}),[A,N]=v.useState(!1),j=qt(h),O=_w(a),D=v.useRef(!1),[M,U]=v.useState(0);return v.useEffect(()=>{const F=b.current;if(F)return F.addEventListener(Kp,j),()=>F.removeEventListener(Kp,j)},[j]),f.jsx(SR,{scope:a,orientation:l,dir:k,loop:o,currentTabStopId:S,onItemFocus:v.useCallback(F=>C(F),[C]),onItemShiftTab:v.useCallback(()=>N(!0),[]),onFocusableItemAdd:v.useCallback(()=>U(F=>F+1),[]),onFocusableItemRemove:v.useCallback(()=>U(F=>F-1),[]),children:f.jsx(Ce.div,{tabIndex:A||M===0?-1:0,"data-orientation":l,...g,ref:w,style:{outline:"none",...e.style},onMouseDown:ve(e.onMouseDown,()=>{D.current=!0}),onFocus:ve(e.onFocus,F=>{const Q=!D.current;if(F.target===F.currentTarget&&Q&&!A){const I=new CustomEvent(Kp,bR);if(F.currentTarget.dispatchEvent(I),!I.defaultPrevented){const Y=O().filter(B=>B.focusable),V=Y.find(B=>B.active),ue=Y.find(B=>B.id===S),J=[V,ue,...Y].filter(Boolean).map(B=>B.ref.current);Dw(J,y)}}D.current=!1}),onBlur:ve(e.onBlur,()=>N(!1))})})}),Mw="RovingFocusGroupItem",Ow=v.forwardRef((e,r)=>{const{__scopeRovingFocusGroup:a,focusable:l=!0,active:o=!1,tabStopId:s,children:c,...d}=e,p=Mt(),h=s||p,y=kR(Mw,a),g=y.currentTabStopId===h,b=_w(a),{onFocusableItemAdd:w,onFocusableItemRemove:k,currentTabStopId:S}=y;return v.useEffect(()=>{if(l)return w(),()=>k()},[l,w,k]),f.jsx(Th.ItemSlot,{scope:a,id:h,focusable:l,active:o,children:f.jsx(Ce.span,{tabIndex:g?0:-1,"data-orientation":y.orientation,...d,ref:r,onMouseDown:ve(e.onMouseDown,C=>{l?y.onItemFocus(h):C.preventDefault()}),onFocus:ve(e.onFocus,()=>y.onItemFocus(h)),onKeyDown:ve(e.onKeyDown,C=>{if(C.key==="Tab"&&C.shiftKey){y.onItemShiftTab();return}if(C.target!==C.currentTarget)return;const A=NR(C,y.orientation,y.dir);if(A!==void 0){if(C.metaKey||C.ctrlKey||C.altKey||C.shiftKey)return;C.preventDefault();let j=b().filter(O=>O.focusable).map(O=>O.ref.current);if(A==="last")j.reverse();else if(A==="prev"||A==="next"){A==="prev"&&j.reverse();const O=j.indexOf(C.currentTarget);j=y.loop?jR(j,O+1):j.slice(O+1)}setTimeout(()=>Dw(j))}}),children:typeof c=="function"?c({isCurrentTabStop:g,hasTabStop:S!=null}):c})})});Ow.displayName=Mw;var CR={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function AR(e,r){return r!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function NR(e,r,a){const l=AR(e.key,a);if(!(r==="vertical"&&["ArrowLeft","ArrowRight"].includes(l))&&!(r==="horizontal"&&["ArrowUp","ArrowDown"].includes(l)))return CR[l]}function Dw(e,r=!1){const a=document.activeElement;for(const l of e)if(l===a||(l.focus({preventScroll:r}),document.activeElement!==a))return}function jR(e,r){return e.map((a,l)=>e[(r+l)%e.length])}var zw=Rw,Lw=Ow,_h=["Enter"," "],TR=["ArrowDown","PageUp","Home"],Iw=["ArrowUp","PageDown","End"],_R=[...TR,...Iw],RR={ltr:[..._h,"ArrowRight"],rtl:[..._h,"ArrowLeft"]},MR={ltr:["ArrowLeft"],rtl:["ArrowRight"]},ps="Menu",[$o,OR,DR]=nm(ps),[yl,Bw]=_n(ps,[DR,Ra,Yc]),Xc=Ra(),Pw=Yc(),[zR,xl]=yl(ps),[LR,hs]=yl(ps),Fw=e=>{const{__scopeMenu:r,open:a=!1,children:l,dir:o,onOpenChange:s,modal:c=!0}=e,d=Xc(r),[p,h]=v.useState(null),y=v.useRef(!1),g=qt(s),b=os(o);return v.useEffect(()=>{const w=()=>{y.current=!0,document.addEventListener("pointerdown",k,{capture:!0,once:!0}),document.addEventListener("pointermove",k,{capture:!0,once:!0})},k=()=>y.current=!1;return document.addEventListener("keydown",w,{capture:!0}),()=>{document.removeEventListener("keydown",w,{capture:!0}),document.removeEventListener("pointerdown",k,{capture:!0}),document.removeEventListener("pointermove",k,{capture:!0})}},[]),f.jsx($c,{...d,children:f.jsx(zR,{scope:r,open:a,onOpenChange:g,content:p,onContentChange:h,children:f.jsx(LR,{scope:r,onClose:v.useCallback(()=>g(!1),[g]),isUsingKeyboardRef:y,dir:b,modal:c,children:l})})})};Fw.displayName=ps;var IR="MenuAnchor",Sm=v.forwardRef((e,r)=>{const{__scopeMenu:a,...l}=e,o=Xc(a);return f.jsx(ds,{...o,...l,ref:r})});Sm.displayName=IR;var km="MenuPortal",[BR,Uw]=yl(km,{forceMount:void 0}),Hw=e=>{const{__scopeMenu:r,forceMount:a,children:l,container:o}=e,s=xl(km,r);return f.jsx(BR,{scope:r,forceMount:a,children:f.jsx(Bt,{present:a||s.open,children:f.jsx(Ni,{asChild:!0,container:o,children:l})})})};Hw.displayName=km;var Xn="MenuContent",[PR,Em]=yl(Xn),Vw=v.forwardRef((e,r)=>{const a=Uw(Xn,e.__scopeMenu),{forceMount:l=a.forceMount,...o}=e,s=xl(Xn,e.__scopeMenu),c=hs(Xn,e.__scopeMenu);return f.jsx($o.Provider,{scope:e.__scopeMenu,children:f.jsx(Bt,{present:l||s.open,children:f.jsx($o.Slot,{scope:e.__scopeMenu,children:c.modal?f.jsx(FR,{...o,ref:r}):f.jsx(UR,{...o,ref:r})})})})}),FR=v.forwardRef((e,r)=>{const a=xl(Xn,e.__scopeMenu),l=v.useRef(null),o=Ve(r,l);return v.useEffect(()=>{const s=l.current;if(s)return Bc(s)},[]),f.jsx(Cm,{...e,ref:o,trapFocus:a.open,disableOutsidePointerEvents:a.open,disableOutsideScroll:!0,onFocusOutside:ve(e.onFocusOutside,s=>s.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>a.onOpenChange(!1)})}),UR=v.forwardRef((e,r)=>{const a=xl(Xn,e.__scopeMenu);return f.jsx(Cm,{...e,ref:r,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>a.onOpenChange(!1)})}),HR=Aa("MenuContent.ScrollLock"),Cm=v.forwardRef((e,r)=>{const{__scopeMenu:a,loop:l=!1,trapFocus:o,onOpenAutoFocus:s,onCloseAutoFocus:c,disableOutsidePointerEvents:d,onEntryFocus:p,onEscapeKeyDown:h,onPointerDownOutside:y,onFocusOutside:g,onInteractOutside:b,onDismiss:w,disableOutsideScroll:k,...S}=e,C=xl(Xn,a),A=hs(Xn,a),N=Xc(a),j=Pw(a),O=OR(a),[D,M]=v.useState(null),U=v.useRef(null),F=Ve(r,U,C.onContentChange),Q=v.useRef(0),I=v.useRef(""),Y=v.useRef(0),V=v.useRef(null),ue=v.useRef("right"),W=v.useRef(0),J=k?us:v.Fragment,B=k?{as:HR,allowPinchZoom:!0}:void 0,G=ce=>{var le,be;const R=I.current+ce,z=O().filter(he=>!he.disabled),L=document.activeElement,_=(le=z.find(he=>he.ref.current===L))==null?void 0:le.textValue,re=z.map(he=>he.textValue),ne=eM(re,R,_),ie=(be=z.find(he=>he.textValue===ne))==null?void 0:be.ref.current;(function he(Ne){I.current=Ne,window.clearTimeout(Q.current),Ne!==""&&(Q.current=window.setTimeout(()=>he(""),1e3))})(R),ie&&setTimeout(()=>ie.focus())};v.useEffect(()=>()=>window.clearTimeout(Q.current),[]),Lc();const te=v.useCallback(ce=>{var z,L;return ue.current===((z=V.current)==null?void 0:z.side)&&nM(ce,(L=V.current)==null?void 0:L.area)},[]);return f.jsx(PR,{scope:a,searchRef:I,onItemEnter:v.useCallback(ce=>{te(ce)&&ce.preventDefault()},[te]),onItemLeave:v.useCallback(ce=>{var R;te(ce)||((R=U.current)==null||R.focus(),M(null))},[te]),onTriggerLeave:v.useCallback(ce=>{te(ce)&&ce.preventDefault()},[te]),pointerGraceTimerRef:Y,onPointerGraceIntentChange:v.useCallback(ce=>{V.current=ce},[]),children:f.jsx(J,{...B,children:f.jsx(ss,{asChild:!0,trapped:o,onMountAutoFocus:ve(s,ce=>{var R;ce.preventDefault(),(R=U.current)==null||R.focus({preventScroll:!0})}),onUnmountAutoFocus:c,children:f.jsx(Ai,{asChild:!0,disableOutsidePointerEvents:d,onEscapeKeyDown:h,onPointerDownOutside:y,onFocusOutside:g,onInteractOutside:b,onDismiss:w,children:f.jsx(zw,{asChild:!0,...j,dir:A.dir,orientation:"vertical",loop:l,currentTabStopId:D,onCurrentTabStopIdChange:M,onEntryFocus:ve(p,ce=>{A.isUsingKeyboardRef.current||ce.preventDefault()}),preventScrollOnEntryFocus:!0,children:f.jsx(qc,{role:"menu","aria-orientation":"vertical","data-state":lS(C.open),"data-radix-menu-content":"",dir:A.dir,...N,...S,ref:F,style:{outline:"none",...S.style},onKeyDown:ve(S.onKeyDown,ce=>{const z=ce.target.closest("[data-radix-menu-content]")===ce.currentTarget,L=ce.ctrlKey||ce.altKey||ce.metaKey,_=ce.key.length===1;z&&(ce.key==="Tab"&&ce.preventDefault(),!L&&_&&G(ce.key));const re=U.current;if(ce.target!==re||!_R.includes(ce.key))return;ce.preventDefault();const ie=O().filter(le=>!le.disabled).map(le=>le.ref.current);Iw.includes(ce.key)&&ie.reverse(),WR(ie)}),onBlur:ve(e.onBlur,ce=>{ce.currentTarget.contains(ce.target)||(window.clearTimeout(Q.current),I.current="")}),onPointerMove:ve(e.onPointerMove,qo(ce=>{const R=ce.target,z=W.current!==ce.clientX;if(ce.currentTarget.contains(R)&&z){const L=ce.clientX>W.current?"right":"left";ue.current=L,W.current=ce.clientX}}))})})})})})})});Vw.displayName=Xn;var VR="MenuGroup",Am=v.forwardRef((e,r)=>{const{__scopeMenu:a,...l}=e;return f.jsx(Ce.div,{role:"group",...l,ref:r})});Am.displayName=VR;var $R="MenuLabel",$w=v.forwardRef((e,r)=>{const{__scopeMenu:a,...l}=e;return f.jsx(Ce.div,{...l,ref:r})});$w.displayName=$R;var yc="MenuItem",qv="menu.itemSelect",Kc=v.forwardRef((e,r)=>{const{disabled:a=!1,onSelect:l,...o}=e,s=v.useRef(null),c=hs(yc,e.__scopeMenu),d=Em(yc,e.__scopeMenu),p=Ve(r,s),h=v.useRef(!1),y=()=>{const g=s.current;if(!a&&g){const b=new CustomEvent(qv,{bubbles:!0,cancelable:!0});g.addEventListener(qv,w=>l==null?void 0:l(w),{once:!0}),N1(g,b),b.defaultPrevented?h.current=!1:c.onClose()}};return f.jsx(qw,{...o,ref:p,disabled:a,onClick:ve(e.onClick,y),onPointerDown:g=>{var b;(b=e.onPointerDown)==null||b.call(e,g),h.current=!0},onPointerUp:ve(e.onPointerUp,g=>{var b;h.current||(b=g.currentTarget)==null||b.click()}),onKeyDown:ve(e.onKeyDown,g=>{const b=d.searchRef.current!=="";a||b&&g.key===" "||_h.includes(g.key)&&(g.currentTarget.click(),g.preventDefault())})})});Kc.displayName=yc;var qw=v.forwardRef((e,r)=>{const{__scopeMenu:a,disabled:l=!1,textValue:o,...s}=e,c=Em(yc,a),d=Pw(a),p=v.useRef(null),h=Ve(r,p),[y,g]=v.useState(!1),[b,w]=v.useState("");return v.useEffect(()=>{var S;const k=p.current;k&&w(((S=k.textContent)!=null?S:"").trim())},[s.children]),f.jsx($o.ItemSlot,{scope:a,disabled:l,textValue:o!=null?o:b,children:f.jsx(Lw,{asChild:!0,...d,focusable:!l,children:f.jsx(Ce.div,{role:"menuitem","data-highlighted":y?"":void 0,"aria-disabled":l||void 0,"data-disabled":l?"":void 0,...s,ref:h,onPointerMove:ve(e.onPointerMove,qo(k=>{l?c.onItemLeave(k):(c.onItemEnter(k),k.defaultPrevented||k.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:ve(e.onPointerLeave,qo(k=>c.onItemLeave(k))),onFocus:ve(e.onFocus,()=>g(!0)),onBlur:ve(e.onBlur,()=>g(!1))})})})}),qR="MenuCheckboxItem",Gw=v.forwardRef((e,r)=>{const{checked:a=!1,onCheckedChange:l,...o}=e;return f.jsx(Zw,{scope:e.__scopeMenu,checked:a,children:f.jsx(Kc,{role:"menuitemcheckbox","aria-checked":xc(a)?"mixed":a,...o,ref:r,"data-state":jm(a),onSelect:ve(o.onSelect,()=>l==null?void 0:l(xc(a)?!0:!a),{checkForDefaultPrevented:!1})})})});Gw.displayName=qR;var Yw="MenuRadioGroup",[GR,YR]=yl(Yw,{value:void 0,onValueChange:()=>{}}),Xw=v.forwardRef((e,r)=>{const{value:a,onValueChange:l,...o}=e,s=qt(l);return f.jsx(GR,{scope:e.__scopeMenu,value:a,onValueChange:s,children:f.jsx(Am,{...o,ref:r})})});Xw.displayName=Yw;var Kw="MenuRadioItem",Qw=v.forwardRef((e,r)=>{const{value:a,...l}=e,o=YR(Kw,e.__scopeMenu),s=a===o.value;return f.jsx(Zw,{scope:e.__scopeMenu,checked:s,children:f.jsx(Kc,{role:"menuitemradio","aria-checked":s,...l,ref:r,"data-state":jm(s),onSelect:ve(l.onSelect,()=>{var c;return(c=o.onValueChange)==null?void 0:c.call(o,a)},{checkForDefaultPrevented:!1})})})});Qw.displayName=Kw;var Nm="MenuItemIndicator",[Zw,XR]=yl(Nm,{checked:!1}),Ww=v.forwardRef((e,r)=>{const{__scopeMenu:a,forceMount:l,...o}=e,s=XR(Nm,a);return f.jsx(Bt,{present:l||xc(s.checked)||s.checked===!0,children:f.jsx(Ce.span,{...o,ref:r,"data-state":jm(s.checked)})})});Ww.displayName=Nm;var KR="MenuSeparator",Jw=v.forwardRef((e,r)=>{const{__scopeMenu:a,...l}=e;return f.jsx(Ce.div,{role:"separator","aria-orientation":"horizontal",...l,ref:r})});Jw.displayName=KR;var QR="MenuArrow",eS=v.forwardRef((e,r)=>{const{__scopeMenu:a,...l}=e,o=Xc(a);return f.jsx(Gc,{...o,...l,ref:r})});eS.displayName=QR;var ZR="MenuSub",[cP,tS]=yl(ZR),Lo="MenuSubTrigger",nS=v.forwardRef((e,r)=>{const a=xl(Lo,e.__scopeMenu),l=hs(Lo,e.__scopeMenu),o=tS(Lo,e.__scopeMenu),s=Em(Lo,e.__scopeMenu),c=v.useRef(null),{pointerGraceTimerRef:d,onPointerGraceIntentChange:p}=s,h={__scopeMenu:e.__scopeMenu},y=v.useCallback(()=>{c.current&&window.clearTimeout(c.current),c.current=null},[]);return v.useEffect(()=>y,[y]),v.useEffect(()=>{const g=d.current;return()=>{window.clearTimeout(g),p(null)}},[d,p]),f.jsx(Sm,{asChild:!0,...h,children:f.jsx(qw,{id:o.triggerId,"aria-haspopup":"menu","aria-expanded":a.open,"aria-controls":o.contentId,"data-state":lS(a.open),...e,ref:$r(r,o.onTriggerChange),onClick:g=>{var b;(b=e.onClick)==null||b.call(e,g),!(e.disabled||g.defaultPrevented)&&(g.currentTarget.focus(),a.open||a.onOpenChange(!0))},onPointerMove:ve(e.onPointerMove,qo(g=>{s.onItemEnter(g),!g.defaultPrevented&&!e.disabled&&!a.open&&!c.current&&(s.onPointerGraceIntentChange(null),c.current=window.setTimeout(()=>{a.onOpenChange(!0),y()},100))})),onPointerLeave:ve(e.onPointerLeave,qo(g=>{var w,k;y();const b=(w=a.content)==null?void 0:w.getBoundingClientRect();if(b){const S=(k=a.content)==null?void 0:k.dataset.side,C=S==="right",A=C?-5:5,N=b[C?"left":"right"],j=b[C?"right":"left"];s.onPointerGraceIntentChange({area:[{x:g.clientX+A,y:g.clientY},{x:N,y:b.top},{x:j,y:b.top},{x:j,y:b.bottom},{x:N,y:b.bottom}],side:S}),window.clearTimeout(d.current),d.current=window.setTimeout(()=>s.onPointerGraceIntentChange(null),300)}else{if(s.onTriggerLeave(g),g.defaultPrevented)return;s.onPointerGraceIntentChange(null)}})),onKeyDown:ve(e.onKeyDown,g=>{var w;const b=s.searchRef.current!=="";e.disabled||b&&g.key===" "||RR[l.dir].includes(g.key)&&(a.onOpenChange(!0),(w=a.content)==null||w.focus(),g.preventDefault())})})})});nS.displayName=Lo;var rS="MenuSubContent",aS=v.forwardRef((e,r)=>{const a=Uw(Xn,e.__scopeMenu),{forceMount:l=a.forceMount,...o}=e,s=xl(Xn,e.__scopeMenu),c=hs(Xn,e.__scopeMenu),d=tS(rS,e.__scopeMenu),p=v.useRef(null),h=Ve(r,p);return f.jsx($o.Provider,{scope:e.__scopeMenu,children:f.jsx(Bt,{present:l||s.open,children:f.jsx($o.Slot,{scope:e.__scopeMenu,children:f.jsx(Cm,{id:d.contentId,"aria-labelledby":d.triggerId,...o,ref:h,align:"start",side:c.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:y=>{var g;c.isUsingKeyboardRef.current&&((g=p.current)==null||g.focus()),y.preventDefault()},onCloseAutoFocus:y=>y.preventDefault(),onFocusOutside:ve(e.onFocusOutside,y=>{y.target!==d.trigger&&s.onOpenChange(!1)}),onEscapeKeyDown:ve(e.onEscapeKeyDown,y=>{c.onClose(),y.preventDefault()}),onKeyDown:ve(e.onKeyDown,y=>{var w;const g=y.currentTarget.contains(y.target),b=MR[c.dir].includes(y.key);g&&b&&(s.onOpenChange(!1),(w=d.trigger)==null||w.focus(),y.preventDefault())})})})})})});aS.displayName=rS;function lS(e){return e?"open":"closed"}function xc(e){return e==="indeterminate"}function jm(e){return xc(e)?"indeterminate":e?"checked":"unchecked"}function WR(e){const r=document.activeElement;for(const a of e)if(a===r||(a.focus(),document.activeElement!==r))return}function JR(e,r){return e.map((a,l)=>e[(r+l)%e.length])}function eM(e,r,a){const o=r.length>1&&Array.from(r).every(h=>h===r[0])?r[0]:r,s=a?e.indexOf(a):-1;let c=JR(e,Math.max(s,0));o.length===1&&(c=c.filter(h=>h!==a));const p=c.find(h=>h.toLowerCase().startsWith(o.toLowerCase()));return p!==a?p:void 0}function tM(e,r){const{x:a,y:l}=e;let o=!1;for(let s=0,c=r.length-1;s<r.length;c=s++){const d=r[s],p=r[c],h=d.x,y=d.y,g=p.x,b=p.y;y>l!=b>l&&a<(g-h)*(l-y)/(b-y)+h&&(o=!o)}return o}function nM(e,r){if(!r)return!1;const a={x:e.clientX,y:e.clientY};return tM(a,r)}function qo(e){return r=>r.pointerType==="mouse"?e(r):void 0}var rM=Fw,aM=Sm,lM=Hw,iM=Vw,oM=Am,sM=$w,uM=Kc,cM=Gw,dM=Xw,fM=Qw,pM=Ww,hM=Jw,mM=eS,gM=nS,yM=aS,Qc="DropdownMenu",[xM]=_n(Qc,[Bw]),rn=Bw(),[bM,iS]=xM(Qc),oS=e=>{const{__scopeDropdownMenu:r,children:a,dir:l,open:o,defaultOpen:s,onOpenChange:c,modal:d=!0}=e,p=rn(r),h=v.useRef(null),[y,g]=qr({prop:o,defaultProp:s!=null?s:!1,onChange:c,caller:Qc});return f.jsx(bM,{scope:r,triggerId:Mt(),triggerRef:h,contentId:Mt(),open:y,onOpenChange:g,onOpenToggle:v.useCallback(()=>g(b=>!b),[g]),modal:d,children:f.jsx(rM,{...p,open:y,onOpenChange:g,dir:l,modal:d,children:a})})};oS.displayName=Qc;var sS="DropdownMenuTrigger",uS=v.forwardRef((e,r)=>{const{__scopeDropdownMenu:a,disabled:l=!1,...o}=e,s=iS(sS,a),c=rn(a);return f.jsx(aM,{asChild:!0,...c,children:f.jsx(Ce.button,{type:"button",id:s.triggerId,"aria-haspopup":"menu","aria-expanded":s.open,"aria-controls":s.open?s.contentId:void 0,"data-state":s.open?"open":"closed","data-disabled":l?"":void 0,disabled:l,...o,ref:$r(r,s.triggerRef),onPointerDown:ve(e.onPointerDown,d=>{!l&&d.button===0&&d.ctrlKey===!1&&(s.onOpenToggle(),s.open||d.preventDefault())}),onKeyDown:ve(e.onKeyDown,d=>{l||(["Enter"," "].includes(d.key)&&s.onOpenToggle(),d.key==="ArrowDown"&&s.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(d.key)&&d.preventDefault())})})})});uS.displayName=sS;var vM="DropdownMenuPortal",cS=e=>{const{__scopeDropdownMenu:r,...a}=e,l=rn(r);return f.jsx(lM,{...l,...a})};cS.displayName=vM;var dS="DropdownMenuContent",fS=v.forwardRef((e,r)=>{const{__scopeDropdownMenu:a,...l}=e,o=iS(dS,a),s=rn(a),c=v.useRef(!1);return f.jsx(iM,{id:o.contentId,"aria-labelledby":o.triggerId,...s,...l,ref:r,onCloseAutoFocus:ve(e.onCloseAutoFocus,d=>{var p;c.current||(p=o.triggerRef.current)==null||p.focus(),c.current=!1,d.preventDefault()}),onInteractOutside:ve(e.onInteractOutside,d=>{const p=d.detail.originalEvent,h=p.button===0&&p.ctrlKey===!0,y=p.button===2||h;(!o.modal||y)&&(c.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});fS.displayName=dS;var wM="DropdownMenuGroup",SM=v.forwardRef((e,r)=>{const{__scopeDropdownMenu:a,...l}=e,o=rn(a);return f.jsx(oM,{...o,...l,ref:r})});SM.displayName=wM;var kM="DropdownMenuLabel",EM=v.forwardRef((e,r)=>{const{__scopeDropdownMenu:a,...l}=e,o=rn(a);return f.jsx(sM,{...o,...l,ref:r})});EM.displayName=kM;var CM="DropdownMenuItem",pS=v.forwardRef((e,r)=>{const{__scopeDropdownMenu:a,...l}=e,o=rn(a);return f.jsx(uM,{...o,...l,ref:r})});pS.displayName=CM;var AM="DropdownMenuCheckboxItem",NM=v.forwardRef((e,r)=>{const{__scopeDropdownMenu:a,...l}=e,o=rn(a);return f.jsx(cM,{...o,...l,ref:r})});NM.displayName=AM;var jM="DropdownMenuRadioGroup",TM=v.forwardRef((e,r)=>{const{__scopeDropdownMenu:a,...l}=e,o=rn(a);return f.jsx(dM,{...o,...l,ref:r})});TM.displayName=jM;var _M="DropdownMenuRadioItem",RM=v.forwardRef((e,r)=>{const{__scopeDropdownMenu:a,...l}=e,o=rn(a);return f.jsx(fM,{...o,...l,ref:r})});RM.displayName=_M;var MM="DropdownMenuItemIndicator",OM=v.forwardRef((e,r)=>{const{__scopeDropdownMenu:a,...l}=e,o=rn(a);return f.jsx(pM,{...o,...l,ref:r})});OM.displayName=MM;var DM="DropdownMenuSeparator",zM=v.forwardRef((e,r)=>{const{__scopeDropdownMenu:a,...l}=e,o=rn(a);return f.jsx(hM,{...o,...l,ref:r})});zM.displayName=DM;var LM="DropdownMenuArrow",IM=v.forwardRef((e,r)=>{const{__scopeDropdownMenu:a,...l}=e,o=rn(a);return f.jsx(mM,{...o,...l,ref:r})});IM.displayName=LM;var BM="DropdownMenuSubTrigger",PM=v.forwardRef((e,r)=>{const{__scopeDropdownMenu:a,...l}=e,o=rn(a);return f.jsx(gM,{...o,...l,ref:r})});PM.displayName=BM;var FM="DropdownMenuSubContent",UM=v.forwardRef((e,r)=>{const{__scopeDropdownMenu:a,...l}=e,o=rn(a);return f.jsx(yM,{...o,...l,ref:r,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});UM.displayName=FM;var HM=oS,VM=uS,$M=cS,qM=fS,GM=pS,YM="Label",hS=v.forwardRef((e,r)=>f.jsx(Ce.label,{...e,ref:r,onMouseDown:a=>{var o;a.target.closest("button, input, select, textarea")||((o=e.onMouseDown)==null||o.call(e,a),!a.defaultPrevented&&a.detail>1&&a.preventDefault())}}));hS.displayName=YM;var XM=hS;function Rh(e,[r,a]){return Math.min(a,Math.max(r,e))}var Zc="Popover",[mS]=_n(Zc,[Ra]),ms=Ra(),[KM,Ma]=mS(Zc),gS=e=>{const{__scopePopover:r,children:a,open:l,defaultOpen:o,onOpenChange:s,modal:c=!1}=e,d=ms(r),p=v.useRef(null),[h,y]=v.useState(!1),[g,b]=qr({prop:l,defaultProp:o!=null?o:!1,onChange:s,caller:Zc});return f.jsx($c,{...d,children:f.jsx(KM,{scope:r,contentId:Mt(),triggerRef:p,open:g,onOpenChange:b,onOpenToggle:v.useCallback(()=>b(w=>!w),[b]),hasCustomAnchor:h,onCustomAnchorAdd:v.useCallback(()=>y(!0),[]),onCustomAnchorRemove:v.useCallback(()=>y(!1),[]),modal:c,children:a})})};gS.displayName=Zc;var yS="PopoverAnchor",xS=v.forwardRef((e,r)=>{const{__scopePopover:a,...l}=e,o=Ma(yS,a),s=ms(a),{onCustomAnchorAdd:c,onCustomAnchorRemove:d}=o;return v.useEffect(()=>(c(),()=>d()),[c,d]),f.jsx(ds,{...s,...l,ref:r})});xS.displayName=yS;var bS="PopoverTrigger",vS=v.forwardRef((e,r)=>{const{__scopePopover:a,...l}=e,o=Ma(bS,a),s=ms(a),c=Ve(r,o.triggerRef),d=f.jsx(Ce.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":CS(o.open),...l,ref:c,onClick:ve(e.onClick,o.onOpenToggle)});return o.hasCustomAnchor?d:f.jsx(ds,{asChild:!0,...s,children:d})});vS.displayName=bS;var Tm="PopoverPortal",[QM,ZM]=mS(Tm,{forceMount:void 0}),wS=e=>{const{__scopePopover:r,forceMount:a,children:l,container:o}=e,s=Ma(Tm,r);return f.jsx(QM,{scope:r,forceMount:a,children:f.jsx(Bt,{present:a||s.open,children:f.jsx(Ni,{asChild:!0,container:o,children:l})})})};wS.displayName=Tm;var vi="PopoverContent",SS=v.forwardRef((e,r)=>{const a=ZM(vi,e.__scopePopover),{forceMount:l=a.forceMount,...o}=e,s=Ma(vi,e.__scopePopover);return f.jsx(Bt,{present:l||s.open,children:s.modal?f.jsx(JM,{...o,ref:r}):f.jsx(eO,{...o,ref:r})})});SS.displayName=vi;var WM=Aa("PopoverContent.RemoveScroll"),JM=v.forwardRef((e,r)=>{const a=Ma(vi,e.__scopePopover),l=v.useRef(null),o=Ve(r,l),s=v.useRef(!1);return v.useEffect(()=>{const c=l.current;if(c)return Bc(c)},[]),f.jsx(us,{as:WM,allowPinchZoom:!0,children:f.jsx(kS,{...e,ref:o,trapFocus:a.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:ve(e.onCloseAutoFocus,c=>{var d;c.preventDefault(),s.current||(d=a.triggerRef.current)==null||d.focus()}),onPointerDownOutside:ve(e.onPointerDownOutside,c=>{const d=c.detail.originalEvent,p=d.button===0&&d.ctrlKey===!0,h=d.button===2||p;s.current=h},{checkForDefaultPrevented:!1}),onFocusOutside:ve(e.onFocusOutside,c=>c.preventDefault(),{checkForDefaultPrevented:!1})})})}),eO=v.forwardRef((e,r)=>{const a=Ma(vi,e.__scopePopover),l=v.useRef(!1),o=v.useRef(!1);return f.jsx(kS,{...e,ref:r,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{var c,d;(c=e.onCloseAutoFocus)==null||c.call(e,s),s.defaultPrevented||(l.current||(d=a.triggerRef.current)==null||d.focus(),s.preventDefault()),l.current=!1,o.current=!1},onInteractOutside:s=>{var p,h;(p=e.onInteractOutside)==null||p.call(e,s),s.defaultPrevented||(l.current=!0,s.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const c=s.target;((h=a.triggerRef.current)==null?void 0:h.contains(c))&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&o.current&&s.preventDefault()}})}),kS=v.forwardRef((e,r)=>{const{__scopePopover:a,trapFocus:l,onOpenAutoFocus:o,onCloseAutoFocus:s,disableOutsidePointerEvents:c,onEscapeKeyDown:d,onPointerDownOutside:p,onFocusOutside:h,onInteractOutside:y,...g}=e,b=Ma(vi,a),w=ms(a);return Lc(),f.jsx(ss,{asChild:!0,loop:!0,trapped:l,onMountAutoFocus:o,onUnmountAutoFocus:s,children:f.jsx(Ai,{asChild:!0,disableOutsidePointerEvents:c,onInteractOutside:y,onEscapeKeyDown:d,onPointerDownOutside:p,onFocusOutside:h,onDismiss:()=>b.onOpenChange(!1),children:f.jsx(qc,{"data-state":CS(b.open),role:"dialog",id:b.contentId,...w,...g,ref:r,style:{...g.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),ES="PopoverClose",tO=v.forwardRef((e,r)=>{const{__scopePopover:a,...l}=e,o=Ma(ES,a);return f.jsx(Ce.button,{type:"button",...l,ref:r,onClick:ve(e.onClick,()=>o.onOpenChange(!1))})});tO.displayName=ES;var nO="PopoverArrow",rO=v.forwardRef((e,r)=>{const{__scopePopover:a,...l}=e,o=ms(a);return f.jsx(Gc,{...o,...l,ref:r})});rO.displayName=nO;function CS(e){return e?"open":"closed"}var aO=gS,lO=xS,iO=vS,oO=wS,sO=SS,_m="Progress",Rm=100,[uO]=_n(_m),[cO,dO]=uO(_m),AS=v.forwardRef((e,r)=>{const{__scopeProgress:a,value:l=null,max:o,getValueLabel:s=fO,...c}=e;(o||o===0)&&!Gv(o)&&console.error(pO(`${o}`,"Progress"));const d=Gv(o)?o:Rm;l!==null&&!Yv(l,d)&&console.error(hO(`${l}`,"Progress"));const p=Yv(l,d)?l:null,h=bc(p)?s(p,d):void 0;return f.jsx(cO,{scope:a,value:p,max:d,children:f.jsx(Ce.div,{"aria-valuemax":d,"aria-valuemin":0,"aria-valuenow":bc(p)?p:void 0,"aria-valuetext":h,role:"progressbar","data-state":TS(p,d),"data-value":p!=null?p:void 0,"data-max":d,...c,ref:r})})});AS.displayName=_m;var NS="ProgressIndicator",jS=v.forwardRef((e,r)=>{var s;const{__scopeProgress:a,...l}=e,o=dO(NS,a);return f.jsx(Ce.div,{"data-state":TS(o.value,o.max),"data-value":(s=o.value)!=null?s:void 0,"data-max":o.max,...l,ref:r})});jS.displayName=NS;function fO(e,r){return`${Math.round(e/r*100)}%`}function TS(e,r){return e==null?"indeterminate":e===r?"complete":"loading"}function bc(e){return typeof e=="number"}function Gv(e){return bc(e)&&!isNaN(e)&&e>0}function Yv(e,r){return bc(e)&&!isNaN(e)&&e<=r&&e>=0}function pO(e,r){return`Invalid prop \`max\` of value \`${e}\` supplied to \`${r}\`. Only numbers greater than 0 are valid max values. Defaulting to \`${Rm}\`.`}function hO(e,r){return`Invalid prop \`value\` of value \`${e}\` supplied to \`${r}\`. The \`value\` prop must be:
399
- - a positive number
400
- - less than the value passed to \`max\` (or ${Rm} if no \`max\` prop is set)
401
- - \`null\` or \`undefined\` if the progress is indeterminate.
402
-
403
- Defaulting to \`null\`.`}var mO=AS,gO=jS;function yO(e,r){return v.useReducer((a,l)=>{const o=r[a][l];return o!=null?o:a},e)}var Mm="ScrollArea",[_S]=_n(Mm),[xO,Kn]=_S(Mm),RS=v.forwardRef((e,r)=>{const{__scopeScrollArea:a,type:l="hover",dir:o,scrollHideDelay:s=600,...c}=e,[d,p]=v.useState(null),[h,y]=v.useState(null),[g,b]=v.useState(null),[w,k]=v.useState(null),[S,C]=v.useState(null),[A,N]=v.useState(0),[j,O]=v.useState(0),[D,M]=v.useState(!1),[U,F]=v.useState(!1),Q=Ve(r,Y=>p(Y)),I=os(o);return f.jsx(xO,{scope:a,type:l,dir:I,scrollHideDelay:s,scrollArea:d,viewport:h,onViewportChange:y,content:g,onContentChange:b,scrollbarX:w,onScrollbarXChange:k,scrollbarXEnabled:D,onScrollbarXEnabledChange:M,scrollbarY:S,onScrollbarYChange:C,scrollbarYEnabled:U,onScrollbarYEnabledChange:F,onCornerWidthChange:N,onCornerHeightChange:O,children:f.jsx(Ce.div,{dir:I,...c,ref:Q,style:{position:"relative","--radix-scroll-area-corner-width":A+"px","--radix-scroll-area-corner-height":j+"px",...e.style}})})});RS.displayName=Mm;var MS="ScrollAreaViewport",OS=v.forwardRef((e,r)=>{const{__scopeScrollArea:a,children:l,nonce:o,...s}=e,c=Kn(MS,a),d=v.useRef(null),p=Ve(r,d,c.onViewportChange);return f.jsxs(f.Fragment,{children:[f.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:o}),f.jsx(Ce.div,{"data-radix-scroll-area-viewport":"",...s,ref:p,style:{overflowX:c.scrollbarXEnabled?"scroll":"hidden",overflowY:c.scrollbarYEnabled?"scroll":"hidden",...e.style},children:f.jsx("div",{ref:c.onContentChange,style:{minWidth:"100%",display:"table"},children:l})})]})});OS.displayName=MS;var yr="ScrollAreaScrollbar",DS=v.forwardRef((e,r)=>{const{forceMount:a,...l}=e,o=Kn(yr,e.__scopeScrollArea),{onScrollbarXEnabledChange:s,onScrollbarYEnabledChange:c}=o,d=e.orientation==="horizontal";return v.useEffect(()=>(d?s(!0):c(!0),()=>{d?s(!1):c(!1)}),[d,s,c]),o.type==="hover"?f.jsx(bO,{...l,ref:r,forceMount:a}):o.type==="scroll"?f.jsx(vO,{...l,ref:r,forceMount:a}):o.type==="auto"?f.jsx(zS,{...l,ref:r,forceMount:a}):o.type==="always"?f.jsx(Om,{...l,ref:r}):null});DS.displayName=yr;var bO=v.forwardRef((e,r)=>{const{forceMount:a,...l}=e,o=Kn(yr,e.__scopeScrollArea),[s,c]=v.useState(!1);return v.useEffect(()=>{const d=o.scrollArea;let p=0;if(d){const h=()=>{window.clearTimeout(p),c(!0)},y=()=>{p=window.setTimeout(()=>c(!1),o.scrollHideDelay)};return d.addEventListener("pointerenter",h),d.addEventListener("pointerleave",y),()=>{window.clearTimeout(p),d.removeEventListener("pointerenter",h),d.removeEventListener("pointerleave",y)}}},[o.scrollArea,o.scrollHideDelay]),f.jsx(Bt,{present:a||s,children:f.jsx(zS,{"data-state":s?"visible":"hidden",...l,ref:r})})}),vO=v.forwardRef((e,r)=>{const{forceMount:a,...l}=e,o=Kn(yr,e.__scopeScrollArea),s=e.orientation==="horizontal",c=Jc(()=>p("SCROLL_END"),100),[d,p]=yO("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 v.useEffect(()=>{if(d==="idle"){const h=window.setTimeout(()=>p("HIDE"),o.scrollHideDelay);return()=>window.clearTimeout(h)}},[d,o.scrollHideDelay,p]),v.useEffect(()=>{const h=o.viewport,y=s?"scrollLeft":"scrollTop";if(h){let g=h[y];const b=()=>{const w=h[y];g!==w&&(p("SCROLL"),c()),g=w};return h.addEventListener("scroll",b),()=>h.removeEventListener("scroll",b)}},[o.viewport,s,p,c]),f.jsx(Bt,{present:a||d!=="hidden",children:f.jsx(Om,{"data-state":d==="hidden"?"hidden":"visible",...l,ref:r,onPointerEnter:ve(e.onPointerEnter,()=>p("POINTER_ENTER")),onPointerLeave:ve(e.onPointerLeave,()=>p("POINTER_LEAVE"))})})}),zS=v.forwardRef((e,r)=>{const a=Kn(yr,e.__scopeScrollArea),{forceMount:l,...o}=e,[s,c]=v.useState(!1),d=e.orientation==="horizontal",p=Jc(()=>{if(a.viewport){const h=a.viewport.offsetWidth<a.viewport.scrollWidth,y=a.viewport.offsetHeight<a.viewport.scrollHeight;c(d?h:y)}},10);return wi(a.viewport,p),wi(a.content,p),f.jsx(Bt,{present:l||s,children:f.jsx(Om,{"data-state":s?"visible":"hidden",...o,ref:r})})}),Om=v.forwardRef((e,r)=>{const{orientation:a="vertical",...l}=e,o=Kn(yr,e.__scopeScrollArea),s=v.useRef(null),c=v.useRef(0),[d,p]=v.useState({content:0,viewport:0,scrollbar:{size:0,paddingStart:0,paddingEnd:0}}),h=FS(d.viewport,d.content),y={...l,sizes:d,onSizesChange:p,hasThumb:h>0&&h<1,onThumbChange:b=>s.current=b,onThumbPointerUp:()=>c.current=0,onThumbPointerDown:b=>c.current=b};function g(b,w){return AO(b,c.current,d,w)}return a==="horizontal"?f.jsx(wO,{...y,ref:r,onThumbPositionChange:()=>{if(o.viewport&&s.current){const b=o.viewport.scrollLeft,w=Xv(b,d,o.dir);s.current.style.transform=`translate3d(${w}px, 0, 0)`}},onWheelScroll:b=>{o.viewport&&(o.viewport.scrollLeft=b)},onDragScroll:b=>{o.viewport&&(o.viewport.scrollLeft=g(b,o.dir))}}):a==="vertical"?f.jsx(SO,{...y,ref:r,onThumbPositionChange:()=>{if(o.viewport&&s.current){const b=o.viewport.scrollTop,w=Xv(b,d);s.current.style.transform=`translate3d(0, ${w}px, 0)`}},onWheelScroll:b=>{o.viewport&&(o.viewport.scrollTop=b)},onDragScroll:b=>{o.viewport&&(o.viewport.scrollTop=g(b))}}):null}),wO=v.forwardRef((e,r)=>{const{sizes:a,onSizesChange:l,...o}=e,s=Kn(yr,e.__scopeScrollArea),[c,d]=v.useState(),p=v.useRef(null),h=Ve(r,p,s.onScrollbarXChange);return v.useEffect(()=>{p.current&&d(getComputedStyle(p.current))},[p]),f.jsx(IS,{"data-orientation":"horizontal",...o,ref:h,sizes:a,style:{bottom:0,left:s.dir==="rtl"?"var(--radix-scroll-area-corner-width)":0,right:s.dir==="ltr"?"var(--radix-scroll-area-corner-width)":0,"--radix-scroll-area-thumb-width":Wc(a)+"px",...e.style},onThumbPointerDown:y=>e.onThumbPointerDown(y.x),onDragScroll:y=>e.onDragScroll(y.x),onWheelScroll:(y,g)=>{if(s.viewport){const b=s.viewport.scrollLeft+y.deltaX;e.onWheelScroll(b),HS(b,g)&&y.preventDefault()}},onResize:()=>{p.current&&s.viewport&&c&&l({content:s.viewport.scrollWidth,viewport:s.viewport.offsetWidth,scrollbar:{size:p.current.clientWidth,paddingStart:wc(c.paddingLeft),paddingEnd:wc(c.paddingRight)}})}})}),SO=v.forwardRef((e,r)=>{const{sizes:a,onSizesChange:l,...o}=e,s=Kn(yr,e.__scopeScrollArea),[c,d]=v.useState(),p=v.useRef(null),h=Ve(r,p,s.onScrollbarYChange);return v.useEffect(()=>{p.current&&d(getComputedStyle(p.current))},[p]),f.jsx(IS,{"data-orientation":"vertical",...o,ref:h,sizes:a,style:{top:0,right:s.dir==="ltr"?0:void 0,left:s.dir==="rtl"?0:void 0,bottom:"var(--radix-scroll-area-corner-height)","--radix-scroll-area-thumb-height":Wc(a)+"px",...e.style},onThumbPointerDown:y=>e.onThumbPointerDown(y.y),onDragScroll:y=>e.onDragScroll(y.y),onWheelScroll:(y,g)=>{if(s.viewport){const b=s.viewport.scrollTop+y.deltaY;e.onWheelScroll(b),HS(b,g)&&y.preventDefault()}},onResize:()=>{p.current&&s.viewport&&c&&l({content:s.viewport.scrollHeight,viewport:s.viewport.offsetHeight,scrollbar:{size:p.current.clientHeight,paddingStart:wc(c.paddingTop),paddingEnd:wc(c.paddingBottom)}})}})}),[kO,LS]=_S(yr),IS=v.forwardRef((e,r)=>{const{__scopeScrollArea:a,sizes:l,hasThumb:o,onThumbChange:s,onThumbPointerUp:c,onThumbPointerDown:d,onThumbPositionChange:p,onDragScroll:h,onWheelScroll:y,onResize:g,...b}=e,w=Kn(yr,a),[k,S]=v.useState(null),C=Ve(r,Q=>S(Q)),A=v.useRef(null),N=v.useRef(""),j=w.viewport,O=l.content-l.viewport,D=qt(y),M=qt(p),U=Jc(g,10);function F(Q){if(A.current){const I=Q.clientX-A.current.left,Y=Q.clientY-A.current.top;h({x:I,y:Y})}}return v.useEffect(()=>{const Q=I=>{const Y=I.target;(k==null?void 0:k.contains(Y))&&D(I,O)};return document.addEventListener("wheel",Q,{passive:!1}),()=>document.removeEventListener("wheel",Q,{passive:!1})},[j,k,O,D]),v.useEffect(M,[l,M]),wi(k,U),wi(w.content,U),f.jsx(kO,{scope:a,scrollbar:k,hasThumb:o,onThumbChange:qt(s),onThumbPointerUp:qt(c),onThumbPositionChange:M,onThumbPointerDown:qt(d),children:f.jsx(Ce.div,{...b,ref:C,style:{position:"absolute",...b.style},onPointerDown:ve(e.onPointerDown,Q=>{Q.button===0&&(Q.target.setPointerCapture(Q.pointerId),A.current=k.getBoundingClientRect(),N.current=document.body.style.webkitUserSelect,document.body.style.webkitUserSelect="none",w.viewport&&(w.viewport.style.scrollBehavior="auto"),F(Q))}),onPointerMove:ve(e.onPointerMove,F),onPointerUp:ve(e.onPointerUp,Q=>{const I=Q.target;I.hasPointerCapture(Q.pointerId)&&I.releasePointerCapture(Q.pointerId),document.body.style.webkitUserSelect=N.current,w.viewport&&(w.viewport.style.scrollBehavior=""),A.current=null})})})}),vc="ScrollAreaThumb",BS=v.forwardRef((e,r)=>{const{forceMount:a,...l}=e,o=LS(vc,e.__scopeScrollArea);return f.jsx(Bt,{present:a||o.hasThumb,children:f.jsx(EO,{ref:r,...l})})}),EO=v.forwardRef((e,r)=>{const{__scopeScrollArea:a,style:l,...o}=e,s=Kn(vc,a),c=LS(vc,a),{onThumbPositionChange:d}=c,p=Ve(r,g=>c.onThumbChange(g)),h=v.useRef(void 0),y=Jc(()=>{h.current&&(h.current(),h.current=void 0)},100);return v.useEffect(()=>{const g=s.viewport;if(g){const b=()=>{if(y(),!h.current){const w=NO(g,d);h.current=w,d()}};return d(),g.addEventListener("scroll",b),()=>g.removeEventListener("scroll",b)}},[s.viewport,y,d]),f.jsx(Ce.div,{"data-state":c.hasThumb?"visible":"hidden",...o,ref:p,style:{width:"var(--radix-scroll-area-thumb-width)",height:"var(--radix-scroll-area-thumb-height)",...l},onPointerDownCapture:ve(e.onPointerDownCapture,g=>{const w=g.target.getBoundingClientRect(),k=g.clientX-w.left,S=g.clientY-w.top;c.onThumbPointerDown({x:k,y:S})}),onPointerUp:ve(e.onPointerUp,c.onThumbPointerUp)})});BS.displayName=vc;var Dm="ScrollAreaCorner",PS=v.forwardRef((e,r)=>{const a=Kn(Dm,e.__scopeScrollArea),l=!!(a.scrollbarX&&a.scrollbarY);return a.type!=="scroll"&&l?f.jsx(CO,{...e,ref:r}):null});PS.displayName=Dm;var CO=v.forwardRef((e,r)=>{const{__scopeScrollArea:a,...l}=e,o=Kn(Dm,a),[s,c]=v.useState(0),[d,p]=v.useState(0),h=!!(s&&d);return wi(o.scrollbarX,()=>{var g;const y=((g=o.scrollbarX)==null?void 0:g.offsetHeight)||0;o.onCornerHeightChange(y),p(y)}),wi(o.scrollbarY,()=>{var g;const y=((g=o.scrollbarY)==null?void 0:g.offsetWidth)||0;o.onCornerWidthChange(y),c(y)}),h?f.jsx(Ce.div,{...l,ref:r,style:{width:s,height:d,position:"absolute",right:o.dir==="ltr"?0:void 0,left:o.dir==="rtl"?0:void 0,bottom:0,...e.style}}):null});function wc(e){return e?parseInt(e,10):0}function FS(e,r){const a=e/r;return isNaN(a)?0:a}function Wc(e){const r=FS(e.viewport,e.content),a=e.scrollbar.paddingStart+e.scrollbar.paddingEnd,l=(e.scrollbar.size-a)*r;return Math.max(l,18)}function AO(e,r,a,l="ltr"){const o=Wc(a),s=o/2,c=r||s,d=o-c,p=a.scrollbar.paddingStart+c,h=a.scrollbar.size-a.scrollbar.paddingEnd-d,y=a.content-a.viewport,g=l==="ltr"?[0,y]:[y*-1,0];return US([p,h],g)(e)}function Xv(e,r,a="ltr"){const l=Wc(r),o=r.scrollbar.paddingStart+r.scrollbar.paddingEnd,s=r.scrollbar.size-o,c=r.content-r.viewport,d=s-l,p=a==="ltr"?[0,c]:[c*-1,0],h=Rh(e,p);return US([0,c],[0,d])(h)}function US(e,r){return a=>{if(e[0]===e[1]||r[0]===r[1])return r[0];const l=(r[1]-r[0])/(e[1]-e[0]);return r[0]+l*(a-e[0])}}function HS(e,r){return e>0&&e<r}var NO=(e,r=()=>{})=>{let a={left:e.scrollLeft,top:e.scrollTop},l=0;return(function o(){const s={left:e.scrollLeft,top:e.scrollTop},c=a.left!==s.left,d=a.top!==s.top;(c||d)&&r(),a=s,l=window.requestAnimationFrame(o)})(),()=>window.cancelAnimationFrame(l)};function Jc(e,r){const a=qt(e),l=v.useRef(0);return v.useEffect(()=>()=>window.clearTimeout(l.current),[]),v.useCallback(()=>{window.clearTimeout(l.current),l.current=window.setTimeout(a,r)},[a,r])}function wi(e,r){const a=qt(r);It(()=>{let l=0;if(e){const o=new ResizeObserver(()=>{cancelAnimationFrame(l),l=window.requestAnimationFrame(a)});return o.observe(e),()=>{window.cancelAnimationFrame(l),o.unobserve(e)}}},[e,a])}var jO=RS,TO=OS,_O=PS,RO=[" ","Enter","ArrowUp","ArrowDown"],MO=[" ","Enter"],pl="Select",[ed,td,OO]=nm(pl),[_i]=_n(pl,[OO,Ra]),nd=Ra(),[DO,Oa]=_i(pl),[zO,LO]=_i(pl),VS=e=>{const{__scopeSelect:r,children:a,open:l,defaultOpen:o,onOpenChange:s,value:c,defaultValue:d,onValueChange:p,dir:h,name:y,autoComplete:g,disabled:b,required:w,form:k}=e,S=nd(r),[C,A]=v.useState(null),[N,j]=v.useState(null),[O,D]=v.useState(!1),M=os(h),[U,F]=qr({prop:l,defaultProp:o!=null?o:!1,onChange:s,caller:pl}),[Q,I]=qr({prop:c,defaultProp:d,onChange:p,caller:pl}),Y=v.useRef(null),V=C?k||!!C.closest("form"):!0,[ue,W]=v.useState(new Set),J=Array.from(ue).map(B=>B.props.value).join(";");return f.jsx($c,{...S,children:f.jsxs(DO,{required:w,scope:r,trigger:C,onTriggerChange:A,valueNode:N,onValueNodeChange:j,valueNodeHasChildren:O,onValueNodeHasChildrenChange:D,contentId:Mt(),value:Q,onValueChange:I,open:U,onOpenChange:F,dir:M,triggerPointerDownPosRef:Y,disabled:b,children:[f.jsx(ed.Provider,{scope:r,children:f.jsx(zO,{scope:e.__scopeSelect,onNativeOptionAdd:v.useCallback(B=>{W(G=>new Set(G).add(B))},[]),onNativeOptionRemove:v.useCallback(B=>{W(G=>{const te=new Set(G);return te.delete(B),te})},[]),children:a})}),V?f.jsxs(pk,{"aria-hidden":!0,required:w,tabIndex:-1,name:y,autoComplete:g,value:Q,onChange:B=>I(B.target.value),disabled:b,form:k,children:[Q===void 0?f.jsx("option",{value:""}):null,Array.from(ue)]},J):null]})})};VS.displayName=pl;var $S="SelectTrigger",qS=v.forwardRef((e,r)=>{const{__scopeSelect:a,disabled:l=!1,...o}=e,s=nd(a),c=Oa($S,a),d=c.disabled||l,p=Ve(r,c.onTriggerChange),h=td(a),y=v.useRef("touch"),[g,b,w]=mk(S=>{const C=h().filter(j=>!j.disabled),A=C.find(j=>j.value===c.value),N=gk(C,S,A);N!==void 0&&c.onValueChange(N.value)}),k=S=>{d||(c.onOpenChange(!0),w()),S&&(c.triggerPointerDownPosRef.current={x:Math.round(S.pageX),y:Math.round(S.pageY)})};return f.jsx(ds,{asChild:!0,...s,children:f.jsx(Ce.button,{type:"button",role:"combobox","aria-controls":c.contentId,"aria-expanded":c.open,"aria-required":c.required,"aria-autocomplete":"none",dir:c.dir,"data-state":c.open?"open":"closed",disabled:d,"data-disabled":d?"":void 0,"data-placeholder":hk(c.value)?"":void 0,...o,ref:p,onClick:ve(o.onClick,S=>{S.currentTarget.focus(),y.current!=="mouse"&&k(S)}),onPointerDown:ve(o.onPointerDown,S=>{y.current=S.pointerType;const C=S.target;C.hasPointerCapture(S.pointerId)&&C.releasePointerCapture(S.pointerId),S.button===0&&S.ctrlKey===!1&&S.pointerType==="mouse"&&(k(S),S.preventDefault())}),onKeyDown:ve(o.onKeyDown,S=>{const C=g.current!=="";!(S.ctrlKey||S.altKey||S.metaKey)&&S.key.length===1&&b(S.key),!(C&&S.key===" ")&&RO.includes(S.key)&&(k(),S.preventDefault())})})})});qS.displayName=$S;var GS="SelectValue",YS=v.forwardRef((e,r)=>{const{__scopeSelect:a,className:l,style:o,children:s,placeholder:c="",...d}=e,p=Oa(GS,a),{onValueNodeHasChildrenChange:h}=p,y=s!==void 0,g=Ve(r,p.onValueNodeChange);return It(()=>{h(y)},[h,y]),f.jsx(Ce.span,{...d,ref:g,style:{pointerEvents:"none"},children:hk(p.value)?f.jsx(f.Fragment,{children:c}):s})});YS.displayName=GS;var IO="SelectIcon",XS=v.forwardRef((e,r)=>{const{__scopeSelect:a,children:l,...o}=e;return f.jsx(Ce.span,{"aria-hidden":!0,...o,ref:r,children:l||"▼"})});XS.displayName=IO;var BO="SelectPortal",KS=e=>f.jsx(Ni,{asChild:!0,...e});KS.displayName=BO;var hl="SelectContent",QS=v.forwardRef((e,r)=>{const a=Oa(hl,e.__scopeSelect),[l,o]=v.useState();if(It(()=>{o(new DocumentFragment)},[]),!a.open){const s=l;return s?ls.createPortal(f.jsx(ZS,{scope:e.__scopeSelect,children:f.jsx(ed.Slot,{scope:e.__scopeSelect,children:f.jsx("div",{children:e.children})})}),s):null}return f.jsx(WS,{...e,ref:r})});QS.displayName=hl;var Jn=10,[ZS,Da]=_i(hl),PO="SelectContentImpl",FO=Aa("SelectContent.RemoveScroll"),WS=v.forwardRef((e,r)=>{const{__scopeSelect:a,position:l="item-aligned",onCloseAutoFocus:o,onEscapeKeyDown:s,onPointerDownOutside:c,side:d,sideOffset:p,align:h,alignOffset:y,arrowPadding:g,collisionBoundary:b,collisionPadding:w,sticky:k,hideWhenDetached:S,avoidCollisions:C,...A}=e,N=Oa(hl,a),[j,O]=v.useState(null),[D,M]=v.useState(null),U=Ve(r,le=>O(le)),[F,Q]=v.useState(null),[I,Y]=v.useState(null),V=td(a),[ue,W]=v.useState(!1),J=v.useRef(!1);v.useEffect(()=>{if(j)return Bc(j)},[j]),Lc();const B=v.useCallback(le=>{const[be,...he]=V().map(ze=>ze.ref.current),[Ne]=he.slice(-1),De=document.activeElement;for(const ze of le)if(ze===De||(ze==null||ze.scrollIntoView({block:"nearest"}),ze===be&&D&&(D.scrollTop=0),ze===Ne&&D&&(D.scrollTop=D.scrollHeight),ze==null||ze.focus(),document.activeElement!==De))return},[V,D]),G=v.useCallback(()=>B([F,j]),[B,F,j]);v.useEffect(()=>{ue&&G()},[ue,G]);const{onOpenChange:te,triggerPointerDownPosRef:ce}=N;v.useEffect(()=>{if(j){let le={x:0,y:0};const be=Ne=>{var De,ze,gt,nt;le={x:Math.abs(Math.round(Ne.pageX)-((ze=(De=ce.current)==null?void 0:De.x)!=null?ze:0)),y:Math.abs(Math.round(Ne.pageY)-((nt=(gt=ce.current)==null?void 0:gt.y)!=null?nt:0))}},he=Ne=>{le.x<=10&&le.y<=10?Ne.preventDefault():j.contains(Ne.target)||te(!1),document.removeEventListener("pointermove",be),ce.current=null};return ce.current!==null&&(document.addEventListener("pointermove",be),document.addEventListener("pointerup",he,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",be),document.removeEventListener("pointerup",he,{capture:!0})}}},[j,te,ce]),v.useEffect(()=>{const le=()=>te(!1);return window.addEventListener("blur",le),window.addEventListener("resize",le),()=>{window.removeEventListener("blur",le),window.removeEventListener("resize",le)}},[te]);const[R,z]=mk(le=>{const be=V().filter(De=>!De.disabled),he=be.find(De=>De.ref.current===document.activeElement),Ne=gk(be,le,he);Ne&&setTimeout(()=>Ne.ref.current.focus())}),L=v.useCallback((le,be,he)=>{const Ne=!J.current&&!he;(N.value!==void 0&&N.value===be||Ne)&&(Q(le),Ne&&(J.current=!0))},[N.value]),_=v.useCallback(()=>j==null?void 0:j.focus(),[j]),re=v.useCallback((le,be,he)=>{const Ne=!J.current&&!he;(N.value!==void 0&&N.value===be||Ne)&&Y(le)},[N.value]),ne=l==="popper"?Mh:JS,ie=ne===Mh?{side:d,sideOffset:p,align:h,alignOffset:y,arrowPadding:g,collisionBoundary:b,collisionPadding:w,sticky:k,hideWhenDetached:S,avoidCollisions:C}:{};return f.jsx(ZS,{scope:a,content:j,viewport:D,onViewportChange:M,itemRefCallback:L,selectedItem:F,onItemLeave:_,itemTextRefCallback:re,focusSelectedItem:G,selectedItemText:I,position:l,isPositioned:ue,searchRef:R,children:f.jsx(us,{as:FO,allowPinchZoom:!0,children:f.jsx(ss,{asChild:!0,trapped:N.open,onMountAutoFocus:le=>{le.preventDefault()},onUnmountAutoFocus:ve(o,le=>{var be;(be=N.trigger)==null||be.focus({preventScroll:!0}),le.preventDefault()}),children:f.jsx(Ai,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:s,onPointerDownOutside:c,onFocusOutside:le=>le.preventDefault(),onDismiss:()=>N.onOpenChange(!1),children:f.jsx(ne,{role:"listbox",id:N.contentId,"data-state":N.open?"open":"closed",dir:N.dir,onContextMenu:le=>le.preventDefault(),...A,...ie,onPlaced:()=>W(!0),ref:U,style:{display:"flex",flexDirection:"column",outline:"none",...A.style},onKeyDown:ve(A.onKeyDown,le=>{const be=le.ctrlKey||le.altKey||le.metaKey;if(le.key==="Tab"&&le.preventDefault(),!be&&le.key.length===1&&z(le.key),["ArrowUp","ArrowDown","Home","End"].includes(le.key)){let Ne=V().filter(De=>!De.disabled).map(De=>De.ref.current);if(["ArrowUp","End"].includes(le.key)&&(Ne=Ne.slice().reverse()),["ArrowUp","ArrowDown"].includes(le.key)){const De=le.target,ze=Ne.indexOf(De);Ne=Ne.slice(ze+1)}setTimeout(()=>B(Ne)),le.preventDefault()}})})})})})})});WS.displayName=PO;var UO="SelectItemAlignedPosition",JS=v.forwardRef((e,r)=>{const{__scopeSelect:a,onPlaced:l,...o}=e,s=Oa(hl,a),c=Da(hl,a),[d,p]=v.useState(null),[h,y]=v.useState(null),g=Ve(r,U=>y(U)),b=td(a),w=v.useRef(!1),k=v.useRef(!0),{viewport:S,selectedItem:C,selectedItemText:A,focusSelectedItem:N}=c,j=v.useCallback(()=>{if(s.trigger&&s.valueNode&&d&&h&&S&&C&&A){const U=s.trigger.getBoundingClientRect(),F=h.getBoundingClientRect(),Q=s.valueNode.getBoundingClientRect(),I=A.getBoundingClientRect();if(s.dir!=="rtl"){const De=I.left-F.left,ze=Q.left-De,gt=U.left-ze,nt=U.width+gt,Ot=Math.max(nt,F.width),Jt=window.innerWidth-Jn,Gt=Rh(ze,[Jn,Math.max(Jn,Jt-Ot)]);d.style.minWidth=nt+"px",d.style.left=Gt+"px"}else{const De=F.right-I.right,ze=window.innerWidth-Q.right-De,gt=window.innerWidth-U.right-ze,nt=U.width+gt,Ot=Math.max(nt,F.width),Jt=window.innerWidth-Jn,Gt=Rh(ze,[Jn,Math.max(Jn,Jt-Ot)]);d.style.minWidth=nt+"px",d.style.right=Gt+"px"}const Y=b(),V=window.innerHeight-Jn*2,ue=S.scrollHeight,W=window.getComputedStyle(h),J=parseInt(W.borderTopWidth,10),B=parseInt(W.paddingTop,10),G=parseInt(W.borderBottomWidth,10),te=parseInt(W.paddingBottom,10),ce=J+B+ue+te+G,R=Math.min(C.offsetHeight*5,ce),z=window.getComputedStyle(S),L=parseInt(z.paddingTop,10),_=parseInt(z.paddingBottom,10),re=U.top+U.height/2-Jn,ne=V-re,ie=C.offsetHeight/2,le=C.offsetTop+ie,be=J+B+le,he=ce-be;if(be<=re){const De=Y.length>0&&C===Y[Y.length-1].ref.current;d.style.bottom="0px";const ze=h.clientHeight-S.offsetTop-S.offsetHeight,gt=Math.max(ne,ie+(De?_:0)+ze+G),nt=be+gt;d.style.height=nt+"px"}else{const De=Y.length>0&&C===Y[0].ref.current;d.style.top="0px";const gt=Math.max(re,J+S.offsetTop+(De?L:0)+ie)+he;d.style.height=gt+"px",S.scrollTop=be-re+S.offsetTop}d.style.margin=`${Jn}px 0`,d.style.minHeight=R+"px",d.style.maxHeight=V+"px",l==null||l(),requestAnimationFrame(()=>w.current=!0)}},[b,s.trigger,s.valueNode,d,h,S,C,A,s.dir,l]);It(()=>j(),[j]);const[O,D]=v.useState();It(()=>{h&&D(window.getComputedStyle(h).zIndex)},[h]);const M=v.useCallback(U=>{U&&k.current===!0&&(j(),N==null||N(),k.current=!1)},[j,N]);return f.jsx(VO,{scope:a,contentWrapper:d,shouldExpandOnScrollRef:w,onScrollButtonChange:M,children:f.jsx("div",{ref:p,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:O},children:f.jsx(Ce.div,{...o,ref:g,style:{boxSizing:"border-box",maxHeight:"100%",...o.style}})})})});JS.displayName=UO;var HO="SelectPopperPosition",Mh=v.forwardRef((e,r)=>{const{__scopeSelect:a,align:l="start",collisionPadding:o=Jn,...s}=e,c=nd(a);return f.jsx(qc,{...c,...s,ref:r,align:l,collisionPadding:o,style:{boxSizing:"border-box",...s.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})});Mh.displayName=HO;var[VO,zm]=_i(hl,{}),Oh="SelectViewport",ek=v.forwardRef((e,r)=>{const{__scopeSelect:a,nonce:l,...o}=e,s=Da(Oh,a),c=zm(Oh,a),d=Ve(r,s.onViewportChange),p=v.useRef(0);return f.jsxs(f.Fragment,{children:[f.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:l}),f.jsx(ed.Slot,{scope:a,children:f.jsx(Ce.div,{"data-radix-select-viewport":"",role:"presentation",...o,ref:d,style:{position:"relative",flex:1,overflow:"hidden auto",...o.style},onScroll:ve(o.onScroll,h=>{const y=h.currentTarget,{contentWrapper:g,shouldExpandOnScrollRef:b}=c;if(b!=null&&b.current&&g){const w=Math.abs(p.current-y.scrollTop);if(w>0){const k=window.innerHeight-Jn*2,S=parseFloat(g.style.minHeight),C=parseFloat(g.style.height),A=Math.max(S,C);if(A<k){const N=A+w,j=Math.min(k,N),O=N-j;g.style.height=j+"px",g.style.bottom==="0px"&&(y.scrollTop=O>0?O:0,g.style.justifyContent="flex-end")}}}p.current=y.scrollTop})})})]})});ek.displayName=Oh;var tk="SelectGroup",[$O,qO]=_i(tk),nk=v.forwardRef((e,r)=>{const{__scopeSelect:a,...l}=e,o=Mt();return f.jsx($O,{scope:a,id:o,children:f.jsx(Ce.div,{role:"group","aria-labelledby":o,...l,ref:r})})});nk.displayName=tk;var rk="SelectLabel",ak=v.forwardRef((e,r)=>{const{__scopeSelect:a,...l}=e,o=qO(rk,a);return f.jsx(Ce.div,{id:o.id,...l,ref:r})});ak.displayName=rk;var Sc="SelectItem",[GO,lk]=_i(Sc),ik=v.forwardRef((e,r)=>{const{__scopeSelect:a,value:l,disabled:o=!1,textValue:s,...c}=e,d=Oa(Sc,a),p=Da(Sc,a),h=d.value===l,[y,g]=v.useState(s!=null?s:""),[b,w]=v.useState(!1),k=Ve(r,N=>{var j;return(j=p.itemRefCallback)==null?void 0:j.call(p,N,l,o)}),S=Mt(),C=v.useRef("touch"),A=()=>{o||(d.onValueChange(l),d.onOpenChange(!1))};if(l==="")throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return f.jsx(GO,{scope:a,value:l,disabled:o,textId:S,isSelected:h,onItemTextChange:v.useCallback(N=>{g(j=>{var O;return j||((O=N==null?void 0:N.textContent)!=null?O:"").trim()})},[]),children:f.jsx(ed.ItemSlot,{scope:a,value:l,disabled:o,textValue:y,children:f.jsx(Ce.div,{role:"option","aria-labelledby":S,"data-highlighted":b?"":void 0,"aria-selected":h&&b,"data-state":h?"checked":"unchecked","aria-disabled":o||void 0,"data-disabled":o?"":void 0,tabIndex:o?void 0:-1,...c,ref:k,onFocus:ve(c.onFocus,()=>w(!0)),onBlur:ve(c.onBlur,()=>w(!1)),onClick:ve(c.onClick,()=>{C.current!=="mouse"&&A()}),onPointerUp:ve(c.onPointerUp,()=>{C.current==="mouse"&&A()}),onPointerDown:ve(c.onPointerDown,N=>{C.current=N.pointerType}),onPointerMove:ve(c.onPointerMove,N=>{var j;C.current=N.pointerType,o?(j=p.onItemLeave)==null||j.call(p):C.current==="mouse"&&N.currentTarget.focus({preventScroll:!0})}),onPointerLeave:ve(c.onPointerLeave,N=>{var j;N.currentTarget===document.activeElement&&((j=p.onItemLeave)==null||j.call(p))}),onKeyDown:ve(c.onKeyDown,N=>{var O;((O=p.searchRef)==null?void 0:O.current)!==""&&N.key===" "||(MO.includes(N.key)&&A(),N.key===" "&&N.preventDefault())})})})})});ik.displayName=Sc;var Io="SelectItemText",ok=v.forwardRef((e,r)=>{const{__scopeSelect:a,className:l,style:o,...s}=e,c=Oa(Io,a),d=Da(Io,a),p=lk(Io,a),h=LO(Io,a),[y,g]=v.useState(null),b=Ve(r,A=>g(A),p.onItemTextChange,A=>{var N;return(N=d.itemTextRefCallback)==null?void 0:N.call(d,A,p.value,p.disabled)}),w=y==null?void 0:y.textContent,k=v.useMemo(()=>f.jsx("option",{value:p.value,disabled:p.disabled,children:w},p.value),[p.disabled,p.value,w]),{onNativeOptionAdd:S,onNativeOptionRemove:C}=h;return It(()=>(S(k),()=>C(k)),[S,C,k]),f.jsxs(f.Fragment,{children:[f.jsx(Ce.span,{id:p.textId,...s,ref:b}),p.isSelected&&c.valueNode&&!c.valueNodeHasChildren?ls.createPortal(s.children,c.valueNode):null]})});ok.displayName=Io;var sk="SelectItemIndicator",uk=v.forwardRef((e,r)=>{const{__scopeSelect:a,...l}=e;return lk(sk,a).isSelected?f.jsx(Ce.span,{"aria-hidden":!0,...l,ref:r}):null});uk.displayName=sk;var Dh="SelectScrollUpButton",ck=v.forwardRef((e,r)=>{const a=Da(Dh,e.__scopeSelect),l=zm(Dh,e.__scopeSelect),[o,s]=v.useState(!1),c=Ve(r,l.onScrollButtonChange);return It(()=>{if(a.viewport&&a.isPositioned){let d=function(){const h=p.scrollTop>0;s(h)};const p=a.viewport;return d(),p.addEventListener("scroll",d),()=>p.removeEventListener("scroll",d)}},[a.viewport,a.isPositioned]),o?f.jsx(fk,{...e,ref:c,onAutoScroll:()=>{const{viewport:d,selectedItem:p}=a;d&&p&&(d.scrollTop=d.scrollTop-p.offsetHeight)}}):null});ck.displayName=Dh;var zh="SelectScrollDownButton",dk=v.forwardRef((e,r)=>{const a=Da(zh,e.__scopeSelect),l=zm(zh,e.__scopeSelect),[o,s]=v.useState(!1),c=Ve(r,l.onScrollButtonChange);return It(()=>{if(a.viewport&&a.isPositioned){let d=function(){const h=p.scrollHeight-p.clientHeight,y=Math.ceil(p.scrollTop)<h;s(y)};const p=a.viewport;return d(),p.addEventListener("scroll",d),()=>p.removeEventListener("scroll",d)}},[a.viewport,a.isPositioned]),o?f.jsx(fk,{...e,ref:c,onAutoScroll:()=>{const{viewport:d,selectedItem:p}=a;d&&p&&(d.scrollTop=d.scrollTop+p.offsetHeight)}}):null});dk.displayName=zh;var fk=v.forwardRef((e,r)=>{const{__scopeSelect:a,onAutoScroll:l,...o}=e,s=Da("SelectScrollButton",a),c=v.useRef(null),d=td(a),p=v.useCallback(()=>{c.current!==null&&(window.clearInterval(c.current),c.current=null)},[]);return v.useEffect(()=>()=>p(),[p]),It(()=>{var y;const h=d().find(g=>g.ref.current===document.activeElement);(y=h==null?void 0:h.ref.current)==null||y.scrollIntoView({block:"nearest"})},[d]),f.jsx(Ce.div,{"aria-hidden":!0,...o,ref:r,style:{flexShrink:0,...o.style},onPointerDown:ve(o.onPointerDown,()=>{c.current===null&&(c.current=window.setInterval(l,50))}),onPointerMove:ve(o.onPointerMove,()=>{var h;(h=s.onItemLeave)==null||h.call(s),c.current===null&&(c.current=window.setInterval(l,50))}),onPointerLeave:ve(o.onPointerLeave,()=>{p()})})}),YO="SelectSeparator",XO=v.forwardRef((e,r)=>{const{__scopeSelect:a,...l}=e;return f.jsx(Ce.div,{"aria-hidden":!0,...l,ref:r})});XO.displayName=YO;var Lh="SelectArrow",KO=v.forwardRef((e,r)=>{const{__scopeSelect:a,...l}=e,o=nd(a),s=Oa(Lh,a),c=Da(Lh,a);return s.open&&c.position==="popper"?f.jsx(Gc,{...o,...l,ref:r}):null});KO.displayName=Lh;var QO="SelectBubbleInput",pk=v.forwardRef(({__scopeSelect:e,value:r,...a},l)=>{const o=v.useRef(null),s=Ve(l,o),c=l_(r);return v.useEffect(()=>{const d=o.current;if(!d)return;const p=window.HTMLSelectElement.prototype,y=Object.getOwnPropertyDescriptor(p,"value").set;if(c!==r&&y){const g=new Event("change",{bubbles:!0});y.call(d,r),d.dispatchEvent(g)}},[c,r]),f.jsx(Ce.select,{...a,style:{...j1,...a.style},ref:s,defaultValue:r})});pk.displayName=QO;function hk(e){return e===""||e===void 0}function mk(e){const r=qt(e),a=v.useRef(""),l=v.useRef(0),o=v.useCallback(c=>{const d=a.current+c;r(d),(function p(h){a.current=h,window.clearTimeout(l.current),h!==""&&(l.current=window.setTimeout(()=>p(""),1e3))})(d)},[r]),s=v.useCallback(()=>{a.current="",window.clearTimeout(l.current)},[]);return v.useEffect(()=>()=>window.clearTimeout(l.current),[]),[a,o,s]}function gk(e,r,a){const o=r.length>1&&Array.from(r).every(h=>h===r[0])?r[0]:r,s=a?e.indexOf(a):-1;let c=ZO(e,Math.max(s,0));o.length===1&&(c=c.filter(h=>h!==a));const p=c.find(h=>h.textValue.toLowerCase().startsWith(o.toLowerCase()));return p!==a?p:void 0}function ZO(e,r){return e.map((a,l)=>e[(r+l)%e.length])}var WO=VS,JO=qS,eD=YS,tD=XS,nD=KS,rD=QS,aD=ek,lD=nk,iD=ak,oD=ik,sD=ok,uD=uk,cD=ck,dD=dk,fD="Separator",Kv="horizontal",pD=["horizontal","vertical"],yk=v.forwardRef((e,r)=>{const{decorative:a,orientation:l=Kv,...o}=e,s=hD(l)?l:Kv,d=a?{role:"none"}:{"aria-orientation":s==="vertical"?s:void 0,role:"separator"};return f.jsx(Ce.div,{"data-orientation":s,...d,...o,ref:r})});yk.displayName=fD;function hD(e){return pD.includes(e)}var mD=yk,rd="Tabs",[gD]=_n(rd,[Yc]),xk=Yc(),[yD,Lm]=gD(rd),bk=v.forwardRef((e,r)=>{const{__scopeTabs:a,value:l,onValueChange:o,defaultValue:s,orientation:c="horizontal",dir:d,activationMode:p="automatic",...h}=e,y=os(d),[g,b]=qr({prop:l,onChange:o,defaultProp:s!=null?s:"",caller:rd});return f.jsx(yD,{scope:a,baseId:Mt(),value:g,onValueChange:b,orientation:c,dir:y,activationMode:p,children:f.jsx(Ce.div,{dir:y,"data-orientation":c,...h,ref:r})})});bk.displayName=rd;var vk="TabsList",wk=v.forwardRef((e,r)=>{const{__scopeTabs:a,loop:l=!0,...o}=e,s=Lm(vk,a),c=xk(a);return f.jsx(zw,{asChild:!0,...c,orientation:s.orientation,dir:s.dir,loop:l,children:f.jsx(Ce.div,{role:"tablist","aria-orientation":s.orientation,...o,ref:r})})});wk.displayName=vk;var Sk="TabsTrigger",kk=v.forwardRef((e,r)=>{const{__scopeTabs:a,value:l,disabled:o=!1,...s}=e,c=Lm(Sk,a),d=xk(a),p=Ak(c.baseId,l),h=Nk(c.baseId,l),y=l===c.value;return f.jsx(Lw,{asChild:!0,...d,focusable:!o,active:y,children:f.jsx(Ce.button,{type:"button",role:"tab","aria-selected":y,"aria-controls":h,"data-state":y?"active":"inactive","data-disabled":o?"":void 0,disabled:o,id:p,...s,ref:r,onMouseDown:ve(e.onMouseDown,g=>{!o&&g.button===0&&g.ctrlKey===!1?c.onValueChange(l):g.preventDefault()}),onKeyDown:ve(e.onKeyDown,g=>{[" ","Enter"].includes(g.key)&&c.onValueChange(l)}),onFocus:ve(e.onFocus,()=>{const g=c.activationMode!=="manual";!y&&!o&&g&&c.onValueChange(l)})})})});kk.displayName=Sk;var Ek="TabsContent",Ck=v.forwardRef((e,r)=>{const{__scopeTabs:a,value:l,forceMount:o,children:s,...c}=e,d=Lm(Ek,a),p=Ak(d.baseId,l),h=Nk(d.baseId,l),y=l===d.value,g=v.useRef(y);return v.useEffect(()=>{const b=requestAnimationFrame(()=>g.current=!1);return()=>cancelAnimationFrame(b)},[]),f.jsx(Bt,{present:o||y,children:({present:b})=>f.jsx(Ce.div,{"data-state":y?"active":"inactive","data-orientation":d.orientation,role:"tabpanel","aria-labelledby":p,hidden:!b,id:h,tabIndex:0,...c,ref:r,style:{...e.style,animationDuration:g.current?"0s":void 0},children:b&&s})})});Ck.displayName=Ek;function Ak(e,r){return`${e}-trigger-${r}`}function Nk(e,r){return`${e}-content-${r}`}var xD=bk,bD=wk,vD=kk,wD=Ck,[ad]=_n("Tooltip",[Ra]),ld=Ra(),jk="TooltipProvider",SD=700,Ih="tooltip.open",[kD,Im]=ad(jk),Tk=e=>{const{__scopeTooltip:r,delayDuration:a=SD,skipDelayDuration:l=300,disableHoverableContent:o=!1,children:s}=e,c=v.useRef(!0),d=v.useRef(!1),p=v.useRef(0);return v.useEffect(()=>{const h=p.current;return()=>window.clearTimeout(h)},[]),f.jsx(kD,{scope:r,isOpenDelayedRef:c,delayDuration:a,onOpen:v.useCallback(()=>{window.clearTimeout(p.current),c.current=!1},[]),onClose:v.useCallback(()=>{window.clearTimeout(p.current),p.current=window.setTimeout(()=>c.current=!0,l)},[l]),isPointerInTransitRef:d,onPointerInTransitChange:v.useCallback(h=>{d.current=h},[]),disableHoverableContent:o,children:s})};Tk.displayName=jk;var Go="Tooltip",[ED,gs]=ad(Go),_k=e=>{const{__scopeTooltip:r,children:a,open:l,defaultOpen:o,onOpenChange:s,disableHoverableContent:c,delayDuration:d}=e,p=Im(Go,e.__scopeTooltip),h=ld(r),[y,g]=v.useState(null),b=Mt(),w=v.useRef(0),k=c!=null?c:p.disableHoverableContent,S=d!=null?d:p.delayDuration,C=v.useRef(!1),[A,N]=qr({prop:l,defaultProp:o!=null?o:!1,onChange:U=>{U?(p.onOpen(),document.dispatchEvent(new CustomEvent(Ih))):p.onClose(),s==null||s(U)},caller:Go}),j=v.useMemo(()=>A?C.current?"delayed-open":"instant-open":"closed",[A]),O=v.useCallback(()=>{window.clearTimeout(w.current),w.current=0,C.current=!1,N(!0)},[N]),D=v.useCallback(()=>{window.clearTimeout(w.current),w.current=0,N(!1)},[N]),M=v.useCallback(()=>{window.clearTimeout(w.current),w.current=window.setTimeout(()=>{C.current=!0,N(!0),w.current=0},S)},[S,N]);return v.useEffect(()=>()=>{w.current&&(window.clearTimeout(w.current),w.current=0)},[]),f.jsx($c,{...h,children:f.jsx(ED,{scope:r,contentId:b,open:A,stateAttribute:j,trigger:y,onTriggerChange:g,onTriggerEnter:v.useCallback(()=>{p.isOpenDelayedRef.current?M():O()},[p.isOpenDelayedRef,M,O]),onTriggerLeave:v.useCallback(()=>{k?D():(window.clearTimeout(w.current),w.current=0)},[D,k]),onOpen:O,onClose:D,disableHoverableContent:k,children:a})})};_k.displayName=Go;var Bh="TooltipTrigger",Rk=v.forwardRef((e,r)=>{const{__scopeTooltip:a,...l}=e,o=gs(Bh,a),s=Im(Bh,a),c=ld(a),d=v.useRef(null),p=Ve(r,d,o.onTriggerChange),h=v.useRef(!1),y=v.useRef(!1),g=v.useCallback(()=>h.current=!1,[]);return v.useEffect(()=>()=>document.removeEventListener("pointerup",g),[g]),f.jsx(ds,{asChild:!0,...c,children:f.jsx(Ce.button,{"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute,...l,ref:p,onPointerMove:ve(e.onPointerMove,b=>{b.pointerType!=="touch"&&!y.current&&!s.isPointerInTransitRef.current&&(o.onTriggerEnter(),y.current=!0)}),onPointerLeave:ve(e.onPointerLeave,()=>{o.onTriggerLeave(),y.current=!1}),onPointerDown:ve(e.onPointerDown,()=>{o.open&&o.onClose(),h.current=!0,document.addEventListener("pointerup",g,{once:!0})}),onFocus:ve(e.onFocus,()=>{h.current||o.onOpen()}),onBlur:ve(e.onBlur,o.onClose),onClick:ve(e.onClick,o.onClose)})})});Rk.displayName=Bh;var Bm="TooltipPortal",[CD,AD]=ad(Bm,{forceMount:void 0}),Mk=e=>{const{__scopeTooltip:r,forceMount:a,children:l,container:o}=e,s=gs(Bm,r);return f.jsx(CD,{scope:r,forceMount:a,children:f.jsx(Bt,{present:a||s.open,children:f.jsx(Ni,{asChild:!0,container:o,children:l})})})};Mk.displayName=Bm;var Si="TooltipContent",Ok=v.forwardRef((e,r)=>{const a=AD(Si,e.__scopeTooltip),{forceMount:l=a.forceMount,side:o="top",...s}=e,c=gs(Si,e.__scopeTooltip);return f.jsx(Bt,{present:l||c.open,children:c.disableHoverableContent?f.jsx(Dk,{side:o,...s,ref:r}):f.jsx(ND,{side:o,...s,ref:r})})}),ND=v.forwardRef((e,r)=>{const a=gs(Si,e.__scopeTooltip),l=Im(Si,e.__scopeTooltip),o=v.useRef(null),s=Ve(r,o),[c,d]=v.useState(null),{trigger:p,onClose:h}=a,y=o.current,{onPointerInTransitChange:g}=l,b=v.useCallback(()=>{d(null),g(!1)},[g]),w=v.useCallback((k,S)=>{const C=k.currentTarget,A={x:k.clientX,y:k.clientY},N=RD(A,C.getBoundingClientRect()),j=MD(A,N),O=OD(S.getBoundingClientRect()),D=zD([...j,...O]);d(D),g(!0)},[g]);return v.useEffect(()=>()=>b(),[b]),v.useEffect(()=>{if(p&&y){const k=C=>w(C,y),S=C=>w(C,p);return p.addEventListener("pointerleave",k),y.addEventListener("pointerleave",S),()=>{p.removeEventListener("pointerleave",k),y.removeEventListener("pointerleave",S)}}},[p,y,w,b]),v.useEffect(()=>{if(c){const k=S=>{const C=S.target,A={x:S.clientX,y:S.clientY},N=(p==null?void 0:p.contains(C))||(y==null?void 0:y.contains(C)),j=!DD(A,c);N?b():j&&(b(),h())};return document.addEventListener("pointermove",k),()=>document.removeEventListener("pointermove",k)}},[p,y,c,h,b]),f.jsx(Dk,{...e,ref:s})}),[jD,TD]=ad(Go,{isInside:!1}),_D=Aj("TooltipContent"),Dk=v.forwardRef((e,r)=>{const{__scopeTooltip:a,children:l,"aria-label":o,onEscapeKeyDown:s,onPointerDownOutside:c,...d}=e,p=gs(Si,a),h=ld(a),{onClose:y}=p;return v.useEffect(()=>(document.addEventListener(Ih,y),()=>document.removeEventListener(Ih,y)),[y]),v.useEffect(()=>{if(p.trigger){const g=b=>{const w=b.target;w!=null&&w.contains(p.trigger)&&y()};return window.addEventListener("scroll",g,{capture:!0}),()=>window.removeEventListener("scroll",g,{capture:!0})}},[p.trigger,y]),f.jsx(Ai,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:s,onPointerDownOutside:c,onFocusOutside:g=>g.preventDefault(),onDismiss:y,children:f.jsxs(qc,{"data-state":p.stateAttribute,...h,...d,ref:r,style:{...d.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[f.jsx(_D,{children:l}),f.jsx(jD,{scope:a,isInside:!0,children:f.jsx(Mj,{id:p.contentId,role:"tooltip",children:o||l})})]})})});Ok.displayName=Si;var zk="TooltipArrow",Lk=v.forwardRef((e,r)=>{const{__scopeTooltip:a,...l}=e,o=ld(a);return TD(zk,a).isInside?null:f.jsx(Gc,{...o,...l,ref:r})});Lk.displayName=zk;function RD(e,r){const a=Math.abs(r.top-e.y),l=Math.abs(r.bottom-e.y),o=Math.abs(r.right-e.x),s=Math.abs(r.left-e.x);switch(Math.min(a,l,o,s)){case s:return"left";case o:return"right";case a:return"top";case l:return"bottom";default:throw new Error("unreachable")}}function MD(e,r,a=5){const l=[];switch(r){case"top":l.push({x:e.x-a,y:e.y+a},{x:e.x+a,y:e.y+a});break;case"bottom":l.push({x:e.x-a,y:e.y-a},{x:e.x+a,y:e.y-a});break;case"left":l.push({x:e.x+a,y:e.y-a},{x:e.x+a,y:e.y+a});break;case"right":l.push({x:e.x-a,y:e.y-a},{x:e.x-a,y:e.y+a});break}return l}function OD(e){const{top:r,right:a,bottom:l,left:o}=e;return[{x:o,y:r},{x:a,y:r},{x:a,y:l},{x:o,y:l}]}function DD(e,r){const{x:a,y:l}=e;let o=!1;for(let s=0,c=r.length-1;s<r.length;c=s++){const d=r[s],p=r[c],h=d.x,y=d.y,g=p.x,b=p.y;y>l!=b>l&&a<(g-h)*(l-y)/(b-y)+h&&(o=!o)}return o}function zD(e){const r=e.slice();return r.sort((a,l)=>a.x<l.x?-1:a.x>l.x?1:a.y<l.y?-1:a.y>l.y?1:0),LD(r)}function LD(e){if(e.length<=1)return e.slice();const r=[];for(let l=0;l<e.length;l++){const o=e[l];for(;r.length>=2;){const s=r[r.length-1],c=r[r.length-2];if((s.x-c.x)*(o.y-c.y)>=(s.y-c.y)*(o.x-c.x))r.pop();else break}r.push(o)}r.pop();const a=[];for(let l=e.length-1;l>=0;l--){const o=e[l];for(;a.length>=2;){const s=a[a.length-1],c=a[a.length-2];if((s.x-c.x)*(o.y-c.y)>=(s.y-c.y)*(o.x-c.x))a.pop();else break}a.push(o)}return a.pop(),r.length===1&&a.length===1&&r[0].x===a[0].x&&r[0].y===a[0].y?r:r.concat(a)}var ID=Tk,BD=_k,PD=Rk,FD=Mk,UD=Ok,HD=Lk;const VD=(e,r)=>{const a=new Array(e.length+r.length);for(let l=0;l<e.length;l++)a[l]=e[l];for(let l=0;l<r.length;l++)a[e.length+l]=r[l];return a},$D=(e,r)=>({classGroupId:e,validator:r}),Ik=(e=new Map,r=null,a)=>({nextPart:e,validators:r,classGroupId:a}),kc="-",Qv=[],qD="arbitrary..",GD=e=>{const r=XD(e),{conflictingClassGroups:a,conflictingClassGroupModifiers:l}=e;return{getClassGroupId:c=>{if(c.startsWith("[")&&c.endsWith("]"))return YD(c);const d=c.split(kc),p=d[0]===""&&d.length>1?1:0;return Bk(d,p,r)},getConflictingClassGroupIds:(c,d)=>{if(d){const p=l[c],h=a[c];return p?h?VD(h,p):p:h||Qv}return a[c]||Qv}}},Bk=(e,r,a)=>{if(e.length-r===0)return a.classGroupId;const o=e[r],s=a.nextPart.get(o);if(s){const h=Bk(e,r+1,s);if(h)return h}const c=a.validators;if(c===null)return;const d=r===0?e.join(kc):e.slice(r).join(kc),p=c.length;for(let h=0;h<p;h++){const y=c[h];if(y.validator(d))return y.classGroupId}},YD=e=>e.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const r=e.slice(1,-1),a=r.indexOf(":"),l=r.slice(0,a);return l?qD+l:void 0})(),XD=e=>{const{theme:r,classGroups:a}=e;return KD(a,r)},KD=(e,r)=>{const a=Ik();for(const l in e){const o=e[l];Pm(o,a,l,r)}return a},Pm=(e,r,a,l)=>{const o=e.length;for(let s=0;s<o;s++){const c=e[s];QD(c,r,a,l)}},QD=(e,r,a,l)=>{if(typeof e=="string"){ZD(e,r,a);return}if(typeof e=="function"){WD(e,r,a,l);return}JD(e,r,a,l)},ZD=(e,r,a)=>{const l=e===""?r:Pk(r,e);l.classGroupId=a},WD=(e,r,a,l)=>{if(e4(e)){Pm(e(l),r,a,l);return}r.validators===null&&(r.validators=[]),r.validators.push($D(a,e))},JD=(e,r,a,l)=>{const o=Object.entries(e),s=o.length;for(let c=0;c<s;c++){const[d,p]=o[c];Pm(p,Pk(r,d),a,l)}},Pk=(e,r)=>{let a=e;const l=r.split(kc),o=l.length;for(let s=0;s<o;s++){const c=l[s];let d=a.nextPart.get(c);d||(d=Ik(),a.nextPart.set(c,d)),a=d}return a},e4=e=>"isThemeGetter"in e&&e.isThemeGetter===!0,t4=e=>{if(e<1)return{get:()=>{},set:()=>{}};let r=0,a=Object.create(null),l=Object.create(null);const o=(s,c)=>{a[s]=c,r++,r>e&&(r=0,l=a,a=Object.create(null))};return{get(s){let c=a[s];if(c!==void 0)return c;if((c=l[s])!==void 0)return o(s,c),c},set(s,c){s in a?a[s]=c:o(s,c)}}},Ph="!",Zv=":",n4=[],Wv=(e,r,a,l,o)=>({modifiers:e,hasImportantModifier:r,baseClassName:a,maybePostfixModifierPosition:l,isExternal:o}),r4=e=>{const{prefix:r,experimentalParseClassName:a}=e;let l=o=>{const s=[];let c=0,d=0,p=0,h;const y=o.length;for(let S=0;S<y;S++){const C=o[S];if(c===0&&d===0){if(C===Zv){s.push(o.slice(p,S)),p=S+1;continue}if(C==="/"){h=S;continue}}C==="["?c++:C==="]"?c--:C==="("?d++:C===")"&&d--}const g=s.length===0?o:o.slice(p);let b=g,w=!1;g.endsWith(Ph)?(b=g.slice(0,-1),w=!0):g.startsWith(Ph)&&(b=g.slice(1),w=!0);const k=h&&h>p?h-p:void 0;return Wv(s,w,b,k)};if(r){const o=r+Zv,s=l;l=c=>c.startsWith(o)?s(c.slice(o.length)):Wv(n4,!1,c,void 0,!0)}if(a){const o=l;l=s=>a({className:s,parseClassName:o})}return l},a4=e=>{const r=new Map;return e.orderSensitiveModifiers.forEach((a,l)=>{r.set(a,1e6+l)}),a=>{const l=[];let o=[];for(let s=0;s<a.length;s++){const c=a[s],d=c[0]==="[",p=r.has(c);d||p?(o.length>0&&(o.sort(),l.push(...o),o=[]),l.push(c)):o.push(c)}return o.length>0&&(o.sort(),l.push(...o)),l}},l4=e=>({cache:t4(e.cacheSize),parseClassName:r4(e),sortModifiers:a4(e),...GD(e)}),i4=/\s+/,o4=(e,r)=>{const{parseClassName:a,getClassGroupId:l,getConflictingClassGroupIds:o,sortModifiers:s}=r,c=[],d=e.trim().split(i4);let p="";for(let h=d.length-1;h>=0;h-=1){const y=d[h],{isExternal:g,modifiers:b,hasImportantModifier:w,baseClassName:k,maybePostfixModifierPosition:S}=a(y);if(g){p=y+(p.length>0?" "+p:p);continue}let C=!!S,A=l(C?k.substring(0,S):k);if(!A){if(!C){p=y+(p.length>0?" "+p:p);continue}if(A=l(k),!A){p=y+(p.length>0?" "+p:p);continue}C=!1}const N=b.length===0?"":b.length===1?b[0]:s(b).join(":"),j=w?N+Ph:N,O=j+A;if(c.indexOf(O)>-1)continue;c.push(O);const D=o(A,C);for(let M=0;M<D.length;++M){const U=D[M];c.push(j+U)}p=y+(p.length>0?" "+p:p)}return p},s4=(...e)=>{let r=0,a,l,o="";for(;r<e.length;)(a=e[r++])&&(l=Fk(a))&&(o&&(o+=" "),o+=l);return o},Fk=e=>{if(typeof e=="string")return e;let r,a="";for(let l=0;l<e.length;l++)e[l]&&(r=Fk(e[l]))&&(a&&(a+=" "),a+=r);return a},u4=(e,...r)=>{let a,l,o,s;const c=p=>{const h=r.reduce((y,g)=>g(y),e());return a=l4(h),l=a.cache.get,o=a.cache.set,s=d,d(p)},d=p=>{const h=l(p);if(h)return h;const y=o4(p,a);return o(p,y),y};return s=c,(...p)=>s(s4(...p))},c4=[],Rt=e=>{const r=a=>a[e]||c4;return r.isThemeGetter=!0,r},Uk=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,Hk=/^\((?:(\w[\w-]*):)?(.+)\)$/i,d4=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,f4=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,p4=/\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$/,h4=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,m4=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,g4=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,wa=e=>d4.test(e),Ue=e=>!!e&&!Number.isNaN(Number(e)),Sa=e=>!!e&&Number.isInteger(Number(e)),Qp=e=>e.endsWith("%")&&Ue(e.slice(0,-1)),Fr=e=>f4.test(e),Vk=()=>!0,y4=e=>p4.test(e)&&!h4.test(e),Fm=()=>!1,x4=e=>m4.test(e),b4=e=>g4.test(e),v4=e=>!Se(e)&&!ke(e),w4=e=>za(e,Gk,Fm),Se=e=>Uk.test(e),il=e=>za(e,Yk,y4),Jv=e=>za(e,T4,Ue),S4=e=>za(e,Kk,Vk),k4=e=>za(e,Xk,Fm),e0=e=>za(e,$k,Fm),E4=e=>za(e,qk,b4),Xu=e=>za(e,Qk,x4),ke=e=>Hk.test(e),_o=e=>bl(e,Yk),C4=e=>bl(e,Xk),t0=e=>bl(e,$k),A4=e=>bl(e,Gk),N4=e=>bl(e,qk),Ku=e=>bl(e,Qk,!0),j4=e=>bl(e,Kk,!0),za=(e,r,a)=>{const l=Uk.exec(e);return l?l[1]?r(l[1]):a(l[2]):!1},bl=(e,r,a=!1)=>{const l=Hk.exec(e);return l?l[1]?r(l[1]):a:!1},$k=e=>e==="position"||e==="percentage",qk=e=>e==="image"||e==="url",Gk=e=>e==="length"||e==="size"||e==="bg-size",Yk=e=>e==="length",T4=e=>e==="number",Xk=e=>e==="family-name",Kk=e=>e==="number"||e==="weight",Qk=e=>e==="shadow",_4=()=>{const e=Rt("color"),r=Rt("font"),a=Rt("text"),l=Rt("font-weight"),o=Rt("tracking"),s=Rt("leading"),c=Rt("breakpoint"),d=Rt("container"),p=Rt("spacing"),h=Rt("radius"),y=Rt("shadow"),g=Rt("inset-shadow"),b=Rt("text-shadow"),w=Rt("drop-shadow"),k=Rt("blur"),S=Rt("perspective"),C=Rt("aspect"),A=Rt("ease"),N=Rt("animate"),j=()=>["auto","avoid","all","avoid-page","page","left","right","column"],O=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],D=()=>[...O(),ke,Se],M=()=>["auto","hidden","clip","visible","scroll"],U=()=>["auto","contain","none"],F=()=>[ke,Se,p],Q=()=>[wa,"full","auto",...F()],I=()=>[Sa,"none","subgrid",ke,Se],Y=()=>["auto",{span:["full",Sa,ke,Se]},Sa,ke,Se],V=()=>[Sa,"auto",ke,Se],ue=()=>["auto","min","max","fr",ke,Se],W=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],J=()=>["start","end","center","stretch","center-safe","end-safe"],B=()=>["auto",...F()],G=()=>[wa,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...F()],te=()=>[wa,"screen","full","dvw","lvw","svw","min","max","fit",...F()],ce=()=>[wa,"screen","full","lh","dvh","lvh","svh","min","max","fit",...F()],R=()=>[e,ke,Se],z=()=>[...O(),t0,e0,{position:[ke,Se]}],L=()=>["no-repeat",{repeat:["","x","y","space","round"]}],_=()=>["auto","cover","contain",A4,w4,{size:[ke,Se]}],re=()=>[Qp,_o,il],ne=()=>["","none","full",h,ke,Se],ie=()=>["",Ue,_o,il],le=()=>["solid","dashed","dotted","double"],be=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],he=()=>[Ue,Qp,t0,e0],Ne=()=>["","none",k,ke,Se],De=()=>["none",Ue,ke,Se],ze=()=>["none",Ue,ke,Se],gt=()=>[Ue,ke,Se],nt=()=>[wa,"full",...F()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[Fr],breakpoint:[Fr],color:[Vk],container:[Fr],"drop-shadow":[Fr],ease:["in","out","in-out"],font:[v4],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[Fr],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[Fr],shadow:[Fr],spacing:["px",Ue],text:[Fr],"text-shadow":[Fr],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",wa,Se,ke,C]}],container:["container"],columns:[{columns:[Ue,Se,ke,d]}],"break-after":[{"break-after":j()}],"break-before":[{"break-before":j()}],"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"],sr:["sr-only","not-sr-only"],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:D()}],overflow:[{overflow:M()}],"overflow-x":[{"overflow-x":M()}],"overflow-y":[{"overflow-y":M()}],overscroll:[{overscroll:U()}],"overscroll-x":[{"overscroll-x":U()}],"overscroll-y":[{"overscroll-y":U()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:Q()}],"inset-x":[{"inset-x":Q()}],"inset-y":[{"inset-y":Q()}],start:[{"inset-s":Q(),start:Q()}],end:[{"inset-e":Q(),end:Q()}],"inset-bs":[{"inset-bs":Q()}],"inset-be":[{"inset-be":Q()}],top:[{top:Q()}],right:[{right:Q()}],bottom:[{bottom:Q()}],left:[{left:Q()}],visibility:["visible","invisible","collapse"],z:[{z:[Sa,"auto",ke,Se]}],basis:[{basis:[wa,"full","auto",d,...F()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[Ue,wa,"auto","initial","none",Se]}],grow:[{grow:["",Ue,ke,Se]}],shrink:[{shrink:["",Ue,ke,Se]}],order:[{order:[Sa,"first","last","none",ke,Se]}],"grid-cols":[{"grid-cols":I()}],"col-start-end":[{col:Y()}],"col-start":[{"col-start":V()}],"col-end":[{"col-end":V()}],"grid-rows":[{"grid-rows":I()}],"row-start-end":[{row:Y()}],"row-start":[{"row-start":V()}],"row-end":[{"row-end":V()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":ue()}],"auto-rows":[{"auto-rows":ue()}],gap:[{gap:F()}],"gap-x":[{"gap-x":F()}],"gap-y":[{"gap-y":F()}],"justify-content":[{justify:[...W(),"normal"]}],"justify-items":[{"justify-items":[...J(),"normal"]}],"justify-self":[{"justify-self":["auto",...J()]}],"align-content":[{content:["normal",...W()]}],"align-items":[{items:[...J(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...J(),{baseline:["","last"]}]}],"place-content":[{"place-content":W()}],"place-items":[{"place-items":[...J(),"baseline"]}],"place-self":[{"place-self":["auto",...J()]}],p:[{p:F()}],px:[{px:F()}],py:[{py:F()}],ps:[{ps:F()}],pe:[{pe:F()}],pbs:[{pbs:F()}],pbe:[{pbe:F()}],pt:[{pt:F()}],pr:[{pr:F()}],pb:[{pb:F()}],pl:[{pl:F()}],m:[{m:B()}],mx:[{mx:B()}],my:[{my:B()}],ms:[{ms:B()}],me:[{me:B()}],mbs:[{mbs:B()}],mbe:[{mbe:B()}],mt:[{mt:B()}],mr:[{mr:B()}],mb:[{mb:B()}],ml:[{ml:B()}],"space-x":[{"space-x":F()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":F()}],"space-y-reverse":["space-y-reverse"],size:[{size:G()}],"inline-size":[{inline:["auto",...te()]}],"min-inline-size":[{"min-inline":["auto",...te()]}],"max-inline-size":[{"max-inline":["none",...te()]}],"block-size":[{block:["auto",...ce()]}],"min-block-size":[{"min-block":["auto",...ce()]}],"max-block-size":[{"max-block":["none",...ce()]}],w:[{w:[d,"screen",...G()]}],"min-w":[{"min-w":[d,"screen","none",...G()]}],"max-w":[{"max-w":[d,"screen","none","prose",{screen:[c]},...G()]}],h:[{h:["screen","lh",...G()]}],"min-h":[{"min-h":["screen","lh","none",...G()]}],"max-h":[{"max-h":["screen","lh",...G()]}],"font-size":[{text:["base",a,_o,il]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[l,j4,S4]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",Qp,Se]}],"font-family":[{font:[C4,k4,r]}],"font-features":[{"font-features":[Se]}],"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:[o,ke,Se]}],"line-clamp":[{"line-clamp":[Ue,"none",ke,Jv]}],leading:[{leading:[s,...F()]}],"list-image":[{"list-image":["none",ke,Se]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",ke,Se]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:R()}],"text-color":[{text:R()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...le(),"wavy"]}],"text-decoration-thickness":[{decoration:[Ue,"from-font","auto",ke,il]}],"text-decoration-color":[{decoration:R()}],"underline-offset":[{"underline-offset":[Ue,"auto",ke,Se]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:F()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",ke,Se]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",ke,Se]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:z()}],"bg-repeat":[{bg:L()}],"bg-size":[{bg:_()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Sa,ke,Se],radial:["",ke,Se],conic:[Sa,ke,Se]},N4,E4]}],"bg-color":[{bg:R()}],"gradient-from-pos":[{from:re()}],"gradient-via-pos":[{via:re()}],"gradient-to-pos":[{to:re()}],"gradient-from":[{from:R()}],"gradient-via":[{via:R()}],"gradient-to":[{to:R()}],rounded:[{rounded:ne()}],"rounded-s":[{"rounded-s":ne()}],"rounded-e":[{"rounded-e":ne()}],"rounded-t":[{"rounded-t":ne()}],"rounded-r":[{"rounded-r":ne()}],"rounded-b":[{"rounded-b":ne()}],"rounded-l":[{"rounded-l":ne()}],"rounded-ss":[{"rounded-ss":ne()}],"rounded-se":[{"rounded-se":ne()}],"rounded-ee":[{"rounded-ee":ne()}],"rounded-es":[{"rounded-es":ne()}],"rounded-tl":[{"rounded-tl":ne()}],"rounded-tr":[{"rounded-tr":ne()}],"rounded-br":[{"rounded-br":ne()}],"rounded-bl":[{"rounded-bl":ne()}],"border-w":[{border:ie()}],"border-w-x":[{"border-x":ie()}],"border-w-y":[{"border-y":ie()}],"border-w-s":[{"border-s":ie()}],"border-w-e":[{"border-e":ie()}],"border-w-bs":[{"border-bs":ie()}],"border-w-be":[{"border-be":ie()}],"border-w-t":[{"border-t":ie()}],"border-w-r":[{"border-r":ie()}],"border-w-b":[{"border-b":ie()}],"border-w-l":[{"border-l":ie()}],"divide-x":[{"divide-x":ie()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":ie()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...le(),"hidden","none"]}],"divide-style":[{divide:[...le(),"hidden","none"]}],"border-color":[{border:R()}],"border-color-x":[{"border-x":R()}],"border-color-y":[{"border-y":R()}],"border-color-s":[{"border-s":R()}],"border-color-e":[{"border-e":R()}],"border-color-bs":[{"border-bs":R()}],"border-color-be":[{"border-be":R()}],"border-color-t":[{"border-t":R()}],"border-color-r":[{"border-r":R()}],"border-color-b":[{"border-b":R()}],"border-color-l":[{"border-l":R()}],"divide-color":[{divide:R()}],"outline-style":[{outline:[...le(),"none","hidden"]}],"outline-offset":[{"outline-offset":[Ue,ke,Se]}],"outline-w":[{outline:["",Ue,_o,il]}],"outline-color":[{outline:R()}],shadow:[{shadow:["","none",y,Ku,Xu]}],"shadow-color":[{shadow:R()}],"inset-shadow":[{"inset-shadow":["none",g,Ku,Xu]}],"inset-shadow-color":[{"inset-shadow":R()}],"ring-w":[{ring:ie()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:R()}],"ring-offset-w":[{"ring-offset":[Ue,il]}],"ring-offset-color":[{"ring-offset":R()}],"inset-ring-w":[{"inset-ring":ie()}],"inset-ring-color":[{"inset-ring":R()}],"text-shadow":[{"text-shadow":["none",b,Ku,Xu]}],"text-shadow-color":[{"text-shadow":R()}],opacity:[{opacity:[Ue,ke,Se]}],"mix-blend":[{"mix-blend":[...be(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":be()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[Ue]}],"mask-image-linear-from-pos":[{"mask-linear-from":he()}],"mask-image-linear-to-pos":[{"mask-linear-to":he()}],"mask-image-linear-from-color":[{"mask-linear-from":R()}],"mask-image-linear-to-color":[{"mask-linear-to":R()}],"mask-image-t-from-pos":[{"mask-t-from":he()}],"mask-image-t-to-pos":[{"mask-t-to":he()}],"mask-image-t-from-color":[{"mask-t-from":R()}],"mask-image-t-to-color":[{"mask-t-to":R()}],"mask-image-r-from-pos":[{"mask-r-from":he()}],"mask-image-r-to-pos":[{"mask-r-to":he()}],"mask-image-r-from-color":[{"mask-r-from":R()}],"mask-image-r-to-color":[{"mask-r-to":R()}],"mask-image-b-from-pos":[{"mask-b-from":he()}],"mask-image-b-to-pos":[{"mask-b-to":he()}],"mask-image-b-from-color":[{"mask-b-from":R()}],"mask-image-b-to-color":[{"mask-b-to":R()}],"mask-image-l-from-pos":[{"mask-l-from":he()}],"mask-image-l-to-pos":[{"mask-l-to":he()}],"mask-image-l-from-color":[{"mask-l-from":R()}],"mask-image-l-to-color":[{"mask-l-to":R()}],"mask-image-x-from-pos":[{"mask-x-from":he()}],"mask-image-x-to-pos":[{"mask-x-to":he()}],"mask-image-x-from-color":[{"mask-x-from":R()}],"mask-image-x-to-color":[{"mask-x-to":R()}],"mask-image-y-from-pos":[{"mask-y-from":he()}],"mask-image-y-to-pos":[{"mask-y-to":he()}],"mask-image-y-from-color":[{"mask-y-from":R()}],"mask-image-y-to-color":[{"mask-y-to":R()}],"mask-image-radial":[{"mask-radial":[ke,Se]}],"mask-image-radial-from-pos":[{"mask-radial-from":he()}],"mask-image-radial-to-pos":[{"mask-radial-to":he()}],"mask-image-radial-from-color":[{"mask-radial-from":R()}],"mask-image-radial-to-color":[{"mask-radial-to":R()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":O()}],"mask-image-conic-pos":[{"mask-conic":[Ue]}],"mask-image-conic-from-pos":[{"mask-conic-from":he()}],"mask-image-conic-to-pos":[{"mask-conic-to":he()}],"mask-image-conic-from-color":[{"mask-conic-from":R()}],"mask-image-conic-to-color":[{"mask-conic-to":R()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:z()}],"mask-repeat":[{mask:L()}],"mask-size":[{mask:_()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",ke,Se]}],filter:[{filter:["","none",ke,Se]}],blur:[{blur:Ne()}],brightness:[{brightness:[Ue,ke,Se]}],contrast:[{contrast:[Ue,ke,Se]}],"drop-shadow":[{"drop-shadow":["","none",w,Ku,Xu]}],"drop-shadow-color":[{"drop-shadow":R()}],grayscale:[{grayscale:["",Ue,ke,Se]}],"hue-rotate":[{"hue-rotate":[Ue,ke,Se]}],invert:[{invert:["",Ue,ke,Se]}],saturate:[{saturate:[Ue,ke,Se]}],sepia:[{sepia:["",Ue,ke,Se]}],"backdrop-filter":[{"backdrop-filter":["","none",ke,Se]}],"backdrop-blur":[{"backdrop-blur":Ne()}],"backdrop-brightness":[{"backdrop-brightness":[Ue,ke,Se]}],"backdrop-contrast":[{"backdrop-contrast":[Ue,ke,Se]}],"backdrop-grayscale":[{"backdrop-grayscale":["",Ue,ke,Se]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[Ue,ke,Se]}],"backdrop-invert":[{"backdrop-invert":["",Ue,ke,Se]}],"backdrop-opacity":[{"backdrop-opacity":[Ue,ke,Se]}],"backdrop-saturate":[{"backdrop-saturate":[Ue,ke,Se]}],"backdrop-sepia":[{"backdrop-sepia":["",Ue,ke,Se]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":F()}],"border-spacing-x":[{"border-spacing-x":F()}],"border-spacing-y":[{"border-spacing-y":F()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",ke,Se]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[Ue,"initial",ke,Se]}],ease:[{ease:["linear","initial",A,ke,Se]}],delay:[{delay:[Ue,ke,Se]}],animate:[{animate:["none",N,ke,Se]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[S,ke,Se]}],"perspective-origin":[{"perspective-origin":D()}],rotate:[{rotate:De()}],"rotate-x":[{"rotate-x":De()}],"rotate-y":[{"rotate-y":De()}],"rotate-z":[{"rotate-z":De()}],scale:[{scale:ze()}],"scale-x":[{"scale-x":ze()}],"scale-y":[{"scale-y":ze()}],"scale-z":[{"scale-z":ze()}],"scale-3d":["scale-3d"],skew:[{skew:gt()}],"skew-x":[{"skew-x":gt()}],"skew-y":[{"skew-y":gt()}],transform:[{transform:[ke,Se,"","none","gpu","cpu"]}],"transform-origin":[{origin:D()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:nt()}],"translate-x":[{"translate-x":nt()}],"translate-y":[{"translate-y":nt()}],"translate-z":[{"translate-z":nt()}],"translate-none":["translate-none"],accent:[{accent:R()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:R()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],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",ke,Se]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":F()}],"scroll-mx":[{"scroll-mx":F()}],"scroll-my":[{"scroll-my":F()}],"scroll-ms":[{"scroll-ms":F()}],"scroll-me":[{"scroll-me":F()}],"scroll-mbs":[{"scroll-mbs":F()}],"scroll-mbe":[{"scroll-mbe":F()}],"scroll-mt":[{"scroll-mt":F()}],"scroll-mr":[{"scroll-mr":F()}],"scroll-mb":[{"scroll-mb":F()}],"scroll-ml":[{"scroll-ml":F()}],"scroll-p":[{"scroll-p":F()}],"scroll-px":[{"scroll-px":F()}],"scroll-py":[{"scroll-py":F()}],"scroll-ps":[{"scroll-ps":F()}],"scroll-pe":[{"scroll-pe":F()}],"scroll-pbs":[{"scroll-pbs":F()}],"scroll-pbe":[{"scroll-pbe":F()}],"scroll-pt":[{"scroll-pt":F()}],"scroll-pr":[{"scroll-pr":F()}],"scroll-pb":[{"scroll-pb":F()}],"scroll-pl":[{"scroll-pl":F()}],"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",ke,Se]}],fill:[{fill:["none",...R()]}],"stroke-w":[{stroke:[Ue,_o,il,Jv]}],stroke:[{stroke:["none",...R()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","inset-bs","inset-be","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","pbs","pbe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mbs","mbe","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-x","border-w-y","border-w-s","border-w-e","border-w-bs","border-w-be","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-x","border-color-y","border-color-s","border-color-e","border-color-bs","border-color-be","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"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mbs","scroll-mbe","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-pbs","scroll-pbe","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"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},R4=u4(_4);function ye(...e){return R4(Dc(e))}const M4=Ci("group/button inline-flex shrink-0 items-center justify-center rounded-lg border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",{variants:{variant:{default:"bg-primary text-primary-foreground [a]:hover:bg-primary/80",outline:"border-border bg-background hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80 aria-expanded:bg-secondary aria-expanded:text-secondary-foreground",ghost:"hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:hover:bg-muted/50",destructive:"bg-destructive/10 text-destructive hover:bg-destructive/20 focus-visible:border-destructive/40 focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:hover:bg-destructive/30 dark:focus-visible:ring-destructive/40",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-8 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",xs:"h-6 gap-1 rounded-[min(var(--radius-md),10px)] px-2 text-xs in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3",sm:"h-7 gap-1 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3.5",lg:"h-9 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-3 has-data-[icon=inline-start]:pl-3",icon:"size-8","icon-xs":"size-6 rounded-[min(var(--radius-md),10px)] in-data-[slot=button-group]:rounded-lg [&_svg:not([class*='size-'])]:size-3","icon-sm":"size-7 rounded-[min(var(--radius-md),12px)] in-data-[slot=button-group]:rounded-lg","icon-lg":"size-9"}},defaultVariants:{variant:"default",size:"default"}});function Me({className:e,variant:r="default",size:a="default",asChild:l=!1,...o}){const s=l?is:"button";return f.jsx(s,{"data-slot":"button","data-variant":r,"data-size":a,className:ye(M4({variant:r,size:a,className:e})),...o})}function ys(){return{fetchWithAuth:v.useCallback(async(r,a={},l)=>{const{serverUrl:o,token:s}=l||{};let c=r;r.startsWith("/")&&o&&(c=`http://${o}${r}`);const d=new Headers(a.headers||{});return s&&d.set("Authorization",`Bearer ${s}`),fetch(c,{...a,headers:d})},[])}}function xs({...e}){return f.jsx(um,{"data-slot":"dialog",...e})}function O4({...e}){return f.jsx(cm,{"data-slot":"dialog-portal",...e})}function D4({className:e,...r}){return f.jsx(dm,{"data-slot":"dialog-overlay",className:ye("fixed inset-0 isolate z-50 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",e),...r})}function bs({className:e,children:r,showCloseButton:a=!0,...l}){return f.jsxs(O4,{children:[f.jsx(D4,{}),f.jsxs(fm,{"data-slot":"dialog-content",className:ye("fixed top-1/2 left-1/2 z-50 grid w-full max-w-[calc(100%-2rem)] -translate-x-1/2 -translate-y-1/2 gap-4 rounded-xl bg-background p-4 text-sm ring-1 ring-foreground/10 duration-100 outline-none sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",e),...l,children:[r,a&&f.jsx(pm,{"data-slot":"dialog-close",asChild:!0,children:f.jsxs(Me,{variant:"ghost",className:"absolute top-2 right-2",size:"icon-sm",children:[f.jsx(xi,{}),f.jsx("span",{className:"sr-only",children:"Close"})]})})]})]})}function vs({className:e,...r}){return f.jsx("div",{"data-slot":"dialog-header",className:ye("flex flex-col gap-2",e),...r})}function Um({className:e,showCloseButton:r=!1,children:a,...l}){return f.jsxs("div",{"data-slot":"dialog-footer",className:ye("-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-xl border-t bg-muted/50 p-4 sm:flex-row sm:justify-end",e),...l,children:[a,r&&f.jsx(pm,{asChild:!0,children:f.jsx(Me,{variant:"outline",children:"Close"})})]})}function ws({className:e,...r}){return f.jsx(ow,{"data-slot":"dialog-title",className:ye("text-base leading-none font-medium",e),...r})}function id({className:e,...r}){return f.jsx(sw,{"data-slot":"dialog-description",className:ye("text-sm text-muted-foreground *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground",e),...r})}function lc({className:e,type:r,...a}){return f.jsx("input",{type:r,"data-slot":"input",className:ye("h-8 w-full min-w-0 rounded-lg border border-input bg-transparent px-2.5 py-1 text-base transition-colors outline-none file:inline-flex file:h-6 file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40",e),...a})}const Ta=v.forwardRef(({className:e,children:r,...a},l)=>f.jsxs(jO,{"data-slot":"scroll-area",className:ye("relative overflow-hidden",e),...a,children:[f.jsx(TO,{ref:l,"data-slot":"scroll-area-viewport",className:"size-full rounded-[inherit] outline-none",style:{WebkitOverflowScrolling:"touch"},children:r}),f.jsx(z4,{}),f.jsx(_O,{})]}));Ta.displayName="ScrollArea";function z4({className:e,orientation:r="vertical",...a}){return f.jsx(DS,{"data-slot":"scroll-area-scrollbar","data-orientation":r,orientation:r,className:ye("flex touch-none p-px transition-colors select-none data-horizontal:h-2.5 data-horizontal:flex-col data-horizontal:border-t data-horizontal:border-t-transparent data-vertical:h-full data-vertical:w-2.5 data-vertical:border-l data-vertical:border-l-transparent",e),...a,children:f.jsx(BS,{"data-slot":"scroll-area-thumb",className:"relative flex-1 rounded-full bg-border"})})}function L4(e){const a=e.replace(/\\/g,"/").split("/");return a.pop(),a.join("/")||"/"}function I4({open:e,onOpenChange:r,onSelect:a,initialPath:l,title:o="Select Folder"}){const[s,c]=v.useState(l||""),[d,p]=v.useState([]),[h,y]=v.useState(!1),[g,b]=v.useState(0),[w,k]=v.useState(null),[S,C]=v.useState(""),A=v.useRef(null),N=v.useRef(null),{fetchWithAuth:j}=ys(),{activeServer:O}=Ei(),D=v.useCallback(async V=>{y(!0),k(null),b(0),C("");try{const ue=await j(`/api/fs/browse?path=${encodeURIComponent(V)}`,{},{serverUrl:O==null?void 0:O.url,token:O==null?void 0:O.token}),W=await ue.json();if(!ue.ok)throw new Error(W.message||"Failed to browse directory");const J=W.files.filter(B=>B.type==="directory");p(J),c(W.currentPath)}catch(ue){k(ue instanceof Error?ue.message:"Failed to load directory"),p([])}finally{y(!1)}},[j,O]);v.useEffect(()=>{e&&D(l||"")},[e,l,D]),v.useEffect(()=>{b(0)},[S]);const M=d.filter(V=>V.name.toLowerCase().includes(S.toLowerCase())),U=()=>{const V=L4(s);V!==s&&D(V)},F=()=>{s&&(a(s),r(!1))},Q=V=>{const ue=s?`${s}/${V.name}`:V.name;D(ue)},I=V=>{if(M.length!==0)switch(V.key){case"ArrowDown":V.preventDefault(),b(ue=>Math.min(ue+1,M.length-1));break;case"ArrowUp":V.preventDefault(),b(ue=>Math.max(ue-1,0));break;case"Enter":V.preventDefault(),M[g]&&Q(M[g]);break;case"Escape":S&&(V.preventDefault(),C(""));break}};v.useEffect(()=>{if(N.current&&M.length>0){const V=N.current.children[g];V&&V.scrollIntoView({block:"nearest"})}},[g,M.length]),v.useEffect(()=>{e&&setTimeout(()=>{var V;return(V=A.current)==null?void 0:V.focus()},100)},[e]);const Y=(V,ue=50)=>{if(V.length<=ue)return V;const W=V.split("/");return W.length<=2?V:".../"+W.slice(-2).join("/")};return f.jsx(xs,{open:e,onOpenChange:r,children:f.jsxs(bs,{className:"sm:max-w-lg",onKeyDown:I,children:[f.jsx(vs,{children:f.jsx(ws,{children:o})}),f.jsxs("div",{className:"space-y-3",children:[f.jsxs("div",{className:"flex items-center gap-2 p-2 bg-muted rounded-md",children:[f.jsx(Me,{variant:"ghost",size:"icon",className:"h-7 w-7 flex-shrink-0",onClick:U,disabled:h||!s,children:f.jsx(rN,{className:"w-4 h-4"})}),f.jsx("span",{className:"flex-1 text-sm font-mono truncate",title:s,children:Y(s)||"Home"})]}),f.jsxs("div",{className:"relative",children:[f.jsx(tm,{className:"absolute left-2.5 top-1/2 -translate-y-1/2 w-4 h-4 text-muted-foreground"}),f.jsx(lc,{ref:A,placeholder:"Filter folders...",value:S,onChange:V=>C(V.target.value),className:"pl-8"})]}),f.jsx(Ta,{className:"h-64 border rounded-md",children:h?f.jsxs("div",{className:"flex items-center justify-center h-full text-muted-foreground",children:[f.jsx(Gn,{className:"w-4 h-4 animate-spin mr-2"}),"Loading..."]}):w?f.jsxs("div",{className:"flex flex-col items-center justify-center h-full text-muted-foreground",children:[f.jsx("span",{className:"text-destructive",children:w}),f.jsx(Me,{variant:"ghost",size:"sm",onClick:()=>D(s),className:"mt-2",children:"Retry"})]}):M.length===0?f.jsxs("div",{className:"flex flex-col items-center justify-center h-full text-muted-foreground text-sm",children:[f.jsx(sl,{className:"w-8 h-8 mb-2 opacity-50"}),S?"No matching folders":"No folders in this directory"]}):f.jsx("div",{className:"p-1",ref:N,children:M.map((V,ue)=>f.jsxs("button",{onClick:()=>{b(ue)},onDoubleClick:()=>Q(V),className:ye("flex items-center gap-2 w-full px-2 py-1.5 rounded text-sm text-left","hover:bg-muted",ue===g&&"bg-primary/20 text-primary font-medium ring-1 ring-primary/50"),children:[f.jsx(sl,{className:"w-4 h-4 text-amber-500 flex-shrink-0"}),f.jsx("span",{className:"truncate flex-1",children:V.name}),ue===g&&f.jsx(Vr,{className:"w-4 h-4 text-primary"})]},V.path))})}),w&&f.jsx("p",{className:"text-xs text-destructive",children:w})]}),f.jsxs(Um,{children:[f.jsx(Me,{variant:"outline",onClick:()=>r(!1),children:"Cancel"}),f.jsx(Me,{onClick:F,disabled:!s||h,children:"Use This Folder"})]})]})})}var n0=1,B4=.9,P4=.8,F4=.17,Zp=.1,Wp=.999,U4=.9999,H4=.99,V4=/[\\\/_+.#"@\[\(\{&]/,$4=/[\\\/_+.#"@\[\(\{&]/g,q4=/[\s-]/,Zk=/[\s-]/g;function Fh(e,r,a,l,o,s,c){if(s===r.length)return o===e.length?n0:H4;var d=`${o},${s}`;if(c[d]!==void 0)return c[d];for(var p=l.charAt(s),h=a.indexOf(p,o),y=0,g,b,w,k;h>=0;)g=Fh(e,r,a,l,h+1,s+1,c),g>y&&(h===o?g*=n0:V4.test(e.charAt(h-1))?(g*=P4,w=e.slice(o,h-1).match($4),w&&o>0&&(g*=Math.pow(Wp,w.length))):q4.test(e.charAt(h-1))?(g*=B4,k=e.slice(o,h-1).match(Zk),k&&o>0&&(g*=Math.pow(Wp,k.length))):(g*=F4,o>0&&(g*=Math.pow(Wp,h-o))),e.charAt(h)!==r.charAt(s)&&(g*=U4)),(g<Zp&&a.charAt(h-1)===l.charAt(s+1)||l.charAt(s+1)===l.charAt(s)&&a.charAt(h-1)!==l.charAt(s))&&(b=Fh(e,r,a,l,h+1,s+2,c),b*Zp>g&&(g=b*Zp)),g>y&&(y=g),h=a.indexOf(p,h+1);return c[d]=y,y}function r0(e){return e.toLowerCase().replace(Zk," ")}function G4(e,r,a){return e=a&&a.length>0?`${e+" "+a.join(" ")}`:e,Fh(e,r,r0(e),r0(r),0,0,{})}var Ro='[cmdk-group=""]',Jp='[cmdk-group-items=""]',Y4='[cmdk-group-heading=""]',Wk='[cmdk-item=""]',a0=`${Wk}:not([aria-disabled="true"])`,Uh="cmdk-item-select",ui="data-value",X4=(e,r,a)=>G4(e,r,a),Jk=v.createContext(void 0),Ss=()=>v.useContext(Jk),eE=v.createContext(void 0),Hm=()=>v.useContext(eE),tE=v.createContext(void 0),nE=v.forwardRef((e,r)=>{let a=ci(()=>{var L,_;return{search:"",value:(_=(L=e.value)!=null?L:e.defaultValue)!=null?_:"",selectedItemId:void 0,filtered:{count:0,items:new Map,groups:new Set}}}),l=ci(()=>new Set),o=ci(()=>new Map),s=ci(()=>new Map),c=ci(()=>new Set),d=rE(e),{label:p,children:h,value:y,onValueChange:g,filter:b,shouldFilter:w,loop:k,disablePointerSelection:S=!1,vimBindings:C=!0,...A}=e,N=Mt(),j=Mt(),O=Mt(),D=v.useRef(null),M=lz();ml(()=>{if(y!==void 0){let L=y.trim();a.current.value=L,U.emit()}},[y]),ml(()=>{M(6,ue)},[]);let U=v.useMemo(()=>({subscribe:L=>(c.current.add(L),()=>c.current.delete(L)),snapshot:()=>a.current,setState:(L,_,re)=>{var ne,ie,le,be;if(!Object.is(a.current[L],_)){if(a.current[L]=_,L==="search")V(),I(),M(1,Y);else if(L==="value"){if(document.activeElement.hasAttribute("cmdk-input")||document.activeElement.hasAttribute("cmdk-root")){let he=document.getElementById(O);he?he.focus():(ne=document.getElementById(N))==null||ne.focus()}if(M(7,()=>{var he;a.current.selectedItemId=(he=W())==null?void 0:he.id,U.emit()}),re||M(5,ue),((ie=d.current)==null?void 0:ie.value)!==void 0){let he=_!=null?_:"";(be=(le=d.current).onValueChange)==null||be.call(le,he);return}}U.emit()}},emit:()=>{c.current.forEach(L=>L())}}),[]),F=v.useMemo(()=>({value:(L,_,re)=>{var ne;_!==((ne=s.current.get(L))==null?void 0:ne.value)&&(s.current.set(L,{value:_,keywords:re}),a.current.filtered.items.set(L,Q(_,re)),M(2,()=>{I(),U.emit()}))},item:(L,_)=>(l.current.add(L),_&&(o.current.has(_)?o.current.get(_).add(L):o.current.set(_,new Set([L]))),M(3,()=>{V(),I(),a.current.value||Y(),U.emit()}),()=>{s.current.delete(L),l.current.delete(L),a.current.filtered.items.delete(L);let re=W();M(4,()=>{V(),(re==null?void 0:re.getAttribute("id"))===L&&Y(),U.emit()})}),group:L=>(o.current.has(L)||o.current.set(L,new Set),()=>{s.current.delete(L),o.current.delete(L)}),filter:()=>d.current.shouldFilter,label:p||e["aria-label"],getDisablePointerSelection:()=>d.current.disablePointerSelection,listId:N,inputId:O,labelId:j,listInnerRef:D}),[]);function Q(L,_){var re,ne;let ie=(ne=(re=d.current)==null?void 0:re.filter)!=null?ne:X4;return L?ie(L,a.current.search,_):0}function I(){if(!a.current.search||d.current.shouldFilter===!1)return;let L=a.current.filtered.items,_=[];a.current.filtered.groups.forEach(ne=>{let ie=o.current.get(ne),le=0;ie.forEach(be=>{let he=L.get(be);le=Math.max(he,le)}),_.push([ne,le])});let re=D.current;J().sort((ne,ie)=>{var le,be;let he=ne.getAttribute("id"),Ne=ie.getAttribute("id");return((le=L.get(Ne))!=null?le:0)-((be=L.get(he))!=null?be:0)}).forEach(ne=>{let ie=ne.closest(Jp);ie?ie.appendChild(ne.parentElement===ie?ne:ne.closest(`${Jp} > *`)):re.appendChild(ne.parentElement===re?ne:ne.closest(`${Jp} > *`))}),_.sort((ne,ie)=>ie[1]-ne[1]).forEach(ne=>{var ie;let le=(ie=D.current)==null?void 0:ie.querySelector(`${Ro}[${ui}="${encodeURIComponent(ne[0])}"]`);le==null||le.parentElement.appendChild(le)})}function Y(){let L=J().find(re=>re.getAttribute("aria-disabled")!=="true"),_=L==null?void 0:L.getAttribute(ui);U.setState("value",_||void 0)}function V(){var L,_,re,ne;if(!a.current.search||d.current.shouldFilter===!1){a.current.filtered.count=l.current.size;return}a.current.filtered.groups=new Set;let ie=0;for(let le of l.current){let be=(_=(L=s.current.get(le))==null?void 0:L.value)!=null?_:"",he=(ne=(re=s.current.get(le))==null?void 0:re.keywords)!=null?ne:[],Ne=Q(be,he);a.current.filtered.items.set(le,Ne),Ne>0&&ie++}for(let[le,be]of o.current)for(let he of be)if(a.current.filtered.items.get(he)>0){a.current.filtered.groups.add(le);break}a.current.filtered.count=ie}function ue(){var L,_,re;let ne=W();ne&&(((L=ne.parentElement)==null?void 0:L.firstChild)===ne&&((re=(_=ne.closest(Ro))==null?void 0:_.querySelector(Y4))==null||re.scrollIntoView({block:"nearest"})),ne.scrollIntoView({block:"nearest"}))}function W(){var L;return(L=D.current)==null?void 0:L.querySelector(`${Wk}[aria-selected="true"]`)}function J(){var L;return Array.from(((L=D.current)==null?void 0:L.querySelectorAll(a0))||[])}function B(L){let _=J()[L];_&&U.setState("value",_.getAttribute(ui))}function G(L){var _;let re=W(),ne=J(),ie=ne.findIndex(be=>be===re),le=ne[ie+L];(_=d.current)!=null&&_.loop&&(le=ie+L<0?ne[ne.length-1]:ie+L===ne.length?ne[0]:ne[ie+L]),le&&U.setState("value",le.getAttribute(ui))}function te(L){let _=W(),re=_==null?void 0:_.closest(Ro),ne;for(;re&&!ne;)re=L>0?rz(re,Ro):az(re,Ro),ne=re==null?void 0:re.querySelector(a0);ne?U.setState("value",ne.getAttribute(ui)):G(L)}let ce=()=>B(J().length-1),R=L=>{L.preventDefault(),L.metaKey?ce():L.altKey?te(1):G(1)},z=L=>{L.preventDefault(),L.metaKey?B(0):L.altKey?te(-1):G(-1)};return v.createElement(Ce.div,{ref:r,tabIndex:-1,...A,"cmdk-root":"",onKeyDown:L=>{var _;(_=A.onKeyDown)==null||_.call(A,L);let re=L.nativeEvent.isComposing||L.keyCode===229;if(!(L.defaultPrevented||re))switch(L.key){case"n":case"j":{C&&L.ctrlKey&&R(L);break}case"ArrowDown":{R(L);break}case"p":case"k":{C&&L.ctrlKey&&z(L);break}case"ArrowUp":{z(L);break}case"Home":{L.preventDefault(),B(0);break}case"End":{L.preventDefault(),ce();break}case"Enter":{L.preventDefault();let ne=W();if(ne){let ie=new Event(Uh);ne.dispatchEvent(ie)}}}}},v.createElement("label",{"cmdk-label":"",htmlFor:F.inputId,id:F.labelId,style:oz},p),od(e,L=>v.createElement(eE.Provider,{value:U},v.createElement(Jk.Provider,{value:F},L))))}),K4=v.forwardRef((e,r)=>{var a,l;let o=Mt(),s=v.useRef(null),c=v.useContext(tE),d=Ss(),p=rE(e),h=(l=(a=p.current)==null?void 0:a.forceMount)!=null?l:c==null?void 0:c.forceMount;ml(()=>{if(!h)return d.item(o,c==null?void 0:c.id)},[h]);let y=aE(o,s,[e.value,e.children,s],e.keywords),g=Hm(),b=_a(M=>M.value&&M.value===y.current),w=_a(M=>h||d.filter()===!1?!0:M.search?M.filtered.items.get(o)>0:!0);v.useEffect(()=>{let M=s.current;if(!(!M||e.disabled))return M.addEventListener(Uh,k),()=>M.removeEventListener(Uh,k)},[w,e.onSelect,e.disabled]);function k(){var M,U;S(),(U=(M=p.current).onSelect)==null||U.call(M,y.current)}function S(){g.setState("value",y.current,!0)}if(!w)return null;let{disabled:C,value:A,onSelect:N,forceMount:j,keywords:O,...D}=e;return v.createElement(Ce.div,{ref:$r(s,r),...D,id:o,"cmdk-item":"",role:"option","aria-disabled":!!C,"aria-selected":!!b,"data-disabled":!!C,"data-selected":!!b,onPointerMove:C||d.getDisablePointerSelection()?void 0:S,onClick:C?void 0:k},e.children)}),Q4=v.forwardRef((e,r)=>{let{heading:a,children:l,forceMount:o,...s}=e,c=Mt(),d=v.useRef(null),p=v.useRef(null),h=Mt(),y=Ss(),g=_a(w=>o||y.filter()===!1?!0:w.search?w.filtered.groups.has(c):!0);ml(()=>y.group(c),[]),aE(c,d,[e.value,e.heading,p]);let b=v.useMemo(()=>({id:c,forceMount:o}),[o]);return v.createElement(Ce.div,{ref:$r(d,r),...s,"cmdk-group":"",role:"presentation",hidden:g?void 0:!0},a&&v.createElement("div",{ref:p,"cmdk-group-heading":"","aria-hidden":!0,id:h},a),od(e,w=>v.createElement("div",{"cmdk-group-items":"",role:"group","aria-labelledby":a?h:void 0},v.createElement(tE.Provider,{value:b},w))))}),Z4=v.forwardRef((e,r)=>{let{alwaysRender:a,...l}=e,o=v.useRef(null),s=_a(c=>!c.search);return!a&&!s?null:v.createElement(Ce.div,{ref:$r(o,r),...l,"cmdk-separator":"",role:"separator"})}),W4=v.forwardRef((e,r)=>{let{onValueChange:a,...l}=e,o=e.value!=null,s=Hm(),c=_a(h=>h.search),d=_a(h=>h.selectedItemId),p=Ss();return v.useEffect(()=>{e.value!=null&&s.setState("search",e.value)},[e.value]),v.createElement(Ce.input,{ref:r,...l,"cmdk-input":"",autoComplete:"off",autoCorrect:"off",spellCheck:!1,"aria-autocomplete":"list",role:"combobox","aria-expanded":!0,"aria-controls":p.listId,"aria-labelledby":p.labelId,"aria-activedescendant":d,id:p.inputId,type:"text",value:o?e.value:c,onChange:h=>{o||s.setState("search",h.target.value),a==null||a(h.target.value)}})}),J4=v.forwardRef((e,r)=>{let{children:a,label:l="Suggestions",...o}=e,s=v.useRef(null),c=v.useRef(null),d=_a(h=>h.selectedItemId),p=Ss();return v.useEffect(()=>{if(c.current&&s.current){let h=c.current,y=s.current,g,b=new ResizeObserver(()=>{g=requestAnimationFrame(()=>{let w=h.offsetHeight;y.style.setProperty("--cmdk-list-height",w.toFixed(1)+"px")})});return b.observe(h),()=>{cancelAnimationFrame(g),b.unobserve(h)}}},[]),v.createElement(Ce.div,{ref:$r(s,r),...o,"cmdk-list":"",role:"listbox",tabIndex:-1,"aria-activedescendant":d,"aria-label":l,id:p.listId},od(e,h=>v.createElement("div",{ref:$r(c,p.listInnerRef),"cmdk-list-sizer":""},h)))}),ez=v.forwardRef((e,r)=>{let{open:a,onOpenChange:l,overlayClassName:o,contentClassName:s,container:c,...d}=e;return v.createElement(um,{open:a,onOpenChange:l},v.createElement(cm,{container:c},v.createElement(dm,{"cmdk-overlay":"",className:o}),v.createElement(fm,{"aria-label":e.label,"cmdk-dialog":"",className:s},v.createElement(nE,{ref:r,...d}))))}),tz=v.forwardRef((e,r)=>_a(a=>a.filtered.count===0)?v.createElement(Ce.div,{ref:r,...e,"cmdk-empty":"",role:"presentation"}):null),nz=v.forwardRef((e,r)=>{let{progress:a,children:l,label:o="Loading...",...s}=e;return v.createElement(Ce.div,{ref:r,...s,"cmdk-loading":"",role:"progressbar","aria-valuenow":a,"aria-valuemin":0,"aria-valuemax":100,"aria-label":o},od(e,c=>v.createElement("div",{"aria-hidden":!0},c)))}),vl=Object.assign(nE,{List:J4,Item:K4,Input:W4,Group:Q4,Separator:Z4,Dialog:ez,Empty:tz,Loading:nz});function rz(e,r){let a=e.nextElementSibling;for(;a;){if(a.matches(r))return a;a=a.nextElementSibling}}function az(e,r){let a=e.previousElementSibling;for(;a;){if(a.matches(r))return a;a=a.previousElementSibling}}function rE(e){let r=v.useRef(e);return ml(()=>{r.current=e}),r}var ml=typeof window>"u"?v.useEffect:v.useLayoutEffect;function ci(e){let r=v.useRef();return r.current===void 0&&(r.current=e()),r}function _a(e){let r=Hm(),a=()=>e(r.snapshot());return v.useSyncExternalStore(r.subscribe,a,a)}function aE(e,r,a,l=[]){let o=v.useRef(),s=Ss();return ml(()=>{var c;let d=(()=>{var h;for(let y of a){if(typeof y=="string")return y.trim();if(typeof y=="object"&&"current"in y)return y.current?(h=y.current.textContent)==null?void 0:h.trim():o.current}})(),p=l.map(h=>h.trim());s.value(e,d,p),(c=r.current)==null||c.setAttribute(ui,d),o.current=d}),o}var lz=()=>{let[e,r]=v.useState(),a=ci(()=>new Map);return ml(()=>{a.current.forEach(l=>l()),a.current=new Map},[e]),(l,o)=>{a.current.set(l,o),r({})}};function iz(e){let r=e.type;return typeof r=="function"?r(e.props):"render"in r?r.render(e.props):e}function od({asChild:e,children:r},a){return e&&v.isValidElement(r)?v.cloneElement(iz(r),{ref:r.ref},a(r.props.children)):a(r)}var oz={position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"};function sz({className:e,...r}){return f.jsx("textarea",{"data-slot":"textarea",className:ye("flex field-sizing-content min-h-16 w-full rounded-lg border border-input bg-transparent px-2.5 py-2 text-base transition-colors outline-none placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40",e),...r})}function uz({className:e,...r}){return f.jsx("div",{"data-slot":"input-group",role:"group",className:ye("group/input-group relative flex h-8 w-full min-w-0 items-center rounded-lg border border-input transition-colors outline-none in-data-[slot=combobox-content]:focus-within:border-inherit in-data-[slot=combobox-content]:focus-within:ring-0 has-disabled:bg-input/50 has-disabled:opacity-50 has-[[data-slot=input-group-control]:focus-visible]:border-ring has-[[data-slot=input-group-control]:focus-visible]:ring-3 has-[[data-slot=input-group-control]:focus-visible]:ring-ring/50 has-[[data-slot][aria-invalid=true]]:border-destructive has-[[data-slot][aria-invalid=true]]:ring-3 has-[[data-slot][aria-invalid=true]]:ring-destructive/20 has-[>[data-align=block-end]]:h-auto has-[>[data-align=block-end]]:flex-col has-[>[data-align=block-start]]:h-auto has-[>[data-align=block-start]]:flex-col has-[>textarea]:h-auto dark:bg-input/30 dark:has-disabled:bg-input/80 dark:has-[[data-slot][aria-invalid=true]]:ring-destructive/40 has-[>[data-align=block-end]]:[&>input]:pt-3 has-[>[data-align=block-start]]:[&>input]:pb-3 has-[>[data-align=inline-end]]:[&>input]:pr-1.5 has-[>[data-align=inline-start]]:[&>input]:pl-1.5",e),...r})}const cz=Ci("flex h-auto cursor-text items-center justify-center gap-2 py-1.5 text-sm font-medium text-muted-foreground select-none group-data-[disabled=true]/input-group:opacity-50 [&>kbd]:rounded-[calc(var(--radius)-5px)] [&>svg:not([class*='size-'])]:size-4",{variants:{align:{"inline-start":"order-first pl-2 has-[>button]:ml-[-0.3rem] has-[>kbd]:ml-[-0.15rem]","inline-end":"order-last pr-2 has-[>button]:mr-[-0.3rem] has-[>kbd]:mr-[-0.15rem]","block-start":"order-first w-full justify-start px-2.5 pt-2 group-has-[>input]/input-group:pt-2 [.border-b]:pb-2","block-end":"order-last w-full justify-start px-2.5 pb-2 group-has-[>input]/input-group:pb-2 [.border-t]:pt-2"}},defaultVariants:{align:"inline-start"}});function dz({className:e,align:r="inline-start",...a}){return f.jsx("div",{role:"group","data-slot":"input-group-addon","data-align":r,className:ye(cz({align:r}),e),onClick:l=>{var o,s;l.target.closest("button")||(s=(o=l.currentTarget.parentElement)==null?void 0:o.querySelector("input"))==null||s.focus()},...a})}function Vm({className:e,...r}){return f.jsx(vl,{"data-slot":"command",className:ye("flex size-full flex-col overflow-hidden rounded-xl! bg-popover p-1 text-popover-foreground",e),...r})}function lE({className:e,...r}){return f.jsx("div",{"data-slot":"command-input-wrapper",className:"p-1 pb-0",children:f.jsxs(uz,{className:"h-8! rounded-lg! border-input/30 bg-input/30 shadow-none! *:data-[slot=input-group-addon]:pl-2!",children:[f.jsx(vl.Input,{"data-slot":"command-input",className:ye("w-full text-sm outline-hidden disabled:cursor-not-allowed disabled:opacity-50",e),...r}),f.jsx(dz,{children:f.jsx(tm,{className:"size-4 shrink-0 opacity-50"})})]})})}function $m({className:e,...r}){return f.jsx(vl.List,{"data-slot":"command-list",className:ye("no-scrollbar max-h-72 scroll-py-1 overflow-x-hidden overflow-y-auto outline-none",e),...r})}function qm({className:e,...r}){return f.jsx(vl.Empty,{"data-slot":"command-empty",className:ye("py-6 text-center text-sm",e),...r})}function Yo({className:e,...r}){return f.jsx(vl.Group,{"data-slot":"command-group",className:ye("overflow-hidden p-1 text-foreground **:[[cmdk-group-heading]]:px-2 **:[[cmdk-group-heading]]:py-1.5 **:[[cmdk-group-heading]]:text-xs **:[[cmdk-group-heading]]:font-medium **:[[cmdk-group-heading]]:text-muted-foreground",e),...r})}function iE({className:e,...r}){return f.jsx(vl.Separator,{"data-slot":"command-separator",className:ye("-mx-1 h-px bg-border",e),...r})}function gi({className:e,children:r,...a}){return f.jsxs(vl.Item,{"data-slot":"command-item",className:ye("group/command-item relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none in-data-[slot=dialog-content]:rounded-lg! data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50 data-selected:bg-muted data-selected:text-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 data-selected:*:[svg]:text-foreground",e),...a,children:[r,f.jsx(Vr,{className:"ml-auto opacity-0 group-has-data-[slot=command-shortcut]/command-item:hidden group-data-[checked=true]/command-item:opacity-100"})]})}function sd({...e}){return f.jsx(aO,{"data-slot":"popover",...e})}function Gm({...e}){return f.jsx(iO,{"data-slot":"popover-trigger",...e})}function ud({className:e,align:r="center",sideOffset:a=4,...l}){return f.jsx(oO,{children:f.jsx(sO,{"data-slot":"popover-content",align:r,sideOffset:a,className:ye("z-50 flex w-72 origin-(--radix-popover-content-transform-origin) flex-col gap-2.5 rounded-lg bg-popover p-2.5 text-sm text-popover-foreground shadow-md ring-1 ring-foreground/10 outline-hidden duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",e),...l})})}function fz({...e}){return f.jsx(lO,{"data-slot":"popover-anchor",...e})}function pz({workspaces:e,activeWorkspace:r,onSelectWorkspace:a,onCreateVirtualWorkspace:l,onCreatePhysicalWorkspace:o,isWorkspaceFavorited:s,onToggleFavorite:c}){const[d,p]=v.useState(!1),[h,y]=v.useState(!1);return f.jsxs(f.Fragment,{children:[f.jsxs(sd,{open:d,onOpenChange:p,children:[f.jsx(Gm,{asChild:!0,children:f.jsxs(Me,{variant:"outline",role:"combobox","aria-expanded":d,"aria-label":"Select workspace",className:"w-full justify-between h-9",children:[f.jsxs("div",{className:"flex items-center gap-2 overflow-hidden",children:[r!=null&&r.isVirtual?f.jsx(hv,{className:"size-4 flex-shrink-0 text-muted-foreground"}):f.jsx(sl,{className:"size-4 flex-shrink-0 text-muted-foreground"}),f.jsx("span",{className:"truncate",children:(r==null?void 0:r.name)||"Select workspace"})]}),f.jsx(g1,{className:"ml-auto size-4 shrink-0 opacity-50"})]})}),f.jsx(ud,{className:"w-[240px] p-0 max-h-[80vh]",children:f.jsxs(Vm,{children:[f.jsx(lE,{placeholder:"Search workspace..."}),f.jsxs($m,{className:"max-h-[50vh] overflow-y-auto",children:[f.jsx(qm,{children:"No workspace found."}),f.jsx(Yo,{heading:"Workspaces",children:e.map(g=>f.jsxs(gi,{onSelect:()=>{a(g),p(!1)},className:"justify-between",children:[f.jsxs("div",{className:"flex items-center gap-2",children:[g.isVirtual?f.jsx(hv,{className:"size-4 text-muted-foreground"}):f.jsx(sl,{className:"size-4 text-muted-foreground"}),f.jsx("span",{children:g.name})]}),f.jsxs("div",{className:"flex items-center gap-1",children:[f.jsx("button",{className:"p-1 rounded hover:bg-secondary transition-colors",onClick:b=>{b.stopPropagation(),c(g.id,g.name)},title:s(g.id)?"Remove from favorites":"Add to favorites",children:s(g.id)?f.jsx(gv,{className:"size-4 fill-primary text-primary"}):f.jsx(gv,{className:"size-4 text-muted-foreground"})}),f.jsx(Vr,{className:ye("size-4",(r==null?void 0:r.id)===g.id?"opacity-100":"opacity-0")})]})]},g.id))}),f.jsx(iE,{}),f.jsxs(Yo,{children:[f.jsxs(gi,{onSelect:()=>{l(),p(!1)},children:[f.jsx(Oc,{className:"size-4","data-icon":"inline-start"}),"Create virtual workspace"]}),f.jsxs(gi,{onSelect:()=>{p(!1),y(!0)},children:[f.jsx(sl,{className:"size-4","data-icon":"inline-start"}),"Add existing folder"]})]})]})]})})]}),f.jsx(I4,{open:h,onOpenChange:y,onSelect:g=>{o(g),y(!1)},title:"Select Workspace Folder"})]})}function hz({onOpenAddServer:e,onServerSwitch:r}){const[a,l]=v.useState(!1),{servers:o,activeServer:s,switchServer:c}=Ei();return f.jsxs(sd,{open:a,onOpenChange:l,children:[f.jsx(Gm,{asChild:!0,children:f.jsxs(Me,{variant:"outline",role:"combobox","aria-expanded":a,"aria-label":"Select server",className:"w-full justify-between h-9",children:[f.jsxs("div",{className:"flex items-center gap-2 overflow-hidden",children:[f.jsx(ul,{className:"size-4 flex-shrink-0 text-muted-foreground"}),f.jsx("span",{className:"truncate",children:(s==null?void 0:s.name)||"Select server"})]}),f.jsx(g1,{className:"ml-auto size-4 shrink-0 opacity-50"})]})}),f.jsx(ud,{className:"w-[240px] p-0 max-h-[80vh]",children:f.jsxs(Vm,{children:[f.jsx(lE,{placeholder:"Search server..."}),f.jsxs($m,{className:"max-h-[50vh] overflow-y-auto",children:[f.jsx(qm,{children:"No server found."}),f.jsx(Yo,{heading:"Servers",children:o.map(d=>f.jsxs(gi,{onSelect:()=>{c(d.id),r==null||r(),l(!1)},className:"justify-between",children:[f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsx(ul,{className:"size-4 text-muted-foreground"}),f.jsx("span",{children:d.name})]}),f.jsx(Vr,{className:ye("size-4",(s==null?void 0:s.id)===d.id?"opacity-100":"opacity-0")})]},d.id))}),f.jsx(iE,{}),f.jsx(Yo,{children:f.jsxs(gi,{onSelect:()=>{e(),l(!1)},children:[f.jsx(Oc,{className:"size-4","data-icon":"inline-start"}),"Add Server..."]})})]})]})})]})}const eh=640;function cd(){const[e,r]=v.useState(void 0);return v.useEffect(()=>{const a=window.matchMedia(`(max-width: ${eh-1}px)`),l=()=>{r(window.innerWidth<eh)};return a.addEventListener("change",l),r(window.innerWidth<eh),()=>a.removeEventListener("change",l)},[]),!!e}function ic({className:e,orientation:r="horizontal",decorative:a=!0,...l}){return f.jsx(mD,{"data-slot":"separator",decorative:a,orientation:r,className:ye("shrink-0 bg-border data-horizontal:h-px data-horizontal:w-full data-vertical:w-px data-vertical:self-stretch",e),...l})}function Ym({...e}){return f.jsx(um,{"data-slot":"sheet",...e})}function mz({...e}){return f.jsx(a_,{"data-slot":"sheet-trigger",...e})}function gz({...e}){return f.jsx(cm,{"data-slot":"sheet-portal",...e})}function yz({className:e,...r}){return f.jsx(dm,{"data-slot":"sheet-overlay",className:ye("fixed inset-0 z-50 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",e),...r})}function Xm({className:e,children:r,side:a="right",showCloseButton:l=!0,...o}){return f.jsxs(gz,{children:[f.jsx(yz,{}),f.jsxs(fm,{"data-slot":"sheet-content","data-side":a,className:ye("fixed z-50 flex flex-col gap-4 bg-background bg-clip-padding text-sm shadow-lg transition duration-200 ease-in-out data-[side=bottom]:inset-x-0 data-[side=bottom]:bottom-0 data-[side=bottom]:h-auto data-[side=bottom]:border-t data-[side=left]:inset-y-0 data-[side=left]:left-0 data-[side=left]:h-full data-[side=left]:w-3/4 data-[side=left]:border-r data-[side=right]:inset-y-0 data-[side=right]:right-0 data-[side=right]:h-full data-[side=right]:w-3/4 data-[side=right]:border-l data-[side=top]:inset-x-0 data-[side=top]:top-0 data-[side=top]:h-auto data-[side=top]:border-b data-[side=left]:sm:max-w-sm data-[side=right]:sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-[side=bottom]:data-open:slide-in-from-bottom-10 data-[side=left]:data-open:slide-in-from-left-10 data-[side=right]:data-open:slide-in-from-right-10 data-[side=top]:data-open:slide-in-from-top-10 data-closed:animate-out data-closed:fade-out-0 data-[side=bottom]:data-closed:slide-out-to-bottom-10 data-[side=left]:data-closed:slide-out-to-left-10 data-[side=right]:data-closed:slide-out-to-right-10 data-[side=top]:data-closed:slide-out-to-top-10",e),style:a==="left"||a==="right"?{top:"env(safe-area-inset-top, 0)",bottom:"env(safe-area-inset-bottom, 0)"}:void 0,...o,children:[r,l&&f.jsx(pm,{"data-slot":"sheet-close",asChild:!0,children:f.jsxs(Me,{variant:"ghost",className:"absolute top-3 right-3",size:"icon-sm",children:[f.jsx(xi,{}),f.jsx("span",{className:"sr-only",children:"Close"})]})})]})]})}function Km({className:e,...r}){return f.jsx("div",{"data-slot":"sheet-header",className:ye("flex flex-col gap-0.5 p-4",e),...r})}function Qm({className:e,...r}){return f.jsx(ow,{"data-slot":"sheet-title",className:ye("text-base font-medium text-foreground",e),...r})}function xz({className:e,...r}){return f.jsx(sw,{"data-slot":"sheet-description",className:ye("text-sm text-muted-foreground",e),...r})}function Ec({delayDuration:e=0,...r}){return f.jsx(ID,{"data-slot":"tooltip-provider",delayDuration:e,...r})}function Xo({...e}){return f.jsx(BD,{"data-slot":"tooltip",...e})}function Ko({...e}){return f.jsx(PD,{"data-slot":"tooltip-trigger",...e})}function Qo({className:e,sideOffset:r=0,children:a,...l}){return f.jsx(FD,{children:f.jsxs(UD,{"data-slot":"tooltip-content",sideOffset:r,className:ye("z-50 inline-flex w-fit max-w-xs origin-(--radix-tooltip-content-transform-origin) items-center gap-1.5 rounded-md bg-foreground px-3 py-1.5 text-xs text-background has-data-[slot=kbd]:pr-1.5 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 **:data-[slot=kbd]:relative **:data-[slot=kbd]:isolate **:data-[slot=kbd]:z-50 **:data-[slot=kbd]:rounded-sm data-[state=delayed-open]:animate-in data-[state=delayed-open]:fade-in-0 data-[state=delayed-open]:zoom-in-95 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",e),...l,children:[a,f.jsx(HD,{className:"z-50 size-2.5 translate-y-[calc(-50%_-_2px)] rotate-45 rounded-[2px] bg-foreground fill-foreground"})]})})}const bz="sidebar_state",vz=3600*24*7,wz="16rem",Sz="18rem",kz="3rem",Ez="b",oE=v.createContext(null);function Zm(){const e=v.useContext(oE);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}function Cz({defaultOpen:e=!0,open:r,onOpenChange:a,className:l,style:o,children:s,...c}){const d=cd(),[p,h]=v.useState(!1),[y,g]=v.useState(e),b=r!=null?r:y,w=v.useCallback(A=>{const N=typeof A=="function"?A(b):A;a?a(N):g(N),document.cookie=`${bz}=${N}; path=/; max-age=${vz}`},[a,b]),k=v.useCallback(()=>d?h(A=>!A):w(A=>!A),[d,w,h]);v.useEffect(()=>{const A=N=>{N.key===Ez&&(N.metaKey||N.ctrlKey)&&(N.preventDefault(),k())};return window.addEventListener("keydown",A),()=>window.removeEventListener("keydown",A)},[k]);const S=b?"expanded":"collapsed",C=v.useMemo(()=>({state:S,open:b,setOpen:w,isMobile:d,openMobile:p,setOpenMobile:h,toggleSidebar:k}),[S,b,w,d,p,h,k]);return f.jsx(oE.Provider,{value:C,children:f.jsx("div",{"data-slot":"sidebar-wrapper",style:{"--sidebar-width":wz,"--sidebar-width-icon":kz,...o},className:ye("overflow-hidden group/sidebar-wrapper flex h-full w-full has-data-[variant=inset]:bg-sidebar",l),...c,children:s})})}function Az({side:e="left",variant:r="sidebar",collapsible:a="offcanvas",className:l,children:o,dir:s,...c}){const{isMobile:d,state:p,openMobile:h,setOpenMobile:y}=Zm();return a==="none"?f.jsx("div",{"data-slot":"sidebar",className:ye("flex h-full w-(--sidebar-width) flex-col bg-sidebar text-sidebar-foreground",l),...c,children:o}):d?f.jsx(Ym,{open:h,onOpenChange:y,...c,children:f.jsxs(Xm,{dir:s,"data-sidebar":"sidebar","data-slot":"sidebar","data-mobile":"true",className:"w-(--sidebar-width) bg-sidebar p-0 text-sidebar-foreground [&>button]:hidden",style:{"--sidebar-width":Sz},side:e,children:[f.jsxs(Km,{className:"sr-only",children:[f.jsx(Qm,{children:"Sidebar"}),f.jsx(xz,{children:"Displays the mobile sidebar."})]}),f.jsx("div",{className:"flex h-full w-full flex-col",style:{paddingTop:"env(safe-area-inset-top, 0)"},children:o})]})}):f.jsxs("div",{className:"group peer hidden text-sidebar-foreground md:block","data-state":p,"data-collapsible":p==="collapsed"?a:"","data-variant":r,"data-side":e,"data-slot":"sidebar",children:[f.jsx("div",{"data-slot":"sidebar-gap",className:ye("relative w-(--sidebar-width) bg-transparent transition-[width] duration-200 ease-linear","group-data-[collapsible=offcanvas]:w-0","group-data-[side=right]:rotate-180",r==="floating"||r==="inset"?"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4)))]":"group-data-[collapsible=icon]:w-(--sidebar-width-icon)")}),f.jsx("div",{"data-slot":"sidebar-container","data-side":e,className:ye("fixed z-10 hidden w-(--sidebar-width) transition-[left,right,width] duration-200 ease-linear data-[side=left]:left-0 data-[side=left]:group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)] data-[side=right]:right-0 data-[side=right]:group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)] md:flex",r==="floating"||r==="inset"?"p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4))+2px)]":"group-data-[collapsible=icon]:w-(--sidebar-width-icon) group-data-[side=left]:border-r group-data-[side=right]:border-l",l),style:{top:"env(safe-area-inset-top, 0)",bottom:"env(safe-area-inset-bottom, 0)",height:"calc(100vh - env(safe-area-inset-top, 0) - env(safe-area-inset-bottom, 0))"},...c,children:f.jsx("div",{"data-sidebar":"sidebar","data-slot":"sidebar-inner",className:"flex size-full flex-col bg-sidebar group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:shadow-sm group-data-[variant=floating]:ring-1 group-data-[variant=floating]:ring-sidebar-border",children:o})})]})}function l0({className:e,onClick:r,...a}){const{toggleSidebar:l}=Zm();return f.jsxs(Me,{"data-sidebar":"trigger","data-slot":"sidebar-trigger",variant:"ghost",size:"icon-sm",className:ye(e),onClick:o=>{r==null||r(o),l()},...a,children:[f.jsx(PN,{}),f.jsx("span",{className:"sr-only",children:"Toggle Sidebar"})]})}function Nz({className:e,...r}){return f.jsx("div",{"data-slot":"sidebar-header","data-sidebar":"header",className:ye("flex flex-col gap-2 p-2",e),...r})}function jz({className:e,...r}){return f.jsx("div",{"data-slot":"sidebar-footer","data-sidebar":"footer",className:ye("flex flex-col gap-2 p-2",e),...r})}function Tz({className:e,...r}){return f.jsx("div",{"data-slot":"sidebar-content","data-sidebar":"content",className:ye("no-scrollbar flex min-h-0 flex-1 flex-col gap-0 overflow-auto group-data-[collapsible=icon]:overflow-hidden",e),...r})}function i0({className:e,...r}){return f.jsx("div",{"data-slot":"sidebar-group","data-sidebar":"group",className:ye("relative flex w-full min-w-0 flex-col p-2",e),...r})}function o0({className:e,asChild:r=!1,...a}){const l=r?is:"div";return f.jsx(l,{"data-slot":"sidebar-group-label","data-sidebar":"group-label",className:ye("flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium text-sidebar-foreground/70 ring-sidebar-ring outline-hidden transition-[margin,opacity] duration-200 ease-linear group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0 focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0",e),...a})}function s0({className:e,...r}){return f.jsx("div",{"data-slot":"sidebar-group-content","data-sidebar":"group-content",className:ye("w-full text-sm",e),...r})}function Qu({className:e,...r}){return f.jsx("ul",{"data-slot":"sidebar-menu","data-sidebar":"menu",className:ye("flex w-full min-w-0 flex-col gap-0",e),...r})}function fi({className:e,...r}){return f.jsx("li",{"data-slot":"sidebar-menu-item","data-sidebar":"menu-item",className:ye("group/menu-item relative",e),...r})}const _z=Ci("peer/menu-button group/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm ring-sidebar-ring outline-hidden transition-[width,height,padding] group-has-data-[sidebar=menu-action]/menu-item:pr-8 group-data-[collapsible=icon]:size-8! group-data-[collapsible=icon]:p-2! hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-open:hover:bg-sidebar-accent data-open:hover:text-sidebar-accent-foreground data-active:bg-sidebar-accent data-active:font-medium data-active:text-sidebar-accent-foreground [&_svg]:size-4 [&_svg]:shrink-0 [&>span:last-child]:truncate",{variants:{variant:{default:"hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",outline:"bg-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"h-8 text-sm",sm:"h-7 text-xs",lg:"h-12 text-sm group-data-[collapsible=icon]:p-0!"}},defaultVariants:{variant:"default",size:"default"}});function Po({asChild:e=!1,isActive:r=!1,variant:a="default",size:l="default",tooltip:o,className:s,...c}){const d=e?is:"button",{isMobile:p,state:h}=Zm(),y=f.jsx(d,{"data-slot":"sidebar-menu-button","data-sidebar":"menu-button","data-size":l,"data-active":r,className:ye(_z({variant:a,size:l}),s),...c});return o?(typeof o=="string"&&(o={children:o}),f.jsxs(Xo,{children:[f.jsx(Ko,{asChild:!0,children:y}),f.jsx(Qo,{side:"right",align:"center",hidden:h!=="collapsed"||p,...o})]})):y}function Rz({className:e,asChild:r=!1,showOnHover:a=!1,...l}){const o=r?is:"button";return f.jsx(o,{"data-slot":"sidebar-menu-action","data-sidebar":"menu-action",className:ye("absolute top-1.5 right-1 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground ring-sidebar-ring outline-hidden transition-transform group-data-[collapsible=icon]:hidden peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[size=default]/menu-button:top-1.5 peer-data-[size=lg]/menu-button:top-2.5 peer-data-[size=sm]/menu-button:top-1 after:absolute after:-inset-2 hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 md:after:hidden [&>svg]:size-4 [&>svg]:shrink-0",a&&"group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 peer-data-active/menu-button:text-sidebar-accent-foreground aria-expanded:opacity-100 md:opacity-0",e),...l})}function Mz({className:e,...r}){return f.jsx("ul",{"data-slot":"sidebar-menu-sub","data-sidebar":"menu-sub",className:ye("ml-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-l border-sidebar-border pl-2.5 py-0.5 group-data-[collapsible=icon]:hidden",e),...r})}function Zo({...e}){return f.jsx(Gj,{"data-slot":"collapsible",...e})}function Wo({...e}){return f.jsx(M1,{"data-slot":"collapsible-trigger",...e})}function Jo({...e}){return f.jsx(O1,{"data-slot":"collapsible-content",...e})}function Oz({...e}){return f.jsx(HM,{"data-slot":"dropdown-menu",...e})}function Dz({...e}){return f.jsx(VM,{"data-slot":"dropdown-menu-trigger",...e})}function zz({className:e,align:r="start",sideOffset:a=4,...l}){return f.jsx($M,{children:f.jsx(qM,{"data-slot":"dropdown-menu-content",sideOffset:a,align:r,className:ye("z-50 max-h-(--radix-dropdown-menu-content-available-height) w-(--radix-dropdown-menu-trigger-width) min-w-32 origin-(--radix-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-lg bg-popover p-1 text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:overflow-hidden data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",e),...l})})}function th({className:e,inset:r,variant:a="default",...l}){return f.jsx(GM,{"data-slot":"dropdown-menu-item","data-inset":r,"data-variant":a,className:ye("group/dropdown-menu-item relative flex cursor-default items-center gap-1.5 rounded-md px-1.5 py-1 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-inset:pl-7 data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 data-[variant=destructive]:focus:text-destructive dark:data-[variant=destructive]:focus:bg-destructive/20 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 data-[variant=destructive]:*:[svg]:text-destructive",e),...l})}const u0=er.memo(function({isClosed:r,onReopen:a,onClose:l,onDelete:o}){return f.jsxs(Oz,{children:[f.jsx(Dz,{asChild:!0,children:f.jsxs(Rz,{showOnHover:!0,children:[f.jsx(xN,{className:"size-4"}),f.jsx("span",{className:"sr-only",children:"Session actions"})]})}),f.jsx(zz,{align:"end",children:r?f.jsxs(f.Fragment,{children:[f.jsxs(th,{onClick:a,children:[f.jsx(YN,{className:"size-4"}),"Restore"]}),f.jsxs(th,{onClick:o,className:"text-destructive focus:text-destructive",children:[f.jsx(as,{className:"size-4"}),"Delete permanently"]})]}):f.jsxs(th,{onClick:l,children:[f.jsx(xi,{className:"size-4"}),"Archive"]})})]})}),c0=er.memo(function({status:r,isStreaming:a,runningAt:l}){return a||r==="running"||!!l?f.jsx(Gn,{className:"size-3.5 animate-spin shrink-0"}):r==="error"?f.jsx(Mc,{className:"size-3.5 shrink-0"}):f.jsx(rs,{className:"size-3.5 shrink-0"})}),d0=er.memo(function e({session:r,allSessions:a,isActive:l,currentSessionId:o,streamingSessionId:s,onResumeSession:c,onCloseSession:d,onReopenSession:p,onDeleteSession:h}){const y=v.useMemo(()=>a.filter(S=>S.parentId===r.id),[a,r.id]),g=y.length>0,b=r.status==="closed",w=v.useMemo(()=>y.some(S=>S.id===o),[y,o]),k=r.id===s;return g?f.jsx(Ec,{delayDuration:300,children:f.jsx(Zo,{defaultOpen:l||w,className:"group/collapsible",children:f.jsxs(fi,{children:[f.jsxs("div",{className:"flex items-center w-full",children:[f.jsx(Wo,{asChild:!0,children:f.jsx("button",{className:"flex items-center justify-center rounded-md hover:bg-sidebar-accent hover:text-sidebar-accent-foreground shrink-0 size-7 p-1","aria-label":"Toggle child sessions",children:f.jsx(cl,{className:"size-4 transition-transform duration-200 [[data-state=open]>&]:rotate-90"})})}),f.jsx(Po,{isActive:l,onClick:()=>c(r.id),className:"flex-1 min-w-0",children:f.jsxs(Xo,{children:[f.jsx(Ko,{asChild:!0,children:f.jsxs("span",{className:"truncate flex items-center gap-2",children:[f.jsx(c0,{status:r.subagentStatus,isStreaming:k,runningAt:r.runningAt}),r.title||"Untitled"]})}),f.jsx(Qo,{side:"right",className:"max-w-xs",children:r.title||"Untitled"})]})}),f.jsx(u0,{isClosed:b,onReopen:()=>p(r.id),onClose:()=>d(r.id),onDelete:()=>h(r.id)})]}),f.jsx(Jo,{children:f.jsx(Mz,{children:y.map(S=>f.jsx(e,{session:S,allSessions:a,isActive:o===S.id,currentSessionId:o,streamingSessionId:s,onResumeSession:c,onCloseSession:d,onReopenSession:p,onDeleteSession:h},S.id))})})]})})}):f.jsx(Ec,{delayDuration:300,children:f.jsx(fi,{children:f.jsxs("div",{className:"flex items-center w-full",children:[f.jsx("div",{className:"shrink-0 size-7 p-1"}),f.jsx(Po,{isActive:l,onClick:()=>c(r.id),className:"flex-1 min-w-0",children:f.jsxs(Xo,{children:[f.jsx(Ko,{asChild:!0,children:f.jsxs("span",{className:"truncate flex items-center gap-2",children:[f.jsx(c0,{status:r.subagentStatus,isStreaming:k,runningAt:r.runningAt}),r.title||"Untitled"]})}),f.jsx(Qo,{side:"right",className:"max-w-xs",children:r.title||"Untitled"})]})}),f.jsx(u0,{isClosed:b,onReopen:()=>p(r.id),onClose:()=>d(r.id),onDelete:()=>h(r.id)})]})})})}),Lz=Ci("group/badge inline-flex h-5 w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-4xl border border-transparent px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-all focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3!",{variants:{variant:{default:"bg-primary text-primary-foreground [a]:hover:bg-primary/80",secondary:"bg-secondary text-secondary-foreground [a]:hover:bg-secondary/80",destructive:"bg-destructive/10 text-destructive focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:focus-visible:ring-destructive/40 [a]:hover:bg-destructive/20",outline:"border-border text-foreground [a]:hover:bg-muted [a]:hover:text-muted-foreground",ghost:"hover:bg-muted hover:text-muted-foreground dark:hover:bg-muted/50",link:"text-primary underline-offset-4 hover:underline"}},defaultVariants:{variant:"default"}});function Nn({className:e,variant:r="default",asChild:a=!1,...l}){const o=a?is:"span";return f.jsx(o,{"data-slot":"badge","data-variant":r,className:ye(Lz({variant:r}),e),...l})}function Iz({sessions:e,currentSession:r,currentSessionId:a,streamingSessionId:l,connected:o,workspaces:s,activeWorkspace:c,onCreateSession:d,onResumeSession:p,onCloseSession:h,onReopenSession:y,onDeleteSession:g,onSelectWorkspace:b,onCreateVirtualWorkspace:w,onCreatePhysicalWorkspace:k,onOpenSettings:S,onOpenMCP:C,onOpenAddServer:A,onServerSwitch:N}){const{quickConnections:j,addToQuickConnections:O,activeServer:D}=Ei(),{activeSessions:M,archivedSessions:U}=v.useMemo(()=>{const I=e.filter(Y=>!Y.parentId);return{activeSessions:I.filter(Y=>Y.status==="active"),archivedSessions:I.filter(Y=>Y.status==="closed")}},[e]),F=I=>j.some(Y=>Y.workspaceId===I&&Y.serverId===(D==null?void 0:D.id)),Q=(I,Y)=>{D&&O(D.id,D.name,I,Y)};return f.jsxs(Az,{collapsible:"offcanvas",children:[f.jsxs(Nz,{children:[f.jsxs("div",{className:"p-2 space-y-2",children:[f.jsx(hz,{onOpenAddServer:A,onServerSwitch:N}),f.jsx(pz,{workspaces:s,activeWorkspace:c,onSelectWorkspace:b,onCreateVirtualWorkspace:w,onCreatePhysicalWorkspace:k,isWorkspaceFavorited:F,onToggleFavorite:Q})]}),f.jsx(Qu,{children:f.jsx(fi,{children:f.jsxs(Po,{onClick:d,disabled:!o,className:"w-full",children:[f.jsx(Oc,{className:"size-4","data-icon":"inline-start"}),f.jsx("span",{children:"New Chat"})]})})})]}),f.jsxs(Tz,{children:[M.length>0&&f.jsx(Zo,{defaultOpen:!0,className:"group/collapsible",children:f.jsxs(i0,{children:[f.jsx(o0,{asChild:!0,children:f.jsxs(Wo,{className:"flex items-center justify-between w-full",children:[f.jsxs("span",{className:"flex items-center gap-2",children:[f.jsx(cl,{className:"size-3 transition-transform duration-200 group-data-[state=open]/collapsible:rotate-90"}),"Active"]}),f.jsx(Nn,{variant:"secondary",children:M.length})]})}),f.jsx(Jo,{children:f.jsx(s0,{children:f.jsx(Qu,{children:M.map(I=>f.jsx(d0,{session:I,allSessions:e,isActive:(r==null?void 0:r.id)===I.id,currentSessionId:a,streamingSessionId:l,onResumeSession:p,onCloseSession:h,onReopenSession:y,onDeleteSession:g},I.id))})})})]})}),U.length>0&&f.jsx(Zo,{defaultOpen:!0,className:"group/collapsible",children:f.jsxs(i0,{children:[f.jsx(o0,{asChild:!0,children:f.jsxs(Wo,{className:"flex items-center justify-between w-full",children:[f.jsxs("span",{className:"flex items-center gap-2",children:[f.jsx(cl,{className:"size-3 transition-transform duration-200 group-data-[state=open]/collapsible:rotate-90"}),"Archived"]}),f.jsx(Nn,{variant:"secondary",children:U.length})]})}),f.jsx(Jo,{children:f.jsx(s0,{children:f.jsx(Qu,{children:U.map(I=>f.jsx(d0,{session:I,allSessions:e,isActive:(r==null?void 0:r.id)===I.id,currentSessionId:a,streamingSessionId:l,onResumeSession:p,onCloseSession:h,onReopenSession:y,onDeleteSession:g},I.id))})})})]})}),M.length===0&&U.length===0&&f.jsxs("div",{className:"p-4 text-center text-sm text-muted-foreground",children:["No sessions yet.",f.jsx("br",{}),"Start a new chat to begin."]})]}),f.jsx(jz,{className:"pb-4",children:f.jsxs(Qu,{children:[f.jsx(fi,{children:f.jsxs("div",{className:"flex items-center gap-2 px-2 py-1.5",children:[o?f.jsx(cj,{className:"size-3.5 text-success"}):f.jsx(w1,{className:"size-3.5 text-destructive"}),f.jsx("span",{className:"text-xs text-muted-foreground",children:o?"Connected":"Disconnected"})]})}),f.jsx(fi,{children:f.jsxs(Po,{onClick:C,children:[f.jsx(ul,{className:"size-4","data-icon":"inline-start"}),f.jsx("span",{children:"MCP Servers"})]})}),f.jsx(fi,{children:f.jsx("div",{className:"flex items-center gap-1",children:f.jsxs(Po,{onClick:S,children:[f.jsx(x1,{className:"size-4","data-icon":"inline-start"}),f.jsx("span",{children:"Settings"})]})})})]})})]})}const Bz={".ts":{icon:cr,color:"text-blue-500"},".tsx":{icon:cr,color:"text-blue-500"},".js":{icon:cr,color:"text-yellow-500"},".jsx":{icon:cr,color:"text-yellow-500"},".json":{icon:cr,color:"text-yellow-600"},".md":{icon:cr,color:"text-gray-500"},".css":{icon:cr,color:"text-purple-500"},".html":{icon:cr,color:"text-orange-500"}};function sE({entry:e,workspaceId:r,parentPath:a,depth:l,onFileSelect:o,showHidden:s=!0,serverUrl:c,apiToken:d}){const{fetchWithAuth:p}=ys(),[h,y]=v.useState(!1),[g,b]=v.useState([]),[w,k]=v.useState(!1),[S,C]=v.useState(!1),A=a?`${a}/${e.path}`:e.path,N=e.type==="directory",j=async()=>{if(!(S||w)){k(!0);try{const I=await(await p(`/api/workspaces/${r}/files?path=${encodeURIComponent(A)}&showHidden=${s}`,{},{serverUrl:c,token:d})).json();b(I.files||[]),C(!0)}catch(Q){console.error("Failed to load children:",Q)}finally{k(!1)}}},O=Q=>{y(Q),Q&&N&&j()},D=()=>{!N&&o&&o({...e,path:A})},M=e.extension?Bz[e.extension]:null,U=N?h?kh:sl:(M==null?void 0:M.icon)||cr,F=N?"text-amber-500":(M==null?void 0:M.color)||"text-muted-foreground";return N?f.jsxs(Zo,{open:h,onOpenChange:O,children:[f.jsx(Wo,{asChild:!0,children:f.jsxs("button",{className:ye("flex items-center gap-1.5 w-full px-1.5 py-0.5 rounded text-sm","hover:bg-accent hover:text-accent-foreground","transition-colors text-left"),style:{paddingLeft:`${l*12+6}px`},children:[w?f.jsx(Gn,{className:"w-3 h-3 animate-spin flex-shrink-0"}):f.jsx(cl,{className:ye("w-3 h-3 flex-shrink-0 transition-transform",h&&"rotate-90")}),f.jsx(U,{className:ye("w-4 h-4 flex-shrink-0",F)}),f.jsx("span",{className:"truncate",children:e.name})]})}),f.jsx(Jo,{children:g.map(Q=>f.jsx(sE,{entry:Q,workspaceId:r,parentPath:A,depth:l+1,onFileSelect:o,showHidden:s,serverUrl:c,apiToken:d},`${A}/${Q.path}`))})]}):f.jsxs("button",{onClick:D,className:ye("flex items-center gap-1.5 w-full px-1.5 py-0.5 rounded text-sm","hover:bg-accent hover:text-accent-foreground","transition-colors text-left"),style:{paddingLeft:`${l*12+6}px`},children:[f.jsx(U,{className:ye("w-4 h-4 flex-shrink-0",F)}),f.jsx("span",{className:"truncate",children:e.name})]})}function f0({workspaceId:e,serverUrl:r,apiToken:a,onFileSelect:l,showHidden:o=!0}){const[s,c]=v.useState([]),[d,p]=v.useState(""),[h,y]=v.useState(!0),[g,b]=v.useState(null),{fetchWithAuth:w}=ys(),k=v.useCallback(async()=>{y(!0),b(null);try{const S=await w(`/api/workspaces/${e}/files?showHidden=${o}`,{},{serverUrl:r,token:a}),C=await S.json();if(!S.ok)throw new Error(C.message||"Failed to load files");c(C.files),p(C.currentPath)}catch(S){b(S instanceof Error?S.message:"Failed to load files")}finally{y(!1)}},[e,o,w,r,a]);return v.useEffect(()=>{k()},[k]),h?f.jsxs("div",{className:"flex items-center justify-center h-32 text-muted-foreground",children:[f.jsx(Gn,{className:"w-4 h-4 animate-spin mr-2"}),"Loading files..."]}):g?f.jsxs("div",{className:"p-4 text-sm text-destructive",children:[g,f.jsx(Me,{variant:"ghost",size:"sm",onClick:k,className:"ml-2",children:f.jsx(pi,{className:"w-3 h-3"})})]}):s.length===0?f.jsxs("div",{className:"p-4 text-sm text-muted-foreground",children:["Empty workspace",f.jsx(Me,{variant:"ghost",size:"sm",onClick:k,className:"ml-2",children:f.jsx(pi,{className:"w-3 h-3"})})]}):f.jsx(Ta,{className:"h-full",children:f.jsxs("div",{className:"p-2",children:[f.jsxs("div",{className:"flex items-center justify-between mb-2 px-1",children:[f.jsx("span",{className:"text-xs font-medium text-muted-foreground uppercase tracking-wide",children:"Files"}),f.jsx(Me,{variant:"ghost",size:"icon",className:"h-5 w-5",onClick:k,children:f.jsx(pi,{className:"w-3 h-3"})})]}),f.jsx("div",{className:"space-y-0.5",children:s.map(S=>f.jsx(sE,{entry:S,workspaceId:e,parentPath:d,depth:0,onFileSelect:l,showHidden:o,serverUrl:r,apiToken:a},S.path))})]})})}function Pz({workspaceId:e,searchQuery:r,selectedIndex:a,onSelect:l,onFilesChange:o,showHidden:s=!0,serverUrl:c,apiToken:d}){const[p,h]=v.useState([]),[y,g]=v.useState(!1),[b,w]=v.useState(r),{fetchWithAuth:k}=ys();return v.useEffect(()=>{const S=setTimeout(()=>{w(r)},150);return()=>clearTimeout(S)},[r]),v.useEffect(()=>{if(!b||b.length<2){h([]),o([]);return}g(!0);const S=new AbortController;return k(`/api/workspaces/${e}/files?search=${encodeURIComponent(b)}&showHidden=${s}`,{signal:S.signal},{serverUrl:c,token:d}).then(C=>C.json()).then(C=>{const A=C.files||[];h(A),o(A)}).catch(C=>{C.name!=="AbortError"&&console.error("File search failed:",C)}).finally(()=>g(!1)),()=>S.abort()},[e,b,o,s,k,c,d]),!r||r.length<2?f.jsx("div",{className:"p-2 text-xs text-muted-foreground",children:"Type at least 2 characters to search files..."}):y?f.jsxs("div",{className:"flex items-center justify-center p-4 text-muted-foreground",children:[f.jsx(Gn,{className:"w-4 h-4 animate-spin mr-2"}),"Searching..."]}):p.length===0?f.jsxs("div",{className:"p-2 text-xs text-muted-foreground",children:['No files found matching "',r,'"']}):f.jsxs("div",{className:"p-1",children:[p.map((S,C)=>f.jsxs("button",{onClick:()=>l(S),className:ye("flex items-center gap-2 w-full px-2 py-1.5 rounded text-sm text-left","hover:bg-muted",C===a&&"bg-primary/20 text-primary font-medium ring-1 ring-primary/50"),children:[S.type==="directory"?f.jsx(sl,{className:"w-4 h-4 text-amber-500 flex-shrink-0"}):f.jsx(cr,{className:"w-4 h-4 text-muted-foreground flex-shrink-0"}),f.jsx("span",{className:"truncate flex-1",children:S.path}),S.extension&&f.jsx("span",{className:"text-xs text-muted-foreground",children:S.extension})]},S.path)),f.jsxs("div",{className:"mt-1 pt-1 border-t text-xs text-muted-foreground px-2",children:[p.length," result",p.length!==1?"s":""," •",f.jsx("kbd",{className:"ml-1 px-1 py-0.5 bg-muted rounded text-[10px]",children:"↑↓"})," navigate",f.jsx("kbd",{className:"ml-1 px-1 py-0.5 bg-muted rounded text-[10px]",children:"↵"})," select",f.jsx("kbd",{className:"ml-1 px-1 py-0.5 bg-muted rounded text-[10px]",children:"esc"})," close"]})]})}function Fz({workspaceId:e,serverUrl:r,apiToken:a,isOpen:l,onClose:o}){const s=cd();return e?s?f.jsx(Ym,{open:l,onOpenChange:c=>!c&&o(),children:f.jsxs(Xm,{side:"right",className:"w-72 p-0 bg-sidebar [&>button]:hidden",children:[f.jsx(Km,{className:"sr-only",children:f.jsx(Qm,{children:"Files"})}),f.jsxs("div",{className:"flex items-center justify-between p-3 border-b border-border",children:[f.jsx("span",{className:"font-semibold text-sm",children:"Files"}),f.jsx(Me,{variant:"ghost",size:"icon-sm",onClick:o,children:f.jsx(xi,{className:"w-4 h-4"})})]}),f.jsx("div",{className:"flex flex-1 flex-col min-h-0 overflow-hidden",style:{paddingBottom:"max(1.5rem, env(safe-area-inset-bottom, 0))"},children:f.jsx(Ta,{className:"flex-1 min-h-0 pb-8",children:f.jsx(f0,{workspaceId:e,serverUrl:r,apiToken:a,showHidden:!0})})})]})}):f.jsxs(f.Fragment,{children:[f.jsx("div",{className:ye("relative w-64 bg-transparent transition-[width] duration-200 ease-linear",!l&&"w-0")}),f.jsxs("div",{className:ye("fixed right-0 z-10 w-64 bg-sidebar border-l border-border flex flex-col overflow-hidden","transform transition-transform duration-200 ease-linear",!l&&"translate-x-full"),style:{top:"env(safe-area-inset-top, 0)",bottom:"env(safe-area-inset-bottom, 0)",height:"calc(100vh - env(safe-area-inset-top, 0) - env(safe-area-inset-bottom, 0))"},children:[f.jsxs("div",{className:"flex items-center justify-between p-3 border-b border-border",children:[f.jsx("span",{className:"font-semibold text-sm",children:"Files"}),f.jsx(Me,{variant:"ghost",size:"icon-sm",onClick:o,children:f.jsx(xi,{className:"w-4 h-4"})})]}),f.jsx("div",{className:"flex flex-1 flex-col min-h-0 overflow-hidden",style:{paddingBottom:"max(1.5rem, env(safe-area-inset-bottom, 0))"},children:f.jsx(Ta,{className:"flex-1 min-h-0",children:f.jsx(f0,{workspaceId:e,serverUrl:r,apiToken:a,showHidden:!0})})})]})]}):null}const Uz=Ci("group/alert relative grid w-full gap-0.5 rounded-lg border px-2.5 py-2 text-left text-sm has-data-[slot=alert-action]:relative has-data-[slot=alert-action]:pr-18 has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-2 *:[svg]:row-span-2 *:[svg]:translate-y-0.5 *:[svg]:text-current *:[svg:not([class*='size-'])]:size-4",{variants:{variant:{default:"bg-card text-card-foreground",destructive:"bg-card text-destructive *:data-[slot=alert-description]:text-destructive/90 *:[svg]:text-current"}},defaultVariants:{variant:"default"}});function oc({className:e,variant:r,...a}){return f.jsx("div",{"data-slot":"alert",role:"alert",className:ye(Uz({variant:r}),e),...a})}function sc({className:e,...r}){return f.jsx("div",{"data-slot":"alert-description",className:ye("text-sm text-balance text-muted-foreground md:text-pretty [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground [&_p:not(:last-child)]:mb-4",e),...r})}function Hz({className:e,value:r,...a}){return f.jsx(mO,{"data-slot":"progress",className:ye("relative flex h-1 w-full items-center overflow-x-hidden rounded-full bg-muted",e),...a,children:f.jsx(gO,{"data-slot":"progress-indicator",className:"size-full flex-1 bg-primary transition-all",style:{transform:`translateX(-${100-(r||0)}%)`}})})}function Zu(e){return e>=1e6?(e/1e6).toFixed(1)+"M":e>=1e3?(e/1e3).toFixed(1)+"k":e.toString()}function Vz(e){return e>=60?"critical":e>=40?"warning":"normal"}function $z({totalTokens:e=0,contextWindow:r=0,modelName:a="",compact:l=!1}){const o=e===0?0:r,s=o===0?0:Math.min(100,Math.round(e/o*100)),c=Vz(s);return l?f.jsxs("div",{className:"flex items-center gap-1.5",children:[f.jsxs("span",{className:"text-xs font-mono",children:[Zu(e),"/",Zu(o)]}),f.jsx(Ec,{children:f.jsxs(Xo,{children:[f.jsx(Ko,{asChild:!0,children:f.jsx(mv,{className:"size-3 text-muted-foreground cursor-help"})}),f.jsxs(Qo,{side:"bottom",children:[f.jsxs("p",{className:"text-xs",children:["Model: ",a]}),f.jsxs("p",{className:"text-xs",children:[s,"% of context window used"]})]})]})})]}):f.jsxs("div",{className:"flex items-center gap-3",children:[f.jsxs("div",{className:"flex flex-col gap-1",children:[f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsx("span",{className:"text-xs text-muted-foreground",children:"Tokens:"}),f.jsxs("span",{className:"text-xs font-mono",children:[Zu(e),"/",Zu(o)]})]}),f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsx(Hz,{value:s,className:ye("h-1 w-20",c==="critical"&&"[&>div]:bg-destructive",c==="warning"&&"[&>div]:bg-warning",c==="normal"&&"[&>div]:bg-primary")}),f.jsxs("span",{className:"text-[11px] text-muted-foreground",children:["(",s,"%)"]})]})]}),f.jsx(Ec,{children:f.jsxs(Xo,{children:[f.jsx(Ko,{asChild:!0,children:f.jsx(mv,{className:"size-3.5 text-muted-foreground cursor-help"})}),f.jsx(Qo,{side:"bottom",children:f.jsxs("p",{className:"text-xs",children:["Model: ",a]})})]})})]})}function uE({...e}){return f.jsx(WO,{"data-slot":"select",...e})}function qz({className:e,...r}){return f.jsx(lD,{"data-slot":"select-group",className:ye("scroll-my-1 p-1",e),...r})}function Cc({...e}){return f.jsx(eD,{"data-slot":"select-value",...e})}function cE({className:e,size:r="default",children:a,...l}){return f.jsxs(JO,{"data-slot":"select-trigger","data-size":r,className:ye("flex w-fit items-center justify-between gap-1.5 rounded-lg border border-input bg-transparent py-2 pr-2 pl-2.5 text-sm whitespace-nowrap transition-colors outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 data-placeholder:text-muted-foreground data-[size=default]:h-8 data-[size=sm]:h-7 data-[size=sm]:rounded-[min(var(--radius-md),10px)] *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-1.5 dark:bg-input/30 dark:hover:bg-input/50 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),...l,children:[a,f.jsx(tD,{asChild:!0,children:f.jsx(ns,{className:"pointer-events-none size-4 text-muted-foreground"})})]})}function dE({className:e,children:r,position:a="item-aligned",align:l="center",...o}){return f.jsx(nD,{children:f.jsxs(rD,{"data-slot":"select-content","data-align-trigger":a==="item-aligned",className:ye("relative z-50 max-h-(--radix-select-content-available-height) min-w-36 origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-lg bg-popover text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 data-[align-trigger=true]:animate-none data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",a==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",e),position:a,align:l,...o,children:[f.jsx(Yz,{}),f.jsx(aD,{"data-position":a,className:ye("data-[position=popper]:h-(--radix-select-trigger-height) data-[position=popper]:w-full data-[position=popper]:min-w-(--radix-select-trigger-width)",a==="popper"&&""),children:r}),f.jsx(Xz,{})]})})}function Gz({className:e,...r}){return f.jsx(iD,{"data-slot":"select-label",className:ye("px-1.5 py-1 text-xs text-muted-foreground",e),...r})}function fE({className:e,children:r,...a}){return f.jsxs(oD,{"data-slot":"select-item",className:ye("relative flex w-full cursor-default items-center gap-1.5 rounded-md py-1 pr-8 pl-1.5 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",e),...a,children:[f.jsx("span",{className:"pointer-events-none absolute right-2 flex size-4 items-center justify-center",children:f.jsx(uD,{children:f.jsx(Vr,{className:"pointer-events-none"})})}),f.jsx(sD,{children:r})]})}function Yz({className:e,...r}){return f.jsx(cD,{"data-slot":"select-scroll-up-button",className:ye("z-10 flex cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4",e),...r,children:f.jsx(iN,{})})}function Xz({className:e,...r}){return f.jsx(dD,{"data-slot":"select-scroll-down-button",className:ye("z-10 flex cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4",e),...r,children:f.jsx(ns,{})})}function Ca({className:e,...r}){return f.jsx(XM,{"data-slot":"label",className:ye("flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50",e),...r})}function Kz(e){switch(e){case"budget":return"$";case"standard":return"$$";case"premium":return"$$$";default:return""}}function Qz({models:e,selectedModelId:r,onChangeModel:a,disabled:l,iconOnly:o=!1}){const s=e.reduce((d,p)=>(d[p.providerName]||(d[p.providerName]=[]),d[p.providerName].push(p),d),{}),c=d=>{const p=e.find(h=>h.id===d);p&&a(d,p.providerId)};return f.jsxs("div",{className:"flex items-center gap-2",children:[!o&&f.jsx(Ca,{className:"text-xs text-muted-foreground",children:"Model:"}),f.jsxs(uE,{value:r||"",onValueChange:c,disabled:l,children:[f.jsx(cE,{className:o?"w-9 h-9 px-0 justify-center gap-0 [&>svg:last-child]:hidden [&_[data-slot=select-value]]:hidden":"w-[180px] h-8 text-sm",children:o?f.jsxs(f.Fragment,{children:[f.jsx(gN,{className:"size-4"}),f.jsx(Cc,{className:"sr-only"})]}):f.jsx(Cc,{placeholder:"Select model"})}),f.jsx(dE,{children:Object.entries(s).map(([d,p])=>f.jsxs(qz,{children:[f.jsx(Gz,{children:d}),p.map(h=>f.jsx(fE,{value:h.id,children:f.jsxs("span",{className:"flex items-center gap-2",children:[h.name,f.jsx("span",{className:"text-muted-foreground text-xs",children:Kz(h.tier)})]})},h.id))]},d))})]})]})}function Zz({preconfigs:e,selectedPreconfigId:r,onChangePreconfig:a,disabled:l,iconOnly:o=!1}){return f.jsxs("div",{className:"flex items-center gap-2",children:[!o&&f.jsx(Ca,{className:"text-xs text-muted-foreground",children:"Config:"}),f.jsxs(uE,{value:r||"",onValueChange:a,disabled:l,children:[f.jsx(cE,{className:o?"w-9 h-9 px-0 justify-center gap-0 [&>svg:last-child]:hidden [&_[data-slot=select-value]]:hidden":"w-[140px] h-8 text-sm",children:o?f.jsxs(f.Fragment,{children:[f.jsx(x1,{className:"size-4"}),f.jsx(Cc,{className:"sr-only"})]}):f.jsx(Cc,{placeholder:"Select config"})}),f.jsx(dE,{children:e.map(s=>f.jsxs(fE,{value:s.id,children:[s.name,s.isDefault&&f.jsx("span",{className:"ml-2 text-muted-foreground text-xs",children:"(default)"})]},s.id))})]})]})}function Wz({session:e,preconfigs:r,models:a,usage:l,modelName:o,onChangePreconfig:s,onChangeModel:c,onRename:d,onNavigateBack:p,isStreaming:h,onInterrupt:y}){var U;const[g,b]=v.useState(!1),[w,k]=v.useState(e.title||""),S=v.useRef(null),C=cd();v.useEffect(()=>{g&&S.current&&(S.current.focus(),S.current.select())},[g]);const A=()=>{k(e.title||""),b(!0)},N=()=>{const F=w.trim();F&&F!==e.title&&d(e.id,F),b(!1)},j=F=>{F.key==="Enter"?N():F.key==="Escape"&&(k(e.title||""),b(!1))},O=e.selectedModel||((U=r.find(F=>F.id===e.preconfigId))==null?void 0:U.model)||o,D=a.find(F=>F.id===O),M=D==null?void 0:D.contextWindow;return f.jsxs("header",{className:"flex flex-col border-b border-border bg-card",children:[f.jsx("div",{className:"flex items-center justify-start px-4 py-2",children:f.jsxs("div",{className:"flex items-center gap-3",children:[e.parentId&&p&&f.jsxs(Me,{variant:"ghost",size:"sm",onClick:p,className:"h-7",children:[f.jsx(QA,{className:"size-4","data-icon":"inline-start"}),"Back"]}),g?f.jsx("input",{ref:S,type:"text",value:w,onChange:F=>k(F.target.value),onBlur:N,onKeyDown:j,className:"text-lg font-semibold bg-background border border-primary rounded px-2 py-0.5 outline-none min-w-[200px]",autoFocus:!0}):f.jsx("h2",{className:"text-lg font-semibold cursor-pointer px-2 py-0.5 -mx-2 rounded hover:bg-accent transition-colors",onDoubleClick:A,children:e.title||"Untitled Session"}),f.jsx(Nn,{variant:"outline",className:"font-mono text-xs",children:e.id.slice(0,8)}),e.status==="closed"&&f.jsxs(Nn,{variant:"secondary",children:[f.jsx(XA,{className:"size-3","data-icon":"inline-start"}),"Archived"]})]})}),f.jsx(ic,{}),f.jsxs("div",{className:"inline-flex align-middle items-center gap-3 sm:gap-4 px-4 py-2 flex-wrap",children:[f.jsx($z,{promptTokens:l.promptTokens,completionTokens:l.completionTokens,totalTokens:l.totalTokens,contextWindow:M,modelName:o,compact:C}),f.jsx(ic,{orientation:"vertical",className:"hidden sm:block"}),f.jsx(Qz,{models:a,selectedModelId:O,onChangeModel:c,disabled:e.status==="closed"||!!e.parentId,iconOnly:C}),f.jsx(Zz,{preconfigs:r,selectedPreconfigId:e.preconfigId,onChangePreconfig:s,disabled:e.status==="closed"||!!e.parentId,iconOnly:C}),f.jsx(ic,{orientation:"vertical",className:"hidden sm:block"}),f.jsxs(Me,{variant:h?"destructive":"outline",size:C?"icon":"sm",onClick:y,disabled:!y,className:h?"":"opacity-60 hover:opacity-100",title:h?"Interrupt operation":"Interrupt (no active operation)",children:[f.jsx(v1,{className:"size-4"}),!C&&f.jsx("span",{className:"ml-1",children:"Stop"})]})]})]})}function Jz({message:e,textContent:r,children:a,isQueued:l=!1,onRemove:o}){const[s,c]=v.useState(!1),d=e.role==="user",p=async()=>{const h=r||"";await navigator.clipboard.writeText(h),c(!0),setTimeout(()=>c(!1),2e3)};return f.jsxs("div",{className:ye("flex flex-col gap-1 mb-4 animate-slide-up",d?"items-end":"items-start"),children:[f.jsx("div",{className:ye("flex items-center gap-1.5 text-xs uppercase tracking-wide text-muted-foreground",d?"mr-3":"ml-3"),children:d?f.jsxs(f.Fragment,{children:[!l&&f.jsx(Me,{variant:"ghost",size:"icon",onClick:p,className:"size-5 text-muted-foreground hover:text-foreground",children:s?f.jsx(Vr,{className:"size-3"}):f.jsx(cc,{className:"size-3"})}),f.jsx(oj,{className:"size-3"}),e.role]}):f.jsxs(f.Fragment,{children:[f.jsx(WA,{className:"size-3"}),e.role,f.jsx(Me,{variant:"ghost",size:"icon",onClick:p,className:"size-5 text-muted-foreground hover:text-foreground",children:s?f.jsx(Vr,{className:"size-3"}):f.jsx(cc,{className:"size-3"})})]})}),f.jsxs("div",{className:ye("rounded-2xl px-4 py-3 max-w-full sm:max-w-full relative group",l?"bg-muted border-2 border-dashed border-muted-foreground/30 opacity-80":d?"bg-primary text-primary-foreground rounded-br-md":"bg-card text-card-foreground border border-border rounded-bl-md"),children:[l&&f.jsxs("div",{className:"flex items-center justify-between gap-2 mb-2 pb-2 border-b border-muted-foreground/20",children:[f.jsxs("div",{className:"flex items-center gap-2 text-xs text-muted-foreground",children:[f.jsx(y1,{className:"size-3 animate-pulse"}),f.jsx("span",{children:"Pending"})]}),o&&f.jsx(Me,{variant:"ghost",size:"icon",onClick:o,className:"size-6 text-muted-foreground hover:text-destructive hover:bg-destructive/10",title:"Remove from queue",children:f.jsx(xi,{className:"size-3"})})]}),f.jsx("div",{className:"min-w-0",children:a})]})]})}var e3=Object.create,dd=Object.defineProperty,t3=Object.defineProperties,n3=Object.getOwnPropertyDescriptor,r3=Object.getOwnPropertyDescriptors,pE=Object.getOwnPropertyNames,Ac=Object.getOwnPropertySymbols,a3=Object.getPrototypeOf,Wm=Object.prototype.hasOwnProperty,hE=Object.prototype.propertyIsEnumerable,p0=(e,r,a)=>r in e?dd(e,r,{enumerable:!0,configurable:!0,writable:!0,value:a}):e[r]=a,mr=(e,r)=>{for(var a in r||(r={}))Wm.call(r,a)&&p0(e,a,r[a]);if(Ac)for(var a of Ac(r))hE.call(r,a)&&p0(e,a,r[a]);return e},fd=(e,r)=>t3(e,r3(r)),mE=(e,r)=>{var a={};for(var l in e)Wm.call(e,l)&&r.indexOf(l)<0&&(a[l]=e[l]);if(e!=null&&Ac)for(var l of Ac(e))r.indexOf(l)<0&&hE.call(e,l)&&(a[l]=e[l]);return a},l3=(e,r)=>function(){return r||(0,e[pE(e)[0]])((r={exports:{}}).exports,r),r.exports},i3=(e,r)=>{for(var a in r)dd(e,a,{get:r[a],enumerable:!0})},o3=(e,r,a,l)=>{if(r&&typeof r=="object"||typeof r=="function")for(let o of pE(r))!Wm.call(e,o)&&o!==a&&dd(e,o,{get:()=>r[o],enumerable:!(l=n3(r,o))||l.enumerable});return e},s3=(e,r,a)=>(a=e!=null?e3(a3(e)):{},o3(!e||!e.__esModule?dd(a,"default",{value:e,enumerable:!0}):a,e)),u3=l3({"../../node_modules/.pnpm/prismjs@1.29.0_patch_hash=vrxx3pzkik6jpmgpayxfjunetu/node_modules/prismjs/prism.js"(e,r){var a=(function(){var l=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,o=0,s={},c={util:{encode:function k(S){return S instanceof d?new d(S.type,k(S.content),S.alias):Array.isArray(S)?S.map(k):S.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/\u00a0/g," ")},type:function(k){return Object.prototype.toString.call(k).slice(8,-1)},objId:function(k){return k.__id||Object.defineProperty(k,"__id",{value:++o}),k.__id},clone:function k(S,C){C=C||{};var A,N;switch(c.util.type(S)){case"Object":if(N=c.util.objId(S),C[N])return C[N];A={},C[N]=A;for(var j in S)S.hasOwnProperty(j)&&(A[j]=k(S[j],C));return A;case"Array":return N=c.util.objId(S),C[N]?C[N]:(A=[],C[N]=A,S.forEach(function(O,D){A[D]=k(O,C)}),A);default:return S}},getLanguage:function(k){for(;k;){var S=l.exec(k.className);if(S)return S[1].toLowerCase();k=k.parentElement}return"none"},setLanguage:function(k,S){k.className=k.className.replace(RegExp(l,"gi"),""),k.classList.add("language-"+S)},isActive:function(k,S,C){for(var A="no-"+S;k;){var N=k.classList;if(N.contains(S))return!0;if(N.contains(A))return!1;k=k.parentElement}return!!C}},languages:{plain:s,plaintext:s,text:s,txt:s,extend:function(k,S){var C=c.util.clone(c.languages[k]);for(var A in S)C[A]=S[A];return C},insertBefore:function(k,S,C,A){A=A||c.languages;var N=A[k],j={};for(var O in N)if(N.hasOwnProperty(O)){if(O==S)for(var D in C)C.hasOwnProperty(D)&&(j[D]=C[D]);C.hasOwnProperty(O)||(j[O]=N[O])}var M=A[k];return A[k]=j,c.languages.DFS(c.languages,function(U,F){F===M&&U!=k&&(this[U]=j)}),j},DFS:function k(S,C,A,N){N=N||{};var j=c.util.objId;for(var O in S)if(S.hasOwnProperty(O)){C.call(S,O,S[O],A||O);var D=S[O],M=c.util.type(D);M==="Object"&&!N[j(D)]?(N[j(D)]=!0,k(D,C,null,N)):M==="Array"&&!N[j(D)]&&(N[j(D)]=!0,k(D,C,O,N))}}},plugins:{},highlight:function(k,S,C){var A={code:k,grammar:S,language:C};if(c.hooks.run("before-tokenize",A),!A.grammar)throw new Error('The language "'+A.language+'" has no grammar.');return A.tokens=c.tokenize(A.code,A.grammar),c.hooks.run("after-tokenize",A),d.stringify(c.util.encode(A.tokens),A.language)},tokenize:function(k,S){var C=S.rest;if(C){for(var A in C)S[A]=C[A];delete S.rest}var N=new y;return g(N,N.head,k),h(k,N,S,N.head,0),w(N)},hooks:{all:{},add:function(k,S){var C=c.hooks.all;C[k]=C[k]||[],C[k].push(S)},run:function(k,S){var C=c.hooks.all[k];if(!(!C||!C.length))for(var A=0,N;N=C[A++];)N(S)}},Token:d};function d(k,S,C,A){this.type=k,this.content=S,this.alias=C,this.length=(A||"").length|0}d.stringify=function k(S,C){if(typeof S=="string")return S;if(Array.isArray(S)){var A="";return S.forEach(function(M){A+=k(M,C)}),A}var N={type:S.type,content:k(S.content,C),tag:"span",classes:["token",S.type],attributes:{},language:C},j=S.alias;j&&(Array.isArray(j)?Array.prototype.push.apply(N.classes,j):N.classes.push(j)),c.hooks.run("wrap",N);var O="";for(var D in N.attributes)O+=" "+D+'="'+(N.attributes[D]||"").replace(/"/g,"&quot;")+'"';return"<"+N.tag+' class="'+N.classes.join(" ")+'"'+O+">"+N.content+"</"+N.tag+">"};function p(k,S,C,A){k.lastIndex=S;var N=k.exec(C);if(N&&A&&N[1]){var j=N[1].length;N.index+=j,N[0]=N[0].slice(j)}return N}function h(k,S,C,A,N,j){for(var O in C)if(!(!C.hasOwnProperty(O)||!C[O])){var D=C[O];D=Array.isArray(D)?D:[D];for(var M=0;M<D.length;++M){if(j&&j.cause==O+","+M)return;var U=D[M],F=U.inside,Q=!!U.lookbehind,I=!!U.greedy,Y=U.alias;if(I&&!U.pattern.global){var V=U.pattern.toString().match(/[imsuy]*$/)[0];U.pattern=RegExp(U.pattern.source,V+"g")}for(var ue=U.pattern||U,W=A.next,J=N;W!==S.tail&&!(j&&J>=j.reach);J+=W.value.length,W=W.next){var B=W.value;if(S.length>k.length)return;if(!(B instanceof d)){var G=1,te;if(I){if(te=p(ue,J,k,Q),!te||te.index>=k.length)break;var L=te.index,ce=te.index+te[0].length,R=J;for(R+=W.value.length;L>=R;)W=W.next,R+=W.value.length;if(R-=W.value.length,J=R,W.value instanceof d)continue;for(var z=W;z!==S.tail&&(R<ce||typeof z.value=="string");z=z.next)G++,R+=z.value.length;G--,B=k.slice(J,R),te.index-=J}else if(te=p(ue,0,B,Q),!te)continue;var L=te.index,_=te[0],re=B.slice(0,L),ne=B.slice(L+_.length),ie=J+B.length;j&&ie>j.reach&&(j.reach=ie);var le=W.prev;re&&(le=g(S,le,re),J+=re.length),b(S,le,G);var be=new d(O,F?c.tokenize(_,F):_,Y,_);if(W=g(S,le,be),ne&&g(S,W,ne),G>1){var he={cause:O+","+M,reach:ie};h(k,S,C,W.prev,J,he),j&&he.reach>j.reach&&(j.reach=he.reach)}}}}}}function y(){var k={value:null,prev:null,next:null},S={value:null,prev:k,next:null};k.next=S,this.head=k,this.tail=S,this.length=0}function g(k,S,C){var A=S.next,N={value:C,prev:S,next:A};return S.next=N,A.prev=N,k.length++,N}function b(k,S,C){for(var A=S.next,N=0;N<C&&A!==k.tail;N++)A=A.next;S.next=A,A.prev=S,k.length-=N}function w(k){for(var S=[],C=k.head.next;C!==k.tail;)S.push(C.value),C=C.next;return S}return c})();r.exports=a,a.default=a}}),fe=s3(u3());fe.languages.markup={comment:{pattern:/<!--(?:(?!<!--)[\s\S])*?-->/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/<!DOCTYPE(?:[^>"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|<!--(?:[^-]|-(?!->))*-->)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^<!|>$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},fe.languages.markup.tag.inside["attr-value"].inside.entity=fe.languages.markup.entity,fe.languages.markup.doctype.inside["internal-subset"].inside=fe.languages.markup,fe.hooks.add("wrap",function(e){e.type==="entity"&&(e.attributes.title=e.content.replace(/&amp;/,"&"))}),Object.defineProperty(fe.languages.markup.tag,"addInlined",{value:function(e,l){var a={},a=(a["language-"+l]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:fe.languages[l]},a.cdata=/^<!\[CDATA\[|\]\]>$/i,{"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:a}}),l=(a["language-"+l]={pattern:/[\s\S]+/,inside:fe.languages[l]},{});l[e]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return e}),"i"),lookbehind:!0,greedy:!0,inside:a},fe.languages.insertBefore("markup","cdata",l)}}),Object.defineProperty(fe.languages.markup.tag,"addAttribute",{value:function(e,r){fe.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+e+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[r,"language-"+r],inside:fe.languages[r]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),fe.languages.html=fe.languages.markup,fe.languages.mathml=fe.languages.markup,fe.languages.svg=fe.languages.markup,fe.languages.xml=fe.languages.extend("markup",{}),fe.languages.ssml=fe.languages.xml,fe.languages.atom=fe.languages.xml,fe.languages.rss=fe.languages.xml,(function(e){var r={pattern:/\\[\\(){}[\]^$+*?|.]/,alias:"escape"},a=/\\(?:x[\da-fA-F]{2}|u[\da-fA-F]{4}|u\{[\da-fA-F]+\}|0[0-7]{0,2}|[123][0-7]{2}|c[a-zA-Z]|.)/,l="(?:[^\\\\-]|"+a.source+")",l=RegExp(l+"-"+l),o={pattern:/(<|')[^<>']+(?=[>']$)/,lookbehind:!0,alias:"variable"};e.languages.regex={"char-class":{pattern:/((?:^|[^\\])(?:\\\\)*)\[(?:[^\\\]]|\\[\s\S])*\]/,lookbehind:!0,inside:{"char-class-negation":{pattern:/(^\[)\^/,lookbehind:!0,alias:"operator"},"char-class-punctuation":{pattern:/^\[|\]$/,alias:"punctuation"},range:{pattern:l,inside:{escape:a,"range-punctuation":{pattern:/-/,alias:"operator"}}},"special-escape":r,"char-set":{pattern:/\\[wsd]|\\p\{[^{}]+\}/i,alias:"class-name"},escape:a}},"special-escape":r,"char-set":{pattern:/\.|\\[wsd]|\\p\{[^{}]+\}/i,alias:"class-name"},backreference:[{pattern:/\\(?![123][0-7]{2})[1-9]/,alias:"keyword"},{pattern:/\\k<[^<>']+>/,alias:"keyword",inside:{"group-name":o}}],anchor:{pattern:/[$^]|\\[ABbGZz]/,alias:"function"},escape:a,group:[{pattern:/\((?:\?(?:<[^<>']+>|'[^<>']+'|[>:]|<?[=!]|[idmnsuxU]+(?:-[idmnsuxU]+)?:?))?/,alias:"punctuation",inside:{"group-name":o}},{pattern:/\)/,alias:"punctuation"}],quantifier:{pattern:/(?:[+*?]|\{\d+(?:,\d*)?\})[?+]?/,alias:"number"},alternation:{pattern:/\|/,alias:"keyword"}}})(fe),fe.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/},fe.languages.javascript=fe.languages.extend("clike",{"class-name":[fe.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),fe.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,fe.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:fe.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:fe.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:fe.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:fe.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:fe.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),fe.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:fe.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),fe.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),fe.languages.markup&&(fe.languages.markup.tag.addInlined("script","javascript"),fe.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),fe.languages.js=fe.languages.javascript,fe.languages.actionscript=fe.languages.extend("javascript",{keyword:/\b(?:as|break|case|catch|class|const|default|delete|do|dynamic|each|else|extends|final|finally|for|function|get|if|implements|import|in|include|instanceof|interface|internal|is|namespace|native|new|null|override|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|use|var|void|while|with)\b/,operator:/\+\+|--|(?:[+\-*\/%^]|&&?|\|\|?|<<?|>>?>?|[!=]=?)=?|[~?@]/}),fe.languages.actionscript["class-name"].alias="function",delete fe.languages.actionscript.parameter,delete fe.languages.actionscript["literal-property"],fe.languages.markup&&fe.languages.insertBefore("actionscript","string",{xml:{pattern:/(^|[^.])<\/?\w+(?:\s+[^\s>\/=]+=("|')(?:\\[\s\S]|(?!\2)[^\\])*\2)*\s*\/?>/,lookbehind:!0,inside:fe.languages.markup}}),(function(e){var r=/#(?!\{).+/,a={pattern:/#\{[^}]+\}/,alias:"variable"};e.languages.coffeescript=e.languages.extend("javascript",{comment:r,string:[{pattern:/'(?:\\[\s\S]|[^\\'])*'/,greedy:!0},{pattern:/"(?:\\[\s\S]|[^\\"])*"/,greedy:!0,inside:{interpolation:a}}],keyword:/\b(?:and|break|by|catch|class|continue|debugger|delete|do|each|else|extend|extends|false|finally|for|if|in|instanceof|is|isnt|let|loop|namespace|new|no|not|null|of|off|on|or|own|return|super|switch|then|this|throw|true|try|typeof|undefined|unless|until|when|while|window|with|yes|yield)\b/,"class-member":{pattern:/@(?!\d)\w+/,alias:"variable"}}),e.languages.insertBefore("coffeescript","comment",{"multiline-comment":{pattern:/###[\s\S]+?###/,alias:"comment"},"block-regex":{pattern:/\/{3}[\s\S]*?\/{3}/,alias:"regex",inside:{comment:r,interpolation:a}}}),e.languages.insertBefore("coffeescript","string",{"inline-javascript":{pattern:/`(?:\\[\s\S]|[^\\`])*`/,inside:{delimiter:{pattern:/^`|`$/,alias:"punctuation"},script:{pattern:/[\s\S]+/,alias:"language-javascript",inside:e.languages.javascript}}},"multiline-string":[{pattern:/'''[\s\S]*?'''/,greedy:!0,alias:"string"},{pattern:/"""[\s\S]*?"""/,greedy:!0,alias:"string",inside:{interpolation:a}}]}),e.languages.insertBefore("coffeescript","keyword",{property:/(?!\d)\w+(?=\s*:(?!:))/}),delete e.languages.coffeescript["template-string"],e.languages.coffee=e.languages.coffeescript})(fe),(function(e){var r=e.languages.javadoclike={parameter:{pattern:/(^[\t ]*(?:\/{3}|\*|\/\*\*)\s*@(?:arg|arguments|param)\s+)\w+/m,lookbehind:!0},keyword:{pattern:/(^[\t ]*(?:\/{3}|\*|\/\*\*)\s*|\{)@[a-z][a-zA-Z-]+\b/m,lookbehind:!0},punctuation:/[{}]/};Object.defineProperty(r,"addSupport",{value:function(a,l){(a=typeof a=="string"?[a]:a).forEach(function(o){var s=function(g){g.inside||(g.inside={}),g.inside.rest=l},c="doc-comment";if(d=e.languages[o]){var d,p=d[c];if((p=p||(d=e.languages.insertBefore(o,"comment",{"doc-comment":{pattern:/(^|[^\\])\/\*\*[^/][\s\S]*?(?:\*\/|$)/,lookbehind:!0,alias:"comment"}}))[c])instanceof RegExp&&(p=d[c]={pattern:p}),Array.isArray(p))for(var h=0,y=p.length;h<y;h++)p[h]instanceof RegExp&&(p[h]={pattern:p[h]}),s(p[h]);else s(p)}})}}),r.addSupport(["java","javascript","php"],r)})(fe),(function(e){var r=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/,r=(e.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+r.source+")*?"+/(?:;|(?=\s*\{))/.source),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+r.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+r.source+"$"),alias:"url"}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+r.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:r,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},e.languages.css.atrule.inside.rest=e.languages.css,e.languages.markup);r&&(r.tag.addInlined("style","css"),r.tag.addAttribute("style","css"))})(fe),(function(e){var r=/("|')(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,r=(e.languages.css.selector={pattern:e.languages.css.selector.pattern,lookbehind:!0,inside:r={"pseudo-element":/:(?:after|before|first-letter|first-line|selection)|::[-\w]+/,"pseudo-class":/:[-\w]+/,class:/\.[-\w]+/,id:/#[-\w]+/,attribute:{pattern:RegExp(`\\[(?:[^[\\]"']|`+r.source+")*\\]"),greedy:!0,inside:{punctuation:/^\[|\]$/,"case-sensitivity":{pattern:/(\s)[si]$/i,lookbehind:!0,alias:"keyword"},namespace:{pattern:/^(\s*)(?:(?!\s)[-*\w\xA0-\uFFFF])*\|(?!=)/,lookbehind:!0,inside:{punctuation:/\|$/}},"attr-name":{pattern:/^(\s*)(?:(?!\s)[-\w\xA0-\uFFFF])+/,lookbehind:!0},"attr-value":[r,{pattern:/(=\s*)(?:(?!\s)[-\w\xA0-\uFFFF])+(?=\s*$)/,lookbehind:!0}],operator:/[|~*^$]?=/}},"n-th":[{pattern:/(\(\s*)[+-]?\d*[\dn](?:\s*[+-]\s*\d+)?(?=\s*\))/,lookbehind:!0,inside:{number:/[\dn]+/,operator:/[+-]/}},{pattern:/(\(\s*)(?:even|odd)(?=\s*\))/i,lookbehind:!0}],combinator:/>|\+|~|\|\|/,punctuation:/[(),]/}},e.languages.css.atrule.inside["selector-function-argument"].inside=r,e.languages.insertBefore("css","property",{variable:{pattern:/(^|[^-\w\xA0-\uFFFF])--(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*/i,lookbehind:!0}}),{pattern:/(\b\d+)(?:%|[a-z]+(?![\w-]))/,lookbehind:!0}),a={pattern:/(^|[^\w.-])-?(?:\d+(?:\.\d+)?|\.\d+)/,lookbehind:!0};e.languages.insertBefore("css","function",{operator:{pattern:/(\s)[+\-*\/](?=\s)/,lookbehind:!0},hexcode:{pattern:/\B#[\da-f]{3,8}\b/i,alias:"color"},color:[{pattern:/(^|[^\w-])(?:AliceBlue|AntiqueWhite|Aqua|Aquamarine|Azure|Beige|Bisque|Black|BlanchedAlmond|Blue|BlueViolet|Brown|BurlyWood|CadetBlue|Chartreuse|Chocolate|Coral|CornflowerBlue|Cornsilk|Crimson|Cyan|DarkBlue|DarkCyan|DarkGoldenRod|DarkGr[ae]y|DarkGreen|DarkKhaki|DarkMagenta|DarkOliveGreen|DarkOrange|DarkOrchid|DarkRed|DarkSalmon|DarkSeaGreen|DarkSlateBlue|DarkSlateGr[ae]y|DarkTurquoise|DarkViolet|DeepPink|DeepSkyBlue|DimGr[ae]y|DodgerBlue|FireBrick|FloralWhite|ForestGreen|Fuchsia|Gainsboro|GhostWhite|Gold|GoldenRod|Gr[ae]y|Green|GreenYellow|HoneyDew|HotPink|IndianRed|Indigo|Ivory|Khaki|Lavender|LavenderBlush|LawnGreen|LemonChiffon|LightBlue|LightCoral|LightCyan|LightGoldenRodYellow|LightGr[ae]y|LightGreen|LightPink|LightSalmon|LightSeaGreen|LightSkyBlue|LightSlateGr[ae]y|LightSteelBlue|LightYellow|Lime|LimeGreen|Linen|Magenta|Maroon|MediumAquaMarine|MediumBlue|MediumOrchid|MediumPurple|MediumSeaGreen|MediumSlateBlue|MediumSpringGreen|MediumTurquoise|MediumVioletRed|MidnightBlue|MintCream|MistyRose|Moccasin|NavajoWhite|Navy|OldLace|Olive|OliveDrab|Orange|OrangeRed|Orchid|PaleGoldenRod|PaleGreen|PaleTurquoise|PaleVioletRed|PapayaWhip|PeachPuff|Peru|Pink|Plum|PowderBlue|Purple|RebeccaPurple|Red|RosyBrown|RoyalBlue|SaddleBrown|Salmon|SandyBrown|SeaGreen|SeaShell|Sienna|Silver|SkyBlue|SlateBlue|SlateGr[ae]y|Snow|SpringGreen|SteelBlue|Tan|Teal|Thistle|Tomato|Transparent|Turquoise|Violet|Wheat|White|WhiteSmoke|Yellow|YellowGreen)(?![\w-])/i,lookbehind:!0},{pattern:/\b(?:hsl|rgb)\(\s*\d{1,3}\s*,\s*\d{1,3}%?\s*,\s*\d{1,3}%?\s*\)\B|\b(?:hsl|rgb)a\(\s*\d{1,3}\s*,\s*\d{1,3}%?\s*,\s*\d{1,3}%?\s*,\s*(?:0|0?\.\d+|1)\s*\)\B/i,inside:{unit:r,number:a,function:/[\w-]+(?=\()/,punctuation:/[(),]/}}],entity:/\\[\da-f]{1,8}/i,unit:r,number:a})})(fe),(function(e){var r=/[*&][^\s[\]{},]+/,a=/!(?:<[\w\-%#;/?:@&=+$,.!~*'()[\]]+>|(?:[a-zA-Z\d-]*!)?[\w\-%#;/?:@&=+$.~*'()]+)?/,l="(?:"+a.source+"(?:[ ]+"+r.source+")?|"+r.source+"(?:[ ]+"+a.source+")?)",o=/(?:[^\s\x00-\x08\x0e-\x1f!"#%&'*,\-:>?@[\]`{|}\x7f-\x84\x86-\x9f\ud800-\udfff\ufffe\uffff]|[?:-]<PLAIN>)(?:[ \t]*(?:(?![#:])<PLAIN>|:<PLAIN>))*/.source.replace(/<PLAIN>/g,function(){return/[^\s\x00-\x08\x0e-\x1f,[\]{}\x7f-\x84\x86-\x9f\ud800-\udfff\ufffe\uffff]/.source}),s=/"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\\\r\n]|\\.)*'/.source;function c(d,p){p=(p||"").replace(/m/g,"")+"m";var h=/([:\-,[{]\s*(?:\s<<prop>>[ \t]+)?)(?:<<value>>)(?=[ \t]*(?:$|,|\]|\}|(?:[\r\n]\s*)?#))/.source.replace(/<<prop>>/g,function(){return l}).replace(/<<value>>/g,function(){return d});return RegExp(h,p)}e.languages.yaml={scalar:{pattern:RegExp(/([\-:]\s*(?:\s<<prop>>[ \t]+)?[|>])[ \t]*(?:((?:\r?\n|\r)[ \t]+)\S[^\r\n]*(?:\2[^\r\n]+)*)/.source.replace(/<<prop>>/g,function(){return l})),lookbehind:!0,alias:"string"},comment:/#.*/,key:{pattern:RegExp(/((?:^|[:\-,[{\r\n?])[ \t]*(?:<<prop>>[ \t]+)?)<<key>>(?=\s*:\s)/.source.replace(/<<prop>>/g,function(){return l}).replace(/<<key>>/g,function(){return"(?:"+o+"|"+s+")"})),lookbehind:!0,greedy:!0,alias:"atrule"},directive:{pattern:/(^[ \t]*)%.+/m,lookbehind:!0,alias:"important"},datetime:{pattern:c(/\d{4}-\d\d?-\d\d?(?:[tT]|[ \t]+)\d\d?:\d{2}:\d{2}(?:\.\d*)?(?:[ \t]*(?:Z|[-+]\d\d?(?::\d{2})?))?|\d{4}-\d{2}-\d{2}|\d\d?:\d{2}(?::\d{2}(?:\.\d*)?)?/.source),lookbehind:!0,alias:"number"},boolean:{pattern:c(/false|true/.source,"i"),lookbehind:!0,alias:"important"},null:{pattern:c(/null|~/.source,"i"),lookbehind:!0,alias:"important"},string:{pattern:c(s),lookbehind:!0,greedy:!0},number:{pattern:c(/[+-]?(?:0x[\da-f]+|0o[0-7]+|(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?|\.inf|\.nan)/.source,"i"),lookbehind:!0},tag:a,important:r,punctuation:/---|[:[\]{}\-,|>?]|\.\.\./},e.languages.yml=e.languages.yaml})(fe),(function(e){var r=/(?:\\.|[^\\\n\r]|(?:\n|\r\n?)(?![\r\n]))/.source;function a(h){return h=h.replace(/<inner>/g,function(){return r}),RegExp(/((?:^|[^\\])(?:\\{2})*)/.source+"(?:"+h+")")}var l=/(?:\\.|``(?:[^`\r\n]|`(?!`))+``|`[^`\r\n]+`|[^\\|\r\n`])+/.source,o=/\|?__(?:\|__)+\|?(?:(?:\n|\r\n?)|(?![\s\S]))/.source.replace(/__/g,function(){return l}),s=/\|?[ \t]*:?-{3,}:?[ \t]*(?:\|[ \t]*:?-{3,}:?[ \t]*)+\|?(?:\n|\r\n?)/.source,c=(e.languages.markdown=e.languages.extend("markup",{}),e.languages.insertBefore("markdown","prolog",{"front-matter-block":{pattern:/(^(?:\s*[\r\n])?)---(?!.)[\s\S]*?[\r\n]---(?!.)/,lookbehind:!0,greedy:!0,inside:{punctuation:/^---|---$/,"front-matter":{pattern:/\S+(?:\s+\S+)*/,alias:["yaml","language-yaml"],inside:e.languages.yaml}}},blockquote:{pattern:/^>(?:[\t ]*>)*/m,alias:"punctuation"},table:{pattern:RegExp("^"+o+s+"(?:"+o+")*","m"),inside:{"table-data-rows":{pattern:RegExp("^("+o+s+")(?:"+o+")*$"),lookbehind:!0,inside:{"table-data":{pattern:RegExp(l),inside:e.languages.markdown},punctuation:/\|/}},"table-line":{pattern:RegExp("^("+o+")"+s+"$"),lookbehind:!0,inside:{punctuation:/\||:?-{3,}:?/}},"table-header-row":{pattern:RegExp("^"+o+"$"),inside:{"table-header":{pattern:RegExp(l),alias:"important",inside:e.languages.markdown},punctuation:/\|/}}}},code:[{pattern:/((?:^|\n)[ \t]*\n|(?:^|\r\n?)[ \t]*\r\n?)(?: {4}|\t).+(?:(?:\n|\r\n?)(?: {4}|\t).+)*/,lookbehind:!0,alias:"keyword"},{pattern:/^```[\s\S]*?^```$/m,greedy:!0,inside:{"code-block":{pattern:/^(```.*(?:\n|\r\n?))[\s\S]+?(?=(?:\n|\r\n?)^```$)/m,lookbehind:!0},"code-language":{pattern:/^(```).+/,lookbehind:!0},punctuation:/```/}}],title:[{pattern:/\S.*(?:\n|\r\n?)(?:==+|--+)(?=[ \t]*$)/m,alias:"important",inside:{punctuation:/==+$|--+$/}},{pattern:/(^\s*)#.+/m,lookbehind:!0,alias:"important",inside:{punctuation:/^#+|#+$/}}],hr:{pattern:/(^\s*)([*-])(?:[\t ]*\2){2,}(?=\s*$)/m,lookbehind:!0,alias:"punctuation"},list:{pattern:/(^\s*)(?:[*+-]|\d+\.)(?=[\t ].)/m,lookbehind:!0,alias:"punctuation"},"url-reference":{pattern:/!?\[[^\]]+\]:[\t ]+(?:\S+|<(?:\\.|[^>\\])+>)(?:[\t ]+(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\)))?/,inside:{variable:{pattern:/^(!?\[)[^\]]+/,lookbehind:!0},string:/(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\))$/,punctuation:/^[\[\]!:]|[<>]/},alias:"url"},bold:{pattern:a(/\b__(?:(?!_)<inner>|_(?:(?!_)<inner>)+_)+__\b|\*\*(?:(?!\*)<inner>|\*(?:(?!\*)<inner>)+\*)+\*\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^..)[\s\S]+(?=..$)/,lookbehind:!0,inside:{}},punctuation:/\*\*|__/}},italic:{pattern:a(/\b_(?:(?!_)<inner>|__(?:(?!_)<inner>)+__)+_\b|\*(?:(?!\*)<inner>|\*\*(?:(?!\*)<inner>)+\*\*)+\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^.)[\s\S]+(?=.$)/,lookbehind:!0,inside:{}},punctuation:/[*_]/}},strike:{pattern:a(/(~~?)(?:(?!~)<inner>)+\2/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^~~?)[\s\S]+(?=\1$)/,lookbehind:!0,inside:{}},punctuation:/~~?/}},"code-snippet":{pattern:/(^|[^\\`])(?:``[^`\r\n]+(?:`[^`\r\n]+)*``(?!`)|`[^`\r\n]+`(?!`))/,lookbehind:!0,greedy:!0,alias:["code","keyword"]},url:{pattern:a(/!?\[(?:(?!\])<inner>)+\](?:\([^\s)]+(?:[\t ]+"(?:\\.|[^"\\])*")?\)|[ \t]?\[(?:(?!\])<inner>)+\])/.source),lookbehind:!0,greedy:!0,inside:{operator:/^!/,content:{pattern:/(^\[)[^\]]+(?=\])/,lookbehind:!0,inside:{}},variable:{pattern:/(^\][ \t]?\[)[^\]]+(?=\]$)/,lookbehind:!0},url:{pattern:/(^\]\()[^\s)]+/,lookbehind:!0},string:{pattern:/(^[ \t]+)"(?:\\.|[^"\\])*"(?=\)$)/,lookbehind:!0}}}}),["url","bold","italic","strike"].forEach(function(h){["url","bold","italic","strike","code-snippet"].forEach(function(y){h!==y&&(e.languages.markdown[h].inside.content.inside[y]=e.languages.markdown[y])})}),e.hooks.add("after-tokenize",function(h){h.language!=="markdown"&&h.language!=="md"||(function y(g){if(g&&typeof g!="string")for(var b=0,w=g.length;b<w;b++){var k,S=g[b];S.type!=="code"?y(S.content):(k=S.content[1],S=S.content[3],k&&S&&k.type==="code-language"&&S.type==="code-block"&&typeof k.content=="string"&&(k=k.content.replace(/\b#/g,"sharp").replace(/\b\+\+/g,"pp"),k="language-"+(k=(/[a-z][\w-]*/i.exec(k)||[""])[0].toLowerCase()),S.alias?typeof S.alias=="string"?S.alias=[S.alias,k]:S.alias.push(k):S.alias=[k]))}})(h.tokens)}),e.hooks.add("wrap",function(h){if(h.type==="code-block"){for(var y="",g=0,b=h.classes.length;g<b;g++){var w=h.classes[g],w=/language-(.+)/.exec(w);if(w){y=w[1];break}}var k,S=e.languages[y];S?h.content=e.highlight((function(C){return C=C.replace(c,""),C=C.replace(/&(\w{1,8}|#x?[\da-f]{1,8});/gi,function(A,N){var j;return(N=N.toLowerCase())[0]==="#"?(j=N[1]==="x"?parseInt(N.slice(2),16):Number(N.slice(1)),p(j)):d[N]||A})})(h.content),S,y):y&&y!=="none"&&e.plugins.autoloader&&(k="md-"+new Date().valueOf()+"-"+Math.floor(1e16*Math.random()),h.attributes.id=k,e.plugins.autoloader.loadLanguages(y,function(){var C=document.getElementById(k);C&&(C.innerHTML=e.highlight(C.textContent,e.languages[y],y))}))}}),RegExp(e.languages.markup.tag.pattern.source,"gi")),d={amp:"&",lt:"<",gt:">",quot:'"'},p=String.fromCodePoint||String.fromCharCode;e.languages.md=e.languages.markdown})(fe),fe.languages.graphql={comment:/#.*/,description:{pattern:/(?:"""(?:[^"]|(?!""")")*"""|"(?:\\.|[^\\"\r\n])*")(?=\s*[a-z_])/i,greedy:!0,alias:"string",inside:{"language-markdown":{pattern:/(^"(?:"")?)(?!\1)[\s\S]+(?=\1$)/,lookbehind:!0,inside:fe.languages.markdown}}},string:{pattern:/"""(?:[^"]|(?!""")")*"""|"(?:\\.|[^\\"\r\n])*"/,greedy:!0},number:/(?:\B-|\b)\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,boolean:/\b(?:false|true)\b/,variable:/\$[a-z_]\w*/i,directive:{pattern:/@[a-z_]\w*/i,alias:"function"},"attr-name":{pattern:/\b[a-z_]\w*(?=\s*(?:\((?:[^()"]|"(?:\\.|[^\\"\r\n])*")*\))?:)/i,greedy:!0},"atom-input":{pattern:/\b[A-Z]\w*Input\b/,alias:"class-name"},scalar:/\b(?:Boolean|Float|ID|Int|String)\b/,constant:/\b[A-Z][A-Z_\d]*\b/,"class-name":{pattern:/(\b(?:enum|implements|interface|on|scalar|type|union)\s+|&\s*|:\s*|\[)[A-Z_]\w*/,lookbehind:!0},fragment:{pattern:/(\bfragment\s+|\.{3}\s*(?!on\b))[a-zA-Z_]\w*/,lookbehind:!0,alias:"function"},"definition-mutation":{pattern:/(\bmutation\s+)[a-zA-Z_]\w*/,lookbehind:!0,alias:"function"},"definition-query":{pattern:/(\bquery\s+)[a-zA-Z_]\w*/,lookbehind:!0,alias:"function"},keyword:/\b(?:directive|enum|extend|fragment|implements|input|interface|mutation|on|query|repeatable|scalar|schema|subscription|type|union)\b/,operator:/[!=|&]|\.{3}/,"property-query":/\w+(?=\s*\()/,object:/\w+(?=\s*\{)/,punctuation:/[!(){}\[\]:=,]/,property:/\w+/},fe.hooks.add("after-tokenize",function(e){if(e.language==="graphql")for(var r=e.tokens.filter(function(k){return typeof k!="string"&&k.type!=="comment"&&k.type!=="scalar"}),a=0;a<r.length;){var l=r[a++];if(l.type==="keyword"&&l.content==="mutation"){var o=[];if(g(["definition-mutation","punctuation"])&&y(1).content==="("){a+=2;var s=b(/^\($/,/^\)$/);if(s===-1)continue;for(;a<s;a++){var c=y(0);c.type==="variable"&&(w(c,"variable-input"),o.push(c.content))}a=s+1}if(g(["punctuation","property-query"])&&y(0).content==="{"&&(a++,w(y(0),"property-mutation"),0<o.length)){var d=b(/^\{$/,/^\}$/);if(d!==-1)for(var p=a;p<d;p++){var h=r[p];h.type==="variable"&&0<=o.indexOf(h.content)&&w(h,"variable-input")}}}}function y(k){return r[a+k]}function g(k,S){S=S||0;for(var C=0;C<k.length;C++){var A=y(C+S);if(!A||A.type!==k[C])return}return 1}function b(k,S){for(var C=1,A=a;A<r.length;A++){var N=r[A],j=N.content;if(N.type==="punctuation"&&typeof j=="string"){if(k.test(j))C++;else if(S.test(j)&&--C===0)return A}}return-1}function w(k,S){var C=k.alias;C?Array.isArray(C)||(k.alias=C=[C]):k.alias=C=[],C.push(S)}}),fe.languages.sql={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},variable:[{pattern:/@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/,greedy:!0},/@[\w.$]+/],string:{pattern:/(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/,greedy:!0,lookbehind:!0},identifier:{pattern:/(^|[^@\\])`(?:\\[\s\S]|[^`\\]|``)*`/,greedy:!0,lookbehind:!0,inside:{punctuation:/^`|`$/}},function:/\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i,keyword:/\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:COL|_INSERT)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURN(?:ING|S)?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i,boolean:/\b(?:FALSE|NULL|TRUE)\b/i,number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i,operator:/[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/},(function(e){var r=e.languages.javascript["template-string"],a=r.pattern.source,l=r.inside.interpolation,o=l.inside["interpolation-punctuation"],s=l.pattern.source;function c(g,b){if(e.languages[g])return{pattern:RegExp("((?:"+b+")\\s*)"+a),lookbehind:!0,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},"embedded-code":{pattern:/[\s\S]+/,alias:g}}}}function d(g,b,w){return g={code:g,grammar:b,language:w},e.hooks.run("before-tokenize",g),g.tokens=e.tokenize(g.code,g.grammar),e.hooks.run("after-tokenize",g),g.tokens}function p(g,b,w){var C=e.tokenize(g,{interpolation:{pattern:RegExp(s),lookbehind:!0}}),k=0,S={},C=d(C.map(function(N){if(typeof N=="string")return N;for(var j,O,N=N.content;g.indexOf((O=k++,j="___"+w.toUpperCase()+"_"+O+"___"))!==-1;);return S[j]=N,j}).join(""),b,w),A=Object.keys(S);return k=0,(function N(j){for(var O=0;O<j.length;O++){if(k>=A.length)return;var D,M,U,F,Q,I,Y,V=j[O];typeof V=="string"||typeof V.content=="string"?(D=A[k],(Y=(I=typeof V=="string"?V:V.content).indexOf(D))!==-1&&(++k,M=I.substring(0,Y),Q=S[D],U=void 0,(F={})["interpolation-punctuation"]=o,(F=e.tokenize(Q,F)).length===3&&((U=[1,1]).push.apply(U,d(F[1],e.languages.javascript,"javascript")),F.splice.apply(F,U)),U=new e.Token("interpolation",F,l.alias,Q),F=I.substring(Y+D.length),Q=[],M&&Q.push(M),Q.push(U),F&&(N(I=[F]),Q.push.apply(Q,I)),typeof V=="string"?(j.splice.apply(j,[O,1].concat(Q)),O+=Q.length-1):V.content=Q)):(Y=V.content,Array.isArray(Y)?N(Y):N([Y]))}})(C),new e.Token(w,C,"language-"+w,g)}e.languages.javascript["template-string"]=[c("css",/\b(?:styled(?:\([^)]*\))?(?:\s*\.\s*\w+(?:\([^)]*\))*)*|css(?:\s*\.\s*(?:global|resolve))?|createGlobalStyle|keyframes)/.source),c("html",/\bhtml|\.\s*(?:inner|outer)HTML\s*\+?=/.source),c("svg",/\bsvg/.source),c("markdown",/\b(?:markdown|md)/.source),c("graphql",/\b(?:gql|graphql(?:\s*\.\s*experimental)?)/.source),c("sql",/\bsql/.source),r].filter(Boolean);var h={javascript:!0,js:!0,typescript:!0,ts:!0,jsx:!0,tsx:!0};function y(g){return typeof g=="string"?g:Array.isArray(g)?g.map(y).join(""):y(g.content)}e.hooks.add("after-tokenize",function(g){g.language in h&&(function b(w){for(var k=0,S=w.length;k<S;k++){var C,A,N,j=w[k];typeof j!="string"&&(C=j.content,Array.isArray(C)?j.type==="template-string"?(j=C[1],C.length===3&&typeof j!="string"&&j.type==="embedded-code"&&(A=y(j),j=j.alias,j=Array.isArray(j)?j[0]:j,N=e.languages[j])&&(C[1]=p(A,N,j))):b(C):typeof C!="string"&&b([C]))}})(g.tokens)})})(fe),(function(e){e.languages.typescript=e.languages.extend("javascript",{"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|type)\s+)(?!keyof\b)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?:\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>)?/,lookbehind:!0,greedy:!0,inside:null},builtin:/\b(?:Array|Function|Promise|any|boolean|console|never|number|string|symbol|unknown)\b/}),e.languages.typescript.keyword.push(/\b(?:abstract|declare|is|keyof|readonly|require)\b/,/\b(?:asserts|infer|interface|module|namespace|type)\b(?=\s*(?:[{_$a-zA-Z\xA0-\uFFFF]|$))/,/\btype\b(?=\s*(?:[\{*]|$))/),delete e.languages.typescript.parameter,delete e.languages.typescript["literal-property"];var r=e.languages.extend("typescript",{});delete r["class-name"],e.languages.typescript["class-name"].inside=r,e.languages.insertBefore("typescript","function",{decorator:{pattern:/@[$\w\xA0-\uFFFF]+/,inside:{at:{pattern:/^@/,alias:"operator"},function:/^[\s\S]+/}},"generic-function":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>(?=\s*\()/,greedy:!0,inside:{function:/^#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:r}}}}),e.languages.ts=e.languages.typescript})(fe),(function(e){var r=e.languages.javascript,a=/\{(?:[^{}]|\{(?:[^{}]|\{[^{}]*\})*\})+\}/.source,l="(@(?:arg|argument|param|property)\\s+(?:"+a+"\\s+)?)";e.languages.jsdoc=e.languages.extend("javadoclike",{parameter:{pattern:RegExp(l+/(?:(?!\s)[$\w\xA0-\uFFFF.])+(?=\s|$)/.source),lookbehind:!0,inside:{punctuation:/\./}}}),e.languages.insertBefore("jsdoc","keyword",{"optional-parameter":{pattern:RegExp(l+/\[(?:(?!\s)[$\w\xA0-\uFFFF.])+(?:=[^[\]]+)?\](?=\s|$)/.source),lookbehind:!0,inside:{parameter:{pattern:/(^\[)[$\w\xA0-\uFFFF\.]+/,lookbehind:!0,inside:{punctuation:/\./}},code:{pattern:/(=)[\s\S]*(?=\]$)/,lookbehind:!0,inside:r,alias:"language-javascript"},punctuation:/[=[\]]/}},"class-name":[{pattern:RegExp(/(@(?:augments|class|extends|interface|memberof!?|template|this|typedef)\s+(?:<TYPE>\s+)?)[A-Z]\w*(?:\.[A-Z]\w*)*/.source.replace(/<TYPE>/g,function(){return a})),lookbehind:!0,inside:{punctuation:/\./}},{pattern:RegExp("(@[a-z]+\\s+)"+a),lookbehind:!0,inside:{string:r.string,number:r.number,boolean:r.boolean,keyword:e.languages.typescript.keyword,operator:/=>|\.\.\.|[&|?:*]/,punctuation:/[.,;=<>{}()[\]]/}}],example:{pattern:/(@example\s+(?!\s))(?:[^@\s]|\s+(?!\s))+?(?=\s*(?:\*\s*)?(?:@\w|\*\/))/,lookbehind:!0,inside:{code:{pattern:/^([\t ]*(?:\*\s*)?)\S.*$/m,lookbehind:!0,inside:r,alias:"language-javascript"}}}}),e.languages.javadoclike.addSupport("javascript",e.languages.jsdoc)})(fe),(function(e){e.languages.flow=e.languages.extend("javascript",{}),e.languages.insertBefore("flow","keyword",{type:[{pattern:/\b(?:[Bb]oolean|Function|[Nn]umber|[Ss]tring|[Ss]ymbol|any|mixed|null|void)\b/,alias:"class-name"}]}),e.languages.flow["function-variable"].pattern=/(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=\s*(?:function\b|(?:\([^()]*\)(?:\s*:\s*\w+)?|(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/i,delete e.languages.flow.parameter,e.languages.insertBefore("flow","operator",{"flow-punctuation":{pattern:/\{\||\|\}/,alias:"punctuation"}}),Array.isArray(e.languages.flow.keyword)||(e.languages.flow.keyword=[e.languages.flow.keyword]),e.languages.flow.keyword.unshift({pattern:/(^|[^$]\b)(?:Class|declare|opaque|type)\b(?!\$)/,lookbehind:!0},{pattern:/(^|[^$]\B)\$(?:Diff|Enum|Exact|Keys|ObjMap|PropertyType|Record|Shape|Subtype|Supertype|await)\b(?!\$)/,lookbehind:!0})})(fe),fe.languages.n4js=fe.languages.extend("javascript",{keyword:/\b(?:Array|any|boolean|break|case|catch|class|const|constructor|continue|debugger|declare|default|delete|do|else|enum|export|extends|false|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|module|new|null|number|package|private|protected|public|return|set|static|string|super|switch|this|throw|true|try|typeof|var|void|while|with|yield)\b/}),fe.languages.insertBefore("n4js","constant",{annotation:{pattern:/@+\w+/,alias:"operator"}}),fe.languages.n4jsd=fe.languages.n4js,(function(e){function r(c,d){return RegExp(c.replace(/<ID>/g,function(){return/(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/.source}),d)}e.languages.insertBefore("javascript","function-variable",{"method-variable":{pattern:RegExp("(\\.\\s*)"+e.languages.javascript["function-variable"].pattern.source),lookbehind:!0,alias:["function-variable","method","function","property-access"]}}),e.languages.insertBefore("javascript","function",{method:{pattern:RegExp("(\\.\\s*)"+e.languages.javascript.function.source),lookbehind:!0,alias:["function","property-access"]}}),e.languages.insertBefore("javascript","constant",{"known-class-name":[{pattern:/\b(?:(?:Float(?:32|64)|(?:Int|Uint)(?:8|16|32)|Uint8Clamped)?Array|ArrayBuffer|BigInt|Boolean|DataView|Date|Error|Function|Intl|JSON|(?:Weak)?(?:Map|Set)|Math|Number|Object|Promise|Proxy|Reflect|RegExp|String|Symbol|WebAssembly)\b/,alias:"class-name"},{pattern:/\b(?:[A-Z]\w*)Error\b/,alias:"class-name"}]}),e.languages.insertBefore("javascript","keyword",{imports:{pattern:r(/(\bimport\b\s*)(?:<ID>(?:\s*,\s*(?:\*\s*as\s+<ID>|\{[^{}]*\}))?|\*\s*as\s+<ID>|\{[^{}]*\})(?=\s*\bfrom\b)/.source),lookbehind:!0,inside:e.languages.javascript},exports:{pattern:r(/(\bexport\b\s*)(?:\*(?:\s*as\s+<ID>)?(?=\s*\bfrom\b)|\{[^{}]*\})/.source),lookbehind:!0,inside:e.languages.javascript}}),e.languages.javascript.keyword.unshift({pattern:/\b(?:as|default|export|from|import)\b/,alias:"module"},{pattern:/\b(?:await|break|catch|continue|do|else|finally|for|if|return|switch|throw|try|while|yield)\b/,alias:"control-flow"},{pattern:/\bnull\b/,alias:["null","nil"]},{pattern:/\bundefined\b/,alias:"nil"}),e.languages.insertBefore("javascript","operator",{spread:{pattern:/\.{3}/,alias:"operator"},arrow:{pattern:/=>/,alias:"operator"}}),e.languages.insertBefore("javascript","punctuation",{"property-access":{pattern:r(/(\.\s*)#?<ID>/.source),lookbehind:!0},"maybe-class-name":{pattern:/(^|[^$\w\xA0-\uFFFF])[A-Z][$\w\xA0-\uFFFF]+/,lookbehind:!0},dom:{pattern:/\b(?:document|(?:local|session)Storage|location|navigator|performance|window)\b/,alias:"variable"},console:{pattern:/\bconsole(?=\s*\.)/,alias:"class-name"}});for(var a=["function","function-variable","method","method-variable","property-access"],l=0;l<a.length;l++){var s=a[l],o=e.languages.javascript[s],s=(o=e.util.type(o)==="RegExp"?e.languages.javascript[s]={pattern:o}:o).inside||{};(o.inside=s)["maybe-class-name"]=/^[A-Z][\s\S]*/}})(fe),(function(e){var r=e.util.clone(e.languages.javascript),a=/(?:\s|\/\/.*(?!.)|\/\*(?:[^*]|\*(?!\/))\*\/)/.source,l=/(?:\{(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])*\})/.source,o=/(?:\{<S>*\.{3}(?:[^{}]|<BRACES>)*\})/.source;function s(p,h){return p=p.replace(/<S>/g,function(){return a}).replace(/<BRACES>/g,function(){return l}).replace(/<SPREAD>/g,function(){return o}),RegExp(p,h)}o=s(o).source,e.languages.jsx=e.languages.extend("markup",r),e.languages.jsx.tag.pattern=s(/<\/?(?:[\w.:-]+(?:<S>+(?:[\w.:$-]+(?:=(?:"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*'|[^\s{'"/>=]+|<BRACES>))?|<SPREAD>))*<S>*\/?)?>/.source),e.languages.jsx.tag.inside.tag.pattern=/^<\/?[^\s>\/]*/,e.languages.jsx.tag.inside["attr-value"].pattern=/=(?!\{)(?:"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*'|[^\s'">]+)/,e.languages.jsx.tag.inside.tag.inside["class-name"]=/^[A-Z]\w*(?:\.[A-Z]\w*)*$/,e.languages.jsx.tag.inside.comment=r.comment,e.languages.insertBefore("inside","attr-name",{spread:{pattern:s(/<SPREAD>/.source),inside:e.languages.jsx}},e.languages.jsx.tag),e.languages.insertBefore("inside","special-attr",{script:{pattern:s(/=<BRACES>/.source),alias:"language-javascript",inside:{"script-punctuation":{pattern:/^=(?=\{)/,alias:"punctuation"},rest:e.languages.jsx}}},e.languages.jsx.tag);function c(p){for(var h=[],y=0;y<p.length;y++){var g=p[y],b=!1;typeof g!="string"&&(g.type==="tag"&&g.content[0]&&g.content[0].type==="tag"?g.content[0].content[0].content==="</"?0<h.length&&h[h.length-1].tagName===d(g.content[0].content[1])&&h.pop():g.content[g.content.length-1].content!=="/>"&&h.push({tagName:d(g.content[0].content[1]),openedBraces:0}):0<h.length&&g.type==="punctuation"&&g.content==="{"?h[h.length-1].openedBraces++:0<h.length&&0<h[h.length-1].openedBraces&&g.type==="punctuation"&&g.content==="}"?h[h.length-1].openedBraces--:b=!0),(b||typeof g=="string")&&0<h.length&&h[h.length-1].openedBraces===0&&(b=d(g),y<p.length-1&&(typeof p[y+1]=="string"||p[y+1].type==="plain-text")&&(b+=d(p[y+1]),p.splice(y+1,1)),0<y&&(typeof p[y-1]=="string"||p[y-1].type==="plain-text")&&(b=d(p[y-1])+b,p.splice(y-1,1),y--),p[y]=new e.Token("plain-text",b,null,b)),g.content&&typeof g.content!="string"&&c(g.content)}}var d=function(p){return p?typeof p=="string"?p:typeof p.content=="string"?p.content:p.content.map(d).join(""):""};e.hooks.add("after-tokenize",function(p){p.language!=="jsx"&&p.language!=="tsx"||c(p.tokens)})})(fe),(function(e){var r=e.util.clone(e.languages.typescript),r=(e.languages.tsx=e.languages.extend("jsx",r),delete e.languages.tsx.parameter,delete e.languages.tsx["literal-property"],e.languages.tsx.tag);r.pattern=RegExp(/(^|[^\w$]|(?=<\/))/.source+"(?:"+r.pattern.source+")",r.pattern.flags),r.lookbehind=!0})(fe),fe.languages.swift={comment:{pattern:/(^|[^\\:])(?:\/\/.*|\/\*(?:[^/*]|\/(?!\*)|\*(?!\/)|\/\*(?:[^*]|\*(?!\/))*\*\/)*\*\/)/,lookbehind:!0,greedy:!0},"string-literal":[{pattern:RegExp(/(^|[^"#])/.source+"(?:"+/"(?:\\(?:\((?:[^()]|\([^()]*\))*\)|\r\n|[^(])|[^\\\r\n"])*"/.source+"|"+/"""(?:\\(?:\((?:[^()]|\([^()]*\))*\)|[^(])|[^\\"]|"(?!""))*"""/.source+")"+/(?!["#])/.source),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\\($/,alias:"punctuation"},punctuation:/\\(?=[\r\n])/,string:/[\s\S]+/}},{pattern:RegExp(/(^|[^"#])(#+)/.source+"(?:"+/"(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|\r\n|[^#])|[^\\\r\n])*?"/.source+"|"+/"""(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|[^#])|[^\\])*?"""/.source+")\\2"),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\#+\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\#+\($/,alias:"punctuation"},string:/[\s\S]+/}}],directive:{pattern:RegExp(/#/.source+"(?:"+/(?:elseif|if)\b/.source+"(?:[ ]*"+/(?:![ \t]*)?(?:\b\w+\b(?:[ \t]*\((?:[^()]|\([^()]*\))*\))?|\((?:[^()]|\([^()]*\))*\))(?:[ \t]*(?:&&|\|\|))?/.source+")+|"+/(?:else|endif)\b/.source+")"),alias:"property",inside:{"directive-name":/^#\w+/,boolean:/\b(?:false|true)\b/,number:/\b\d+(?:\.\d+)*\b/,operator:/!|&&|\|\||[<>]=?/,punctuation:/[(),]/}},literal:{pattern:/#(?:colorLiteral|column|dsohandle|file(?:ID|Literal|Path)?|function|imageLiteral|line)\b/,alias:"constant"},"other-directive":{pattern:/#\w+\b/,alias:"property"},attribute:{pattern:/@\w+/,alias:"atrule"},"function-definition":{pattern:/(\bfunc\s+)\w+/,lookbehind:!0,alias:"function"},label:{pattern:/\b(break|continue)\s+\w+|\b[a-zA-Z_]\w*(?=\s*:\s*(?:for|repeat|while)\b)/,lookbehind:!0,alias:"important"},keyword:/\b(?:Any|Protocol|Self|Type|actor|as|assignment|associatedtype|associativity|async|await|break|case|catch|class|continue|convenience|default|defer|deinit|didSet|do|dynamic|else|enum|extension|fallthrough|fileprivate|final|for|func|get|guard|higherThan|if|import|in|indirect|infix|init|inout|internal|is|isolated|lazy|left|let|lowerThan|mutating|none|nonisolated|nonmutating|open|operator|optional|override|postfix|precedencegroup|prefix|private|protocol|public|repeat|required|rethrows|return|right|safe|self|set|some|static|struct|subscript|super|switch|throw|throws|try|typealias|unowned|unsafe|var|weak|where|while|willSet)\b/,boolean:/\b(?:false|true)\b/,nil:{pattern:/\bnil\b/,alias:"constant"},"short-argument":/\$\d+\b/,omit:{pattern:/\b_\b/,alias:"keyword"},number:/\b(?:[\d_]+(?:\.[\de_]+)?|0x[a-f0-9_]+(?:\.[a-f0-9p_]+)?|0b[01_]+|0o[0-7_]+)\b/i,"class-name":/\b[A-Z](?:[A-Z_\d]*[a-z]\w*)?\b/,function:/\b[a-z_]\w*(?=\s*\()/i,constant:/\b(?:[A-Z_]{2,}|k[A-Z][A-Za-z_]+)\b/,operator:/[-+*/%=!<>&|^~?]+|\.[.\-+*/%=!<>&|^~?]+/,punctuation:/[{}[\]();,.:\\]/},fe.languages.swift["string-literal"].forEach(function(e){e.inside.interpolation.inside=fe.languages.swift}),(function(e){e.languages.kotlin=e.languages.extend("clike",{keyword:{pattern:/(^|[^.])\b(?:abstract|actual|annotation|as|break|by|catch|class|companion|const|constructor|continue|crossinline|data|do|dynamic|else|enum|expect|external|final|finally|for|fun|get|if|import|in|infix|init|inline|inner|interface|internal|is|lateinit|noinline|null|object|open|operator|out|override|package|private|protected|public|reified|return|sealed|set|super|suspend|tailrec|this|throw|to|try|typealias|val|var|vararg|when|where|while)\b/,lookbehind:!0},function:[{pattern:/(?:`[^\r\n`]+`|\b\w+)(?=\s*\()/,greedy:!0},{pattern:/(\.)(?:`[^\r\n`]+`|\w+)(?=\s*\{)/,lookbehind:!0,greedy:!0}],number:/\b(?:0[xX][\da-fA-F]+(?:_[\da-fA-F]+)*|0[bB][01]+(?:_[01]+)*|\d+(?:_\d+)*(?:\.\d+(?:_\d+)*)?(?:[eE][+-]?\d+(?:_\d+)*)?[fFL]?)\b/,operator:/\+[+=]?|-[-=>]?|==?=?|!(?:!|==?)?|[\/*%<>]=?|[?:]:?|\.\.|&&|\|\||\b(?:and|inv|or|shl|shr|ushr|xor)\b/}),delete e.languages.kotlin["class-name"];var r={"interpolation-punctuation":{pattern:/^\$\{?|\}$/,alias:"punctuation"},expression:{pattern:/[\s\S]+/,inside:e.languages.kotlin}};e.languages.insertBefore("kotlin","string",{"string-literal":[{pattern:/"""(?:[^$]|\$(?:(?!\{)|\{[^{}]*\}))*?"""/,alias:"multiline",inside:{interpolation:{pattern:/\$(?:[a-z_]\w*|\{[^{}]*\})/i,inside:r},string:/[\s\S]+/}},{pattern:/"(?:[^"\\\r\n$]|\\.|\$(?:(?!\{)|\{[^{}]*\}))*"/,alias:"singleline",inside:{interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$(?:[a-z_]\w*|\{[^{}]*\})/i,lookbehind:!0,inside:r},string:/[\s\S]+/}}],char:{pattern:/'(?:[^'\\\r\n]|\\(?:.|u[a-fA-F0-9]{0,4}))'/,greedy:!0}}),delete e.languages.kotlin.string,e.languages.insertBefore("kotlin","keyword",{annotation:{pattern:/\B@(?:\w+:)?(?:[A-Z]\w*|\[[^\]]+\])/,alias:"builtin"}}),e.languages.insertBefore("kotlin","function",{label:{pattern:/\b\w+@|@\w+\b/,alias:"symbol"}}),e.languages.kt=e.languages.kotlin,e.languages.kts=e.languages.kotlin})(fe),fe.languages.c=fe.languages.extend("clike",{comment:{pattern:/\/\/(?:[^\r\n\\]|\\(?:\r\n?|\n|(?![\r\n])))*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"class-name":{pattern:/(\b(?:enum|struct)\s+(?:__attribute__\s*\(\([\s\S]*?\)\)\s*)?)\w+|\b[a-z]\w*_t\b/,lookbehind:!0},keyword:/\b(?:_Alignas|_Alignof|_Atomic|_Bool|_Complex|_Generic|_Imaginary|_Noreturn|_Static_assert|_Thread_local|__attribute__|asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|inline|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|typeof|union|unsigned|void|volatile|while)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:/(?:\b0x(?:[\da-f]+(?:\.[\da-f]*)?|\.[\da-f]+)(?:p[+-]?\d+)?|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[ful]{0,4}/i,operator:/>>=?|<<=?|->|([-+&|:])\1|[?:~]|[-+*/%&|^!=<>]=?/}),fe.languages.insertBefore("c","string",{char:{pattern:/'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n]){0,32}'/,greedy:!0}}),fe.languages.insertBefore("c","string",{macro:{pattern:/(^[\t ]*)#\s*[a-z](?:[^\r\n\\/]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|\\(?:\r\n|[\s\S]))*/im,lookbehind:!0,greedy:!0,alias:"property",inside:{string:[{pattern:/^(#\s*include\s*)<[^>]+>/,lookbehind:!0},fe.languages.c.string],char:fe.languages.c.char,comment:fe.languages.c.comment,"macro-name":[{pattern:/(^#\s*define\s+)\w+\b(?!\()/i,lookbehind:!0},{pattern:/(^#\s*define\s+)\w+\b(?=\()/i,lookbehind:!0,alias:"function"}],directive:{pattern:/^(#\s*)[a-z]+/,lookbehind:!0,alias:"keyword"},"directive-hash":/^#/,punctuation:/##|\\(?=[\r\n])/,expression:{pattern:/\S[\s\S]*/,inside:fe.languages.c}}}}),fe.languages.insertBefore("c","function",{constant:/\b(?:EOF|NULL|SEEK_CUR|SEEK_END|SEEK_SET|__DATE__|__FILE__|__LINE__|__TIMESTAMP__|__TIME__|__func__|stderr|stdin|stdout)\b/}),delete fe.languages.c.boolean,fe.languages.objectivec=fe.languages.extend("c",{string:{pattern:/@?"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},keyword:/\b(?:asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|in|inline|int|long|register|return|self|short|signed|sizeof|static|struct|super|switch|typedef|typeof|union|unsigned|void|volatile|while)\b|(?:@interface|@end|@implementation|@protocol|@class|@public|@protected|@private|@property|@try|@catch|@finally|@throw|@synthesize|@dynamic|@selector)\b/,operator:/-[->]?|\+\+?|!=?|<<?=?|>>?=?|==?|&&?|\|\|?|[~^%?*\/@]/}),delete fe.languages.objectivec["class-name"],fe.languages.objc=fe.languages.objectivec,fe.languages.reason=fe.languages.extend("clike",{string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^\\\r\n"])*"/,greedy:!0},"class-name":/\b[A-Z]\w*/,keyword:/\b(?:and|as|assert|begin|class|constraint|do|done|downto|else|end|exception|external|for|fun|function|functor|if|in|include|inherit|initializer|lazy|let|method|module|mutable|new|nonrec|object|of|open|or|private|rec|sig|struct|switch|then|to|try|type|val|virtual|when|while|with)\b/,operator:/\.{3}|:[:=]|\|>|->|=(?:==?|>)?|<=?|>=?|[|^?'#!~`]|[+\-*\/]\.?|\b(?:asr|land|lor|lsl|lsr|lxor|mod)\b/}),fe.languages.insertBefore("reason","class-name",{char:{pattern:/'(?:\\x[\da-f]{2}|\\o[0-3][0-7][0-7]|\\\d{3}|\\.|[^'\\\r\n])'/,greedy:!0},constructor:/\b[A-Z]\w*\b(?!\s*\.)/,label:{pattern:/\b[a-z]\w*(?=::)/,alias:"symbol"}}),delete fe.languages.reason.function,(function(e){for(var r=/\/\*(?:[^*/]|\*(?!\/)|\/(?!\*)|<self>)*\*\//.source,a=0;a<2;a++)r=r.replace(/<self>/g,function(){return r});r=r.replace(/<self>/g,function(){return/[^\s\S]/.source}),e.languages.rust={comment:[{pattern:RegExp(/(^|[^\\])/.source+r),lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/b?"(?:\\[\s\S]|[^\\"])*"|b?r(#*)"(?:[^"]|"(?!\1))*"\1/,greedy:!0},char:{pattern:/b?'(?:\\(?:x[0-7][\da-fA-F]|u\{(?:[\da-fA-F]_*){1,6}\}|.)|[^\\\r\n\t'])'/,greedy:!0},attribute:{pattern:/#!?\[(?:[^\[\]"]|"(?:\\[\s\S]|[^\\"])*")*\]/,greedy:!0,alias:"attr-name",inside:{string:null}},"closure-params":{pattern:/([=(,:]\s*|\bmove\s*)\|[^|]*\||\|[^|]*\|(?=\s*(?:\{|->))/,lookbehind:!0,greedy:!0,inside:{"closure-punctuation":{pattern:/^\||\|$/,alias:"punctuation"},rest:null}},"lifetime-annotation":{pattern:/'\w+/,alias:"symbol"},"fragment-specifier":{pattern:/(\$\w+:)[a-z]+/,lookbehind:!0,alias:"punctuation"},variable:/\$\w+/,"function-definition":{pattern:/(\bfn\s+)\w+/,lookbehind:!0,alias:"function"},"type-definition":{pattern:/(\b(?:enum|struct|trait|type|union)\s+)\w+/,lookbehind:!0,alias:"class-name"},"module-declaration":[{pattern:/(\b(?:crate|mod)\s+)[a-z][a-z_\d]*/,lookbehind:!0,alias:"namespace"},{pattern:/(\b(?:crate|self|super)\s*)::\s*[a-z][a-z_\d]*\b(?:\s*::(?:\s*[a-z][a-z_\d]*\s*::)*)?/,lookbehind:!0,alias:"namespace",inside:{punctuation:/::/}}],keyword:[/\b(?:Self|abstract|as|async|await|become|box|break|const|continue|crate|do|dyn|else|enum|extern|final|fn|for|if|impl|in|let|loop|macro|match|mod|move|mut|override|priv|pub|ref|return|self|static|struct|super|trait|try|type|typeof|union|unsafe|unsized|use|virtual|where|while|yield)\b/,/\b(?:bool|char|f(?:32|64)|[ui](?:8|16|32|64|128|size)|str)\b/],function:/\b[a-z_]\w*(?=\s*(?:::\s*<|\())/,macro:{pattern:/\b\w+!/,alias:"property"},constant:/\b[A-Z_][A-Z_\d]+\b/,"class-name":/\b[A-Z]\w*\b/,namespace:{pattern:/(?:\b[a-z][a-z_\d]*\s*::\s*)*\b[a-z][a-z_\d]*\s*::(?!\s*<)/,inside:{punctuation:/::/}},number:/\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0o[0-7](?:_?[0-7])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)(?:_?(?:f32|f64|[iu](?:8|16|32|64|size)?))?\b/,boolean:/\b(?:false|true)\b/,punctuation:/->|\.\.=|\.{1,3}|::|[{}[\];(),:]/,operator:/[-+*\/%!^]=?|=[=>]?|&[&=]?|\|[|=]?|<<?=?|>>?=?|[@?]/},e.languages.rust["closure-params"].inside.rest=e.languages.rust,e.languages.rust.attribute.inside.string=e.languages.rust.string})(fe),fe.languages.go=fe.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"|`[^`]*`/,lookbehind:!0,greedy:!0},keyword:/\b(?:break|case|chan|const|continue|default|defer|else|fallthrough|for|func|go(?:to)?|if|import|interface|map|package|range|return|select|struct|switch|type|var)\b/,boolean:/\b(?:_|false|iota|nil|true)\b/,number:[/\b0(?:b[01_]+|o[0-7_]+)i?\b/i,/\b0x(?:[a-f\d_]+(?:\.[a-f\d_]*)?|\.[a-f\d_]+)(?:p[+-]?\d+(?:_\d+)*)?i?(?!\w)/i,/(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?[\d_]+)?i?(?!\w)/i],operator:/[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\./,builtin:/\b(?:append|bool|byte|cap|close|complex|complex(?:64|128)|copy|delete|error|float(?:32|64)|u?int(?:8|16|32|64)?|imag|len|make|new|panic|print(?:ln)?|real|recover|rune|string|uintptr)\b/}),fe.languages.insertBefore("go","string",{char:{pattern:/'(?:\\.|[^'\\\r\n]){0,10}'/,greedy:!0}}),delete fe.languages.go["class-name"],(function(e){var r=/\b(?:alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|char8_t|class|co_await|co_return|co_yield|compl|concept|const|const_cast|consteval|constexpr|constinit|continue|decltype|default|delete|do|double|dynamic_cast|else|enum|explicit|export|extern|final|float|for|friend|goto|if|import|inline|int|int16_t|int32_t|int64_t|int8_t|long|module|mutable|namespace|new|noexcept|nullptr|operator|override|private|protected|public|register|reinterpret_cast|requires|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|uint16_t|uint32_t|uint64_t|uint8_t|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/,a=/\b(?!<keyword>)\w+(?:\s*\.\s*\w+)*\b/.source.replace(/<keyword>/g,function(){return r.source});e.languages.cpp=e.languages.extend("c",{"class-name":[{pattern:RegExp(/(\b(?:class|concept|enum|struct|typename)\s+)(?!<keyword>)\w+/.source.replace(/<keyword>/g,function(){return r.source})),lookbehind:!0},/\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/,/\b[A-Z_]\w*(?=\s*::\s*~\w+\s*\()/i,/\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/],keyword:r,number:{pattern:/(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,greedy:!0},operator:/>>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,boolean:/\b(?:false|true)\b/}),e.languages.insertBefore("cpp","string",{module:{pattern:RegExp(/(\b(?:import|module)\s+)/.source+"(?:"+/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|<[^<>\r\n]*>/.source+"|"+/<mod-name>(?:\s*:\s*<mod-name>)?|:\s*<mod-name>/.source.replace(/<mod-name>/g,function(){return a})+")"),lookbehind:!0,greedy:!0,inside:{string:/^[<"][\s\S]+/,operator:/:/,punctuation:/\./}},"raw-string":{pattern:/R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,alias:"string",greedy:!0}}),e.languages.insertBefore("cpp","keyword",{"generic-function":{pattern:/\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,inside:{function:/^\w+/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:e.languages.cpp}}}}),e.languages.insertBefore("cpp","operator",{"double-colon":{pattern:/::/,alias:"punctuation"}}),e.languages.insertBefore("cpp","class-name",{"base-clause":{pattern:/(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,lookbehind:!0,greedy:!0,inside:e.languages.extend("cpp",{})}}),e.languages.insertBefore("inside","double-colon",{"class-name":/\b[a-z_]\w*\b(?!\s*::)/i},e.languages.cpp["base-clause"])})(fe),fe.languages.python={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},"string-interpolation":{pattern:/(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,lookbehind:!0,inside:{"format-spec":{pattern:/(:)[^:(){}]+(?=\}$)/,lookbehind:!0},"conversion-option":{pattern:/![sra](?=[:}]$)/,alias:"punctuation"},rest:null}},string:/[\s\S]+/}},"triple-quoted-string":{pattern:/(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,greedy:!0,alias:"string"},string:{pattern:/(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,greedy:!0},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,lookbehind:!0},"class-name":{pattern:/(\bclass\s+)\w+/i,lookbehind:!0},decorator:{pattern:/(^[\t ]*)@\w+(?:\.\w+)*/m,lookbehind:!0,alias:["annotation","punctuation"],inside:{punctuation:/\./}},keyword:/\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,builtin:/\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,boolean:/\b(?:False|None|True)\b/,number:/\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,operator:/[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},fe.languages.python["string-interpolation"].inside.interpolation.inside.rest=fe.languages.python,fe.languages.py=fe.languages.python,fe.languages.json={property:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?=\s*:)/,lookbehind:!0,greedy:!0},string:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?!\s*:)/,lookbehind:!0,greedy:!0},comment:{pattern:/\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},number:/-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,punctuation:/[{}[\],]/,operator:/:/,boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:"keyword"}},fe.languages.webmanifest=fe.languages.json;var pd={};i3(pd,{dracula:()=>d3,duotoneDark:()=>p3,duotoneLight:()=>m3,github:()=>y3,gruvboxMaterialDark:()=>G3,gruvboxMaterialLight:()=>X3,jettwaveDark:()=>B3,jettwaveLight:()=>F3,nightOwl:()=>b3,nightOwlLight:()=>w3,oceanicNext:()=>k3,okaidia:()=>C3,oneDark:()=>H3,oneLight:()=>$3,palenight:()=>N3,shadesOfPurple:()=>T3,synthwave84:()=>R3,ultramin:()=>O3,vsDark:()=>gE,vsLight:()=>L3});var c3={plain:{color:"#F8F8F2",backgroundColor:"#282A36"},styles:[{types:["prolog","constant","builtin"],style:{color:"rgb(189, 147, 249)"}},{types:["inserted","function"],style:{color:"rgb(80, 250, 123)"}},{types:["deleted"],style:{color:"rgb(255, 85, 85)"}},{types:["changed"],style:{color:"rgb(255, 184, 108)"}},{types:["punctuation","symbol"],style:{color:"rgb(248, 248, 242)"}},{types:["string","char","tag","selector"],style:{color:"rgb(255, 121, 198)"}},{types:["keyword","variable"],style:{color:"rgb(189, 147, 249)",fontStyle:"italic"}},{types:["comment"],style:{color:"rgb(98, 114, 164)"}},{types:["attr-name"],style:{color:"rgb(241, 250, 140)"}}]},d3=c3,f3={plain:{backgroundColor:"#2a2734",color:"#9a86fd"},styles:[{types:["comment","prolog","doctype","cdata","punctuation"],style:{color:"#6c6783"}},{types:["namespace"],style:{opacity:.7}},{types:["tag","operator","number"],style:{color:"#e09142"}},{types:["property","function"],style:{color:"#9a86fd"}},{types:["tag-id","selector","atrule-id"],style:{color:"#eeebff"}},{types:["attr-name"],style:{color:"#c4b9fe"}},{types:["boolean","string","entity","url","attr-value","keyword","control","directive","unit","statement","regex","atrule","placeholder","variable"],style:{color:"#ffcc99"}},{types:["deleted"],style:{textDecorationLine:"line-through"}},{types:["inserted"],style:{textDecorationLine:"underline"}},{types:["italic"],style:{fontStyle:"italic"}},{types:["important","bold"],style:{fontWeight:"bold"}},{types:["important"],style:{color:"#c4b9fe"}}]},p3=f3,h3={plain:{backgroundColor:"#faf8f5",color:"#728fcb"},styles:[{types:["comment","prolog","doctype","cdata","punctuation"],style:{color:"#b6ad9a"}},{types:["namespace"],style:{opacity:.7}},{types:["tag","operator","number"],style:{color:"#063289"}},{types:["property","function"],style:{color:"#b29762"}},{types:["tag-id","selector","atrule-id"],style:{color:"#2d2006"}},{types:["attr-name"],style:{color:"#896724"}},{types:["boolean","string","entity","url","attr-value","keyword","control","directive","unit","statement","regex","atrule"],style:{color:"#728fcb"}},{types:["placeholder","variable"],style:{color:"#93abdc"}},{types:["deleted"],style:{textDecorationLine:"line-through"}},{types:["inserted"],style:{textDecorationLine:"underline"}},{types:["italic"],style:{fontStyle:"italic"}},{types:["important","bold"],style:{fontWeight:"bold"}},{types:["important"],style:{color:"#896724"}}]},m3=h3,g3={plain:{color:"#393A34",backgroundColor:"#f6f8fa"},styles:[{types:["comment","prolog","doctype","cdata"],style:{color:"#999988",fontStyle:"italic"}},{types:["namespace"],style:{opacity:.7}},{types:["string","attr-value"],style:{color:"#e3116c"}},{types:["punctuation","operator"],style:{color:"#393A34"}},{types:["entity","url","symbol","number","boolean","variable","constant","property","regex","inserted"],style:{color:"#36acaa"}},{types:["atrule","keyword","attr-name","selector"],style:{color:"#00a4db"}},{types:["function","deleted","tag"],style:{color:"#d73a49"}},{types:["function-variable"],style:{color:"#6f42c1"}},{types:["tag","selector","keyword"],style:{color:"#00009f"}}]},y3=g3,x3={plain:{color:"#d6deeb",backgroundColor:"#011627"},styles:[{types:["changed"],style:{color:"rgb(162, 191, 252)",fontStyle:"italic"}},{types:["deleted"],style:{color:"rgba(239, 83, 80, 0.56)",fontStyle:"italic"}},{types:["inserted","attr-name"],style:{color:"rgb(173, 219, 103)",fontStyle:"italic"}},{types:["comment"],style:{color:"rgb(99, 119, 119)",fontStyle:"italic"}},{types:["string","url"],style:{color:"rgb(173, 219, 103)"}},{types:["variable"],style:{color:"rgb(214, 222, 235)"}},{types:["number"],style:{color:"rgb(247, 140, 108)"}},{types:["builtin","char","constant","function"],style:{color:"rgb(130, 170, 255)"}},{types:["punctuation"],style:{color:"rgb(199, 146, 234)"}},{types:["selector","doctype"],style:{color:"rgb(199, 146, 234)",fontStyle:"italic"}},{types:["class-name"],style:{color:"rgb(255, 203, 139)"}},{types:["tag","operator","keyword"],style:{color:"rgb(127, 219, 202)"}},{types:["boolean"],style:{color:"rgb(255, 88, 116)"}},{types:["property"],style:{color:"rgb(128, 203, 196)"}},{types:["namespace"],style:{color:"rgb(178, 204, 214)"}}]},b3=x3,v3={plain:{color:"#403f53",backgroundColor:"#FBFBFB"},styles:[{types:["changed"],style:{color:"rgb(162, 191, 252)",fontStyle:"italic"}},{types:["deleted"],style:{color:"rgba(239, 83, 80, 0.56)",fontStyle:"italic"}},{types:["inserted","attr-name"],style:{color:"rgb(72, 118, 214)",fontStyle:"italic"}},{types:["comment"],style:{color:"rgb(152, 159, 177)",fontStyle:"italic"}},{types:["string","builtin","char","constant","url"],style:{color:"rgb(72, 118, 214)"}},{types:["variable"],style:{color:"rgb(201, 103, 101)"}},{types:["number"],style:{color:"rgb(170, 9, 130)"}},{types:["punctuation"],style:{color:"rgb(153, 76, 195)"}},{types:["function","selector","doctype"],style:{color:"rgb(153, 76, 195)",fontStyle:"italic"}},{types:["class-name"],style:{color:"rgb(17, 17, 17)"}},{types:["tag"],style:{color:"rgb(153, 76, 195)"}},{types:["operator","property","keyword","namespace"],style:{color:"rgb(12, 150, 155)"}},{types:["boolean"],style:{color:"rgb(188, 84, 84)"}}]},w3=v3,En={char:"#D8DEE9",comment:"#999999",keyword:"#c5a5c5",primitive:"#5a9bcf",string:"#8dc891",variable:"#d7deea",boolean:"#ff8b50",tag:"#fc929e",function:"#79b6f2",className:"#FAC863"},S3={plain:{backgroundColor:"#282c34",color:"#ffffff"},styles:[{types:["attr-name"],style:{color:En.keyword}},{types:["attr-value"],style:{color:En.string}},{types:["comment","block-comment","prolog","doctype","cdata","shebang"],style:{color:En.comment}},{types:["property","number","function-name","constant","symbol","deleted"],style:{color:En.primitive}},{types:["boolean"],style:{color:En.boolean}},{types:["tag"],style:{color:En.tag}},{types:["string"],style:{color:En.string}},{types:["punctuation"],style:{color:En.string}},{types:["selector","char","builtin","inserted"],style:{color:En.char}},{types:["function"],style:{color:En.function}},{types:["operator","entity","url","variable"],style:{color:En.variable}},{types:["keyword"],style:{color:En.keyword}},{types:["atrule","class-name"],style:{color:En.className}},{types:["important"],style:{fontWeight:"400"}},{types:["bold"],style:{fontWeight:"bold"}},{types:["italic"],style:{fontStyle:"italic"}},{types:["namespace"],style:{opacity:.7}}]},k3=S3,E3={plain:{color:"#f8f8f2",backgroundColor:"#272822"},styles:[{types:["changed"],style:{color:"rgb(162, 191, 252)",fontStyle:"italic"}},{types:["deleted"],style:{color:"#f92672",fontStyle:"italic"}},{types:["inserted"],style:{color:"rgb(173, 219, 103)",fontStyle:"italic"}},{types:["comment"],style:{color:"#8292a2",fontStyle:"italic"}},{types:["string","url"],style:{color:"#a6e22e"}},{types:["variable"],style:{color:"#f8f8f2"}},{types:["number"],style:{color:"#ae81ff"}},{types:["builtin","char","constant","function","class-name"],style:{color:"#e6db74"}},{types:["punctuation"],style:{color:"#f8f8f2"}},{types:["selector","doctype"],style:{color:"#a6e22e",fontStyle:"italic"}},{types:["tag","operator","keyword"],style:{color:"#66d9ef"}},{types:["boolean"],style:{color:"#ae81ff"}},{types:["namespace"],style:{color:"rgb(178, 204, 214)",opacity:.7}},{types:["tag","property"],style:{color:"#f92672"}},{types:["attr-name"],style:{color:"#a6e22e !important"}},{types:["doctype"],style:{color:"#8292a2"}},{types:["rule"],style:{color:"#e6db74"}}]},C3=E3,A3={plain:{color:"#bfc7d5",backgroundColor:"#292d3e"},styles:[{types:["comment"],style:{color:"rgb(105, 112, 152)",fontStyle:"italic"}},{types:["string","inserted"],style:{color:"rgb(195, 232, 141)"}},{types:["number"],style:{color:"rgb(247, 140, 108)"}},{types:["builtin","char","constant","function"],style:{color:"rgb(130, 170, 255)"}},{types:["punctuation","selector"],style:{color:"rgb(199, 146, 234)"}},{types:["variable"],style:{color:"rgb(191, 199, 213)"}},{types:["class-name","attr-name"],style:{color:"rgb(255, 203, 107)"}},{types:["tag","deleted"],style:{color:"rgb(255, 85, 114)"}},{types:["operator"],style:{color:"rgb(137, 221, 255)"}},{types:["boolean"],style:{color:"rgb(255, 88, 116)"}},{types:["keyword"],style:{fontStyle:"italic"}},{types:["doctype"],style:{color:"rgb(199, 146, 234)",fontStyle:"italic"}},{types:["namespace"],style:{color:"rgb(178, 204, 214)"}},{types:["url"],style:{color:"rgb(221, 221, 221)"}}]},N3=A3,j3={plain:{color:"#9EFEFF",backgroundColor:"#2D2A55"},styles:[{types:["changed"],style:{color:"rgb(255, 238, 128)"}},{types:["deleted"],style:{color:"rgba(239, 83, 80, 0.56)"}},{types:["inserted"],style:{color:"rgb(173, 219, 103)"}},{types:["comment"],style:{color:"rgb(179, 98, 255)",fontStyle:"italic"}},{types:["punctuation"],style:{color:"rgb(255, 255, 255)"}},{types:["constant"],style:{color:"rgb(255, 98, 140)"}},{types:["string","url"],style:{color:"rgb(165, 255, 144)"}},{types:["variable"],style:{color:"rgb(255, 238, 128)"}},{types:["number","boolean"],style:{color:"rgb(255, 98, 140)"}},{types:["attr-name"],style:{color:"rgb(255, 180, 84)"}},{types:["keyword","operator","property","namespace","tag","selector","doctype"],style:{color:"rgb(255, 157, 0)"}},{types:["builtin","char","constant","function","class-name"],style:{color:"rgb(250, 208, 0)"}}]},T3=j3,_3={plain:{backgroundColor:"linear-gradient(to bottom, #2a2139 75%, #34294f)",backgroundImage:"#34294f",color:"#f92aad",textShadow:"0 0 2px #100c0f, 0 0 5px #dc078e33, 0 0 10px #fff3"},styles:[{types:["comment","block-comment","prolog","doctype","cdata"],style:{color:"#495495",fontStyle:"italic"}},{types:["punctuation"],style:{color:"#ccc"}},{types:["tag","attr-name","namespace","number","unit","hexcode","deleted"],style:{color:"#e2777a"}},{types:["property","selector"],style:{color:"#72f1b8",textShadow:"0 0 2px #100c0f, 0 0 10px #257c5575, 0 0 35px #21272475"}},{types:["function-name"],style:{color:"#6196cc"}},{types:["boolean","selector-id","function"],style:{color:"#fdfdfd",textShadow:"0 0 2px #001716, 0 0 3px #03edf975, 0 0 5px #03edf975, 0 0 8px #03edf975"}},{types:["class-name","maybe-class-name","builtin"],style:{color:"#fff5f6",textShadow:"0 0 2px #000, 0 0 10px #fc1f2c75, 0 0 5px #fc1f2c75, 0 0 25px #fc1f2c75"}},{types:["constant","symbol"],style:{color:"#f92aad",textShadow:"0 0 2px #100c0f, 0 0 5px #dc078e33, 0 0 10px #fff3"}},{types:["important","atrule","keyword","selector-class"],style:{color:"#f4eee4",textShadow:"0 0 2px #393a33, 0 0 8px #f39f0575, 0 0 2px #f39f0575"}},{types:["string","char","attr-value","regex","variable"],style:{color:"#f87c32"}},{types:["parameter"],style:{fontStyle:"italic"}},{types:["entity","url"],style:{color:"#67cdcc"}},{types:["operator"],style:{color:"ffffffee"}},{types:["important","bold"],style:{fontWeight:"bold"}},{types:["italic"],style:{fontStyle:"italic"}},{types:["entity"],style:{cursor:"help"}},{types:["inserted"],style:{color:"green"}}]},R3=_3,M3={plain:{color:"#282a2e",backgroundColor:"#ffffff"},styles:[{types:["comment"],style:{color:"rgb(197, 200, 198)"}},{types:["string","number","builtin","variable"],style:{color:"rgb(150, 152, 150)"}},{types:["class-name","function","tag","attr-name"],style:{color:"rgb(40, 42, 46)"}}]},O3=M3,D3={plain:{color:"#9CDCFE",backgroundColor:"#1E1E1E"},styles:[{types:["prolog"],style:{color:"rgb(0, 0, 128)"}},{types:["comment"],style:{color:"rgb(106, 153, 85)"}},{types:["builtin","changed","keyword","interpolation-punctuation"],style:{color:"rgb(86, 156, 214)"}},{types:["number","inserted"],style:{color:"rgb(181, 206, 168)"}},{types:["constant"],style:{color:"rgb(100, 102, 149)"}},{types:["attr-name","variable"],style:{color:"rgb(156, 220, 254)"}},{types:["deleted","string","attr-value","template-punctuation"],style:{color:"rgb(206, 145, 120)"}},{types:["selector"],style:{color:"rgb(215, 186, 125)"}},{types:["tag"],style:{color:"rgb(78, 201, 176)"}},{types:["tag"],languages:["markup"],style:{color:"rgb(86, 156, 214)"}},{types:["punctuation","operator"],style:{color:"rgb(212, 212, 212)"}},{types:["punctuation"],languages:["markup"],style:{color:"#808080"}},{types:["function"],style:{color:"rgb(220, 220, 170)"}},{types:["class-name"],style:{color:"rgb(78, 201, 176)"}},{types:["char"],style:{color:"rgb(209, 105, 105)"}}]},gE=D3,z3={plain:{color:"#000000",backgroundColor:"#ffffff"},styles:[{types:["comment"],style:{color:"rgb(0, 128, 0)"}},{types:["builtin"],style:{color:"rgb(0, 112, 193)"}},{types:["number","variable","inserted"],style:{color:"rgb(9, 134, 88)"}},{types:["operator"],style:{color:"rgb(0, 0, 0)"}},{types:["constant","char"],style:{color:"rgb(129, 31, 63)"}},{types:["tag"],style:{color:"rgb(128, 0, 0)"}},{types:["attr-name"],style:{color:"rgb(255, 0, 0)"}},{types:["deleted","string"],style:{color:"rgb(163, 21, 21)"}},{types:["changed","punctuation"],style:{color:"rgb(4, 81, 165)"}},{types:["function","keyword"],style:{color:"rgb(0, 0, 255)"}},{types:["class-name"],style:{color:"rgb(38, 127, 153)"}}]},L3=z3,I3={plain:{color:"#f8fafc",backgroundColor:"#011627"},styles:[{types:["prolog"],style:{color:"#000080"}},{types:["comment"],style:{color:"#6A9955"}},{types:["builtin","changed","keyword","interpolation-punctuation"],style:{color:"#569CD6"}},{types:["number","inserted"],style:{color:"#B5CEA8"}},{types:["constant"],style:{color:"#f8fafc"}},{types:["attr-name","variable"],style:{color:"#9CDCFE"}},{types:["deleted","string","attr-value","template-punctuation"],style:{color:"#cbd5e1"}},{types:["selector"],style:{color:"#D7BA7D"}},{types:["tag"],style:{color:"#0ea5e9"}},{types:["tag"],languages:["markup"],style:{color:"#0ea5e9"}},{types:["punctuation","operator"],style:{color:"#D4D4D4"}},{types:["punctuation"],languages:["markup"],style:{color:"#808080"}},{types:["function"],style:{color:"#7dd3fc"}},{types:["class-name"],style:{color:"#0ea5e9"}},{types:["char"],style:{color:"#D16969"}}]},B3=I3,P3={plain:{color:"#0f172a",backgroundColor:"#f1f5f9"},styles:[{types:["prolog"],style:{color:"#000080"}},{types:["comment"],style:{color:"#6A9955"}},{types:["builtin","changed","keyword","interpolation-punctuation"],style:{color:"#0c4a6e"}},{types:["number","inserted"],style:{color:"#B5CEA8"}},{types:["constant"],style:{color:"#0f172a"}},{types:["attr-name","variable"],style:{color:"#0c4a6e"}},{types:["deleted","string","attr-value","template-punctuation"],style:{color:"#64748b"}},{types:["selector"],style:{color:"#D7BA7D"}},{types:["tag"],style:{color:"#0ea5e9"}},{types:["tag"],languages:["markup"],style:{color:"#0ea5e9"}},{types:["punctuation","operator"],style:{color:"#475569"}},{types:["punctuation"],languages:["markup"],style:{color:"#808080"}},{types:["function"],style:{color:"#0e7490"}},{types:["class-name"],style:{color:"#0ea5e9"}},{types:["char"],style:{color:"#D16969"}}]},F3=P3,U3={plain:{backgroundColor:"hsl(220, 13%, 18%)",color:"hsl(220, 14%, 71%)",textShadow:"0 1px rgba(0, 0, 0, 0.3)"},styles:[{types:["comment","prolog","cdata"],style:{color:"hsl(220, 10%, 40%)"}},{types:["doctype","punctuation","entity"],style:{color:"hsl(220, 14%, 71%)"}},{types:["attr-name","class-name","maybe-class-name","boolean","constant","number","atrule"],style:{color:"hsl(29, 54%, 61%)"}},{types:["keyword"],style:{color:"hsl(286, 60%, 67%)"}},{types:["property","tag","symbol","deleted","important"],style:{color:"hsl(355, 65%, 65%)"}},{types:["selector","string","char","builtin","inserted","regex","attr-value"],style:{color:"hsl(95, 38%, 62%)"}},{types:["variable","operator","function"],style:{color:"hsl(207, 82%, 66%)"}},{types:["url"],style:{color:"hsl(187, 47%, 55%)"}},{types:["deleted"],style:{textDecorationLine:"line-through"}},{types:["inserted"],style:{textDecorationLine:"underline"}},{types:["italic"],style:{fontStyle:"italic"}},{types:["important","bold"],style:{fontWeight:"bold"}},{types:["important"],style:{color:"hsl(220, 14%, 71%)"}}]},H3=U3,V3={plain:{backgroundColor:"hsl(230, 1%, 98%)",color:"hsl(230, 8%, 24%)"},styles:[{types:["comment","prolog","cdata"],style:{color:"hsl(230, 4%, 64%)"}},{types:["doctype","punctuation","entity"],style:{color:"hsl(230, 8%, 24%)"}},{types:["attr-name","class-name","boolean","constant","number","atrule"],style:{color:"hsl(35, 99%, 36%)"}},{types:["keyword"],style:{color:"hsl(301, 63%, 40%)"}},{types:["property","tag","symbol","deleted","important"],style:{color:"hsl(5, 74%, 59%)"}},{types:["selector","string","char","builtin","inserted","regex","attr-value","punctuation"],style:{color:"hsl(119, 34%, 47%)"}},{types:["variable","operator","function"],style:{color:"hsl(221, 87%, 60%)"}},{types:["url"],style:{color:"hsl(198, 99%, 37%)"}},{types:["deleted"],style:{textDecorationLine:"line-through"}},{types:["inserted"],style:{textDecorationLine:"underline"}},{types:["italic"],style:{fontStyle:"italic"}},{types:["important","bold"],style:{fontWeight:"bold"}},{types:["important"],style:{color:"hsl(230, 8%, 24%)"}}]},$3=V3,q3={plain:{color:"#ebdbb2",backgroundColor:"#292828"},styles:[{types:["imports","class-name","maybe-class-name","constant","doctype","builtin","function"],style:{color:"#d8a657"}},{types:["property-access"],style:{color:"#7daea3"}},{types:["tag"],style:{color:"#e78a4e"}},{types:["attr-name","char","url","regex"],style:{color:"#a9b665"}},{types:["attr-value","string"],style:{color:"#89b482"}},{types:["comment","prolog","cdata","operator","inserted"],style:{color:"#a89984"}},{types:["delimiter","boolean","keyword","selector","important","atrule","property","variable","deleted"],style:{color:"#ea6962"}},{types:["entity","number","symbol"],style:{color:"#d3869b"}}]},G3=q3,Y3={plain:{color:"#654735",backgroundColor:"#f9f5d7"},styles:[{types:["delimiter","boolean","keyword","selector","important","atrule","property","variable","deleted"],style:{color:"#af2528"}},{types:["imports","class-name","maybe-class-name","constant","doctype","builtin"],style:{color:"#b4730e"}},{types:["string","attr-value"],style:{color:"#477a5b"}},{types:["property-access"],style:{color:"#266b79"}},{types:["function","attr-name","char","url"],style:{color:"#72761e"}},{types:["tag"],style:{color:"#b94c07"}},{types:["comment","prolog","cdata","operator","inserted"],style:{color:"#a89984"}},{types:["entity","number","symbol"],style:{color:"#924f79"}}]},X3=Y3,K3=e=>v.useCallback(r=>{var a=r,{className:l,style:o,line:s}=a,c=mE(a,["className","style","line"]);const d=fd(mr({},c),{className:Dc("token-line",l)});return typeof e=="object"&&"plain"in e&&(d.style=e.plain),typeof o=="object"&&(d.style=mr(mr({},d.style||{}),o)),d},[e]),Q3=e=>{const r=v.useCallback(({types:a,empty:l})=>{if(e!=null){{if(a.length===1&&a[0]==="plain")return l!=null?{display:"inline-block"}:void 0;if(a.length===1&&l!=null)return e[a[0]]}return Object.assign(l!=null?{display:"inline-block"}:{},...a.map(o=>e[o]))}},[e]);return v.useCallback(a=>{var l=a,{token:o,className:s,style:c}=l,d=mE(l,["token","className","style"]);const p=fd(mr({},d),{className:Dc("token",...o.types,s),children:o.content,style:r(o)});return c!=null&&(p.style=mr(mr({},p.style||{}),c)),p},[r])},Z3=/\r\n|\r|\n/,h0=e=>{e.length===0?e.push({types:["plain"],content:`
404
- `,empty:!0}):e.length===1&&e[0].content===""&&(e[0].content=`
405
- `,e[0].empty=!0)},m0=(e,r)=>{const a=e.length;return a>0&&e[a-1]===r?e:e.concat(r)},W3=e=>{const r=[[]],a=[e],l=[0],o=[e.length];let s=0,c=0,d=[];const p=[d];for(;c>-1;){for(;(s=l[c]++)<o[c];){let h,y=r[c];const b=a[c][s];if(typeof b=="string"?(y=c>0?y:["plain"],h=b):(y=m0(y,b.type),b.alias&&(y=m0(y,b.alias)),h=b.content),typeof h!="string"){c++,r.push(y),a.push(h),l.push(0),o.push(h.length);continue}const w=h.split(Z3),k=w.length;d.push({types:y,content:w[0]});for(let S=1;S<k;S++)h0(d),p.push(d=[]),d.push({types:y,content:w[S]})}c--,r.pop(),a.pop(),l.pop(),o.pop()}return h0(d),p},g0=W3,J3=({prism:e,code:r,grammar:a,language:l})=>v.useMemo(()=>{if(a==null)return g0([r]);const o={code:r,grammar:a,language:l,tokens:[]};return e.hooks.run("before-tokenize",o),o.tokens=e.tokenize(r,a),e.hooks.run("after-tokenize",o),g0(o.tokens)},[r,a,l,e]),e5=(e,r)=>{const{plain:a}=e,l=e.styles.reduce((o,s)=>{const{languages:c,style:d}=s;return c&&!c.includes(r)||s.types.forEach(p=>{const h=mr(mr({},o[p]),d);o[p]=h}),o},{});return l.root=a,l.plain=fd(mr({},a),{backgroundColor:void 0}),l},t5=e5,n5=({children:e,language:r,code:a,theme:l,prism:o})=>{const s=r.toLowerCase(),c=t5(l,s),d=K3(c),p=Q3(c),h=o.languages[s],y=J3({prism:o,language:s,code:a,grammar:h});return e({tokens:y,className:`prism-code language-${s}`,style:c!=null?c.root:{},getLineProps:d,getTokenProps:p})},Jm=e=>v.createElement(n5,fd(mr({},e),{prism:e.prism||fe,theme:e.theme||gE,code:e.code,language:e.language}));/*! Bundled license information:
406
-
407
- prismjs/prism.js:
408
- (**
409
- * Prism: Lightweight, robust, elegant syntax highlighting
410
- *
411
- * @license MIT <https://opensource.org/licenses/MIT>
412
- * @author Lea Verou <https://lea.verou.me>
413
- * @namespace
414
- * @public
415
- *)
416
- */function r5(e){var l;const r=(l=e.split(".").pop())==null?void 0:l.toLowerCase();return{ts:"typescript",tsx:"typescript",js:"javascript",jsx:"javascript",json:"json",md:"markdown",css:"css",html:"html",py:"python",go:"go",rs:"rust",sh:"bash",yaml:"yaml",yml:"yaml"}[r||""]||r||"text"}function a5({type:e,content:r,lineNumber:a,newLineNumber:l,language:o}){const s=ye("flex font-mono text-xs",e==="added"&&"bg-green-500/20",e==="removed"&&"bg-red-500/20",e==="context"&&"bg-muted/30"),c=ye("font-bold w-4 select-none",e==="added"&&"text-green-400",e==="removed"&&"text-red-400",e==="context"&&"text-muted-foreground/50");return f.jsxs("div",{className:s,children:[f.jsx("span",{className:"w-10 text-right pr-2 text-muted-foreground select-none border-r border-white/10",children:a!=null?a:""}),f.jsx("span",{className:"w-10 text-right pr-2 text-muted-foreground select-none border-r border-white/10",children:l!=null?l:""}),f.jsxs("span",{className:"pl-2 flex-1 whitespace-pre flex",children:[f.jsxs("span",{className:c,children:[e==="added"&&"+",e==="removed"&&"-",e==="context"&&" "]}),f.jsx(Jm,{theme:pd.oneDark,code:r,language:o,children:({tokens:d,getTokenProps:p})=>f.jsx(f.Fragment,{children:d.map((h,y)=>f.jsx("span",{children:h.map((g,b)=>f.jsx("span",{...p({token:g})},b))},y))})})]})]})}function y0({hunks:e,path:r,language:a,additions:l,deletions:o}){const[s,c]=v.useState(!0),d=a||r5(r);return f.jsx("div",{className:"visualization-container overflow-x-auto border border-white/10 rounded-md",children:f.jsxs("div",{style:{minWidth:"max-content"},children:[f.jsxs("div",{className:"flex items-center gap-2 px-1 bg-muted/50 text-xs text-muted-foreground",children:[f.jsx("button",{onClick:()=>c(!s),className:"px-1 py-1 hover:bg-muted rounded",children:s?f.jsx(ns,{className:"size-3"}):f.jsx(cl,{className:"size-3"})}),f.jsx(em,{className:"size-3"}),f.jsx("span",{className:"font-mono pr-2",children:r}),l!==void 0&&o!==void 0&&f.jsxs("span",{className:"ml-auto mr-2 text-muted-foreground",children:["+",l," -",o]})]}),s&&f.jsx("div",{style:{backgroundColor:"#282c34"},children:e.map((p,h)=>f.jsx("div",{className:"divide-y divide-white/5",children:p.changes.map((y,g)=>f.jsx(a5,{...y,language:d},g))},h))})]})})}function l5(e){var l;const r=(l=e.split(".").pop())==null?void 0:l.toLowerCase();return{ts:"typescript",tsx:"typescript",js:"javascript",jsx:"javascript",json:"json",md:"markdown",css:"css",html:"html",py:"python",go:"go",rs:"rust",sh:"bash",yaml:"yaml",yml:"yaml"}[r||""]||r||"text"}const i5=({content:e,path:r,language:a,created:l,highlightLines:o=[]})=>{const[s,c]=v.useState(!0),d=a||l5(r),p=new Set(o);return f.jsx("div",{className:"visualization-container overflow-x-auto border border-white/10 rounded-md",children:f.jsxs("div",{style:{minWidth:"max-content"},children:[f.jsxs("div",{className:"flex items-center gap-2 px-1 bg-muted/50 text-xs text-muted-foreground",children:[f.jsx("button",{onClick:()=>c(!s),className:"flex items-center gap-2 px-2 py-1 hover:bg-muted",children:s?f.jsx(ns,{className:"size-3"}):f.jsx(cl,{className:"size-3"})}),f.jsx(em,{className:"size-3"}),f.jsx("span",{className:"font-mono pr-2",children:r}),l===!1?f.jsxs("span",{className:"flex items-center gap-1 text-warning ml-auto mr-2",children:[f.jsx(Bo,{className:"size-3"}),"Overwrote"]}):f.jsxs("span",{className:"flex items-center gap-1 text-success ml-auto mr-2",children:[f.jsx(Vr,{className:"size-3"}),"Created"]})]}),s&&f.jsx("div",{style:{backgroundColor:"#282c34"},children:f.jsx(Jm,{theme:pd.oneDark,code:e,language:d,children:({tokens:h,getTokenProps:y})=>f.jsx(f.Fragment,{children:h.map((g,b)=>f.jsxs("div",{className:`flex font-mono text-xs ${p.has(b+1)?"bg-yellow-500/20":""}`,children:[f.jsx("span",{className:"w-10 text-right pr-2 text-muted-foreground select-none border-r border-white/10",children:b+1}),f.jsx("span",{className:"pl-2 flex-1 whitespace-pre",children:g.map((w,k)=>f.jsx("span",{...y({token:w})},k))})]},b))})})})]})})};function o5({message:e="Success"}){return f.jsxs("div",{className:"flex items-center gap-2 text-sm text-muted-foreground",children:[f.jsx(rs,{className:"size-4"}),f.jsx("span",{children:e})]})}const s5={edit:CN,plus:Oc,trash:as,search:tm};function u5({text:e}){const[r,a]=v.useState(!1),l=async()=>{await navigator.clipboard.writeText(e),a(!0),setTimeout(()=>a(!1),1500)};return f.jsx("button",{onClick:l,className:"text-muted-foreground hover:text-foreground transition-colors",title:"Copy path",children:r?f.jsx("span",{className:"text-success text-xs",children:"Copied!"}):f.jsx(cc,{className:"size-3"})})}function c5({title:e,groups:r,files:a,total:l}){const s=r||(a?[{label:"Files",files:a||[],icon:void 0}]:[]);return s.length===0?null:f.jsxs("div",{className:"flex flex-col gap-3",children:[e&&f.jsxs("div",{className:"text-sm font-medium text-foreground",children:[e,l!==void 0&&f.jsxs("span",{className:"ml-2 text-muted-foreground",children:["(",l," files)"]})]}),s.map((c,d)=>f.jsxs("div",{className:"flex flex-col gap-1",children:[f.jsxs("div",{className:"flex items-center gap-2 text-xs text-muted-foreground",children:[c.icon&&f.jsx("span",{className:"flex items-center",children:(()=>{const p=s5[c.icon];return f.jsx(p,{className:"size-3"})})()}),f.jsx("span",{children:c.label}),f.jsxs("span",{className:"text-muted-foreground/50",children:["(",c.files.length,")"]})]}),f.jsx("div",{className:"flex flex-col gap-0.5 pl-5",children:c.files.map((p,h)=>f.jsxs("div",{className:"flex items-center gap-2 text-xs group",children:[f.jsx(em,{className:"size-3 text-muted-foreground shrink-0"}),f.jsx("span",{className:"font-mono text-foreground/80 truncate",children:p.path}),p.line!==void 0&&f.jsxs("span",{className:"text-muted-foreground shrink-0",children:[":",p.line]}),p.action&&f.jsx("span",{className:ye("text-xs px-1 rounded shrink-0",p.action==="created"&&"bg-success/20 text-success",p.action==="modified"&&"bg-warning/20 text-warning",p.action==="deleted"&&"bg-destructive/20 text-destructive"),children:p.action}),f.jsx(u5,{text:p.path})]},h))})]},d))]})}function d5({command:e,stdout:r,stderr:a,exitCode:l}){const o=l===0;return f.jsxs("div",{className:"visualization-container border border-white/10 rounded-md overflow-hidden",children:[f.jsxs("div",{className:"bg-muted px-3 py-2 flex items-center justify-between",children:[f.jsxs("div",{className:"font-mono text-xs text-muted-foreground truncate flex-1 mr-2",children:[f.jsx("span",{className:"text-muted-foreground",children:"$ "}),f.jsx("span",{className:"text-foreground",children:e})]}),f.jsxs("span",{className:`text-xs font-mono px-2 py-0.5 rounded ${o?"bg-muted text-muted-foreground":"bg-red-500/20 text-red-400"}`,children:["[",l,"]"]})]}),(r||a)&&f.jsxs("div",{className:"bg-black px-3 py-2 font-mono text-xs overflow-x-auto",children:[r&&f.jsx("pre",{className:"text-gray-300 whitespace-pre-wrap",children:r}),a&&f.jsx("pre",{className:"text-red-400 whitespace-pre-wrap mt-1",children:a})]})]})}const f5={pending:{icon:fN,color:"text-muted-foreground"},in_progress:{icon:Gn,color:"text-warning",animate:!0},completed:{icon:rs,color:"text-success"},cancelled:{icon:Mc,color:"text-destructive"}},p5={high:{label:"high",className:"bg-destructive/20 text-destructive"},medium:{label:"",className:""},low:{label:"low",className:"text-muted-foreground"}};function h5({title:e,items:r}){if(r.length===0)return null;const a=r.filter(l=>l.status==="completed").length;return r.filter(l=>l.status==="in_progress").length,r.filter(l=>l.status==="pending").length,f.jsxs("div",{className:"flex flex-col gap-3 w-full overflow-hidden",children:[(e||r.length>0)&&f.jsxs("div",{className:"text-sm font-medium text-foreground",children:[e||"Todo List",f.jsxs("span",{className:"ml-2 text-muted-foreground",children:["(",r.length,")"]}),a>0&&f.jsxs("span",{className:"ml-2 text-success text-xs",children:[a," completed"]})]}),f.jsx("div",{className:"flex flex-col gap-1 w-full",children:r.map((l,o)=>{const s=f5[l.status],c=s.icon,d=p5[l.priority];return f.jsxs("div",{className:"flex items-center gap-2 text-sm min-w-0",children:[f.jsx(c,{className:ye("size-4 shrink-0",s.color,s.animate&&"animate-spin")}),f.jsx("span",{className:ye("flex-1",l.status==="completed"&&"line-through text-muted-foreground",l.status==="cancelled"&&"text-muted-foreground"),children:l.content}),d.label&&l.priority==="high"&&f.jsx("span",{className:ye("text-xs px-1.5 py-0.5 rounded shrink-0",d.className),children:d.label}),l.priority==="low"&&l.status!=="completed"&&l.status!=="cancelled"&&f.jsx("span",{className:"text-xs text-muted-foreground shrink-0",children:d.label})]},o)})})]})}function m5({visualization:e}){if(!e)return null;switch(e.type){case"diff":return f.jsx(y0,{path:e.path,hunks:e.hunks,language:e.language,additions:e.additions,deletions:e.deletions,matchInfo:e.matchInfo});case"diffs":return f.jsx("div",{className:"space-y-3",children:e.items.map((r,a)=>f.jsx(y0,{path:r.path,hunks:r.hunks,language:r.language,additions:r.additions,deletions:r.deletions,matchInfo:r.matchInfo},`${r.path}-${a}`))});case"code":return f.jsx(i5,{path:e.path,content:e.content,language:e.language,created:e.created,highlightLines:e.highlightLines});case"file-list":return f.jsx(c5,{title:e.title,groups:e.groups,files:e.files,total:e.total});case"table":return f.jsx("pre",{className:"text-xs bg-muted/50 border rounded-md p-2 overflow-x-auto",children:JSON.stringify(e.rows,null,2)});case"markdown":return f.jsx("div",{className:"prose prose-sm dark:prose-invert max-w-none",children:e.content});case"none":return f.jsx(o5,{message:e.message});case"shell-output":return f.jsx(d5,{command:e.command,stdout:e.stdout,stderr:e.stderr,exitCode:e.exitCode});case"todo-list":return f.jsx(h5,{title:e.title,items:e.items});default:return null}}function g5(e){switch(e){case"pending":return f.jsx(y1,{className:"size-3 text-warning"});case"running":return f.jsx(Gn,{className:"size-3 text-warning animate-spin"});case"completed":return f.jsx(rs,{className:"size-3 text-success"});case"error":return f.jsx(Mc,{className:"size-3 text-destructive"});default:return null}}function y5(e){if(e&&typeof e=="object"&&"_visualization"in e)return e._visualization}function x5({part:e,pendingPermissions:r,onPermissionResponse:a,onNavigateToSubagent:l}){const[o,s]=v.useState(!1),[c,d]=v.useState(!1),p=e.state,h=p.status,y=h==="completed"&&"output"in p?y5(p.output):void 0,g=h==="pending"?r.find(S=>S.toolCallId===e.callId):void 0;let b=null;if(e.name==="task"){if("childSessionId"in p&&p.childSessionId)b=p.childSessionId;else if(h==="completed"&&"output"in p){const C=(typeof p.output=="string"?p.output:"").match(/task_id:\s*([a-f0-9-]{36})/i);C&&(b=C[1])}}const w=async()=>{if("output"in p){const S=typeof p.output=="string"?p.output:JSON.stringify(p.output,null,2);await navigator.clipboard.writeText(S),d(!0),setTimeout(()=>d(!1),2e3)}},k=(()=>{try{const S=JSON.stringify(p.input);return S.length>50?S.slice(0,47)+"...":S}catch{return String(p.input)}})();return f.jsxs("div",{className:"my-1",children:[f.jsxs(Zo,{open:o,onOpenChange:s,children:[f.jsx(Wo,{asChild:!0,children:f.jsxs("div",{className:"flex items-center gap-2 py-1 cursor-pointer hover:text-foreground transition-colors text-muted-foreground",children:[o?f.jsx(ns,{className:"size-4 text-muted-foreground"}):f.jsx(cl,{className:"size-4 text-muted-foreground"}),f.jsx(fj,{className:"size-3"}),f.jsx("span",{className:"text-xs truncate max-w-[120px] sm:max-w-none",children:e.name}),!o&&f.jsx("span",{className:"text-xs text-muted-foreground font-mono truncate flex-1 min-w-0 sm:max-w-[200px] hidden sm:block",children:k}),f.jsxs("div",{className:"ml-auto flex items-center gap-2",children:[g5(h),b&&l&&f.jsxs(Me,{variant:"ghost",size:"sm",className:"h-6 w-6 p-0 sm:w-auto sm:px-2",onClick:S=>{S.stopPropagation(),l(b)},title:"View session",children:[f.jsx(Sh,{className:"size-3"}),f.jsx("span",{className:"hidden sm:inline ml-1",children:"View"})]})]})]})}),f.jsx(Jo,{children:f.jsxs("div",{className:"pl-5 pb-2 flex flex-col gap-2",children:[f.jsxs("div",{children:[f.jsx("div",{className:"text-xs uppercase text-muted-foreground mb-1",children:"Input"}),f.jsx("pre",{className:"text-xs bg-background border rounded-md p-2 overflow-x-auto whitespace-pre-wrap break-words",children:JSON.stringify(p.input,null,2)})]}),(h==="running"||h==="completed")&&b&&l&&f.jsxs(Me,{variant:"outline",className:"w-full",size:"sm",onClick:()=>l(b),children:[f.jsx(Sh,{className:"size-4","data-icon":"inline-start"}),h==="running"?"Watch Subagent":"View Session"]}),h==="completed"&&"output"in p&&f.jsxs("div",{children:[f.jsxs("div",{className:"flex items-center justify-between mb-1",children:[f.jsx("div",{className:"text-xs uppercase text-muted-foreground",children:"Output"}),f.jsx(Me,{variant:"ghost",size:"icon",onClick:w,className:"size-6",children:c?f.jsx(Vr,{className:"size-3 text-success"}):f.jsx(cc,{className:"size-3"})})]}),f.jsx("pre",{className:"text-xs bg-success/10 border border-success/20 rounded-md p-2 overflow-x-auto whitespace-pre-wrap break-words",children:typeof p.output=="string"?p.output:JSON.stringify(p.output,null,2)})]}),h==="error"&&"error"in p&&f.jsxs("div",{children:[f.jsx("div",{className:"text-xs uppercase text-muted-foreground mb-1",children:"Error"}),f.jsx("pre",{className:"text-xs bg-destructive/10 border border-destructive/20 rounded-md p-2 overflow-x-auto whitespace-pre-wrap break-words text-destructive",children:p.error})]})]})})]}),h==="pending"&&g&&f.jsxs("div",{className:"border border-warning/50 bg-warning/10 rounded-md p-3 flex flex-col gap-3 mt-2",children:[f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsx(yv,{className:"size-4 text-warning"}),f.jsx(Nn,{variant:"outline",className:"text-warning border-warning",children:g.permissionType}),f.jsx("span",{className:"text-sm font-mono text-muted-foreground",children:g.permissionKey})]}),g.message&&f.jsx("p",{className:"text-sm",children:g.message}),g.dangerous&&f.jsxs("div",{className:"flex items-center gap-2 text-sm text-destructive font-medium",children:[f.jsx(yv,{className:"size-4"}),"This operation is marked as dangerous"]}),f.jsxs("div",{className:"flex justify-end gap-2 flex-wrap",children:[f.jsx(Me,{variant:"outline",size:"sm",onClick:()=>a(e.callId,!1,!1),children:"Deny"}),f.jsx(Me,{variant:"secondary",size:"sm",onClick:()=>a(e.callId,!0,!1),children:"Approve"}),f.jsx(Me,{size:"sm",onClick:()=>a(e.callId,!0,!0),children:"Always Allow"})]})]}),h==="completed"&&y&&f.jsx("div",{className:"mt-2",children:f.jsx(m5,{visualization:y})})]})}function b5({workspaceId:e,debounceMs:r=150}){const[a,l]=v.useState(""),[o,s]=v.useState(!1),[c,d]=v.useState([]),p=v.useCallback(g=>{const b={type:"file",path:g.path,display:g.name};return d(w=>[...w,b]),s(!1),l(""),b},[]),h=v.useCallback((g,b,w)=>{const k=g.lastIndexOf("@",b);if(k===-1)return{text:g,cursorPos:b};const S=g.slice(0,k)+`@${w.path}`+g.slice(b),C=k+w.path.length+1;return{text:S,cursorPos:C}},[]),y=v.useCallback(g=>{const b=/@([^\s@]+)/g,w=[];let k;for(;(k=b.exec(g))!==null;){const S=k[1];c.some(C=>C.path===S)&&!w.some(C=>C.path===S)&&w.push({type:"file",path:S,display:S.split("/").pop()||S})}return w},[c]);return{query:a,setQuery:l,showAutocomplete:o,setShowAutocomplete:s,mentions:c,handleFileSelect:p,insertMention:h,extractMentions:y}}function v5({onSendMessage:e,disabled:r,isStreaming:a,onStopStreaming:l,placeholder:o="Type a message...",workspaceId:s,serverUrl:c,apiToken:d}){const[p,h]=v.useState(""),[y,g]=v.useState(0),[b,w]=v.useState([]),[k,S]=v.useState(0),C=v.useRef(null),{query:A,setQuery:N,showAutocomplete:j,setShowAutocomplete:O,handleFileSelect:D,insertMention:M}=b5({workspaceId:s||""});v.useEffect(()=>{S(0)},[b]),v.useEffect(()=>{const V=C.current;V&&(V.style.height="auto",V.style.height=`${Math.min(V.scrollHeight,150)}px`)},[p]);const U=v.useCallback(V=>{const ue=V.target.value,W=V.target.selectionStart||0;h(ue),g(W);const J=ue.lastIndexOf("@",W);if(J!==-1){const B=ue.slice(J+1,W);if(!B.includes(" ")){N(B),O(!0);return}}O(!1)},[N,O]),F=v.useCallback(V=>{const ue=D(V),W=M(p,y,ue);h(W.text),O(!1),w([]),setTimeout(()=>{C.current&&(C.current.focus(),C.current.setSelectionRange(W.cursorPos,W.cursorPos))},0)},[p,y,D,M,O]),Q=V=>{V==null||V.preventDefault(),p.trim()&&!r&&(e(p.trim()),h(""))},I=V=>{if(j&&b.length>0)switch(V.key){case"ArrowDown":V.preventDefault(),S(ue=>Math.min(ue+1,b.length-1));return;case"ArrowUp":V.preventDefault(),S(ue=>Math.max(ue-1,0));return;case"Enter":V.preventDefault(),b[k]&&F(b[k]);return;case"Escape":V.preventDefault(),O(!1);return;case"Tab":V.preventDefault(),b[k]&&F(b[k]);return}V.key==="Enter"&&!V.shiftKey&&(V.preventDefault(),Q())},Y=v.useCallback(V=>{w(V)},[]);return a&&l?f.jsx("div",{className:"p-4 border-t border-border bg-card",children:f.jsxs("div",{className:"flex items-center justify-center gap-3",children:[f.jsxs("div",{className:"animate-pulse flex items-center gap-2 text-muted-foreground",children:[f.jsx("div",{className:"size-2 rounded-full bg-primary animate-bounce"}),f.jsx("div",{className:"size-2 rounded-full bg-primary animate-bounce [animation-delay:0.1s]"}),f.jsx("div",{className:"size-2 rounded-full bg-primary animate-bounce [animation-delay:0.2s]"}),f.jsx("span",{className:"text-sm ml-2",children:"Generating..."})]}),f.jsxs(Me,{variant:"outline",size:"sm",onClick:l,children:[f.jsx(v1,{className:"size-4","data-icon":"inline-start"}),"Stop"]})]})}):f.jsxs("form",{onSubmit:Q,className:"p-4 border-t border-border bg-card",children:[f.jsxs("div",{className:"flex gap-3 items-end",children:[f.jsx("div",{className:"flex-1 relative",children:f.jsxs(sd,{open:j&&!!s,onOpenChange:O,children:[f.jsx(fz,{asChild:!0,children:f.jsx(sz,{ref:C,value:p,onChange:U,onKeyDown:I,placeholder:o,disabled:r,className:ye("min-h-[44px] max-h-[150px] resize-none pr-12","focus-visible:ring-1"),rows:1})}),f.jsx(ud,{className:"w-72 p-0",align:"start",side:"top",sideOffset:8,onOpenAutoFocus:V=>V.preventDefault(),onCloseAutoFocus:V=>V.preventDefault(),children:f.jsx(Pz,{workspaceId:s||"",searchQuery:A,selectedIndex:k,onSelect:F,onFilesChange:Y,serverUrl:c,apiToken:d})})]})}),f.jsx(Me,{type:"submit",disabled:!p.trim()||r,size:"default",className:"h-11",children:f.jsx(QN,{className:"size-4"})})]}),f.jsxs("div",{className:"mt-2 text-xs text-muted-foreground text-center flex items-center justify-center gap-1",children:[f.jsx("kbd",{className:"px-1.5 py-0.5 bg-muted rounded text-[10px]",children:"Enter"}),f.jsx("span",{children:"to send"}),f.jsx("span",{className:"mx-2",children:"•"}),f.jsx("kbd",{className:"px-1.5 py-0.5 bg-muted rounded text-[10px]",children:"Shift + Enter"}),f.jsx("span",{children:"for new line"})]})]})}function w5(e,r){const a={};return(e[e.length-1]===""?[...e,""]:e).join((a.padRight?" ":"")+","+(a.padLeft===!1?"":" ")).trim()}const S5=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,k5=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,E5={};function x0(e,r){return(E5.jsx?k5:S5).test(e)}const C5=/[ \t\n\f\r]/g;function A5(e){return typeof e=="object"?e.type==="text"?b0(e.value):!1:b0(e)}function b0(e){return e.replace(C5,"")===""}class ks{constructor(r,a,l){this.normal=a,this.property=r,l&&(this.space=l)}}ks.prototype.normal={};ks.prototype.property={};ks.prototype.space=void 0;function yE(e,r){const a={},l={};for(const o of e)Object.assign(a,o.property),Object.assign(l,o.normal);return new ks(a,l,r)}function Hh(e){return e.toLowerCase()}class hn{constructor(r,a){this.attribute=a,this.property=r}}hn.prototype.attribute="";hn.prototype.booleanish=!1;hn.prototype.boolean=!1;hn.prototype.commaOrSpaceSeparated=!1;hn.prototype.commaSeparated=!1;hn.prototype.defined=!1;hn.prototype.mustUseProperty=!1;hn.prototype.number=!1;hn.prototype.overloadedBoolean=!1;hn.prototype.property="";hn.prototype.spaceSeparated=!1;hn.prototype.space=void 0;let N5=0;const Fe=wl(),Tt=wl(),Vh=wl(),ge=wl(),pt=wl(),yi=wl(),Cn=wl();function wl(){return 2**++N5}const $h=Object.freeze(Object.defineProperty({__proto__:null,boolean:Fe,booleanish:Tt,commaOrSpaceSeparated:Cn,commaSeparated:yi,number:ge,overloadedBoolean:Vh,spaceSeparated:pt},Symbol.toStringTag,{value:"Module"})),nh=Object.keys($h);class eg extends hn{constructor(r,a,l,o){let s=-1;if(super(r,a),v0(this,"space",o),typeof l=="number")for(;++s<nh.length;){const c=nh[s];v0(this,nh[s],(l&$h[c])===$h[c])}}}eg.prototype.defined=!0;function v0(e,r,a){a&&(e[r]=a)}function Ri(e){const r={},a={};for(const[l,o]of Object.entries(e.properties)){const s=new eg(l,e.transform(e.attributes||{},l),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(l)&&(s.mustUseProperty=!0),r[l]=s,a[Hh(l)]=l,a[Hh(s.attribute)]=l}return new ks(r,a,e.space)}const xE=Ri({properties:{ariaActiveDescendant:null,ariaAtomic:Tt,ariaAutoComplete:null,ariaBusy:Tt,ariaChecked:Tt,ariaColCount:ge,ariaColIndex:ge,ariaColSpan:ge,ariaControls:pt,ariaCurrent:null,ariaDescribedBy:pt,ariaDetails:null,ariaDisabled:Tt,ariaDropEffect:pt,ariaErrorMessage:null,ariaExpanded:Tt,ariaFlowTo:pt,ariaGrabbed:Tt,ariaHasPopup:null,ariaHidden:Tt,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:pt,ariaLevel:ge,ariaLive:null,ariaModal:Tt,ariaMultiLine:Tt,ariaMultiSelectable:Tt,ariaOrientation:null,ariaOwns:pt,ariaPlaceholder:null,ariaPosInSet:ge,ariaPressed:Tt,ariaReadOnly:Tt,ariaRelevant:null,ariaRequired:Tt,ariaRoleDescription:pt,ariaRowCount:ge,ariaRowIndex:ge,ariaRowSpan:ge,ariaSelected:Tt,ariaSetSize:ge,ariaSort:null,ariaValueMax:ge,ariaValueMin:ge,ariaValueNow:ge,ariaValueText:null,role:null},transform(e,r){return r==="role"?r:"aria-"+r.slice(4).toLowerCase()}});function bE(e,r){return r in e?e[r]:r}function vE(e,r){return bE(e,r.toLowerCase())}const j5=Ri({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:yi,acceptCharset:pt,accessKey:pt,action:null,allow:null,allowFullScreen:Fe,allowPaymentRequest:Fe,allowUserMedia:Fe,alt:null,as:null,async:Fe,autoCapitalize:null,autoComplete:pt,autoFocus:Fe,autoPlay:Fe,blocking:pt,capture:null,charSet:null,checked:Fe,cite:null,className:pt,cols:ge,colSpan:null,content:null,contentEditable:Tt,controls:Fe,controlsList:pt,coords:ge|yi,crossOrigin:null,data:null,dateTime:null,decoding:null,default:Fe,defer:Fe,dir:null,dirName:null,disabled:Fe,download:Vh,draggable:Tt,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:Fe,formTarget:null,headers:pt,height:ge,hidden:Vh,high:ge,href:null,hrefLang:null,htmlFor:pt,httpEquiv:pt,id:null,imageSizes:null,imageSrcSet:null,inert:Fe,inputMode:null,integrity:null,is:null,isMap:Fe,itemId:null,itemProp:pt,itemRef:pt,itemScope:Fe,itemType:pt,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:Fe,low:ge,manifest:null,max:null,maxLength:ge,media:null,method:null,min:null,minLength:ge,multiple:Fe,muted:Fe,name:null,nonce:null,noModule:Fe,noValidate:Fe,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:Fe,optimum:ge,pattern:null,ping:pt,placeholder:null,playsInline:Fe,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:Fe,referrerPolicy:null,rel:pt,required:Fe,reversed:Fe,rows:ge,rowSpan:ge,sandbox:pt,scope:null,scoped:Fe,seamless:Fe,selected:Fe,shadowRootClonable:Fe,shadowRootDelegatesFocus:Fe,shadowRootMode:null,shape:null,size:ge,sizes:null,slot:null,span:ge,spellCheck:Tt,src:null,srcDoc:null,srcLang:null,srcSet:null,start:ge,step:null,style:null,tabIndex:ge,target:null,title:null,translate:null,type:null,typeMustMatch:Fe,useMap:null,value:Tt,width:ge,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:pt,axis:null,background:null,bgColor:null,border:ge,borderColor:null,bottomMargin:ge,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:Fe,declare:Fe,event:null,face:null,frame:null,frameBorder:null,hSpace:ge,leftMargin:ge,link:null,longDesc:null,lowSrc:null,marginHeight:ge,marginWidth:ge,noResize:Fe,noHref:Fe,noShade:Fe,noWrap:Fe,object:null,profile:null,prompt:null,rev:null,rightMargin:ge,rules:null,scheme:null,scrolling:Tt,standby:null,summary:null,text:null,topMargin:ge,valueType:null,version:null,vAlign:null,vLink:null,vSpace:ge,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:Fe,disableRemotePlayback:Fe,prefix:null,property:null,results:ge,security:null,unselectable:null},space:"html",transform:vE}),T5=Ri({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:Cn,accentHeight:ge,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:ge,amplitude:ge,arabicForm:null,ascent:ge,attributeName:null,attributeType:null,azimuth:ge,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:ge,by:null,calcMode:null,capHeight:ge,className:pt,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:ge,diffuseConstant:ge,direction:null,display:null,dur:null,divisor:ge,dominantBaseline:null,download:Fe,dx:null,dy:null,edgeMode:null,editable:null,elevation:ge,enableBackground:null,end:null,event:null,exponent:ge,externalResourcesRequired:null,fill:null,fillOpacity:ge,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:yi,g2:yi,glyphName:yi,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:ge,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:ge,horizOriginX:ge,horizOriginY:ge,id:null,ideographic:ge,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:ge,k:ge,k1:ge,k2:ge,k3:ge,k4:ge,kernelMatrix:Cn,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:ge,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:ge,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:ge,overlineThickness:ge,paintOrder:null,panose1:null,path:null,pathLength:ge,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:pt,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:ge,pointsAtY:ge,pointsAtZ:ge,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Cn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Cn,rev:Cn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Cn,requiredFeatures:Cn,requiredFonts:Cn,requiredFormats:Cn,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:ge,specularExponent:ge,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:ge,strikethroughThickness:ge,string:null,stroke:null,strokeDashArray:Cn,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:ge,strokeOpacity:ge,strokeWidth:null,style:null,surfaceScale:ge,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Cn,tabIndex:ge,tableValues:null,target:null,targetX:ge,targetY:ge,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Cn,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:ge,underlineThickness:ge,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:ge,values:null,vAlphabetic:ge,vMathematical:ge,vectorEffect:null,vHanging:ge,vIdeographic:ge,version:null,vertAdvY:ge,vertOriginX:ge,vertOriginY:ge,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:ge,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:bE}),wE=Ri({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(e,r){return"xlink:"+r.slice(5).toLowerCase()}}),SE=Ri({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:vE}),kE=Ri({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,r){return"xml:"+r.slice(3).toLowerCase()}}),_5={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"},R5=/[A-Z]/g,w0=/-[a-z]/g,M5=/^data[-\w.:]+$/i;function O5(e,r){const a=Hh(r);let l=r,o=hn;if(a in e.normal)return e.property[e.normal[a]];if(a.length>4&&a.slice(0,4)==="data"&&M5.test(r)){if(r.charAt(4)==="-"){const s=r.slice(5).replace(w0,z5);l="data"+s.charAt(0).toUpperCase()+s.slice(1)}else{const s=r.slice(4);if(!w0.test(s)){let c=s.replace(R5,D5);c.charAt(0)!=="-"&&(c="-"+c),r="data"+c}}o=eg}return new o(l,r)}function D5(e){return"-"+e.toLowerCase()}function z5(e){return e.charAt(1).toUpperCase()}const L5=yE([xE,j5,wE,SE,kE],"html"),tg=yE([xE,T5,wE,SE,kE],"svg");function I5(e){return e.join(" ").trim()}var oi={},rh,S0;function B5(){if(S0)return rh;S0=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,r=/\n/g,a=/^\s*/,l=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,s=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,c=/^[;\s]*/,d=/^\s+|\s+$/g,p=`
417
- `,h="/",y="*",g="",b="comment",w="declaration";function k(C,A){if(typeof C!="string")throw new TypeError("First argument must be a string");if(!C)return[];A=A||{};var N=1,j=1;function O(W){var J=W.match(r);J&&(N+=J.length);var B=W.lastIndexOf(p);j=~B?W.length-B:j+W.length}function D(){var W={line:N,column:j};return function(J){return J.position=new M(W),Q(),J}}function M(W){this.start=W,this.end={line:N,column:j},this.source=A.source}M.prototype.content=C;function U(W){var J=new Error(A.source+":"+N+":"+j+": "+W);if(J.reason=W,J.filename=A.source,J.line=N,J.column=j,J.source=C,!A.silent)throw J}function F(W){var J=W.exec(C);if(J){var B=J[0];return O(B),C=C.slice(B.length),J}}function Q(){F(a)}function I(W){var J;for(W=W||[];J=Y();)J!==!1&&W.push(J);return W}function Y(){var W=D();if(!(h!=C.charAt(0)||y!=C.charAt(1))){for(var J=2;g!=C.charAt(J)&&(y!=C.charAt(J)||h!=C.charAt(J+1));)++J;if(J+=2,g===C.charAt(J-1))return U("End of comment missing");var B=C.slice(2,J-2);return j+=2,O(B),C=C.slice(J),j+=2,W({type:b,comment:B})}}function V(){var W=D(),J=F(l);if(J){if(Y(),!F(o))return U("property missing ':'");var B=F(s),G=W({type:w,property:S(J[0].replace(e,g)),value:B?S(B[0].replace(e,g)):g});return F(c),G}}function ue(){var W=[];I(W);for(var J;J=V();)J!==!1&&(W.push(J),I(W));return W}return Q(),ue()}function S(C){return C?C.replace(d,g):g}return rh=k,rh}var k0;function P5(){if(k0)return oi;k0=1;var e=oi&&oi.__importDefault||function(l){return l&&l.__esModule?l:{default:l}};Object.defineProperty(oi,"__esModule",{value:!0}),oi.default=a;const r=e(B5());function a(l,o){let s=null;if(!l||typeof l!="string")return s;const c=(0,r.default)(l),d=typeof o=="function";return c.forEach(p=>{if(p.type!=="declaration")return;const{property:h,value:y}=p;d?o(h,y,p):y&&(s=s||{},s[h]=y)}),s}return oi}var Mo={},E0;function F5(){if(E0)return Mo;E0=1,Object.defineProperty(Mo,"__esModule",{value:!0}),Mo.camelCase=void 0;var e=/^--[a-zA-Z0-9_-]+$/,r=/-([a-z])/g,a=/^[^-]+$/,l=/^-(webkit|moz|ms|o|khtml)-/,o=/^-(ms)-/,s=function(h){return!h||a.test(h)||e.test(h)},c=function(h,y){return y.toUpperCase()},d=function(h,y){return"".concat(y,"-")},p=function(h,y){return y===void 0&&(y={}),s(h)?h:(h=h.toLowerCase(),y.reactCompat?h=h.replace(o,d):h=h.replace(l,d),h.replace(r,c))};return Mo.camelCase=p,Mo}var Oo,C0;function U5(){if(C0)return Oo;C0=1;var e=Oo&&Oo.__importDefault||function(o){return o&&o.__esModule?o:{default:o}},r=e(P5()),a=F5();function l(o,s){var c={};return!o||typeof o!="string"||(0,r.default)(o,function(d,p){d&&p&&(c[(0,a.camelCase)(d,s)]=p)}),c}return l.default=l,Oo=l,Oo}var H5=U5();const V5=Rc(H5),EE=CE("end"),ng=CE("start");function CE(e){return r;function r(a){const l=a&&a.position&&a.position[e]||{};if(typeof l.line=="number"&&l.line>0&&typeof l.column=="number"&&l.column>0)return{line:l.line,column:l.column,offset:typeof l.offset=="number"&&l.offset>-1?l.offset:void 0}}}function $5(e){const r=ng(e),a=EE(e);if(r&&a)return{start:r,end:a}}function Fo(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?A0(e.position):"start"in e||"end"in e?A0(e):"line"in e||"column"in e?qh(e):""}function qh(e){return N0(e&&e.line)+":"+N0(e&&e.column)}function A0(e){return qh(e&&e.start)+"-"+qh(e&&e.end)}function N0(e){return e&&typeof e=="number"?e:1}class Wt extends Error{constructor(r,a,l){super(),typeof a=="string"&&(l=a,a=void 0);let o="",s={},c=!1;if(a&&("line"in a&&"column"in a?s={place:a}:"start"in a&&"end"in a?s={place:a}:"type"in a?s={ancestors:[a],place:a.position}:s={...a}),typeof r=="string"?o=r:!s.cause&&r&&(c=!0,o=r.message,s.cause=r),!s.ruleId&&!s.source&&typeof l=="string"){const p=l.indexOf(":");p===-1?s.ruleId=l:(s.source=l.slice(0,p),s.ruleId=l.slice(p+1))}if(!s.place&&s.ancestors&&s.ancestors){const p=s.ancestors[s.ancestors.length-1];p&&(s.place=p.position)}const d=s.place&&"start"in s.place?s.place.start:s.place;this.ancestors=s.ancestors||void 0,this.cause=s.cause||void 0,this.column=d?d.column:void 0,this.fatal=void 0,this.file="",this.message=o,this.line=d?d.line:void 0,this.name=Fo(s.place)||"1:1",this.place=s.place||void 0,this.reason=this.message,this.ruleId=s.ruleId||void 0,this.source=s.source||void 0,this.stack=c&&s.cause&&typeof s.cause.stack=="string"?s.cause.stack:"",this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}}Wt.prototype.file="";Wt.prototype.name="";Wt.prototype.reason="";Wt.prototype.message="";Wt.prototype.stack="";Wt.prototype.column=void 0;Wt.prototype.line=void 0;Wt.prototype.ancestors=void 0;Wt.prototype.cause=void 0;Wt.prototype.fatal=void 0;Wt.prototype.place=void 0;Wt.prototype.ruleId=void 0;Wt.prototype.source=void 0;const rg={}.hasOwnProperty,q5=new Map,G5=/[A-Z]/g,Y5=new Set(["table","tbody","thead","tfoot","tr"]),X5=new Set(["td","th"]),AE="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function K5(e,r){if(!r||r.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const a=r.filePath||void 0;let l;if(r.development){if(typeof r.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");l=rL(a,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");l=nL(a,r.jsx,r.jsxs)}const o={Fragment:r.Fragment,ancestors:[],components:r.components||{},create:l,elementAttributeNameCase:r.elementAttributeNameCase||"react",evaluater:r.createEvaluater?r.createEvaluater():void 0,filePath:a,ignoreInvalidStyle:r.ignoreInvalidStyle||!1,passKeys:r.passKeys!==!1,passNode:r.passNode||!1,schema:r.space==="svg"?tg:L5,stylePropertyNameCase:r.stylePropertyNameCase||"dom",tableCellAlignToStyle:r.tableCellAlignToStyle!==!1},s=NE(o,e,void 0);return s&&typeof s!="string"?s:o.create(e,o.Fragment,{children:s||void 0},void 0)}function NE(e,r,a){if(r.type==="element")return Q5(e,r,a);if(r.type==="mdxFlowExpression"||r.type==="mdxTextExpression")return Z5(e,r);if(r.type==="mdxJsxFlowElement"||r.type==="mdxJsxTextElement")return J5(e,r,a);if(r.type==="mdxjsEsm")return W5(e,r);if(r.type==="root")return eL(e,r,a);if(r.type==="text")return tL(e,r)}function Q5(e,r,a){const l=e.schema;let o=l;r.tagName.toLowerCase()==="svg"&&l.space==="html"&&(o=tg,e.schema=o),e.ancestors.push(r);const s=TE(e,r.tagName,!1),c=aL(e,r);let d=lg(e,r);return Y5.has(r.tagName)&&(d=d.filter(function(p){return typeof p=="string"?!A5(p):!0})),jE(e,c,s,r),ag(c,d),e.ancestors.pop(),e.schema=l,e.create(r,s,c,a)}function Z5(e,r){if(r.data&&r.data.estree&&e.evaluater){const l=r.data.estree.body[0];return l.type,e.evaluater.evaluateExpression(l.expression)}es(e,r.position)}function W5(e,r){if(r.data&&r.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(r.data.estree);es(e,r.position)}function J5(e,r,a){const l=e.schema;let o=l;r.name==="svg"&&l.space==="html"&&(o=tg,e.schema=o),e.ancestors.push(r);const s=r.name===null?e.Fragment:TE(e,r.name,!0),c=lL(e,r),d=lg(e,r);return jE(e,c,s,r),ag(c,d),e.ancestors.pop(),e.schema=l,e.create(r,s,c,a)}function eL(e,r,a){const l={};return ag(l,lg(e,r)),e.create(r,e.Fragment,l,a)}function tL(e,r){return r.value}function jE(e,r,a,l){typeof a!="string"&&a!==e.Fragment&&e.passNode&&(r.node=l)}function ag(e,r){if(r.length>0){const a=r.length>1?r:r[0];a&&(e.children=a)}}function nL(e,r,a){return l;function l(o,s,c,d){const h=Array.isArray(c.children)?a:r;return d?h(s,c,d):h(s,c)}}function rL(e,r){return a;function a(l,o,s,c){const d=Array.isArray(s.children),p=ng(l);return r(o,s,c,d,{columnNumber:p?p.column-1:void 0,fileName:e,lineNumber:p?p.line:void 0},void 0)}}function aL(e,r){const a={};let l,o;for(o in r.properties)if(o!=="children"&&rg.call(r.properties,o)){const s=iL(e,o,r.properties[o]);if(s){const[c,d]=s;e.tableCellAlignToStyle&&c==="align"&&typeof d=="string"&&X5.has(r.tagName)?l=d:a[c]=d}}if(l){const s=a.style||(a.style={});s[e.stylePropertyNameCase==="css"?"text-align":"textAlign"]=l}return a}function lL(e,r){const a={};for(const l of r.attributes)if(l.type==="mdxJsxExpressionAttribute")if(l.data&&l.data.estree&&e.evaluater){const s=l.data.estree.body[0];s.type;const c=s.expression;c.type;const d=c.properties[0];d.type,Object.assign(a,e.evaluater.evaluateExpression(d.argument))}else es(e,r.position);else{const o=l.name;let s;if(l.value&&typeof l.value=="object")if(l.value.data&&l.value.data.estree&&e.evaluater){const d=l.value.data.estree.body[0];d.type,s=e.evaluater.evaluateExpression(d.expression)}else es(e,r.position);else s=l.value===null?!0:l.value;a[o]=s}return a}function lg(e,r){const a=[];let l=-1;const o=e.passKeys?new Map:q5;for(;++l<r.children.length;){const s=r.children[l];let c;if(e.passKeys){const p=s.type==="element"?s.tagName:s.type==="mdxJsxFlowElement"||s.type==="mdxJsxTextElement"?s.name:void 0;if(p){const h=o.get(p)||0;c=p+"-"+h,o.set(p,h+1)}}const d=NE(e,s,c);d!==void 0&&a.push(d)}return a}function iL(e,r,a){const l=O5(e.schema,r);if(!(a==null||typeof a=="number"&&Number.isNaN(a))){if(Array.isArray(a)&&(a=l.commaSeparated?w5(a):I5(a)),l.property==="style"){let o=typeof a=="object"?a:oL(e,String(a));return e.stylePropertyNameCase==="css"&&(o=sL(o)),["style",o]}return[e.elementAttributeNameCase==="react"&&l.space?_5[l.property]||l.property:l.attribute,a]}}function oL(e,r){try{return V5(r,{reactCompat:!0})}catch(a){if(e.ignoreInvalidStyle)return{};const l=a,o=new Wt("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:l,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw o.file=e.filePath||void 0,o.url=AE+"#cannot-parse-style-attribute",o}}function TE(e,r,a){let l;if(!a)l={type:"Literal",value:r};else if(r.includes(".")){const o=r.split(".");let s=-1,c;for(;++s<o.length;){const d=x0(o[s])?{type:"Identifier",name:o[s]}:{type:"Literal",value:o[s]};c=c?{type:"MemberExpression",object:c,property:d,computed:!!(s&&d.type==="Literal"),optional:!1}:d}l=c}else l=x0(r)&&!/^[a-z]/.test(r)?{type:"Identifier",name:r}:{type:"Literal",value:r};if(l.type==="Literal"){const o=l.value;return rg.call(e.components,o)?e.components[o]:o}if(e.evaluater)return e.evaluater.evaluateExpression(l);es(e)}function es(e,r){const a=new Wt("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:r,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw a.file=e.filePath||void 0,a.url=AE+"#cannot-handle-mdx-estrees-without-createevaluater",a}function sL(e){const r={};let a;for(a in e)rg.call(e,a)&&(r[uL(a)]=e[a]);return r}function uL(e){let r=e.replace(G5,cL);return r.slice(0,3)==="ms-"&&(r="-"+r),r}function cL(e){return"-"+e.toLowerCase()}const ah={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"]},dL={};function ig(e,r){const a=dL,l=typeof a.includeImageAlt=="boolean"?a.includeImageAlt:!0,o=typeof a.includeHtml=="boolean"?a.includeHtml:!0;return _E(e,l,o)}function _E(e,r,a){if(fL(e)){if("value"in e)return e.type==="html"&&!a?"":e.value;if(r&&"alt"in e&&e.alt)return e.alt;if("children"in e)return j0(e.children,r,a)}return Array.isArray(e)?j0(e,r,a):""}function j0(e,r,a){const l=[];let o=-1;for(;++o<e.length;)l[o]=_E(e[o],r,a);return l.join("")}function fL(e){return!!(e&&typeof e=="object")}const T0=document.createElement("i");function og(e){const r="&"+e+";";T0.innerHTML=r;const a=T0.textContent;return a.charCodeAt(a.length-1)===59&&e!=="semi"||a===r?!1:a}function Tn(e,r,a,l){const o=e.length;let s=0,c;if(r<0?r=-r>o?0:o+r:r=r>o?o:r,a=a>0?a:0,l.length<1e4)c=Array.from(l),c.unshift(r,a),e.splice(...c);else for(a&&e.splice(r,a);s<l.length;)c=l.slice(s,s+1e4),c.unshift(r,0),e.splice(...c),s+=1e4,r+=1e4}function qn(e,r){return e.length>0?(Tn(e,e.length,0,r),e):r}const _0={}.hasOwnProperty;function RE(e){const r={};let a=-1;for(;++a<e.length;)pL(r,e[a]);return r}function pL(e,r){let a;for(a in r){const o=(_0.call(e,a)?e[a]:void 0)||(e[a]={}),s=r[a];let c;if(s)for(c in s){_0.call(o,c)||(o[c]=[]);const d=s[c];hL(o[c],Array.isArray(d)?d:d?[d]:[])}}}function hL(e,r){let a=-1;const l=[];for(;++a<r.length;)(r[a].add==="after"?e:l).push(r[a]);Tn(e,0,0,l)}function ME(e,r){const a=Number.parseInt(e,r);return a<9||a===11||a>13&&a<32||a>126&&a<160||a>55295&&a<57344||a>64975&&a<65008||(a&65535)===65535||(a&65535)===65534||a>1114111?"�":String.fromCodePoint(a)}function tr(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const nn=La(/[A-Za-z]/),Zt=La(/[\dA-Za-z]/),mL=La(/[#-'*+\--9=?A-Z^-~]/);function Nc(e){return e!==null&&(e<32||e===127)}const Gh=La(/\d/),gL=La(/[\dA-Fa-f]/),yL=La(/[!-/:-@[-`{-~]/);function Re(e){return e!==null&&e<-2}function ft(e){return e!==null&&(e<0||e===32)}function Ge(e){return e===-2||e===-1||e===32}const hd=La(new RegExp("\\p{P}|\\p{S}","u")),gl=La(/\s/);function La(e){return r;function r(a){return a!==null&&a>-1&&e.test(String.fromCharCode(a))}}function Mi(e){const r=[];let a=-1,l=0,o=0;for(;++a<e.length;){const s=e.charCodeAt(a);let c="";if(s===37&&Zt(e.charCodeAt(a+1))&&Zt(e.charCodeAt(a+2)))o=2;else if(s<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(s))||(c=String.fromCharCode(s));else if(s>55295&&s<57344){const d=e.charCodeAt(a+1);s<56320&&d>56319&&d<57344?(c=String.fromCharCode(s,d),o=1):c="�"}else c=String.fromCharCode(s);c&&(r.push(e.slice(l,a),encodeURIComponent(c)),l=a+o+1,c=""),o&&(a+=o,o=0)}return r.join("")+e.slice(l)}function Ze(e,r,a,l){const o=l?l-1:Number.POSITIVE_INFINITY;let s=0;return c;function c(p){return Ge(p)?(e.enter(a),d(p)):r(p)}function d(p){return Ge(p)&&s++<o?(e.consume(p),d):(e.exit(a),r(p))}}const xL={tokenize:bL};function bL(e){const r=e.attempt(this.parser.constructs.contentInitial,l,o);let a;return r;function l(d){if(d===null){e.consume(d);return}return e.enter("lineEnding"),e.consume(d),e.exit("lineEnding"),Ze(e,r,"linePrefix")}function o(d){return e.enter("paragraph"),s(d)}function s(d){const p=e.enter("chunkText",{contentType:"text",previous:a});return a&&(a.next=p),a=p,c(d)}function c(d){if(d===null){e.exit("chunkText"),e.exit("paragraph"),e.consume(d);return}return Re(d)?(e.consume(d),e.exit("chunkText"),s):(e.consume(d),c)}}const vL={tokenize:wL},R0={tokenize:SL};function wL(e){const r=this,a=[];let l=0,o,s,c;return d;function d(j){if(l<a.length){const O=a[l];return r.containerState=O[1],e.attempt(O[0].continuation,p,h)(j)}return h(j)}function p(j){if(l++,r.containerState._closeFlow){r.containerState._closeFlow=void 0,o&&N();const O=r.events.length;let D=O,M;for(;D--;)if(r.events[D][0]==="exit"&&r.events[D][1].type==="chunkFlow"){M=r.events[D][1].end;break}A(l);let U=O;for(;U<r.events.length;)r.events[U][1].end={...M},U++;return Tn(r.events,D+1,0,r.events.slice(O)),r.events.length=U,h(j)}return d(j)}function h(j){if(l===a.length){if(!o)return b(j);if(o.currentConstruct&&o.currentConstruct.concrete)return k(j);r.interrupt=!!(o.currentConstruct&&!o._gfmTableDynamicInterruptHack)}return r.containerState={},e.check(R0,y,g)(j)}function y(j){return o&&N(),A(l),b(j)}function g(j){return r.parser.lazy[r.now().line]=l!==a.length,c=r.now().offset,k(j)}function b(j){return r.containerState={},e.attempt(R0,w,k)(j)}function w(j){return l++,a.push([r.currentConstruct,r.containerState]),b(j)}function k(j){if(j===null){o&&N(),A(0),e.consume(j);return}return o=o||r.parser.flow(r.now()),e.enter("chunkFlow",{_tokenizer:o,contentType:"flow",previous:s}),S(j)}function S(j){if(j===null){C(e.exit("chunkFlow"),!0),A(0),e.consume(j);return}return Re(j)?(e.consume(j),C(e.exit("chunkFlow")),l=0,r.interrupt=void 0,d):(e.consume(j),S)}function C(j,O){const D=r.sliceStream(j);if(O&&D.push(null),j.previous=s,s&&(s.next=j),s=j,o.defineSkip(j.start),o.write(D),r.parser.lazy[j.start.line]){let M=o.events.length;for(;M--;)if(o.events[M][1].start.offset<c&&(!o.events[M][1].end||o.events[M][1].end.offset>c))return;const U=r.events.length;let F=U,Q,I;for(;F--;)if(r.events[F][0]==="exit"&&r.events[F][1].type==="chunkFlow"){if(Q){I=r.events[F][1].end;break}Q=!0}for(A(l),M=U;M<r.events.length;)r.events[M][1].end={...I},M++;Tn(r.events,F+1,0,r.events.slice(U)),r.events.length=M}}function A(j){let O=a.length;for(;O-- >j;){const D=a[O];r.containerState=D[1],D[0].exit.call(r,e)}a.length=j}function N(){o.write([null]),s=void 0,o=void 0,r.containerState._closeFlow=void 0}}function SL(e,r,a){return Ze(e,e.attempt(this.parser.constructs.document,r,a),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function ki(e){if(e===null||ft(e)||gl(e))return 1;if(hd(e))return 2}function md(e,r,a){const l=[];let o=-1;for(;++o<e.length;){const s=e[o].resolveAll;s&&!l.includes(s)&&(r=s(r,a),l.push(s))}return r}const Yh={name:"attention",resolveAll:kL,tokenize:EL};function kL(e,r){let a=-1,l,o,s,c,d,p,h,y;for(;++a<e.length;)if(e[a][0]==="enter"&&e[a][1].type==="attentionSequence"&&e[a][1]._close){for(l=a;l--;)if(e[l][0]==="exit"&&e[l][1].type==="attentionSequence"&&e[l][1]._open&&r.sliceSerialize(e[l][1]).charCodeAt(0)===r.sliceSerialize(e[a][1]).charCodeAt(0)){if((e[l][1]._close||e[a][1]._open)&&(e[a][1].end.offset-e[a][1].start.offset)%3&&!((e[l][1].end.offset-e[l][1].start.offset+e[a][1].end.offset-e[a][1].start.offset)%3))continue;p=e[l][1].end.offset-e[l][1].start.offset>1&&e[a][1].end.offset-e[a][1].start.offset>1?2:1;const g={...e[l][1].end},b={...e[a][1].start};M0(g,-p),M0(b,p),c={type:p>1?"strongSequence":"emphasisSequence",start:g,end:{...e[l][1].end}},d={type:p>1?"strongSequence":"emphasisSequence",start:{...e[a][1].start},end:b},s={type:p>1?"strongText":"emphasisText",start:{...e[l][1].end},end:{...e[a][1].start}},o={type:p>1?"strong":"emphasis",start:{...c.start},end:{...d.end}},e[l][1].end={...c.start},e[a][1].start={...d.end},h=[],e[l][1].end.offset-e[l][1].start.offset&&(h=qn(h,[["enter",e[l][1],r],["exit",e[l][1],r]])),h=qn(h,[["enter",o,r],["enter",c,r],["exit",c,r],["enter",s,r]]),h=qn(h,md(r.parser.constructs.insideSpan.null,e.slice(l+1,a),r)),h=qn(h,[["exit",s,r],["enter",d,r],["exit",d,r],["exit",o,r]]),e[a][1].end.offset-e[a][1].start.offset?(y=2,h=qn(h,[["enter",e[a][1],r],["exit",e[a][1],r]])):y=0,Tn(e,l-1,a-l+3,h),a=l+h.length-y-2;break}}for(a=-1;++a<e.length;)e[a][1].type==="attentionSequence"&&(e[a][1].type="data");return e}function EL(e,r){const a=this.parser.constructs.attentionMarkers.null,l=this.previous,o=ki(l);let s;return c;function c(p){return s=p,e.enter("attentionSequence"),d(p)}function d(p){if(p===s)return e.consume(p),d;const h=e.exit("attentionSequence"),y=ki(p),g=!y||y===2&&o||a.includes(p),b=!o||o===2&&y||a.includes(l);return h._open=!!(s===42?g:g&&(o||!b)),h._close=!!(s===42?b:b&&(y||!g)),r(p)}}function M0(e,r){e.column+=r,e.offset+=r,e._bufferIndex+=r}const CL={name:"autolink",tokenize:AL};function AL(e,r,a){let l=0;return o;function o(w){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(w),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),s}function s(w){return nn(w)?(e.consume(w),c):w===64?a(w):h(w)}function c(w){return w===43||w===45||w===46||Zt(w)?(l=1,d(w)):h(w)}function d(w){return w===58?(e.consume(w),l=0,p):(w===43||w===45||w===46||Zt(w))&&l++<32?(e.consume(w),d):(l=0,h(w))}function p(w){return w===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(w),e.exit("autolinkMarker"),e.exit("autolink"),r):w===null||w===32||w===60||Nc(w)?a(w):(e.consume(w),p)}function h(w){return w===64?(e.consume(w),y):mL(w)?(e.consume(w),h):a(w)}function y(w){return Zt(w)?g(w):a(w)}function g(w){return w===46?(e.consume(w),l=0,y):w===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(w),e.exit("autolinkMarker"),e.exit("autolink"),r):b(w)}function b(w){if((w===45||Zt(w))&&l++<63){const k=w===45?b:g;return e.consume(w),k}return a(w)}}const Es={partial:!0,tokenize:NL};function NL(e,r,a){return l;function l(s){return Ge(s)?Ze(e,o,"linePrefix")(s):o(s)}function o(s){return s===null||Re(s)?r(s):a(s)}}const OE={continuation:{tokenize:TL},exit:_L,name:"blockQuote",tokenize:jL};function jL(e,r,a){const l=this;return o;function o(c){if(c===62){const d=l.containerState;return d.open||(e.enter("blockQuote",{_container:!0}),d.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(c),e.exit("blockQuoteMarker"),s}return a(c)}function s(c){return Ge(c)?(e.enter("blockQuotePrefixWhitespace"),e.consume(c),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),r):(e.exit("blockQuotePrefix"),r(c))}}function TL(e,r,a){const l=this;return o;function o(c){return Ge(c)?Ze(e,s,"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(c):s(c)}function s(c){return e.attempt(OE,r,a)(c)}}function _L(e){e.exit("blockQuote")}const DE={name:"characterEscape",tokenize:RL};function RL(e,r,a){return l;function l(s){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(s),e.exit("escapeMarker"),o}function o(s){return yL(s)?(e.enter("characterEscapeValue"),e.consume(s),e.exit("characterEscapeValue"),e.exit("characterEscape"),r):a(s)}}const zE={name:"characterReference",tokenize:ML};function ML(e,r,a){const l=this;let o=0,s,c;return d;function d(g){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(g),e.exit("characterReferenceMarker"),p}function p(g){return g===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(g),e.exit("characterReferenceMarkerNumeric"),h):(e.enter("characterReferenceValue"),s=31,c=Zt,y(g))}function h(g){return g===88||g===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(g),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),s=6,c=gL,y):(e.enter("characterReferenceValue"),s=7,c=Gh,y(g))}function y(g){if(g===59&&o){const b=e.exit("characterReferenceValue");return c===Zt&&!og(l.sliceSerialize(b))?a(g):(e.enter("characterReferenceMarker"),e.consume(g),e.exit("characterReferenceMarker"),e.exit("characterReference"),r)}return c(g)&&o++<s?(e.consume(g),y):a(g)}}const O0={partial:!0,tokenize:DL},D0={concrete:!0,name:"codeFenced",tokenize:OL};function OL(e,r,a){const l=this,o={partial:!0,tokenize:D};let s=0,c=0,d;return p;function p(M){return h(M)}function h(M){const U=l.events[l.events.length-1];return s=U&&U[1].type==="linePrefix"?U[2].sliceSerialize(U[1],!0).length:0,d=M,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),y(M)}function y(M){return M===d?(c++,e.consume(M),y):c<3?a(M):(e.exit("codeFencedFenceSequence"),Ge(M)?Ze(e,g,"whitespace")(M):g(M))}function g(M){return M===null||Re(M)?(e.exit("codeFencedFence"),l.interrupt?r(M):e.check(O0,S,O)(M)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),b(M))}function b(M){return M===null||Re(M)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),g(M)):Ge(M)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),Ze(e,w,"whitespace")(M)):M===96&&M===d?a(M):(e.consume(M),b)}function w(M){return M===null||Re(M)?g(M):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),k(M))}function k(M){return M===null||Re(M)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),g(M)):M===96&&M===d?a(M):(e.consume(M),k)}function S(M){return e.attempt(o,O,C)(M)}function C(M){return e.enter("lineEnding"),e.consume(M),e.exit("lineEnding"),A}function A(M){return s>0&&Ge(M)?Ze(e,N,"linePrefix",s+1)(M):N(M)}function N(M){return M===null||Re(M)?e.check(O0,S,O)(M):(e.enter("codeFlowValue"),j(M))}function j(M){return M===null||Re(M)?(e.exit("codeFlowValue"),N(M)):(e.consume(M),j)}function O(M){return e.exit("codeFenced"),r(M)}function D(M,U,F){let Q=0;return I;function I(J){return M.enter("lineEnding"),M.consume(J),M.exit("lineEnding"),Y}function Y(J){return M.enter("codeFencedFence"),Ge(J)?Ze(M,V,"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(J):V(J)}function V(J){return J===d?(M.enter("codeFencedFenceSequence"),ue(J)):F(J)}function ue(J){return J===d?(Q++,M.consume(J),ue):Q>=c?(M.exit("codeFencedFenceSequence"),Ge(J)?Ze(M,W,"whitespace")(J):W(J)):F(J)}function W(J){return J===null||Re(J)?(M.exit("codeFencedFence"),U(J)):F(J)}}}function DL(e,r,a){const l=this;return o;function o(c){return c===null?a(c):(e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),s)}function s(c){return l.parser.lazy[l.now().line]?a(c):r(c)}}const lh={name:"codeIndented",tokenize:LL},zL={partial:!0,tokenize:IL};function LL(e,r,a){const l=this;return o;function o(h){return e.enter("codeIndented"),Ze(e,s,"linePrefix",5)(h)}function s(h){const y=l.events[l.events.length-1];return y&&y[1].type==="linePrefix"&&y[2].sliceSerialize(y[1],!0).length>=4?c(h):a(h)}function c(h){return h===null?p(h):Re(h)?e.attempt(zL,c,p)(h):(e.enter("codeFlowValue"),d(h))}function d(h){return h===null||Re(h)?(e.exit("codeFlowValue"),c(h)):(e.consume(h),d)}function p(h){return e.exit("codeIndented"),r(h)}}function IL(e,r,a){const l=this;return o;function o(c){return l.parser.lazy[l.now().line]?a(c):Re(c)?(e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),o):Ze(e,s,"linePrefix",5)(c)}function s(c){const d=l.events[l.events.length-1];return d&&d[1].type==="linePrefix"&&d[2].sliceSerialize(d[1],!0).length>=4?r(c):Re(c)?o(c):a(c)}}const BL={name:"codeText",previous:FL,resolve:PL,tokenize:UL};function PL(e){let r=e.length-4,a=3,l,o;if((e[a][1].type==="lineEnding"||e[a][1].type==="space")&&(e[r][1].type==="lineEnding"||e[r][1].type==="space")){for(l=a;++l<r;)if(e[l][1].type==="codeTextData"){e[a][1].type="codeTextPadding",e[r][1].type="codeTextPadding",a+=2,r-=2;break}}for(l=a-1,r++;++l<=r;)o===void 0?l!==r&&e[l][1].type!=="lineEnding"&&(o=l):(l===r||e[l][1].type==="lineEnding")&&(e[o][1].type="codeTextData",l!==o+2&&(e[o][1].end=e[l-1][1].end,e.splice(o+2,l-o-2),r-=l-o-2,l=o+2),o=void 0);return e}function FL(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function UL(e,r,a){let l=0,o,s;return c;function c(g){return e.enter("codeText"),e.enter("codeTextSequence"),d(g)}function d(g){return g===96?(e.consume(g),l++,d):(e.exit("codeTextSequence"),p(g))}function p(g){return g===null?a(g):g===32?(e.enter("space"),e.consume(g),e.exit("space"),p):g===96?(s=e.enter("codeTextSequence"),o=0,y(g)):Re(g)?(e.enter("lineEnding"),e.consume(g),e.exit("lineEnding"),p):(e.enter("codeTextData"),h(g))}function h(g){return g===null||g===32||g===96||Re(g)?(e.exit("codeTextData"),p(g)):(e.consume(g),h)}function y(g){return g===96?(e.consume(g),o++,y):o===l?(e.exit("codeTextSequence"),e.exit("codeText"),r(g)):(s.type="codeTextData",h(g))}}class HL{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,a){const l=a==null?Number.POSITIVE_INFINITY:a;return l<this.left.length?this.left.slice(r,l):r>this.left.length?this.right.slice(this.right.length-l+this.left.length,this.right.length-r+this.left.length).reverse():this.left.slice(r).concat(this.right.slice(this.right.length-l+this.left.length).reverse())}splice(r,a,l){const o=a||0;this.setCursor(Math.trunc(r));const s=this.right.splice(this.right.length-o,Number.POSITIVE_INFINITY);return l&&Do(this.left,l),s.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),Do(this.left,r)}unshift(r){this.setCursor(0),this.right.push(r)}unshiftMany(r){this.setCursor(0),Do(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 a=this.left.splice(r,Number.POSITIVE_INFINITY);Do(this.right,a.reverse())}else{const a=this.right.splice(this.left.length+this.right.length-r,Number.POSITIVE_INFINITY);Do(this.left,a.reverse())}}}function Do(e,r){let a=0;if(r.length<1e4)e.push(...r);else for(;a<r.length;)e.push(...r.slice(a,a+1e4)),a+=1e4}function LE(e){const r={};let a=-1,l,o,s,c,d,p,h;const y=new HL(e);for(;++a<y.length;){for(;a in r;)a=r[a];if(l=y.get(a),a&&l[1].type==="chunkFlow"&&y.get(a-1)[1].type==="listItemPrefix"&&(p=l[1]._tokenizer.events,s=0,s<p.length&&p[s][1].type==="lineEndingBlank"&&(s+=2),s<p.length&&p[s][1].type==="content"))for(;++s<p.length&&p[s][1].type!=="content";)p[s][1].type==="chunkText"&&(p[s][1]._isInFirstContentOfListItem=!0,s++);if(l[0]==="enter")l[1].contentType&&(Object.assign(r,VL(y,a)),a=r[a],h=!0);else if(l[1]._container){for(s=a,o=void 0;s--;)if(c=y.get(s),c[1].type==="lineEnding"||c[1].type==="lineEndingBlank")c[0]==="enter"&&(o&&(y.get(o)[1].type="lineEndingBlank"),c[1].type="lineEnding",o=s);else if(!(c[1].type==="linePrefix"||c[1].type==="listItemIndent"))break;o&&(l[1].end={...y.get(o)[1].start},d=y.slice(o,a),d.unshift(l),y.splice(o,a-o+1,d))}}return Tn(e,0,Number.POSITIVE_INFINITY,y.slice(0)),!h}function VL(e,r){const a=e.get(r)[1],l=e.get(r)[2];let o=r-1;const s=[];let c=a._tokenizer;c||(c=l.parser[a.contentType](a.start),a._contentTypeTextTrailing&&(c._contentTypeTextTrailing=!0));const d=c.events,p=[],h={};let y,g,b=-1,w=a,k=0,S=0;const C=[S];for(;w;){for(;e.get(++o)[1]!==w;);s.push(o),w._tokenizer||(y=l.sliceStream(w),w.next||y.push(null),g&&c.defineSkip(w.start),w._isInFirstContentOfListItem&&(c._gfmTasklistFirstContentOfListItem=!0),c.write(y),w._isInFirstContentOfListItem&&(c._gfmTasklistFirstContentOfListItem=void 0)),g=w,w=w.next}for(w=a;++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&&(S=b+1,C.push(S),w._tokenizer=void 0,w.previous=void 0,w=w.next);for(c.events=[],w?(w._tokenizer=void 0,w.previous=void 0):C.pop(),b=C.length;b--;){const A=d.slice(C[b],C[b+1]),N=s.pop();p.push([N,N+A.length-1]),e.splice(N,2,A)}for(p.reverse(),b=-1;++b<p.length;)h[k+p[b][0]]=k+p[b][1],k+=p[b][1]-p[b][0]-1;return h}const $L={resolve:GL,tokenize:YL},qL={partial:!0,tokenize:XL};function GL(e){return LE(e),e}function YL(e,r){let a;return l;function l(d){return e.enter("content"),a=e.enter("chunkContent",{contentType:"content"}),o(d)}function o(d){return d===null?s(d):Re(d)?e.check(qL,c,s)(d):(e.consume(d),o)}function s(d){return e.exit("chunkContent"),e.exit("content"),r(d)}function c(d){return e.consume(d),e.exit("chunkContent"),a.next=e.enter("chunkContent",{contentType:"content",previous:a}),a=a.next,o}}function XL(e,r,a){const l=this;return o;function o(c){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),Ze(e,s,"linePrefix")}function s(c){if(c===null||Re(c))return a(c);const d=l.events[l.events.length-1];return!l.parser.constructs.disable.null.includes("codeIndented")&&d&&d[1].type==="linePrefix"&&d[2].sliceSerialize(d[1],!0).length>=4?r(c):e.interrupt(l.parser.constructs.flow,a,r)(c)}}function IE(e,r,a,l,o,s,c,d,p){const h=p||Number.POSITIVE_INFINITY;let y=0;return g;function g(A){return A===60?(e.enter(l),e.enter(o),e.enter(s),e.consume(A),e.exit(s),b):A===null||A===32||A===41||Nc(A)?a(A):(e.enter(l),e.enter(c),e.enter(d),e.enter("chunkString",{contentType:"string"}),S(A))}function b(A){return A===62?(e.enter(s),e.consume(A),e.exit(s),e.exit(o),e.exit(l),r):(e.enter(d),e.enter("chunkString",{contentType:"string"}),w(A))}function w(A){return A===62?(e.exit("chunkString"),e.exit(d),b(A)):A===null||A===60||Re(A)?a(A):(e.consume(A),A===92?k:w)}function k(A){return A===60||A===62||A===92?(e.consume(A),w):w(A)}function S(A){return!y&&(A===null||A===41||ft(A))?(e.exit("chunkString"),e.exit(d),e.exit(c),e.exit(l),r(A)):y<h&&A===40?(e.consume(A),y++,S):A===41?(e.consume(A),y--,S):A===null||A===32||A===40||Nc(A)?a(A):(e.consume(A),A===92?C:S)}function C(A){return A===40||A===41||A===92?(e.consume(A),S):S(A)}}function BE(e,r,a,l,o,s){const c=this;let d=0,p;return h;function h(w){return e.enter(l),e.enter(o),e.consume(w),e.exit(o),e.enter(s),y}function y(w){return d>999||w===null||w===91||w===93&&!p||w===94&&!d&&"_hiddenFootnoteSupport"in c.parser.constructs?a(w):w===93?(e.exit(s),e.enter(o),e.consume(w),e.exit(o),e.exit(l),r):Re(w)?(e.enter("lineEnding"),e.consume(w),e.exit("lineEnding"),y):(e.enter("chunkString",{contentType:"string"}),g(w))}function g(w){return w===null||w===91||w===93||Re(w)||d++>999?(e.exit("chunkString"),y(w)):(e.consume(w),p||(p=!Ge(w)),w===92?b:g)}function b(w){return w===91||w===92||w===93?(e.consume(w),d++,g):g(w)}}function PE(e,r,a,l,o,s){let c;return d;function d(b){return b===34||b===39||b===40?(e.enter(l),e.enter(o),e.consume(b),e.exit(o),c=b===40?41:b,p):a(b)}function p(b){return b===c?(e.enter(o),e.consume(b),e.exit(o),e.exit(l),r):(e.enter(s),h(b))}function h(b){return b===c?(e.exit(s),p(c)):b===null?a(b):Re(b)?(e.enter("lineEnding"),e.consume(b),e.exit("lineEnding"),Ze(e,h,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),y(b))}function y(b){return b===c||b===null||Re(b)?(e.exit("chunkString"),h(b)):(e.consume(b),b===92?g:y)}function g(b){return b===c||b===92?(e.consume(b),y):y(b)}}function Uo(e,r){let a;return l;function l(o){return Re(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),a=!0,l):Ge(o)?Ze(e,l,a?"linePrefix":"lineSuffix")(o):r(o)}}const KL={name:"definition",tokenize:ZL},QL={partial:!0,tokenize:WL};function ZL(e,r,a){const l=this;let o;return s;function s(w){return e.enter("definition"),c(w)}function c(w){return BE.call(l,e,d,a,"definitionLabel","definitionLabelMarker","definitionLabelString")(w)}function d(w){return o=tr(l.sliceSerialize(l.events[l.events.length-1][1]).slice(1,-1)),w===58?(e.enter("definitionMarker"),e.consume(w),e.exit("definitionMarker"),p):a(w)}function p(w){return ft(w)?Uo(e,h)(w):h(w)}function h(w){return IE(e,y,a,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(w)}function y(w){return e.attempt(QL,g,g)(w)}function g(w){return Ge(w)?Ze(e,b,"whitespace")(w):b(w)}function b(w){return w===null||Re(w)?(e.exit("definition"),l.parser.defined.push(o),r(w)):a(w)}}function WL(e,r,a){return l;function l(d){return ft(d)?Uo(e,o)(d):a(d)}function o(d){return PE(e,s,a,"definitionTitle","definitionTitleMarker","definitionTitleString")(d)}function s(d){return Ge(d)?Ze(e,c,"whitespace")(d):c(d)}function c(d){return d===null||Re(d)?r(d):a(d)}}const JL={name:"hardBreakEscape",tokenize:e6};function e6(e,r,a){return l;function l(s){return e.enter("hardBreakEscape"),e.consume(s),o}function o(s){return Re(s)?(e.exit("hardBreakEscape"),r(s)):a(s)}}const t6={name:"headingAtx",resolve:n6,tokenize:r6};function n6(e,r){let a=e.length-2,l=3,o,s;return e[l][1].type==="whitespace"&&(l+=2),a-2>l&&e[a][1].type==="whitespace"&&(a-=2),e[a][1].type==="atxHeadingSequence"&&(l===a-1||a-4>l&&e[a-2][1].type==="whitespace")&&(a-=l+1===a?2:4),a>l&&(o={type:"atxHeadingText",start:e[l][1].start,end:e[a][1].end},s={type:"chunkText",start:e[l][1].start,end:e[a][1].end,contentType:"text"},Tn(e,l,a-l+1,[["enter",o,r],["enter",s,r],["exit",s,r],["exit",o,r]])),e}function r6(e,r,a){let l=0;return o;function o(y){return e.enter("atxHeading"),s(y)}function s(y){return e.enter("atxHeadingSequence"),c(y)}function c(y){return y===35&&l++<6?(e.consume(y),c):y===null||ft(y)?(e.exit("atxHeadingSequence"),d(y)):a(y)}function d(y){return y===35?(e.enter("atxHeadingSequence"),p(y)):y===null||Re(y)?(e.exit("atxHeading"),r(y)):Ge(y)?Ze(e,d,"whitespace")(y):(e.enter("atxHeadingText"),h(y))}function p(y){return y===35?(e.consume(y),p):(e.exit("atxHeadingSequence"),d(y))}function h(y){return y===null||y===35||ft(y)?(e.exit("atxHeadingText"),d(y)):(e.consume(y),h)}}const a6=["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"],z0=["pre","script","style","textarea"],l6={concrete:!0,name:"htmlFlow",resolveTo:s6,tokenize:u6},i6={partial:!0,tokenize:d6},o6={partial:!0,tokenize:c6};function s6(e){let r=e.length;for(;r--&&!(e[r][0]==="enter"&&e[r][1].type==="htmlFlow"););return r>1&&e[r-2][1].type==="linePrefix"&&(e[r][1].start=e[r-2][1].start,e[r+1][1].start=e[r-2][1].start,e.splice(r-2,2)),e}function u6(e,r,a){const l=this;let o,s,c,d,p;return h;function h(_){return y(_)}function y(_){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(_),g}function g(_){return _===33?(e.consume(_),b):_===47?(e.consume(_),s=!0,S):_===63?(e.consume(_),o=3,l.interrupt?r:R):nn(_)?(e.consume(_),c=String.fromCharCode(_),C):a(_)}function b(_){return _===45?(e.consume(_),o=2,w):_===91?(e.consume(_),o=5,d=0,k):nn(_)?(e.consume(_),o=4,l.interrupt?r:R):a(_)}function w(_){return _===45?(e.consume(_),l.interrupt?r:R):a(_)}function k(_){const re="CDATA[";return _===re.charCodeAt(d++)?(e.consume(_),d===re.length?l.interrupt?r:V:k):a(_)}function S(_){return nn(_)?(e.consume(_),c=String.fromCharCode(_),C):a(_)}function C(_){if(_===null||_===47||_===62||ft(_)){const re=_===47,ne=c.toLowerCase();return!re&&!s&&z0.includes(ne)?(o=1,l.interrupt?r(_):V(_)):a6.includes(c.toLowerCase())?(o=6,re?(e.consume(_),A):l.interrupt?r(_):V(_)):(o=7,l.interrupt&&!l.parser.lazy[l.now().line]?a(_):s?N(_):j(_))}return _===45||Zt(_)?(e.consume(_),c+=String.fromCharCode(_),C):a(_)}function A(_){return _===62?(e.consume(_),l.interrupt?r:V):a(_)}function N(_){return Ge(_)?(e.consume(_),N):I(_)}function j(_){return _===47?(e.consume(_),I):_===58||_===95||nn(_)?(e.consume(_),O):Ge(_)?(e.consume(_),j):I(_)}function O(_){return _===45||_===46||_===58||_===95||Zt(_)?(e.consume(_),O):D(_)}function D(_){return _===61?(e.consume(_),M):Ge(_)?(e.consume(_),D):j(_)}function M(_){return _===null||_===60||_===61||_===62||_===96?a(_):_===34||_===39?(e.consume(_),p=_,U):Ge(_)?(e.consume(_),M):F(_)}function U(_){return _===p?(e.consume(_),p=null,Q):_===null||Re(_)?a(_):(e.consume(_),U)}function F(_){return _===null||_===34||_===39||_===47||_===60||_===61||_===62||_===96||ft(_)?D(_):(e.consume(_),F)}function Q(_){return _===47||_===62||Ge(_)?j(_):a(_)}function I(_){return _===62?(e.consume(_),Y):a(_)}function Y(_){return _===null||Re(_)?V(_):Ge(_)?(e.consume(_),Y):a(_)}function V(_){return _===45&&o===2?(e.consume(_),B):_===60&&o===1?(e.consume(_),G):_===62&&o===4?(e.consume(_),z):_===63&&o===3?(e.consume(_),R):_===93&&o===5?(e.consume(_),ce):Re(_)&&(o===6||o===7)?(e.exit("htmlFlowData"),e.check(i6,L,ue)(_)):_===null||Re(_)?(e.exit("htmlFlowData"),ue(_)):(e.consume(_),V)}function ue(_){return e.check(o6,W,L)(_)}function W(_){return e.enter("lineEnding"),e.consume(_),e.exit("lineEnding"),J}function J(_){return _===null||Re(_)?ue(_):(e.enter("htmlFlowData"),V(_))}function B(_){return _===45?(e.consume(_),R):V(_)}function G(_){return _===47?(e.consume(_),c="",te):V(_)}function te(_){if(_===62){const re=c.toLowerCase();return z0.includes(re)?(e.consume(_),z):V(_)}return nn(_)&&c.length<8?(e.consume(_),c+=String.fromCharCode(_),te):V(_)}function ce(_){return _===93?(e.consume(_),R):V(_)}function R(_){return _===62?(e.consume(_),z):_===45&&o===2?(e.consume(_),R):V(_)}function z(_){return _===null||Re(_)?(e.exit("htmlFlowData"),L(_)):(e.consume(_),z)}function L(_){return e.exit("htmlFlow"),r(_)}}function c6(e,r,a){const l=this;return o;function o(c){return Re(c)?(e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),s):a(c)}function s(c){return l.parser.lazy[l.now().line]?a(c):r(c)}}function d6(e,r,a){return l;function l(o){return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),e.attempt(Es,r,a)}}const f6={name:"htmlText",tokenize:p6};function p6(e,r,a){const l=this;let o,s,c;return d;function d(R){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(R),p}function p(R){return R===33?(e.consume(R),h):R===47?(e.consume(R),D):R===63?(e.consume(R),j):nn(R)?(e.consume(R),F):a(R)}function h(R){return R===45?(e.consume(R),y):R===91?(e.consume(R),s=0,k):nn(R)?(e.consume(R),N):a(R)}function y(R){return R===45?(e.consume(R),w):a(R)}function g(R){return R===null?a(R):R===45?(e.consume(R),b):Re(R)?(c=g,G(R)):(e.consume(R),g)}function b(R){return R===45?(e.consume(R),w):g(R)}function w(R){return R===62?B(R):R===45?b(R):g(R)}function k(R){const z="CDATA[";return R===z.charCodeAt(s++)?(e.consume(R),s===z.length?S:k):a(R)}function S(R){return R===null?a(R):R===93?(e.consume(R),C):Re(R)?(c=S,G(R)):(e.consume(R),S)}function C(R){return R===93?(e.consume(R),A):S(R)}function A(R){return R===62?B(R):R===93?(e.consume(R),A):S(R)}function N(R){return R===null||R===62?B(R):Re(R)?(c=N,G(R)):(e.consume(R),N)}function j(R){return R===null?a(R):R===63?(e.consume(R),O):Re(R)?(c=j,G(R)):(e.consume(R),j)}function O(R){return R===62?B(R):j(R)}function D(R){return nn(R)?(e.consume(R),M):a(R)}function M(R){return R===45||Zt(R)?(e.consume(R),M):U(R)}function U(R){return Re(R)?(c=U,G(R)):Ge(R)?(e.consume(R),U):B(R)}function F(R){return R===45||Zt(R)?(e.consume(R),F):R===47||R===62||ft(R)?Q(R):a(R)}function Q(R){return R===47?(e.consume(R),B):R===58||R===95||nn(R)?(e.consume(R),I):Re(R)?(c=Q,G(R)):Ge(R)?(e.consume(R),Q):B(R)}function I(R){return R===45||R===46||R===58||R===95||Zt(R)?(e.consume(R),I):Y(R)}function Y(R){return R===61?(e.consume(R),V):Re(R)?(c=Y,G(R)):Ge(R)?(e.consume(R),Y):Q(R)}function V(R){return R===null||R===60||R===61||R===62||R===96?a(R):R===34||R===39?(e.consume(R),o=R,ue):Re(R)?(c=V,G(R)):Ge(R)?(e.consume(R),V):(e.consume(R),W)}function ue(R){return R===o?(e.consume(R),o=void 0,J):R===null?a(R):Re(R)?(c=ue,G(R)):(e.consume(R),ue)}function W(R){return R===null||R===34||R===39||R===60||R===61||R===96?a(R):R===47||R===62||ft(R)?Q(R):(e.consume(R),W)}function J(R){return R===47||R===62||ft(R)?Q(R):a(R)}function B(R){return R===62?(e.consume(R),e.exit("htmlTextData"),e.exit("htmlText"),r):a(R)}function G(R){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(R),e.exit("lineEnding"),te}function te(R){return Ge(R)?Ze(e,ce,"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(R):ce(R)}function ce(R){return e.enter("htmlTextData"),c(R)}}const sg={name:"labelEnd",resolveAll:y6,resolveTo:x6,tokenize:b6},h6={tokenize:v6},m6={tokenize:w6},g6={tokenize:S6};function y6(e){let r=-1;const a=[];for(;++r<e.length;){const l=e[r][1];if(a.push(e[r]),l.type==="labelImage"||l.type==="labelLink"||l.type==="labelEnd"){const o=l.type==="labelImage"?4:2;l.type="data",r+=o}}return e.length!==a.length&&Tn(e,0,e.length,a),e}function x6(e,r){let a=e.length,l=0,o,s,c,d;for(;a--;)if(o=e[a][1],s){if(o.type==="link"||o.type==="labelLink"&&o._inactive)break;e[a][0]==="enter"&&o.type==="labelLink"&&(o._inactive=!0)}else if(c){if(e[a][0]==="enter"&&(o.type==="labelImage"||o.type==="labelLink")&&!o._balanced&&(s=a,o.type!=="labelLink")){l=2;break}}else o.type==="labelEnd"&&(c=a);const p={type:e[s][1].type==="labelLink"?"link":"image",start:{...e[s][1].start},end:{...e[e.length-1][1].end}},h={type:"label",start:{...e[s][1].start},end:{...e[c][1].end}},y={type:"labelText",start:{...e[s+l+2][1].end},end:{...e[c-2][1].start}};return d=[["enter",p,r],["enter",h,r]],d=qn(d,e.slice(s+1,s+l+3)),d=qn(d,[["enter",y,r]]),d=qn(d,md(r.parser.constructs.insideSpan.null,e.slice(s+l+4,c-3),r)),d=qn(d,[["exit",y,r],e[c-2],e[c-1],["exit",h,r]]),d=qn(d,e.slice(c+1)),d=qn(d,[["exit",p,r]]),Tn(e,s,e.length,d),e}function b6(e,r,a){const l=this;let o=l.events.length,s,c;for(;o--;)if((l.events[o][1].type==="labelImage"||l.events[o][1].type==="labelLink")&&!l.events[o][1]._balanced){s=l.events[o][1];break}return d;function d(b){return s?s._inactive?g(b):(c=l.parser.defined.includes(tr(l.sliceSerialize({start:s.end,end:l.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(b),e.exit("labelMarker"),e.exit("labelEnd"),p):a(b)}function p(b){return b===40?e.attempt(h6,y,c?y:g)(b):b===91?e.attempt(m6,y,c?h:g)(b):c?y(b):g(b)}function h(b){return e.attempt(g6,y,g)(b)}function y(b){return r(b)}function g(b){return s._balanced=!0,a(b)}}function v6(e,r,a){return l;function l(g){return e.enter("resource"),e.enter("resourceMarker"),e.consume(g),e.exit("resourceMarker"),o}function o(g){return ft(g)?Uo(e,s)(g):s(g)}function s(g){return g===41?y(g):IE(e,c,d,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(g)}function c(g){return ft(g)?Uo(e,p)(g):y(g)}function d(g){return a(g)}function p(g){return g===34||g===39||g===40?PE(e,h,a,"resourceTitle","resourceTitleMarker","resourceTitleString")(g):y(g)}function h(g){return ft(g)?Uo(e,y)(g):y(g)}function y(g){return g===41?(e.enter("resourceMarker"),e.consume(g),e.exit("resourceMarker"),e.exit("resource"),r):a(g)}}function w6(e,r,a){const l=this;return o;function o(d){return BE.call(l,e,s,c,"reference","referenceMarker","referenceString")(d)}function s(d){return l.parser.defined.includes(tr(l.sliceSerialize(l.events[l.events.length-1][1]).slice(1,-1)))?r(d):a(d)}function c(d){return a(d)}}function S6(e,r,a){return l;function l(s){return e.enter("reference"),e.enter("referenceMarker"),e.consume(s),e.exit("referenceMarker"),o}function o(s){return s===93?(e.enter("referenceMarker"),e.consume(s),e.exit("referenceMarker"),e.exit("reference"),r):a(s)}}const k6={name:"labelStartImage",resolveAll:sg.resolveAll,tokenize:E6};function E6(e,r,a){const l=this;return o;function o(d){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(d),e.exit("labelImageMarker"),s}function s(d){return d===91?(e.enter("labelMarker"),e.consume(d),e.exit("labelMarker"),e.exit("labelImage"),c):a(d)}function c(d){return d===94&&"_hiddenFootnoteSupport"in l.parser.constructs?a(d):r(d)}}const C6={name:"labelStartLink",resolveAll:sg.resolveAll,tokenize:A6};function A6(e,r,a){const l=this;return o;function o(c){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(c),e.exit("labelMarker"),e.exit("labelLink"),s}function s(c){return c===94&&"_hiddenFootnoteSupport"in l.parser.constructs?a(c):r(c)}}const ih={name:"lineEnding",tokenize:N6};function N6(e,r){return a;function a(l){return e.enter("lineEnding"),e.consume(l),e.exit("lineEnding"),Ze(e,r,"linePrefix")}}const uc={name:"thematicBreak",tokenize:j6};function j6(e,r,a){let l=0,o;return s;function s(h){return e.enter("thematicBreak"),c(h)}function c(h){return o=h,d(h)}function d(h){return h===o?(e.enter("thematicBreakSequence"),p(h)):l>=3&&(h===null||Re(h))?(e.exit("thematicBreak"),r(h)):a(h)}function p(h){return h===o?(e.consume(h),l++,p):(e.exit("thematicBreakSequence"),Ge(h)?Ze(e,d,"whitespace")(h):d(h))}}const pn={continuation:{tokenize:M6},exit:D6,name:"list",tokenize:R6},T6={partial:!0,tokenize:z6},_6={partial:!0,tokenize:O6};function R6(e,r,a){const l=this,o=l.events[l.events.length-1];let s=o&&o[1].type==="linePrefix"?o[2].sliceSerialize(o[1],!0).length:0,c=0;return d;function d(w){const k=l.containerState.type||(w===42||w===43||w===45?"listUnordered":"listOrdered");if(k==="listUnordered"?!l.containerState.marker||w===l.containerState.marker:Gh(w)){if(l.containerState.type||(l.containerState.type=k,e.enter(k,{_container:!0})),k==="listUnordered")return e.enter("listItemPrefix"),w===42||w===45?e.check(uc,a,h)(w):h(w);if(!l.interrupt||w===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),p(w)}return a(w)}function p(w){return Gh(w)&&++c<10?(e.consume(w),p):(!l.interrupt||c<2)&&(l.containerState.marker?w===l.containerState.marker:w===41||w===46)?(e.exit("listItemValue"),h(w)):a(w)}function h(w){return e.enter("listItemMarker"),e.consume(w),e.exit("listItemMarker"),l.containerState.marker=l.containerState.marker||w,e.check(Es,l.interrupt?a:y,e.attempt(T6,b,g))}function y(w){return l.containerState.initialBlankLine=!0,s++,b(w)}function g(w){return Ge(w)?(e.enter("listItemPrefixWhitespace"),e.consume(w),e.exit("listItemPrefixWhitespace"),b):a(w)}function b(w){return l.containerState.size=s+l.sliceSerialize(e.exit("listItemPrefix"),!0).length,r(w)}}function M6(e,r,a){const l=this;return l.containerState._closeFlow=void 0,e.check(Es,o,s);function o(d){return l.containerState.furtherBlankLines=l.containerState.furtherBlankLines||l.containerState.initialBlankLine,Ze(e,r,"listItemIndent",l.containerState.size+1)(d)}function s(d){return l.containerState.furtherBlankLines||!Ge(d)?(l.containerState.furtherBlankLines=void 0,l.containerState.initialBlankLine=void 0,c(d)):(l.containerState.furtherBlankLines=void 0,l.containerState.initialBlankLine=void 0,e.attempt(_6,r,c)(d))}function c(d){return l.containerState._closeFlow=!0,l.interrupt=void 0,Ze(e,e.attempt(pn,r,a),"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(d)}}function O6(e,r,a){const l=this;return Ze(e,o,"listItemIndent",l.containerState.size+1);function o(s){const c=l.events[l.events.length-1];return c&&c[1].type==="listItemIndent"&&c[2].sliceSerialize(c[1],!0).length===l.containerState.size?r(s):a(s)}}function D6(e){e.exit(this.containerState.type)}function z6(e,r,a){const l=this;return Ze(e,o,"listItemPrefixWhitespace",l.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function o(s){const c=l.events[l.events.length-1];return!Ge(s)&&c&&c[1].type==="listItemPrefixWhitespace"?r(s):a(s)}}const L0={name:"setextUnderline",resolveTo:L6,tokenize:I6};function L6(e,r){let a=e.length,l,o,s;for(;a--;)if(e[a][0]==="enter"){if(e[a][1].type==="content"){l=a;break}e[a][1].type==="paragraph"&&(o=a)}else e[a][1].type==="content"&&e.splice(a,1),!s&&e[a][1].type==="definition"&&(s=a);const c={type:"setextHeading",start:{...e[l][1].start},end:{...e[e.length-1][1].end}};return e[o][1].type="setextHeadingText",s?(e.splice(o,0,["enter",c,r]),e.splice(s+1,0,["exit",e[l][1],r]),e[l][1].end={...e[s][1].end}):e[l][1]=c,e.push(["exit",c,r]),e}function I6(e,r,a){const l=this;let o;return s;function s(h){let y=l.events.length,g;for(;y--;)if(l.events[y][1].type!=="lineEnding"&&l.events[y][1].type!=="linePrefix"&&l.events[y][1].type!=="content"){g=l.events[y][1].type==="paragraph";break}return!l.parser.lazy[l.now().line]&&(l.interrupt||g)?(e.enter("setextHeadingLine"),o=h,c(h)):a(h)}function c(h){return e.enter("setextHeadingLineSequence"),d(h)}function d(h){return h===o?(e.consume(h),d):(e.exit("setextHeadingLineSequence"),Ge(h)?Ze(e,p,"lineSuffix")(h):p(h))}function p(h){return h===null||Re(h)?(e.exit("setextHeadingLine"),r(h)):a(h)}}const B6={tokenize:P6};function P6(e){const r=this,a=e.attempt(Es,l,e.attempt(this.parser.constructs.flowInitial,o,Ze(e,e.attempt(this.parser.constructs.flow,o,e.attempt($L,o)),"linePrefix")));return a;function l(s){if(s===null){e.consume(s);return}return e.enter("lineEndingBlank"),e.consume(s),e.exit("lineEndingBlank"),r.currentConstruct=void 0,a}function o(s){if(s===null){e.consume(s);return}return e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),r.currentConstruct=void 0,a}}const F6={resolveAll:UE()},U6=FE("string"),H6=FE("text");function FE(e){return{resolveAll:UE(e==="text"?V6:void 0),tokenize:r};function r(a){const l=this,o=this.parser.constructs[e],s=a.attempt(o,c,d);return c;function c(y){return h(y)?s(y):d(y)}function d(y){if(y===null){a.consume(y);return}return a.enter("data"),a.consume(y),p}function p(y){return h(y)?(a.exit("data"),s(y)):(a.consume(y),p)}function h(y){if(y===null)return!0;const g=o[y];let b=-1;if(g)for(;++b<g.length;){const w=g[b];if(!w.previous||w.previous.call(l,l.previous))return!0}return!1}}}function UE(e){return r;function r(a,l){let o=-1,s;for(;++o<=a.length;)s===void 0?a[o]&&a[o][1].type==="data"&&(s=o,o++):(!a[o]||a[o][1].type!=="data")&&(o!==s+2&&(a[s][1].end=a[o-1][1].end,a.splice(s+2,o-s-2),o=s+2),s=void 0);return e?e(a,l):a}}function V6(e,r){let a=0;for(;++a<=e.length;)if((a===e.length||e[a][1].type==="lineEnding")&&e[a-1][1].type==="data"){const l=e[a-1][1],o=r.sliceStream(l);let s=o.length,c=-1,d=0,p;for(;s--;){const h=o[s];if(typeof h=="string"){for(c=h.length;h.charCodeAt(c-1)===32;)d++,c--;if(c)break;c=-1}else if(h===-2)p=!0,d++;else if(h!==-1){s++;break}}if(r._contentTypeTextTrailing&&a===e.length&&(d=0),d){const h={type:a===e.length||p||d<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:s?c:l.start._bufferIndex+c,_index:l.start._index+s,line:l.end.line,column:l.end.column-d,offset:l.end.offset-d},end:{...l.end}};l.end={...h.start},l.start.offset===l.end.offset?Object.assign(l,h):(e.splice(a,0,["enter",h,r],["exit",h,r]),a+=2)}a++}return e}const $6={42:pn,43:pn,45:pn,48:pn,49:pn,50:pn,51:pn,52:pn,53:pn,54:pn,55:pn,56:pn,57:pn,62:OE},q6={91:KL},G6={[-2]:lh,[-1]:lh,32:lh},Y6={35:t6,42:uc,45:[L0,uc],60:l6,61:L0,95:uc,96:D0,126:D0},X6={38:zE,92:DE},K6={[-5]:ih,[-4]:ih,[-3]:ih,33:k6,38:zE,42:Yh,60:[CL,f6],91:C6,92:[JL,DE],93:sg,95:Yh,96:BL},Q6={null:[Yh,F6]},Z6={null:[42,95]},W6={null:[]},J6=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:Z6,contentInitial:q6,disable:W6,document:$6,flow:Y6,flowInitial:G6,insideSpan:Q6,string:X6,text:K6},Symbol.toStringTag,{value:"Module"}));function eI(e,r,a){let l={_bufferIndex:-1,_index:0,line:a&&a.line||1,column:a&&a.column||1,offset:a&&a.offset||0};const o={},s=[];let c=[],d=[];const p={attempt:U(D),check:U(M),consume:N,enter:j,exit:O,interrupt:U(M,{interrupt:!0})},h={code:null,containerState:{},defineSkip:S,events:[],now:k,parser:e,previous:null,sliceSerialize:b,sliceStream:w,write:g};let y=r.tokenize.call(h,p);return r.resolveAll&&s.push(r),h;function g(Y){return c=qn(c,Y),C(),c[c.length-1]!==null?[]:(F(r,0),h.events=md(s,h.events,h),h.events)}function b(Y,V){return nI(w(Y),V)}function w(Y){return tI(c,Y)}function k(){const{_bufferIndex:Y,_index:V,line:ue,column:W,offset:J}=l;return{_bufferIndex:Y,_index:V,line:ue,column:W,offset:J}}function S(Y){o[Y.line]=Y.column,I()}function C(){let Y;for(;l._index<c.length;){const V=c[l._index];if(typeof V=="string")for(Y=l._index,l._bufferIndex<0&&(l._bufferIndex=0);l._index===Y&&l._bufferIndex<V.length;)A(V.charCodeAt(l._bufferIndex));else A(V)}}function A(Y){y=y(Y)}function N(Y){Re(Y)?(l.line++,l.column=1,l.offset+=Y===-3?2:1,I()):Y!==-1&&(l.column++,l.offset++),l._bufferIndex<0?l._index++:(l._bufferIndex++,l._bufferIndex===c[l._index].length&&(l._bufferIndex=-1,l._index++)),h.previous=Y}function j(Y,V){const ue=V||{};return ue.type=Y,ue.start=k(),h.events.push(["enter",ue,h]),d.push(ue),ue}function O(Y){const V=d.pop();return V.end=k(),h.events.push(["exit",V,h]),V}function D(Y,V){F(Y,V.from)}function M(Y,V){V.restore()}function U(Y,V){return ue;function ue(W,J,B){let G,te,ce,R;return Array.isArray(W)?L(W):"tokenize"in W?L([W]):z(W);function z(ie){return le;function le(be){const he=be!==null&&ie[be],Ne=be!==null&&ie.null,De=[...Array.isArray(he)?he:he?[he]:[],...Array.isArray(Ne)?Ne:Ne?[Ne]:[]];return L(De)(be)}}function L(ie){return G=ie,te=0,ie.length===0?B:_(ie[te])}function _(ie){return le;function le(be){return R=Q(),ce=ie,ie.partial||(h.currentConstruct=ie),ie.name&&h.parser.constructs.disable.null.includes(ie.name)?ne():ie.tokenize.call(V?Object.assign(Object.create(h),V):h,p,re,ne)(be)}}function re(ie){return Y(ce,R),J}function ne(ie){return R.restore(),++te<G.length?_(G[te]):B}}}function F(Y,V){Y.resolveAll&&!s.includes(Y)&&s.push(Y),Y.resolve&&Tn(h.events,V,h.events.length-V,Y.resolve(h.events.slice(V),h)),Y.resolveTo&&(h.events=Y.resolveTo(h.events,h))}function Q(){const Y=k(),V=h.previous,ue=h.currentConstruct,W=h.events.length,J=Array.from(d);return{from:W,restore:B};function B(){l=Y,h.previous=V,h.currentConstruct=ue,h.events.length=W,d=J,I()}}function I(){l.line in o&&l.column<2&&(l.column=o[l.line],l.offset+=o[l.line]-1)}}function tI(e,r){const a=r.start._index,l=r.start._bufferIndex,o=r.end._index,s=r.end._bufferIndex;let c;if(a===o)c=[e[a].slice(l,s)];else{if(c=e.slice(a,o),l>-1){const d=c[0];typeof d=="string"?c[0]=d.slice(l):c.shift()}s>0&&c.push(e[o].slice(0,s))}return c}function nI(e,r){let a=-1;const l=[];let o;for(;++a<e.length;){const s=e[a];let c;if(typeof s=="string")c=s;else switch(s){case-5:{c="\r";break}case-4:{c=`
418
- `;break}case-3:{c=`\r
419
- `;break}case-2:{c=r?" ":" ";break}case-1:{if(!r&&o)continue;c=" ";break}default:c=String.fromCharCode(s)}o=s===-2,l.push(c)}return l.join("")}function rI(e){const l={constructs:RE([J6,...(e||{}).extensions||[]]),content:o(xL),defined:[],document:o(vL),flow:o(B6),lazy:{},string:o(U6),text:o(H6)};return l;function o(s){return c;function c(d){return eI(l,s,d)}}}function aI(e){for(;!LE(e););return e}const I0=/[\0\t\n\r]/g;function lI(){let e=1,r="",a=!0,l;return o;function o(s,c,d){const p=[];let h,y,g,b,w;for(s=r+(typeof s=="string"?s.toString():new TextDecoder(c||void 0).decode(s)),g=0,r="",a&&(s.charCodeAt(0)===65279&&g++,a=void 0);g<s.length;){if(I0.lastIndex=g,h=I0.exec(s),b=h&&h.index!==void 0?h.index:s.length,w=s.charCodeAt(b),!h){r=s.slice(g);break}if(w===10&&g===b&&l)p.push(-3),l=void 0;else switch(l&&(p.push(-5),l=void 0),g<b&&(p.push(s.slice(g,b)),e+=b-g),w){case 0:{p.push(65533),e++;break}case 9:{for(y=Math.ceil(e/4)*4,p.push(-2);e++<y;)p.push(-1);break}case 10:{p.push(-4),e=1;break}default:l=!0,e=1}g=b+1}return d&&(l&&p.push(-5),r&&p.push(r),p.push(null)),p}}const iI=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function oI(e){return e.replace(iI,sI)}function sI(e,r,a){if(r)return r;if(a.charCodeAt(0)===35){const o=a.charCodeAt(1),s=o===120||o===88;return ME(a.slice(s?2:1),s?16:10)}return og(a)||e}const HE={}.hasOwnProperty;function uI(e,r,a){return r&&typeof r=="object"&&(a=r,r=void 0),cI(a)(aI(rI(a).document().write(lI()(e,r,!0))))}function cI(e){const r={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:s(Mn),autolinkProtocol:Q,autolinkEmail:Q,atxHeading:s(Ot),blockQuote:s(Ne),characterEscape:Q,characterReference:Q,codeFenced:s(De),codeFencedFenceInfo:c,codeFencedFenceMeta:c,codeIndented:s(De,c),codeText:s(ze,c),codeTextData:Q,data:Q,codeFlowValue:Q,definition:s(gt),definitionDestinationString:c,definitionLabelString:c,definitionTitleString:c,emphasis:s(nt),hardBreakEscape:s(Jt),hardBreakTrailing:s(Jt),htmlFlow:s(Gt,c),htmlFlowData:Q,htmlText:s(Gt,c),htmlTextData:Q,image:s(Rn),label:c,link:s(Mn),listItem:s(On),listItemValue:b,listOrdered:s(an,g),listUnordered:s(an),paragraph:s(br),reference:_,referenceString:c,resourceDestinationString:c,resourceTitleString:c,setextHeading:s(Ot),strong:s(Oi),thematicBreak:s(Di)},exit:{atxHeading:p(),atxHeadingSequence:D,autolink:p(),autolinkEmail:he,autolinkProtocol:be,blockQuote:p(),characterEscapeValue:I,characterReferenceMarkerHexadecimal:ne,characterReferenceMarkerNumeric:ne,characterReferenceValue:ie,characterReference:le,codeFenced:p(C),codeFencedFence:S,codeFencedFenceInfo:w,codeFencedFenceMeta:k,codeFlowValue:I,codeIndented:p(A),codeText:p(J),codeTextData:I,data:I,definition:p(),definitionDestinationString:O,definitionLabelString:N,definitionTitleString:j,emphasis:p(),hardBreakEscape:p(V),hardBreakTrailing:p(V),htmlFlow:p(ue),htmlFlowData:I,htmlText:p(W),htmlTextData:I,image:p(G),label:ce,labelText:te,lineEnding:Y,link:p(B),listItem:p(),listOrdered:p(),listUnordered:p(),paragraph:p(),referenceString:re,resourceDestinationString:R,resourceTitleString:z,resource:L,setextHeading:p(F),setextHeadingLineSequence:U,setextHeadingText:M,strong:p(),thematicBreak:p()}};VE(r,(e||{}).mdastExtensions||[]);const a={};return l;function l(oe){let xe={type:"root",children:[]};const Te={stack:[xe],tokenStack:[],config:r,enter:d,exit:h,buffer:c,resume:y,data:a},Ie=[];let rt=-1;for(;++rt<oe.length;)if(oe[rt][1].type==="listOrdered"||oe[rt][1].type==="listUnordered")if(oe[rt][0]==="enter")Ie.push(rt);else{const Pt=Ie.pop();rt=o(oe,Pt,rt)}for(rt=-1;++rt<oe.length;){const Pt=r[oe[rt][0]];HE.call(Pt,oe[rt][1].type)&&Pt[oe[rt][1].type].call(Object.assign({sliceSerialize:oe[rt][2].sliceSerialize},Te),oe[rt][1])}if(Te.tokenStack.length>0){const Pt=Te.tokenStack[Te.tokenStack.length-1];(Pt[1]||B0).call(Te,void 0,Pt[0])}for(xe.position={start:ka(oe.length>0?oe[0][1].start:{line:1,column:1,offset:0}),end:ka(oe.length>0?oe[oe.length-2][1].end:{line:1,column:1,offset:0})},rt=-1;++rt<r.transforms.length;)xe=r.transforms[rt](xe)||xe;return xe}function o(oe,xe,Te){let Ie=xe-1,rt=-1,Pt=!1,Je,He,yt,zt;for(;++Ie<=Te;){const lt=oe[Ie];switch(lt[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{lt[0]==="enter"?rt++:rt--,zt=void 0;break}case"lineEndingBlank":{lt[0]==="enter"&&(Je&&!zt&&!rt&&!yt&&(yt=Ie),zt=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:zt=void 0}if(!rt&&lt[0]==="enter"&&lt[1].type==="listItemPrefix"||rt===-1&&lt[0]==="exit"&&(lt[1].type==="listUnordered"||lt[1].type==="listOrdered")){if(Je){let Yt=Ie;for(He=void 0;Yt--;){const mn=oe[Yt];if(mn[1].type==="lineEnding"||mn[1].type==="lineEndingBlank"){if(mn[0]==="exit")continue;He&&(oe[He][1].type="lineEndingBlank",Pt=!0),mn[1].type="lineEnding",He=Yt}else if(!(mn[1].type==="linePrefix"||mn[1].type==="blockQuotePrefix"||mn[1].type==="blockQuotePrefixWhitespace"||mn[1].type==="blockQuoteMarker"||mn[1].type==="listItemIndent"))break}yt&&(!He||yt<He)&&(Je._spread=!0),Je.end=Object.assign({},He?oe[He][1].start:lt[1].end),oe.splice(He||Ie,0,["exit",Je,lt[2]]),Ie++,Te++}if(lt[1].type==="listItemPrefix"){const Yt={type:"listItem",_spread:!1,start:Object.assign({},lt[1].start),end:void 0};Je=Yt,oe.splice(Ie,0,["enter",Yt,lt[2]]),Ie++,Te++,yt=void 0,zt=!0}}}return oe[xe][1]._spread=Pt,Te}function s(oe,xe){return Te;function Te(Ie){d.call(this,oe(Ie),Ie),xe&&xe.call(this,Ie)}}function c(){this.stack.push({type:"fragment",children:[]})}function d(oe,xe,Te){this.stack[this.stack.length-1].children.push(oe),this.stack.push(oe),this.tokenStack.push([xe,Te||void 0]),oe.position={start:ka(xe.start),end:void 0}}function p(oe){return xe;function xe(Te){oe&&oe.call(this,Te),h.call(this,Te)}}function h(oe,xe){const Te=this.stack.pop(),Ie=this.tokenStack.pop();if(Ie)Ie[0].type!==oe.type&&(xe?xe.call(this,oe,Ie[0]):(Ie[1]||B0).call(this,oe,Ie[0]));else throw new Error("Cannot close `"+oe.type+"` ("+Fo({start:oe.start,end:oe.end})+"): it’s not open");Te.position.end=ka(oe.end)}function y(){return ig(this.stack.pop())}function g(){this.data.expectingFirstListItemValue=!0}function b(oe){if(this.data.expectingFirstListItemValue){const xe=this.stack[this.stack.length-2];xe.start=Number.parseInt(this.sliceSerialize(oe),10),this.data.expectingFirstListItemValue=void 0}}function w(){const oe=this.resume(),xe=this.stack[this.stack.length-1];xe.lang=oe}function k(){const oe=this.resume(),xe=this.stack[this.stack.length-1];xe.meta=oe}function S(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function C(){const oe=this.resume(),xe=this.stack[this.stack.length-1];xe.value=oe.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function A(){const oe=this.resume(),xe=this.stack[this.stack.length-1];xe.value=oe.replace(/(\r?\n|\r)$/g,"")}function N(oe){const xe=this.resume(),Te=this.stack[this.stack.length-1];Te.label=xe,Te.identifier=tr(this.sliceSerialize(oe)).toLowerCase()}function j(){const oe=this.resume(),xe=this.stack[this.stack.length-1];xe.title=oe}function O(){const oe=this.resume(),xe=this.stack[this.stack.length-1];xe.url=oe}function D(oe){const xe=this.stack[this.stack.length-1];if(!xe.depth){const Te=this.sliceSerialize(oe).length;xe.depth=Te}}function M(){this.data.setextHeadingSlurpLineEnding=!0}function U(oe){const xe=this.stack[this.stack.length-1];xe.depth=this.sliceSerialize(oe).codePointAt(0)===61?1:2}function F(){this.data.setextHeadingSlurpLineEnding=void 0}function Q(oe){const Te=this.stack[this.stack.length-1].children;let Ie=Te[Te.length-1];(!Ie||Ie.type!=="text")&&(Ie=Dt(),Ie.position={start:ka(oe.start),end:void 0},Te.push(Ie)),this.stack.push(Ie)}function I(oe){const xe=this.stack.pop();xe.value+=this.sliceSerialize(oe),xe.position.end=ka(oe.end)}function Y(oe){const xe=this.stack[this.stack.length-1];if(this.data.atHardBreak){const Te=xe.children[xe.children.length-1];Te.position.end=ka(oe.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&r.canContainEols.includes(xe.type)&&(Q.call(this,oe),I.call(this,oe))}function V(){this.data.atHardBreak=!0}function ue(){const oe=this.resume(),xe=this.stack[this.stack.length-1];xe.value=oe}function W(){const oe=this.resume(),xe=this.stack[this.stack.length-1];xe.value=oe}function J(){const oe=this.resume(),xe=this.stack[this.stack.length-1];xe.value=oe}function B(){const oe=this.stack[this.stack.length-1];if(this.data.inReference){const xe=this.data.referenceType||"shortcut";oe.type+="Reference",oe.referenceType=xe,delete oe.url,delete oe.title}else delete oe.identifier,delete oe.label;this.data.referenceType=void 0}function G(){const oe=this.stack[this.stack.length-1];if(this.data.inReference){const xe=this.data.referenceType||"shortcut";oe.type+="Reference",oe.referenceType=xe,delete oe.url,delete oe.title}else delete oe.identifier,delete oe.label;this.data.referenceType=void 0}function te(oe){const xe=this.sliceSerialize(oe),Te=this.stack[this.stack.length-2];Te.label=oI(xe),Te.identifier=tr(xe).toLowerCase()}function ce(){const oe=this.stack[this.stack.length-1],xe=this.resume(),Te=this.stack[this.stack.length-1];if(this.data.inReference=!0,Te.type==="link"){const Ie=oe.children;Te.children=Ie}else Te.alt=xe}function R(){const oe=this.resume(),xe=this.stack[this.stack.length-1];xe.url=oe}function z(){const oe=this.resume(),xe=this.stack[this.stack.length-1];xe.title=oe}function L(){this.data.inReference=void 0}function _(){this.data.referenceType="collapsed"}function re(oe){const xe=this.resume(),Te=this.stack[this.stack.length-1];Te.label=xe,Te.identifier=tr(this.sliceSerialize(oe)).toLowerCase(),this.data.referenceType="full"}function ne(oe){this.data.characterReferenceType=oe.type}function ie(oe){const xe=this.sliceSerialize(oe),Te=this.data.characterReferenceType;let Ie;Te?(Ie=ME(xe,Te==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):Ie=og(xe);const rt=this.stack[this.stack.length-1];rt.value+=Ie}function le(oe){const xe=this.stack.pop();xe.position.end=ka(oe.end)}function be(oe){I.call(this,oe);const xe=this.stack[this.stack.length-1];xe.url=this.sliceSerialize(oe)}function he(oe){I.call(this,oe);const xe=this.stack[this.stack.length-1];xe.url="mailto:"+this.sliceSerialize(oe)}function Ne(){return{type:"blockquote",children:[]}}function De(){return{type:"code",lang:null,meta:null,value:""}}function ze(){return{type:"inlineCode",value:""}}function gt(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function nt(){return{type:"emphasis",children:[]}}function Ot(){return{type:"heading",depth:0,children:[]}}function Jt(){return{type:"break"}}function Gt(){return{type:"html",value:""}}function Rn(){return{type:"image",title:null,url:"",alt:null}}function Mn(){return{type:"link",title:null,url:"",children:[]}}function an(oe){return{type:"list",ordered:oe.type==="listOrdered",start:null,spread:oe._spread,children:[]}}function On(oe){return{type:"listItem",spread:oe._spread,checked:null,children:[]}}function br(){return{type:"paragraph",children:[]}}function Oi(){return{type:"strong",children:[]}}function Dt(){return{type:"text",value:""}}function Di(){return{type:"thematicBreak"}}}function ka(e){return{line:e.line,column:e.column,offset:e.offset}}function VE(e,r){let a=-1;for(;++a<r.length;){const l=r[a];Array.isArray(l)?VE(e,l):dI(e,l)}}function dI(e,r){let a;for(a in r)if(HE.call(r,a))switch(a){case"canContainEols":{const l=r[a];l&&e[a].push(...l);break}case"transforms":{const l=r[a];l&&e[a].push(...l);break}case"enter":case"exit":{const l=r[a];l&&Object.assign(e[a],l);break}}}function B0(e,r){throw e?new Error("Cannot close `"+e.type+"` ("+Fo({start:e.start,end:e.end})+"): a different token (`"+r.type+"`, "+Fo({start:r.start,end:r.end})+") is open"):new Error("Cannot close document, a token (`"+r.type+"`, "+Fo({start:r.start,end:r.end})+") is still open")}function fI(e){const r=this;r.parser=a;function a(l){return uI(l,{...r.data("settings"),...e,extensions:r.data("micromarkExtensions")||[],mdastExtensions:r.data("fromMarkdownExtensions")||[]})}}function pI(e,r){const a={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(r),!0)};return e.patch(r,a),e.applyData(r,a)}function hI(e,r){const a={type:"element",tagName:"br",properties:{},children:[]};return e.patch(r,a),[e.applyData(r,a),{type:"text",value:`
420
- `}]}function mI(e,r){const a=r.value?r.value+`
421
- `:"",l={},o=r.lang?r.lang.split(/\s+/):[];o.length>0&&(l.className=["language-"+o[0]]);let s={type:"element",tagName:"code",properties:l,children:[{type:"text",value:a}]};return r.meta&&(s.data={meta:r.meta}),e.patch(r,s),s=e.applyData(r,s),s={type:"element",tagName:"pre",properties:{},children:[s]},e.patch(r,s),s}function gI(e,r){const a={type:"element",tagName:"del",properties:{},children:e.all(r)};return e.patch(r,a),e.applyData(r,a)}function yI(e,r){const a={type:"element",tagName:"em",properties:{},children:e.all(r)};return e.patch(r,a),e.applyData(r,a)}function xI(e,r){const a=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",l=String(r.identifier).toUpperCase(),o=Mi(l.toLowerCase()),s=e.footnoteOrder.indexOf(l);let c,d=e.footnoteCounts.get(l);d===void 0?(d=0,e.footnoteOrder.push(l),c=e.footnoteOrder.length):c=s+1,d+=1,e.footnoteCounts.set(l,d);const p={type:"element",tagName:"a",properties:{href:"#"+a+"fn-"+o,id:a+"fnref-"+o+(d>1?"-"+d:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(c)}]};e.patch(r,p);const h={type:"element",tagName:"sup",properties:{},children:[p]};return e.patch(r,h),e.applyData(r,h)}function bI(e,r){const a={type:"element",tagName:"h"+r.depth,properties:{},children:e.all(r)};return e.patch(r,a),e.applyData(r,a)}function vI(e,r){if(e.options.allowDangerousHtml){const a={type:"raw",value:r.value};return e.patch(r,a),e.applyData(r,a)}}function $E(e,r){const a=r.referenceType;let l="]";if(a==="collapsed"?l+="[]":a==="full"&&(l+="["+(r.label||r.identifier)+"]"),r.type==="imageReference")return[{type:"text",value:"!["+r.alt+l}];const o=e.all(r),s=o[0];s&&s.type==="text"?s.value="["+s.value:o.unshift({type:"text",value:"["});const c=o[o.length-1];return c&&c.type==="text"?c.value+=l:o.push({type:"text",value:l}),o}function wI(e,r){const a=String(r.identifier).toUpperCase(),l=e.definitionById.get(a);if(!l)return $E(e,r);const o={src:Mi(l.url||""),alt:r.alt};l.title!==null&&l.title!==void 0&&(o.title=l.title);const s={type:"element",tagName:"img",properties:o,children:[]};return e.patch(r,s),e.applyData(r,s)}function SI(e,r){const a={src:Mi(r.url)};r.alt!==null&&r.alt!==void 0&&(a.alt=r.alt),r.title!==null&&r.title!==void 0&&(a.title=r.title);const l={type:"element",tagName:"img",properties:a,children:[]};return e.patch(r,l),e.applyData(r,l)}function kI(e,r){const a={type:"text",value:r.value.replace(/\r?\n|\r/g," ")};e.patch(r,a);const l={type:"element",tagName:"code",properties:{},children:[a]};return e.patch(r,l),e.applyData(r,l)}function EI(e,r){const a=String(r.identifier).toUpperCase(),l=e.definitionById.get(a);if(!l)return $E(e,r);const o={href:Mi(l.url||"")};l.title!==null&&l.title!==void 0&&(o.title=l.title);const s={type:"element",tagName:"a",properties:o,children:e.all(r)};return e.patch(r,s),e.applyData(r,s)}function CI(e,r){const a={href:Mi(r.url)};r.title!==null&&r.title!==void 0&&(a.title=r.title);const l={type:"element",tagName:"a",properties:a,children:e.all(r)};return e.patch(r,l),e.applyData(r,l)}function AI(e,r,a){const l=e.all(r),o=a?NI(a):qE(r),s={},c=[];if(typeof r.checked=="boolean"){const y=l[0];let g;y&&y.type==="element"&&y.tagName==="p"?g=y:(g={type:"element",tagName:"p",properties:{},children:[]},l.unshift(g)),g.children.length>0&&g.children.unshift({type:"text",value:" "}),g.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:r.checked,disabled:!0},children:[]}),s.className=["task-list-item"]}let d=-1;for(;++d<l.length;){const y=l[d];(o||d!==0||y.type!=="element"||y.tagName!=="p")&&c.push({type:"text",value:`
422
- `}),y.type==="element"&&y.tagName==="p"&&!o?c.push(...y.children):c.push(y)}const p=l[l.length-1];p&&(o||p.type!=="element"||p.tagName!=="p")&&c.push({type:"text",value:`
423
- `});const h={type:"element",tagName:"li",properties:s,children:c};return e.patch(r,h),e.applyData(r,h)}function NI(e){let r=!1;if(e.type==="list"){r=e.spread||!1;const a=e.children;let l=-1;for(;!r&&++l<a.length;)r=qE(a[l])}return r}function qE(e){const r=e.spread;return r==null?e.children.length>1:r}function jI(e,r){const a={},l=e.all(r);let o=-1;for(typeof r.start=="number"&&r.start!==1&&(a.start=r.start);++o<l.length;){const c=l[o];if(c.type==="element"&&c.tagName==="li"&&c.properties&&Array.isArray(c.properties.className)&&c.properties.className.includes("task-list-item")){a.className=["contains-task-list"];break}}const s={type:"element",tagName:r.ordered?"ol":"ul",properties:a,children:e.wrap(l,!0)};return e.patch(r,s),e.applyData(r,s)}function TI(e,r){const a={type:"element",tagName:"p",properties:{},children:e.all(r)};return e.patch(r,a),e.applyData(r,a)}function _I(e,r){const a={type:"root",children:e.wrap(e.all(r))};return e.patch(r,a),e.applyData(r,a)}function RI(e,r){const a={type:"element",tagName:"strong",properties:{},children:e.all(r)};return e.patch(r,a),e.applyData(r,a)}function MI(e,r){const a=e.all(r),l=a.shift(),o=[];if(l){const c={type:"element",tagName:"thead",properties:{},children:e.wrap([l],!0)};e.patch(r.children[0],c),o.push(c)}if(a.length>0){const c={type:"element",tagName:"tbody",properties:{},children:e.wrap(a,!0)},d=ng(r.children[1]),p=EE(r.children[r.children.length-1]);d&&p&&(c.position={start:d,end:p}),o.push(c)}const s={type:"element",tagName:"table",properties:{},children:e.wrap(o,!0)};return e.patch(r,s),e.applyData(r,s)}function OI(e,r,a){const l=a?a.children:void 0,s=(l?l.indexOf(r):1)===0?"th":"td",c=a&&a.type==="table"?a.align:void 0,d=c?c.length:r.children.length;let p=-1;const h=[];for(;++p<d;){const g=r.children[p],b={},w=c?c[p]:void 0;w&&(b.align=w);let k={type:"element",tagName:s,properties:b,children:[]};g&&(k.children=e.all(g),e.patch(g,k),k=e.applyData(g,k)),h.push(k)}const y={type:"element",tagName:"tr",properties:{},children:e.wrap(h,!0)};return e.patch(r,y),e.applyData(r,y)}function DI(e,r){const a={type:"element",tagName:"td",properties:{},children:e.all(r)};return e.patch(r,a),e.applyData(r,a)}const P0=9,F0=32;function zI(e){const r=String(e),a=/\r?\n|\r/g;let l=a.exec(r),o=0;const s=[];for(;l;)s.push(U0(r.slice(o,l.index),o>0,!0),l[0]),o=l.index+l[0].length,l=a.exec(r);return s.push(U0(r.slice(o),o>0,!1)),s.join("")}function U0(e,r,a){let l=0,o=e.length;if(r){let s=e.codePointAt(l);for(;s===P0||s===F0;)l++,s=e.codePointAt(l)}if(a){let s=e.codePointAt(o-1);for(;s===P0||s===F0;)o--,s=e.codePointAt(o-1)}return o>l?e.slice(l,o):""}function LI(e,r){const a={type:"text",value:zI(String(r.value))};return e.patch(r,a),e.applyData(r,a)}function II(e,r){const a={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(r,a),e.applyData(r,a)}const BI={blockquote:pI,break:hI,code:mI,delete:gI,emphasis:yI,footnoteReference:xI,heading:bI,html:vI,imageReference:wI,image:SI,inlineCode:kI,linkReference:EI,link:CI,listItem:AI,list:jI,paragraph:TI,root:_I,strong:RI,table:MI,tableCell:DI,tableRow:OI,text:LI,thematicBreak:II,toml:Wu,yaml:Wu,definition:Wu,footnoteDefinition:Wu};function Wu(){}const GE=-1,gd=0,Ho=1,jc=2,ug=3,cg=4,dg=5,fg=6,YE=7,XE=8,H0=typeof self=="object"?self:globalThis,PI=(e,r)=>{const a=(o,s)=>(e.set(s,o),o),l=o=>{if(e.has(o))return e.get(o);const[s,c]=r[o];switch(s){case gd:case GE:return a(c,o);case Ho:{const d=a([],o);for(const p of c)d.push(l(p));return d}case jc:{const d=a({},o);for(const[p,h]of c)d[l(p)]=l(h);return d}case ug:return a(new Date(c),o);case cg:{const{source:d,flags:p}=c;return a(new RegExp(d,p),o)}case dg:{const d=a(new Map,o);for(const[p,h]of c)d.set(l(p),l(h));return d}case fg:{const d=a(new Set,o);for(const p of c)d.add(l(p));return d}case YE:{const{name:d,message:p}=c;return a(new H0[d](p),o)}case XE:return a(BigInt(c),o);case"BigInt":return a(Object(BigInt(c)),o);case"ArrayBuffer":return a(new Uint8Array(c).buffer,c);case"DataView":{const{buffer:d}=new Uint8Array(c);return a(new DataView(d),c)}}return a(new H0[s](c),o)};return l},V0=e=>PI(new Map,e)(0),si="",{toString:FI}={},{keys:UI}=Object,zo=e=>{const r=typeof e;if(r!=="object"||!e)return[gd,r];const a=FI.call(e).slice(8,-1);switch(a){case"Array":return[Ho,si];case"Object":return[jc,si];case"Date":return[ug,si];case"RegExp":return[cg,si];case"Map":return[dg,si];case"Set":return[fg,si];case"DataView":return[Ho,a]}return a.includes("Array")?[Ho,a]:a.includes("Error")?[YE,a]:[jc,a]},Ju=([e,r])=>e===gd&&(r==="function"||r==="symbol"),HI=(e,r,a,l)=>{const o=(c,d)=>{const p=l.push(c)-1;return a.set(d,p),p},s=c=>{if(a.has(c))return a.get(c);let[d,p]=zo(c);switch(d){case gd:{let y=c;switch(p){case"bigint":d=XE,y=c.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+p);y=null;break;case"undefined":return o([GE],c)}return o([d,y],c)}case Ho:{if(p){let b=c;return p==="DataView"?b=new Uint8Array(c.buffer):p==="ArrayBuffer"&&(b=new Uint8Array(c)),o([p,[...b]],c)}const y=[],g=o([d,y],c);for(const b of c)y.push(s(b));return g}case jc:{if(p)switch(p){case"BigInt":return o([p,c.toString()],c);case"Boolean":case"Number":case"String":return o([p,c.valueOf()],c)}if(r&&"toJSON"in c)return s(c.toJSON());const y=[],g=o([d,y],c);for(const b of UI(c))(e||!Ju(zo(c[b])))&&y.push([s(b),s(c[b])]);return g}case ug:return o([d,c.toISOString()],c);case cg:{const{source:y,flags:g}=c;return o([d,{source:y,flags:g}],c)}case dg:{const y=[],g=o([d,y],c);for(const[b,w]of c)(e||!(Ju(zo(b))||Ju(zo(w))))&&y.push([s(b),s(w)]);return g}case fg:{const y=[],g=o([d,y],c);for(const b of c)(e||!Ju(zo(b)))&&y.push(s(b));return g}}const{message:h}=c;return o([d,{name:p,message:h}],c)};return s},$0=(e,{json:r,lossy:a}={})=>{const l=[];return HI(!(r||a),!!r,new Map,l)(e),l},Tc=typeof structuredClone=="function"?(e,r)=>r&&("json"in r||"lossy"in r)?V0($0(e,r)):structuredClone(e):(e,r)=>V0($0(e,r));function VI(e,r){const a=[{type:"text",value:"↩"}];return r>1&&a.push({type:"element",tagName:"sup",properties:{},children:[{type:"text",value:String(r)}]}),a}function $I(e,r){return"Back to reference "+(e+1)+(r>1?"-"+r:"")}function qI(e){const r=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",a=e.options.footnoteBackContent||VI,l=e.options.footnoteBackLabel||$I,o=e.options.footnoteLabel||"Footnotes",s=e.options.footnoteLabelTagName||"h2",c=e.options.footnoteLabelProperties||{className:["sr-only"]},d=[];let p=-1;for(;++p<e.footnoteOrder.length;){const h=e.footnoteById.get(e.footnoteOrder[p]);if(!h)continue;const y=e.all(h),g=String(h.identifier).toUpperCase(),b=Mi(g.toLowerCase());let w=0;const k=[],S=e.footnoteCounts.get(g);for(;S!==void 0&&++w<=S;){k.length>0&&k.push({type:"text",value:" "});let N=typeof a=="string"?a:a(p,w);typeof N=="string"&&(N={type:"text",value:N}),k.push({type:"element",tagName:"a",properties:{href:"#"+r+"fnref-"+b+(w>1?"-"+w:""),dataFootnoteBackref:"",ariaLabel:typeof l=="string"?l:l(p,w),className:["data-footnote-backref"]},children:Array.isArray(N)?N:[N]})}const C=y[y.length-1];if(C&&C.type==="element"&&C.tagName==="p"){const N=C.children[C.children.length-1];N&&N.type==="text"?N.value+=" ":C.children.push({type:"text",value:" "}),C.children.push(...k)}else y.push(...k);const A={type:"element",tagName:"li",properties:{id:r+"fn-"+b},children:e.wrap(y,!0)};e.patch(h,A),d.push(A)}if(d.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:s,properties:{...Tc(c),id:"footnote-label"},children:[{type:"text",value:o}]},{type:"text",value:`
424
- `},{type:"element",tagName:"ol",properties:{},children:e.wrap(d,!0)},{type:"text",value:`
425
- `}]}}const yd=(function(e){if(e==null)return KI;if(typeof e=="function")return xd(e);if(typeof e=="object")return Array.isArray(e)?GI(e):YI(e);if(typeof e=="string")return XI(e);throw new Error("Expected function, string, or object as test")});function GI(e){const r=[];let a=-1;for(;++a<e.length;)r[a]=yd(e[a]);return xd(l);function l(...o){let s=-1;for(;++s<r.length;)if(r[s].apply(this,o))return!0;return!1}}function YI(e){const r=e;return xd(a);function a(l){const o=l;let s;for(s in e)if(o[s]!==r[s])return!1;return!0}}function XI(e){return xd(r);function r(a){return a&&a.type===e}}function xd(e){return r;function r(a,l,o){return!!(QI(a)&&e.call(this,a,typeof l=="number"?l:void 0,o||void 0))}}function KI(){return!0}function QI(e){return e!==null&&typeof e=="object"&&"type"in e}const KE=[],ZI=!0,Xh=!1,WI="skip";function QE(e,r,a,l){let o;typeof r=="function"&&typeof a!="function"?(l=a,a=r):o=r;const s=yd(o),c=l?-1:1;d(e,void 0,[])();function d(p,h,y){const g=p&&typeof p=="object"?p:{};if(typeof g.type=="string"){const w=typeof g.tagName=="string"?g.tagName:typeof g.name=="string"?g.name:void 0;Object.defineProperty(b,"name",{value:"node ("+(p.type+(w?"<"+w+">":""))+")"})}return b;function b(){let w=KE,k,S,C;if((!r||s(p,h,y[y.length-1]||void 0))&&(w=JI(a(p,y)),w[0]===Xh))return w;if("children"in p&&p.children){const A=p;if(A.children&&w[0]!==WI)for(S=(l?A.children.length:-1)+c,C=y.concat(A);S>-1&&S<A.children.length;){const N=A.children[S];if(k=d(N,S,C)(),k[0]===Xh)return k;S=typeof k[1]=="number"?k[1]:S+c}}return w}}}function JI(e){return Array.isArray(e)?e:typeof e=="number"?[ZI,e]:e==null?KE:[e]}function pg(e,r,a,l){let o,s,c;typeof r=="function"&&typeof a!="function"?(s=void 0,c=r,o=a):(s=r,c=a,o=l),QE(e,s,d,o);function d(p,h){const y=h[h.length-1],g=y?y.children.indexOf(p):void 0;return c(p,g,y)}}const Kh={}.hasOwnProperty,e8={};function t8(e,r){const a=r||e8,l=new Map,o=new Map,s=new Map,c={...BI,...a.handlers},d={all:h,applyData:r8,definitionById:l,footnoteById:o,footnoteCounts:s,footnoteOrder:[],handlers:c,one:p,options:a,patch:n8,wrap:l8};return pg(e,function(y){if(y.type==="definition"||y.type==="footnoteDefinition"){const g=y.type==="definition"?l:o,b=String(y.identifier).toUpperCase();g.has(b)||g.set(b,y)}}),d;function p(y,g){const b=y.type,w=d.handlers[b];if(Kh.call(d.handlers,b)&&w)return w(d,y,g);if(d.options.passThrough&&d.options.passThrough.includes(b)){if("children"in y){const{children:S,...C}=y,A=Tc(C);return A.children=d.all(y),A}return Tc(y)}return(d.options.unknownHandler||a8)(d,y,g)}function h(y){const g=[];if("children"in y){const b=y.children;let w=-1;for(;++w<b.length;){const k=d.one(b[w],y);if(k){if(w&&b[w-1].type==="break"&&(!Array.isArray(k)&&k.type==="text"&&(k.value=q0(k.value)),!Array.isArray(k)&&k.type==="element")){const S=k.children[0];S&&S.type==="text"&&(S.value=q0(S.value))}Array.isArray(k)?g.push(...k):g.push(k)}}}return g}}function n8(e,r){e.position&&(r.position=$5(e))}function r8(e,r){let a=r;if(e&&e.data){const l=e.data.hName,o=e.data.hChildren,s=e.data.hProperties;if(typeof l=="string")if(a.type==="element")a.tagName=l;else{const c="children"in a?a.children:[a];a={type:"element",tagName:l,properties:{},children:c}}a.type==="element"&&s&&Object.assign(a.properties,Tc(s)),"children"in a&&a.children&&o!==null&&o!==void 0&&(a.children=o)}return a}function a8(e,r){const a=r.data||{},l="value"in r&&!(Kh.call(a,"hProperties")||Kh.call(a,"hChildren"))?{type:"text",value:r.value}:{type:"element",tagName:"div",properties:{},children:e.all(r)};return e.patch(r,l),e.applyData(r,l)}function l8(e,r){const a=[];let l=-1;for(r&&a.push({type:"text",value:`
426
- `});++l<e.length;)l&&a.push({type:"text",value:`
427
- `}),a.push(e[l]);return r&&e.length>0&&a.push({type:"text",value:`
428
- `}),a}function q0(e){let r=0,a=e.charCodeAt(r);for(;a===9||a===32;)r++,a=e.charCodeAt(r);return e.slice(r)}function G0(e,r){const a=t8(e,r),l=a.one(e,void 0),o=qI(a),s=Array.isArray(l)?{type:"root",children:l}:l||{type:"root",children:[]};return o&&s.children.push({type:"text",value:`
429
- `},o),s}function i8(e,r){return e&&"run"in e?async function(a,l){const o=G0(a,{file:l,...r});await e.run(o,l)}:function(a,l){return G0(a,{file:l,...e||r})}}function Y0(e){if(e)throw e}var oh,X0;function o8(){if(X0)return oh;X0=1;var e=Object.prototype.hasOwnProperty,r=Object.prototype.toString,a=Object.defineProperty,l=Object.getOwnPropertyDescriptor,o=function(h){return typeof Array.isArray=="function"?Array.isArray(h):r.call(h)==="[object Array]"},s=function(h){if(!h||r.call(h)!=="[object Object]")return!1;var y=e.call(h,"constructor"),g=h.constructor&&h.constructor.prototype&&e.call(h.constructor.prototype,"isPrototypeOf");if(h.constructor&&!y&&!g)return!1;var b;for(b in h);return typeof b>"u"||e.call(h,b)},c=function(h,y){a&&y.name==="__proto__"?a(h,y.name,{enumerable:!0,configurable:!0,value:y.newValue,writable:!0}):h[y.name]=y.newValue},d=function(h,y){if(y==="__proto__")if(e.call(h,y)){if(l)return l(h,y).value}else return;return h[y]};return oh=function p(){var h,y,g,b,w,k,S=arguments[0],C=1,A=arguments.length,N=!1;for(typeof S=="boolean"&&(N=S,S=arguments[1]||{},C=2),(S==null||typeof S!="object"&&typeof S!="function")&&(S={});C<A;++C)if(h=arguments[C],h!=null)for(y in h)g=d(S,y),b=d(h,y),S!==b&&(N&&b&&(s(b)||(w=o(b)))?(w?(w=!1,k=g&&o(g)?g:[]):k=g&&s(g)?g:{},c(S,{name:y,newValue:p(N,k,b)})):typeof b<"u"&&c(S,{name:y,newValue:b}));return S},oh}var s8=o8();const sh=Rc(s8);function Qh(e){if(typeof e!="object"||e===null)return!1;const r=Object.getPrototypeOf(e);return(r===null||r===Object.prototype||Object.getPrototypeOf(r)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function u8(){const e=[],r={run:a,use:l};return r;function a(...o){let s=-1;const c=o.pop();if(typeof c!="function")throw new TypeError("Expected function as last argument, not "+c);d(null,...o);function d(p,...h){const y=e[++s];let g=-1;if(p){c(p);return}for(;++g<o.length;)(h[g]===null||h[g]===void 0)&&(h[g]=o[g]);o=h,y?c8(y,d)(...h):c(null,...h)}}function l(o){if(typeof o!="function")throw new TypeError("Expected `middelware` to be a function, not "+o);return e.push(o),r}}function c8(e,r){let a;return l;function l(...c){const d=e.length>c.length;let p;d&&c.push(o);try{p=e.apply(this,c)}catch(h){const y=h;if(d&&a)throw y;return o(y)}d||(p&&p.then&&typeof p.then=="function"?p.then(s,o):p instanceof Error?o(p):s(p))}function o(c,...d){a||(a=!0,r(c,...d))}function s(c){o(null,c)}}const dr={basename:d8,dirname:f8,extname:p8,join:h8,sep:"/"};function d8(e,r){if(r!==void 0&&typeof r!="string")throw new TypeError('"ext" argument must be a string');Cs(e);let a=0,l=-1,o=e.length,s;if(r===void 0||r.length===0||r.length>e.length){for(;o--;)if(e.codePointAt(o)===47){if(s){a=o+1;break}}else l<0&&(s=!0,l=o+1);return l<0?"":e.slice(a,l)}if(r===e)return"";let c=-1,d=r.length-1;for(;o--;)if(e.codePointAt(o)===47){if(s){a=o+1;break}}else c<0&&(s=!0,c=o+1),d>-1&&(e.codePointAt(o)===r.codePointAt(d--)?d<0&&(l=o):(d=-1,l=c));return a===l?l=c:l<0&&(l=e.length),e.slice(a,l)}function f8(e){if(Cs(e),e.length===0)return".";let r=-1,a=e.length,l;for(;--a;)if(e.codePointAt(a)===47){if(l){r=a;break}}else l||(l=!0);return r<0?e.codePointAt(0)===47?"/":".":r===1&&e.codePointAt(0)===47?"//":e.slice(0,r)}function p8(e){Cs(e);let r=e.length,a=-1,l=0,o=-1,s=0,c;for(;r--;){const d=e.codePointAt(r);if(d===47){if(c){l=r+1;break}continue}a<0&&(c=!0,a=r+1),d===46?o<0?o=r:s!==1&&(s=1):o>-1&&(s=-1)}return o<0||a<0||s===0||s===1&&o===a-1&&o===l+1?"":e.slice(o,a)}function h8(...e){let r=-1,a;for(;++r<e.length;)Cs(e[r]),e[r]&&(a=a===void 0?e[r]:a+"/"+e[r]);return a===void 0?".":m8(a)}function m8(e){Cs(e);const r=e.codePointAt(0)===47;let a=g8(e,!r);return a.length===0&&!r&&(a="."),a.length>0&&e.codePointAt(e.length-1)===47&&(a+="/"),r?"/"+a:a}function g8(e,r){let a="",l=0,o=-1,s=0,c=-1,d,p;for(;++c<=e.length;){if(c<e.length)d=e.codePointAt(c);else{if(d===47)break;d=47}if(d===47){if(!(o===c-1||s===1))if(o!==c-1&&s===2){if(a.length<2||l!==2||a.codePointAt(a.length-1)!==46||a.codePointAt(a.length-2)!==46){if(a.length>2){if(p=a.lastIndexOf("/"),p!==a.length-1){p<0?(a="",l=0):(a=a.slice(0,p),l=a.length-1-a.lastIndexOf("/")),o=c,s=0;continue}}else if(a.length>0){a="",l=0,o=c,s=0;continue}}r&&(a=a.length>0?a+"/..":"..",l=2)}else a.length>0?a+="/"+e.slice(o+1,c):a=e.slice(o+1,c),l=c-o-1;o=c,s=0}else d===46&&s>-1?s++:s=-1}return a}function Cs(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const y8={cwd:x8};function x8(){return"/"}function Zh(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function b8(e){if(typeof e=="string")e=new URL(e);else if(!Zh(e)){const r=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw r.code="ERR_INVALID_ARG_TYPE",r}if(e.protocol!=="file:"){const r=new TypeError("The URL must be of scheme file");throw r.code="ERR_INVALID_URL_SCHEME",r}return v8(e)}function v8(e){if(e.hostname!==""){const l=new TypeError('File URL host must be "localhost" or empty on darwin');throw l.code="ERR_INVALID_FILE_URL_HOST",l}const r=e.pathname;let a=-1;for(;++a<r.length;)if(r.codePointAt(a)===37&&r.codePointAt(a+1)===50){const l=r.codePointAt(a+2);if(l===70||l===102){const o=new TypeError("File URL path must not include encoded / characters");throw o.code="ERR_INVALID_FILE_URL_PATH",o}}return decodeURIComponent(r)}const uh=["history","path","basename","stem","extname","dirname"];class ZE{constructor(r){let a;r?Zh(r)?a={path:r}:typeof r=="string"||w8(r)?a={value:r}:a=r:a={},this.cwd="cwd"in a?"":y8.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let l=-1;for(;++l<uh.length;){const s=uh[l];s in a&&a[s]!==void 0&&a[s]!==null&&(this[s]=s==="history"?[...a[s]]:a[s])}let o;for(o in a)uh.includes(o)||(this[o]=a[o])}get basename(){return typeof this.path=="string"?dr.basename(this.path):void 0}set basename(r){dh(r,"basename"),ch(r,"basename"),this.path=dr.join(this.dirname||"",r)}get dirname(){return typeof this.path=="string"?dr.dirname(this.path):void 0}set dirname(r){K0(this.basename,"dirname"),this.path=dr.join(r||"",this.basename)}get extname(){return typeof this.path=="string"?dr.extname(this.path):void 0}set extname(r){if(ch(r,"extname"),K0(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=dr.join(this.dirname,this.stem+(r||""))}get path(){return this.history[this.history.length-1]}set path(r){Zh(r)&&(r=b8(r)),dh(r,"path"),this.path!==r&&this.history.push(r)}get stem(){return typeof this.path=="string"?dr.basename(this.path,this.extname):void 0}set stem(r){dh(r,"stem"),ch(r,"stem"),this.path=dr.join(this.dirname||"",r+(this.extname||""))}fail(r,a,l){const o=this.message(r,a,l);throw o.fatal=!0,o}info(r,a,l){const o=this.message(r,a,l);return o.fatal=void 0,o}message(r,a,l){const o=new Wt(r,a,l);return this.path&&(o.name=this.path+":"+o.name,o.file=this.path),o.fatal=!1,this.messages.push(o),o}toString(r){return this.value===void 0?"":typeof this.value=="string"?this.value:new TextDecoder(r||void 0).decode(this.value)}}function ch(e,r){if(e&&e.includes(dr.sep))throw new Error("`"+r+"` cannot be a path: did not expect `"+dr.sep+"`")}function dh(e,r){if(!e)throw new Error("`"+r+"` cannot be empty")}function K0(e,r){if(!e)throw new Error("Setting `"+r+"` requires `path` to be set too")}function w8(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const S8=(function(e){const l=this.constructor.prototype,o=l[e],s=function(){return o.apply(s,arguments)};return Object.setPrototypeOf(s,l),s}),k8={}.hasOwnProperty;class hg extends S8{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=u8()}copy(){const r=new hg;let a=-1;for(;++a<this.attachers.length;){const l=this.attachers[a];r.use(...l)}return r.data(sh(!0,{},this.namespace)),r}data(r,a){return typeof r=="string"?arguments.length===2?(hh("data",this.frozen),this.namespace[r]=a,this):k8.call(this.namespace,r)&&this.namespace[r]||void 0:r?(hh("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[a,...l]=this.attachers[this.freezeIndex];if(l[0]===!1)continue;l[0]===!0&&(l[0]=void 0);const o=a.call(r,...l);typeof o=="function"&&this.transformers.use(o)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(r){this.freeze();const a=ec(r),l=this.parser||this.Parser;return fh("parse",l),l(String(a),a)}process(r,a){const l=this;return this.freeze(),fh("process",this.parser||this.Parser),ph("process",this.compiler||this.Compiler),a?o(void 0,a):new Promise(o);function o(s,c){const d=ec(r),p=l.parse(d);l.run(p,d,function(y,g,b){if(y||!g||!b)return h(y);const w=g,k=l.stringify(w,b);A8(k)?b.value=k:b.result=k,h(y,b)});function h(y,g){y||!g?c(y):s?s(g):a(void 0,g)}}}processSync(r){let a=!1,l;return this.freeze(),fh("processSync",this.parser||this.Parser),ph("processSync",this.compiler||this.Compiler),this.process(r,o),Z0("processSync","process",a),l;function o(s,c){a=!0,Y0(s),l=c}}run(r,a,l){Q0(r),this.freeze();const o=this.transformers;return!l&&typeof a=="function"&&(l=a,a=void 0),l?s(void 0,l):new Promise(s);function s(c,d){const p=ec(a);o.run(r,p,h);function h(y,g,b){const w=g||r;y?d(y):c?c(w):l(void 0,w,b)}}}runSync(r,a){let l=!1,o;return this.run(r,a,s),Z0("runSync","run",l),o;function s(c,d){Y0(c),o=d,l=!0}}stringify(r,a){this.freeze();const l=ec(a),o=this.compiler||this.Compiler;return ph("stringify",o),Q0(r),o(r,l)}use(r,...a){const l=this.attachers,o=this.namespace;if(hh("use",this.frozen),r!=null)if(typeof r=="function")p(r,a);else if(typeof r=="object")Array.isArray(r)?d(r):c(r);else throw new TypeError("Expected usable value, not `"+r+"`");return this;function s(h){if(typeof h=="function")p(h,[]);else if(typeof h=="object")if(Array.isArray(h)){const[y,...g]=h;p(y,g)}else c(h);else throw new TypeError("Expected usable value, not `"+h+"`")}function c(h){if(!("plugins"in h)&&!("settings"in h))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(h.plugins),h.settings&&(o.settings=sh(!0,o.settings,h.settings))}function d(h){let y=-1;if(h!=null)if(Array.isArray(h))for(;++y<h.length;){const g=h[y];s(g)}else throw new TypeError("Expected a list of plugins, not `"+h+"`")}function p(h,y){let g=-1,b=-1;for(;++g<l.length;)if(l[g][0]===h){b=g;break}if(b===-1)l.push([h,...y]);else if(y.length>0){let[w,...k]=y;const S=l[b][1];Qh(S)&&Qh(w)&&(w=sh(!0,S,w)),l[b]=[h,w,...k]}}}}const E8=new hg().freeze();function fh(e,r){if(typeof r!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function ph(e,r){if(typeof r!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function hh(e,r){if(r)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function Q0(e){if(!Qh(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function Z0(e,r,a){if(!a)throw new Error("`"+e+"` finished async. Use `"+r+"` instead")}function ec(e){return C8(e)?e:new ZE(e)}function C8(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function A8(e){return typeof e=="string"||N8(e)}function N8(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const j8="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",W0=[],J0={allowDangerousHtml:!0},T8=/^(https?|ircs?|mailto|xmpp)$/i,_8=[{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:"className",id:"remove-classname"},{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 R8(e){const r=M8(e),a=O8(e);return D8(r.runSync(r.parse(a),a),e)}function M8(e){const r=e.rehypePlugins||W0,a=e.remarkPlugins||W0,l=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...J0}:J0;return E8().use(fI).use(a).use(i8,l).use(r)}function O8(e){const r=e.children||"",a=new ZE;return typeof r=="string"&&(a.value=r),a}function D8(e,r){const a=r.allowedElements,l=r.allowElement,o=r.components,s=r.disallowedElements,c=r.skipHtml,d=r.unwrapDisallowed,p=r.urlTransform||z8;for(const y of _8)Object.hasOwn(r,y.from)&&(""+y.from+(y.to?"use `"+y.to+"` instead":"remove it")+j8+y.id,void 0);return pg(e,h),K5(e,{Fragment:f.Fragment,components:o,ignoreInvalidStyle:!0,jsx:f.jsx,jsxs:f.jsxs,passKeys:!0,passNode:!0});function h(y,g,b){if(y.type==="raw"&&b&&typeof g=="number")return c?b.children.splice(g,1):b.children[g]={type:"text",value:y.value},g;if(y.type==="element"){let w;for(w in ah)if(Object.hasOwn(ah,w)&&Object.hasOwn(y.properties,w)){const k=y.properties[w],S=ah[w];(S===null||S.includes(y.tagName))&&(y.properties[w]=p(String(k||""),w,y))}}if(y.type==="element"){let w=a?!a.includes(y.tagName):s?s.includes(y.tagName):!1;if(!w&&l&&typeof g=="number"&&(w=!l(y,g,b)),w&&b&&typeof g=="number")return d&&y.children?b.children.splice(g,1,...y.children):b.children.splice(g,1),g}}}function z8(e){const r=e.indexOf(":"),a=e.indexOf("?"),l=e.indexOf("#"),o=e.indexOf("/");return r===-1||o!==-1&&r>o||a!==-1&&r>a||l!==-1&&r>l||T8.test(e.slice(0,r))?e:""}function e1(e,r){const a=String(e);if(typeof r!="string")throw new TypeError("Expected character");let l=0,o=a.indexOf(r);for(;o!==-1;)l++,o=a.indexOf(r,o+r.length);return l}function L8(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function I8(e,r,a){const o=yd((a||{}).ignore||[]),s=B8(r);let c=-1;for(;++c<s.length;)QE(e,"text",d);function d(h,y){let g=-1,b;for(;++g<y.length;){const w=y[g],k=b?b.children:void 0;if(o(w,k?k.indexOf(w):void 0,b))return;b=w}if(b)return p(h,y)}function p(h,y){const g=y[y.length-1],b=s[c][0],w=s[c][1];let k=0;const C=g.children.indexOf(h);let A=!1,N=[];b.lastIndex=0;let j=b.exec(h.value);for(;j;){const O=j.index,D={index:j.index,input:j.input,stack:[...y,h]};let M=w(...j,D);if(typeof M=="string"&&(M=M.length>0?{type:"text",value:M}:void 0),M===!1?b.lastIndex=O+1:(k!==O&&N.push({type:"text",value:h.value.slice(k,O)}),Array.isArray(M)?N.push(...M):M&&N.push(M),k=O+j[0].length,A=!0),!b.global)break;j=b.exec(h.value)}return A?(k<h.value.length&&N.push({type:"text",value:h.value.slice(k)}),g.children.splice(C,1,...N)):N=[h],C+N.length}}function B8(e){const r=[];if(!Array.isArray(e))throw new TypeError("Expected find and replace tuple or list of tuples");const a=!e[0]||Array.isArray(e[0])?e:[e];let l=-1;for(;++l<a.length;){const o=a[l];r.push([P8(o[0]),F8(o[1])])}return r}function P8(e){return typeof e=="string"?new RegExp(L8(e),"g"):e}function F8(e){return typeof e=="function"?e:function(){return e}}const mh="phrasing",gh=["autolink","link","image","label"];function U8(){return{transforms:[X8],enter:{literalAutolink:V8,literalAutolinkEmail:yh,literalAutolinkHttp:yh,literalAutolinkWww:yh},exit:{literalAutolink:Y8,literalAutolinkEmail:G8,literalAutolinkHttp:$8,literalAutolinkWww:q8}}}function H8(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:mh,notInConstruct:gh},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:mh,notInConstruct:gh},{character:":",before:"[ps]",after:"\\/",inConstruct:mh,notInConstruct:gh}]}}function V8(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function yh(e){this.config.enter.autolinkProtocol.call(this,e)}function $8(e){this.config.exit.autolinkProtocol.call(this,e)}function q8(e){this.config.exit.data.call(this,e);const r=this.stack[this.stack.length-1];r.type,r.url="http://"+this.sliceSerialize(e)}function G8(e){this.config.exit.autolinkEmail.call(this,e)}function Y8(e){this.exit(e)}function X8(e){I8(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,K8],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),Q8]],{ignore:["link","linkReference"]})}function K8(e,r,a,l,o){let s="";if(!WE(o)||(/^w/i.test(r)&&(a=r+a,r="",s="http://"),!Z8(a)))return!1;const c=W8(a+l);if(!c[0])return!1;const d={type:"link",title:null,url:s+r+c[0],children:[{type:"text",value:r+c[0]}]};return c[1]?[d,{type:"text",value:c[1]}]:d}function Q8(e,r,a,l){return!WE(l,!0)||/[-\d_]$/.test(a)?!1:{type:"link",title:null,url:"mailto:"+r+"@"+a,children:[{type:"text",value:r+"@"+a}]}}function Z8(e){const r=e.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 W8(e){const r=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!r)return[e,void 0];e=e.slice(0,r.index);let a=r[0],l=a.indexOf(")");const o=e1(e,"(");let s=e1(e,")");for(;l!==-1&&o>s;)e+=a.slice(0,l+1),a=a.slice(l+1),l=a.indexOf(")"),s++;return[e,a]}function WE(e,r){const a=e.input.charCodeAt(e.index-1);return(e.index===0||gl(a)||hd(a))&&(!r||a!==47)}JE.peek=o9;function J8(){this.buffer()}function e9(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function t9(){this.buffer()}function n9(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function r9(e){const r=this.resume(),a=this.stack[this.stack.length-1];a.type,a.identifier=tr(this.sliceSerialize(e)).toLowerCase(),a.label=r}function a9(e){this.exit(e)}function l9(e){const r=this.resume(),a=this.stack[this.stack.length-1];a.type,a.identifier=tr(this.sliceSerialize(e)).toLowerCase(),a.label=r}function i9(e){this.exit(e)}function o9(){return"["}function JE(e,r,a,l){const o=a.createTracker(l);let s=o.move("[^");const c=a.enter("footnoteReference"),d=a.enter("reference");return s+=o.move(a.safe(a.associationId(e),{after:"]",before:s})),d(),c(),s+=o.move("]"),s}function s9(){return{enter:{gfmFootnoteCallString:J8,gfmFootnoteCall:e9,gfmFootnoteDefinitionLabelString:t9,gfmFootnoteDefinition:n9},exit:{gfmFootnoteCallString:r9,gfmFootnoteCall:a9,gfmFootnoteDefinitionLabelString:l9,gfmFootnoteDefinition:i9}}}function u9(e){let r=!1;return e&&e.firstLineBlank&&(r=!0),{handlers:{footnoteDefinition:a,footnoteReference:JE},unsafe:[{character:"[",inConstruct:["label","phrasing","reference"]}]};function a(l,o,s,c){const d=s.createTracker(c);let p=d.move("[^");const h=s.enter("footnoteDefinition"),y=s.enter("label");return p+=d.move(s.safe(s.associationId(l),{before:p,after:"]"})),y(),p+=d.move("]:"),l.children&&l.children.length>0&&(d.shift(4),p+=d.move((r?`
430
- `:" ")+s.indentLines(s.containerFlow(l,d.current()),r?eC:c9))),h(),p}}function c9(e,r,a){return r===0?e:eC(e,r,a)}function eC(e,r,a){return(a?"":" ")+e}const d9=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];tC.peek=g9;function f9(){return{canContainEols:["delete"],enter:{strikethrough:h9},exit:{strikethrough:m9}}}function p9(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:d9}],handlers:{delete:tC}}}function h9(e){this.enter({type:"delete",children:[]},e)}function m9(e){this.exit(e)}function tC(e,r,a,l){const o=a.createTracker(l),s=a.enter("strikethrough");let c=o.move("~~");return c+=a.containerPhrasing(e,{...o.current(),before:c,after:"~"}),c+=o.move("~~"),s(),c}function g9(){return"~"}function y9(e){return e.length}function x9(e,r){const a=r||{},l=(a.align||[]).concat(),o=a.stringLength||y9,s=[],c=[],d=[],p=[];let h=0,y=-1;for(;++y<e.length;){const S=[],C=[];let A=-1;for(e[y].length>h&&(h=e[y].length);++A<e[y].length;){const N=b9(e[y][A]);if(a.alignDelimiters!==!1){const j=o(N);C[A]=j,(p[A]===void 0||j>p[A])&&(p[A]=j)}S.push(N)}c[y]=S,d[y]=C}let g=-1;if(typeof l=="object"&&"length"in l)for(;++g<h;)s[g]=t1(l[g]);else{const S=t1(l);for(;++g<h;)s[g]=S}g=-1;const b=[],w=[];for(;++g<h;){const S=s[g];let C="",A="";S===99?(C=":",A=":"):S===108?C=":":S===114&&(A=":");let N=a.alignDelimiters===!1?1:Math.max(1,p[g]-C.length-A.length);const j=C+"-".repeat(N)+A;a.alignDelimiters!==!1&&(N=C.length+N+A.length,N>p[g]&&(p[g]=N),w[g]=N),b[g]=j}c.splice(1,0,b),d.splice(1,0,w),y=-1;const k=[];for(;++y<c.length;){const S=c[y],C=d[y];g=-1;const A=[];for(;++g<h;){const N=S[g]||"";let j="",O="";if(a.alignDelimiters!==!1){const D=p[g]-(C[g]||0),M=s[g];M===114?j=" ".repeat(D):M===99?D%2?(j=" ".repeat(D/2+.5),O=" ".repeat(D/2-.5)):(j=" ".repeat(D/2),O=j):O=" ".repeat(D)}a.delimiterStart!==!1&&!g&&A.push("|"),a.padding!==!1&&!(a.alignDelimiters===!1&&N==="")&&(a.delimiterStart!==!1||g)&&A.push(" "),a.alignDelimiters!==!1&&A.push(j),A.push(N),a.alignDelimiters!==!1&&A.push(O),a.padding!==!1&&A.push(" "),(a.delimiterEnd!==!1||g!==h-1)&&A.push("|")}k.push(a.delimiterEnd===!1?A.join("").replace(/ +$/,""):A.join(""))}return k.join(`
431
- `)}function b9(e){return e==null?"":String(e)}function t1(e){const r=typeof e=="string"?e.codePointAt(0):0;return r===67||r===99?99:r===76||r===108?108:r===82||r===114?114:0}function v9(e,r,a,l){const o=a.enter("blockquote"),s=a.createTracker(l);s.move("> "),s.shift(2);const c=a.indentLines(a.containerFlow(e,s.current()),w9);return o(),c}function w9(e,r,a){return">"+(a?"":" ")+e}function S9(e,r){return n1(e,r.inConstruct,!0)&&!n1(e,r.notInConstruct,!1)}function n1(e,r,a){if(typeof r=="string"&&(r=[r]),!r||r.length===0)return a;let l=-1;for(;++l<r.length;)if(e.includes(r[l]))return!0;return!1}function r1(e,r,a,l){let o=-1;for(;++o<a.unsafe.length;)if(a.unsafe[o].character===`
432
- `&&S9(a.stack,a.unsafe[o]))return/[ \t]/.test(l.before)?"":" ";return`\\
433
- `}function k9(e,r){const a=String(e);let l=a.indexOf(r),o=l,s=0,c=0;if(typeof r!="string")throw new TypeError("Expected substring");for(;l!==-1;)l===o?++s>c&&(c=s):s=1,o=l+r.length,l=a.indexOf(r,o);return c}function E9(e,r){return!!(r.options.fences===!1&&e.value&&!e.lang&&/[^ \r\n]/.test(e.value)&&!/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test(e.value))}function C9(e){const r=e.options.fence||"`";if(r!=="`"&&r!=="~")throw new Error("Cannot serialize code with `"+r+"` for `options.fence`, expected `` ` `` or `~`");return r}function A9(e,r,a,l){const o=C9(a),s=e.value||"",c=o==="`"?"GraveAccent":"Tilde";if(E9(e,a)){const g=a.enter("codeIndented"),b=a.indentLines(s,N9);return g(),b}const d=a.createTracker(l),p=o.repeat(Math.max(k9(s,o)+1,3)),h=a.enter("codeFenced");let y=d.move(p);if(e.lang){const g=a.enter(`codeFencedLang${c}`);y+=d.move(a.safe(e.lang,{before:y,after:" ",encode:["`"],...d.current()})),g()}if(e.lang&&e.meta){const g=a.enter(`codeFencedMeta${c}`);y+=d.move(" "),y+=d.move(a.safe(e.meta,{before:y,after:`
434
- `,encode:["`"],...d.current()})),g()}return y+=d.move(`
435
- `),s&&(y+=d.move(s+`
436
- `)),y+=d.move(p),h(),y}function N9(e,r,a){return(a?"":" ")+e}function mg(e){const r=e.options.quote||'"';if(r!=='"'&&r!=="'")throw new Error("Cannot serialize title with `"+r+"` for `options.quote`, expected `\"`, or `'`");return r}function j9(e,r,a,l){const o=mg(a),s=o==='"'?"Quote":"Apostrophe",c=a.enter("definition");let d=a.enter("label");const p=a.createTracker(l);let h=p.move("[");return h+=p.move(a.safe(a.associationId(e),{before:h,after:"]",...p.current()})),h+=p.move("]: "),d(),!e.url||/[\0- \u007F]/.test(e.url)?(d=a.enter("destinationLiteral"),h+=p.move("<"),h+=p.move(a.safe(e.url,{before:h,after:">",...p.current()})),h+=p.move(">")):(d=a.enter("destinationRaw"),h+=p.move(a.safe(e.url,{before:h,after:e.title?" ":`
437
- `,...p.current()}))),d(),e.title&&(d=a.enter(`title${s}`),h+=p.move(" "+o),h+=p.move(a.safe(e.title,{before:h,after:o,...p.current()})),h+=p.move(o),d()),c(),h}function T9(e){const r=e.options.emphasis||"*";if(r!=="*"&&r!=="_")throw new Error("Cannot serialize emphasis with `"+r+"` for `options.emphasis`, expected `*`, or `_`");return r}function ts(e){return"&#x"+e.toString(16).toUpperCase()+";"}function _c(e,r,a){const l=ki(e),o=ki(r);return l===void 0?o===void 0?a==="_"?{inside:!0,outside:!0}:{inside:!1,outside:!1}:o===1?{inside:!0,outside:!0}:{inside:!1,outside:!0}:l===1?o===void 0?{inside:!1,outside:!1}:o===1?{inside:!0,outside:!0}:{inside:!1,outside:!1}:o===void 0?{inside:!1,outside:!1}:o===1?{inside:!0,outside:!1}:{inside:!1,outside:!1}}nC.peek=_9;function nC(e,r,a,l){const o=T9(a),s=a.enter("emphasis"),c=a.createTracker(l),d=c.move(o);let p=c.move(a.containerPhrasing(e,{after:o,before:d,...c.current()}));const h=p.charCodeAt(0),y=_c(l.before.charCodeAt(l.before.length-1),h,o);y.inside&&(p=ts(h)+p.slice(1));const g=p.charCodeAt(p.length-1),b=_c(l.after.charCodeAt(0),g,o);b.inside&&(p=p.slice(0,-1)+ts(g));const w=c.move(o);return s(),a.attentionEncodeSurroundingInfo={after:b.outside,before:y.outside},d+p+w}function _9(e,r,a){return a.options.emphasis||"*"}function R9(e,r){let a=!1;return pg(e,function(l){if("value"in l&&/\r?\n|\r/.test(l.value)||l.type==="break")return a=!0,Xh}),!!((!e.depth||e.depth<3)&&ig(e)&&(r.options.setext||a))}function M9(e,r,a,l){const o=Math.max(Math.min(6,e.depth||1),1),s=a.createTracker(l);if(R9(e,a)){const y=a.enter("headingSetext"),g=a.enter("phrasing"),b=a.containerPhrasing(e,{...s.current(),before:`
438
- `,after:`
439
- `});return g(),y(),b+`
440
- `+(o===1?"=":"-").repeat(b.length-(Math.max(b.lastIndexOf("\r"),b.lastIndexOf(`
441
- `))+1))}const c="#".repeat(o),d=a.enter("headingAtx"),p=a.enter("phrasing");s.move(c+" ");let h=a.containerPhrasing(e,{before:"# ",after:`
442
- `,...s.current()});return/^[\t ]/.test(h)&&(h=ts(h.charCodeAt(0))+h.slice(1)),h=h?c+" "+h:c,a.options.closeAtx&&(h+=" "+c),p(),d(),h}rC.peek=O9;function rC(e){return e.value||""}function O9(){return"<"}aC.peek=D9;function aC(e,r,a,l){const o=mg(a),s=o==='"'?"Quote":"Apostrophe",c=a.enter("image");let d=a.enter("label");const p=a.createTracker(l);let h=p.move("![");return h+=p.move(a.safe(e.alt,{before:h,after:"]",...p.current()})),h+=p.move("]("),d(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(d=a.enter("destinationLiteral"),h+=p.move("<"),h+=p.move(a.safe(e.url,{before:h,after:">",...p.current()})),h+=p.move(">")):(d=a.enter("destinationRaw"),h+=p.move(a.safe(e.url,{before:h,after:e.title?" ":")",...p.current()}))),d(),e.title&&(d=a.enter(`title${s}`),h+=p.move(" "+o),h+=p.move(a.safe(e.title,{before:h,after:o,...p.current()})),h+=p.move(o),d()),h+=p.move(")"),c(),h}function D9(){return"!"}lC.peek=z9;function lC(e,r,a,l){const o=e.referenceType,s=a.enter("imageReference");let c=a.enter("label");const d=a.createTracker(l);let p=d.move("![");const h=a.safe(e.alt,{before:p,after:"]",...d.current()});p+=d.move(h+"]["),c();const y=a.stack;a.stack=[],c=a.enter("reference");const g=a.safe(a.associationId(e),{before:p,after:"]",...d.current()});return c(),a.stack=y,s(),o==="full"||!h||h!==g?p+=d.move(g+"]"):o==="shortcut"?p=p.slice(0,-1):p+=d.move("]"),p}function z9(){return"!"}iC.peek=L9;function iC(e,r,a){let l=e.value||"",o="`",s=-1;for(;new RegExp("(^|[^`])"+o+"([^`]|$)").test(l);)o+="`";for(/[^ \r\n]/.test(l)&&(/^[ \r\n]/.test(l)&&/[ \r\n]$/.test(l)||/^`|`$/.test(l))&&(l=" "+l+" ");++s<a.unsafe.length;){const c=a.unsafe[s],d=a.compilePattern(c);let p;if(c.atBreak)for(;p=d.exec(l);){let h=p.index;l.charCodeAt(h)===10&&l.charCodeAt(h-1)===13&&h--,l=l.slice(0,h)+" "+l.slice(p.index+1)}}return o+l+o}function L9(){return"`"}function oC(e,r){const a=ig(e);return!!(!r.options.resourceLink&&e.url&&!e.title&&e.children&&e.children.length===1&&e.children[0].type==="text"&&(a===e.url||"mailto:"+a===e.url)&&/^[a-z][a-z+.-]+:/i.test(e.url)&&!/[\0- <>\u007F]/.test(e.url))}sC.peek=I9;function sC(e,r,a,l){const o=mg(a),s=o==='"'?"Quote":"Apostrophe",c=a.createTracker(l);let d,p;if(oC(e,a)){const y=a.stack;a.stack=[],d=a.enter("autolink");let g=c.move("<");return g+=c.move(a.containerPhrasing(e,{before:g,after:">",...c.current()})),g+=c.move(">"),d(),a.stack=y,g}d=a.enter("link"),p=a.enter("label");let h=c.move("[");return h+=c.move(a.containerPhrasing(e,{before:h,after:"](",...c.current()})),h+=c.move("]("),p(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(p=a.enter("destinationLiteral"),h+=c.move("<"),h+=c.move(a.safe(e.url,{before:h,after:">",...c.current()})),h+=c.move(">")):(p=a.enter("destinationRaw"),h+=c.move(a.safe(e.url,{before:h,after:e.title?" ":")",...c.current()}))),p(),e.title&&(p=a.enter(`title${s}`),h+=c.move(" "+o),h+=c.move(a.safe(e.title,{before:h,after:o,...c.current()})),h+=c.move(o),p()),h+=c.move(")"),d(),h}function I9(e,r,a){return oC(e,a)?"<":"["}uC.peek=B9;function uC(e,r,a,l){const o=e.referenceType,s=a.enter("linkReference");let c=a.enter("label");const d=a.createTracker(l);let p=d.move("[");const h=a.containerPhrasing(e,{before:p,after:"]",...d.current()});p+=d.move(h+"]["),c();const y=a.stack;a.stack=[],c=a.enter("reference");const g=a.safe(a.associationId(e),{before:p,after:"]",...d.current()});return c(),a.stack=y,s(),o==="full"||!h||h!==g?p+=d.move(g+"]"):o==="shortcut"?p=p.slice(0,-1):p+=d.move("]"),p}function B9(){return"["}function gg(e){const r=e.options.bullet||"*";if(r!=="*"&&r!=="+"&&r!=="-")throw new Error("Cannot serialize items with `"+r+"` for `options.bullet`, expected `*`, `+`, or `-`");return r}function P9(e){const r=gg(e),a=e.options.bulletOther;if(!a)return r==="*"?"-":"*";if(a!=="*"&&a!=="+"&&a!=="-")throw new Error("Cannot serialize items with `"+a+"` for `options.bulletOther`, expected `*`, `+`, or `-`");if(a===r)throw new Error("Expected `bullet` (`"+r+"`) and `bulletOther` (`"+a+"`) to be different");return a}function F9(e){const r=e.options.bulletOrdered||".";if(r!=="."&&r!==")")throw new Error("Cannot serialize items with `"+r+"` for `options.bulletOrdered`, expected `.` or `)`");return r}function cC(e){const r=e.options.rule||"*";if(r!=="*"&&r!=="-"&&r!=="_")throw new Error("Cannot serialize rules with `"+r+"` for `options.rule`, expected `*`, `-`, or `_`");return r}function U9(e,r,a,l){const o=a.enter("list"),s=a.bulletCurrent;let c=e.ordered?F9(a):gg(a);const d=e.ordered?c==="."?")":".":P9(a);let p=r&&a.bulletLastUsed?c===a.bulletLastUsed:!1;if(!e.ordered){const y=e.children?e.children[0]:void 0;if((c==="*"||c==="-")&&y&&(!y.children||!y.children[0])&&a.stack[a.stack.length-1]==="list"&&a.stack[a.stack.length-2]==="listItem"&&a.stack[a.stack.length-3]==="list"&&a.stack[a.stack.length-4]==="listItem"&&a.indexStack[a.indexStack.length-1]===0&&a.indexStack[a.indexStack.length-2]===0&&a.indexStack[a.indexStack.length-3]===0&&(p=!0),cC(a)===c&&y){let g=-1;for(;++g<e.children.length;){const b=e.children[g];if(b&&b.type==="listItem"&&b.children&&b.children[0]&&b.children[0].type==="thematicBreak"){p=!0;break}}}}p&&(c=d),a.bulletCurrent=c;const h=a.containerFlow(e,l);return a.bulletLastUsed=c,a.bulletCurrent=s,o(),h}function H9(e){const r=e.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 V9(e,r,a,l){const o=H9(a);let s=a.bulletCurrent||gg(a);r&&r.type==="list"&&r.ordered&&(s=(typeof r.start=="number"&&r.start>-1?r.start:1)+(a.options.incrementListMarker===!1?0:r.children.indexOf(e))+s);let c=s.length+1;(o==="tab"||o==="mixed"&&(r&&r.type==="list"&&r.spread||e.spread))&&(c=Math.ceil(c/4)*4);const d=a.createTracker(l);d.move(s+" ".repeat(c-s.length)),d.shift(c);const p=a.enter("listItem"),h=a.indentLines(a.containerFlow(e,d.current()),y);return p(),h;function y(g,b,w){return b?(w?"":" ".repeat(c))+g:(w?s:s+" ".repeat(c-s.length))+g}}function $9(e,r,a,l){const o=a.enter("paragraph"),s=a.enter("phrasing"),c=a.containerPhrasing(e,l);return s(),o(),c}const q9=yd(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function G9(e,r,a,l){return(e.children.some(function(c){return q9(c)})?a.containerPhrasing:a.containerFlow).call(a,e,l)}function Y9(e){const r=e.options.strong||"*";if(r!=="*"&&r!=="_")throw new Error("Cannot serialize strong with `"+r+"` for `options.strong`, expected `*`, or `_`");return r}dC.peek=X9;function dC(e,r,a,l){const o=Y9(a),s=a.enter("strong"),c=a.createTracker(l),d=c.move(o+o);let p=c.move(a.containerPhrasing(e,{after:o,before:d,...c.current()}));const h=p.charCodeAt(0),y=_c(l.before.charCodeAt(l.before.length-1),h,o);y.inside&&(p=ts(h)+p.slice(1));const g=p.charCodeAt(p.length-1),b=_c(l.after.charCodeAt(0),g,o);b.inside&&(p=p.slice(0,-1)+ts(g));const w=c.move(o+o);return s(),a.attentionEncodeSurroundingInfo={after:b.outside,before:y.outside},d+p+w}function X9(e,r,a){return a.options.strong||"*"}function K9(e,r,a,l){return a.safe(e.value,l)}function Q9(e){const r=e.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 Z9(e,r,a){const l=(cC(a)+(a.options.ruleSpaces?" ":"")).repeat(Q9(a));return a.options.ruleSpaces?l.slice(0,-1):l}const fC={blockquote:v9,break:r1,code:A9,definition:j9,emphasis:nC,hardBreak:r1,heading:M9,html:rC,image:aC,imageReference:lC,inlineCode:iC,link:sC,linkReference:uC,list:U9,listItem:V9,paragraph:$9,root:G9,strong:dC,text:K9,thematicBreak:Z9};function W9(){return{enter:{table:J9,tableData:a1,tableHeader:a1,tableRow:tB},exit:{codeText:nB,table:eB,tableData:xh,tableHeader:xh,tableRow:xh}}}function J9(e){const r=e._align;this.enter({type:"table",align:r.map(function(a){return a==="none"?null:a}),children:[]},e),this.data.inTable=!0}function eB(e){this.exit(e),this.data.inTable=void 0}function tB(e){this.enter({type:"tableRow",children:[]},e)}function xh(e){this.exit(e)}function a1(e){this.enter({type:"tableCell",children:[]},e)}function nB(e){let r=this.resume();this.data.inTable&&(r=r.replace(/\\([\\|])/g,rB));const a=this.stack[this.stack.length-1];a.type,a.value=r,this.exit(e)}function rB(e,r){return r==="|"?r:e}function aB(e){const r=e||{},a=r.tableCellPadding,l=r.tablePipeAlign,o=r.stringLength,s=a?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:`
443
- `,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(w,k,S,C){return h(y(w,S,C),w.align)}function d(w,k,S,C){const A=g(w,S,C),N=h([A]);return N.slice(0,N.indexOf(`
444
- `))}function p(w,k,S,C){const A=S.enter("tableCell"),N=S.enter("phrasing"),j=S.containerPhrasing(w,{...C,before:s,after:s});return N(),A(),j}function h(w,k){return x9(w,{align:k,alignDelimiters:l,padding:a,stringLength:o})}function y(w,k,S){const C=w.children;let A=-1;const N=[],j=k.enter("table");for(;++A<C.length;)N[A]=g(C[A],k,S);return j(),N}function g(w,k,S){const C=w.children;let A=-1;const N=[],j=k.enter("tableRow");for(;++A<C.length;)N[A]=p(C[A],w,k,S);return j(),N}function b(w,k,S){let C=fC.inlineCode(w,k,S);return S.stack.includes("tableCell")&&(C=C.replace(/\|/g,"\\$&")),C}}function lB(){return{exit:{taskListCheckValueChecked:l1,taskListCheckValueUnchecked:l1,paragraph:oB}}}function iB(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:sB}}}function l1(e){const r=this.stack[this.stack.length-2];r.type,r.checked=e.type==="taskListCheckValueChecked"}function oB(e){const r=this.stack[this.stack.length-2];if(r&&r.type==="listItem"&&typeof r.checked=="boolean"){const a=this.stack[this.stack.length-1];a.type;const l=a.children[0];if(l&&l.type==="text"){const o=r.children;let s=-1,c;for(;++s<o.length;){const d=o[s];if(d.type==="paragraph"){c=d;break}}c===a&&(l.value=l.value.slice(1),l.value.length===0?a.children.shift():a.position&&l.position&&typeof l.position.start.offset=="number"&&(l.position.start.column++,l.position.start.offset++,a.position.start=Object.assign({},l.position.start)))}}this.exit(e)}function sB(e,r,a,l){const o=e.children[0],s=typeof e.checked=="boolean"&&o&&o.type==="paragraph",c="["+(e.checked?"x":" ")+"] ",d=a.createTracker(l);s&&d.move(c);let p=fC.listItem(e,r,a,{...l,...d.current()});return s&&(p=p.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,h)),p;function h(y){return y+c}}function uB(){return[U8(),s9(),f9(),W9(),lB()]}function cB(e){return{extensions:[H8(),u9(e),p9(),aB(e),iB()]}}const dB={tokenize:yB,partial:!0},pC={tokenize:xB,partial:!0},hC={tokenize:bB,partial:!0},mC={tokenize:vB,partial:!0},fB={tokenize:wB,partial:!0},gC={name:"wwwAutolink",tokenize:mB,previous:xC},yC={name:"protocolAutolink",tokenize:gB,previous:bC},Kr={name:"emailAutolink",tokenize:hB,previous:vC},xr={};function pB(){return{text:xr}}let ol=48;for(;ol<123;)xr[ol]=Kr,ol++,ol===58?ol=65:ol===91&&(ol=97);xr[43]=Kr;xr[45]=Kr;xr[46]=Kr;xr[95]=Kr;xr[72]=[Kr,yC];xr[104]=[Kr,yC];xr[87]=[Kr,gC];xr[119]=[Kr,gC];function hB(e,r,a){const l=this;let o,s;return c;function c(g){return!Wh(g)||!vC.call(l,l.previous)||yg(l.events)?a(g):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),d(g))}function d(g){return Wh(g)?(e.consume(g),d):g===64?(e.consume(g),p):a(g)}function p(g){return g===46?e.check(fB,y,h)(g):g===45||g===95||Zt(g)?(s=!0,e.consume(g),p):y(g)}function h(g){return e.consume(g),o=!0,p}function y(g){return s&&o&&nn(l.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),r(g)):a(g)}}function mB(e,r,a){const l=this;return o;function o(c){return c!==87&&c!==119||!xC.call(l,l.previous)||yg(l.events)?a(c):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(dB,e.attempt(pC,e.attempt(hC,s),a),a)(c))}function s(c){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),r(c)}}function gB(e,r,a){const l=this;let o="",s=!1;return c;function c(g){return(g===72||g===104)&&bC.call(l,l.previous)&&!yg(l.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),o+=String.fromCodePoint(g),e.consume(g),d):a(g)}function d(g){if(nn(g)&&o.length<5)return o+=String.fromCodePoint(g),e.consume(g),d;if(g===58){const b=o.toLowerCase();if(b==="http"||b==="https")return e.consume(g),p}return a(g)}function p(g){return g===47?(e.consume(g),s?h:(s=!0,p)):a(g)}function h(g){return g===null||Nc(g)||ft(g)||gl(g)||hd(g)?a(g):e.attempt(pC,e.attempt(hC,y),a)(g)}function y(g){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),r(g)}}function yB(e,r,a){let l=0;return o;function o(c){return(c===87||c===119)&&l<3?(l++,e.consume(c),o):c===46&&l===3?(e.consume(c),s):a(c)}function s(c){return c===null?a(c):r(c)}}function xB(e,r,a){let l,o,s;return c;function c(h){return h===46||h===95?e.check(mC,p,d)(h):h===null||ft(h)||gl(h)||h!==45&&hd(h)?p(h):(s=!0,e.consume(h),c)}function d(h){return h===95?l=!0:(o=l,l=void 0),e.consume(h),c}function p(h){return o||l||!s?a(h):r(h)}}function bB(e,r){let a=0,l=0;return o;function o(c){return c===40?(a++,e.consume(c),o):c===41&&l<a?s(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?e.check(mC,r,s)(c):c===null||ft(c)||gl(c)?r(c):(e.consume(c),o)}function s(c){return c===41&&l++,e.consume(c),o}}function vB(e,r,a){return l;function l(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?(e.consume(d),l):d===38?(e.consume(d),s):d===93?(e.consume(d),o):d===60||d===null||ft(d)||gl(d)?r(d):a(d)}function o(d){return d===null||d===40||d===91||ft(d)||gl(d)?r(d):l(d)}function s(d){return nn(d)?c(d):a(d)}function c(d){return d===59?(e.consume(d),l):nn(d)?(e.consume(d),c):a(d)}}function wB(e,r,a){return l;function l(s){return e.consume(s),o}function o(s){return Zt(s)?a(s):r(s)}}function xC(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||ft(e)}function bC(e){return!nn(e)}function vC(e){return!(e===47||Wh(e))}function Wh(e){return e===43||e===45||e===46||e===95||Zt(e)}function yg(e){let r=e.length,a=!1;for(;r--;){const l=e[r][1];if((l.type==="labelLink"||l.type==="labelImage")&&!l._balanced){a=!0;break}if(l._gfmAutolinkLiteralWalkedInto){a=!1;break}}return e.length>0&&!a&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),a}const SB={tokenize:_B,partial:!0};function kB(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:NB,continuation:{tokenize:jB},exit:TB}},text:{91:{name:"gfmFootnoteCall",tokenize:AB},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:EB,resolveTo:CB}}}}function EB(e,r,a){const l=this;let o=l.events.length;const s=l.parser.gfmFootnotes||(l.parser.gfmFootnotes=[]);let c;for(;o--;){const p=l.events[o][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 a(p);const h=tr(l.sliceSerialize({start:c.end,end:l.now()}));return h.codePointAt(0)!==94||!s.includes(h.slice(1))?a(p):(e.enter("gfmFootnoteCallLabelMarker"),e.consume(p),e.exit("gfmFootnoteCallLabelMarker"),r(p))}}function CB(e,r){let a=e.length;for(;a--;)if(e[a][1].type==="labelImage"&&e[a][0]==="enter"){e[a][1];break}e[a+1][1].type="data",e[a+3][1].type="gfmFootnoteCallLabelMarker";const l={type:"gfmFootnoteCall",start:Object.assign({},e[a+3][1].start),end:Object.assign({},e[e.length-1][1].end)},o={type:"gfmFootnoteCallMarker",start:Object.assign({},e[a+3][1].end),end:Object.assign({},e[a+3][1].end)};o.end.column++,o.end.offset++,o.end._bufferIndex++;const s={type:"gfmFootnoteCallString",start:Object.assign({},o.end),end:Object.assign({},e[e.length-1][1].start)},c={type:"chunkString",contentType:"string",start:Object.assign({},s.start),end:Object.assign({},s.end)},d=[e[a+1],e[a+2],["enter",l,r],e[a+3],e[a+4],["enter",o,r],["exit",o,r],["enter",s,r],["enter",c,r],["exit",c,r],["exit",s,r],e[e.length-2],e[e.length-1],["exit",l,r]];return e.splice(a,e.length-a+1,...d),e}function AB(e,r,a){const l=this,o=l.parser.gfmFootnotes||(l.parser.gfmFootnotes=[]);let s=0,c;return d;function d(g){return e.enter("gfmFootnoteCall"),e.enter("gfmFootnoteCallLabelMarker"),e.consume(g),e.exit("gfmFootnoteCallLabelMarker"),p}function p(g){return g!==94?a(g):(e.enter("gfmFootnoteCallMarker"),e.consume(g),e.exit("gfmFootnoteCallMarker"),e.enter("gfmFootnoteCallString"),e.enter("chunkString").contentType="string",h)}function h(g){if(s>999||g===93&&!c||g===null||g===91||ft(g))return a(g);if(g===93){e.exit("chunkString");const b=e.exit("gfmFootnoteCallString");return o.includes(tr(l.sliceSerialize(b)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(g),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),r):a(g)}return ft(g)||(c=!0),s++,e.consume(g),g===92?y:h}function y(g){return g===91||g===92||g===93?(e.consume(g),s++,h):h(g)}}function NB(e,r,a){const l=this,o=l.parser.gfmFootnotes||(l.parser.gfmFootnotes=[]);let s,c=0,d;return p;function p(k){return e.enter("gfmFootnoteDefinition")._container=!0,e.enter("gfmFootnoteDefinitionLabel"),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(k),e.exit("gfmFootnoteDefinitionLabelMarker"),h}function h(k){return k===94?(e.enter("gfmFootnoteDefinitionMarker"),e.consume(k),e.exit("gfmFootnoteDefinitionMarker"),e.enter("gfmFootnoteDefinitionLabelString"),e.enter("chunkString").contentType="string",y):a(k)}function y(k){if(c>999||k===93&&!d||k===null||k===91||ft(k))return a(k);if(k===93){e.exit("chunkString");const S=e.exit("gfmFootnoteDefinitionLabelString");return s=tr(l.sliceSerialize(S)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(k),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),b}return ft(k)||(d=!0),c++,e.consume(k),k===92?g:y}function g(k){return k===91||k===92||k===93?(e.consume(k),c++,y):y(k)}function b(k){return k===58?(e.enter("definitionMarker"),e.consume(k),e.exit("definitionMarker"),o.includes(s)||o.push(s),Ze(e,w,"gfmFootnoteDefinitionWhitespace")):a(k)}function w(k){return r(k)}}function jB(e,r,a){return e.check(Es,r,e.attempt(SB,r,a))}function TB(e){e.exit("gfmFootnoteDefinition")}function _B(e,r,a){const l=this;return Ze(e,o,"gfmFootnoteDefinitionIndent",5);function o(s){const c=l.events[l.events.length-1];return c&&c[1].type==="gfmFootnoteDefinitionIndent"&&c[2].sliceSerialize(c[1],!0).length===4?r(s):a(s)}}function RB(e){let a=(e||{}).singleTilde;const l={name:"strikethrough",tokenize:s,resolveAll:o};return a==null&&(a=!0),{text:{126:l},insideSpan:{null:[l]},attentionMarkers:{null:[126]}};function o(c,d){let p=-1;for(;++p<c.length;)if(c[p][0]==="enter"&&c[p][1].type==="strikethroughSequenceTemporary"&&c[p][1]._close){let h=p;for(;h--;)if(c[h][0]==="exit"&&c[h][1].type==="strikethroughSequenceTemporary"&&c[h][1]._open&&c[p][1].end.offset-c[p][1].start.offset===c[h][1].end.offset-c[h][1].start.offset){c[p][1].type="strikethroughSequence",c[h][1].type="strikethroughSequence";const y={type:"strikethrough",start:Object.assign({},c[h][1].start),end:Object.assign({},c[p][1].end)},g={type:"strikethroughText",start:Object.assign({},c[h][1].end),end:Object.assign({},c[p][1].start)},b=[["enter",y,d],["enter",c[h][1],d],["exit",c[h][1],d],["enter",g,d]],w=d.parser.constructs.insideSpan.null;w&&Tn(b,b.length,0,md(w,c.slice(h+1,p),d)),Tn(b,b.length,0,[["exit",g,d],["enter",c[p][1],d],["exit",c[p][1],d],["exit",y,d]]),Tn(c,h-1,p-h+3,b),p=h+b.length-2;break}}for(p=-1;++p<c.length;)c[p][1].type==="strikethroughSequenceTemporary"&&(c[p][1].type="data");return c}function s(c,d,p){const h=this.previous,y=this.events;let g=0;return b;function b(k){return h===126&&y[y.length-1][1].type!=="characterEscape"?p(k):(c.enter("strikethroughSequenceTemporary"),w(k))}function w(k){const S=ki(h);if(k===126)return g>1?p(k):(c.consume(k),g++,w);if(g<2&&!a)return p(k);const C=c.exit("strikethroughSequenceTemporary"),A=ki(k);return C._open=!A||A===2&&!!S,C._close=!S||S===2&&!!A,d(k)}}}class MB{constructor(){this.map=[]}add(r,a,l){OB(this,r,a,l)}consume(r){if(this.map.sort(function(s,c){return s[0]-c[0]}),this.map.length===0)return;let a=this.map.length;const l=[];for(;a>0;)a-=1,l.push(r.slice(this.map[a][0]+this.map[a][1]),this.map[a][2]),r.length=this.map[a][0];l.push(r.slice()),r.length=0;let o=l.pop();for(;o;){for(const s of o)r.push(s);o=l.pop()}this.map.length=0}}function OB(e,r,a,l){let o=0;if(!(a===0&&l.length===0)){for(;o<e.map.length;){if(e.map[o][0]===r){e.map[o][1]+=a,e.map[o][2].push(...l);return}o+=1}e.map.push([r,a,l])}}function DB(e,r){let a=!1;const l=[];for(;r<e.length;){const o=e[r];if(a){if(o[0]==="enter")o[1].type==="tableContent"&&l.push(e[r+1][1].type==="tableDelimiterMarker"?"left":"none");else if(o[1].type==="tableContent"){if(e[r-1][1].type==="tableDelimiterMarker"){const s=l.length-1;l[s]=l[s]==="left"?"center":"right"}}else if(o[1].type==="tableDelimiterRow")break}else o[0]==="enter"&&o[1].type==="tableDelimiterRow"&&(a=!0);r+=1}return l}function zB(){return{flow:{null:{name:"table",tokenize:LB,resolveAll:IB}}}}function LB(e,r,a){const l=this;let o=0,s=0,c;return d;function d(I){let Y=l.events.length-1;for(;Y>-1;){const W=l.events[Y][1].type;if(W==="lineEnding"||W==="linePrefix")Y--;else break}const V=Y>-1?l.events[Y][1].type:null,ue=V==="tableHead"||V==="tableRow"?M:p;return ue===M&&l.parser.lazy[l.now().line]?a(I):ue(I)}function p(I){return e.enter("tableHead"),e.enter("tableRow"),h(I)}function h(I){return I===124||(c=!0,s+=1),y(I)}function y(I){return I===null?a(I):Re(I)?s>1?(s=0,l.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(I),e.exit("lineEnding"),w):a(I):Ge(I)?Ze(e,y,"whitespace")(I):(s+=1,c&&(c=!1,o+=1),I===124?(e.enter("tableCellDivider"),e.consume(I),e.exit("tableCellDivider"),c=!0,y):(e.enter("data"),g(I)))}function g(I){return I===null||I===124||ft(I)?(e.exit("data"),y(I)):(e.consume(I),I===92?b:g)}function b(I){return I===92||I===124?(e.consume(I),g):g(I)}function w(I){return l.interrupt=!1,l.parser.lazy[l.now().line]?a(I):(e.enter("tableDelimiterRow"),c=!1,Ge(I)?Ze(e,k,"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(I):k(I))}function k(I){return I===45||I===58?C(I):I===124?(c=!0,e.enter("tableCellDivider"),e.consume(I),e.exit("tableCellDivider"),S):D(I)}function S(I){return Ge(I)?Ze(e,C,"whitespace")(I):C(I)}function C(I){return I===58?(s+=1,c=!0,e.enter("tableDelimiterMarker"),e.consume(I),e.exit("tableDelimiterMarker"),A):I===45?(s+=1,A(I)):I===null||Re(I)?O(I):D(I)}function A(I){return I===45?(e.enter("tableDelimiterFiller"),N(I)):D(I)}function N(I){return I===45?(e.consume(I),N):I===58?(c=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(I),e.exit("tableDelimiterMarker"),j):(e.exit("tableDelimiterFiller"),j(I))}function j(I){return Ge(I)?Ze(e,O,"whitespace")(I):O(I)}function O(I){return I===124?k(I):I===null||Re(I)?!c||o!==s?D(I):(e.exit("tableDelimiterRow"),e.exit("tableHead"),r(I)):D(I)}function D(I){return a(I)}function M(I){return e.enter("tableRow"),U(I)}function U(I){return I===124?(e.enter("tableCellDivider"),e.consume(I),e.exit("tableCellDivider"),U):I===null||Re(I)?(e.exit("tableRow"),r(I)):Ge(I)?Ze(e,U,"whitespace")(I):(e.enter("data"),F(I))}function F(I){return I===null||I===124||ft(I)?(e.exit("data"),U(I)):(e.consume(I),I===92?Q:F)}function Q(I){return I===92||I===124?(e.consume(I),F):F(I)}}function IB(e,r){let a=-1,l=!0,o=0,s=[0,0,0,0],c=[0,0,0,0],d=!1,p=0,h,y,g;const b=new MB;for(;++a<e.length;){const w=e[a],k=w[1];w[0]==="enter"?k.type==="tableHead"?(d=!1,p!==0&&(i1(b,r,p,h,y),y=void 0,p=0),h={type:"table",start:Object.assign({},k.start),end:Object.assign({},k.end)},b.add(a,0,[["enter",h,r]])):k.type==="tableRow"||k.type==="tableDelimiterRow"?(l=!0,g=void 0,s=[0,0,0,0],c=[0,a+1,0,0],d&&(d=!1,y={type:"tableBody",start:Object.assign({},k.start),end:Object.assign({},k.end)},b.add(a,0,[["enter",y,r]])),o=k.type==="tableDelimiterRow"?2:y?3:1):o&&(k.type==="data"||k.type==="tableDelimiterMarker"||k.type==="tableDelimiterFiller")?(l=!1,c[2]===0&&(s[1]!==0&&(c[0]=c[1],g=tc(b,r,s,o,void 0,g),s=[0,0,0,0]),c[2]=a)):k.type==="tableCellDivider"&&(l?l=!1:(s[1]!==0&&(c[0]=c[1],g=tc(b,r,s,o,void 0,g)),s=c,c=[s[1],a,0,0])):k.type==="tableHead"?(d=!0,p=a):k.type==="tableRow"||k.type==="tableDelimiterRow"?(p=a,s[1]!==0?(c[0]=c[1],g=tc(b,r,s,o,a,g)):c[1]!==0&&(g=tc(b,r,c,o,a,g)),o=0):o&&(k.type==="data"||k.type==="tableDelimiterMarker"||k.type==="tableDelimiterFiller")&&(c[3]=a)}for(p!==0&&i1(b,r,p,h,y),b.consume(r.events),a=-1;++a<r.events.length;){const w=r.events[a];w[0]==="enter"&&w[1].type==="table"&&(w[1]._align=DB(r.events,a))}return e}function tc(e,r,a,l,o,s){const c=l===1?"tableHeader":l===2?"tableDelimiter":"tableData",d="tableContent";a[0]!==0&&(s.end=Object.assign({},di(r.events,a[0])),e.add(a[0],0,[["exit",s,r]]));const p=di(r.events,a[1]);if(s={type:c,start:Object.assign({},p),end:Object.assign({},p)},e.add(a[1],0,[["enter",s,r]]),a[2]!==0){const h=di(r.events,a[2]),y=di(r.events,a[3]),g={type:d,start:Object.assign({},h),end:Object.assign({},y)};if(e.add(a[2],0,[["enter",g,r]]),l!==2){const b=r.events[a[2]],w=r.events[a[3]];if(b[1].end=Object.assign({},w[1].end),b[1].type="chunkText",b[1].contentType="text",a[3]>a[2]+1){const k=a[2]+1,S=a[3]-a[2]-1;e.add(k,S,[])}}e.add(a[3]+1,0,[["exit",g,r]])}return o!==void 0&&(s.end=Object.assign({},di(r.events,o)),e.add(o,0,[["exit",s,r]]),s=void 0),s}function i1(e,r,a,l,o){const s=[],c=di(r.events,a);o&&(o.end=Object.assign({},c),s.push(["exit",o,r])),l.end=Object.assign({},c),s.push(["exit",l,r]),e.add(a+1,0,s)}function di(e,r){const a=e[r],l=a[0]==="enter"?"start":"end";return a[1][l]}const BB={name:"tasklistCheck",tokenize:FB};function PB(){return{text:{91:BB}}}function FB(e,r,a){const l=this;return o;function o(p){return l.previous!==null||!l._gfmTasklistFirstContentOfListItem?a(p):(e.enter("taskListCheck"),e.enter("taskListCheckMarker"),e.consume(p),e.exit("taskListCheckMarker"),s)}function s(p){return ft(p)?(e.enter("taskListCheckValueUnchecked"),e.consume(p),e.exit("taskListCheckValueUnchecked"),c):p===88||p===120?(e.enter("taskListCheckValueChecked"),e.consume(p),e.exit("taskListCheckValueChecked"),c):a(p)}function c(p){return p===93?(e.enter("taskListCheckMarker"),e.consume(p),e.exit("taskListCheckMarker"),e.exit("taskListCheck"),d):a(p)}function d(p){return Re(p)?r(p):Ge(p)?e.check({tokenize:UB},r,a)(p):a(p)}}function UB(e,r,a){return Ze(e,l,"whitespace");function l(o){return o===null?a(o):r(o)}}function HB(e){return RE([pB(),kB(),RB(e),zB(),PB()])}const VB={};function $B(e){const r=this,a=e||VB,l=r.data(),o=l.micromarkExtensions||(l.micromarkExtensions=[]),s=l.fromMarkdownExtensions||(l.fromMarkdownExtensions=[]),c=l.toMarkdownExtensions||(l.toMarkdownExtensions=[]);o.push(HB(a)),s.push(uB()),c.push(cB(a))}function qB({children:e,className:r}){return f.jsx("div",{className:ye("markdown-render max-w-none",r),children:f.jsx(R8,{remarkPlugins:[$B],components:{code({className:a,children:l,...o}){const s=/language-(\w+)/.exec(a||""),c=s?s[1]:"",d=!c,p=Array.isArray(l)?l.join(""):String(l);return!d&&c?f.jsx("div",{className:"w-full max-w-full overflow-x-auto my-2",children:f.jsx(Jm,{theme:pd.oneDark,code:p.trim(),language:c,children:({className:h,style:y,tokens:g,getLineProps:b,getTokenProps:w})=>f.jsx("pre",{className:ye("rounded-lg text-sm p-3",h),style:y,children:g.map((k,S)=>f.jsx("div",{...b({line:k}),children:k.map((C,A)=>f.jsx("span",{...w({token:C})},A))},S))})})}):f.jsx("code",{className:ye("px-1.5 py-0.5 rounded bg-muted text-sm font-mono break-all",a),...o,children:l})},a({href:a,children:l,...o}){return f.jsx("a",{href:a,target:"_blank",rel:"noopener noreferrer",className:"text-primary underline underline-offset-2 hover:text-primary/80 transition-colors",...o,children:l})},p({children:a}){return f.jsx("p",{className:"last:mb-0 leading-relaxed break-words",children:a})},ul({children:a}){return f.jsx("ul",{className:"list-outside list-disc pl-4",children:a})},ol({children:a}){return f.jsx("ol",{className:"list-outside list-decimal pl-4",children:a})},li({children:a,className:l}){const o=l==null?void 0:l.includes("nested");return f.jsx("li",{className:ye("leading-snug",o&&"ml-4"),children:a})},h1({children:a}){return f.jsx("h1",{className:"text-lg font-semibold mb-1.5 mt-3 first:mt-0",children:a})},h2({children:a}){return f.jsx("h2",{className:"text-base font-semibold mb-1.5 mt-2.5 first:mt-0",children:a})},h3({children:a}){return f.jsx("h3",{className:"text-sm font-semibold mb-1 mt-2 first:mt-0",children:a})},blockquote({children:a}){return f.jsx("blockquote",{className:"border-l-2 border-muted-foreground/40 pl-3 my-1.5 text-muted-foreground italic",children:a})},strong({children:a}){return f.jsx("strong",{className:"font-semibold",children:a})},em({children:a}){return f.jsx("em",{className:"italic",children:a})},hr(){return f.jsx("hr",{className:"my-3 border-border"})},table({children:a}){return f.jsx("div",{className:"my-2 overflow-x-auto max-w-full",children:f.jsx("table",{className:"w-full border-collapse text-sm",children:a})})},th({children:a}){return f.jsx("th",{className:"border border-border px-2 py-1.5 bg-muted text-left font-semibold",children:a})},td({children:a}){return f.jsx("td",{className:"border border-border px-2 py-1.5",children:a})}},children:e})})}function GB(e){return e.filter(r=>r.type==="text").map(r=>r.text).join("")}function YB(e,r){const a=e.map(c=>({message:c.message,parts:c.parts,isQueued:!1})),l=r.map(c=>({message:{id:c.id,role:"user",sessionId:c.sessionId,createdAt:c.createdAt},parts:[{id:`${c.id}-part`,messageId:c.id,createdAt:c.createdAt,type:"text",text:c.content}],isQueued:!0,queueId:c.id})),o=[...a].sort((c,d)=>c.message.createdAt-d.message.createdAt),s=[...l].sort((c,d)=>c.message.createdAt-d.message.createdAt);return[...o,...s]}function XB({parts:e,pendingPermissions:r,onPermissionResponse:a,onNavigateToSubagent:l}){const o=[...e].sort((s,c)=>s.createdAt-c.createdAt);return f.jsx(f.Fragment,{children:o.map(s=>{switch(s.type){case"text":return f.jsx("div",{className:"min-w-0",children:f.jsx(qB,{children:s.text||"..."})},s.id);case"reasoning":return f.jsx("div",{className:"text-muted-foreground text-sm italic border-l-2 border-muted-foreground/30 pl-3 my-2",children:s.text},s.id);case"tool":return f.jsx(x5,{part:s,pendingPermissions:r,onPermissionResponse:a,onNavigateToSubagent:l},s.id);case"image":return f.jsx("img",{src:s.url,alt:"",className:"max-w-full rounded-lg mt-2"},s.id);case"file":return f.jsx("div",{className:"mt-2 p-2 bg-muted rounded text-sm",children:s.filename||"unnamed"},s.id);case"compaction":return f.jsxs("div",{className:"mt-2 p-2 bg-muted rounded text-sm text-muted-foreground",children:[s.compactedMessageIds.length," messages compacted"]},s.id);default:return null}})})}function KB({session:e,messagesWithParts:r,queuedMessages:a,preconfigs:l,models:o,defaultModel:s,onSendMessage:c,onRemoveFromQueue:d,onChangePreconfig:p,onChangeModel:h,pendingPermissions:y,onPermissionResponse:g,onRename:b,usage:w,modelName:k,onNavigateToSubagent:S,onNavigateBack:C,isStreaming:A,onInterrupt:N,serverUrl:j,apiToken:O}){const D=v.useRef(null),[M,U]=v.useState(!0),F=150,Q=YB(r,a);v.useEffect(()=>{U(!0),D.current&&(D.current.scrollTop=D.current.scrollHeight)},[e.id]),v.useEffect(()=>{D.current&&M&&(D.current.scrollTop=D.current.scrollHeight)},[r,M]),v.useEffect(()=>{const Y=D.current;if(!Y)return;const V=()=>{const{scrollHeight:ue,scrollTop:W,clientHeight:J}=Y,B=ue-W-J;U(B<F)};return Y.addEventListener("scroll",V,{passive:!0}),()=>Y.removeEventListener("scroll",V)},[]);const I=y.filter(Y=>!r.some(V=>V.parts.some(ue=>ue.type==="tool"&&ue.callId===Y.toolCallId)));return f.jsxs("div",{className:"flex flex-col flex-1 min-h-0",children:[f.jsx(Wz,{session:e,preconfigs:l,models:o,defaultModel:s,usage:w,modelName:k,onChangePreconfig:p,onChangeModel:h,onRename:b,onNavigateBack:C,isStreaming:A,onInterrupt:N}),e.status==="closed"&&f.jsx(oc,{className:"mx-4 mt-4",children:f.jsx(sc,{children:"This session is archived. You can reopen it from the sidebar."})}),f.jsx(Ta,{className:"flex-1 min-h-0",ref:D,children:f.jsxs("div",{className:"p-4",children:[Q.length===0?f.jsxs("div",{className:"text-center py-16 text-muted-foreground",children:[f.jsx("p",{className:"text-lg mb-2",children:"Start a conversation"}),f.jsx("p",{className:"text-sm",children:"Send a message below to begin."})]}):Q.map(Y=>f.jsx(Jz,{message:Y.message,textContent:GB(Y.parts),isQueued:Y.isQueued,onRemove:Y.isQueued?()=>d(Y.queueId):void 0,children:Y.parts.length===0?f.jsx("span",{className:"opacity-50",children:"..."}):f.jsx(XB,{parts:Y.parts,pendingPermissions:y,onPermissionResponse:g,onNavigateToSubagent:S})},Y.message.id)),I.length>0&&f.jsx("div",{className:"mt-4 flex flex-col gap-2",children:I.map(Y=>f.jsxs("div",{className:"p-3 bg-warning/10 border border-warning/30 rounded-lg",children:[f.jsxs("div",{className:"flex items-center gap-2 mb-2",children:[f.jsx("span",{className:"text-sm font-medium",children:Y.toolName}),f.jsx("span",{className:"text-xs text-muted-foreground",children:Y.permissionType})]}),f.jsx("p",{className:"text-sm mb-3",children:Y.message}),f.jsxs("div",{className:"flex justify-end gap-2",children:[f.jsx(Me,{variant:"outline",size:"sm",onClick:()=>g(Y.toolCallId,!1,!1),children:"Deny"}),f.jsx(Me,{size:"sm",onClick:()=>g(Y.toolCallId,!0,!1),children:"Approve"})]})]},Y.toolCallId))})]})}),e.status==="active"&&!e.parentId&&f.jsx(v5,{onSendMessage:c,disabled:!1,workspaceId:e.workspaceId,serverUrl:j,apiToken:O}),e.parentId&&f.jsxs("div",{className:"p-4 border-t border-border bg-muted/50 text-center flex items-center justify-center gap-2 text-sm text-muted-foreground",children:[f.jsx(ON,{className:"size-4"}),"This is a subagent session (read-only)"]})]})}function QB({className:e,orientation:r="horizontal",...a}){return f.jsx(xD,{"data-slot":"tabs","data-orientation":r,className:ye("group/tabs flex gap-2 data-horizontal:flex-col",e),...a})}const ZB=Ci("group/tabs-list inline-flex w-fit items-center justify-center rounded-lg p-[3px] text-muted-foreground group-data-horizontal/tabs:h-8 group-data-vertical/tabs:h-fit group-data-vertical/tabs:flex-col data-[variant=line]:rounded-none",{variants:{variant:{default:"bg-muted",line:"gap-1 bg-transparent"}},defaultVariants:{variant:"default"}});function WB({className:e,variant:r="default",...a}){return f.jsx(bD,{"data-slot":"tabs-list","data-variant":r,className:ye(ZB({variant:r}),e),...a})}function bh({className:e,...r}){return f.jsx(vD,{"data-slot":"tabs-trigger",className:ye("relative inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-1.5 py-0.5 text-sm font-medium whitespace-nowrap text-foreground/60 transition-all group-data-vertical/tabs:w-full group-data-vertical/tabs:justify-start hover:text-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 focus-visible:outline-1 focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50 dark:text-muted-foreground dark:hover:text-foreground group-data-[variant=default]/tabs-list:data-active:shadow-sm group-data-[variant=line]/tabs-list:data-active:shadow-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4","group-data-[variant=line]/tabs-list:bg-transparent group-data-[variant=line]/tabs-list:data-active:bg-transparent dark:group-data-[variant=line]/tabs-list:data-active:border-transparent dark:group-data-[variant=line]/tabs-list:data-active:bg-transparent","data-active:bg-background data-active:text-foreground dark:data-active:border-input dark:data-active:bg-input/30 dark:data-active:text-foreground","after:absolute after:bg-foreground after:opacity-0 after:transition-opacity group-data-horizontal/tabs:after:inset-x-0 group-data-horizontal/tabs:after:bottom-[-5px] group-data-horizontal/tabs:after:h-0.5 group-data-vertical/tabs:after:inset-y-0 group-data-vertical/tabs:after:-right-1 group-data-vertical/tabs:after:w-0.5 group-data-[variant=line]/tabs-list:data-active:after:opacity-100",e),...r})}function vh({className:e,...r}){return f.jsx(wD,{"data-slot":"tabs-content",className:ye("flex-1 text-sm outline-none",e),...r})}function o1(e){return new Date(e).toLocaleDateString(void 0,{year:"numeric",month:"short",day:"numeric"})}function s1({permission:e,onRevoke:r}){const a=!!e.revokedAt;return f.jsxs("div",{className:"flex items-start justify-between gap-4 py-3 border-b border-border last:border-0",children:[f.jsxs("div",{className:"flex-1 min-w-0",children:[f.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[f.jsxs(Nn,{variant:a?"outline":"secondary",children:[f.jsx(b1,{className:"size-3","data-icon":"inline-start"}),e.permissionType]}),a&&f.jsx(Nn,{variant:"outline",className:"text-muted-foreground",children:"Revoked"})]}),f.jsx("p",{className:"text-sm font-mono truncate text-muted-foreground",children:e.permissionKey}),f.jsxs("p",{className:"text-xs text-muted-foreground mt-1",children:["Granted ",o1(e.grantedAt),e.revokedAt&&` • Revoked ${o1(e.revokedAt)}`]})]}),!a&&f.jsx(Me,{variant:"ghost",size:"icon",onClick:()=>r(e.id),className:"size-8 text-destructive hover:text-destructive",children:f.jsx(as,{className:"size-4"})})]})}function JB({open:e,onOpenChange:r,title:a,description:l,confirmLabel:o="Confirm",cancelLabel:s="Cancel",variant:c="default",onConfirm:d,onCancel:p}){const h=()=>{p==null||p(),r(!1)},y=()=>{d(),r(!1)};return f.jsx(xs,{open:e,onOpenChange:r,children:f.jsxs(bs,{className:"sm:max-w-[425px]",children:[f.jsxs(vs,{children:[f.jsx(ws,{children:a}),f.jsx(id,{children:l})]}),f.jsxs(Um,{children:[f.jsx(Me,{variant:"outline",onClick:h,children:s}),f.jsx(Me,{variant:c==="destructive"?"destructive":"default",onClick:y,children:o})]})]})})}function eP({token:e,onLogout:r}){return f.jsxs("div",{className:"flex items-center gap-3 p-2 rounded-md bg-muted",children:[f.jsxs("div",{className:"flex items-center gap-2 text-xs",children:[f.jsx("span",{className:"text-muted-foreground",children:"Token:"}),f.jsx("code",{className:"font-mono text-foreground bg-background px-1.5 py-0.5 rounded text-[10px]",children:Sj(e)})]}),f.jsx(Me,{variant:"destructive",size:"sm",onClick:r,title:"Disconnect and clear token",children:"Logout"})]})}function tP({open:e,onOpenChange:r,permissions:a,onRefreshPermissions:l,onRevokePermission:o,onRevokeAllPermissions:s,apiToken:c,onLogout:d}){const{theme:p,setTheme:h}=FA(),[y,g]=v.useState(!1),b=a.filter(k=>!k.revokedAt),w=a.filter(k=>k.revokedAt);return f.jsxs(xs,{open:e,onOpenChange:r,children:[f.jsxs(bs,{className:"sm:max-w-[500px] max-h-[80vh]",children:[f.jsxs(vs,{children:[f.jsx(ws,{children:"Settings"}),f.jsx(id,{children:"Manage your preferences and permissions"})]}),f.jsxs(QB,{defaultValue:"account",className:"mt-4",children:[f.jsxs(WB,{className:"grid w-full grid-cols-3",children:[f.jsx(bh,{value:"account",children:"Account"}),f.jsx(bh,{value:"appearance",children:"Appearance"}),f.jsxs(bh,{value:"permissions",children:[f.jsx(b1,{className:"size-3","data-icon":"inline-start"}),"Permissions",b.length>0&&f.jsx("span",{className:"ml-1.5 px-1.5 py-0.5 text-xs bg-primary text-primary-foreground rounded-full",children:b.length})]})]}),f.jsx(vh,{value:"account",className:"mt-4",children:f.jsx("div",{className:"flex flex-col gap-4",children:f.jsxs("div",{children:[f.jsx(Ca,{className:"text-sm font-medium",children:"Session"}),f.jsx("p",{className:"text-sm text-muted-foreground mb-3",children:"Manage your current session"}),c?f.jsx(eP,{token:c,onLogout:d}):f.jsx("p",{className:"text-sm text-muted-foreground",children:"No active session"})]})})}),f.jsx(vh,{value:"appearance",className:"mt-4",children:f.jsx("div",{className:"flex flex-col gap-4",children:f.jsxs("div",{children:[f.jsx(Ca,{className:"text-sm font-medium",children:"Theme"}),f.jsx("p",{className:"text-sm text-muted-foreground mb-3",children:"Choose your preferred color scheme"}),f.jsxs("div",{className:"grid grid-cols-3 gap-2",children:[f.jsxs(Me,{variant:p==="light"?"default":"outline",className:"justify-start",onClick:()=>h("light"),children:[f.jsx(rj,{className:"size-4","data-icon":"inline-start"}),"Light"]}),f.jsxs(Me,{variant:p==="dark"?"default":"outline",className:"justify-start",onClick:()=>h("dark"),children:[f.jsx(IN,{className:"size-4","data-icon":"inline-start"}),"Dark"]}),f.jsxs(Me,{variant:p==="system"?"default":"outline",className:"justify-start",onClick:()=>h("system"),children:[f.jsx(zN,{className:"size-4","data-icon":"inline-start"}),"System"]})]})]})})}),f.jsx(vh,{value:"permissions",className:"mt-4",children:f.jsxs("div",{className:"flex flex-col gap-4",children:[f.jsxs("div",{className:"flex items-center justify-between",children:[f.jsxs("div",{children:[f.jsx(Ca,{className:"text-sm font-medium",children:"Always-allowed Operations"}),f.jsx("p",{className:"text-sm text-muted-foreground",children:"Tools you've approved to run without asking"})]}),f.jsxs("div",{className:"flex gap-2",children:[f.jsx(Me,{variant:"outline",size:"icon",onClick:l,className:"size-8",children:f.jsx(pi,{className:"size-4"})}),b.length>0&&f.jsxs(Me,{variant:"destructive",size:"sm",onClick:()=>g(!0),children:[f.jsx(as,{className:"size-4","data-icon":"inline-start"}),"Revoke All"]})]})]}),f.jsx(ic,{}),f.jsxs(Ta,{className:"h-[300px]",children:[b.length===0&&w.length===0&&f.jsxs("div",{className:"text-center py-8 text-muted-foreground text-sm",children:["No permissions granted yet.",f.jsx("br",{}),'Approve tool requests with "Always allow" to add them here.']}),b.length>0&&f.jsxs("div",{className:"mb-4",children:[f.jsxs("h4",{className:"text-xs uppercase text-muted-foreground mb-2 font-medium",children:["Active (",b.length,")"]}),b.map(k=>f.jsx(s1,{permission:k,onRevoke:o},k.id))]}),w.length>0&&f.jsxs("div",{children:[f.jsxs("h4",{className:"text-xs uppercase text-muted-foreground mb-2 font-medium",children:["Revoked (",w.length,")"]}),w.map(k=>f.jsx(s1,{permission:k,onRevoke:o},k.id))]})]})]})})]})]}),f.jsx(JB,{open:y,onOpenChange:g,title:"Revoke All Permissions",description:"This will revoke all always-allowed permissions for this workspace. You'll need to approve these tools again when they're used.",confirmLabel:"Revoke All",variant:"destructive",onConfirm:()=>{s(),g(!1)}})]})}function nP({status:e}){switch(e.status){case"connected":return f.jsxs(Nn,{variant:"default",className:"bg-green-600",children:[f.jsx(rs,{className:"size-3 mr-1"}),"Connected"]});case"disabled":return f.jsxs(Nn,{variant:"secondary",children:[f.jsx(Mc,{className:"size-3 mr-1"}),"Disabled"]});case"failed":return f.jsxs(Nn,{variant:"destructive",children:[f.jsx(Bo,{className:"size-3 mr-1"}),"Failed"]});case"needs_auth":return f.jsxs(Nn,{variant:"outline",className:"border-yellow-500 text-yellow-600",children:[f.jsx(Bo,{className:"size-3 mr-1"}),"Needs Auth"]});case"needs_client_registration":return f.jsxs(Nn,{variant:"outline",className:"border-orange-500 text-orange-600",children:[f.jsx(Bo,{className:"size-3 mr-1"}),"Needs Registration"]});default:return f.jsx(Nn,{variant:"secondary",children:"Unknown"})}}function rP({open:e,onOpenChange:r,workspaceId:a,workspacePath:l,serverUrl:o,apiToken:s}){const{fetchWithAuth:c}=ys(),[d,p]=v.useState({}),[h,y]=v.useState(!1),[g,b]=v.useState(null),[w,k]=v.useState(null),S=v.useCallback(async()=>{if(a){y(!0),k(null);try{const O=await c(`/api/workspaces/${a}/mcp/status`,{},{serverUrl:o,token:s});if(!O.ok)throw new Error("Failed to load MCP status");const D=await O.json();p(D.status||{})}catch(O){const D=O instanceof Error?O.message:"Unknown error";k(D)}finally{y(!1)}}},[a,c,o,s]);v.useEffect(()=>{e&&a&&S()},[e,a,S]);const C=async O=>{if(a){b(O);try{if(!(await c(`/api/workspaces/${a}/mcp/connect`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:O})},{serverUrl:o,token:s})).ok)throw new Error("Failed to connect");await S()}catch(D){const M=D instanceof Error?D.message:"Unknown error";k(M)}finally{b(null)}}},A=async O=>{if(a){b(O);try{if(!(await c(`/api/workspaces/${a}/mcp/disconnect`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:O})},{serverUrl:o,token:s})).ok)throw new Error("Failed to disconnect");await S()}catch(D){const M=D instanceof Error?D.message:"Unknown error";k(M)}finally{b(null)}}},N=async O=>{if(a){b(O);try{const D=await c(`/api/workspaces/${a}/mcp/auth`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:O})},{serverUrl:o,token:s});if(!D.ok)throw new Error("Failed to start auth");const M=await D.json();M.authorizationUrl&&window.open(M.authorizationUrl,"_blank"),await S()}catch(D){const M=D instanceof Error?D.message:"Unknown error";k(M)}finally{b(null)}}},j=Object.entries(d);return f.jsx(xs,{open:e,onOpenChange:r,children:f.jsxs(bs,{className:"sm:max-w-[600px] max-h-[80vh]",children:[f.jsxs(vs,{children:[f.jsxs(ws,{className:"flex items-center gap-2",children:[f.jsx(ul,{className:"size-5"}),"MCP Servers"]}),f.jsx(id,{children:"Manage Model Context Protocol servers for this workspace"})]}),f.jsxs("div",{className:"mt-4 space-y-4",children:[w&&f.jsxs(oc,{variant:"destructive",children:[f.jsx(Bo,{className:"size-4"}),f.jsx(sc,{children:w})]}),f.jsxs("div",{className:"flex items-center justify-between",children:[f.jsxs("p",{className:"text-sm text-muted-foreground",children:["Configure servers in ",f.jsx("code",{className:"text-xs bg-muted px-1 rounded",children:".jean2/mcp.json"})]}),f.jsx(Me,{variant:"outline",size:"sm",onClick:S,disabled:h,children:f.jsx(pi,{className:`size-4 ${h?"animate-spin":""}`})})]}),f.jsx(Ta,{className:"h-[400px]",children:h&&j.length===0?f.jsx("div",{className:"flex items-center justify-center py-8",children:f.jsx(Gn,{className:"size-6 animate-spin text-muted-foreground"})}):j.length===0?f.jsxs("div",{className:"text-center py-8 text-muted-foreground",children:[f.jsx(ul,{className:"size-12 mx-auto mb-3 opacity-50"}),f.jsx("p",{className:"font-medium",children:"No MCP servers configured"}),f.jsxs("p",{className:"text-sm mt-1",children:["Create ",f.jsx("code",{className:"text-xs bg-muted px-1 rounded",children:".jean2/mcp.json"})," in your workspace to add servers."]})]}):f.jsx("div",{className:"space-y-3",children:j.map(([O,{config:D,status:M}])=>{var U;return f.jsxs("div",{className:"border rounded-lg p-4",children:[f.jsxs("div",{className:"flex items-start justify-between",children:[f.jsxs("div",{className:"flex items-start gap-3",children:[f.jsx(ul,{className:"size-5 text-muted-foreground mt-0.5"}),f.jsxs("div",{children:[f.jsx("div",{className:"font-medium",children:O}),f.jsx("div",{className:"text-sm text-muted-foreground",children:(D==null?void 0:D.type)==="local"?f.jsxs("span",{children:["Local - ",((U=D.command)==null?void 0:U[0])||"command"]}):(D==null?void 0:D.type)==="remote"?f.jsxs("span",{className:"flex items-center gap-1",children:["Remote - ",D.url]}):"Unknown type"}),M.status==="failed"&&"error"in M&&f.jsx(oc,{variant:"destructive",className:"mt-2 py-2",children:f.jsx(sc,{className:"text-xs",children:M.error})}),M.status==="needs_client_registration"&&"error"in M&&f.jsx(oc,{className:"mt-2 py-2 border-orange-500",children:f.jsx(sc,{className:"text-xs",children:M.error})})]})]}),f.jsx("div",{className:"flex items-center gap-2",children:f.jsx(nP,{status:M})})]}),f.jsxs("div",{className:"flex items-center gap-2 mt-3 pt-3 border-t",children:[M.status==="connected"&&f.jsxs(Me,{variant:"outline",size:"sm",onClick:()=>A(O),disabled:g===O,children:[g===O?f.jsx(Gn,{className:"size-4 animate-spin"}):f.jsx(UN,{className:"size-4"}),f.jsx("span",{className:"ml-1",children:"Disconnect"})]}),(M.status==="disabled"||M.status==="failed")&&f.jsxs(Me,{variant:"outline",size:"sm",onClick:()=>C(O),disabled:g===O,children:[g===O?f.jsx(Gn,{className:"size-4 animate-spin"}):f.jsx(VN,{className:"size-4"}),f.jsx("span",{className:"ml-1",children:"Connect"})]}),M.status==="needs_auth"&&f.jsxs(Me,{variant:"default",size:"sm",onClick:()=>N(O),disabled:g===O,children:[g===O?f.jsx(Gn,{className:"size-4 animate-spin"}):f.jsx(Sh,{className:"size-4"}),f.jsx("span",{className:"ml-1",children:"Authenticate"})]})]})]},O)})})})]})]})})}function u1({message:e="Connecting to server..."}){return f.jsxs("div",{className:"flex flex-col items-center justify-center gap-4 text-muted-foreground",children:[f.jsx(Gn,{className:"size-8 animate-spin"}),f.jsx("p",{className:"text-sm",children:e})]})}const aP=({serverUrl:e,authError:r,retryCount:a,nextRetryIn:l,onRetry:o,onLogout:s})=>f.jsxs("div",{className:"flex flex-col items-center justify-center min-h-[400px] px-4 text-center",children:[f.jsx(w1,{className:"size-12 text-destructive mb-4"}),f.jsx("h2",{className:"text-xl font-semibold text-foreground mb-2",children:"Unable to connect to server"}),f.jsx("p",{className:"text-sm text-muted-foreground mb-4 max-w-[400px]",children:r||"Please check that the server is running."}),e&&f.jsx("p",{className:"text-xs text-muted-foreground mb-6 font-mono bg-muted px-3 py-1.5 rounded",children:e}),f.jsxs("div",{className:"flex flex-col items-center gap-4",children:[f.jsxs("p",{className:"text-sm text-muted-foreground",children:["Retrying in ",l,"s..."]}),f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsxs(Me,{onClick:o,variant:"default",children:[f.jsx(pi,{className:"size-4 mr-2","data-icon":"inline-start"}),"Retry Now"]}),f.jsx(Me,{onClick:s,variant:"ghost",children:"Change Server"})]}),a>0&&f.jsxs("p",{className:"text-xs text-muted-foreground",children:["Retry attempt: ",a]})]})]});function c1({onServerAdded:e,error:r}){const[a,l]=v.useState(""),[o,s]=v.useState(""),[c,d]=v.useState(""),[p,h]=v.useState(!1),[y,g]=v.useState(null),b=w=>{w.preventDefault();const k=a.trim(),S=o.trim(),C=c.trim();if(!k){g("Please enter a server name");return}if(!S){g("Please enter a server URL");return}if(!C){g("Please enter an API token");return}if(!k1(C)){g("Invalid token format. Token should be 64 hex characters (0-9, a-f).");return}const A=dc(S),N={id:crypto.randomUUID(),name:k,url:A,token:C,createdAt:new Date().toISOString()};e(N)};return f.jsx("div",{className:"w-full h-full flex items-center justify-center bg-background dark:bg-gradient-to-br dark:from-muted dark:via-background dark:to-muted p-4",children:f.jsx("div",{className:"w-full max-w-md",children:f.jsxs("div",{className:"bg-card border border-border rounded-xl shadow-2xl overflow-hidden",children:[f.jsxs("div",{className:"px-6 pt-6 pb-4 text-center border-b border-border",children:[f.jsx("h1",{className:"text-2xl font-bold text-foreground",children:"Add your first server"}),f.jsx("p",{className:"text-muted-foreground mt-1",children:"Connect to a Jean2 server to get started"})]}),f.jsxs("form",{onSubmit:b,className:"p-6 space-y-4",children:[f.jsxs("div",{className:"space-y-2",children:[f.jsx("label",{htmlFor:"serverName",className:"text-sm font-medium text-foreground",children:"Server Name"}),f.jsx("input",{id:"serverName",type:"text",value:a,onChange:w=>{l(w.target.value),g(null)},placeholder:"Production",className:"w-full px-3 py-2 bg-background border border-input rounded-lg text-foreground placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:border-transparent transition-colors"})]}),f.jsxs("div",{className:"space-y-2",children:[f.jsx("label",{htmlFor:"serverUrl",className:"text-sm font-medium text-foreground",children:"Server URL"}),f.jsx("input",{id:"serverUrl",type:"text",value:o,onChange:w=>{s(w.target.value),g(null)},placeholder:"localhost:3000",className:"w-full px-3 py-2 bg-background border border-input rounded-lg text-foreground placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:border-transparent transition-colors"})]}),f.jsxs("div",{className:"space-y-2",children:[f.jsx("label",{htmlFor:"token",className:"text-sm font-medium text-foreground",children:"API Token"}),f.jsxs("div",{className:"relative",children:[f.jsx("input",{id:"token",type:p?"text":"password",value:c,onChange:w=>{d(w.target.value),g(null)},placeholder:"Enter your 64-character token",className:"w-full px-3 py-2 pr-10 bg-background border border-input rounded-lg text-foreground font-mono text-sm placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:border-transparent transition-colors"}),f.jsx("button",{type:"button",onClick:()=>h(!p),className:"absolute right-2 top-1/2 -translate-y-1/2 p-1 text-muted-foreground hover:text-foreground transition-colors","aria-label":p?"Hide token":"Show token",children:p?f.jsx("svg",{className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:f.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M13.875 18.825A10.05 10.05 0 0112 19c-4.478 0-8.268-2.943-9.543-7a9.97 9.97 0 011.563-3.029m5.858.908a3 3 0 114.243 4.243M9.878 9.878l4.242 4.242M9.88 9.88l-3.29-3.29m7.532 7.532l3.29 3.29M3 3l3.59 3.59m0 0A9.953 9.953 0 0112 5c4.478 0 8.268 2.943 9.543 7a10.025 10.025 0 01-4.132 5.411m0 0L21 21"})}):f.jsxs("svg",{className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:[f.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M15 12a3 3 0 11-6 0 3 3 0 016 0z"}),f.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M2.458 12C3.732 7.943 7.523 5 12 5c4.478 0 8.268 2.943 9.542 7-1.274 4.057-5.064 7-9.542 7-4.477 0-8.268-2.943-9.542-7z"})]})})]})]}),(y||r)&&f.jsx("div",{className:"px-3 py-2 bg-destructive/10 border border-destructive/20 rounded-lg text-destructive text-sm",children:y||r}),f.jsx("button",{type:"submit",className:"w-full py-2.5 bg-primary text-primary-foreground font-medium rounded-lg hover:bg-primary/90 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 transition-colors",children:"Add Server"})]})]})})})}function d1({onServerSwitch:e,onSelectWorkspace:r}){const[a,l]=v.useState(!1),o=v.useRef(!1),s=cd(),{quickConnections:c,switchServer:d,removeFromQuickConnections:p,isSwitching:h}=Ei(),y=w=>{d(w.serverId)&&(o.current=!0,e==null||e(),w.workspaceId&&r&&r(w.workspaceId))};v.useEffect(()=>{!h&&a&&o.current&&(l(!1),o.current=!1)},[h,a]);const g=(w,k)=>{w.stopPropagation(),p(k)},b=()=>f.jsx(Vm,{children:f.jsx($m,{className:"max-h-[50vh] overflow-y-auto",children:c.length>0?f.jsx(Yo,{heading:"Quick Switch",children:c.map(w=>f.jsxs(gi,{onSelect:()=>y(w),className:"justify-between",children:[f.jsxs("div",{className:"flex items-center gap-2",children:[f.jsx(ul,{className:"size-4 text-muted-foreground"}),f.jsxs("span",{children:[w.serverName,w.workspaceName&&f.jsxs("span",{className:"text-muted-foreground",children:[" / ",w.workspaceName]})]})]}),f.jsx("button",{className:"opacity-0 group-hover:opacity-100 hover:opacity-100 transition-opacity p-1 rounded hover:bg-destructive/10",onClick:k=>g(k,w.id),children:f.jsx(as,{className:"size-3 text-destructive"})})]},w.id))}):f.jsx(qm,{className:"py-6",children:f.jsxs("div",{className:"flex flex-col items-center gap-2 text-muted-foreground",children:[f.jsx(Ip,{className:"size-8"}),f.jsx("p",{className:"text-sm font-medium",children:"No favorites yet"}),f.jsx("p",{className:"text-xs",children:"Star a workspace to add it here"})]})})})});return s?f.jsxs(Ym,{open:a,onOpenChange:l,children:[f.jsx(mz,{asChild:!0,children:f.jsx(Me,{variant:"ghost",size:"icon-sm","aria-label":"Quick switch",children:f.jsx(Ip,{className:"size-4"})})}),f.jsxs(Xm,{side:"bottom",className:"max-h-[80vh]",children:[f.jsx(Km,{children:f.jsx(Qm,{children:"Quick Switch"})}),f.jsx("div",{className:"mt-4",children:b()})]})]}):f.jsxs(sd,{open:a,onOpenChange:l,children:[f.jsx(Gm,{asChild:!0,children:f.jsx(Me,{variant:"ghost",size:"icon-sm","aria-label":"Quick switch",children:f.jsx(Ip,{className:"size-4"})})}),f.jsx(ud,{className:"w-[300px] p-0",align:"start",children:b()})]})}function lP({open:e,onOpenChange:r,editServer:a}){const{addServer:l,editServer:o}=Ei(),[s,c]=v.useState(""),[d,p]=v.useState(""),[h,y]=v.useState(""),[g,b]=v.useState(!1),[w,k]=v.useState(null),S=a!=null;v.useEffect(()=>{a?(c(a.name),p(a.url),y(a.token)):(c(""),p(""),y("")),k(null),b(!1)},[a,e]);const C=A=>{A.preventDefault(),k(null);const N=s.trim(),j=d.trim(),O=h.trim();if(!N){k("Name is required");return}if(!j){k("Server URL is required");return}if(!O){k("API token is required");return}if(!k1(O)){k("Token must be 64 hexadecimal characters");return}const D=dc(j);S?o(a.id,{name:N,url:D,token:O}):l(N,D,O),r(!1)};return f.jsx(xs,{open:e,onOpenChange:r,children:f.jsxs(bs,{className:"sm:max-w-[425px]",children:[f.jsxs(vs,{children:[f.jsx(ws,{children:S?"Edit Server":"Add Server"}),f.jsx(id,{children:S?"Update server details":"Enter your server details"})]}),f.jsxs("form",{onSubmit:C,children:[f.jsxs("div",{className:"grid gap-4 py-4",children:[f.jsxs("div",{className:"grid gap-2",children:[f.jsx(Ca,{htmlFor:"server-name",children:"Name"}),f.jsx(lc,{id:"server-name",value:s,onChange:A=>c(A.target.value),placeholder:"My Server"})]}),f.jsxs("div",{className:"grid gap-2",children:[f.jsx(Ca,{htmlFor:"server-url",children:"Server URL"}),f.jsx(lc,{id:"server-url",value:d,onChange:A=>p(A.target.value),placeholder:"localhost:3000"})]}),f.jsxs("div",{className:"grid gap-2",children:[f.jsx(Ca,{htmlFor:"server-token",children:"API Token"}),f.jsxs("div",{className:"relative",children:[f.jsx(lc,{id:"server-token",type:g?"text":"password",value:h,onChange:A=>y(A.target.value),placeholder:"64-character hex string",className:"pr-10"}),f.jsx("button",{type:"button",onClick:()=>b(!g),className:"absolute right-2 top-1/2 -translate-y-1/2 p-1 hover:bg-transparent",children:g?f.jsx(wN,{className:"size-4 text-muted-foreground"}):f.jsx(kN,{className:"size-4 text-muted-foreground"})})]})]}),w&&f.jsx("p",{className:"text-sm text-destructive",children:w})]}),f.jsxs(Um,{children:[f.jsx(Me,{type:"button",variant:"outline",onClick:()=>r(!1),children:"Cancel"}),f.jsx(Me,{type:"submit",children:S?"Save":"Add"})]})]})]})})}const iP=(e,r)=>e&&r?`ws://${r}/ws?token=${e}`:null,wh=e=>e?`http://${e}/api`:null;function oP(){var wr,wt,Pi;const{servers:e,activeServer:r,addServer:a,removeServer:l,isSwitching:o,clearSwitchingState:s}=Ei(),[c,d]=v.useState([]),[p,h]=v.useState([]),[y,g]=v.useState(null),[b,w]=v.useState({}),[k,S]=v.useState({}),[C,A]=v.useState(null),N=v.useRef(null),[j,O]=v.useState(!1),[D,M]=v.useState(null),[U,F]=v.useState({promptTokens:0,completionTokens:0,totalTokens:0}),[Q,I]=v.useState("gpt-4o"),[Y,V]=v.useState([]),[ue,W]=v.useState("gpt-4o"),[J,B]=v.useState([]),[G,te]=v.useState(null),[ce,R]=v.useState(!1),[z,L]=v.useState(!1),[_,re]=v.useState(!1),[ne,ie]=v.useState([]),[le,be]=v.useState([]),[he,Ne]=v.useState({}),[De,ze]=v.useState(null),[gt,nt]=v.useState(!1),[Ot,Jt]=v.useState(null),[Gt,Rn]=v.useState(!1),[Mn,an]=v.useState(0),[On,br]=v.useState(0),[Oi,Dt]=v.useState(0),Di=1e4,oe=3e4,xe=1e3,Te=v.useRef(null),Ie=v.useRef(null),[rt,Pt]=v.useState(!1),Je=(wr=r==null?void 0:r.token)!=null?wr:null,He=(wt=r==null?void 0:r.url)!=null?wt:null;v.useEffect(()=>{N.current=C},[C]);const yt=v.useRef(null),zt=v.useRef(!1),lt=v.useCallback($=>{a($.name,$.url,$.token)},[a]),Yt=v.useCallback(()=>{r&&l(r.id),N.current&&N.current.close(),A(null),O(!1),Rn(!1),an(0),br(0)},[r,l]),mn=v.useCallback(()=>{an($=>$+1),Rn(!1),br(0)},[]),zi=v.useCallback(()=>{N.current&&N.current.close(),A(null),O(!1),Rn(!1),an(0),br(0),d([]),h([]),g(null),w({}),S({}),M(null),F({promptTokens:0,completionTokens:0,totalTokens:0}),I("gpt-4o"),V([]),B([]),te(null),ie([]),be([]),Ne({}),Dt($=>$+1)},[]),Dn=v.useCallback(async($,Ae={})=>{if(!Je)throw new Error("No API token available");const pe=new Headers(Ae.headers||{});pe.set("Authorization",`Bearer ${Je}`);const me=await fetch($,{...Ae,signal:Ae.signal,headers:pe});if(me.status===401)throw ze("Authentication failed. Your token may have been regenerated."),Yt(),new Error("Unauthorized");return me},[Je,Yt]),Sl=v.useCallback($=>{const Ae=b[$]||[],pe=k[$]||{};return Ae.map(me=>({message:me,parts:(pe[me.id]||[]).sort((We,Ft)=>We.createdAt-Ft.createdAt)}))},[b,k]);v.useEffect(()=>{if(!Je||!He)return;const $=iP(Je,He);if(!$)return;const Ae=new WebSocket($);return Ae.onopen=()=>{O(!0),ze(null),an(0),Rn(!1)},Ae.onclose=pe=>{O(!1),(pe.code===1008||pe.code===401)&&(ze("Authentication failed. Please check your token."),Yt())},Ae.onerror=pe=>{console.error("WebSocket error:",pe)},Ae.onmessage=pe=>{var We;const me=JSON.parse(pe.data);(We=yt.current)==null||We.call(yt,me)},A(Ae),()=>Ae.close()},[Je,He,Yt,Oi]),v.useEffect(()=>{if(Je&&He&&!j&&!Gt){const $=setTimeout(()=>{j||Rn(!0)},Di);return()=>clearTimeout($)}},[Je,He,j,Gt]),v.useEffect(()=>{if(Gt&&!j&&Je&&He){const $=Math.min(xe*Math.pow(2,Mn),oe);let Ae=Math.floor($/1e3);br(Ae);const pe=setInterval(()=>{Ae-=1,br(Math.max(0,Ae))},1e3),me=setTimeout(()=>{an(We=>We+1),Dt(We=>We+1)},$);return()=>{clearInterval(pe),clearTimeout(me)}}},[Gt,j,Je,He,Mn]),v.useEffect(()=>{var pe;if(!Je||!He)return;(pe=Te.current)==null||pe.abort(),Te.current=new AbortController;const $=Te.current.signal,Ae=wh(He);if(Ae)return Pt(!0),Promise.all([Dn(`${Ae}/sessions`,{signal:$}).then(me=>me.json()),Dn(`${Ae}/preconfigs`,{signal:$}).then(me=>me.json()),Dn(`${Ae}/models`,{signal:$}).then(me=>me.json()),Dn(`${Ae}/workspaces`,{signal:$}).then(me=>me.json())]).then(([me,We,Ft,Sr])=>{d(me.sessions||[]),h(We.preconfigs||[]),V(Ft.models||[]),W(Ft.defaultModel||"gpt-4o");const Kt=Sr.workspaces||[];if(B(Kt),Ie.current){const zn=Kt.find(gn=>gn.id===Ie.current);zn&&te(zn),Ie.current=null}else{const zn=localStorage.getItem("activeWorkspaceId"),gn=Kt.find(ln=>ln.id===zn);te(gn||Kt[0])}s(),Pt(!1)}).catch(me=>{var We;if(me.name==="AbortError"){console.log("Fetch aborted due to server switch");return}console.error("Failed to load server data:",me),Pt(!1),(We=me.message)!=null&&We.includes("Unauthorized")||ze("Failed to connect to server")}),()=>{var me;(me=Te.current)==null||me.abort()}},[Je,He,Dn,s]),v.useEffect(()=>{G&&localStorage.setItem("activeWorkspaceId",G.id)},[G]);const Ia=async($,Ae,pe)=>{const me=wh(He);if(!me)return;const Ft=await(await Dn(`${me}/workspaces`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:$,path:Ae,isVirtual:pe})})).json();return B(Sr=>[...Sr,Ft.workspace]),Ft.workspace},vr=$=>{te($),g(null)},Ba=$=>{Ie.current=$},Pa=async $=>{const Ae=wh(He);Ae&&(await Dn(`${Ae}/workspaces/${$}`,{method:"DELETE"}),B(pe=>pe.filter(me=>me.id!==$)),(G==null?void 0:G.id)===$&&te(J[0]||null))},bd=async()=>{const $=`Workspace ${J.length+1}`,Ae=`~/.jean2/workspaces/${crypto.randomUUID()}`;await Ia($,Ae,!0)},As=async $=>{const Ae=$.split("/").pop()||$.split("\\").pop()||"Workspace";await Ia(Ae,$,!1)},kl=v.useCallback($=>{var Ae;switch($.type){case"session.created":d(pe=>[$.session,...pe]),zt.current&&(g($.session),w(pe=>({...pe,[$.session.id]:[]})),S(pe=>({...pe,[$.session.id]:{}})),F({promptTokens:0,completionTokens:0,totalTokens:0}),I(ue),zt.current=!1);break;case"session.resumed":g($.session),$.isRunning&&M($.session.id),$.messages&&(w(pe=>({...pe,[$.session.id]:$.messages.map(me=>me.message)})),S(pe=>{const me={...pe};me[$.session.id]={};for(const We of $.messages)me[$.session.id][We.message.id]=We.parts;return me})),F((Ae=$.usage)!=null?Ae:{promptTokens:0,completionTokens:0,totalTokens:0}),I($.session.selectedModel||ue);break;case"message.created":w(pe=>({...pe,[$.message.sessionId]:[...pe[$.message.sessionId]||[],$.message]})),S(pe=>({...pe,[$.message.sessionId]:{...pe[$.message.sessionId],[$.message.id]:[]}})),"status"in $.message&&$.message.status==="streaming"&&M($.message.sessionId);break;case"message.updated":w(pe=>({...pe,[$.message.sessionId]:(pe[$.message.sessionId]||[]).map(me=>me.id===$.message.id?$.message:me)})),"status"in $.message&&$.message.status!=="streaming"&&M(pe=>pe===$.message.sessionId?null:pe);break;case"part.created":S(pe=>{const me=pe[$.sessionId]||{},We=me[$.part.messageId]||[];return{...pe,[$.sessionId]:{...me,[$.part.messageId]:[...We,$.part]}}});break;case"part.updated":S(pe=>{const me=pe[$.sessionId]||{},We=me[$.part.messageId]||[];return{...pe,[$.sessionId]:{...me,[$.part.messageId]:We.map(Ft=>Ft.id===$.part.id?$.part:Ft)}}});break;case"part.append":M($.sessionId),S(pe=>{const me=pe[$.sessionId]||{};for(const We of Object.keys(me)){const Ft=me[We],Sr=Ft.findIndex(Kt=>Kt.id===$.partId);if(Sr!==-1){const Kt=Ft[Sr];if(Kt.type==="text"||Kt.type==="reasoning"){const zn=[...Ft];return zn[Sr]={...Kt,text:Kt.text+$.delta},{...pe,[$.sessionId]:{...me,[We]:zn}}}}}return pe});break;case"chat.usage":if($.sessionId!==(y==null?void 0:y.id))return;F({promptTokens:$.usage.promptTokens,completionTokens:$.usage.completionTokens,totalTokens:$.usage.totalTokens}),I($.model);break;case"error":console.error("Server error:",$.code,$.message);break;case"session.closed":d(pe=>pe.map(me=>me.id===$.sessionId?{...me,status:"closed"}:me)),w(pe=>{const me={...pe};return delete me[$.sessionId],me}),S(pe=>{const me={...pe};return delete me[$.sessionId],me}),(y==null?void 0:y.id)===$.sessionId&&g(null);break;case"session.reopened":d(pe=>pe.map(me=>me.id===$.session.id?$.session:me)),(y==null?void 0:y.id)===$.session.id&&g($.session);break;case"session.deleted":d(pe=>pe.filter(me=>me.id!==$.sessionId)),w(pe=>{const me={...pe};return delete me[$.sessionId],me}),S(pe=>{const me={...pe};return delete me[$.sessionId],me}),(y==null?void 0:y.id)===$.sessionId&&g(null);break;case"session.updated":d(pe=>pe.map(me=>me.id===$.session.id?$.session:me)),(y==null?void 0:y.id)===$.session.id&&g($.session);break;case"session.renamed":d(pe=>pe.map(me=>me.id===$.session.id?$.session:me)),(y==null?void 0:y.id)===$.session.id&&g($.session);break;case"permission.list":ie($.permissions);break;case"permission.revoked":ie(pe=>pe.map(me=>me.id===$.permissionId?{...me,revokedAt:new Date().toISOString()}:me));break;case"permission.all_revoked":ie(pe=>{const me=new Date().toISOString();return pe.map(We=>({...We,revokedAt:me}))});break;case"permission.request":{const pe={toolCallId:$.toolCallId,toolName:$.toolName,args:$.args,permissionType:$.permissionType,permissionKey:$.permissionKey,message:$.message,details:$.details,dangerous:$.dangerous,childSessionId:$.childSessionId,subagentName:$.subagentName};be(me=>[...me,pe]);break}case"permission.granted":be(pe=>pe.filter(me=>me.toolCallId!==$.toolCallId));break;case"session.interrupted":D===$.sessionId&&M(null),$.result.cascadedTo.length>0&&console.log(`Session ${$.sessionId} interrupted. Cascaded to:`,$.result.cascadedTo);break;case"queue.list":Ne(pe=>({...pe,[$.sessionId]:$.messages}));break;case"queue.added":Ne(pe=>({...pe,[$.sessionId]:[...pe[$.sessionId]||[],$.message]}));break;case"queue.removed":Ne(pe=>({...pe,[$.sessionId]:(pe[$.sessionId]||[]).filter(me=>me.id!==$.queueId)}));break;case"queue.sending":Ne(pe=>({...pe,[$.sessionId]:(pe[$.sessionId]||[]).filter(me=>me.id!==$.queueId)}));break}},[y,ue,D]);v.useEffect(()=>{yt.current=kl},[kl]),v.useEffect(()=>{const $=async Ae=>{const pe=Ae.target;if(!(pe.tagName==="INPUT"||pe.tagName==="TEXTAREA"||pe.isContentEditable)&&(Ae.metaKey||Ae.ctrlKey)&&Ae.key==="n"){Ae.preventDefault();try{await UA("create_new_window")}catch(We){console.error("Failed to create new window:",We)}}};return window.addEventListener("keydown",$),()=>window.removeEventListener("keydown",$)},[]);const Ye=v.useCallback(($,Ae)=>{C&&C.readyState===WebSocket.OPEN&&C.send(JSON.stringify({type:$,...Ae}))},[C]),vd=v.useCallback(($,Ae)=>{zt.current=!0,Ye("session.create",{preconfigId:$,title:Ae,workspaceId:G==null?void 0:G.id})},[Ye,G]),Fa=v.useCallback($=>{be([]),M(null),Ye("session.resume",{sessionId:$})},[Ye]),Ns=v.useCallback($=>{Ye("session.close",{sessionId:$})},[Ye]),js=v.useCallback($=>{Ye("session.reopen",{sessionId:$})},[Ye]),Li=v.useCallback($=>{Ye("session.delete",{sessionId:$})},[Ye]),Ii=v.useCallback($=>{y&&Ye("session.update",{sessionId:y.id,preconfigId:$})},[y,Ye]),Ts=v.useCallback(($,Ae)=>{y&&Ye("session.update_model",{sessionId:y.id,modelId:$,providerId:Ae})},[y,Ye]),_s=v.useCallback(($,Ae)=>{Ye("session.rename",{sessionId:$,title:Ae})},[Ye]),lr=v.useCallback(()=>{y!=null&&y.parentId&&Fa(y.parentId)},[y,Fa]),Et=v.useCallback(($,Ae)=>{Ye("queue.add",{sessionId:$,content:Ae})},[Ye]),Xt=v.useCallback($=>{Ye("queue.remove",{queueId:$})},[Ye]),Qr=v.useCallback($=>{y&&(D===y.id?Et(y.id,$):Ye("chat.message",{sessionId:y.id,content:$}))},[y,D,Ye,Et]),Bi=v.useCallback(($,Ae,pe)=>{be(me=>me.filter(We=>We.toolCallId!==$)),Ye("permission.response",{toolCallId:$,allowed:Ae,alwaysAllow:pe})},[Ye]),wd=v.useCallback(()=>{y&&Ye("session.interrupt",{sessionId:y.id})},[y,Ye]),Sd=v.useCallback(()=>{G&&Ye("permission.list",{workspaceId:G.id})},[G,Ye]),Rs=c.filter($=>$.workspaceId===(G==null?void 0:G.id)),Ua=y?Sl(y.id):[],El=p.filter($=>$.mode!=="subagent"),Zr=!(y!=null&&y.parentId),en=!!r,Ha=()=>e.length===0?f.jsx(c1,{onServerAdded:lt,error:De||void 0}):en?o?f.jsx("div",{className:"flex flex-col w-full h-full items-center justify-center bg-background gap-4",children:f.jsx(u1,{message:`Connecting to ${(r==null?void 0:r.name)||"server"}...`})}):!j&&c.length===0?Gt?f.jsx("div",{className:"flex w-full h-full items-center justify-center bg-background",children:f.jsx(aP,{serverUrl:He,authError:De,retryCount:Mn,nextRetryIn:On,onRetry:mn,onLogout:Yt})}):f.jsxs("div",{className:"flex flex-col w-full h-full items-center justify-center bg-background gap-4",children:[f.jsx(u1,{}),f.jsx(Me,{variant:"ghost",size:"sm",onClick:Yt,className:"text-muted-foreground",children:"Change Server"})]}):f.jsx(f.Fragment,{children:y?f.jsx(KB,{session:y,messagesWithParts:Ua,queuedMessages:he[y.id]||[],preconfigs:Zr?El:p,models:Y,defaultModel:ue,onSendMessage:Qr,onRemoveFromQueue:Xt,onChangePreconfig:Ii,onChangeModel:Ts,pendingPermissions:le,onPermissionResponse:Bi,onRename:_s,usage:U,modelName:Q,onNavigateToSubagent:Fa,onNavigateBack:lr,isStreaming:D===y.id,onInterrupt:wd,serverUrl:He!=null?He:void 0,apiToken:Je!=null?Je:void 0}):f.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center text-center text-muted-foreground px-6",children:[f.jsx("h2",{className:"mb-2",children:"Select or create a session"}),f.jsx("p",{children:"Choose a session from the sidebar or create a new one to start chatting."})]})}):f.jsx(c1,{onServerAdded:lt,error:De||void 0});return f.jsxs(Cz,{defaultOpen:!0,children:[en&&f.jsx(Iz,{sessions:Rs,currentSession:y,currentSessionId:(Pi=y==null?void 0:y.id)!=null?Pi:null,streamingSessionId:D,connected:j,workspaces:J,activeWorkspace:G,onCreateSession:()=>{var $;return vd(($=El[0])==null?void 0:$.id)},onResumeSession:Fa,onCloseSession:Ns,onReopenSession:js,onDeleteSession:Li,onSelectWorkspace:vr,onCreateVirtualWorkspace:bd,onCreatePhysicalWorkspace:As,onDeleteWorkspace:Pa,onOpenSettings:()=>R(!0),onOpenMCP:()=>re(!0),onOpenAddServer:()=>nt(!0),onServerSwitch:zi}),f.jsxs("main",{className:"flex-1 flex flex-col overflow-hidden",style:{paddingTop:"env(safe-area-inset-top, 0)",paddingBottom:"env(safe-area-inset-bottom, 0)"},children:[f.jsxs("header",{className:"md:hidden flex items-center justify-between p-3 border-b border-border bg-background sticky top-0 z-10",children:[f.jsxs("div",{className:"flex items-center gap-2",children:[en&&f.jsx(l0,{}),f.jsx("span",{className:"font-semibold",children:"Jean2"})]}),f.jsxs("div",{className:"flex items-center gap-1",children:[f.jsx(d1,{onServerSwitch:zi,onSelectWorkspace:Ba}),en&&G&&f.jsx(Me,{variant:"ghost",size:"icon-sm",onClick:()=>L(!z),title:z?"Hide Files":"Show Files",children:f.jsx(kh,{className:"w-4 h-4"})})]})]}),f.jsxs("header",{className:"hidden md:flex items-center justify-between p-3 border-b border-border",children:[f.jsxs("div",{className:"flex items-center gap-2",children:[en&&f.jsx(l0,{}),f.jsx("span",{className:"font-semibold",children:"Jean2"})]}),f.jsxs("div",{className:"flex items-center gap-2",children:[en&&f.jsx(d1,{onServerSwitch:zi,onSelectWorkspace:Ba}),en&&G&&f.jsx(Me,{variant:"ghost",size:"icon-sm",onClick:()=>L(!z),title:z?"Hide Files":"Show Files",children:f.jsx(kh,{className:"w-4 h-4"})})]})]}),Ha()]}),en&&f.jsxs(f.Fragment,{children:[f.jsx(Fz,{workspaceId:G==null?void 0:G.id,serverUrl:He!=null?He:void 0,apiToken:Je!=null?Je:void 0,isOpen:z,onClose:()=>L(!1)}),f.jsx(tP,{open:ce,onOpenChange:R,permissions:ne,onRefreshPermissions:Sd,onRevokePermission:$=>{Ye("permission.revoke",{permissionId:$})},onRevokeAllPermissions:()=>{Ye("permission.revoke_all",{workspaceId:G==null?void 0:G.id})},apiToken:Je,onLogout:Yt}),f.jsx(rP,{open:_,onOpenChange:re,workspaceId:G==null?void 0:G.id,workspacePath:G==null?void 0:G.path,serverUrl:He!=null?He:void 0,apiToken:Je!=null?Je:void 0})]}),f.jsx(lP,{open:gt,onOpenChange:$=>{nt($),$||Jt(null)},editServer:Ot})]})}function sP(){return f.jsx(kj,{children:f.jsx(oP,{})})}IA.createRoot(document.getElementById("root")).render(f.jsx(v.StrictMode,{children:f.jsx(PA,{defaultTheme:"dark",storageKey:"jean2-theme",children:f.jsx(sP,{})})}));