@mrpatronz/nexusflow 2.4.0 → 2.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/commands/isolate.d.ts +12 -0
- package/dist/commands/isolate.d.ts.map +1 -0
- package/dist/commands/isolate.js +78 -0
- package/dist/commands/isolate.js.map +1 -0
- package/dist/commands/isolate.test.d.ts +2 -0
- package/dist/commands/isolate.test.d.ts.map +1 -0
- package/dist/commands/isolate.test.js +59 -0
- package/dist/commands/isolate.test.js.map +1 -0
- package/dist/commands/open.d.ts.map +1 -1
- package/dist/commands/open.js +66 -21
- package/dist/commands/open.js.map +1 -1
- package/dist/commands/ui.d.ts +1 -1
- package/dist/commands/ui.d.ts.map +1 -1
- package/dist/commands/ui.js +26 -6
- package/dist/commands/ui.js.map +1 -1
- package/dist/core/config-schema.d.ts +17 -0
- package/dist/core/config-schema.d.ts.map +1 -0
- package/dist/core/config-schema.js +24 -0
- package/dist/core/config-schema.js.map +1 -0
- package/dist/core/doctor.d.ts.map +1 -1
- package/dist/core/doctor.js +19 -5
- package/dist/core/doctor.js.map +1 -1
- package/dist/core/isolate.d.ts +31 -0
- package/dist/core/isolate.d.ts.map +1 -0
- package/dist/core/isolate.js +175 -0
- package/dist/core/isolate.js.map +1 -0
- package/dist/core/isolate.test.d.ts +2 -0
- package/dist/core/isolate.test.d.ts.map +1 -0
- package/dist/core/isolate.test.js +290 -0
- package/dist/core/isolate.test.js.map +1 -0
- package/dist/core/refresh.d.ts.map +1 -1
- package/dist/core/refresh.js +35 -1
- package/dist/core/refresh.js.map +1 -1
- package/dist/core/sync.d.ts.map +1 -1
- package/dist/core/sync.js +21 -7
- package/dist/core/sync.js.map +1 -1
- package/dist/core/workspace.d.ts +6 -0
- package/dist/core/workspace.d.ts.map +1 -1
- package/dist/core/workspace.js +61 -17
- package/dist/core/workspace.js.map +1 -1
- package/dist/core/worktree.d.ts.map +1 -1
- package/dist/core/worktree.js +7 -0
- package/dist/core/worktree.js.map +1 -1
- package/dist/desktop-server.js +2 -1
- package/dist/desktop-server.js.map +1 -1
- package/dist/generators/base.d.ts.map +1 -1
- package/dist/generators/base.js +13 -5
- package/dist/generators/base.js.map +1 -1
- package/dist/generators/base.test.js +1 -1
- package/dist/generators/base.test.js.map +1 -1
- package/dist/gui/antigravity-logo.png +0 -0
- package/dist/gui/assets/AgentsPage-BNHR9qux.js +3 -0
- package/dist/gui/assets/CSPContext-BG7no5S_.js +1 -0
- package/dist/gui/assets/DashboardPage-BScH3Cxp.js +1 -0
- package/dist/gui/assets/{GettingStartedPage-DQ5kCj0q.js → GettingStartedPage-AWlI-176.js} +1 -1
- package/dist/gui/assets/ProjectsPage-Bojj7gxI.js +1 -0
- package/dist/gui/assets/ScaffoldRepoInline-DJMbeHVM.js +1 -0
- package/dist/gui/assets/SettingsPage-BAdXO8X0.js +1 -0
- package/dist/gui/assets/SkillsPage-CF6Db1FA.js +6 -0
- package/dist/gui/assets/StartWorkPage-BQid3uIw.js +1 -0
- package/dist/gui/assets/{StrategiesPage-CkpJI4Q3.js → StrategiesPage-nGbR9TAc.js} +2 -2
- package/dist/gui/assets/WorkspacesPage-7XRtVJNF.js +2 -0
- package/dist/gui/assets/{alert-dialog-Cjwogh-W.js → alert-dialog-67uzXJi4.js} +1 -1
- package/dist/gui/assets/antigravity-logo-DRKQga2U.png +0 -0
- package/dist/gui/assets/{badge-BnkhqVEF.js → badge-CAohJGj6.js} +1 -1
- package/dist/gui/assets/{bot-wH0FKlic.js → bot-C2HWrAft.js} +1 -1
- package/dist/gui/assets/{button-cPldH5S4.js → button-BDDZnIHx.js} +1 -1
- package/dist/gui/assets/card-BKXzd_5L.js +1 -0
- package/dist/gui/assets/chevron-down-qTL8HPug.js +1 -0
- package/dist/gui/assets/{circle-plus-C0PNc7h4.js → circle-plus-lmU1yNJd.js} +1 -1
- package/dist/gui/assets/code-xml-jFAa3-TT.js +1 -0
- package/dist/gui/assets/{cpu-CPUNnHRM.js → cpu-Cdwd84Jz.js} +1 -1
- package/dist/gui/assets/{empty-DWyDwDYB.js → empty-BdlgbifD.js} +1 -1
- package/dist/gui/assets/{git-branch-Dw55pQWa.js → git-branch-Cfj9D8yW.js} +1 -1
- package/dist/gui/assets/index-CZoZQkeC.css +2 -0
- package/dist/gui/assets/index-V1dDX1O_.js +50 -0
- package/dist/gui/assets/isElementDisabled-D_fu2zfc.js +1 -0
- package/dist/gui/assets/{label-JFgMNsTn.js → label-CG5exjag.js} +1 -1
- package/dist/gui/assets/{terminal-D1awFRPr.js → square-DlIYnlSq.js} +1 -1
- package/dist/gui/assets/store-D7ixdVck.js +3 -0
- package/dist/gui/assets/styles-CVwNuFCx.js +1 -0
- package/dist/gui/assets/textarea-BNRuIXNs.js +1 -0
- package/dist/gui/assets/{trash-2-Da8F2gKd.js → trash-2-CtR35_eF.js} +1 -1
- package/dist/gui/assets/useAriaLabelledBy-DfRdwH8a.js +1 -0
- package/dist/gui/assets/useValueChanged-CStSGSsD.js +1 -0
- package/dist/gui/assets/vsc-Di05BTNr.js +1 -0
- package/dist/gui/assets/zap-CWG_Lvki.js +1 -0
- package/dist/gui/index.html +9 -7
- package/dist/index.js +22 -0
- package/dist/index.js.map +1 -1
- package/dist/mcp/tools.d.ts.map +1 -1
- package/dist/mcp/tools.js +47 -1
- package/dist/mcp/tools.js.map +1 -1
- package/dist/mcp/tools.test.d.ts +2 -0
- package/dist/mcp/tools.test.d.ts.map +1 -0
- package/dist/mcp/tools.test.js +70 -0
- package/dist/mcp/tools.test.js.map +1 -0
- package/dist/orchestration/orchestrator.js +2 -2
- package/dist/orchestration/orchestrator.js.map +1 -1
- package/dist/orchestration/orchestrator.test.js +1 -1
- package/dist/orchestration/orchestrator.test.js.map +1 -1
- package/dist/orchestration/runner.d.ts +5 -1
- package/dist/orchestration/runner.d.ts.map +1 -1
- package/dist/orchestration/runner.js +14 -4
- package/dist/orchestration/runner.js.map +1 -1
- package/dist/orchestration/runner.test.js +22 -16
- package/dist/orchestration/runner.test.js.map +1 -1
- package/dist/server.d.ts.map +1 -1
- package/dist/server.js +189 -27
- package/dist/server.js.map +1 -1
- package/dist/server.test.js +220 -7
- package/dist/server.test.js.map +1 -1
- package/dist/types.d.ts +17 -1
- package/dist/types.d.ts.map +1 -1
- package/dist/utils/detect-editors.d.ts +1 -7
- package/dist/utils/detect-editors.d.ts.map +1 -1
- package/dist/utils/detect-editors.js +12 -10
- package/dist/utils/detect-editors.js.map +1 -1
- package/dist/utils/detect-editors.test.js +58 -25
- package/dist/utils/detect-editors.test.js.map +1 -1
- package/dist/utils/feature.d.ts +10 -1
- package/dist/utils/feature.d.ts.map +1 -1
- package/dist/utils/feature.js +36 -4
- package/dist/utils/feature.js.map +1 -1
- package/dist/utils/open-editor.d.ts +1 -1
- package/dist/utils/open-editor.d.ts.map +1 -1
- package/dist/utils/open-editor.js +11 -2
- package/dist/utils/open-editor.js.map +1 -1
- package/dist/utils/session-finder.d.ts +11 -0
- package/dist/utils/session-finder.d.ts.map +1 -1
- package/dist/utils/session-finder.js +121 -48
- package/dist/utils/session-finder.js.map +1 -1
- package/dist/utils/session-finder.test.js +105 -1
- package/dist/utils/session-finder.test.js.map +1 -1
- package/dist/utils/terminal-launch.d.ts +39 -0
- package/dist/utils/terminal-launch.d.ts.map +1 -0
- package/dist/utils/terminal-launch.js +205 -0
- package/dist/utils/terminal-launch.js.map +1 -0
- package/dist/utils/terminal-launch.test.d.ts +2 -0
- package/dist/utils/terminal-launch.test.d.ts.map +1 -0
- package/dist/utils/terminal-launch.test.js +117 -0
- package/dist/utils/terminal-launch.test.js.map +1 -0
- package/dist/utils/workspace-launch.d.ts.map +1 -1
- package/dist/utils/workspace-launch.js +3 -1
- package/dist/utils/workspace-launch.js.map +1 -1
- package/package.json +5 -3
- package/dist/gui/assets/AgentsPage-B_3Vqn2y.js +0 -3
- package/dist/gui/assets/DashboardPage-W7KE2gn1.js +0 -1
- package/dist/gui/assets/ProjectsPage-CrZhKj85.js +0 -1
- package/dist/gui/assets/ScaffoldRepoInline-BSpQbVe7.js +0 -1
- package/dist/gui/assets/Separator-Chx6O62Y.js +0 -1
- package/dist/gui/assets/SettingsPage-Zvq-P6Hj.js +0 -1
- package/dist/gui/assets/SkillsPage-DR-Y5ZM1.js +0 -6
- package/dist/gui/assets/StartWorkPage-DO6t_zFb.js +0 -1
- package/dist/gui/assets/WorkspaceLauncher-CDtnv1IK.js +0 -1
- package/dist/gui/assets/WorkspacesPage-B9QOLnq_.js +0 -6
- package/dist/gui/assets/card-82INhRRE.js +0 -1
- package/dist/gui/assets/chevron-down-DDmhvRLr.js +0 -1
- package/dist/gui/assets/index-ofoYKpCG.js +0 -52
- package/dist/gui/assets/index-w-iQhEQv.css +0 -2
- package/dist/gui/assets/search-ChVovkOL.js +0 -1
- package/dist/gui/assets/skeleton-CCPbfn1L.js +0 -1
- package/dist/gui/assets/spinner-BCEaGbib.js +0 -1
- package/dist/gui/assets/textarea-D3-elOAa.js +0 -1
- package/dist/gui/assets/useAriaLabelledBy-DmwmZIqb.js +0 -1
- package/dist/gui/assets/useCompositeListItem-CZnlZ-eF.js +0 -1
- package/dist/gui/assets/useValueChanged-BfI2s7NX.js +0 -1
- package/dist/gui/assets/zap-DhYfYRlq.js +0 -1
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/DashboardPage-BScH3Cxp.js","assets/button-BDDZnIHx.js","assets/code-xml-jFAa3-TT.js","assets/git-branch-Cfj9D8yW.js","assets/card-BKXzd_5L.js","assets/empty-BdlgbifD.js","assets/ProjectsPage-Bojj7gxI.js","assets/CSPContext-BG7no5S_.js","assets/ScaffoldRepoInline-DJMbeHVM.js","assets/store-D7ixdVck.js","assets/useValueChanged-CStSGSsD.js","assets/useAriaLabelledBy-DfRdwH8a.js","assets/alert-dialog-67uzXJi4.js","assets/trash-2-CtR35_eF.js","assets/badge-CAohJGj6.js","assets/SettingsPage-BAdXO8X0.js","assets/label-CG5exjag.js","assets/SkillsPage-CF6Db1FA.js","assets/chevron-down-qTL8HPug.js","assets/square-DlIYnlSq.js","assets/cpu-Cdwd84Jz.js","assets/zap-CWG_Lvki.js","assets/textarea-BNRuIXNs.js","assets/AgentsPage-BNHR9qux.js","assets/bot-C2HWrAft.js","assets/StartWorkPage-BQid3uIw.js","assets/vsc-Di05BTNr.js","assets/StrategiesPage-nGbR9TAc.js","assets/circle-plus-lmU1yNJd.js","assets/WorkspacesPage-7XRtVJNF.js","assets/isElementDisabled-D_fu2zfc.js","assets/GettingStartedPage-AWlI-176.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{_ as e,b as t,c as n,d as r,f as i,g as a,h as o,i as s,m as c,n as l,o as u,p as d,s as f,t as p,v as m,y as h}from"./button-BDDZnIHx.js";import{$ as g,$t as _,A as v,An as y,At as b,B as x,Cn as S,Ct as C,Dt as w,Et as T,F as E,Ft as D,G as O,Gn as k,H as A,Hn as j,Ht as M,I as N,In as P,It as F,J as I,Jn as L,Jt as ee,K as te,Kn as R,Kt as z,L as B,Lt as V,M as H,N as ne,Nn as re,Nt as U,O as ie,On as ae,Ot as oe,P as se,Pn as ce,Pt as le,Q as ue,Qn as de,Qt as fe,R as pe,Sn as me,St as he,Tt as ge,U as _e,Un as ve,Ut as ye,Vn as be,W,X as xe,Xt as Se,Y as Ce,Yn as we,Yt as Te,Z as Ee,Zn as De,Zt as Oe,a as ke,an as Ae,c as je,cn as Me,ct as Ne,d as Pe,dt as Fe,en as Ie,et as Le,f as Re,ft as ze,ht as Be,i as Ve,it as He,j as Ue,jt as We,k as Ge,kn as Ke,kt as qe,l as Je,ln as Ye,mt as Xe,n as Ze,nt as Qe,o as $e,on as et,p as tt,pt as nt,qn as rt,qt as it,rn as at,rt as ot,s as st,st as ct,t as lt,tn as ut,tt as dt,u as ft,un as pt,ut as mt,vn as ht,wt as gt,xn as _t,y as vt,yn as yt,z as bt,zn as xt}from"./CSPContext-BG7no5S_.js";import{t as St}from"./chevron-down-qTL8HPug.js";import{a as Ct,c as wt,d as Tt,h as Et,i as Dt,l as Ot,m as kt,n as At,o as jt,p as Mt,r as Nt,s as Pt,t as Ft,u as It}from"./store-D7ixdVck.js";import{_ as Lt,b as Rt,c as zt,d as Bt,f as Vt,g as Ht,h as Ut,i as Wt,l as Gt,m as Kt,n as qt,o as Jt,p as Yt,r as Xt,s as Zt,t as Qt,u as $t,v as en,x as tn}from"./isElementDisabled-D_fu2zfc.js";import{t as nn}from"./useValueChanged-CStSGSsD.js";import{i as rn,n as an,r as on,t as sn}from"./styles-CVwNuFCx.js";(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),e.crossOrigin===`use-credentials`?t.credentials=`include`:e.crossOrigin===`anonymous`?t.credentials=`omit`:t.credentials=`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var cn=m((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0<n;){var r=n-1>>>1,a=e[r];if(0<i(a,t))e[r]=t,e[n]=a,n=r;else break a}}function n(e){return e.length===0?null:e[0]}function r(e){if(e.length===0)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;a:for(var r=0,a=e.length,o=a>>>1;r<o;){var s=2*(r+1)-1,c=e[s],l=s+1,u=e[l];if(0>i(c,n))l<a&&0>i(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(l<a&&0>i(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function x(e){if(h=!1,b(e),!m)if(n(c)!==null)m=!0,S||(S=!0,O());else{var t=n(l);t!==null&&j(x,t.startTime-e)}}var S=!1,C=-1,w=5,T=-1;function E(){return g?!0:!(e.unstable_now()-T<w)}function D(){if(g=!1,S){var t=e.unstable_now();T=t;var i=!0;try{a:{m=!1,h&&(h=!1,v(C),C=-1),p=!0;var a=f;try{b:{for(b(t),d=n(c);d!==null&&!(d.expirationTime>t&&E());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&j(x,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}i=void 0}}finally{i?O():S=!1}}}var O;if(typeof y==`function`)O=function(){y(D)};else if(typeof MessageChannel<`u`){var k=new MessageChannel,A=k.port2;k.port1.onmessage=D,O=function(){A.postMessage(null)}}else O=function(){_(D,0)};function j(t,n){C=_(function(){t(e.unstable_now())},n)}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(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125<e?console.error(`forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported`):w=0<e?Math.floor(1e3/e):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_next=function(e){switch(f){case 1:case 2:case 3:var t=3;break;default:t=f}var n=f;f=t;try{return e()}finally{f=n}},e.unstable_requestPaint=function(){g=!0},e.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=f;f=e;try{return t()}finally{f=n}},e.unstable_scheduleCallback=function(r,i,a){var o=e.unstable_now();switch(typeof a==`object`&&a?(a=a.delay,a=typeof a==`number`&&0<a?o+a:o):a=o,r){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return s=a+s,r={id:u++,callback:i,priorityLevel:r,startTime:a,expirationTime:s,sortIndex:-1},a>o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(C),C=-1):h=!0,j(x,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,S||(S=!0,O()))),r},e.unstable_shouldYield=E,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),ln=m(((e,t)=>{t.exports=cn()})),un=m((t=>{var n=ln(),r=e(),i=de();function a(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function o(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function s(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function c(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function l(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function u(e){if(s(e)!==e)throw Error(a(188))}function d(e){var t=e.alternate;if(!t){if(t=s(e),t===null)throw Error(a(188));return t===e?e:null}for(var n=e,r=t;;){var i=n.return;if(i===null)break;var o=i.alternate;if(o===null){if(r=i.return,r!==null){n=r;continue}break}if(i.child===o.child){for(o=i.child;o;){if(o===n)return u(i),e;if(o===r)return u(i),t;o=o.sibling}throw Error(a(188))}if(n.return!==r.return)n=i,r=o;else{for(var c=!1,l=i.child;l;){if(l===n){c=!0,n=i,r=o;break}if(l===r){c=!0,r=i,n=o;break}l=l.sibling}if(!c){for(l=o.child;l;){if(l===n){c=!0,n=o,r=i;break}if(l===r){c=!0,r=o,n=i;break}l=l.sibling}if(!c)throw Error(a(189))}}if(n.alternate!==r)throw Error(a(190))}if(n.tag!==3)throw Error(a(188));return n.stateNode.current===n?e:t}function f(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=f(e),t!==null)return t;e=e.sibling}return null}var p=Object.assign,m=Symbol.for(`react.element`),h=Symbol.for(`react.transitional.element`),g=Symbol.for(`react.portal`),_=Symbol.for(`react.fragment`),v=Symbol.for(`react.strict_mode`),y=Symbol.for(`react.profiler`),b=Symbol.for(`react.consumer`),x=Symbol.for(`react.context`),S=Symbol.for(`react.forward_ref`),C=Symbol.for(`react.suspense`),w=Symbol.for(`react.suspense_list`),T=Symbol.for(`react.memo`),E=Symbol.for(`react.lazy`),D=Symbol.for(`react.activity`),O=Symbol.for(`react.memo_cache_sentinel`),k=Symbol.iterator;function A(e){return typeof e!=`object`||!e?null:(e=k&&e[k]||e[`@@iterator`],typeof e==`function`?e:null)}var j=Symbol.for(`react.client.reference`);function M(e){if(e==null)return null;if(typeof e==`function`)return e.$$typeof===j?null:e.displayName||e.name||null;if(typeof e==`string`)return e;switch(e){case _:return`Fragment`;case y:return`Profiler`;case v:return`StrictMode`;case C:return`Suspense`;case w:return`SuspenseList`;case D:return`Activity`}if(typeof e==`object`)switch(e.$$typeof){case g:return`Portal`;case x:return e.displayName||`Context`;case b:return(e._context.displayName||`Context`)+`.Consumer`;case S:var t=e.render;return e=e.displayName,e||=(e=t.displayName||t.name||``,e===``?`ForwardRef`:`ForwardRef(`+e+`)`),e;case T:return t=e.displayName||null,t===null?M(e.type)||`Memo`:t;case E:t=e._payload,e=e._init;try{return M(e(t))}catch{}}return null}var N=Array.isArray,P=r.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,F=i.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,I={pending:!1,data:null,method:null,action:null},L=[],ee=-1;function te(e){return{current:e}}function R(e){0>ee||(e.current=L[ee],L[ee]=null,ee--)}function z(e,t){ee++,L[ee]=e.current,e.current=t}var B=te(null),V=te(null),H=te(null),ne=te(null);function re(e,t){switch(z(H,t),z(V,e),z(B,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Vd(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Vd(t),e=Hd(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}R(B),z(B,e)}function U(){R(B),R(V),R(H)}function ie(e){e.memoizedState!==null&&z(ne,e);var t=B.current,n=Hd(t,e.type);t!==n&&(z(V,e),z(B,n))}function ae(e){V.current===e&&(R(B),R(V)),ne.current===e&&(R(ne),Qf._currentValue=I)}var oe,se;function ce(e){if(oe===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);oe=t&&t[1]||``,se=-1<e.stack.indexOf(`
|
|
3
|
+
at`)?` (<anonymous>)`:-1<e.stack.indexOf(`@`)?`@unknown:0:0`:``}return`
|
|
4
|
+
`+oe+e+se}var le=!1;function ue(e,t){if(!e||le)return``;le=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var r={DetermineComponentFrameRoot:function(){try{if(t){var n=function(){throw Error()};if(Object.defineProperty(n.prototype,"props",{set:function(){throw Error()}}),typeof Reflect==`object`&&Reflect.construct){try{Reflect.construct(n,[])}catch(e){var r=e}Reflect.construct(e,[],n)}else{try{n.call()}catch(e){r=e}e.call(n.prototype)}}else{try{throw Error()}catch(e){r=e}(n=e())&&typeof n.catch==`function`&&n.catch(function(){})}}catch(e){if(e&&r&&typeof e.stack==`string`)return[e.stack,r.stack]}return[null,null]}};r.DetermineComponentFrameRoot.displayName=`DetermineComponentFrameRoot`;var i=Object.getOwnPropertyDescriptor(r.DetermineComponentFrameRoot,`name`);i&&i.configurable&&Object.defineProperty(r.DetermineComponentFrameRoot,"name",{value:`DetermineComponentFrameRoot`});var a=r.DetermineComponentFrameRoot(),o=a[0],s=a[1];if(o&&s){var c=o.split(`
|
|
5
|
+
`),l=s.split(`
|
|
6
|
+
`);for(i=r=0;r<c.length&&!c[r].includes(`DetermineComponentFrameRoot`);)r++;for(;i<l.length&&!l[i].includes(`DetermineComponentFrameRoot`);)i++;if(r===c.length||i===l.length)for(r=c.length-1,i=l.length-1;1<=r&&0<=i&&c[r]!==l[i];)i--;for(;1<=r&&0<=i;r--,i--)if(c[r]!==l[i]){if(r!==1||i!==1)do if(r--,i--,0>i||c[r]!==l[i]){var u=`
|
|
7
|
+
`+c[r].replace(` at new `,` at `);return e.displayName&&u.includes(`<anonymous>`)&&(u=u.replace(`<anonymous>`,e.displayName)),u}while(1<=r&&0<=i);break}}}finally{le=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?ce(n):``}function fe(e,t){switch(e.tag){case 26:case 27:case 5:return ce(e.type);case 16:return ce(`Lazy`);case 13:return e.child!==t&&t!==null?ce(`Suspense Fallback`):ce(`Suspense`);case 19:return ce(`SuspenseList`);case 0:case 15:return ue(e.type,!1);case 11:return ue(e.type.render,!1);case 1:return ue(e.type,!0);case 31:return ce(`Activity`);default:return``}}function pe(e){try{var t=``,n=null;do t+=fe(e,n),n=e,e=e.return;while(e);return t}catch(e){return`
|
|
8
|
+
Error generating stack: `+e.message+`
|
|
9
|
+
`+e.stack}}var me=Object.prototype.hasOwnProperty,he=n.unstable_scheduleCallback,ge=n.unstable_cancelCallback,_e=n.unstable_shouldYield,ve=n.unstable_requestPaint,ye=n.unstable_now,be=n.unstable_getCurrentPriorityLevel,W=n.unstable_ImmediatePriority,xe=n.unstable_UserBlockingPriority,Se=n.unstable_NormalPriority,Ce=n.unstable_LowPriority,we=n.unstable_IdlePriority,Te=n.log,Ee=n.unstable_setDisableYieldValue,De=null,Oe=null;function ke(e){if(typeof Te==`function`&&Ee(e),Oe&&typeof Oe.setStrictMode==`function`)try{Oe.setStrictMode(De,e)}catch{}}var Ae=Math.clz32?Math.clz32:Ne,je=Math.log,Me=Math.LN2;function Ne(e){return e>>>=0,e===0?32:31-(je(e)/Me|0)|0}var Pe=256,Fe=262144,Ie=4194304;function Le(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function Re(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var i=0,a=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var s=r&134217727;return s===0?(s=r&~a,s===0?o===0?n||(n=r&~e,n!==0&&(i=Le(n))):i=Le(o):i=Le(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=Le(n))):i=Le(o)):i=Le(r)),i===0?0:t!==0&&t!==i&&(t&a)===0&&(a=i&-i,n=t&-t,a>=n||a===32&&n&4194048)?t:i}function ze(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Be(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Ve(){var e=Ie;return Ie<<=1,!(Ie&62914560)&&(Ie=4194304),e}function He(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Ue(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function We(e,t,n,r,i,a){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var s=e.entanglements,c=e.expirationTimes,l=e.hiddenUpdates;for(n=o&~n;0<n;){var u=31-Ae(n),d=1<<u;s[u]=0,c[u]=-1;var f=l[u];if(f!==null)for(l[u]=null,u=0;u<f.length;u++){var p=f[u];p!==null&&(p.lane&=-536870913)}n&=~d}r!==0&&Ge(e,r,0),a!==0&&i===0&&e.tag!==0&&(e.suspendedLanes|=a&~(o&~t))}function Ge(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var r=31-Ae(t);e.entangledLanes|=t,e.entanglements[r]=e.entanglements[r]|1073741824|n&261930}function Ke(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-Ae(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}function qe(e,t){var n=t&-t;return n=n&42?1:Je(n),(n&(e.suspendedLanes|t))===0?n:0}function Je(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function Ye(e){return e&=-e,2<e?8<e?e&134217727?32:268435456:8:2}function Xe(){var e=F.p;return e===0?(e=window.event,e===void 0?32:mp(e.type)):e}function Ze(e,t){var n=F.p;try{return F.p=e,t()}finally{F.p=n}}var Qe=Math.random().toString(36).slice(2),$e=`__reactFiber$`+Qe,et=`__reactProps$`+Qe,tt=`__reactContainer$`+Qe,nt=`__reactEvents$`+Qe,rt=`__reactListeners$`+Qe,it=`__reactHandles$`+Qe,at=`__reactResources$`+Qe,ot=`__reactMarker$`+Qe;function st(e){delete e[$e],delete e[et],delete e[nt],delete e[rt],delete e[it]}function ct(e){var t=e[$e];if(t)return t;for(var n=e.parentNode;n;){if(t=n[tt]||n[$e]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=df(e);e!==null;){if(n=e[$e])return n;e=df(e)}return t}e=n,n=e.parentNode}return null}function lt(e){if(e=e[$e]||e[tt]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function ut(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(a(33))}function dt(e){var t=e[at];return t||=e[at]={hoistableStyles:new Map,hoistableScripts:new Map},t}function ft(e){e[ot]=!0}var pt=new Set,mt={};function ht(e,t){gt(e,t),gt(e+`Capture`,t)}function gt(e,t){for(mt[e]=t,e=0;e<t.length;e++)pt.add(t[e])}var _t=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]*$`),vt={},yt={};function bt(e){return me.call(yt,e)?!0:me.call(vt,e)?!1:_t.test(e)?yt[e]=!0:(vt[e]=!0,!1)}function xt(e,t,n){if(bt(t))if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:e.removeAttribute(t);return;case`boolean`:var r=t.toLowerCase().slice(0,5);if(r!==`data-`&&r!==`aria-`){e.removeAttribute(t);return}}e.setAttribute(t,``+n)}}function St(e,t,n){if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(t);return}e.setAttribute(t,``+n)}}function Ct(e,t,n,r){if(r===null)e.removeAttribute(n);else{switch(typeof r){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(n);return}e.setAttributeNS(t,n,``+r)}}function wt(e){switch(typeof e){case`bigint`:case`boolean`:case`number`:case`string`:case`undefined`:return e;case`object`:return e;default:return``}}function Tt(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()===`input`&&(t===`checkbox`||t===`radio`)}function Et(e,t,n){var r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&r!==void 0&&typeof r.get==`function`&&typeof r.set==`function`){var i=r.get,a=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(e){n=``+e,a.call(this,e)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(e){n=``+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Dt(e){if(!e._valueTracker){var t=Tt(e)?`checked`:`value`;e._valueTracker=Et(e,t,``+e[t])}}function Ot(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r=``;return e&&(r=Tt(e)?e.checked?`true`:`false`:e.value),e=r,e===n?!1:(t.setValue(e),!0)}function kt(e){if(e||=typeof document<`u`?document:void 0,e===void 0)return null;try{return e.activeElement||e.body}catch{return e.body}}var At=/[\n"\\]/g;function jt(e){return e.replace(At,function(e){return`\\`+e.charCodeAt(0).toString(16)+` `})}function Mt(e,t,n,r,i,a,o,s){e.name=``,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`?e.type=o:e.removeAttribute(`type`),t==null?o!==`submit`&&o!==`reset`||e.removeAttribute(`value`):o===`number`?(t===0&&e.value===``||e.value!=t)&&(e.value=``+wt(t)):e.value!==``+wt(t)&&(e.value=``+wt(t)),t==null?n==null?r!=null&&e.removeAttribute(`value`):Pt(e,o,wt(n)):Pt(e,o,wt(t)),i==null&&a!=null&&(e.defaultChecked=!!a),i!=null&&(e.checked=i&&typeof i!=`function`&&typeof i!=`symbol`),s!=null&&typeof s!=`function`&&typeof s!=`symbol`&&typeof s!=`boolean`?e.name=``+wt(s):e.removeAttribute(`name`)}function Nt(e,t,n,r,i,a,o,s){if(a!=null&&typeof a!=`function`&&typeof a!=`symbol`&&typeof a!=`boolean`&&(e.type=a),t!=null||n!=null){if(!(a!==`submit`&&a!==`reset`||t!=null)){Dt(e);return}n=n==null?``:``+wt(n),t=t==null?n:``+wt(t),s||t===e.value||(e.value=t),e.defaultValue=t}r??=i,r=typeof r!=`function`&&typeof r!=`symbol`&&!!r,e.checked=s?e.checked:!!r,e.defaultChecked=!!r,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`&&(e.name=o),Dt(e)}function Pt(e,t,n){t===`number`&&kt(e.ownerDocument)===e||e.defaultValue===``+n||(e.defaultValue=``+n)}function Ft(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t[`$`+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty(`$`+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=``+wt(n),t=null,i=0;i<e.length;i++){if(e[i].value===n){e[i].selected=!0,r&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function It(e,t,n){if(t!=null&&(t=``+wt(t),t!==e.value&&(e.value=t),n==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=n==null?``:``+wt(n)}function Lt(e,t,n,r){if(t==null){if(r!=null){if(n!=null)throw Error(a(92));if(N(r)){if(1<r.length)throw Error(a(93));r=r[0]}n=r}n??=``,t=n}n=wt(t),e.defaultValue=n,r=e.textContent,r===n&&r!==``&&r!==null&&(e.value=r),Dt(e)}function Rt(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var zt=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 Bt(e,t,n){var r=t.indexOf(`--`)===0;n==null||typeof n==`boolean`||n===``?r?e.setProperty(t,``):t===`float`?e.cssFloat=``:e[t]=``:r?e.setProperty(t,n):typeof n!=`number`||n===0||zt.has(t)?t===`float`?e.cssFloat=n:e[t]=(``+n).trim():e[t]=n+`px`}function Vt(e,t,n){if(t!=null&&typeof t!=`object`)throw Error(a(62));if(e=e.style,n!=null){for(var r in n)!n.hasOwnProperty(r)||t!=null&&t.hasOwnProperty(r)||(r.indexOf(`--`)===0?e.setProperty(r,``):r===`float`?e.cssFloat=``:e[r]=``);for(var i in t)r=t[i],t.hasOwnProperty(i)&&n[i]!==r&&Bt(e,i,r)}else for(var o in t)t.hasOwnProperty(o)&&Bt(e,o,t[o])}function Ht(e){if(e.indexOf(`-`)===-1)return!1;switch(e){case`annotation-xml`:case`color-profile`:case`font-face`:case`font-face-src`:case`font-face-uri`:case`font-face-format`:case`font-face-name`:case`missing-glyph`:return!1;default:return!0}}var Ut=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`]]),Wt=/^[\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 Gt(e){return Wt.test(``+e)?`javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')`:e}function Kt(){}var qt=null;function Jt(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Yt=null,Xt=null;function Zt(e){var t=lt(e);if(t&&(e=t.stateNode)){var n=e[et]||null;a:switch(e=t.stateNode,t.type){case`input`:if(Mt(e,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),t=n.name,n.type===`radio`&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll(`input[name="`+jt(``+t)+`"][type="radio"]`),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var i=r[et]||null;if(!i)throw Error(a(90));Mt(r,i.value,i.defaultValue,i.defaultValue,i.checked,i.defaultChecked,i.type,i.name)}}for(t=0;t<n.length;t++)r=n[t],r.form===e.form&&Ot(r)}break a;case`textarea`:It(e,n.value,n.defaultValue);break a;case`select`:t=n.value,t!=null&&Ft(e,!!n.multiple,t,!1)}}}var Qt=!1;function $t(e,t,n){if(Qt)return e(t,n);Qt=!0;try{return e(t)}finally{if(Qt=!1,(Yt!==null||Xt!==null)&&(_u(),Yt&&(t=Yt,e=Xt,Xt=Yt=null,Zt(t),e)))for(t=0;t<e.length;t++)Zt(e[t])}}function en(e,t){var n=e.stateNode;if(n===null)return null;var r=n[et]||null;if(r===null)return null;n=r[t];a:switch(t){case`onClick`:case`onClickCapture`:case`onDoubleClick`:case`onDoubleClickCapture`:case`onMouseDown`:case`onMouseDownCapture`:case`onMouseMove`:case`onMouseMoveCapture`:case`onMouseUp`:case`onMouseUpCapture`:case`onMouseEnter`:(r=!r.disabled)||(e=e.type,r=!(e===`button`||e===`input`||e===`select`||e===`textarea`)),e=!r;break a;default:e=!1}if(e)return null;if(n&&typeof n!=`function`)throw Error(a(231,t,typeof n));return n}var tn=!(typeof window>`u`||window.document===void 0||window.document.createElement===void 0),nn=!1;if(tn)try{var rn={};Object.defineProperty(rn,"passive",{get:function(){nn=!0}}),window.addEventListener(`test`,rn,rn),window.removeEventListener(`test`,rn,rn)}catch{nn=!1}var an=null,on=null,sn=null;function cn(){if(sn)return sn;var e,t=on,n=t.length,r,i=`value`in an?an.value:an.textContent,a=i.length;for(e=0;e<n&&t[e]===i[e];e++);var o=n-e;for(r=1;r<=o&&t[n-r]===i[a-r];r++);return sn=i.slice(e,1<r?1-r:void 0)}function un(e){var t=e.keyCode;return`charCode`in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function dn(){return!0}function fn(){return!1}function pn(e){function t(t,n,r,i,a){for(var o in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=i,this.target=a,this.currentTarget=null,e)e.hasOwnProperty(o)&&(t=e[o],this[o]=t?t(i):i[o]);return this.isDefaultPrevented=(i.defaultPrevented==null?!1===i.returnValue:i.defaultPrevented)?dn:fn,this.isPropagationStopped=fn,this}return p(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():typeof e.returnValue!=`unknown`&&(e.returnValue=!1),this.isDefaultPrevented=dn)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():typeof e.cancelBubble!=`unknown`&&(e.cancelBubble=!0),this.isPropagationStopped=dn)},persist:function(){},isPersistent:dn}),t}var mn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},hn=pn(mn),gn=p({},mn,{view:0,detail:0}),_n=pn(gn),vn,yn,bn,xn=p({},gn,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Mn,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return`movementX`in e?e.movementX:(e!==bn&&(bn&&e.type===`mousemove`?(vn=e.screenX-bn.screenX,yn=e.screenY-bn.screenY):yn=vn=0,bn=e),vn)},movementY:function(e){return`movementY`in e?e.movementY:yn}}),Sn=pn(xn),Cn=pn(p({},xn,{dataTransfer:0})),wn=pn(p({},gn,{relatedTarget:0})),Tn=pn(p({},mn,{animationName:0,elapsedTime:0,pseudoElement:0})),En=pn(p({},mn,{clipboardData:function(e){return`clipboardData`in e?e.clipboardData:window.clipboardData}})),Dn=pn(p({},mn,{data:0})),On={Esc:`Escape`,Spacebar:` `,Left:`ArrowLeft`,Up:`ArrowUp`,Right:`ArrowRight`,Down:`ArrowDown`,Del:`Delete`,Win:`OS`,Menu:`ContextMenu`,Apps:`ContextMenu`,Scroll:`ScrollLock`,MozPrintableKey:`Unidentified`},kn={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`},An={Alt:`altKey`,Control:`ctrlKey`,Meta:`metaKey`,Shift:`shiftKey`};function jn(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=An[e])?!!t[e]:!1}function Mn(){return jn}var Nn=pn(p({},gn,{key:function(e){if(e.key){var t=On[e.key]||e.key;if(t!==`Unidentified`)return t}return e.type===`keypress`?(e=un(e),e===13?`Enter`:String.fromCharCode(e)):e.type===`keydown`||e.type===`keyup`?kn[e.keyCode]||`Unidentified`:``},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Mn,charCode:function(e){return e.type===`keypress`?un(e):0},keyCode:function(e){return e.type===`keydown`||e.type===`keyup`?e.keyCode:0},which:function(e){return e.type===`keypress`?un(e):e.type===`keydown`||e.type===`keyup`?e.keyCode:0}})),Pn=pn(p({},xn,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),Fn=pn(p({},gn,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Mn})),In=pn(p({},mn,{propertyName:0,elapsedTime:0,pseudoElement:0})),Ln=pn(p({},xn,{deltaX:function(e){return`deltaX`in e?e.deltaX:`wheelDeltaX`in e?-e.wheelDeltaX:0},deltaY:function(e){return`deltaY`in e?e.deltaY:`wheelDeltaY`in e?-e.wheelDeltaY:`wheelDelta`in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0})),Rn=pn(p({},mn,{newState:0,oldState:0})),zn=[9,13,27,32],Bn=tn&&`CompositionEvent`in window,Vn=null;tn&&`documentMode`in document&&(Vn=document.documentMode);var Hn=tn&&`TextEvent`in window&&!Vn,Un=tn&&(!Bn||Vn&&8<Vn&&11>=Vn),Wn=` `,Gn=!1;function Kn(e,t){switch(e){case`keyup`:return zn.indexOf(t.keyCode)!==-1;case`keydown`:return t.keyCode!==229;case`keypress`:case`mousedown`:case`focusout`:return!0;default:return!1}}function qn(e){return e=e.detail,typeof e==`object`&&`data`in e?e.data:null}var Jn=!1;function Yn(e,t){switch(e){case`compositionend`:return qn(t);case`keypress`:return t.which===32?(Gn=!0,Wn):null;case`textInput`:return e=t.data,e===Wn&&Gn?null:e;default:return null}}function Xn(e,t){if(Jn)return e===`compositionend`||!Bn&&Kn(e,t)?(e=cn(),sn=on=an=null,Jn=!1,e):null;switch(e){case`paste`:return null;case`keypress`:if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case`compositionend`:return Un&&t.locale!==`ko`?null:t.data;default:return null}}var Zn={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 Qn(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t===`input`?!!Zn[e.type]:t===`textarea`}function $n(e,t,n,r){Yt?Xt?Xt.push(r):Xt=[r]:Yt=r,t=Td(t,`onChange`),0<t.length&&(n=new hn(`onChange`,`change`,null,n,r),e.push({event:n,listeners:t}))}var er=null,tr=null;function nr(e){_d(e,0)}function rr(e){if(Ot(ut(e)))return e}function ir(e,t){if(e===`change`)return t}var ar=!1;if(tn){var or;if(tn){var sr=`oninput`in document;if(!sr){var cr=document.createElement(`div`);cr.setAttribute(`oninput`,`return;`),sr=typeof cr.oninput==`function`}or=sr}else or=!1;ar=or&&(!document.documentMode||9<document.documentMode)}function lr(){er&&(er.detachEvent(`onpropertychange`,ur),tr=er=null)}function ur(e){if(e.propertyName===`value`&&rr(tr)){var t=[];$n(t,tr,e,Jt(e)),$t(nr,t)}}function dr(e,t,n){e===`focusin`?(lr(),er=t,tr=n,er.attachEvent(`onpropertychange`,ur)):e===`focusout`&&lr()}function fr(e){if(e===`selectionchange`||e===`keyup`||e===`keydown`)return rr(tr)}function pr(e,t){if(e===`click`)return rr(t)}function mr(e,t){if(e===`input`||e===`change`)return rr(t)}function hr(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var gr=typeof Object.is==`function`?Object.is:hr;function _r(e,t){if(gr(e,t))return!0;if(typeof e!=`object`||!e||typeof t!=`object`||!t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!me.call(t,i)||!gr(e[i],t[i]))return!1}return!0}function vr(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function yr(e,t){var n=vr(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}a:{for(;n;){if(n.nextSibling){n=n.nextSibling;break a}n=n.parentNode}n=void 0}n=vr(n)}}function br(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?br(e,t.parentNode):`contains`in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function G(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=kt(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href==`string`}catch{n=!1}if(n)e=t.contentWindow;else break;t=kt(e.document)}return t}function K(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t===`input`&&(e.type===`text`||e.type===`search`||e.type===`tel`||e.type===`url`||e.type===`password`)||t===`textarea`||e.contentEditable===`true`)}var xr=tn&&`documentMode`in document&&11>=document.documentMode,Sr=null,Cr=null,wr=null,Tr=!1;function Er(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Tr||Sr==null||Sr!==kt(r)||(r=Sr,`selectionStart`in r&&K(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),wr&&_r(wr,r)||(wr=r,r=Td(Cr,`onSelect`),0<r.length&&(t=new hn(`onSelect`,`select`,null,t,n),e.push({event:t,listeners:r}),t.target=Sr)))}function Dr(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n[`Webkit`+e]=`webkit`+t,n[`Moz`+e]=`moz`+t,n}var Or={animationend:Dr(`Animation`,`AnimationEnd`),animationiteration:Dr(`Animation`,`AnimationIteration`),animationstart:Dr(`Animation`,`AnimationStart`),transitionrun:Dr(`Transition`,`TransitionRun`),transitionstart:Dr(`Transition`,`TransitionStart`),transitioncancel:Dr(`Transition`,`TransitionCancel`),transitionend:Dr(`Transition`,`TransitionEnd`)},kr={},Ar={};tn&&(Ar=document.createElement(`div`).style,`AnimationEvent`in window||(delete Or.animationend.animation,delete Or.animationiteration.animation,delete Or.animationstart.animation),`TransitionEvent`in window||delete Or.transitionend.transition);function jr(e){if(kr[e])return kr[e];if(!Or[e])return e;var t=Or[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Ar)return kr[e]=t[n];return e}var Mr=jr(`animationend`),Nr=jr(`animationiteration`),Pr=jr(`animationstart`),Fr=jr(`transitionrun`),Ir=jr(`transitionstart`),Lr=jr(`transitioncancel`),Rr=jr(`transitionend`),zr=new Map,Br=`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(` `);Br.push(`scrollEnd`);function Vr(e,t){zr.set(e,t),ht(t,[e])}var Hr=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},Ur=[],Wr=0,Gr=0;function Kr(){for(var e=Wr,t=Gr=Wr=0;t<e;){var n=Ur[t];Ur[t++]=null;var r=Ur[t];Ur[t++]=null;var i=Ur[t];Ur[t++]=null;var a=Ur[t];if(Ur[t++]=null,r!==null&&i!==null){var o=r.pending;o===null?i.next=i:(i.next=o.next,o.next=i),r.pending=i}a!==0&&Xr(n,i,a)}}function qr(e,t,n,r){Ur[Wr++]=e,Ur[Wr++]=t,Ur[Wr++]=n,Ur[Wr++]=r,Gr|=r,e.lanes|=r,e=e.alternate,e!==null&&(e.lanes|=r)}function Jr(e,t,n,r){return qr(e,t,n,r),Zr(e)}function Yr(e,t){return qr(e,null,null,t),Zr(e)}function Xr(e,t,n){e.lanes|=n;var r=e.alternate;r!==null&&(r.lanes|=n);for(var i=!1,a=e.return;a!==null;)a.childLanes|=n,r=a.alternate,r!==null&&(r.childLanes|=n),a.tag===22&&(e=a.stateNode,e===null||e._visibility&1||(i=!0)),e=a,a=a.return;return e.tag===3?(a=e.stateNode,i&&t!==null&&(i=31-Ae(n),e=a.hiddenUpdates,r=e[i],r===null?e[i]=[t]:r.push(t),t.lane=n|536870912),a):null}function Zr(e){if(50<cu)throw cu=0,lu=null,Error(a(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var Qr={};function $r(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function ei(e,t,n,r){return new $r(e,t,n,r)}function ti(e){return e=e.prototype,!(!e||!e.isReactComponent)}function ni(e,t){var n=e.alternate;return n===null?(n=ei(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&65011712,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n.refCleanup=e.refCleanup,n}function ri(e,t){e.flags&=65011714;var n=e.alternate;return n===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=n.childLanes,e.lanes=n.lanes,e.child=n.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=n.memoizedProps,e.memoizedState=n.memoizedState,e.updateQueue=n.updateQueue,e.type=n.type,t=n.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function ii(e,t,n,r,i,o){var s=0;if(r=e,typeof e==`function`)ti(e)&&(s=1);else if(typeof e==`string`)s=Uf(e,n,B.current)?26:e===`html`||e===`head`||e===`body`?27:5;else a:switch(e){case D:return e=ei(31,n,t,i),e.elementType=D,e.lanes=o,e;case _:return ai(n.children,i,o,t);case v:s=8,i|=24;break;case y:return e=ei(12,n,t,i|2),e.elementType=y,e.lanes=o,e;case C:return e=ei(13,n,t,i),e.elementType=C,e.lanes=o,e;case w:return e=ei(19,n,t,i),e.elementType=w,e.lanes=o,e;default:if(typeof e==`object`&&e)switch(e.$$typeof){case x:s=10;break a;case b:s=9;break a;case S:s=11;break a;case T:s=14;break a;case E:s=16,r=null;break a}s=29,n=Error(a(130,e===null?`null`:typeof e,``)),r=null}return t=ei(s,n,t,i),t.elementType=e,t.type=r,t.lanes=o,t}function ai(e,t,n,r){return e=ei(7,e,r,t),e.lanes=n,e}function oi(e,t,n){return e=ei(6,e,null,t),e.lanes=n,e}function si(e){var t=ei(18,null,null,0);return t.stateNode=e,t}function ci(e,t,n){return t=ei(4,e.children===null?[]:e.children,e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var li=new WeakMap;function ui(e,t){if(typeof e==`object`&&e){var n=li.get(e);return n===void 0?(t={value:e,source:t,stack:pe(t)},li.set(e,t),t):n}return{value:e,source:t,stack:pe(t)}}var di=[],fi=0,pi=null,mi=0,hi=[],gi=0,_i=null,vi=1,yi=``;function bi(e,t){di[fi++]=mi,di[fi++]=pi,pi=e,mi=t}function xi(e,t,n){hi[gi++]=vi,hi[gi++]=yi,hi[gi++]=_i,_i=e;var r=vi;e=yi;var i=32-Ae(r)-1;r&=~(1<<i),n+=1;var a=32-Ae(t)+i;if(30<a){var o=i-i%5;a=(r&(1<<o)-1).toString(32),r>>=o,i-=o,vi=1<<32-Ae(t)+i|n<<i|r,yi=a+e}else vi=1<<a|n<<i|r,yi=e}function Si(e){e.return!==null&&(bi(e,1),xi(e,1,0))}function Ci(e){for(;e===pi;)pi=di[--fi],di[fi]=null,mi=di[--fi],di[fi]=null;for(;e===_i;)_i=hi[--gi],hi[gi]=null,yi=hi[--gi],hi[gi]=null,vi=hi[--gi],hi[gi]=null}function wi(e,t){hi[gi++]=vi,hi[gi++]=yi,hi[gi++]=_i,vi=t.id,yi=t.overflow,_i=e}var Ti=null,Ei=null,Di=!1,Oi=null,ki=!1,Ai=Error(a(519));function ji(e){throw Li(ui(Error(a(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?`text`:`HTML`,``)),e)),Ai}function Mi(e){var t=e.stateNode,n=e.type,r=e.memoizedProps;switch(t[$e]=e,t[et]=r,n){case`dialog`:vd(`cancel`,t),vd(`close`,t);break;case`iframe`:case`object`:case`embed`:vd(`load`,t);break;case`video`:case`audio`:for(n=0;n<hd.length;n++)vd(hd[n],t);break;case`source`:vd(`error`,t);break;case`img`:case`image`:case`link`:vd(`error`,t),vd(`load`,t);break;case`details`:vd(`toggle`,t);break;case`input`:vd(`invalid`,t),Nt(t,r.value,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name,!0);break;case`select`:vd(`invalid`,t);break;case`textarea`:vd(`invalid`,t),Lt(t,r.value,r.defaultValue,r.children)}n=r.children,typeof n!=`string`&&typeof n!=`number`&&typeof n!=`bigint`||t.textContent===``+n||!0===r.suppressHydrationWarning||jd(t.textContent,n)?(r.popover!=null&&(vd(`beforetoggle`,t),vd(`toggle`,t)),r.onScroll!=null&&vd(`scroll`,t),r.onScrollEnd!=null&&vd(`scrollend`,t),r.onClick!=null&&(t.onclick=Kt),t=!0):t=!1,t||ji(e,!0)}function Ni(e){for(Ti=e.return;Ti;)switch(Ti.tag){case 5:case 31:case 13:ki=!1;return;case 27:case 3:ki=!0;return;default:Ti=Ti.return}}function Pi(e){if(e!==Ti)return!1;if(!Di)return Ni(e),Di=!0,!1;var t=e.tag,n;if((n=t!==3&&t!==27)&&((n=t===5)&&(n=e.type,n=!(n!==`form`&&n!==`button`)||Ud(e.type,e.memoizedProps)),n=!n),n&&Ei&&ji(e),Ni(e),t===13){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(a(317));Ei=uf(e)}else if(t===31){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(a(317));Ei=uf(e)}else t===27?(t=Ei,Zd(e.type)?(e=lf,lf=null,Ei=e):Ei=t):Ei=Ti?cf(e.stateNode.nextSibling):null;return!0}function Fi(){Ei=Ti=null,Di=!1}function Ii(){var e=Oi;return e!==null&&(Jl===null?Jl=e:Jl.push.apply(Jl,e),Oi=null),e}function Li(e){Oi===null?Oi=[e]:Oi.push(e)}var Ri=te(null),zi=null,Bi=null;function Vi(e,t,n){z(Ri,t._currentValue),t._currentValue=n}function Hi(e){e._currentValue=Ri.current,R(Ri)}function Ui(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)===t?r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t):(e.childLanes|=t,r!==null&&(r.childLanes|=t)),e===n)break;e=e.return}}function Wi(e,t,n,r){var i=e.child;for(i!==null&&(i.return=e);i!==null;){var o=i.dependencies;if(o!==null){var s=i.child;o=o.firstContext;a:for(;o!==null;){var c=o;o=i;for(var l=0;l<t.length;l++)if(c.context===t[l]){o.lanes|=n,c=o.alternate,c!==null&&(c.lanes|=n),Ui(o.return,n,e),r||(s=null);break a}o=c.next}}else if(i.tag===18){if(s=i.return,s===null)throw Error(a(341));s.lanes|=n,o=s.alternate,o!==null&&(o.lanes|=n),Ui(s,n,e),s=null}else s=i.child;if(s!==null)s.return=i;else for(s=i;s!==null;){if(s===e){s=null;break}if(i=s.sibling,i!==null){i.return=s.return,s=i;break}s=s.return}i=s}}function Gi(e,t,n,r){e=null;for(var i=t,o=!1;i!==null;){if(!o){if(i.flags&524288)o=!0;else if(i.flags&262144)break}if(i.tag===10){var s=i.alternate;if(s===null)throw Error(a(387));if(s=s.memoizedProps,s!==null){var c=i.type;gr(i.pendingProps.value,s.value)||(e===null?e=[c]:e.push(c))}}else if(i===ne.current){if(s=i.alternate,s===null)throw Error(a(387));s.memoizedState.memoizedState!==i.memoizedState.memoizedState&&(e===null?e=[Qf]:e.push(Qf))}i=i.return}e!==null&&Wi(t,e,n,r),t.flags|=262144}function Ki(e){for(e=e.firstContext;e!==null;){if(!gr(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function qi(e){zi=e,Bi=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function Ji(e){return Xi(zi,e)}function Yi(e,t){return zi===null&&qi(e),Xi(e,t)}function Xi(e,t){var n=t._currentValue;if(t={context:t,memoizedValue:n,next:null},Bi===null){if(e===null)throw Error(a(308));Bi=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Bi=Bi.next=t;return n}var Zi=typeof AbortController<`u`?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(t,n){e.push(n)}};this.abort=function(){t.aborted=!0,e.forEach(function(e){return e()})}},Qi=n.unstable_scheduleCallback,$i=n.unstable_NormalPriority,ea={$$typeof:x,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function ta(){return{controller:new Zi,data:new Map,refCount:0}}function na(e){e.refCount--,e.refCount===0&&Qi($i,function(){e.controller.abort()})}var ra=null,ia=0,aa=0,oa=null;function sa(e,t){if(ra===null){var n=ra=[];ia=0,aa=ld(),oa={status:`pending`,value:void 0,then:function(e){n.push(e)}}}return ia++,t.then(ca,ca),t}function ca(){if(--ia===0&&ra!==null){oa!==null&&(oa.status=`fulfilled`);var e=ra;ra=null,aa=0,oa=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function la(e,t){var n=[],r={status:`pending`,value:null,reason:null,then:function(e){n.push(e)}};return e.then(function(){r.status=`fulfilled`,r.value=t;for(var e=0;e<n.length;e++)(0,n[e])(t)},function(e){for(r.status=`rejected`,r.reason=e,e=0;e<n.length;e++)(0,n[e])(void 0)}),r}var ua=P.S;P.S=function(e,t){Zl=ye(),typeof t==`object`&&t&&typeof t.then==`function`&&sa(e,t),ua!==null&&ua(e,t)};var da=te(null);function fa(){var e=da.current;return e===null?Pl.pooledCache:e}function pa(e,t){t===null?z(da,da.current):z(da,t.pool)}function ma(){var e=fa();return e===null?null:{parent:ea._currentValue,pool:e}}var ha=Error(a(460)),ga=Error(a(474)),_a=Error(a(542)),va={then:function(){}};function ya(e){return e=e.status,e===`fulfilled`||e===`rejected`}function ba(e,t,n){switch(n=e[n],n===void 0?e.push(t):n!==t&&(t.then(Kt,Kt),t=n),t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,wa(e),e;default:if(typeof t.status==`string`)t.then(Kt,Kt);else{if(e=Pl,e!==null&&100<e.shellSuspendCounter)throw Error(a(482));e=t,e.status=`pending`,e.then(function(e){if(t.status===`pending`){var n=t;n.status=`fulfilled`,n.value=e}},function(e){if(t.status===`pending`){var n=t;n.status=`rejected`,n.reason=e}})}switch(t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,wa(e),e}throw Sa=t,ha}}function xa(e){try{var t=e._init;return t(e._payload)}catch(e){throw typeof e==`object`&&e&&typeof e.then==`function`?(Sa=e,ha):e}}var Sa=null;function Ca(){if(Sa===null)throw Error(a(459));var e=Sa;return Sa=null,e}function wa(e){if(e===ha||e===_a)throw Error(a(483))}var Ta=null,Ea=0;function Da(e){var t=Ea;return Ea+=1,Ta===null&&(Ta=[]),ba(Ta,e,t)}function Oa(e,t){t=t.props.ref,e.ref=t===void 0?null:t}function ka(e,t){throw t.$$typeof===m?Error(a(525)):(e=Object.prototype.toString.call(t),Error(a(31,e===`[object Object]`?`object with keys {`+Object.keys(t).join(`, `)+`}`:e)))}function Aa(e){function t(t,n){if(e){var r=t.deletions;r===null?(t.deletions=[n],t.flags|=16):r.push(n)}}function n(n,r){if(!e)return null;for(;r!==null;)t(n,r),r=r.sibling;return null}function r(e){for(var t=new Map;e!==null;)e.key===null?t.set(e.index,e):t.set(e.key,e),e=e.sibling;return t}function i(e,t){return e=ni(e,t),e.index=0,e.sibling=null,e}function o(t,n,r){return t.index=r,e?(r=t.alternate,r===null?(t.flags|=67108866,n):(r=r.index,r<n?(t.flags|=67108866,n):r)):(t.flags|=1048576,n)}function s(t){return e&&t.alternate===null&&(t.flags|=67108866),t}function c(e,t,n,r){return t===null||t.tag!==6?(t=oi(n,e.mode,r),t.return=e,t):(t=i(t,n),t.return=e,t)}function l(e,t,n,r){var a=n.type;return a===_?d(e,t,n.props.children,r,n.key):t!==null&&(t.elementType===a||typeof a==`object`&&a&&a.$$typeof===E&&xa(a)===t.type)?(t=i(t,n.props),Oa(t,n),t.return=e,t):(t=ii(n.type,n.key,n.props,null,e.mode,r),Oa(t,n),t.return=e,t)}function u(e,t,n,r){return t===null||t.tag!==4||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?(t=ci(n,e.mode,r),t.return=e,t):(t=i(t,n.children||[]),t.return=e,t)}function d(e,t,n,r,a){return t===null||t.tag!==7?(t=ai(n,e.mode,r,a),t.return=e,t):(t=i(t,n),t.return=e,t)}function f(e,t,n){if(typeof t==`string`&&t!==``||typeof t==`number`||typeof t==`bigint`)return t=oi(``+t,e.mode,n),t.return=e,t;if(typeof t==`object`&&t){switch(t.$$typeof){case h:return n=ii(t.type,t.key,t.props,null,e.mode,n),Oa(n,t),n.return=e,n;case g:return t=ci(t,e.mode,n),t.return=e,t;case E:return t=xa(t),f(e,t,n)}if(N(t)||A(t))return t=ai(t,e.mode,n,null),t.return=e,t;if(typeof t.then==`function`)return f(e,Da(t),n);if(t.$$typeof===x)return f(e,Yi(e,t),n);ka(e,t)}return null}function p(e,t,n,r){var i=t===null?null:t.key;if(typeof n==`string`&&n!==``||typeof n==`number`||typeof n==`bigint`)return i===null?c(e,t,``+n,r):null;if(typeof n==`object`&&n){switch(n.$$typeof){case h:return n.key===i?l(e,t,n,r):null;case g:return n.key===i?u(e,t,n,r):null;case E:return n=xa(n),p(e,t,n,r)}if(N(n)||A(n))return i===null?d(e,t,n,r,null):null;if(typeof n.then==`function`)return p(e,t,Da(n),r);if(n.$$typeof===x)return p(e,t,Yi(e,n),r);ka(e,n)}return null}function m(e,t,n,r,i){if(typeof r==`string`&&r!==``||typeof r==`number`||typeof r==`bigint`)return e=e.get(n)||null,c(t,e,``+r,i);if(typeof r==`object`&&r){switch(r.$$typeof){case h:return e=e.get(r.key===null?n:r.key)||null,l(t,e,r,i);case g:return e=e.get(r.key===null?n:r.key)||null,u(t,e,r,i);case E:return r=xa(r),m(e,t,n,r,i)}if(N(r)||A(r))return e=e.get(n)||null,d(t,e,r,i,null);if(typeof r.then==`function`)return m(e,t,n,Da(r),i);if(r.$$typeof===x)return m(e,t,n,Yi(t,r),i);ka(t,r)}return null}function v(i,a,s,c){for(var l=null,u=null,d=a,h=a=0,g=null;d!==null&&h<s.length;h++){d.index>h?(g=d,d=null):g=d.sibling;var _=p(i,d,s[h],c);if(_===null){d===null&&(d=g);break}e&&d&&_.alternate===null&&t(i,d),a=o(_,a,h),u===null?l=_:u.sibling=_,u=_,d=g}if(h===s.length)return n(i,d),Di&&bi(i,h),l;if(d===null){for(;h<s.length;h++)d=f(i,s[h],c),d!==null&&(a=o(d,a,h),u===null?l=d:u.sibling=d,u=d);return Di&&bi(i,h),l}for(d=r(d);h<s.length;h++)g=m(d,i,h,s[h],c),g!==null&&(e&&g.alternate!==null&&d.delete(g.key===null?h:g.key),a=o(g,a,h),u===null?l=g:u.sibling=g,u=g);return e&&d.forEach(function(e){return t(i,e)}),Di&&bi(i,h),l}function y(i,s,c,l){if(c==null)throw Error(a(151));for(var u=null,d=null,h=s,g=s=0,_=null,v=c.next();h!==null&&!v.done;g++,v=c.next()){h.index>g?(_=h,h=null):_=h.sibling;var y=p(i,h,v.value,l);if(y===null){h===null&&(h=_);break}e&&h&&y.alternate===null&&t(i,h),s=o(y,s,g),d===null?u=y:d.sibling=y,d=y,h=_}if(v.done)return n(i,h),Di&&bi(i,g),u;if(h===null){for(;!v.done;g++,v=c.next())v=f(i,v.value,l),v!==null&&(s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return Di&&bi(i,g),u}for(h=r(h);!v.done;g++,v=c.next())v=m(h,i,g,v.value,l),v!==null&&(e&&v.alternate!==null&&h.delete(v.key===null?g:v.key),s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return e&&h.forEach(function(e){return t(i,e)}),Di&&bi(i,g),u}function b(e,r,o,c){if(typeof o==`object`&&o&&o.type===_&&o.key===null&&(o=o.props.children),typeof o==`object`&&o){switch(o.$$typeof){case h:a:{for(var l=o.key;r!==null;){if(r.key===l){if(l=o.type,l===_){if(r.tag===7){n(e,r.sibling),c=i(r,o.props.children),c.return=e,e=c;break a}}else if(r.elementType===l||typeof l==`object`&&l&&l.$$typeof===E&&xa(l)===r.type){n(e,r.sibling),c=i(r,o.props),Oa(c,o),c.return=e,e=c;break a}n(e,r);break}else t(e,r);r=r.sibling}o.type===_?(c=ai(o.props.children,e.mode,c,o.key),c.return=e,e=c):(c=ii(o.type,o.key,o.props,null,e.mode,c),Oa(c,o),c.return=e,e=c)}return s(e);case g:a:{for(l=o.key;r!==null;){if(r.key===l)if(r.tag===4&&r.stateNode.containerInfo===o.containerInfo&&r.stateNode.implementation===o.implementation){n(e,r.sibling),c=i(r,o.children||[]),c.return=e,e=c;break a}else{n(e,r);break}else t(e,r);r=r.sibling}c=ci(o,e.mode,c),c.return=e,e=c}return s(e);case E:return o=xa(o),b(e,r,o,c)}if(N(o))return v(e,r,o,c);if(A(o)){if(l=A(o),typeof l!=`function`)throw Error(a(150));return o=l.call(o),y(e,r,o,c)}if(typeof o.then==`function`)return b(e,r,Da(o),c);if(o.$$typeof===x)return b(e,r,Yi(e,o),c);ka(e,o)}return typeof o==`string`&&o!==``||typeof o==`number`||typeof o==`bigint`?(o=``+o,r!==null&&r.tag===6?(n(e,r.sibling),c=i(r,o),c.return=e,e=c):(n(e,r),c=oi(o,e.mode,c),c.return=e,e=c),s(e)):n(e,r)}return function(e,t,n,r){try{Ea=0;var i=b(e,t,n,r);return Ta=null,i}catch(t){if(t===ha||t===_a)throw t;var a=ei(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var ja=Aa(!0),Ma=Aa(!1),Na=!1;function Pa(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Fa(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function Ia(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function La(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,Nl&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=Zr(e),Xr(e,null,n),t}return qr(e,r,t,n),Zr(e)}function Ra(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,n&4194048)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Ke(e,n)}}function za(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var Ba=!1;function Va(){if(Ba){var e=oa;if(e!==null)throw e}}function Ha(e,t,n,r){Ba=!1;var i=e.updateQueue;Na=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var c=s,l=c.next;c.next=null,o===null?a=l:o.next=l,o=c;var u=e.alternate;u!==null&&(u=u.updateQueue,s=u.lastBaseUpdate,s!==o&&(s===null?u.firstBaseUpdate=l:s.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;o=0,u=l=c=null,s=a;do{var f=s.lane&-536870913,m=f!==s.lane;if(m?(Il&f)===f:(r&f)===f){f!==0&&f===aa&&(Ba=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var h=e,g=s;f=t;var _=n;switch(g.tag){case 1:if(h=g.payload,typeof h==`function`){d=h.call(_,d,f);break a}d=h;break a;case 3:h.flags=h.flags&-65537|128;case 0:if(h=g.payload,f=typeof h==`function`?h.call(_,d,f):h,f==null)break a;d=p({},d,f);break a;case 2:Na=!0}}f=s.callback,f!==null&&(e.flags|=64,m&&(e.flags|=8192),m=i.callbacks,m===null?i.callbacks=[f]:m.push(f))}else m={lane:f,tag:s.tag,payload:s.payload,callback:s.callback,next:null},u===null?(l=u=m,c=d):u=u.next=m,o|=f;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;m=s,s=m.next,m.next=null,i.lastBaseUpdate=m,i.shared.pending=null}}while(1);u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,a===null&&(i.shared.lanes=0),Hl|=o,e.lanes=o,e.memoizedState=d}}function Ua(e,t){if(typeof e!=`function`)throw Error(a(191,e));e.call(t)}function Wa(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;e<n.length;e++)Ua(n[e],t)}var Ga=te(null),Ka=te(0);function qa(e,t){e=Bl,z(Ka,e),z(Ga,t),Bl=e|t.baseLanes}function Ja(){z(Ka,Bl),z(Ga,Ga.current)}function Ya(){Bl=Ka.current,R(Ga),R(Ka)}var Xa=te(null),q=null;function Za(e){var t=e.alternate;z(no,no.current&1),z(Xa,e),q===null&&(t===null||Ga.current!==null||t.memoizedState!==null)&&(q=e)}function Qa(e){z(no,no.current),z(Xa,e),q===null&&(q=e)}function $a(e){e.tag===22?(z(no,no.current),z(Xa,e),q===null&&(q=e)):eo(e)}function eo(){z(no,no.current),z(Xa,Xa.current)}function to(e){R(Xa),q===e&&(q=null),R(no)}var no=te(0);function ro(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||af(n)||of(n)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder===`forwards`||t.memoizedProps.revealOrder===`backwards`||t.memoizedProps.revealOrder===`unstable_legacy-backwards`||t.memoizedProps.revealOrder===`together`)){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var io=0,J=null,ao=null,oo=null,so=!1,co=!1,lo=!1,uo=0,fo=0,po=null,mo=0;function ho(){throw Error(a(321))}function go(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!gr(e[n],t[n]))return!1;return!0}function _o(e,t,n,r,i,a){return io=a,J=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,P.H=e===null||e.memoizedState===null?Ns:Ps,lo=!1,a=n(r,i),lo=!1,co&&(a=yo(t,n,r,i)),vo(e),a}function vo(e){P.H=Ms;var t=ao!==null&&ao.next!==null;if(io=0,oo=ao=J=null,so=!1,fo=0,po=null,t)throw Error(a(300));e===null||Zs||(e=e.dependencies,e!==null&&Ki(e)&&(Zs=!0))}function yo(e,t,n,r){J=e;var i=0;do{if(co&&(po=null),fo=0,co=!1,25<=i)throw Error(a(301));if(i+=1,oo=ao=null,e.updateQueue!=null){var o=e.updateQueue;o.lastEffect=null,o.events=null,o.stores=null,o.memoCache!=null&&(o.memoCache.index=0)}P.H=Fs,o=t(n,r)}while(co);return o}function bo(){var e=P.H,t=e.useState()[0];return t=typeof t.then==`function`?Do(t):t,e=e.useState()[0],(ao===null?null:ao.memoizedState)!==e&&(J.flags|=1024),t}function xo(){var e=uo!==0;return uo=0,e}function So(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function Co(e){if(so){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}so=!1}io=0,oo=ao=J=null,co=!1,fo=uo=0,po=null}function wo(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return oo===null?J.memoizedState=oo=e:oo=oo.next=e,oo}function To(){if(ao===null){var e=J.alternate;e=e===null?null:e.memoizedState}else e=ao.next;var t=oo===null?J.memoizedState:oo.next;if(t!==null)oo=t,ao=e;else{if(e===null)throw J.alternate===null?Error(a(467)):Error(a(310));ao=e,e={memoizedState:ao.memoizedState,baseState:ao.baseState,baseQueue:ao.baseQueue,queue:ao.queue,next:null},oo===null?J.memoizedState=oo=e:oo=oo.next=e}return oo}function Eo(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Do(e){var t=fo;return fo+=1,po===null&&(po=[]),e=ba(po,e,t),t=J,(oo===null?t.memoizedState:oo.next)===null&&(t=t.alternate,P.H=t===null||t.memoizedState===null?Ns:Ps),e}function Oo(e){if(typeof e==`object`&&e){if(typeof e.then==`function`)return Do(e);if(e.$$typeof===x)return Ji(e)}throw Error(a(438,String(e)))}function ko(e){var t=null,n=J.updateQueue;if(n!==null&&(t=n.memoCache),t==null){var r=J.alternate;r!==null&&(r=r.updateQueue,r!==null&&(r=r.memoCache,r!=null&&(t={data:r.data.map(function(e){return e.slice()}),index:0})))}if(t??={data:[],index:0},n===null&&(n=Eo(),J.updateQueue=n),n.memoCache=t,n=t.data[t.index],n===void 0)for(n=t.data[t.index]=Array(e),r=0;r<e;r++)n[r]=O;return t.index++,n}function Ao(e,t){return typeof t==`function`?t(e):t}function jo(e){return Mo(To(),ao,e)}function Mo(e,t,n){var r=e.queue;if(r===null)throw Error(a(311));r.lastRenderedReducer=n;var i=e.baseQueue,o=r.pending;if(o!==null){if(i!==null){var s=i.next;i.next=o.next,o.next=s}t.baseQueue=i=o,r.pending=null}if(o=e.baseState,i===null)e.memoizedState=o;else{t=i.next;var c=s=null,l=null,u=t,d=!1;do{var f=u.lane&-536870913;if(f===u.lane?(io&f)===f:(Il&f)===f){var p=u.revertLane;if(p===0)l!==null&&(l=l.next={lane:0,revertLane:0,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),f===aa&&(d=!0);else if((io&p)===p){u=u.next,p===aa&&(d=!0);continue}else f={lane:0,revertLane:u.revertLane,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=f,s=o):l=l.next=f,J.lanes|=p,Hl|=p;f=u.action,lo&&n(o,f),o=u.hasEagerState?u.eagerState:n(o,f)}else p={lane:f,revertLane:u.revertLane,gesture:u.gesture,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=p,s=o):l=l.next=p,J.lanes|=f,Hl|=f;u=u.next}while(u!==null&&u!==t);if(l===null?s=o:l.next=c,!gr(o,e.memoizedState)&&(Zs=!0,d&&(n=oa,n!==null)))throw n;e.memoizedState=o,e.baseState=s,e.baseQueue=l,r.lastRenderedState=o}return i===null&&(r.lanes=0),[e.memoizedState,r.dispatch]}function No(e){var t=To(),n=t.queue;if(n===null)throw Error(a(311));n.lastRenderedReducer=e;var r=n.dispatch,i=n.pending,o=t.memoizedState;if(i!==null){n.pending=null;var s=i=i.next;do o=e(o,s.action),s=s.next;while(s!==i);gr(o,t.memoizedState)||(Zs=!0),t.memoizedState=o,t.baseQueue===null&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function Po(e,t,n){var r=J,i=To(),o=Di;if(o){if(n===void 0)throw Error(a(407));n=n()}else n=t();var s=!gr((ao||i).memoizedState,n);if(s&&(i.memoizedState=n,Zs=!0),i=i.queue,is(Lo.bind(null,r,i,e),[e]),i.getSnapshot!==t||s||oo!==null&&oo.memoizedState.tag&1){if(r.flags|=2048,$o(9,{destroy:void 0},Io.bind(null,r,i,n,t),null),Pl===null)throw Error(a(349));o||io&127||Fo(r,t,n)}return n}function Fo(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=J.updateQueue,t===null?(t=Eo(),J.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Io(e,t,n,r){t.value=n,t.getSnapshot=r,Ro(t)&&zo(e)}function Lo(e,t,n){return n(function(){Ro(t)&&zo(e)})}function Ro(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!gr(e,n)}catch{return!0}}function zo(e){var t=Yr(e,2);t!==null&&fu(t,e,2)}function Bo(e){var t=wo();if(typeof e==`function`){var n=e;if(e=n(),lo){ke(!0);try{n()}finally{ke(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ao,lastRenderedState:e},t}function Vo(e,t,n,r){return e.baseState=n,Mo(e,ao,typeof r==`function`?r:Ao)}function Ho(e,t,n,r,i){if(ks(e))throw Error(a(485));if(e=t.action,e!==null){var o={payload:i,action:e,next:null,isTransition:!0,status:`pending`,value:null,reason:null,listeners:[],then:function(e){o.listeners.push(e)}};P.T===null?o.isTransition=!1:n(!0),r(o),n=t.pending,n===null?(o.next=t.pending=o,Uo(t,o)):(o.next=n.next,t.pending=n.next=o)}}function Uo(e,t){var n=t.action,r=t.payload,i=e.state;if(t.isTransition){var a=P.T,o={};P.T=o;try{var s=n(i,r),c=P.S;c!==null&&c(o,s),Wo(e,t,s)}catch(n){Ko(e,t,n)}finally{a!==null&&o.types!==null&&(a.types=o.types),P.T=a}}else try{a=n(i,r),Wo(e,t,a)}catch(n){Ko(e,t,n)}}function Wo(e,t,n){typeof n==`object`&&n&&typeof n.then==`function`?n.then(function(n){Go(e,t,n)},function(n){return Ko(e,t,n)}):Go(e,t,n)}function Go(e,t,n){t.status=`fulfilled`,t.value=n,qo(t),e.state=n,t=e.pending,t!==null&&(n=t.next,n===t?e.pending=null:(n=n.next,t.next=n,Uo(e,n)))}function Ko(e,t,n){var r=e.pending;if(e.pending=null,r!==null){r=r.next;do t.status=`rejected`,t.reason=n,qo(t),t=t.next;while(t!==r)}e.action=null}function qo(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function Jo(e,t){return t}function Y(e,t){if(Di){var n=Pl.formState;if(n!==null){a:{var r=J;if(Di){if(Ei){b:{for(var i=Ei,a=ki;i.nodeType!==8;){if(!a){i=null;break b}if(i=cf(i.nextSibling),i===null){i=null;break b}}a=i.data,i=a===`F!`||a===`F`?i:null}if(i){Ei=cf(i.nextSibling),r=i.data===`F!`;break a}}ji(r)}r=!1}r&&(t=n[0])}}return n=wo(),n.memoizedState=n.baseState=t,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Jo,lastRenderedState:t},n.queue=r,n=Es.bind(null,J,r),r.dispatch=n,r=Bo(!1),a=Os.bind(null,J,!1,r.queue),r=wo(),i={state:t,dispatch:null,action:e,pending:null},r.queue=i,n=Ho.bind(null,J,i,a,n),i.dispatch=n,r.memoizedState=e,[t,n,!1]}function Yo(e){return Xo(To(),ao,e)}function Xo(e,t,n){if(t=Mo(e,t,Jo)[0],e=jo(Ao)[0],typeof t==`object`&&t&&typeof t.then==`function`)try{var r=Do(t)}catch(e){throw e===ha?_a:e}else r=t;t=To();var i=t.queue,a=i.dispatch;return n!==t.memoizedState&&(J.flags|=2048,$o(9,{destroy:void 0},Zo.bind(null,i,n),null)),[r,a,e]}function Zo(e,t){e.action=t}function Qo(e){var t=To(),n=ao;if(n!==null)return Xo(t,n,e);To(),t=t.memoizedState,n=To();var r=n.queue.dispatch;return n.memoizedState=e,[t,r,!1]}function $o(e,t,n,r){return e={tag:e,create:n,deps:r,inst:t,next:null},t=J.updateQueue,t===null&&(t=Eo(),J.updateQueue=t),n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function es(){return To().memoizedState}function ts(e,t,n,r){var i=wo();J.flags|=e,i.memoizedState=$o(1|t,{destroy:void 0},n,r===void 0?null:r)}function ns(e,t,n,r){var i=To();r=r===void 0?null:r;var a=i.memoizedState.inst;ao!==null&&r!==null&&go(r,ao.memoizedState.deps)?i.memoizedState=$o(t,a,n,r):(J.flags|=e,i.memoizedState=$o(1|t,a,n,r))}function rs(e,t){ts(8390656,8,e,t)}function is(e,t){ns(2048,8,e,t)}function as(e){J.flags|=4;var t=J.updateQueue;if(t===null)t=Eo(),J.updateQueue=t,t.events=[e];else{var n=t.events;n===null?t.events=[e]:n.push(e)}}function os(e){var t=To().memoizedState;return as({ref:t,nextImpl:e}),function(){if(Nl&2)throw Error(a(440));return t.impl.apply(void 0,arguments)}}function ss(e,t){return ns(4,2,e,t)}function cs(e,t){return ns(4,4,e,t)}function ls(e,t){if(typeof t==`function`){e=e();var n=t(e);return function(){typeof n==`function`?n():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function us(e,t,n){n=n==null?null:n.concat([e]),ns(4,4,ls.bind(null,t,e),n)}function ds(){}function fs(e,t){var n=To();t=t===void 0?null:t;var r=n.memoizedState;return t!==null&&go(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function ps(e,t){var n=To();t=t===void 0?null:t;var r=n.memoizedState;if(t!==null&&go(t,r[1]))return r[0];if(r=e(),lo){ke(!0);try{e()}finally{ke(!1)}}return n.memoizedState=[r,t],r}function ms(e,t,n){return n===void 0||io&1073741824&&!(Il&261930)?e.memoizedState=t:(e.memoizedState=n,e=du(),J.lanes|=e,Hl|=e,n)}function hs(e,t,n,r){return gr(n,t)?n:Ga.current===null?!(io&42)||io&1073741824&&!(Il&261930)?(Zs=!0,e.memoizedState=n):(e=du(),J.lanes|=e,Hl|=e,t):(e=ms(e,n,r),gr(e,t)||(Zs=!0),e)}function gs(e,t,n,r,i){var a=F.p;F.p=a!==0&&8>a?a:8;var o=P.T,s={};P.T=s,Os(e,!1,t,n);try{var c=i(),l=P.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?Ds(e,t,la(c,r),uu(e)):Ds(e,t,r,uu(e))}catch(n){Ds(e,t,{then:function(){},status:`rejected`,reason:n},uu())}finally{F.p=a,o!==null&&s.types!==null&&(o.types=s.types),P.T=o}}function _s(){}function vs(e,t,n,r){if(e.tag!==5)throw Error(a(476));var i=ys(e).queue;gs(e,i,t,I,n===null?_s:function(){return bs(e),n(r)})}function ys(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:I,baseState:I,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ao,lastRenderedState:I},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ao,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function bs(e){var t=ys(e);t.next===null&&(t=e.alternate.memoizedState),Ds(e,t.next.queue,{},uu())}function xs(){return Ji(Qf)}function Ss(){return To().memoizedState}function Cs(){return To().memoizedState}function ws(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=uu();e=Ia(n);var r=La(t,e,n);r!==null&&(fu(r,t,n),Ra(r,t,n)),t={cache:ta()},e.payload=t;return}t=t.return}}function Ts(e,t,n){var r=uu();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},ks(e)?As(t,n):(n=Jr(e,t,n,r),n!==null&&(fu(n,e,r),js(n,t,r)))}function Es(e,t,n){Ds(e,t,n,uu())}function Ds(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(ks(e))As(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,gr(s,o))return qr(e,t,i,0),Pl===null&&Kr(),!1}catch{}if(n=Jr(e,t,i,r),n!==null)return fu(n,e,r),js(n,t,r),!0}return!1}function Os(e,t,n,r){if(r={lane:2,revertLane:ld(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},ks(e)){if(t)throw Error(a(479))}else t=Jr(e,n,r,2),t!==null&&fu(t,e,2)}function ks(e){var t=e.alternate;return e===J||t!==null&&t===J}function As(e,t){co=so=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function js(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Ke(e,n)}}var Ms={readContext:Ji,use:Oo,useCallback:ho,useContext:ho,useEffect:ho,useImperativeHandle:ho,useLayoutEffect:ho,useInsertionEffect:ho,useMemo:ho,useReducer:ho,useRef:ho,useState:ho,useDebugValue:ho,useDeferredValue:ho,useTransition:ho,useSyncExternalStore:ho,useId:ho,useHostTransitionStatus:ho,useFormState:ho,useActionState:ho,useOptimistic:ho,useMemoCache:ho,useCacheRefresh:ho};Ms.useEffectEvent=ho;var Ns={readContext:Ji,use:Oo,useCallback:function(e,t){return wo().memoizedState=[e,t===void 0?null:t],e},useContext:Ji,useEffect:rs,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),ts(4194308,4,ls.bind(null,t,e),n)},useLayoutEffect:function(e,t){return ts(4194308,4,e,t)},useInsertionEffect:function(e,t){ts(4,2,e,t)},useMemo:function(e,t){var n=wo();t=t===void 0?null:t;var r=e();if(lo){ke(!0);try{e()}finally{ke(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=wo();if(n!==void 0){var i=n(t);if(lo){ke(!0);try{n(t)}finally{ke(!1)}}}else i=t;return r.memoizedState=r.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},r.queue=e,e=e.dispatch=Ts.bind(null,J,e),[r.memoizedState,e]},useRef:function(e){var t=wo();return e={current:e},t.memoizedState=e},useState:function(e){e=Bo(e);var t=e.queue,n=Es.bind(null,J,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:ds,useDeferredValue:function(e,t){return ms(wo(),e,t)},useTransition:function(){var e=Bo(!1);return e=gs.bind(null,J,e.queue,!0,!1),wo().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=J,i=wo();if(Di){if(n===void 0)throw Error(a(407));n=n()}else{if(n=t(),Pl===null)throw Error(a(349));Il&127||Fo(r,t,n)}i.memoizedState=n;var o={value:n,getSnapshot:t};return i.queue=o,rs(Lo.bind(null,r,o,e),[e]),r.flags|=2048,$o(9,{destroy:void 0},Io.bind(null,r,o,n,t),null),n},useId:function(){var e=wo(),t=Pl.identifierPrefix;if(Di){var n=yi,r=vi;n=(r&~(1<<32-Ae(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=uo++,0<n&&(t+=`H`+n.toString(32)),t+=`_`}else n=mo++,t=`_`+t+`r_`+n.toString(32)+`_`;return e.memoizedState=t},useHostTransitionStatus:xs,useFormState:Y,useActionState:Y,useOptimistic:function(e){var t=wo();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=Os.bind(null,J,!0,n),n.dispatch=t,[e,t]},useMemoCache:ko,useCacheRefresh:function(){return wo().memoizedState=ws.bind(null,J)},useEffectEvent:function(e){var t=wo(),n={impl:e};return t.memoizedState=n,function(){if(Nl&2)throw Error(a(440));return n.impl.apply(void 0,arguments)}}},Ps={readContext:Ji,use:Oo,useCallback:fs,useContext:Ji,useEffect:is,useImperativeHandle:us,useInsertionEffect:ss,useLayoutEffect:cs,useMemo:ps,useReducer:jo,useRef:es,useState:function(){return jo(Ao)},useDebugValue:ds,useDeferredValue:function(e,t){return hs(To(),ao.memoizedState,e,t)},useTransition:function(){var e=jo(Ao)[0],t=To().memoizedState;return[typeof e==`boolean`?e:Do(e),t]},useSyncExternalStore:Po,useId:Ss,useHostTransitionStatus:xs,useFormState:Yo,useActionState:Yo,useOptimistic:function(e,t){return Vo(To(),ao,e,t)},useMemoCache:ko,useCacheRefresh:Cs};Ps.useEffectEvent=os;var Fs={readContext:Ji,use:Oo,useCallback:fs,useContext:Ji,useEffect:is,useImperativeHandle:us,useInsertionEffect:ss,useLayoutEffect:cs,useMemo:ps,useReducer:No,useRef:es,useState:function(){return No(Ao)},useDebugValue:ds,useDeferredValue:function(e,t){var n=To();return ao===null?ms(n,e,t):hs(n,ao.memoizedState,e,t)},useTransition:function(){var e=No(Ao)[0],t=To().memoizedState;return[typeof e==`boolean`?e:Do(e),t]},useSyncExternalStore:Po,useId:Ss,useHostTransitionStatus:xs,useFormState:Qo,useActionState:Qo,useOptimistic:function(e,t){var n=To();return ao===null?(n.baseState=e,[e,n.queue.dispatch]):Vo(n,ao,e,t)},useMemoCache:ko,useCacheRefresh:Cs};Fs.useEffectEvent=os;function Is(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:p({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Ls={enqueueSetState:function(e,t,n){e=e._reactInternals;var r=uu(),i=Ia(r);i.payload=t,n!=null&&(i.callback=n),t=La(e,i,r),t!==null&&(fu(t,e,r),Ra(t,e,r))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=uu(),i=Ia(r);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=La(e,i,r),t!==null&&(fu(t,e,r),Ra(t,e,r))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=uu(),r=Ia(n);r.tag=2,t!=null&&(r.callback=t),t=La(e,r,n),t!==null&&(fu(t,e,n),Ra(t,e,n))}};function Rs(e,t,n,r,i,a,o){return e=e.stateNode,typeof e.shouldComponentUpdate==`function`?e.shouldComponentUpdate(r,a,o):t.prototype&&t.prototype.isPureReactComponent?!_r(n,r)||!_r(i,a):!0}function zs(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps==`function`&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps==`function`&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&Ls.enqueueReplaceState(t,t.state,null)}function Bs(e,t){var n=t;if(`ref`in t)for(var r in n={},t)r!==`ref`&&(n[r]=t[r]);if(e=e.defaultProps)for(var i in n===t&&(n=p({},n)),e)n[i]===void 0&&(n[i]=e[i]);return n}function Vs(e){Hr(e)}function Hs(e){console.error(e)}function Us(e){Hr(e)}function Ws(e,t){try{var n=e.onUncaughtError;n(t.value,{componentStack:t.stack})}catch(e){setTimeout(function(){throw e})}}function Gs(e,t,n){try{var r=e.onCaughtError;r(n.value,{componentStack:n.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(e){setTimeout(function(){throw e})}}function Ks(e,t,n){return n=Ia(n),n.tag=3,n.payload={element:null},n.callback=function(){Ws(e,t)},n}function qs(e){return e=Ia(e),e.tag=3,e}function Js(e,t,n,r){var i=n.type.getDerivedStateFromError;if(typeof i==`function`){var a=r.value;e.payload=function(){return i(a)},e.callback=function(){Gs(t,n,r)}}var o=n.stateNode;o!==null&&typeof o.componentDidCatch==`function`&&(e.callback=function(){Gs(t,n,r),typeof i!=`function`&&(eu===null?eu=new Set([this]):eu.add(this));var e=r.stack;this.componentDidCatch(r.value,{componentStack:e===null?``:e})})}function Ys(e,t,n,r,i){if(n.flags|=32768,typeof r==`object`&&r&&typeof r.then==`function`){if(t=n.alternate,t!==null&&Gi(t,n,i,!0),n=Xa.current,n!==null){switch(n.tag){case 31:case 13:return q===null?wu():n.alternate===null&&Vl===0&&(Vl=3),n.flags&=-257,n.flags|=65536,n.lanes=i,r===va?n.flags|=16384:(t=n.updateQueue,t===null?n.updateQueue=new Set([r]):t.add(r),Uu(e,r,i)),!1;case 22:return n.flags|=65536,r===va?n.flags|=16384:(t=n.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([r])},n.updateQueue=t):(n=t.retryQueue,n===null?t.retryQueue=new Set([r]):n.add(r)),Uu(e,r,i)),!1}throw Error(a(435,n.tag))}return Uu(e,r,i),wu(),!1}if(Di)return t=Xa.current,t===null?(r!==Ai&&(t=Error(a(423),{cause:r}),Li(ui(t,n))),e=e.current.alternate,e.flags|=65536,i&=-i,e.lanes|=i,r=ui(r,n),i=Ks(e.stateNode,r,i),za(e,i),Vl!==4&&(Vl=2)):(!(t.flags&65536)&&(t.flags|=256),t.flags|=65536,t.lanes=i,r!==Ai&&(e=Error(a(422),{cause:r}),Li(ui(e,n)))),!1;var o=Error(a(520),{cause:r});if(o=ui(o,n),ql===null?ql=[o]:ql.push(o),Vl!==4&&(Vl=2),t===null)return!0;r=ui(r,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=i&-i,n.lanes|=e,e=Ks(n.stateNode,r,e),za(n,e),!1;case 1:if(t=n.type,o=n.stateNode,!(n.flags&128)&&(typeof t.getDerivedStateFromError==`function`||o!==null&&typeof o.componentDidCatch==`function`&&(eu===null||!eu.has(o))))return n.flags|=65536,i&=-i,n.lanes|=i,i=qs(i),Js(i,e,n,r),za(n,i),!1}n=n.return}while(n!==null);return!1}var Xs=Error(a(461)),Zs=!1;function Qs(e,t,n,r){t.child=e===null?Ma(t,null,n,r):ja(t,e.child,n,r)}function $s(e,t,n,r,i){n=n.render;var a=t.ref;if(`ref`in r){var o={};for(var s in r)s!==`ref`&&(o[s]=r[s])}else o=r;return qi(t),r=_o(e,t,n,o,a,i),s=xo(),e!==null&&!Zs?(So(e,t,i),xc(e,t,i)):(Di&&s&&Si(t),t.flags|=1,Qs(e,t,r,i),t.child)}function X(e,t,n,r,i){if(e===null){var a=n.type;return typeof a==`function`&&!ti(a)&&a.defaultProps===void 0&&n.compare===null?(t.tag=15,t.type=a,ec(e,t,a,r,i)):(e=ii(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!Sc(e,i)){var o=a.memoizedProps;if(n=n.compare,n=n===null?_r:n,n(o,r)&&e.ref===t.ref)return xc(e,t,i)}return t.flags|=1,e=ni(a,r),e.ref=t.ref,e.return=t,t.child=e}function ec(e,t,n,r,i){if(e!==null){var a=e.memoizedProps;if(_r(a,r)&&e.ref===t.ref)if(Zs=!1,t.pendingProps=r=a,Sc(e,i))e.flags&131072&&(Zs=!0);else return t.lanes=e.lanes,xc(e,t,i)}return sc(e,t,n,r,i)}function tc(e,t,n,r){var i=r.children,a=e===null?null:e.memoizedState;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),r.mode===`hidden`){if(t.flags&128){if(a=a===null?n:a.baseLanes|n,e!==null){for(r=t.child=e.child,i=0;r!==null;)i=i|r.lanes|r.childLanes,r=r.sibling;r=i&~a}else r=0,t.child=null;return nc(e,t,a,n,r)}if(n&536870912)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&pa(t,a===null?null:a.cachePool),a===null?Ja():qa(t,a),$a(t);else return r=t.lanes=536870912,nc(e,t,a===null?n:a.baseLanes|n,n,r)}else a===null?(e!==null&&pa(t,null),Ja(),eo(t)):(pa(t,a.cachePool),qa(t,a),eo(t),t.memoizedState=null);return Qs(e,t,i,n),t.child}function Z(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function nc(e,t,n,r,i){var a=fa();return a=a===null?null:{parent:ea._currentValue,pool:a},t.memoizedState={baseLanes:n,cachePool:a},e!==null&&pa(t,null),Ja(),$a(t),e!==null&&Gi(e,t,r,!0),t.childLanes=i,null}function rc(e,t){return t=gc({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function ic(e,t,n){return ja(t,e.child,null,n),e=rc(t,t.pendingProps),e.flags|=2,to(t),t.memoizedState=null,e}function ac(e,t,n){var r=t.pendingProps,i=(t.flags&128)!=0;if(t.flags&=-129,e===null){if(Di){if(r.mode===`hidden`)return e=rc(t,r),t.lanes=536870912,Z(null,e);if(Qa(t),(e=Ei)?(e=rf(e,ki),e=e!==null&&e.data===`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:_i===null?null:{id:vi,overflow:yi},retryLane:536870912,hydrationErrors:null},n=si(e),n.return=t,t.child=n,Ti=t,Ei=null)):e=null,e===null)throw ji(t);return t.lanes=536870912,null}return rc(t,r)}var o=e.memoizedState;if(o!==null){var s=o.dehydrated;if(Qa(t),i)if(t.flags&256)t.flags&=-257,t=ic(e,t,n);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(a(558));else if(Zs||Gi(e,t,n,!1),i=(n&e.childLanes)!==0,Zs||i){if(r=Pl,r!==null&&(s=qe(r,n),s!==0&&s!==o.retryLane))throw o.retryLane=s,Yr(e,s),fu(r,e,s),Xs;wu(),t=ic(e,t,n)}else e=o.treeContext,Ei=cf(s.nextSibling),Ti=t,Di=!0,Oi=null,ki=!1,e!==null&&wi(t,e),t=rc(t,r),t.flags|=4096;return t}return e=ni(e.child,{mode:r.mode,children:r.children}),e.ref=t.ref,t.child=e,e.return=t,e}function oc(e,t){var n=t.ref;if(n===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof n!=`function`&&typeof n!=`object`)throw Error(a(284));(e===null||e.ref!==n)&&(t.flags|=4194816)}}function sc(e,t,n,r,i){return qi(t),n=_o(e,t,n,r,void 0,i),r=xo(),e!==null&&!Zs?(So(e,t,i),xc(e,t,i)):(Di&&r&&Si(t),t.flags|=1,Qs(e,t,n,i),t.child)}function cc(e,t,n,r,i,a){return qi(t),t.updateQueue=null,n=yo(t,r,n,i),vo(e),r=xo(),e!==null&&!Zs?(So(e,t,a),xc(e,t,a)):(Di&&r&&Si(t),t.flags|=1,Qs(e,t,n,a),t.child)}function lc(e,t,n,r,i){if(qi(t),t.stateNode===null){var a=Qr,o=n.contextType;typeof o==`object`&&o&&(a=Ji(o)),a=new n(r,a),t.memoizedState=a.state!==null&&a.state!==void 0?a.state:null,a.updater=Ls,t.stateNode=a,a._reactInternals=t,a=t.stateNode,a.props=r,a.state=t.memoizedState,a.refs={},Pa(t),o=n.contextType,a.context=typeof o==`object`&&o?Ji(o):Qr,a.state=t.memoizedState,o=n.getDerivedStateFromProps,typeof o==`function`&&(Is(t,n,o,r),a.state=t.memoizedState),typeof n.getDerivedStateFromProps==`function`||typeof a.getSnapshotBeforeUpdate==`function`||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(o=a.state,typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount(),o!==a.state&&Ls.enqueueReplaceState(a,a.state,null),Ha(t,r,a,i),Va(),a.state=t.memoizedState),typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!0}else if(e===null){a=t.stateNode;var s=t.memoizedProps,c=Bs(n,s);a.props=c;var l=a.context,u=n.contextType;o=Qr,typeof u==`object`&&u&&(o=Ji(u));var d=n.getDerivedStateFromProps;u=typeof d==`function`||typeof a.getSnapshotBeforeUpdate==`function`,s=t.pendingProps!==s,u||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(s||l!==o)&&zs(t,a,r,o),Na=!1;var f=t.memoizedState;a.state=f,Ha(t,r,a,i),Va(),l=t.memoizedState,s||f!==l||Na?(typeof d==`function`&&(Is(t,n,d,r),l=t.memoizedState),(c=Na||Rs(t,n,c,r,f,l,o))?(u||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount()),typeof a.componentDidMount==`function`&&(t.flags|=4194308)):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=o,r=c):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!1)}else{a=t.stateNode,Fa(e,t),o=t.memoizedProps,u=Bs(n,o),a.props=u,d=t.pendingProps,f=a.context,l=n.contextType,c=Qr,typeof l==`object`&&l&&(c=Ji(l)),s=n.getDerivedStateFromProps,(l=typeof s==`function`||typeof a.getSnapshotBeforeUpdate==`function`)||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(o!==d||f!==c)&&zs(t,a,r,c),Na=!1,f=t.memoizedState,a.state=f,Ha(t,r,a,i),Va();var p=t.memoizedState;o!==d||f!==p||Na||e!==null&&e.dependencies!==null&&Ki(e.dependencies)?(typeof s==`function`&&(Is(t,n,s,r),p=t.memoizedState),(u=Na||Rs(t,n,u,r,f,p,c)||e!==null&&e.dependencies!==null&&Ki(e.dependencies))?(l||typeof a.UNSAFE_componentWillUpdate!=`function`&&typeof a.componentWillUpdate!=`function`||(typeof a.componentWillUpdate==`function`&&a.componentWillUpdate(r,p,c),typeof a.UNSAFE_componentWillUpdate==`function`&&a.UNSAFE_componentWillUpdate(r,p,c)),typeof a.componentDidUpdate==`function`&&(t.flags|=4),typeof a.getSnapshotBeforeUpdate==`function`&&(t.flags|=1024)):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=p),a.props=r,a.state=p,a.context=c,r=u):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return a=r,oc(e,t),r=(t.flags&128)!=0,a||r?(a=t.stateNode,n=r&&typeof n.getDerivedStateFromError!=`function`?null:a.render(),t.flags|=1,e!==null&&r?(t.child=ja(t,e.child,null,i),t.child=ja(t,null,n,i)):Qs(e,t,n,i),t.memoizedState=a.state,e=t.child):e=xc(e,t,i),e}function uc(e,t,n,r){return Fi(),t.flags|=256,Qs(e,t,n,r),t.child}var dc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function fc(e){return{baseLanes:e,cachePool:ma()}}function pc(e,t,n){return e=e===null?0:e.childLanes&~n,t&&(e|=Gl),e}function mc(e,t,n){var r=t.pendingProps,i=!1,o=(t.flags&128)!=0,s;if((s=o)||(s=e!==null&&e.memoizedState===null?!1:(no.current&2)!=0),s&&(i=!0,t.flags&=-129),s=(t.flags&32)!=0,t.flags&=-33,e===null){if(Di){if(i?Za(t):eo(t),(e=Ei)?(e=rf(e,ki),e=e!==null&&e.data!==`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:_i===null?null:{id:vi,overflow:yi},retryLane:536870912,hydrationErrors:null},n=si(e),n.return=t,t.child=n,Ti=t,Ei=null)):e=null,e===null)throw ji(t);return of(e)?t.lanes=32:t.lanes=536870912,null}var c=r.children;return r=r.fallback,i?(eo(t),i=t.mode,c=gc({mode:`hidden`,children:c},i),r=ai(r,i,n,null),c.return=t,r.return=t,c.sibling=r,t.child=c,r=t.child,r.memoizedState=fc(n),r.childLanes=pc(e,s,n),t.memoizedState=dc,Z(null,r)):(Za(t),hc(t,c))}var l=e.memoizedState;if(l!==null&&(c=l.dehydrated,c!==null)){if(o)t.flags&256?(Za(t),t.flags&=-257,t=_c(e,t,n)):t.memoizedState===null?(eo(t),c=r.fallback,i=t.mode,r=gc({mode:`visible`,children:r.children},i),c=ai(c,i,n,null),c.flags|=2,r.return=t,c.return=t,r.sibling=c,t.child=r,ja(t,e.child,null,n),r=t.child,r.memoizedState=fc(n),r.childLanes=pc(e,s,n),t.memoizedState=dc,t=Z(null,r)):(eo(t),t.child=e.child,t.flags|=128,t=null);else if(Za(t),of(c)){if(s=c.nextSibling&&c.nextSibling.dataset,s)var u=s.dgst;s=u,r=Error(a(419)),r.stack=``,r.digest=s,Li({value:r,source:null,stack:null}),t=_c(e,t,n)}else if(Zs||Gi(e,t,n,!1),s=(n&e.childLanes)!==0,Zs||s){if(s=Pl,s!==null&&(r=qe(s,n),r!==0&&r!==l.retryLane))throw l.retryLane=r,Yr(e,r),fu(s,e,r),Xs;af(c)||wu(),t=_c(e,t,n)}else af(c)?(t.flags|=192,t.child=e.child,t=null):(e=l.treeContext,Ei=cf(c.nextSibling),Ti=t,Di=!0,Oi=null,ki=!1,e!==null&&wi(t,e),t=hc(t,r.children),t.flags|=4096);return t}return i?(eo(t),c=r.fallback,i=t.mode,l=e.child,u=l.sibling,r=ni(l,{mode:`hidden`,children:r.children}),r.subtreeFlags=l.subtreeFlags&65011712,u===null?(c=ai(c,i,n,null),c.flags|=2):c=ni(u,c),c.return=t,r.return=t,r.sibling=c,t.child=r,Z(null,r),r=t.child,c=e.child.memoizedState,c===null?c=fc(n):(i=c.cachePool,i===null?i=ma():(l=ea._currentValue,i=i.parent===l?i:{parent:l,pool:l}),c={baseLanes:c.baseLanes|n,cachePool:i}),r.memoizedState=c,r.childLanes=pc(e,s,n),t.memoizedState=dc,Z(e.child,r)):(Za(t),n=e.child,e=n.sibling,n=ni(n,{mode:`visible`,children:r.children}),n.return=t,n.sibling=null,e!==null&&(s=t.deletions,s===null?(t.deletions=[e],t.flags|=16):s.push(e)),t.child=n,t.memoizedState=null,n)}function hc(e,t){return t=gc({mode:`visible`,children:t},e.mode),t.return=e,e.child=t}function gc(e,t){return e=ei(22,e,null,t),e.lanes=0,e}function _c(e,t,n){return ja(t,e.child,null,n),e=hc(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function vc(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Ui(e.return,t,n)}function yc(e,t,n,r,i,a){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i,treeForkCount:a}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=i,o.treeForkCount=a)}function bc(e,t,n){var r=t.pendingProps,i=r.revealOrder,a=r.tail;r=r.children;var o=no.current,s=(o&2)!=0;if(s?(o=o&1|2,t.flags|=128):o&=1,z(no,o),Qs(e,t,r,n),r=Di?mi:0,!s&&e!==null&&e.flags&128)a:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&vc(e,n,t);else if(e.tag===19)vc(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break a;for(;e.sibling===null;){if(e.return===null||e.return===t)break a;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(i){case`forwards`:for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&ro(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),yc(t,!1,i,n,a,r);break;case`backwards`:case`unstable_legacy-backwards`:for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&ro(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}yc(t,!0,n,null,a,r);break;case`together`:yc(t,!1,null,null,void 0,r);break;default:t.memoizedState=null}return t.child}function xc(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Hl|=t.lanes,(n&t.childLanes)===0)if(e!==null){if(Gi(e,t,n,!1),(n&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(a(153));if(t.child!==null){for(e=t.child,n=ni(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=ni(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function Sc(e,t){return(e.lanes&t)===0?(e=e.dependencies,!!(e!==null&&Ki(e))):!0}function Cc(e,t,n){switch(t.tag){case 3:re(t,t.stateNode.containerInfo),Vi(t,ea,e.memoizedState.cache),Fi();break;case 27:case 5:ie(t);break;case 4:re(t,t.stateNode.containerInfo);break;case 10:Vi(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,Qa(t),null;break;case 13:var r=t.memoizedState;if(r!==null)return r.dehydrated===null?(n&t.child.childLanes)===0?(Za(t),e=xc(e,t,n),e===null?null:e.sibling):mc(e,t,n):(Za(t),t.flags|=128,null);Za(t);break;case 19:var i=(e.flags&128)!=0;if(r=(n&t.childLanes)!==0,r||=(Gi(e,t,n,!1),(n&t.childLanes)!==0),i){if(r)return bc(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),z(no,no.current),r)break;return null;case 22:return t.lanes=0,tc(e,t,n,t.pendingProps);case 24:Vi(t,ea,e.memoizedState.cache)}return xc(e,t,n)}function wc(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps)Zs=!0;else{if(!Sc(e,n)&&!(t.flags&128))return Zs=!1,Cc(e,t,n);Zs=!!(e.flags&131072)}else Zs=!1,Di&&t.flags&1048576&&xi(t,mi,t.index);switch(t.lanes=0,t.tag){case 16:a:{var r=t.pendingProps;if(e=xa(t.elementType),t.type=e,typeof e==`function`)ti(e)?(r=Bs(e,r),t.tag=1,t=lc(null,t,e,r,n)):(t.tag=0,t=sc(null,t,e,r,n));else{if(e!=null){var i=e.$$typeof;if(i===S){t.tag=11,t=$s(null,t,e,r,n);break a}else if(i===T){t.tag=14,t=X(null,t,e,r,n);break a}}throw t=M(e)||e,Error(a(306,t,``))}}return t;case 0:return sc(e,t,t.type,t.pendingProps,n);case 1:return r=t.type,i=Bs(r,t.pendingProps),lc(e,t,r,i,n);case 3:a:{if(re(t,t.stateNode.containerInfo),e===null)throw Error(a(387));r=t.pendingProps;var o=t.memoizedState;i=o.element,Fa(e,t),Ha(t,r,null,n);var s=t.memoizedState;if(r=s.cache,Vi(t,ea,r),r!==o.cache&&Wi(t,[ea],n,!0),Va(),r=s.element,o.isDehydrated)if(o={element:r,isDehydrated:!1,cache:s.cache},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){t=uc(e,t,r,n);break a}else if(r!==i){i=ui(Error(a(424)),t),Li(i),t=uc(e,t,r,n);break a}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName===`HTML`?e.ownerDocument.body:e}for(Ei=cf(e.firstChild),Ti=t,Di=!0,Oi=null,ki=!0,n=Ma(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling}else{if(Fi(),r===i){t=xc(e,t,n);break a}Qs(e,t,r,n)}t=t.child}return t;case 26:return oc(e,t),e===null?(n=kf(t.type,null,t.pendingProps,null))?t.memoizedState=n:Di||(n=t.type,e=t.pendingProps,r=Bd(H.current).createElement(n),r[$e]=t,r[et]=e,Pd(r,n,e),ft(r),t.stateNode=r):t.memoizedState=kf(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return ie(t),e===null&&Di&&(r=t.stateNode=ff(t.type,t.pendingProps,H.current),Ti=t,ki=!0,i=Ei,Zd(t.type)?(lf=i,Ei=cf(r.firstChild)):Ei=i),Qs(e,t,t.pendingProps.children,n),oc(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&Di&&((i=r=Ei)&&(r=tf(r,t.type,t.pendingProps,ki),r===null?i=!1:(t.stateNode=r,Ti=t,Ei=cf(r.firstChild),ki=!1,i=!0)),i||ji(t)),ie(t),i=t.type,o=t.pendingProps,s=e===null?null:e.memoizedProps,r=o.children,Ud(i,o)?r=null:s!==null&&Ud(i,s)&&(t.flags|=32),t.memoizedState!==null&&(i=_o(e,t,bo,null,null,n),Qf._currentValue=i),oc(e,t),Qs(e,t,r,n),t.child;case 6:return e===null&&Di&&((e=n=Ei)&&(n=nf(n,t.pendingProps,ki),n===null?e=!1:(t.stateNode=n,Ti=t,Ei=null,e=!0)),e||ji(t)),null;case 13:return mc(e,t,n);case 4:return re(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=ja(t,null,r,n):Qs(e,t,r,n),t.child;case 11:return $s(e,t,t.type,t.pendingProps,n);case 7:return Qs(e,t,t.pendingProps,n),t.child;case 8:return Qs(e,t,t.pendingProps.children,n),t.child;case 12:return Qs(e,t,t.pendingProps.children,n),t.child;case 10:return r=t.pendingProps,Vi(t,t.type,r.value),Qs(e,t,r.children,n),t.child;case 9:return i=t.type._context,r=t.pendingProps.children,qi(t),i=Ji(i),r=r(i),t.flags|=1,Qs(e,t,r,n),t.child;case 14:return X(e,t,t.type,t.pendingProps,n);case 15:return ec(e,t,t.type,t.pendingProps,n);case 19:return bc(e,t,n);case 31:return ac(e,t,n);case 22:return tc(e,t,n,t.pendingProps);case 24:return qi(t),r=Ji(ea),e===null?(i=fa(),i===null&&(i=Pl,o=ta(),i.pooledCache=o,o.refCount++,o!==null&&(i.pooledCacheLanes|=n),i=o),t.memoizedState={parent:r,cache:i},Pa(t),Vi(t,ea,i)):((e.lanes&n)!==0&&(Fa(e,t),Ha(t,null,null,n),Va()),i=e.memoizedState,o=t.memoizedState,i.parent===r?(r=o.cache,Vi(t,ea,r),r!==i.cache&&Wi(t,[ea],n,!0)):(i={parent:r,cache:r},t.memoizedState=i,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=i),Vi(t,ea,r))),Qs(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(a(156,t.tag))}function Tc(e){e.flags|=4}function Ec(e,t,n,r,i){if((t=(e.mode&32)!=0)&&(t=!1),t){if(e.flags|=16777216,(i&335544128)===i)if(e.stateNode.complete)e.flags|=8192;else if(xu())e.flags|=8192;else throw Sa=va,ga}else e.flags&=-16777217}function Dc(e,t){if(t.type!==`stylesheet`||t.state.loading&4)e.flags&=-16777217;else if(e.flags|=16777216,!Wf(t))if(xu())e.flags|=8192;else throw Sa=va,ga}function Oc(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag===22?536870912:Ve(),e.lanes|=t,Kl|=t)}function kc(e,t){if(!Di)switch(e.tailMode){case`hidden`:t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case`collapsed`:n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function Ac(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&65011712,r|=i.flags&65011712,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function jc(e,t,n){var r=t.pendingProps;switch(Ci(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Ac(t),null;case 1:return Ac(t),null;case 3:return n=t.stateNode,r=null,e!==null&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),Hi(ea),U(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(e===null||e.child===null)&&(Pi(t)?Tc(t):e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Ii())),Ac(t),null;case 26:var i=t.type,o=t.memoizedState;return e===null?(Tc(t),o===null?(Ac(t),Ec(t,i,null,r,n)):(Ac(t),Dc(t,o))):o?o===e.memoizedState?(Ac(t),t.flags&=-16777217):(Tc(t),Ac(t),Dc(t,o)):(e=e.memoizedProps,e!==r&&Tc(t),Ac(t),Ec(t,i,e,r,n)),null;case 27:if(ae(t),n=H.current,i=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Tc(t);else{if(!r){if(t.stateNode===null)throw Error(a(166));return Ac(t),null}e=B.current,Pi(t)?Mi(t,e):(e=ff(i,r,n),t.stateNode=e,Tc(t))}return Ac(t),null;case 5:if(ae(t),i=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Tc(t);else{if(!r){if(t.stateNode===null)throw Error(a(166));return Ac(t),null}if(o=B.current,Pi(t))Mi(t,o);else{var s=Bd(H.current);switch(o){case 1:o=s.createElementNS(`http://www.w3.org/2000/svg`,i);break;case 2:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,i);break;default:switch(i){case`svg`:o=s.createElementNS(`http://www.w3.org/2000/svg`,i);break;case`math`:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,i);break;case`script`:o=s.createElement(`div`),o.innerHTML=`<script><\/script>`,o=o.removeChild(o.firstChild);break;case`select`:o=typeof r.is==`string`?s.createElement(`select`,{is:r.is}):s.createElement(`select`),r.multiple?o.multiple=!0:r.size&&(o.size=r.size);break;default:o=typeof r.is==`string`?s.createElement(i,{is:r.is}):s.createElement(i)}}o[$e]=t,o[et]=r;a:for(s=t.child;s!==null;){if(s.tag===5||s.tag===6)o.appendChild(s.stateNode);else if(s.tag!==4&&s.tag!==27&&s.child!==null){s.child.return=s,s=s.child;continue}if(s===t)break a;for(;s.sibling===null;){if(s.return===null||s.return===t)break a;s=s.return}s.sibling.return=s.return,s=s.sibling}t.stateNode=o;a:switch(Pd(o,i,r),i){case`button`:case`input`:case`select`:case`textarea`:r=!!r.autoFocus;break a;case`img`:r=!0;break a;default:r=!1}r&&Tc(t)}}return Ac(t),Ec(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&Tc(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(a(166));if(e=H.current,Pi(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,i=Ti,i!==null)switch(i.tag){case 27:case 5:r=i.memoizedProps}e[$e]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||jd(e.nodeValue,n)),e||ji(t,!0)}else e=Bd(e).createTextNode(r),e[$e]=t,t.stateNode=e}return Ac(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=Pi(t),n!==null){if(e===null){if(!r)throw Error(a(318));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(a(557));e[$e]=t}else Fi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Ac(t),e=!1}else n=Ii(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(to(t),t):(to(t),null);if(t.flags&128)throw Error(a(558))}return Ac(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(i=Pi(t),r!==null&&r.dehydrated!==null){if(e===null){if(!i)throw Error(a(318));if(i=t.memoizedState,i=i===null?null:i.dehydrated,!i)throw Error(a(317));i[$e]=t}else Fi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Ac(t),i=!1}else i=Ii(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=i),i=!0;if(!i)return t.flags&256?(to(t),t):(to(t),null)}return to(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,i=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(i=r.alternate.memoizedState.cachePool.pool),o=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(o=r.memoizedState.cachePool.pool),o!==i&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Oc(t,t.updateQueue),Ac(t),null);case 4:return U(),e===null&&xd(t.stateNode.containerInfo),Ac(t),null;case 10:return Hi(t.type),Ac(t),null;case 19:if(R(no),r=t.memoizedState,r===null)return Ac(t),null;if(i=(t.flags&128)!=0,o=r.rendering,o===null)if(i)kc(r,!1);else{if(Vl!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=ro(e),o!==null){for(t.flags|=128,kc(r,!1),e=o.updateQueue,t.updateQueue=e,Oc(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)ri(n,e),n=n.sibling;return z(no,no.current&1|2),Di&&bi(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&ye()>Ql&&(t.flags|=128,i=!0,kc(r,!1),t.lanes=4194304)}else{if(!i)if(e=ro(o),e!==null){if(t.flags|=128,i=!0,e=e.updateQueue,t.updateQueue=e,Oc(t,e),kc(r,!0),r.tail===null&&r.tailMode===`hidden`&&!o.alternate&&!Di)return Ac(t),null}else 2*ye()-r.renderingStartTime>Ql&&n!==536870912&&(t.flags|=128,i=!0,kc(r,!1),t.lanes=4194304);r.isBackwards?(o.sibling=t.child,t.child=o):(e=r.last,e===null?t.child=o:e.sibling=o,r.last=o)}return r.tail===null?(Ac(t),null):(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=ye(),e.sibling=null,n=no.current,z(no,i?n&1|2:n&1),Di&&bi(t,r.treeForkCount),e);case 22:case 23:return to(t),Ya(),r=t.memoizedState!==null,e===null?r&&(t.flags|=8192):e.memoizedState!==null!==r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(Ac(t),t.subtreeFlags&6&&(t.flags|=8192)):Ac(t),n=t.updateQueue,n!==null&&Oc(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),r=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),e!==null&&R(da),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),Hi(ea),Ac(t),null;case 25:return null;case 30:return null}throw Error(a(156,t.tag))}function Mc(e,t){switch(Ci(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Hi(ea),U(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return ae(t),null;case 31:if(t.memoizedState!==null){if(to(t),t.alternate===null)throw Error(a(340));Fi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(to(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(a(340));Fi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return R(no),null;case 4:return U(),null;case 10:return Hi(t.type),null;case 22:case 23:return to(t),Ya(),e!==null&&R(da),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Hi(ea),null;case 25:return null;default:return null}}function Nc(e,t){switch(Ci(t),t.tag){case 3:Hi(ea),U();break;case 26:case 27:case 5:ae(t);break;case 4:U();break;case 31:t.memoizedState!==null&&to(t);break;case 13:to(t);break;case 19:R(no);break;case 10:Hi(t.type);break;case 22:case 23:to(t),Ya(),e!==null&&R(da);break;case 24:Hi(ea)}}function Pc(e,t){try{var n=t.updateQueue,r=n===null?null:n.lastEffect;if(r!==null){var i=r.next;n=i;do{if((n.tag&e)===e){r=void 0;var a=n.create,o=n.inst;r=a(),o.destroy=r}n=n.next}while(n!==i)}}catch(e){Hu(t,t.return,e)}}function Fc(e,t,n){try{var r=t.updateQueue,i=r===null?null:r.lastEffect;if(i!==null){var a=i.next;r=a;do{if((r.tag&e)===e){var o=r.inst,s=o.destroy;if(s!==void 0){o.destroy=void 0,i=t;var c=n,l=s;try{l()}catch(e){Hu(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){Hu(t,t.return,e)}}function Ic(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{Wa(t,n)}catch(t){Hu(e,e.return,t)}}}function Lc(e,t,n){n.props=Bs(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){Hu(e,t,n)}}function Rc(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;case 30:r=e.stateNode;break;default:r=e.stateNode}typeof n==`function`?e.refCleanup=n(r):n.current=r}}catch(n){Hu(e,t,n)}}function zc(e,t){var n=e.ref,r=e.refCleanup;if(n!==null)if(typeof r==`function`)try{r()}catch(n){Hu(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==`function`)try{n(null)}catch(n){Hu(e,t,n)}else n.current=null}function Bc(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{a:switch(t){case`button`:case`input`:case`select`:case`textarea`:n.autoFocus&&r.focus();break a;case`img`:n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){Hu(e,e.return,t)}}function Vc(e,t,n){try{var r=e.stateNode;Fd(r,e.type,n,t),r[et]=t}catch(t){Hu(e,e.return,t)}}function Hc(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Zd(e.type)||e.tag===4}function Uc(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||Hc(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&Zd(e.type)||e.flags&2||e.child===null||e.tag===4)continue a;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Wc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n).insertBefore(e,t):(t=n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n,t.appendChild(e),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Kt));else if(r!==4&&(r===27&&Zd(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(Wc(e,t,n),e=e.sibling;e!==null;)Wc(e,t,n),e=e.sibling}function Gc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(r===27&&Zd(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(Gc(e,t,n),e=e.sibling;e!==null;)Gc(e,t,n),e=e.sibling}function Kc(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Pd(t,r,n),t[$e]=e,t[et]=n}catch(t){Hu(e,e.return,t)}}var qc=!1,Jc=!1,Yc=!1,Xc=typeof WeakSet==`function`?WeakSet:Set,Zc=null;function Qc(e,t){if(e=e.containerInfo,Rd=sp,e=G(e),K(e)){if(`selectionStart`in e)var n={start:e.selectionStart,end:e.selectionEnd};else a:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var i=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break a}var s=0,c=-1,l=-1,u=0,d=0,f=e,p=null;b:for(;;){for(var m;f!==n||i!==0&&f.nodeType!==3||(c=s+i),f!==o||r!==0&&f.nodeType!==3||(l=s+r),f.nodeType===3&&(s+=f.nodeValue.length),(m=f.firstChild)!==null;)p=f,f=m;for(;;){if(f===e)break b;if(p===n&&++u===i&&(c=s),p===o&&++d===r&&(l=s),(m=f.nextSibling)!==null)break;f=p,p=f.parentNode}f=m}n=c===-1||l===-1?null:{start:c,end:l}}else n=null}n||={start:0,end:0}}else n=null;for(zd={focusedElem:e,selectionRange:n},sp=!1,Zc=t;Zc!==null;)if(t=Zc,e=t.child,t.subtreeFlags&1028&&e!==null)e.return=t,Zc=e;else for(;Zc!==null;){switch(t=Zc,o=t.alternate,e=t.flags,t.tag){case 0:if(e&4&&(e=t.updateQueue,e=e===null?null:e.events,e!==null))for(n=0;n<e.length;n++)i=e[n],i.ref.impl=i.nextImpl;break;case 11:case 15:break;case 1:if(e&1024&&o!==null){e=void 0,n=t,i=o.memoizedProps,o=o.memoizedState,r=n.stateNode;try{var h=Bs(n.type,i);e=r.getSnapshotBeforeUpdate(h,o),r.__reactInternalSnapshotBeforeUpdate=e}catch(e){Hu(n,n.return,e)}}break;case 3:if(e&1024){if(e=t.stateNode.containerInfo,n=e.nodeType,n===9)ef(e);else if(n===1)switch(e.nodeName){case`HEAD`:case`HTML`:case`BODY`:ef(e);break;default:e.textContent=``}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if(e&1024)throw Error(a(163))}if(e=t.sibling,e!==null){e.return=t.return,Zc=e;break}Zc=t.return}}function $c(e,t,n){var r=n.flags;switch(n.tag){case 0:case 11:case 15:ml(e,n),r&4&&Pc(5,n);break;case 1:if(ml(e,n),r&4)if(e=n.stateNode,t===null)try{e.componentDidMount()}catch(e){Hu(n,n.return,e)}else{var i=Bs(n.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(i,t,e.__reactInternalSnapshotBeforeUpdate)}catch(e){Hu(n,n.return,e)}}r&64&&Ic(n),r&512&&Rc(n,n.return);break;case 3:if(ml(e,n),r&64&&(e=n.updateQueue,e!==null)){if(t=null,n.child!==null)switch(n.child.tag){case 27:case 5:t=n.child.stateNode;break;case 1:t=n.child.stateNode}try{Wa(e,t)}catch(e){Hu(n,n.return,e)}}break;case 27:t===null&&r&4&&Kc(n);case 26:case 5:ml(e,n),t===null&&r&4&&Bc(n),r&512&&Rc(n,n.return);break;case 12:ml(e,n);break;case 31:ml(e,n),r&4&&al(e,n);break;case 13:ml(e,n),r&4&&ol(e,n),r&64&&(e=n.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(n=Ku.bind(null,n),sf(e,n))));break;case 22:if(r=n.memoizedState!==null||qc,!r){t=t!==null&&t.memoizedState!==null||Jc,i=qc;var a=Jc;qc=r,(Jc=t)&&!a?gl(e,n,(n.subtreeFlags&8772)!=0):ml(e,n),qc=i,Jc=a}break;case 30:break;default:ml(e,n)}}function el(e){var t=e.alternate;t!==null&&(e.alternate=null,el(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&st(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var tl=null,nl=!1;function rl(e,t,n){for(n=n.child;n!==null;)il(e,t,n),n=n.sibling}function il(e,t,n){if(Oe&&typeof Oe.onCommitFiberUnmount==`function`)try{Oe.onCommitFiberUnmount(De,n)}catch{}switch(n.tag){case 26:Jc||zc(n,t),rl(e,t,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:Jc||zc(n,t);var r=tl,i=nl;Zd(n.type)&&(tl=n.stateNode,nl=!1),rl(e,t,n),pf(n.stateNode),tl=r,nl=i;break;case 5:Jc||zc(n,t);case 6:if(r=tl,i=nl,tl=null,rl(e,t,n),tl=r,nl=i,tl!==null)if(nl)try{(tl.nodeType===9?tl.body:tl.nodeName===`HTML`?tl.ownerDocument.body:tl).removeChild(n.stateNode)}catch(e){Hu(n,t,e)}else try{tl.removeChild(n.stateNode)}catch(e){Hu(n,t,e)}break;case 18:tl!==null&&(nl?(e=tl,Qd(e.nodeType===9?e.body:e.nodeName===`HTML`?e.ownerDocument.body:e,n.stateNode),Np(e)):Qd(tl,n.stateNode));break;case 4:r=tl,i=nl,tl=n.stateNode.containerInfo,nl=!0,rl(e,t,n),tl=r,nl=i;break;case 0:case 11:case 14:case 15:Fc(2,n,t),Jc||Fc(4,n,t),rl(e,t,n);break;case 1:Jc||(zc(n,t),r=n.stateNode,typeof r.componentWillUnmount==`function`&&Lc(n,t,r)),rl(e,t,n);break;case 21:rl(e,t,n);break;case 22:Jc=(r=Jc)||n.memoizedState!==null,rl(e,t,n),Jc=r;break;default:rl(e,t,n)}}function al(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Np(e)}catch(e){Hu(t,t.return,e)}}}function ol(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Np(e)}catch(e){Hu(t,t.return,e)}}function sl(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new Xc),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new Xc),t;default:throw Error(a(435,e.tag))}}function cl(e,t){var n=sl(e);t.forEach(function(t){if(!n.has(t)){n.add(t);var r=qu.bind(null,e,t);t.then(r,r)}})}function ll(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var i=n[r],o=e,s=t,c=s;a:for(;c!==null;){switch(c.tag){case 27:if(Zd(c.type)){tl=c.stateNode,nl=!1;break a}break;case 5:tl=c.stateNode,nl=!1;break a;case 3:case 4:tl=c.stateNode.containerInfo,nl=!0;break a}c=c.return}if(tl===null)throw Error(a(160));il(o,s,i),tl=null,nl=!1,o=i.alternate,o!==null&&(o.return=null),i.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)dl(t,e),t=t.sibling}var ul=null;function dl(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:ll(t,e),fl(e),r&4&&(Fc(3,e,e.return),Pc(3,e),Fc(5,e,e.return));break;case 1:ll(t,e),fl(e),r&512&&(Jc||n===null||zc(n,n.return)),r&64&&qc&&(e=e.updateQueue,e!==null&&(r=e.callbacks,r!==null&&(n=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=n===null?r:n.concat(r))));break;case 26:var i=ul;if(ll(t,e),fl(e),r&512&&(Jc||n===null||zc(n,n.return)),r&4){var o=n===null?null:n.memoizedState;if(r=e.memoizedState,n===null)if(r===null)if(e.stateNode===null){a:{r=e.type,n=e.memoizedProps,i=i.ownerDocument||i;b:switch(r){case`title`:o=i.getElementsByTagName(`title`)[0],(!o||o[ot]||o[$e]||o.namespaceURI===`http://www.w3.org/2000/svg`||o.hasAttribute(`itemprop`))&&(o=i.createElement(r),i.head.insertBefore(o,i.querySelector(`head > title`))),Pd(o,r,n),o[$e]=e,ft(o),r=o;break a;case`link`:var s=Vf(`link`,`href`,i).get(r+(n.href||``));if(s){for(var c=0;c<s.length;c++)if(o=s[c],o.getAttribute(`href`)===(n.href==null||n.href===``?null:n.href)&&o.getAttribute(`rel`)===(n.rel==null?null:n.rel)&&o.getAttribute(`title`)===(n.title==null?null:n.title)&&o.getAttribute(`crossorigin`)===(n.crossOrigin==null?null:n.crossOrigin)){s.splice(c,1);break b}}o=i.createElement(r),Pd(o,r,n),i.head.appendChild(o);break;case`meta`:if(s=Vf(`meta`,`content`,i).get(r+(n.content||``))){for(c=0;c<s.length;c++)if(o=s[c],o.getAttribute(`content`)===(n.content==null?null:``+n.content)&&o.getAttribute(`name`)===(n.name==null?null:n.name)&&o.getAttribute(`property`)===(n.property==null?null:n.property)&&o.getAttribute(`http-equiv`)===(n.httpEquiv==null?null:n.httpEquiv)&&o.getAttribute(`charset`)===(n.charSet==null?null:n.charSet)){s.splice(c,1);break b}}o=i.createElement(r),Pd(o,r,n),i.head.appendChild(o);break;default:throw Error(a(468,r))}o[$e]=e,ft(o),r=o}e.stateNode=r}else Hf(i,e.type,e.stateNode);else e.stateNode=If(i,r,e.memoizedProps);else o===r?r===null&&e.stateNode!==null&&Vc(e,e.memoizedProps,n.memoizedProps):(o===null?n.stateNode!==null&&(n=n.stateNode,n.parentNode.removeChild(n)):o.count--,r===null?Hf(i,e.type,e.stateNode):If(i,r,e.memoizedProps))}break;case 27:ll(t,e),fl(e),r&512&&(Jc||n===null||zc(n,n.return)),n!==null&&r&4&&Vc(e,e.memoizedProps,n.memoizedProps);break;case 5:if(ll(t,e),fl(e),r&512&&(Jc||n===null||zc(n,n.return)),e.flags&32){i=e.stateNode;try{Rt(i,``)}catch(t){Hu(e,e.return,t)}}r&4&&e.stateNode!=null&&(i=e.memoizedProps,Vc(e,i,n===null?i:n.memoizedProps)),r&1024&&(Yc=!0);break;case 6:if(ll(t,e),fl(e),r&4){if(e.stateNode===null)throw Error(a(162));r=e.memoizedProps,n=e.stateNode;try{n.nodeValue=r}catch(t){Hu(e,e.return,t)}}break;case 3:if(Bf=null,i=ul,ul=gf(t.containerInfo),ll(t,e),ul=i,fl(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Np(t.containerInfo)}catch(t){Hu(e,e.return,t)}Yc&&(Yc=!1,pl(e));break;case 4:r=ul,ul=gf(e.stateNode.containerInfo),ll(t,e),fl(e),ul=r;break;case 12:ll(t,e),fl(e);break;case 31:ll(t,e),fl(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,cl(e,r)));break;case 13:ll(t,e),fl(e),e.child.flags&8192&&e.memoizedState!==null!=(n!==null&&n.memoizedState!==null)&&(Xl=ye()),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,cl(e,r)));break;case 22:i=e.memoizedState!==null;var l=n!==null&&n.memoizedState!==null,u=qc,d=Jc;if(qc=u||i,Jc=d||l,ll(t,e),Jc=d,qc=u,fl(e),r&8192)a:for(t=e.stateNode,t._visibility=i?t._visibility&-2:t._visibility|1,i&&(n===null||l||qc||Jc||hl(e)),n=null,t=e;;){if(t.tag===5||t.tag===26){if(n===null){l=n=t;try{if(o=l.stateNode,i)s=o.style,typeof s.setProperty==`function`?s.setProperty(`display`,`none`,`important`):s.display=`none`;else{c=l.stateNode;var f=l.memoizedProps.style,p=f!=null&&f.hasOwnProperty(`display`)?f.display:null;c.style.display=p==null||typeof p==`boolean`?``:(``+p).trim()}}catch(e){Hu(l,l.return,e)}}}else if(t.tag===6){if(n===null){l=t;try{l.stateNode.nodeValue=i?``:l.memoizedProps}catch(e){Hu(l,l.return,e)}}}else if(t.tag===18){if(n===null){l=t;try{var m=l.stateNode;i?$d(m,!0):$d(l.stateNode,!1)}catch(e){Hu(l,l.return,e)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break a;for(;t.sibling===null;){if(t.return===null||t.return===e)break a;n===t&&(n=null),t=t.return}n===t&&(n=null),t.sibling.return=t.return,t=t.sibling}r&4&&(r=e.updateQueue,r!==null&&(n=r.retryQueue,n!==null&&(r.retryQueue=null,cl(e,n))));break;case 19:ll(t,e),fl(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,cl(e,r)));break;case 30:break;case 21:break;default:ll(t,e),fl(e)}}function fl(e){var t=e.flags;if(t&2){try{for(var n,r=e.return;r!==null;){if(Hc(r)){n=r;break}r=r.return}if(n==null)throw Error(a(160));switch(n.tag){case 27:var i=n.stateNode;Gc(e,Uc(e),i);break;case 5:var o=n.stateNode;n.flags&32&&(Rt(o,``),n.flags&=-33),Gc(e,Uc(e),o);break;case 3:case 4:var s=n.stateNode.containerInfo;Wc(e,Uc(e),s);break;default:throw Error(a(161))}}catch(t){Hu(e,e.return,t)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function pl(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;pl(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function ml(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)$c(e,t.alternate,t),t=t.sibling}function hl(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:Fc(4,t,t.return),hl(t);break;case 1:zc(t,t.return);var n=t.stateNode;typeof n.componentWillUnmount==`function`&&Lc(t,t.return,n),hl(t);break;case 27:pf(t.stateNode);case 26:case 5:zc(t,t.return),hl(t);break;case 22:t.memoizedState===null&&hl(t);break;case 30:hl(t);break;default:hl(t)}e=e.sibling}}function gl(e,t,n){for(n&&=(t.subtreeFlags&8772)!=0,t=t.child;t!==null;){var r=t.alternate,i=e,a=t,o=a.flags;switch(a.tag){case 0:case 11:case 15:gl(i,a,n),Pc(4,a);break;case 1:if(gl(i,a,n),r=a,i=r.stateNode,typeof i.componentDidMount==`function`)try{i.componentDidMount()}catch(e){Hu(r,r.return,e)}if(r=a,i=r.updateQueue,i!==null){var s=r.stateNode;try{var c=i.shared.hiddenCallbacks;if(c!==null)for(i.shared.hiddenCallbacks=null,i=0;i<c.length;i++)Ua(c[i],s)}catch(e){Hu(r,r.return,e)}}n&&o&64&&Ic(a),Rc(a,a.return);break;case 27:Kc(a);case 26:case 5:gl(i,a,n),n&&r===null&&o&4&&Bc(a),Rc(a,a.return);break;case 12:gl(i,a,n);break;case 31:gl(i,a,n),n&&o&4&&al(i,a);break;case 13:gl(i,a,n),n&&o&4&&ol(i,a);break;case 22:a.memoizedState===null&&gl(i,a,n),Rc(a,a.return);break;case 30:break;default:gl(i,a,n)}t=t.sibling}}function _l(e,t){var n=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==n&&(e!=null&&e.refCount++,n!=null&&na(n))}function vl(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&na(e))}function yl(e,t,n,r){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)bl(e,t,n,r),t=t.sibling}function bl(e,t,n,r){var i=t.flags;switch(t.tag){case 0:case 11:case 15:yl(e,t,n,r),i&2048&&Pc(9,t);break;case 1:yl(e,t,n,r);break;case 3:yl(e,t,n,r),i&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&na(e)));break;case 12:if(i&2048){yl(e,t,n,r),e=t.stateNode;try{var a=t.memoizedProps,o=a.id,s=a.onPostCommit;typeof s==`function`&&s(o,t.alternate===null?`mount`:`update`,e.passiveEffectDuration,-0)}catch(e){Hu(t,t.return,e)}}else yl(e,t,n,r);break;case 31:yl(e,t,n,r);break;case 13:yl(e,t,n,r);break;case 23:break;case 22:a=t.stateNode,o=t.alternate,t.memoizedState===null?a._visibility&2?yl(e,t,n,r):(a._visibility|=2,xl(e,t,n,r,(t.subtreeFlags&10256)!=0||!1)):a._visibility&2?yl(e,t,n,r):Sl(e,t),i&2048&&_l(o,t);break;case 24:yl(e,t,n,r),i&2048&&vl(t.alternate,t);break;default:yl(e,t,n,r)}}function xl(e,t,n,r,i){for(i&&=(t.subtreeFlags&10256)!=0||!1,t=t.child;t!==null;){var a=e,o=t,s=n,c=r,l=o.flags;switch(o.tag){case 0:case 11:case 15:xl(a,o,s,c,i),Pc(8,o);break;case 23:break;case 22:var u=o.stateNode;o.memoizedState===null?(u._visibility|=2,xl(a,o,s,c,i)):u._visibility&2?xl(a,o,s,c,i):Sl(a,o),i&&l&2048&&_l(o.alternate,o);break;case 24:xl(a,o,s,c,i),i&&l&2048&&vl(o.alternate,o);break;default:xl(a,o,s,c,i)}t=t.sibling}}function Sl(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var n=e,r=t,i=r.flags;switch(r.tag){case 22:Sl(n,r),i&2048&&_l(r.alternate,r);break;case 24:Sl(n,r),i&2048&&vl(r.alternate,r);break;default:Sl(n,r)}t=t.sibling}}var Cl=8192;function wl(e,t,n){if(e.subtreeFlags&Cl)for(e=e.child;e!==null;)Tl(e,t,n),e=e.sibling}function Tl(e,t,n){switch(e.tag){case 26:wl(e,t,n),e.flags&Cl&&e.memoizedState!==null&&Gf(n,ul,e.memoizedState,e.memoizedProps);break;case 5:wl(e,t,n);break;case 3:case 4:var r=ul;ul=gf(e.stateNode.containerInfo),wl(e,t,n),ul=r;break;case 22:e.memoizedState===null&&(r=e.alternate,r!==null&&r.memoizedState!==null?(r=Cl,Cl=16777216,wl(e,t,n),Cl=r):wl(e,t,n));break;default:wl(e,t,n)}}function El(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Dl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];Zc=r,Al(r,e)}El(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Ol(e),e=e.sibling}function Ol(e){switch(e.tag){case 0:case 11:case 15:Dl(e),e.flags&2048&&Fc(9,e,e.return);break;case 3:Dl(e);break;case 12:Dl(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,kl(e)):Dl(e);break;default:Dl(e)}}function kl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];Zc=r,Al(r,e)}El(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:Fc(8,t,t.return),kl(t);break;case 22:n=t.stateNode,n._visibility&2&&(n._visibility&=-3,kl(t));break;default:kl(t)}e=e.sibling}}function Al(e,t){for(;Zc!==null;){var n=Zc;switch(n.tag){case 0:case 11:case 15:Fc(8,n,t);break;case 23:case 22:if(n.memoizedState!==null&&n.memoizedState.cachePool!==null){var r=n.memoizedState.cachePool.pool;r!=null&&r.refCount++}break;case 24:na(n.memoizedState.cache)}if(r=n.child,r!==null)r.return=n,Zc=r;else a:for(n=e;Zc!==null;){r=Zc;var i=r.sibling,a=r.return;if(el(r),r===n){Zc=null;break a}if(i!==null){i.return=a,Zc=i;break a}Zc=a}}}var jl={getCacheForType:function(e){var t=Ji(ea),n=t.data.get(e);return n===void 0&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return Ji(ea).controller.signal}},Ml=typeof WeakMap==`function`?WeakMap:Map,Nl=0,Pl=null,Fl=null,Il=0,Ll=0,Q=null,Rl=!1,$=!1,zl=!1,Bl=0,Vl=0,Hl=0,Ul=0,Wl=0,Gl=0,Kl=0,ql=null,Jl=null,Yl=!1,Xl=0,Zl=0,Ql=1/0,$l=null,eu=null,tu=0,nu=null,ru=null,iu=0,au=0,ou=null,su=null,cu=0,lu=null;function uu(){return Nl&2&&Il!==0?Il&-Il:P.T===null?Xe():ld()}function du(){if(Gl===0)if(!(Il&536870912)||Di){var e=Fe;Fe<<=1,!(Fe&3932160)&&(Fe=262144),Gl=e}else Gl=536870912;return e=Xa.current,e!==null&&(e.flags|=32),Gl}function fu(e,t,n){(e===Pl&&(Ll===2||Ll===9)||e.cancelPendingCommit!==null)&&(yu(e,0),gu(e,Il,Gl,!1)),Ue(e,n),(!(Nl&2)||e!==Pl)&&(e===Pl&&(!(Nl&2)&&(Ul|=n),Vl===4&&gu(e,Il,Gl,!1)),td(e))}function pu(e,t,n){if(Nl&6)throw Error(a(327));var r=!n&&(t&127)==0&&(t&e.expiredLanes)===0||ze(e,t),i=r?Du(e,t):Tu(e,t,!0),o=r;do{if(i===0){$&&!r&&gu(e,t,0,!1);break}else{if(n=e.current.alternate,o&&!hu(n)){i=Tu(e,t,!1),o=!1;continue}if(i===2){if(o=t,e.errorRecoveryDisabledLanes&o)var s=0;else s=e.pendingLanes&-536870913,s=s===0?s&536870912?536870912:0:s;if(s!==0){t=s;a:{var c=e;i=ql;var l=c.current.memoizedState.isDehydrated;if(l&&(yu(c,s).flags|=256),s=Tu(c,s,!1),s!==2){if(zl&&!l){c.errorRecoveryDisabledLanes|=o,Ul|=o,i=4;break a}o=Jl,Jl=i,o!==null&&(Jl===null?Jl=o:Jl.push.apply(Jl,o))}i=s}if(o=!1,i!==2)continue}}if(i===1){yu(e,0),gu(e,t,0,!0);break}a:{switch(r=e,o=i,o){case 0:case 1:throw Error(a(345));case 4:if((t&4194048)!==t)break;case 6:gu(r,t,Gl,!Rl);break a;case 2:Jl=null;break;case 3:case 5:break;default:throw Error(a(329))}if((t&62914560)===t&&(i=Xl+300-ye(),10<i)){if(gu(r,t,Gl,!Rl),Re(r,0,!0)!==0)break a;iu=t,r.timeoutHandle=Kd(mu.bind(null,r,n,Jl,$l,Yl,t,Gl,Ul,Kl,Rl,o,`Throttled`,-0,0),i);break a}mu(r,n,Jl,$l,Yl,t,Gl,Ul,Kl,Rl,o,null,-0,0)}}break}while(1);td(e)}function mu(e,t,n,r,i,a,o,s,c,l,u,d,f,p){if(e.timeoutHandle=-1,d=t.subtreeFlags,d&8192||(d&16785408)==16785408){d={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Kt},Tl(t,a,d);var m=(a&62914560)===a?Xl-ye():(a&4194048)===a?Zl-ye():0;if(m=qf(d,m),m!==null){iu=a,e.cancelPendingCommit=m(Pu.bind(null,e,t,a,n,r,i,o,s,c,u,d,null,f,p)),gu(e,a,o,!l);return}}Pu(e,t,a,n,r,i,o,s,c)}function hu(e){for(var t=e;;){var n=t.tag;if((n===0||n===11||n===15)&&t.flags&16384&&(n=t.updateQueue,n!==null&&(n=n.stores,n!==null)))for(var r=0;r<n.length;r++){var i=n[r],a=i.getSnapshot;i=i.value;try{if(!gr(a(),i))return!1}catch{return!1}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function gu(e,t,n,r){t&=~Wl,t&=~Ul,e.suspendedLanes|=t,e.pingedLanes&=~t,r&&(e.warmLanes|=t),r=e.expirationTimes;for(var i=t;0<i;){var a=31-Ae(i),o=1<<a;r[a]=-1,i&=~o}n!==0&&Ge(e,n,t)}function _u(){return Nl&6?!0:(nd(0,!1),!1)}function vu(){if(Fl!==null){if(Ll===0)var e=Fl.return;else e=Fl,Bi=zi=null,Co(e),Ta=null,Ea=0,e=Fl;for(;e!==null;)Nc(e.alternate,e),e=e.return;Fl=null}}function yu(e,t){var n=e.timeoutHandle;n!==-1&&(e.timeoutHandle=-1,qd(n)),n=e.cancelPendingCommit,n!==null&&(e.cancelPendingCommit=null,n()),iu=0,vu(),Pl=e,Fl=n=ni(e.current,null),Il=t,Ll=0,Q=null,Rl=!1,$=ze(e,t),zl=!1,Kl=Gl=Wl=Ul=Hl=Vl=0,Jl=ql=null,Yl=!1,t&8&&(t|=t&32);var r=e.entangledLanes;if(r!==0)for(e=e.entanglements,r&=t;0<r;){var i=31-Ae(r),a=1<<i;t|=e[i],r&=~a}return Bl=t,Kr(),n}function bu(e,t){J=null,P.H=Ms,t===ha||t===_a?(t=Ca(),Ll=3):t===ga?(t=Ca(),Ll=4):Ll=t===Xs?8:typeof t==`object`&&t&&typeof t.then==`function`?6:1,Q=t,Fl===null&&(Vl=1,Ws(e,ui(t,e.current)))}function xu(){var e=Xa.current;return e===null?!0:(Il&4194048)===Il?q===null:(Il&62914560)===Il||Il&536870912?e===q:!1}function Su(){var e=P.H;return P.H=Ms,e===null?Ms:e}function Cu(){var e=P.A;return P.A=jl,e}function wu(){Vl=4,Rl||(Il&4194048)!==Il&&Xa.current!==null||($=!0),!(Hl&134217727)&&!(Ul&134217727)||Pl===null||gu(Pl,Il,Gl,!1)}function Tu(e,t,n){var r=Nl;Nl|=2;var i=Su(),a=Cu();(Pl!==e||Il!==t)&&($l=null,yu(e,t)),t=!1;var o=Vl;a:do try{if(Ll!==0&&Fl!==null){var s=Fl,c=Q;switch(Ll){case 8:vu(),o=6;break a;case 3:case 2:case 9:case 6:Xa.current===null&&(t=!0);var l=Ll;if(Ll=0,Q=null,ju(e,s,c,l),n&&$){o=0;break a}break;default:l=Ll,Ll=0,Q=null,ju(e,s,c,l)}}Eu(),o=Vl;break}catch(t){bu(e,t)}while(1);return t&&e.shellSuspendCounter++,Bi=zi=null,Nl=r,P.H=i,P.A=a,Fl===null&&(Pl=null,Il=0,Kr()),o}function Eu(){for(;Fl!==null;)ku(Fl)}function Du(e,t){var n=Nl;Nl|=2;var r=Su(),i=Cu();Pl!==e||Il!==t?($l=null,Ql=ye()+500,yu(e,t)):$=ze(e,t);a:do try{if(Ll!==0&&Fl!==null){t=Fl;var o=Q;b:switch(Ll){case 1:Ll=0,Q=null,ju(e,t,o,1);break;case 2:case 9:if(ya(o)){Ll=0,Q=null,Au(t);break}t=function(){Ll!==2&&Ll!==9||Pl!==e||(Ll=7),td(e)},o.then(t,t);break a;case 3:Ll=7;break a;case 4:Ll=5;break a;case 7:ya(o)?(Ll=0,Q=null,Au(t)):(Ll=0,Q=null,ju(e,t,o,7));break;case 5:var s=null;switch(Fl.tag){case 26:s=Fl.memoizedState;case 5:case 27:var c=Fl;if(s?Wf(s):c.stateNode.complete){Ll=0,Q=null;var l=c.sibling;if(l!==null)Fl=l;else{var u=c.return;u===null?Fl=null:(Fl=u,Mu(u))}break b}}Ll=0,Q=null,ju(e,t,o,5);break;case 6:Ll=0,Q=null,ju(e,t,o,6);break;case 8:vu(),Vl=6;break a;default:throw Error(a(462))}}Ou();break}catch(t){bu(e,t)}while(1);return Bi=zi=null,P.H=r,P.A=i,Nl=n,Fl===null?(Pl=null,Il=0,Kr(),Vl):0}function Ou(){for(;Fl!==null&&!_e();)ku(Fl)}function ku(e){var t=wc(e.alternate,e,Bl);e.memoizedProps=e.pendingProps,t===null?Mu(e):Fl=t}function Au(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=cc(n,t,t.pendingProps,t.type,void 0,Il);break;case 11:t=cc(n,t,t.pendingProps,t.type.render,t.ref,Il);break;case 5:Co(t);default:Nc(n,t),t=Fl=ri(t,Bl),t=wc(n,t,Bl)}e.memoizedProps=e.pendingProps,t===null?Mu(e):Fl=t}function ju(e,t,n,r){Bi=zi=null,Co(t),Ta=null,Ea=0;var i=t.return;try{if(Ys(e,i,t,n,Il)){Vl=1,Ws(e,ui(n,e.current)),Fl=null;return}}catch(t){if(i!==null)throw Fl=i,t;Vl=1,Ws(e,ui(n,e.current)),Fl=null;return}t.flags&32768?(Di||r===1?e=!0:$||Il&536870912?e=!1:(Rl=e=!0,(r===2||r===9||r===3||r===6)&&(r=Xa.current,r!==null&&r.tag===13&&(r.flags|=16384))),Nu(t,e)):Mu(t)}function Mu(e){var t=e;do{if(t.flags&32768){Nu(t,Rl);return}e=t.return;var n=jc(t.alternate,t,Bl);if(n!==null){Fl=n;return}if(t=t.sibling,t!==null){Fl=t;return}Fl=t=e}while(t!==null);Vl===0&&(Vl=5)}function Nu(e,t){do{var n=Mc(e.alternate,e);if(n!==null){n.flags&=32767,Fl=n;return}if(n=e.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&(e=e.sibling,e!==null)){Fl=e;return}Fl=e=n}while(e!==null);Vl=6,Fl=null}function Pu(e,t,n,r,i,o,s,c,l){e.cancelPendingCommit=null;do zu();while(tu!==0);if(Nl&6)throw Error(a(327));if(t!==null){if(t===e.current)throw Error(a(177));if(o=t.lanes|t.childLanes,o|=Gr,We(e,n,o,s,c,l),e===Pl&&(Fl=Pl=null,Il=0),ru=t,nu=e,iu=n,au=o,ou=i,su=r,t.subtreeFlags&10256||t.flags&10256?(e.callbackNode=null,e.callbackPriority=0,Ju(Se,function(){return Bu(),null})):(e.callbackNode=null,e.callbackPriority=0),r=(t.flags&13878)!=0,t.subtreeFlags&13878||r){r=P.T,P.T=null,i=F.p,F.p=2,s=Nl,Nl|=4;try{Qc(e,t,n)}finally{Nl=s,F.p=i,P.T=r}}tu=1,Fu(),Iu(),Lu()}}function Fu(){if(tu===1){tu=0;var e=nu,t=ru,n=(t.flags&13878)!=0;if(t.subtreeFlags&13878||n){n=P.T,P.T=null;var r=F.p;F.p=2;var i=Nl;Nl|=4;try{dl(t,e);var a=zd,o=G(e.containerInfo),s=a.focusedElem,c=a.selectionRange;if(o!==s&&s&&s.ownerDocument&&br(s.ownerDocument.documentElement,s)){if(c!==null&&K(s)){var l=c.start,u=c.end;if(u===void 0&&(u=l),`selectionStart`in s)s.selectionStart=l,s.selectionEnd=Math.min(u,s.value.length);else{var d=s.ownerDocument||document,f=d&&d.defaultView||window;if(f.getSelection){var p=f.getSelection(),m=s.textContent.length,h=Math.min(c.start,m),g=c.end===void 0?h:Math.min(c.end,m);!p.extend&&h>g&&(o=g,g=h,h=o);var _=yr(s,h),v=yr(s,g);if(_&&v&&(p.rangeCount!==1||p.anchorNode!==_.node||p.anchorOffset!==_.offset||p.focusNode!==v.node||p.focusOffset!==v.offset)){var y=d.createRange();y.setStart(_.node,_.offset),p.removeAllRanges(),h>g?(p.addRange(y),p.extend(v.node,v.offset)):(y.setEnd(v.node,v.offset),p.addRange(y))}}}}for(d=[],p=s;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof s.focus==`function`&&s.focus(),s=0;s<d.length;s++){var b=d[s];b.element.scrollLeft=b.left,b.element.scrollTop=b.top}}sp=!!Rd,zd=Rd=null}finally{Nl=i,F.p=r,P.T=n}}e.current=t,tu=2}}function Iu(){if(tu===2){tu=0;var e=nu,t=ru,n=(t.flags&8772)!=0;if(t.subtreeFlags&8772||n){n=P.T,P.T=null;var r=F.p;F.p=2;var i=Nl;Nl|=4;try{$c(e,t.alternate,t)}finally{Nl=i,F.p=r,P.T=n}}tu=3}}function Lu(){if(tu===4||tu===3){tu=0,ve();var e=nu,t=ru,n=iu,r=su;t.subtreeFlags&10256||t.flags&10256?tu=5:(tu=0,ru=nu=null,Ru(e,e.pendingLanes));var i=e.pendingLanes;if(i===0&&(eu=null),Ye(n),t=t.stateNode,Oe&&typeof Oe.onCommitFiberRoot==`function`)try{Oe.onCommitFiberRoot(De,t,void 0,(t.current.flags&128)==128)}catch{}if(r!==null){t=P.T,i=F.p,F.p=2,P.T=null;try{for(var a=e.onRecoverableError,o=0;o<r.length;o++){var s=r[o];a(s.value,{componentStack:s.stack})}}finally{P.T=t,F.p=i}}iu&3&&zu(),td(e),i=e.pendingLanes,n&261930&&i&42?e===lu?cu++:(cu=0,lu=e):cu=0,nd(0,!1)}}function Ru(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,na(t)))}function zu(){return Fu(),Iu(),Lu(),Bu()}function Bu(){if(tu!==5)return!1;var e=nu,t=au;au=0;var n=Ye(iu),r=P.T,i=F.p;try{F.p=32>n?32:n,P.T=null,n=ou,ou=null;var o=nu,s=iu;if(tu=0,ru=nu=null,iu=0,Nl&6)throw Error(a(331));var c=Nl;if(Nl|=4,Ol(o.current),bl(o,o.current,s,n),Nl=c,nd(0,!1),Oe&&typeof Oe.onPostCommitFiberRoot==`function`)try{Oe.onPostCommitFiberRoot(De,o)}catch{}return!0}finally{F.p=i,P.T=r,Ru(e,t)}}function Vu(e,t,n){t=ui(n,t),t=Ks(e.stateNode,t,2),e=La(e,t,2),e!==null&&(Ue(e,2),td(e))}function Hu(e,t,n){if(e.tag===3)Vu(e,e,n);else for(;t!==null;){if(t.tag===3){Vu(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(eu===null||!eu.has(r))){e=ui(n,e),n=qs(2),r=La(t,n,2),r!==null&&(Js(n,r,t,e),Ue(r,2),td(r));break}}t=t.return}}function Uu(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Ml;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(zl=!0,i.add(n),e=Wu.bind(null,e,t,n),t.then(e,e))}function Wu(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,Pl===e&&(Il&n)===n&&(Vl===4||Vl===3&&(Il&62914560)===Il&&300>ye()-Xl?!(Nl&2)&&yu(e,0):Wl|=n,Kl===Il&&(Kl=0)),td(e)}function Gu(e,t){t===0&&(t=Ve()),e=Yr(e,t),e!==null&&(Ue(e,t),td(e))}function Ku(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Gu(e,n)}function qu(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(a(314))}r!==null&&r.delete(t),Gu(e,n)}function Ju(e,t){return he(e,t)}var Yu=null,Xu=null,Zu=!1,Qu=!1,$u=!1,ed=0;function td(e){e!==Xu&&e.next===null&&(Xu===null?Yu=Xu=e:Xu=Xu.next=e),Qu=!0,Zu||(Zu=!0,cd())}function nd(e,t){if(!$u&&Qu){$u=!0;do for(var n=!1,r=Yu;r!==null;){if(!t)if(e!==0){var i=r.pendingLanes;if(i===0)var a=0;else{var o=r.suspendedLanes,s=r.pingedLanes;a=(1<<31-Ae(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,sd(r,a))}else a=Il,a=Re(r,r===Pl?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||ze(r,a)||(n=!0,sd(r,a));r=r.next}while(n);$u=!1}}function rd(){id()}function id(){Qu=Zu=!1;var e=0;ed!==0&&Gd()&&(e=ed);for(var t=ye(),n=null,r=Yu;r!==null;){var i=r.next,a=ad(r,t);a===0?(r.next=null,n===null?Yu=i:n.next=i,i===null&&(Xu=n)):(n=r,(e!==0||a&3)&&(Qu=!0)),r=i}tu!==0&&tu!==5||nd(e,!1),ed!==0&&(ed=0)}function ad(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0<a;){var o=31-Ae(a),s=1<<o,c=i[o];c===-1?((s&n)===0||(s&r)!==0)&&(i[o]=Be(s,t)):c<=t&&(e.expiredLanes|=s),a&=~s}if(t=Pl,n=Il,n=Re(e,e===t?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r=e.callbackNode,n===0||e===t&&(Ll===2||Ll===9)||e.cancelPendingCommit!==null)return r!==null&&r!==null&&ge(r),e.callbackNode=null,e.callbackPriority=0;if(!(n&3)||ze(e,n)){if(t=n&-n,t===e.callbackPriority)return t;switch(r!==null&&ge(r),Ye(n)){case 2:case 8:n=xe;break;case 32:n=Se;break;case 268435456:n=we;break;default:n=Se}return r=od.bind(null,e),n=he(n,r),e.callbackPriority=t,e.callbackNode=n,t}return r!==null&&r!==null&&ge(r),e.callbackPriority=2,e.callbackNode=null,2}function od(e,t){if(tu!==0&&tu!==5)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(zu()&&e.callbackNode!==n)return null;var r=Il;return r=Re(e,e===Pl?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r===0?null:(pu(e,r,t),ad(e,ye()),e.callbackNode!=null&&e.callbackNode===n?od.bind(null,e):null)}function sd(e,t){if(zu())return null;pu(e,t,!0)}function cd(){Yd(function(){Nl&6?he(W,rd):id()})}function ld(){if(ed===0){var e=aa;e===0&&(e=Pe,Pe<<=1,!(Pe&261888)&&(Pe=256)),ed=e}return ed}function ud(e){return e==null||typeof e==`symbol`||typeof e==`boolean`?null:typeof e==`function`?e:Gt(``+e)}function dd(e,t){var n=t.ownerDocument.createElement(`input`);return n.name=t.name,n.value=t.value,e.id&&n.setAttribute(`form`,e.id),t.parentNode.insertBefore(n,t),e=new FormData(e),n.parentNode.removeChild(n),e}function fd(e,t,n,r,i){if(t===`submit`&&n&&n.stateNode===i){var a=ud((i[et]||null).action),o=r.submitter;o&&(t=(t=o[et]||null)?ud(t.formAction):o.getAttribute(`formAction`),t!==null&&(a=t,o=null));var s=new hn(`action`,`action`,null,r,i);e.push({event:s,listeners:[{instance:null,listener:function(){if(r.defaultPrevented){if(ed!==0){var e=o?dd(i,o):new FormData(i);vs(n,{pending:!0,data:e,method:i.method,action:a},null,e)}}else typeof a==`function`&&(s.preventDefault(),e=o?dd(i,o):new FormData(i),vs(n,{pending:!0,data:e,method:i.method,action:a},a,e))},currentTarget:i}]})}}for(var pd=0;pd<Br.length;pd++){var md=Br[pd];Vr(md.toLowerCase(),`on`+(md[0].toUpperCase()+md.slice(1)))}Vr(Mr,`onAnimationEnd`),Vr(Nr,`onAnimationIteration`),Vr(Pr,`onAnimationStart`),Vr(`dblclick`,`onDoubleClick`),Vr(`focusin`,`onFocus`),Vr(`focusout`,`onBlur`),Vr(Fr,`onTransitionRun`),Vr(Ir,`onTransitionStart`),Vr(Lr,`onTransitionCancel`),Vr(Rr,`onTransitionEnd`),gt(`onMouseEnter`,[`mouseout`,`mouseover`]),gt(`onMouseLeave`,[`mouseout`,`mouseover`]),gt(`onPointerEnter`,[`pointerout`,`pointerover`]),gt(`onPointerLeave`,[`pointerout`,`pointerover`]),ht(`onChange`,`change click focusin focusout input keydown keyup selectionchange`.split(` `)),ht(`onSelect`,`focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange`.split(` `)),ht(`onBeforeInput`,[`compositionend`,`keypress`,`textInput`,`paste`]),ht(`onCompositionEnd`,`compositionend focusout keydown keypress keyup mousedown`.split(` `)),ht(`onCompositionStart`,`compositionstart focusout keydown keypress keyup mousedown`.split(` `)),ht(`onCompositionUpdate`,`compositionupdate focusout keydown keypress keyup mousedown`.split(` `));var hd=`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(` `),gd=new Set(`beforetoggle cancel close invalid load scroll scrollend toggle`.split(` `).concat(hd));function _d(e,t){t=(t&4)!=0;for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;a:{var a=void 0;if(t)for(var o=r.length-1;0<=o;o--){var s=r[o],c=s.instance,l=s.currentTarget;if(s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){Hr(e)}i.currentTarget=null,a=c}else for(o=0;o<r.length;o++){if(s=r[o],c=s.instance,l=s.currentTarget,s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){Hr(e)}i.currentTarget=null,a=c}}}}function vd(e,t){var n=t[nt];n===void 0&&(n=t[nt]=new Set);var r=e+`__bubble`;n.has(r)||(Sd(t,e,2,!1),n.add(r))}function yd(e,t,n){var r=0;t&&(r|=4),Sd(n,e,r,t)}var bd=`_reactListening`+Math.random().toString(36).slice(2);function xd(e){if(!e[bd]){e[bd]=!0,pt.forEach(function(t){t!==`selectionchange`&&(gd.has(t)||yd(t,!1,e),yd(t,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[bd]||(t[bd]=!0,yd(`selectionchange`,!1,t))}}function Sd(e,t,n,r){switch(mp(t)){case 2:var i=cp;break;case 8:i=lp;break;default:i=up}n=i.bind(null,t,n,e),i=void 0,!nn||t!==`touchstart`&&t!==`touchmove`&&t!==`wheel`||(i=!0),r?i===void 0?e.addEventListener(t,n,!0):e.addEventListener(t,n,{capture:!0,passive:i}):i===void 0?e.addEventListener(t,n,!1):e.addEventListener(t,n,{passive:i})}function Cd(e,t,n,r,i){var a=r;if(!(t&1)&&!(t&2)&&r!==null)a:for(;;){if(r===null)return;var o=r.tag;if(o===3||o===4){var c=r.stateNode.containerInfo;if(c===i)break;if(o===4)for(o=r.return;o!==null;){var l=o.tag;if((l===3||l===4)&&o.stateNode.containerInfo===i)return;o=o.return}for(;c!==null;){if(o=ct(c),o===null)return;if(l=o.tag,l===5||l===6||l===26||l===27){r=a=o;continue a}c=c.parentNode}}r=r.return}$t(function(){var r=a,i=Jt(n),o=[];a:{var c=zr.get(e);if(c!==void 0){var l=hn,u=e;switch(e){case`keypress`:if(un(n)===0)break a;case`keydown`:case`keyup`:l=Nn;break;case`focusin`:u=`focus`,l=wn;break;case`focusout`:u=`blur`,l=wn;break;case`beforeblur`:case`afterblur`:l=wn;break;case`click`:if(n.button===2)break a;case`auxclick`:case`dblclick`:case`mousedown`:case`mousemove`:case`mouseup`:case`mouseout`:case`mouseover`:case`contextmenu`:l=Sn;break;case`drag`:case`dragend`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`dragstart`:case`drop`:l=Cn;break;case`touchcancel`:case`touchend`:case`touchmove`:case`touchstart`:l=Fn;break;case Mr:case Nr:case Pr:l=Tn;break;case Rr:l=In;break;case`scroll`:case`scrollend`:l=_n;break;case`wheel`:l=Ln;break;case`copy`:case`cut`:case`paste`:l=En;break;case`gotpointercapture`:case`lostpointercapture`:case`pointercancel`:case`pointerdown`:case`pointermove`:case`pointerout`:case`pointerover`:case`pointerup`:l=Pn;break;case`toggle`:case`beforetoggle`:l=Rn}var d=(t&4)!=0,f=!d&&(e===`scroll`||e===`scrollend`),p=d?c===null?null:c+`Capture`:c;d=[];for(var m=r,h;m!==null;){var g=m;if(h=g.stateNode,g=g.tag,g!==5&&g!==26&&g!==27||h===null||p===null||(g=en(m,p),g!=null&&d.push(wd(m,g,h))),f)break;m=m.return}0<d.length&&(c=new l(c,u,null,n,i),o.push({event:c,listeners:d}))}}if(!(t&7)){a:{if(c=e===`mouseover`||e===`pointerover`,l=e===`mouseout`||e===`pointerout`,c&&n!==qt&&(u=n.relatedTarget||n.fromElement)&&(ct(u)||u[tt]))break a;if((l||c)&&(c=i.window===i?i:(c=i.ownerDocument)?c.defaultView||c.parentWindow:window,l?(u=n.relatedTarget||n.toElement,l=r,u=u?ct(u):null,u!==null&&(f=s(u),d=u.tag,u!==f||d!==5&&d!==27&&d!==6)&&(u=null)):(l=null,u=r),l!==u)){if(d=Sn,g=`onMouseLeave`,p=`onMouseEnter`,m=`mouse`,(e===`pointerout`||e===`pointerover`)&&(d=Pn,g=`onPointerLeave`,p=`onPointerEnter`,m=`pointer`),f=l==null?c:ut(l),h=u==null?c:ut(u),c=new d(g,m+`leave`,l,n,i),c.target=f,c.relatedTarget=h,g=null,ct(i)===r&&(d=new d(p,m+`enter`,u,n,i),d.target=h,d.relatedTarget=f,g=d),f=g,l&&u)b:{for(d=Ed,p=l,m=u,h=0,g=p;g;g=d(g))h++;g=0;for(var _=m;_;_=d(_))g++;for(;0<h-g;)p=d(p),h--;for(;0<g-h;)m=d(m),g--;for(;h--;){if(p===m||m!==null&&p===m.alternate){d=p;break b}p=d(p),m=d(m)}d=null}else d=null;l!==null&&Dd(o,c,l,d,!1),u!==null&&f!==null&&Dd(o,f,u,d,!0)}}a:{if(c=r?ut(r):window,l=c.nodeName&&c.nodeName.toLowerCase(),l===`select`||l===`input`&&c.type===`file`)var v=ir;else if(Qn(c))if(ar)v=mr;else{v=fr;var y=dr}else l=c.nodeName,!l||l.toLowerCase()!==`input`||c.type!==`checkbox`&&c.type!==`radio`?r&&Ht(r.elementType)&&(v=ir):v=pr;if(v&&=v(e,r)){$n(o,v,n,i);break a}y&&y(e,c,r),e===`focusout`&&r&&c.type===`number`&&r.memoizedProps.value!=null&&Pt(c,`number`,c.value)}switch(y=r?ut(r):window,e){case`focusin`:(Qn(y)||y.contentEditable===`true`)&&(Sr=y,Cr=r,wr=null);break;case`focusout`:wr=Cr=Sr=null;break;case`mousedown`:Tr=!0;break;case`contextmenu`:case`mouseup`:case`dragend`:Tr=!1,Er(o,n,i);break;case`selectionchange`:if(xr)break;case`keydown`:case`keyup`:Er(o,n,i)}var b;if(Bn)b:{switch(e){case`compositionstart`:var x=`onCompositionStart`;break b;case`compositionend`:x=`onCompositionEnd`;break b;case`compositionupdate`:x=`onCompositionUpdate`;break b}x=void 0}else Jn?Kn(e,n)&&(x=`onCompositionEnd`):e===`keydown`&&n.keyCode===229&&(x=`onCompositionStart`);x&&(Un&&n.locale!==`ko`&&(Jn||x!==`onCompositionStart`?x===`onCompositionEnd`&&Jn&&(b=cn()):(an=i,on=`value`in an?an.value:an.textContent,Jn=!0)),y=Td(r,x),0<y.length&&(x=new Dn(x,e,null,n,i),o.push({event:x,listeners:y}),b?x.data=b:(b=qn(n),b!==null&&(x.data=b)))),(b=Hn?Yn(e,n):Xn(e,n))&&(x=Td(r,`onBeforeInput`),0<x.length&&(y=new Dn(`onBeforeInput`,`beforeinput`,null,n,i),o.push({event:y,listeners:x}),y.data=b)),fd(o,e,r,n,i)}_d(o,t)})}function wd(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Td(e,t){for(var n=t+`Capture`,r=[];e!==null;){var i=e,a=i.stateNode;if(i=i.tag,i!==5&&i!==26&&i!==27||a===null||(i=en(e,n),i!=null&&r.unshift(wd(e,i,a)),i=en(e,t),i!=null&&r.push(wd(e,i,a))),e.tag===3)return r;e=e.return}return[]}function Ed(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Dd(e,t,n,r,i){for(var a=t._reactName,o=[];n!==null&&n!==r;){var s=n,c=s.alternate,l=s.stateNode;if(s=s.tag,c!==null&&c===r)break;s!==5&&s!==26&&s!==27||l===null||(c=l,i?(l=en(n,a),l!=null&&o.unshift(wd(n,l,c))):i||(l=en(n,a),l!=null&&o.push(wd(n,l,c)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var Od=/\r\n?/g,kd=/\u0000|\uFFFD/g;function Ad(e){return(typeof e==`string`?e:``+e).replace(Od,`
|
|
10
|
+
`).replace(kd,``)}function jd(e,t){return t=Ad(t),Ad(e)===t}function Md(e,t,n,r,i,o){switch(n){case`children`:typeof r==`string`?t===`body`||t===`textarea`&&r===``||Rt(e,r):(typeof r==`number`||typeof r==`bigint`)&&t!==`body`&&Rt(e,``+r);break;case`className`:St(e,`class`,r);break;case`tabIndex`:St(e,`tabindex`,r);break;case`dir`:case`role`:case`viewBox`:case`width`:case`height`:St(e,n,r);break;case`style`:Vt(e,r,o);break;case`data`:if(t!==`object`){St(e,`data`,r);break}case`src`:case`href`:if(r===``&&(t!==`a`||n!==`href`)){e.removeAttribute(n);break}if(r==null||typeof r==`function`||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=Gt(``+r),e.setAttribute(n,r);break;case`action`:case`formAction`:if(typeof r==`function`){e.setAttribute(n,`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 o==`function`&&(n===`formAction`?(t!==`input`&&Md(e,t,`name`,i.name,i,null),Md(e,t,`formEncType`,i.formEncType,i,null),Md(e,t,`formMethod`,i.formMethod,i,null),Md(e,t,`formTarget`,i.formTarget,i,null)):(Md(e,t,`encType`,i.encType,i,null),Md(e,t,`method`,i.method,i,null),Md(e,t,`target`,i.target,i,null)));if(r==null||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=Gt(``+r),e.setAttribute(n,r);break;case`onClick`:r!=null&&(e.onclick=Kt);break;case`onScroll`:r!=null&&vd(`scroll`,e);break;case`onScrollEnd`:r!=null&&vd(`scrollend`,e);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(a(61));if(n=r.__html,n!=null){if(i.children!=null)throw Error(a(60));e.innerHTML=n}}break;case`multiple`:e.multiple=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`muted`:e.muted=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`defaultValue`:case`defaultChecked`:case`innerHTML`:case`ref`:break;case`autoFocus`:break;case`xlinkHref`:if(r==null||typeof r==`function`||typeof r==`boolean`||typeof r==`symbol`){e.removeAttribute(`xlink:href`);break}n=Gt(``+r),e.setAttributeNS(`http://www.w3.org/1999/xlink`,`xlink:href`,n);break;case`contentEditable`:case`spellCheck`:case`draggable`:case`value`:case`autoReverse`:case`externalResourcesRequired`:case`focusable`:case`preserveAlpha`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``+r):e.removeAttribute(n);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`:r&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``):e.removeAttribute(n);break;case`capture`:case`download`:!0===r?e.setAttribute(n,``):!1!==r&&r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,r):e.removeAttribute(n);break;case`cols`:case`rows`:case`size`:case`span`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`&&!isNaN(r)&&1<=r?e.setAttribute(n,r):e.removeAttribute(n);break;case`rowSpan`:case`start`:r==null||typeof r==`function`||typeof r==`symbol`||isNaN(r)?e.removeAttribute(n):e.setAttribute(n,r);break;case`popover`:vd(`beforetoggle`,e),vd(`toggle`,e),xt(e,`popover`,r);break;case`xlinkActuate`:Ct(e,`http://www.w3.org/1999/xlink`,`xlink:actuate`,r);break;case`xlinkArcrole`:Ct(e,`http://www.w3.org/1999/xlink`,`xlink:arcrole`,r);break;case`xlinkRole`:Ct(e,`http://www.w3.org/1999/xlink`,`xlink:role`,r);break;case`xlinkShow`:Ct(e,`http://www.w3.org/1999/xlink`,`xlink:show`,r);break;case`xlinkTitle`:Ct(e,`http://www.w3.org/1999/xlink`,`xlink:title`,r);break;case`xlinkType`:Ct(e,`http://www.w3.org/1999/xlink`,`xlink:type`,r);break;case`xmlBase`:Ct(e,`http://www.w3.org/XML/1998/namespace`,`xml:base`,r);break;case`xmlLang`:Ct(e,`http://www.w3.org/XML/1998/namespace`,`xml:lang`,r);break;case`xmlSpace`:Ct(e,`http://www.w3.org/XML/1998/namespace`,`xml:space`,r);break;case`is`:xt(e,`is`,r);break;case`innerText`:case`textContent`:break;default:(!(2<n.length)||n[0]!==`o`&&n[0]!==`O`||n[1]!==`n`&&n[1]!==`N`)&&(n=Ut.get(n)||n,xt(e,n,r))}}function Nd(e,t,n,r,i,o){switch(n){case`style`:Vt(e,r,o);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(a(61));if(n=r.__html,n!=null){if(i.children!=null)throw Error(a(60));e.innerHTML=n}}break;case`children`:typeof r==`string`?Rt(e,r):(typeof r==`number`||typeof r==`bigint`)&&Rt(e,``+r);break;case`onScroll`:r!=null&&vd(`scroll`,e);break;case`onScrollEnd`:r!=null&&vd(`scrollend`,e);break;case`onClick`:r!=null&&(e.onclick=Kt);break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`innerHTML`:case`ref`:break;case`innerText`:case`textContent`:break;default:if(!mt.hasOwnProperty(n))a:{if(n[0]===`o`&&n[1]===`n`&&(i=n.endsWith(`Capture`),t=n.slice(2,i?n.length-7:void 0),o=e[et]||null,o=o==null?null:o[n],typeof o==`function`&&e.removeEventListener(t,o,i),typeof r==`function`)){typeof o!=`function`&&o!==null&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(t,r,i);break a}n in e?e[n]=r:!0===r?e.setAttribute(n,``):xt(e,n,r)}}}function Pd(e,t,n){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`img`:vd(`error`,e),vd(`load`,e);var r=!1,i=!1,o;for(o in n)if(n.hasOwnProperty(o)){var s=n[o];if(s!=null)switch(o){case`src`:r=!0;break;case`srcSet`:i=!0;break;case`children`:case`dangerouslySetInnerHTML`:throw Error(a(137,t));default:Md(e,t,o,s,n,null)}}i&&Md(e,t,`srcSet`,n.srcSet,n,null),r&&Md(e,t,`src`,n.src,n,null);return;case`input`:vd(`invalid`,e);var c=o=s=i=null,l=null,u=null;for(r in n)if(n.hasOwnProperty(r)){var d=n[r];if(d!=null)switch(r){case`name`:i=d;break;case`type`:s=d;break;case`checked`:l=d;break;case`defaultChecked`:u=d;break;case`value`:o=d;break;case`defaultValue`:c=d;break;case`children`:case`dangerouslySetInnerHTML`:if(d!=null)throw Error(a(137,t));break;default:Md(e,t,r,d,n,null)}}Nt(e,o,c,l,u,s,i,!1);return;case`select`:for(i in vd(`invalid`,e),r=s=o=null,n)if(n.hasOwnProperty(i)&&(c=n[i],c!=null))switch(i){case`value`:o=c;break;case`defaultValue`:s=c;break;case`multiple`:r=c;default:Md(e,t,i,c,n,null)}t=o,n=s,e.multiple=!!r,t==null?n!=null&&Ft(e,!!r,n,!0):Ft(e,!!r,t,!1);return;case`textarea`:for(s in vd(`invalid`,e),o=i=r=null,n)if(n.hasOwnProperty(s)&&(c=n[s],c!=null))switch(s){case`value`:r=c;break;case`defaultValue`:i=c;break;case`children`:o=c;break;case`dangerouslySetInnerHTML`:if(c!=null)throw Error(a(91));break;default:Md(e,t,s,c,n,null)}Lt(e,r,i,o);return;case`option`:for(l in n)if(n.hasOwnProperty(l)&&(r=n[l],r!=null))switch(l){case`selected`:e.selected=r&&typeof r!=`function`&&typeof r!=`symbol`;break;default:Md(e,t,l,r,n,null)}return;case`dialog`:vd(`beforetoggle`,e),vd(`toggle`,e),vd(`cancel`,e),vd(`close`,e);break;case`iframe`:case`object`:vd(`load`,e);break;case`video`:case`audio`:for(r=0;r<hd.length;r++)vd(hd[r],e);break;case`image`:vd(`error`,e),vd(`load`,e);break;case`details`:vd(`toggle`,e);break;case`embed`:case`source`:case`link`:vd(`error`,e),vd(`load`,e);case`area`:case`base`:case`br`:case`col`:case`hr`:case`keygen`:case`meta`:case`param`:case`track`:case`wbr`:case`menuitem`:for(u in n)if(n.hasOwnProperty(u)&&(r=n[u],r!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:throw Error(a(137,t));default:Md(e,t,u,r,n,null)}return;default:if(Ht(t)){for(d in n)n.hasOwnProperty(d)&&(r=n[d],r!==void 0&&Nd(e,t,d,r,n,void 0));return}}for(c in n)n.hasOwnProperty(c)&&(r=n[c],r!=null&&Md(e,t,c,r,n,null))}function Fd(e,t,n,r){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`input`:var i=null,o=null,s=null,c=null,l=null,u=null,d=null;for(m in n){var f=n[m];if(n.hasOwnProperty(m)&&f!=null)switch(m){case`checked`:break;case`value`:break;case`defaultValue`:l=f;default:r.hasOwnProperty(m)||Md(e,t,m,null,r,f)}}for(var p in r){var m=r[p];if(f=n[p],r.hasOwnProperty(p)&&(m!=null||f!=null))switch(p){case`type`:o=m;break;case`name`:i=m;break;case`checked`:u=m;break;case`defaultChecked`:d=m;break;case`value`:s=m;break;case`defaultValue`:c=m;break;case`children`:case`dangerouslySetInnerHTML`:if(m!=null)throw Error(a(137,t));break;default:m!==f&&Md(e,t,p,m,r,f)}}Mt(e,s,c,l,u,d,o,i);return;case`select`:for(o in m=s=c=p=null,n)if(l=n[o],n.hasOwnProperty(o)&&l!=null)switch(o){case`value`:break;case`multiple`:m=l;default:r.hasOwnProperty(o)||Md(e,t,o,null,r,l)}for(i in r)if(o=r[i],l=n[i],r.hasOwnProperty(i)&&(o!=null||l!=null))switch(i){case`value`:p=o;break;case`defaultValue`:c=o;break;case`multiple`:s=o;default:o!==l&&Md(e,t,i,o,r,l)}t=c,n=s,r=m,p==null?!!r!=!!n&&(t==null?Ft(e,!!n,n?[]:``,!1):Ft(e,!!n,t,!0)):Ft(e,!!n,p,!1);return;case`textarea`:for(c in m=p=null,n)if(i=n[c],n.hasOwnProperty(c)&&i!=null&&!r.hasOwnProperty(c))switch(c){case`value`:break;case`children`:break;default:Md(e,t,c,null,r,i)}for(s in r)if(i=r[s],o=n[s],r.hasOwnProperty(s)&&(i!=null||o!=null))switch(s){case`value`:p=i;break;case`defaultValue`:m=i;break;case`children`:break;case`dangerouslySetInnerHTML`:if(i!=null)throw Error(a(91));break;default:i!==o&&Md(e,t,s,i,r,o)}It(e,p,m);return;case`option`:for(var h in n)if(p=n[h],n.hasOwnProperty(h)&&p!=null&&!r.hasOwnProperty(h))switch(h){case`selected`:e.selected=!1;break;default:Md(e,t,h,null,r,p)}for(l in r)if(p=r[l],m=n[l],r.hasOwnProperty(l)&&p!==m&&(p!=null||m!=null))switch(l){case`selected`:e.selected=p&&typeof p!=`function`&&typeof p!=`symbol`;break;default:Md(e,t,l,p,r,m)}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 g in n)p=n[g],n.hasOwnProperty(g)&&p!=null&&!r.hasOwnProperty(g)&&Md(e,t,g,null,r,p);for(u in r)if(p=r[u],m=n[u],r.hasOwnProperty(u)&&p!==m&&(p!=null||m!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:if(p!=null)throw Error(a(137,t));break;default:Md(e,t,u,p,r,m)}return;default:if(Ht(t)){for(var _ in n)p=n[_],n.hasOwnProperty(_)&&p!==void 0&&!r.hasOwnProperty(_)&&Nd(e,t,_,void 0,r,p);for(d in r)p=r[d],m=n[d],!r.hasOwnProperty(d)||p===m||p===void 0&&m===void 0||Nd(e,t,d,p,r,m);return}}for(var v in n)p=n[v],n.hasOwnProperty(v)&&p!=null&&!r.hasOwnProperty(v)&&Md(e,t,v,null,r,p);for(f in r)p=r[f],m=n[f],!r.hasOwnProperty(f)||p===m||p==null&&m==null||Md(e,t,f,p,r,m)}function Id(e){switch(e){case`css`:case`script`:case`font`:case`img`:case`image`:case`input`:case`link`:return!0;default:return!1}}function Ld(){if(typeof performance.getEntriesByType==`function`){for(var e=0,t=0,n=performance.getEntriesByType(`resource`),r=0;r<n.length;r++){var i=n[r],a=i.transferSize,o=i.initiatorType,s=i.duration;if(a&&s&&Id(o)){for(o=0,s=i.responseEnd,r+=1;r<n.length;r++){var c=n[r],l=c.startTime;if(l>s)break;var u=c.transferSize,d=c.initiatorType;u&&Id(d)&&(c=c.responseEnd,o+=u*(c<s?1:(s-l)/(c-l)))}if(--r,t+=8*(a+o)/(i.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e==`number`)?e:5}var Rd=null,zd=null;function Bd(e){return e.nodeType===9?e:e.ownerDocument}function Vd(e){switch(e){case`http://www.w3.org/2000/svg`:return 1;case`http://www.w3.org/1998/Math/MathML`:return 2;default:return 0}}function Hd(e,t){if(e===0)switch(t){case`svg`:return 1;case`math`:return 2;default:return 0}return e===1&&t===`foreignObject`?0:e}function Ud(e,t){return e===`textarea`||e===`noscript`||typeof t.children==`string`||typeof t.children==`number`||typeof t.children==`bigint`||typeof t.dangerouslySetInnerHTML==`object`&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var Wd=null;function Gd(){var e=window.event;return e&&e.type===`popstate`?e===Wd?!1:(Wd=e,!0):(Wd=null,!1)}var Kd=typeof setTimeout==`function`?setTimeout:void 0,qd=typeof clearTimeout==`function`?clearTimeout:void 0,Jd=typeof Promise==`function`?Promise:void 0,Yd=typeof queueMicrotask==`function`?queueMicrotask:Jd===void 0?Kd:function(e){return Jd.resolve(null).then(e).catch(Xd)};function Xd(e){setTimeout(function(){throw e})}function Zd(e){return e===`head`}function Qd(e,t){var n=t,r=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8)if(n=i.data,n===`/$`||n===`/&`){if(r===0){e.removeChild(i),Np(t);return}r--}else if(n===`$`||n===`$?`||n===`$~`||n===`$!`||n===`&`)r++;else if(n===`html`)pf(e.ownerDocument.documentElement);else if(n===`head`){n=e.ownerDocument.head,pf(n);for(var a=n.firstChild;a;){var o=a.nextSibling,s=a.nodeName;a[ot]||s===`SCRIPT`||s===`STYLE`||s===`LINK`&&a.rel.toLowerCase()===`stylesheet`||n.removeChild(a),a=o}}else n===`body`&&pf(e.ownerDocument.body);n=i}while(n);Np(t)}function $d(e,t){var n=e;e=0;do{var r=n.nextSibling;if(n.nodeType===1?t?(n._stashedDisplay=n.style.display,n.style.display=`none`):(n.style.display=n._stashedDisplay||``,n.getAttribute(`style`)===``&&n.removeAttribute(`style`)):n.nodeType===3&&(t?(n._stashedText=n.nodeValue,n.nodeValue=``):n.nodeValue=n._stashedText||``),r&&r.nodeType===8)if(n=r.data,n===`/$`){if(e===0)break;e--}else n!==`$`&&n!==`$?`&&n!==`$~`&&n!==`$!`||e++;n=r}while(n)}function ef(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var n=t;switch(t=t.nextSibling,n.nodeName){case`HTML`:case`HEAD`:case`BODY`:ef(n),st(n);continue;case`SCRIPT`:case`STYLE`:continue;case`LINK`:if(n.rel.toLowerCase()===`stylesheet`)continue}e.removeChild(n)}}function tf(e,t,n,r){for(;e.nodeType===1;){var i=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!r&&(e.nodeName!==`INPUT`||e.type!==`hidden`))break}else if(!r)if(t===`input`&&e.type===`hidden`){var a=i.name==null?null:``+i.name;if(i.type===`hidden`&&e.getAttribute(`name`)===a)return e}else return e;else if(!e[ot])switch(t){case`meta`:if(!e.hasAttribute(`itemprop`))break;return e;case`link`:if(a=e.getAttribute(`rel`),a===`stylesheet`&&e.hasAttribute(`data-precedence`)||a!==i.rel||e.getAttribute(`href`)!==(i.href==null||i.href===``?null:i.href)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin)||e.getAttribute(`title`)!==(i.title==null?null:i.title))break;return e;case`style`:if(e.hasAttribute(`data-precedence`))break;return e;case`script`:if(a=e.getAttribute(`src`),(a!==(i.src==null?null:i.src)||e.getAttribute(`type`)!==(i.type==null?null:i.type)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin))&&a&&e.hasAttribute(`async`)&&!e.hasAttribute(`itemprop`))break;return e;default:return e}if(e=cf(e.nextSibling),e===null)break}return null}function nf(e,t,n){if(t===``)return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!n||(e=cf(e.nextSibling),e===null))return null;return e}function rf(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!t||(e=cf(e.nextSibling),e===null))return null;return e}function af(e){return e.data===`$?`||e.data===`$~`}function of(e){return e.data===`$!`||e.data===`$?`&&e.ownerDocument.readyState!==`loading`}function sf(e,t){var n=e.ownerDocument;if(e.data===`$~`)e._reactRetry=t;else if(e.data!==`$?`||n.readyState!==`loading`)t();else{var r=function(){t(),n.removeEventListener(`DOMContentLoaded`,r)};n.addEventListener(`DOMContentLoaded`,r),e._reactRetry=r}}function cf(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t===`$`||t===`$!`||t===`$?`||t===`$~`||t===`&`||t===`F!`||t===`F`)break;if(t===`/$`||t===`/&`)return null}}return e}var lf=null;function uf(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`/$`||n===`/&`){if(t===0)return cf(e.nextSibling);t--}else n!==`$`&&n!==`$!`&&n!==`$?`&&n!==`$~`&&n!==`&`||t++}e=e.nextSibling}return null}function df(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`$`||n===`$!`||n===`$?`||n===`$~`||n===`&`){if(t===0)return e;t--}else n!==`/$`&&n!==`/&`||t++}e=e.previousSibling}return null}function ff(e,t,n){switch(t=Bd(n),e){case`html`:if(e=t.documentElement,!e)throw Error(a(452));return e;case`head`:if(e=t.head,!e)throw Error(a(453));return e;case`body`:if(e=t.body,!e)throw Error(a(454));return e;default:throw Error(a(451))}}function pf(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);st(e)}var mf=new Map,hf=new Set;function gf(e){return typeof e.getRootNode==`function`?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var _f=F.d;F.d={f:vf,r:yf,D:Sf,C:Cf,L:wf,m:Tf,X:Df,S:Ef,M:Of};function vf(){var e=_f.f(),t=_u();return e||t}function yf(e){var t=lt(e);t!==null&&t.tag===5&&t.type===`form`?bs(t):_f.r(e)}var bf=typeof document>`u`?null:document;function xf(e,t,n){var r=bf;if(r&&typeof t==`string`&&t){var i=jt(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),hf.has(i)||(hf.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Pd(t,`link`,e),ft(t),r.head.appendChild(t)))}}function Sf(e){_f.D(e),xf(`dns-prefetch`,e,null)}function Cf(e,t){_f.C(e,t),xf(`preconnect`,e,t)}function wf(e,t,n){_f.L(e,t,n);var r=bf;if(r&&e&&t){var i=`link[rel="preload"][as="`+jt(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+jt(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+jt(n.imageSizes)+`"]`)):i+=`[href="`+jt(e)+`"]`;var a=i;switch(t){case`style`:a=Af(e);break;case`script`:a=Pf(e)}mf.has(a)||(e=p({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),mf.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(jf(a))||t===`script`&&r.querySelector(Ff(a))||(t=r.createElement(`link`),Pd(t,`link`,e),ft(t),r.head.appendChild(t)))}}function Tf(e,t){_f.m(e,t);var n=bf;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+jt(r)+`"][href="`+jt(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Pf(e)}if(!mf.has(a)&&(e=p({rel:`modulepreload`,href:e},t),mf.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(Ff(a)))return}r=n.createElement(`link`),Pd(r,`link`,e),ft(r),n.head.appendChild(r)}}}function Ef(e,t,n){_f.S(e,t,n);var r=bf;if(r&&e){var i=dt(r).hoistableStyles,a=Af(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(jf(a)))s.loading=5;else{e=p({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=mf.get(a))&&Rf(e,n);var c=o=r.createElement(`link`);ft(c),Pd(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,Lf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function Df(e,t){_f.X(e,t);var n=bf;if(n&&e){var r=dt(n).hoistableScripts,i=Pf(e),a=r.get(i);a||(a=n.querySelector(Ff(i)),a||(e=p({src:e,async:!0},t),(t=mf.get(i))&&zf(e,t),a=n.createElement(`script`),ft(a),Pd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Of(e,t){_f.M(e,t);var n=bf;if(n&&e){var r=dt(n).hoistableScripts,i=Pf(e),a=r.get(i);a||(a=n.querySelector(Ff(i)),a||(e=p({src:e,async:!0,type:`module`},t),(t=mf.get(i))&&zf(e,t),a=n.createElement(`script`),ft(a),Pd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function kf(e,t,n,r){var i=(i=H.current)?gf(i):null;if(!i)throw Error(a(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=Af(n.href),n=dt(i).hoistableStyles,r=n.get(t),r||(r={type:`style`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=Af(n.href);var o=dt(i).hoistableStyles,s=o.get(e);if(s||(i=i.ownerDocument||i,s={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},o.set(e,s),(o=i.querySelector(jf(e)))&&!o._p&&(s.instance=o,s.state.loading=5),mf.has(e)||(n={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},mf.set(e,n),o||Nf(i,e,n,s.state))),t&&r===null)throw Error(a(528,``));return s}if(t&&r!==null)throw Error(a(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Pf(n),n=dt(i).hoistableScripts,r=n.get(t),r||(r={type:`script`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(a(444,e))}}function Af(e){return`href="`+jt(e)+`"`}function jf(e){return`link[rel="stylesheet"][`+e+`]`}function Mf(e){return p({},e,{"data-precedence":e.precedence,precedence:null})}function Nf(e,t,n,r){e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)?r.loading=1:(t=e.createElement(`link`),r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2}),Pd(t,`link`,n),ft(t),e.head.appendChild(t))}function Pf(e){return`[src="`+jt(e)+`"]`}function Ff(e){return`script[async]`+e}function If(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+jt(n.href)+`"]`);if(r)return t.instance=r,ft(r),r;var i=p({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),ft(r),Pd(r,`style`,i),Lf(r,n.precedence,e),t.instance=r;case`stylesheet`:i=Af(n.href);var o=e.querySelector(jf(i));if(o)return t.state.loading|=4,t.instance=o,ft(o),o;r=Mf(n),(i=mf.get(i))&&Rf(r,i),o=(e.ownerDocument||e).createElement(`link`),ft(o);var s=o;return s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),Pd(o,`link`,r),t.state.loading|=4,Lf(o,n.precedence,e),t.instance=o;case`script`:return o=Pf(n.src),(i=e.querySelector(Ff(o)))?(t.instance=i,ft(i),i):(r=n,(i=mf.get(o))&&(r=p({},n),zf(r,i)),e=e.ownerDocument||e,i=e.createElement(`script`),ft(i),Pd(i,`link`,r),e.head.appendChild(i),t.instance=i);case`void`:return null;default:throw Error(a(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Lf(r,n.precedence,e));return t.instance}function Lf(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o<r.length;o++){var s=r[o];if(s.dataset.precedence===t)a=s;else if(a!==i)break}a?a.parentNode.insertBefore(e,a.nextSibling):(t=n.nodeType===9?n.head:n,t.insertBefore(e,t.firstChild))}function Rf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.title??=t.title}function zf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.integrity??=t.integrity}var Bf=null;function Vf(e,t,n){if(Bf===null){var r=new Map,i=Bf=new Map;i.set(n,r)}else i=Bf,r=i.get(n),r||(r=new Map,i.set(n,r));if(r.has(e))return r;for(r.set(e,null),n=n.getElementsByTagName(e),i=0;i<n.length;i++){var a=n[i];if(!(a[ot]||a[$e]||e===`link`&&a.getAttribute(`rel`)===`stylesheet`)&&a.namespaceURI!==`http://www.w3.org/2000/svg`){var o=a.getAttribute(t)||``;o=e+o;var s=r.get(o);s?s.push(a):r.set(o,[a])}}return r}function Hf(e,t,n){e=e.ownerDocument||e,e.head.insertBefore(n,t===`title`?e.querySelector(`head > title`):null)}function Uf(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case`meta`:case`title`:return!0;case`style`:if(typeof t.precedence!=`string`||typeof t.href!=`string`||t.href===``)break;return!0;case`link`:if(typeof t.rel!=`string`||typeof t.href!=`string`||t.href===``||t.onLoad||t.onError)break;switch(t.rel){case`stylesheet`:return e=t.disabled,typeof t.precedence==`string`&&e==null;default:return!0}case`script`:if(t.async&&typeof t.async!=`function`&&typeof t.async!=`symbol`&&!t.onLoad&&!t.onError&&t.src&&typeof t.src==`string`)return!0}return!1}function Wf(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function Gf(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=Af(r.href),a=t.querySelector(jf(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=Jf.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,ft(a);return}a=t.ownerDocument||t,r=Mf(r),(i=mf.get(i))&&Rf(r,i),a=a.createElement(`link`),ft(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Pd(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=Jf.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var Kf=0;function qf(e,t){return e.stylesheets&&e.count===0&&Xf(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&Xf(e,e.stylesheets),e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}},6e4+t);0<e.imgBytes&&Kf===0&&(Kf=62500*Ld());var i=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&Xf(e,e.stylesheets),e.unsuspend)){var t=e.unsuspend;e.unsuspend=null,t()}},(e.imgBytes>Kf?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function Jf(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Xf(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Yf=null;function Xf(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Yf=new Map,t.forEach(Zf,e),Yf=null,Jf.call(e))}function Zf(e,t){if(!(t.state.loading&4)){var n=Yf.get(e);if(n)var r=n.get(null);else{n=new Map,Yf.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a<i.length;a++){var o=i[a];(o.nodeName===`LINK`||o.getAttribute(`media`)!==`not all`)&&(n.set(o.dataset.precedence,o),r=o)}r&&n.set(null,r)}i=t.instance,o=i.getAttribute(`data-precedence`),a=n.get(o)||r,a===r&&n.set(null,i),n.set(o,i),this.count++,r=Jf.bind(this),i.addEventListener(`load`,r),i.addEventListener(`error`,r),a?a.parentNode.insertBefore(i,a.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(i,e.firstChild)),t.state.loading|=4}}var Qf={$$typeof:x,Provider:null,Consumer:null,_currentValue:I,_currentValue2:I,_threadCount:0};function $f(e,t,n,r,i,a,o,s,c){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=He(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=He(0),this.hiddenUpdates=He(null),this.identifierPrefix=r,this.onUncaughtError=i,this.onCaughtError=a,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=c,this.incompleteTransitions=new Map}function ep(e,t,n,r,i,a,o,s,c,l,u,d){return e=new $f(e,t,n,o,c,l,u,d,s),t=1,!0===a&&(t|=24),a=ei(3,null,null,t),e.current=a,a.stateNode=e,t=ta(),t.refCount++,e.pooledCache=t,t.refCount++,a.memoizedState={element:r,isDehydrated:n,cache:t},Pa(a),e}function tp(e){return e?(e=Qr,e):Qr}function np(e,t,n,r,i,a){i=tp(i),r.context===null?r.context=i:r.pendingContext=i,r=Ia(t),r.payload={element:n},a=a===void 0?null:a,a!==null&&(r.callback=a),n=La(e,r,t),n!==null&&(fu(n,e,t),Ra(n,e,t))}function rp(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function ip(e,t){rp(e,t),(e=e.alternate)&&rp(e,t)}function ap(e){if(e.tag===13||e.tag===31){var t=Yr(e,67108864);t!==null&&fu(t,e,67108864),ip(e,67108864)}}function op(e){if(e.tag===13||e.tag===31){var t=uu();t=Je(t);var n=Yr(e,t);n!==null&&fu(n,e,t),ip(e,t)}}var sp=!0;function cp(e,t,n,r){var i=P.T;P.T=null;var a=F.p;try{F.p=2,up(e,t,n,r)}finally{F.p=a,P.T=i}}function lp(e,t,n,r){var i=P.T;P.T=null;var a=F.p;try{F.p=8,up(e,t,n,r)}finally{F.p=a,P.T=i}}function up(e,t,n,r){if(sp){var i=dp(r);if(i===null)Cd(e,t,r,fp,n),Cp(e,r);else if(Tp(i,e,t,n,r))r.stopPropagation();else if(Cp(e,r),t&4&&-1<Sp.indexOf(e)){for(;i!==null;){var a=lt(i);if(a!==null)switch(a.tag){case 3:if(a=a.stateNode,a.current.memoizedState.isDehydrated){var o=Le(a.pendingLanes);if(o!==0){var s=a;for(s.pendingLanes|=2,s.entangledLanes|=2;o;){var c=1<<31-Ae(o);s.entanglements[1]|=c,o&=~c}td(a),!(Nl&6)&&(Ql=ye()+500,nd(0,!1))}}break;case 31:case 13:s=Yr(a,2),s!==null&&fu(s,a,2),_u(),ip(a,2)}if(a=dp(r),a===null&&Cd(e,t,r,fp,n),a===i)break;i=a}i!==null&&r.stopPropagation()}else Cd(e,t,r,null,n)}}function dp(e){return e=Jt(e),pp(e)}var fp=null;function pp(e){if(fp=null,e=ct(e),e!==null){var t=s(e);if(t===null)e=null;else{var n=t.tag;if(n===13){if(e=c(t),e!==null)return e;e=null}else if(n===31){if(e=l(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return fp=e,null}function mp(e){switch(e){case`beforetoggle`:case`cancel`:case`click`:case`close`:case`contextmenu`:case`copy`:case`cut`:case`auxclick`:case`dblclick`:case`dragend`:case`dragstart`:case`drop`:case`focusin`:case`focusout`:case`input`:case`invalid`:case`keydown`:case`keypress`:case`keyup`:case`mousedown`:case`mouseup`:case`paste`:case`pause`:case`play`:case`pointercancel`:case`pointerdown`:case`pointerup`:case`ratechange`:case`reset`:case`resize`:case`seeked`:case`submit`:case`toggle`:case`touchcancel`:case`touchend`:case`touchstart`:case`volumechange`:case`change`:case`selectionchange`:case`textInput`:case`compositionstart`:case`compositionend`:case`compositionupdate`:case`beforeblur`:case`afterblur`:case`beforeinput`:case`blur`:case`fullscreenchange`:case`focus`:case`hashchange`:case`popstate`:case`select`:case`selectstart`:return 2;case`drag`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`mousemove`:case`mouseout`:case`mouseover`:case`pointermove`:case`pointerout`:case`pointerover`:case`scroll`:case`touchmove`:case`wheel`:case`mouseenter`:case`mouseleave`:case`pointerenter`:case`pointerleave`:return 8;case`message`:switch(be()){case W:return 2;case xe:return 8;case Se:case Ce:return 32;case we:return 268435456;default:return 32}default:return 32}}var hp=!1,gp=null,_p=null,vp=null,yp=new Map,bp=new Map,xp=[],Sp=`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 Cp(e,t){switch(e){case`focusin`:case`focusout`:gp=null;break;case`dragenter`:case`dragleave`:_p=null;break;case`mouseover`:case`mouseout`:vp=null;break;case`pointerover`:case`pointerout`:yp.delete(t.pointerId);break;case`gotpointercapture`:case`lostpointercapture`:bp.delete(t.pointerId)}}function wp(e,t,n,r,i,a){return e===null||e.nativeEvent!==a?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:a,targetContainers:[i]},t!==null&&(t=lt(t),t!==null&&ap(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function Tp(e,t,n,r,i){switch(t){case`focusin`:return gp=wp(gp,e,t,n,r,i),!0;case`dragenter`:return _p=wp(_p,e,t,n,r,i),!0;case`mouseover`:return vp=wp(vp,e,t,n,r,i),!0;case`pointerover`:var a=i.pointerId;return yp.set(a,wp(yp.get(a)||null,e,t,n,r,i)),!0;case`gotpointercapture`:return a=i.pointerId,bp.set(a,wp(bp.get(a)||null,e,t,n,r,i)),!0}return!1}function Ep(e){var t=ct(e.target);if(t!==null){var n=s(t);if(n!==null){if(t=n.tag,t===13){if(t=c(n),t!==null){e.blockedOn=t,Ze(e.priority,function(){op(n)});return}}else if(t===31){if(t=l(n),t!==null){e.blockedOn=t,Ze(e.priority,function(){op(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Dp(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=dp(e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);qt=r,n.target.dispatchEvent(r),qt=null}else return t=lt(n),t!==null&&ap(t),e.blockedOn=n,!1;t.shift()}return!0}function Op(e,t,n){Dp(e)&&n.delete(t)}function kp(){hp=!1,gp!==null&&Dp(gp)&&(gp=null),_p!==null&&Dp(_p)&&(_p=null),vp!==null&&Dp(vp)&&(vp=null),yp.forEach(Op),bp.forEach(Op)}function Ap(e,t){e.blockedOn===t&&(e.blockedOn=null,hp||(hp=!0,n.unstable_scheduleCallback(n.unstable_NormalPriority,kp)))}var jp=null;function Mp(e){jp!==e&&(jp=e,n.unstable_scheduleCallback(n.unstable_NormalPriority,function(){jp===e&&(jp=null);for(var t=0;t<e.length;t+=3){var n=e[t],r=e[t+1],i=e[t+2];if(typeof r!=`function`){if(pp(r||n)===null)continue;break}var a=lt(n);a!==null&&(e.splice(t,3),t-=3,vs(a,{pending:!0,data:i,method:n.method,action:r},r,i))}}))}function Np(e){function t(t){return Ap(t,e)}gp!==null&&Ap(gp,e),_p!==null&&Ap(_p,e),vp!==null&&Ap(vp,e),yp.forEach(t),bp.forEach(t);for(var n=0;n<xp.length;n++){var r=xp[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<xp.length&&(n=xp[0],n.blockedOn===null);)Ep(n),n.blockedOn===null&&xp.shift();if(n=(e.ownerDocument||e).$$reactFormReplay,n!=null)for(r=0;r<n.length;r+=3){var i=n[r],a=n[r+1],o=i[et]||null;if(typeof a==`function`)o||Mp(n);else if(o){var s=null;if(a&&a.hasAttribute(`formAction`)){if(i=a,o=a[et]||null)s=o.formAction;else if(pp(i)!==null)continue}else s=o.action;typeof s==`function`?n[r+1]=s:(n.splice(r,3),r-=3),Mp(n)}}}function Pp(){function e(e){e.canIntercept&&e.info===`react-transition`&&e.intercept({handler:function(){return new Promise(function(e){return i=e})},focusReset:`manual`,scroll:`manual`})}function t(){i!==null&&(i(),i=null),r||setTimeout(n,20)}function n(){if(!r&&!navigation.transition){var e=navigation.currentEntry;e&&e.url!=null&&navigation.navigate(e.url,{state:e.getState(),info:`react-transition`,history:`replace`})}}if(typeof navigation==`object`){var r=!1,i=null;return navigation.addEventListener(`navigate`,e),navigation.addEventListener(`navigatesuccess`,t),navigation.addEventListener(`navigateerror`,t),setTimeout(n,100),function(){r=!0,navigation.removeEventListener(`navigate`,e),navigation.removeEventListener(`navigatesuccess`,t),navigation.removeEventListener(`navigateerror`,t),i!==null&&(i(),i=null)}}}function Fp(e){this._internalRoot=e}Ip.prototype.render=Fp.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(a(409));var n=t.current;np(n,uu(),e,t,null,null)},Ip.prototype.unmount=Fp.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;np(e.current,2,null,e,null,null),_u(),t[tt]=null}};function Ip(e){this._internalRoot=e}Ip.prototype.unstable_scheduleHydration=function(e){if(e){var t=Xe();e={blockedOn:null,target:e,priority:t};for(var n=0;n<xp.length&&t!==0&&t<xp[n].priority;n++);xp.splice(n,0,e),n===0&&Ep(e)}};var Lp=r.version;if(Lp!==`19.2.7`)throw Error(a(527,Lp,`19.2.7`));F.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render==`function`?Error(a(188)):(e=Object.keys(e).join(`,`),Error(a(268,e)));return e=d(t),e=e===null?null:f(e),e=e===null?null:e.stateNode,e};var Rp={bundleType:0,version:`19.2.7`,rendererPackageName:`react-dom`,currentDispatcherRef:P,reconcilerVersion:`19.2.7`};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`){var zp=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!zp.isDisabled&&zp.supportsFiber)try{De=zp.inject(Rp),Oe=zp}catch{}}t.createRoot=function(e,t){if(!o(e))throw Error(a(299));var n=!1,r=``,i=Vs,s=Hs,c=Us;return t!=null&&(!0===t.unstable_strictMode&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onUncaughtError!==void 0&&(i=t.onUncaughtError),t.onCaughtError!==void 0&&(s=t.onCaughtError),t.onRecoverableError!==void 0&&(c=t.onRecoverableError)),t=ep(e,1,!1,null,null,n,r,null,i,s,c,Pp),e[tt]=t.current,xd(e),new Fp(t)}})),dn=m(((e,t)=>{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=un()})),fn=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},pn=new class extends fn{#e;#t;#n;constructor(){super(),this.#n=e=>{if(typeof window<`u`&&window.addEventListener){let t=()=>e();return window.addEventListener(`visibilitychange`,t,!1),()=>{window.removeEventListener(`visibilitychange`,t)}}}}onSubscribe(){this.#t||this.setEventListener(this.#n)}onUnsubscribe(){this.hasListeners()||(this.#t?.(),this.#t=void 0)}setEventListener(e){this.#n=e,this.#t?.(),this.#t=e(e=>{typeof e==`boolean`?this.setFocused(e):this.onFocus()})}setFocused(e){this.#e!==e&&(this.#e=e,this.onFocus())}onFocus(){let e=this.isFocused();this.listeners.forEach(t=>{t(e)})}isFocused(){return typeof this.#e==`boolean`?this.#e:globalThis.document?.visibilityState!==`hidden`}},mn={setTimeout:(e,t)=>setTimeout(e,t),clearTimeout:e=>clearTimeout(e),setInterval:(e,t)=>setInterval(e,t),clearInterval:e=>clearInterval(e)},hn=new class{#e=mn;setTimeoutProvider(e){this.#e=e}setTimeout(e,t){return this.#e.setTimeout(e,t)}clearTimeout(e){this.#e.clearTimeout(e)}setInterval(e,t){return this.#e.setInterval(e,t)}clearInterval(e){this.#e.clearInterval(e)}};function gn(e){setTimeout(e,0)}var _n=typeof window>`u`||`Deno`in globalThis;function vn(){}function yn(e,t){return typeof e==`function`?e(t):e}function bn(e){return typeof e==`number`&&e>=0&&e!==1/0}function xn(e,t){return Math.max(e+(t||0)-Date.now(),0)}function Sn(e,t){return typeof e==`function`?e(t):e}function Cn(e,t){return typeof e==`function`?e(t):e}function wn(e,t){let{type:n=`all`,exact:r,fetchStatus:i,predicate:a,queryKey:o,stale:s}=e;if(o){if(r){if(t.queryHash!==En(o,t.options))return!1}else if(!On(t.queryKey,o))return!1}if(n!==`all`){let e=t.isActive();if(n===`active`&&!e||n===`inactive`&&e)return!1}return!(typeof s==`boolean`&&t.isStale()!==s||i&&i!==t.state.fetchStatus||a&&!a(t))}function Tn(e,t){let{exact:n,status:r,predicate:i,mutationKey:a}=e;if(a){if(!t.options.mutationKey)return!1;if(n){if(Dn(t.options.mutationKey)!==Dn(a))return!1}else if(!On(t.options.mutationKey,a))return!1}return!(r&&t.state.status!==r||i&&!i(t))}function En(e,t){return(t?.queryKeyHashFn||Dn)(e)}function Dn(e){return JSON.stringify(e,(e,t)=>Nn(t)?Object.keys(t).sort().reduce((e,n)=>(e[n]=t[n],e),{}):t)}function On(e,t){return e===t?!0:typeof e==typeof t&&e&&t&&typeof e==`object`&&typeof t==`object`?Object.keys(t).every(n=>On(e[n],t[n])):!1}var kn=Object.prototype.hasOwnProperty;function An(e,t,n=0){if(e===t)return e;if(n>500)return t;let r=Mn(e)&&Mn(t);if(!r&&!(Nn(e)&&Nn(t)))return t;let i=(r?e:Object.keys(e)).length,a=r?t:Object.keys(t),o=a.length,s=r?Array(o):{},c=0;for(let l=0;l<o;l++){let o=r?l:a[l],u=e[o],d=t[o];if(u===d){s[o]=u,(r?l<i:kn.call(e,o))&&c++;continue}if(u===null||d===null||typeof u!=`object`||typeof d!=`object`){s[o]=d;continue}let f=An(u,d,n+1);s[o]=f,f===u&&c++}return i===o&&c===i?e:s}function jn(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(let n in e)if(e[n]!==t[n])return!1;return!0}function Mn(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Nn(e){if(!Pn(e))return!1;let t=e.constructor;if(t===void 0)return!0;let n=t.prototype;return!(!Pn(n)||!n.hasOwnProperty(`isPrototypeOf`)||Object.getPrototypeOf(e)!==Object.prototype)}function Pn(e){return Object.prototype.toString.call(e)===`[object Object]`}function Fn(e){return new Promise(t=>{hn.setTimeout(t,e)})}function In(e,t,n){return typeof n.structuralSharing==`function`?n.structuralSharing(e,t):n.structuralSharing===!1?t:An(e,t)}function Ln(e,t,n=0){let r=[...e,t];return n&&r.length>n?r.slice(1):r}function Rn(e,t,n=0){let r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var zn=Symbol();function Bn(e,t){return!e.queryFn&&t?.initialPromise?()=>t.initialPromise:!e.queryFn||e.queryFn===zn?()=>Promise.reject(Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function Vn(e,t){return typeof e==`function`?e(...t):!!e}function Hn(e,t,n){let r=!1,i;return Object.defineProperty(e,"signal",{enumerable:!0,get:()=>(i??=t(),r?i:(r=!0,i.aborted?n():i.addEventListener(`abort`,n,{once:!0}),i))}),e}var Un=(()=>{let e=()=>_n;return{isServer(){return e()},setIsServer(t){e=t}}})();function Wn(){let e,t,n=new Promise((n,r)=>{e=n,t=r});n.status=`pending`,n.catch(()=>{});function r(e){Object.assign(n,e),delete n.resolve,delete n.reject}return n.resolve=t=>{r({status:`fulfilled`,value:t}),e(t)},n.reject=e=>{r({status:`rejected`,reason:e}),t(e)},n}var Gn=gn;function Kn(){let e=[],t=0,n=e=>{e()},r=e=>{e()},i=Gn,a=r=>{t?e.push(r):i(()=>{n(r)})},o=()=>{let t=e;e=[],t.length&&i(()=>{r(()=>{t.forEach(e=>{n(e)})})})};return{batch:e=>{let n;t++;try{n=e()}finally{t--,t||o()}return n},batchCalls:e=>(...t)=>{a(()=>{e(...t)})},schedule:a,setNotifyFunction:e=>{n=e},setBatchNotifyFunction:e=>{r=e},setScheduler:e=>{i=e}}}var qn=Kn(),Jn=new class extends fn{#e=!0;#t;#n;constructor(){super(),this.#n=e=>{if(typeof window<`u`&&window.addEventListener){let t=()=>e(!0),n=()=>e(!1);return window.addEventListener(`online`,t,!1),window.addEventListener(`offline`,n,!1),()=>{window.removeEventListener(`online`,t),window.removeEventListener(`offline`,n)}}}}onSubscribe(){this.#t||this.setEventListener(this.#n)}onUnsubscribe(){this.hasListeners()||(this.#t?.(),this.#t=void 0)}setEventListener(e){this.#n=e,this.#t?.(),this.#t=e(this.setOnline.bind(this))}setOnline(e){this.#e!==e&&(this.#e=e,this.listeners.forEach(t=>{t(e)}))}isOnline(){return this.#e}};function Yn(e){return Math.min(1e3*2**e,3e4)}function Xn(e){return(e??`online`)!==`online`||Jn.isOnline()}var Zn=class extends Error{constructor(e){super(`CancelledError`),this.revert=e?.revert,this.silent=e?.silent}};function Qn(e){let t=!1,n=0,r,i=Wn(),a=()=>i.status!==`pending`,o=t=>{if(!a()){let n=new Zn(t);f(n),e.onCancel?.(n)}},s=()=>{t=!0},c=()=>{t=!1},l=()=>pn.isFocused()&&(e.networkMode===`always`||Jn.isOnline())&&e.canRun(),u=()=>Xn(e.networkMode)&&e.canRun(),d=e=>{a()||(r?.(),i.resolve(e))},f=e=>{a()||(r?.(),i.reject(e))},p=()=>new Promise(t=>{r=e=>{(a()||l())&&t(e)},e.onPause?.()}).then(()=>{r=void 0,a()||e.onContinue?.()}),m=()=>{if(a())return;let r,i=n===0?e.initialPromise:void 0;try{r=i??e.fn()}catch(e){r=Promise.reject(e)}Promise.resolve(r).then(d).catch(r=>{if(a())return;let i=e.retry??(Un.isServer()?0:3),o=e.retryDelay??Yn,s=typeof o==`function`?o(n,r):o,c=i===!0||typeof i==`number`&&n<i||typeof i==`function`&&i(n,r);if(t||!c){f(r);return}n++,e.onFail?.(n,r),Fn(s).then(()=>l()?void 0:p()).then(()=>{t?f(r):m()})})};return{promise:i,status:()=>i.status,cancel:o,continue:()=>(r?.(),i),cancelRetry:s,continueRetry:c,canStart:u,start:()=>(u()?m():p().then(m),i)}}var $n=class{#e;destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),bn(this.gcTime)&&(this.#e=hn.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Un.isServer()?1/0:300*1e3))}clearGcTimeout(){this.#e!==void 0&&(hn.clearTimeout(this.#e),this.#e=void 0)}};function er(e){return{onFetch:(t,n)=>{let r=t.options,i=t.fetchOptions?.meta?.fetchMore?.direction,a=t.state.data?.pages||[],o=t.state.data?.pageParams||[],s={pages:[],pageParams:[]},c=0,l=async()=>{let n=!1,l=e=>{Hn(e,()=>t.signal,()=>n=!0)},u=Bn(t.options,t.fetchOptions),d=async(e,r,i)=>{if(n)return Promise.reject(t.signal.reason);if(r==null&&e.pages.length)return Promise.resolve(e);let a=(()=>{let e={client:t.client,queryKey:t.queryKey,pageParam:r,direction:i?`backward`:`forward`,meta:t.options.meta};return l(e),e})(),o=await u(a),{maxPages:s}=t.options,c=i?Rn:Ln;return{pages:c(e.pages,o,s),pageParams:c(e.pageParams,r,s)}};if(i&&a.length){let e=i===`backward`,t=e?nr:tr,n={pages:a,pageParams:o};s=await d(n,t(r,n),e)}else{let t=e??a.length;do{let e=c===0?o[0]??r.initialPageParam:tr(r,s);if(c>0&&e==null)break;s=await d(s,e),c++}while(c<t)}return s};t.options.persister?t.fetchFn=()=>t.options.persister?.(l,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n):t.fetchFn=l}}}function tr(e,{pages:t,pageParams:n}){let r=t.length-1;return t.length>0?e.getNextPageParam(t[r],t,n[r],n):void 0}function nr(e,{pages:t,pageParams:n}){return t.length>0?e.getPreviousPageParam?.(t[0],t,n[0],n):void 0}var rr=class extends $n{#e;#t;#n;#r;#i;#a;#o;#s;constructor(e){super(),this.#s=!1,this.#o=e.defaultOptions,this.setOptions(e.options),this.observers=[],this.#i=e.client,this.#r=this.#i.getQueryCache(),this.queryKey=e.queryKey,this.queryHash=e.queryHash,this.#t=or(this.options),this.state=e.state??this.#t,this.scheduleGc()}get meta(){return this.options.meta}get queryType(){return this.#e}get promise(){return this.#a?.promise}setOptions(e){if(this.options={...this.#o,...e},e?._type&&(this.#e=e._type),this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){let e=or(this.options);e.data!==void 0&&(this.setState(ar(e.data,e.dataUpdatedAt)),this.#t=e)}}optionalRemove(){!this.observers.length&&this.state.fetchStatus===`idle`&&this.#r.remove(this)}setData(e,t){let n=In(this.state.data,e,this.options);return this.#l({data:n,type:`success`,dataUpdatedAt:t?.updatedAt,manual:t?.manual}),n}setState(e){this.#l({type:`setState`,state:e})}cancel(e){let t=this.#a?.promise;return this.#a?.cancel(e),t?t.then(vn).catch(vn):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}get resetState(){return this.#t}reset(){this.destroy(),this.setState(this.resetState)}isActive(){return this.observers.some(e=>Cn(e.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===zn||!this.isFetched()}isFetched(){return this.state.dataUpdateCount+this.state.errorUpdateCount>0}isStatic(){return this.getObserversCount()>0&&this.observers.some(e=>Sn(e.options.staleTime,this)===`static`)}isStale(){return this.getObserversCount()>0?this.observers.some(e=>e.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(e=0){return this.state.data===void 0?!0:e===`static`?!1:this.state.isInvalidated?!0:!xn(this.state.dataUpdatedAt,e)}onFocus(){this.observers.find(e=>e.shouldFetchOnWindowFocus())?.refetch({cancelRefetch:!1}),this.#a?.continue()}onOnline(){this.observers.find(e=>e.shouldFetchOnReconnect())?.refetch({cancelRefetch:!1}),this.#a?.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),this.#r.notify({type:`observerAdded`,query:this,observer:e}))}removeObserver(e){this.observers.includes(e)&&(this.observers=this.observers.filter(t=>t!==e),this.observers.length||(this.#a&&(this.#s||this.#c()?this.#a.cancel({revert:!0}):this.#a.cancelRetry()),this.scheduleGc()),this.#r.notify({type:`observerRemoved`,query:this,observer:e}))}getObserversCount(){return this.observers.length}#c(){return this.state.fetchStatus===`paused`&&this.state.status===`pending`}invalidate(){this.state.isInvalidated||this.#l({type:`invalidate`})}async fetch(e,t){if(this.state.fetchStatus!==`idle`&&this.#a?.status()!==`rejected`){if(this.state.data!==void 0&&t?.cancelRefetch)this.cancel({silent:!0});else if(this.#a)return this.#a.continueRetry(),this.#a.promise}if(e&&this.setOptions(e),!this.options.queryFn){let e=this.observers.find(e=>e.options.queryFn);e&&this.setOptions(e.options)}let n=new AbortController,r=e=>{Object.defineProperty(e,"signal",{enumerable:!0,get:()=>(this.#s=!0,n.signal)})},i=()=>{let e=Bn(this.options,t),n=(()=>{let e={client:this.#i,queryKey:this.queryKey,meta:this.meta};return r(e),e})();return this.#s=!1,this.options.persister?this.options.persister(e,n,this):e(n)},a=(()=>{let e={fetchOptions:t,options:this.options,queryKey:this.queryKey,client:this.#i,state:this.state,fetchFn:i};return r(e),e})();(this.#e===`infinite`?er(this.options.pages):this.options.behavior)?.onFetch(a,this),this.#n=this.state,(this.state.fetchStatus===`idle`||this.state.fetchMeta!==a.fetchOptions?.meta)&&this.#l({type:`fetch`,meta:a.fetchOptions?.meta}),this.#a=Qn({initialPromise:t?.initialPromise,fn:a.fetchFn,onCancel:e=>{e instanceof Zn&&e.revert&&this.setState({...this.#n,fetchStatus:`idle`}),n.abort()},onFail:(e,t)=>{this.#l({type:`failed`,failureCount:e,error:t})},onPause:()=>{this.#l({type:`pause`})},onContinue:()=>{this.#l({type:`continue`})},retry:a.options.retry,retryDelay:a.options.retryDelay,networkMode:a.options.networkMode,canRun:()=>!0});try{let e=await this.#a.start();if(e===void 0)throw Error(`${this.queryHash} data is undefined`);return this.setData(e),this.#r.config.onSuccess?.(e,this),this.#r.config.onSettled?.(e,this.state.error,this),e}catch(e){if(e instanceof Zn){if(e.silent)return this.#a.promise;if(e.revert){if(this.state.data===void 0)throw e;return this.state.data}}throw this.#l({type:`error`,error:e}),this.#r.config.onError?.(e,this),this.#r.config.onSettled?.(this.state.data,e,this),e}finally{this.scheduleGc()}}#l(e){let t=t=>{switch(e.type){case`failed`:return{...t,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case`pause`:return{...t,fetchStatus:`paused`};case`continue`:return{...t,fetchStatus:`fetching`};case`fetch`:return{...t,...ir(t.data,this.options),fetchMeta:e.meta??null};case`success`:let n={...t,...ar(e.data,e.dataUpdatedAt),dataUpdateCount:t.dataUpdateCount+1,...!e.manual&&{fetchStatus:`idle`,fetchFailureCount:0,fetchFailureReason:null}};return this.#n=e.manual?n:void 0,n;case`error`:let r=e.error;return{...t,error:r,errorUpdateCount:t.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:t.fetchFailureCount+1,fetchFailureReason:r,fetchStatus:`idle`,status:`error`,isInvalidated:!0};case`invalidate`:return{...t,isInvalidated:!0};case`setState`:return{...t,...e.state}}};this.state=t(this.state),qn.batch(()=>{this.observers.forEach(e=>{e.onQueryUpdate()}),this.#r.notify({query:this,type:`updated`,action:e})})}};function ir(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:Xn(t.networkMode)?`fetching`:`paused`,...e===void 0&&{error:null,status:`pending`}}}function ar(e,t){return{data:e,dataUpdatedAt:t??Date.now(),error:null,isInvalidated:!1,status:`success`}}function or(e){let t=typeof e.initialData==`function`?e.initialData():e.initialData,n=t!==void 0,r=n?typeof e.initialDataUpdatedAt==`function`?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?`success`:`pending`,fetchStatus:`idle`}}var sr=class extends fn{constructor(e,t){super(),this.options=t,this.#e=e,this.#s=null,this.#o=Wn(),this.bindMethods(),this.setOptions(t)}#e;#t=void 0;#n=void 0;#r=void 0;#i;#a;#o;#s;#c;#l;#u;#d;#f;#p;#m=new Set;bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(this.#t.addObserver(this),lr(this.#t,this.options)?this.#h():this.updateResult(),this.#y())}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return ur(this.#t,this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return ur(this.#t,this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,this.#b(),this.#x(),this.#t.removeObserver(this)}setOptions(e){let t=this.options,n=this.#t;if(this.options=this.#e.defaultQueryOptions(e),this.options.enabled!==void 0&&typeof this.options.enabled!=`boolean`&&typeof this.options.enabled!=`function`&&typeof Cn(this.options.enabled,this.#t)!=`boolean`)throw Error(`Expected enabled to be a boolean or a callback that returns a boolean`);this.#S(),this.#t.setOptions(this.options),t._defaulted&&!jn(this.options,t)&&this.#e.getQueryCache().notify({type:`observerOptionsUpdated`,query:this.#t,observer:this});let r=this.hasListeners();r&&dr(this.#t,n,this.options,t)&&this.#h(),this.updateResult(),r&&(this.#t!==n||Cn(this.options.enabled,this.#t)!==Cn(t.enabled,this.#t)||Sn(this.options.staleTime,this.#t)!==Sn(t.staleTime,this.#t))&&this.#g();let i=this.#_();r&&(this.#t!==n||Cn(this.options.enabled,this.#t)!==Cn(t.enabled,this.#t)||i!==this.#p)&&this.#v(i)}getOptimisticResult(e){let t=this.#e.getQueryCache().build(this.#e,e),n=this.createResult(t,e);return pr(this,n)&&(this.#r=n,this.#a=this.options,this.#i=this.#t.state),n}getCurrentResult(){return this.#r}trackResult(e,t){return new Proxy(e,{get:(e,n)=>(this.trackProp(n),t?.(n),n===`promise`&&(this.trackProp(`data`),!this.options.experimental_prefetchInRender&&this.#o.status===`pending`&&this.#o.reject(Error(`experimental_prefetchInRender feature flag is not enabled`))),Reflect.get(e,n))})}trackProp(e){this.#m.add(e)}getCurrentQuery(){return this.#t}refetch({...e}={}){return this.fetch({...e})}fetchOptimistic(e){let t=this.#e.defaultQueryOptions(e),n=this.#e.getQueryCache().build(this.#e,t);return n.fetch().then(()=>this.createResult(n,t))}fetch(e){return this.#h({...e,cancelRefetch:e.cancelRefetch??!0}).then(()=>(this.updateResult(),this.#r))}#h(e){this.#S();let t=this.#t.fetch(this.options,e);return e?.throwOnError||(t=t.catch(vn)),t}#g(){this.#b();let e=Sn(this.options.staleTime,this.#t);if(Un.isServer()||this.#r.isStale||!bn(e))return;let t=xn(this.#r.dataUpdatedAt,e)+1;this.#d=hn.setTimeout(()=>{this.#r.isStale||this.updateResult()},t)}#_(){return(typeof this.options.refetchInterval==`function`?this.options.refetchInterval(this.#t):this.options.refetchInterval)??!1}#v(e){this.#x(),this.#p=e,!(Un.isServer()||Cn(this.options.enabled,this.#t)===!1||!bn(this.#p)||this.#p===0)&&(this.#f=hn.setInterval(()=>{(this.options.refetchIntervalInBackground||pn.isFocused())&&this.#h()},this.#p))}#y(){this.#g(),this.#v(this.#_())}#b(){this.#d!==void 0&&(hn.clearTimeout(this.#d),this.#d=void 0)}#x(){this.#f!==void 0&&(hn.clearInterval(this.#f),this.#f=void 0)}createResult(e,t){let n=this.#t,r=this.options,i=this.#r,a=this.#i,o=this.#a,s=e===n?this.#n:e.state,{state:c}=e,l={...c},u=!1,d;if(t._optimisticResults){let i=this.hasListeners(),a=!i&&lr(e,t),o=i&&dr(e,n,t,r);(a||o)&&(l={...l,...ir(c.data,e.options)}),t._optimisticResults===`isRestoring`&&(l.fetchStatus=`idle`)}let{error:f,errorUpdatedAt:p,status:m}=l;d=l.data;let h=!1;if(t.placeholderData!==void 0&&d===void 0&&m===`pending`){let e;i?.isPlaceholderData&&t.placeholderData===o?.placeholderData?(e=i.data,h=!0):e=typeof t.placeholderData==`function`?t.placeholderData(this.#u?.state.data,this.#u):t.placeholderData,e!==void 0&&(m=`success`,d=In(i?.data,e,t),u=!0)}if(t.select&&d!==void 0&&!h)if(i&&d===a?.data&&t.select===this.#c)d=this.#l;else try{this.#c=t.select,d=t.select(d),d=In(i?.data,d,t),this.#l=d,this.#s=null}catch(e){this.#s=e}this.#s&&(f=this.#s,d=this.#l,p=Date.now(),m=`error`);let g=l.fetchStatus===`fetching`,_=m===`pending`,v=m===`error`,y=_&&g,b=d!==void 0,x={status:m,fetchStatus:l.fetchStatus,isPending:_,isSuccess:m===`success`,isError:v,isInitialLoading:y,isLoading:y,data:d,dataUpdatedAt:l.dataUpdatedAt,error:f,errorUpdatedAt:p,failureCount:l.fetchFailureCount,failureReason:l.fetchFailureReason,errorUpdateCount:l.errorUpdateCount,isFetched:e.isFetched(),isFetchedAfterMount:l.dataUpdateCount>s.dataUpdateCount||l.errorUpdateCount>s.errorUpdateCount,isFetching:g,isRefetching:g&&!_,isLoadingError:v&&!b,isPaused:l.fetchStatus===`paused`,isPlaceholderData:u,isRefetchError:v&&b,isStale:fr(e,t),refetch:this.refetch,promise:this.#o,isEnabled:Cn(t.enabled,e)!==!1};if(this.options.experimental_prefetchInRender){let t=x.data!==void 0,r=x.status===`error`&&!t,i=e=>{r?e.reject(x.error):t&&e.resolve(x.data)},a=()=>{let e=this.#o=x.promise=Wn();i(e)},o=this.#o;switch(o.status){case`pending`:e.queryHash===n.queryHash&&i(o);break;case`fulfilled`:(r||x.data!==o.value)&&a();break;case`rejected`:(!r||x.error!==o.reason)&&a();break}}return x}updateResult(){let e=this.#r,t=this.createResult(this.#t,this.options);this.#i=this.#t.state,this.#a=this.options,this.#i.data!==void 0&&(this.#u=this.#t),!jn(t,e)&&(this.#r=t,this.#C({listeners:(()=>{if(!e)return!0;let{notifyOnChangeProps:t}=this.options,n=typeof t==`function`?t():t;if(n===`all`||!n&&!this.#m.size)return!0;let r=new Set(n??this.#m);return this.options.throwOnError&&r.add(`error`),Object.keys(this.#r).some(t=>{let n=t;return this.#r[n]!==e[n]&&r.has(n)})})()}))}#S(){let e=this.#e.getQueryCache().build(this.#e,this.options);if(e===this.#t)return;let t=this.#t;this.#t=e,this.#n=e.state,this.hasListeners()&&(t?.removeObserver(this),e.addObserver(this))}onQueryUpdate(){this.updateResult(),this.hasListeners()&&this.#y()}#C(e){qn.batch(()=>{e.listeners&&this.listeners.forEach(e=>{e(this.#r)}),this.#e.getQueryCache().notify({query:this.#t,type:`observerResultsUpdated`})})}};function cr(e,t){return Cn(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status===`error`&&Cn(t.retryOnMount,e)===!1)}function lr(e,t){return cr(e,t)||e.state.data!==void 0&&ur(e,t,t.refetchOnMount)}function ur(e,t,n){if(Cn(t.enabled,e)!==!1&&Sn(t.staleTime,e)!==`static`){let r=typeof n==`function`?n(e):n;return r===`always`||r!==!1&&fr(e,t)}return!1}function dr(e,t,n,r){return(e!==t||Cn(r.enabled,e)===!1)&&(!n.suspense||e.state.status!==`error`)&&fr(e,n)}function fr(e,t){return Cn(t.enabled,e)!==!1&&e.isStaleByTime(Sn(t.staleTime,e))}function pr(e,t){return!jn(e.getCurrentResult(),t)}var mr=class extends $n{#e;#t;#n;#r;constructor(e){super(),this.#e=e.client,this.mutationId=e.mutationId,this.#n=e.mutationCache,this.#t=[],this.state=e.state||hr(),this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options=e,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(e){this.#t.includes(e)||(this.#t.push(e),this.clearGcTimeout(),this.#n.notify({type:`observerAdded`,mutation:this,observer:e}))}removeObserver(e){this.#t=this.#t.filter(t=>t!==e),this.scheduleGc(),this.#n.notify({type:`observerRemoved`,mutation:this,observer:e})}optionalRemove(){this.#t.length||(this.state.status===`pending`?this.scheduleGc():this.#n.remove(this))}continue(){return this.#r?.continue()??this.execute(this.state.variables)}async execute(e){let t=()=>{this.#i({type:`continue`})},n={client:this.#e,meta:this.options.meta,mutationKey:this.options.mutationKey};this.#r=Qn({fn:()=>this.options.mutationFn?this.options.mutationFn(e,n):Promise.reject(Error(`No mutationFn found`)),onFail:(e,t)=>{this.#i({type:`failed`,failureCount:e,error:t})},onPause:()=>{this.#i({type:`pause`})},onContinue:t,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>this.#n.canRun(this)});let r=this.state.status===`pending`,i=!this.#r.canStart();try{if(r)t();else{this.#i({type:`pending`,variables:e,isPaused:i}),this.#n.config.onMutate&&await this.#n.config.onMutate(e,this,n);let t=await this.options.onMutate?.(e,n);t!==this.state.context&&this.#i({type:`pending`,context:t,variables:e,isPaused:i})}let a=await this.#r.start();return await this.#n.config.onSuccess?.(a,e,this.state.context,this,n),await this.options.onSuccess?.(a,e,this.state.context,n),await this.#n.config.onSettled?.(a,null,this.state.variables,this.state.context,this,n),await this.options.onSettled?.(a,null,e,this.state.context,n),this.#i({type:`success`,data:a}),a}catch(t){try{await this.#n.config.onError?.(t,e,this.state.context,this,n)}catch(e){Promise.reject(e)}try{await this.options.onError?.(t,e,this.state.context,n)}catch(e){Promise.reject(e)}try{await this.#n.config.onSettled?.(void 0,t,this.state.variables,this.state.context,this,n)}catch(e){Promise.reject(e)}try{await this.options.onSettled?.(void 0,t,e,this.state.context,n)}catch(e){Promise.reject(e)}throw this.#i({type:`error`,error:t}),t}finally{this.#n.runNext(this)}}#i(e){let t=t=>{switch(e.type){case`failed`:return{...t,failureCount:e.failureCount,failureReason:e.error};case`pause`:return{...t,isPaused:!0};case`continue`:return{...t,isPaused:!1};case`pending`:return{...t,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:e.isPaused,status:`pending`,variables:e.variables,submittedAt:Date.now()};case`success`:return{...t,data:e.data,failureCount:0,failureReason:null,error:null,status:`success`,isPaused:!1};case`error`:return{...t,data:void 0,error:e.error,failureCount:t.failureCount+1,failureReason:e.error,isPaused:!1,status:`error`}}};this.state=t(this.state),qn.batch(()=>{this.#t.forEach(t=>{t.onMutationUpdate(e)}),this.#n.notify({mutation:this,type:`updated`,action:e})})}};function hr(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:`idle`,variables:void 0,submittedAt:0}}var gr=class extends fn{constructor(e={}){super(),this.config=e,this.#e=new Set,this.#t=new Map,this.#n=0}#e;#t;#n;build(e,t,n){let r=new mr({client:e,mutationCache:this,mutationId:++this.#n,options:e.defaultMutationOptions(t),state:n});return this.add(r),r}add(e){this.#e.add(e);let t=_r(e);if(typeof t==`string`){let n=this.#t.get(t);n?n.push(e):this.#t.set(t,[e])}this.notify({type:`added`,mutation:e})}remove(e){if(this.#e.delete(e)){let t=_r(e);if(typeof t==`string`){let n=this.#t.get(t);if(n)if(n.length>1){let t=n.indexOf(e);t!==-1&&n.splice(t,1)}else n[0]===e&&this.#t.delete(t)}}this.notify({type:`removed`,mutation:e})}canRun(e){let t=_r(e);if(typeof t==`string`){let n=this.#t.get(t)?.find(e=>e.state.status===`pending`);return!n||n===e}else return!0}runNext(e){let t=_r(e);return typeof t==`string`?(this.#t.get(t)?.find(t=>t!==e&&t.state.isPaused))?.continue()??Promise.resolve():Promise.resolve()}clear(){qn.batch(()=>{this.#e.forEach(e=>{this.notify({type:`removed`,mutation:e})}),this.#e.clear(),this.#t.clear()})}getAll(){return Array.from(this.#e)}find(e){let t={exact:!0,...e};return this.getAll().find(e=>Tn(t,e))}findAll(e={}){return this.getAll().filter(t=>Tn(e,t))}notify(e){qn.batch(()=>{this.listeners.forEach(t=>{t(e)})})}resumePausedMutations(){let e=this.getAll().filter(e=>e.state.isPaused);return qn.batch(()=>Promise.all(e.map(e=>e.continue().catch(vn))))}};function _r(e){return e.options.scope?.id}var vr=class extends fn{#e;#t=void 0;#n;#r;constructor(e,t){super(),this.#e=e,this.setOptions(t),this.bindMethods(),this.#i()}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(e){let t=this.options;this.options=this.#e.defaultMutationOptions(e),jn(this.options,t)||this.#e.getMutationCache().notify({type:`observerOptionsUpdated`,mutation:this.#n,observer:this}),t?.mutationKey&&this.options.mutationKey&&Dn(t.mutationKey)!==Dn(this.options.mutationKey)?this.reset():this.#n?.state.status===`pending`&&this.#n.setOptions(this.options)}onUnsubscribe(){this.hasListeners()||this.#n?.removeObserver(this)}onMutationUpdate(e){this.#i(),this.#a(e)}getCurrentResult(){return this.#t}reset(){this.#n?.removeObserver(this),this.#n=void 0,this.#i(),this.#a()}mutate(e,t){return this.#r=t,this.#n?.removeObserver(this),this.#n=this.#e.getMutationCache().build(this.#e,this.options),this.#n.addObserver(this),this.#n.execute(e)}#i(){let e=this.#n?.state??hr();this.#t={...e,isPending:e.status===`pending`,isSuccess:e.status===`success`,isError:e.status===`error`,isIdle:e.status===`idle`,mutate:this.mutate,reset:this.reset}}#a(e){qn.batch(()=>{if(this.#r&&this.hasListeners()){let t=this.#t.variables,n=this.#t.context,r={client:this.#e,meta:this.options.meta,mutationKey:this.options.mutationKey};if(e?.type===`success`){try{this.#r.onSuccess?.(e.data,t,n,r)}catch(e){Promise.reject(e)}try{this.#r.onSettled?.(e.data,null,t,n,r)}catch(e){Promise.reject(e)}}else if(e?.type===`error`){try{this.#r.onError?.(e.error,t,n,r)}catch(e){Promise.reject(e)}try{this.#r.onSettled?.(void 0,e.error,t,n,r)}catch(e){Promise.reject(e)}}}this.listeners.forEach(e=>{e(this.#t)})})}},yr=class extends fn{constructor(e={}){super(),this.config=e,this.#e=new Map}#e;build(e,t,n){let r=t.queryKey,i=t.queryHash??En(r,t),a=this.get(i);return a||(a=new rr({client:e,queryKey:r,queryHash:i,options:e.defaultQueryOptions(t),state:n,defaultOptions:e.getQueryDefaults(r)}),this.add(a)),a}add(e){this.#e.has(e.queryHash)||(this.#e.set(e.queryHash,e),this.notify({type:`added`,query:e}))}remove(e){let t=this.#e.get(e.queryHash);t&&(e.destroy(),t===e&&this.#e.delete(e.queryHash),this.notify({type:`removed`,query:e}))}clear(){qn.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}get(e){return this.#e.get(e)}getAll(){return[...this.#e.values()]}find(e){let t={exact:!0,...e};return this.getAll().find(e=>wn(t,e))}findAll(e={}){let t=this.getAll();return Object.keys(e).length>0?t.filter(t=>wn(e,t)):t}notify(e){qn.batch(()=>{this.listeners.forEach(t=>{t(e)})})}onFocus(){qn.batch(()=>{this.getAll().forEach(e=>{e.onFocus()})})}onOnline(){qn.batch(()=>{this.getAll().forEach(e=>{e.onOnline()})})}},br=class{#e;#t;#n;#r;#i;#a;#o;#s;constructor(e={}){this.#e=e.queryCache||new yr,this.#t=e.mutationCache||new gr,this.#n=e.defaultOptions||{},this.#r=new Map,this.#i=new Map,this.#a=0}mount(){this.#a++,this.#a===1&&(this.#o=pn.subscribe(async e=>{e&&(await this.resumePausedMutations(),this.#e.onFocus())}),this.#s=Jn.subscribe(async e=>{e&&(await this.resumePausedMutations(),this.#e.onOnline())}))}unmount(){this.#a--,this.#a===0&&(this.#o?.(),this.#o=void 0,this.#s?.(),this.#s=void 0)}isFetching(e){return this.#e.findAll({...e,fetchStatus:`fetching`}).length}isMutating(e){return this.#t.findAll({...e,status:`pending`}).length}getQueryData(e){let t=this.defaultQueryOptions({queryKey:e});return this.#e.get(t.queryHash)?.state.data}ensureQueryData(e){let t=this.defaultQueryOptions(e),n=this.#e.build(this,t),r=n.state.data;return r===void 0?this.fetchQuery(e):(e.revalidateIfStale&&n.isStaleByTime(Sn(t.staleTime,n))&&this.prefetchQuery(t),Promise.resolve(r))}getQueriesData(e){return this.#e.findAll(e).map(({queryKey:e,state:t})=>[e,t.data])}setQueryData(e,t,n){let r=this.defaultQueryOptions({queryKey:e}),i=this.#e.get(r.queryHash)?.state.data,a=yn(t,i);if(a!==void 0)return this.#e.build(this,r).setData(a,{...n,manual:!0})}setQueriesData(e,t,n){return qn.batch(()=>this.#e.findAll(e).map(({queryKey:e})=>[e,this.setQueryData(e,t,n)]))}getQueryState(e){let t=this.defaultQueryOptions({queryKey:e});return this.#e.get(t.queryHash)?.state}removeQueries(e){let t=this.#e;qn.batch(()=>{t.findAll(e).forEach(e=>{t.remove(e)})})}resetQueries(e,t){let n=this.#e;return qn.batch(()=>(n.findAll(e).forEach(e=>{e.reset()}),this.refetchQueries({type:`active`,...e},t)))}cancelQueries(e,t={}){let n={revert:!0,...t},r=qn.batch(()=>this.#e.findAll(e).map(e=>e.cancel(n)));return Promise.all(r).then(vn).catch(vn)}invalidateQueries(e,t={}){return qn.batch(()=>(this.#e.findAll(e).forEach(e=>{e.invalidate()}),e?.refetchType===`none`?Promise.resolve():this.refetchQueries({...e,type:e?.refetchType??e?.type??`active`},t)))}refetchQueries(e,t={}){let n={...t,cancelRefetch:t.cancelRefetch??!0},r=qn.batch(()=>this.#e.findAll(e).filter(e=>!e.isDisabled()&&!e.isStatic()).map(e=>{let t=e.fetch(void 0,n);return n.throwOnError||(t=t.catch(vn)),e.state.fetchStatus===`paused`?Promise.resolve():t}));return Promise.all(r).then(vn)}fetchQuery(e){let t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);let n=this.#e.build(this,t);return n.isStaleByTime(Sn(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(vn).catch(vn)}fetchInfiniteQuery(e){return e._type=`infinite`,this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(vn).catch(vn)}ensureInfiniteQueryData(e){return e._type=`infinite`,this.ensureQueryData(e)}resumePausedMutations(){return Jn.isOnline()?this.#t.resumePausedMutations():Promise.resolve()}getQueryCache(){return this.#e}getMutationCache(){return this.#t}getDefaultOptions(){return this.#n}setDefaultOptions(e){this.#n=e}setQueryDefaults(e,t){this.#r.set(Dn(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){let t=[...this.#r.values()],n={};return t.forEach(t=>{On(e,t.queryKey)&&Object.assign(n,t.defaultOptions)}),n}setMutationDefaults(e,t){this.#i.set(Dn(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){let t=[...this.#i.values()],n={};return t.forEach(t=>{On(e,t.mutationKey)&&Object.assign(n,t.defaultOptions)}),n}defaultQueryOptions(e){if(e._defaulted)return e;let t={...this.#n.queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||=En(t.queryKey,t),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!==`always`),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode=`offlineFirst`),t.queryFn===zn&&(t.enabled=!1),t}defaultMutationOptions(e){return e?._defaulted?e:{...this.#n.mutations,...e?.mutationKey&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){this.#e.clear(),this.#t.clear()}},G=t(e(),1),K=a(),xr=G.createContext(void 0),Sr=e=>{let t=G.useContext(xr);if(e)return e;if(!t)throw Error(`No QueryClient set, use QueryClientProvider to set one`);return t},Cr=({client:e,children:t})=>(G.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),(0,K.jsx)(xr.Provider,{value:e,children:t})),wr=G.createContext(!1),Tr=()=>G.useContext(wr);wr.Provider;function Er(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var Dr=G.createContext(Er()),Or=()=>G.useContext(Dr),kr=(e,t,n)=>{let r=n?.state.error&&typeof e.throwOnError==`function`?Vn(e.throwOnError,[n.state.error,n]):e.throwOnError;(e.suspense||e.experimental_prefetchInRender||r)&&(t.isReset()||(e.retryOnMount=!1))},Ar=e=>{G.useEffect(()=>{e.clearReset()},[e])},jr=({result:e,errorResetBoundary:t,throwOnError:n,query:r,suspense:i})=>e.isError&&!t.isReset()&&!e.isFetching&&r&&(i&&e.data===void 0||Vn(n,[e.error,r])),Mr=e=>{if(e.suspense){let t=1e3,n=e=>e===`static`?e:Math.max(e??t,t),r=e.staleTime;e.staleTime=typeof r==`function`?(...e)=>n(r(...e)):n(r),typeof e.gcTime==`number`&&(e.gcTime=Math.max(e.gcTime,t))}},Nr=(e,t)=>e.isLoading&&e.isFetching&&!t,Pr=(e,t)=>e?.suspense&&t.isPending,Fr=(e,t,n)=>t.fetchOptimistic(e).catch(()=>{n.clearReset()});function Ir(e,t,n){let r=Tr(),i=Or(),a=Sr(n),o=a.defaultQueryOptions(e);a.getDefaultOptions().queries?._experimental_beforeQuery?.(o);let s=a.getQueryCache().get(o.queryHash),c=e.subscribed!==!1;o._optimisticResults=r?`isRestoring`:c?`optimistic`:void 0,Mr(o),kr(o,i,s),Ar(i);let l=!a.getQueryCache().get(o.queryHash),[u]=G.useState(()=>new t(a,o)),d=u.getOptimisticResult(o),f=!r&&c;if(G.useSyncExternalStore(G.useCallback(e=>{let t=f?u.subscribe(qn.batchCalls(e)):vn;return u.updateResult(),t},[u,f]),()=>u.getCurrentResult(),()=>u.getCurrentResult()),G.useEffect(()=>{u.setOptions(o)},[o,u]),Pr(o,d))throw Fr(o,u,i);if(jr({result:d,errorResetBoundary:i,throwOnError:o.throwOnError,query:s,suspense:o.suspense}))throw d.error;return a.getDefaultOptions().queries?._experimental_afterQuery?.(o,d),o.experimental_prefetchInRender&&!Un.isServer()&&Nr(d,r)&&(l?Fr(o,u,i):s?.promise)?.catch(vn).finally(()=>{u.updateResult()}),o.notifyOnChangeProps?d:u.trackResult(d)}function Lr(e,t){return Ir(e,sr,t)}function Rr(e,t){let n=Sr(t),[r]=G.useState(()=>new vr(n,e));G.useEffect(()=>{r.setOptions(e)},[r,e]);let i=G.useSyncExternalStore(G.useCallback(e=>r.subscribe(qn.batchCalls(e)),[r]),()=>r.getCurrentResult(),()=>r.getCurrentResult()),a=G.useCallback((e,t)=>{r.mutate(e,t).catch(vn)},[r]);if(i.error&&Vn(r.options.throwOnError,[i.error]))throw i.error;return{...i,mutate:a,mutateAsync:i.mutate}}var zr=dn(),Br=o(`activity`,[[`path`,{d:`M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2`,key:`169zse`}]]),Vr=o(`arrow-right`,[[`path`,{d:`M5 12h14`,key:`1ays0h`}],[`path`,{d:`m12 5 7 7-7 7`,key:`xquz4c`}]]),Hr=o(`arrow-up-down`,[[`path`,{d:`m21 16-4 4-4-4`,key:`f6ql7i`}],[`path`,{d:`M17 20V4`,key:`1ejh1v`}],[`path`,{d:`m3 8 4-4 4 4`,key:`11wl7u`}],[`path`,{d:`M7 4v16`,key:`1glfcx`}]]),Ur=o(`book-open`,[[`path`,{d:`M12 7v14`,key:`1akyts`}],[`path`,{d:`M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z`,key:`ruj8y`}]]),Wr=o(`boxes`,[[`path`,{d:`M2.97 12.92A2 2 0 0 0 2 14.63v3.24a2 2 0 0 0 .97 1.71l3 1.8a2 2 0 0 0 2.06 0L12 19v-5.5l-5-3-4.03 2.42Z`,key:`lc1i9w`}],[`path`,{d:`m7 16.5-4.74-2.85`,key:`1o9zyk`}],[`path`,{d:`m7 16.5 5-3`,key:`va8pkn`}],[`path`,{d:`M7 16.5v5.17`,key:`jnp8gn`}],[`path`,{d:`M12 13.5V19l3.97 2.38a2 2 0 0 0 2.06 0l3-1.8a2 2 0 0 0 .97-1.71v-3.24a2 2 0 0 0-.97-1.71L17 10.5l-5 3Z`,key:`8zsnat`}],[`path`,{d:`m17 16.5-5-3`,key:`8arw3v`}],[`path`,{d:`m17 16.5 4.74-2.85`,key:`8rfmw`}],[`path`,{d:`M17 16.5v5.17`,key:`k6z78m`}],[`path`,{d:`M7.97 4.42A2 2 0 0 0 7 6.13v4.37l5 3 5-3V6.13a2 2 0 0 0-.97-1.71l-3-1.8a2 2 0 0 0-2.06 0l-3 1.8Z`,key:`1xygjf`}],[`path`,{d:`M12 8 7.26 5.15`,key:`1vbdud`}],[`path`,{d:`m12 8 4.74-2.85`,key:`3rx089`}],[`path`,{d:`M12 13.5V8`,key:`1io7kd`}]]),Gr=o(`check`,[[`path`,{d:`M20 6 9 17l-5-5`,key:`1gmf2c`}]]),Kr=o(`chevron-up`,[[`path`,{d:`m18 15-6-6-6 6`,key:`153udz`}]]),qr=o(`circle-alert`,[[`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`}]]),Jr=o(`copy`,[[`rect`,{width:`14`,height:`14`,x:`8`,y:`8`,rx:`2`,ry:`2`,key:`17jyea`}],[`path`,{d:`M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2`,key:`zix9uf`}]]),Yr=o(`external-link`,[[`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`}]]),Xr=o(`folder-git-2`,[[`path`,{d:`M18 19a5 5 0 0 1-5-5v8`,key:`sz5oeg`}],[`path`,{d:`M9 20H4a2 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.9H20a2 2 0 0 1 2 2v5`,key:`1w6njk`}],[`circle`,{cx:`13`,cy:`12`,r:`2`,key:`1j92g6`}],[`circle`,{cx:`20`,cy:`19`,r:`2`,key:`1obnsp`}]]),Zr=o(`info`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 16v-4`,key:`1dtifu`}],[`path`,{d:`M12 8h.01`,key:`e9boi3`}]]),Qr=o(`loader-circle`,[[`path`,{d:`M21 12a9 9 0 1 1-6.219-8.56`,key:`13zald`}]]),$r=o(`moon`,[[`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`}]]),ei=o(`play`,[[`path`,{d:`M5 5a2 2 0 0 1 3.008-1.728l11.997 6.998a2 2 0 0 1 .003 3.458l-12 7A2 2 0 0 1 5 19z`,key:`10ikf1`}]]),ti=o(`plus`,[[`path`,{d:`M5 12h14`,key:`1ays0h`}],[`path`,{d:`M12 5v14`,key:`s699le`}]]),ni=o(`refresh-cw`,[[`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`}]]),ri=o(`settings`,[[`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`}]]),ii=o(`sparkles`,[[`path`,{d:`M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z`,key:`1s2grr`}],[`path`,{d:`M20 2v4`,key:`1rf3ol`}],[`path`,{d:`M22 4h-4`,key:`gwowj6`}],[`circle`,{cx:`4`,cy:`20`,r:`2`,key:`6kqj1y`}]]),ai=o(`sun`,[[`circle`,{cx:`12`,cy:`12`,r:`4`,key:`4exip2`}],[`path`,{d:`M12 2v2`,key:`tus03m`}],[`path`,{d:`M12 20v2`,key:`1lh1kg`}],[`path`,{d:`m4.93 4.93 1.41 1.41`,key:`149t6j`}],[`path`,{d:`m17.66 17.66 1.41 1.41`,key:`ptbguv`}],[`path`,{d:`M2 12h2`,key:`1t8f8n`}],[`path`,{d:`M20 12h2`,key:`1q8mjw`}],[`path`,{d:`m6.34 17.66-1.41 1.41`,key:`1m8zz5`}],[`path`,{d:`m19.07 4.93-1.41 1.41`,key:`1shlcs`}]]),oi=o(`terminal`,[[`path`,{d:`M12 19h8`,key:`baeox8`}],[`path`,{d:`m4 17 6-6-6-6`,key:`1yngyt`}]]),si=o(`triangle-alert`,[[`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`}]]),ci=o(`workflow`,[[`rect`,{width:`8`,height:`8`,x:`3`,y:`3`,rx:`2`,key:`by2w9f`}],[`path`,{d:`M7 11v4a2 2 0 0 0 2 2h4`,key:`xkn7yn`}],[`rect`,{width:`8`,height:`8`,x:`13`,y:`13`,rx:`2`,key:`1cgmvn`}]]),li={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},ui=G.createContext&&G.createContext(li),di=[`attr`,`size`,`title`];function fi(e,t){if(e==null)return{};var n,r,i=pi(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function pi(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function mi(){return mi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},mi.apply(null,arguments)}function hi(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function gi(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?hi(Object(n),!0).forEach(function(t){_i(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):hi(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function _i(e,t,n){return(t=vi(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function vi(e){var t=yi(e,`string`);return typeof t==`symbol`?t:t+``}function yi(e,t){if(typeof e!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(typeof r!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function bi(e){return e&&e.map((e,t)=>G.createElement(e.tag,gi({key:t},e.attr),bi(e.child)))}function xi(e){return t=>G.createElement(Si,mi({attr:gi({},e.attr)},t),bi(e.child))}function Si(e){var t=t=>{var n=e.attr,r=e.size,i=e.title,a=fi(e,di),o=r||t.size||`1em`,s;return t.className&&(s=t.className),e.className&&(s=(s?s+` `:``)+e.className),G.createElement(`svg`,mi({stroke:`currentColor`,fill:`currentColor`,strokeWidth:`0`},t.attr,n,a,{className:s,style:gi(gi({color:e.color||t.color},t.style),e.style),height:o,width:o,xmlns:`http://www.w3.org/2000/svg`}),i&&G.createElement(`title`,null,i),e.children)};return ui===void 0?t(li):G.createElement(ui.Consumer,null,e=>t(e))}function Ci(e){return xi({tag:`svg`,attr:{fill:`currentColor`,viewBox:`0 0 16 16`},child:[{tag:`path`,attr:{d:`M14.949 6.547a3.94 3.94 0 0 0-.348-3.273 4.11 4.11 0 0 0-4.4-1.934A4.1 4.1 0 0 0 8.423.2 4.15 4.15 0 0 0 6.305.086a4.1 4.1 0 0 0-1.891.948 4.04 4.04 0 0 0-1.158 1.753 4.1 4.1 0 0 0-1.563.679A4 4 0 0 0 .554 4.72a3.99 3.99 0 0 0 .502 4.731 3.94 3.94 0 0 0 .346 3.274 4.11 4.11 0 0 0 4.402 1.933c.382.425.852.764 1.377.995.526.231 1.095.35 1.67.346 1.78.002 3.358-1.132 3.901-2.804a4.1 4.1 0 0 0 1.563-.68 4 4 0 0 0 1.14-1.253 3.99 3.99 0 0 0-.506-4.716m-6.097 8.406a3.05 3.05 0 0 1-1.945-.694l.096-.054 3.23-1.838a.53.53 0 0 0 .265-.455v-4.49l1.366.778q.02.011.025.035v3.722c-.003 1.653-1.361 2.992-3.037 2.996m-6.53-2.75a2.95 2.95 0 0 1-.36-2.01l.095.057L5.29 12.09a.53.53 0 0 0 .527 0l3.949-2.246v1.555a.05.05 0 0 1-.022.041L6.473 13.3c-1.454.826-3.311.335-4.15-1.098m-.85-6.94A3.02 3.02 0 0 1 3.07 3.949v3.785a.51.51 0 0 0 .262.451l3.93 2.237-1.366.779a.05.05 0 0 1-.048 0L2.585 9.342a2.98 2.98 0 0 1-1.113-4.094zm11.216 2.571L8.747 5.576l1.362-.776a.05.05 0 0 1 .048 0l3.265 1.86a3 3 0 0 1 1.173 1.207 2.96 2.96 0 0 1-.27 3.2 3.05 3.05 0 0 1-1.36.997V8.279a.52.52 0 0 0-.276-.445m1.36-2.015-.097-.057-3.226-1.855a.53.53 0 0 0-.53 0L6.249 6.153V4.598a.04.04 0 0 1 .019-.04L9.533 2.7a3.07 3.07 0 0 1 3.257.139c.474.325.843.778 1.066 1.303.223.526.289 1.103.191 1.664zM5.503 8.575 4.139 7.8a.05.05 0 0 1-.026-.037V4.049c0-.57.166-1.127.476-1.607s.752-.864 1.275-1.105a3.08 3.08 0 0 1 3.234.41l-.096.054-3.23 1.838a.53.53 0 0 0-.265.455zm.742-1.577 1.758-1 1.762 1v2l-1.755 1-1.762-1z`},child:[]}]})(e)}function wi(e){return xi({tag:`svg`,attr:{role:`img`,viewBox:`0 0 24 24`},child:[{tag:`path`,attr:{d:`M2.25 1.5a.75.75 0 0 0-.75.75v16.5H0V2.25A2.25 2.25 0 0 1 2.25 0h20.095c1.002 0 1.504 1.212.795 1.92L10.764 14.298h3.486V12.75h1.5v1.922a1.125 1.125 0 0 1-1.125 1.125H9.264l-2.578 2.578h11.689V9h1.5v9.375a1.5 1.5 0 0 1-1.5 1.5H5.185L2.562 22.5H21.75a.75.75 0 0 0 .75-.75V5.25H24v16.5A2.25 2.25 0 0 1 21.75 24H1.655C.653 24 .151 22.788.86 22.08L13.19 9.75H9.75v1.5h-1.5V9.375A1.125 1.125 0 0 1 9.375 8.25h5.314l2.625-2.625H5.625V15h-1.5V5.625a1.5 1.5 0 0 1 1.5-1.5h13.19L21.438 1.5z`},child:[]}]})(e)}function Ti(e){return xi({tag:`svg`,attr:{role:`img`,viewBox:`0 0 24 24`},child:[{tag:`path`,attr:{d:`M23.55 5.067c-1.2038-.002-2.1806.973-2.1806 2.1765v4.8676c0 .972-.8035 1.7594-1.7597 1.7594-.568 0-1.1352-.286-1.4718-.7659l-4.9713-7.1003c-.4125-.5896-1.0837-.941-1.8103-.941-1.1334 0-2.1533.9635-2.1533 2.153v4.8957c0 .972-.7969 1.7594-1.7596 1.7594-.57 0-1.1363-.286-1.4728-.7658L.4076 5.1598C.2822 4.9798 0 5.0688 0 5.2882v4.2452c0 .2147.0656.4228.1884.599l5.4748 7.8183c.3234.462.8006.8052 1.3509.9298 1.3771.313 2.6446-.747 2.6446-2.0977v-4.893c0-.972.7875-1.7593 1.7596-1.7593h.003a1.798 1.798 0 0 1 1.4718.7658l4.9723 7.0994c.4135.5905 1.05.941 1.8093.941 1.1587 0 2.1515-.9645 2.1515-2.153v-4.8948c0-.972.7875-1.7594 1.7596-1.7594h.194a.22.22 0 0 0 .2204-.2202v-4.622a.22.22 0 0 0-.2203-.2203Z`},child:[]}]})(e)}function Ei(e){return xi({tag:`svg`,attr:{role:`img`,viewBox:`0 0 24 24`},child:[{tag:`path`,attr:{d:`M0 0v24h24V0H0zm17.889 2.889c1.444 0 2.667.444 3.667 1.278l-1.111 1.667c-.889-.611-1.722-1-2.556-1s-1.278.389-1.278.889v.056c0 .667.444.889 2.111 1.333 2 .556 3.111 1.278 3.111 3v.056c0 2-1.5 3.111-3.611 3.111-1.5-.056-3-.611-4.167-1.667l1.278-1.556c.889.722 1.833 1.222 2.944 1.222.889 0 1.389-.333 1.389-.944v-.056c0-.556-.333-.833-2-1.278-2-.5-3.222-1.056-3.222-3.056v-.056c0-1.833 1.444-3 3.444-3zm-16.111.222h2.278l1.5 5.778 1.722-5.778h1.667l1.667 5.778 1.5-5.778h2.333l-2.833 9.944H9.723L8.112 7.277l-1.667 5.778H4.612L1.779 3.111zm.5 16.389h9V21h-9v-1.5z`},child:[]}]})(e)}function Di(e){return xi({tag:`svg`,attr:{role:`img`,viewBox:`0 0 24 24`},child:[{tag:`path`,attr:{d:`M20.953.004a.397.397 0 0 0-.18.017L3.225 5.585c-.175.055-.323.214-.402.398a.42.42 0 0 0-.06.22v5.726a.42.42 0 0 0 .06.22c.079.183.227.341.402.397l7.454 2.364-7.454 2.363c-.255.08-.463.374-.463.655v5.688c0 .282.208.444.463.363l17.55-5.565c.237-.075.426-.336.452-.6.003-.022.013-.04.013-.065V12.06c0-.281-.208-.575-.463-.656L13.4 9.065l7.375-2.339c.255-.08.462-.375.462-.656V.384c0-.211-.117-.355-.283-.38z`},child:[]}]})(e)}function Oi(e){return xi({tag:`svg`,attr:{role:`img`,viewBox:`0 0 24 24`},child:[{tag:`path`,attr:{d:`M7.833 6.666v-.055c0-1-.667-1.5-1.778-1.5H4.389v3.055h1.723c1.111 0 1.721-.666 1.721-1.5zM0 0v24h24V0H0zm2.223 3.167h4c2.389 0 3.833 1.389 3.833 3.445v.055c0 2.278-1.778 3.5-4.001 3.5H4.389v2.945H2.223V3.167zM11.277 21h-9v-1.5h9V21zm4.779-7.777c-2.944.055-5.111-2.223-5.111-5.057C10.944 5.333 13.056 3 16.111 3c1.889 0 3 .611 3.944 1.556l-1.389 1.61c-.778-.722-1.556-1.111-2.556-1.111-1.658 0-2.873 1.375-2.887 3.084.014 1.709 1.174 3.083 2.887 3.083 1.111 0 1.833-.445 2.61-1.167l1.39 1.389c-.999 1.112-2.166 1.779-4.054 1.779z`},child:[]}]})(e)}function ki(e){return xi({tag:`svg`,attr:{role:`img`,viewBox:`0 0 24 24`},child:[{tag:`path`,attr:{d:`M0 0v24h24V0zm3.723 3.111h5v1.834h-1.39v6.277h1.39v1.834h-5v-1.834h1.444V4.945H3.723zm11.055 0H17v6.5c0 .612-.055 1.111-.222 1.556-.167.444-.39.777-.723 1.11-.277.279-.666.557-1.11.668a3.933 3.933 0 0 1-1.445.278c-.778 0-1.444-.167-1.944-.445a4.81 4.81 0 0 1-1.279-1.056l1.39-1.555c.277.334.555.555.833.722.277.167.611.278.945.278.389 0 .721-.111 1-.389.221-.278.333-.667.333-1.278zM2.222 19.5h9V21h-9z`},child:[]}]})(e)}function Ai(e){return xi({tag:`svg`,attr:{role:`img`,viewBox:`0 0 24 24`},child:[{tag:`path`,attr:{d:`M23.922 16.997C23.061 18.492 18.063 22.02 12 22.02 5.937 22.02.939 18.492.078 16.997A.641.641 0 0 1 0 16.741v-2.869a.883.883 0 0 1 .053-.22c.372-.935 1.347-2.292 2.605-2.656.167-.429.414-1.055.644-1.517a10.098 10.098 0 0 1-.052-1.086c0-1.331.282-2.499 1.132-3.368.397-.406.89-.717 1.474-.952C7.255 2.937 9.248 1.98 11.978 1.98c2.731 0 4.767.957 6.166 2.093.584.235 1.077.546 1.474.952.85.869 1.132 2.037 1.132 3.368 0 .368-.014.733-.052 1.086.23.462.477 1.088.644 1.517 1.258.364 2.233 1.721 2.605 2.656a.841.841 0 0 1 .053.22v2.869a.641.641 0 0 1-.078.256Zm-11.75-5.992h-.344a4.359 4.359 0 0 1-.355.508c-.77.947-1.918 1.492-3.508 1.492-1.725 0-2.989-.359-3.782-1.259a2.137 2.137 0 0 1-.085-.104L4 11.746v6.585c1.435.779 4.514 2.179 8 2.179 3.486 0 6.565-1.4 8-2.179v-6.585l-.098-.104s-.033.045-.085.104c-.793.9-2.057 1.259-3.782 1.259-1.59 0-2.738-.545-3.508-1.492a4.359 4.359 0 0 1-.355-.508Zm2.328 3.25c.549 0 1 .451 1 1v2c0 .549-.451 1-1 1-.549 0-1-.451-1-1v-2c0-.549.451-1 1-1Zm-5 0c.549 0 1 .451 1 1v2c0 .549-.451 1-1 1-.549 0-1-.451-1-1v-2c0-.549.451-1 1-1Zm3.313-6.185c.136 1.057.403 1.913.878 2.497.442.544 1.134.938 2.344.938 1.573 0 2.292-.337 2.657-.751.384-.435.558-1.15.558-2.361 0-1.14-.243-1.847-.705-2.319-.477-.488-1.319-.862-2.824-1.025-1.487-.161-2.192.138-2.533.529-.269.307-.437.808-.438 1.578v.021c0 .265.021.562.063.893Zm-1.626 0c.042-.331.063-.628.063-.894v-.02c-.001-.77-.169-1.271-.438-1.578-.341-.391-1.046-.69-2.533-.529-1.505.163-2.347.537-2.824 1.025-.462.472-.705 1.179-.705 2.319 0 1.211.175 1.926.558 2.361.365.414 1.084.751 2.657.751 1.21 0 1.902-.394 2.344-.938.475-.584.742-1.44.878-2.497Z`},child:[]}]})(e)}function ji(e){return xi({tag:`svg`,attr:{role:`img`,viewBox:`0 0 24 24`},child:[{tag:`path`,attr:{d:`M11.503.131 1.891 5.678a.84.84 0 0 0-.42.726v11.188c0 .3.162.575.42.724l9.609 5.55a1 1 0 0 0 .998 0l9.61-5.55a.84.84 0 0 0 .42-.724V6.404a.84.84 0 0 0-.42-.726L12.497.131a1.01 1.01 0 0 0-.996 0M2.657 6.338h18.55c.263 0 .43.287.297.515L12.23 22.918c-.062.107-.229.064-.229-.06V12.335a.59.59 0 0 0-.295-.51l-9.11-5.257c-.109-.063-.064-.23.061-.23`},child:[]}]})(e)}function Mi(e){return xi({tag:`svg`,attr:{role:`img`,viewBox:`0 0 24 24`},child:[{tag:`path`,attr:{d:`m4.7144 15.9555 4.7174-2.6471.079-.2307-.079-.1275h-.2307l-.7893-.0486-2.6956-.0729-2.3375-.0971-2.2646-.1214-.5707-.1215-.5343-.7042.0546-.3522.4797-.3218.686.0608 1.5179.1032 2.2767.1578 1.6514.0972 2.4468.255h.3886l.0546-.1579-.1336-.0971-.1032-.0972L6.973 9.8356l-2.55-1.6879-1.3356-.9714-.7225-.4918-.3643-.4614-.1578-1.0078.6557-.7225.8803.0607.2246.0607.8925.686 1.9064 1.4754 2.4893 1.8336.3643.3035.1457-.1032.0182-.0728-.164-.2733-1.3539-2.4467-1.445-2.4893-.6435-1.032-.17-.6194c-.0607-.255-.1032-.4674-.1032-.7285L6.287.1335 6.6997 0l.9957.1336.419.3642.6192 1.4147 1.0018 2.2282 1.5543 3.0296.4553.8985.2429.8318.091.255h.1579v-.1457l.1275-1.706.2368-2.0947.2307-2.6957.0789-.7589.3764-.9107.7468-.4918.5828.2793.4797.686-.0668.4433-.2853 1.8517-.5586 2.9021-.3643 1.9429h.2125l.2429-.2429.9835-1.3053 1.6514-2.0643.7286-.8196.85-.9046.5464-.4311h1.0321l.759 1.1293-.34 1.1657-1.0625 1.3478-.8804 1.1414-1.2628 1.7-.7893 1.36.0729.1093.1882-.0183 2.8535-.607 1.5421-.2794 1.8396-.3157.8318.3886.091.3946-.3278.8075-1.967.4857-2.3072.4614-3.4364.8136-.0425.0304.0486.0607 1.5482.1457.6618.0364h1.621l3.0175.2247.7892.522.4736.6376-.079.4857-1.2142.6193-1.6393-.3886-3.825-.9107-1.3113-.3279h-.1822v.1093l1.0929 1.0686 2.0035 1.8092 2.5075 2.3314.1275.5768-.3218.4554-.34-.0486-2.2039-1.6575-.85-.7468-1.9246-1.621h-.1275v.17l.4432.6496 2.3436 3.5214.1214 1.0807-.17.3521-.6071.2125-.6679-.1214-1.3721-1.9246L14.38 17.959l-1.1414-1.9428-.1397.079-.674 7.2552-.3156.3703-.7286.2793-.6071-.4614-.3218-.7468.3218-1.4753.3886-1.9246.3157-1.53.2853-1.9004.17-.6314-.0121-.0425-.1397.0182-1.4328 1.9672-2.1796 2.9446-1.7243 1.8456-.4128.164-.7164-.3704.0667-.6618.4008-.5889 2.386-3.0357 1.4389-1.882.929-1.0868-.0062-.1579h-.0546l-6.3385 4.1164-1.1293.1457-.4857-.4554.0608-.7467.2307-.2429 1.9064-1.3114Z`},child:[]}]})(e)}var Ni=`/assets/antigravity-logo-DRKQga2U.png`;function Pi({className:e,size:t,alt:n=`Google Antigravity`,...r}){return(0,K.jsx)(`img`,{src:Ni,alt:n,className:c(`inline-block object-contain select-none shrink-0`,e),style:t?{width:t,height:t}:void 0,...r})}var Fi=G.createContext(void 0);function Ii(e){let t=G.useContext(Fi);if(t===void 0&&!e)throw Error(d(33));return t}var Li=G.createContext(void 0);function Ri(e){let t=G.useContext(Li);if(t===void 0&&!e)throw Error(d(36));return t}var zi=G.createContext(void 0);function Bi(e=!0){let t=G.useContext(zi);if(t===void 0&&!e)throw Error(d(25));return t}function Vi(e){let{closeOnClick:t,highlighted:n,id:r,nodeId:i,store:a,typingRef:o,itemRef:s,itemMetadata:c}=e,{events:l}=a.useState(`floatingTreeRoot`),u=a.useState(`open`),d=Bi(!0),f=d!==void 0;return G.useMemo(()=>({id:r,role:`menuitem`,tabIndex:u&&n?0:-1,onKeyDown(e){e.key===` `&&o?.current&&e.preventDefault()},onMouseMove(e){i&&l.emit(`itemhover`,{nodeId:i,target:e.currentTarget})},onClick(e){t&&l.emit(`close`,{domEvent:e,reason:P})},onMouseUp(e){if(d){let t=d.initialCursorPointRef.current;if(d.initialCursorPointRef.current=null,f&&t&&Math.abs(e.clientX-t.x)<=1&&Math.abs(e.clientY-t.y)<=1||f&&!Ae&&e.button===2)return}s.current&&a.context.allowMouseUpTriggerRef.current&&(!f||e.button===2)&&(!c||c.type===`regular-item`)&&s.current.click()}}),[t,n,r,l,i,u,a,o,s,d,f,c])}var Hi={type:`regular-item`};function Ui(e){let{closeOnClick:t,disabled:n=!1,highlighted:i,id:a,store:o,typingRef:s=o.context.typingRef,nativeButton:c,itemMetadata:l,nodeId:d}=e,f=o.useState(`disabled`),p=n||f,m=G.useRef(null),{getButtonProps:h,buttonRef:g}=et({disabled:p,focusableWhenDisabled:!0,native:c,composite:!0}),_=Vi({closeOnClick:t,highlighted:i,id:a,nodeId:d,store:o,typingRef:s,itemRef:m,itemMetadata:l}),v=G.useCallback(e=>u(_,{onMouseEnter(){l.type===`submenu-trigger`&&l.setActive()}},e,h),[_,h,l]),y=r(m,g);return G.useMemo(()=>({getItemProps:v,itemRef:y}),[v,y])}var Wi=G.forwardRef(function(e,t){let{render:n,className:r,id:i,label:a,nativeButton:o=!1,disabled:c=!1,closeOnClick:l=!0,style:u,...d}=e,f=tn({label:a}),p=Ii(!0),m=Ie(i),{store:h}=Ri(),g=h.useState(`isActive`,f.index),_=h.useState(`itemProps`),{getItemProps:v,itemRef:y}=Ui({closeOnClick:l,disabled:c,highlighted:g,id:m,store:h,nativeButton:o,nodeId:p?.context.nodeId,itemMetadata:Hi});return s(`div`,e,{state:{disabled:c,highlighted:g},props:[_,d,v],ref:[y,t,f.ref]})});function Gi(e,t){return t!=null&&!M(t)?0:typeof e==`function`?e():e}function Ki(e,t,n){let r=Gi(e,n);return typeof r==`number`?r:r?.[t]}function qi(e){return typeof e==`function`?e():e}function Ji(e,t){return t||e===`click`||e===`mousedown`}function Yi(e){return e?.includes(`mouse`)&&e!==`mousedown`}var Xi=Ae&&at;function Zi(e,t={}){let{enabled:n=!0,delay:r}=t,i=`rootStore`in e?e.rootStore:e,{events:a,dataRef:o}=i.context,s=G.useRef(!1),c=G.useRef(null),l=G.useRef(!0),u=it();G.useEffect(()=>{let e=i.select(`domReferenceElement`);if(!n)return;let t=yt(e);function r(){let e=i.select(`domReferenceElement`);!i.select(`open`)&&me(e)&&e===D(ge(e))&&(s.current=!0)}function a(){l.current=!0}function o(){l.current=!1}return w(oe(t,`blur`,r),Xi&&oe(t,`keydown`,a,!0),Xi&&oe(t,`pointerdown`,o,!0))},[i,n]),G.useEffect(()=>{if(!n)return;function e(e){if(e.reason===`trigger-press`||e.reason===`escape-key`){let e=i.select(`domReferenceElement`);_t(e)&&(c.current=e,s.current=!0)}}return a.on(`openchange`,e),()=>{a.off(`openchange`,e)}},[a,n,i]);let d=G.useMemo(()=>{function e(){s.current=!1,c.current=null}return{onMouseLeave(){e()},onFocus(t){let n=t.currentTarget;if(s.current){if(c.current===n)return;e()}let a=V(t.nativeEvent);if(_t(a)){if(Xi&&!t.relatedTarget){if(!l.current&&!U(a))return}else if(!le(a))return}let o=We(t.relatedTarget,i.context.triggerElements),{nativeEvent:d,currentTarget:f}=t,p=typeof r==`function`?r():r;if(i.select(`open`)&&o||p===0||p===void 0){i.setOpen(!0,_(j,d,f));return}u.start(p,()=>{s.current||i.setOpen(!0,_(j,d,f))})},onBlur(t){e();let n=t.relatedTarget,r=t.nativeEvent,a=_t(n)&&n.hasAttribute(mt(`focus-guard`))&&n.getAttribute(`data-type`)===`outside`;u.start(0,()=>{let e=i.select(`domReferenceElement`),t=D(ge(e));!n&&t===e||F(o.current.floatingContext?.refs.floating.current,t)||F(e,t)||a||We(n??t,i.context.triggerElements)||i.setOpen(!1,_(j,r))})}}},[o,r,i,u]);return G.useMemo(()=>n?{reference:d,trigger:d}:{},[n,d])}var Qi=class e{constructor(){this.pointerType=void 0,this.interactedInside=!1,this.handler=void 0,this.blockMouseMove=!0,this.performedPointerEventsMutation=!1,this.pointerEventsScopeElement=null,this.pointerEventsReferenceElement=null,this.pointerEventsFloatingElement=null,this.restTimeoutPending=!1,this.openChangeTimeout=new z,this.restTimeout=new z,this.handleCloseOptions=void 0}static create(){return new e}dispose=()=>{this.openChangeTimeout.clear(),this.restTimeout.clear()};disposeEffect=()=>this.dispose},$i=new WeakMap;function ea(e){if(!e.performedPointerEventsMutation)return;let t=e.pointerEventsScopeElement;t&&$i.get(t)===e&&(e.pointerEventsScopeElement?.style.removeProperty(`pointer-events`),e.pointerEventsReferenceElement?.style.removeProperty(`pointer-events`),e.pointerEventsFloatingElement?.style.removeProperty(`pointer-events`),$i.delete(t)),e.performedPointerEventsMutation=!1,e.pointerEventsScopeElement=null,e.pointerEventsReferenceElement=null,e.pointerEventsFloatingElement=null}function ta(e,t){let{scopeElement:n,referenceElement:r,floatingElement:i}=t,a=$i.get(n);a&&a!==e&&ea(a),ea(e),e.performedPointerEventsMutation=!0,e.pointerEventsScopeElement=n,e.pointerEventsReferenceElement=r,e.pointerEventsFloatingElement=i,$i.set(n,e),n.style.pointerEvents=`none`,r.style.pointerEvents=`auto`,i.style.pointerEvents=`auto`}function na(e){let t=e.context.dataRef.current,n=i(()=>t.hoverInteractionState??Qi.create()).current;return t.hoverInteractionState||=n,fe(t.hoverInteractionState.disposeEffect),t.hoverInteractionState}function ra(e,t={}){let{enabled:n=!0,closeDelay:r=0,nodeId:i}=t,a=`rootStore`in e?e.rootStore:e,o=a.useState(`open`),s=a.useState(`floatingElement`),c=a.useState(`domReferenceElement`),{dataRef:l}=a.context,u=Qe(),d=dt(),f=na(a),p=it(),m=pt(()=>Ji(l.current.openEvent?.type,f.interactedInside)),h=pt(()=>Yi(l.current.openEvent?.type)),g=pt(()=>{ea(f)});Ye(()=>{o||(f.pointerType=void 0,f.restTimeoutPending=!1,f.interactedInside=!1,g())},[o,f,g]),G.useEffect(()=>g,[g]),Ye(()=>{if(n&&o&&f.handleCloseOptions?.blockPointerEvents&&h()&&_t(c)&&s){let e=c,t=s,n=ge(s),r=u?.nodesRef.current.find(e=>e.id===d)?.context?.elements.floating;r&&(r.style.pointerEvents=``);let i=f.pointerEventsScopeElement===t?null:f.pointerEventsScopeElement,a=r===t?null:r,o=f.handleCloseOptions?.getScope?.()??i??a??e.closest(`[data-rootownerid]`)??n.body;return ta(f,{scopeElement:o,referenceElement:e,floatingElement:t}),()=>{g()}}},[n,o,c,s,f,h,u,d,g]),G.useEffect(()=>{if(!n)return;function e(){return!!(u&&d&&Fe(u.nodesRef.current,d).length>0)}function t(e){let t=Ki(r,`close`,f.pointerType),n=()=>{a.setOpen(!1,_(ve,e)),u?.events.emit(`floating.closed`,e)};t?f.openChangeTimeout.start(t,n):(f.openChangeTimeout.clear(),n())}function o(e){let t=V(e);if(!b(t)){f.interactedInside=!1;return}f.interactedInside=t?.closest(`[aria-haspopup]`)!=null}function c(){f.openChangeTimeout.clear(),p.clear(),u?.events.off(`floating.closed`,y),g()}function v(n){if(e()&&u){u.events.on(`floating.closed`,y);return}if(We(n.relatedTarget,a.context.triggerElements))return;let r=l.current.floatingContext?.nodeId??i,o=n.relatedTarget;if(!(u&&r&&_t(o)&&Fe(u.nodesRef.current,r,!1).some(e=>F(e.context?.elements.floating,o)))){if(f.handler){f.handler(n);return}g(),h()&&!m()&&t(n)}}function y(t){!u||!d||e()||p.start(0,()=>{u.events.off(`floating.closed`,y),a.setOpen(!1,_(ve,t)),u.events.emit(`floating.closed`,t)})}let x=s;return w(x&&oe(x,`mouseenter`,c),x&&oe(x,`mouseleave`,v),x&&oe(x,`pointerdown`,o,!0),()=>{u?.events.off(`floating.closed`,y)})},[n,s,a,l,r,i,h,m,g,f,u,d,p])}var ia=t(de(),1),aa={current:null};function oa(e,t={}){let{enabled:n=!0,delay:r=0,handleClose:i=null,mouseOnly:a=!1,restMs:o=0,move:s=!0,triggerElementRef:c=aa,externalTree:l,isActiveTrigger:u=!0,getHandleCloseContext:d,isClosing:f,shouldOpen:p}=t,m=`rootStore`in e?e.rootStore:e,{dataRef:h,events:g}=m.context,v=Qe(l),y=na(m),b=G.useRef(!1),x=T(i),S=T(r),C=T(o),E=T(n),D=T(p),O=T(f),k=pt(()=>Ji(h.current.openEvent?.type,y.interactedInside)),A=pt(()=>D.current?.()!==!1),j=pt((e,t,n)=>{let r=m.context.triggerElements;if(r.hasElement(t))return!e||!F(e,t);if(!_t(n))return!1;let i=n;return r.hasMatchingElement(e=>F(e,i))&&(!e||!F(e,i))}),N=pt(()=>{y.handler&&=(ge(m.select(`domReferenceElement`)).removeEventListener(`mousemove`,y.handler),void 0)}),P=pt(()=>{ea(y)});return u&&(y.handleCloseOptions=x.current?.__options),G.useEffect(()=>N,[N]),G.useEffect(()=>{if(!n)return;function e(e){e.open?b.current=!1:(b.current=e.reason===ve,N(),y.openChangeTimeout.clear(),y.restTimeout.clear(),y.blockMouseMove=!0,y.restTimeoutPending=!1)}return g.on(`openchange`,e),()=>{g.off(`openchange`,e)}},[n,g,y,N]),G.useEffect(()=>{if(!n)return;function e(e,t=!0){let n=Ki(S.current,`close`,y.pointerType);n?y.openChangeTimeout.start(n,()=>{m.setOpen(!1,_(ve,e)),v?.events.emit(`floating.closed`,e)}):t&&(y.openChangeTimeout.clear(),m.setOpen(!1,_(ve,e)),v?.events.emit(`floating.closed`,e))}let t=c.current??(u?m.select(`domReferenceElement`):null);if(!_t(t))return;function r(e){if(y.openChangeTimeout.clear(),y.blockMouseMove=!1,a&&!M(y.pointerType))return;let t=qi(C.current),n=Ki(S.current,`open`,y.pointerType),r=V(e),i=e.currentTarget??null,o=m.select(`domReferenceElement`),s=i;if(_t(r)&&!m.context.triggerElements.hasElement(r)){for(let e of m.context.triggerElements.elements())if(F(e,r)){s=e;break}}_t(i)&&_t(o)&&!m.context.triggerElements.hasElement(i)&&F(i,o)&&(s=o);let c=s!=null&&j(o,s,r),l=m.select(`open`),u=O.current?.()??m.select(`transitionStatus`)===`ending`,d=!l&&u&&b.current,f=!c&&_t(s)&&_t(o)&&F(o,s)&&d,p=t>0&&!n,h=c&&(l||d)||f,g=!l||c;if(h){A()&&m.setOpen(!0,_(ve,e,s));return}p||(n?y.openChangeTimeout.start(n,()=>{g&&A()&&m.setOpen(!0,_(ve,e,s))}):g&&A()&&m.setOpen(!0,_(ve,e,s)))}function i(t){if(k()){P();return}N();let n=ge(m.select(`domReferenceElement`));y.restTimeout.clear(),y.restTimeoutPending=!1;let r=h.current.floatingContext??d?.();if(!We(t.relatedTarget,m.context.triggerElements)){if(x.current&&r){m.select(`open`)||y.openChangeTimeout.clear();let i=c.current;y.handler=x.current({...r,tree:v,x:t.clientX,y:t.clientY,onClose(){P(),N(),E.current&&!k()&&i===m.select(`domReferenceElement`)&&e(t,!0)}}),n.addEventListener(`mousemove`,y.handler),y.handler(t);return}(y.pointerType!==`touch`||!F(m.select(`floatingElement`),t.relatedTarget))&&e(t)}}return s?w(oe(t,`mousemove`,r,{once:!0}),oe(t,`mouseenter`,r),oe(t,`mouseleave`,i)):w(oe(t,`mouseenter`,r),oe(t,`mouseleave`,i))},[N,P,h,S,m,n,x,y,u,j,k,a,s,C,c,v,E,d,O,A]),G.useMemo(()=>{if(!n)return;function e(e){y.pointerType=e.pointerType}return{onPointerDown:e,onPointerEnter:e,onMouseMove(e){let{nativeEvent:t}=e,n=e.currentTarget,r=m.select(`domReferenceElement`),i=m.select(`open`),o=j(r,n,e.target);if(a&&!M(y.pointerType))return;if(i&&o&&y.handleCloseOptions?.blockPointerEvents){let e=m.select(`floatingElement`);if(e){let t=y.handleCloseOptions?.getScope?.()??n.ownerDocument.body;ta(y,{scopeElement:t,referenceElement:n,floatingElement:e})}}let s=qi(C.current);if(i&&!o||s===0||!o&&y.restTimeoutPending&&e.movementX**2+e.movementY**2<2)return;y.restTimeout.clear();function c(){if(y.restTimeoutPending=!1,k())return;let e=m.select(`open`);!y.blockMouseMove&&(!e||o)&&A()&&m.setOpen(!0,_(ve,t,n))}y.pointerType===`touch`?ia.flushSync(()=>{c()}):o&&i?c():(y.restTimeoutPending=!0,y.restTimeout.start(s,c))}}},[n,y,k,j,a,m,C,A])}var sa=.1,ca=sa*sa,la=.5;function ua(e,t,n,r,i,a){return r>=t!=a>=t&&e<=(i-n)*(t-r)/(a-r)+n}function da(e,t,n,r,i,a,o,s,c,l){let u=!1;return ua(e,t,n,r,i,a)&&(u=!u),ua(e,t,i,a,o,s)&&(u=!u),ua(e,t,o,s,c,l)&&(u=!u),ua(e,t,c,l,n,r)&&(u=!u),u}function fa(e,t,n){return e>=n.x&&e<=n.x+n.width&&t>=n.y&&t<=n.y+n.height}function pa(e,t,n,r,i,a){return e>=Math.min(n,i)&&e<=Math.max(n,i)&&t>=Math.min(r,a)&&t<=Math.max(r,a)}function ma(e={}){let{blockPointerEvents:t=!1}=e,n=new z,r=({x:e,y:t,placement:r,elements:i,onClose:a,nodeId:o,tree:s})=>{let c=r?.split(`-`)[0],l=!1,u=null,d=null,f=typeof performance<`u`?performance.now():0;function p(e,t){let n=performance.now(),r=n-f;if(u===null||d===null||r===0)return u=e,d=t,f=n,!1;let i=e-u,a=t-d,o=i*i+a*a,s=r*r*ca;return u=e,d=t,f=n,o<s}function m(){n.clear(),a()}return function(r){n.clear();let a=i.domReference,u=i.floating;if(!a||!u||c==null||e==null||t==null)return;let{clientX:d,clientY:f}=r,h=V(r),g=r.type===`mouseleave`,_=F(u,h),v=F(a,h);if(_&&(l=!0,!g))return;if(v&&(l=!1,!g)){l=!0;return}if(g&&_t(r.relatedTarget)&&F(u,r.relatedTarget))return;function y(){return!!(s&&Fe(s.nodesRef.current,o).length>0)}function b(){y()||m()}if(y())return;let x=a.getBoundingClientRect(),S=u.getBoundingClientRect(),C=e>S.right-S.width/2,w=t>S.bottom-S.height/2,T=S.width>x.width,E=S.height>x.height,D=(T?x:S).left,O=(T?x:S).right,k=(E?x:S).top,A=(E?x:S).bottom;if(c===`top`&&t>=x.bottom-1||c===`bottom`&&t<=x.top+1||c===`left`&&e>=x.right-1||c===`right`&&e<=x.left+1){b();return}let j=!1;switch(c){case`top`:j=pa(d,f,D,x.top+1,O,S.bottom-1);break;case`bottom`:j=pa(d,f,D,S.top+1,O,x.bottom-1);break;case`left`:j=pa(d,f,S.right-1,A,x.left+1,k);break;case`right`:j=pa(d,f,x.right-1,A,S.left+1,k);break;default:}if(j)return;if(l&&!fa(d,f,x)){b();return}if(!g&&p(d,f)){b();return}let M=!1;switch(c){case`top`:{let n=T?la/2:la*4,r=T||C?e+n:e-n,i=T?e-n:C?e+n:e-n,a=t+la+1,o=C||T?S.bottom-la:S.top,s=C?T?S.bottom-la:S.top:S.bottom-la;M=da(d,f,r,a,i,a,S.left,o,S.right,s);break}case`bottom`:{let n=T?la/2:la*4,r=T||C?e+n:e-n,i=T?e-n:C?e+n:e-n,a=t-la,o=C||T?S.top+la:S.bottom,s=C?T?S.top+la:S.bottom:S.top+la;M=da(d,f,r,a,i,a,S.left,o,S.right,s);break}case`left`:{let n=E?la/2:la*4,r=E||w?t+n:t-n,i=E?t-n:w?t+n:t-n,a=e+la+1,o=w||E?S.right-la:S.left,s=w?E?S.right-la:S.left:S.right-la;M=da(d,f,o,S.top,s,S.bottom,a,r,a,i);break}case`right`:{let n=E?la/2:la*4,r=E||w?t+n:t-n,i=E?t-n:w?t+n:t-n,a=e-la,o=w||E?S.left+la:S.right,s=w?E?S.left+la:S.right:S.left+la;M=da(d,f,a,r,a,i,o,S.top,s,S.bottom);break}default:}M?l||n.start(40,b):b()}};return r.__options={...e,blockPointerEvents:t},r}var ha={...rt,...De},ga=G.forwardRef(function(e,t){let{render:n,className:r,style:i,finalFocus:a,...o}=e,{store:c}=Ri(),{side:l,align:u}=Ii(),d=Vt(!0)!=null,f=c.useState(`open`),p=c.useState(`transitionStatus`),m=c.useState(`popupProps`),h=c.useState(`mounted`),g=c.useState(`instantType`),v=c.useState(`activeTriggerElement`),y=c.useState(`parent`),b=c.useState(`lastOpenChangeReason`),x=c.useState(`rootId`),S=c.useState(`floatingRootContext`),C=c.useState(`floatingTreeRoot`),w=c.useState(`closeDelay`),T=c.useState(`activeTriggerElement`),E=c.useState(`hoverEnabled`),D=c.useState(`disabled`),O=c.useState(`openMethod`),k=y.type===`context-menu`;ee({open:f,ref:c.context.popupRef,onComplete(){f&&c.context.onOpenChangeComplete?.(!0)}}),G.useEffect(()=>{function e(e){c.setOpen(!1,_(e.reason,e.domEvent))}return C.events.on(`close`,e),()=>{C.events.off(`close`,e)}},[C.events,c]),ra(S,{enabled:E&&!D&&!k&&y.type!==`menubar`,closeDelay:w});let A=G.useCallback(e=>{c.set(`popupElement`,e)},[c]),j=s(`div`,e,{state:{transitionStatus:p,side:l,align:u,open:f,nested:y.type===`menu`,instant:g},ref:[t,c.context.popupRef,A],stateAttributesMapping:ha,props:[m,{onKeyDown(e){d&&vt.has(e.key)&&e.stopPropagation()}},Bt(p),o,{"data-rootownerid":x}]}),M=y.type===void 0||k;return(v||y.type===`menubar`&&b!==`outside-press`)&&(M=!0),(0,K.jsx)(Ee,{context:S,openInteractionType:O,modal:k,disabled:!h,returnFocus:a===void 0?M:a,initialFocus:y.type!==`menu`,restoreFocus:!0,externalTree:y.type===`menubar`?void 0:C,previousFocusableElement:T,nextFocusableElement:y.type===void 0?c.context.triggerFocusTargetRef:void 0,beforeContentFocusGuardRef:y.type===void 0?c.context.beforeContentFocusGuardRef:void 0,children:j})}),_a=G.createContext(void 0);function va(){let e=G.useContext(_a);if(e===void 0)throw Error(d(32));return e}var ya=G.forwardRef(function(e,t){let{keepMounted:n=!1,...r}=e,{store:i}=Ri();return i.useState(`mounted`)||n?(0,K.jsx)(_a.Provider,{value:n,children:(0,K.jsx)(He,{ref:t,...r})}):null}),ba=G.forwardRef(function(e,t){let{anchor:n,positionMethod:r=`absolute`,className:i,render:a,side:o,align:s,sideOffset:c=0,alignOffset:l=0,collisionBoundary:u=`clipping-ancestors`,collisionPadding:d=5,arrowPadding:f=5,sticky:p=!1,disableAnchorTracking:m=!1,collisionAvoidance:h=ct,style:g,...v}=e,{store:y}=Ri(),b=va(),x=Bi(!0),S=y.useState(`parent`),C=y.useState(`floatingRootContext`),w=y.useState(`floatingTreeRoot`),T=y.useState(`mounted`),E=y.useState(`open`),D=y.useState(`modal`),O=y.useState(`openMethod`),k=y.useState(`activeTriggerElement`),A=y.useState(`transitionStatus`),j=y.useState(`positionerElement`),M=y.useState(`instantType`),N=y.useState(`hasViewport`),P=y.useState(`lastOpenChangeReason`),F=y.useState(`floatingNodeId`),I=y.useState(`floatingParentNodeId`),L=C.useState(`domReferenceElement`),ee=G.useRef(null),te=Te(j,!1,!1),R=n,z=c,B=l,V=s,H=h;S.type===`context-menu`&&(R=n??S.context?.anchor,V??=`start`,!o&&V!==`center`&&(B=e.alignOffset??2,z=e.sideOffset??-5));let ne=o,re=V;S.type===`menu`?(ne??=`inline-end`,re??=`start`,H=e.collisionAvoidance??Ne):S.type===`menubar`&&(ne??=S.context.orientation===`vertical`?`inline-end`:`bottom`,re??=`start`);let U=S.type===`context-menu`,ie=Gt({anchor:R,floatingRootContext:C,positionMethod:x?`fixed`:r,mounted:T,side:ne,sideOffset:z,align:re,alignOffset:B,arrowPadding:U?0:f,collisionBoundary:u,collisionPadding:d,sticky:p,nodeId:F,keepMounted:b,disableAnchorTracking:m,collisionAvoidance:H,shiftCrossAxis:U&&!(`side`in H&&H.side===`flip`),externalTree:w,adaptiveOrigin:N?$t:void 0});G.useEffect(()=>{function e(e){e.open&&(e.parentNodeId===F&&y.set(`hoverEnabled`,!1),e.nodeId!==F&&e.parentNodeId===y.select(`floatingParentNodeId`)&&y.setOpen(!1,_(be)))}return w.events.on(`menuopenchange`,e),()=>{w.events.off(`menuopenchange`,e)}},[y,w.events,F]),G.useEffect(()=>{if(y.select(`floatingParentNodeId`)==null)return;function e(e){if(e.open||e.nodeId!==y.select(`floatingParentNodeId`))return;let t=e.reason??`sibling-open`;y.setOpen(!1,_(t))}return w.events.on(`menuopenchange`,e),()=>{w.events.off(`menuopenchange`,e)}},[w.events,y]);let ae=it();G.useEffect(()=>{E||ae.clear()},[E,ae]),G.useEffect(()=>{function e(e){if(!(!E||e.nodeId!==y.select(`floatingParentNodeId`)))if(e.target&&k&&k!==e.target){let e=y.select(`closeDelay`);e>0?ae.isStarted()||ae.start(e,()=>{y.setOpen(!1,_(be))}):y.setOpen(!1,_(be))}else ae.clear()}return w.events.on(`itemhover`,e),()=>{w.events.off(`itemhover`,e)}},[w.events,E,k,y,ae]),G.useEffect(()=>{let e={open:E,nodeId:F,parentNodeId:I,reason:y.select(`lastOpenChangeReason`)};w.events.emit(`menuopenchange`,e)},[w.events,E,y,F,I]),Ye(()=>{let e=L,t=ee.current;if(e&&(ee.current=e),t&&e&&e!==t){y.set(`instantType`,void 0);let e=new AbortController;return te(()=>{y.set(`instantType`,`trigger-change`)},e.signal),()=>{e.abort()}}},[L,te,y]);let oe={open:E,side:ie.side,align:ie.align,anchorHidden:ie.anchorHidden,nested:S.type===`menu`,instant:M},se=S.type===`menubar`&&S.context.modal;Jt(E&&(se||D&&P!==`trigger-hover`),O===`touch`,j,k);let ce=Zt(e,oe,{styles:ie.positionerStyles,transitionStatus:A,props:v,refs:[t,y.useStateSetter(`positionerElement`)],hidden:!T,inert:!E}),le=T&&S.type!==`menu`&&(S.type!==`menubar`&&D&&P!==`trigger-hover`||S.type===`menubar`&&S.context.modal),de=null;return S.type===`menubar`?de=S.context.contentElement:S.type===void 0&&(de=k),(0,K.jsxs)(Fi.Provider,{value:ie,children:[le&&(0,K.jsx)(Pe,{ref:S.type===`context-menu`||S.type===`nested-context-menu`?S.context.internalBackdropRef:null,inert:tt(!E),cutout:de}),(0,K.jsx)(ue,{id:F,children:(0,K.jsx)(zt,{elementsRef:y.context.itemDomElements,labelsRef:y.context.itemLabels,children:ce})})]})}),xa=G.createContext(null);function Sa(e){let t=G.useContext(xa);if(t===null&&!e)throw Error(d(5));return t}var Ca={...Nt,disabled:I(e=>e.parent.type===`menubar`&&e.parent.context.disabled||e.disabled),modal:I(e=>(e.parent.type===void 0||e.parent.type===`context-menu`)&&(e.modal??!0)),openMethod:I(e=>e.openMethod),allowMouseEnter:I(e=>e.allowMouseEnter),highlightItemOnHover:I(e=>e.highlightItemOnHover),stickIfOpen:I(e=>e.stickIfOpen),parent:I(e=>e.parent),rootId:I(e=>e.parent.type===`menu`?e.parent.store.select(`rootId`):e.parent.type===void 0?e.rootId:e.parent.context.rootId),activeIndex:I(e=>e.activeIndex),isActive:I((e,t)=>e.activeIndex===t),hoverEnabled:I(e=>e.hoverEnabled),instantType:I(e=>e.instantType),lastOpenChangeReason:I(e=>e.openChangeReason),floatingTreeRoot:I(e=>e.parent.type===`menu`?e.parent.store.select(`floatingTreeRoot`):e.floatingTreeRoot),floatingNodeId:I(e=>e.floatingNodeId),floatingParentNodeId:I(e=>e.floatingParentNodeId),itemProps:I(e=>e.itemProps),closeDelay:I(e=>e.closeDelay),hasViewport:I(e=>e.hasViewport),keyboardEventRelay:I(e=>{if(e.keyboardEventRelay)return e.keyboardEventRelay;if(e.parent.type===`menu`)return e.parent.store.select(`keyboardEventRelay`)})},wa=class e extends A{constructor(e){super({...Ta(),...e},{positionerRef:G.createRef(),popupRef:G.createRef(),typingRef:{current:!1},itemDomElements:{current:[]},itemLabels:{current:[]},allowMouseUpTriggerRef:{current:!1},triggerFocusTargetRef:G.createRef(),beforeContentFocusGuardRef:G.createRef(),onOpenChangeComplete:void 0,triggerElements:new ie},Ca),this.unsubscribeParentListener=this.observe(`parent`,e=>{if(this.unsubscribeParentListener?.(),e.type===`menu`){let t=e.store.select(`rootId`),n=e.store.select(`floatingTreeRoot`),r=e.store.select(`keyboardEventRelay`);this.unsubscribeParentListener=e.store.subscribe(()=>{let i=e.store.select(`rootId`),a=e.store.select(`floatingTreeRoot`),o=e.store.select(`keyboardEventRelay`);t===i&&n===a&&r===o||(t=i,n=a,r=o,this.notifyAll())}),this.context.allowMouseUpTriggerRef=e.store.context.allowMouseUpTriggerRef;return}e.type!==void 0&&(this.context.allowMouseUpTriggerRef=e.context.allowMouseUpTriggerRef),this.unsubscribeParentListener=null})}setOpen(e,t){this.state.floatingRootContext.context.events.emit(`setOpen`,{open:e,eventDetails:t})}static useStore(t,n){let r=i(()=>new e(n)).current;return t??r}unsubscribeParentListener=null};function Ta(){return{...Ft(),disabled:!1,modal:!0,openMethod:null,allowMouseEnter:!1,highlightItemOnHover:!0,stickIfOpen:!0,parent:{type:void 0},rootId:void 0,activeIndex:null,hoverEnabled:!0,instantType:void 0,openChangeReason:null,floatingTreeRoot:new ot,floatingNodeId:void 0,floatingParentNodeId:null,itemProps:n,keyboardEventRelay:void 0,closeDelay:0,hasViewport:!1}}var Ea=G.createContext(void 0);function Da(){return G.useContext(Ea)}var Oa=O(function(e){let{children:t,open:r,onOpenChange:i,onOpenChangeComplete:a,defaultOpen:o=!1,disabled:s=!1,modal:c,loopFocus:l=!0,orientation:d=`vertical`,actionsRef:p,closeParentOnEsc:m=!1,handle:h,triggerId:y,defaultTriggerId:b=null,highlightItemOnHover:S=!0}=e,C=Bi(!0),w=Ri(!0),T=Sa(!0),D=Da(),O=G.useMemo(()=>D&&w?{type:`menu`,store:w.store}:T?{type:`menubar`,context:T}:C&&!w?{type:`context-menu`,context:C}:{type:void 0},[C,w,T,D]),k=wa.useStore(h?.store,{open:o,openProp:r,activeTriggerId:b,triggerIdProp:y,parent:O});se(k,r,o,b),k.useControlledProp(`openProp`,r),k.useControlledProp(`triggerIdProp`,y),k.useContextCallback(`onOpenChangeComplete`,a);let A=ut(),j=ut(),M=k.useState(`floatingTreeRoot`),P=Le(M),F=dt(),I=k.useState(`open`),L=k.useState(`activeTriggerElement`),ee=k.useState(`positionerElement`),te=k.useState(`hoverEnabled`),R=k.useState(`disabled`),z=k.useState(`lastOpenChangeReason`),B=k.useState(`parent`),V=k.useState(`activeIndex`),re=k.useState(`payload`),U=k.useState(`floatingParentNodeId`),ie=G.useRef(null),ae=G.useRef(B.type!==`context-menu`),oe=it(),le=G.useRef(!0),ue=it(),de=U!=null,{openMethod:fe,triggerProps:pe}=Wt(I);k.useSyncedValues({disabled:s,highlightItemOnHover:S,modal:B.type===void 0?c:void 0,openMethod:fe,rootId:A}),ne(k);let{forceUnmount:me}=E(I,k,()=>{k.update({allowMouseEnter:!1,stickIfOpen:!0})});Ye(()=>{C&&!w?k.update({parent:{type:`context-menu`,context:C},floatingNodeId:P,floatingParentNodeId:F}):w&&k.update({floatingNodeId:P,floatingParentNodeId:F})},[C,w,P,F,k]),G.useEffect(()=>{if(I||(ie.current=null),B.type===`context-menu`){if(!I){oe.clear(),ae.current=!1;return}oe.start(500,()=>{ae.current=!0})}},[oe,I,B.type]),Ye(()=>{!I&&!te&&k.set(`hoverEnabled`,!0)},[I,te,k]);let he=pt((e,t)=>{let n=t.reason;if(I===e&&t.trigger===L&&z===n)return;let r=v(t);if(!e&&t.trigger==null&&(t.trigger=L??void 0),i?.(e,t),t.isCanceled)return;k.state.floatingRootContext.dispatchOpenChange(e,t);let a=t.event;if(e===!1&&a?.type===`click`&&a.pointerType===`touch`&&!le.current)return;e&&n===`trigger-focus`?(le.current=!1,ue.start(300,()=>{le.current=!0})):(le.current=!0,ue.clear());let o=(n===`trigger-press`||n===`item-press`)&&a.detail===0&&a?.isTrusted,s=!e&&(n===`escape-key`||n==null),c={open:e,openChangeReason:n};ie.current=t.event??null,H(c,e,t.trigger,r()),k.update(c),B.type===`menubar`&&(n===`trigger-focus`||n===`focus-out`||n===`trigger-hover`||n===`list-navigation`||n===`sibling-open`)?k.set(`instantType`,`group`):o||s?k.set(`instantType`,o?`click`:`dismiss`):k.set(`instantType`,void 0)}),ge=x({popupStore:k,floatingId:j,nested:F!=null,onOpenChange:he}),_e=ge.context.events;G.useEffect(()=>{let e=({open:e,eventDetails:t})=>he(e,t);return _e.on(`setOpen`,e),()=>{_e?.off(`setOpen`,e)}},[_e,he]);let ve=G.useCallback(()=>{k.setOpen(!1,_(ce))},[k]);G.useImperativeHandle(p,()=>({unmount:me,close:ve}),[me,ve]);let ye;B.type===`context-menu`&&(ye=B.context),G.useImperativeHandle(ye?.positionerRef,()=>ee,[ee]),G.useImperativeHandle(ye?.actionsRef,()=>({setOpen:he}),[he]);let be=xe(ge,{enabled:!R,bubbles:{escapeKey:m&&B.type===`menu`},outsidePress(){return B.type!==`context-menu`||ie.current?.type===`contextmenu`||ae.current},externalTree:de?M:void 0}),W=Re(),Se=G.useCallback(e=>{k.select(`activeIndex`)!==e&&k.set(`activeIndex`,e)},[k]),Ce=Kt(ge,{enabled:!R,listRef:k.context.itemDomElements,activeIndex:V,nested:B.type!==void 0,loopFocus:l,orientation:d,parentOrientation:B.type===`menubar`?B.context.orientation:void 0,rtl:W===`rtl`,disabledIndices:f,onNavigate:Se,openOnArrowKeyDown:B.type!==`context-menu`,externalTree:de?M:void 0,focusItemOnHover:S}),we=G.useCallback(e=>{k.context.typingRef.current=e},[k]),Te=Yt(ge,{enabled:!R,listRef:k.context.itemLabels,elementsRef:k.context.itemDomElements,activeIndex:V,resetMs:500,onMatch:e=>{I&&e!==V&&k.set(`activeIndex`,e)},onTyping:we});N(k,{floatingRootContext:ge,activeTriggerProps:G.useMemo(()=>{let e=u(Te.reference,Ce.reference,be.reference,{onMouseMove(){k.set(`allowMouseEnter`,!0)}},pe);return e[`aria-haspopup`]=`menu`,e[`aria-expanded`]=I,e},[k,Te.reference,Ce.reference,be.reference,pe,I]),inactiveTriggerProps:G.useMemo(()=>{let e=u(Ce.trigger,be.trigger,pe);return e[`aria-haspopup`]=`menu`,e[`aria-expanded`]=!1,e},[Ce.trigger,be.trigger,pe]),popupProps:G.useMemo(()=>u(Ge,{id:j,role:`menu`,"aria-labelledby":L?.id,onMouseMove(){k.set(`allowMouseEnter`,!0),B.type===`menu`&&k.set(`hoverEnabled`,!1)},onClick(){k.select(`hoverEnabled`)&&k.set(`hoverEnabled`,!1)},onKeyDown(e){let t=k.select(`keyboardEventRelay`);t&&!e.isPropagationStopped()&&t(e)}},Te.floating,Ce.floating,be.floating),[L,j,B.type,k,Te.floating,Ce.floating,be.floating]),itemProps:Ce.item??n});let Ee=G.useMemo(()=>({store:k,parent:O}),[k,O]),De=(0,K.jsx)(Li.Provider,{value:Ee,children:typeof t==`function`?t({payload:re}):t});return B.type===void 0||B.type===`context-menu`?(0,K.jsx)(g,{externalTree:M,children:De}):De});function ka(e={}){let{highlightItemOnHover:t,highlightedIndex:n,onHighlightedIndexChange:i}=Me(),{ref:a,index:o}=tn(e),s=n===o,c=G.useRef(null),l=r(a,c);return{compositeProps:{tabIndex:s?0:-1,onFocus(){i(o)},onMouseMove(){let e=c.current;if(!t||!e)return;let n=e.hasAttribute(`disabled`)||e.ariaDisabled===`true`;!s&&!n&&e.focus()}},compositeRef:l,index:o}}function Aa(e){let{render:t,className:r,style:i,state:a=n,props:o=f,refs:c=f,metadata:l,stateAttributesMapping:u,tag:d=`div`,...p}=e,{compositeProps:m,compositeRef:h}=ka({metadata:l});return s(d,e,{state:a,ref:[...c,h],props:[m,...o,p],stateAttributesMapping:u})}function ja(e){if(me(e)&&e.hasAttribute(`data-rootownerid`))return e.getAttribute(`data-rootownerid`)??void 0;if(!S(e))return ja(ht(e))}function Ma(e,t){let n=G.useRef(null);function r(t){ia.flushSync(()=>{e.setOpen(!1,_(re,t.nativeEvent,t.currentTarget))}),Xe(n.current)?.focus()}function i(n){let r=e.select(`positionerElement`);if(r&&Be(n,r))e.context.beforeContentFocusGuardRef.current?.focus();else{ia.flushSync(()=>{e.setOpen(!1,_(re,n.nativeEvent,n.currentTarget))});let i=nt(e.context.triggerFocusTargetRef.current||t.current);for(;i!==null&&F(r,i);){let e=i;if(i=ze(i),i===e)break}i?.focus()}}return{preFocusGuardRef:n,handlePreFocusGuardFocus:r,handleFocusTargetFocus:i}}function Na(e){let{enabled:t=!0,mouseDownAction:r,open:i}=e,a=G.useRef(!1);return G.useMemo(()=>t?{onMouseDown:e=>{(r===`open`&&!i||r===`close`&&i)&&(a.current=!0,ge(e.currentTarget).addEventListener(`click`,()=>{a.current=!1},{once:!0}))},onClick:e=>{a.current&&(a.current=!1,e.preventBaseUIHandler())}}:n,[t,r,i])}var Pa=2,Fa=te(function(e,t){let{render:r,className:i,style:a,disabled:o=!1,nativeButton:c=!0,id:l,openOnHover:f,delay:p=100,closeDelay:m=0,handle:h,payload:g,..._}=e,v=Ri(!0),y=h?.store??v?.store;if(!y)throw Error(d(85));let b=Ie(l),x=y.useState(`isTriggerActive`,b),S=y.useState(`floatingRootContext`),C=y.useState(`isOpenedByTrigger`,b),w=y.useState(`triggerPopupId`,b),T=G.useRef(null),E=La(),D=Me(!0),O=Qe(),k=G.useMemo(()=>O??new ot,[O]),{registerTrigger:A,isMountedByThisTrigger:j}=bt(b,T,y,{payload:g,closeDelay:m,parent:E,floatingTreeRoot:k,floatingNodeId:Le(k),floatingParentNodeId:dt(),keyboardEventRelay:D?.relayKeyboardEvent}),M=E.type===`menubar`,N=y.useState(`disabled`),P=o||N||M&&E.context.disabled,{getButtonProps:I,buttonRef:ee}=et({disabled:P,native:c});G.useEffect(()=>{!C&&E.type===void 0&&(y.context.allowMouseUpTriggerRef.current=!1)},[y,C,E.type]);let te=G.useRef(null),R=it(),z=pt(e=>{if(!te.current)return;R.clear(),y.context.allowMouseUpTriggerRef.current=!1;let t=e.target;if(F(te.current,t)||F(y.select(`positionerElement`),t)||t===te.current||t!=null&&ja(t)===y.select(`rootId`))return;let n=Xt(te.current);e.clientX>=n.left-Pa&&e.clientX<=n.right+Pa&&e.clientY>=n.top-Pa&&e.clientY<=n.bottom+Pa||k.events.emit(`close`,{domEvent:e,reason:Ke})});G.useEffect(()=>{C&&y.select(`lastOpenChangeReason`)===`trigger-hover`&&ge(te.current).addEventListener(`mouseup`,z,{once:!0})},[C,z,y]);let B=M&&E.context.hasSubmenuOpen,V=oa(S,{enabled:(f??B)&&!P&&E.type!==`context-menu`&&(!M||B&&!j),handleClose:ma({blockPointerEvents:!M}),mouseOnly:!0,move:!1,restMs:E.type===void 0?p:void 0,delay:{close:m},triggerElementRef:T,externalTree:k,isActiveTrigger:x,isClosing:()=>y.select(`transitionStatus`)===`ending`}),H=Ia(C,y.select(`lastOpenChangeReason`)),ne=Lt(S,{enabled:!P&&E.type!==`context-menu`,event:C&&M?`click`:`mousedown`,toggle:!0,ignoreMouse:!1,stickIfOpen:E.type===void 0&&H}),re=Zi(S,{enabled:!P&&B}),U=Na({open:C,enabled:M,mouseDownAction:`open`}),ie=G.useMemo(()=>u(re.reference,ne.reference),[re.reference,ne.reference]),ae=y.useState(`triggerProps`,j),{preFocusGuardRef:oe,handlePreFocusGuardFocus:se,handleFocusTargetFocus:ce}=Ma(y,T),le={disabled:P,open:C},ue=[te,t,ee,A,T],de=[ie,V??n,ae,{"aria-haspopup":`menu`,"aria-controls":w,id:b,onMouseDown:e=>{y.select(`open`)||(R.start(200,()=>{y.context.allowMouseUpTriggerRef.current=!0}),ge(e.currentTarget).addEventListener(`mouseup`,z,{once:!0}))}},M?{role:`menuitem`}:{},U,_,I],fe=s(`button`,e,{enabled:!M,stateAttributesMapping:L,state:le,ref:ue,props:de});return M?(0,K.jsx)(Aa,{tag:`button`,render:r,className:i,style:a,state:le,refs:ue,props:de,stateAttributesMapping:L}):C?(0,K.jsxs)(G.Fragment,{children:[(0,K.jsx)(he,{ref:oe,onFocus:se},`${b}-pre-focus-guard`),(0,K.jsx)(G.Fragment,{children:fe},b),(0,K.jsx)(he,{ref:y.context.triggerFocusTargetRef,onFocus:ce},`${b}-post-focus-guard`)]}):(0,K.jsx)(G.Fragment,{children:fe},b)});function Ia(e,t){let n=it(),[r,i]=G.useState(!1);return Ye(()=>{e&&t===`trigger-hover`?(i(!0),n.start(500,()=>{i(!1)})):e||(n.clear(),i(!1))},[e,t,n]),r}function La(){let e=Bi(!0),t=Ri(!0),n=Sa(!0);return G.useMemo(()=>n?{type:`menubar`,context:n}:e&&!t?{type:`context-menu`,context:e}:{type:void 0},[e,t,n])}var Ra=Oa;function za({className:e,children:t,...n}){return(0,K.jsx)(Fa,{className:e,"data-slot":`menu-trigger`,...n,children:t})}function Ba({children:e,className:t,sideOffset:n=4,align:r=`center`,alignOffset:i,side:a=`bottom`,anchor:o,...s}){return(0,K.jsx)(ya,{children:(0,K.jsx)(ba,{align:r,alignOffset:i,anchor:o,className:`z-50`,"data-slot":`menu-positioner`,side:a,sideOffset:n,children:(0,K.jsx)(ga,{className:c(`relative flex not-[class*='w-']:min-w-32 origin-(--transform-origin) rounded-lg border bg-popover not-dark:bg-clip-padding shadow-lg/5 outline-none before:pointer-events-none before:absolute before:inset-0 before:rounded-[calc(var(--radius-lg)-1px)] before:shadow-[0_1px_--theme(--color-black/4%)] focus:outline-none dark:before:shadow-[0_-1px_--theme(--color-white/6%)]`,t),"data-slot":`menu-popup`,...s,children:(0,K.jsx)(`div`,{className:`max-h-(--available-height) w-full overflow-y-auto p-1`,children:e})})})})}function Va({className:e,inset:t,variant:n=`default`,...r}){return(0,K.jsx)(Wi,{className:c(`[&>svg]:-mx-0.5 flex min-h-8 cursor-default select-none items-center gap-2 rounded-sm px-2 py-1 text-base text-foreground outline-none data-disabled:pointer-events-none data-highlighted:bg-accent data-inset:ps-8 data-[variant=destructive]:text-destructive-foreground data-highlighted:text-accent-foreground data-disabled:opacity-64 sm:min-h-7 sm:text-sm [&>svg:not([class*='opacity-'])]:opacity-80 [&>svg:not([class*='size-'])]:size-4.5 sm:[&>svg:not([class*='size-'])]:size-4 [&>svg:not([class*='text-'])]:text-muted-foreground data-[variant=destructive]:[&>svg:not([class*='text-'])]:text-current [&>svg]:pointer-events-none [&>svg]:shrink-0`,e),"data-inset":t,"data-slot":`menu-item`,"data-variant":n,...r})}var Ha=`nexusflow-theme`,Ua=(0,G.createContext)({theme:`dark`,setTheme:()=>{}});function Wa(){let e=localStorage.getItem(Ha);return e===`light`||e===`dark`?e:window.matchMedia(`(prefers-color-scheme: dark)`).matches?`dark`:`light`}function Ga({children:e}){let[t,n]=(0,G.useState)(Wa);(0,G.useEffect)(()=>{let e=document.documentElement;e.classList.add(`no-transitions`),e.classList.toggle(`dark`,t===`dark`),requestAnimationFrame(()=>e.classList.remove(`no-transitions`))},[t]);let r=(0,G.useCallback)(e=>{localStorage.setItem(Ha,e),n(e)},[]);return(0,K.jsx)(Ua.Provider,{value:{theme:t,setTheme:r},children:e})}function Ka(){return(0,G.useContext)(Ua)}var qa=[{label:`Projects`,to:`/projects`,icon:Xr,match:e=>e.startsWith(`/projects`)},{label:`Resource Library`,to:`/skills`,icon:Wr,match:e=>e.startsWith(`/skills`)||e.startsWith(`/agents`)},{label:`Strategies`,to:`/workflows`,icon:ci,match:e=>e.startsWith(`/workflows`)||e.startsWith(`/strategies`)},{label:`Settings`,to:`/settings`,icon:ri,match:e=>e.startsWith(`/settings`)}];function Ja({appVersion:e,workspaces:t=[],workspaceStatuses:n={},workspacesLoading:r=!1,activeWsId:i=null,onSelectWorkspace:a}){let{pathname:o}=It(),{theme:s,setTheme:l}=Ka(),[u,d]=(0,G.useState)(``),[f,p]=(0,G.useState)(`created-desc`),m=(0,G.useMemo)(()=>{let e=t,r=u.trim().toLowerCase();return r&&(e=e.filter(e=>`${e.branchName} ${e.description}`.toLowerCase().includes(r))),[...e].sort((e,t)=>{switch(f){case`created-desc`:{let n=new Date(e.createdAt||0).getTime();return new Date(t.createdAt||0).getTime()-n}case`created-asc`:return new Date(e.createdAt||0).getTime()-new Date(t.createdAt||0).getTime();case`changes-desc`:{let r=n[e.branchName]?.changedFiles||0;return(n[t.branchName]?.changedFiles||0)-r}case`repos-desc`:return(t.repos?.length||0)-(e.repos?.length||0);case`name-asc`:return e.branchName.localeCompare(t.branchName);default:return 0}})},[t,u,f,n]),[h,g]=(0,G.useState)(!0),_=e=>c(`flex items-center gap-2 rounded-md px-2 py-1.5 text-xs font-medium transition-colors cursor-pointer`,e?`bg-primary/10 text-primary font-semibold`:`text-muted-foreground hover:bg-accent hover:text-foreground`);return(0,K.jsxs)(`aside`,{className:`flex w-64 shrink-0 flex-col border-r border-border bg-card/60 select-none h-screen overflow-hidden`,children:[(0,K.jsxs)(`div`,{className:`flex h-12 items-center justify-between px-3 border-b border-border/60`,children:[(0,K.jsxs)(Ct,{to:`/overview`,className:`flex items-center gap-2`,children:[(0,K.jsx)(`div`,{className:`grid h-6 w-6 place-items-center rounded bg-primary text-[11px] font-bold text-primary-foreground shadow-xs`,children:`NF`}),(0,K.jsx)(`span`,{className:`text-xs font-bold tracking-tight text-foreground`,children:`NexusFlow`})]}),(0,K.jsxs)(`span`,{className:`text-[10px] font-mono text-muted-foreground/70`,children:[`v`,e]})]}),(0,K.jsxs)(`div`,{className:`p-2.5 pb-1 space-y-1.5`,children:[(0,K.jsxs)(jt,{to:`/overview`,className:({isActive:e})=>c(`flex h-7.5 items-center gap-2 rounded-md px-2.5 text-xs font-medium transition-colors cursor-pointer`,e||location.pathname===`/`?`bg-primary/10 text-primary font-semibold`:`text-muted-foreground hover:bg-accent/60 hover:text-foreground`),children:[(0,K.jsx)(Br,{size:13,className:`shrink-0 text-primary`}),(0,K.jsx)(`span`,{children:`Overview`})]}),(0,K.jsxs)(Ct,{to:`/new`,className:`flex h-8 w-full cursor-pointer items-center justify-center gap-1.5 rounded-md bg-primary px-3 text-xs font-semibold text-primary-foreground shadow-xs transition-colors hover:bg-primary/90`,children:[(0,K.jsx)(ti,{size:14}),(0,K.jsx)(`span`,{children:`Start work`})]})]}),(0,K.jsxs)(`div`,{className:`flex flex-1 flex-col overflow-hidden px-2`,children:[(0,K.jsxs)(`div`,{className:`flex items-center justify-between px-1 py-1.5 text-[11px] font-semibold uppercase tracking-wider text-muted-foreground`,children:[(0,K.jsxs)(`div`,{className:`flex items-center gap-1.5`,children:[(0,K.jsx)(`span`,{children:`Workspaces`}),(0,K.jsx)(`span`,{className:`rounded bg-muted/80 px-1 py-0.2 font-mono text-[10px] text-foreground`,children:m.length})]}),(0,K.jsxs)(Ra,{children:[(0,K.jsxs)(za,{className:`flex items-center gap-1 text-[11px] normal-case font-medium text-muted-foreground hover:text-foreground cursor-pointer px-1.5 py-0.5 rounded hover:bg-muted/70 transition-colors`,children:[(0,K.jsx)(Hr,{size:11,className:`opacity-70`}),(0,K.jsx)(`span`,{children:{"created-desc":`Newest`,"created-asc":`Oldest`,"changes-desc":`Changes`,"name-asc":`A–Z`,"repos-desc":`Repos`}[f]}),(0,K.jsx)(St,{size:10,className:`opacity-60`})]}),(0,K.jsxs)(Ba,{align:`end`,className:`w-48`,children:[(0,K.jsx)(`div`,{className:`px-2 py-1 text-[10px] font-semibold text-muted-foreground uppercase tracking-wider`,children:`Order Workspaces By`}),(0,K.jsxs)(Va,{onClick:()=>p(`created-desc`),className:`flex items-center justify-between text-xs`,children:[(0,K.jsx)(`span`,{children:`Newest created`}),f===`created-desc`&&(0,K.jsx)(Gr,{size:12,className:`text-primary`})]}),(0,K.jsxs)(Va,{onClick:()=>p(`created-asc`),className:`flex items-center justify-between text-xs`,children:[(0,K.jsx)(`span`,{children:`Oldest created`}),f===`created-asc`&&(0,K.jsx)(Gr,{size:12,className:`text-primary`})]}),(0,K.jsxs)(Va,{onClick:()=>p(`changes-desc`),className:`flex items-center justify-between text-xs`,children:[(0,K.jsx)(`span`,{children:`Most changes`}),f===`changes-desc`&&(0,K.jsx)(Gr,{size:12,className:`text-primary`})]}),(0,K.jsxs)(Va,{onClick:()=>p(`name-asc`),className:`flex items-center justify-between text-xs`,children:[(0,K.jsx)(`span`,{children:`Name (A–Z)`}),f===`name-asc`&&(0,K.jsx)(Gr,{size:12,className:`text-primary`})]}),(0,K.jsxs)(Va,{onClick:()=>p(`repos-desc`),className:`flex items-center justify-between text-xs`,children:[(0,K.jsx)(`span`,{children:`Most repos`}),f===`repos-desc`&&(0,K.jsx)(Gr,{size:12,className:`text-primary`})]})]})]})]}),(0,K.jsxs)(`div`,{className:`relative mb-2`,children:[(0,K.jsx)(Et,{size:12,className:`pointer-events-none absolute left-2 top-1/2 -translate-y-1/2 text-muted-foreground`}),(0,K.jsx)(`input`,{type:`text`,value:u,onChange:e=>d(e.target.value),placeholder:`Filter workspaces...`,className:`h-7 w-full rounded-md border border-border/80 bg-background/80 py-1 pl-6 pr-6 text-xs text-foreground placeholder:text-muted-foreground/70 focus:border-primary focus:outline-none`}),u&&(0,K.jsx)(`button`,{onClick:()=>d(``),"aria-label":`Clear filter`,className:`absolute right-2 top-1/2 -translate-y-1/2 text-muted-foreground hover:text-foreground text-[10px] cursor-pointer`,children:`✕`})]}),(0,K.jsx)(`div`,{className:`flex-1 overflow-y-auto space-y-1 pr-0.5`,children:r?(0,K.jsx)(`div`,{className:`space-y-1.5 py-1`,children:[1,2,3].map(e=>(0,K.jsx)(`div`,{className:`h-10 rounded-md bg-muted/40 animate-pulse`},e))}):m.length===0?(0,K.jsx)(`div`,{className:`py-6 text-center text-xs text-muted-foreground/80`,children:u?`No matches`:`No workspaces`}):m.map(e=>{let t=i===e.branchName,r=n[e.branchName],o=!!(r&&r.changedFiles>0),s=!!(r&&r.runningServices>0);return(0,K.jsxs)(Ct,{to:`/workspaces/${encodeURIComponent(e.branchName)}`,onClick:()=>a?.(e.branchName),className:c(`group flex flex-col gap-0.5 rounded-md px-2.5 py-1.5 text-xs transition-colors cursor-pointer border border-transparent`,t?`bg-accent text-foreground font-medium border-border/70 shadow-2xs`:`text-muted-foreground hover:bg-accent/50 hover:text-foreground`),children:[(0,K.jsxs)(`div`,{className:`flex items-center justify-between gap-1.5 min-w-0`,children:[(0,K.jsx)(`span`,{className:`truncate font-mono tracking-tight font-medium text-foreground`,children:e.branchName}),(0,K.jsx)(`span`,{className:c(`size-1.5 rounded-full shrink-0`,o?`bg-amber-500`:`bg-emerald-500`),title:o?`${r.changedFiles} uncommitted changes`:`Clean working directory`})]}),(0,K.jsxs)(`div`,{className:`flex items-center gap-2 text-[11px] text-muted-foreground/80 font-mono`,children:[(0,K.jsxs)(`span`,{children:[e.repos.length,` `,e.repos.length===1?`repo`:`repos`]}),o&&(0,K.jsxs)(K.Fragment,{children:[(0,K.jsx)(`span`,{children:`•`}),(0,K.jsxs)(`span`,{className:`text-amber-600 dark:text-amber-400 font-semibold`,children:[r.changedFiles,` chg`]})]}),s&&(0,K.jsxs)(K.Fragment,{children:[(0,K.jsx)(`span`,{children:`•`}),(0,K.jsxs)(`span`,{className:`text-emerald-600 dark:text-emerald-400 flex items-center gap-0.5 font-semibold`,children:[(0,K.jsx)(`span`,{className:`size-1 rounded-full bg-emerald-500 animate-pulse`}),r.runningServices,` svc`]})]}),e.assistants&&e.assistants.length>0&&(0,K.jsx)(`div`,{className:`ml-auto flex items-center gap-1`,children:e.assistants.map(e=>(0,K.jsx)(`span`,{className:`opacity-70 group-hover:opacity-100 transition-opacity`,children:e===`antigravity`?(0,K.jsx)(Pi,{className:`size-3`}):e===`claude`?(0,K.jsx)(Mi,{className:`size-2.5 text-[#D97757]`}):e===`codex`?(0,K.jsx)(Ci,{className:`size-2.5 text-foreground`}):(0,K.jsx)(Ai,{className:`size-2.5 text-blue-400`})},e))})]})]},e.id)})})]}),(0,K.jsxs)(`div`,{className:`border-t border-border/60 p-2 flex flex-col gap-0.5`,children:[(0,K.jsxs)(`button`,{type:`button`,onClick:()=>g(e=>!e),className:`flex items-center justify-between w-full rounded-md px-2 py-1.5 text-xs font-medium text-muted-foreground hover:bg-accent hover:text-foreground transition-colors cursor-pointer`,"aria-expanded":h,children:[(0,K.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,K.jsx)(ri,{size:13,className:`text-muted-foreground/70`}),(0,K.jsx)(`span`,{children:`Tools & Library`})]}),(0,K.jsx)(St,{size:12,className:c(`transition-transform duration-200 opacity-60`,h&&`rotate-180`)})]}),h&&(0,K.jsxs)(`div`,{className:`flex flex-col gap-0.5 pt-1 animate-fade-in`,children:[qa.map(e=>{let t=e.match(o),n=e.icon;return(0,K.jsxs)(jt,{to:e.to,className:_(t),children:[(0,K.jsx)(n,{size:13}),(0,K.jsx)(`span`,{children:e.label})]},e.to)}),(0,K.jsxs)(jt,{to:`/guide`,className:_(o.startsWith(`/guide`)),children:[(0,K.jsx)(Ur,{size:13}),(0,K.jsx)(`span`,{children:`Getting Started`})]}),(0,K.jsxs)(`button`,{type:`button`,"aria-label":s===`dark`?`Switch to light theme`:`Switch to dark theme`,onClick:()=>l(s===`dark`?`light`:`dark`),className:`flex w-full cursor-pointer items-center gap-2 rounded-md px-2 py-1.5 text-xs font-medium text-muted-foreground transition-colors hover:bg-accent hover:text-foreground`,children:[s===`dark`?(0,K.jsx)(ai,{size:13}):(0,K.jsx)($r,{size:13}),(0,K.jsx)(`span`,{children:s===`dark`?`Light mode`:`Dark mode`})]})]})]})]})}function Ya({toasts:e,onDismiss:t}){return(0,K.jsx)(`div`,{className:`fixed bottom-5 right-5 z-[9999] flex flex-col gap-3 pointer-events-none max-w-md w-full`,children:e.map(e=>(0,K.jsxs)(`div`,{className:`pointer-events-auto flex items-start justify-between gap-3 rounded-xl border px-4 py-3 shadow-sm transition-all duration-300 animate-rise ${e.type===`success`?`border-success/32 bg-success/10 text-success-foreground`:e.type===`error`?`border-destructive/32 bg-destructive/10 text-destructive-foreground`:`border-info/32 bg-info/10 text-info-foreground`}`,children:[(0,K.jsxs)(`div`,{className:`flex items-start gap-2.5 text-xs font-semibold flex-1`,children:[e.type===`success`&&(0,K.jsx)(Gr,{className:`mt-0.5 shrink-0 text-success`,size:16}),e.type===`error`&&(0,K.jsx)(qr,{className:`mt-0.5 shrink-0 text-destructive`,size:16}),e.type===`info`&&(0,K.jsx)(Zr,{className:`mt-0.5 shrink-0 text-info`,size:16}),(0,K.jsx)(`span`,{className:`whitespace-pre-line text-left leading-relaxed`,children:e.message})]}),(0,K.jsx)(`button`,{onClick:()=>t(e.id),className:`mt-0.5 shrink-0 cursor-pointer text-muted-foreground transition-colors hover:text-foreground`,children:(0,K.jsx)(kt,{size:14})})]},e.id))})}var Xa=class extends Error{status;constructor(e,t){super(e),this.name=`ApiError`,this.status=t}};async function q(e,t){let n=await fetch(`${e}`,{...t,headers:{...t?.body?{"Content-Type":`application/json`}:{},...t?.headers}}),r=n.headers.get(`content-type`)?.includes(`application/json`)?await n.json().catch(()=>null):null;if(!n.ok)throw new Xa(r&&typeof r.error==`string`&&r.error||`Request failed (${n.status})`,n.status);return r}function Za(){return Lr({queryKey:[`config`],queryFn:()=>q(`/api/config`)})}function Qa(){return Lr({queryKey:[`workspaces`],queryFn:()=>q(`/api/workspaces`)})}function $a(e={}){return Lr({queryKey:[`workspaces-status`],queryFn:()=>q(`/api/workspaces/status`),enabled:e.enabled??!0,refetchInterval:e.intervalMs??!1})}function eo(){let e=Sr();return Rr({mutationFn:e=>q(`/api/workspace`,{method:`POST`,body:JSON.stringify(e)}),onSuccess:()=>{e.invalidateQueries({queryKey:[`workspaces`]}),e.invalidateQueries({queryKey:[`workspaces-status`]})}})}function to(){return Lr({queryKey:[`projects`],queryFn:()=>q(`/api/projects`)})}function no(){let e=Sr();return Rr({mutationFn:e=>q(`/api/projects`,{method:`POST`,body:JSON.stringify(e)}),onSuccess:()=>e.invalidateQueries({queryKey:[`projects`]})})}function ro(){let e=Sr();return Rr({mutationFn:({id:e,...t})=>q(`/api/projects/${encodeURIComponent(e)}`,{method:`PUT`,body:JSON.stringify(t)}),onSuccess:()=>e.invalidateQueries({queryKey:[`projects`]})})}function io(){let e=Sr();return Rr({mutationFn:e=>q(`/api/projects/${encodeURIComponent(e)}`,{method:`DELETE`}),onSuccess:()=>e.invalidateQueries({queryKey:[`projects`]})})}function J(){return Lr({queryKey:[`repos`],queryFn:()=>q(`/api/repos`)})}function ao(e,t){return Lr({queryKey:[`repo-branches`,e],queryFn:()=>q(`/api/repos/branches?path=${encodeURIComponent(e)}`),enabled:t,staleTime:6e4})}function oo(){let e=Sr();return Rr({mutationFn:e=>q(`/api/repos/new`,{method:`POST`,body:JSON.stringify({name:e})}),onSuccess:()=>e.invalidateQueries({queryKey:[`repos`]})})}function so(){return Lr({queryKey:[`ai-detect`],queryFn:()=>q(`/api/ai-detect`),staleTime:6e4})}function co(){return Lr({queryKey:[`editor-detect`],queryFn:()=>q(`/api/editor-detect`),staleTime:6e4})}function lo(){return Lr({queryKey:[`workspace-launch-targets`],queryFn:()=>q(`/api/workspace-launch-targets`),staleTime:6e4})}function uo(e,t){return Lr({queryKey:[`workspace-recent-sessions`,e],queryFn:async()=>{let t=new URLSearchParams({limit:`3`,desktopHandoffOnly:`true`});return(await q(`/api/workspace/${encodeURIComponent(e)}/sessions?${t}`)).sessions},enabled:t,staleTime:3e4})}function fo(){return Lr({queryKey:[`workflow-templates`],queryFn:async()=>(await q(`/api/workflows/templates`)).templates})}function po(e){return Lr({queryKey:[`workspace-services`,e],queryFn:()=>q(`/api/workspace/${encodeURIComponent(e)}/services`),enabled:!!e,refetchInterval:3e3})}function mo(e){let t=Sr();return Rr({mutationFn:({action:t,service:n})=>{let r=`/api/workspace/${encodeURIComponent(e)}/services`;return q(n?`${r}/${encodeURIComponent(n)}/${t}`:`${r}/${t}`,{method:`POST`})},onSettled:()=>{t.invalidateQueries({queryKey:[`workspace-services`,e]}),t.invalidateQueries({queryKey:[`workspaces-status`]})}})}function ho(e){let t=Sr();return Rr({mutationFn:({action:t,id:n})=>q(`/api/workspace/${encodeURIComponent(e)}/orchestrators/${t}`,{method:`POST`,body:JSON.stringify({id:n})}),onSettled:()=>{t.invalidateQueries({queryKey:[`workspace-services`,e]}),t.invalidateQueries({queryKey:[`workspaces-status`]})}})}function go(){return Lr({queryKey:[`skill-categories`],queryFn:async()=>(await q(`/api/skills/categories`)).categories})}function _o(){let e=Sr();return Rr({mutationFn:e=>q(`/api/skills/categories`,{method:`POST`,body:JSON.stringify(e)}),onSuccess:()=>{e.invalidateQueries({queryKey:[`skill-categories`]}),e.invalidateQueries({queryKey:[`skills`]})}})}function vo(){let e=Sr();return Rr({mutationFn:e=>q(`/api/skills/categories/${encodeURIComponent(e)}`,{method:`DELETE`}),onSuccess:()=>{e.invalidateQueries({queryKey:[`skill-categories`]}),e.invalidateQueries({queryKey:[`skills`]})}})}function yo(e){return Lr({queryKey:[`skills`,e],queryFn:async()=>(await q(e?`/api/skills?workspace=${encodeURIComponent(e)}`:`/api/skills`)).skills})}function bo(){let e=Sr();return Rr({mutationFn:e=>q(`/api/skills`,{method:`POST`,body:JSON.stringify(e)}),onSuccess:()=>{e.invalidateQueries({queryKey:[`skills`]}),e.invalidateQueries({queryKey:[`skill-categories`]})}})}function xo(){let e=Sr();return Rr({mutationFn:e=>q(`/api/skills/${encodeURIComponent(e)}`,{method:`DELETE`}),onSuccess:()=>{e.invalidateQueries({queryKey:[`skills`]})}})}function So(){return Lr({queryKey:[`codex-agents`],queryFn:async()=>(await q(`/api/agents`)).agents})}function Co(){let e=Sr();return Rr({mutationFn:e=>q(`/api/agents`,{method:`POST`,body:JSON.stringify(e)}),onSuccess:()=>e.invalidateQueries({queryKey:[`codex-agents`]})})}function wo(){let e=Sr();return Rr({mutationFn:({toml:e,category:t})=>q(`/api/agents/import`,{method:`POST`,body:JSON.stringify({toml:e,category:t})}),onSuccess:()=>e.invalidateQueries({queryKey:[`codex-agents`]})})}function To(){let e=Sr();return Rr({mutationFn:e=>q(`/api/agents/${encodeURIComponent(e)}`,{method:`DELETE`}),onSuccess:()=>e.invalidateQueries({queryKey:[`codex-agents`]})})}function Eo(e){return Lr({queryKey:[`workspace-skills`,e],queryFn:async()=>(await q(`/api/skills/workspace/${encodeURIComponent(e)}`)).config,enabled:!!e})}function Do(){let e=Sr();return Rr({mutationFn:({workspaceId:e,expectedRevision:t,...n})=>q(`/api/skills/workspace/${encodeURIComponent(e)}/assign`,{method:`POST`,body:JSON.stringify({...n,expectedRevision:t})}),onSuccess:(t,n)=>{e.setQueryData([`workspace-skills`,n.workspaceId],t.config),e.invalidateQueries({queryKey:[`skills`]})}})}function Oo(){return Rr({mutationFn:({workspaceId:e,...t})=>q(`/api/workspace/${encodeURIComponent(e)}/terminal`,{method:`POST`,body:JSON.stringify(t)})})}function ko(){let e=Sr();return Rr({mutationFn:({workspaceId:e,force:t})=>q(`/api/workspace/${encodeURIComponent(e)}/refresh`,{method:`POST`,body:JSON.stringify({force:t})}),onSuccess:(t,n)=>{e.invalidateQueries({queryKey:[`workspaces`]}),e.invalidateQueries({queryKey:[`workspace-skills`,n.workspaceId]}),e.invalidateQueries({queryKey:[`skills`,n.workspaceId]}),e.invalidateQueries({queryKey:[`workspaces-status`]})}})}var Ao=512e3;function jo(e,t,n){let[r,i]=(0,G.useState)({logs:``,connected:!1}),a=(0,G.useCallback)(()=>i(e=>({...e,logs:``})),[]);return(0,G.useEffect)(()=>{let r=!1,a=null,o=null;if(i({logs:``,connected:!1}),!n||!e||!t)return;let s=encodeURIComponent(e),c=encodeURIComponent(t),l=async()=>{if(r)return;let e=0;try{let t=await(await fetch(`/api/workspace/${s}/services/logs/${c}`)).json();if(r)return;e=typeof t.size==`number`?t.size:0,i({logs:typeof t.logs==`string`?t.logs:``,connected:!1})}catch{}if(r)return;let t=new EventSource(`/api/workspace/${s}/services/logs/${c}/stream?offset=${e}`);a=t,t.addEventListener(`open`,()=>{r||i(e=>({...e,connected:!0}))}),t.addEventListener(`log`,e=>{try{let{chunk:t}=JSON.parse(e.data);typeof t==`string`&&!r&&i(e=>{let n=e.logs+t;return{...e,logs:n.length>Ao?n.slice(-512e3):n}})}catch{}}),t.onerror=()=>{t.close(),a===t&&(a=null),!r&&(i(e=>({...e,connected:!1})),o=setTimeout(l,2e3))}};return l(),()=>{r=!0,o&&clearTimeout(o),a?.close(),a=null}},[e,t,n]),{logs:r.logs,connected:r.connected,clear:a}}function Mo({activeWsId:e,setActiveWsId:t,appVersion:n,workspaces:r,executeTerminal:i}){let[a,o]=(0,G.useState)(null),s=po(e),c=s.data?.services??[],l=s.data?.runningState??[],u=mo(e??``),{logs:d}=jo(e,a,!!e);(0,G.useEffect)(()=>{c.length===0?a!==null&&o(null):(!a||!c.some(e=>e.name===a))&&o(c[0].name)},[c]);let f=(0,G.useRef)(null);(0,G.useEffect)(()=>{f.current?.scrollIntoView({behavior:`smooth`})},[d]);let p=l.filter(e=>e.pid>0).length;return(0,K.jsxs)(`div`,{className:`flex flex-col h-screen w-full bg-background text-foreground font-mono text-[11px] overflow-hidden select-none border-t border-border`,children:[(0,K.jsxs)(`div`,{className:`flex items-center justify-between px-3 py-2 bg-card border-b border-border shrink-0 text-[10px]`,children:[(0,K.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,K.jsx)(`span`,{className:`font-bold text-primary`,children:`NEXUSFLOW_SHELL`}),(0,K.jsx)(`span`,{className:`text-muted-foreground`,children:`|`}),(0,K.jsxs)(`span`,{className:`text-muted-foreground`,children:[`ws: `,e||`none`]})]}),(0,K.jsxs)(`div`,{className:`flex items-center gap-2`,children:[e&&(0,K.jsx)(`button`,{onClick:()=>{t(null),o(null)},className:`text-primary hover:text-primary/90 hover:underline transition-colors cursor-pointer bg-transparent border-none p-0 outline-none`,children:`[Change WS]`}),n&&(0,K.jsxs)(`span`,{className:`text-[10px] text-muted-foreground`,children:[`v`,n]})]})]}),e?(0,K.jsxs)(`div`,{className:`flex-1 flex flex-col min-h-0`,children:[(0,K.jsxs)(`div`,{className:`p-3 border-b border-border shrink-0 bg-muted/30`,children:[(0,K.jsxs)(`div`,{className:`flex gap-2 mb-3`,children:[(0,K.jsxs)(`button`,{onClick:()=>u.mutate({action:`start`}),disabled:u.isPending,className:`flex-1 inline-flex items-center justify-center gap-1.5 px-3 py-1.5 rounded border border-success/20 bg-success/10 hover:bg-success/20 text-success font-bold transition-all cursor-pointer text-[10px] disabled:opacity-50`,children:[(0,K.jsx)(ei,{size:10}),` [START SERVICES]`]}),(0,K.jsxs)(`button`,{onClick:()=>u.mutate({action:`stop`}),disabled:u.isPending,className:`flex-1 inline-flex items-center justify-center gap-1.5 px-3 py-1.5 rounded border border-destructive/20 bg-destructive/10 hover:bg-destructive/20 text-destructive font-bold transition-all cursor-pointer text-[10px] disabled:opacity-50`,children:[(0,K.jsx)(kt,{size:10}),` [STOP SERVICES]`]})]}),(0,K.jsxs)(`div`,{className:`mb-3`,children:[(0,K.jsxs)(`div`,{className:`text-[10px] text-muted-foreground uppercase font-bold tracking-wider mb-1 px-1`,children:[`Background Services (`,p,`/`,c.length,`)`]}),c.length===0?(0,K.jsx)(`div`,{className:`text-muted-foreground/50 italic px-1 text-[10px]`,children:`No services detected in workspace.`}):(0,K.jsx)(`div`,{className:`flex flex-col gap-1 max-h-[120px] overflow-y-auto pr-1`,children:c.map(e=>{let t=l.some(t=>t.name===e.name&&t.pid>0);return(0,K.jsxs)(`div`,{onClick:()=>o(e.name),className:`flex items-center justify-between p-1.5 border rounded cursor-pointer transition-all ${a===e.name?`bg-primary/20 border-primary/50 text-foreground`:`bg-muted/20 border-border hover:border-border/80 text-muted-foreground`}`,children:[(0,K.jsxs)(`div`,{className:`flex items-center gap-2 truncate`,children:[(0,K.jsx)(`span`,{className:`h-1.5 w-1.5 rounded-full ${t?`bg-success`:`bg-destructive`}`}),(0,K.jsx)(`span`,{className:`font-bold truncate`,children:e.name})]}),(0,K.jsx)(`span`,{className:`text-[10px] font-mono shrink-0`,children:t?(0,K.jsx)(`span`,{className:`text-success bg-success/10 px-1 py-0.2 rounded border border-success/20 text-[8px] font-bold uppercase`,children:`on`}):(0,K.jsx)(`span`,{className:`text-muted-foreground bg-muted px-1 py-0.2 rounded border border-border text-[8px] font-bold uppercase`,children:`off`})})]},e.name)})})]}),(0,K.jsxs)(`div`,{className:`mb-3 border-t border-border pt-2.5`,children:[(0,K.jsx)(`div`,{className:`text-[10px] text-muted-foreground font-bold uppercase mb-1 px-1`,children:`Active Local MCP Tools`}),(0,K.jsxs)(`div`,{className:`flex flex-col gap-1 px-1 text-[10px] text-muted-foreground font-mono`,children:[(0,K.jsxs)(`div`,{className:`flex justify-between`,children:[(0,K.jsx)(`span`,{children:`• search_workspace`}),(0,K.jsx)(`span`,{className:`text-primary font-bold`,children:`READY`})]}),(0,K.jsxs)(`div`,{className:`flex justify-between`,children:[(0,K.jsx)(`span`,{children:`• get_service_logs`}),(0,K.jsx)(`span`,{className:`text-primary font-bold`,children:`READY`})]})]})]}),(0,K.jsxs)(`div`,{className:`border-t border-border pt-2.5`,children:[(0,K.jsx)(`div`,{className:`text-[10px] text-muted-foreground font-bold uppercase mb-1.5 px-1`,children:`Terminal Commands (Click to Run)`}),(0,K.jsx)(`div`,{className:`grid grid-cols-2 gap-1.5`,children:[`nexusflow sync`,`nexusflow diff`,`nexusflow handoff`,`nexusflow status`].map(e=>(0,K.jsxs)(`button`,{onClick:()=>i(e),className:`px-2 py-1.5 text-left border border-border hover:border-primary bg-muted/40 rounded text-muted-foreground hover:text-foreground hover:bg-primary/10 transition-all font-mono text-[9px] cursor-pointer`,children:[`$ `,e]},e))})]})]}),(0,K.jsxs)(`div`,{className:`flex-1 flex flex-col min-h-0 bg-background`,children:[(0,K.jsx)(`div`,{className:`flex items-center justify-between px-3 py-1.5 bg-card border-b border-border shrink-0 text-[9px] text-muted-foreground uppercase tracking-wider font-bold`,children:(0,K.jsxs)(`div`,{className:`flex items-center gap-1.5`,children:[(0,K.jsx)(`span`,{className:`h-1.5 w-1.5 rounded-full bg-primary`}),(0,K.jsxs)(`span`,{children:[`log_stream: `,a||`none`]})]})}),(0,K.jsxs)(`div`,{className:`flex-1 p-3 overflow-y-auto font-mono text-[10px] leading-relaxed whitespace-pre-wrap select-text selection:bg-primary/30 text-foreground`,children:[d.trim()?d:(0,K.jsx)(`span`,{className:`text-muted-foreground/50 italic font-mono`,children:`(no logs recorded yet)`}),(0,K.jsx)(`div`,{ref:f})]})]})]}):(0,K.jsxs)(`div`,{className:`flex-1 flex flex-col items-center justify-center p-6 text-center overflow-y-auto`,children:[(0,K.jsx)(`div`,{className:`text-primary font-bold mb-4 text-[12px] uppercase`,children:`=== Select Active Workspace ===`}),(0,K.jsxs)(`div`,{className:`flex flex-col gap-2 w-full max-w-xs`,children:[r.map(e=>(0,K.jsxs)(`button`,{onClick:()=>t(e.branchName),className:`w-full text-left p-2.5 bg-muted border border-border hover:border-primary rounded hover:bg-primary/10 text-muted-foreground hover:text-foreground transition-all text-[11px] cursor-pointer`,children:[`> `,e.branchName]},e.branchName)),r.length===0&&(0,K.jsx)(`div`,{className:`text-muted-foreground italic`,children:`No workspaces found. Initialize one via the CLI.`})]})]})]})}var No=G.createContext(null),Po=G.createContext(null);function Fo(){let e=G.useContext(No);if(e===null)throw Error(d(60));return e}function Io(){let e=G.useContext(Po);if(e===null)throw Error(d(61));return e}var Lo=(e,t)=>Object.is(e,t);function Ro(e,t,n){return e==null||t==null?Object.is(e,t):n(e,t)}function zo(e,t,n){return!e||e.length===0?!1:e.some(e=>e!==void 0&&Ro(t,e,n))}function Bo(e,t,n){return!e||e.length===0?-1:e.findIndex(e=>e!==void 0&&Ro(e,t,n))}function Vo(e,t,n){return e.filter(e=>!Ro(t,e,n))}function Ho(e){if(e==null)return``;if(typeof e==`string`)return e;try{return JSON.stringify(e)}catch{return String(e)}}function Uo(e){return e!=null&&e.length>0&&typeof e[0]==`object`&&e[0]!=null&&`items`in e[0]}function Wo(e){if(!Array.isArray(e))return e!=null&&`null`in e;let t=e;if(Uo(t)){for(let e of t)for(let t of e.items)if(t&&t.value==null&&t.label!=null)return!0;return!1}for(let e of t)if(e&&e.value==null&&e.label!=null)return!0;return!1}function Go(e,t){if(t&&e!=null)return t(e)??``;if(e&&typeof e==`object`){if(`label`in e&&e.label!=null)return String(e.label);if(`value`in e)return String(e.value)}return Ho(e)}function Ko(e,t){return t&&e!=null?t(e)??``:e&&typeof e==`object`&&`value`in e&&`label`in e?Ho(e.value):Ho(e)}function qo(e,t,n){function r(){return Go(e,n)}if(n&&e!=null)return n(e);if(e&&typeof e==`object`&&`label`in e&&e.label!=null)return e.label;if(t&&!Array.isArray(t))return t[e]??r();if(Array.isArray(t)){let n=t,i=Uo(n)?n.flatMap(e=>e.items):n;if(typeof e!=`object`||!e){let t=i.find(t=>t.value===e);return t&&t.label!=null?t.label:r()}if(`value`in e){let t=i.find(t=>t&&t.value===e.value);if(t&&t.label!=null)return t.label}}return r()}function Jo(e,t,n){return e.reduce((e,r,i)=>(i>0&&e.push(`, `),e.push((0,K.jsx)(G.Fragment,{children:qo(r,t,n)},i)),e),[])}var Y={id:I(e=>e.id),labelId:I(e=>e.labelId),modal:I(e=>e.modal),multiple:I(e=>e.multiple),items:I(e=>e.items),itemToStringLabel:I(e=>e.itemToStringLabel),itemToStringValue:I(e=>e.itemToStringValue),isItemEqualToValue:I(e=>e.isItemEqualToValue),value:I(e=>e.value),hasSelectedValue:I(e=>{let{value:t,multiple:n,itemToStringValue:r}=e;return t==null?!1:n&&Array.isArray(t)?t.length>0:Ko(t,r)!==``}),hasNullItemLabel:I((e,t)=>t?Wo(e.items):!1),open:I(e=>e.open),mounted:I(e=>e.mounted),forceMount:I(e=>e.forceMount),transitionStatus:I(e=>e.transitionStatus),openMethod:I(e=>e.openMethod),activeIndex:I(e=>e.activeIndex),selectedIndex:I(e=>e.selectedIndex),isActive:I((e,t)=>e.activeIndex===t),isSelected:I((e,t)=>{let n=e.isItemEqualToValue,r=e.value;return e.multiple?Array.isArray(r)&&r.some(e=>Ro(t,e,n)):Ro(t,r,n)}),isSelectedByFocus:I((e,t)=>e.selectedIndex===t),popupProps:I(e=>e.popupProps),triggerProps:I(e=>e.triggerProps),triggerElement:I(e=>e.triggerElement),positionerElement:I(e=>e.positionerElement),listElement:I(e=>e.listElement),popupSide:I(e=>e.popupSide),scrollUpArrowVisible:I(e=>e.scrollUpArrowVisible),scrollDownArrowVisible:I(e=>e.scrollDownArrowVisible),hasScrollArrows:I(e=>e.hasScrollArrows)};function Yo(e,t,n=(e,t)=>e===t){return e.length===t.length&&e.every((e,r)=>n(e,t[r]))}function Xo(e){let{id:t,value:a,defaultValue:o=null,onValueChange:s,open:c,defaultOpen:l=!1,onOpenChange:d,name:p,form:m,autoComplete:h,disabled:g=!1,readOnly:v=!1,required:y=!1,modal:b=!0,actionsRef:x,inputRef:S,onOpenChangeComplete:w,items:E,multiple:D=!1,itemToStringLabel:O,itemToStringValue:k,isItemEqualToValue:A=Lo,highlightItemOnHover:j=!0,children:M}=e,{clearErrors:N}=st(),{setDirty:P,setTouched:F,setFocused:I,validityData:L,setFilled:te,name:R,disabled:z,validation:B,validationMode:V}=je(),H=ke({id:t}),ne=z||g,re=R??p,[U,ie]=ae({controlled:a,default:D?o??f:o,name:`Select`,state:`value`}),[oe,se]=ae({controlled:c,default:l,name:`Select`,state:`open`}),ce=G.useRef([]),le=G.useRef([]),ue=G.useRef(null),de=G.useRef(null),fe=G.useRef(0),pe=G.useRef(null),me=G.useRef([]),he=G.useRef(!1),ge=G.useRef(null),ve=G.useRef(null),ye=G.useRef({allowSelectedMouseUp:!1,allowUnselectedMouseUp:!1,dragY:0}),be=G.useRef(!1),{mounted:we,setMounted:Te,transitionStatus:Ee}=Se(oe),{openMethod:De,triggerProps:Oe}=Wt(oe),Ae=i(()=>new _e({id:H,labelId:void 0,modal:b,multiple:D,itemToStringLabel:O,itemToStringValue:k,isItemEqualToValue:A,value:U,open:oe,mounted:we,transitionStatus:Ee,items:E,forceMount:!1,openMethod:null,activeIndex:null,selectedIndex:null,popupProps:{},triggerProps:{},triggerElement:null,positionerElement:null,listElement:null,popupSide:null,scrollUpArrowVisible:!1,scrollDownArrowVisible:!1,hasScrollArrows:!1})).current,Me=W(Ae,Y.activeIndex),Ne=W(Ae,Y.selectedIndex),Pe=W(Ae,Y.triggerElement),Fe=W(Ae,Y.positionerElement),Ie=qt(De),Le=De??Ie??null,Re=G.useMemo(()=>D?``:Ko(U,k),[D,U,k]),ze=G.useMemo(()=>D&&Array.isArray(U)?U.map(e=>Ko(e,k)):Ko(U,k),[D,U,k]);Ve(T(Ae.state.triggerElement),H,U,pt(()=>ze),!ne,p);let Be=G.useRef(U),He=D?Array.isArray(U)&&U.length>0:U!=null&&Ko(U,k)!==``;Ye(()=>{U!==Be.current&&Ae.set(`forceMount`,!0)},[Ae,U]),Ye(()=>{te(He)},[He,te]),Ye(function(){let e=me.current,t;if(D){let n=Array.isArray(U)?U:[];if(n.length===0)t=null;else{let r=n[n.length-1],i=Bo(e,r,A);t=i===-1?null:i}}else{let n=Bo(e,U,A);t=n===-1?null:n}t===null&&(ve.current=null),!oe&&Ae.set(`selectedIndex`,t)},[He,D,oe,U,me,A,Ae,ve]);function Ue(e){let t=L.initialValue;return Array.isArray(e)&&Array.isArray(t)?!Yo(e,t,(e,t)=>Ro(e,t,A)):e!==t}nn(U,()=>{N(re),P(Ue(U)),B.change(U)});let We=pt((e,t)=>{d?.(e,t),!t.isCanceled&&(se(e),!e&&(t.reason===`focus-out`||t.reason===`outside-press`)&&(F(!0),I(!1),V===`onBlur`&&B.commit(U)))}),Ke=pt(()=>{Te(!1),Ae.update({activeIndex:null,openMethod:null}),w?.(!1)});ee({enabled:!x,open:oe,ref:ue,onComplete(){oe||Ke()}}),G.useImperativeHandle(x,()=>({unmount:Ke}),[Ke]);let qe=pt((e,t)=>{s?.(e,t),!t.isCanceled&&ie(e)}),Je=pt(()=>{let e=Ae.state.listElement||ue.current;if(!e)return;let t=an(e.scrollHeight,e.clientHeight),n=on(e.scrollTop,t),r=n>0,i=n<t;Ae.state.scrollUpArrowVisible!==r&&Ae.set(`scrollUpArrowVisible`,r),Ae.state.scrollDownArrowVisible!==i&&Ae.set(`scrollDownArrowVisible`,i)}),Xe=Ut({open:oe,onOpenChange:We,elements:{reference:Pe,floating:Fe}}),Ze=Lt(Xe,{enabled:!v&&!ne,event:`mousedown`}),Qe=xe(Xe),$e=Kt(Xe,{enabled:!v&&!ne,listRef:ce,activeIndex:Me,selectedIndex:Ne,disabledIndices:f,onNavigate(e){e===null&&!oe||Ae.set(`activeIndex`,e)},focusItemOnHover:j}),et=Yt(Xe,{enabled:!v&&!ne&&(oe||!D),listRef:le,activeIndex:Me,selectedIndex:Ne,disabledIndices:e=>Qt(ce.current[e]),onMatch(e){oe?Ae.set(`activeIndex`,e):qe(me.current[e],_(`none`))},onTyping(e){he.current=e}}),tt=G.useMemo(()=>{let e=u(et.reference,$e.reference,Qe.reference,Ze.reference,Oe);return H&&(e.id=H),e},[Ze.reference,et.reference,$e.reference,Qe.reference,Oe,H]),nt=G.useMemo(()=>u(Ge,et.floating,$e.floating,Qe.floating),[et.floating,$e.floating,Qe.floating]),rt=$e.item??n;Ce(()=>{Ae.update({popupProps:nt,triggerProps:tt})}),Ye(()=>{Ae.update({id:H,modal:b,multiple:D,value:U,open:oe,mounted:we,transitionStatus:Ee,popupProps:nt,triggerProps:tt,items:E,itemToStringLabel:O,itemToStringValue:k,isItemEqualToValue:A,openMethod:Le})},[Ae,H,b,D,U,oe,we,Ee,nt,tt,E,O,k,A,Le]);let it=G.useMemo(()=>({store:Ae,name:re,required:y,disabled:ne,readOnly:v,multiple:D,highlightItemOnHover:j,setValue:qe,setOpen:We,listRef:ce,popupRef:ue,scrollHandlerRef:de,handleScrollArrowVisibility:Je,scrollArrowsMountedCountRef:fe,itemProps:rt,valueRef:pe,valuesRef:me,labelsRef:le,typingRef:he,selectionRef:ye,firstItemTextRef:ge,selectedItemTextRef:ve,validation:B,onOpenChangeComplete:w,alignItemWithTriggerActiveRef:be,initialValueRef:Be}),[Ae,re,y,ne,v,D,j,qe,We,rt,B,w,Je]),at=r(S,B.inputRef),ot=D&&Array.isArray(U)&&U.length>0,ct=D?void 0:re,lt=G.useMemo(()=>!D||!Array.isArray(U)||!re?null:U.map(e=>{let t=Ko(e,k);return(0,K.jsx)(`input`,{type:`hidden`,form:m,name:re,value:t,disabled:ne},t)}),[D,U,m,re,k,ne]);return(0,K.jsx)(No.Provider,{value:it,children:(0,K.jsxs)(Po.Provider,{value:Xe,children:[M,(0,K.jsx)(`input`,{...B.getValidationProps(ne,{onFocus(){Ae.state.triggerElement?.focus({focusVisible:!0})},onChange(e){if(e.nativeEvent.defaultPrevented||ne||v)return;let t=e.currentTarget.value,n=_(xt,e.nativeEvent);function r(){if(D)return;let e=t.toLowerCase(),r=me.current.findIndex(t=>Ko(t,k).toLowerCase()===e||Go(t,O).toLowerCase()===e);r===-1&&(r=me.current.findIndex((t,n)=>{let r=le.current[n];return r!=null&&r.toLowerCase()===e}));let i=r===-1?void 0:me.current[r];i!=null&&qe(i,n)}Ae.set(`forceMount`,!0),queueMicrotask(r)}}),id:H&&ct==null?`${H}-hidden-input`:void 0,form:m,name:ct,autoComplete:h,value:Re,disabled:ne,required:y&&!ot,readOnly:v,ref:at,style:re?gt:C,tabIndex:-1,"aria-hidden":!0,suppressHydrationWarning:!0}),lt]})})}function Zo(e,t){return e??t}var Qo=2,$o=400,es={...L,...Je,popupSide:e=>e?{"data-popup-side":e}:null,value:()=>null},ts=G.forwardRef(function(e,t){let{render:n,className:r,id:i,disabled:a=!1,nativeButton:o=!0,style:c,...l}=e,{setTouched:d,setFocused:f,validationMode:p,state:m,disabled:h}=je(),{labelId:g}=$e(),{store:v,setOpen:y,selectionRef:b,validation:x,readOnly:S,required:C,alignItemWithTriggerActiveRef:w,disabled:E}=Fo(),D=h||E||a,O=W(v,Y.open),k=W(v,Y.mounted),A=W(v,Y.value),j=W(v,Y.triggerProps),M=W(v,Y.positionerElement),N=W(v,Y.listElement),P=W(v,Y.popupSide),I=W(v,Y.id),L=W(v,Y.labelId),ee=W(v,Y.hasSelectedValue),te=k&&M?P:null,R=i??I,z=Zo(g,L);ke({id:R});let B=T(M),V=G.useRef(null),{getButtonProps:H,buttonRef:ne}=et({disabled:D,native:o}),re=pt(e=>{v.set(`triggerElement`,e)}),U=it(),ie=it(),ae=it();G.useEffect(()=>{if(O)return ae.start($o,()=>{b.current.allowUnselectedMouseUp=!0,b.current.allowSelectedMouseUp=!0}),()=>{ae.clear()};b.current={allowSelectedMouseUp:!1,allowUnselectedMouseUp:!1,dragY:0},ie.clear()},[O,b,ie,ae]);let oe=u(j,{id:R,role:`combobox`,"aria-expanded":O?`true`:`false`,"aria-haspopup":`listbox`,"aria-controls":O?N?.id??qe(M)?.id:void 0,"aria-labelledby":z,"aria-readonly":S||void 0,"aria-required":C||void 0,tabIndex:D?-1:0,onFocus(e){f(!0),O&&w.current&&y(!1,_(xt,e.nativeEvent)),U.start(0,()=>{v.set(`forceMount`,!0)})},onBlur(e){F(M,e.relatedTarget)||(d(!0),f(!1),p===`onBlur`&&x.commit(A))},onMouseDown(e){if(O)return;let t=ge(e.currentTarget);function n(e){if(!V.current)return;let t=e.target;if(F(V.current,t)||F(B.current,t))return;let n=Xt(V.current);e.clientX>=n.left-Qo&&e.clientX<=n.right+Qo&&e.clientY>=n.top-Qo&&e.clientY<=n.bottom+Qo||y(!1,_(Ke,e))}ie.start(0,()=>{t.addEventListener(`mouseup`,n,{once:!0})})}},l,H),se=x.getValidationProps(D,oe);se.role=`combobox`;let ce={...m,open:O,disabled:D,value:A,readOnly:S,popupSide:te,placeholder:!ee};return s(`button`,e,{ref:[t,V,ne,re],state:ce,stateAttributesMapping:es,props:se})}),ns={value:()=>null},rs=G.forwardRef(function(e,t){let{className:n,render:r,children:i,placeholder:a,style:o,...c}=e,{store:l,valueRef:u}=Fo(),d=W(l,Y.value),f=W(l,Y.items),p=W(l,Y.itemToStringLabel),m=W(l,Y.hasSelectedValue),h=!m&&a!=null&&i==null,g=W(l,Y.hasNullItemLabel,h),_={value:d,placeholder:!m},v=null;return v=typeof i==`function`?i(d):i??(!m&&a!=null&&!g?a:Array.isArray(d)?Jo(d,f,p):qo(d,f,p)),s(`span`,e,{state:_,ref:[t,u],props:[{children:v},c],stateAttributesMapping:ns})}),is=G.forwardRef(function(e,t){let{render:n,className:r,style:i,...a}=e,{store:o}=Fo();return s(`span`,e,{state:{open:W(o,Y.open)},ref:t,props:[{"aria-hidden":!0,children:`▼`},a],stateAttributesMapping:we})}),as=G.createContext(void 0),os=G.forwardRef(function(e,t){let{store:n}=Fo(),r=W(n,Y.mounted),i=W(n,Y.forceMount);return r||i?(0,K.jsx)(as.Provider,{value:!0,children:(0,K.jsx)(He,{ref:t,...e})}):null}),ss=G.createContext(void 0);function cs(){let e=G.useContext(ss);if(!e)throw Error(d(59));return e}function ls(e,t){e&&Object.assign(e.style,t)}var us={position:`relative`,maxHeight:`100%`,overflowX:`hidden`,overflowY:`auto`},ds={position:`fixed`},fs=G.forwardRef(function(e,t){let{anchor:n,positionMethod:r=`absolute`,className:i,render:a,side:o=`bottom`,align:s=`center`,sideOffset:c=0,alignOffset:l=0,collisionBoundary:u=`clipping-ancestors`,collisionPadding:d,arrowPadding:f=5,sticky:p=!1,disableAnchorTracking:m,alignItemWithTrigger:h=!0,collisionAvoidance:g=ct,style:v,...y}=e,{store:b,listRef:x,labelsRef:S,alignItemWithTriggerActiveRef:C,selectedItemTextRef:w,valuesRef:T,initialValueRef:E,popupRef:D,setValue:O}=Fo(),k=Io(),A=W(b,Y.open),j=W(b,Y.mounted),M=W(b,Y.modal),N=W(b,Y.value),P=W(b,Y.openMethod),F=W(b,Y.positionerElement),I=W(b,Y.triggerElement),L=W(b,Y.isItemEqualToValue),ee=W(b,Y.transitionStatus),te=G.useRef(null),R=G.useRef(null),[z,B]=G.useState(h),V=j&&z&&P!==`touch`;!j&&z!==h&&B(h),Ye(()=>{j||(Y.scrollUpArrowVisible(b.state)&&b.set(`scrollUpArrowVisible`,!1),Y.scrollDownArrowVisible(b.state)&&b.set(`scrollDownArrowVisible`,!1))},[b,j]),G.useImperativeHandle(C,()=>V),Jt((V||M)&&A,P===`touch`,F,I);let H=Gt({anchor:n,floatingRootContext:k,positionMethod:r,mounted:j,side:o,sideOffset:c,align:s,alignOffset:l,arrowPadding:f,collisionBoundary:u,collisionPadding:d,sticky:p,disableAnchorTracking:m??V,collisionAvoidance:g,keepMounted:!0}),ne=V?`none`:H.side,re=V?ds:H.positionerStyles,U={open:A,side:ne,align:H.align,anchorHidden:H.anchorHidden};Ye(()=>{b.set(`popupSide`,H.side)},[b,H.side]);let ie=Zt(e,U,{styles:re,transitionStatus:ee,props:y,refs:[t,pt(e=>{b.set(`positionerElement`,e)})],hidden:!j,inert:!A}),ae=G.useRef(0),oe=pt(e=>{if(e.size===0&&ae.current===0||T.current.length===0)return;let t=ae.current;if(ae.current=e.size,e.size===t)return;let n=_(xt);if(t!==0&&!b.state.multiple&&N!==null&&Bo(T.current,N,L)===-1){let e=E.current,t=e!=null&&Bo(T.current,e,L)!==-1?e:null;O(t,n),t===null&&(b.set(`selectedIndex`,null),w.current=null)}if(t!==0&&b.state.multiple&&Array.isArray(N)){let e=e=>Bo(T.current,e,L)!==-1,t=N.filter(t=>e(t));(t.length!==N.length||t.some(e=>!zo(N,e,L)))&&(O(t,n),t.length===0&&(b.set(`selectedIndex`,null),w.current=null))}if(A&&V){b.update({scrollUpArrowVisible:!1,scrollDownArrowVisible:!1});let e={height:``};ls(F,e),ls(D.current,e)}}),se=G.useMemo(()=>({...H,side:ne,alignItemWithTriggerActive:V,setControlledAlignItemWithTrigger:B,scrollUpArrowRef:te,scrollDownArrowRef:R}),[H,ne,V,B]);return(0,K.jsx)(zt,{elementsRef:x,labelsRef:S,onMapChange:oe,children:(0,K.jsxs)(ss.Provider,{value:se,children:[j&&M&&(0,K.jsx)(Pe,{inert:tt(!A),cutout:I}),ie]})})}),ps={...rt,...De},ms=G.forwardRef(function(e,t){let{render:n,className:r,style:i,finalFocus:a,...o}=e,{store:c,popupRef:l,onOpenChangeComplete:u,setOpen:d,valueRef:f,firstItemTextRef:p,selectedItemTextRef:m,multiple:h,handleScrollArrowVisibility:g,scrollHandlerRef:v,listRef:y,highlightItemOnHover:b}=Fo(),{side:x,align:S,alignItemWithTriggerActive:C,isPositioned:w,setControlledAlignItemWithTrigger:T}=cs(),E=Vt(!0)!=null,D=Io(),O=Re(),{nonce:A,disableStyleElements:j}=lt(),M=W(c,Y.id),N=W(c,Y.open),P=W(c,Y.openMethod),F=W(c,Y.mounted),I=W(c,Y.popupProps),L=W(c,Y.transitionStatus),te=W(c,Y.triggerElement),R=W(c,Y.positionerElement),z=W(c,Y.listElement),B=G.useRef(!1),V=G.useRef(!1),H=G.useRef({}),ne=Oe(),re=pt(e=>{if(!R||!l.current||!V.current)return;if(B.current||!C){g();return}let t=R.style.top===`0px`,n=R.style.bottom===`0px`;if(!t&&!n){g();return}let r=_s(R),i=vs(R.getBoundingClientRect().height,`y`,r),a=ge(R),o=yt(R),s=o.getComputedStyle(R),c=parseFloat(s.marginTop),u=parseFloat(s.marginBottom),d=hs(o.getComputedStyle(l.current)),f=Math.min(a.documentElement.clientHeight-c-u,d),p=e.scrollTop,m=gs(e),h=0,_=null,v=!1,y=!1,b=e=>{R.style.height=`${e}px`},x=(t,n)=>{let r=rn(t,0,f-i);r>0&&b(i+r),e.scrollTop=n,f-(i+r)<=1&&(B.current=!0),g()},S=t?m-p:p,w=Math.min(i+S,f);if(h=w,S<=1){x(S,t?m:0);return}if(f-w>1?t?y=!0:_=0:(v=!0,n&&p<m&&(_=p-(S-(i+S-f)))),h=Math.ceil(h),h!==0&&b(h),y||_!=null){let t=gs(e),n=y?t:rn(_,0,t);Math.abs(e.scrollTop-n)>1&&(e.scrollTop=n)}(v||h>=f-1)&&(B.current=!0),g()});G.useImperativeHandle(v,()=>re,[re]),ee({open:N,ref:l,onComplete(){N&&u?.(!0)}});let U={open:N,transitionStatus:L,side:x,align:S};Ye(()=>{!R||!l.current||Object.keys(H.current).length||(H.current={top:R.style.top||`0`,left:R.style.left||`0`,right:R.style.right,height:R.style.height,bottom:R.style.bottom,minHeight:R.style.minHeight,maxHeight:R.style.maxHeight,marginTop:R.style.marginTop,marginBottom:R.style.marginBottom})},[l,R]),Ye(()=>{N||C||(V.current=!1,B.current=!1,ls(R,H.current))},[N,C,R,l]),Ye(()=>{let e=l.current;if(!N||!te||!R||!e||C&&!w||c.state.transitionStatus===`ending`)return;if(!C){V.current=!0,ne.request(g),e.style.removeProperty(`--transform-origin`);return}let t=xs(e);e.style.removeProperty(`--transform-origin`);try{let t=m.current;t?.isConnected||(t=!Y.hasSelectedValue(c.state)&&p.current?.isConnected?p.current:null);let n=f.current,r=yt(R),i=r.getComputedStyle(R),a=r.getComputedStyle(e),o=ge(te),s=_s(te),l=ys(te.getBoundingClientRect(),s),u=ys(R.getBoundingClientRect(),s),d=l.height,h=z||e,_=h.scrollHeight,v=parseFloat(a.borderBottomWidth),x=parseFloat(i.marginTop)||10,S=parseFloat(i.marginBottom)||10,C=parseFloat(i.minHeight)||100,w=hs(a),E=o.documentElement.clientHeight-x-S,D=o.documentElement.clientWidth,k=E-l.bottom+d,A,j=O===`rtl`?l.right-u.width:l.left,M=0;if(t&&n){let e=ys(n.getBoundingClientRect(),s);A=ys(t.getBoundingClientRect(),s),j=u.left+(O===`rtl`?e.right-A.right:e.left-A.left);let r=e.top-l.top+e.height/2;M=A.top-u.top+A.height/2-r}let N=k+M+S+v,P=Math.min(E,N),F=E-x-S,I=N-P,L=D-5;R.style.left=`${rn(j,5,L-u.width)}px`,R.style.height=`${P}px`,R.style.maxHeight=`none`,R.style.marginTop=`${x}px`,R.style.marginBottom=`${S}px`,e.style.height=`100%`;let ee=gs(h),ne=I>=ee-1;ne&&(P=Math.min(E,u.height)-(I-ee));let re=l.top<20||l.bottom>E-20||Math.ceil(P)+1<Math.min(_,C),U=(r.visualViewport?.scale??1)!==1&&at;if(re||U){V.current=!0,ls(R,H.current),T(!1);return}let ie=Math.max(C,P);if(ne){let e=Math.max(0,E-N);R.style.top=u.height>=F?`0`:`${e}px`,R.style.height=`${P}px`,h.scrollTop=gs(h)}else R.style.bottom=`0`,h.scrollTop=I;if(A){let t=u.top,n=u.height,r=A.top+A.height/2,i=rn(n>0?(r-t)/n*100:50,0,100);e.style.setProperty(`--transform-origin`,`50% ${i}%`)}(ie===E||P>=w)&&(B.current=!0),g(),b&&c.state.selectedIndex===null&&c.state.activeIndex===null&&y.current[0]!=null&&c.set(`activeIndex`,0),V.current=!0}finally{t()}},[c,N,R,te,f,p,m,l,g,C,T,ne,z,y,b,O,w]),G.useEffect(()=>{if(!C||!R||!N)return;let e=yt(R);function t(e){d(!1,_(k,e))}return oe(e,`resize`,t)},[d,C,R,N]);let ie={...z?{role:`presentation`,"aria-orientation":void 0}:{role:`listbox`,"aria-multiselectable":h||void 0,id:`${M}-list`},onKeyDown(e){E&&vt.has(e.key)&&e.stopPropagation()},onScroll(e){z||re(e.currentTarget)},...C&&{style:z?{height:`100%`}:us}},ae=s(`div`,e,{ref:[t,l],state:U,stateAttributesMapping:ps,props:[I,ie,Bt(L),{className:!z&&C?sn.className:void 0},o]});return(0,K.jsxs)(G.Fragment,{children:[!j&&sn.getElement(A),(0,K.jsx)(Ee,{context:D,modal:!1,disabled:!F,openInteractionType:P,returnFocus:a,restoreFocus:!0,children:ae})]})});function hs(e){let t=e.maxHeight||``;return t.endsWith(`px`)&&parseFloat(t)||1/0}function gs(e){return an(e.scrollHeight,e.clientHeight)}function _s(e){return Ht.getScale(e)}function vs(e,t,n){return e/n[t]}function ys(e,t){return en({x:vs(e.x,`x`,t),y:vs(e.y,`y`,t),width:vs(e.width,`x`,t),height:vs(e.height,`y`,t)})}var bs=[[`transform`,`none`],[`scale`,`1`],[`translate`,`0 0`]];function xs(e){let{style:t}=e,n={};for(let[e,r]of bs)n[e]=t.getPropertyValue(e),t.setProperty(e,r,`important`);return()=>{for(let[e]of bs){let r=n[e];r?t.setProperty(e,r):t.removeProperty(e)}}}var Ss=G.forwardRef(function(e,t){let{render:n,className:r,style:i,...a}=e,{store:o,scrollHandlerRef:c}=Fo(),{alignItemWithTriggerActive:l}=cs(),u=W(o,Y.hasScrollArrows),d=W(o,Y.openMethod),f=W(o,Y.multiple),p={id:`${W(o,Y.id)}-list`,role:`listbox`,"aria-multiselectable":f||void 0,onScroll(e){c.current?.(e.currentTarget)},...l&&{style:us},className:u&&d!==`touch`?sn.className:void 0};return s(`div`,e,{ref:[t,pt(e=>{o.set(`listElement`,e)})],props:[p,a]})}),Cs=G.createContext(void 0);function ws(){let e=G.useContext(Cs);if(!e)throw Error(d(57));return e}var Ts=G.memo(G.forwardRef(function(e,t){let{render:n,className:r,style:i,value:a=null,label:o,disabled:c=!1,nativeButton:l=!1,...u}=e,d=G.useRef(null),f=tn({label:o,textRef:d,indexGuessBehavior:Rt.GuessFromOrder}),{store:p,itemProps:m,setOpen:h,setValue:g,selectionRef:v,typingRef:y,valuesRef:b,multiple:x,selectedItemTextRef:S,disabled:C,readOnly:w}=Fo(),T=W(p,Y.isActive,f.index),E=W(p,Y.open),D=W(p,Y.isSelected,a),O=W(p,Y.isSelectedByFocus,f.index),k=W(p,Y.isItemEqualToValue),A=f.index,j=A!==-1,M=G.useRef(null);Ye(()=>{if(!j)return;let e=b.current;return e[A]=a,()=>{delete e[A]}},[j,A,a,b]),Ye(()=>{if(!j)return;let e=p.state.value,t=e;x&&Array.isArray(e)&&(t=e.length>0?e[e.length-1]:void 0),t!==void 0&&Ro(a,t,k)&&(p.set(`selectedIndex`,A),d.current&&(S.current=d.current))},[j,A,x,k,p,a,S]);let N=G.useRef(null),F=G.useRef(`mouse`),I=G.useRef(!1),{getButtonProps:L,buttonRef:ee}=et({disabled:c,focusableWhenDisabled:!0,native:l,composite:!0}),te={disabled:c,selected:D,highlighted:T};function R(e){if(C||w)return;let t=p.state.value;if(x){let n=Array.isArray(t)?t:[],r=D?Vo(n,a,k):[...n,a];g(r,_(P,e))}else g(a,_(P,e)),h(!1,_(P,e))}function z(){v.current.dragY=0}let B={role:`option`,"aria-selected":D,tabIndex:E&&T?0:-1,onKeyDown(e){N.current=e.key,p.set(`activeIndex`,A),e.key===` `&&y.current&&e.preventDefault()},onClick(e){let t=e.type===`click`&&F.current!==`touch`,n=e.nativeEvent.pointerType,r=t&&ye(e.nativeEvent)&&(n!==void 0||T),i=t&&!r&&!I.current;I.current=!1,!(e.type===`keydown`&&N.current===null)&&(c||e.type===`keydown`&&N.current===` `&&y.current||i||(N.current=null,R(e.nativeEvent)))},onPointerEnter(e){F.current=e.pointerType},onPointerMove(e){if(e.pointerType===`mouse`&&e.buttons===1){let t=v.current;t.dragY+=e.movementY,t.dragY**2>=64&&(t.allowUnselectedMouseUp=!0)}},onPointerDown(e){F.current=e.pointerType,I.current=!0,z()},onMouseUp(){if(z(),c||F.current===`touch`||I.current)return;let e=!v.current.allowSelectedMouseUp&&D,t=!v.current.allowUnselectedMouseUp&&!D;e||t||(I.current=!0,M.current?.click(),I.current=!1)}},V=s(`div`,e,{ref:[ee,t,f.ref,M],state:te,props:[m,B,u,L]}),H=G.useMemo(()=>({selected:D,index:A,textRef:d,selectedByFocus:O,hasRegistered:j}),[D,A,d,O,j]);return(0,K.jsx)(Cs.Provider,{value:H,children:V})})),Es=G.forwardRef(function(e,t){let n=e.keepMounted??!1,{selected:r}=ws();return n||r?(0,K.jsx)(Ds,{...e,ref:t}):null}),Ds=G.memo(G.forwardRef((e,t)=>{let{render:n,className:r,style:i,keepMounted:a,...o}=e,{selected:c}=ws(),l=G.useRef(null),{transitionStatus:u,setMounted:d}=Se(c),f=s(`span`,e,{ref:[t,l],state:{selected:c,transitionStatus:u},props:[{"aria-hidden":!0,children:`✔️`},o],stateAttributesMapping:De});return ee({open:c,ref:l,onComplete(){c||d(!1)}}),f})),Os=G.memo(G.forwardRef(function(e,t){let{index:n,textRef:r,selectedByFocus:i,hasRegistered:a}=ws(),{firstItemTextRef:o,selectedItemTextRef:c}=Fo(),{render:l,className:u,style:d,...f}=e;return s(`div`,e,{ref:[G.useCallback(e=>{e&&(a&&n===0&&(o.current=e),a&&i&&(c.current=e))},[o,c,n,i,a]),t,r],props:f})})),ks=G.forwardRef(function(e,t){let{render:n,className:r,style:i,direction:a,keepMounted:o=!1,...c}=e,l=a===`up`,{store:u,popupRef:d,listRef:f,handleScrollArrowVisibility:p,scrollArrowsMountedCountRef:m}=Fo(),{side:h,scrollDownArrowRef:g,scrollUpArrowRef:_}=cs(),v=W(u,l?Y.scrollUpArrowVisible:Y.scrollDownArrowVisible),y=W(u,Y.openMethod),b=v&&y!==`touch`,x=it(),S=l?_:g,{mounted:C,transitionStatus:w,setMounted:T}=Se(b);Ye(()=>(m.current+=1,u.state.hasScrollArrows||u.set(`hasScrollArrows`,!0),()=>{m.current=Math.max(0,m.current-1),m.current===0&&u.state.hasScrollArrows&&u.set(`hasScrollArrows`,!1)}),[u,m]),ee({open:b,ref:S,onComplete(){b||T(!1)}});let E=s(`div`,e,{ref:[t,S],state:{direction:a,visible:b,side:h,transitionStatus:w},props:[{"aria-hidden":!0,children:l?`▲`:`▼`,style:{position:`absolute`},onMouseMove(e){if(e.movementX===0&&e.movementY===0||x.isStarted())return;u.set(`activeIndex`,null);function t(){let e=u.state.listElement??d.current;if(!e)return;u.set(`activeIndex`,null),p();let n=an(e.scrollHeight,e.clientHeight),r=on(e.scrollTop,n),i=r===(l?0:n),a=f.current;if(r!==e.scrollTop&&(e.scrollTop=r),a.length===0&&u.set(l?`scrollUpArrowVisible`:`scrollDownArrowVisible`,!i),i){x.clear();return}if(a.length>0){let t=S.current?.offsetHeight||0;e.scrollTop=As(a,l,r,e.clientHeight,t,n)}x.start(40,t)}x.start(40,t)},onMouseLeave(){x.clear()}},c],stateAttributesMapping:De});return C||o?E:null});function As(e,t,n,r,i,a){if(t){let t=0,r=n+i-1;for(let n=0;n<e.length;n+=1){let i=e[n];if(i&&i.offsetTop>=r){t=n;break}}let o=Math.max(0,t-1),s=e[o];return o<t&&s?on(s.offsetTop-i,a):0}let o=e.length-1,s=n+r-i+1;for(let t=0;t<e.length;t+=1){let n=e[t];if(n&&n.offsetTop+n.offsetHeight>s){o=Math.max(0,t-1);break}}let c=Math.min(e.length-1,o+1),l=e[c];return c>o&&l?on(l.offsetTop+l.offsetHeight-r+i,a):a}var js=G.forwardRef(function(e,t){return(0,K.jsx)(ks,{...e,ref:t,direction:`down`})}),Ms=G.forwardRef(function(e,t){return(0,K.jsx)(ks,{...e,ref:t,direction:`up`})}),Ns=Xo,Ps=l(`relative inline-flex cursor-pointer select-none items-center justify-between gap-2 border rounded-lg text-left text-base outline-none transition-[color,box-shadow,background-color] data-disabled:pointer-events-none data-disabled:opacity-64 sm:text-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4.5 sm:[&_svg:not([class*='size-'])]:size-4`,{defaultVariants:{size:`default`,variant:`default`},variants:{variant:{default:`w-full min-w-36 border-input bg-background not-dark:bg-clip-padding text-foreground shadow-xs/5 ring-ring/24 before:pointer-events-none before:absolute before:inset-0 before:rounded-[calc(var(--radius-lg)-1px)] not-data-disabled:not-focus-visible:not-aria-invalid:not-data-pressed:before:shadow-[0_1px_--theme(--color-black/4%)] pointer-coarse:after:absolute pointer-coarse:after:size-full pointer-coarse:after:min-h-11 focus-visible:border-ring focus-visible:ring-[3px] aria-invalid:border-destructive/36 focus-visible:aria-invalid:border-destructive/64 focus-visible:aria-invalid:ring-destructive/16 dark:bg-input/32 dark:aria-invalid:ring-destructive/24 dark:not-data-disabled:not-focus-visible:not-aria-invalid:not-data-pressed:before:shadow-[0_-1px_--theme(--color-white/6%)] [&_svg:not([class*='opacity-'])]:opacity-80 [&_svg:not([class*='text-'])]:text-muted-foreground [[data-disabled],:focus-visible,[aria-invalid],[data-pressed]]:shadow-none`,ghost:`border-transparent text-muted-foreground/70 focus-visible:ring-2 focus-visible:ring-ring data-pressed:bg-accent [:hover,[data-pressed]]:bg-accent [:hover,[data-pressed]]:text-foreground/80`},size:{default:`min-h-9 px-[calc(--spacing(3)-1px)] sm:min-h-8`,lg:`min-h-10 px-[calc(--spacing(3)-1px)] sm:min-h-9`,sm:`min-h-8 gap-1.5 px-[calc(--spacing(2.5)-1px)] sm:min-h-7`,xs:`h-7 gap-1 rounded-md px-[calc(--spacing(2)-1px)] text-sm before:rounded-[calc(var(--radius-md)-1px)] sm:h-6 sm:text-xs [&_svg:not([class*='size-'])]:size-4 sm:[&_svg:not([class*='size-'])]:size-3.5`}}});function Fs({className:e,size:t=`default`,variant:n=`default`,children:r,...i}){return(0,K.jsxs)(ts,{className:c(Ps({size:t,variant:n}),e),"data-slot":`select-trigger`,...i,children:[r,(0,K.jsx)(is,{"data-slot":`select-icon`,children:(0,K.jsx)(St,{className:`-me-1 size-3 opacity-50`})})]})}function Is({className:e,...t}){return(0,K.jsx)(rs,{className:c(`flex-1 truncate data-placeholder:text-muted-foreground`,e),"data-slot":`select-value`,...t})}function Ls({className:e,popupClassName:t,children:n,side:r=`bottom`,sideOffset:i=4,align:a=`start`,alignOffset:o=0,alignItemWithTrigger:s=!0,matchTriggerWidth:l=!0,anchor:u,...d}){return(0,K.jsx)(os,{children:(0,K.jsx)(fs,{align:a,alignItemWithTrigger:s,alignOffset:o,anchor:u,className:`z-50 select-none`,"data-slot":`select-positioner`,side:r,sideOffset:i,children:(0,K.jsxs)(ms,{className:`origin-(--transform-origin) rounded-lg text-foreground outline-none`,"data-slot":`select-popup`,...d,children:[(0,K.jsx)(Ms,{className:`top-0 z-50 flex h-6 w-full cursor-default items-center justify-center before:pointer-events-none before:absolute before:inset-x-px before:top-px before:h-[200%] before:rounded-t-[calc(var(--radius-lg)-1px)] before:bg-linear-to-b before:from-50% before:from-popover`,"data-slot":`select-scroll-up-arrow`,children:(0,K.jsx)(Kr,{className:`relative size-4.5 sm:size-4`})}),(0,K.jsx)(`div`,{className:c(`relative h-full rounded-lg border bg-popover not-dark:bg-clip-padding shadow-lg/5 before:pointer-events-none before:absolute before:inset-0 before:rounded-[calc(var(--radius-lg)-1px)] before:shadow-[0_1px_--theme(--color-black/4%)] dark:before:shadow-[0_-1px_--theme(--color-white/6%)]`,l&&`min-w-(--anchor-width)`,t),children:(0,K.jsx)(Ss,{className:c(`max-h-(--available-height) overflow-y-auto p-1`,e),"data-slot":`select-list`,children:n})}),(0,K.jsx)(js,{className:`bottom-0 z-50 flex h-6 w-full cursor-default items-center justify-center before:pointer-events-none before:absolute before:inset-x-px before:bottom-px before:h-[200%] before:rounded-b-[calc(var(--radius-lg)-1px)] before:bg-linear-to-t before:from-50% before:from-popover`,"data-slot":`select-scroll-down-arrow`,children:(0,K.jsx)(St,{className:`relative size-4.5 sm:size-4`})})]})})})}function Rs({className:e,children:t,hideIndicator:n=!1,...r}){return(0,K.jsxs)(Ts,{className:c(`grid min-h-8 in-data-[side=none]:min-w-[calc(var(--anchor-width)+1.25rem)] cursor-default items-center gap-2 rounded-sm py-1 text-base outline-none data-disabled:pointer-events-none data-highlighted:bg-accent data-highlighted:text-accent-foreground data-disabled:opacity-64 sm:min-h-7 sm:text-sm [&_svg:not([class*='size-'])]:size-4.5 sm:[&_svg:not([class*='size-'])]:size-4 [&_svg]:pointer-events-none [&_svg]:shrink-0`,n?`grid-cols-[1fr] ps-3 pe-3`:`grid-cols-[1rem_1fr] ps-2 pe-4`,e),"data-slot":`select-item`,...r,children:[n?null:(0,K.jsx)(Es,{className:`col-start-1`,"data-slot":`select-item-indicator`,children:(0,K.jsx)(`svg`,{fill:`none`,height:`24`,stroke:`currentColor`,strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:`2`,viewBox:`0 0 24 24`,width:`24`,xmlns:`http://www.w3.org/1500/svg`,children:(0,K.jsx)(`path`,{d:`M5.252 12.7 10.2 18.63 18.748 5.37`})})}),(0,K.jsx)(Os,{className:c(`min-w-0 [&_svg:not([class*='text-'])]:text-muted-foreground`,n?`col-start-1`:`col-start-2`),"data-slot":`select-item-text`,children:t})]})}function zs({config:e,setConfig:t,defaultPaths:n,adapters:r,saveAppConfig:i}){let a=e.devDir.trim()!==``&&e.workspacesDir.trim()!==``;return(0,K.jsx)(`div`,{className:`flex min-h-screen bg-background text-foreground font-sans items-center justify-center p-6`,children:(0,K.jsxs)(`div`,{className:`max-w-6xl w-full bg-card border border-border rounded-xl p-10 shadow-sm grid grid-cols-1 lg:grid-cols-12 gap-12`,children:[(0,K.jsxs)(`div`,{className:`lg:col-span-7 flex flex-col justify-between`,children:[(0,K.jsxs)(`div`,{children:[(0,K.jsx)(`div`,{className:`inline-flex items-center gap-1.5 px-3 py-1 rounded-full bg-primary/10 text-primary border border-primary/20 text-xs font-semibold uppercase tracking-wider mb-5`,children:`Onboarding Guide`}),(0,K.jsx)(`h1`,{className:`text-3xl font-bold tracking-tight text-foreground mb-2`,children:`Welcome to NexusFlow`}),(0,K.jsx)(`p`,{className:`text-sm text-muted-foreground mb-8 max-w-xl leading-relaxed`,children:`NexusFlow orchestrates multi-repository developer environments. It combines isolated Git worktrees, automatic code analyzer sweeps, and background process running into a single dashboard.`}),(0,K.jsxs)(`div`,{className:`space-y-6`,children:[(0,K.jsxs)(`div`,{className:`flex gap-4 group`,children:[(0,K.jsx)(`div`,{className:`w-8 h-8 rounded-full bg-primary/10 border border-primary/20 text-primary flex items-center justify-center font-bold text-sm shrink-0 group-hover:bg-primary/20 transition-colors`,children:`1`}),(0,K.jsxs)(`div`,{children:[(0,K.jsx)(`h3`,{className:`text-sm font-semibold text-foreground transition-colors`,children:`Configure Development Folders`}),(0,K.jsx)(`p`,{className:`text-xs text-muted-foreground mt-1 leading-relaxed`,children:`Specify your local code path and target workspaces path. For the first setup, these paths start empty so you can explicitly configure them.`})]})]}),(0,K.jsxs)(`div`,{className:`flex gap-4 group`,children:[(0,K.jsx)(`div`,{className:`w-8 h-8 rounded-full bg-primary/10 border border-primary/20 text-primary flex items-center justify-center font-bold text-sm shrink-0 group-hover:bg-primary/20 transition-colors`,children:`2`}),(0,K.jsxs)(`div`,{children:[(0,K.jsx)(`h3`,{className:`text-sm font-semibold text-foreground transition-colors`,children:`Build Isolated Branch Workspaces`}),(0,K.jsxs)(`p`,{className:`text-xs text-muted-foreground mt-1 leading-relaxed`,children:[`Choose repositories and input your feature branch. NexusFlow runs `,(0,K.jsx)(`code`,{children:`git worktree`}),` to checkout dependencies under a unified folder structure, leaving your primary repository directories clean.`]})]})]}),(0,K.jsxs)(`div`,{className:`flex gap-4 group`,children:[(0,K.jsx)(`div`,{className:`w-8 h-8 rounded-full bg-primary/10 border border-primary/20 text-primary flex items-center justify-center font-bold text-sm shrink-0 group-hover:bg-primary/20 transition-colors`,children:`3`}),(0,K.jsxs)(`div`,{children:[(0,K.jsx)(`h3`,{className:`text-sm font-semibold text-foreground transition-colors`,children:`Align AI Coding Contexts`}),(0,K.jsxs)(`p`,{className:`text-xs text-muted-foreground mt-1 leading-relaxed`,children:[`NexusFlow automatically generates configuration files (`,(0,K.jsx)(`code`,{children:`CLAUDE.md`}),`, `,(0,K.jsx)(`code`,{children:`.cursorrules`}),`, `,(0,K.jsx)(`code`,{children:`AGENTS.md`}),`) that instruct the AI assistant to analyze project inter-dependencies, document its assumptions in `,(0,K.jsx)(`code`,{children:`nexusflow-overview.md`}),`, and highlight clarifying questions.`]})]})]}),(0,K.jsxs)(`div`,{className:`flex gap-4 group`,children:[(0,K.jsx)(`div`,{className:`w-8 h-8 rounded-full bg-primary/10 border border-primary/20 text-primary flex items-center justify-center font-bold text-sm shrink-0 group-hover:bg-primary/20 transition-colors`,children:`4`}),(0,K.jsxs)(`div`,{children:[(0,K.jsx)(`h3`,{className:`text-sm font-semibold text-foreground transition-colors`,children:`Orchestrate Background Services`}),(0,K.jsx)(`p`,{className:`text-xs text-muted-foreground mt-1 leading-relaxed`,children:`Run APIs, database scripts, and frontend watch tasks concurrently from the web portal. Monitor real-time logs inside a unified terminal pane.`})]})]})]})]}),(0,K.jsx)(`div`,{className:`mt-8 pt-6 border-t border-border`,children:(0,K.jsx)(`p`,{className:`text-sm text-muted-foreground`,children:`NexusFlow offers native worktrees and local AI orchestration without the overhead of containers or virtual machines.`})})]}),(0,K.jsx)(`div`,{className:`lg:col-span-5 flex flex-col justify-center`,children:(0,K.jsxs)(`div`,{className:`bg-muted border border-border rounded-xl p-8 shadow-sm`,children:[(0,K.jsxs)(`h2`,{className:`text-xl font-semibold text-foreground mb-1 flex items-center gap-2`,children:[(0,K.jsx)(ri,{className:`text-primary`,size:20}),` Initialize Config`]}),(0,K.jsx)(`p`,{className:`text-sm text-muted-foreground mb-6`,children:`Define the directories on your machine. The fields are empty so you can provide your paths.`}),(0,K.jsxs)(`div`,{className:`space-y-5`,children:[(0,K.jsxs)(`div`,{children:[(0,K.jsx)(`label`,{className:`block text-sm font-medium text-foreground mb-2`,children:`Development Directory`}),(0,K.jsx)(Ze,{type:`text`,placeholder:`e.g. C:\\Users\\username\\dev`,value:e.devDir,onChange:n=>t({...e,devDir:n.target.value})}),n&&(0,K.jsx)(`div`,{className:`text-xs text-muted-foreground mt-1.5 flex justify-between items-center`,children:(0,K.jsxs)(`span`,{children:[`Suggested: `,(0,K.jsx)(`code`,{className:`text-primary`,children:n.devDir})]})})]}),(0,K.jsxs)(`div`,{children:[(0,K.jsx)(`label`,{className:`block text-sm font-medium text-foreground mb-2`,children:`Workspaces Directory`}),(0,K.jsx)(Ze,{type:`text`,placeholder:`e.g. C:\\Users\\username\\dev\\workspaces`,value:e.workspacesDir,onChange:n=>t({...e,workspacesDir:n.target.value})}),n&&(0,K.jsx)(`div`,{className:`text-xs text-muted-foreground mt-1.5 flex justify-between items-center`,children:(0,K.jsxs)(`span`,{children:[`Suggested: `,(0,K.jsx)(`code`,{className:`text-primary`,children:n.workspacesDir})]})})]}),(0,K.jsxs)(`div`,{className:`pt-2`,children:[(0,K.jsx)(`label`,{htmlFor:`onboardingStorageProvider`,className:`text-sm font-medium text-foreground block mb-2`,children:`Storage Provider`}),(0,K.jsxs)(Ns,{value:e.storageProvider||`local`,onValueChange:n=>{if(!n)return;let i={...e,storageProvider:n},a=r.find(e=>e.name===n);a?.configFields?.length&&(i.adapterConfig||={},i.adapterConfig[n]||(i.adapterConfig[n]={}),a.configFields.forEach(e=>{i.adapterConfig[n][e.key]===void 0&&e.default!==void 0&&(i.adapterConfig[n][e.key]=e.default)})),t(i)},children:[(0,K.jsx)(Fs,{id:`onboardingStorageProvider`,children:(0,K.jsx)(Is,{placeholder:`Select a provider`})}),(0,K.jsx)(Ls,{children:r.length>0?r.map(e=>(0,K.jsx)(Rs,{value:e.name,children:e.displayName},e.name)):(0,K.jsx)(Rs,{value:`local`,children:`Local Workspace (Folders)`})})]}),(0,K.jsx)(`span`,{className:`text-xs text-muted-foreground mt-1 block leading-normal`,children:r.find(t=>t.name===(e.storageProvider||`local`))?.description||`Where the generated context files are written. They must sit at the workspace root for an assistant to load them.`})]}),(0,K.jsxs)(`div`,{className:`flex gap-2 pt-2`,children:[(0,K.jsx)(p,{variant:`outline`,className:`flex-1`,onClick:()=>{n&&t({...e,devDir:n.devDir,workspacesDir:n.workspacesDir})},children:`Suggest Defaults`}),(0,K.jsx)(p,{variant:`ghost`,onClick:()=>{t({...e,devDir:``,workspacesDir:``})},children:`Clear`})]}),(0,K.jsx)(`div`,{className:`pt-4`,children:(0,K.jsxs)(p,{className:`w-full gap-2`,disabled:!a,onClick:()=>i(e),children:[`Save & Get Started `,(0,K.jsx)(Vr,{size:16})]})})]})]})})]})})}function Bs(e,t){let n=t||{};return(e[e.length-1]===``?[...e,``]:e).join((n.padRight?` `:``)+`,`+(n.padLeft===!1?``:` `)).trim()}var Vs=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,Hs=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,Us={};function Ws(e,t){return((t||Us).jsx?Hs:Vs).test(e)}var Gs=/[ \t\n\f\r]/g;function Ks(e){return typeof e==`object`?e.type===`text`&&qs(e.value):qs(e)}function qs(e){return e.replace(Gs,``)===``}var Js=class{constructor(e,t,n){this.normal=t,this.property=e,n&&(this.space=n)}};Js.prototype.normal={},Js.prototype.property={},Js.prototype.space=void 0;function Ys(e,t){let n={},r={};for(let t of e)Object.assign(n,t.property),Object.assign(r,t.normal);return new Js(n,r,t)}function Xs(e){return e.toLowerCase()}var Zs=class{constructor(e,t){this.attribute=t,this.property=e}};Zs.prototype.attribute=``,Zs.prototype.booleanish=!1,Zs.prototype.boolean=!1,Zs.prototype.commaOrSpaceSeparated=!1,Zs.prototype.commaSeparated=!1,Zs.prototype.defined=!1,Zs.prototype.mustUseProperty=!1,Zs.prototype.number=!1,Zs.prototype.overloadedBoolean=!1,Zs.prototype.property=``,Zs.prototype.spaceSeparated=!1,Zs.prototype.space=void 0;var Qs=h({boolean:()=>X,booleanish:()=>ec,commaOrSpaceSeparated:()=>ic,commaSeparated:()=>rc,number:()=>Z,overloadedBoolean:()=>tc,spaceSeparated:()=>nc}),$s=0,X=ac(),ec=ac(),tc=ac(),Z=ac(),nc=ac(),rc=ac(),ic=ac();function ac(){return 2**++$s}var oc=Object.keys(Qs),sc=class extends Zs{constructor(e,t,n,r){let i=-1;if(super(e,t),cc(this,`space`,r),typeof n==`number`)for(;++i<oc.length;){let e=oc[i];cc(this,oc[i],(n&Qs[e])===Qs[e])}}};sc.prototype.defined=!0;function cc(e,t,n){n&&(e[t]=n)}function lc(e){let t={},n={};for(let[r,i]of Object.entries(e.properties)){let a=new sc(r,e.transform(e.attributes||{},r),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[Xs(r)]=r,n[Xs(a.attribute)]=r}return new Js(t,n,e.space)}var uc=lc({properties:{ariaActiveDescendant:null,ariaAtomic:ec,ariaAutoComplete:null,ariaBusy:ec,ariaChecked:ec,ariaColCount:Z,ariaColIndex:Z,ariaColSpan:Z,ariaControls:nc,ariaCurrent:null,ariaDescribedBy:nc,ariaDetails:null,ariaDisabled:ec,ariaDropEffect:nc,ariaErrorMessage:null,ariaExpanded:ec,ariaFlowTo:nc,ariaGrabbed:ec,ariaHasPopup:null,ariaHidden:ec,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:nc,ariaLevel:Z,ariaLive:null,ariaModal:ec,ariaMultiLine:ec,ariaMultiSelectable:ec,ariaOrientation:null,ariaOwns:nc,ariaPlaceholder:null,ariaPosInSet:Z,ariaPressed:ec,ariaReadOnly:ec,ariaRelevant:null,ariaRequired:ec,ariaRoleDescription:nc,ariaRowCount:Z,ariaRowIndex:Z,ariaRowSpan:Z,ariaSelected:ec,ariaSetSize:Z,ariaSort:null,ariaValueMax:Z,ariaValueMin:Z,ariaValueNow:Z,ariaValueText:null,role:null},transform(e,t){return t===`role`?t:`aria-`+t.slice(4).toLowerCase()}});function dc(e,t){return t in e?e[t]:t}function fc(e,t){return dc(e,t.toLowerCase())}var pc=lc({attributes:{acceptcharset:`accept-charset`,classname:`class`,htmlfor:`for`,httpequiv:`http-equiv`},mustUseProperty:[`checked`,`multiple`,`muted`,`selected`],properties:{abbr:null,accept:rc,acceptCharset:nc,accessKey:nc,action:null,allow:null,allowFullScreen:X,allowPaymentRequest:X,allowUserMedia:X,alpha:X,alt:null,as:null,async:X,autoCapitalize:null,autoComplete:nc,autoFocus:X,autoPlay:X,blocking:nc,capture:null,charSet:null,checked:X,cite:null,className:nc,closedBy:null,colorSpace:null,cols:Z,colSpan:Z,command:null,commandFor:null,content:null,contentEditable:ec,controls:X,controlsList:nc,coords:Z|rc,crossOrigin:null,data:null,dateTime:null,decoding:null,default:X,defer:X,dir:null,dirName:null,disabled:X,download:tc,draggable:ec,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:X,formTarget:null,headers:nc,height:Z,hidden:tc,high:Z,href:null,hrefLang:null,htmlFor:nc,httpEquiv:nc,id:null,imageSizes:null,imageSrcSet:null,inert:X,inputMode:null,integrity:null,is:null,isMap:X,itemId:null,itemProp:nc,itemRef:nc,itemScope:X,itemType:nc,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:X,low:Z,manifest:null,max:null,maxLength:Z,media:null,method:null,min:null,minLength:Z,multiple:X,muted:X,name:null,nonce:null,noModule:X,noValidate:X,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:X,optimum:Z,pattern:null,ping:nc,placeholder:null,playsInline:X,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:X,referrerPolicy:null,rel:nc,required:X,reversed:X,rows:Z,rowSpan:Z,sandbox:nc,scope:null,scoped:X,seamless:X,selected:X,shadowRootClonable:X,shadowRootCustomElementRegistry:X,shadowRootDelegatesFocus:X,shadowRootMode:null,shadowRootSerializable:X,shape:null,size:Z,sizes:null,slot:null,span:Z,spellCheck:ec,src:null,srcDoc:null,srcLang:null,srcSet:null,start:Z,step:null,style:null,tabIndex:Z,target:null,title:null,translate:null,type:null,typeMustMatch:X,useMap:null,value:ec,width:Z,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:nc,axis:null,background:null,bgColor:null,border:Z,borderColor:null,bottomMargin:Z,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:X,declare:X,event:null,face:null,frame:null,frameBorder:null,hSpace:Z,leftMargin:Z,link:null,longDesc:null,lowSrc:null,marginHeight:Z,marginWidth:Z,noResize:X,noHref:X,noShade:X,noWrap:X,object:null,profile:null,prompt:null,rev:null,rightMargin:Z,rules:null,scheme:null,scrolling:ec,standby:null,summary:null,text:null,topMargin:Z,valueType:null,version:null,vAlign:null,vLink:null,vSpace:Z,allowTransparency:null,autoCorrect:null,autoSave:null,credentialless:X,disablePictureInPicture:X,disableRemotePlayback:X,exportParts:rc,part:nc,prefix:null,property:null,results:Z,security:null,unselectable:null},space:`html`,transform:fc}),mc=lc({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`,maskType:`mask-type`,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:ic,accentHeight:Z,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:Z,amplitude:Z,arabicForm:null,ascent:Z,attributeName:null,attributeType:null,azimuth:Z,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:Z,by:null,calcMode:null,capHeight:Z,className:nc,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:Z,diffuseConstant:Z,direction:null,display:null,dur:null,divisor:Z,dominantBaseline:null,download:X,dx:null,dy:null,edgeMode:null,editable:null,elevation:Z,enableBackground:null,end:null,event:null,exponent:Z,externalResourcesRequired:null,fill:null,fillOpacity:Z,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:rc,g2:rc,glyphName:rc,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:Z,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:Z,horizOriginX:Z,horizOriginY:Z,id:null,ideographic:Z,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:Z,k:Z,k1:Z,k2:Z,k3:Z,k4:Z,kernelMatrix:ic,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:Z,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskType:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:Z,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:Z,overlineThickness:Z,paintOrder:null,panose1:null,path:null,pathLength:Z,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:nc,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:Z,pointsAtY:Z,pointsAtZ:Z,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:ic,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:ic,rev:ic,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:ic,requiredFeatures:ic,requiredFonts:ic,requiredFormats:ic,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:Z,specularExponent:Z,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:Z,strikethroughThickness:Z,string:null,stroke:null,strokeDashArray:ic,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:Z,strokeOpacity:Z,strokeWidth:null,style:null,surfaceScale:Z,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:ic,tabIndex:Z,tableValues:null,target:null,targetX:Z,targetY:Z,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:ic,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:Z,underlineThickness:Z,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:Z,values:null,vAlphabetic:Z,vMathematical:Z,vectorEffect:null,vHanging:Z,vIdeographic:Z,version:null,vertAdvY:Z,vertOriginX:Z,vertOriginY:Z,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:Z,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:`svg`,transform:dc}),hc=lc({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:`xlink`,transform(e,t){return`xlink:`+t.slice(5).toLowerCase()}}),gc=lc({attributes:{xmlnsxlink:`xmlns:xlink`},properties:{xmlnsXLink:null,xmlns:null},space:`xmlns`,transform:fc}),_c=lc({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:`xml`,transform(e,t){return`xml:`+t.slice(3).toLowerCase()}}),vc={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`},yc=/[A-Z]/g,bc=/-[a-z]/g,xc=/^data[-\w.:]+$/i;function Sc(e,t){let n=Xs(t),r=t,i=Zs;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)===`data`&&xc.test(t)){if(t.charAt(4)===`-`){let e=t.slice(5).replace(bc,wc);r=`data`+e.charAt(0).toUpperCase()+e.slice(1)}else{let e=t.slice(4);if(!bc.test(e)){let n=e.replace(yc,Cc);n.charAt(0)!==`-`&&(n=`-`+n),t=`data`+n}}i=sc}return new i(r,t)}function Cc(e){return`-`+e.toLowerCase()}function wc(e){return e.charAt(1).toUpperCase()}var Tc=Ys([uc,pc,hc,gc,_c],`html`),Ec=Ys([uc,mc,hc,gc,_c],`svg`);function Dc(e){return e.join(` `).trim()}var Oc=m(((e,t)=>{var n=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,r=/\n/g,i=/^\s*/,a=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,s=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,c=/^[;\s]*/,l=/^\s+|\s+$/g;function u(e,t){if(typeof e!=`string`)throw TypeError(`First argument must be a string`);if(!e)return[];t||={};var l=1,u=1;function f(e){var t=e.match(r);t&&(l+=t.length);var n=e.lastIndexOf(`
|
|
11
|
+
`);u=~n?e.length-n:u+e.length}function p(){var e={line:l,column:u};return function(t){return t.position=new m(e),_(),t}}function m(e){this.start=e,this.end={line:l,column:u},this.source=t.source}m.prototype.content=e;function h(n){var r=Error(t.source+`:`+l+`:`+u+`: `+n);if(r.reason=n,r.filename=t.source,r.line=l,r.column=u,r.source=e,!t.silent)throw r}function g(t){var n=t.exec(e);if(n){var r=n[0];return f(r),e=e.slice(r.length),n}}function _(){g(i)}function v(e){var t;for(e||=[];t=y();)t!==!1&&e.push(t);return e}function y(){var t=p();if(!(e.charAt(0)!=`/`||e.charAt(1)!=`*`)){for(var n=2;e.charAt(n)!=``&&(e.charAt(n)!=`*`||e.charAt(n+1)!=`/`);)++n;if(n+=2,e.charAt(n-1)===``)return h(`End of comment missing`);var r=e.slice(2,n-2);return u+=2,f(r),e=e.slice(n),u+=2,t({type:`comment`,comment:r})}}function b(){var e=p(),t=g(a);if(t){if(y(),!g(o))return h(`property missing ':'`);var r=g(s),i=e({type:`declaration`,property:d(t[0].replace(n,``)),value:r?d(r[0].replace(n,``)):``});return g(c),i}}function x(){var e=[];v(e);for(var t;t=b();)t!==!1&&(e.push(t),v(e));return e}return _(),x()}function d(e){return e?e.replace(l,``):``}t.exports=u})),kc=m((e=>{var t=e&&e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(e,"__esModule",{value:!0}),e.default=r;var n=t(Oc());function r(e,t){let r=null;if(!e||typeof e!=`string`)return r;let i=(0,n.default)(e),a=typeof t==`function`;return i.forEach(e=>{if(e.type!==`declaration`)return;let{property:n,value:i}=e;a?t(n,i,e):i&&(r||={},r[n]=i)}),r}})),Ac=m((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.camelCase=void 0;var t=/^--[a-zA-Z0-9_-]+$/,n=/-([a-z])/g,r=/^[^-]+$/,i=/^-(webkit|moz|ms|o|khtml)-/,a=/^-(ms)-/,o=function(e){return!e||r.test(e)||t.test(e)},s=function(e,t){return t.toUpperCase()},c=function(e,t){return`${t}-`};e.camelCase=function(e,t){return t===void 0&&(t={}),o(e)?e:(e=e.toLowerCase(),e=t.reactCompat?e.replace(a,c):e.replace(i,c),e.replace(n,s))}})),jc=m(((e,t)=>{var n=(e&&e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}})(kc()),r=Ac();function i(e,t){var i={};return!e||typeof e!=`string`||(0,n.default)(e,function(e,n){e&&n&&(i[(0,r.camelCase)(e,t)]=n)}),i}i.default=i,t.exports=i})),Mc=Pc(`end`),Nc=Pc(`start`);function Pc(e){return t;function t(t){let n=t&&t.position&&t.position[e]||{};if(typeof n.line==`number`&&n.line>0&&typeof n.column==`number`&&n.column>0)return{line:n.line,column:n.column,offset:typeof n.offset==`number`&&n.offset>-1?n.offset:void 0}}}function Fc(e){let t=Nc(e),n=Mc(e);if(t&&n)return{start:t,end:n}}function Ic(e){return!e||typeof e!=`object`?``:`position`in e||`type`in e?Rc(e.position):`start`in e||`end`in e?Rc(e):`line`in e||`column`in e?Lc(e):``}function Lc(e){return zc(e&&e.line)+`:`+zc(e&&e.column)}function Rc(e){return Lc(e&&e.start)+`-`+Lc(e&&e.end)}function zc(e){return e&&typeof e==`number`?e:1}var Bc=class extends Error{constructor(e,t,n){super(),typeof t==`string`&&(n=t,t=void 0);let r=``,i={},a=!1;if(t&&(i=`line`in t&&`column`in t||`start`in t&&`end`in t?{place:t}:`type`in t?{ancestors:[t],place:t.position}:{...t}),typeof e==`string`?r=e:!i.cause&&e&&(a=!0,r=e.message,i.cause=e),!i.ruleId&&!i.source&&typeof n==`string`){let e=n.indexOf(`:`);e===-1?i.ruleId=n:(i.source=n.slice(0,e),i.ruleId=n.slice(e+1))}if(!i.place&&i.ancestors&&i.ancestors){let e=i.ancestors[i.ancestors.length-1];e&&(i.place=e.position)}let o=i.place&&`start`in i.place?i.place.start:i.place;this.ancestors=i.ancestors||void 0,this.cause=i.cause||void 0,this.column=o?o.column:void 0,this.fatal=void 0,this.file=``,this.message=r,this.line=o?o.line:void 0,this.name=Ic(i.place)||`1:1`,this.place=i.place||void 0,this.reason=this.message,this.ruleId=i.ruleId||void 0,this.source=i.source||void 0,this.stack=a&&i.cause&&typeof i.cause.stack==`string`?i.cause.stack:``,this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}};Bc.prototype.file=``,Bc.prototype.name=``,Bc.prototype.reason=``,Bc.prototype.message=``,Bc.prototype.stack=``,Bc.prototype.column=void 0,Bc.prototype.line=void 0,Bc.prototype.ancestors=void 0,Bc.prototype.cause=void 0,Bc.prototype.fatal=void 0,Bc.prototype.place=void 0,Bc.prototype.ruleId=void 0,Bc.prototype.source=void 0;var Vc=t(jc(),1),Hc={}.hasOwnProperty,Uc=new Map,Wc=/[A-Z]/g,Gc=new Set([`table`,`tbody`,`thead`,`tfoot`,`tr`]),Kc=new Set([`td`,`th`]);function qc(e,t){if(!t||t.Fragment===void 0)throw TypeError("Expected `Fragment` in options");let n=t.filePath||void 0,r;if(t.development){if(typeof t.jsxDEV!=`function`)throw TypeError("Expected `jsxDEV` in options when `development: true`");r=il(n,t.jsxDEV)}else{if(typeof t.jsx!=`function`)throw TypeError("Expected `jsx` in production options");if(typeof t.jsxs!=`function`)throw TypeError("Expected `jsxs` in production options");r=rl(n,t.jsx,t.jsxs)}let i={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:r,elementAttributeNameCase:t.elementAttributeNameCase||`react`,evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:n,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:t.passKeys!==!1,passNode:t.passNode||!1,schema:t.space===`svg`?Ec:Tc,stylePropertyNameCase:t.stylePropertyNameCase||`dom`,tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},a=Jc(i,e,void 0);return a&&typeof a!=`string`?a:i.create(e,i.Fragment,{children:a||void 0},void 0)}function Jc(e,t,n){if(t.type===`element`)return Yc(e,t,n);if(t.type===`mdxFlowExpression`||t.type===`mdxTextExpression`)return Xc(e,t);if(t.type===`mdxJsxFlowElement`||t.type===`mdxJsxTextElement`)return Qc(e,t,n);if(t.type===`mdxjsEsm`)return Zc(e,t);if(t.type===`root`)return $c(e,t,n);if(t.type===`text`)return el(e,t)}function Yc(e,t,n){let r=e.schema,i=r;t.tagName.toLowerCase()===`svg`&&r.space===`html`&&(i=Ec,e.schema=i),e.ancestors.push(t);let a=ul(e,t.tagName,!1),o=al(e,t),s=sl(e,t);return Gc.has(t.tagName)&&(s=s.filter(function(e){return typeof e!=`string`||!Ks(e)})),tl(e,o,a,t),nl(o,s),e.ancestors.pop(),e.schema=r,e.create(t,a,o,n)}function Xc(e,t){if(t.data&&t.data.estree&&e.evaluater){let n=t.data.estree.body[0];return n.type,e.evaluater.evaluateExpression(n.expression)}dl(e,t.position)}function Zc(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);dl(e,t.position)}function Qc(e,t,n){let r=e.schema,i=r;t.name===`svg`&&r.space===`html`&&(i=Ec,e.schema=i),e.ancestors.push(t);let a=t.name===null?e.Fragment:ul(e,t.name,!0),o=ol(e,t),s=sl(e,t);return tl(e,o,a,t),nl(o,s),e.ancestors.pop(),e.schema=r,e.create(t,a,o,n)}function $c(e,t,n){let r={};return nl(r,sl(e,t)),e.create(t,e.Fragment,r,n)}function el(e,t){return t.value}function tl(e,t,n,r){typeof n!=`string`&&n!==e.Fragment&&e.passNode&&(t.node=r)}function nl(e,t){if(t.length>0){let n=t.length>1?t:t[0];n&&(e.children=n)}}function rl(e,t,n){return r;function r(e,r,i,a){let o=Array.isArray(i.children)?n:t;return a?o(r,i,a):o(r,i)}}function il(e,t){return n;function n(n,r,i,a){let o=Array.isArray(i.children),s=Nc(n);return t(r,i,a,o,{columnNumber:s?s.column-1:void 0,fileName:e,lineNumber:s?s.line:void 0},void 0)}}function al(e,t){let n={},r,i;for(i in t.properties)if(i!==`children`&&Hc.call(t.properties,i)){let a=cl(e,i,t.properties[i]);if(a){let[i,o]=a;e.tableCellAlignToStyle&&i===`align`&&typeof o==`string`&&Kc.has(t.tagName)?r=o:n[i]=o}}if(r){let t=n.style||={};t[e.stylePropertyNameCase===`css`?`text-align`:`textAlign`]=r}return n}function ol(e,t){let n={};for(let r of t.attributes)if(r.type===`mdxJsxExpressionAttribute`)if(r.data&&r.data.estree&&e.evaluater){let t=r.data.estree.body[0];t.type;let i=t.expression;i.type;let a=i.properties[0];a.type,Object.assign(n,e.evaluater.evaluateExpression(a.argument))}else dl(e,t.position);else{let i=r.name,a;if(r.value&&typeof r.value==`object`)if(r.value.data&&r.value.data.estree&&e.evaluater){let t=r.value.data.estree.body[0];t.type,a=e.evaluater.evaluateExpression(t.expression)}else dl(e,t.position);else a=r.value===null||r.value;n[i]=a}return n}function sl(e,t){let n=[],r=-1,i=e.passKeys?new Map:Uc;for(;++r<t.children.length;){let a=t.children[r],o;if(e.passKeys){let e=a.type===`element`?a.tagName:a.type===`mdxJsxFlowElement`||a.type===`mdxJsxTextElement`?a.name:void 0;if(e){let t=i.get(e)||0;o=e+`-`+t,i.set(e,t+1)}}let s=Jc(e,a,o);s!==void 0&&n.push(s)}return n}function cl(e,t,n){let r=Sc(e.schema,t);if(!(n==null||typeof n==`number`&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?Bs(n):Dc(n)),r.property===`style`){let t=typeof n==`object`?n:ll(e,String(n));return e.stylePropertyNameCase===`css`&&(t=fl(t)),[`style`,t]}return[e.elementAttributeNameCase===`react`&&r.space?vc[r.property]||r.property:r.attribute,n]}}function ll(e,t){try{return(0,Vc.default)(t,{reactCompat:!0})}catch(t){if(e.ignoreInvalidStyle)return{};let n=t,r=new Bc("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:n,ruleId:`style`,source:`hast-util-to-jsx-runtime`});throw r.file=e.filePath||void 0,r.url=`https://github.com/syntax-tree/hast-util-to-jsx-runtime#cannot-parse-style-attribute`,r}}function ul(e,t,n){let r;if(!n)r={type:`Literal`,value:t};else if(t.includes(`.`)){let e=t.split(`.`),n=-1,i;for(;++n<e.length;){let t=Ws(e[n])?{type:`Identifier`,name:e[n]}:{type:`Literal`,value:e[n]};i=i?{type:`MemberExpression`,object:i,property:t,computed:!!(n&&t.type===`Literal`),optional:!1}:t}r=i}else r=Ws(t)&&!/^[a-z]/.test(t)?{type:`Identifier`,name:t}:{type:`Literal`,value:t};if(r.type===`Literal`){let t=r.value;return Hc.call(e.components,t)?e.components[t]:t}if(e.evaluater)return e.evaluater.evaluateExpression(r);dl(e)}function dl(e,t){let n=new Bc("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:t,ruleId:`mdx-estree`,source:`hast-util-to-jsx-runtime`});throw n.file=e.filePath||void 0,n.url=`https://github.com/syntax-tree/hast-util-to-jsx-runtime#cannot-handle-mdx-estrees-without-createevaluater`,n}function fl(e){let t={},n;for(n in e)Hc.call(e,n)&&(t[pl(n)]=e[n]);return t}function pl(e){let t=e.replace(Wc,ml);return t.slice(0,3)===`ms-`&&(t=`-`+t),t}function ml(e){return`-`+e.toLowerCase()}var hl={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`]},gl={};function _l(e,t){let n=t||gl;return vl(e,typeof n.includeImageAlt!=`boolean`||n.includeImageAlt,typeof n.includeHtml!=`boolean`||n.includeHtml)}function vl(e,t,n){if(bl(e)){if(`value`in e)return e.type===`html`&&!n?``:e.value;if(t&&`alt`in e&&e.alt)return e.alt;if(`children`in e)return yl(e.children,t,n)}return Array.isArray(e)?yl(e,t,n):``}function yl(e,t,n){let r=[],i=-1;for(;++i<e.length;)r[i]=vl(e[i],t,n);return r.join(``)}function bl(e){return!!(e&&typeof e==`object`)}var xl=document.createElement(`i`);function Sl(e){let t=`&`+e+`;`;xl.innerHTML=t;let n=xl.textContent;return n.charCodeAt(n.length-1)===59&&e!==`semi`?!1:n!==t&&n}function Cl(e,t,n,r){let i=e.length,a=0,o;if(t=t<0?-t>i?0:i+t:t>i?i:t,n=n>0?n:0,r.length<1e4)o=Array.from(r),o.unshift(t,n),e.splice(...o);else for(n&&e.splice(t,n);a<r.length;)o=r.slice(a,a+1e4),o.unshift(t,0),e.splice(...o),a+=1e4,t+=1e4}function wl(e,t){return e.length>0?(Cl(e,e.length,0,t),e):t}var Tl={}.hasOwnProperty;function El(e){let t={},n=-1;for(;++n<e.length;)Dl(t,e[n]);return t}function Dl(e,t){let n;for(n in t){let r=(Tl.call(e,n)?e[n]:void 0)||(e[n]={}),i=t[n],a;if(i)for(a in i){Tl.call(r,a)||(r[a]=[]);let e=i[a];Ol(r[a],Array.isArray(e)?e:e?[e]:[])}}}function Ol(e,t){let n=-1,r=[];for(;++n<t.length;)(t[n].add===`after`?e:r).push(t[n]);Cl(e,0,0,r)}function kl(e,t){let n=Number.parseInt(e,t);return n<9||n===11||n>13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)==65535||(n&65535)==65534||n>1114111?`�`:String.fromCodePoint(n)}function Al(e){return e.replace(/[\t\n\r ]+/g,` `).replace(/^ | $/g,``).toLowerCase().toUpperCase()}var jl=Vl(/[A-Za-z]/),Ml=Vl(/[\dA-Za-z]/),Nl=Vl(/[#-'*+\--9=?A-Z^-~]/);function Pl(e){return e!==null&&(e<32||e===127)}var Fl=Vl(/\d/),Il=Vl(/[\dA-Fa-f]/),Ll=Vl(/[!-/:-@[-`{-~]/);function Q(e){return e!==null&&e<-2}function Rl(e){return e!==null&&(e<0||e===32)}function $(e){return e===-2||e===-1||e===32}var zl=Vl(/\p{P}|\p{S}/u),Bl=Vl(/\s/);function Vl(e){return t;function t(t){return t!==null&&t>-1&&e.test(String.fromCharCode(t))}}function Hl(e){let t=[],n=-1,r=0,i=0;for(;++n<e.length;){let a=e.charCodeAt(n),o=``;if(a===37&&Ml(e.charCodeAt(n+1))&&Ml(e.charCodeAt(n+2)))i=2;else if(a<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(a))||(o=String.fromCharCode(a));else if(a>55295&&a<57344){let t=e.charCodeAt(n+1);a<56320&&t>56319&&t<57344?(o=String.fromCharCode(a,t),i=1):o=`�`}else o=String.fromCharCode(a);o&&=(t.push(e.slice(r,n),encodeURIComponent(o)),r=n+i+1,``),i&&=(n+=i,0)}return t.join(``)+e.slice(r)}function Ul(e,t,n,r){let i=r?r-1:1/0,a=0;return o;function o(r){return $(r)?(e.enter(n),s(r)):t(r)}function s(r){return $(r)&&a++<i?(e.consume(r),s):(e.exit(n),t(r))}}var Wl={tokenize:Gl};function Gl(e){let t=e.attempt(this.parser.constructs.contentInitial,r,i),n;return t;function r(n){if(n===null){e.consume(n);return}return e.enter(`lineEnding`),e.consume(n),e.exit(`lineEnding`),Ul(e,t,`linePrefix`)}function i(t){return e.enter(`paragraph`),a(t)}function a(t){let r=e.enter(`chunkText`,{contentType:`text`,previous:n});return n&&(n.next=r),n=r,o(t)}function o(t){if(t===null){e.exit(`chunkText`),e.exit(`paragraph`),e.consume(t);return}return Q(t)?(e.consume(t),e.exit(`chunkText`),a):(e.consume(t),o)}}var Kl={tokenize:Jl},ql={tokenize:Yl};function Jl(e){let t=this,n=[],r=0,i,a,o;return s;function s(i){if(r<n.length){let a=n[r];return t.containerState=a[1],e.attempt(a[0].continuation,c,l)(i)}return l(i)}function c(e){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,i&&v();let n=t.events.length,a=n,o;for(;a--;)if(t.events[a][0]===`exit`&&t.events[a][1].type===`chunkFlow`){o=t.events[a][1].end;break}_(r);let s=n;for(;s<t.events.length;)t.events[s][1].end={...o},s++;return Cl(t.events,a+1,0,t.events.slice(n)),t.events.length=s,l(e)}return s(e)}function l(a){if(r===n.length){if(!i)return f(a);if(i.currentConstruct&&i.currentConstruct.concrete)return m(a);t.interrupt=!!(i.currentConstruct&&!i._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(ql,u,d)(a)}function u(e){return i&&v(),_(r),f(e)}function d(e){return t.parser.lazy[t.now().line]=r!==n.length,o=t.now().offset,m(e)}function f(n){return t.containerState={},e.attempt(ql,p,m)(n)}function p(e){return r++,n.push([t.currentConstruct,t.containerState]),f(e)}function m(n){if(n===null){i&&v(),_(0),e.consume(n);return}return i||=t.parser.flow(t.now()),e.enter(`chunkFlow`,{_tokenizer:i,contentType:`flow`,previous:a}),h(n)}function h(n){if(n===null){g(e.exit(`chunkFlow`),!0),_(0),e.consume(n);return}return Q(n)?(e.consume(n),g(e.exit(`chunkFlow`)),r=0,t.interrupt=void 0,s):(e.consume(n),h)}function g(e,n){let s=t.sliceStream(e);if(n&&s.push(null),e.previous=a,a&&(a.next=e),a=e,i.defineSkip(e.start),i.write(s),t.parser.lazy[e.start.line]){let e=i.events.length;for(;e--;)if(i.events[e][1].start.offset<o&&(!i.events[e][1].end||i.events[e][1].end.offset>o))return;let n=t.events.length,a=n,s,c;for(;a--;)if(t.events[a][0]===`exit`&&t.events[a][1].type===`chunkFlow`){if(s){c=t.events[a][1].end;break}s=!0}for(_(r),e=n;e<t.events.length;)t.events[e][1].end={...c},e++;Cl(t.events,a+1,0,t.events.slice(n)),t.events.length=e}}function _(r){let i=n.length;for(;i-->r;){let r=n[i];t.containerState=r[1],r[0].exit.call(t,e)}n.length=r}function v(){i.write([null]),a=void 0,i=void 0,t.containerState._closeFlow=void 0}}function Yl(e,t,n){return Ul(e,e.attempt(this.parser.constructs.document,t,n),`linePrefix`,this.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)}function Xl(e){if(e===null||Rl(e)||Bl(e))return 1;if(zl(e))return 2}function Zl(e,t,n){let r=[],i=-1;for(;++i<e.length;){let a=e[i].resolveAll;a&&!r.includes(a)&&(t=a(t,n),r.push(a))}return t}var Ql={name:`attention`,resolveAll:$l,tokenize:eu};function $l(e,t){let n=-1,r,i,a,o,s,c,l,u;for(;++n<e.length;)if(e[n][0]===`enter`&&e[n][1].type===`attentionSequence`&&e[n][1]._close){for(r=n;r--;)if(e[r][0]===`exit`&&e[r][1].type===`attentionSequence`&&e[r][1]._open&&t.sliceSerialize(e[r][1]).charCodeAt(0)===t.sliceSerialize(e[n][1]).charCodeAt(0)){if((e[r][1]._close||e[n][1]._open)&&(e[n][1].end.offset-e[n][1].start.offset)%3&&!((e[r][1].end.offset-e[r][1].start.offset+e[n][1].end.offset-e[n][1].start.offset)%3))continue;c=e[r][1].end.offset-e[r][1].start.offset>1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;let d={...e[r][1].end},f={...e[n][1].start};tu(d,-c),tu(f,c),o={type:c>1?`strongSequence`:`emphasisSequence`,start:d,end:{...e[r][1].end}},s={type:c>1?`strongSequence`:`emphasisSequence`,start:{...e[n][1].start},end:f},a={type:c>1?`strongText`:`emphasisText`,start:{...e[r][1].end},end:{...e[n][1].start}},i={type:c>1?`strong`:`emphasis`,start:{...o.start},end:{...s.end}},e[r][1].end={...o.start},e[n][1].start={...s.end},l=[],e[r][1].end.offset-e[r][1].start.offset&&(l=wl(l,[[`enter`,e[r][1],t],[`exit`,e[r][1],t]])),l=wl(l,[[`enter`,i,t],[`enter`,o,t],[`exit`,o,t],[`enter`,a,t]]),l=wl(l,Zl(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),l=wl(l,[[`exit`,a,t],[`enter`,s,t],[`exit`,s,t],[`exit`,i,t]]),e[n][1].end.offset-e[n][1].start.offset?(u=2,l=wl(l,[[`enter`,e[n][1],t],[`exit`,e[n][1],t]])):u=0,Cl(e,r-1,n-r+3,l),n=r+l.length-u-2;break}}for(n=-1;++n<e.length;)e[n][1].type===`attentionSequence`&&(e[n][1].type=`data`);return e}function eu(e,t){let n=this.parser.constructs.attentionMarkers.null,r=this.previous,i=Xl(r),a;return o;function o(t){return a=t,e.enter(`attentionSequence`),s(t)}function s(o){if(o===a)return e.consume(o),s;let c=e.exit(`attentionSequence`),l=Xl(o),u=!l||l===2&&i||n.includes(o),d=!i||i===2&&l||n.includes(r);return c._open=!!(a===42?u:u&&(i||!d)),c._close=!!(a===42?d:d&&(l||!u)),t(o)}}function tu(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}var nu={name:`autolink`,tokenize:ru};function ru(e,t,n){let r=0;return i;function i(t){return e.enter(`autolink`),e.enter(`autolinkMarker`),e.consume(t),e.exit(`autolinkMarker`),e.enter(`autolinkProtocol`),a}function a(t){return jl(t)?(e.consume(t),o):t===64?n(t):l(t)}function o(e){return e===43||e===45||e===46||Ml(e)?(r=1,s(e)):l(e)}function s(t){return t===58?(e.consume(t),r=0,c):(t===43||t===45||t===46||Ml(t))&&r++<32?(e.consume(t),s):(r=0,l(t))}function c(r){return r===62?(e.exit(`autolinkProtocol`),e.enter(`autolinkMarker`),e.consume(r),e.exit(`autolinkMarker`),e.exit(`autolink`),t):r===null||r===32||r===60||Pl(r)?n(r):(e.consume(r),c)}function l(t){return t===64?(e.consume(t),u):Nl(t)?(e.consume(t),l):n(t)}function u(e){return Ml(e)?d(e):n(e)}function d(n){return n===46?(e.consume(n),r=0,u):n===62?(e.exit(`autolinkProtocol`).type=`autolinkEmail`,e.enter(`autolinkMarker`),e.consume(n),e.exit(`autolinkMarker`),e.exit(`autolink`),t):f(n)}function f(t){if((t===45||Ml(t))&&r++<63){let n=t===45?f:d;return e.consume(t),n}return n(t)}}var iu={partial:!0,tokenize:au};function au(e,t,n){return r;function r(t){return $(t)?Ul(e,i,`linePrefix`)(t):i(t)}function i(e){return e===null||Q(e)?t(e):n(e)}}var ou={continuation:{tokenize:cu},exit:lu,name:`blockQuote`,tokenize:su};function su(e,t,n){let r=this;return i;function i(t){if(t===62){let n=r.containerState;return n.open||=(e.enter(`blockQuote`,{_container:!0}),!0),e.enter(`blockQuotePrefix`),e.enter(`blockQuoteMarker`),e.consume(t),e.exit(`blockQuoteMarker`),a}return n(t)}function a(n){return $(n)?(e.enter(`blockQuotePrefixWhitespace`),e.consume(n),e.exit(`blockQuotePrefixWhitespace`),e.exit(`blockQuotePrefix`),t):(e.exit(`blockQuotePrefix`),t(n))}}function cu(e,t,n){let r=this;return i;function i(t){return $(t)?Ul(e,a,`linePrefix`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)(t):a(t)}function a(r){return e.attempt(ou,t,n)(r)}}function lu(e){e.exit(`blockQuote`)}var uu={name:`characterEscape`,tokenize:du};function du(e,t,n){return r;function r(t){return e.enter(`characterEscape`),e.enter(`escapeMarker`),e.consume(t),e.exit(`escapeMarker`),i}function i(r){return Ll(r)?(e.enter(`characterEscapeValue`),e.consume(r),e.exit(`characterEscapeValue`),e.exit(`characterEscape`),t):n(r)}}var fu={name:`characterReference`,tokenize:pu};function pu(e,t,n){let r=this,i=0,a,o;return s;function s(t){return e.enter(`characterReference`),e.enter(`characterReferenceMarker`),e.consume(t),e.exit(`characterReferenceMarker`),c}function c(t){return t===35?(e.enter(`characterReferenceMarkerNumeric`),e.consume(t),e.exit(`characterReferenceMarkerNumeric`),l):(e.enter(`characterReferenceValue`),a=31,o=Ml,u(t))}function l(t){return t===88||t===120?(e.enter(`characterReferenceMarkerHexadecimal`),e.consume(t),e.exit(`characterReferenceMarkerHexadecimal`),e.enter(`characterReferenceValue`),a=6,o=Il,u):(e.enter(`characterReferenceValue`),a=7,o=Fl,u(t))}function u(s){if(s===59&&i){let i=e.exit(`characterReferenceValue`);return o===Ml&&!Sl(r.sliceSerialize(i))?n(s):(e.enter(`characterReferenceMarker`),e.consume(s),e.exit(`characterReferenceMarker`),e.exit(`characterReference`),t)}return o(s)&&i++<a?(e.consume(s),u):n(s)}}var mu={partial:!0,tokenize:_u},hu={concrete:!0,name:`codeFenced`,tokenize:gu};function gu(e,t,n){let r=this,i={partial:!0,tokenize:x},a=0,o=0,s;return c;function c(e){return l(e)}function l(t){let n=r.events[r.events.length-1];return a=n&&n[1].type===`linePrefix`?n[2].sliceSerialize(n[1],!0).length:0,s=t,e.enter(`codeFenced`),e.enter(`codeFencedFence`),e.enter(`codeFencedFenceSequence`),u(t)}function u(t){return t===s?(o++,e.consume(t),u):o<3?n(t):(e.exit(`codeFencedFenceSequence`),$(t)?Ul(e,d,`whitespace`)(t):d(t))}function d(n){return n===null||Q(n)?(e.exit(`codeFencedFence`),r.interrupt?t(n):e.check(mu,h,b)(n)):(e.enter(`codeFencedFenceInfo`),e.enter(`chunkString`,{contentType:`string`}),f(n))}function f(t){return t===null||Q(t)?(e.exit(`chunkString`),e.exit(`codeFencedFenceInfo`),d(t)):$(t)?(e.exit(`chunkString`),e.exit(`codeFencedFenceInfo`),Ul(e,p,`whitespace`)(t)):t===96&&t===s?n(t):(e.consume(t),f)}function p(t){return t===null||Q(t)?d(t):(e.enter(`codeFencedFenceMeta`),e.enter(`chunkString`,{contentType:`string`}),m(t))}function m(t){return t===null||Q(t)?(e.exit(`chunkString`),e.exit(`codeFencedFenceMeta`),d(t)):t===96&&t===s?n(t):(e.consume(t),m)}function h(t){return e.attempt(i,b,g)(t)}function g(t){return e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),_}function _(t){return a>0&&$(t)?Ul(e,v,`linePrefix`,a+1)(t):v(t)}function v(t){return t===null||Q(t)?e.check(mu,h,b)(t):(e.enter(`codeFlowValue`),y(t))}function y(t){return t===null||Q(t)?(e.exit(`codeFlowValue`),v(t)):(e.consume(t),y)}function b(n){return e.exit(`codeFenced`),t(n)}function x(e,t,n){let i=0;return a;function a(t){return e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),c}function c(t){return e.enter(`codeFencedFence`),$(t)?Ul(e,l,`linePrefix`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)(t):l(t)}function l(t){return t===s?(e.enter(`codeFencedFenceSequence`),u(t)):n(t)}function u(t){return t===s?(i++,e.consume(t),u):i>=o?(e.exit(`codeFencedFenceSequence`),$(t)?Ul(e,d,`whitespace`)(t):d(t)):n(t)}function d(r){return r===null||Q(r)?(e.exit(`codeFencedFence`),t(r)):n(r)}}}function _u(e,t,n){let r=this;return i;function i(t){return t===null?n(t):(e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),a)}function a(e){return r.parser.lazy[r.now().line]?n(e):t(e)}}var vu={name:`codeIndented`,tokenize:bu},yu={partial:!0,tokenize:xu};function bu(e,t,n){let r=this;return i;function i(t){return e.enter(`codeIndented`),Ul(e,a,`linePrefix`,5)(t)}function a(e){let t=r.events[r.events.length-1];return t&&t[1].type===`linePrefix`&&t[2].sliceSerialize(t[1],!0).length>=4?o(e):n(e)}function o(t){return t===null?c(t):Q(t)?e.attempt(yu,o,c)(t):(e.enter(`codeFlowValue`),s(t))}function s(t){return t===null||Q(t)?(e.exit(`codeFlowValue`),o(t)):(e.consume(t),s)}function c(n){return e.exit(`codeIndented`),t(n)}}function xu(e,t,n){let r=this;return i;function i(t){return r.parser.lazy[r.now().line]?n(t):Q(t)?(e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),i):Ul(e,a,`linePrefix`,5)(t)}function a(e){let a=r.events[r.events.length-1];return a&&a[1].type===`linePrefix`&&a[2].sliceSerialize(a[1],!0).length>=4?t(e):Q(e)?i(e):n(e)}}var Su={name:`codeText`,previous:wu,resolve:Cu,tokenize:Tu};function Cu(e){let t=e.length-4,n=3,r,i;if((e[n][1].type===`lineEnding`||e[n][1].type===`space`)&&(e[t][1].type===`lineEnding`||e[t][1].type===`space`)){for(r=n;++r<t;)if(e[r][1].type===`codeTextData`){e[n][1].type=`codeTextPadding`,e[t][1].type=`codeTextPadding`,n+=2,t-=2;break}}for(r=n-1,t++;++r<=t;)i===void 0?r!==t&&e[r][1].type!==`lineEnding`&&(i=r):(r===t||e[r][1].type===`lineEnding`)&&(e[i][1].type=`codeTextData`,r!==i+2&&(e[i][1].end=e[r-1][1].end,e.splice(i+2,r-i-2),t-=r-i-2,r=i+2),i=void 0);return e}function wu(e){return e!==96||this.events[this.events.length-1][1].type===`characterEscape`}function Tu(e,t,n){let r=0,i,a;return o;function o(t){return e.enter(`codeText`),e.enter(`codeTextSequence`),s(t)}function s(t){return t===96?(e.consume(t),r++,s):(e.exit(`codeTextSequence`),c(t))}function c(t){return t===null?n(t):t===32?(e.enter(`space`),e.consume(t),e.exit(`space`),c):t===96?(a=e.enter(`codeTextSequence`),i=0,u(t)):Q(t)?(e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),c):(e.enter(`codeTextData`),l(t))}function l(t){return t===null||t===32||t===96||Q(t)?(e.exit(`codeTextData`),c(t)):(e.consume(t),l)}function u(n){return n===96?(e.consume(n),i++,u):i===r?(e.exit(`codeTextSequence`),e.exit(`codeText`),t(n)):(a.type=`codeTextData`,l(n))}}var Eu=class{constructor(e){this.left=e?[...e]:[],this.right=[]}get(e){if(e<0||e>=this.left.length+this.right.length)throw RangeError("Cannot access index `"+e+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return e<this.left.length?this.left[e]:this.right[this.right.length-e+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(e,t){let n=t??1/0;return n<this.left.length?this.left.slice(e,n):e>this.left.length?this.right.slice(this.right.length-n+this.left.length,this.right.length-e+this.left.length).reverse():this.left.slice(e).concat(this.right.slice(this.right.length-n+this.left.length).reverse())}splice(e,t,n){let r=t||0;this.setCursor(Math.trunc(e));let i=this.right.splice(this.right.length-r,1/0);return n&&Du(this.left,n),i.reverse()}pop(){return this.setCursor(1/0),this.left.pop()}push(e){this.setCursor(1/0),this.left.push(e)}pushMany(e){this.setCursor(1/0),Du(this.left,e)}unshift(e){this.setCursor(0),this.right.push(e)}unshiftMany(e){this.setCursor(0),Du(this.right,e.reverse())}setCursor(e){if(!(e===this.left.length||e>this.left.length&&this.right.length===0||e<0&&this.left.length===0))if(e<this.left.length){let t=this.left.splice(e,1/0);Du(this.right,t.reverse())}else{let t=this.right.splice(this.left.length+this.right.length-e,1/0);Du(this.left,t.reverse())}}};function Du(e,t){let n=0;if(t.length<1e4)e.push(...t);else for(;n<t.length;)e.push(...t.slice(n,n+1e4)),n+=1e4}function Ou(e){let t={},n=-1,r,i,a,o,s,c,l,u=new Eu(e);for(;++n<u.length;){for(;n in t;)n=t[n];if(r=u.get(n),n&&r[1].type===`chunkFlow`&&u.get(n-1)[1].type===`listItemPrefix`&&(c=r[1]._tokenizer.events,a=0,a<c.length&&c[a][1].type===`lineEndingBlank`&&(a+=2),a<c.length&&c[a][1].type===`content`))for(;++a<c.length&&c[a][1].type!==`content`;)c[a][1].type===`chunkText`&&(c[a][1]._isInFirstContentOfListItem=!0,a++);if(r[0]===`enter`)r[1].contentType&&(Object.assign(t,ku(u,n)),n=t[n],l=!0);else if(r[1]._container){for(a=n,i=void 0;a--;)if(o=u.get(a),o[1].type===`lineEnding`||o[1].type===`lineEndingBlank`)o[0]===`enter`&&(i&&(u.get(i)[1].type=`lineEndingBlank`),o[1].type=`lineEnding`,i=a);else if(!(o[1].type===`linePrefix`||o[1].type===`listItemIndent`))break;i&&(r[1].end={...u.get(i)[1].start},s=u.slice(i,n),s.unshift(r),u.splice(i,n-i+1,s))}}return Cl(e,0,1/0,u.slice(0)),!l}function ku(e,t){let n=e.get(t)[1],r=e.get(t)[2],i=t-1,a=[],o=n._tokenizer;o||(o=r.parser[n.contentType](n.start),n._contentTypeTextTrailing&&(o._contentTypeTextTrailing=!0));let s=o.events,c=[],l={},u,d,f=-1,p=n,m=0,h=0,g=[h];for(;p;){for(;e.get(++i)[1]!==p;);a.push(i),p._tokenizer||(u=r.sliceStream(p),p.next||u.push(null),d&&o.defineSkip(p.start),p._isInFirstContentOfListItem&&(o._gfmTasklistFirstContentOfListItem=!0),o.write(u),p._isInFirstContentOfListItem&&(o._gfmTasklistFirstContentOfListItem=void 0)),d=p,p=p.next}for(p=n;++f<s.length;)s[f][0]===`exit`&&s[f-1][0]===`enter`&&s[f][1].type===s[f-1][1].type&&s[f][1].start.line!==s[f][1].end.line&&(h=f+1,g.push(h),p._tokenizer=void 0,p.previous=void 0,p=p.next);for(o.events=[],p?(p._tokenizer=void 0,p.previous=void 0):g.pop(),f=g.length;f--;){let t=s.slice(g[f],g[f+1]),n=a.pop();c.push([n,n+t.length-1]),e.splice(n,2,t)}for(c.reverse(),f=-1;++f<c.length;)l[m+c[f][0]]=m+c[f][1],m+=c[f][1]-c[f][0]-1;return l}var Au={resolve:Mu,tokenize:Nu},ju={partial:!0,tokenize:Pu};function Mu(e){return Ou(e),e}function Nu(e,t){let n;return r;function r(t){return e.enter(`content`),n=e.enter(`chunkContent`,{contentType:`content`}),i(t)}function i(t){return t===null?a(t):Q(t)?e.check(ju,o,a)(t):(e.consume(t),i)}function a(n){return e.exit(`chunkContent`),e.exit(`content`),t(n)}function o(t){return e.consume(t),e.exit(`chunkContent`),n.next=e.enter(`chunkContent`,{contentType:`content`,previous:n}),n=n.next,i}}function Pu(e,t,n){let r=this;return i;function i(t){return e.exit(`chunkContent`),e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),Ul(e,a,`linePrefix`)}function a(i){if(i===null||Q(i))return n(i);let a=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes(`codeIndented`)&&a&&a[1].type===`linePrefix`&&a[2].sliceSerialize(a[1],!0).length>=4?t(i):e.interrupt(r.parser.constructs.flow,n,t)(i)}}function Fu(e,t,n,r,i,a,o,s,c){let l=c||1/0,u=0;return d;function d(t){return t===60?(e.enter(r),e.enter(i),e.enter(a),e.consume(t),e.exit(a),f):t===null||t===32||t===41||Pl(t)?n(t):(e.enter(r),e.enter(o),e.enter(s),e.enter(`chunkString`,{contentType:`string`}),h(t))}function f(n){return n===62?(e.enter(a),e.consume(n),e.exit(a),e.exit(i),e.exit(r),t):(e.enter(s),e.enter(`chunkString`,{contentType:`string`}),p(n))}function p(t){return t===62?(e.exit(`chunkString`),e.exit(s),f(t)):t===null||t===60||Q(t)?n(t):(e.consume(t),t===92?m:p)}function m(t){return t===60||t===62||t===92?(e.consume(t),p):p(t)}function h(i){return!u&&(i===null||i===41||Rl(i))?(e.exit(`chunkString`),e.exit(s),e.exit(o),e.exit(r),t(i)):u<l&&i===40?(e.consume(i),u++,h):i===41?(e.consume(i),u--,h):i===null||i===32||i===40||Pl(i)?n(i):(e.consume(i),i===92?g:h)}function g(t){return t===40||t===41||t===92?(e.consume(t),h):h(t)}}function Iu(e,t,n,r,i,a){let o=this,s=0,c;return l;function l(t){return e.enter(r),e.enter(i),e.consume(t),e.exit(i),e.enter(a),u}function u(l){return s>999||l===null||l===91||l===93&&!c||l===94&&!s&&`_hiddenFootnoteSupport`in o.parser.constructs?n(l):l===93?(e.exit(a),e.enter(i),e.consume(l),e.exit(i),e.exit(r),t):Q(l)?(e.enter(`lineEnding`),e.consume(l),e.exit(`lineEnding`),u):(e.enter(`chunkString`,{contentType:`string`}),d(l))}function d(t){return t===null||t===91||t===93||Q(t)||s++>999?(e.exit(`chunkString`),u(t)):(e.consume(t),c||=!$(t),t===92?f:d)}function f(t){return t===91||t===92||t===93?(e.consume(t),s++,d):d(t)}}function Lu(e,t,n,r,i,a){let o;return s;function s(t){return t===34||t===39||t===40?(e.enter(r),e.enter(i),e.consume(t),e.exit(i),o=t===40?41:t,c):n(t)}function c(n){return n===o?(e.enter(i),e.consume(n),e.exit(i),e.exit(r),t):(e.enter(a),l(n))}function l(t){return t===o?(e.exit(a),c(o)):t===null?n(t):Q(t)?(e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),Ul(e,l,`linePrefix`)):(e.enter(`chunkString`,{contentType:`string`}),u(t))}function u(t){return t===o||t===null||Q(t)?(e.exit(`chunkString`),l(t)):(e.consume(t),t===92?d:u)}function d(t){return t===o||t===92?(e.consume(t),u):u(t)}}function Ru(e,t){let n;return r;function r(i){return Q(i)?(e.enter(`lineEnding`),e.consume(i),e.exit(`lineEnding`),n=!0,r):$(i)?Ul(e,r,n?`linePrefix`:`lineSuffix`)(i):t(i)}}var zu={name:`definition`,tokenize:Vu},Bu={partial:!0,tokenize:Hu};function Vu(e,t,n){let r=this,i;return a;function a(t){return e.enter(`definition`),o(t)}function o(t){return Iu.call(r,e,s,n,`definitionLabel`,`definitionLabelMarker`,`definitionLabelString`)(t)}function s(t){return i=Al(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),t===58?(e.enter(`definitionMarker`),e.consume(t),e.exit(`definitionMarker`),c):n(t)}function c(t){return Rl(t)?Ru(e,l)(t):l(t)}function l(t){return Fu(e,u,n,`definitionDestination`,`definitionDestinationLiteral`,`definitionDestinationLiteralMarker`,`definitionDestinationRaw`,`definitionDestinationString`)(t)}function u(t){return e.attempt(Bu,d,d)(t)}function d(t){return $(t)?Ul(e,f,`whitespace`)(t):f(t)}function f(a){return a===null||Q(a)?(e.exit(`definition`),r.parser.defined.push(i),t(a)):n(a)}}function Hu(e,t,n){return r;function r(t){return Rl(t)?Ru(e,i)(t):n(t)}function i(t){return Lu(e,a,n,`definitionTitle`,`definitionTitleMarker`,`definitionTitleString`)(t)}function a(t){return $(t)?Ul(e,o,`whitespace`)(t):o(t)}function o(e){return e===null||Q(e)?t(e):n(e)}}var Uu={name:`hardBreakEscape`,tokenize:Wu};function Wu(e,t,n){return r;function r(t){return e.enter(`hardBreakEscape`),e.consume(t),i}function i(r){return Q(r)?(e.exit(`hardBreakEscape`),t(r)):n(r)}}var Gu={name:`headingAtx`,resolve:Ku,tokenize:qu};function Ku(e,t){let n=e.length-2,r=3,i,a;return e[r][1].type===`whitespace`&&(r+=2),n-2>r&&e[n][1].type===`whitespace`&&(n-=2),e[n][1].type===`atxHeadingSequence`&&(r===n-1||n-4>r&&e[n-2][1].type===`whitespace`)&&(n-=r+1===n?2:4),n>r&&(i={type:`atxHeadingText`,start:e[r][1].start,end:e[n][1].end},a={type:`chunkText`,start:e[r][1].start,end:e[n][1].end,contentType:`text`},Cl(e,r,n-r+1,[[`enter`,i,t],[`enter`,a,t],[`exit`,a,t],[`exit`,i,t]])),e}function qu(e,t,n){let r=0;return i;function i(t){return e.enter(`atxHeading`),a(t)}function a(t){return e.enter(`atxHeadingSequence`),o(t)}function o(t){return t===35&&r++<6?(e.consume(t),o):t===null||Rl(t)?(e.exit(`atxHeadingSequence`),s(t)):n(t)}function s(n){return n===35?(e.enter(`atxHeadingSequence`),c(n)):n===null||Q(n)?(e.exit(`atxHeading`),t(n)):$(n)?Ul(e,s,`whitespace`)(n):(e.enter(`atxHeadingText`),l(n))}function c(t){return t===35?(e.consume(t),c):(e.exit(`atxHeadingSequence`),s(t))}function l(t){return t===null||t===35||Rl(t)?(e.exit(`atxHeadingText`),s(t)):(e.consume(t),l)}}var Ju=`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`.split(`.`),Yu=[`pre`,`script`,`style`,`textarea`],Xu={concrete:!0,name:`htmlFlow`,resolveTo:$u,tokenize:ed},Zu={partial:!0,tokenize:nd},Qu={partial:!0,tokenize:td};function $u(e){let t=e.length;for(;t--&&!(e[t][0]===`enter`&&e[t][1].type===`htmlFlow`););return t>1&&e[t-2][1].type===`linePrefix`&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function ed(e,t,n){let r=this,i,a,o,s,c;return l;function l(e){return u(e)}function u(t){return e.enter(`htmlFlow`),e.enter(`htmlFlowData`),e.consume(t),d}function d(s){return s===33?(e.consume(s),f):s===47?(e.consume(s),a=!0,h):s===63?(e.consume(s),i=3,r.interrupt?t:I):jl(s)?(e.consume(s),o=String.fromCharCode(s),g):n(s)}function f(a){return a===45?(e.consume(a),i=2,p):a===91?(e.consume(a),i=5,s=0,m):jl(a)?(e.consume(a),i=4,r.interrupt?t:I):n(a)}function p(i){return i===45?(e.consume(i),r.interrupt?t:I):n(i)}function m(i){return i===`CDATA[`.charCodeAt(s++)?(e.consume(i),s===6?r.interrupt?t:O:m):n(i)}function h(t){return jl(t)?(e.consume(t),o=String.fromCharCode(t),g):n(t)}function g(s){if(s===null||s===47||s===62||Rl(s)){let c=s===47,l=o.toLowerCase();return!c&&!a&&Yu.includes(l)?(i=1,r.interrupt?t(s):O(s)):Ju.includes(o.toLowerCase())?(i=6,c?(e.consume(s),_):r.interrupt?t(s):O(s)):(i=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(s):a?v(s):y(s))}return s===45||Ml(s)?(e.consume(s),o+=String.fromCharCode(s),g):n(s)}function _(i){return i===62?(e.consume(i),r.interrupt?t:O):n(i)}function v(t){return $(t)?(e.consume(t),v):E(t)}function y(t){return t===47?(e.consume(t),E):t===58||t===95||jl(t)?(e.consume(t),b):$(t)?(e.consume(t),y):E(t)}function b(t){return t===45||t===46||t===58||t===95||Ml(t)?(e.consume(t),b):x(t)}function x(t){return t===61?(e.consume(t),S):$(t)?(e.consume(t),x):y(t)}function S(t){return t===null||t===60||t===61||t===62||t===96?n(t):t===34||t===39?(e.consume(t),c=t,C):$(t)?(e.consume(t),S):w(t)}function C(t){return t===c?(e.consume(t),c=null,T):t===null||Q(t)?n(t):(e.consume(t),C)}function w(t){return t===null||t===34||t===39||t===47||t===60||t===61||t===62||t===96||Rl(t)?x(t):(e.consume(t),w)}function T(e){return e===47||e===62||$(e)?y(e):n(e)}function E(t){return t===62?(e.consume(t),D):n(t)}function D(t){return t===null||Q(t)?O(t):$(t)?(e.consume(t),D):n(t)}function O(t){return t===45&&i===2?(e.consume(t),M):t===60&&i===1?(e.consume(t),N):t===62&&i===4?(e.consume(t),L):t===63&&i===3?(e.consume(t),I):t===93&&i===5?(e.consume(t),F):Q(t)&&(i===6||i===7)?(e.exit(`htmlFlowData`),e.check(Zu,ee,k)(t)):t===null||Q(t)?(e.exit(`htmlFlowData`),k(t)):(e.consume(t),O)}function k(t){return e.check(Qu,A,ee)(t)}function A(t){return e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),j}function j(t){return t===null||Q(t)?k(t):(e.enter(`htmlFlowData`),O(t))}function M(t){return t===45?(e.consume(t),I):O(t)}function N(t){return t===47?(e.consume(t),o=``,P):O(t)}function P(t){if(t===62){let n=o.toLowerCase();return Yu.includes(n)?(e.consume(t),L):O(t)}return jl(t)&&o.length<8?(e.consume(t),o+=String.fromCharCode(t),P):O(t)}function F(t){return t===93?(e.consume(t),I):O(t)}function I(t){return t===62?(e.consume(t),L):t===45&&i===2?(e.consume(t),I):O(t)}function L(t){return t===null||Q(t)?(e.exit(`htmlFlowData`),ee(t)):(e.consume(t),L)}function ee(n){return e.exit(`htmlFlow`),t(n)}}function td(e,t,n){let r=this;return i;function i(t){return Q(t)?(e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),a):n(t)}function a(e){return r.parser.lazy[r.now().line]?n(e):t(e)}}function nd(e,t,n){return r;function r(r){return e.enter(`lineEnding`),e.consume(r),e.exit(`lineEnding`),e.attempt(iu,t,n)}}var rd={name:`htmlText`,tokenize:id};function id(e,t,n){let r=this,i,a,o;return s;function s(t){return e.enter(`htmlText`),e.enter(`htmlTextData`),e.consume(t),c}function c(t){return t===33?(e.consume(t),l):t===47?(e.consume(t),x):t===63?(e.consume(t),y):jl(t)?(e.consume(t),w):n(t)}function l(t){return t===45?(e.consume(t),u):t===91?(e.consume(t),a=0,m):jl(t)?(e.consume(t),v):n(t)}function u(t){return t===45?(e.consume(t),p):n(t)}function d(t){return t===null?n(t):t===45?(e.consume(t),f):Q(t)?(o=d,N(t)):(e.consume(t),d)}function f(t){return t===45?(e.consume(t),p):d(t)}function p(e){return e===62?M(e):e===45?f(e):d(e)}function m(t){return t===`CDATA[`.charCodeAt(a++)?(e.consume(t),a===6?h:m):n(t)}function h(t){return t===null?n(t):t===93?(e.consume(t),g):Q(t)?(o=h,N(t)):(e.consume(t),h)}function g(t){return t===93?(e.consume(t),_):h(t)}function _(t){return t===62?M(t):t===93?(e.consume(t),_):h(t)}function v(t){return t===null||t===62?M(t):Q(t)?(o=v,N(t)):(e.consume(t),v)}function y(t){return t===null?n(t):t===63?(e.consume(t),b):Q(t)?(o=y,N(t)):(e.consume(t),y)}function b(e){return e===62?M(e):y(e)}function x(t){return jl(t)?(e.consume(t),S):n(t)}function S(t){return t===45||Ml(t)?(e.consume(t),S):C(t)}function C(t){return Q(t)?(o=C,N(t)):$(t)?(e.consume(t),C):M(t)}function w(t){return t===45||Ml(t)?(e.consume(t),w):t===47||t===62||Rl(t)?T(t):n(t)}function T(t){return t===47?(e.consume(t),M):t===58||t===95||jl(t)?(e.consume(t),E):Q(t)?(o=T,N(t)):$(t)?(e.consume(t),T):M(t)}function E(t){return t===45||t===46||t===58||t===95||Ml(t)?(e.consume(t),E):D(t)}function D(t){return t===61?(e.consume(t),O):Q(t)?(o=D,N(t)):$(t)?(e.consume(t),D):T(t)}function O(t){return t===null||t===60||t===61||t===62||t===96?n(t):t===34||t===39?(e.consume(t),i=t,k):Q(t)?(o=O,N(t)):$(t)?(e.consume(t),O):(e.consume(t),A)}function k(t){return t===i?(e.consume(t),i=void 0,j):t===null?n(t):Q(t)?(o=k,N(t)):(e.consume(t),k)}function A(t){return t===null||t===34||t===39||t===60||t===61||t===96?n(t):t===47||t===62||Rl(t)?T(t):(e.consume(t),A)}function j(e){return e===47||e===62||Rl(e)?T(e):n(e)}function M(r){return r===62?(e.consume(r),e.exit(`htmlTextData`),e.exit(`htmlText`),t):n(r)}function N(t){return e.exit(`htmlTextData`),e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),P}function P(t){return $(t)?Ul(e,F,`linePrefix`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)(t):F(t)}function F(t){return e.enter(`htmlTextData`),o(t)}}var ad={name:`labelEnd`,resolveAll:ld,resolveTo:ud,tokenize:dd},od={tokenize:fd},sd={tokenize:pd},cd={tokenize:md};function ld(e){let t=-1,n=[];for(;++t<e.length;){let r=e[t][1];if(n.push(e[t]),r.type===`labelImage`||r.type===`labelLink`||r.type===`labelEnd`){let e=r.type===`labelImage`?4:2;r.type=`data`,t+=e}}return e.length!==n.length&&Cl(e,0,e.length,n),e}function ud(e,t){let n=e.length,r=0,i,a,o,s;for(;n--;)if(i=e[n][1],a){if(i.type===`link`||i.type===`labelLink`&&i._inactive)break;e[n][0]===`enter`&&i.type===`labelLink`&&(i._inactive=!0)}else if(o){if(e[n][0]===`enter`&&(i.type===`labelImage`||i.type===`labelLink`)&&!i._balanced&&(a=n,i.type!==`labelLink`)){r=2;break}}else i.type===`labelEnd`&&(o=n);let c={type:e[a][1].type===`labelLink`?`link`:`image`,start:{...e[a][1].start},end:{...e[e.length-1][1].end}},l={type:`label`,start:{...e[a][1].start},end:{...e[o][1].end}},u={type:`labelText`,start:{...e[a+r+2][1].end},end:{...e[o-2][1].start}};return s=[[`enter`,c,t],[`enter`,l,t]],s=wl(s,e.slice(a+1,a+r+3)),s=wl(s,[[`enter`,u,t]]),s=wl(s,Zl(t.parser.constructs.insideSpan.null,e.slice(a+r+4,o-3),t)),s=wl(s,[[`exit`,u,t],e[o-2],e[o-1],[`exit`,l,t]]),s=wl(s,e.slice(o+1)),s=wl(s,[[`exit`,c,t]]),Cl(e,a,e.length,s),e}function dd(e,t,n){let r=this,i=r.events.length,a,o;for(;i--;)if((r.events[i][1].type===`labelImage`||r.events[i][1].type===`labelLink`)&&!r.events[i][1]._balanced){a=r.events[i][1];break}return s;function s(t){return a?a._inactive?d(t):(o=r.parser.defined.includes(Al(r.sliceSerialize({start:a.end,end:r.now()}))),e.enter(`labelEnd`),e.enter(`labelMarker`),e.consume(t),e.exit(`labelMarker`),e.exit(`labelEnd`),c):n(t)}function c(t){return t===40?e.attempt(od,u,o?u:d)(t):t===91?e.attempt(sd,u,o?l:d)(t):o?u(t):d(t)}function l(t){return e.attempt(cd,u,d)(t)}function u(e){return t(e)}function d(e){return a._balanced=!0,n(e)}}function fd(e,t,n){return r;function r(t){return e.enter(`resource`),e.enter(`resourceMarker`),e.consume(t),e.exit(`resourceMarker`),i}function i(t){return Rl(t)?Ru(e,a)(t):a(t)}function a(t){return t===41?u(t):Fu(e,o,s,`resourceDestination`,`resourceDestinationLiteral`,`resourceDestinationLiteralMarker`,`resourceDestinationRaw`,`resourceDestinationString`,32)(t)}function o(t){return Rl(t)?Ru(e,c)(t):u(t)}function s(e){return n(e)}function c(t){return t===34||t===39||t===40?Lu(e,l,n,`resourceTitle`,`resourceTitleMarker`,`resourceTitleString`)(t):u(t)}function l(t){return Rl(t)?Ru(e,u)(t):u(t)}function u(r){return r===41?(e.enter(`resourceMarker`),e.consume(r),e.exit(`resourceMarker`),e.exit(`resource`),t):n(r)}}function pd(e,t,n){let r=this;return i;function i(t){return Iu.call(r,e,a,o,`reference`,`referenceMarker`,`referenceString`)(t)}function a(e){return r.parser.defined.includes(Al(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(e):n(e)}function o(e){return n(e)}}function md(e,t,n){return r;function r(t){return e.enter(`reference`),e.enter(`referenceMarker`),e.consume(t),e.exit(`referenceMarker`),i}function i(r){return r===93?(e.enter(`referenceMarker`),e.consume(r),e.exit(`referenceMarker`),e.exit(`reference`),t):n(r)}}var hd={name:`labelStartImage`,resolveAll:ad.resolveAll,tokenize:gd};function gd(e,t,n){let r=this;return i;function i(t){return e.enter(`labelImage`),e.enter(`labelImageMarker`),e.consume(t),e.exit(`labelImageMarker`),a}function a(t){return t===91?(e.enter(`labelMarker`),e.consume(t),e.exit(`labelMarker`),e.exit(`labelImage`),o):n(t)}function o(e){return e===94&&`_hiddenFootnoteSupport`in r.parser.constructs?n(e):t(e)}}var _d={name:`labelStartLink`,resolveAll:ad.resolveAll,tokenize:vd};function vd(e,t,n){let r=this;return i;function i(t){return e.enter(`labelLink`),e.enter(`labelMarker`),e.consume(t),e.exit(`labelMarker`),e.exit(`labelLink`),a}function a(e){return e===94&&`_hiddenFootnoteSupport`in r.parser.constructs?n(e):t(e)}}var yd={name:`lineEnding`,tokenize:bd};function bd(e,t){return n;function n(n){return e.enter(`lineEnding`),e.consume(n),e.exit(`lineEnding`),Ul(e,t,`linePrefix`)}}var xd={name:`thematicBreak`,tokenize:Sd};function Sd(e,t,n){let r=0,i;return a;function a(t){return e.enter(`thematicBreak`),o(t)}function o(e){return i=e,s(e)}function s(a){return a===i?(e.enter(`thematicBreakSequence`),c(a)):r>=3&&(a===null||Q(a))?(e.exit(`thematicBreak`),t(a)):n(a)}function c(t){return t===i?(e.consume(t),r++,c):(e.exit(`thematicBreakSequence`),$(t)?Ul(e,s,`whitespace`)(t):s(t))}}var Cd={continuation:{tokenize:Dd},exit:kd,name:`list`,tokenize:Ed},wd={partial:!0,tokenize:Ad},Td={partial:!0,tokenize:Od};function Ed(e,t,n){let r=this,i=r.events[r.events.length-1],a=i&&i[1].type===`linePrefix`?i[2].sliceSerialize(i[1],!0).length:0,o=0;return s;function s(t){let i=r.containerState.type||(t===42||t===43||t===45?`listUnordered`:`listOrdered`);if(i===`listUnordered`?!r.containerState.marker||t===r.containerState.marker:Fl(t)){if(r.containerState.type||(r.containerState.type=i,e.enter(i,{_container:!0})),i===`listUnordered`)return e.enter(`listItemPrefix`),t===42||t===45?e.check(xd,n,l)(t):l(t);if(!r.interrupt||t===49)return e.enter(`listItemPrefix`),e.enter(`listItemValue`),c(t)}return n(t)}function c(t){return Fl(t)&&++o<10?(e.consume(t),c):(!r.interrupt||o<2)&&(r.containerState.marker?t===r.containerState.marker:t===41||t===46)?(e.exit(`listItemValue`),l(t)):n(t)}function l(t){return e.enter(`listItemMarker`),e.consume(t),e.exit(`listItemMarker`),r.containerState.marker=r.containerState.marker||t,e.check(iu,r.interrupt?n:u,e.attempt(wd,f,d))}function u(e){return r.containerState.initialBlankLine=!0,a++,f(e)}function d(t){return $(t)?(e.enter(`listItemPrefixWhitespace`),e.consume(t),e.exit(`listItemPrefixWhitespace`),f):n(t)}function f(n){return r.containerState.size=a+r.sliceSerialize(e.exit(`listItemPrefix`),!0).length,t(n)}}function Dd(e,t,n){let r=this;return r.containerState._closeFlow=void 0,e.check(iu,i,a);function i(n){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,Ul(e,t,`listItemIndent`,r.containerState.size+1)(n)}function a(n){return r.containerState.furtherBlankLines||!$(n)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,o(n)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(Td,t,o)(n))}function o(i){return r.containerState._closeFlow=!0,r.interrupt=void 0,Ul(e,e.attempt(Cd,t,n),`linePrefix`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)(i)}}function Od(e,t,n){let r=this;return Ul(e,i,`listItemIndent`,r.containerState.size+1);function i(e){let i=r.events[r.events.length-1];return i&&i[1].type===`listItemIndent`&&i[2].sliceSerialize(i[1],!0).length===r.containerState.size?t(e):n(e)}}function kd(e){e.exit(this.containerState.type)}function Ad(e,t,n){let r=this;return Ul(e,i,`listItemPrefixWhitespace`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:5);function i(e){let i=r.events[r.events.length-1];return!$(e)&&i&&i[1].type===`listItemPrefixWhitespace`?t(e):n(e)}}var jd={name:`setextUnderline`,resolveTo:Md,tokenize:Nd};function Md(e,t){let n=e.length,r,i,a;for(;n--;)if(e[n][0]===`enter`){if(e[n][1].type===`content`){r=n;break}e[n][1].type===`paragraph`&&(i=n)}else e[n][1].type===`content`&&e.splice(n,1),!a&&e[n][1].type===`definition`&&(a=n);let o={type:`setextHeading`,start:{...e[r][1].start},end:{...e[e.length-1][1].end}};return e[i][1].type=`setextHeadingText`,a?(e.splice(i,0,[`enter`,o,t]),e.splice(a+1,0,[`exit`,e[r][1],t]),e[r][1].end={...e[a][1].end}):e[r][1]=o,e.push([`exit`,o,t]),e}function Nd(e,t,n){let r=this,i;return a;function a(t){let a=r.events.length,s;for(;a--;)if(r.events[a][1].type!==`lineEnding`&&r.events[a][1].type!==`linePrefix`&&r.events[a][1].type!==`content`){s=r.events[a][1].type===`paragraph`;break}return!r.parser.lazy[r.now().line]&&(r.interrupt||s)?(e.enter(`setextHeadingLine`),i=t,o(t)):n(t)}function o(t){return e.enter(`setextHeadingLineSequence`),s(t)}function s(t){return t===i?(e.consume(t),s):(e.exit(`setextHeadingLineSequence`),$(t)?Ul(e,c,`lineSuffix`)(t):c(t))}function c(r){return r===null||Q(r)?(e.exit(`setextHeadingLine`),t(r)):n(r)}}var Pd={tokenize:Fd};function Fd(e){let t=this,n=e.attempt(iu,r,e.attempt(this.parser.constructs.flowInitial,i,Ul(e,e.attempt(this.parser.constructs.flow,i,e.attempt(Au,i)),`linePrefix`)));return n;function r(r){if(r===null){e.consume(r);return}return e.enter(`lineEndingBlank`),e.consume(r),e.exit(`lineEndingBlank`),t.currentConstruct=void 0,n}function i(r){if(r===null){e.consume(r);return}return e.enter(`lineEnding`),e.consume(r),e.exit(`lineEnding`),t.currentConstruct=void 0,n}}var Id={resolveAll:Bd()},Ld=zd(`string`),Rd=zd(`text`);function zd(e){return{resolveAll:Bd(e===`text`?Vd:void 0),tokenize:t};function t(t){let n=this,r=this.parser.constructs[e],i=t.attempt(r,a,o);return a;function a(e){return c(e)?i(e):o(e)}function o(e){if(e===null){t.consume(e);return}return t.enter(`data`),t.consume(e),s}function s(e){return c(e)?(t.exit(`data`),i(e)):(t.consume(e),s)}function c(e){if(e===null)return!0;let t=r[e],i=-1;if(t)for(;++i<t.length;){let e=t[i];if(!e.previous||e.previous.call(n,n.previous))return!0}return!1}}}function Bd(e){return t;function t(t,n){let r=-1,i;for(;++r<=t.length;)i===void 0?t[r]&&t[r][1].type===`data`&&(i=r,r++):(!t[r]||t[r][1].type!==`data`)&&(r!==i+2&&(t[i][1].end=t[r-1][1].end,t.splice(i+2,r-i-2),r=i+2),i=void 0);return e?e(t,n):t}}function Vd(e,t){let n=0;for(;++n<=e.length;)if((n===e.length||e[n][1].type===`lineEnding`)&&e[n-1][1].type===`data`){let r=e[n-1][1],i=t.sliceStream(r),a=i.length,o=-1,s=0,c;for(;a--;){let e=i[a];if(typeof e==`string`){for(o=e.length;e.charCodeAt(o-1)===32;)s++,o--;if(o)break;o=-1}else if(e===-2)c=!0,s++;else if(e!==-1){a++;break}}if(t._contentTypeTextTrailing&&n===e.length&&(s=0),s){let i={type:n===e.length||c||s<2?`lineSuffix`:`hardBreakTrailing`,start:{_bufferIndex:a?o:r.start._bufferIndex+o,_index:r.start._index+a,line:r.end.line,column:r.end.column-s,offset:r.end.offset-s},end:{...r.end}};r.end={...i.start},r.start.offset===r.end.offset?Object.assign(r,i):(e.splice(n,0,[`enter`,i,t],[`exit`,i,t]),n+=2)}n++}return e}var Hd=h({attentionMarkers:()=>Xd,contentInitial:()=>Wd,disable:()=>Zd,document:()=>Ud,flow:()=>Kd,flowInitial:()=>Gd,insideSpan:()=>Yd,string:()=>qd,text:()=>Jd}),Ud={42:Cd,43:Cd,45:Cd,48:Cd,49:Cd,50:Cd,51:Cd,52:Cd,53:Cd,54:Cd,55:Cd,56:Cd,57:Cd,62:ou},Wd={91:zu},Gd={[-2]:vu,[-1]:vu,32:vu},Kd={35:Gu,42:xd,45:[jd,xd],60:Xu,61:jd,95:xd,96:hu,126:hu},qd={38:fu,92:uu},Jd={[-5]:yd,[-4]:yd,[-3]:yd,33:hd,38:fu,42:Ql,60:[nu,rd],91:_d,92:[Uu,uu],93:ad,95:Ql,96:Su},Yd={null:[Ql,Id]},Xd={null:[42,95]},Zd={null:[]};function Qd(e,t,n){let r={_bufferIndex:-1,_index:0,line:n&&n.line||1,column:n&&n.column||1,offset:n&&n.offset||0},i={},a=[],o=[],s=[],c={attempt:C(x),check:C(S),consume:v,enter:y,exit:b,interrupt:C(S,{interrupt:!0})},l={code:null,containerState:{},defineSkip:h,events:[],now:m,parser:e,previous:null,sliceSerialize:f,sliceStream:p,write:d},u=t.tokenize.call(l,c);return t.resolveAll&&a.push(t),l;function d(e){return o=wl(o,e),g(),o[o.length-1]===null?(w(t,0),l.events=Zl(a,l.events,l),l.events):[]}function f(e,t){return ef(p(e),t)}function p(e){return $d(o,e)}function m(){let{_bufferIndex:e,_index:t,line:n,column:i,offset:a}=r;return{_bufferIndex:e,_index:t,line:n,column:i,offset:a}}function h(e){i[e.line]=e.column,E()}function g(){let e;for(;r._index<o.length;){let t=o[r._index];if(typeof t==`string`)for(e=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===e&&r._bufferIndex<t.length;)_(t.charCodeAt(r._bufferIndex));else _(t)}}function _(e){u=u(e)}function v(e){Q(e)?(r.line++,r.column=1,r.offset+=e===-3?2:1,E()):e!==-1&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===o[r._index].length&&(r._bufferIndex=-1,r._index++)),l.previous=e}function y(e,t){let n=t||{};return n.type=e,n.start=m(),l.events.push([`enter`,n,l]),s.push(n),n}function b(e){let t=s.pop();return t.end=m(),l.events.push([`exit`,t,l]),t}function x(e,t){w(e,t.from)}function S(e,t){t.restore()}function C(e,t){return n;function n(n,r,i){let a,o,s,u;return Array.isArray(n)?f(n):`tokenize`in n?f([n]):d(n);function d(e){return t;function t(t){let n=t!==null&&e[t],r=t!==null&&e.null;return f([...Array.isArray(n)?n:n?[n]:[],...Array.isArray(r)?r:r?[r]:[]])(t)}}function f(e){return a=e,o=0,e.length===0?i:p(e[o])}function p(e){return n;function n(n){return u=T(),s=e,e.partial||(l.currentConstruct=e),e.name&&l.parser.constructs.disable.null.includes(e.name)?h(n):e.tokenize.call(t?Object.assign(Object.create(l),t):l,c,m,h)(n)}}function m(t){return e(s,u),r}function h(e){return u.restore(),++o<a.length?p(a[o]):i}}}function w(e,t){e.resolveAll&&!a.includes(e)&&a.push(e),e.resolve&&Cl(l.events,t,l.events.length-t,e.resolve(l.events.slice(t),l)),e.resolveTo&&(l.events=e.resolveTo(l.events,l))}function T(){let e=m(),t=l.previous,n=l.currentConstruct,i=l.events.length,a=Array.from(s);return{from:i,restore:o};function o(){r=e,l.previous=t,l.currentConstruct=n,l.events.length=i,s=a,E()}}function E(){r.line in i&&r.column<2&&(r.column=i[r.line],r.offset+=i[r.line]-1)}}function $d(e,t){let n=t.start._index,r=t.start._bufferIndex,i=t.end._index,a=t.end._bufferIndex,o;if(n===i)o=[e[n].slice(r,a)];else{if(o=e.slice(n,i),r>-1){let e=o[0];typeof e==`string`?o[0]=e.slice(r):o.shift()}a>0&&o.push(e[i].slice(0,a))}return o}function ef(e,t){let n=-1,r=[],i;for(;++n<e.length;){let a=e[n],o;if(typeof a==`string`)o=a;else switch(a){case-5:o=`\r`;break;case-4:o=`
|
|
12
|
+
`;break;case-3:o=`\r
|
|
13
|
+
`;break;case-2:o=t?` `:` `;break;case-1:if(!t&&i)continue;o=` `;break;default:o=String.fromCharCode(a)}i=a===-2,r.push(o)}return r.join(``)}function tf(e){let t={constructs:El([Hd,...(e||{}).extensions||[]]),content:n(Wl),defined:[],document:n(Kl),flow:n(Pd),lazy:{},string:n(Ld),text:n(Rd)};return t;function n(e){return n;function n(n){return Qd(t,e,n)}}}function nf(e){for(;!Ou(e););return e}var rf=/[\0\t\n\r]/g;function af(){let e=1,t=``,n=!0,r;return i;function i(i,a,o){let s=[],c,l,u,d,f;for(i=t+(typeof i==`string`?i.toString():new TextDecoder(a||void 0).decode(i)),u=0,t=``,n&&=(i.charCodeAt(0)===65279&&u++,void 0);u<i.length;){if(rf.lastIndex=u,c=rf.exec(i),d=c&&c.index!==void 0?c.index:i.length,f=i.charCodeAt(d),!c){t=i.slice(u);break}if(f===10&&u===d&&r)s.push(-3),r=void 0;else switch(r&&=(s.push(-5),void 0),u<d&&(s.push(i.slice(u,d)),e+=d-u),f){case 0:s.push(65533),e++;break;case 9:for(l=Math.ceil(e/4)*4,s.push(-2);e++<l;)s.push(-1);break;case 10:s.push(-4),e=1;break;default:r=!0,e=1}u=d+1}return o&&(r&&s.push(-5),t&&s.push(t),s.push(null)),s}}var of=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function sf(e){return e.replace(of,cf)}function cf(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){let e=n.charCodeAt(1),t=e===120||e===88;return kl(n.slice(t?2:1),t?16:10)}return Sl(n)||e}var lf={}.hasOwnProperty;function uf(e,t,n){return t&&typeof t==`object`&&(n=t,t=void 0),df(n)(nf(tf(n).document().write(af()(e,t,!0))))}function df(e){let t={transforms:[],canContainEols:[`emphasis`,`fragment`,`heading`,`paragraph`,`strong`],enter:{autolink:a(de),autolinkProtocol:T,autolinkEmail:T,atxHeading:a(se),blockQuote:a(re),characterEscape:T,characterReference:T,codeFenced:a(U),codeFencedFenceInfo:o,codeFencedFenceMeta:o,codeIndented:a(U,o),codeText:a(ie,o),codeTextData:T,data:T,codeFlowValue:T,definition:a(ae),definitionDestinationString:o,definitionLabelString:o,definitionTitleString:o,emphasis:a(oe),hardBreakEscape:a(ce),hardBreakTrailing:a(ce),htmlFlow:a(le,o),htmlFlowData:T,htmlText:a(le,o),htmlTextData:T,image:a(ue),label:o,link:a(de),listItem:a(pe),listItemValue:f,listOrdered:a(fe,d),listUnordered:a(fe),paragraph:a(me),reference:te,referenceString:o,resourceDestinationString:o,resourceTitleString:o,setextHeading:a(se),strong:a(he),thematicBreak:a(_e)},exit:{atxHeading:c(),atxHeadingSequence:x,autolink:c(),autolinkEmail:ne,autolinkProtocol:H,blockQuote:c(),characterEscapeValue:E,characterReferenceMarkerHexadecimal:z,characterReferenceMarkerNumeric:z,characterReferenceValue:B,characterReference:V,codeFenced:c(g),codeFencedFence:h,codeFencedFenceInfo:p,codeFencedFenceMeta:m,codeFlowValue:E,codeIndented:c(_),codeText:c(j),codeTextData:E,data:E,definition:c(),definitionDestinationString:b,definitionLabelString:v,definitionTitleString:y,emphasis:c(),hardBreakEscape:c(O),hardBreakTrailing:c(O),htmlFlow:c(k),htmlFlowData:E,htmlText:c(A),htmlTextData:E,image:c(N),label:F,labelText:P,lineEnding:D,link:c(M),listItem:c(),listOrdered:c(),listUnordered:c(),paragraph:c(),referenceString:R,resourceDestinationString:I,resourceTitleString:L,resource:ee,setextHeading:c(w),setextHeadingLineSequence:C,setextHeadingText:S,strong:c(),thematicBreak:c()}};pf(t,(e||{}).mdastExtensions||[]);let n={};return r;function r(e){let r={type:`root`,children:[]},a={stack:[r],tokenStack:[],config:t,enter:s,exit:l,buffer:o,resume:u,data:n},c=[],d=-1;for(;++d<e.length;)(e[d][1].type===`listOrdered`||e[d][1].type===`listUnordered`)&&(e[d][0]===`enter`?c.push(d):d=i(e,c.pop(),d));for(d=-1;++d<e.length;){let n=t[e[d][0]];lf.call(n,e[d][1].type)&&n[e[d][1].type].call(Object.assign({sliceSerialize:e[d][2].sliceSerialize},a),e[d][1])}if(a.tokenStack.length>0){let e=a.tokenStack[a.tokenStack.length-1];(e[1]||hf).call(a,void 0,e[0])}for(r.position={start:ff(e.length>0?e[0][1].start:{line:1,column:1,offset:0}),end:ff(e.length>0?e[e.length-2][1].end:{line:1,column:1,offset:0})},d=-1;++d<t.transforms.length;)r=t.transforms[d](r)||r;return r}function i(e,t,n){let r=t-1,i=-1,a=!1,o,s,c,l;for(;++r<=n;){let t=e[r];switch(t[1].type){case`listUnordered`:case`listOrdered`:case`blockQuote`:t[0]===`enter`?i++:i--,l=void 0;break;case`lineEndingBlank`:t[0]===`enter`&&(o&&!l&&!i&&!c&&(c=r),l=void 0);break;case`linePrefix`:case`listItemValue`:case`listItemMarker`:case`listItemPrefix`:case`listItemPrefixWhitespace`:break;default:l=void 0}if(!i&&t[0]===`enter`&&t[1].type===`listItemPrefix`||i===-1&&t[0]===`exit`&&(t[1].type===`listUnordered`||t[1].type===`listOrdered`)){if(o){let i=r;for(s=void 0;i--;){let t=e[i];if(t[1].type===`lineEnding`||t[1].type===`lineEndingBlank`){if(t[0]===`exit`)continue;s&&(e[s][1].type=`lineEndingBlank`,a=!0),t[1].type=`lineEnding`,s=i}else if(!(t[1].type===`linePrefix`||t[1].type===`blockQuotePrefix`||t[1].type===`blockQuotePrefixWhitespace`||t[1].type===`blockQuoteMarker`||t[1].type===`listItemIndent`))break}c&&(!s||c<s)&&(o._spread=!0),o.end=Object.assign({},s?e[s][1].start:t[1].end),e.splice(s||r,0,[`exit`,o,t[2]]),r++,n++}if(t[1].type===`listItemPrefix`){let i={type:`listItem`,_spread:!1,start:Object.assign({},t[1].start),end:void 0};o=i,e.splice(r,0,[`enter`,i,t[2]]),r++,n++,c=void 0,l=!0}}}return e[t][1]._spread=a,n}function a(e,t){return n;function n(n){s.call(this,e(n),n),t&&t.call(this,n)}}function o(){this.stack.push({type:`fragment`,children:[]})}function s(e,t,n){this.stack[this.stack.length-1].children.push(e),this.stack.push(e),this.tokenStack.push([t,n||void 0]),e.position={start:ff(t.start),end:void 0}}function c(e){return t;function t(t){e&&e.call(this,t),l.call(this,t)}}function l(e,t){let n=this.stack.pop(),r=this.tokenStack.pop();if(r)r[0].type!==e.type&&(t?t.call(this,e,r[0]):(r[1]||hf).call(this,e,r[0]));else throw Error("Cannot close `"+e.type+"` ("+Ic({start:e.start,end:e.end})+`): it’s not open`);n.position.end=ff(e.end)}function u(){return _l(this.stack.pop())}function d(){this.data.expectingFirstListItemValue=!0}function f(e){if(this.data.expectingFirstListItemValue){let t=this.stack[this.stack.length-2];t.start=Number.parseInt(this.sliceSerialize(e),10),this.data.expectingFirstListItemValue=void 0}}function p(){let e=this.resume(),t=this.stack[this.stack.length-1];t.lang=e}function m(){let e=this.resume(),t=this.stack[this.stack.length-1];t.meta=e}function h(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function g(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,``),this.data.flowCodeInside=void 0}function _(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e.replace(/(\r?\n|\r)$/g,``)}function v(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=Al(this.sliceSerialize(e)).toLowerCase()}function y(){let e=this.resume(),t=this.stack[this.stack.length-1];t.title=e}function b(){let e=this.resume(),t=this.stack[this.stack.length-1];t.url=e}function x(e){let t=this.stack[this.stack.length-1];t.depth||=this.sliceSerialize(e).length}function S(){this.data.setextHeadingSlurpLineEnding=!0}function C(e){let t=this.stack[this.stack.length-1];t.depth=this.sliceSerialize(e).codePointAt(0)===61?1:2}function w(){this.data.setextHeadingSlurpLineEnding=void 0}function T(e){let t=this.stack[this.stack.length-1].children,n=t[t.length-1];(!n||n.type!==`text`)&&(n=ge(),n.position={start:ff(e.start),end:void 0},t.push(n)),this.stack.push(n)}function E(e){let t=this.stack.pop();t.value+=this.sliceSerialize(e),t.position.end=ff(e.end)}function D(e){let n=this.stack[this.stack.length-1];if(this.data.atHardBreak){let t=n.children[n.children.length-1];t.position.end=ff(e.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(n.type)&&(T.call(this,e),E.call(this,e))}function O(){this.data.atHardBreak=!0}function k(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function A(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function j(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function M(){let e=this.stack[this.stack.length-1];if(this.data.inReference){let t=this.data.referenceType||`shortcut`;e.type+=`Reference`,e.referenceType=t,delete e.url,delete e.title}else delete e.identifier,delete e.label;this.data.referenceType=void 0}function N(){let e=this.stack[this.stack.length-1];if(this.data.inReference){let t=this.data.referenceType||`shortcut`;e.type+=`Reference`,e.referenceType=t,delete e.url,delete e.title}else delete e.identifier,delete e.label;this.data.referenceType=void 0}function P(e){let t=this.sliceSerialize(e),n=this.stack[this.stack.length-2];n.label=sf(t),n.identifier=Al(t).toLowerCase()}function F(){let e=this.stack[this.stack.length-1],t=this.resume(),n=this.stack[this.stack.length-1];this.data.inReference=!0,n.type===`link`?n.children=e.children:n.alt=t}function I(){let e=this.resume(),t=this.stack[this.stack.length-1];t.url=e}function L(){let e=this.resume(),t=this.stack[this.stack.length-1];t.title=e}function ee(){this.data.inReference=void 0}function te(){this.data.referenceType=`collapsed`}function R(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=Al(this.sliceSerialize(e)).toLowerCase(),this.data.referenceType=`full`}function z(e){this.data.characterReferenceType=e.type}function B(e){let t=this.sliceSerialize(e),n=this.data.characterReferenceType,r;n?(r=kl(t,n===`characterReferenceMarkerNumeric`?10:16),this.data.characterReferenceType=void 0):r=Sl(t);let i=this.stack[this.stack.length-1];i.value+=r}function V(e){let t=this.stack.pop();t.position.end=ff(e.end)}function H(e){E.call(this,e);let t=this.stack[this.stack.length-1];t.url=this.sliceSerialize(e)}function ne(e){E.call(this,e);let t=this.stack[this.stack.length-1];t.url=`mailto:`+this.sliceSerialize(e)}function re(){return{type:`blockquote`,children:[]}}function U(){return{type:`code`,lang:null,meta:null,value:``}}function ie(){return{type:`inlineCode`,value:``}}function ae(){return{type:`definition`,identifier:``,label:null,title:null,url:``}}function oe(){return{type:`emphasis`,children:[]}}function se(){return{type:`heading`,depth:0,children:[]}}function ce(){return{type:`break`}}function le(){return{type:`html`,value:``}}function ue(){return{type:`image`,title:null,url:``,alt:null}}function de(){return{type:`link`,title:null,url:``,children:[]}}function fe(e){return{type:`list`,ordered:e.type===`listOrdered`,start:null,spread:e._spread,children:[]}}function pe(e){return{type:`listItem`,spread:e._spread,checked:null,children:[]}}function me(){return{type:`paragraph`,children:[]}}function he(){return{type:`strong`,children:[]}}function ge(){return{type:`text`,value:``}}function _e(){return{type:`thematicBreak`}}}function ff(e){return{line:e.line,column:e.column,offset:e.offset}}function pf(e,t){let n=-1;for(;++n<t.length;){let r=t[n];Array.isArray(r)?pf(e,r):mf(e,r)}}function mf(e,t){let n;for(n in t)if(lf.call(t,n))switch(n){case`canContainEols`:{let r=t[n];r&&e[n].push(...r);break}case`transforms`:{let r=t[n];r&&e[n].push(...r);break}case`enter`:case`exit`:{let r=t[n];r&&Object.assign(e[n],r);break}}}function hf(e,t){throw Error(e?"Cannot close `"+e.type+"` ("+Ic({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+Ic({start:t.start,end:t.end})+`) is open`:"Cannot close document, a token (`"+t.type+"`, "+Ic({start:t.start,end:t.end})+`) is still open`)}function gf(e){let t=this;t.parser=n;function n(n){return uf(n,{...t.data(`settings`),...e,extensions:t.data(`micromarkExtensions`)||[],mdastExtensions:t.data(`fromMarkdownExtensions`)||[]})}}function _f(e,t){let n={type:`element`,tagName:`blockquote`,properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,n),e.applyData(t,n)}function vf(e,t){let n={type:`element`,tagName:`br`,properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:`text`,value:`
|
|
14
|
+
`}]}function yf(e,t){let n=t.value?t.value+`
|
|
15
|
+
`:``,r={},i=t.lang?t.lang.split(/\s+/):[];i.length>0&&(r.className=[`language-`+i[0]]);let a={type:`element`,tagName:`code`,properties:r,children:[{type:`text`,value:n}]};return t.meta&&(a.data={meta:t.meta}),e.patch(t,a),a=e.applyData(t,a),a={type:`element`,tagName:`pre`,properties:{},children:[a]},e.patch(t,a),a}function bf(e,t){let n={type:`element`,tagName:`del`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function xf(e,t){let n={type:`element`,tagName:`em`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function Sf(e,t){let n=typeof e.options.clobberPrefix==`string`?e.options.clobberPrefix:`user-content-`,r=String(t.identifier).toUpperCase(),i=Hl(r.toLowerCase()),a=e.footnoteOrder.indexOf(r),o,s=e.footnoteCounts.get(r);s===void 0?(s=0,e.footnoteOrder.push(r),o=e.footnoteOrder.length):o=a+1,s+=1,e.footnoteCounts.set(r,s);let c={type:`element`,tagName:`a`,properties:{href:`#`+n+`fn-`+i,id:n+`fnref-`+i+(s>1?`-`+s:``),dataFootnoteRef:!0,ariaDescribedBy:[`footnote-label`]},children:[{type:`text`,value:String(o)}]};e.patch(t,c);let l={type:`element`,tagName:`sup`,properties:{},children:[c]};return e.patch(t,l),e.applyData(t,l)}function Cf(e,t){let n={type:`element`,tagName:`h`+t.depth,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function wf(e,t){if(e.options.allowDangerousHtml){let n={type:`raw`,value:t.value};return e.patch(t,n),e.applyData(t,n)}}function Tf(e,t){let n=t.referenceType,r=`]`;if(n===`collapsed`?r+=`[]`:n===`full`&&(r+=`[`+(t.label||t.identifier)+`]`),t.type===`imageReference`)return[{type:`text`,value:`![`+t.alt+r}];let i=e.all(t),a=i[0];a&&a.type===`text`?a.value=`[`+a.value:i.unshift({type:`text`,value:`[`});let o=i[i.length-1];return o&&o.type===`text`?o.value+=r:i.push({type:`text`,value:r}),i}function Ef(e,t){let n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return Tf(e,t);let i={src:Hl(r.url||``),alt:t.alt};r.title!==null&&r.title!==void 0&&(i.title=r.title);let a={type:`element`,tagName:`img`,properties:i,children:[]};return e.patch(t,a),e.applyData(t,a)}function Df(e,t){let n={src:Hl(t.url)};t.alt!==null&&t.alt!==void 0&&(n.alt=t.alt),t.title!==null&&t.title!==void 0&&(n.title=t.title);let r={type:`element`,tagName:`img`,properties:n,children:[]};return e.patch(t,r),e.applyData(t,r)}function Of(e,t){let n={type:`text`,value:t.value.replace(/\r?\n|\r/g,` `)};e.patch(t,n);let r={type:`element`,tagName:`code`,properties:{},children:[n]};return e.patch(t,r),e.applyData(t,r)}function kf(e,t){let n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return Tf(e,t);let i={href:Hl(r.url||``)};r.title!==null&&r.title!==void 0&&(i.title=r.title);let a={type:`element`,tagName:`a`,properties:i,children:e.all(t)};return e.patch(t,a),e.applyData(t,a)}function Af(e,t){let n={href:Hl(t.url)};t.title!==null&&t.title!==void 0&&(n.title=t.title);let r={type:`element`,tagName:`a`,properties:n,children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function jf(e,t,n){let r=e.all(t),i=n?Mf(n):Nf(t),a={},o=[];if(typeof t.checked==`boolean`){let e=r[0],n;e&&e.type===`element`&&e.tagName===`p`?n=e:(n={type:`element`,tagName:`p`,properties:{},children:[]},r.unshift(n)),n.children.length>0&&n.children.unshift({type:`text`,value:` `}),n.children.unshift({type:`element`,tagName:`input`,properties:{type:`checkbox`,checked:t.checked,disabled:!0},children:[]}),a.className=[`task-list-item`]}let s=-1;for(;++s<r.length;){let e=r[s];(i||s!==0||e.type!==`element`||e.tagName!==`p`)&&o.push({type:`text`,value:`
|
|
16
|
+
`}),e.type===`element`&&e.tagName===`p`&&!i?o.push(...e.children):o.push(e)}let c=r[r.length-1];c&&(i||c.type!==`element`||c.tagName!==`p`)&&o.push({type:`text`,value:`
|
|
17
|
+
`});let l={type:`element`,tagName:`li`,properties:a,children:o};return e.patch(t,l),e.applyData(t,l)}function Mf(e){let t=!1;if(e.type===`list`){t=e.spread||!1;let n=e.children,r=-1;for(;!t&&++r<n.length;)t=Nf(n[r])}return t}function Nf(e){return e.spread??e.children.length>1}function Pf(e,t){let n={},r=e.all(t),i=-1;for(typeof t.start==`number`&&t.start!==1&&(n.start=t.start);++i<r.length;){let e=r[i];if(e.type===`element`&&e.tagName===`li`&&e.properties&&Array.isArray(e.properties.className)&&e.properties.className.includes(`task-list-item`)){n.className=[`contains-task-list`];break}}let a={type:`element`,tagName:t.ordered?`ol`:`ul`,properties:n,children:e.wrap(r,!0)};return e.patch(t,a),e.applyData(t,a)}function Ff(e,t){let n={type:`element`,tagName:`p`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function If(e,t){let n={type:`root`,children:e.wrap(e.all(t))};return e.patch(t,n),e.applyData(t,n)}function Lf(e,t){let n={type:`element`,tagName:`strong`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function Rf(e,t){let n=e.all(t),r=n.shift(),i=[];if(r){let n={type:`element`,tagName:`thead`,properties:{},children:e.wrap([r],!0)};e.patch(t.children[0],n),i.push(n)}if(n.length>0){let r={type:`element`,tagName:`tbody`,properties:{},children:e.wrap(n,!0)},a=Nc(t.children[1]),o=Mc(t.children[t.children.length-1]);a&&o&&(r.position={start:a,end:o}),i.push(r)}let a={type:`element`,tagName:`table`,properties:{},children:e.wrap(i,!0)};return e.patch(t,a),e.applyData(t,a)}function zf(e,t,n){let r=n?n.children:void 0,i=(r?r.indexOf(t):1)===0?`th`:`td`,a=n&&n.type===`table`?n.align:void 0,o=a?a.length:t.children.length,s=-1,c=[];for(;++s<o;){let n=t.children[s],r={},o=a?a[s]:void 0;o&&(r.align=o);let l={type:`element`,tagName:i,properties:r,children:[]};n&&(l.children=e.all(n),e.patch(n,l),l=e.applyData(n,l)),c.push(l)}let l={type:`element`,tagName:`tr`,properties:{},children:e.wrap(c,!0)};return e.patch(t,l),e.applyData(t,l)}function Bf(e,t){let n={type:`element`,tagName:`td`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}var Vf=9,Hf=32;function Uf(e){let t=String(e),n=/\r?\n|\r/g,r=n.exec(t),i=0,a=[];for(;r;)a.push(Wf(t.slice(i,r.index),i>0,!0),r[0]),i=r.index+r[0].length,r=n.exec(t);return a.push(Wf(t.slice(i),i>0,!1)),a.join(``)}function Wf(e,t,n){let r=0,i=e.length;if(t){let t=e.codePointAt(r);for(;t===Vf||t===Hf;)r++,t=e.codePointAt(r)}if(n){let t=e.codePointAt(i-1);for(;t===Vf||t===Hf;)i--,t=e.codePointAt(i-1)}return i>r?e.slice(r,i):``}function Gf(e,t){let n={type:`text`,value:Uf(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function Kf(e,t){let n={type:`element`,tagName:`hr`,properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}var qf={blockquote:_f,break:vf,code:yf,delete:bf,emphasis:xf,footnoteReference:Sf,heading:Cf,html:wf,imageReference:Ef,image:Df,inlineCode:Of,linkReference:kf,link:Af,listItem:jf,list:Pf,paragraph:Ff,root:If,strong:Lf,table:Rf,tableCell:Bf,tableRow:zf,text:Gf,thematicBreak:Kf,toml:Jf,yaml:Jf,definition:Jf,footnoteDefinition:Jf};function Jf(){}var Yf=typeof self==`object`?self:globalThis,Xf=(e,t)=>{switch(e){case`Function`:case`SharedWorker`:case`Worker`:case`eval`:case`setInterval`:case`setTimeout`:throw TypeError(`unable to deserialize `+e)}return new Yf[e](t)},Zf=(e,t)=>{let n=(t,n)=>(e.set(n,t),t),r=i=>{if(e.has(i))return e.get(i);let[a,o]=t[i];switch(a){case 0:case-1:return n(o,i);case 1:{let e=n([],i);for(let t of o)e.push(r(t));return e}case 2:{let e=n({},i);for(let[t,n]of o)e[r(t)]=r(n);return e}case 3:return n(new Date(o),i);case 4:{let{source:e,flags:t}=o;return n(new RegExp(e,t),i)}case 5:{let e=n(new Map,i);for(let[t,n]of o)e.set(r(t),r(n));return e}case 6:{let e=n(new Set,i);for(let t of o)e.add(r(t));return e}case 7:{let{name:e,message:t}=o;return n(Xf(e,t),i)}case 8:return n(BigInt(o),i);case`BigInt`:return n(Object(BigInt(o)),i);case`ArrayBuffer`:return n(new Uint8Array(o).buffer,o);case`DataView`:{let{buffer:e}=new Uint8Array(o);return n(new DataView(e),o)}}return n(Xf(a,o),i)};return r},Qf=e=>Zf(new Map,e)(0),$f=``,{toString:ep}={},{keys:tp}=Object,np=e=>{let t=typeof e;if(t!==`object`||!e)return[0,t];let n=ep.call(e).slice(8,-1);switch(n){case`Array`:return[1,$f];case`Object`:return[2,$f];case`Date`:return[3,$f];case`RegExp`:return[4,$f];case`Map`:return[5,$f];case`Set`:return[6,$f];case`DataView`:return[1,n]}return n.includes(`Array`)?[1,n]:n.includes(`Error`)?[7,n]:[2,n]},rp=([e,t])=>e===0&&(t===`function`||t===`symbol`),ip=(e,t,n,r)=>{let i=(e,t)=>{let i=r.push(e)-1;return n.set(t,i),i},a=r=>{if(n.has(r))return n.get(r);let[o,s]=np(r);switch(o){case 0:{let t=r;switch(s){case`bigint`:o=8,t=r.toString();break;case`function`:case`symbol`:if(e)throw TypeError(`unable to serialize `+s);t=null;break;case`undefined`:return i([-1],r)}return i([o,t],r)}case 1:{if(s){let e=r;return s===`DataView`?e=new Uint8Array(r.buffer):s===`ArrayBuffer`&&(e=new Uint8Array(r)),i([s,[...e]],r)}let e=[],t=i([o,e],r);for(let t of r)e.push(a(t));return t}case 2:{if(s)switch(s){case`BigInt`:return i([s,r.toString()],r);case`Boolean`:case`Number`:case`String`:return i([s,r.valueOf()],r)}if(t&&`toJSON`in r)return a(r.toJSON());let n=[],c=i([o,n],r);for(let t of tp(r))(e||!rp(np(r[t])))&&n.push([a(t),a(r[t])]);return c}case 3:return i([o,isNaN(r.getTime())?$f:r.toISOString()],r);case 4:{let{source:e,flags:t}=r;return i([o,{source:e,flags:t}],r)}case 5:{let t=[],n=i([o,t],r);for(let[n,i]of r)(e||!(rp(np(n))||rp(np(i))))&&t.push([a(n),a(i)]);return n}case 6:{let t=[],n=i([o,t],r);for(let n of r)(e||!rp(np(n)))&&t.push(a(n));return n}}let{message:c}=r;return i([o,{name:s,message:c}],r)};return a},ap=(e,{json:t,lossy:n}={})=>{let r=[];return ip(!(t||n),!!t,new Map,r)(e),r},op=typeof structuredClone==`function`?(e,t)=>t&&(`json`in t||`lossy`in t)?Qf(ap(e,t)):structuredClone(e):(e,t)=>Qf(ap(e,t));function sp(e,t){let n=[{type:`text`,value:`↩`}];return t>1&&n.push({type:`element`,tagName:`sup`,properties:{},children:[{type:`text`,value:String(t)}]}),n}function cp(e,t){return`Back to reference `+(e+1)+(t>1?`-`+t:``)}function lp(e){let t=typeof e.options.clobberPrefix==`string`?e.options.clobberPrefix:`user-content-`,n=e.options.footnoteBackContent||sp,r=e.options.footnoteBackLabel||cp,i=e.options.footnoteLabel||`Footnotes`,a=e.options.footnoteLabelTagName||`h2`,o=e.options.footnoteLabelProperties||{className:[`sr-only`]},s=[],c=-1;for(;++c<e.footnoteOrder.length;){let i=e.footnoteById.get(e.footnoteOrder[c]);if(!i)continue;let a=e.all(i),o=String(i.identifier).toUpperCase(),l=Hl(o.toLowerCase()),u=0,d=[],f=e.footnoteCounts.get(o);for(;f!==void 0&&++u<=f;){d.length>0&&d.push({type:`text`,value:` `});let e=typeof n==`string`?n:n(c,u);typeof e==`string`&&(e={type:`text`,value:e}),d.push({type:`element`,tagName:`a`,properties:{href:`#`+t+`fnref-`+l+(u>1?`-`+u:``),dataFootnoteBackref:``,ariaLabel:typeof r==`string`?r:r(c,u),className:[`data-footnote-backref`]},children:Array.isArray(e)?e:[e]})}let p=a[a.length-1];if(p&&p.type===`element`&&p.tagName===`p`){let e=p.children[p.children.length-1];e&&e.type===`text`?e.value+=` `:p.children.push({type:`text`,value:` `}),p.children.push(...d)}else a.push(...d);let m={type:`element`,tagName:`li`,properties:{id:t+`fn-`+l},children:e.wrap(a,!0)};e.patch(i,m),s.push(m)}if(s.length!==0)return{type:`element`,tagName:`section`,properties:{dataFootnotes:!0,className:[`footnotes`]},children:[{type:`element`,tagName:a,properties:{...op(o),id:`footnote-label`},children:[{type:`text`,value:i}]},{type:`text`,value:`
|
|
18
|
+
`},{type:`element`,tagName:`ol`,properties:{},children:e.wrap(s,!0)},{type:`text`,value:`
|
|
19
|
+
`}]}}var up=(function(e){if(e==null)return hp;if(typeof e==`function`)return mp(e);if(typeof e==`object`)return Array.isArray(e)?dp(e):fp(e);if(typeof e==`string`)return pp(e);throw Error(`Expected function, string, or object as test`)});function dp(e){let t=[],n=-1;for(;++n<e.length;)t[n]=up(e[n]);return mp(r);function r(...e){let n=-1;for(;++n<t.length;)if(t[n].apply(this,e))return!0;return!1}}function fp(e){let t=e;return mp(n);function n(n){let r=n,i;for(i in e)if(r[i]!==t[i])return!1;return!0}}function pp(e){return mp(t);function t(t){return t&&t.type===e}}function mp(e){return t;function t(t,n,r){return!!(gp(t)&&e.call(this,t,typeof n==`number`?n:void 0,r||void 0))}}function hp(){return!0}function gp(e){return typeof e==`object`&&!!e&&`type`in e}function _p(e){return e}var vp=[];function yp(e,t,n,r){let i;typeof t==`function`&&typeof n!=`function`?(r=n,n=t):i=t;let a=up(i),o=r?-1:1;s(e,void 0,[])();function s(e,i,c){let l=e&&typeof e==`object`?e:{};if(typeof l.type==`string`){let t=typeof l.tagName==`string`?l.tagName:typeof l.name==`string`?l.name:void 0;Object.defineProperty(u,"name",{value:`node (`+_p(e.type+(t?`<`+t+`>`:``))+`)`})}return u;function u(){let l=vp,u,d,f;if((!t||a(e,i,c[c.length-1]||void 0))&&(l=bp(n(e,c)),l[0]===!1))return l;if(`children`in e&&e.children){let t=e;if(t.children&&l[0]!==`skip`)for(d=(r?t.children.length:-1)+o,f=c.concat(t);d>-1&&d<t.children.length;){let e=t.children[d];if(u=s(e,d,f)(),u[0]===!1)return u;d=typeof u[1]==`number`?u[1]:d+o}}return l}}}function bp(e){return Array.isArray(e)?e:typeof e==`number`?[!0,e]:e==null?vp:[e]}function xp(e,t,n,r){let i,a,o;typeof t==`function`&&typeof n!=`function`?(a=void 0,o=t,i=n):(a=t,o=n,i=r),yp(e,a,s,i);function s(e,t){let n=t[t.length-1],r=n?n.children.indexOf(e):void 0;return o(e,r,n)}}var Sp={}.hasOwnProperty,Cp={};function wp(e,t){let n=t||Cp,r=new Map,i=new Map,a={all:s,applyData:Ep,definitionById:r,footnoteById:i,footnoteCounts:new Map,footnoteOrder:[],handlers:{...qf,...n.handlers},one:o,options:n,patch:Tp,wrap:Op};return xp(e,function(e){if(e.type===`definition`||e.type===`footnoteDefinition`){let t=e.type===`definition`?r:i,n=String(e.identifier).toUpperCase();t.has(n)||t.set(n,e)}}),a;function o(e,t){let n=e.type,r=a.handlers[n];if(Sp.call(a.handlers,n)&&r)return r(a,e,t);if(a.options.passThrough&&a.options.passThrough.includes(n)){if(`children`in e){let{children:t,...n}=e,r=op(n);return r.children=a.all(e),r}return op(e)}return(a.options.unknownHandler||Dp)(a,e,t)}function s(e){let t=[];if(`children`in e){let n=e.children,r=-1;for(;++r<n.length;){let i=a.one(n[r],e);if(i){if(r&&n[r-1].type===`break`&&(!Array.isArray(i)&&i.type===`text`&&(i.value=kp(i.value)),!Array.isArray(i)&&i.type===`element`)){let e=i.children[0];e&&e.type===`text`&&(e.value=kp(e.value))}Array.isArray(i)?t.push(...i):t.push(i)}}}return t}}function Tp(e,t){e.position&&(t.position=Fc(e))}function Ep(e,t){let n=t;if(e&&e.data){let t=e.data.hName,r=e.data.hChildren,i=e.data.hProperties;typeof t==`string`&&(n.type===`element`?n.tagName=t:n={type:`element`,tagName:t,properties:{},children:`children`in n?n.children:[n]}),n.type===`element`&&i&&Object.assign(n.properties,op(i)),`children`in n&&n.children&&r!=null&&(n.children=r)}return n}function Dp(e,t){let n=t.data||{},r=`value`in t&&!(Sp.call(n,`hProperties`)||Sp.call(n,`hChildren`))?{type:`text`,value:t.value}:{type:`element`,tagName:`div`,properties:{},children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function Op(e,t){let n=[],r=-1;for(t&&n.push({type:`text`,value:`
|
|
20
|
+
`});++r<e.length;)r&&n.push({type:`text`,value:`
|
|
21
|
+
`}),n.push(e[r]);return t&&e.length>0&&n.push({type:`text`,value:`
|
|
22
|
+
`}),n}function kp(e){let t=0,n=e.charCodeAt(t);for(;n===9||n===32;)t++,n=e.charCodeAt(t);return e.slice(t)}function Ap(e,t){let n=wp(e,t),r=n.one(e,void 0),i=lp(n),a=Array.isArray(r)?{type:`root`,children:r}:r||{type:`root`,children:[]};return i&&(`children`in a,a.children.push({type:`text`,value:`
|
|
23
|
+
`},i)),a}function jp(e,t){return e&&`run`in e?async function(n,r){let i=Ap(n,{file:r,...t});await e.run(i,r)}:function(n,r){return Ap(n,{file:r,...e||t})}}function Mp(e){if(e)throw e}var Np=m(((e,t)=>{var n=Object.prototype.hasOwnProperty,r=Object.prototype.toString,i=Object.defineProperty,a=Object.getOwnPropertyDescriptor,o=function(e){return typeof Array.isArray==`function`?Array.isArray(e):r.call(e)===`[object Array]`},s=function(e){if(!e||r.call(e)!==`[object Object]`)return!1;var t=n.call(e,`constructor`),i=e.constructor&&e.constructor.prototype&&n.call(e.constructor.prototype,`isPrototypeOf`);if(e.constructor&&!t&&!i)return!1;for(var a in e);return a===void 0||n.call(e,a)},c=function(e,t){i&&t.name===`__proto__`?i(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},l=function(e,t){if(t===`__proto__`){if(!n.call(e,t))return;if(a)return a(e,t).value}return e[t]};t.exports=function e(){var t,n,r,i,a,u,d=arguments[0],f=1,p=arguments.length,m=!1;for(typeof d==`boolean`&&(m=d,d=arguments[1]||{},f=2),(d==null||typeof d!=`object`&&typeof d!=`function`)&&(d={});f<p;++f)if(t=arguments[f],t!=null)for(n in t)r=l(d,n),i=l(t,n),d!==i&&(m&&i&&(s(i)||(a=o(i)))?(a?(a=!1,u=r&&o(r)?r:[]):u=r&&s(r)?r:{},c(d,{name:n,newValue:e(m,u,i)})):i!==void 0&&c(d,{name:n,newValue:i}));return d}}));function Pp(e){if(typeof e!=`object`||!e)return!1;let t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function Fp(){let e=[],t={run:n,use:r};return t;function n(...t){let n=-1,r=t.pop();if(typeof r!=`function`)throw TypeError(`Expected function as last argument, not `+r);i(null,...t);function i(a,...o){let s=e[++n],c=-1;if(a){r(a);return}for(;++c<t.length;)(o[c]===null||o[c]===void 0)&&(o[c]=t[c]);t=o,s?Ip(s,i)(...o):r(null,...o)}}function r(n){if(typeof n!=`function`)throw TypeError("Expected `middelware` to be a function, not "+n);return e.push(n),t}}function Ip(e,t){let n;return r;function r(...t){let r=e.length>t.length,o;r&&t.push(i);try{o=e.apply(this,t)}catch(e){let t=e;if(r&&n)throw t;return i(t)}r||(o&&o.then&&typeof o.then==`function`?o.then(a,i):o instanceof Error?i(o):a(o))}function i(e,...r){n||(n=!0,t(e,...r))}function a(e){i(null,e)}}var Lp={basename:Rp,dirname:zp,extname:Bp,join:Vp,sep:`/`};function Rp(e,t){if(t!==void 0&&typeof t!=`string`)throw TypeError(`"ext" argument must be a string`);Wp(e);let n=0,r=-1,i=e.length,a;if(t===void 0||t.length===0||t.length>e.length){for(;i--;)if(e.codePointAt(i)===47){if(a){n=i+1;break}}else r<0&&(a=!0,r=i+1);return r<0?``:e.slice(n,r)}if(t===e)return``;let o=-1,s=t.length-1;for(;i--;)if(e.codePointAt(i)===47){if(a){n=i+1;break}}else o<0&&(a=!0,o=i+1),s>-1&&(e.codePointAt(i)===t.codePointAt(s--)?s<0&&(r=i):(s=-1,r=o));return n===r?r=o:r<0&&(r=e.length),e.slice(n,r)}function zp(e){if(Wp(e),e.length===0)return`.`;let t=-1,n=e.length,r;for(;--n;)if(e.codePointAt(n)===47){if(r){t=n;break}}else r||=!0;return t<0?e.codePointAt(0)===47?`/`:`.`:t===1&&e.codePointAt(0)===47?`//`:e.slice(0,t)}function Bp(e){Wp(e);let t=e.length,n=-1,r=0,i=-1,a=0,o;for(;t--;){let s=e.codePointAt(t);if(s===47){if(o){r=t+1;break}continue}n<0&&(o=!0,n=t+1),s===46?i<0?i=t:a!==1&&(a=1):i>-1&&(a=-1)}return i<0||n<0||a===0||a===1&&i===n-1&&i===r+1?``:e.slice(i,n)}function Vp(...e){let t=-1,n;for(;++t<e.length;)Wp(e[t]),e[t]&&(n=n===void 0?e[t]:n+`/`+e[t]);return n===void 0?`.`:Hp(n)}function Hp(e){Wp(e);let t=e.codePointAt(0)===47,n=Up(e,!t);return n.length===0&&!t&&(n=`.`),n.length>0&&e.codePointAt(e.length-1)===47&&(n+=`/`),t?`/`+n:n}function Up(e,t){let n=``,r=0,i=-1,a=0,o=-1,s,c;for(;++o<=e.length;){if(o<e.length)s=e.codePointAt(o);else if(s===47)break;else s=47;if(s===47){if(!(i===o-1||a===1))if(i!==o-1&&a===2){if(n.length<2||r!==2||n.codePointAt(n.length-1)!==46||n.codePointAt(n.length-2)!==46){if(n.length>2){if(c=n.lastIndexOf(`/`),c!==n.length-1){c<0?(n=``,r=0):(n=n.slice(0,c),r=n.length-1-n.lastIndexOf(`/`)),i=o,a=0;continue}}else if(n.length>0){n=``,r=0,i=o,a=0;continue}}t&&(n=n.length>0?n+`/..`:`..`,r=2)}else n.length>0?n+=`/`+e.slice(i+1,o):n=e.slice(i+1,o),r=o-i-1;i=o,a=0}else s===46&&a>-1?a++:a=-1}return n}function Wp(e){if(typeof e!=`string`)throw TypeError(`Path must be a string. Received `+JSON.stringify(e))}var Gp={cwd:Kp};function Kp(){return`/`}function qp(e){return!!(typeof e==`object`&&e&&`href`in e&&e.href&&`protocol`in e&&e.protocol&&e.auth===void 0)}function Jp(e){if(typeof e==`string`)e=new URL(e);else if(!qp(e)){let t=TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code=`ERR_INVALID_ARG_TYPE`,t}if(e.protocol!==`file:`){let e=TypeError(`The URL must be of scheme file`);throw e.code=`ERR_INVALID_URL_SCHEME`,e}return Yp(e)}function Yp(e){if(e.hostname!==``){let e=TypeError(`File URL host must be "localhost" or empty on darwin`);throw e.code=`ERR_INVALID_FILE_URL_HOST`,e}let t=e.pathname,n=-1;for(;++n<t.length;)if(t.codePointAt(n)===37&&t.codePointAt(n+1)===50){let e=t.codePointAt(n+2);if(e===70||e===102){let e=TypeError(`File URL path must not include encoded / characters`);throw e.code=`ERR_INVALID_FILE_URL_PATH`,e}}return decodeURIComponent(t)}var Xp=[`history`,`path`,`basename`,`stem`,`extname`,`dirname`],Zp=class{constructor(e){let t;t=e?qp(e)?{path:e}:typeof e==`string`||tm(e)?{value:e}:e:{},this.cwd=`cwd`in t?``:Gp.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let n=-1;for(;++n<Xp.length;){let e=Xp[n];e in t&&t[e]!==void 0&&t[e]!==null&&(this[e]=e===`history`?[...t[e]]:t[e])}let r;for(r in t)Xp.includes(r)||(this[r]=t[r])}get basename(){return typeof this.path==`string`?Lp.basename(this.path):void 0}set basename(e){$p(e,`basename`),Qp(e,`basename`),this.path=Lp.join(this.dirname||``,e)}get dirname(){return typeof this.path==`string`?Lp.dirname(this.path):void 0}set dirname(e){em(this.basename,`dirname`),this.path=Lp.join(e||``,this.basename)}get extname(){return typeof this.path==`string`?Lp.extname(this.path):void 0}set extname(e){if(Qp(e,`extname`),em(this.dirname,`extname`),e){if(e.codePointAt(0)!==46)throw Error("`extname` must start with `.`");if(e.includes(`.`,1))throw Error("`extname` cannot contain multiple dots")}this.path=Lp.join(this.dirname,this.stem+(e||``))}get path(){return this.history[this.history.length-1]}set path(e){qp(e)&&(e=Jp(e)),$p(e,`path`),this.path!==e&&this.history.push(e)}get stem(){return typeof this.path==`string`?Lp.basename(this.path,this.extname):void 0}set stem(e){$p(e,`stem`),Qp(e,`stem`),this.path=Lp.join(this.dirname||``,e+(this.extname||``))}fail(e,t,n){let r=this.message(e,t,n);throw r.fatal=!0,r}info(e,t,n){let r=this.message(e,t,n);return r.fatal=void 0,r}message(e,t,n){let r=new Bc(e,t,n);return this.path&&(r.name=this.path+`:`+r.name,r.file=this.path),r.fatal=!1,this.messages.push(r),r}toString(e){return this.value===void 0?``:typeof this.value==`string`?this.value:new TextDecoder(e||void 0).decode(this.value)}};function Qp(e,t){if(e&&e.includes(Lp.sep))throw Error("`"+t+"` cannot be a path: did not expect `"+Lp.sep+"`")}function $p(e,t){if(!e)throw Error("`"+t+"` cannot be empty")}function em(e,t){if(!e)throw Error("Setting `"+t+"` requires `path` to be set too")}function tm(e){return!!(e&&typeof e==`object`&&`byteLength`in e&&`byteOffset`in e)}var nm=(function(e){let t=this.constructor.prototype,n=t[e],r=function(){return n.apply(r,arguments)};return Object.setPrototypeOf(r,t),r}),rm=t(Np(),1),im={}.hasOwnProperty,am=new class e extends nm{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=Fp()}copy(){let t=new e,n=-1;for(;++n<this.attachers.length;){let e=this.attachers[n];t.use(...e)}return t.data((0,rm.default)(!0,{},this.namespace)),t}data(e,t){return typeof e==`string`?arguments.length===2?(cm(`data`,this.frozen),this.namespace[e]=t,this):im.call(this.namespace,e)&&this.namespace[e]||void 0:e?(cm(`data`,this.frozen),this.namespace=e,this):this.namespace}freeze(){if(this.frozen)return this;let e=this;for(;++this.freezeIndex<this.attachers.length;){let[t,...n]=this.attachers[this.freezeIndex];if(n[0]===!1)continue;n[0]===!0&&(n[0]=void 0);let r=t.call(e,...n);typeof r==`function`&&this.transformers.use(r)}return this.frozen=!0,this.freezeIndex=1/0,this}parse(e){this.freeze();let t=dm(e),n=this.parser||this.Parser;return om(`parse`,n),n(String(t),t)}process(e,t){let n=this;return this.freeze(),om(`process`,this.parser||this.Parser),sm(`process`,this.compiler||this.Compiler),t?r(void 0,t):new Promise(r);function r(r,i){let a=dm(e),o=n.parse(a);n.run(o,a,function(e,t,r){if(e||!t||!r)return s(e);let i=t,a=n.stringify(i,r);pm(a)?r.value=a:r.result=a,s(e,r)});function s(e,n){e||!n?i(e):r?r(n):t(void 0,n)}}}processSync(e){let t=!1,n;return this.freeze(),om(`processSync`,this.parser||this.Parser),sm(`processSync`,this.compiler||this.Compiler),this.process(e,r),um(`processSync`,`process`,t),n;function r(e,r){t=!0,Mp(e),n=r}}run(e,t,n){lm(e),this.freeze();let r=this.transformers;return!n&&typeof t==`function`&&(n=t,t=void 0),n?i(void 0,n):new Promise(i);function i(i,a){let o=dm(t);r.run(e,o,s);function s(t,r,o){let s=r||e;t?a(t):i?i(s):n(void 0,s,o)}}}runSync(e,t){let n=!1,r;return this.run(e,t,i),um(`runSync`,`run`,n),r;function i(e,t){Mp(e),r=t,n=!0}}stringify(e,t){this.freeze();let n=dm(t),r=this.compiler||this.Compiler;return sm(`stringify`,r),lm(e),r(e,n)}use(e,...t){let n=this.attachers,r=this.namespace;if(cm(`use`,this.frozen),e!=null)if(typeof e==`function`)s(e,t);else if(typeof e==`object`)Array.isArray(e)?o(e):a(e);else throw TypeError("Expected usable value, not `"+e+"`");return this;function i(e){if(typeof e==`function`)s(e,[]);else if(typeof e==`object`)if(Array.isArray(e)){let[t,...n]=e;s(t,n)}else a(e);else throw TypeError("Expected usable value, not `"+e+"`")}function a(e){if(!(`plugins`in e)&&!(`settings`in e))throw 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");o(e.plugins),e.settings&&(r.settings=(0,rm.default)(!0,r.settings,e.settings))}function o(e){let t=-1;if(e!=null)if(Array.isArray(e))for(;++t<e.length;){let n=e[t];i(n)}else throw TypeError("Expected a list of plugins, not `"+e+"`")}function s(e,t){let r=-1,i=-1;for(;++r<n.length;)if(n[r][0]===e){i=r;break}if(i===-1)n.push([e,...t]);else if(t.length>0){let[r,...a]=t,o=n[i][1];Pp(o)&&Pp(r)&&(r=(0,rm.default)(!0,o,r)),n[i]=[e,r,...a]}}}}().freeze();function om(e,t){if(typeof t!=`function`)throw TypeError("Cannot `"+e+"` without `parser`")}function sm(e,t){if(typeof t!=`function`)throw TypeError("Cannot `"+e+"` without `compiler`")}function cm(e,t){if(t)throw Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function lm(e){if(!Pp(e)||typeof e.type!=`string`)throw TypeError("Expected node, got `"+e+"`")}function um(e,t,n){if(!n)throw Error("`"+e+"` finished async. Use `"+t+"` instead")}function dm(e){return fm(e)?e:new Zp(e)}function fm(e){return!!(e&&typeof e==`object`&&`message`in e&&`messages`in e)}function pm(e){return typeof e==`string`||mm(e)}function mm(e){return!!(e&&typeof e==`object`&&`byteLength`in e&&`byteOffset`in e)}var hm=[],gm={allowDangerousHtml:!0},_m=/^(https?|ircs?|mailto|xmpp)$/i,vm=[{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 ym(e){let t=bm(e),n=xm(e);return Sm(t.runSync(t.parse(n),n),e)}function bm(e){let t=e.rehypePlugins||hm,n=e.remarkPlugins||hm,r=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...gm}:gm;return am().use(gf).use(n).use(jp,r).use(t)}function xm(e){let t=e.children||``,n=new Zp;return typeof t==`string`?n.value=t:``+t,n}function Sm(e,t){let n=t.allowedElements,r=t.allowElement,i=t.components,a=t.disallowedElements,o=t.skipHtml,s=t.unwrapDisallowed,c=t.urlTransform||Cm;for(let e of vm)Object.hasOwn(t,e.from)&&``+e.from+(e.to?"use `"+e.to+"` instead":`remove it`)+e.id;return xp(e,l),qc(e,{Fragment:K.Fragment,components:i,ignoreInvalidStyle:!0,jsx:K.jsx,jsxs:K.jsxs,passKeys:!0,passNode:!0});function l(e,t,i){if(e.type===`raw`&&i&&typeof t==`number`)return o?i.children.splice(t,1):i.children[t]={type:`text`,value:e.value},t;if(e.type===`element`){let t;for(t in hl)if(Object.hasOwn(hl,t)&&Object.hasOwn(e.properties,t)){let n=e.properties[t],r=hl[t];(r===null||r.includes(e.tagName))&&(e.properties[t]=c(String(n||``),t,e))}}if(e.type===`element`){let o=n?!n.includes(e.tagName):a?a.includes(e.tagName):!1;if(!o&&r&&typeof t==`number`&&(o=!r(e,t,i)),o&&i&&typeof t==`number`)return s&&e.children?i.children.splice(t,1,...e.children):i.children.splice(t,1),t}}}function Cm(e){let t=e.indexOf(`:`),n=e.indexOf(`?`),r=e.indexOf(`#`),i=e.indexOf(`/`);return t===-1||i!==-1&&t>i||n!==-1&&t>n||r!==-1&&t>r||_m.test(e.slice(0,t))?e:``}function wm(e,t){let n=String(e);if(typeof t!=`string`)throw TypeError(`Expected character`);let r=0,i=n.indexOf(t);for(;i!==-1;)r++,i=n.indexOf(t,i+t.length);return r}function Tm(e){if(typeof e!=`string`)throw TypeError(`Expected a string`);return e.replace(/[|\\{}()[\]^$+*?.]/g,`\\$&`).replace(/-/g,`\\x2d`)}function Em(e,t,n){let r=up((n||{}).ignore||[]),i=Dm(t),a=-1;for(;++a<i.length;)yp(e,`text`,o);function o(e,t){let n=-1,i;for(;++n<t.length;){let e=t[n],a=i?i.children:void 0;if(r(e,a?a.indexOf(e):void 0,i))return;i=e}if(i)return s(e,t)}function s(e,t){let n=t[t.length-1],r=i[a][0],o=i[a][1],s=0,c=n.children.indexOf(e),l=!1,u=[];r.lastIndex=0;let d=r.exec(e.value);for(;d;){let n=d.index,i={index:d.index,input:d.input,stack:[...t,e]},a=o(...d,i);if(typeof a==`string`&&(a=a.length>0?{type:`text`,value:a}:void 0),a===!1?r.lastIndex=n+1:(s!==n&&u.push({type:`text`,value:e.value.slice(s,n)}),Array.isArray(a)?u.push(...a):a&&u.push(a),s=n+d[0].length,l=!0),!r.global)break;d=r.exec(e.value)}return l?(s<e.value.length&&u.push({type:`text`,value:e.value.slice(s)}),n.children.splice(c,1,...u)):u=[e],c+u.length}}function Dm(e){let t=[];if(!Array.isArray(e))throw TypeError(`Expected find and replace tuple or list of tuples`);let n=!e[0]||Array.isArray(e[0])?e:[e],r=-1;for(;++r<n.length;){let e=n[r];t.push([Om(e[0]),km(e[1])])}return t}function Om(e){return typeof e==`string`?new RegExp(Tm(e),`g`):e}function km(e){return typeof e==`function`?e:function(){return e}}var Am=`phrasing`,jm=[`autolink`,`link`,`image`,`label`];function Mm(){return{transforms:[Bm],enter:{literalAutolink:Pm,literalAutolinkEmail:Fm,literalAutolinkHttp:Fm,literalAutolinkWww:Fm},exit:{literalAutolink:zm,literalAutolinkEmail:Rm,literalAutolinkHttp:Im,literalAutolinkWww:Lm}}}function Nm(){return{unsafe:[{character:`@`,before:`[+\\-.\\w]`,after:`[\\-.\\w]`,inConstruct:Am,notInConstruct:jm},{character:`.`,before:`[Ww]`,after:`[\\-.\\w]`,inConstruct:Am,notInConstruct:jm},{character:`:`,before:`[ps]`,after:`\\/`,inConstruct:Am,notInConstruct:jm}]}}function Pm(e){this.enter({type:`link`,title:null,url:``,children:[]},e)}function Fm(e){this.config.enter.autolinkProtocol.call(this,e)}function Im(e){this.config.exit.autolinkProtocol.call(this,e)}function Lm(e){this.config.exit.data.call(this,e);let t=this.stack[this.stack.length-1];t.type,t.url=`http://`+this.sliceSerialize(e)}function Rm(e){this.config.exit.autolinkEmail.call(this,e)}function zm(e){this.exit(e)}function Bm(e){Em(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,Vm],[/(?<=^|\s|\p{P}|\p{S})([-.\w+]+)@([-\w]+(?:\.[-\w]+)+)/gu,Hm]],{ignore:[`link`,`linkReference`]})}function Vm(e,t,n,r,i){let a=``;if(!Gm(i)||(/^w/i.test(t)&&(n=t+n,t=``,a=`http://`),!Um(n)))return!1;let o=Wm(n+r);if(!o[0])return!1;let s={type:`link`,title:null,url:a+t+o[0],children:[{type:`text`,value:t+o[0]}]};return o[1]?[s,{type:`text`,value:o[1]}]:s}function Hm(e,t,n,r){return!Gm(r,!0)||/[-\d_]$/.test(n)?!1:{type:`link`,title:null,url:`mailto:`+t+`@`+n,children:[{type:`text`,value:t+`@`+n}]}}function Um(e){let t=e.split(`.`);return!(t.length<2||t[t.length-1]&&(/_/.test(t[t.length-1])||!/[a-zA-Z\d]/.test(t[t.length-1]))||t[t.length-2]&&(/_/.test(t[t.length-2])||!/[a-zA-Z\d]/.test(t[t.length-2])))}function Wm(e){let t=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],r=n.indexOf(`)`),i=wm(e,`(`),a=wm(e,`)`);for(;r!==-1&&i>a;)e+=n.slice(0,r+1),n=n.slice(r+1),r=n.indexOf(`)`),a++;return[e,n]}function Gm(e,t){let n=e.input.charCodeAt(e.index-1);return(e.index===0||Bl(n)||zl(n))&&(!t||n!==47)}th.peek=eh;function Km(){this.buffer()}function qm(e){this.enter({type:`footnoteReference`,identifier:``,label:``},e)}function Jm(){this.buffer()}function Ym(e){this.enter({type:`footnoteDefinition`,identifier:``,label:``,children:[]},e)}function Xm(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=Al(this.sliceSerialize(e)).toLowerCase(),n.label=t}function Zm(e){this.exit(e)}function Qm(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=Al(this.sliceSerialize(e)).toLowerCase(),n.label=t}function $m(e){this.exit(e)}function eh(){return`[`}function th(e,t,n,r){let i=n.createTracker(r),a=i.move(`[^`),o=n.enter(`footnoteReference`),s=n.enter(`reference`);return a+=i.move(n.safe(n.associationId(e),{after:`]`,before:a})),s(),o(),a+=i.move(`]`),a}function nh(){return{enter:{gfmFootnoteCallString:Km,gfmFootnoteCall:qm,gfmFootnoteDefinitionLabelString:Jm,gfmFootnoteDefinition:Ym},exit:{gfmFootnoteCallString:Xm,gfmFootnoteCall:Zm,gfmFootnoteDefinitionLabelString:Qm,gfmFootnoteDefinition:$m}}}function rh(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:th},unsafe:[{character:`[`,inConstruct:[`label`,`phrasing`,`reference`]}]};function n(e,n,r,i){let a=r.createTracker(i),o=a.move(`[^`),s=r.enter(`footnoteDefinition`),c=r.enter(`label`);return o+=a.move(r.safe(r.associationId(e),{before:o,after:`]`})),c(),o+=a.move(`]:`),e.children&&e.children.length>0&&(a.shift(4),o+=a.move((t?`
|
|
24
|
+
`:` `)+r.indentLines(r.containerFlow(e,a.current()),t?ah:ih))),s(),o}}function ih(e,t,n){return t===0?e:ah(e,t,n)}function ah(e,t,n){return(n?``:` `)+e}var oh=[`autolink`,`destinationLiteral`,`destinationRaw`,`reference`,`titleQuote`,`titleApostrophe`];dh.peek=fh;function sh(){return{canContainEols:[`delete`],enter:{strikethrough:lh},exit:{strikethrough:uh}}}function ch(){return{unsafe:[{character:`~`,inConstruct:`phrasing`,notInConstruct:oh}],handlers:{delete:dh}}}function lh(e){this.enter({type:`delete`,children:[]},e)}function uh(e){this.exit(e)}function dh(e,t,n,r){let i=n.createTracker(r),a=n.enter(`strikethrough`),o=i.move(`~~`);return o+=n.containerPhrasing(e,{...i.current(),before:o,after:`~`}),o+=i.move(`~~`),a(),o}function fh(){return`~`}function ph(e){return e.length}function mh(e,t){let n=t||{},r=(n.align||[]).concat(),i=n.stringLength||ph,a=[],o=[],s=[],c=[],l=0,u=-1;for(;++u<e.length;){let t=[],r=[],a=-1;for(e[u].length>l&&(l=e[u].length);++a<e[u].length;){let o=hh(e[u][a]);if(n.alignDelimiters!==!1){let e=i(o);r[a]=e,(c[a]===void 0||e>c[a])&&(c[a]=e)}t.push(o)}o[u]=t,s[u]=r}let d=-1;if(typeof r==`object`&&`length`in r)for(;++d<l;)a[d]=gh(r[d]);else{let e=gh(r);for(;++d<l;)a[d]=e}d=-1;let f=[],p=[];for(;++d<l;){let e=a[d],t=``,r=``;e===99?(t=`:`,r=`:`):e===108?t=`:`:e===114&&(r=`:`);let i=n.alignDelimiters===!1?1:Math.max(1,c[d]-t.length-r.length),o=t+`-`.repeat(i)+r;n.alignDelimiters!==!1&&(i=t.length+i+r.length,i>c[d]&&(c[d]=i),p[d]=i),f[d]=o}o.splice(1,0,f),s.splice(1,0,p),u=-1;let m=[];for(;++u<o.length;){let e=o[u],t=s[u];d=-1;let r=[];for(;++d<l;){let i=e[d]||``,o=``,s=``;if(n.alignDelimiters!==!1){let e=c[d]-(t[d]||0),n=a[d];n===114?o=` `.repeat(e):n===99?e%2?(o=` `.repeat(e/2+.5),s=` `.repeat(e/2-.5)):(o=` `.repeat(e/2),s=o):s=` `.repeat(e)}n.delimiterStart!==!1&&!d&&r.push(`|`),n.padding!==!1&&!(n.alignDelimiters===!1&&i===``)&&(n.delimiterStart!==!1||d)&&r.push(` `),n.alignDelimiters!==!1&&r.push(o),r.push(i),n.alignDelimiters!==!1&&r.push(s),n.padding!==!1&&r.push(` `),(n.delimiterEnd!==!1||d!==l-1)&&r.push(`|`)}m.push(n.delimiterEnd===!1?r.join(``).replace(/ +$/,``):r.join(``))}return m.join(`
|
|
25
|
+
`)}function hh(e){return e==null?``:String(e)}function gh(e){let t=typeof e==`string`?e.codePointAt(0):0;return t===67||t===99?99:t===76||t===108?108:t===82||t===114?114:0}function _h(e,t,n,r){let i=n.enter(`blockquote`),a=n.createTracker(r);a.move(`> `),a.shift(2);let o=n.indentLines(n.containerFlow(e,a.current()),vh);return i(),o}function vh(e,t,n){return`>`+(n?``:` `)+e}function yh(e,t){return bh(e,t.inConstruct,!0)&&!bh(e,t.notInConstruct,!1)}function bh(e,t,n){if(typeof t==`string`&&(t=[t]),!t||t.length===0)return n;let r=-1;for(;++r<t.length;)if(e.includes(t[r]))return!0;return!1}function xh(e,t,n,r){let i=-1;for(;++i<n.unsafe.length;)if(n.unsafe[i].character===`
|
|
26
|
+
`&&yh(n.stack,n.unsafe[i]))return/[ \t]/.test(r.before)?``:` `;return`\\
|
|
27
|
+
`}function Sh(e,t){let n=String(e),r=n.indexOf(t),i=r,a=0,o=0;if(typeof t!=`string`)throw TypeError(`Expected substring`);for(;r!==-1;)r===i?++a>o&&(o=a):a=1,i=r+t.length,r=n.indexOf(t,i);return o}function Ch(e,t){return!!(t.options.fences===!1&&e.value&&!e.lang&&/[^ \r\n]/.test(e.value)&&!/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test(e.value))}function wh(e){let t=e.options.fence||"`";if(t!=="`"&&t!==`~`)throw Error("Cannot serialize code with `"+t+"` for `options.fence`, expected `` ` `` or `~`");return t}function Th(e,t,n,r){let i=wh(n),a=e.value||``,o=i==="`"?`GraveAccent`:`Tilde`;if(Ch(e,n)){let e=n.enter(`codeIndented`),t=n.indentLines(a,Eh);return e(),t}let s=n.createTracker(r),c=i.repeat(Math.max(Sh(a,i)+1,3)),l=n.enter(`codeFenced`),u=s.move(c);if(e.lang){let t=n.enter(`codeFencedLang${o}`);u+=s.move(n.safe(e.lang,{before:u,after:` `,encode:["`"],...s.current()})),t()}if(e.lang&&e.meta){let t=n.enter(`codeFencedMeta${o}`);u+=s.move(` `),u+=s.move(n.safe(e.meta,{before:u,after:`
|
|
28
|
+
`,encode:["`"],...s.current()})),t()}return u+=s.move(`
|
|
29
|
+
`),a&&(u+=s.move(a+`
|
|
30
|
+
`)),u+=s.move(c),l(),u}function Eh(e,t,n){return(n?``:` `)+e}function Dh(e){let t=e.options.quote||`"`;if(t!==`"`&&t!==`'`)throw Error("Cannot serialize title with `"+t+"` for `options.quote`, expected `\"`, or `'`");return t}function Oh(e,t,n,r){let i=Dh(n),a=i===`"`?`Quote`:`Apostrophe`,o=n.enter(`definition`),s=n.enter(`label`),c=n.createTracker(r),l=c.move(`[`);return l+=c.move(n.safe(n.associationId(e),{before:l,after:`]`,...c.current()})),l+=c.move(`]: `),s(),!e.url||/[\0- \u007F]/.test(e.url)?(s=n.enter(`destinationLiteral`),l+=c.move(`<`),l+=c.move(n.safe(e.url,{before:l,after:`>`,...c.current()})),l+=c.move(`>`)):(s=n.enter(`destinationRaw`),l+=c.move(n.safe(e.url,{before:l,after:e.title?` `:`
|
|
31
|
+
`,...c.current()}))),s(),e.title&&(s=n.enter(`title${a}`),l+=c.move(` `+i),l+=c.move(n.safe(e.title,{before:l,after:i,...c.current()})),l+=c.move(i),s()),o(),l}function kh(e){let t=e.options.emphasis||`*`;if(t!==`*`&&t!==`_`)throw Error("Cannot serialize emphasis with `"+t+"` for `options.emphasis`, expected `*`, or `_`");return t}function Ah(e){return`&#x`+e.toString(16).toUpperCase()+`;`}function jh(e,t,n){let r=Xl(e),i=Xl(t);return r===void 0?i===void 0?n===`_`?{inside:!0,outside:!0}:{inside:!1,outside:!1}:i===1?{inside:!0,outside:!0}:{inside:!1,outside:!0}:r===1?i===void 0?{inside:!1,outside:!1}:i===1?{inside:!0,outside:!0}:{inside:!1,outside:!1}:i===void 0?{inside:!1,outside:!1}:i===1?{inside:!0,outside:!1}:{inside:!1,outside:!1}}Mh.peek=Nh;function Mh(e,t,n,r){let i=kh(n),a=n.enter(`emphasis`),o=n.createTracker(r),s=o.move(i),c=o.move(n.containerPhrasing(e,{after:i,before:s,...o.current()})),l=c.charCodeAt(0),u=jh(r.before.charCodeAt(r.before.length-1),l,i);u.inside&&(c=Ah(l)+c.slice(1));let d=c.charCodeAt(c.length-1),f=jh(r.after.charCodeAt(0),d,i);f.inside&&(c=c.slice(0,-1)+Ah(d));let p=o.move(i);return a(),n.attentionEncodeSurroundingInfo={after:f.outside,before:u.outside},s+c+p}function Nh(e,t,n){return n.options.emphasis||`*`}function Ph(e,t){let n=!1;return xp(e,function(e){if(`value`in e&&/\r?\n|\r/.test(e.value)||e.type===`break`)return n=!0,!1}),!!((!e.depth||e.depth<3)&&_l(e)&&(t.options.setext||n))}function Fh(e,t,n,r){let i=Math.max(Math.min(6,e.depth||1),1),a=n.createTracker(r);if(Ph(e,n)){let t=n.enter(`headingSetext`),r=n.enter(`phrasing`),o=n.containerPhrasing(e,{...a.current(),before:`
|
|
32
|
+
`,after:`
|
|
33
|
+
`});return r(),t(),o+`
|
|
34
|
+
`+(i===1?`=`:`-`).repeat(o.length-(Math.max(o.lastIndexOf(`\r`),o.lastIndexOf(`
|
|
35
|
+
`))+1))}let o=`#`.repeat(i),s=n.enter(`headingAtx`),c=n.enter(`phrasing`);a.move(o+` `);let l=n.containerPhrasing(e,{before:`# `,after:`
|
|
36
|
+
`,...a.current()});return/^[\t ]/.test(l)&&(l=Ah(l.charCodeAt(0))+l.slice(1)),l=l?o+` `+l:o,n.options.closeAtx&&(l+=` `+o),c(),s(),l}Ih.peek=Lh;function Ih(e){return e.value||``}function Lh(){return`<`}Rh.peek=zh;function Rh(e,t,n,r){let i=Dh(n),a=i===`"`?`Quote`:`Apostrophe`,o=n.enter(`image`),s=n.enter(`label`),c=n.createTracker(r),l=c.move(`![`);return l+=c.move(n.safe(e.alt,{before:l,after:`]`,...c.current()})),l+=c.move(`](`),s(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(s=n.enter(`destinationLiteral`),l+=c.move(`<`),l+=c.move(n.safe(e.url,{before:l,after:`>`,...c.current()})),l+=c.move(`>`)):(s=n.enter(`destinationRaw`),l+=c.move(n.safe(e.url,{before:l,after:e.title?` `:`)`,...c.current()}))),s(),e.title&&(s=n.enter(`title${a}`),l+=c.move(` `+i),l+=c.move(n.safe(e.title,{before:l,after:i,...c.current()})),l+=c.move(i),s()),l+=c.move(`)`),o(),l}function zh(){return`!`}Bh.peek=Vh;function Bh(e,t,n,r){let i=e.referenceType,a=n.enter(`imageReference`),o=n.enter(`label`),s=n.createTracker(r),c=s.move(`![`),l=n.safe(e.alt,{before:c,after:`]`,...s.current()});c+=s.move(l+`][`),o();let u=n.stack;n.stack=[],o=n.enter(`reference`);let d=n.safe(n.associationId(e),{before:c,after:`]`,...s.current()});return o(),n.stack=u,a(),i===`full`||!l||l!==d?c+=s.move(d+`]`):i===`shortcut`?c=c.slice(0,-1):c+=s.move(`]`),c}function Vh(){return`!`}Hh.peek=Uh;function Hh(e,t,n){let r=e.value||``,i="`",a=-1;for(;RegExp("(^|[^`])"+i+"([^`]|$)").test(r);)i+="`";for(/[^ \r\n]/.test(r)&&(/^[ \r\n]/.test(r)&&/[ \r\n]$/.test(r)||/^`|`$/.test(r))&&(r=` `+r+` `);++a<n.unsafe.length;){let e=n.unsafe[a],t=n.compilePattern(e),i;if(e.atBreak)for(;i=t.exec(r);){let e=i.index;r.charCodeAt(e)===10&&r.charCodeAt(e-1)===13&&e--,r=r.slice(0,e)+` `+r.slice(i.index+1)}}return i+r+i}function Uh(){return"`"}function Wh(e,t){let n=_l(e);return!!(!t.options.resourceLink&&e.url&&!e.title&&e.children&&e.children.length===1&&e.children[0].type===`text`&&(n===e.url||`mailto:`+n===e.url)&&/^[a-z][a-z+.-]+:/i.test(e.url)&&!/[\0- <>\u007F]/.test(e.url))}Gh.peek=Kh;function Gh(e,t,n,r){let i=Dh(n),a=i===`"`?`Quote`:`Apostrophe`,o=n.createTracker(r),s,c;if(Wh(e,n)){let t=n.stack;n.stack=[],s=n.enter(`autolink`);let r=o.move(`<`);return r+=o.move(n.containerPhrasing(e,{before:r,after:`>`,...o.current()})),r+=o.move(`>`),s(),n.stack=t,r}s=n.enter(`link`),c=n.enter(`label`);let l=o.move(`[`);return l+=o.move(n.containerPhrasing(e,{before:l,after:`](`,...o.current()})),l+=o.move(`](`),c(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(c=n.enter(`destinationLiteral`),l+=o.move(`<`),l+=o.move(n.safe(e.url,{before:l,after:`>`,...o.current()})),l+=o.move(`>`)):(c=n.enter(`destinationRaw`),l+=o.move(n.safe(e.url,{before:l,after:e.title?` `:`)`,...o.current()}))),c(),e.title&&(c=n.enter(`title${a}`),l+=o.move(` `+i),l+=o.move(n.safe(e.title,{before:l,after:i,...o.current()})),l+=o.move(i),c()),l+=o.move(`)`),s(),l}function Kh(e,t,n){return Wh(e,n)?`<`:`[`}qh.peek=Jh;function qh(e,t,n,r){let i=e.referenceType,a=n.enter(`linkReference`),o=n.enter(`label`),s=n.createTracker(r),c=s.move(`[`),l=n.containerPhrasing(e,{before:c,after:`]`,...s.current()});c+=s.move(l+`][`),o();let u=n.stack;n.stack=[],o=n.enter(`reference`);let d=n.safe(n.associationId(e),{before:c,after:`]`,...s.current()});return o(),n.stack=u,a(),i===`full`||!l||l!==d?c+=s.move(d+`]`):i===`shortcut`?c=c.slice(0,-1):c+=s.move(`]`),c}function Jh(){return`[`}function Yh(e){let t=e.options.bullet||`*`;if(t!==`*`&&t!==`+`&&t!==`-`)throw Error("Cannot serialize items with `"+t+"` for `options.bullet`, expected `*`, `+`, or `-`");return t}function Xh(e){let t=Yh(e),n=e.options.bulletOther;if(!n)return t===`*`?`-`:`*`;if(n!==`*`&&n!==`+`&&n!==`-`)throw Error("Cannot serialize items with `"+n+"` for `options.bulletOther`, expected `*`, `+`, or `-`");if(n===t)throw Error("Expected `bullet` (`"+t+"`) and `bulletOther` (`"+n+"`) to be different");return n}function Zh(e){let t=e.options.bulletOrdered||`.`;if(t!==`.`&&t!==`)`)throw Error("Cannot serialize items with `"+t+"` for `options.bulletOrdered`, expected `.` or `)`");return t}function Qh(e){let t=e.options.rule||`*`;if(t!==`*`&&t!==`-`&&t!==`_`)throw Error("Cannot serialize rules with `"+t+"` for `options.rule`, expected `*`, `-`, or `_`");return t}function $h(e,t,n,r){let i=n.enter(`list`),a=n.bulletCurrent,o=e.ordered?Zh(n):Yh(n),s=e.ordered?o===`.`?`)`:`.`:Xh(n),c=t&&n.bulletLastUsed?o===n.bulletLastUsed:!1;if(!e.ordered){let t=e.children?e.children[0]:void 0;if((o===`*`||o===`-`)&&t&&(!t.children||!t.children[0])&&n.stack[n.stack.length-1]===`list`&&n.stack[n.stack.length-2]===`listItem`&&n.stack[n.stack.length-3]===`list`&&n.stack[n.stack.length-4]===`listItem`&&n.indexStack[n.indexStack.length-1]===0&&n.indexStack[n.indexStack.length-2]===0&&n.indexStack[n.indexStack.length-3]===0&&(c=!0),Qh(n)===o&&t){let t=-1;for(;++t<e.children.length;){let n=e.children[t];if(n&&n.type===`listItem`&&n.children&&n.children[0]&&n.children[0].type===`thematicBreak`){c=!0;break}}}}c&&(o=s),n.bulletCurrent=o;let l=n.containerFlow(e,r);return n.bulletLastUsed=o,n.bulletCurrent=a,i(),l}function eg(e){let t=e.options.listItemIndent||`one`;if(t!==`tab`&&t!==`one`&&t!==`mixed`)throw Error("Cannot serialize items with `"+t+"` for `options.listItemIndent`, expected `tab`, `one`, or `mixed`");return t}function tg(e,t,n,r){let i=eg(n),a=n.bulletCurrent||Yh(n);t&&t.type===`list`&&t.ordered&&(a=(typeof t.start==`number`&&t.start>-1?t.start:1)+(n.options.incrementListMarker===!1?0:t.children.indexOf(e))+a);let o=a.length+1;(i===`tab`||i===`mixed`&&(t&&t.type===`list`&&t.spread||e.spread))&&(o=Math.ceil(o/4)*4);let s=n.createTracker(r);s.move(a+` `.repeat(o-a.length)),s.shift(o);let c=n.enter(`listItem`),l=n.indentLines(n.containerFlow(e,s.current()),u);return c(),l;function u(e,t,n){return t?(n?``:` `.repeat(o))+e:(n?a:a+` `.repeat(o-a.length))+e}}function ng(e,t,n,r){let i=n.enter(`paragraph`),a=n.enter(`phrasing`),o=n.containerPhrasing(e,r);return a(),i(),o}var rg=up([`break`,`delete`,`emphasis`,`footnote`,`footnoteReference`,`image`,`imageReference`,`inlineCode`,`inlineMath`,`link`,`linkReference`,`mdxJsxTextElement`,`mdxTextExpression`,`strong`,`text`,`textDirective`]);function ig(e,t,n,r){return(e.children.some(function(e){return rg(e)})?n.containerPhrasing:n.containerFlow).call(n,e,r)}function ag(e){let t=e.options.strong||`*`;if(t!==`*`&&t!==`_`)throw Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}og.peek=sg;function og(e,t,n,r){let i=ag(n),a=n.enter(`strong`),o=n.createTracker(r),s=o.move(i+i),c=o.move(n.containerPhrasing(e,{after:i,before:s,...o.current()})),l=c.charCodeAt(0),u=jh(r.before.charCodeAt(r.before.length-1),l,i);u.inside&&(c=Ah(l)+c.slice(1));let d=c.charCodeAt(c.length-1),f=jh(r.after.charCodeAt(0),d,i);f.inside&&(c=c.slice(0,-1)+Ah(d));let p=o.move(i+i);return a(),n.attentionEncodeSurroundingInfo={after:f.outside,before:u.outside},s+c+p}function sg(e,t,n){return n.options.strong||`*`}function cg(e,t,n,r){return n.safe(e.value,r)}function lg(e){let t=e.options.ruleRepetition||3;if(t<3)throw Error("Cannot serialize rules with repetition `"+t+"` for `options.ruleRepetition`, expected `3` or more");return t}function ug(e,t,n){let r=(Qh(n)+(n.options.ruleSpaces?` `:``)).repeat(lg(n));return n.options.ruleSpaces?r.slice(0,-1):r}var dg={blockquote:_h,break:xh,code:Th,definition:Oh,emphasis:Mh,hardBreak:xh,heading:Fh,html:Ih,image:Rh,imageReference:Bh,inlineCode:Hh,link:Gh,linkReference:qh,list:$h,listItem:tg,paragraph:ng,root:ig,strong:og,text:cg,thematicBreak:ug};function fg(){return{enter:{table:pg,tableData:_g,tableHeader:_g,tableRow:hg},exit:{codeText:vg,table:mg,tableData:gg,tableHeader:gg,tableRow:gg}}}function pg(e){let t=e._align;this.enter({type:`table`,align:t.map(function(e){return e===`none`?null:e}),children:[]},e),this.data.inTable=!0}function mg(e){this.exit(e),this.data.inTable=void 0}function hg(e){this.enter({type:`tableRow`,children:[]},e)}function gg(e){this.exit(e)}function _g(e){this.enter({type:`tableCell`,children:[]},e)}function vg(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,yg));let n=this.stack[this.stack.length-1];n.type,n.value=t,this.exit(e)}function yg(e,t){return t===`|`?t:e}function bg(e){let t=e||{},n=t.tableCellPadding,r=t.tablePipeAlign,i=t.stringLength,a=n?` `:`|`;return{unsafe:[{character:`\r`,inConstruct:`tableCell`},{character:`
|
|
37
|
+
`,inConstruct:`tableCell`},{atBreak:!0,character:`|`,after:`[ :-]`},{character:`|`,inConstruct:`tableCell`},{atBreak:!0,character:`:`,after:`-`},{atBreak:!0,character:`-`,after:`[:|-]`}],handlers:{inlineCode:f,table:o,tableCell:c,tableRow:s}};function o(e,t,n,r){return l(u(e,n,r),e.align)}function s(e,t,n,r){let i=l([d(e,n,r)]);return i.slice(0,i.indexOf(`
|
|
38
|
+
`))}function c(e,t,n,r){let i=n.enter(`tableCell`),o=n.enter(`phrasing`),s=n.containerPhrasing(e,{...r,before:a,after:a});return o(),i(),s}function l(e,t){return mh(e,{align:t,alignDelimiters:r,padding:n,stringLength:i})}function u(e,t,n){let r=e.children,i=-1,a=[],o=t.enter(`table`);for(;++i<r.length;)a[i]=d(r[i],t,n);return o(),a}function d(e,t,n){let r=e.children,i=-1,a=[],o=t.enter(`tableRow`);for(;++i<r.length;)a[i]=c(r[i],e,t,n);return o(),a}function f(e,t,n){let r=dg.inlineCode(e,t,n);return n.stack.includes(`tableCell`)&&(r=r.replace(/\|/g,`\\$&`)),r}}function xg(){return{exit:{taskListCheckValueChecked:Cg,taskListCheckValueUnchecked:Cg,paragraph:wg}}}function Sg(){return{unsafe:[{atBreak:!0,character:`-`,after:`[:|-]`}],handlers:{listItem:Tg}}}function Cg(e){let t=this.stack[this.stack.length-2];t.type,t.checked=e.type===`taskListCheckValueChecked`}function wg(e){let t=this.stack[this.stack.length-2];if(t&&t.type===`listItem`&&typeof t.checked==`boolean`){let e=this.stack[this.stack.length-1];e.type;let n=e.children[0];if(n&&n.type===`text`){let r=t.children,i=-1,a;for(;++i<r.length;){let e=r[i];if(e.type===`paragraph`){a=e;break}}a===e&&(n.value=n.value.slice(1),n.value.length===0?e.children.shift():e.position&&n.position&&typeof n.position.start.offset==`number`&&(n.position.start.column++,n.position.start.offset++,e.position.start=Object.assign({},n.position.start)))}}this.exit(e)}function Tg(e,t,n,r){let i=e.children[0],a=typeof e.checked==`boolean`&&i&&i.type===`paragraph`,o=`[`+(e.checked?`x`:` `)+`] `,s=n.createTracker(r);a&&s.move(o);let c=dg.listItem(e,t,n,{...r,...s.current()});return a&&(c=c.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,l)),c;function l(e){return e+o}}function Eg(){return[Mm(),nh(),sh(),fg(),xg()]}function Dg(e){return{extensions:[Nm(),rh(e),ch(),bg(e),Sg()]}}var Og={tokenize:Hg,partial:!0},kg={tokenize:Ug,partial:!0},Ag={tokenize:Wg,partial:!0},jg={tokenize:Gg,partial:!0},Mg={tokenize:Kg,partial:!0},Ng={name:`wwwAutolink`,tokenize:Bg,previous:qg},Pg={name:`protocolAutolink`,tokenize:Vg,previous:Jg},Fg={name:`emailAutolink`,tokenize:zg,previous:Yg},Ig={};function Lg(){return{text:Ig}}for(var Rg=48;Rg<123;)Ig[Rg]=Fg,Rg++,Rg===58?Rg=65:Rg===91&&(Rg=97);Ig[43]=Fg,Ig[45]=Fg,Ig[46]=Fg,Ig[95]=Fg,Ig[72]=[Fg,Pg],Ig[104]=[Fg,Pg],Ig[87]=[Fg,Ng],Ig[119]=[Fg,Ng];function zg(e,t,n){let r=this,i,a;return o;function o(t){return!Xg(t)||!Yg.call(r,r.previous)||Zg(r.events)?n(t):(e.enter(`literalAutolink`),e.enter(`literalAutolinkEmail`),s(t))}function s(t){return Xg(t)?(e.consume(t),s):t===64?(e.consume(t),c):n(t)}function c(t){return t===46?e.check(Mg,u,l)(t):t===45||t===95||Ml(t)?(a=!0,e.consume(t),c):u(t)}function l(t){return e.consume(t),i=!0,c}function u(o){return a&&i&&jl(r.previous)?(e.exit(`literalAutolinkEmail`),e.exit(`literalAutolink`),t(o)):n(o)}}function Bg(e,t,n){let r=this;return i;function i(t){return t!==87&&t!==119||!qg.call(r,r.previous)||Zg(r.events)?n(t):(e.enter(`literalAutolink`),e.enter(`literalAutolinkWww`),e.check(Og,e.attempt(kg,e.attempt(Ag,a),n),n)(t))}function a(n){return e.exit(`literalAutolinkWww`),e.exit(`literalAutolink`),t(n)}}function Vg(e,t,n){let r=this,i=``,a=!1;return o;function o(t){return(t===72||t===104)&&Jg.call(r,r.previous)&&!Zg(r.events)?(e.enter(`literalAutolink`),e.enter(`literalAutolinkHttp`),i+=String.fromCodePoint(t),e.consume(t),s):n(t)}function s(t){if(jl(t)&&i.length<5)return i+=String.fromCodePoint(t),e.consume(t),s;if(t===58){let n=i.toLowerCase();if(n===`http`||n===`https`)return e.consume(t),c}return n(t)}function c(t){return t===47?(e.consume(t),a?l:(a=!0,c)):n(t)}function l(t){return t===null||Pl(t)||Rl(t)||Bl(t)||zl(t)?n(t):e.attempt(kg,e.attempt(Ag,u),n)(t)}function u(n){return e.exit(`literalAutolinkHttp`),e.exit(`literalAutolink`),t(n)}}function Hg(e,t,n){let r=0;return i;function i(t){return(t===87||t===119)&&r<3?(r++,e.consume(t),i):t===46&&r===3?(e.consume(t),a):n(t)}function a(e){return e===null?n(e):t(e)}}function Ug(e,t,n){let r,i,a;return o;function o(t){return t===46||t===95?e.check(jg,c,s)(t):t===null||Rl(t)||Bl(t)||t!==45&&zl(t)?c(t):(a=!0,e.consume(t),o)}function s(t){return t===95?r=!0:(i=r,r=void 0),e.consume(t),o}function c(e){return i||r||!a?n(e):t(e)}}function Wg(e,t){let n=0,r=0;return i;function i(o){return o===40?(n++,e.consume(o),i):o===41&&r<n?a(o):o===33||o===34||o===38||o===39||o===41||o===42||o===44||o===46||o===58||o===59||o===60||o===63||o===93||o===95||o===126?e.check(jg,t,a)(o):o===null||Rl(o)||Bl(o)?t(o):(e.consume(o),i)}function a(t){return t===41&&r++,e.consume(t),i}}function Gg(e,t,n){return r;function r(o){return o===33||o===34||o===39||o===41||o===42||o===44||o===46||o===58||o===59||o===63||o===95||o===126?(e.consume(o),r):o===38?(e.consume(o),a):o===93?(e.consume(o),i):o===60||o===null||Rl(o)||Bl(o)?t(o):n(o)}function i(e){return e===null||e===40||e===91||Rl(e)||Bl(e)?t(e):r(e)}function a(e){return jl(e)?o(e):n(e)}function o(t){return t===59?(e.consume(t),r):jl(t)?(e.consume(t),o):n(t)}}function Kg(e,t,n){return r;function r(t){return e.consume(t),i}function i(e){return Ml(e)?n(e):t(e)}}function qg(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||Rl(e)}function Jg(e){return!jl(e)}function Yg(e){return!(e===47||Xg(e))}function Xg(e){return e===43||e===45||e===46||e===95||Ml(e)}function Zg(e){let t=e.length,n=!1;for(;t--;){let r=e[t][1];if((r.type===`labelLink`||r.type===`labelImage`)&&!r._balanced){n=!0;break}if(r._gfmAutolinkLiteralWalkedInto){n=!1;break}}return e.length>0&&!n&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),n}var Qg={tokenize:o_,partial:!0};function $g(){return{document:{91:{name:`gfmFootnoteDefinition`,tokenize:r_,continuation:{tokenize:i_},exit:a_}},text:{91:{name:`gfmFootnoteCall`,tokenize:n_},93:{name:`gfmPotentialFootnoteCall`,add:`after`,tokenize:e_,resolveTo:t_}}}}function e_(e,t,n){let r=this,i=r.events.length,a=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]),o;for(;i--;){let e=r.events[i][1];if(e.type===`labelImage`){o=e;break}if(e.type===`gfmFootnoteCall`||e.type===`labelLink`||e.type===`label`||e.type===`image`||e.type===`link`)break}return s;function s(i){if(!o||!o._balanced)return n(i);let s=Al(r.sliceSerialize({start:o.end,end:r.now()}));return s.codePointAt(0)!==94||!a.includes(s.slice(1))?n(i):(e.enter(`gfmFootnoteCallLabelMarker`),e.consume(i),e.exit(`gfmFootnoteCallLabelMarker`),t(i))}}function t_(e,t){let n=e.length;for(;n--;)if(e[n][1].type===`labelImage`&&e[n][0]===`enter`){e[n][1];break}e[n+1][1].type=`data`,e[n+3][1].type=`gfmFootnoteCallLabelMarker`;let r={type:`gfmFootnoteCall`,start:Object.assign({},e[n+3][1].start),end:Object.assign({},e[e.length-1][1].end)},i={type:`gfmFootnoteCallMarker`,start:Object.assign({},e[n+3][1].end),end:Object.assign({},e[n+3][1].end)};i.end.column++,i.end.offset++,i.end._bufferIndex++;let a={type:`gfmFootnoteCallString`,start:Object.assign({},i.end),end:Object.assign({},e[e.length-1][1].start)},o={type:`chunkString`,contentType:`string`,start:Object.assign({},a.start),end:Object.assign({},a.end)},s=[e[n+1],e[n+2],[`enter`,r,t],e[n+3],e[n+4],[`enter`,i,t],[`exit`,i,t],[`enter`,a,t],[`enter`,o,t],[`exit`,o,t],[`exit`,a,t],e[e.length-2],e[e.length-1],[`exit`,r,t]];return e.splice(n,e.length-n+1,...s),e}function n_(e,t,n){let r=this,i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]),a=0,o;return s;function s(t){return e.enter(`gfmFootnoteCall`),e.enter(`gfmFootnoteCallLabelMarker`),e.consume(t),e.exit(`gfmFootnoteCallLabelMarker`),c}function c(t){return t===94?(e.enter(`gfmFootnoteCallMarker`),e.consume(t),e.exit(`gfmFootnoteCallMarker`),e.enter(`gfmFootnoteCallString`),e.enter(`chunkString`).contentType=`string`,l):n(t)}function l(s){if(a>999||s===93&&!o||s===null||s===91||Rl(s))return n(s);if(s===93){e.exit(`chunkString`);let a=e.exit(`gfmFootnoteCallString`);return i.includes(Al(r.sliceSerialize(a)))?(e.enter(`gfmFootnoteCallLabelMarker`),e.consume(s),e.exit(`gfmFootnoteCallLabelMarker`),e.exit(`gfmFootnoteCall`),t):n(s)}return Rl(s)||(o=!0),a++,e.consume(s),s===92?u:l}function u(t){return t===91||t===92||t===93?(e.consume(t),a++,l):l(t)}}function r_(e,t,n){let r=this,i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]),a,o=0,s;return c;function c(t){return e.enter(`gfmFootnoteDefinition`)._container=!0,e.enter(`gfmFootnoteDefinitionLabel`),e.enter(`gfmFootnoteDefinitionLabelMarker`),e.consume(t),e.exit(`gfmFootnoteDefinitionLabelMarker`),l}function l(t){return t===94?(e.enter(`gfmFootnoteDefinitionMarker`),e.consume(t),e.exit(`gfmFootnoteDefinitionMarker`),e.enter(`gfmFootnoteDefinitionLabelString`),e.enter(`chunkString`).contentType=`string`,u):n(t)}function u(t){if(o>999||t===93&&!s||t===null||t===91||Rl(t))return n(t);if(t===93){e.exit(`chunkString`);let n=e.exit(`gfmFootnoteDefinitionLabelString`);return a=Al(r.sliceSerialize(n)),e.enter(`gfmFootnoteDefinitionLabelMarker`),e.consume(t),e.exit(`gfmFootnoteDefinitionLabelMarker`),e.exit(`gfmFootnoteDefinitionLabel`),f}return Rl(t)||(s=!0),o++,e.consume(t),t===92?d:u}function d(t){return t===91||t===92||t===93?(e.consume(t),o++,u):u(t)}function f(t){return t===58?(e.enter(`definitionMarker`),e.consume(t),e.exit(`definitionMarker`),i.includes(a)||i.push(a),Ul(e,p,`gfmFootnoteDefinitionWhitespace`)):n(t)}function p(e){return t(e)}}function i_(e,t,n){return e.check(iu,t,e.attempt(Qg,t,n))}function a_(e){e.exit(`gfmFootnoteDefinition`)}function o_(e,t,n){let r=this;return Ul(e,i,`gfmFootnoteDefinitionIndent`,5);function i(e){let i=r.events[r.events.length-1];return i&&i[1].type===`gfmFootnoteDefinitionIndent`&&i[2].sliceSerialize(i[1],!0).length===4?t(e):n(e)}}function s_(e){let t=(e||{}).singleTilde,n={name:`strikethrough`,tokenize:i,resolveAll:r};return t??=!0,{text:{126:n},insideSpan:{null:[n]},attentionMarkers:{null:[126]}};function r(e,t){let n=-1;for(;++n<e.length;)if(e[n][0]===`enter`&&e[n][1].type===`strikethroughSequenceTemporary`&&e[n][1]._close){let r=n;for(;r--;)if(e[r][0]===`exit`&&e[r][1].type===`strikethroughSequenceTemporary`&&e[r][1]._open&&e[n][1].end.offset-e[n][1].start.offset===e[r][1].end.offset-e[r][1].start.offset){e[n][1].type=`strikethroughSequence`,e[r][1].type=`strikethroughSequence`;let i={type:`strikethrough`,start:Object.assign({},e[r][1].start),end:Object.assign({},e[n][1].end)},a={type:`strikethroughText`,start:Object.assign({},e[r][1].end),end:Object.assign({},e[n][1].start)},o=[[`enter`,i,t],[`enter`,e[r][1],t],[`exit`,e[r][1],t],[`enter`,a,t]],s=t.parser.constructs.insideSpan.null;s&&Cl(o,o.length,0,Zl(s,e.slice(r+1,n),t)),Cl(o,o.length,0,[[`exit`,a,t],[`enter`,e[n][1],t],[`exit`,e[n][1],t],[`exit`,i,t]]),Cl(e,r-1,n-r+3,o),n=r+o.length-2;break}}for(n=-1;++n<e.length;)e[n][1].type===`strikethroughSequenceTemporary`&&(e[n][1].type=`data`);return e}function i(e,n,r){let i=this.previous,a=this.events,o=0;return s;function s(t){return i===126&&a[a.length-1][1].type!==`characterEscape`?r(t):(e.enter(`strikethroughSequenceTemporary`),c(t))}function c(a){let s=Xl(i);if(a===126)return o>1?r(a):(e.consume(a),o++,c);if(o<2&&!t)return r(a);let l=e.exit(`strikethroughSequenceTemporary`),u=Xl(a);return l._open=!u||u===2&&!!s,l._close=!s||s===2&&!!u,n(a)}}}var c_=class{constructor(){this.map=[]}add(e,t,n){l_(this,e,t,n)}consume(e){if(this.map.sort(function(e,t){return e[0]-t[0]}),this.map.length===0)return;let t=this.map.length,n=[];for(;t>0;)--t,n.push(e.slice(this.map[t][0]+this.map[t][1]),this.map[t][2]),e.length=this.map[t][0];n.push(e.slice()),e.length=0;let r=n.pop();for(;r;){for(let t of r)e.push(t);r=n.pop()}this.map.length=0}};function l_(e,t,n,r){let i=0;if(!(n===0&&r.length===0)){for(;i<e.map.length;){if(e.map[i][0]===t){e.map[i][1]+=n,e.map[i][2].push(...r);return}i+=1}e.map.push([t,n,r])}}function u_(e,t){let n=!1,r=[];for(;t<e.length;){let i=e[t];if(n){if(i[0]===`enter`)i[1].type===`tableContent`&&r.push(e[t+1][1].type===`tableDelimiterMarker`?`left`:`none`);else if(i[1].type===`tableContent`){if(e[t-1][1].type===`tableDelimiterMarker`){let e=r.length-1;r[e]=r[e]===`left`?`center`:`right`}}else if(i[1].type===`tableDelimiterRow`)break}else i[0]===`enter`&&i[1].type===`tableDelimiterRow`&&(n=!0);t+=1}return r}function d_(){return{flow:{null:{name:`table`,tokenize:f_,resolveAll:p_}}}}function f_(e,t,n){let r=this,i=0,a=0,o;return s;function s(e){let t=r.events.length-1;for(;t>-1;){let e=r.events[t][1].type;if(e===`lineEnding`||e===`linePrefix`)t--;else break}let i=t>-1?r.events[t][1].type:null,a=i===`tableHead`||i===`tableRow`?S:c;return a===S&&r.parser.lazy[r.now().line]?n(e):a(e)}function c(t){return e.enter(`tableHead`),e.enter(`tableRow`),l(t)}function l(e){return e===124?u(e):(o=!0,a+=1,u(e))}function u(t){return t===null?n(t):Q(t)?a>1?(a=0,r.interrupt=!0,e.exit(`tableRow`),e.enter(`lineEnding`),e.consume(t),e.exit(`lineEnding`),p):n(t):$(t)?Ul(e,u,`whitespace`)(t):(a+=1,o&&(o=!1,i+=1),t===124?(e.enter(`tableCellDivider`),e.consume(t),e.exit(`tableCellDivider`),o=!0,u):(e.enter(`data`),d(t)))}function d(t){return t===null||t===124||Rl(t)?(e.exit(`data`),u(t)):(e.consume(t),t===92?f:d)}function f(t){return t===92||t===124?(e.consume(t),d):d(t)}function p(t){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(t):(e.enter(`tableDelimiterRow`),o=!1,$(t)?Ul(e,m,`linePrefix`,r.parser.constructs.disable.null.includes(`codeIndented`)?void 0:4)(t):m(t))}function m(t){return t===45||t===58?g(t):t===124?(o=!0,e.enter(`tableCellDivider`),e.consume(t),e.exit(`tableCellDivider`),h):x(t)}function h(t){return $(t)?Ul(e,g,`whitespace`)(t):g(t)}function g(t){return t===58?(a+=1,o=!0,e.enter(`tableDelimiterMarker`),e.consume(t),e.exit(`tableDelimiterMarker`),_):t===45?(a+=1,_(t)):t===null||Q(t)?b(t):x(t)}function _(t){return t===45?(e.enter(`tableDelimiterFiller`),v(t)):x(t)}function v(t){return t===45?(e.consume(t),v):t===58?(o=!0,e.exit(`tableDelimiterFiller`),e.enter(`tableDelimiterMarker`),e.consume(t),e.exit(`tableDelimiterMarker`),y):(e.exit(`tableDelimiterFiller`),y(t))}function y(t){return $(t)?Ul(e,b,`whitespace`)(t):b(t)}function b(n){return n===124?m(n):n===null||Q(n)?!o||i!==a?x(n):(e.exit(`tableDelimiterRow`),e.exit(`tableHead`),t(n)):x(n)}function x(e){return n(e)}function S(t){return e.enter(`tableRow`),C(t)}function C(n){return n===124?(e.enter(`tableCellDivider`),e.consume(n),e.exit(`tableCellDivider`),C):n===null||Q(n)?(e.exit(`tableRow`),t(n)):$(n)?Ul(e,C,`whitespace`)(n):(e.enter(`data`),w(n))}function w(t){return t===null||t===124||Rl(t)?(e.exit(`data`),C(t)):(e.consume(t),t===92?T:w)}function T(t){return t===92||t===124?(e.consume(t),w):w(t)}}function p_(e,t){let n=-1,r=!0,i=0,a=[0,0,0,0],o=[0,0,0,0],s=!1,c=0,l,u,d,f=new c_;for(;++n<e.length;){let p=e[n],m=p[1];p[0]===`enter`?m.type===`tableHead`?(s=!1,c!==0&&(h_(f,t,c,l,u),u=void 0,c=0),l={type:`table`,start:Object.assign({},m.start),end:Object.assign({},m.end)},f.add(n,0,[[`enter`,l,t]])):m.type===`tableRow`||m.type===`tableDelimiterRow`?(r=!0,d=void 0,a=[0,0,0,0],o=[0,n+1,0,0],s&&(s=!1,u={type:`tableBody`,start:Object.assign({},m.start),end:Object.assign({},m.end)},f.add(n,0,[[`enter`,u,t]])),i=m.type===`tableDelimiterRow`?2:u?3:1):i&&(m.type===`data`||m.type===`tableDelimiterMarker`||m.type===`tableDelimiterFiller`)?(r=!1,o[2]===0&&(a[1]!==0&&(o[0]=o[1],d=m_(f,t,a,i,void 0,d),a=[0,0,0,0]),o[2]=n)):m.type===`tableCellDivider`&&(r?r=!1:(a[1]!==0&&(o[0]=o[1],d=m_(f,t,a,i,void 0,d)),a=o,o=[a[1],n,0,0])):m.type===`tableHead`?(s=!0,c=n):m.type===`tableRow`||m.type===`tableDelimiterRow`?(c=n,a[1]===0?o[1]!==0&&(d=m_(f,t,o,i,n,d)):(o[0]=o[1],d=m_(f,t,a,i,n,d)),i=0):i&&(m.type===`data`||m.type===`tableDelimiterMarker`||m.type===`tableDelimiterFiller`)&&(o[3]=n)}for(c!==0&&h_(f,t,c,l,u),f.consume(t.events),n=-1;++n<t.events.length;){let e=t.events[n];e[0]===`enter`&&e[1].type===`table`&&(e[1]._align=u_(t.events,n))}return e}function m_(e,t,n,r,i,a){let o=r===1?`tableHeader`:r===2?`tableDelimiter`:`tableData`;n[0]!==0&&(a.end=Object.assign({},g_(t.events,n[0])),e.add(n[0],0,[[`exit`,a,t]]));let s=g_(t.events,n[1]);if(a={type:o,start:Object.assign({},s),end:Object.assign({},s)},e.add(n[1],0,[[`enter`,a,t]]),n[2]!==0){let i=g_(t.events,n[2]),a=g_(t.events,n[3]),o={type:`tableContent`,start:Object.assign({},i),end:Object.assign({},a)};if(e.add(n[2],0,[[`enter`,o,t]]),r!==2){let r=t.events[n[2]],i=t.events[n[3]];if(r[1].end=Object.assign({},i[1].end),r[1].type=`chunkText`,r[1].contentType=`text`,n[3]>n[2]+1){let t=n[2]+1,r=n[3]-n[2]-1;e.add(t,r,[])}}e.add(n[3]+1,0,[[`exit`,o,t]])}return i!==void 0&&(a.end=Object.assign({},g_(t.events,i)),e.add(i,0,[[`exit`,a,t]]),a=void 0),a}function h_(e,t,n,r,i){let a=[],o=g_(t.events,n);i&&(i.end=Object.assign({},o),a.push([`exit`,i,t])),r.end=Object.assign({},o),a.push([`exit`,r,t]),e.add(n+1,0,a)}function g_(e,t){let n=e[t],r=n[0]===`enter`?`start`:`end`;return n[1][r]}var __={name:`tasklistCheck`,tokenize:y_};function v_(){return{text:{91:__}}}function y_(e,t,n){let r=this;return i;function i(t){return r.previous!==null||!r._gfmTasklistFirstContentOfListItem?n(t):(e.enter(`taskListCheck`),e.enter(`taskListCheckMarker`),e.consume(t),e.exit(`taskListCheckMarker`),a)}function a(t){return Rl(t)?(e.enter(`taskListCheckValueUnchecked`),e.consume(t),e.exit(`taskListCheckValueUnchecked`),o):t===88||t===120?(e.enter(`taskListCheckValueChecked`),e.consume(t),e.exit(`taskListCheckValueChecked`),o):n(t)}function o(t){return t===93?(e.enter(`taskListCheckMarker`),e.consume(t),e.exit(`taskListCheckMarker`),e.exit(`taskListCheck`),s):n(t)}function s(r){return Q(r)?t(r):$(r)?e.check({tokenize:b_},t,n)(r):n(r)}}function b_(e,t,n){return Ul(e,r,`whitespace`);function r(e){return e===null?n(e):t(e)}}function x_(e){return El([Lg(),$g(),s_(e),d_(),v_()])}var S_={};function C_(e){let t=this,n=e||S_,r=t.data(),i=r.micromarkExtensions||=[],a=r.fromMarkdownExtensions||=[],o=r.toMarkdownExtensions||=[];i.push(x_(n)),a.push(Eg()),o.push(Dg(n))}var w_=[C_],T_=({content:e})=>(0,K.jsx)(`div`,{className:`prose prose-sm max-w-none text-foreground prose-a:text-primary prose-code:text-foreground prose-headings:text-foreground prose-pre:border prose-pre:border-border prose-pre:bg-muted/50 prose-strong:text-foreground prose-li:marker:text-muted-foreground`,children:(0,K.jsx)(ym,{remarkPlugins:w_,children:e})}),E_=G.createContext(!1),D_=G.createContext(void 0);function O_(e){let t=G.useContext(D_);if(e===!1&&t===void 0)throw Error(d(27));return t}var k_={...rt,...De},A_=G.forwardRef(function(e,t){let{render:n,className:r,style:i,forceRender:a=!1,...o}=e,{store:c}=O_(),l=c.useState(`open`),u=c.useState(`nested`),d=c.useState(`mounted`);return s(`div`,e,{state:{open:l,transitionStatus:c.useState(`transitionStatus`)},ref:[c.context.backdropRef,t],stateAttributesMapping:k_,props:[{role:`presentation`,hidden:!d,style:{userSelect:`none`,WebkitUserSelect:`none`}},o],enabled:a||!u})}),j_=G.forwardRef(function(e,t){let{render:n,className:r,style:i,disabled:a=!1,nativeButton:o=!0,...c}=e,{store:l}=O_(),u=l.useState(`open`),{getButtonProps:d,buttonRef:f}=et({disabled:a,native:o}),p={disabled:a};function m(e){u&&l.setOpen(!1,_(y,e.nativeEvent))}return s(`button`,e,{state:p,ref:[t,f],props:[{onClick:m},c,d]})}),M_=G.forwardRef(function(e,t){let{render:n,className:r,style:i,id:a,...o}=e,{store:c}=O_(),l=Ie(a);return c.useSyncedValueWithCleanup(`descriptionElementId`,l),s(`p`,e,{ref:t,props:[{id:l},o]})}),N_=function(e){return e.nestedDialogs=`--nested-dialogs`,e}({}),P_=function(e){return e[e.open=R.open]=`open`,e[e.closed=R.closed]=`closed`,e[e.startingStyle=R.startingStyle]=`startingStyle`,e[e.endingStyle=R.endingStyle]=`endingStyle`,e.nested=`data-nested`,e.nestedDialogOpen=`data-nested-dialog-open`,e}({}),F_=G.createContext(void 0);function I_(){let e=G.useContext(F_);if(e===void 0)throw Error(d(26));return e}var L_={...rt,...De,nestedDialogOpen(e){return e?{[P_.nestedDialogOpen]:``}:null}},R_=G.forwardRef(function(e,t){let{render:n,className:r,style:i,finalFocus:a,initialFocus:o,...c}=e,{store:l}=O_(),u=l.useState(`descriptionElementId`),d=l.useState(`disablePointerDismissal`),f=l.useState(`floatingRootContext`),p=l.useState(`popupProps`),m=l.useState(`modal`),h=l.useState(`mounted`),g=l.useState(`nested`),_=l.useState(`nestedOpenDialogCount`),v=l.useState(`open`),y=l.useState(`openMethod`),b=l.useState(`titleElementId`),x=l.useState(`transitionStatus`),S=l.useState(`role`),C=f.useState(`floatingId`),w=c.id??C;I_(),ee({open:v,ref:l.context.popupRef,onComplete(){v&&l.context.onOpenChangeComplete?.(!0)}});let T=o===void 0?Ue(l.context.popupRef):o,E=_>0,D=l.useStateSetter(`popupElement`),O=s(`div`,e,{state:{open:v,nested:g,transitionStatus:x,nestedDialogOpen:E},props:[p,{id:w,"aria-labelledby":b??void 0,"aria-describedby":u??void 0,role:S,...Ge,hidden:!h,onKeyDown(e){vt.has(e.key)&&e.stopPropagation()},style:{[N_.nestedDialogs]:_}},c],ref:[t,l.context.popupRef,D],stateAttributesMapping:L_});return(0,K.jsx)(Ee,{context:f,openInteractionType:y,disabled:!h,closeOnFocusOut:!d,initialFocus:T,returnFocus:a,modal:m!==!1,restoreFocus:`popup`,children:O})}),z_=G.forwardRef(function(e,t){let{keepMounted:n=!1,...r}=e,{store:i}=O_(),a=i.useState(`mounted`),o=i.useState(`modal`),s=i.useState(`open`);return a||n?(0,K.jsx)(F_.Provider,{value:n,children:(0,K.jsxs)(He,{ref:t,...r,children:[a&&o===!0&&(0,K.jsx)(Pe,{ref:i.context.internalBackdropRef,inert:tt(!s)}),e.children]})}):null});function B_(e){let{store:t,actionsRef:n}=e,r=t.useState(`open`);B(t,r),ne(t);let{forceUnmount:i}=E(r,t),a=G.useCallback(()=>{t.setOpen(!1,_(ce))},[t]);G.useImperativeHandle(n,()=>({unmount:i,close:a}),[i,a])}function V_({store:e,parentContext:t,isDrawer:r}){let i=e.useState(`open`),a=e.useState(`disablePointerDismissal`),o=e.useState(`modal`),s=e.useState(`popupElement`),c=e.useState(`floatingRootContext`),[l,u]=G.useState(0),[d,f]=G.useState(0),p=l===0,m=xe(c,{outsidePressEvent(){return e.context.internalBackdropRef.current||e.context.backdropRef.current?`intentional`:{mouse:o===`trap-focus`?`sloppy`:`intentional`,touch:`sloppy`}},outsidePress(t){if(!e.context.outsidePressEnabledRef.current||`button`in t&&t.button!==0||`touches`in t&&t.touches.length!==1)return!1;let n=V(t);return p&&!a?o&&(e.context.internalBackdropRef.current||e.context.backdropRef.current)?e.context.internalBackdropRef.current===n||e.context.backdropRef.current===n||F(n,s)&&!n?.hasAttribute(`data-base-ui-portal`):!0:!1},escapeKey:p});return ft(i&&o===!0,s),e.useContextCallback(`onNestedDialogOpen`,(e,t)=>{u(e),f(t)}),e.useContextCallback(`onNestedDialogClose`,()=>{u(0),f(0)}),G.useEffect(()=>(t?.onNestedDialogOpen&&i&&t.onNestedDialogOpen(l+1,d+ +!!r),t?.onNestedDialogClose&&!i&&t.onNestedDialogClose(),()=>{t?.onNestedDialogClose&&i&&t.onNestedDialogClose()}),[r,i,l,d,t]),N(e,{activeTriggerProps:m.reference??n,inactiveTriggerProps:m.trigger??n,popupProps:m.floating??n,nestedOpenDialogCount:l,nestedOpenDrawerCount:d}),null}var H_={...Nt,modal:I(e=>e.modal),nested:I(e=>e.nested),nestedOpenDialogCount:I(e=>e.nestedOpenDialogCount),nestedOpenDrawerCount:I(e=>e.nestedOpenDrawerCount),disablePointerDismissal:I(e=>e.disablePointerDismissal),openMethod:I(e=>e.openMethod),descriptionElementId:I(e=>e.descriptionElementId),titleElementId:I(e=>e.titleElementId),viewportElement:I(e=>e.viewportElement),role:I(e=>e.role)},U_=class e extends A{constructor(e,t,n=!1){let r=new ie,i=W_(e);i.floatingRootContext=At(r,t,n),super(i,{popupRef:G.createRef(),backdropRef:G.createRef(),internalBackdropRef:G.createRef(),outsidePressEnabledRef:{current:!0},triggerElements:r,onOpenChange:void 0,onOpenChangeComplete:void 0},H_)}setOpen=(e,t)=>{if(t.preventUnmountOnClose=()=>{this.set(`preventUnmountingOnClose`,!0)},!e&&t.trigger==null&&this.state.activeTriggerId!=null&&(t.trigger=this.state.activeTriggerElement??void 0),this.context.onOpenChange?.(e,t),t.isCanceled)return;this.state.floatingRootContext.dispatchOpenChange(e,t);let n={open:e};H(n,e,t.trigger),this.update(n)};static useStore(t,n){return pe(t,(t,r)=>new e(n,t,r),!0).store}};function W_(e={}){return{...Ft(),modal:!0,disablePointerDismissal:!1,popupElement:null,viewportElement:null,descriptionElementId:void 0,titleElementId:void 0,openMethod:null,nested:!1,nestedOpenDialogCount:0,nestedOpenDrawerCount:0,role:`dialog`,...e}}function G_(e,t=`dialog`){let{children:n,open:r,defaultOpen:i=!1,onOpenChange:a,onOpenChangeComplete:o,disablePointerDismissal:s=!1,modal:c=!0,actionsRef:l,handle:u,triggerId:d,defaultTriggerId:f=null}=e,p=t===`drawer`,m=t===`alert-dialog`,h=m?!0:c,g=m||s,_=m?`alertdialog`:`dialog`,v=O_(!0),y={modal:h,disablePointerDismissal:g,nested:!!v,role:_},b=U_.useStore(u?.store,{open:i,openProp:r,activeTriggerId:f,triggerIdProp:d,...y});Ce(()=>{let e=r===void 0&&b.state.open===!1&&i===!0?{open:!0,activeTriggerId:f}:null;m?b.update(e?{...y,...e}:y):e&&b.update(e)}),b.useControlledProp(`openProp`,r),b.useControlledProp(`triggerIdProp`,d),b.useSyncedValues(y),b.useContextCallback(`onOpenChange`,a),b.useContextCallback(`onOpenChangeComplete`,o);let x=b.useState(`open`),S=b.useState(`mounted`),C=b.useState(`payload`);B_({store:b,actionsRef:l});let w=x||S,T=G.useMemo(()=>({store:b}),[b]);return(0,K.jsx)(E_.Provider,{value:!1,children:(0,K.jsxs)(D_.Provider,{value:T,children:[w&&(0,K.jsx)(V_,{store:b,parentContext:v?.store.context,isDrawer:p}),typeof n==`function`?n({payload:C}):n]})})}function K_(e){return G_(e,G.useContext(E_)?`drawer`:`dialog`)}var q_=function(e){return e[e.open=R.open]=`open`,e[e.closed=R.closed]=`closed`,e[e.startingStyle=R.startingStyle]=`startingStyle`,e[e.endingStyle=R.endingStyle]=`endingStyle`,e.nested=`data-nested`,e.nestedDialogOpen=`data-nested-dialog-open`,e}({}),J_={...rt,...De,nested(e){return e?{[q_.nested]:``}:null},nestedDialogOpen(e){return e?{[q_.nestedDialogOpen]:``}:null}},Y_=G.forwardRef(function(e,t){let{render:n,className:r,style:i,children:a,...o}=e,c=I_(),{store:l}=O_(),u=l.useState(`open`),d=l.useState(`nested`),f=l.useState(`transitionStatus`),p=l.useState(`nestedOpenDialogCount`),m=l.useState(`mounted`),h=l.useStateSetter(`viewportElement`);return s(`div`,e,{enabled:c||m,state:{open:u,nested:d,transitionStatus:f,nestedDialogOpen:p>0},ref:[t,h],stateAttributesMapping:J_,props:[{role:`presentation`,hidden:!m,style:{pointerEvents:u?void 0:`none`},children:a},o]})}),X_=G.forwardRef(function(e,t){let{render:n,className:r,style:i,id:a,...o}=e,{store:c}=O_(),l=Ie(a);return c.useSyncedValueWithCleanup(`titleElementId`,l),s(`h2`,e,{ref:t,props:[{id:l},o]})}),Z_=class{constructor(e){this.store=e??new U_}open(e){let t=e?this.store.context.triggerElements.getById(e):void 0;this.store.setOpen(!0,_(ce,void 0,t))}openWithPayload(e){this.store.set(`payload`,e),this.store.setOpen(!0,_(ce,void 0,void 0))}close(){this.store.setOpen(!1,_(ce,void 0,void 0))}get isOpen(){return this.store.select(`open`)}},Q_=G.createContext(void 0);function $_(){let e=G.useContext(Q_);if(e===void 0)throw Error(d(53));return e}var ev=function(e){return e.scrollAreaCornerHeight=`--scroll-area-corner-height`,e.scrollAreaCornerWidth=`--scroll-area-corner-width`,e}({});function tv(e,t,n){if(!e)return 0;let r=getComputedStyle(e),i=n===`x`?`Inline`:`Block`;return n===`x`&&t===`margin`?parseFloat(r[`${t}InlineStart`])*2:parseFloat(r[`${t}${i}Start`])+parseFloat(r[`${t}${i}End`])}var nv=function(e){return e.orientation=`data-orientation`,e.hovering=`data-hovering`,e.scrolling=`data-scrolling`,e.hasOverflowX=`data-has-overflow-x`,e.hasOverflowY=`data-has-overflow-y`,e.overflowXStart=`data-overflow-x-start`,e.overflowXEnd=`data-overflow-x-end`,e.overflowYStart=`data-overflow-y-start`,e.overflowYEnd=`data-overflow-y-end`,e}({}),rv=function(e){return e.scrolling=`data-scrolling`,e.hasOverflowX=`data-has-overflow-x`,e.hasOverflowY=`data-has-overflow-y`,e.overflowXStart=`data-overflow-x-start`,e.overflowXEnd=`data-overflow-x-end`,e.overflowYStart=`data-overflow-y-start`,e.overflowYEnd=`data-overflow-y-end`,e}({}),iv={hasOverflowX:e=>e?{[rv.hasOverflowX]:``}:null,hasOverflowY:e=>e?{[rv.hasOverflowY]:``}:null,overflowXStart:e=>e?{[rv.overflowXStart]:``}:null,overflowXEnd:e=>e?{[rv.overflowXEnd]:``}:null,overflowYStart:e=>e?{[rv.overflowYStart]:``}:null,overflowYEnd:e=>e?{[rv.overflowYEnd]:``}:null,cornerHidden:()=>null},av={x:0,y:0},ov={width:0,height:0},sv={xStart:!1,xEnd:!1,yStart:!1,yEnd:!1},cv={x:!0,y:!0,corner:!0},lv=G.forwardRef(function(e,t){let{render:n,className:r,overflowEdgeThreshold:i,style:a,...o}=e,{xStart:c,xEnd:l,yStart:u,yEnd:d}=uv(i),f=Ie(),p=it(),m=it(),{nonce:h,disableStyleElements:g}=lt(),[_,v]=G.useState(!1),[y,b]=G.useState(!1),[x,S]=G.useState(!1),[C,w]=G.useState(!1),[T,E]=G.useState(!1),[D,O]=G.useState(ov),[k,A]=G.useState(ov),[j,M]=G.useState(sv),[N,P]=G.useState(cv),I=G.useRef(null),L=G.useRef(null),ee=G.useRef(null),te=G.useRef(null),R=G.useRef(null),z=G.useRef(null),B=G.useRef(null),V=G.useRef(!1),H=G.useRef(0),ne=G.useRef(0),re=G.useRef(0),U=G.useRef(0),ie=G.useRef(`vertical`),ae=G.useRef(av),oe=pt(e=>{let t=e.x-ae.current.x,n=e.y-ae.current.y;ae.current=e,n!==0&&(S(!0),p.start(500,()=>{S(!1)})),t!==0&&(b(!0),m.start(500,()=>{b(!1)}))}),se=pt(e=>{e.button===0&&(V.current=!0,H.current=e.clientY,ne.current=e.clientX,ie.current=e.currentTarget.getAttribute(nv.orientation),L.current&&(re.current=L.current.scrollTop,U.current=L.current.scrollLeft),R.current&&ie.current===`vertical`&&R.current.setPointerCapture(e.pointerId),z.current&&ie.current===`horizontal`&&z.current.setPointerCapture(e.pointerId))}),ce=pt(e=>{if(!V.current)return;let t=e.clientY-H.current,n=e.clientX-ne.current;if(L.current){let r=L.current.scrollHeight,i=L.current.clientHeight,a=L.current.scrollWidth,o=L.current.clientWidth;if(R.current&&ee.current&&ie.current===`vertical`){let n=tv(ee.current,`padding`,`y`),a=tv(R.current,`margin`,`y`),o=R.current.offsetHeight,s=t/(ee.current.offsetHeight-o-n-a);L.current.scrollTop=re.current+s*(r-i),e.preventDefault(),S(!0),p.start(500,()=>{S(!1)})}if(z.current&&te.current&&ie.current===`horizontal`){let t=tv(te.current,`padding`,`x`),r=tv(z.current,`margin`,`x`),i=z.current.offsetWidth,s=n/(te.current.offsetWidth-i-t-r);L.current.scrollLeft=U.current+s*(a-o),e.preventDefault(),b(!0),m.start(500,()=>{b(!1)})}}}),le=pt(e=>{V.current=!1,R.current&&ie.current===`vertical`&&R.current.hasPointerCapture(e.pointerId)&&R.current.releasePointerCapture(e.pointerId),z.current&&ie.current===`horizontal`&&z.current.hasPointerCapture(e.pointerId)&&z.current.releasePointerCapture(e.pointerId)});function ue(e){w(e.pointerType===`touch`)}function de(e){if(ue(e),e.pointerType!==`touch`){let t=F(I.current,e.target);v(t)}}let fe=G.useMemo(()=>({scrolling:y||x,hasOverflowX:!N.x,hasOverflowY:!N.y,overflowXStart:j.xStart,overflowXEnd:j.xEnd,overflowYStart:j.yStart,overflowYEnd:j.yEnd,cornerHidden:N.corner}),[y,x,N.x,N.y,N.corner,j]),pe={role:`presentation`,onPointerEnter:de,onPointerMove:de,onPointerDown:ue,onPointerLeave(){v(!1)},style:{position:`relative`,[ev.scrollAreaCornerHeight]:`${D.height}px`,[ev.scrollAreaCornerWidth]:`${D.width}px`}},me=s(`div`,e,{state:fe,ref:[t,I],props:[pe,o],stateAttributesMapping:iv}),he=G.useMemo(()=>({handlePointerDown:se,handlePointerMove:ce,handlePointerUp:le,handleScroll:oe,cornerSize:D,setCornerSize:O,thumbSize:k,setThumbSize:A,hasMeasuredScrollbar:T,setHasMeasuredScrollbar:E,touchModality:C,cornerRef:B,scrollingX:y,setScrollingX:b,scrollingY:x,setScrollingY:S,hovering:_,setHovering:v,viewportRef:L,rootRef:I,scrollbarYRef:ee,scrollbarXRef:te,thumbYRef:R,thumbXRef:z,rootId:f,hiddenState:N,setHiddenState:P,overflowEdges:j,setOverflowEdges:M,viewportState:fe,overflowEdgeThreshold:{xStart:c,xEnd:l,yStart:u,yEnd:d}}),[se,ce,le,oe,D,k,T,C,y,b,x,S,_,v,f,N,j,fe,c,l,u,d]);return(0,K.jsxs)(Q_.Provider,{value:he,children:[!g&&sn.getElement(h),me]})});function uv(e){if(typeof e==`number`){let t=Math.max(0,e);return{xStart:t,xEnd:t,yStart:t,yEnd:t}}return{xStart:Math.max(0,e?.xStart||0),xEnd:Math.max(0,e?.xEnd||0),yStart:Math.max(0,e?.yStart||0),yEnd:Math.max(0,e?.yEnd||0)}}var dv=G.createContext(void 0),fv=function(e){return e.scrollAreaOverflowXStart=`--scroll-area-overflow-x-start`,e.scrollAreaOverflowXEnd=`--scroll-area-overflow-x-end`,e.scrollAreaOverflowYStart=`--scroll-area-overflow-y-start`,e.scrollAreaOverflowYEnd=`--scroll-area-overflow-y-end`,e}({}),pv=!1;function mv(){pv||at||(typeof CSS<`u`&&`registerProperty`in CSS&&[fv.scrollAreaOverflowXStart,fv.scrollAreaOverflowXEnd,fv.scrollAreaOverflowYStart,fv.scrollAreaOverflowYEnd].forEach(e=>{try{CSS.registerProperty({name:e,syntax:`<length>`,inherits:!1,initialValue:`0px`})}catch{}}),pv=!0)}var hv=G.forwardRef(function(e,t){let{render:n,className:r,style:i,...a}=e,{viewportRef:o,scrollbarYRef:c,scrollbarXRef:l,thumbYRef:u,thumbXRef:d,cornerRef:f,cornerSize:p,setCornerSize:m,setThumbSize:h,rootId:g,setHiddenState:_,hiddenState:v,setHasMeasuredScrollbar:y,handleScroll:b,setHovering:x,setOverflowEdges:S,overflowEdges:C,overflowEdgeThreshold:w,scrollingX:T,scrollingY:E}=$_(),D=Re(),O=G.useRef(!0),k=G.useRef([NaN,NaN,NaN,NaN]),A=it(),j=it(),M=pt(()=>{let e=o.current,t=c.current,n=l.current,r=u.current,i=d.current,a=f.current;if(!e)return;let s=e.scrollHeight,g=e.scrollWidth,v=e.clientHeight,b=e.clientWidth,x=e.scrollTop,C=e.scrollLeft,T=k.current,E=Number.isNaN(T[0]);if(T[0]=v,T[1]=s,T[2]=b,T[3]=g,E&&y(!0),s===0||g===0)return;let O=gv(e),A=O.y,j=O.x,M=b/g,N=v/s,P=Math.max(0,g-b),F=Math.max(0,s-v),I=0,L=0;if(!j){let e=0;e=rn(D===`rtl`?-C:C,0,P),I=on(e,P),L=P-I}let ee=A?0:rn(x,0,F),te=A?0:on(ee,F),R=A?0:F-te,z=j?0:b,B=A?0:v,V=0,H=0;!j&&!A&&(V=t?.offsetWidth||0,H=n?.offsetHeight||0);let ne=p.width===0&&p.height===0,re=ne?V:0,U=ne?H:0,ie=tv(n,`padding`,`x`),ae=tv(t,`padding`,`y`),oe=tv(i,`margin`,`x`),se=tv(r,`margin`,`y`),ce=z-ie-oe,le=B-ae-se,ue=n?Math.min(n.offsetWidth-re,ce):ce,de=t?Math.min(t.offsetHeight-U,le):le,fe=Math.max(16,ue*M),pe=Math.max(16,de*N);if(h(e=>e.height===pe&&e.width===fe?e:{width:fe,height:pe}),t&&r){let e=t.offsetHeight-pe-ae-se,n=s-v,i=n===0?0:x/n,a=Math.min(e,Math.max(0,i*e));r.style.transform=`translate3d(0,${a}px,0)`}if(n&&i){let e=n.offsetWidth-fe-ie-oe,t=g-b,r=t===0?0:C/t,a=D===`rtl`?rn(r*e,-e,0):rn(r*e,0,e);i.style.transform=`translate3d(${a}px,0,0)`}let me=[[fv.scrollAreaOverflowXStart,I],[fv.scrollAreaOverflowXEnd,L],[fv.scrollAreaOverflowYStart,te],[fv.scrollAreaOverflowYEnd,R]];for(let[t,n]of me)e.style.setProperty(t,`${n}px`);a&&(j||A?m({width:0,height:0}):!j&&!A&&m({width:V,height:H})),_(e=>_v(e,O));let he={xStart:!j&&I>w.xStart,xEnd:!j&&L>w.xEnd,yStart:!A&&te>w.yStart,yEnd:!A&&R>w.yEnd};S(e=>e.xStart===he.xStart&&e.xEnd===he.xEnd&&e.yStart===he.yStart&&e.yEnd===he.yEnd?e:he)});Ye(()=>{o.current&&mv()},[o]),Ye(()=>{queueMicrotask(M)},[M,v,D,w.xStart,w.xEnd,w.yStart,w.yEnd]),Ye(()=>{o.current?.matches(`:hover`)&&x(!0)},[o,x]),Ye(()=>{let e=o.current;if(typeof ResizeObserver>`u`||!e)return;let t=!1,n=new ResizeObserver(()=>{if(!t){t=!0;let n=k.current;if(n[0]===e.clientHeight&&n[1]===e.scrollHeight&&n[2]===e.clientWidth&&n[3]===e.scrollWidth)return}M()});return n.observe(e),j.start(0,()=>{let t=e.getAnimations({subtree:!0});t.length!==0&&Promise.allSettled(t.map(e=>e.finished)).then(M).catch(()=>{})}),()=>{n.disconnect(),j.clear()}},[M,o,j]);function N(){O.current=!1}let P={role:`presentation`,...g&&{"data-id":`${g}-viewport`},tabIndex:v.x&&v.y?-1:0,className:sn.className,style:{overflow:`scroll`},onScroll(){o.current&&(M(),O.current||b({x:o.current.scrollLeft,y:o.current.scrollTop}),A.start(100,()=>{O.current=!0}))},onWheel:N,onTouchMove:N,onPointerMove:N,onPointerEnter:N,onKeyDown:N},F=G.useMemo(()=>({scrolling:T||E,hasOverflowX:!v.x,hasOverflowY:!v.y,overflowXStart:C.xStart,overflowXEnd:C.xEnd,overflowYStart:C.yStart,overflowYEnd:C.yEnd,cornerHidden:v.corner}),[T,E,v.x,v.y,v.corner,C]),I=s(`div`,e,{ref:[t,o],state:F,props:[P,a],stateAttributesMapping:iv}),L=G.useMemo(()=>({computeThumbPosition:M}),[M]);return(0,K.jsx)(dv.Provider,{value:L,children:I})});function gv(e){let t=e.clientHeight>=e.scrollHeight,n=e.clientWidth>=e.scrollWidth;return{y:t,x:n,corner:t||n}}function _v(e,t){return e.y===t.y&&e.x===t.x&&e.corner===t.corner?e:t}var vv=G.createContext(void 0);function yv(){let e=G.useContext(vv);if(e===void 0)throw Error(d(54));return e}var bv=function(e){return e.scrollAreaThumbHeight=`--scroll-area-thumb-height`,e.scrollAreaThumbWidth=`--scroll-area-thumb-width`,e}({}),xv=G.forwardRef(function(e,t){let{render:n,className:r,orientation:i=`vertical`,keepMounted:a=!1,style:o,...c}=e,{hovering:l,scrollingX:u,scrollingY:d,hiddenState:f,overflowEdges:p,scrollbarYRef:m,scrollbarXRef:h,viewportRef:g,thumbYRef:_,thumbXRef:v,handlePointerDown:y,handlePointerUp:b,handleScroll:x,rootId:S,thumbSize:C,hasMeasuredScrollbar:w}=$_(),T={hovering:l,scrolling:{horizontal:u,vertical:d}[i],orientation:i,hasOverflowX:!f.x,hasOverflowY:!f.y,overflowXStart:p.xStart,overflowXEnd:p.xEnd,overflowYStart:p.yStart,overflowYEnd:p.yEnd,cornerHidden:f.corner},E=Re(),D=!w&&!a,O=i===`vertical`?f.y:f.x,k=a||!O;G.useEffect(()=>{if(!k)return;let e=g.current,t=i===`vertical`?m.current:h.current;if(!t)return;function n(n){if(!e||!t||n.ctrlKey)return;let r=i===`horizontal`,a=r?`scrollLeft`:`scrollTop`,o=r?n.deltaX:n.deltaY;if(o===0)return;let s=r?e.scrollWidth-e.clientWidth:e.scrollHeight-e.clientHeight,c=r&&E===`rtl`?-s:0,l=r&&E===`rtl`?0:s,u=e[a];u<=c&&o<0||u>=l&&o>0||(n.preventDefault(),e[a]=Math.min(l,Math.max(c,u+o)),x({x:e.scrollLeft,y:e.scrollTop}))}return oe(t,`wheel`,n,{passive:!1})},[E,x,i,h,m,k,g]);let A={...S&&{"data-id":`${S}-scrollbar`},onPointerDown(e){if(e.button!==0)return;let t=V(e.nativeEvent),n=i===`vertical`?_.current:v.current;if(!(n&&F(n,t))&&g.current){if(_.current&&m.current&&i===`vertical`){let t=tv(_.current,`margin`,`y`),n=tv(m.current,`padding`,`y`),r=_.current.offsetHeight,i=m.current.getBoundingClientRect(),a=e.clientY-i.top-r/2-n+t/2,o=g.current.scrollHeight,s=g.current.clientHeight,c=a/(m.current.offsetHeight-r-n-t)*(o-s);g.current.scrollTop=c}if(v.current&&h.current&&i===`horizontal`){let t=tv(v.current,`margin`,`x`),n=tv(h.current,`padding`,`x`),r=v.current.offsetWidth,i=h.current.getBoundingClientRect(),a=e.clientX-i.left-r/2-n+t/2,o=g.current.scrollWidth,s=g.current.clientWidth,c=a/(h.current.offsetWidth-r-n-t),l;E===`rtl`?(l=(1-c)*(o-s),g.current.scrollLeft<=0&&(l=-l)):l=c*(o-s),g.current.scrollLeft=l}x({x:g.current.scrollLeft,y:g.current.scrollTop}),y(e)}},onPointerUp:b,onPointerCancel:b,style:{position:`absolute`,touchAction:`none`,WebkitUserSelect:`none`,userSelect:`none`,visibility:D?`hidden`:void 0,...i===`vertical`&&{top:0,bottom:`var(${ev.scrollAreaCornerHeight})`,insetInlineEnd:0,[bv.scrollAreaThumbHeight]:`${C.height}px`},...i===`horizontal`&&{insetInlineStart:0,insetInlineEnd:`var(${ev.scrollAreaCornerWidth})`,bottom:0,[bv.scrollAreaThumbWidth]:`${C.width}px`}}},j=s(`div`,e,{ref:[t,i===`vertical`?m:h],state:T,props:[A,c],stateAttributesMapping:iv}),M=G.useMemo(()=>({orientation:i}),[i]);return k?(0,K.jsx)(vv.Provider,{value:M,children:j}):null}),Sv=G.forwardRef(function(e,t){let{render:n,className:r,style:i,...a}=e,{thumbYRef:o,thumbXRef:c,handlePointerDown:l,handlePointerMove:u,handlePointerUp:d,setScrollingX:f,setScrollingY:p,scrollingX:m,scrollingY:h,hasMeasuredScrollbar:g}=$_(),{orientation:_}=yv(),v={scrolling:_===`horizontal`?m:h,orientation:_};function y(e){_===`vertical`&&p(!1),_===`horizontal`&&f(!1),d(e)}return s(`div`,e,{ref:[t,_===`vertical`?o:c],state:v,props:[{onPointerDown:l,onPointerMove:u,onPointerUp:y,onPointerCancel:y,style:{visibility:g?void 0:`hidden`,..._===`vertical`&&{height:`var(${bv.scrollAreaThumbHeight})`},..._===`horizontal`&&{width:`var(${bv.scrollAreaThumbWidth})`}}},a]})}),Cv=G.forwardRef(function(e,t){let{render:n,className:r,style:i,...a}=e,{cornerRef:o,cornerSize:c,hiddenState:l}=$_(),u=s(`div`,e,{ref:[t,o],props:[{style:{position:`absolute`,bottom:0,insetInlineEnd:0,width:c.width,height:c.height}},a]});return l.corner?null:u});function wv({className:e,children:t,scrollFade:n=!1,scrollbarGutter:r=!1,hideScrollbars:i=!1,chainVerticalScroll:a=!1,...o}){return(0,K.jsxs)(lv,{className:c(`relative size-full min-h-0 overflow-hidden rounded-[inherit]`,e),...o,children:[(0,K.jsx)(hv,{className:c(`h-full max-h-[inherit] overflow-auto overscroll-contain rounded-[inherit] outline-none transition-shadows focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-1 focus-visible:ring-offset-background data-has-overflow-x:overscroll-x-contain`,a&&`overscroll-y-auto`,n&&`mask-t-from-[calc(100%-min(var(--fade-size),var(--scroll-area-overflow-y-start)))] mask-b-from-[calc(100%-min(var(--fade-size),var(--scroll-area-overflow-y-end)))] mask-l-from-[calc(100%-min(var(--fade-size),var(--scroll-area-overflow-x-start)))] mask-r-from-[calc(100%-min(var(--fade-size),var(--scroll-area-overflow-x-end)))] [--fade-size:1.5rem]`,r&&`scrollbar-gutter-stable`,i&&`[-ms-overflow-style:none] [scrollbar-width:none] [&::-webkit-scrollbar]:hidden`),"data-slot":`scroll-area-viewport`,children:t}),!i&&(0,K.jsxs)(K.Fragment,{children:[(0,K.jsx)(Tv,{orientation:`vertical`}),(0,K.jsx)(Tv,{orientation:`horizontal`}),(0,K.jsx)(Cv,{"data-slot":`scroll-area-corner`})]})]})}function Tv({className:e,orientation:t=`vertical`,...n}){return(0,K.jsx)(xv,{className:c(`m-1 flex opacity-0 transition-opacity delay-300 data-[orientation=horizontal]:h-1.5 data-[orientation=vertical]:w-1.5 data-[orientation=horizontal]:flex-col data-hovering:opacity-100 data-scrolling:opacity-100 data-hovering:delay-0 data-scrolling:delay-0 data-hovering:duration-100 data-scrolling:duration-100`,e),"data-slot":`scroll-area-scrollbar`,orientation:t,...n,children:(0,K.jsx)(Sv,{className:`relative flex-1 rounded-full bg-foreground/20`,"data-slot":`scroll-area-thumb`})})}var Ev=K_,Dv=z_;function Ov({className:e,...t}){return(0,K.jsx)(A_,{forceRender:!0,className:c(`fixed inset-0 z-50 bg-background/60 backdrop-blur-xs transition-all duration-200 data-ending-style:opacity-0 data-starting-style:opacity-0`,e),"data-slot":`dialog-backdrop`,...t})}function kv({className:e,...t}){return(0,K.jsx)(Y_,{className:c(`fixed inset-0 z-50 grid grid-rows-[1fr_auto_1fr] justify-items-center p-4`,e),"data-slot":`dialog-viewport`,...t})}function Av({className:e,children:t,showCloseButton:n=!0,bottomStickOnMobile:r=!0,...i}){return(0,K.jsxs)(Dv,{children:[(0,K.jsx)(Ov,{}),(0,K.jsx)(kv,{className:c(r&&`max-sm:grid-rows-[1fr_auto] max-sm:p-0 max-sm:pt-12`),children:(0,K.jsxs)(R_,{className:c(`-translate-y-[calc(1.25rem*var(--nested-dialogs))] relative row-start-2 flex max-h-full min-h-0 w-full min-w-0 max-w-xl scale-[calc(1-0.1*var(--nested-dialogs))] flex-col rounded-xl border border-border bg-popover text-popover-foreground opacity-[calc(1-0.1*var(--nested-dialogs))] shadow-2xl transition-[scale,opacity,translate] duration-150 ease-out will-change-transform data-nested:data-ending-style:translate-y-8 data-nested:data-starting-style:translate-y-8 data-nested-dialog-open:origin-top data-ending-style:scale-98 data-starting-style:scale-98 data-ending-style:opacity-0 data-starting-style:opacity-0`,r&&`max-sm:max-w-none max-sm:rounded-none max-sm:border-x-0 max-sm:border-t max-sm:border-b-0 max-sm:opacity-[calc(1-min(var(--nested-dialogs),1))] max-sm:data-ending-style:translate-y-4 max-sm:data-starting-style:translate-y-4`,e),"data-slot":`dialog-popup`,...i,children:[t,n&&(0,K.jsx)(j_,{"aria-label":`Close`,className:`absolute end-2 top-2`,render:(0,K.jsx)(p,{size:`icon`,variant:`ghost`}),children:(0,K.jsx)(kt,{})})]})})]})}function jv({className:e,...t}){return(0,K.jsx)(`div`,{className:c(`flex flex-col gap-2 p-6 in-[[data-slot=dialog-popup]:has([data-slot=dialog-panel])]:pb-3 max-sm:pb-4`,e),"data-slot":`dialog-header`,...t})}function Mv({className:e,variant:t=`default`,...n}){return(0,K.jsx)(`div`,{className:c(`flex flex-col-reverse gap-2 px-6 sm:flex-row sm:justify-end sm:rounded-b-[calc(var(--radius-2xl)-1px)]`,t==="default"&&`border-t bg-muted/72 py-4`,t===`bare`&&`in-[[data-slot=dialog-popup]:has([data-slot=dialog-panel])]:pt-3 pt-4 pb-6`,e),"data-slot":`dialog-footer`,...n})}function Nv({className:e,...t}){return(0,K.jsx)(X_,{className:c(`font-heading font-semibold text-xl leading-none`,e),"data-slot":`dialog-title`,...t})}function Pv({className:e,...t}){return(0,K.jsx)(M_,{className:c(`text-muted-foreground text-sm`,e),"data-slot":`dialog-description`,...t})}function Fv({className:e,scrollFade:t=!0,...n}){return(0,K.jsx)(wv,{scrollFade:t,children:(0,K.jsx)(`div`,{className:c(`p-6 in-[[data-slot=dialog-popup]:has([data-slot=dialog-header])]:pt-1 in-[[data-slot=dialog-popup]:has([data-slot=dialog-footer]:not(.border-t))]:pb-1`,e),"data-slot":`dialog-panel`,...n})})}function Iv({className:e,...t}){return(0,K.jsx)(Qr,{"aria-label":`Loading`,className:c(`animate-spin`,e),role:`status`,...t})}var Lv=l(`inline-flex w-fit shrink-0 items-center gap-1.5 whitespace-nowrap rounded-full border px-2 py-0.5 font-medium text-[11px] tracking-tight transition-colors`,{defaultVariants:{tone:`neutral`},variants:{tone:{success:`border-emerald-500/20 bg-emerald-500/10 text-emerald-600 dark:border-emerald-500/25 dark:bg-emerald-500/15 dark:text-emerald-300`,warning:`border-amber-500/20 bg-amber-500/10 text-amber-600 dark:border-amber-500/25 dark:bg-amber-500/15 dark:text-amber-300`,danger:`border-rose-500/20 bg-rose-500/10 text-rose-600 dark:border-rose-500/25 dark:bg-rose-500/15 dark:text-rose-300`,running:`border-sky-500/20 bg-sky-500/10 text-sky-600 dark:border-sky-500/25 dark:bg-sky-500/15 dark:text-sky-300`,info:`border-blue-500/20 bg-blue-500/10 text-blue-600 dark:border-blue-500/25 dark:bg-blue-500/15 dark:text-blue-300`,accent:`border-primary/25 bg-primary/10 text-primary`,idle:`border-border/70 bg-muted/60 text-muted-foreground`,neutral:`border-border/70 bg-muted/60 text-muted-foreground`,"in-place":`border-sky-500/20 bg-sky-500/10 text-sky-600 dark:text-sky-300 font-mono text-[10px]`,worktree:`border-primary/20 bg-primary/10 text-primary font-mono text-[10px]`}}});function Rv({className:e,tone:t,dot:n=!0,children:r,...i}){return(0,K.jsxs)(`span`,{className:c(Lv({className:e,tone:t})),"data-slot":`status-badge`,...i,children:[n&&(0,K.jsx)(`span`,{"aria-hidden":!0,className:`size-1.5 rounded-full bg-current opacity-70`}),r]})}function zv(e){switch(e){case`up-to-date`:return{label:`In sync`,tone:`success`};case`rebased`:return{label:`Rebased`,tone:`accent`};case`conflict`:case`stash-conflict`:return{label:`Sync conflict`,tone:`danger`};case`error`:return{label:`Sync error`,tone:`danger`};default:return{label:`Not synced`,tone:`idle`}}}function Bv(e){return e.replace(/[\\/]+$/,``).split(/[\\/]/).pop()||e}function Vv(e,t){let n=Bv(t),r=e.find(e=>e.branchName===n);if(r)return r;let i=e.filter(e=>e.repos.some(e=>Bv(e)===n));return i.length===1?i[0]:void 0}async function Hv(e){if(typeof navigator<`u`&&navigator.clipboard&&window.isSecureContext)try{return await navigator.clipboard.writeText(e),!0}catch{}try{let t=document.createElement(`textarea`);t.value=e,t.style.position=`fixed`,t.style.left=`-999999px`,t.style.top=`-999999px`,t.style.opacity=`0`,document.body.appendChild(t),t.focus(),t.select();let n=document.execCommand(`copy`);return document.body.removeChild(t),n}catch{return!1}}var Uv=e=>e===`antigravity`?`Antigravity`:e===`claude`?`Claude Code`:e===`codex`?`OpenAI Codex`:`GitHub Copilot`,Wv=e=>e===`claude`?`warning`:e===`codex`?`success`:e===`antigravity`?`accent`:`info`,Gv=(e,t)=>{switch(e){case`antigravity`:return`agy --conversation ${t}`;case`claude`:return`claude --resume ${t}`;case`codex`:return`codex resume ${t}`;case`copilot`:return`copilot --resume ${t}`;default:return`agy --conversation ${t}`}};function Kv({activeSession:e,transcript:t,transcriptLoading:n,setActiveSession:r,workspaces:i,workspace:a,handleOpenDesktopSession:o,showToast:s}){let c=lo(),l=Oo(),u=c.data?.find(e=>e.id===`codex-desktop`),d=u?.available===!0,f=c.isLoading?`Checking whether Codex Desktop is available…`:c.isError?`Could not check whether Codex Desktop is available.`:u?.unavailableReason??`Codex Desktop is not available on this computer.`,m=(0,G.useRef)(!1),h=(0,G.useRef)(!1),g=(0,G.useRef)(null),[_,v]=(0,G.useState)(!1),[y,b]=(0,G.useState)(!1);(0,G.useEffect)(()=>{!n&&t.length>0&&g.current?.scrollIntoView({behavior:`auto`})},[n,t]);let x=()=>a??Vv(i,e.workspacePath),S=async()=>{if(!d||m.current)return;let t=x();if(!t){s(`Could not match this session to a workspace — it may have been removed.`,`error`);return}m.current=!0,v(!0);try{await o(t,e.id,e.assistant)&&r(null)}finally{m.current=!1,v(!1)}},C=async()=>{if(h.current)return;let t=x();if(!t){s(`Could not match this session to a workspace.`,`error`);return}h.current=!0,b(!0);try{await l.mutateAsync({workspaceId:t.branchName,assistant:e.assistant,sessionId:e.id}),s(`Launched interactive terminal for ${Uv(e.assistant)}.`,`success`),r(null)}catch{let t=Gv(e.assistant,e.id);await Hv(t)?s(`Could not open terminal automatically. Copied command to clipboard:\n\n${t}`,`info`):s(`Could not open terminal automatically. Run manually:\n\n${t}`,`error`)}finally{b(!1),h.current=!1}};return(0,K.jsx)(Ev,{open:!0,onOpenChange:e=>!e&&r(null),children:(0,K.jsxs)(Av,{className:`h-[80vh] max-w-4xl`,children:[(0,K.jsx)(jv,{children:(0,K.jsxs)(`div`,{children:[(0,K.jsxs)(`div`,{className:`flex items-center gap-2 mb-1`,children:[(0,K.jsx)(Rv,{tone:Wv(e.assistant),children:Uv(e.assistant)}),(0,K.jsxs)(`span`,{className:`text-[10px] font-mono bg-muted/60 text-muted-foreground px-1.5 py-0.5 rounded`,children:[`Read-Only Transcript · `,t.length,` turns`]}),(0,K.jsxs)(`span`,{className:`text-[10px] text-muted-foreground font-mono`,children:[`ID: `,e.id.slice(0,8)]})]}),(0,K.jsx)(Nv,{className:`max-w-xl truncate text-sm`,title:e.title,children:e.title}),(0,K.jsxs)(Pv,{className:`sr-only`,children:[`Read-only transcript log and resume options for session `,e.id]})]})}),(0,K.jsxs)(Fv,{className:`space-y-4`,children:[n?(0,K.jsxs)(`div`,{className:`flex flex-col items-center justify-center h-full gap-2`,children:[(0,K.jsx)(Iv,{className:`size-6 text-primary`}),(0,K.jsx)(`span`,{className:`text-xs font-medium text-muted-foreground`,children:`Loading conversation history...`})]}):t.length===0?(0,K.jsx)(`div`,{className:`flex h-full items-center justify-center text-xs text-muted-foreground`,children:`No messages found in this transcript.`}):t.map((t,n)=>(0,K.jsxs)(`div`,{className:`flex flex-col ${t.role===`user`?`items-end`:`items-start`}`,children:[(0,K.jsxs)(`div`,{className:`mb-1 px-1 text-[10px] text-muted-foreground`,children:[t.role===`user`?`Developer`:e.assistant===`antigravity`?`Antigravity`:e.assistant===`claude`?`Claude`:e.assistant===`codex`?`Codex`:`Copilot`,t.timestamp&&` • ${new Date(t.timestamp).toLocaleTimeString()}`]}),(0,K.jsx)(`div`,{className:`max-w-[85%] rounded-xl border px-4 py-3 text-xs leading-relaxed ${t.role===`user`?`rounded-tr-none border-primary/30 bg-primary/10 text-foreground dark:border-primary/40 dark:bg-primary/20`:`rounded-tl-none border-border bg-card text-foreground shadow-xs dark:bg-muted/30`}`,children:(0,K.jsx)(T_,{content:t.content})})]},n)),(0,K.jsx)(`div`,{ref:g})]}),(0,K.jsxs)(Mv,{className:`sm:justify-between`,children:[(0,K.jsx)(`span`,{className:`text-[11px] text-muted-foreground`,children:`Read-only transcript. Interactive coding happens in your terminal or IDE.`}),(0,K.jsxs)(`div`,{className:`flex flex-wrap gap-2`,children:[(0,K.jsxs)(p,{variant:`outline`,size:`sm`,onClick:async()=>{let t=Gv(e.assistant,e.id);await Hv(t),s(`Copied run command to clipboard:\n\n${t}`,`success`)},children:[(0,K.jsx)(Jr,{size:13}),` Copy CLI Command`]}),(0,K.jsxs)(p,{size:`sm`,variant:`default`,disabled:y,onClick:()=>void C(),children:[y?(0,K.jsx)(Iv,{className:`size-3`}):(0,K.jsx)(oi,{size:12}),`Resume in Terminal`]}),e.assistant===`codex`&&(0,K.jsxs)(p,{variant:`outline`,size:`sm`,disabled:!d||_,title:d?`Open this exact thread in Codex Desktop`:f,"aria-label":d?`Open in Codex Desktop`:`Codex Desktop unavailable: ${f}`,onClick:()=>void S(),children:[_?(0,K.jsx)(Iv,{className:`size-3`}):(0,K.jsx)(Yr,{size:12}),_?`Opening…`:`Open in Codex Desktop`]})]})]})]})})}var qv=(0,G.lazy)(()=>Mt(()=>import(`./DashboardPage-BScH3Cxp.js`).then(e=>({default:e.DashboardPage})),__vite__mapDeps([0,1,2,3,4,5]))),Jv=(0,G.lazy)(()=>Mt(()=>import(`./ProjectsPage-Bojj7gxI.js`).then(e=>({default:e.ProjectsPage})),__vite__mapDeps([6,1,7,8,9,10,11,12,13,14,5]))),Yv=(0,G.lazy)(()=>Mt(()=>import(`./SettingsPage-BAdXO8X0.js`).then(e=>({default:e.SettingsPage})),__vite__mapDeps([15,1,7,10,11,14,4,16]))),Xv=(0,G.lazy)(()=>Mt(()=>import(`./SkillsPage-CF6Db1FA.js`).then(e=>({default:e.SkillsPage})),__vite__mapDeps([17,1,7,18,19,2,20,9,13,21,14,4,5,16,22]))),Zv=(0,G.lazy)(()=>Mt(()=>import(`./AgentsPage-BNHR9qux.js`).then(e=>({default:e.AgentsPage})),__vite__mapDeps([23,1,7,24,12,9,13,14,4,5,16,22]))),Qv=(0,G.lazy)(()=>Mt(()=>import(`./StartWorkPage-BQid3uIw.js`).then(e=>({default:e.StartWorkPage})),__vite__mapDeps([25,1,7,24,18,2,8,9,10,11,3,21,14,5,22,26]))),$v=(0,G.lazy)(()=>Mt(()=>import(`./StrategiesPage-nGbR9TAc.js`).then(e=>({default:e.StrategiesPage})),__vite__mapDeps([27,1,7,28,20,13,14,4,5,16,22]))),ey=(0,G.lazy)(()=>Mt(()=>import(`./WorkspacesPage-7XRtVJNF.js`).then(e=>({default:e.WorkspacesPage})),__vite__mapDeps([29,1,7,24,18,19,2,20,9,13,21,30,10,14,4,5,22,26]))),ty=(0,G.lazy)(()=>Mt(()=>import(`./GettingStartedPage-AWlI-176.js`).then(e=>({default:e.GettingStartedPage})),__vite__mapDeps([31,1,28]))),ny=new URLSearchParams(window.location.search).get(`env`)===`vscode`,ry=0;function iy(){let e=Tt(),t=It(),[n,r]=(0,G.useState)([]),i=(e,t=`info`,n=5e3)=>{let i=`toast-${++ry}`;r(r=>[...r,{id:i,message:e,type:t,duration:n}]),setTimeout(()=>{r(e=>e.filter(e=>e.id!==i))},n)},[a,o]=(0,G.useState)(null),[s,l]=(0,G.useState)(!0),[u,d]=(0,G.useState)(!0),[f,p]=(0,G.useState)(null),[m,h]=(0,G.useState)([]),[g,_]=(0,G.useState)(null),[v,y]=(0,G.useState)(``),[b,x]=(0,G.useState)(null),S=J(),C=so(),w=co(),T=fo(),E=S.data??[],D=C.data??[],O=w.data??[],k=T.data??[],[A,j]=(0,G.useState)(!1),[M,N]=(0,G.useState)(`idle`),[P,F]=(0,G.useState)(null),[I,L]=(0,G.useState)(!1),[ee,te]=(0,G.useState)(``),[R,z]=(0,G.useState)(``),[B,V]=(0,G.useState)(null),[H,ne]=(0,G.useState)(!1),[re,U]=(0,G.useState)(!1),[ie,ae]=(0,G.useState)(!1),[oe,se]=(0,G.useState)(`antigravity`),ce=(0,G.useRef)(!1);(0,G.useEffect)(()=>{if(ce.current||!C.data)return;let e=C.data.find(e=>e.detected&&e.command);e&&(ce.current=!0,se(e.name))},[C.data]);let[le,ue]=(0,G.useState)(null),[de,fe]=(0,G.useState)(``),pe=t.pathname===`/`||t.pathname.startsWith(`/workspaces`),me=Sr(),he=Qa(),ge=$a({enabled:u&&!s,intervalMs:pe?15e3:!1}),_e=he.data??[],ve=he.isLoading,ye=ge.data??{},[be,W]=(0,G.useState)(null),[xe,Se]=(0,G.useState)(`overview`),[Ce,we]=(0,G.useState)([]),[Te,Ee]=(0,G.useState)(!1),[De,Oe]=(0,G.useState)(null),[ke,Ae]=(0,G.useState)([]),[je,Me]=(0,G.useState)(!1),[Ne,Pe]=(0,G.useState)([]),[Fe,Ie]=(0,G.useState)(!1),[Le,Re]=(0,G.useState)(``),[ze,Be]=(0,G.useState)(!1),[Ve,He]=(0,G.useState)(!1),[Ue,We]=(0,G.useState)(``),[Ge,Ke]=(0,G.useState)(!1),[qe,Je]=(0,G.useState)(``),[Ye,Xe]=(0,G.useState)(!1),[Ze,Qe]=(0,G.useState)(!1),[$e,et]=(0,G.useState)(null),[tt,nt]=(0,G.useState)(``),[rt,it]=(0,G.useState)(!1),[at,ot]=(0,G.useState)(!1),[st,ct]=(0,G.useState)(null),[lt,ut]=(0,G.useState)(null),[dt,ft]=(0,G.useState)(!1),[pt,mt]=(0,G.useState)([]),[ht,gt]=(0,G.useState)(!1),[_t,vt]=(0,G.useState)(null),yt=!(!a||!a.devDir||a.devDir.trim()===``||!a.workspacesDir||a.workspacesDir.trim()===``),bt=async()=>{try{let e=await fetch(`/api/update-status`);if(e.ok){let t=await e.json();_(t),t.currentVersion&&y(t.currentVersion)}}catch(e){console.error(`Failed to fetch update status:`,e)}},xt=async()=>{if(!g||!g.downloadUrl){i(`No update download URL found.`,`error`);return}j(!0),N(`downloading`);try{let e=await fetch(`/api/updates/download`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({downloadUrl:g.downloadUrl})}),t=await e.json();if(!e.ok||!t.success)throw Error(t.error||`Failed to download installer binary`);N(`applying`);let n=await fetch(`/api/updates/apply`,{method:`POST`}),r=await n.json();if(!n.ok||!r.success)throw Error(r.error||`Failed to trigger application update`);let a=typeof window<`u`&&window.Neutralino;i(a?`Update downloaded! App is restarting...`:`Update downloaded and installer launched. Restart NexusFlow to complete the update.`,`success`),a?setTimeout(()=>{window.Neutralino.app.exit()},800):(N(`idle`),j(!1))}catch(e){console.error(`Update failed:`,e),N(`error`),i(`Update Failed: ${e.message||`Unknown error`}`,`error`),j(!1)}},St=async()=>{try{let e=await(await fetch(`/api/adapters`)).json();e.adapters&&h(e.adapters)}catch(e){console.error(`Failed to fetch adapters:`,e)}},Ct=async()=>{St();try{let e=await(await fetch(`/api/config`)).json();o(e.config),d(e.exists),e.exists&&e.config.devDir||(x({devDir:e.config.devDir||``,workspacesDir:e.config.workspacesDir||``}),o({version:`1.0.0`,devDir:``,workspacesDir:``,defaultAssistant:null,scanDepth:2}))}catch(e){console.error(e)}finally{l(!1)}},Et=async e=>{try{(await fetch(`/api/config`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify(e)})).ok?(p(`success`),o(e),d(!0),me.invalidateQueries({queryKey:[`repos`]}),Dt()):p(`error`)}catch{p(`error`)}setTimeout(()=>p(null),3e3)},Dt=async()=>{await Promise.all([me.invalidateQueries({queryKey:[`workspaces`]}),me.invalidateQueries({queryKey:[`workspaces-status`]})])},kt=async()=>{if(!ee.trim()||!R.trim()){i(`Name and content are required.`,`error`);return}U(!0);try{let e=await fetch(`/api/workflows/templates`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({id:P,name:ee,content:R})});if(e.ok){let t=await e.json();i(`Strategy template saved successfully!`,`success`),await me.invalidateQueries({queryKey:[`workflow-templates`]}),F(t.template.id),L(!1),V(null)}else{let t=await e.json();i(t.error||`Failed to save template`,`error`)}}catch(e){i(e.message||`Error saving template`,`error`)}finally{U(!1)}},At=async e=>{if(window.confirm(`Are you sure you want to delete this custom strategy template?`)){ae(!0);try{let t=await fetch(`/api/workflows/templates/${encodeURIComponent(e)}`,{method:`DELETE`});if(t.ok)i(`Strategy template deleted successfully!`,`success`),await me.invalidateQueries({queryKey:[`workflow-templates`]}),F(null),V(null);else{let e=await t.json();i(e.error||`Failed to delete template`,`error`)}}catch(e){i(e.message||`Error deleting template`,`error`)}finally{ae(!1)}}},jt=async(e,t,n)=>{ne(!0),V(null),ue(null);try{let r=await fetch(`/api/workflows/templates/${encodeURIComponent(e)}/analyze`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({content:t,assistant:n,comment:de})});if(r.ok){let e=await r.json();V(e.analysis),ue(e.suggestedImprovement||null),i(`Strategy analysis completed successfully!`,`success`)}else{let e=await r.json();i(e.error||`Failed to analyze template using the selected assistant harness.`,`error`)}}catch(e){i(e.message||`Error analyzing template`,`error`)}finally{ne(!1)}},Mt=async e=>{Ie(!0);try{let t=await(await fetch(`/api/workspace/${encodeURIComponent(e)}/changes`)).json();Pe(t.changes||[])}catch(e){console.error(e)}finally{Ie(!1)}},Nt=async e=>{Ee(!0);try{let t=await(await fetch(`/api/workspace/${encodeURIComponent(e)}/sessions`)).json();we(t.sessions||[])}catch(e){console.error(e)}finally{Ee(!1)}},Ft=async(e,t)=>{Me(!0);try{let n=await(await fetch(`/api/session/${e}/${t}/transcript`)).json();Ae(n.messages||[])}catch(e){console.error(e)}finally{Me(!1)}},Lt=async e=>{Be(!0);try{let t=await(await fetch(`/api/workspace/${encodeURIComponent(e)}/knowledge`)).json();Re(t.content||``),We(t.content||``)}catch(e){console.error(e)}finally{Be(!1)}},Rt=async e=>{Ke(!0);try{(await fetch(`/api/workspace/${encodeURIComponent(e)}/knowledge`,{method:`PUT`,headers:{"Content-Type":`application/json`},body:JSON.stringify({content:Ue})})).ok&&(Re(Ue),He(!1))}catch(e){console.error(e)}finally{Ke(!1)}},zt=async e=>{Xe(!0);try{let t=await(await fetch(`/api/workspace/${encodeURIComponent(e)}/plan`)).json();Je(t.content||``)}catch(e){console.error(e)}finally{Xe(!1)}},Bt=async e=>{Qe(!0),et(null);try{let t=await(await fetch(`/api/workspace/${encodeURIComponent(e)}/sync`,{method:`POST`})).json();et(t.results||[]),Mt(e)}catch(e){console.error(e)}finally{Qe(!1)}},Vt=async e=>{if(tt.trim()){ot(!0),ct(null);try{let t=await(await fetch(`/api/workspace/${encodeURIComponent(e)}/commit`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({message:tt})})).json();ct(t.results||[]),nt(``),it(!1),Mt(e)}catch(e){console.error(e)}finally{ot(!1)}}},Ht=async(e,t,n)=>{if(n!==`codex`){let e=n===`claude`?`claude --resume ${t}`:`agy --conversation ${t}`;return await Hv(e),i(`Copied ${n} resume command to clipboard:\n\n${e}`,`info`),!0}try{return await q(`/api/workspace/${encodeURIComponent(e.branchName)}/launch`,{method:`POST`,body:JSON.stringify({targetId:`codex-desktop`,action:`resume`,sessionId:t})}),i(`Sent the existing session to Codex Desktop.`,`success`),!0}catch(e){return i(e instanceof Error?e.message:String(e),`error`),!1}},Ut=async e=>{if(!be)return;let t=_e.find(e=>e.branchName===be);if(t){if(ny){window.parent.postMessage({type:`executeTerminalCommand`,command:e,cwd:t.workspacePath},`*`);return}try{await q(`/api/workspace/${encodeURIComponent(t.branchName)}/terminal`,{method:`POST`,body:JSON.stringify({command:e})})}catch(e){i(`Terminal error: ${e instanceof Error?e.message:String(e)}`,`error`)}}};(0,G.useEffect)(()=>{Ct(),bt();let t=new URLSearchParams(window.location.search).get(`workspaceId`);t&&e(`/workspaces/${encodeURIComponent(t)}`)},[]),(0,G.useEffect)(()=>{let e=t.pathname;if(e.startsWith(`/workspaces`)){let t=e.split(`/`).filter(Boolean);W(t[1]?decodeURIComponent(t[1]):null);let n=t[2];Se(n&&[`overview`,`sessions`,`services`,`changes`,`knowledge`,`plan`,`skills`].includes(n)?n:`overview`)}else W(null)},[t.pathname]);let Wt=async(e=!1)=>{gt(!0);try{let t=await fetch(`/api/updates/tools${e?`?force=true`:``}`);t.ok&&mt(await t.json())}catch(e){console.error(`Failed to fetch tools status:`,e)}finally{gt(!1)}},Gt=async e=>{vt(e);try{let t=await fetch(`/api/updates/install`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({toolId:e})}),n=await t.json();t.ok&&n.success?(i(`${e} updated successfully!\n\nOutput:\n${n.output}`,`success`),Wt(!0),bt()):i(`Error: ${n.error||`Failed to update tool`}`,`error`)}catch(e){console.error(e),i(`Network error when updating tool.`,`error`)}finally{vt(null)}};(0,G.useEffect)(()=>{t.pathname.startsWith(`/settings`)&&Wt()},[t.pathname]),(0,G.useEffect)(()=>{we([]),Pe([]),Re(``),Je(``)},[be]),(0,G.useEffect)(()=>{be&&(xe===`changes`||xe===`overview`)&&Mt(be)},[be,xe]),(0,G.useEffect)(()=>{be&&(xe===`sessions`||xe===`overview`)&&Nt(be)},[be,xe]),(0,G.useEffect)(()=>{be&&xe===`knowledge`&&Lt(be)},[be,xe]),(0,G.useEffect)(()=>{be&&xe===`plan`&&zt(be)},[be,xe]);let Kt=async e=>{let t=e.repos.map(e=>e.split(/[\\/]/).pop()).join(`, `);await Hv(`You are an AI assistant helping with feature development.
|
|
39
|
+
We are working in a multi-repository workspace.
|
|
40
|
+
|
|
41
|
+
Workspace Metadata:
|
|
42
|
+
- Feature Branch: ${e.branchName}
|
|
43
|
+
- Purpose & Context: ${e.description}
|
|
44
|
+
- Mapped Repositories: ${t}
|
|
45
|
+
|
|
46
|
+
Core Instructions:
|
|
47
|
+
1. Read "AGENTS.md" at the workspace root first — it names the repos, how they depend on each other, which to change first, and how to verify each.
|
|
48
|
+
2. Search "nexusflow-knowledge.md" for decisions and gotchas from earlier sessions rather than reading it whole, and record new ones with \`nexusflow knowledge add\`. "nexusflow-plan.md" carries the phase order when a change spans repos.
|
|
49
|
+
3. Follow all project-specific rules in "CLAUDE.md", ".cursorrules", or "AGENTS.md" inside sub-repositories.
|
|
50
|
+
`)?i(`AI context prompt copied to clipboard!`,`success`):i(`Could not copy prompt to clipboard. Please check browser permissions.`,`error`)},qt=async t=>{if(window.confirm(`Are you sure you want to delete the workspace "${t}"?\nThis will force remove all git worktrees inside it and delete all files in the folder.`)){ut(t);try{let n=await fetch(`/api/workspace/${encodeURIComponent(t)}`,{method:`DELETE`}),r=await n.json();n.ok&&r.success?(be===t&&e(`/workspaces`),await Dt(),i(`Workspace ${t} successfully deleted.`,`success`)):i(`Failed to delete workspace: ${r.error||`Unknown error`}`,`error`)}catch(e){console.error(e),i(`Network error while deleting workspace.`,`error`)}finally{ut(null)}}},Jt=async(e,t)=>{ft(!0);try{let n=await fetch(`/api/workspace/${encodeURIComponent(e)}/repo`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({repoPath:t})}),r=await n.json();n.ok&&r.success?(await Dt(),me.invalidateQueries({queryKey:[`workspace-services`,e]}),be===e&&(Mt(e),Nt(e)),i(`Repository successfully added and configurations updated.`,`success`)):i(`Failed to add repository: ${r.error||`Unknown error`}`,`error`)}catch(e){console.error(e),i(`Network error while adding repository.`,`error`)}finally{ft(!1)}};if(!u&&a)return(0,K.jsx)(zs,{config:a,setConfig:o,defaultPaths:b,adapters:m,saveAppConfig:Et});if(ny)return(0,K.jsx)(Mo,{activeWsId:be,setActiveWsId:W,appVersion:v,workspaces:_e,executeTerminal:Ut});let Yt=a?(0,K.jsx)(qv,{workspaces:_e,workspaceStatuses:ye,workspacesLoading:ve,onOpenWorkspace:t=>e(`/workspaces/${encodeURIComponent(t)}`),onNewWorkspace:()=>e(`/new`),showToast:i}):null,Xt=a?(0,K.jsx)(ty,{config:a,onCreateWorkspace:()=>e(`/new`),onModifySettings:()=>e(`/settings`)}):null,Zt=a?(0,K.jsx)(Qv,{}):null,Qt=a?(0,K.jsx)(Jv,{}):null,$t=(0,K.jsx)(ey,{workspaces:_e,workspaceStatuses:ye,workspacesLoading:ve,fetchWorkspaces:Dt,selectedId:be,subTab:xe,onSelect:t=>e(`/workspaces/${encodeURIComponent(t)}`),onSelectTab:(t,n)=>e(`/workspaces/${encodeURIComponent(t)}/${n}`),handleCopyPrompt:Kt,handleDeleteWorkspace:qt,deleteWsLoading:lt,repos:E,addRepoLoading:dt,handleAddRepo:Jt,sessionProps:{sessions:Ce,sessionsLoading:Te,setActiveSession:Oe,setTranscript:Ae,fetchSessionTranscript:Ft,handleOpenDesktopSession:Ht,showToast:i},changesProps:{gitChanges:Ne,gitChangesLoading:Fe,syncLoading:Ze,syncResults:$e,commitMessage:tt,showCommitModal:rt,commitLoading:at,commitResults:st,setSyncResults:et,setCommitResults:ct,setCommitMessage:nt,setShowCommitModal:it,fetchGitChanges:Mt,handleSyncAll:Bt,handleCommitAll:Vt},knowledgeProps:{knowledgeContent:Le,knowledgeLoading:ze,isEditingKnowledge:Ve,editedKnowledge:Ue,saveKnowledgeLoading:Ge,setEditedKnowledge:We,setIsEditingKnowledge:He,handleSaveKnowledge:Rt},planProps:{planContent:qe,planLoading:Ye},showToast:i}),en=(0,K.jsx)($v,{workflowTemplates:k,isEditingTemplate:I,setIsEditingTemplate:L,mgtTemplateName:ee,setMgtTemplateName:te,mgtTemplateContent:R,setMgtTemplateContent:z,selectedMgtTemplateId:P,setSelectedMgtTemplateId:F,analysisResult:B,setAnalysisResult:V,showToast:i,handleAnalyzeTemplate:jt,handleSaveTemplate:kt,handleDeleteTemplate:At,aiAssistants:D,analyzingTemplate:H,mgtAnalysisComment:de,setMgtAnalysisComment:fe,suggestedImprovement:le,setSuggestedImprovement:ue,savingTemplate:re,deletingTemplate:ie,selectedInspectAssistant:oe,setSelectedInspectAssistant:se}),tn=(0,K.jsx)(Xv,{showToast:i}),nn=(0,K.jsx)(Zv,{showToast:i}),rn=a?(0,K.jsx)(Yv,{config:a,setConfig:o,saveStatus:f,editors:O,adapters:m,saveAppConfig:Et,isSettingsFormValid:yt,toolsStatus:pt,toolsLoading:ht,updatingToolId:_t,fetchToolsStatus:Wt,handleUpdateTool:Gt}):null,an=be||(_e.length>0?_e[0].branchName:null),on=t.pathname.startsWith(`/workspaces`);return(0,K.jsxs)(`div`,{className:`flex min-h-screen bg-background text-foreground`,children:[(0,K.jsx)(Ja,{appVersion:v,workspaces:_e,workspaceStatuses:ye,workspacesLoading:ve,activeWsId:be,onSelectWorkspace:t=>e(`/workspaces/${encodeURIComponent(t)}`)}),(0,K.jsx)(`main`,{className:c(`flex-1 min-w-0 h-screen`,on?`overflow-hidden flex flex-col`:`overflow-y-auto p-3 sm:p-5 lg:p-6`),children:s?(0,K.jsxs)(`div`,{className:`flex flex-col items-center justify-center py-40 gap-4 text-muted-foreground`,children:[(0,K.jsx)(ni,{className:`animate-spin text-primary`,size:32}),(0,K.jsx)(`span`,{className:`text-sm font-medium`,children:`Loading config settings...`})]}):(0,K.jsxs)(K.Fragment,{children:[g&&g.updateAvailable&&(0,K.jsxs)(`div`,{className:`mb-6 p-4 bg-gradient-to-r from-amber-500/10 to-orange-600/10 border border-amber-500/30 rounded-xl shadow-lg flex flex-col sm:flex-row sm:items-center sm:justify-between gap-4 backdrop-blur-sm`,children:[(0,K.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,K.jsx)(`div`,{className:`w-10 h-10 rounded-lg bg-amber-500/10 border border-amber-500/20 flex items-center justify-center text-amber-400 shrink-0`,children:A?(0,K.jsx)(ni,{size:20,className:`animate-spin text-amber-400`}):(0,K.jsx)(ii,{size:20})}),(0,K.jsxs)(`div`,{children:[(0,K.jsx)(`h4`,{className:`text-sm font-bold text-amber-300`,children:A?M===`downloading`?`Downloading Update...`:`Applying Update...`:`A new version of NexusFlow is available!`}),(0,K.jsx)(`p`,{className:`text-xs text-muted-foreground mt-0.5`,children:A?M===`downloading`?`Fetching installer from GitHub Releases...`:`Closing app and launching silent installer setup...`:`Upgrade from v${g.currentVersion} to v${g.latestVersion} to get the latest features and bug fixes.`})]})]}),(0,K.jsxs)(`div`,{className:`flex items-center gap-3 shrink-0`,children:[typeof window<`u`&&window.Neutralino&&g.downloadUrl&&(0,K.jsx)(`button`,{onClick:xt,disabled:A,className:`px-4 py-2 bg-gradient-to-r from-emerald-500 to-teal-600 hover:from-emerald-600 hover:to-teal-700 text-white font-bold text-xs rounded-lg transition-all shadow-md disabled:opacity-50 cursor-pointer flex items-center gap-1.5`,children:A?`Installing...`:`Install Automatically`}),(0,K.jsx)(`button`,{onClick:async()=>{await Hv(`npm install -g @mrpatronz/nexusflow`),i(`Update command copied to clipboard!`,`success`)},disabled:A,className:`px-4 py-2 bg-amber-500 hover:bg-amber-600 text-[#060813] font-bold text-xs rounded-lg transition-all shadow-md shadow-amber-500/10 disabled:opacity-50 cursor-pointer flex items-center gap-1.5`,children:`Copy Update Command`})]})]}),!a&&(0,K.jsxs)(`div`,{className:`flex flex-col items-center justify-center py-40 gap-6`,children:[(0,K.jsx)(`div`,{className:`bg-red-500/10 p-6 rounded-full`,children:(0,K.jsx)(si,{className:`text-red-400`,size:48})}),(0,K.jsxs)(`div`,{className:`text-center max-w-md`,children:[(0,K.jsx)(`h2`,{className:`text-2xl font-bold text-white mb-2`,children:`Backend Unreachable`}),(0,K.jsxs)(`p`,{className:`text-sm text-muted-foreground mb-6`,children:[`The NexusFlow GUI could not connect to the local server. Make sure you started the GUI correctly via `,(0,K.jsx)(`code`,{children:`nexusflow ui`}),` or that the backend is running.`]}),(0,K.jsxs)(`button`,{onClick:()=>{l(!0),Ct(),me.invalidateQueries()},className:`px-4 py-2 bg-primary hover:bg-primary/90 text-white font-medium text-sm rounded-md transition-colors cursor-pointer inline-flex items-center gap-2`,children:[(0,K.jsx)(ni,{size:16}),` Try Again`]})]})]}),(0,K.jsx)(G.Suspense,{fallback:(0,K.jsx)(`div`,{className:`flex justify-center py-20`,children:(0,K.jsx)(Iv,{className:`size-6`})}),children:(0,K.jsxs)(Ot,{children:[(0,K.jsx)(wt,{path:`/`,element:Yt}),(0,K.jsx)(wt,{path:`/overview`,element:Yt}),(0,K.jsx)(wt,{path:`/dashboard`,element:Yt}),(0,K.jsx)(wt,{path:`/guide`,element:Xt}),(0,K.jsx)(wt,{path:`/create`,element:Zt}),(0,K.jsx)(wt,{path:`/new`,element:Zt}),(0,K.jsx)(wt,{path:`/projects`,element:Qt}),(0,K.jsx)(wt,{path:`/workspaces`,element:an?(0,K.jsx)(Pt,{to:`/workspaces/${encodeURIComponent(an)}`,replace:!0}):(0,K.jsx)(Pt,{to:`/new`,replace:!0})}),(0,K.jsx)(wt,{path:`/workspaces/:workspaceId`,element:$t}),(0,K.jsx)(wt,{path:`/workspaces/:workspaceId/:tab`,element:$t}),(0,K.jsx)(wt,{path:`/skills`,element:tn}),(0,K.jsx)(wt,{path:`/agents`,element:nn}),(0,K.jsx)(wt,{path:`/settings`,element:rn}),(0,K.jsx)(wt,{path:`/workflows`,element:en}),(0,K.jsx)(wt,{path:`/strategies`,element:en}),(0,K.jsx)(wt,{path:`*`,element:(0,K.jsx)(Pt,{to:`/overview`,replace:!0})})]})})]})}),De&&(0,K.jsx)(Kv,{activeSession:De,transcript:ke,transcriptLoading:je,setActiveSession:Oe,workspaces:_e,workspace:_e.find(e=>e.branchName===be),handleOpenDesktopSession:Ht,showToast:i}),(0,K.jsx)(Ya,{toasts:n,onDismiss:e=>r(t=>t.filter(t=>t.id!==e))})]})}function ay(){return(0,K.jsx)(Dt,{children:(0,K.jsx)(iy,{})})}var oy=new br;(0,zr.createRoot)(document.getElementById(`root`)).render((0,K.jsx)(G.StrictMode,{children:(0,K.jsx)(Ga,{children:(0,K.jsx)(Cr,{client:oy,children:(0,K.jsx)(ay,{})})})}));export{go as $,jo as A,si as At,xo as B,qr as Bt,A_ as C,Oi as Ct,Ls as D,wi as Dt,Rs as E,Ti as Et,no as F,ti as Ft,to as G,Vr as Gt,wo as H,Wr as Ht,oo as I,ei as It,J,ko as K,Sr as Kt,eo as L,Xr as Lt,so as M,ii as Mt,Do as N,ri as Nt,Fs as O,Ci as Ot,Za as P,ni as Pt,mo as Q,To as R,Yr as Rt,j_ as S,ki as St,Ns as T,Ei as Tt,Oo as U,Ur as Ut,vo as V,Gr as Vt,ho as W,Hr as Wt,bo as X,Co as Y,_o as Z,G_ as _,ra as _t,Iv as a,po as at,R_ as b,ji as bt,Mv as c,q as ct,Av as d,Ba as dt,yo as et,Nv as f,za as ft,Y_ as g,oa as gt,X_ as h,ma as ht,Rv as i,uo as it,So as j,oi as jt,Is as k,xi as kt,jv as l,Ra as lt,Z_ as m,ka as mt,Bv as n,fo as nt,Ev as o,Eo as ot,wv as p,Ma as pt,ao as q,zv as r,lo as rt,Pv as s,Qa as st,Hv as t,ro as tt,Fv as u,Va as ut,U_ as v,Pi as vt,T_ as w,Di as wt,M_ as x,Ai as xt,z_ as y,Mi as yt,io as z,Jr as zt};
|