@lovelybunch/api 1.0.75 → 1.0.76-alpha.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/lib/storage/file-storage.d.ts +1 -0
- package/dist/lib/storage/file-storage.js +9 -1
- package/dist/routes/api/v1/mail/route.d.ts +3 -3
- package/dist/routes/api/v1/slack/route.d.ts +6 -6
- package/dist/routes/api/v1/tasks/[id]/route.d.ts +2 -2
- package/dist/routes/api/v1/tasks/[id]/steps/[stepId]/route.d.ts +60 -0
- package/dist/routes/api/v1/tasks/[id]/steps/[stepId]/route.js +81 -0
- package/dist/routes/api/v1/tasks/index.js +2 -0
- package/dist/routes/api/v1/tasks/route.d.ts +2 -2
- package/package.json +4 -4
- package/static/assets/{ActivityPage-k4I7Q53O.js → ActivityPage-DxajSxG1.js} +1 -1
- package/static/assets/{ApiKeysSettingsPage-B1YvVdmg.js → ApiKeysSettingsPage-DiBqSUMz.js} +1 -1
- package/static/assets/{ArchitectureEditPage-CpowsIx2.js → ArchitectureEditPage-iflIJaCh.js} +1 -1
- package/static/assets/{ArchitecturePage-DYxC_aMR.js → ArchitecturePage-oB3FtdZ7.js} +1 -1
- package/static/assets/{AuthSettingsPage-DtSo78Y_.js → AuthSettingsPage-BY7x-6wd.js} +1 -1
- package/static/assets/{CallbackPage-bROCGapx.js → CallbackPage-CYcV3OHa.js} +1 -1
- package/static/assets/{CodePage-CPCj64rX.js → CodePage-DxJYFhiT.js} +1 -1
- package/static/assets/{CollapsibleSection-M5cXbl92.js → CollapsibleSection-BLZv27JC.js} +1 -1
- package/static/assets/{DashboardPage-B9BZZfw6.js → DashboardPage-BdsK2Vor.js} +1 -1
- package/static/assets/{GitPage-BiDtdSK1.js → GitPage-CKIIMGjF.js} +1 -1
- package/static/assets/{GitSettingsPage-THm6wDjs.js → GitSettingsPage-sI4uzGzt.js} +1 -1
- package/static/assets/{IdentityPage-BC16skg6.js → IdentityPage-vzzaKU2-.js} +1 -1
- package/static/assets/ImplementationStepsEditor-BMHTxNEX.js +6 -0
- package/static/assets/{IntegrationsSettingsPage-CC_VKIQa.js → IntegrationsSettingsPage-BzuUrHO1.js} +1 -1
- package/static/assets/{JobDetailPage-z1QQYvmU.js → JobDetailPage-C-IKmhAF.js} +1 -1
- package/static/assets/{KnowledgeDetailPage-DzHXBS7Q.js → KnowledgeDetailPage-C1RHtPzz.js} +1 -1
- package/static/assets/{KnowledgeEditPage-BwGnUH_m.js → KnowledgeEditPage-D3gIqqKn.js} +1 -1
- package/static/assets/{KnowledgePage-CGIVMS02.js → KnowledgePage-DJphs1Kg.js} +1 -1
- package/static/assets/{LoginPage-VQ3lcfLV.js → LoginPage-DVaToPHL.js} +1 -1
- package/static/assets/{MailInboxPage-DiZKqwdU.js → MailInboxPage-I-MbS647.js} +1 -1
- package/static/assets/{MailProcessingModal-DIeSQBoR.js → MailProcessingModal-DXtDHWM_.js} +1 -1
- package/static/assets/{MailReadPage-C8AACmZQ.js → MailReadPage-DUN8EQjl.js} +1 -1
- package/static/assets/{MailSentPage-C_5yFly_.js → MailSentPage-DsGgBGBQ.js} +1 -1
- package/static/assets/{McpSettingsPage-i9YHcu1s.js → McpSettingsPage-d66ZIwm7.js} +1 -1
- package/static/assets/{NewKnowledgePage-BnVY7WUD.js → NewKnowledgePage-WbN6BikQ.js} +1 -1
- package/static/assets/{NewSkillPage-DwniHD6D.js → NewSkillPage-DesCsYgS.js} +1 -1
- package/static/assets/NewTaskPage-CrmiPuuw.js +91 -0
- package/static/assets/{NotFoundPage-BbSZX_4L.js → NotFoundPage-BcTtqwNP.js} +1 -1
- package/static/assets/{NotificationsSettingsPage-C8kjcift.js → NotificationsSettingsPage-BeJw7gY7.js} +1 -1
- package/static/assets/{ProjectEditPage-DUUlIEqI.js → ProjectEditPage-DiHz-pYk.js} +1 -1
- package/static/assets/{ProjectPage-Unz9PQpA.js → ProjectPage-CKaHBZlw.js} +1 -1
- package/static/assets/{PromptsSettingsPage-DVpIuRKI.js → PromptsSettingsPage-B_Opt_KA.js} +1 -1
- package/static/assets/{ResourceDetailPage-DqHZ2KYD.js → ResourceDetailPage-BSeDQxri.js} +1 -1
- package/static/assets/{ResourcesPage-BP5tuAi-.js → ResourcesPage-YmerqN0J.js} +1 -1
- package/static/assets/{RoleEditPage-BgKu8S0-.js → RoleEditPage-Bm7HG4sg.js} +1 -1
- package/static/assets/{RolePage-Fed52Ov5.js → RolePage-DoN5_uka.js} +1 -1
- package/static/assets/{RulesSettingsPage-BQ2O0u66.js → RulesSettingsPage-yQELBKgb.js} +1 -1
- package/static/assets/{SchedulePage-jkxjuzBx.js → SchedulePage-nmchdGUK.js} +1 -1
- package/static/assets/{SkillDetailPage-k3Q2-NFd.js → SkillDetailPage-BFjBVPS8.js} +1 -1
- package/static/assets/{SkillEditPage-urF4snjo.js → SkillEditPage-CjpscD5K.js} +1 -1
- package/static/assets/{SkillsPage-DlWDhEjR.js → SkillsPage-Dr_uyKVB.js} +1 -1
- package/static/assets/{SkillsSettingsPage-BViFgckG.js → SkillsSettingsPage-BknrbJBC.js} +1 -1
- package/static/assets/{SourceInput-CAFKTHw-.js → SourceInput-LclyzQLW.js} +1 -1
- package/static/assets/{TagInput-C6lI-ePr.js → TagInput-BZ6JyIo1.js} +1 -1
- package/static/assets/{TaskDetailPage-DpbRHnW_.js → TaskDetailPage-D97oWW98.js} +1 -1
- package/static/assets/{TaskEditPage-DssRbW0h.js → TaskEditPage-BTfzRYwM.js} +1 -1
- package/static/assets/{TasksPage-CD_eo0Bj.js → TasksPage-COvedmQz.js} +1 -1
- package/static/assets/{TerminalPage-BG_wlccr.js → TerminalPage-DhbOmISZ.js} +1 -1
- package/static/assets/{TerminalSessionPage-CsK-LznK.js → TerminalSessionPage-D2rZb8Ej.js} +1 -1
- package/static/assets/{UserPreferencesPage-CWUq3efu.js → UserPreferencesPage-CgtsVqvs.js} +1 -1
- package/static/assets/{UserSettingsPage-CduI_MGS.js → UserSettingsPage-AXLWqe0G.js} +1 -1
- package/static/assets/{UtilitiesPage-BAxokhLh.js → UtilitiesPage-CxQkYrza.js} +1 -1
- package/static/assets/{alert-BXsc6_qu.js → alert-BUrHsk9_.js} +1 -1
- package/static/assets/{arrow-down-DmW_3gE8.js → arrow-down-J9YP8VW9.js} +1 -1
- package/static/assets/{arrow-left-1S-835kP.js → arrow-left-RAzvFXpe.js} +1 -1
- package/static/assets/{arrow-up-BYism_o1.js → arrow-up-CjXXRPYC.js} +1 -1
- package/static/assets/{arrow-up-down-Dw3J0a4i.js → arrow-up-down-BRoDh-fK.js} +1 -1
- package/static/assets/{badge-BUEY53dV.js → badge-CA-A_JCd.js} +1 -1
- package/static/assets/{browser-modal-DCNdI4NT.js → browser-modal-DVtwh2h7.js} +1 -1
- package/static/assets/{card-BcPlIAH5.js → card-DdrUHBUG.js} +1 -1
- package/static/assets/{chevron-left-FMmNe7yP.js → chevron-left-C4bGr2Al.js} +1 -1
- package/static/assets/{chevron-up-CqM3won3.js → chevron-up-CPpQ_jgb.js} +1 -1
- package/static/assets/{chevrons-up-DTvCkIHc.js → chevrons-up-C8oR0iOR.js} +1 -1
- package/static/assets/{circle-alert-dseM-Ib7.js → circle-alert-B3zeVGHG.js} +1 -1
- package/static/assets/{circle-check-eyo6pBP1.js → circle-check-OfRBf8tJ.js} +1 -1
- package/static/assets/{circle-check-big-jKg34xC-.js → circle-check-big-CeVxJ4hA.js} +1 -1
- package/static/assets/{circle-play-BrY_lNiH.js → circle-play-C_Chmziu.js} +1 -1
- package/static/assets/{circle-x-uqmzEce1.js → circle-x-CtfEmATn.js} +1 -1
- package/static/assets/{clipboard-tzPFoieb.js → clipboard-Z_0Z5-r1.js} +1 -1
- package/static/assets/{clock-Bjc06QBM.js → clock-B43LjbrK.js} +1 -1
- package/static/assets/{code-DrYqPukx.js → code-D77i0toJ.js} +1 -1
- package/static/assets/{download-Bg__QCLT.js → download-C8rLaNF6.js} +1 -1
- package/static/assets/{external-link-CNDy2UUo.js → external-link-D6UvIQYD.js} +1 -1
- package/static/assets/{eye-DLFBnC8t.js → eye-C3fWwYx-.js} +1 -1
- package/static/assets/{folder-git-2-DUqd0WRi.js → folder-git-2-Crtn4eyJ.js} +1 -1
- package/static/assets/{index-DFcWlnzl.js → index-SWBrq2bx.js} +3 -3
- package/static/assets/{info-D6jxZC5X.js → info-BZi8bEGv.js} +1 -1
- package/static/assets/{label-DBuh-ke5.js → label-C8Wxd6GE.js} +1 -1
- package/static/assets/{markdown-editor-B4YNQFT2.js → markdown-editor-DAk7M9Ju.js} +1 -1
- package/static/assets/{message-square-B5RWz_ff.js → message-square-BpqFAvyq.js} +1 -1
- package/static/assets/{paperclip-4A_3MaPx.js → paperclip-Dk7jEYtI.js} +1 -1
- package/static/assets/{pause-BzhKXHtR.js → pause-CX3StCWt.js} +1 -1
- package/static/assets/{play-CHIf-Rcz.js → play-CRPN1vUy.js} +1 -1
- package/static/assets/{radio-group-C1ct-VsJ.js → radio-group-DFIfCEpZ.js} +1 -1
- package/static/assets/{refresh-cw-B3OwrDUf.js → refresh-cw-DGBXSYy5.js} +1 -1
- package/static/assets/{search-Cq1ksEdp.js → search-C9jI6Lg7.js} +1 -1
- package/static/assets/{select-44mcS2_G.js → select-DgNHsbaX.js} +1 -1
- package/static/assets/status-utils-PwF3DXLL.js +1 -0
- package/static/assets/{switch-CIwjYvCt.js → switch-C2zPfM3G.js} +1 -1
- package/static/assets/{tabs-DTV6Su-h.js → tabs-B7fjkp5h.js} +1 -1
- package/static/assets/{tag-p6yeowCW.js → tag-BOwlwHfi.js} +1 -1
- package/static/assets/{terminal-preview-DN38x9Jm.js → terminal-preview-BvBQu5Sd.js} +1 -1
- package/static/assets/{use-terminal-BXJqOeJe.js → use-terminal-xv9qDaX1.js} +1 -1
- package/static/assets/{video-BH5ChaoS.js → video-CW0zFsfp.js} +1 -1
- package/static/index.html +1 -1
- package/static/assets/ImplementationStepsEditor-HliLQav5.js +0 -6
- package/static/assets/NewTaskPage-F5UX2WMc.js +0 -90
- package/static/assets/status-utils-CDkPeVfP.js +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/DashboardPage-
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/DashboardPage-BdsK2Vor.js","assets/card-DdrUHBUG.js","assets/badge-CA-A_JCd.js","assets/status-utils-PwF3DXLL.js","assets/label-C8Wxd6GE.js","assets/select-DgNHsbaX.js","assets/chevron-up-CPpQ_jgb.js","assets/use-terminal-xv9qDaX1.js","assets/terminal-preview-BvBQu5Sd.js","assets/xterm-DTxiCjtJ.js","assets/xterm-qxJ8_QYu.css","assets/circle-check-OfRBf8tJ.js","assets/chevron-left-C4bGr2Al.js","assets/search-C9jI6Lg7.js","assets/code-D77i0toJ.js","assets/folder-git-2-Crtn4eyJ.js","assets/external-link-D6UvIQYD.js","assets/play-CRPN1vUy.js","assets/clock-B43LjbrK.js","assets/circle-check-big-CeVxJ4hA.js","assets/LoginPage-DVaToPHL.js","assets/tabs-B7fjkp5h.js","assets/CallbackPage-CYcV3OHa.js","assets/circle-x-CtfEmATn.js","assets/TasksPage-COvedmQz.js","assets/TaskDetailPage-D97oWW98.js","assets/clipboard-B9ndUJKl.js","assets/arrow-left-RAzvFXpe.js","assets/clipboard-Z_0Z5-r1.js","assets/arrow-up-down-BRoDh-fK.js","assets/info-BZi8bEGv.js","assets/message-square-BpqFAvyq.js","assets/TaskEditPage-BTfzRYwM.js","assets/markdown-editor-DAk7M9Ju.js","assets/markdown-editor-DUEthZ0y.css","assets/CollapsibleSection-BLZv27JC.js","assets/ImplementationStepsEditor-BMHTxNEX.js","assets/TagInput-BZ6JyIo1.js","assets/NewTaskPage-CrmiPuuw.js","assets/TerminalPage-DhbOmISZ.js","assets/refresh-cw-DGBXSYy5.js","assets/chevrons-up-C8oR0iOR.js","assets/circle-play-C_Chmziu.js","assets/terminal-xj47PT8r.css","assets/TerminalSessionPage-D2rZb8Ej.js","assets/radio-group-DFIfCEpZ.js","assets/arrow-down-J9YP8VW9.js","assets/kiro-CX1mOsRO.js","assets/eye-C3fWwYx-.js","assets/UtilitiesPage-CxQkYrza.js","assets/CodePage-DxJYFhiT.js","assets/SkillsPage-Dr_uyKVB.js","assets/browser-modal-DVtwh2h7.js","assets/registry-ANRa5WBi.js","assets/SkillDetailPage-BFjBVPS8.js","assets/NewSkillPage-DesCsYgS.js","assets/SkillEditPage-CjpscD5K.js","assets/ResourcesPage-YmerqN0J.js","assets/video-CW0zFsfp.js","assets/download-C8rLaNF6.js","assets/tag-BOwlwHfi.js","assets/ResourceDetailPage-BSeDQxri.js","assets/KnowledgePage-DJphs1Kg.js","assets/arrow-up-CjXXRPYC.js","assets/KnowledgeDetailPage-C1RHtPzz.js","assets/KnowledgeEditPage-D3gIqqKn.js","assets/SourceInput-LclyzQLW.js","assets/NewKnowledgePage-WbN6BikQ.js","assets/ProjectPage-CKaHBZlw.js","assets/ProjectEditPage-DiHz-pYk.js","assets/ArchitecturePage-oB3FtdZ7.js","assets/ArchitectureEditPage-iflIJaCh.js","assets/RolePage-DoN5_uka.js","assets/RoleEditPage-Bm7HG4sg.js","assets/IdentityPage-vzzaKU2-.js","assets/alert-BUrHsk9_.js","assets/UserSettingsPage-AXLWqe0G.js","assets/AuthSettingsPage-BY7x-6wd.js","assets/switch-C2zPfM3G.js","assets/circle-alert-B3zeVGHG.js","assets/ApiKeysSettingsPage-DiBqSUMz.js","assets/SkillsSettingsPage-BknrbJBC.js","assets/IntegrationsSettingsPage-BzuUrHO1.js","assets/GitSettingsPage-sI4uzGzt.js","assets/McpSettingsPage-d66ZIwm7.js","assets/PromptsSettingsPage-B_Opt_KA.js","assets/RulesSettingsPage-yQELBKgb.js","assets/NotificationsSettingsPage-BeJw7gY7.js","assets/GitPage-CKIIMGjF.js","assets/SchedulePage-nmchdGUK.js","assets/pause-CX3StCWt.js","assets/JobDetailPage-C-IKmhAF.js","assets/UserPreferencesPage-CgtsVqvs.js","assets/ActivityPage-DxajSxG1.js","assets/MailInboxPage-I-MbS647.js","assets/MailProcessingModal-DXtDHWM_.js","assets/paperclip-Dk7jEYtI.js","assets/MailReadPage-DUN8EQjl.js","assets/MailSentPage-DsGgBGBQ.js"])))=>i.map(i=>d[i]);
|
|
2
2
|
function _A(e,n){for(var r=0;r<n.length;r++){const i=n[r];if(typeof i!="string"&&!Array.isArray(i)){for(const o in i)if(o!=="default"&&!(o in e)){const s=Object.getOwnPropertyDescriptor(i,o);s&&Object.defineProperty(e,o,s.get?s:{enumerable:!0,get:()=>i[o]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const n=document.createElement("link").relList;if(n&&n.supports&&n.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))i(o);new MutationObserver(o=>{for(const s of o)if(s.type==="childList")for(const c of s.addedNodes)c.tagName==="LINK"&&c.rel==="modulepreload"&&i(c)}).observe(document,{childList:!0,subtree:!0});function r(o){const s={};return o.integrity&&(s.integrity=o.integrity),o.referrerPolicy&&(s.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?s.credentials="include":o.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function i(o){if(o.ep)return;o.ep=!0;const s=r(o);fetch(o.href,s)}})();function ac(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Gd={exports:{}},so={};/**
|
|
3
3
|
* @license React
|
|
4
4
|
* react-jsx-runtime.production.js
|
|
@@ -382,7 +382,7 @@ Please change the parent <Route path="${_}"> to <Route path="${_==="/"?"*":`${_}
|
|
|
382
382
|
|
|
383
383
|
If you want to hide the \`${n.titleName}\`, you can wrap it with our VisuallyHidden component.
|
|
384
384
|
|
|
385
|
-
For more information, see https://radix-ui.com/primitives/docs/components/${n.docsSlug}`;return x.useEffect(()=>{e&&(document.getElementById(e)||console.error(r))},[r,e]),null},bD="DialogDescriptionWarning",wD=({contentRef:e,descriptionId:n})=>{const i=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${mw(bD).contentName}}.`;return x.useEffect(()=>{const o=e.current?.getAttribute("aria-describedby");n&&o&&(document.getElementById(n)||console.warn(i))},[i,e,n]),null},Hp=tw,gw=rw,Fp=iw,Vo=lw,$o=ow,Go=uw,Yo=fw,yc=hw;const yw=Hp,SD=Fp,vw=x.forwardRef(({className:e,...n},r)=>g.jsx(Vo,{className:fe("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...n,ref:r}));vw.displayName=Vo.displayName;const ED=pc("fixed z-50 gap-4 bg-background p-6 shadow-lg transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:duration-500",{variants:{side:{top:"inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",bottom:"inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",left:"inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",right:"inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm"}},defaultVariants:{side:"right"}}),qp=x.forwardRef(({side:e="right",className:n,children:r,...i},o)=>g.jsxs(SD,{children:[g.jsx(vw,{}),g.jsxs($o,{ref:o,className:fe(ED({side:e}),n),...i,children:[r,g.jsxs(yc,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary",children:[g.jsx(Yi,{className:"h-4 w-4"}),g.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));qp.displayName=$o.displayName;const Vp=({className:e,...n})=>g.jsx("div",{className:fe("flex flex-col space-y-2 text-center sm:text-left",e),...n});Vp.displayName="SheetHeader";const $p=x.forwardRef(({className:e,...n},r)=>g.jsx(Go,{ref:r,className:fe("text-lg font-semibold text-foreground",e),...n}));$p.displayName=Go.displayName;const xw=x.forwardRef(({className:e,...n},r)=>g.jsx(Yo,{ref:r,className:fe("text-sm text-muted-foreground",e),...n}));xw.displayName=Yo.displayName;function ub({className:e,...n}){return g.jsx("div",{className:fe("animate-pulse rounded-md bg-muted",e),...n})}const kD=["top","right","bottom","left"],ya=Math.min,vn=Math.max,Yu=Math.round,Au=Math.floor,ur=e=>({x:e,y:e}),CD={left:"right",right:"left",bottom:"top",top:"bottom"},AD={start:"end",end:"start"};function Xh(e,n,r){return vn(e,ya(n,r))}function Lr(e,n){return typeof e=="function"?e(n):e}function zr(e){return e.split("-")[0]}function cl(e){return e.split("-")[1]}function Gp(e){return e==="x"?"y":"x"}function Yp(e){return e==="y"?"height":"width"}const TD=new Set(["top","bottom"]);function sr(e){return TD.has(zr(e))?"y":"x"}function Kp(e){return Gp(sr(e))}function RD(e,n,r){r===void 0&&(r=!1);const i=cl(e),o=Kp(e),s=Yp(o);let c=o==="x"?i===(r?"end":"start")?"right":"left":i==="start"?"bottom":"top";return n.reference[s]>n.floating[s]&&(c=Ku(c)),[c,Ku(c)]}function _D(e){const n=Ku(e);return[Qh(e),n,Qh(n)]}function Qh(e){return e.replace(/start|end/g,n=>AD[n])}const cb=["left","right"],fb=["right","left"],ND=["top","bottom"],MD=["bottom","top"];function jD(e,n,r){switch(e){case"top":case"bottom":return r?n?fb:cb:n?cb:fb;case"left":case"right":return n?ND:MD;default:return[]}}function DD(e,n,r,i){const o=cl(e);let s=jD(zr(e),r==="start",i);return o&&(s=s.map(c=>c+"-"+o),n&&(s=s.concat(s.map(Qh)))),s}function Ku(e){return e.replace(/left|right|bottom|top/g,n=>CD[n])}function OD(e){return{top:0,right:0,bottom:0,left:0,...e}}function bw(e){return typeof e!="number"?OD(e):{top:e,right:e,bottom:e,left:e}}function Xu(e){const{x:n,y:r,width:i,height:o}=e;return{width:i,height:o,top:r,left:n,right:n+i,bottom:r+o,x:n,y:r}}function db(e,n,r){let{reference:i,floating:o}=e;const s=sr(n),c=Kp(n),f=Yp(c),h=zr(n),d=s==="y",m=i.x+i.width/2-o.width/2,y=i.y+i.height/2-o.height/2,b=i[f]/2-o[f]/2;let w;switch(h){case"top":w={x:m,y:i.y-o.height};break;case"bottom":w={x:m,y:i.y+i.height};break;case"right":w={x:i.x+i.width,y};break;case"left":w={x:i.x-o.width,y};break;default:w={x:i.x,y:i.y}}switch(cl(n)){case"start":w[c]-=b*(r&&d?-1:1);break;case"end":w[c]+=b*(r&&d?-1:1);break}return w}const LD=async(e,n,r)=>{const{placement:i="bottom",strategy:o="absolute",middleware:s=[],platform:c}=r,f=s.filter(Boolean),h=await(c.isRTL==null?void 0:c.isRTL(n));let d=await c.getElementRects({reference:e,floating:n,strategy:o}),{x:m,y}=db(d,i,h),b=i,w={},k=0;for(let C=0;C<f.length;C++){const{name:T,fn:A}=f[C],{x:_,y:N,data:O,reset:z}=await A({x:m,y,initialPlacement:i,placement:b,strategy:o,middlewareData:w,rects:d,platform:c,elements:{reference:e,floating:n}});m=_??m,y=N??y,w={...w,[T]:{...w[T],...O}},z&&k<=50&&(k++,typeof z=="object"&&(z.placement&&(b=z.placement),z.rects&&(d=z.rects===!0?await c.getElementRects({reference:e,floating:n,strategy:o}):z.rects),{x:m,y}=db(d,b,h)),C=-1)}return{x:m,y,placement:b,strategy:o,middlewareData:w}};async function No(e,n){var r;n===void 0&&(n={});const{x:i,y:o,platform:s,rects:c,elements:f,strategy:h}=e,{boundary:d="clippingAncestors",rootBoundary:m="viewport",elementContext:y="floating",altBoundary:b=!1,padding:w=0}=Lr(n,e),k=bw(w),T=f[b?y==="floating"?"reference":"floating":y],A=Xu(await s.getClippingRect({element:(r=await(s.isElement==null?void 0:s.isElement(T)))==null||r?T:T.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(f.floating)),boundary:d,rootBoundary:m,strategy:h})),_=y==="floating"?{x:i,y:o,width:c.floating.width,height:c.floating.height}:c.reference,N=await(s.getOffsetParent==null?void 0:s.getOffsetParent(f.floating)),O=await(s.isElement==null?void 0:s.isElement(N))?await(s.getScale==null?void 0:s.getScale(N))||{x:1,y:1}:{x:1,y:1},z=Xu(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:f,rect:_,offsetParent:N,strategy:h}):_);return{top:(A.top-z.top+k.top)/O.y,bottom:(z.bottom-A.bottom+k.bottom)/O.y,left:(A.left-z.left+k.left)/O.x,right:(z.right-A.right+k.right)/O.x}}const zD=e=>({name:"arrow",options:e,async fn(n){const{x:r,y:i,placement:o,rects:s,platform:c,elements:f,middlewareData:h}=n,{element:d,padding:m=0}=Lr(e,n)||{};if(d==null)return{};const y=bw(m),b={x:r,y:i},w=Kp(o),k=Yp(w),C=await c.getDimensions(d),T=w==="y",A=T?"top":"left",_=T?"bottom":"right",N=T?"clientHeight":"clientWidth",O=s.reference[k]+s.reference[w]-b[w]-s.floating[k],z=b[w]-s.reference[w],j=await(c.getOffsetParent==null?void 0:c.getOffsetParent(d));let $=j?j[N]:0;(!$||!await(c.isElement==null?void 0:c.isElement(j)))&&($=f.floating[N]||s.floating[k]);const G=O/2-z/2,ee=$/2-C[k]/2-1,P=ya(y[A],ee),ne=ya(y[_],ee),ae=P,le=$-C[k]-ne,H=$/2-C[k]/2+G,Q=Xh(ae,H,le),L=!h.arrow&&cl(o)!=null&&H!==Q&&s.reference[k]/2-(H<ae?P:ne)-C[k]/2<0,K=L?H<ae?H-ae:H-le:0;return{[w]:b[w]+K,data:{[w]:Q,centerOffset:H-Q-K,...L&&{alignmentOffset:K}},reset:L}}}),PD=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(n){var r,i;const{placement:o,middlewareData:s,rects:c,initialPlacement:f,platform:h,elements:d}=n,{mainAxis:m=!0,crossAxis:y=!0,fallbackPlacements:b,fallbackStrategy:w="bestFit",fallbackAxisSideDirection:k="none",flipAlignment:C=!0,...T}=Lr(e,n);if((r=s.arrow)!=null&&r.alignmentOffset)return{};const A=zr(o),_=sr(f),N=zr(f)===f,O=await(h.isRTL==null?void 0:h.isRTL(d.floating)),z=b||(N||!C?[Ku(f)]:_D(f)),j=k!=="none";!b&&j&&z.push(...DD(f,C,k,O));const $=[f,...z],G=await No(n,T),ee=[];let P=((i=s.flip)==null?void 0:i.overflows)||[];if(m&&ee.push(G[A]),y){const H=RD(o,c,O);ee.push(G[H[0]],G[H[1]])}if(P=[...P,{placement:o,overflows:ee}],!ee.every(H=>H<=0)){var ne,ae;const H=(((ne=s.flip)==null?void 0:ne.index)||0)+1,Q=$[H];if(Q&&(!(y==="alignment"?_!==sr(Q):!1)||P.every(U=>sr(U.placement)===_?U.overflows[0]>0:!0)))return{data:{index:H,overflows:P},reset:{placement:Q}};let L=(ae=P.filter(K=>K.overflows[0]<=0).sort((K,U)=>K.overflows[1]-U.overflows[1])[0])==null?void 0:ae.placement;if(!L)switch(w){case"bestFit":{var le;const K=(le=P.filter(U=>{if(j){const J=sr(U.placement);return J===_||J==="y"}return!0}).map(U=>[U.placement,U.overflows.filter(J=>J>0).reduce((J,E)=>J+E,0)]).sort((U,J)=>U[1]-J[1])[0])==null?void 0:le[0];K&&(L=K);break}case"initialPlacement":L=f;break}if(o!==L)return{reset:{placement:L}}}return{}}}};function hb(e,n){return{top:e.top-n.height,right:e.right-n.width,bottom:e.bottom-n.height,left:e.left-n.width}}function pb(e){return kD.some(n=>e[n]>=0)}const ID=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(n){const{rects:r}=n,{strategy:i="referenceHidden",...o}=Lr(e,n);switch(i){case"referenceHidden":{const s=await No(n,{...o,elementContext:"reference"}),c=hb(s,r.reference);return{data:{referenceHiddenOffsets:c,referenceHidden:pb(c)}}}case"escaped":{const s=await No(n,{...o,altBoundary:!0}),c=hb(s,r.floating);return{data:{escapedOffsets:c,escaped:pb(c)}}}default:return{}}}}},ww=new Set(["left","top"]);async function BD(e,n){const{placement:r,platform:i,elements:o}=e,s=await(i.isRTL==null?void 0:i.isRTL(o.floating)),c=zr(r),f=cl(r),h=sr(r)==="y",d=ww.has(c)?-1:1,m=s&&h?-1:1,y=Lr(n,e);let{mainAxis:b,crossAxis:w,alignmentAxis:k}=typeof y=="number"?{mainAxis:y,crossAxis:0,alignmentAxis:null}:{mainAxis:y.mainAxis||0,crossAxis:y.crossAxis||0,alignmentAxis:y.alignmentAxis};return f&&typeof k=="number"&&(w=f==="end"?k*-1:k),h?{x:w*m,y:b*d}:{x:b*d,y:w*m}}const UD=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(n){var r,i;const{x:o,y:s,placement:c,middlewareData:f}=n,h=await BD(n,e);return c===((r=f.offset)==null?void 0:r.placement)&&(i=f.arrow)!=null&&i.alignmentOffset?{}:{x:o+h.x,y:s+h.y,data:{...h,placement:c}}}}},HD=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(n){const{x:r,y:i,placement:o}=n,{mainAxis:s=!0,crossAxis:c=!1,limiter:f={fn:T=>{let{x:A,y:_}=T;return{x:A,y:_}}},...h}=Lr(e,n),d={x:r,y:i},m=await No(n,h),y=sr(zr(o)),b=Gp(y);let w=d[b],k=d[y];if(s){const T=b==="y"?"top":"left",A=b==="y"?"bottom":"right",_=w+m[T],N=w-m[A];w=Xh(_,w,N)}if(c){const T=y==="y"?"top":"left",A=y==="y"?"bottom":"right",_=k+m[T],N=k-m[A];k=Xh(_,k,N)}const C=f.fn({...n,[b]:w,[y]:k});return{...C,data:{x:C.x-r,y:C.y-i,enabled:{[b]:s,[y]:c}}}}}},FD=function(e){return e===void 0&&(e={}),{options:e,fn(n){const{x:r,y:i,placement:o,rects:s,middlewareData:c}=n,{offset:f=0,mainAxis:h=!0,crossAxis:d=!0}=Lr(e,n),m={x:r,y:i},y=sr(o),b=Gp(y);let w=m[b],k=m[y];const C=Lr(f,n),T=typeof C=="number"?{mainAxis:C,crossAxis:0}:{mainAxis:0,crossAxis:0,...C};if(h){const N=b==="y"?"height":"width",O=s.reference[b]-s.floating[N]+T.mainAxis,z=s.reference[b]+s.reference[N]-T.mainAxis;w<O?w=O:w>z&&(w=z)}if(d){var A,_;const N=b==="y"?"width":"height",O=ww.has(zr(o)),z=s.reference[y]-s.floating[N]+(O&&((A=c.offset)==null?void 0:A[y])||0)+(O?0:T.crossAxis),j=s.reference[y]+s.reference[N]+(O?0:((_=c.offset)==null?void 0:_[y])||0)-(O?T.crossAxis:0);k<z?k=z:k>j&&(k=j)}return{[b]:w,[y]:k}}}},qD=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(n){var r,i;const{placement:o,rects:s,platform:c,elements:f}=n,{apply:h=()=>{},...d}=Lr(e,n),m=await No(n,d),y=zr(o),b=cl(o),w=sr(o)==="y",{width:k,height:C}=s.floating;let T,A;y==="top"||y==="bottom"?(T=y,A=b===(await(c.isRTL==null?void 0:c.isRTL(f.floating))?"start":"end")?"left":"right"):(A=y,T=b==="end"?"top":"bottom");const _=C-m.top-m.bottom,N=k-m.left-m.right,O=ya(C-m[T],_),z=ya(k-m[A],N),j=!n.middlewareData.shift;let $=O,G=z;if((r=n.middlewareData.shift)!=null&&r.enabled.x&&(G=N),(i=n.middlewareData.shift)!=null&&i.enabled.y&&($=_),j&&!b){const P=vn(m.left,0),ne=vn(m.right,0),ae=vn(m.top,0),le=vn(m.bottom,0);w?G=k-2*(P!==0||ne!==0?P+ne:vn(m.left,m.right)):$=C-2*(ae!==0||le!==0?ae+le:vn(m.top,m.bottom))}await h({...n,availableWidth:G,availableHeight:$});const ee=await c.getDimensions(f.floating);return k!==ee.width||C!==ee.height?{reset:{rects:!0}}:{}}}};function vc(){return typeof window<"u"}function fl(e){return Sw(e)?(e.nodeName||"").toLowerCase():"#document"}function xn(e){var n;return(e==null||(n=e.ownerDocument)==null?void 0:n.defaultView)||window}function dr(e){var n;return(n=(Sw(e)?e.ownerDocument:e.document)||window.document)==null?void 0:n.documentElement}function Sw(e){return vc()?e instanceof Node||e instanceof xn(e).Node:!1}function Yn(e){return vc()?e instanceof Element||e instanceof xn(e).Element:!1}function fr(e){return vc()?e instanceof HTMLElement||e instanceof xn(e).HTMLElement:!1}function mb(e){return!vc()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof xn(e).ShadowRoot}const VD=new Set(["inline","contents"]);function Ko(e){const{overflow:n,overflowX:r,overflowY:i,display:o}=Kn(e);return/auto|scroll|overlay|hidden|clip/.test(n+i+r)&&!VD.has(o)}const $D=new Set(["table","td","th"]);function GD(e){return $D.has(fl(e))}const YD=[":popover-open",":modal"];function xc(e){return YD.some(n=>{try{return e.matches(n)}catch{return!1}})}const KD=["transform","translate","scale","rotate","perspective"],XD=["transform","translate","scale","rotate","perspective","filter"],QD=["paint","layout","strict","content"];function Xp(e){const n=Qp(),r=Yn(e)?Kn(e):e;return KD.some(i=>r[i]?r[i]!=="none":!1)||(r.containerType?r.containerType!=="normal":!1)||!n&&(r.backdropFilter?r.backdropFilter!=="none":!1)||!n&&(r.filter?r.filter!=="none":!1)||XD.some(i=>(r.willChange||"").includes(i))||QD.some(i=>(r.contain||"").includes(i))}function ZD(e){let n=va(e);for(;fr(n)&&!Ji(n);){if(Xp(n))return n;if(xc(n))return null;n=va(n)}return null}function Qp(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const WD=new Set(["html","body","#document"]);function Ji(e){return WD.has(fl(e))}function Kn(e){return xn(e).getComputedStyle(e)}function bc(e){return Yn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function va(e){if(fl(e)==="html")return e;const n=e.assignedSlot||e.parentNode||mb(e)&&e.host||dr(e);return mb(n)?n.host:n}function Ew(e){const n=va(e);return Ji(n)?e.ownerDocument?e.ownerDocument.body:e.body:fr(n)&&Ko(n)?n:Ew(n)}function Mo(e,n,r){var i;n===void 0&&(n=[]),r===void 0&&(r=!0);const o=Ew(e),s=o===((i=e.ownerDocument)==null?void 0:i.body),c=xn(o);if(s){const f=Zh(c);return n.concat(c,c.visualViewport||[],Ko(o)?o:[],f&&r?Mo(f):[])}return n.concat(o,Mo(o,[],r))}function Zh(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function kw(e){const n=Kn(e);let r=parseFloat(n.width)||0,i=parseFloat(n.height)||0;const o=fr(e),s=o?e.offsetWidth:r,c=o?e.offsetHeight:i,f=Yu(r)!==s||Yu(i)!==c;return f&&(r=s,i=c),{width:r,height:i,$:f}}function Zp(e){return Yn(e)?e:e.contextElement}function Xi(e){const n=Zp(e);if(!fr(n))return ur(1);const r=n.getBoundingClientRect(),{width:i,height:o,$:s}=kw(n);let c=(s?Yu(r.width):r.width)/i,f=(s?Yu(r.height):r.height)/o;return(!c||!Number.isFinite(c))&&(c=1),(!f||!Number.isFinite(f))&&(f=1),{x:c,y:f}}const JD=ur(0);function Cw(e){const n=xn(e);return!Qp()||!n.visualViewport?JD:{x:n.visualViewport.offsetLeft,y:n.visualViewport.offsetTop}}function eO(e,n,r){return n===void 0&&(n=!1),!r||n&&r!==xn(e)?!1:n}function Ya(e,n,r,i){n===void 0&&(n=!1),r===void 0&&(r=!1);const o=e.getBoundingClientRect(),s=Zp(e);let c=ur(1);n&&(i?Yn(i)&&(c=Xi(i)):c=Xi(e));const f=eO(s,r,i)?Cw(s):ur(0);let h=(o.left+f.x)/c.x,d=(o.top+f.y)/c.y,m=o.width/c.x,y=o.height/c.y;if(s){const b=xn(s),w=i&&Yn(i)?xn(i):i;let k=b,C=Zh(k);for(;C&&i&&w!==k;){const T=Xi(C),A=C.getBoundingClientRect(),_=Kn(C),N=A.left+(C.clientLeft+parseFloat(_.paddingLeft))*T.x,O=A.top+(C.clientTop+parseFloat(_.paddingTop))*T.y;h*=T.x,d*=T.y,m*=T.x,y*=T.y,h+=N,d+=O,k=xn(C),C=Zh(k)}}return Xu({width:m,height:y,x:h,y:d})}function Wp(e,n){const r=bc(e).scrollLeft;return n?n.left+r:Ya(dr(e)).left+r}function Aw(e,n,r){r===void 0&&(r=!1);const i=e.getBoundingClientRect(),o=i.left+n.scrollLeft-(r?0:Wp(e,i)),s=i.top+n.scrollTop;return{x:o,y:s}}function tO(e){let{elements:n,rect:r,offsetParent:i,strategy:o}=e;const s=o==="fixed",c=dr(i),f=n?xc(n.floating):!1;if(i===c||f&&s)return r;let h={scrollLeft:0,scrollTop:0},d=ur(1);const m=ur(0),y=fr(i);if((y||!y&&!s)&&((fl(i)!=="body"||Ko(c))&&(h=bc(i)),fr(i))){const w=Ya(i);d=Xi(i),m.x=w.x+i.clientLeft,m.y=w.y+i.clientTop}const b=c&&!y&&!s?Aw(c,h,!0):ur(0);return{width:r.width*d.x,height:r.height*d.y,x:r.x*d.x-h.scrollLeft*d.x+m.x+b.x,y:r.y*d.y-h.scrollTop*d.y+m.y+b.y}}function nO(e){return Array.from(e.getClientRects())}function rO(e){const n=dr(e),r=bc(e),i=e.ownerDocument.body,o=vn(n.scrollWidth,n.clientWidth,i.scrollWidth,i.clientWidth),s=vn(n.scrollHeight,n.clientHeight,i.scrollHeight,i.clientHeight);let c=-r.scrollLeft+Wp(e);const f=-r.scrollTop;return Kn(i).direction==="rtl"&&(c+=vn(n.clientWidth,i.clientWidth)-o),{width:o,height:s,x:c,y:f}}function aO(e,n){const r=xn(e),i=dr(e),o=r.visualViewport;let s=i.clientWidth,c=i.clientHeight,f=0,h=0;if(o){s=o.width,c=o.height;const d=Qp();(!d||d&&n==="fixed")&&(f=o.offsetLeft,h=o.offsetTop)}return{width:s,height:c,x:f,y:h}}const iO=new Set(["absolute","fixed"]);function lO(e,n){const r=Ya(e,!0,n==="fixed"),i=r.top+e.clientTop,o=r.left+e.clientLeft,s=fr(e)?Xi(e):ur(1),c=e.clientWidth*s.x,f=e.clientHeight*s.y,h=o*s.x,d=i*s.y;return{width:c,height:f,x:h,y:d}}function gb(e,n,r){let i;if(n==="viewport")i=aO(e,r);else if(n==="document")i=rO(dr(e));else if(Yn(n))i=lO(n,r);else{const o=Cw(e);i={x:n.x-o.x,y:n.y-o.y,width:n.width,height:n.height}}return Xu(i)}function Tw(e,n){const r=va(e);return r===n||!Yn(r)||Ji(r)?!1:Kn(r).position==="fixed"||Tw(r,n)}function oO(e,n){const r=n.get(e);if(r)return r;let i=Mo(e,[],!1).filter(f=>Yn(f)&&fl(f)!=="body"),o=null;const s=Kn(e).position==="fixed";let c=s?va(e):e;for(;Yn(c)&&!Ji(c);){const f=Kn(c),h=Xp(c);!h&&f.position==="fixed"&&(o=null),(s?!h&&!o:!h&&f.position==="static"&&!!o&&iO.has(o.position)||Ko(c)&&!h&&Tw(e,c))?i=i.filter(m=>m!==c):o=f,c=va(c)}return n.set(e,i),i}function sO(e){let{element:n,boundary:r,rootBoundary:i,strategy:o}=e;const c=[...r==="clippingAncestors"?xc(n)?[]:oO(n,this._c):[].concat(r),i],f=c[0],h=c.reduce((d,m)=>{const y=gb(n,m,o);return d.top=vn(y.top,d.top),d.right=ya(y.right,d.right),d.bottom=ya(y.bottom,d.bottom),d.left=vn(y.left,d.left),d},gb(n,f,o));return{width:h.right-h.left,height:h.bottom-h.top,x:h.left,y:h.top}}function uO(e){const{width:n,height:r}=kw(e);return{width:n,height:r}}function cO(e,n,r){const i=fr(n),o=dr(n),s=r==="fixed",c=Ya(e,!0,s,n);let f={scrollLeft:0,scrollTop:0};const h=ur(0);function d(){h.x=Wp(o)}if(i||!i&&!s)if((fl(n)!=="body"||Ko(o))&&(f=bc(n)),i){const w=Ya(n,!0,s,n);h.x=w.x+n.clientLeft,h.y=w.y+n.clientTop}else o&&d();s&&!i&&o&&d();const m=o&&!i&&!s?Aw(o,f):ur(0),y=c.left+f.scrollLeft-h.x-m.x,b=c.top+f.scrollTop-h.y-m.y;return{x:y,y:b,width:c.width,height:c.height}}function ph(e){return Kn(e).position==="static"}function yb(e,n){if(!fr(e)||Kn(e).position==="fixed")return null;if(n)return n(e);let r=e.offsetParent;return dr(e)===r&&(r=r.ownerDocument.body),r}function Rw(e,n){const r=xn(e);if(xc(e))return r;if(!fr(e)){let o=va(e);for(;o&&!Ji(o);){if(Yn(o)&&!ph(o))return o;o=va(o)}return r}let i=yb(e,n);for(;i&&GD(i)&&ph(i);)i=yb(i,n);return i&&Ji(i)&&ph(i)&&!Xp(i)?r:i||ZD(e)||r}const fO=async function(e){const n=this.getOffsetParent||Rw,r=this.getDimensions,i=await r(e.floating);return{reference:cO(e.reference,await n(e.floating),e.strategy),floating:{x:0,y:0,width:i.width,height:i.height}}};function dO(e){return Kn(e).direction==="rtl"}const hO={convertOffsetParentRelativeRectToViewportRelativeRect:tO,getDocumentElement:dr,getClippingRect:sO,getOffsetParent:Rw,getElementRects:fO,getClientRects:nO,getDimensions:uO,getScale:Xi,isElement:Yn,isRTL:dO};function _w(e,n){return e.x===n.x&&e.y===n.y&&e.width===n.width&&e.height===n.height}function pO(e,n){let r=null,i;const o=dr(e);function s(){var f;clearTimeout(i),(f=r)==null||f.disconnect(),r=null}function c(f,h){f===void 0&&(f=!1),h===void 0&&(h=1),s();const d=e.getBoundingClientRect(),{left:m,top:y,width:b,height:w}=d;if(f||n(),!b||!w)return;const k=Au(y),C=Au(o.clientWidth-(m+b)),T=Au(o.clientHeight-(y+w)),A=Au(m),N={rootMargin:-k+"px "+-C+"px "+-T+"px "+-A+"px",threshold:vn(0,ya(1,h))||1};let O=!0;function z(j){const $=j[0].intersectionRatio;if($!==h){if(!O)return c();$?c(!1,$):i=setTimeout(()=>{c(!1,1e-7)},1e3)}$===1&&!_w(d,e.getBoundingClientRect())&&c(),O=!1}try{r=new IntersectionObserver(z,{...N,root:o.ownerDocument})}catch{r=new IntersectionObserver(z,N)}r.observe(e)}return c(!0),s}function mO(e,n,r,i){i===void 0&&(i={});const{ancestorScroll:o=!0,ancestorResize:s=!0,elementResize:c=typeof ResizeObserver=="function",layoutShift:f=typeof IntersectionObserver=="function",animationFrame:h=!1}=i,d=Zp(e),m=o||s?[...d?Mo(d):[],...Mo(n)]:[];m.forEach(A=>{o&&A.addEventListener("scroll",r,{passive:!0}),s&&A.addEventListener("resize",r)});const y=d&&f?pO(d,r):null;let b=-1,w=null;c&&(w=new ResizeObserver(A=>{let[_]=A;_&&_.target===d&&w&&(w.unobserve(n),cancelAnimationFrame(b),b=requestAnimationFrame(()=>{var N;(N=w)==null||N.observe(n)})),r()}),d&&!h&&w.observe(d),w.observe(n));let k,C=h?Ya(e):null;h&&T();function T(){const A=Ya(e);C&&!_w(C,A)&&r(),C=A,k=requestAnimationFrame(T)}return r(),()=>{var A;m.forEach(_=>{o&&_.removeEventListener("scroll",r),s&&_.removeEventListener("resize",r)}),y?.(),(A=w)==null||A.disconnect(),w=null,h&&cancelAnimationFrame(k)}}const gO=UD,yO=HD,vO=PD,xO=qD,bO=ID,vb=zD,wO=FD,SO=(e,n,r)=>{const i=new Map,o={platform:hO,...r},s={...o.platform,_c:i};return LD(e,n,{...o,platform:s})};var EO=typeof document<"u",kO=function(){},Bu=EO?x.useLayoutEffect:kO;function Qu(e,n){if(e===n)return!0;if(typeof e!=typeof n)return!1;if(typeof e=="function"&&e.toString()===n.toString())return!0;let r,i,o;if(e&&n&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!==n.length)return!1;for(i=r;i--!==0;)if(!Qu(e[i],n[i]))return!1;return!0}if(o=Object.keys(e),r=o.length,r!==Object.keys(n).length)return!1;for(i=r;i--!==0;)if(!{}.hasOwnProperty.call(n,o[i]))return!1;for(i=r;i--!==0;){const s=o[i];if(!(s==="_owner"&&e.$$typeof)&&!Qu(e[s],n[s]))return!1}return!0}return e!==e&&n!==n}function Nw(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function xb(e,n){const r=Nw(e);return Math.round(n*r)/r}function mh(e){const n=x.useRef(e);return Bu(()=>{n.current=e}),n}function CO(e){e===void 0&&(e={});const{placement:n="bottom",strategy:r="absolute",middleware:i=[],platform:o,elements:{reference:s,floating:c}={},transform:f=!0,whileElementsMounted:h,open:d}=e,[m,y]=x.useState({x:0,y:0,strategy:r,placement:n,middlewareData:{},isPositioned:!1}),[b,w]=x.useState(i);Qu(b,i)||w(i);const[k,C]=x.useState(null),[T,A]=x.useState(null),_=x.useCallback(U=>{U!==j.current&&(j.current=U,C(U))},[]),N=x.useCallback(U=>{U!==$.current&&($.current=U,A(U))},[]),O=s||k,z=c||T,j=x.useRef(null),$=x.useRef(null),G=x.useRef(m),ee=h!=null,P=mh(h),ne=mh(o),ae=mh(d),le=x.useCallback(()=>{if(!j.current||!$.current)return;const U={placement:n,strategy:r,middleware:b};ne.current&&(U.platform=ne.current),SO(j.current,$.current,U).then(J=>{const E={...J,isPositioned:ae.current!==!1};H.current&&!Qu(G.current,E)&&(G.current=E,oc.flushSync(()=>{y(E)}))})},[b,n,r,ne,ae]);Bu(()=>{d===!1&&G.current.isPositioned&&(G.current.isPositioned=!1,y(U=>({...U,isPositioned:!1})))},[d]);const H=x.useRef(!1);Bu(()=>(H.current=!0,()=>{H.current=!1}),[]),Bu(()=>{if(O&&(j.current=O),z&&($.current=z),O&&z){if(P.current)return P.current(O,z,le);le()}},[O,z,le,P,ee]);const Q=x.useMemo(()=>({reference:j,floating:$,setReference:_,setFloating:N}),[_,N]),L=x.useMemo(()=>({reference:O,floating:z}),[O,z]),K=x.useMemo(()=>{const U={position:r,left:0,top:0};if(!L.floating)return U;const J=xb(L.floating,m.x),E=xb(L.floating,m.y);return f?{...U,transform:"translate("+J+"px, "+E+"px)",...Nw(L.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:J,top:E}},[r,f,L.floating,m.x,m.y]);return x.useMemo(()=>({...m,update:le,refs:Q,elements:L,floatingStyles:K}),[m,le,Q,L,K])}const AO=e=>{function n(r){return{}.hasOwnProperty.call(r,"current")}return{name:"arrow",options:e,fn(r){const{element:i,padding:o}=typeof e=="function"?e(r):e;return i&&n(i)?i.current!=null?vb({element:i.current,padding:o}).fn(r):{}:i?vb({element:i,padding:o}).fn(r):{}}}},TO=(e,n)=>({...gO(e),options:[e,n]}),RO=(e,n)=>({...yO(e),options:[e,n]}),_O=(e,n)=>({...wO(e),options:[e,n]}),NO=(e,n)=>({...vO(e),options:[e,n]}),MO=(e,n)=>({...xO(e),options:[e,n]}),jO=(e,n)=>({...bO(e),options:[e,n]}),DO=(e,n)=>({...AO(e),options:[e,n]});var OO="Arrow",Mw=x.forwardRef((e,n)=>{const{children:r,width:i=10,height:o=5,...s}=e;return g.jsx(Fe.svg,{...s,ref:n,width:i,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?r:g.jsx("polygon",{points:"0,0 30,0 15,10"})})});Mw.displayName=OO;var LO=Mw;function jw(e){const[n,r]=x.useState(void 0);return cr(()=>{if(e){r({width:e.offsetWidth,height:e.offsetHeight});const i=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const s=o[0];let c,f;if("borderBoxSize"in s){const h=s.borderBoxSize,d=Array.isArray(h)?h[0]:h;c=d.inlineSize,f=d.blockSize}else c=e.offsetWidth,f=e.offsetHeight;r({width:c,height:f})});return i.observe(e,{box:"border-box"}),()=>i.unobserve(e)}else r(void 0)},[e]),n}var Jp="Popper",[Dw,wc]=Qn(Jp),[zO,Ow]=Dw(Jp),Lw=e=>{const{__scopePopper:n,children:r}=e,[i,o]=x.useState(null);return g.jsx(zO,{scope:n,anchor:i,onAnchorChange:o,children:r})};Lw.displayName=Jp;var zw="PopperAnchor",Pw=x.forwardRef((e,n)=>{const{__scopePopper:r,virtualRef:i,...o}=e,s=Ow(zw,r),c=x.useRef(null),f=Xe(n,c),h=x.useRef(null);return x.useEffect(()=>{const d=h.current;h.current=i?.current||c.current,d!==h.current&&s.onAnchorChange(h.current)}),i?null:g.jsx(Fe.div,{...o,ref:f})});Pw.displayName=zw;var em="PopperContent",[PO,IO]=Dw(em),Iw=x.forwardRef((e,n)=>{const{__scopePopper:r,side:i="bottom",sideOffset:o=0,align:s="center",alignOffset:c=0,arrowPadding:f=0,avoidCollisions:h=!0,collisionBoundary:d=[],collisionPadding:m=0,sticky:y="partial",hideWhenDetached:b=!1,updatePositionStrategy:w="optimized",onPlaced:k,...C}=e,T=Ow(em,r),[A,_]=x.useState(null),N=Xe(n,xe=>_(xe)),[O,z]=x.useState(null),j=jw(O),$=j?.width??0,G=j?.height??0,ee=i+(s!=="center"?"-"+s:""),P=typeof m=="number"?m:{top:0,right:0,bottom:0,left:0,...m},ne=Array.isArray(d)?d:[d],ae=ne.length>0,le={padding:P,boundary:ne.filter(UO),altBoundary:ae},{refs:H,floatingStyles:Q,placement:L,isPositioned:K,middlewareData:U}=CO({strategy:"fixed",placement:ee,whileElementsMounted:(...xe)=>mO(...xe,{animationFrame:w==="always"}),elements:{reference:T.anchor},middleware:[TO({mainAxis:o+G,alignmentAxis:c}),h&&RO({mainAxis:!0,crossAxis:!1,limiter:y==="partial"?_O():void 0,...le}),h&&NO({...le}),MO({...le,apply:({elements:xe,rects:Ee,availableWidth:Qe,availableHeight:bt})=>{const{width:Rt,height:It}=Ee.reference,Gt=xe.floating.style;Gt.setProperty("--radix-popper-available-width",`${Qe}px`),Gt.setProperty("--radix-popper-available-height",`${bt}px`),Gt.setProperty("--radix-popper-anchor-width",`${Rt}px`),Gt.setProperty("--radix-popper-anchor-height",`${It}px`)}}),O&&DO({element:O,padding:f}),HO({arrowWidth:$,arrowHeight:G}),b&&jO({strategy:"referenceHidden",...le})]}),[J,E]=Hw(L),Z=kt(k);cr(()=>{K&&Z?.()},[K,Z]);const oe=U.arrow?.x,M=U.arrow?.y,se=U.arrow?.centerOffset!==0,[Se,he]=x.useState();return cr(()=>{A&&he(window.getComputedStyle(A).zIndex)},[A]),g.jsx("div",{ref:H.setFloating,"data-radix-popper-content-wrapper":"",style:{...Q,transform:K?Q.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Se,"--radix-popper-transform-origin":[U.transformOrigin?.x,U.transformOrigin?.y].join(" "),...U.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:g.jsx(PO,{scope:r,placedSide:J,onArrowChange:z,arrowX:oe,arrowY:M,shouldHideArrow:se,children:g.jsx(Fe.div,{"data-side":J,"data-align":E,...C,ref:N,style:{...C.style,animation:K?void 0:"none"}})})})});Iw.displayName=em;var Bw="PopperArrow",BO={top:"bottom",right:"left",bottom:"top",left:"right"},Uw=x.forwardRef(function(n,r){const{__scopePopper:i,...o}=n,s=IO(Bw,i),c=BO[s.placedSide];return g.jsx("span",{ref:s.onArrowChange,style:{position:"absolute",left:s.arrowX,top:s.arrowY,[c]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[s.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[s.placedSide],visibility:s.shouldHideArrow?"hidden":void 0},children:g.jsx(LO,{...o,ref:r,style:{...o.style,display:"block"}})})});Uw.displayName=Bw;function UO(e){return e!==null}var HO=e=>({name:"transformOrigin",options:e,fn(n){const{placement:r,rects:i,middlewareData:o}=n,c=o.arrow?.centerOffset!==0,f=c?0:e.arrowWidth,h=c?0:e.arrowHeight,[d,m]=Hw(r),y={start:"0%",center:"50%",end:"100%"}[m],b=(o.arrow?.x??0)+f/2,w=(o.arrow?.y??0)+h/2;let k="",C="";return d==="bottom"?(k=c?y:`${b}px`,C=`${-h}px`):d==="top"?(k=c?y:`${b}px`,C=`${i.floating.height+h}px`):d==="right"?(k=`${-h}px`,C=c?y:`${w}px`):d==="left"&&(k=`${i.floating.width+h}px`,C=c?y:`${w}px`),{data:{x:k,y:C}}}});function Hw(e){const[n,r="center"]=e.split("-");return[n,r]}var Fw=Lw,qw=Pw,Vw=Iw,$w=Uw,[Sc,DB]=Qn("Tooltip",[wc]),Ec=wc(),Gw="TooltipProvider",FO=700,Wh="tooltip.open",[qO,tm]=Sc(Gw),Yw=e=>{const{__scopeTooltip:n,delayDuration:r=FO,skipDelayDuration:i=300,disableHoverableContent:o=!1,children:s}=e,c=x.useRef(!0),f=x.useRef(!1),h=x.useRef(0);return x.useEffect(()=>{const d=h.current;return()=>window.clearTimeout(d)},[]),g.jsx(qO,{scope:n,isOpenDelayedRef:c,delayDuration:r,onOpen:x.useCallback(()=>{window.clearTimeout(h.current),c.current=!1},[]),onClose:x.useCallback(()=>{window.clearTimeout(h.current),h.current=window.setTimeout(()=>c.current=!0,i)},[i]),isPointerInTransitRef:f,onPointerInTransitChange:x.useCallback(d=>{f.current=d},[]),disableHoverableContent:o,children:s})};Yw.displayName=Gw;var jo="Tooltip",[VO,kc]=Sc(jo),Kw=e=>{const{__scopeTooltip:n,children:r,open:i,defaultOpen:o,onOpenChange:s,disableHoverableContent:c,delayDuration:f}=e,h=tm(jo,e.__scopeTooltip),d=Ec(n),[m,y]=x.useState(null),b=$a(),w=x.useRef(0),k=c??h.disableHoverableContent,C=f??h.delayDuration,T=x.useRef(!1),[A,_]=ol({prop:i,defaultProp:o??!1,onChange:$=>{$?(h.onOpen(),document.dispatchEvent(new CustomEvent(Wh))):h.onClose(),s?.($)},caller:jo}),N=x.useMemo(()=>A?T.current?"delayed-open":"instant-open":"closed",[A]),O=x.useCallback(()=>{window.clearTimeout(w.current),w.current=0,T.current=!1,_(!0)},[_]),z=x.useCallback(()=>{window.clearTimeout(w.current),w.current=0,_(!1)},[_]),j=x.useCallback(()=>{window.clearTimeout(w.current),w.current=window.setTimeout(()=>{T.current=!0,_(!0),w.current=0},C)},[C,_]);return x.useEffect(()=>()=>{w.current&&(window.clearTimeout(w.current),w.current=0)},[]),g.jsx(Fw,{...d,children:g.jsx(VO,{scope:n,contentId:b,open:A,stateAttribute:N,trigger:m,onTriggerChange:y,onTriggerEnter:x.useCallback(()=>{h.isOpenDelayedRef.current?j():O()},[h.isOpenDelayedRef,j,O]),onTriggerLeave:x.useCallback(()=>{k?z():(window.clearTimeout(w.current),w.current=0)},[z,k]),onOpen:O,onClose:z,disableHoverableContent:k,children:r})})};Kw.displayName=jo;var Jh="TooltipTrigger",Xw=x.forwardRef((e,n)=>{const{__scopeTooltip:r,...i}=e,o=kc(Jh,r),s=tm(Jh,r),c=Ec(r),f=x.useRef(null),h=Xe(n,f,o.onTriggerChange),d=x.useRef(!1),m=x.useRef(!1),y=x.useCallback(()=>d.current=!1,[]);return x.useEffect(()=>()=>document.removeEventListener("pointerup",y),[y]),g.jsx(qw,{asChild:!0,...c,children:g.jsx(Fe.button,{"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute,...i,ref:h,onPointerMove:pe(e.onPointerMove,b=>{b.pointerType!=="touch"&&!m.current&&!s.isPointerInTransitRef.current&&(o.onTriggerEnter(),m.current=!0)}),onPointerLeave:pe(e.onPointerLeave,()=>{o.onTriggerLeave(),m.current=!1}),onPointerDown:pe(e.onPointerDown,()=>{o.open&&o.onClose(),d.current=!0,document.addEventListener("pointerup",y,{once:!0})}),onFocus:pe(e.onFocus,()=>{d.current||o.onOpen()}),onBlur:pe(e.onBlur,o.onClose),onClick:pe(e.onClick,o.onClose)})})});Xw.displayName=Jh;var $O="TooltipPortal",[OB,GO]=Sc($O,{forceMount:void 0}),el="TooltipContent",Qw=x.forwardRef((e,n)=>{const r=GO(el,e.__scopeTooltip),{forceMount:i=r.forceMount,side:o="top",...s}=e,c=kc(el,e.__scopeTooltip);return g.jsx(Zt,{present:i||c.open,children:c.disableHoverableContent?g.jsx(Zw,{side:o,...s,ref:n}):g.jsx(YO,{side:o,...s,ref:n})})}),YO=x.forwardRef((e,n)=>{const r=kc(el,e.__scopeTooltip),i=tm(el,e.__scopeTooltip),o=x.useRef(null),s=Xe(n,o),[c,f]=x.useState(null),{trigger:h,onClose:d}=r,m=o.current,{onPointerInTransitChange:y}=i,b=x.useCallback(()=>{f(null),y(!1)},[y]),w=x.useCallback((k,C)=>{const T=k.currentTarget,A={x:k.clientX,y:k.clientY},_=WO(A,T.getBoundingClientRect()),N=JO(A,_),O=e4(C.getBoundingClientRect()),z=n4([...N,...O]);f(z),y(!0)},[y]);return x.useEffect(()=>()=>b(),[b]),x.useEffect(()=>{if(h&&m){const k=T=>w(T,m),C=T=>w(T,h);return h.addEventListener("pointerleave",k),m.addEventListener("pointerleave",C),()=>{h.removeEventListener("pointerleave",k),m.removeEventListener("pointerleave",C)}}},[h,m,w,b]),x.useEffect(()=>{if(c){const k=C=>{const T=C.target,A={x:C.clientX,y:C.clientY},_=h?.contains(T)||m?.contains(T),N=!t4(A,c);_?b():N&&(b(),d())};return document.addEventListener("pointermove",k),()=>document.removeEventListener("pointermove",k)}},[h,m,c,d,b]),g.jsx(Zw,{...e,ref:s})}),[KO,XO]=Sc(jo,{isInside:!1}),QO=K0("TooltipContent"),Zw=x.forwardRef((e,n)=>{const{__scopeTooltip:r,children:i,"aria-label":o,onEscapeKeyDown:s,onPointerDownOutside:c,...f}=e,h=kc(el,r),d=Ec(r),{onClose:m}=h;return x.useEffect(()=>(document.addEventListener(Wh,m),()=>document.removeEventListener(Wh,m)),[m]),x.useEffect(()=>{if(h.trigger){const y=b=>{b.target?.contains(h.trigger)&&m()};return window.addEventListener("scroll",y,{capture:!0}),()=>window.removeEventListener("scroll",y,{capture:!0})}},[h.trigger,m]),g.jsx(Fo,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:s,onPointerDownOutside:c,onFocusOutside:y=>y.preventDefault(),onDismiss:m,children:g.jsxs(Vw,{"data-state":h.stateAttribute,...d,...f,ref:n,style:{...f.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[g.jsx(QO,{children:i}),g.jsx(KO,{scope:r,isInside:!0,children:g.jsx(b_,{id:h.contentId,role:"tooltip",children:o||i})})]})})});Qw.displayName=el;var Ww="TooltipArrow",ZO=x.forwardRef((e,n)=>{const{__scopeTooltip:r,...i}=e,o=Ec(r);return XO(Ww,r).isInside?null:g.jsx($w,{...o,...i,ref:n})});ZO.displayName=Ww;function WO(e,n){const r=Math.abs(n.top-e.y),i=Math.abs(n.bottom-e.y),o=Math.abs(n.right-e.x),s=Math.abs(n.left-e.x);switch(Math.min(r,i,o,s)){case s:return"left";case o:return"right";case r:return"top";case i:return"bottom";default:throw new Error("unreachable")}}function JO(e,n,r=5){const i=[];switch(n){case"top":i.push({x:e.x-r,y:e.y+r},{x:e.x+r,y:e.y+r});break;case"bottom":i.push({x:e.x-r,y:e.y-r},{x:e.x+r,y:e.y-r});break;case"left":i.push({x:e.x+r,y:e.y-r},{x:e.x+r,y:e.y+r});break;case"right":i.push({x:e.x-r,y:e.y-r},{x:e.x-r,y:e.y+r});break}return i}function e4(e){const{top:n,right:r,bottom:i,left:o}=e;return[{x:o,y:n},{x:r,y:n},{x:r,y:i},{x:o,y:i}]}function t4(e,n){const{x:r,y:i}=e;let o=!1;for(let s=0,c=n.length-1;s<n.length;c=s++){const f=n[s],h=n[c],d=f.x,m=f.y,y=h.x,b=h.y;m>i!=b>i&&r<(y-d)*(i-m)/(b-m)+d&&(o=!o)}return o}function n4(e){const n=e.slice();return n.sort((r,i)=>r.x<i.x?-1:r.x>i.x?1:r.y<i.y?-1:r.y>i.y?1:0),r4(n)}function r4(e){if(e.length<=1)return e.slice();const n=[];for(let i=0;i<e.length;i++){const o=e[i];for(;n.length>=2;){const s=n[n.length-1],c=n[n.length-2];if((s.x-c.x)*(o.y-c.y)>=(s.y-c.y)*(o.x-c.x))n.pop();else break}n.push(o)}n.pop();const r=[];for(let i=e.length-1;i>=0;i--){const o=e[i];for(;r.length>=2;){const s=r[r.length-1],c=r[r.length-2];if((s.x-c.x)*(o.y-c.y)>=(s.y-c.y)*(o.x-c.x))r.pop();else break}r.push(o)}return r.pop(),n.length===1&&r.length===1&&n[0].x===r[0].x&&n[0].y===r[0].y?n:n.concat(r)}var a4=Yw,i4=Kw,l4=Xw,Jw=Qw;const o4=a4,s4=i4,u4=l4,eS=x.forwardRef(({className:e,sideOffset:n=4,...r},i)=>g.jsx(Jw,{ref:i,sideOffset:n,className:fe("z-50 overflow-hidden rounded-md border bg-popover px-3 py-1.5 text-sm text-popover-foreground shadow-md animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...r}));eS.displayName=Jw.displayName;const c4="sidebar_state",f4=3600*24*7,d4="16rem",h4="18rem",p4="3rem",m4="b",tS=x.createContext(null);function Cc(){const e=x.useContext(tS);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const nS=x.forwardRef(({defaultOpen:e=!0,open:n,onOpenChange:r,className:i,style:o,children:s,...c},f)=>{const h=P1(),[d,m]=x.useState(!1),[y,b]=x.useState(e),w=n??y,k=x.useCallback(_=>{const N=typeof _=="function"?_(w):_;r?r(N):b(N),document.cookie=`${c4}=${N}; path=/; max-age=${f4}`},[r,w]),C=x.useCallback(()=>h?m(_=>!_):k(_=>!_),[h,k,m]);x.useEffect(()=>{const _=N=>{N.key===m4&&(N.metaKey||N.ctrlKey)&&(N.preventDefault(),C())};return window.addEventListener("keydown",_),()=>window.removeEventListener("keydown",_)},[C]);const T=w?"expanded":"collapsed",A=x.useMemo(()=>({state:T,open:w,setOpen:k,isMobile:h,openMobile:d,setOpenMobile:m,toggleSidebar:C}),[T,w,k,h,d,m,C]);return g.jsx(tS.Provider,{value:A,children:g.jsx(o4,{delayDuration:0,children:g.jsx("div",{style:{"--sidebar-width":d4,"--sidebar-width-icon":p4,...o},className:fe("group/sidebar-wrapper flex min-h-svh w-full has-[[data-variant=inset]]:bg-sidebar",i),ref:f,...c,children:s})})})});nS.displayName="SidebarProvider";const rS=x.forwardRef(({side:e="left",variant:n="sidebar",collapsible:r="offcanvas",className:i,children:o,...s},c)=>{const{isMobile:f,state:h,openMobile:d,setOpenMobile:m}=Cc();return r==="none"?g.jsx("div",{className:fe("flex h-full w-[--sidebar-width] flex-col bg-sidebar text-sidebar-foreground",i),ref:c,...s,children:o}):f?g.jsx(yw,{open:d,onOpenChange:m,...s,children:g.jsxs(qp,{"data-sidebar":"sidebar","data-mobile":"true",className:"w-[--sidebar-width] bg-sidebar p-0 text-sidebar-foreground [&>button]:hidden",style:{"--sidebar-width":h4},side:e,children:[g.jsxs(Vp,{className:"sr-only",children:[g.jsx($p,{children:"Sidebar"}),g.jsx(xw,{children:"Displays the mobile sidebar."})]}),g.jsx("div",{className:"flex h-full w-full flex-col",children:o})]})}):g.jsxs("div",{ref:c,className:"group peer hidden text-sidebar-foreground md:block","data-state":h,"data-collapsible":h==="collapsed"?r:"","data-variant":n,"data-side":e,children:[g.jsx("div",{className:fe("relative w-[--sidebar-width] bg-transparent transition-[width] duration-200 ease-linear","group-data-[collapsible=offcanvas]:w-0","group-data-[side=right]:rotate-180",n==="floating"||n==="inset"?"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon]")}),g.jsx("div",{className:fe("fixed inset-y-0 z-10 hidden h-svh w-[--sidebar-width] transition-[left,right,width] duration-200 ease-linear md:flex",e==="left"?"left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]":"right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]",n==="floating"||n==="inset"?"p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon] group-data-[side=left]:border-r group-data-[side=right]:border-l",i),...s,children:g.jsx("div",{"data-sidebar":"sidebar",className:"flex h-full w-full flex-col bg-sidebar group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:border group-data-[variant=floating]:border-sidebar-border group-data-[variant=floating]:shadow",children:o})})]})});rS.displayName="Sidebar";const aS=x.forwardRef(({className:e,onClick:n,...r},i)=>{const{toggleSidebar:o}=Cc();return g.jsxs(pt,{ref:i,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:fe("h-7 w-7",e),onClick:s=>{n?.(s),o()},...r,children:[g.jsx($N,{}),g.jsx("span",{className:"sr-only",children:"Toggle Sidebar"})]})});aS.displayName="SidebarTrigger";const g4=x.forwardRef(({className:e,...n},r)=>{const{toggleSidebar:i}=Cc();return g.jsx("button",{ref:r,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:i,title:"Toggle Sidebar",className:fe("absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] hover:after:bg-sidebar-border group-data-[side=left]:-right-4 group-data-[side=right]:left-0 sm:flex","[[data-side=left]_&]:cursor-w-resize [[data-side=right]_&]:cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize","group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full group-data-[collapsible=offcanvas]:hover:bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:-right-2","[[data-side=right][data-collapsible=offcanvas]_&]:-left-2",e),...n})});g4.displayName="SidebarRail";const iS=x.forwardRef(({className:e,...n},r)=>g.jsx("main",{ref:r,className:fe("relative flex w-full flex-1 flex-col bg-background","md:peer-data-[variant=inset]:m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:ml-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow",e),...n}));iS.displayName="SidebarInset";const y4=x.forwardRef(({className:e,...n},r)=>g.jsx(I1,{ref:r,"data-sidebar":"input",className:fe("h-8 w-full bg-background shadow-none focus-visible:ring-2 focus-visible:ring-sidebar-ring",e),...n}));y4.displayName="SidebarInput";const lS=x.forwardRef(({className:e,...n},r)=>g.jsx("div",{ref:r,"data-sidebar":"header",className:fe("flex flex-col gap-2 p-2",e),...n}));lS.displayName="SidebarHeader";const oS=x.forwardRef(({className:e,...n},r)=>g.jsx("div",{ref:r,"data-sidebar":"footer",className:fe("flex flex-col gap-2 p-2",e),...n}));oS.displayName="SidebarFooter";const v4=x.forwardRef(({className:e,...n},r)=>g.jsx(H1,{ref:r,"data-sidebar":"separator",className:fe("mx-2 w-auto bg-sidebar-border",e),...n}));v4.displayName="SidebarSeparator";const sS=x.forwardRef(({className:e,...n},r)=>g.jsx("div",{ref:r,"data-sidebar":"content",className:fe("flex min-h-0 flex-1 flex-col gap-2 overflow-auto group-data-[collapsible=icon]:overflow-hidden",e),...n}));sS.displayName="SidebarContent";const yo=x.forwardRef(({className:e,...n},r)=>g.jsx("div",{ref:r,"data-sidebar":"group",className:fe("relative flex w-full min-w-0 flex-col p-2",e),...n}));yo.displayName="SidebarGroup";const Uu=x.forwardRef(({className:e,asChild:n=!1,...r},i)=>{const o=n?ll:"div";return g.jsx(o,{ref:i,"data-sidebar":"group-label",className:fe("flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium text-sidebar-foreground/70 outline-none ring-sidebar-ring transition-[margin,opacity] duration-200 ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0",e),...r})});Uu.displayName="SidebarGroupLabel";const x4=x.forwardRef(({className:e,asChild:n=!1,...r},i)=>{const o=n?ll:"button";return g.jsx(o,{ref:i,"data-sidebar":"group-action",className:fe("absolute right-3 top-3.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:md:hidden","group-data-[collapsible=icon]:hidden",e),...r})});x4.displayName="SidebarGroupAction";const vo=x.forwardRef(({className:e,...n},r)=>g.jsx("div",{ref:r,"data-sidebar":"group-content",className:fe("w-full text-sm",e),...n}));vo.displayName="SidebarGroupContent";const Va=x.forwardRef(({className:e,...n},r)=>g.jsx("ul",{ref:r,"data-sidebar":"menu",className:fe("flex w-full min-w-0 flex-col gap-1",e),...n}));Va.displayName="SidebarMenu";const ha=x.forwardRef(({className:e,...n},r)=>g.jsx("li",{ref:r,"data-sidebar":"menu-item",className:fe("group/menu-item relative",e),...n}));ha.displayName="SidebarMenuItem";const b4=pc("peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm outline-none ring-sidebar-ring transition-[width,height,padding] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:bg-sidebar-active data-[active=true]:font-medium data-[active=true]:text-sidebar-active-foreground data-[state=open]:hover:bg-sidebar-accent data-[state=open]:hover:text-sidebar-accent-foreground group-data-[collapsible=icon]:!size-8 group-data-[collapsible=icon]:!p-2 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0",{variants:{variant:{default:"hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",outline:"bg-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"h-8 text-sm",sm:"h-7 text-xs",lg:"h-12 text-sm group-data-[collapsible=icon]:!p-0"}},defaultVariants:{variant:"default",size:"default"}}),pa=x.forwardRef(({asChild:e=!1,isActive:n=!1,variant:r="default",size:i="default",tooltip:o,className:s,...c},f)=>{const h=e?ll:"button",{isMobile:d,state:m}=Cc(),y=g.jsx(h,{ref:f,"data-sidebar":"menu-button","data-size":i,"data-active":n,className:fe(b4({variant:r,size:i}),s),...c});return o?(typeof o=="string"&&(o={children:o}),g.jsxs(s4,{children:[g.jsx(u4,{asChild:!0,children:y}),g.jsx(eS,{side:"right",align:"center",hidden:m!=="collapsed"||d,...o})]})):y});pa.displayName="SidebarMenuButton";const w4=x.forwardRef(({className:e,asChild:n=!1,showOnHover:r=!1,...i},o)=>{const s=n?ll:"button";return g.jsx(s,{ref:o,"data-sidebar":"menu-action",className:fe("absolute right-1 top-1.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 peer-hover/menu-button:text-sidebar-accent-foreground [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:md:hidden","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",r&&"group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 peer-data-[active=true]/menu-button:text-sidebar-active-foreground md:opacity-0",e),...i})});w4.displayName="SidebarMenuAction";const ep=x.forwardRef(({className:e,...n},r)=>g.jsx("div",{ref:r,"data-sidebar":"menu-badge",className:fe("pointer-events-none absolute right-1 flex h-5 min-w-5 select-none items-center justify-center rounded-full px-1.5 text-xs font-semibold tabular-nums shadow-sm","transition-all duration-200 ease-in-out hover:scale-110","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",e),...n}));ep.displayName="SidebarMenuBadge";const S4=x.forwardRef(({className:e,showIcon:n=!1,...r},i)=>{const o=x.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return g.jsxs("div",{ref:i,"data-sidebar":"menu-skeleton",className:fe("flex h-8 items-center gap-2 rounded-md px-2",e),...r,children:[n&&g.jsx(ub,{className:"size-4 rounded-md","data-sidebar":"menu-skeleton-icon"}),g.jsx(ub,{className:"h-4 max-w-[--skeleton-width] flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});S4.displayName="SidebarMenuSkeleton";const uS=x.forwardRef(({className:e,...n},r)=>g.jsx("ul",{ref:r,"data-sidebar":"menu-sub",className:fe("mx-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-l border-sidebar-border px-2.5 py-0.5","group-data-[collapsible=icon]:hidden",e),...n}));uS.displayName="SidebarMenuSub";const cS=x.forwardRef(({...e},n)=>g.jsx("li",{ref:n,...e}));cS.displayName="SidebarMenuSubItem";const fS=x.forwardRef(({asChild:e=!1,size:n="md",isActive:r,className:i,...o},s)=>{const c=e?ll:"a";return g.jsx(c,{ref:s,"data-sidebar":"menu-sub-button","data-size":n,"data-active":r,className:fe("flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 text-sidebar-foreground outline-none ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 [&>svg]:text-sidebar-accent-foreground","data-[active=true]:bg-sidebar-active data-[active=true]:text-sidebar-active-foreground",n==="sm"&&"text-xs",n==="md"&&"text-sm","group-data-[collapsible=icon]:hidden",i),...o})});fS.displayName="SidebarMenuSubButton";const E4="1.0.75",k4={version:E4};function C4({className:e}){return g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:e,children:[g.jsx("path",{d:"M13 8c0-2.76-2.46-5-5.5-5S2 5.24 2 8h2l1-1 1 1h4"}),g.jsx("path",{d:"M13 7.14A5.82 5.82 0 0 1 16.5 6c3.04 0 5.5 2.24 5.5 5h-3l-1-1-1 1h-3"}),g.jsx("path",{d:"M5.89 9.71c-2.15 2.15-2.3 5.47-.35 7.43l4.24-4.25.7-.7.71-.71 2.12-2.12c-1.95-1.96-5.27-1.8-7.42.35"}),g.jsx("path",{d:"M11 15.5c.5 2.5-.17 4.5-1 6.5h4c2-5.5-.5-12-1-14"})]})}function Ha(e,n){if(n==="/")return e==="/";const r=e.match(/^\/terminal\/([^/]+)/);if(r){const i=r[1];if(n==="/agents")return i.startsWith("cp-")||i.startsWith("sk-");if(n==="/terminal")return!i.startsWith("cp-")&&!i.startsWith("sk-")}return e===n||e.startsWith(n+"/")}const A4=[{title:"Home",url:"/",icon:EN},{title:"Tasks",url:"/tasks",icon:uM},{title:"Skills",url:"/skills",icon:RM},{title:"Mail",url:"/mail",icon:zN}],T4=[{title:"Agents",url:"/agents",icon:So},{title:"Jobs",url:"/schedule",icon:Q_},{title:"Utilities",url:"/utilities",icon:CM}],R4=[{title:"Knowledge",url:"/knowledge",icon:_o},{title:"Resources",url:"/resources",icon:mN}],bb=[{title:"Overview",url:"/context/project",icon:_o},{title:"Architecture",url:"/context/architecture",icon:eM},{title:"Role",url:"/context/role",icon:wM}],_4=[{title:"Source Control",url:"/git",icon:b1},{title:"Terminal",url:"/terminal",icon:mM},{title:"Identity",url:"/identity",icon:CN},{title:"Activity",url:"/activity",icon:$_}],N4=[{title:"Documentation",url:"https://docs.coconut.dev/studio",icon:qN,external:!0},{title:"Settings",url:"/settings/user",icon:nM}];function M4(){const{badges:e}=HR(),n=on(),[r,i]=x.useState(!1);return x.useEffect(()=>{bb.some(s=>Ha(n.pathname,s.url))&&i(!0)},[n.pathname]),g.jsxs(rS,{className:"bg-sidebar border-r border-sidebar-border",children:[g.jsx(lS,{children:g.jsx(Va,{children:g.jsx(ha,{children:g.jsx(pa,{size:"lg",asChild:!0,className:"[&>svg]:!size-8",children:g.jsxs($n,{to:"/",children:[g.jsx(C4,{className:"size-8"}),g.jsxs("div",{className:"flex flex-col gap-0.5",children:[g.jsxs("span",{className:"font-semibold",children:[g.jsx("span",{className:"bg-gradient-to-r from-amber-500 via-orange-500 to-yellow-600 bg-clip-text text-transparent",children:"Coconut"}),g.jsx("span",{children:" Studio"})]}),g.jsxs("span",{className:"text-xs text-muted-foreground",children:["v",k4.version]})]})]})})})})}),g.jsxs(sS,{children:[g.jsx(yo,{children:g.jsx(vo,{children:g.jsx(Va,{children:A4.map(o=>g.jsx(ha,{children:g.jsx(pa,{asChild:!0,isActive:Ha(n.pathname,o.url),children:g.jsxs($n,{to:o.url,children:[g.jsx(o.icon,{}),g.jsx("span",{children:o.title})]})})},o.title))})})}),g.jsxs(yo,{children:[g.jsx(Uu,{children:"Work"}),g.jsx(vo,{children:g.jsx(Va,{children:T4.map(o=>{let s=0;return o.title==="Agents"&&e.codeSessions>0?s=e.codeSessions:o.title==="Jobs"&&e.runningScheduledJobs>0&&(s=e.runningScheduledJobs),g.jsxs(ha,{children:[g.jsx(pa,{asChild:!0,isActive:Ha(n.pathname,o.url),children:g.jsxs($n,{to:o.url,children:[g.jsx(o.icon,{}),g.jsx("span",{children:o.title})]})}),s>0&&g.jsx(ep,{className:"bg-blue-600 text-white dark:bg-blue-500",children:s})]},o.title)})})})]}),g.jsxs(yo,{children:[g.jsx(Uu,{children:"Assets"}),g.jsx(vo,{children:g.jsxs(Va,{children:[R4.map(o=>g.jsx(ha,{children:g.jsx(pa,{asChild:!0,isActive:Ha(n.pathname,o.url),children:g.jsxs($n,{to:o.url,children:[g.jsx(o.icon,{}),g.jsx("span",{children:o.title})]})})},o.title)),g.jsxs(ha,{children:[g.jsxs(pa,{onClick:()=>i(o=>!o),"data-state":r?"open":"closed",className:"w-full",children:[g.jsx(yN,{}),g.jsx("span",{children:"Context"}),g.jsx(tN,{className:`ml-auto size-4 shrink-0 transition-transform duration-200 ${r?"rotate-180":""}`})]}),r&&g.jsx(uS,{children:bb.map(o=>g.jsx(cS,{children:g.jsx(fS,{asChild:!0,isActive:Ha(n.pathname,o.url),children:g.jsxs($n,{to:o.url,children:[g.jsx(o.icon,{}),g.jsx("span",{children:o.title})]})})},o.title))})]})]})})]}),g.jsxs(yo,{children:[g.jsx(Uu,{children:"System"}),g.jsx(vo,{children:g.jsx(Va,{children:_4.map(o=>{let s=0;return o.title==="Source Control"&&e.gitChanges>0?s=e.gitChanges:o.title==="Terminal"&&e.terminalSessions>0&&(s=e.terminalSessions),g.jsxs(ha,{children:[g.jsx(pa,{asChild:!0,isActive:Ha(n.pathname,o.url),children:g.jsxs($n,{to:o.url,children:[g.jsx(o.icon,{}),g.jsx("span",{children:o.title})]})}),s>0&&g.jsx(ep,{className:"bg-blue-600 text-white dark:bg-blue-500",children:s})]},o.title)})})})]})]}),g.jsx(oS,{children:g.jsx(Va,{children:N4.map(o=>g.jsx(ha,{children:g.jsx(pa,{asChild:!0,isActive:!o.external&&Ha(n.pathname,o.url==="/settings/user"?"/settings":o.url),children:o.external?g.jsxs("a",{href:o.url,target:"_blank",rel:"noopener noreferrer",children:[g.jsx(o.icon,{}),g.jsx("span",{children:o.title})]}):g.jsxs($n,{to:o.url,children:[g.jsx(o.icon,{}),g.jsx("span",{children:o.title})]})})},o.title))})})]})}function j4(e){const n=e.match(/\bres-\d+-[a-z0-9]+\b/g);return n?[...new Set(n)]:[]}const Ac=Hp,LB=gw,D4=Fp,dS=x.forwardRef(({className:e,...n},r)=>g.jsx(Vo,{ref:r,className:fe("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...n}));dS.displayName=Vo.displayName;const Xo=x.forwardRef(({className:e,children:n,...r},i)=>g.jsxs(D4,{children:[g.jsx(dS,{}),g.jsxs($o,{ref:i,className:fe("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",e),...r,children:[n,g.jsxs(yc,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground",children:[g.jsx(Yi,{className:"h-4 w-4"}),g.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));Xo.displayName=$o.displayName;const Qo=({className:e,...n})=>g.jsx("div",{className:fe("flex flex-col space-y-1.5 text-center sm:text-left",e),...n});Qo.displayName="DialogHeader";const hS=({className:e,...n})=>g.jsx("div",{className:fe("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...n});hS.displayName="DialogFooter";const Zo=x.forwardRef(({className:e,...n},r)=>g.jsx(Go,{ref:r,className:fe("text-lg font-semibold leading-none tracking-tight",e),...n}));Zo.displayName=Go.displayName;const xo=x.forwardRef(({className:e,...n},r)=>g.jsx(Yo,{ref:r,className:fe("text-sm text-muted-foreground",e),...n}));xo.displayName=Yo.displayName;function gh({className:e,...n}){return g.jsx("kbd",{"data-slot":"kbd",className:fe("inline-flex h-5 items-center justify-center rounded border border-muted-foreground/30 bg-muted/50 px-1.5 font-sans text-[11px] font-medium text-muted-foreground shadow-sm",e),...n})}function zB({className:e,...n}){return g.jsx("span",{"data-slot":"kbd-group",className:fe("inline-flex items-center gap-0.5",e),...n})}function PB(){}function IB(){}function BB(e){const n=[],r=String(e||"");let i=r.indexOf(","),o=0,s=!1;for(;!s;){i===-1&&(i=r.length,s=!0);const c=r.slice(o,i).trim();(c||!s)&&n.push(c),o=i+1,i=r.indexOf(",",o)}return n}function O4(e,n){const r=n||{};return(e[e.length-1]===""?[...e,""]:e).join((r.padRight?" ":"")+","+(r.padLeft===!1?"":" ")).trim()}const L4=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,z4=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,P4={};function wb(e,n){return(P4.jsx?z4:L4).test(e)}const I4=/[ \t\n\f\r]/g;function B4(e){return typeof e=="object"?e.type==="text"?Sb(e.value):!1:Sb(e)}function Sb(e){return e.replace(I4,"")===""}class Wo{constructor(n,r,i){this.normal=r,this.property=n,i&&(this.space=i)}}Wo.prototype.normal={};Wo.prototype.property={};Wo.prototype.space=void 0;function pS(e,n){const r={},i={};for(const o of e)Object.assign(r,o.property),Object.assign(i,o.normal);return new Wo(r,i,n)}function tp(e){return e.toLowerCase()}class sn{constructor(n,r){this.attribute=r,this.property=n}}sn.prototype.attribute="";sn.prototype.booleanish=!1;sn.prototype.boolean=!1;sn.prototype.commaOrSpaceSeparated=!1;sn.prototype.commaSeparated=!1;sn.prototype.defined=!1;sn.prototype.mustUseProperty=!1;sn.prototype.number=!1;sn.prototype.overloadedBoolean=!1;sn.prototype.property="";sn.prototype.spaceSeparated=!1;sn.prototype.space=void 0;let U4=0;const Le=Xa(),Et=Xa(),np=Xa(),ce=Xa(),lt=Xa(),Qi=Xa(),yn=Xa();function Xa(){return 2**++U4}const rp=Object.freeze(Object.defineProperty({__proto__:null,boolean:Le,booleanish:Et,commaOrSpaceSeparated:yn,commaSeparated:Qi,number:ce,overloadedBoolean:np,spaceSeparated:lt},Symbol.toStringTag,{value:"Module"})),yh=Object.keys(rp);class nm extends sn{constructor(n,r,i,o){let s=-1;if(super(n,r),Eb(this,"space",o),typeof i=="number")for(;++s<yh.length;){const c=yh[s];Eb(this,yh[s],(i&rp[c])===rp[c])}}}nm.prototype.defined=!0;function Eb(e,n,r){r&&(e[n]=r)}function dl(e){const n={},r={};for(const[i,o]of Object.entries(e.properties)){const s=new nm(i,e.transform(e.attributes||{},i),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(i)&&(s.mustUseProperty=!0),n[i]=s,r[tp(i)]=i,r[tp(s.attribute)]=i}return new Wo(n,r,e.space)}const mS=dl({properties:{ariaActiveDescendant:null,ariaAtomic:Et,ariaAutoComplete:null,ariaBusy:Et,ariaChecked:Et,ariaColCount:ce,ariaColIndex:ce,ariaColSpan:ce,ariaControls:lt,ariaCurrent:null,ariaDescribedBy:lt,ariaDetails:null,ariaDisabled:Et,ariaDropEffect:lt,ariaErrorMessage:null,ariaExpanded:Et,ariaFlowTo:lt,ariaGrabbed:Et,ariaHasPopup:null,ariaHidden:Et,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:lt,ariaLevel:ce,ariaLive:null,ariaModal:Et,ariaMultiLine:Et,ariaMultiSelectable:Et,ariaOrientation:null,ariaOwns:lt,ariaPlaceholder:null,ariaPosInSet:ce,ariaPressed:Et,ariaReadOnly:Et,ariaRelevant:null,ariaRequired:Et,ariaRoleDescription:lt,ariaRowCount:ce,ariaRowIndex:ce,ariaRowSpan:ce,ariaSelected:Et,ariaSetSize:ce,ariaSort:null,ariaValueMax:ce,ariaValueMin:ce,ariaValueNow:ce,ariaValueText:null,role:null},transform(e,n){return n==="role"?n:"aria-"+n.slice(4).toLowerCase()}});function gS(e,n){return n in e?e[n]:n}function yS(e,n){return gS(e,n.toLowerCase())}const H4=dl({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:Qi,acceptCharset:lt,accessKey:lt,action:null,allow:null,allowFullScreen:Le,allowPaymentRequest:Le,allowUserMedia:Le,alt:null,as:null,async:Le,autoCapitalize:null,autoComplete:lt,autoFocus:Le,autoPlay:Le,blocking:lt,capture:null,charSet:null,checked:Le,cite:null,className:lt,cols:ce,colSpan:null,content:null,contentEditable:Et,controls:Le,controlsList:lt,coords:ce|Qi,crossOrigin:null,data:null,dateTime:null,decoding:null,default:Le,defer:Le,dir:null,dirName:null,disabled:Le,download:np,draggable:Et,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:Le,formTarget:null,headers:lt,height:ce,hidden:np,high:ce,href:null,hrefLang:null,htmlFor:lt,httpEquiv:lt,id:null,imageSizes:null,imageSrcSet:null,inert:Le,inputMode:null,integrity:null,is:null,isMap:Le,itemId:null,itemProp:lt,itemRef:lt,itemScope:Le,itemType:lt,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:Le,low:ce,manifest:null,max:null,maxLength:ce,media:null,method:null,min:null,minLength:ce,multiple:Le,muted:Le,name:null,nonce:null,noModule:Le,noValidate:Le,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:Le,optimum:ce,pattern:null,ping:lt,placeholder:null,playsInline:Le,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:Le,referrerPolicy:null,rel:lt,required:Le,reversed:Le,rows:ce,rowSpan:ce,sandbox:lt,scope:null,scoped:Le,seamless:Le,selected:Le,shadowRootClonable:Le,shadowRootDelegatesFocus:Le,shadowRootMode:null,shape:null,size:ce,sizes:null,slot:null,span:ce,spellCheck:Et,src:null,srcDoc:null,srcLang:null,srcSet:null,start:ce,step:null,style:null,tabIndex:ce,target:null,title:null,translate:null,type:null,typeMustMatch:Le,useMap:null,value:Et,width:ce,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:lt,axis:null,background:null,bgColor:null,border:ce,borderColor:null,bottomMargin:ce,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:Le,declare:Le,event:null,face:null,frame:null,frameBorder:null,hSpace:ce,leftMargin:ce,link:null,longDesc:null,lowSrc:null,marginHeight:ce,marginWidth:ce,noResize:Le,noHref:Le,noShade:Le,noWrap:Le,object:null,profile:null,prompt:null,rev:null,rightMargin:ce,rules:null,scheme:null,scrolling:Et,standby:null,summary:null,text:null,topMargin:ce,valueType:null,version:null,vAlign:null,vLink:null,vSpace:ce,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:Le,disableRemotePlayback:Le,prefix:null,property:null,results:ce,security:null,unselectable:null},space:"html",transform:yS}),F4=dl({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:yn,accentHeight:ce,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:ce,amplitude:ce,arabicForm:null,ascent:ce,attributeName:null,attributeType:null,azimuth:ce,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:ce,by:null,calcMode:null,capHeight:ce,className:lt,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:ce,diffuseConstant:ce,direction:null,display:null,dur:null,divisor:ce,dominantBaseline:null,download:Le,dx:null,dy:null,edgeMode:null,editable:null,elevation:ce,enableBackground:null,end:null,event:null,exponent:ce,externalResourcesRequired:null,fill:null,fillOpacity:ce,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:Qi,g2:Qi,glyphName:Qi,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:ce,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:ce,horizOriginX:ce,horizOriginY:ce,id:null,ideographic:ce,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:ce,k:ce,k1:ce,k2:ce,k3:ce,k4:ce,kernelMatrix:yn,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:ce,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:ce,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:ce,overlineThickness:ce,paintOrder:null,panose1:null,path:null,pathLength:ce,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:lt,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:ce,pointsAtY:ce,pointsAtZ:ce,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:yn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:yn,rev:yn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:yn,requiredFeatures:yn,requiredFonts:yn,requiredFormats:yn,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:ce,specularExponent:ce,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:ce,strikethroughThickness:ce,string:null,stroke:null,strokeDashArray:yn,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:ce,strokeOpacity:ce,strokeWidth:null,style:null,surfaceScale:ce,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:yn,tabIndex:ce,tableValues:null,target:null,targetX:ce,targetY:ce,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:yn,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:ce,underlineThickness:ce,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:ce,values:null,vAlphabetic:ce,vMathematical:ce,vectorEffect:null,vHanging:ce,vIdeographic:ce,version:null,vertAdvY:ce,vertOriginX:ce,vertOriginY:ce,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:ce,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:gS}),vS=dl({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(e,n){return"xlink:"+n.slice(5).toLowerCase()}}),xS=dl({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:yS}),bS=dl({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,n){return"xml:"+n.slice(3).toLowerCase()}}),q4={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"},V4=/[A-Z]/g,kb=/-[a-z]/g,$4=/^data[-\w.:]+$/i;function G4(e,n){const r=tp(n);let i=n,o=sn;if(r in e.normal)return e.property[e.normal[r]];if(r.length>4&&r.slice(0,4)==="data"&&$4.test(n)){if(n.charAt(4)==="-"){const s=n.slice(5).replace(kb,K4);i="data"+s.charAt(0).toUpperCase()+s.slice(1)}else{const s=n.slice(4);if(!kb.test(s)){let c=s.replace(V4,Y4);c.charAt(0)!=="-"&&(c="-"+c),n="data"+c}}o=nm}return new o(i,n)}function Y4(e){return"-"+e.toLowerCase()}function K4(e){return e.charAt(1).toUpperCase()}const X4=pS([mS,H4,vS,xS,bS],"html"),rm=pS([mS,F4,vS,xS,bS],"svg");function UB(e){const n=String(e||"").trim();return n?n.split(/[ \t\n\r\f]+/g):[]}function Q4(e){return e.join(" ").trim()}var Vi={},vh,Cb;function Z4(){if(Cb)return vh;Cb=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,n=/\n/g,r=/^\s*/,i=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,s=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,c=/^[;\s]*/,f=/^\s+|\s+$/g,h=`
|
|
385
|
+
For more information, see https://radix-ui.com/primitives/docs/components/${n.docsSlug}`;return x.useEffect(()=>{e&&(document.getElementById(e)||console.error(r))},[r,e]),null},bD="DialogDescriptionWarning",wD=({contentRef:e,descriptionId:n})=>{const i=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${mw(bD).contentName}}.`;return x.useEffect(()=>{const o=e.current?.getAttribute("aria-describedby");n&&o&&(document.getElementById(n)||console.warn(i))},[i,e,n]),null},Hp=tw,gw=rw,Fp=iw,Vo=lw,$o=ow,Go=uw,Yo=fw,yc=hw;const yw=Hp,SD=Fp,vw=x.forwardRef(({className:e,...n},r)=>g.jsx(Vo,{className:fe("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...n,ref:r}));vw.displayName=Vo.displayName;const ED=pc("fixed z-50 gap-4 bg-background p-6 shadow-lg transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:duration-500",{variants:{side:{top:"inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",bottom:"inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",left:"inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",right:"inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm"}},defaultVariants:{side:"right"}}),qp=x.forwardRef(({side:e="right",className:n,children:r,...i},o)=>g.jsxs(SD,{children:[g.jsx(vw,{}),g.jsxs($o,{ref:o,className:fe(ED({side:e}),n),...i,children:[r,g.jsxs(yc,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary",children:[g.jsx(Yi,{className:"h-4 w-4"}),g.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));qp.displayName=$o.displayName;const Vp=({className:e,...n})=>g.jsx("div",{className:fe("flex flex-col space-y-2 text-center sm:text-left",e),...n});Vp.displayName="SheetHeader";const $p=x.forwardRef(({className:e,...n},r)=>g.jsx(Go,{ref:r,className:fe("text-lg font-semibold text-foreground",e),...n}));$p.displayName=Go.displayName;const xw=x.forwardRef(({className:e,...n},r)=>g.jsx(Yo,{ref:r,className:fe("text-sm text-muted-foreground",e),...n}));xw.displayName=Yo.displayName;function ub({className:e,...n}){return g.jsx("div",{className:fe("animate-pulse rounded-md bg-muted",e),...n})}const kD=["top","right","bottom","left"],ya=Math.min,vn=Math.max,Yu=Math.round,Au=Math.floor,ur=e=>({x:e,y:e}),CD={left:"right",right:"left",bottom:"top",top:"bottom"},AD={start:"end",end:"start"};function Xh(e,n,r){return vn(e,ya(n,r))}function Lr(e,n){return typeof e=="function"?e(n):e}function zr(e){return e.split("-")[0]}function cl(e){return e.split("-")[1]}function Gp(e){return e==="x"?"y":"x"}function Yp(e){return e==="y"?"height":"width"}const TD=new Set(["top","bottom"]);function sr(e){return TD.has(zr(e))?"y":"x"}function Kp(e){return Gp(sr(e))}function RD(e,n,r){r===void 0&&(r=!1);const i=cl(e),o=Kp(e),s=Yp(o);let c=o==="x"?i===(r?"end":"start")?"right":"left":i==="start"?"bottom":"top";return n.reference[s]>n.floating[s]&&(c=Ku(c)),[c,Ku(c)]}function _D(e){const n=Ku(e);return[Qh(e),n,Qh(n)]}function Qh(e){return e.replace(/start|end/g,n=>AD[n])}const cb=["left","right"],fb=["right","left"],ND=["top","bottom"],MD=["bottom","top"];function jD(e,n,r){switch(e){case"top":case"bottom":return r?n?fb:cb:n?cb:fb;case"left":case"right":return n?ND:MD;default:return[]}}function DD(e,n,r,i){const o=cl(e);let s=jD(zr(e),r==="start",i);return o&&(s=s.map(c=>c+"-"+o),n&&(s=s.concat(s.map(Qh)))),s}function Ku(e){return e.replace(/left|right|bottom|top/g,n=>CD[n])}function OD(e){return{top:0,right:0,bottom:0,left:0,...e}}function bw(e){return typeof e!="number"?OD(e):{top:e,right:e,bottom:e,left:e}}function Xu(e){const{x:n,y:r,width:i,height:o}=e;return{width:i,height:o,top:r,left:n,right:n+i,bottom:r+o,x:n,y:r}}function db(e,n,r){let{reference:i,floating:o}=e;const s=sr(n),c=Kp(n),f=Yp(c),h=zr(n),d=s==="y",m=i.x+i.width/2-o.width/2,y=i.y+i.height/2-o.height/2,b=i[f]/2-o[f]/2;let w;switch(h){case"top":w={x:m,y:i.y-o.height};break;case"bottom":w={x:m,y:i.y+i.height};break;case"right":w={x:i.x+i.width,y};break;case"left":w={x:i.x-o.width,y};break;default:w={x:i.x,y:i.y}}switch(cl(n)){case"start":w[c]-=b*(r&&d?-1:1);break;case"end":w[c]+=b*(r&&d?-1:1);break}return w}const LD=async(e,n,r)=>{const{placement:i="bottom",strategy:o="absolute",middleware:s=[],platform:c}=r,f=s.filter(Boolean),h=await(c.isRTL==null?void 0:c.isRTL(n));let d=await c.getElementRects({reference:e,floating:n,strategy:o}),{x:m,y}=db(d,i,h),b=i,w={},k=0;for(let C=0;C<f.length;C++){const{name:T,fn:A}=f[C],{x:_,y:N,data:O,reset:z}=await A({x:m,y,initialPlacement:i,placement:b,strategy:o,middlewareData:w,rects:d,platform:c,elements:{reference:e,floating:n}});m=_??m,y=N??y,w={...w,[T]:{...w[T],...O}},z&&k<=50&&(k++,typeof z=="object"&&(z.placement&&(b=z.placement),z.rects&&(d=z.rects===!0?await c.getElementRects({reference:e,floating:n,strategy:o}):z.rects),{x:m,y}=db(d,b,h)),C=-1)}return{x:m,y,placement:b,strategy:o,middlewareData:w}};async function No(e,n){var r;n===void 0&&(n={});const{x:i,y:o,platform:s,rects:c,elements:f,strategy:h}=e,{boundary:d="clippingAncestors",rootBoundary:m="viewport",elementContext:y="floating",altBoundary:b=!1,padding:w=0}=Lr(n,e),k=bw(w),T=f[b?y==="floating"?"reference":"floating":y],A=Xu(await s.getClippingRect({element:(r=await(s.isElement==null?void 0:s.isElement(T)))==null||r?T:T.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(f.floating)),boundary:d,rootBoundary:m,strategy:h})),_=y==="floating"?{x:i,y:o,width:c.floating.width,height:c.floating.height}:c.reference,N=await(s.getOffsetParent==null?void 0:s.getOffsetParent(f.floating)),O=await(s.isElement==null?void 0:s.isElement(N))?await(s.getScale==null?void 0:s.getScale(N))||{x:1,y:1}:{x:1,y:1},z=Xu(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:f,rect:_,offsetParent:N,strategy:h}):_);return{top:(A.top-z.top+k.top)/O.y,bottom:(z.bottom-A.bottom+k.bottom)/O.y,left:(A.left-z.left+k.left)/O.x,right:(z.right-A.right+k.right)/O.x}}const zD=e=>({name:"arrow",options:e,async fn(n){const{x:r,y:i,placement:o,rects:s,platform:c,elements:f,middlewareData:h}=n,{element:d,padding:m=0}=Lr(e,n)||{};if(d==null)return{};const y=bw(m),b={x:r,y:i},w=Kp(o),k=Yp(w),C=await c.getDimensions(d),T=w==="y",A=T?"top":"left",_=T?"bottom":"right",N=T?"clientHeight":"clientWidth",O=s.reference[k]+s.reference[w]-b[w]-s.floating[k],z=b[w]-s.reference[w],j=await(c.getOffsetParent==null?void 0:c.getOffsetParent(d));let $=j?j[N]:0;(!$||!await(c.isElement==null?void 0:c.isElement(j)))&&($=f.floating[N]||s.floating[k]);const G=O/2-z/2,ee=$/2-C[k]/2-1,P=ya(y[A],ee),ne=ya(y[_],ee),ae=P,le=$-C[k]-ne,H=$/2-C[k]/2+G,Q=Xh(ae,H,le),L=!h.arrow&&cl(o)!=null&&H!==Q&&s.reference[k]/2-(H<ae?P:ne)-C[k]/2<0,K=L?H<ae?H-ae:H-le:0;return{[w]:b[w]+K,data:{[w]:Q,centerOffset:H-Q-K,...L&&{alignmentOffset:K}},reset:L}}}),PD=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(n){var r,i;const{placement:o,middlewareData:s,rects:c,initialPlacement:f,platform:h,elements:d}=n,{mainAxis:m=!0,crossAxis:y=!0,fallbackPlacements:b,fallbackStrategy:w="bestFit",fallbackAxisSideDirection:k="none",flipAlignment:C=!0,...T}=Lr(e,n);if((r=s.arrow)!=null&&r.alignmentOffset)return{};const A=zr(o),_=sr(f),N=zr(f)===f,O=await(h.isRTL==null?void 0:h.isRTL(d.floating)),z=b||(N||!C?[Ku(f)]:_D(f)),j=k!=="none";!b&&j&&z.push(...DD(f,C,k,O));const $=[f,...z],G=await No(n,T),ee=[];let P=((i=s.flip)==null?void 0:i.overflows)||[];if(m&&ee.push(G[A]),y){const H=RD(o,c,O);ee.push(G[H[0]],G[H[1]])}if(P=[...P,{placement:o,overflows:ee}],!ee.every(H=>H<=0)){var ne,ae;const H=(((ne=s.flip)==null?void 0:ne.index)||0)+1,Q=$[H];if(Q&&(!(y==="alignment"?_!==sr(Q):!1)||P.every(U=>sr(U.placement)===_?U.overflows[0]>0:!0)))return{data:{index:H,overflows:P},reset:{placement:Q}};let L=(ae=P.filter(K=>K.overflows[0]<=0).sort((K,U)=>K.overflows[1]-U.overflows[1])[0])==null?void 0:ae.placement;if(!L)switch(w){case"bestFit":{var le;const K=(le=P.filter(U=>{if(j){const J=sr(U.placement);return J===_||J==="y"}return!0}).map(U=>[U.placement,U.overflows.filter(J=>J>0).reduce((J,E)=>J+E,0)]).sort((U,J)=>U[1]-J[1])[0])==null?void 0:le[0];K&&(L=K);break}case"initialPlacement":L=f;break}if(o!==L)return{reset:{placement:L}}}return{}}}};function hb(e,n){return{top:e.top-n.height,right:e.right-n.width,bottom:e.bottom-n.height,left:e.left-n.width}}function pb(e){return kD.some(n=>e[n]>=0)}const ID=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(n){const{rects:r}=n,{strategy:i="referenceHidden",...o}=Lr(e,n);switch(i){case"referenceHidden":{const s=await No(n,{...o,elementContext:"reference"}),c=hb(s,r.reference);return{data:{referenceHiddenOffsets:c,referenceHidden:pb(c)}}}case"escaped":{const s=await No(n,{...o,altBoundary:!0}),c=hb(s,r.floating);return{data:{escapedOffsets:c,escaped:pb(c)}}}default:return{}}}}},ww=new Set(["left","top"]);async function BD(e,n){const{placement:r,platform:i,elements:o}=e,s=await(i.isRTL==null?void 0:i.isRTL(o.floating)),c=zr(r),f=cl(r),h=sr(r)==="y",d=ww.has(c)?-1:1,m=s&&h?-1:1,y=Lr(n,e);let{mainAxis:b,crossAxis:w,alignmentAxis:k}=typeof y=="number"?{mainAxis:y,crossAxis:0,alignmentAxis:null}:{mainAxis:y.mainAxis||0,crossAxis:y.crossAxis||0,alignmentAxis:y.alignmentAxis};return f&&typeof k=="number"&&(w=f==="end"?k*-1:k),h?{x:w*m,y:b*d}:{x:b*d,y:w*m}}const UD=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(n){var r,i;const{x:o,y:s,placement:c,middlewareData:f}=n,h=await BD(n,e);return c===((r=f.offset)==null?void 0:r.placement)&&(i=f.arrow)!=null&&i.alignmentOffset?{}:{x:o+h.x,y:s+h.y,data:{...h,placement:c}}}}},HD=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(n){const{x:r,y:i,placement:o}=n,{mainAxis:s=!0,crossAxis:c=!1,limiter:f={fn:T=>{let{x:A,y:_}=T;return{x:A,y:_}}},...h}=Lr(e,n),d={x:r,y:i},m=await No(n,h),y=sr(zr(o)),b=Gp(y);let w=d[b],k=d[y];if(s){const T=b==="y"?"top":"left",A=b==="y"?"bottom":"right",_=w+m[T],N=w-m[A];w=Xh(_,w,N)}if(c){const T=y==="y"?"top":"left",A=y==="y"?"bottom":"right",_=k+m[T],N=k-m[A];k=Xh(_,k,N)}const C=f.fn({...n,[b]:w,[y]:k});return{...C,data:{x:C.x-r,y:C.y-i,enabled:{[b]:s,[y]:c}}}}}},FD=function(e){return e===void 0&&(e={}),{options:e,fn(n){const{x:r,y:i,placement:o,rects:s,middlewareData:c}=n,{offset:f=0,mainAxis:h=!0,crossAxis:d=!0}=Lr(e,n),m={x:r,y:i},y=sr(o),b=Gp(y);let w=m[b],k=m[y];const C=Lr(f,n),T=typeof C=="number"?{mainAxis:C,crossAxis:0}:{mainAxis:0,crossAxis:0,...C};if(h){const N=b==="y"?"height":"width",O=s.reference[b]-s.floating[N]+T.mainAxis,z=s.reference[b]+s.reference[N]-T.mainAxis;w<O?w=O:w>z&&(w=z)}if(d){var A,_;const N=b==="y"?"width":"height",O=ww.has(zr(o)),z=s.reference[y]-s.floating[N]+(O&&((A=c.offset)==null?void 0:A[y])||0)+(O?0:T.crossAxis),j=s.reference[y]+s.reference[N]+(O?0:((_=c.offset)==null?void 0:_[y])||0)-(O?T.crossAxis:0);k<z?k=z:k>j&&(k=j)}return{[b]:w,[y]:k}}}},qD=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(n){var r,i;const{placement:o,rects:s,platform:c,elements:f}=n,{apply:h=()=>{},...d}=Lr(e,n),m=await No(n,d),y=zr(o),b=cl(o),w=sr(o)==="y",{width:k,height:C}=s.floating;let T,A;y==="top"||y==="bottom"?(T=y,A=b===(await(c.isRTL==null?void 0:c.isRTL(f.floating))?"start":"end")?"left":"right"):(A=y,T=b==="end"?"top":"bottom");const _=C-m.top-m.bottom,N=k-m.left-m.right,O=ya(C-m[T],_),z=ya(k-m[A],N),j=!n.middlewareData.shift;let $=O,G=z;if((r=n.middlewareData.shift)!=null&&r.enabled.x&&(G=N),(i=n.middlewareData.shift)!=null&&i.enabled.y&&($=_),j&&!b){const P=vn(m.left,0),ne=vn(m.right,0),ae=vn(m.top,0),le=vn(m.bottom,0);w?G=k-2*(P!==0||ne!==0?P+ne:vn(m.left,m.right)):$=C-2*(ae!==0||le!==0?ae+le:vn(m.top,m.bottom))}await h({...n,availableWidth:G,availableHeight:$});const ee=await c.getDimensions(f.floating);return k!==ee.width||C!==ee.height?{reset:{rects:!0}}:{}}}};function vc(){return typeof window<"u"}function fl(e){return Sw(e)?(e.nodeName||"").toLowerCase():"#document"}function xn(e){var n;return(e==null||(n=e.ownerDocument)==null?void 0:n.defaultView)||window}function dr(e){var n;return(n=(Sw(e)?e.ownerDocument:e.document)||window.document)==null?void 0:n.documentElement}function Sw(e){return vc()?e instanceof Node||e instanceof xn(e).Node:!1}function Yn(e){return vc()?e instanceof Element||e instanceof xn(e).Element:!1}function fr(e){return vc()?e instanceof HTMLElement||e instanceof xn(e).HTMLElement:!1}function mb(e){return!vc()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof xn(e).ShadowRoot}const VD=new Set(["inline","contents"]);function Ko(e){const{overflow:n,overflowX:r,overflowY:i,display:o}=Kn(e);return/auto|scroll|overlay|hidden|clip/.test(n+i+r)&&!VD.has(o)}const $D=new Set(["table","td","th"]);function GD(e){return $D.has(fl(e))}const YD=[":popover-open",":modal"];function xc(e){return YD.some(n=>{try{return e.matches(n)}catch{return!1}})}const KD=["transform","translate","scale","rotate","perspective"],XD=["transform","translate","scale","rotate","perspective","filter"],QD=["paint","layout","strict","content"];function Xp(e){const n=Qp(),r=Yn(e)?Kn(e):e;return KD.some(i=>r[i]?r[i]!=="none":!1)||(r.containerType?r.containerType!=="normal":!1)||!n&&(r.backdropFilter?r.backdropFilter!=="none":!1)||!n&&(r.filter?r.filter!=="none":!1)||XD.some(i=>(r.willChange||"").includes(i))||QD.some(i=>(r.contain||"").includes(i))}function ZD(e){let n=va(e);for(;fr(n)&&!Ji(n);){if(Xp(n))return n;if(xc(n))return null;n=va(n)}return null}function Qp(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const WD=new Set(["html","body","#document"]);function Ji(e){return WD.has(fl(e))}function Kn(e){return xn(e).getComputedStyle(e)}function bc(e){return Yn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function va(e){if(fl(e)==="html")return e;const n=e.assignedSlot||e.parentNode||mb(e)&&e.host||dr(e);return mb(n)?n.host:n}function Ew(e){const n=va(e);return Ji(n)?e.ownerDocument?e.ownerDocument.body:e.body:fr(n)&&Ko(n)?n:Ew(n)}function Mo(e,n,r){var i;n===void 0&&(n=[]),r===void 0&&(r=!0);const o=Ew(e),s=o===((i=e.ownerDocument)==null?void 0:i.body),c=xn(o);if(s){const f=Zh(c);return n.concat(c,c.visualViewport||[],Ko(o)?o:[],f&&r?Mo(f):[])}return n.concat(o,Mo(o,[],r))}function Zh(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function kw(e){const n=Kn(e);let r=parseFloat(n.width)||0,i=parseFloat(n.height)||0;const o=fr(e),s=o?e.offsetWidth:r,c=o?e.offsetHeight:i,f=Yu(r)!==s||Yu(i)!==c;return f&&(r=s,i=c),{width:r,height:i,$:f}}function Zp(e){return Yn(e)?e:e.contextElement}function Xi(e){const n=Zp(e);if(!fr(n))return ur(1);const r=n.getBoundingClientRect(),{width:i,height:o,$:s}=kw(n);let c=(s?Yu(r.width):r.width)/i,f=(s?Yu(r.height):r.height)/o;return(!c||!Number.isFinite(c))&&(c=1),(!f||!Number.isFinite(f))&&(f=1),{x:c,y:f}}const JD=ur(0);function Cw(e){const n=xn(e);return!Qp()||!n.visualViewport?JD:{x:n.visualViewport.offsetLeft,y:n.visualViewport.offsetTop}}function eO(e,n,r){return n===void 0&&(n=!1),!r||n&&r!==xn(e)?!1:n}function Ya(e,n,r,i){n===void 0&&(n=!1),r===void 0&&(r=!1);const o=e.getBoundingClientRect(),s=Zp(e);let c=ur(1);n&&(i?Yn(i)&&(c=Xi(i)):c=Xi(e));const f=eO(s,r,i)?Cw(s):ur(0);let h=(o.left+f.x)/c.x,d=(o.top+f.y)/c.y,m=o.width/c.x,y=o.height/c.y;if(s){const b=xn(s),w=i&&Yn(i)?xn(i):i;let k=b,C=Zh(k);for(;C&&i&&w!==k;){const T=Xi(C),A=C.getBoundingClientRect(),_=Kn(C),N=A.left+(C.clientLeft+parseFloat(_.paddingLeft))*T.x,O=A.top+(C.clientTop+parseFloat(_.paddingTop))*T.y;h*=T.x,d*=T.y,m*=T.x,y*=T.y,h+=N,d+=O,k=xn(C),C=Zh(k)}}return Xu({width:m,height:y,x:h,y:d})}function Wp(e,n){const r=bc(e).scrollLeft;return n?n.left+r:Ya(dr(e)).left+r}function Aw(e,n,r){r===void 0&&(r=!1);const i=e.getBoundingClientRect(),o=i.left+n.scrollLeft-(r?0:Wp(e,i)),s=i.top+n.scrollTop;return{x:o,y:s}}function tO(e){let{elements:n,rect:r,offsetParent:i,strategy:o}=e;const s=o==="fixed",c=dr(i),f=n?xc(n.floating):!1;if(i===c||f&&s)return r;let h={scrollLeft:0,scrollTop:0},d=ur(1);const m=ur(0),y=fr(i);if((y||!y&&!s)&&((fl(i)!=="body"||Ko(c))&&(h=bc(i)),fr(i))){const w=Ya(i);d=Xi(i),m.x=w.x+i.clientLeft,m.y=w.y+i.clientTop}const b=c&&!y&&!s?Aw(c,h,!0):ur(0);return{width:r.width*d.x,height:r.height*d.y,x:r.x*d.x-h.scrollLeft*d.x+m.x+b.x,y:r.y*d.y-h.scrollTop*d.y+m.y+b.y}}function nO(e){return Array.from(e.getClientRects())}function rO(e){const n=dr(e),r=bc(e),i=e.ownerDocument.body,o=vn(n.scrollWidth,n.clientWidth,i.scrollWidth,i.clientWidth),s=vn(n.scrollHeight,n.clientHeight,i.scrollHeight,i.clientHeight);let c=-r.scrollLeft+Wp(e);const f=-r.scrollTop;return Kn(i).direction==="rtl"&&(c+=vn(n.clientWidth,i.clientWidth)-o),{width:o,height:s,x:c,y:f}}function aO(e,n){const r=xn(e),i=dr(e),o=r.visualViewport;let s=i.clientWidth,c=i.clientHeight,f=0,h=0;if(o){s=o.width,c=o.height;const d=Qp();(!d||d&&n==="fixed")&&(f=o.offsetLeft,h=o.offsetTop)}return{width:s,height:c,x:f,y:h}}const iO=new Set(["absolute","fixed"]);function lO(e,n){const r=Ya(e,!0,n==="fixed"),i=r.top+e.clientTop,o=r.left+e.clientLeft,s=fr(e)?Xi(e):ur(1),c=e.clientWidth*s.x,f=e.clientHeight*s.y,h=o*s.x,d=i*s.y;return{width:c,height:f,x:h,y:d}}function gb(e,n,r){let i;if(n==="viewport")i=aO(e,r);else if(n==="document")i=rO(dr(e));else if(Yn(n))i=lO(n,r);else{const o=Cw(e);i={x:n.x-o.x,y:n.y-o.y,width:n.width,height:n.height}}return Xu(i)}function Tw(e,n){const r=va(e);return r===n||!Yn(r)||Ji(r)?!1:Kn(r).position==="fixed"||Tw(r,n)}function oO(e,n){const r=n.get(e);if(r)return r;let i=Mo(e,[],!1).filter(f=>Yn(f)&&fl(f)!=="body"),o=null;const s=Kn(e).position==="fixed";let c=s?va(e):e;for(;Yn(c)&&!Ji(c);){const f=Kn(c),h=Xp(c);!h&&f.position==="fixed"&&(o=null),(s?!h&&!o:!h&&f.position==="static"&&!!o&&iO.has(o.position)||Ko(c)&&!h&&Tw(e,c))?i=i.filter(m=>m!==c):o=f,c=va(c)}return n.set(e,i),i}function sO(e){let{element:n,boundary:r,rootBoundary:i,strategy:o}=e;const c=[...r==="clippingAncestors"?xc(n)?[]:oO(n,this._c):[].concat(r),i],f=c[0],h=c.reduce((d,m)=>{const y=gb(n,m,o);return d.top=vn(y.top,d.top),d.right=ya(y.right,d.right),d.bottom=ya(y.bottom,d.bottom),d.left=vn(y.left,d.left),d},gb(n,f,o));return{width:h.right-h.left,height:h.bottom-h.top,x:h.left,y:h.top}}function uO(e){const{width:n,height:r}=kw(e);return{width:n,height:r}}function cO(e,n,r){const i=fr(n),o=dr(n),s=r==="fixed",c=Ya(e,!0,s,n);let f={scrollLeft:0,scrollTop:0};const h=ur(0);function d(){h.x=Wp(o)}if(i||!i&&!s)if((fl(n)!=="body"||Ko(o))&&(f=bc(n)),i){const w=Ya(n,!0,s,n);h.x=w.x+n.clientLeft,h.y=w.y+n.clientTop}else o&&d();s&&!i&&o&&d();const m=o&&!i&&!s?Aw(o,f):ur(0),y=c.left+f.scrollLeft-h.x-m.x,b=c.top+f.scrollTop-h.y-m.y;return{x:y,y:b,width:c.width,height:c.height}}function ph(e){return Kn(e).position==="static"}function yb(e,n){if(!fr(e)||Kn(e).position==="fixed")return null;if(n)return n(e);let r=e.offsetParent;return dr(e)===r&&(r=r.ownerDocument.body),r}function Rw(e,n){const r=xn(e);if(xc(e))return r;if(!fr(e)){let o=va(e);for(;o&&!Ji(o);){if(Yn(o)&&!ph(o))return o;o=va(o)}return r}let i=yb(e,n);for(;i&&GD(i)&&ph(i);)i=yb(i,n);return i&&Ji(i)&&ph(i)&&!Xp(i)?r:i||ZD(e)||r}const fO=async function(e){const n=this.getOffsetParent||Rw,r=this.getDimensions,i=await r(e.floating);return{reference:cO(e.reference,await n(e.floating),e.strategy),floating:{x:0,y:0,width:i.width,height:i.height}}};function dO(e){return Kn(e).direction==="rtl"}const hO={convertOffsetParentRelativeRectToViewportRelativeRect:tO,getDocumentElement:dr,getClippingRect:sO,getOffsetParent:Rw,getElementRects:fO,getClientRects:nO,getDimensions:uO,getScale:Xi,isElement:Yn,isRTL:dO};function _w(e,n){return e.x===n.x&&e.y===n.y&&e.width===n.width&&e.height===n.height}function pO(e,n){let r=null,i;const o=dr(e);function s(){var f;clearTimeout(i),(f=r)==null||f.disconnect(),r=null}function c(f,h){f===void 0&&(f=!1),h===void 0&&(h=1),s();const d=e.getBoundingClientRect(),{left:m,top:y,width:b,height:w}=d;if(f||n(),!b||!w)return;const k=Au(y),C=Au(o.clientWidth-(m+b)),T=Au(o.clientHeight-(y+w)),A=Au(m),N={rootMargin:-k+"px "+-C+"px "+-T+"px "+-A+"px",threshold:vn(0,ya(1,h))||1};let O=!0;function z(j){const $=j[0].intersectionRatio;if($!==h){if(!O)return c();$?c(!1,$):i=setTimeout(()=>{c(!1,1e-7)},1e3)}$===1&&!_w(d,e.getBoundingClientRect())&&c(),O=!1}try{r=new IntersectionObserver(z,{...N,root:o.ownerDocument})}catch{r=new IntersectionObserver(z,N)}r.observe(e)}return c(!0),s}function mO(e,n,r,i){i===void 0&&(i={});const{ancestorScroll:o=!0,ancestorResize:s=!0,elementResize:c=typeof ResizeObserver=="function",layoutShift:f=typeof IntersectionObserver=="function",animationFrame:h=!1}=i,d=Zp(e),m=o||s?[...d?Mo(d):[],...Mo(n)]:[];m.forEach(A=>{o&&A.addEventListener("scroll",r,{passive:!0}),s&&A.addEventListener("resize",r)});const y=d&&f?pO(d,r):null;let b=-1,w=null;c&&(w=new ResizeObserver(A=>{let[_]=A;_&&_.target===d&&w&&(w.unobserve(n),cancelAnimationFrame(b),b=requestAnimationFrame(()=>{var N;(N=w)==null||N.observe(n)})),r()}),d&&!h&&w.observe(d),w.observe(n));let k,C=h?Ya(e):null;h&&T();function T(){const A=Ya(e);C&&!_w(C,A)&&r(),C=A,k=requestAnimationFrame(T)}return r(),()=>{var A;m.forEach(_=>{o&&_.removeEventListener("scroll",r),s&&_.removeEventListener("resize",r)}),y?.(),(A=w)==null||A.disconnect(),w=null,h&&cancelAnimationFrame(k)}}const gO=UD,yO=HD,vO=PD,xO=qD,bO=ID,vb=zD,wO=FD,SO=(e,n,r)=>{const i=new Map,o={platform:hO,...r},s={...o.platform,_c:i};return LD(e,n,{...o,platform:s})};var EO=typeof document<"u",kO=function(){},Bu=EO?x.useLayoutEffect:kO;function Qu(e,n){if(e===n)return!0;if(typeof e!=typeof n)return!1;if(typeof e=="function"&&e.toString()===n.toString())return!0;let r,i,o;if(e&&n&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!==n.length)return!1;for(i=r;i--!==0;)if(!Qu(e[i],n[i]))return!1;return!0}if(o=Object.keys(e),r=o.length,r!==Object.keys(n).length)return!1;for(i=r;i--!==0;)if(!{}.hasOwnProperty.call(n,o[i]))return!1;for(i=r;i--!==0;){const s=o[i];if(!(s==="_owner"&&e.$$typeof)&&!Qu(e[s],n[s]))return!1}return!0}return e!==e&&n!==n}function Nw(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function xb(e,n){const r=Nw(e);return Math.round(n*r)/r}function mh(e){const n=x.useRef(e);return Bu(()=>{n.current=e}),n}function CO(e){e===void 0&&(e={});const{placement:n="bottom",strategy:r="absolute",middleware:i=[],platform:o,elements:{reference:s,floating:c}={},transform:f=!0,whileElementsMounted:h,open:d}=e,[m,y]=x.useState({x:0,y:0,strategy:r,placement:n,middlewareData:{},isPositioned:!1}),[b,w]=x.useState(i);Qu(b,i)||w(i);const[k,C]=x.useState(null),[T,A]=x.useState(null),_=x.useCallback(U=>{U!==j.current&&(j.current=U,C(U))},[]),N=x.useCallback(U=>{U!==$.current&&($.current=U,A(U))},[]),O=s||k,z=c||T,j=x.useRef(null),$=x.useRef(null),G=x.useRef(m),ee=h!=null,P=mh(h),ne=mh(o),ae=mh(d),le=x.useCallback(()=>{if(!j.current||!$.current)return;const U={placement:n,strategy:r,middleware:b};ne.current&&(U.platform=ne.current),SO(j.current,$.current,U).then(J=>{const E={...J,isPositioned:ae.current!==!1};H.current&&!Qu(G.current,E)&&(G.current=E,oc.flushSync(()=>{y(E)}))})},[b,n,r,ne,ae]);Bu(()=>{d===!1&&G.current.isPositioned&&(G.current.isPositioned=!1,y(U=>({...U,isPositioned:!1})))},[d]);const H=x.useRef(!1);Bu(()=>(H.current=!0,()=>{H.current=!1}),[]),Bu(()=>{if(O&&(j.current=O),z&&($.current=z),O&&z){if(P.current)return P.current(O,z,le);le()}},[O,z,le,P,ee]);const Q=x.useMemo(()=>({reference:j,floating:$,setReference:_,setFloating:N}),[_,N]),L=x.useMemo(()=>({reference:O,floating:z}),[O,z]),K=x.useMemo(()=>{const U={position:r,left:0,top:0};if(!L.floating)return U;const J=xb(L.floating,m.x),E=xb(L.floating,m.y);return f?{...U,transform:"translate("+J+"px, "+E+"px)",...Nw(L.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:J,top:E}},[r,f,L.floating,m.x,m.y]);return x.useMemo(()=>({...m,update:le,refs:Q,elements:L,floatingStyles:K}),[m,le,Q,L,K])}const AO=e=>{function n(r){return{}.hasOwnProperty.call(r,"current")}return{name:"arrow",options:e,fn(r){const{element:i,padding:o}=typeof e=="function"?e(r):e;return i&&n(i)?i.current!=null?vb({element:i.current,padding:o}).fn(r):{}:i?vb({element:i,padding:o}).fn(r):{}}}},TO=(e,n)=>({...gO(e),options:[e,n]}),RO=(e,n)=>({...yO(e),options:[e,n]}),_O=(e,n)=>({...wO(e),options:[e,n]}),NO=(e,n)=>({...vO(e),options:[e,n]}),MO=(e,n)=>({...xO(e),options:[e,n]}),jO=(e,n)=>({...bO(e),options:[e,n]}),DO=(e,n)=>({...AO(e),options:[e,n]});var OO="Arrow",Mw=x.forwardRef((e,n)=>{const{children:r,width:i=10,height:o=5,...s}=e;return g.jsx(Fe.svg,{...s,ref:n,width:i,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?r:g.jsx("polygon",{points:"0,0 30,0 15,10"})})});Mw.displayName=OO;var LO=Mw;function jw(e){const[n,r]=x.useState(void 0);return cr(()=>{if(e){r({width:e.offsetWidth,height:e.offsetHeight});const i=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const s=o[0];let c,f;if("borderBoxSize"in s){const h=s.borderBoxSize,d=Array.isArray(h)?h[0]:h;c=d.inlineSize,f=d.blockSize}else c=e.offsetWidth,f=e.offsetHeight;r({width:c,height:f})});return i.observe(e,{box:"border-box"}),()=>i.unobserve(e)}else r(void 0)},[e]),n}var Jp="Popper",[Dw,wc]=Qn(Jp),[zO,Ow]=Dw(Jp),Lw=e=>{const{__scopePopper:n,children:r}=e,[i,o]=x.useState(null);return g.jsx(zO,{scope:n,anchor:i,onAnchorChange:o,children:r})};Lw.displayName=Jp;var zw="PopperAnchor",Pw=x.forwardRef((e,n)=>{const{__scopePopper:r,virtualRef:i,...o}=e,s=Ow(zw,r),c=x.useRef(null),f=Xe(n,c),h=x.useRef(null);return x.useEffect(()=>{const d=h.current;h.current=i?.current||c.current,d!==h.current&&s.onAnchorChange(h.current)}),i?null:g.jsx(Fe.div,{...o,ref:f})});Pw.displayName=zw;var em="PopperContent",[PO,IO]=Dw(em),Iw=x.forwardRef((e,n)=>{const{__scopePopper:r,side:i="bottom",sideOffset:o=0,align:s="center",alignOffset:c=0,arrowPadding:f=0,avoidCollisions:h=!0,collisionBoundary:d=[],collisionPadding:m=0,sticky:y="partial",hideWhenDetached:b=!1,updatePositionStrategy:w="optimized",onPlaced:k,...C}=e,T=Ow(em,r),[A,_]=x.useState(null),N=Xe(n,xe=>_(xe)),[O,z]=x.useState(null),j=jw(O),$=j?.width??0,G=j?.height??0,ee=i+(s!=="center"?"-"+s:""),P=typeof m=="number"?m:{top:0,right:0,bottom:0,left:0,...m},ne=Array.isArray(d)?d:[d],ae=ne.length>0,le={padding:P,boundary:ne.filter(UO),altBoundary:ae},{refs:H,floatingStyles:Q,placement:L,isPositioned:K,middlewareData:U}=CO({strategy:"fixed",placement:ee,whileElementsMounted:(...xe)=>mO(...xe,{animationFrame:w==="always"}),elements:{reference:T.anchor},middleware:[TO({mainAxis:o+G,alignmentAxis:c}),h&&RO({mainAxis:!0,crossAxis:!1,limiter:y==="partial"?_O():void 0,...le}),h&&NO({...le}),MO({...le,apply:({elements:xe,rects:Ee,availableWidth:Qe,availableHeight:bt})=>{const{width:Rt,height:It}=Ee.reference,Gt=xe.floating.style;Gt.setProperty("--radix-popper-available-width",`${Qe}px`),Gt.setProperty("--radix-popper-available-height",`${bt}px`),Gt.setProperty("--radix-popper-anchor-width",`${Rt}px`),Gt.setProperty("--radix-popper-anchor-height",`${It}px`)}}),O&&DO({element:O,padding:f}),HO({arrowWidth:$,arrowHeight:G}),b&&jO({strategy:"referenceHidden",...le})]}),[J,E]=Hw(L),Z=kt(k);cr(()=>{K&&Z?.()},[K,Z]);const oe=U.arrow?.x,M=U.arrow?.y,se=U.arrow?.centerOffset!==0,[Se,he]=x.useState();return cr(()=>{A&&he(window.getComputedStyle(A).zIndex)},[A]),g.jsx("div",{ref:H.setFloating,"data-radix-popper-content-wrapper":"",style:{...Q,transform:K?Q.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Se,"--radix-popper-transform-origin":[U.transformOrigin?.x,U.transformOrigin?.y].join(" "),...U.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:g.jsx(PO,{scope:r,placedSide:J,onArrowChange:z,arrowX:oe,arrowY:M,shouldHideArrow:se,children:g.jsx(Fe.div,{"data-side":J,"data-align":E,...C,ref:N,style:{...C.style,animation:K?void 0:"none"}})})})});Iw.displayName=em;var Bw="PopperArrow",BO={top:"bottom",right:"left",bottom:"top",left:"right"},Uw=x.forwardRef(function(n,r){const{__scopePopper:i,...o}=n,s=IO(Bw,i),c=BO[s.placedSide];return g.jsx("span",{ref:s.onArrowChange,style:{position:"absolute",left:s.arrowX,top:s.arrowY,[c]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[s.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[s.placedSide],visibility:s.shouldHideArrow?"hidden":void 0},children:g.jsx(LO,{...o,ref:r,style:{...o.style,display:"block"}})})});Uw.displayName=Bw;function UO(e){return e!==null}var HO=e=>({name:"transformOrigin",options:e,fn(n){const{placement:r,rects:i,middlewareData:o}=n,c=o.arrow?.centerOffset!==0,f=c?0:e.arrowWidth,h=c?0:e.arrowHeight,[d,m]=Hw(r),y={start:"0%",center:"50%",end:"100%"}[m],b=(o.arrow?.x??0)+f/2,w=(o.arrow?.y??0)+h/2;let k="",C="";return d==="bottom"?(k=c?y:`${b}px`,C=`${-h}px`):d==="top"?(k=c?y:`${b}px`,C=`${i.floating.height+h}px`):d==="right"?(k=`${-h}px`,C=c?y:`${w}px`):d==="left"&&(k=`${i.floating.width+h}px`,C=c?y:`${w}px`),{data:{x:k,y:C}}}});function Hw(e){const[n,r="center"]=e.split("-");return[n,r]}var Fw=Lw,qw=Pw,Vw=Iw,$w=Uw,[Sc,DB]=Qn("Tooltip",[wc]),Ec=wc(),Gw="TooltipProvider",FO=700,Wh="tooltip.open",[qO,tm]=Sc(Gw),Yw=e=>{const{__scopeTooltip:n,delayDuration:r=FO,skipDelayDuration:i=300,disableHoverableContent:o=!1,children:s}=e,c=x.useRef(!0),f=x.useRef(!1),h=x.useRef(0);return x.useEffect(()=>{const d=h.current;return()=>window.clearTimeout(d)},[]),g.jsx(qO,{scope:n,isOpenDelayedRef:c,delayDuration:r,onOpen:x.useCallback(()=>{window.clearTimeout(h.current),c.current=!1},[]),onClose:x.useCallback(()=>{window.clearTimeout(h.current),h.current=window.setTimeout(()=>c.current=!0,i)},[i]),isPointerInTransitRef:f,onPointerInTransitChange:x.useCallback(d=>{f.current=d},[]),disableHoverableContent:o,children:s})};Yw.displayName=Gw;var jo="Tooltip",[VO,kc]=Sc(jo),Kw=e=>{const{__scopeTooltip:n,children:r,open:i,defaultOpen:o,onOpenChange:s,disableHoverableContent:c,delayDuration:f}=e,h=tm(jo,e.__scopeTooltip),d=Ec(n),[m,y]=x.useState(null),b=$a(),w=x.useRef(0),k=c??h.disableHoverableContent,C=f??h.delayDuration,T=x.useRef(!1),[A,_]=ol({prop:i,defaultProp:o??!1,onChange:$=>{$?(h.onOpen(),document.dispatchEvent(new CustomEvent(Wh))):h.onClose(),s?.($)},caller:jo}),N=x.useMemo(()=>A?T.current?"delayed-open":"instant-open":"closed",[A]),O=x.useCallback(()=>{window.clearTimeout(w.current),w.current=0,T.current=!1,_(!0)},[_]),z=x.useCallback(()=>{window.clearTimeout(w.current),w.current=0,_(!1)},[_]),j=x.useCallback(()=>{window.clearTimeout(w.current),w.current=window.setTimeout(()=>{T.current=!0,_(!0),w.current=0},C)},[C,_]);return x.useEffect(()=>()=>{w.current&&(window.clearTimeout(w.current),w.current=0)},[]),g.jsx(Fw,{...d,children:g.jsx(VO,{scope:n,contentId:b,open:A,stateAttribute:N,trigger:m,onTriggerChange:y,onTriggerEnter:x.useCallback(()=>{h.isOpenDelayedRef.current?j():O()},[h.isOpenDelayedRef,j,O]),onTriggerLeave:x.useCallback(()=>{k?z():(window.clearTimeout(w.current),w.current=0)},[z,k]),onOpen:O,onClose:z,disableHoverableContent:k,children:r})})};Kw.displayName=jo;var Jh="TooltipTrigger",Xw=x.forwardRef((e,n)=>{const{__scopeTooltip:r,...i}=e,o=kc(Jh,r),s=tm(Jh,r),c=Ec(r),f=x.useRef(null),h=Xe(n,f,o.onTriggerChange),d=x.useRef(!1),m=x.useRef(!1),y=x.useCallback(()=>d.current=!1,[]);return x.useEffect(()=>()=>document.removeEventListener("pointerup",y),[y]),g.jsx(qw,{asChild:!0,...c,children:g.jsx(Fe.button,{"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute,...i,ref:h,onPointerMove:pe(e.onPointerMove,b=>{b.pointerType!=="touch"&&!m.current&&!s.isPointerInTransitRef.current&&(o.onTriggerEnter(),m.current=!0)}),onPointerLeave:pe(e.onPointerLeave,()=>{o.onTriggerLeave(),m.current=!1}),onPointerDown:pe(e.onPointerDown,()=>{o.open&&o.onClose(),d.current=!0,document.addEventListener("pointerup",y,{once:!0})}),onFocus:pe(e.onFocus,()=>{d.current||o.onOpen()}),onBlur:pe(e.onBlur,o.onClose),onClick:pe(e.onClick,o.onClose)})})});Xw.displayName=Jh;var $O="TooltipPortal",[OB,GO]=Sc($O,{forceMount:void 0}),el="TooltipContent",Qw=x.forwardRef((e,n)=>{const r=GO(el,e.__scopeTooltip),{forceMount:i=r.forceMount,side:o="top",...s}=e,c=kc(el,e.__scopeTooltip);return g.jsx(Zt,{present:i||c.open,children:c.disableHoverableContent?g.jsx(Zw,{side:o,...s,ref:n}):g.jsx(YO,{side:o,...s,ref:n})})}),YO=x.forwardRef((e,n)=>{const r=kc(el,e.__scopeTooltip),i=tm(el,e.__scopeTooltip),o=x.useRef(null),s=Xe(n,o),[c,f]=x.useState(null),{trigger:h,onClose:d}=r,m=o.current,{onPointerInTransitChange:y}=i,b=x.useCallback(()=>{f(null),y(!1)},[y]),w=x.useCallback((k,C)=>{const T=k.currentTarget,A={x:k.clientX,y:k.clientY},_=WO(A,T.getBoundingClientRect()),N=JO(A,_),O=e4(C.getBoundingClientRect()),z=n4([...N,...O]);f(z),y(!0)},[y]);return x.useEffect(()=>()=>b(),[b]),x.useEffect(()=>{if(h&&m){const k=T=>w(T,m),C=T=>w(T,h);return h.addEventListener("pointerleave",k),m.addEventListener("pointerleave",C),()=>{h.removeEventListener("pointerleave",k),m.removeEventListener("pointerleave",C)}}},[h,m,w,b]),x.useEffect(()=>{if(c){const k=C=>{const T=C.target,A={x:C.clientX,y:C.clientY},_=h?.contains(T)||m?.contains(T),N=!t4(A,c);_?b():N&&(b(),d())};return document.addEventListener("pointermove",k),()=>document.removeEventListener("pointermove",k)}},[h,m,c,d,b]),g.jsx(Zw,{...e,ref:s})}),[KO,XO]=Sc(jo,{isInside:!1}),QO=K0("TooltipContent"),Zw=x.forwardRef((e,n)=>{const{__scopeTooltip:r,children:i,"aria-label":o,onEscapeKeyDown:s,onPointerDownOutside:c,...f}=e,h=kc(el,r),d=Ec(r),{onClose:m}=h;return x.useEffect(()=>(document.addEventListener(Wh,m),()=>document.removeEventListener(Wh,m)),[m]),x.useEffect(()=>{if(h.trigger){const y=b=>{b.target?.contains(h.trigger)&&m()};return window.addEventListener("scroll",y,{capture:!0}),()=>window.removeEventListener("scroll",y,{capture:!0})}},[h.trigger,m]),g.jsx(Fo,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:s,onPointerDownOutside:c,onFocusOutside:y=>y.preventDefault(),onDismiss:m,children:g.jsxs(Vw,{"data-state":h.stateAttribute,...d,...f,ref:n,style:{...f.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[g.jsx(QO,{children:i}),g.jsx(KO,{scope:r,isInside:!0,children:g.jsx(b_,{id:h.contentId,role:"tooltip",children:o||i})})]})})});Qw.displayName=el;var Ww="TooltipArrow",ZO=x.forwardRef((e,n)=>{const{__scopeTooltip:r,...i}=e,o=Ec(r);return XO(Ww,r).isInside?null:g.jsx($w,{...o,...i,ref:n})});ZO.displayName=Ww;function WO(e,n){const r=Math.abs(n.top-e.y),i=Math.abs(n.bottom-e.y),o=Math.abs(n.right-e.x),s=Math.abs(n.left-e.x);switch(Math.min(r,i,o,s)){case s:return"left";case o:return"right";case r:return"top";case i:return"bottom";default:throw new Error("unreachable")}}function JO(e,n,r=5){const i=[];switch(n){case"top":i.push({x:e.x-r,y:e.y+r},{x:e.x+r,y:e.y+r});break;case"bottom":i.push({x:e.x-r,y:e.y-r},{x:e.x+r,y:e.y-r});break;case"left":i.push({x:e.x+r,y:e.y-r},{x:e.x+r,y:e.y+r});break;case"right":i.push({x:e.x-r,y:e.y-r},{x:e.x-r,y:e.y+r});break}return i}function e4(e){const{top:n,right:r,bottom:i,left:o}=e;return[{x:o,y:n},{x:r,y:n},{x:r,y:i},{x:o,y:i}]}function t4(e,n){const{x:r,y:i}=e;let o=!1;for(let s=0,c=n.length-1;s<n.length;c=s++){const f=n[s],h=n[c],d=f.x,m=f.y,y=h.x,b=h.y;m>i!=b>i&&r<(y-d)*(i-m)/(b-m)+d&&(o=!o)}return o}function n4(e){const n=e.slice();return n.sort((r,i)=>r.x<i.x?-1:r.x>i.x?1:r.y<i.y?-1:r.y>i.y?1:0),r4(n)}function r4(e){if(e.length<=1)return e.slice();const n=[];for(let i=0;i<e.length;i++){const o=e[i];for(;n.length>=2;){const s=n[n.length-1],c=n[n.length-2];if((s.x-c.x)*(o.y-c.y)>=(s.y-c.y)*(o.x-c.x))n.pop();else break}n.push(o)}n.pop();const r=[];for(let i=e.length-1;i>=0;i--){const o=e[i];for(;r.length>=2;){const s=r[r.length-1],c=r[r.length-2];if((s.x-c.x)*(o.y-c.y)>=(s.y-c.y)*(o.x-c.x))r.pop();else break}r.push(o)}return r.pop(),n.length===1&&r.length===1&&n[0].x===r[0].x&&n[0].y===r[0].y?n:n.concat(r)}var a4=Yw,i4=Kw,l4=Xw,Jw=Qw;const o4=a4,s4=i4,u4=l4,eS=x.forwardRef(({className:e,sideOffset:n=4,...r},i)=>g.jsx(Jw,{ref:i,sideOffset:n,className:fe("z-50 overflow-hidden rounded-md border bg-popover px-3 py-1.5 text-sm text-popover-foreground shadow-md animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...r}));eS.displayName=Jw.displayName;const c4="sidebar_state",f4=3600*24*7,d4="16rem",h4="18rem",p4="3rem",m4="b",tS=x.createContext(null);function Cc(){const e=x.useContext(tS);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const nS=x.forwardRef(({defaultOpen:e=!0,open:n,onOpenChange:r,className:i,style:o,children:s,...c},f)=>{const h=P1(),[d,m]=x.useState(!1),[y,b]=x.useState(e),w=n??y,k=x.useCallback(_=>{const N=typeof _=="function"?_(w):_;r?r(N):b(N),document.cookie=`${c4}=${N}; path=/; max-age=${f4}`},[r,w]),C=x.useCallback(()=>h?m(_=>!_):k(_=>!_),[h,k,m]);x.useEffect(()=>{const _=N=>{N.key===m4&&(N.metaKey||N.ctrlKey)&&(N.preventDefault(),C())};return window.addEventListener("keydown",_),()=>window.removeEventListener("keydown",_)},[C]);const T=w?"expanded":"collapsed",A=x.useMemo(()=>({state:T,open:w,setOpen:k,isMobile:h,openMobile:d,setOpenMobile:m,toggleSidebar:C}),[T,w,k,h,d,m,C]);return g.jsx(tS.Provider,{value:A,children:g.jsx(o4,{delayDuration:0,children:g.jsx("div",{style:{"--sidebar-width":d4,"--sidebar-width-icon":p4,...o},className:fe("group/sidebar-wrapper flex min-h-svh w-full has-[[data-variant=inset]]:bg-sidebar",i),ref:f,...c,children:s})})})});nS.displayName="SidebarProvider";const rS=x.forwardRef(({side:e="left",variant:n="sidebar",collapsible:r="offcanvas",className:i,children:o,...s},c)=>{const{isMobile:f,state:h,openMobile:d,setOpenMobile:m}=Cc();return r==="none"?g.jsx("div",{className:fe("flex h-full w-[--sidebar-width] flex-col bg-sidebar text-sidebar-foreground",i),ref:c,...s,children:o}):f?g.jsx(yw,{open:d,onOpenChange:m,...s,children:g.jsxs(qp,{"data-sidebar":"sidebar","data-mobile":"true",className:"w-[--sidebar-width] bg-sidebar p-0 text-sidebar-foreground [&>button]:hidden",style:{"--sidebar-width":h4},side:e,children:[g.jsxs(Vp,{className:"sr-only",children:[g.jsx($p,{children:"Sidebar"}),g.jsx(xw,{children:"Displays the mobile sidebar."})]}),g.jsx("div",{className:"flex h-full w-full flex-col",children:o})]})}):g.jsxs("div",{ref:c,className:"group peer hidden text-sidebar-foreground md:block","data-state":h,"data-collapsible":h==="collapsed"?r:"","data-variant":n,"data-side":e,children:[g.jsx("div",{className:fe("relative w-[--sidebar-width] bg-transparent transition-[width] duration-200 ease-linear","group-data-[collapsible=offcanvas]:w-0","group-data-[side=right]:rotate-180",n==="floating"||n==="inset"?"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon]")}),g.jsx("div",{className:fe("fixed inset-y-0 z-10 hidden h-svh w-[--sidebar-width] transition-[left,right,width] duration-200 ease-linear md:flex",e==="left"?"left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]":"right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]",n==="floating"||n==="inset"?"p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon] group-data-[side=left]:border-r group-data-[side=right]:border-l",i),...s,children:g.jsx("div",{"data-sidebar":"sidebar",className:"flex h-full w-full flex-col bg-sidebar group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:border group-data-[variant=floating]:border-sidebar-border group-data-[variant=floating]:shadow",children:o})})]})});rS.displayName="Sidebar";const aS=x.forwardRef(({className:e,onClick:n,...r},i)=>{const{toggleSidebar:o}=Cc();return g.jsxs(pt,{ref:i,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:fe("h-7 w-7",e),onClick:s=>{n?.(s),o()},...r,children:[g.jsx($N,{}),g.jsx("span",{className:"sr-only",children:"Toggle Sidebar"})]})});aS.displayName="SidebarTrigger";const g4=x.forwardRef(({className:e,...n},r)=>{const{toggleSidebar:i}=Cc();return g.jsx("button",{ref:r,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:i,title:"Toggle Sidebar",className:fe("absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] hover:after:bg-sidebar-border group-data-[side=left]:-right-4 group-data-[side=right]:left-0 sm:flex","[[data-side=left]_&]:cursor-w-resize [[data-side=right]_&]:cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize","group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full group-data-[collapsible=offcanvas]:hover:bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:-right-2","[[data-side=right][data-collapsible=offcanvas]_&]:-left-2",e),...n})});g4.displayName="SidebarRail";const iS=x.forwardRef(({className:e,...n},r)=>g.jsx("main",{ref:r,className:fe("relative flex w-full flex-1 flex-col bg-background","md:peer-data-[variant=inset]:m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:ml-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow",e),...n}));iS.displayName="SidebarInset";const y4=x.forwardRef(({className:e,...n},r)=>g.jsx(I1,{ref:r,"data-sidebar":"input",className:fe("h-8 w-full bg-background shadow-none focus-visible:ring-2 focus-visible:ring-sidebar-ring",e),...n}));y4.displayName="SidebarInput";const lS=x.forwardRef(({className:e,...n},r)=>g.jsx("div",{ref:r,"data-sidebar":"header",className:fe("flex flex-col gap-2 p-2",e),...n}));lS.displayName="SidebarHeader";const oS=x.forwardRef(({className:e,...n},r)=>g.jsx("div",{ref:r,"data-sidebar":"footer",className:fe("flex flex-col gap-2 p-2",e),...n}));oS.displayName="SidebarFooter";const v4=x.forwardRef(({className:e,...n},r)=>g.jsx(H1,{ref:r,"data-sidebar":"separator",className:fe("mx-2 w-auto bg-sidebar-border",e),...n}));v4.displayName="SidebarSeparator";const sS=x.forwardRef(({className:e,...n},r)=>g.jsx("div",{ref:r,"data-sidebar":"content",className:fe("flex min-h-0 flex-1 flex-col gap-2 overflow-auto group-data-[collapsible=icon]:overflow-hidden",e),...n}));sS.displayName="SidebarContent";const yo=x.forwardRef(({className:e,...n},r)=>g.jsx("div",{ref:r,"data-sidebar":"group",className:fe("relative flex w-full min-w-0 flex-col p-2",e),...n}));yo.displayName="SidebarGroup";const Uu=x.forwardRef(({className:e,asChild:n=!1,...r},i)=>{const o=n?ll:"div";return g.jsx(o,{ref:i,"data-sidebar":"group-label",className:fe("flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium text-sidebar-foreground/70 outline-none ring-sidebar-ring transition-[margin,opacity] duration-200 ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0",e),...r})});Uu.displayName="SidebarGroupLabel";const x4=x.forwardRef(({className:e,asChild:n=!1,...r},i)=>{const o=n?ll:"button";return g.jsx(o,{ref:i,"data-sidebar":"group-action",className:fe("absolute right-3 top-3.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:md:hidden","group-data-[collapsible=icon]:hidden",e),...r})});x4.displayName="SidebarGroupAction";const vo=x.forwardRef(({className:e,...n},r)=>g.jsx("div",{ref:r,"data-sidebar":"group-content",className:fe("w-full text-sm",e),...n}));vo.displayName="SidebarGroupContent";const Va=x.forwardRef(({className:e,...n},r)=>g.jsx("ul",{ref:r,"data-sidebar":"menu",className:fe("flex w-full min-w-0 flex-col gap-1",e),...n}));Va.displayName="SidebarMenu";const ha=x.forwardRef(({className:e,...n},r)=>g.jsx("li",{ref:r,"data-sidebar":"menu-item",className:fe("group/menu-item relative",e),...n}));ha.displayName="SidebarMenuItem";const b4=pc("peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm outline-none ring-sidebar-ring transition-[width,height,padding] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:bg-sidebar-active data-[active=true]:font-medium data-[active=true]:text-sidebar-active-foreground data-[state=open]:hover:bg-sidebar-accent data-[state=open]:hover:text-sidebar-accent-foreground group-data-[collapsible=icon]:!size-8 group-data-[collapsible=icon]:!p-2 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0",{variants:{variant:{default:"hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",outline:"bg-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"h-8 text-sm",sm:"h-7 text-xs",lg:"h-12 text-sm group-data-[collapsible=icon]:!p-0"}},defaultVariants:{variant:"default",size:"default"}}),pa=x.forwardRef(({asChild:e=!1,isActive:n=!1,variant:r="default",size:i="default",tooltip:o,className:s,...c},f)=>{const h=e?ll:"button",{isMobile:d,state:m}=Cc(),y=g.jsx(h,{ref:f,"data-sidebar":"menu-button","data-size":i,"data-active":n,className:fe(b4({variant:r,size:i}),s),...c});return o?(typeof o=="string"&&(o={children:o}),g.jsxs(s4,{children:[g.jsx(u4,{asChild:!0,children:y}),g.jsx(eS,{side:"right",align:"center",hidden:m!=="collapsed"||d,...o})]})):y});pa.displayName="SidebarMenuButton";const w4=x.forwardRef(({className:e,asChild:n=!1,showOnHover:r=!1,...i},o)=>{const s=n?ll:"button";return g.jsx(s,{ref:o,"data-sidebar":"menu-action",className:fe("absolute right-1 top-1.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 peer-hover/menu-button:text-sidebar-accent-foreground [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:md:hidden","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",r&&"group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 peer-data-[active=true]/menu-button:text-sidebar-active-foreground md:opacity-0",e),...i})});w4.displayName="SidebarMenuAction";const ep=x.forwardRef(({className:e,...n},r)=>g.jsx("div",{ref:r,"data-sidebar":"menu-badge",className:fe("pointer-events-none absolute right-1 flex h-5 min-w-5 select-none items-center justify-center rounded-full px-1.5 text-xs font-semibold tabular-nums shadow-sm","transition-all duration-200 ease-in-out hover:scale-110","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",e),...n}));ep.displayName="SidebarMenuBadge";const S4=x.forwardRef(({className:e,showIcon:n=!1,...r},i)=>{const o=x.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return g.jsxs("div",{ref:i,"data-sidebar":"menu-skeleton",className:fe("flex h-8 items-center gap-2 rounded-md px-2",e),...r,children:[n&&g.jsx(ub,{className:"size-4 rounded-md","data-sidebar":"menu-skeleton-icon"}),g.jsx(ub,{className:"h-4 max-w-[--skeleton-width] flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});S4.displayName="SidebarMenuSkeleton";const uS=x.forwardRef(({className:e,...n},r)=>g.jsx("ul",{ref:r,"data-sidebar":"menu-sub",className:fe("mx-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-l border-sidebar-border px-2.5 py-0.5","group-data-[collapsible=icon]:hidden",e),...n}));uS.displayName="SidebarMenuSub";const cS=x.forwardRef(({...e},n)=>g.jsx("li",{ref:n,...e}));cS.displayName="SidebarMenuSubItem";const fS=x.forwardRef(({asChild:e=!1,size:n="md",isActive:r,className:i,...o},s)=>{const c=e?ll:"a";return g.jsx(c,{ref:s,"data-sidebar":"menu-sub-button","data-size":n,"data-active":r,className:fe("flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 text-sidebar-foreground outline-none ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 [&>svg]:text-sidebar-accent-foreground","data-[active=true]:bg-sidebar-active data-[active=true]:text-sidebar-active-foreground",n==="sm"&&"text-xs",n==="md"&&"text-sm","group-data-[collapsible=icon]:hidden",i),...o})});fS.displayName="SidebarMenuSubButton";const E4="1.0.76-alpha.0",k4={version:E4};function C4({className:e}){return g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:e,children:[g.jsx("path",{d:"M13 8c0-2.76-2.46-5-5.5-5S2 5.24 2 8h2l1-1 1 1h4"}),g.jsx("path",{d:"M13 7.14A5.82 5.82 0 0 1 16.5 6c3.04 0 5.5 2.24 5.5 5h-3l-1-1-1 1h-3"}),g.jsx("path",{d:"M5.89 9.71c-2.15 2.15-2.3 5.47-.35 7.43l4.24-4.25.7-.7.71-.71 2.12-2.12c-1.95-1.96-5.27-1.8-7.42.35"}),g.jsx("path",{d:"M11 15.5c.5 2.5-.17 4.5-1 6.5h4c2-5.5-.5-12-1-14"})]})}function Ha(e,n){if(n==="/")return e==="/";const r=e.match(/^\/terminal\/([^/]+)/);if(r){const i=r[1];if(n==="/agents")return i.startsWith("cp-")||i.startsWith("sk-");if(n==="/terminal")return!i.startsWith("cp-")&&!i.startsWith("sk-")}return e===n||e.startsWith(n+"/")}const A4=[{title:"Home",url:"/",icon:EN},{title:"Tasks",url:"/tasks",icon:uM},{title:"Skills",url:"/skills",icon:RM},{title:"Mail",url:"/mail",icon:zN}],T4=[{title:"Agents",url:"/agents",icon:So},{title:"Jobs",url:"/schedule",icon:Q_},{title:"Utilities",url:"/utilities",icon:CM}],R4=[{title:"Knowledge",url:"/knowledge",icon:_o},{title:"Resources",url:"/resources",icon:mN}],bb=[{title:"Overview",url:"/context/project",icon:_o},{title:"Architecture",url:"/context/architecture",icon:eM},{title:"Role",url:"/context/role",icon:wM}],_4=[{title:"Source Control",url:"/git",icon:b1},{title:"Terminal",url:"/terminal",icon:mM},{title:"Identity",url:"/identity",icon:CN},{title:"Activity",url:"/activity",icon:$_}],N4=[{title:"Documentation",url:"https://docs.coconut.dev/studio",icon:qN,external:!0},{title:"Settings",url:"/settings/user",icon:nM}];function M4(){const{badges:e}=HR(),n=on(),[r,i]=x.useState(!1);return x.useEffect(()=>{bb.some(s=>Ha(n.pathname,s.url))&&i(!0)},[n.pathname]),g.jsxs(rS,{className:"bg-sidebar border-r border-sidebar-border",children:[g.jsx(lS,{children:g.jsx(Va,{children:g.jsx(ha,{children:g.jsx(pa,{size:"lg",asChild:!0,className:"[&>svg]:!size-8",children:g.jsxs($n,{to:"/",children:[g.jsx(C4,{className:"size-8"}),g.jsxs("div",{className:"flex flex-col gap-0.5",children:[g.jsxs("span",{className:"font-semibold",children:[g.jsx("span",{className:"bg-gradient-to-r from-amber-500 via-orange-500 to-yellow-600 bg-clip-text text-transparent",children:"Coconut"}),g.jsx("span",{children:" Studio"})]}),g.jsxs("span",{className:"text-xs text-muted-foreground",children:["v",k4.version]})]})]})})})})}),g.jsxs(sS,{children:[g.jsx(yo,{children:g.jsx(vo,{children:g.jsx(Va,{children:A4.map(o=>g.jsx(ha,{children:g.jsx(pa,{asChild:!0,isActive:Ha(n.pathname,o.url),children:g.jsxs($n,{to:o.url,children:[g.jsx(o.icon,{}),g.jsx("span",{children:o.title})]})})},o.title))})})}),g.jsxs(yo,{children:[g.jsx(Uu,{children:"Work"}),g.jsx(vo,{children:g.jsx(Va,{children:T4.map(o=>{let s=0;return o.title==="Agents"&&e.codeSessions>0?s=e.codeSessions:o.title==="Jobs"&&e.runningScheduledJobs>0&&(s=e.runningScheduledJobs),g.jsxs(ha,{children:[g.jsx(pa,{asChild:!0,isActive:Ha(n.pathname,o.url),children:g.jsxs($n,{to:o.url,children:[g.jsx(o.icon,{}),g.jsx("span",{children:o.title})]})}),s>0&&g.jsx(ep,{className:"bg-blue-600 text-white dark:bg-blue-500",children:s})]},o.title)})})})]}),g.jsxs(yo,{children:[g.jsx(Uu,{children:"Assets"}),g.jsx(vo,{children:g.jsxs(Va,{children:[R4.map(o=>g.jsx(ha,{children:g.jsx(pa,{asChild:!0,isActive:Ha(n.pathname,o.url),children:g.jsxs($n,{to:o.url,children:[g.jsx(o.icon,{}),g.jsx("span",{children:o.title})]})})},o.title)),g.jsxs(ha,{children:[g.jsxs(pa,{onClick:()=>i(o=>!o),"data-state":r?"open":"closed",className:"w-full",children:[g.jsx(yN,{}),g.jsx("span",{children:"Context"}),g.jsx(tN,{className:`ml-auto size-4 shrink-0 transition-transform duration-200 ${r?"rotate-180":""}`})]}),r&&g.jsx(uS,{children:bb.map(o=>g.jsx(cS,{children:g.jsx(fS,{asChild:!0,isActive:Ha(n.pathname,o.url),children:g.jsxs($n,{to:o.url,children:[g.jsx(o.icon,{}),g.jsx("span",{children:o.title})]})})},o.title))})]})]})})]}),g.jsxs(yo,{children:[g.jsx(Uu,{children:"System"}),g.jsx(vo,{children:g.jsx(Va,{children:_4.map(o=>{let s=0;return o.title==="Source Control"&&e.gitChanges>0?s=e.gitChanges:o.title==="Terminal"&&e.terminalSessions>0&&(s=e.terminalSessions),g.jsxs(ha,{children:[g.jsx(pa,{asChild:!0,isActive:Ha(n.pathname,o.url),children:g.jsxs($n,{to:o.url,children:[g.jsx(o.icon,{}),g.jsx("span",{children:o.title})]})}),s>0&&g.jsx(ep,{className:"bg-blue-600 text-white dark:bg-blue-500",children:s})]},o.title)})})})]})]}),g.jsx(oS,{children:g.jsx(Va,{children:N4.map(o=>g.jsx(ha,{children:g.jsx(pa,{asChild:!0,isActive:!o.external&&Ha(n.pathname,o.url==="/settings/user"?"/settings":o.url),children:o.external?g.jsxs("a",{href:o.url,target:"_blank",rel:"noopener noreferrer",children:[g.jsx(o.icon,{}),g.jsx("span",{children:o.title})]}):g.jsxs($n,{to:o.url,children:[g.jsx(o.icon,{}),g.jsx("span",{children:o.title})]})})},o.title))})})]})}function j4(e){const n=e.match(/\bres-\d+-[a-z0-9]+\b/g);return n?[...new Set(n)]:[]}const Ac=Hp,LB=gw,D4=Fp,dS=x.forwardRef(({className:e,...n},r)=>g.jsx(Vo,{ref:r,className:fe("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...n}));dS.displayName=Vo.displayName;const Xo=x.forwardRef(({className:e,children:n,...r},i)=>g.jsxs(D4,{children:[g.jsx(dS,{}),g.jsxs($o,{ref:i,className:fe("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",e),...r,children:[n,g.jsxs(yc,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground",children:[g.jsx(Yi,{className:"h-4 w-4"}),g.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));Xo.displayName=$o.displayName;const Qo=({className:e,...n})=>g.jsx("div",{className:fe("flex flex-col space-y-1.5 text-center sm:text-left",e),...n});Qo.displayName="DialogHeader";const hS=({className:e,...n})=>g.jsx("div",{className:fe("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...n});hS.displayName="DialogFooter";const Zo=x.forwardRef(({className:e,...n},r)=>g.jsx(Go,{ref:r,className:fe("text-lg font-semibold leading-none tracking-tight",e),...n}));Zo.displayName=Go.displayName;const xo=x.forwardRef(({className:e,...n},r)=>g.jsx(Yo,{ref:r,className:fe("text-sm text-muted-foreground",e),...n}));xo.displayName=Yo.displayName;function gh({className:e,...n}){return g.jsx("kbd",{"data-slot":"kbd",className:fe("inline-flex h-5 items-center justify-center rounded border border-muted-foreground/30 bg-muted/50 px-1.5 font-sans text-[11px] font-medium text-muted-foreground shadow-sm",e),...n})}function zB({className:e,...n}){return g.jsx("span",{"data-slot":"kbd-group",className:fe("inline-flex items-center gap-0.5",e),...n})}function PB(){}function IB(){}function BB(e){const n=[],r=String(e||"");let i=r.indexOf(","),o=0,s=!1;for(;!s;){i===-1&&(i=r.length,s=!0);const c=r.slice(o,i).trim();(c||!s)&&n.push(c),o=i+1,i=r.indexOf(",",o)}return n}function O4(e,n){const r=n||{};return(e[e.length-1]===""?[...e,""]:e).join((r.padRight?" ":"")+","+(r.padLeft===!1?"":" ")).trim()}const L4=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,z4=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,P4={};function wb(e,n){return(P4.jsx?z4:L4).test(e)}const I4=/[ \t\n\f\r]/g;function B4(e){return typeof e=="object"?e.type==="text"?Sb(e.value):!1:Sb(e)}function Sb(e){return e.replace(I4,"")===""}class Wo{constructor(n,r,i){this.normal=r,this.property=n,i&&(this.space=i)}}Wo.prototype.normal={};Wo.prototype.property={};Wo.prototype.space=void 0;function pS(e,n){const r={},i={};for(const o of e)Object.assign(r,o.property),Object.assign(i,o.normal);return new Wo(r,i,n)}function tp(e){return e.toLowerCase()}class sn{constructor(n,r){this.attribute=r,this.property=n}}sn.prototype.attribute="";sn.prototype.booleanish=!1;sn.prototype.boolean=!1;sn.prototype.commaOrSpaceSeparated=!1;sn.prototype.commaSeparated=!1;sn.prototype.defined=!1;sn.prototype.mustUseProperty=!1;sn.prototype.number=!1;sn.prototype.overloadedBoolean=!1;sn.prototype.property="";sn.prototype.spaceSeparated=!1;sn.prototype.space=void 0;let U4=0;const Le=Xa(),Et=Xa(),np=Xa(),ce=Xa(),lt=Xa(),Qi=Xa(),yn=Xa();function Xa(){return 2**++U4}const rp=Object.freeze(Object.defineProperty({__proto__:null,boolean:Le,booleanish:Et,commaOrSpaceSeparated:yn,commaSeparated:Qi,number:ce,overloadedBoolean:np,spaceSeparated:lt},Symbol.toStringTag,{value:"Module"})),yh=Object.keys(rp);class nm extends sn{constructor(n,r,i,o){let s=-1;if(super(n,r),Eb(this,"space",o),typeof i=="number")for(;++s<yh.length;){const c=yh[s];Eb(this,yh[s],(i&rp[c])===rp[c])}}}nm.prototype.defined=!0;function Eb(e,n,r){r&&(e[n]=r)}function dl(e){const n={},r={};for(const[i,o]of Object.entries(e.properties)){const s=new nm(i,e.transform(e.attributes||{},i),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(i)&&(s.mustUseProperty=!0),n[i]=s,r[tp(i)]=i,r[tp(s.attribute)]=i}return new Wo(n,r,e.space)}const mS=dl({properties:{ariaActiveDescendant:null,ariaAtomic:Et,ariaAutoComplete:null,ariaBusy:Et,ariaChecked:Et,ariaColCount:ce,ariaColIndex:ce,ariaColSpan:ce,ariaControls:lt,ariaCurrent:null,ariaDescribedBy:lt,ariaDetails:null,ariaDisabled:Et,ariaDropEffect:lt,ariaErrorMessage:null,ariaExpanded:Et,ariaFlowTo:lt,ariaGrabbed:Et,ariaHasPopup:null,ariaHidden:Et,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:lt,ariaLevel:ce,ariaLive:null,ariaModal:Et,ariaMultiLine:Et,ariaMultiSelectable:Et,ariaOrientation:null,ariaOwns:lt,ariaPlaceholder:null,ariaPosInSet:ce,ariaPressed:Et,ariaReadOnly:Et,ariaRelevant:null,ariaRequired:Et,ariaRoleDescription:lt,ariaRowCount:ce,ariaRowIndex:ce,ariaRowSpan:ce,ariaSelected:Et,ariaSetSize:ce,ariaSort:null,ariaValueMax:ce,ariaValueMin:ce,ariaValueNow:ce,ariaValueText:null,role:null},transform(e,n){return n==="role"?n:"aria-"+n.slice(4).toLowerCase()}});function gS(e,n){return n in e?e[n]:n}function yS(e,n){return gS(e,n.toLowerCase())}const H4=dl({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:Qi,acceptCharset:lt,accessKey:lt,action:null,allow:null,allowFullScreen:Le,allowPaymentRequest:Le,allowUserMedia:Le,alt:null,as:null,async:Le,autoCapitalize:null,autoComplete:lt,autoFocus:Le,autoPlay:Le,blocking:lt,capture:null,charSet:null,checked:Le,cite:null,className:lt,cols:ce,colSpan:null,content:null,contentEditable:Et,controls:Le,controlsList:lt,coords:ce|Qi,crossOrigin:null,data:null,dateTime:null,decoding:null,default:Le,defer:Le,dir:null,dirName:null,disabled:Le,download:np,draggable:Et,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:Le,formTarget:null,headers:lt,height:ce,hidden:np,high:ce,href:null,hrefLang:null,htmlFor:lt,httpEquiv:lt,id:null,imageSizes:null,imageSrcSet:null,inert:Le,inputMode:null,integrity:null,is:null,isMap:Le,itemId:null,itemProp:lt,itemRef:lt,itemScope:Le,itemType:lt,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:Le,low:ce,manifest:null,max:null,maxLength:ce,media:null,method:null,min:null,minLength:ce,multiple:Le,muted:Le,name:null,nonce:null,noModule:Le,noValidate:Le,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:Le,optimum:ce,pattern:null,ping:lt,placeholder:null,playsInline:Le,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:Le,referrerPolicy:null,rel:lt,required:Le,reversed:Le,rows:ce,rowSpan:ce,sandbox:lt,scope:null,scoped:Le,seamless:Le,selected:Le,shadowRootClonable:Le,shadowRootDelegatesFocus:Le,shadowRootMode:null,shape:null,size:ce,sizes:null,slot:null,span:ce,spellCheck:Et,src:null,srcDoc:null,srcLang:null,srcSet:null,start:ce,step:null,style:null,tabIndex:ce,target:null,title:null,translate:null,type:null,typeMustMatch:Le,useMap:null,value:Et,width:ce,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:lt,axis:null,background:null,bgColor:null,border:ce,borderColor:null,bottomMargin:ce,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:Le,declare:Le,event:null,face:null,frame:null,frameBorder:null,hSpace:ce,leftMargin:ce,link:null,longDesc:null,lowSrc:null,marginHeight:ce,marginWidth:ce,noResize:Le,noHref:Le,noShade:Le,noWrap:Le,object:null,profile:null,prompt:null,rev:null,rightMargin:ce,rules:null,scheme:null,scrolling:Et,standby:null,summary:null,text:null,topMargin:ce,valueType:null,version:null,vAlign:null,vLink:null,vSpace:ce,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:Le,disableRemotePlayback:Le,prefix:null,property:null,results:ce,security:null,unselectable:null},space:"html",transform:yS}),F4=dl({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:yn,accentHeight:ce,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:ce,amplitude:ce,arabicForm:null,ascent:ce,attributeName:null,attributeType:null,azimuth:ce,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:ce,by:null,calcMode:null,capHeight:ce,className:lt,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:ce,diffuseConstant:ce,direction:null,display:null,dur:null,divisor:ce,dominantBaseline:null,download:Le,dx:null,dy:null,edgeMode:null,editable:null,elevation:ce,enableBackground:null,end:null,event:null,exponent:ce,externalResourcesRequired:null,fill:null,fillOpacity:ce,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:Qi,g2:Qi,glyphName:Qi,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:ce,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:ce,horizOriginX:ce,horizOriginY:ce,id:null,ideographic:ce,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:ce,k:ce,k1:ce,k2:ce,k3:ce,k4:ce,kernelMatrix:yn,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:ce,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:ce,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:ce,overlineThickness:ce,paintOrder:null,panose1:null,path:null,pathLength:ce,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:lt,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:ce,pointsAtY:ce,pointsAtZ:ce,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:yn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:yn,rev:yn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:yn,requiredFeatures:yn,requiredFonts:yn,requiredFormats:yn,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:ce,specularExponent:ce,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:ce,strikethroughThickness:ce,string:null,stroke:null,strokeDashArray:yn,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:ce,strokeOpacity:ce,strokeWidth:null,style:null,surfaceScale:ce,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:yn,tabIndex:ce,tableValues:null,target:null,targetX:ce,targetY:ce,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:yn,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:ce,underlineThickness:ce,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:ce,values:null,vAlphabetic:ce,vMathematical:ce,vectorEffect:null,vHanging:ce,vIdeographic:ce,version:null,vertAdvY:ce,vertOriginX:ce,vertOriginY:ce,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:ce,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:gS}),vS=dl({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(e,n){return"xlink:"+n.slice(5).toLowerCase()}}),xS=dl({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:yS}),bS=dl({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,n){return"xml:"+n.slice(3).toLowerCase()}}),q4={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"},V4=/[A-Z]/g,kb=/-[a-z]/g,$4=/^data[-\w.:]+$/i;function G4(e,n){const r=tp(n);let i=n,o=sn;if(r in e.normal)return e.property[e.normal[r]];if(r.length>4&&r.slice(0,4)==="data"&&$4.test(n)){if(n.charAt(4)==="-"){const s=n.slice(5).replace(kb,K4);i="data"+s.charAt(0).toUpperCase()+s.slice(1)}else{const s=n.slice(4);if(!kb.test(s)){let c=s.replace(V4,Y4);c.charAt(0)!=="-"&&(c="-"+c),n="data"+c}}o=nm}return new o(i,n)}function Y4(e){return"-"+e.toLowerCase()}function K4(e){return e.charAt(1).toUpperCase()}const X4=pS([mS,H4,vS,xS,bS],"html"),rm=pS([mS,F4,vS,xS,bS],"svg");function UB(e){const n=String(e||"").trim();return n?n.split(/[ \t\n\r\f]+/g):[]}function Q4(e){return e.join(" ").trim()}var Vi={},vh,Cb;function Z4(){if(Cb)return vh;Cb=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,n=/\n/g,r=/^\s*/,i=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,s=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,c=/^[;\s]*/,f=/^\s+|\s+$/g,h=`
|
|
386
386
|
`,d="/",m="*",y="",b="comment",w="declaration";vh=function(C,T){if(typeof C!="string")throw new TypeError("First argument must be a string");if(!C)return[];T=T||{};var A=1,_=1;function N(le){var H=le.match(n);H&&(A+=H.length);var Q=le.lastIndexOf(h);_=~Q?le.length-Q:_+le.length}function O(){var le={line:A,column:_};return function(H){return H.position=new z(le),G(),H}}function z(le){this.start=le,this.end={line:A,column:_},this.source=T.source}z.prototype.content=C;function j(le){var H=new Error(T.source+":"+A+":"+_+": "+le);if(H.reason=le,H.filename=T.source,H.line=A,H.column=_,H.source=C,!T.silent)throw H}function $(le){var H=le.exec(C);if(H){var Q=H[0];return N(Q),C=C.slice(Q.length),H}}function G(){$(r)}function ee(le){var H;for(le=le||[];H=P();)H!==!1&&le.push(H);return le}function P(){var le=O();if(!(d!=C.charAt(0)||m!=C.charAt(1))){for(var H=2;y!=C.charAt(H)&&(m!=C.charAt(H)||d!=C.charAt(H+1));)++H;if(H+=2,y===C.charAt(H-1))return j("End of comment missing");var Q=C.slice(2,H-2);return _+=2,N(Q),C=C.slice(H),_+=2,le({type:b,comment:Q})}}function ne(){var le=O(),H=$(i);if(H){if(P(),!$(o))return j("property missing ':'");var Q=$(s),L=le({type:w,property:k(H[0].replace(e,y)),value:Q?k(Q[0].replace(e,y)):y});return $(c),L}}function ae(){var le=[];ee(le);for(var H;H=ne();)H!==!1&&(le.push(H),ee(le));return le}return G(),ae()};function k(C){return C?C.replace(f,y):y}return vh}var Ab;function W4(){if(Ab)return Vi;Ab=1;var e=Vi&&Vi.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(Vi,"__esModule",{value:!0}),Vi.default=r;var n=e(Z4());function r(i,o){var s=null;if(!i||typeof i!="string")return s;var c=(0,n.default)(i),f=typeof o=="function";return c.forEach(function(h){if(h.type==="declaration"){var d=h.property,m=h.value;f?o(d,m,h):m&&(s=s||{},s[d]=m)}}),s}return Vi}var ho={},Tb;function J4(){if(Tb)return ho;Tb=1,Object.defineProperty(ho,"__esModule",{value:!0}),ho.camelCase=void 0;var e=/^--[a-zA-Z0-9_-]+$/,n=/-([a-z])/g,r=/^[^-]+$/,i=/^-(webkit|moz|ms|o|khtml)-/,o=/^-(ms)-/,s=function(d){return!d||r.test(d)||e.test(d)},c=function(d,m){return m.toUpperCase()},f=function(d,m){return"".concat(m,"-")},h=function(d,m){return m===void 0&&(m={}),s(d)?d:(d=d.toLowerCase(),m.reactCompat?d=d.replace(o,f):d=d.replace(i,f),d.replace(n,c))};return ho.camelCase=h,ho}var po,Rb;function eL(){if(Rb)return po;Rb=1;var e=po&&po.__importDefault||function(o){return o&&o.__esModule?o:{default:o}},n=e(W4()),r=J4();function i(o,s){var c={};return!o||typeof o!="string"||(0,n.default)(o,function(f,h){f&&h&&(c[(0,r.camelCase)(f,s)]=h)}),c}return i.default=i,po=i,po}var tL=eL();const nL=ac(tL),wS=SS("end"),am=SS("start");function SS(e){return n;function n(r){const i=r&&r.position&&r.position[e]||{};if(typeof i.line=="number"&&i.line>0&&typeof i.column=="number"&&i.column>0)return{line:i.line,column:i.column,offset:typeof i.offset=="number"&&i.offset>-1?i.offset:void 0}}}function ES(e){const n=am(e),r=wS(e);if(n&&r)return{start:n,end:r}}function Eo(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?_b(e.position):"start"in e||"end"in e?_b(e):"line"in e||"column"in e?ap(e):""}function ap(e){return Nb(e&&e.line)+":"+Nb(e&&e.column)}function _b(e){return ap(e&&e.start)+"-"+ap(e&&e.end)}function Nb(e){return e&&typeof e=="number"?e:1}class $t extends Error{constructor(n,r,i){super(),typeof r=="string"&&(i=r,r=void 0);let o="",s={},c=!1;if(r&&("line"in r&&"column"in r?s={place:r}:"start"in r&&"end"in r?s={place:r}:"type"in r?s={ancestors:[r],place:r.position}:s={...r}),typeof n=="string"?o=n:!s.cause&&n&&(c=!0,o=n.message,s.cause=n),!s.ruleId&&!s.source&&typeof i=="string"){const h=i.indexOf(":");h===-1?s.ruleId=i:(s.source=i.slice(0,h),s.ruleId=i.slice(h+1))}if(!s.place&&s.ancestors&&s.ancestors){const h=s.ancestors[s.ancestors.length-1];h&&(s.place=h.position)}const f=s.place&&"start"in s.place?s.place.start:s.place;this.ancestors=s.ancestors||void 0,this.cause=s.cause||void 0,this.column=f?f.column:void 0,this.fatal=void 0,this.file="",this.message=o,this.line=f?f.line:void 0,this.name=Eo(s.place)||"1:1",this.place=s.place||void 0,this.reason=this.message,this.ruleId=s.ruleId||void 0,this.source=s.source||void 0,this.stack=c&&s.cause&&typeof s.cause.stack=="string"?s.cause.stack:"",this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}}$t.prototype.file="";$t.prototype.name="";$t.prototype.reason="";$t.prototype.message="";$t.prototype.stack="";$t.prototype.column=void 0;$t.prototype.line=void 0;$t.prototype.ancestors=void 0;$t.prototype.cause=void 0;$t.prototype.fatal=void 0;$t.prototype.place=void 0;$t.prototype.ruleId=void 0;$t.prototype.source=void 0;const im={}.hasOwnProperty,rL=new Map,aL=/[A-Z]/g,iL=new Set(["table","tbody","thead","tfoot","tr"]),lL=new Set(["td","th"]),kS="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function oL(e,n){if(!n||n.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const r=n.filePath||void 0;let i;if(n.development){if(typeof n.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");i=mL(r,n.jsxDEV)}else{if(typeof n.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof n.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");i=pL(r,n.jsx,n.jsxs)}const o={Fragment:n.Fragment,ancestors:[],components:n.components||{},create:i,elementAttributeNameCase:n.elementAttributeNameCase||"react",evaluater:n.createEvaluater?n.createEvaluater():void 0,filePath:r,ignoreInvalidStyle:n.ignoreInvalidStyle||!1,passKeys:n.passKeys!==!1,passNode:n.passNode||!1,schema:n.space==="svg"?rm:X4,stylePropertyNameCase:n.stylePropertyNameCase||"dom",tableCellAlignToStyle:n.tableCellAlignToStyle!==!1},s=CS(o,e,void 0);return s&&typeof s!="string"?s:o.create(e,o.Fragment,{children:s||void 0},void 0)}function CS(e,n,r){if(n.type==="element")return sL(e,n,r);if(n.type==="mdxFlowExpression"||n.type==="mdxTextExpression")return uL(e,n);if(n.type==="mdxJsxFlowElement"||n.type==="mdxJsxTextElement")return fL(e,n,r);if(n.type==="mdxjsEsm")return cL(e,n);if(n.type==="root")return dL(e,n,r);if(n.type==="text")return hL(e,n)}function sL(e,n,r){const i=e.schema;let o=i;n.tagName.toLowerCase()==="svg"&&i.space==="html"&&(o=rm,e.schema=o),e.ancestors.push(n);const s=TS(e,n.tagName,!1),c=gL(e,n);let f=om(e,n);return iL.has(n.tagName)&&(f=f.filter(function(h){return typeof h=="string"?!B4(h):!0})),AS(e,c,s,n),lm(c,f),e.ancestors.pop(),e.schema=i,e.create(n,s,c,r)}function uL(e,n){if(n.data&&n.data.estree&&e.evaluater){const i=n.data.estree.body[0];return i.type,e.evaluater.evaluateExpression(i.expression)}Do(e,n.position)}function cL(e,n){if(n.data&&n.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(n.data.estree);Do(e,n.position)}function fL(e,n,r){const i=e.schema;let o=i;n.name==="svg"&&i.space==="html"&&(o=rm,e.schema=o),e.ancestors.push(n);const s=n.name===null?e.Fragment:TS(e,n.name,!0),c=yL(e,n),f=om(e,n);return AS(e,c,s,n),lm(c,f),e.ancestors.pop(),e.schema=i,e.create(n,s,c,r)}function dL(e,n,r){const i={};return lm(i,om(e,n)),e.create(n,e.Fragment,i,r)}function hL(e,n){return n.value}function AS(e,n,r,i){typeof r!="string"&&r!==e.Fragment&&e.passNode&&(n.node=i)}function lm(e,n){if(n.length>0){const r=n.length>1?n:n[0];r&&(e.children=r)}}function pL(e,n,r){return i;function i(o,s,c,f){const d=Array.isArray(c.children)?r:n;return f?d(s,c,f):d(s,c)}}function mL(e,n){return r;function r(i,o,s,c){const f=Array.isArray(s.children),h=am(i);return n(o,s,c,f,{columnNumber:h?h.column-1:void 0,fileName:e,lineNumber:h?h.line:void 0},void 0)}}function gL(e,n){const r={};let i,o;for(o in n.properties)if(o!=="children"&&im.call(n.properties,o)){const s=vL(e,o,n.properties[o]);if(s){const[c,f]=s;e.tableCellAlignToStyle&&c==="align"&&typeof f=="string"&&lL.has(n.tagName)?i=f:r[c]=f}}if(i){const s=r.style||(r.style={});s[e.stylePropertyNameCase==="css"?"text-align":"textAlign"]=i}return r}function yL(e,n){const r={};for(const i of n.attributes)if(i.type==="mdxJsxExpressionAttribute")if(i.data&&i.data.estree&&e.evaluater){const s=i.data.estree.body[0];s.type;const c=s.expression;c.type;const f=c.properties[0];f.type,Object.assign(r,e.evaluater.evaluateExpression(f.argument))}else Do(e,n.position);else{const o=i.name;let s;if(i.value&&typeof i.value=="object")if(i.value.data&&i.value.data.estree&&e.evaluater){const f=i.value.data.estree.body[0];f.type,s=e.evaluater.evaluateExpression(f.expression)}else Do(e,n.position);else s=i.value===null?!0:i.value;r[o]=s}return r}function om(e,n){const r=[];let i=-1;const o=e.passKeys?new Map:rL;for(;++i<n.children.length;){const s=n.children[i];let c;if(e.passKeys){const h=s.type==="element"?s.tagName:s.type==="mdxJsxFlowElement"||s.type==="mdxJsxTextElement"?s.name:void 0;if(h){const d=o.get(h)||0;c=h+"-"+d,o.set(h,d+1)}}const f=CS(e,s,c);f!==void 0&&r.push(f)}return r}function vL(e,n,r){const i=G4(e.schema,n);if(!(r==null||typeof r=="number"&&Number.isNaN(r))){if(Array.isArray(r)&&(r=i.commaSeparated?O4(r):Q4(r)),i.property==="style"){let o=typeof r=="object"?r:xL(e,String(r));return e.stylePropertyNameCase==="css"&&(o=bL(o)),["style",o]}return[e.elementAttributeNameCase==="react"&&i.space?q4[i.property]||i.property:i.attribute,r]}}function xL(e,n){try{return nL(n,{reactCompat:!0})}catch(r){if(e.ignoreInvalidStyle)return{};const i=r,o=new $t("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:i,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw o.file=e.filePath||void 0,o.url=kS+"#cannot-parse-style-attribute",o}}function TS(e,n,r){let i;if(!r)i={type:"Literal",value:n};else if(n.includes(".")){const o=n.split(".");let s=-1,c;for(;++s<o.length;){const f=wb(o[s])?{type:"Identifier",name:o[s]}:{type:"Literal",value:o[s]};c=c?{type:"MemberExpression",object:c,property:f,computed:!!(s&&f.type==="Literal"),optional:!1}:f}i=c}else i=wb(n)&&!/^[a-z]/.test(n)?{type:"Identifier",name:n}:{type:"Literal",value:n};if(i.type==="Literal"){const o=i.value;return im.call(e.components,o)?e.components[o]:o}if(e.evaluater)return e.evaluater.evaluateExpression(i);Do(e)}function Do(e,n){const r=new $t("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:n,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw r.file=e.filePath||void 0,r.url=kS+"#cannot-handle-mdx-estrees-without-createevaluater",r}function bL(e){const n={};let r;for(r in e)im.call(e,r)&&(n[wL(r)]=e[r]);return n}function wL(e){let n=e.replace(aL,SL);return n.slice(0,3)==="ms-"&&(n="-"+n),n}function SL(e){return"-"+e.toLowerCase()}const xh={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"]},EL={};function sm(e,n){const r=EL,i=typeof r.includeImageAlt=="boolean"?r.includeImageAlt:!0,o=typeof r.includeHtml=="boolean"?r.includeHtml:!0;return RS(e,i,o)}function RS(e,n,r){if(kL(e)){if("value"in e)return e.type==="html"&&!r?"":e.value;if(n&&"alt"in e&&e.alt)return e.alt;if("children"in e)return Mb(e.children,n,r)}return Array.isArray(e)?Mb(e,n,r):""}function Mb(e,n,r){const i=[];let o=-1;for(;++o<e.length;)i[o]=RS(e[o],n,r);return i.join("")}function kL(e){return!!(e&&typeof e=="object")}const jb=document.createElement("i");function um(e){const n="&"+e+";";jb.innerHTML=n;const r=jb.textContent;return r.charCodeAt(r.length-1)===59&&e!=="semi"||r===n?!1:r}function bn(e,n,r,i){const o=e.length;let s=0,c;if(n<0?n=-n>o?0:o+n:n=n>o?o:n,r=r>0?r:0,i.length<1e4)c=Array.from(i),c.unshift(n,r),e.splice(...c);else for(r&&e.splice(n,r);s<i.length;)c=i.slice(s,s+1e4),c.unshift(n,0),e.splice(...c),s+=1e4,n+=1e4}function jn(e,n){return e.length>0?(bn(e,e.length,0,n),e):n}const Db={}.hasOwnProperty;function _S(e){const n={};let r=-1;for(;++r<e.length;)CL(n,e[r]);return n}function CL(e,n){let r;for(r in n){const o=(Db.call(e,r)?e[r]:void 0)||(e[r]={}),s=n[r];let c;if(s)for(c in s){Db.call(o,c)||(o[c]=[]);const f=s[c];AL(o[c],Array.isArray(f)?f:f?[f]:[])}}}function AL(e,n){let r=-1;const i=[];for(;++r<n.length;)(n[r].add==="after"?e:i).push(n[r]);bn(e,0,0,i)}function NS(e,n){const r=Number.parseInt(e,n);return r<9||r===11||r>13&&r<32||r>126&&r<160||r>55295&&r<57344||r>64975&&r<65008||(r&65535)===65535||(r&65535)===65534||r>1114111?"�":String.fromCodePoint(r)}function Gn(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const Qt=xa(/[A-Za-z]/),Vt=xa(/[\dA-Za-z]/),TL=xa(/[#-'*+\--9=?A-Z^-~]/);function Zu(e){return e!==null&&(e<32||e===127)}const ip=xa(/\d/),RL=xa(/[\dA-Fa-f]/),_L=xa(/[!-/:-@[-`{-~]/);function Ae(e){return e!==null&&e<-2}function at(e){return e!==null&&(e<0||e===32)}function He(e){return e===-2||e===-1||e===32}const Tc=xa(new RegExp("\\p{P}|\\p{S}","u")),Ka=xa(/\s/);function xa(e){return n;function n(r){return r!==null&&r>-1&&e.test(String.fromCharCode(r))}}function hl(e){const n=[];let r=-1,i=0,o=0;for(;++r<e.length;){const s=e.charCodeAt(r);let c="";if(s===37&&Vt(e.charCodeAt(r+1))&&Vt(e.charCodeAt(r+2)))o=2;else if(s<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(s))||(c=String.fromCharCode(s));else if(s>55295&&s<57344){const f=e.charCodeAt(r+1);s<56320&&f>56319&&f<57344?(c=String.fromCharCode(s,f),o=1):c="�"}else c=String.fromCharCode(s);c&&(n.push(e.slice(i,r),encodeURIComponent(c)),i=r+o+1,c=""),o&&(r+=o,o=0)}return n.join("")+e.slice(i)}function Ve(e,n,r,i){const o=i?i-1:Number.POSITIVE_INFINITY;let s=0;return c;function c(h){return He(h)?(e.enter(r),f(h)):n(h)}function f(h){return He(h)&&s++<o?(e.consume(h),f):(e.exit(r),n(h))}}const NL={tokenize:ML};function ML(e){const n=e.attempt(this.parser.constructs.contentInitial,i,o);let r;return n;function i(f){if(f===null){e.consume(f);return}return e.enter("lineEnding"),e.consume(f),e.exit("lineEnding"),Ve(e,n,"linePrefix")}function o(f){return e.enter("paragraph"),s(f)}function s(f){const h=e.enter("chunkText",{contentType:"text",previous:r});return r&&(r.next=h),r=h,c(f)}function c(f){if(f===null){e.exit("chunkText"),e.exit("paragraph"),e.consume(f);return}return Ae(f)?(e.consume(f),e.exit("chunkText"),s):(e.consume(f),c)}}const jL={tokenize:DL},Ob={tokenize:OL};function DL(e){const n=this,r=[];let i=0,o,s,c;return f;function f(N){if(i<r.length){const O=r[i];return n.containerState=O[1],e.attempt(O[0].continuation,h,d)(N)}return d(N)}function h(N){if(i++,n.containerState._closeFlow){n.containerState._closeFlow=void 0,o&&_();const O=n.events.length;let z=O,j;for(;z--;)if(n.events[z][0]==="exit"&&n.events[z][1].type==="chunkFlow"){j=n.events[z][1].end;break}A(i);let $=O;for(;$<n.events.length;)n.events[$][1].end={...j},$++;return bn(n.events,z+1,0,n.events.slice(O)),n.events.length=$,d(N)}return f(N)}function d(N){if(i===r.length){if(!o)return b(N);if(o.currentConstruct&&o.currentConstruct.concrete)return k(N);n.interrupt=!!(o.currentConstruct&&!o._gfmTableDynamicInterruptHack)}return n.containerState={},e.check(Ob,m,y)(N)}function m(N){return o&&_(),A(i),b(N)}function y(N){return n.parser.lazy[n.now().line]=i!==r.length,c=n.now().offset,k(N)}function b(N){return n.containerState={},e.attempt(Ob,w,k)(N)}function w(N){return i++,r.push([n.currentConstruct,n.containerState]),b(N)}function k(N){if(N===null){o&&_(),A(0),e.consume(N);return}return o=o||n.parser.flow(n.now()),e.enter("chunkFlow",{_tokenizer:o,contentType:"flow",previous:s}),C(N)}function C(N){if(N===null){T(e.exit("chunkFlow"),!0),A(0),e.consume(N);return}return Ae(N)?(e.consume(N),T(e.exit("chunkFlow")),i=0,n.interrupt=void 0,f):(e.consume(N),C)}function T(N,O){const z=n.sliceStream(N);if(O&&z.push(null),N.previous=s,s&&(s.next=N),s=N,o.defineSkip(N.start),o.write(z),n.parser.lazy[N.start.line]){let j=o.events.length;for(;j--;)if(o.events[j][1].start.offset<c&&(!o.events[j][1].end||o.events[j][1].end.offset>c))return;const $=n.events.length;let G=$,ee,P;for(;G--;)if(n.events[G][0]==="exit"&&n.events[G][1].type==="chunkFlow"){if(ee){P=n.events[G][1].end;break}ee=!0}for(A(i),j=$;j<n.events.length;)n.events[j][1].end={...P},j++;bn(n.events,G+1,0,n.events.slice($)),n.events.length=j}}function A(N){let O=r.length;for(;O-- >N;){const z=r[O];n.containerState=z[1],z[0].exit.call(n,e)}r.length=N}function _(){o.write([null]),s=void 0,o=void 0,n.containerState._closeFlow=void 0}}function OL(e,n,r){return Ve(e,e.attempt(this.parser.constructs.document,n,r),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function tl(e){if(e===null||at(e)||Ka(e))return 1;if(Tc(e))return 2}function Rc(e,n,r){const i=[];let o=-1;for(;++o<e.length;){const s=e[o].resolveAll;s&&!i.includes(s)&&(n=s(n,r),i.push(s))}return n}const lp={name:"attention",resolveAll:LL,tokenize:zL};function LL(e,n){let r=-1,i,o,s,c,f,h,d,m;for(;++r<e.length;)if(e[r][0]==="enter"&&e[r][1].type==="attentionSequence"&&e[r][1]._close){for(i=r;i--;)if(e[i][0]==="exit"&&e[i][1].type==="attentionSequence"&&e[i][1]._open&&n.sliceSerialize(e[i][1]).charCodeAt(0)===n.sliceSerialize(e[r][1]).charCodeAt(0)){if((e[i][1]._close||e[r][1]._open)&&(e[r][1].end.offset-e[r][1].start.offset)%3&&!((e[i][1].end.offset-e[i][1].start.offset+e[r][1].end.offset-e[r][1].start.offset)%3))continue;h=e[i][1].end.offset-e[i][1].start.offset>1&&e[r][1].end.offset-e[r][1].start.offset>1?2:1;const y={...e[i][1].end},b={...e[r][1].start};Lb(y,-h),Lb(b,h),c={type:h>1?"strongSequence":"emphasisSequence",start:y,end:{...e[i][1].end}},f={type:h>1?"strongSequence":"emphasisSequence",start:{...e[r][1].start},end:b},s={type:h>1?"strongText":"emphasisText",start:{...e[i][1].end},end:{...e[r][1].start}},o={type:h>1?"strong":"emphasis",start:{...c.start},end:{...f.end}},e[i][1].end={...c.start},e[r][1].start={...f.end},d=[],e[i][1].end.offset-e[i][1].start.offset&&(d=jn(d,[["enter",e[i][1],n],["exit",e[i][1],n]])),d=jn(d,[["enter",o,n],["enter",c,n],["exit",c,n],["enter",s,n]]),d=jn(d,Rc(n.parser.constructs.insideSpan.null,e.slice(i+1,r),n)),d=jn(d,[["exit",s,n],["enter",f,n],["exit",f,n],["exit",o,n]]),e[r][1].end.offset-e[r][1].start.offset?(m=2,d=jn(d,[["enter",e[r][1],n],["exit",e[r][1],n]])):m=0,bn(e,i-1,r-i+3,d),r=i+d.length-m-2;break}}for(r=-1;++r<e.length;)e[r][1].type==="attentionSequence"&&(e[r][1].type="data");return e}function zL(e,n){const r=this.parser.constructs.attentionMarkers.null,i=this.previous,o=tl(i);let s;return c;function c(h){return s=h,e.enter("attentionSequence"),f(h)}function f(h){if(h===s)return e.consume(h),f;const d=e.exit("attentionSequence"),m=tl(h),y=!m||m===2&&o||r.includes(h),b=!o||o===2&&m||r.includes(i);return d._open=!!(s===42?y:y&&(o||!b)),d._close=!!(s===42?b:b&&(m||!y)),n(h)}}function Lb(e,n){e.column+=n,e.offset+=n,e._bufferIndex+=n}const PL={name:"autolink",tokenize:IL};function IL(e,n,r){let i=0;return o;function o(w){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(w),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),s}function s(w){return Qt(w)?(e.consume(w),c):w===64?r(w):d(w)}function c(w){return w===43||w===45||w===46||Vt(w)?(i=1,f(w)):d(w)}function f(w){return w===58?(e.consume(w),i=0,h):(w===43||w===45||w===46||Vt(w))&&i++<32?(e.consume(w),f):(i=0,d(w))}function h(w){return w===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(w),e.exit("autolinkMarker"),e.exit("autolink"),n):w===null||w===32||w===60||Zu(w)?r(w):(e.consume(w),h)}function d(w){return w===64?(e.consume(w),m):TL(w)?(e.consume(w),d):r(w)}function m(w){return Vt(w)?y(w):r(w)}function y(w){return w===46?(e.consume(w),i=0,m):w===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(w),e.exit("autolinkMarker"),e.exit("autolink"),n):b(w)}function b(w){if((w===45||Vt(w))&&i++<63){const k=w===45?b:y;return e.consume(w),k}return r(w)}}const Jo={partial:!0,tokenize:BL};function BL(e,n,r){return i;function i(s){return He(s)?Ve(e,o,"linePrefix")(s):o(s)}function o(s){return s===null||Ae(s)?n(s):r(s)}}const MS={continuation:{tokenize:HL},exit:FL,name:"blockQuote",tokenize:UL};function UL(e,n,r){const i=this;return o;function o(c){if(c===62){const f=i.containerState;return f.open||(e.enter("blockQuote",{_container:!0}),f.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(c),e.exit("blockQuoteMarker"),s}return r(c)}function s(c){return He(c)?(e.enter("blockQuotePrefixWhitespace"),e.consume(c),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),n):(e.exit("blockQuotePrefix"),n(c))}}function HL(e,n,r){const i=this;return o;function o(c){return He(c)?Ve(e,s,"linePrefix",i.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(c):s(c)}function s(c){return e.attempt(MS,n,r)(c)}}function FL(e){e.exit("blockQuote")}const jS={name:"characterEscape",tokenize:qL};function qL(e,n,r){return i;function i(s){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(s),e.exit("escapeMarker"),o}function o(s){return _L(s)?(e.enter("characterEscapeValue"),e.consume(s),e.exit("characterEscapeValue"),e.exit("characterEscape"),n):r(s)}}const DS={name:"characterReference",tokenize:VL};function VL(e,n,r){const i=this;let o=0,s,c;return f;function f(y){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(y),e.exit("characterReferenceMarker"),h}function h(y){return y===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(y),e.exit("characterReferenceMarkerNumeric"),d):(e.enter("characterReferenceValue"),s=31,c=Vt,m(y))}function d(y){return y===88||y===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(y),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),s=6,c=RL,m):(e.enter("characterReferenceValue"),s=7,c=ip,m(y))}function m(y){if(y===59&&o){const b=e.exit("characterReferenceValue");return c===Vt&&!um(i.sliceSerialize(b))?r(y):(e.enter("characterReferenceMarker"),e.consume(y),e.exit("characterReferenceMarker"),e.exit("characterReference"),n)}return c(y)&&o++<s?(e.consume(y),m):r(y)}}const zb={partial:!0,tokenize:GL},Pb={concrete:!0,name:"codeFenced",tokenize:$L};function $L(e,n,r){const i=this,o={partial:!0,tokenize:z};let s=0,c=0,f;return h;function h(j){return d(j)}function d(j){const $=i.events[i.events.length-1];return s=$&&$[1].type==="linePrefix"?$[2].sliceSerialize($[1],!0).length:0,f=j,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),m(j)}function m(j){return j===f?(c++,e.consume(j),m):c<3?r(j):(e.exit("codeFencedFenceSequence"),He(j)?Ve(e,y,"whitespace")(j):y(j))}function y(j){return j===null||Ae(j)?(e.exit("codeFencedFence"),i.interrupt?n(j):e.check(zb,C,O)(j)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),b(j))}function b(j){return j===null||Ae(j)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),y(j)):He(j)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),Ve(e,w,"whitespace")(j)):j===96&&j===f?r(j):(e.consume(j),b)}function w(j){return j===null||Ae(j)?y(j):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),k(j))}function k(j){return j===null||Ae(j)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),y(j)):j===96&&j===f?r(j):(e.consume(j),k)}function C(j){return e.attempt(o,O,T)(j)}function T(j){return e.enter("lineEnding"),e.consume(j),e.exit("lineEnding"),A}function A(j){return s>0&&He(j)?Ve(e,_,"linePrefix",s+1)(j):_(j)}function _(j){return j===null||Ae(j)?e.check(zb,C,O)(j):(e.enter("codeFlowValue"),N(j))}function N(j){return j===null||Ae(j)?(e.exit("codeFlowValue"),_(j)):(e.consume(j),N)}function O(j){return e.exit("codeFenced"),n(j)}function z(j,$,G){let ee=0;return P;function P(Q){return j.enter("lineEnding"),j.consume(Q),j.exit("lineEnding"),ne}function ne(Q){return j.enter("codeFencedFence"),He(Q)?Ve(j,ae,"linePrefix",i.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(Q):ae(Q)}function ae(Q){return Q===f?(j.enter("codeFencedFenceSequence"),le(Q)):G(Q)}function le(Q){return Q===f?(ee++,j.consume(Q),le):ee>=c?(j.exit("codeFencedFenceSequence"),He(Q)?Ve(j,H,"whitespace")(Q):H(Q)):G(Q)}function H(Q){return Q===null||Ae(Q)?(j.exit("codeFencedFence"),$(Q)):G(Q)}}}function GL(e,n,r){const i=this;return o;function o(c){return c===null?r(c):(e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),s)}function s(c){return i.parser.lazy[i.now().line]?r(c):n(c)}}const bh={name:"codeIndented",tokenize:KL},YL={partial:!0,tokenize:XL};function KL(e,n,r){const i=this;return o;function o(d){return e.enter("codeIndented"),Ve(e,s,"linePrefix",5)(d)}function s(d){const m=i.events[i.events.length-1];return m&&m[1].type==="linePrefix"&&m[2].sliceSerialize(m[1],!0).length>=4?c(d):r(d)}function c(d){return d===null?h(d):Ae(d)?e.attempt(YL,c,h)(d):(e.enter("codeFlowValue"),f(d))}function f(d){return d===null||Ae(d)?(e.exit("codeFlowValue"),c(d)):(e.consume(d),f)}function h(d){return e.exit("codeIndented"),n(d)}}function XL(e,n,r){const i=this;return o;function o(c){return i.parser.lazy[i.now().line]?r(c):Ae(c)?(e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),o):Ve(e,s,"linePrefix",5)(c)}function s(c){const f=i.events[i.events.length-1];return f&&f[1].type==="linePrefix"&&f[2].sliceSerialize(f[1],!0).length>=4?n(c):Ae(c)?o(c):r(c)}}const QL={name:"codeText",previous:WL,resolve:ZL,tokenize:JL};function ZL(e){let n=e.length-4,r=3,i,o;if((e[r][1].type==="lineEnding"||e[r][1].type==="space")&&(e[n][1].type==="lineEnding"||e[n][1].type==="space")){for(i=r;++i<n;)if(e[i][1].type==="codeTextData"){e[r][1].type="codeTextPadding",e[n][1].type="codeTextPadding",r+=2,n-=2;break}}for(i=r-1,n++;++i<=n;)o===void 0?i!==n&&e[i][1].type!=="lineEnding"&&(o=i):(i===n||e[i][1].type==="lineEnding")&&(e[o][1].type="codeTextData",i!==o+2&&(e[o][1].end=e[i-1][1].end,e.splice(o+2,i-o-2),n-=i-o-2,i=o+2),o=void 0);return e}function WL(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function JL(e,n,r){let i=0,o,s;return c;function c(y){return e.enter("codeText"),e.enter("codeTextSequence"),f(y)}function f(y){return y===96?(e.consume(y),i++,f):(e.exit("codeTextSequence"),h(y))}function h(y){return y===null?r(y):y===32?(e.enter("space"),e.consume(y),e.exit("space"),h):y===96?(s=e.enter("codeTextSequence"),o=0,m(y)):Ae(y)?(e.enter("lineEnding"),e.consume(y),e.exit("lineEnding"),h):(e.enter("codeTextData"),d(y))}function d(y){return y===null||y===32||y===96||Ae(y)?(e.exit("codeTextData"),h(y)):(e.consume(y),d)}function m(y){return y===96?(e.consume(y),o++,m):o===i?(e.exit("codeTextSequence"),e.exit("codeText"),n(y)):(s.type="codeTextData",d(y))}}class ez{constructor(n){this.left=n?[...n]:[],this.right=[]}get(n){if(n<0||n>=this.left.length+this.right.length)throw new RangeError("Cannot access index `"+n+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return n<this.left.length?this.left[n]:this.right[this.right.length-n+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(n,r){const i=r??Number.POSITIVE_INFINITY;return i<this.left.length?this.left.slice(n,i):n>this.left.length?this.right.slice(this.right.length-i+this.left.length,this.right.length-n+this.left.length).reverse():this.left.slice(n).concat(this.right.slice(this.right.length-i+this.left.length).reverse())}splice(n,r,i){const o=r||0;this.setCursor(Math.trunc(n));const s=this.right.splice(this.right.length-o,Number.POSITIVE_INFINITY);return i&&mo(this.left,i),s.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(n){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(n)}pushMany(n){this.setCursor(Number.POSITIVE_INFINITY),mo(this.left,n)}unshift(n){this.setCursor(0),this.right.push(n)}unshiftMany(n){this.setCursor(0),mo(this.right,n.reverse())}setCursor(n){if(!(n===this.left.length||n>this.left.length&&this.right.length===0||n<0&&this.left.length===0))if(n<this.left.length){const r=this.left.splice(n,Number.POSITIVE_INFINITY);mo(this.right,r.reverse())}else{const r=this.right.splice(this.left.length+this.right.length-n,Number.POSITIVE_INFINITY);mo(this.left,r.reverse())}}}function mo(e,n){let r=0;if(n.length<1e4)e.push(...n);else for(;r<n.length;)e.push(...n.slice(r,r+1e4)),r+=1e4}function OS(e){const n={};let r=-1,i,o,s,c,f,h,d;const m=new ez(e);for(;++r<m.length;){for(;r in n;)r=n[r];if(i=m.get(r),r&&i[1].type==="chunkFlow"&&m.get(r-1)[1].type==="listItemPrefix"&&(h=i[1]._tokenizer.events,s=0,s<h.length&&h[s][1].type==="lineEndingBlank"&&(s+=2),s<h.length&&h[s][1].type==="content"))for(;++s<h.length&&h[s][1].type!=="content";)h[s][1].type==="chunkText"&&(h[s][1]._isInFirstContentOfListItem=!0,s++);if(i[0]==="enter")i[1].contentType&&(Object.assign(n,tz(m,r)),r=n[r],d=!0);else if(i[1]._container){for(s=r,o=void 0;s--;)if(c=m.get(s),c[1].type==="lineEnding"||c[1].type==="lineEndingBlank")c[0]==="enter"&&(o&&(m.get(o)[1].type="lineEndingBlank"),c[1].type="lineEnding",o=s);else if(!(c[1].type==="linePrefix"||c[1].type==="listItemIndent"))break;o&&(i[1].end={...m.get(o)[1].start},f=m.slice(o,r),f.unshift(i),m.splice(o,r-o+1,f))}}return bn(e,0,Number.POSITIVE_INFINITY,m.slice(0)),!d}function tz(e,n){const r=e.get(n)[1],i=e.get(n)[2];let o=n-1;const s=[];let c=r._tokenizer;c||(c=i.parser[r.contentType](r.start),r._contentTypeTextTrailing&&(c._contentTypeTextTrailing=!0));const f=c.events,h=[],d={};let m,y,b=-1,w=r,k=0,C=0;const T=[C];for(;w;){for(;e.get(++o)[1]!==w;);s.push(o),w._tokenizer||(m=i.sliceStream(w),w.next||m.push(null),y&&c.defineSkip(w.start),w._isInFirstContentOfListItem&&(c._gfmTasklistFirstContentOfListItem=!0),c.write(m),w._isInFirstContentOfListItem&&(c._gfmTasklistFirstContentOfListItem=void 0)),y=w,w=w.next}for(w=r;++b<f.length;)f[b][0]==="exit"&&f[b-1][0]==="enter"&&f[b][1].type===f[b-1][1].type&&f[b][1].start.line!==f[b][1].end.line&&(C=b+1,T.push(C),w._tokenizer=void 0,w.previous=void 0,w=w.next);for(c.events=[],w?(w._tokenizer=void 0,w.previous=void 0):T.pop(),b=T.length;b--;){const A=f.slice(T[b],T[b+1]),_=s.pop();h.push([_,_+A.length-1]),e.splice(_,2,A)}for(h.reverse(),b=-1;++b<h.length;)d[k+h[b][0]]=k+h[b][1],k+=h[b][1]-h[b][0]-1;return d}const nz={resolve:az,tokenize:iz},rz={partial:!0,tokenize:lz};function az(e){return OS(e),e}function iz(e,n){let r;return i;function i(f){return e.enter("content"),r=e.enter("chunkContent",{contentType:"content"}),o(f)}function o(f){return f===null?s(f):Ae(f)?e.check(rz,c,s)(f):(e.consume(f),o)}function s(f){return e.exit("chunkContent"),e.exit("content"),n(f)}function c(f){return e.consume(f),e.exit("chunkContent"),r.next=e.enter("chunkContent",{contentType:"content",previous:r}),r=r.next,o}}function lz(e,n,r){const i=this;return o;function o(c){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),Ve(e,s,"linePrefix")}function s(c){if(c===null||Ae(c))return r(c);const f=i.events[i.events.length-1];return!i.parser.constructs.disable.null.includes("codeIndented")&&f&&f[1].type==="linePrefix"&&f[2].sliceSerialize(f[1],!0).length>=4?n(c):e.interrupt(i.parser.constructs.flow,r,n)(c)}}function LS(e,n,r,i,o,s,c,f,h){const d=h||Number.POSITIVE_INFINITY;let m=0;return y;function y(A){return A===60?(e.enter(i),e.enter(o),e.enter(s),e.consume(A),e.exit(s),b):A===null||A===32||A===41||Zu(A)?r(A):(e.enter(i),e.enter(c),e.enter(f),e.enter("chunkString",{contentType:"string"}),C(A))}function b(A){return A===62?(e.enter(s),e.consume(A),e.exit(s),e.exit(o),e.exit(i),n):(e.enter(f),e.enter("chunkString",{contentType:"string"}),w(A))}function w(A){return A===62?(e.exit("chunkString"),e.exit(f),b(A)):A===null||A===60||Ae(A)?r(A):(e.consume(A),A===92?k:w)}function k(A){return A===60||A===62||A===92?(e.consume(A),w):w(A)}function C(A){return!m&&(A===null||A===41||at(A))?(e.exit("chunkString"),e.exit(f),e.exit(c),e.exit(i),n(A)):m<d&&A===40?(e.consume(A),m++,C):A===41?(e.consume(A),m--,C):A===null||A===32||A===40||Zu(A)?r(A):(e.consume(A),A===92?T:C)}function T(A){return A===40||A===41||A===92?(e.consume(A),C):C(A)}}function zS(e,n,r,i,o,s){const c=this;let f=0,h;return d;function d(w){return e.enter(i),e.enter(o),e.consume(w),e.exit(o),e.enter(s),m}function m(w){return f>999||w===null||w===91||w===93&&!h||w===94&&!f&&"_hiddenFootnoteSupport"in c.parser.constructs?r(w):w===93?(e.exit(s),e.enter(o),e.consume(w),e.exit(o),e.exit(i),n):Ae(w)?(e.enter("lineEnding"),e.consume(w),e.exit("lineEnding"),m):(e.enter("chunkString",{contentType:"string"}),y(w))}function y(w){return w===null||w===91||w===93||Ae(w)||f++>999?(e.exit("chunkString"),m(w)):(e.consume(w),h||(h=!He(w)),w===92?b:y)}function b(w){return w===91||w===92||w===93?(e.consume(w),f++,y):y(w)}}function PS(e,n,r,i,o,s){let c;return f;function f(b){return b===34||b===39||b===40?(e.enter(i),e.enter(o),e.consume(b),e.exit(o),c=b===40?41:b,h):r(b)}function h(b){return b===c?(e.enter(o),e.consume(b),e.exit(o),e.exit(i),n):(e.enter(s),d(b))}function d(b){return b===c?(e.exit(s),h(c)):b===null?r(b):Ae(b)?(e.enter("lineEnding"),e.consume(b),e.exit("lineEnding"),Ve(e,d,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),m(b))}function m(b){return b===c||b===null||Ae(b)?(e.exit("chunkString"),d(b)):(e.consume(b),b===92?y:m)}function y(b){return b===c||b===92?(e.consume(b),m):m(b)}}function ko(e,n){let r;return i;function i(o){return Ae(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),r=!0,i):He(o)?Ve(e,i,r?"linePrefix":"lineSuffix")(o):n(o)}}const oz={name:"definition",tokenize:uz},sz={partial:!0,tokenize:cz};function uz(e,n,r){const i=this;let o;return s;function s(w){return e.enter("definition"),c(w)}function c(w){return zS.call(i,e,f,r,"definitionLabel","definitionLabelMarker","definitionLabelString")(w)}function f(w){return o=Gn(i.sliceSerialize(i.events[i.events.length-1][1]).slice(1,-1)),w===58?(e.enter("definitionMarker"),e.consume(w),e.exit("definitionMarker"),h):r(w)}function h(w){return at(w)?ko(e,d)(w):d(w)}function d(w){return LS(e,m,r,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(w)}function m(w){return e.attempt(sz,y,y)(w)}function y(w){return He(w)?Ve(e,b,"whitespace")(w):b(w)}function b(w){return w===null||Ae(w)?(e.exit("definition"),i.parser.defined.push(o),n(w)):r(w)}}function cz(e,n,r){return i;function i(f){return at(f)?ko(e,o)(f):r(f)}function o(f){return PS(e,s,r,"definitionTitle","definitionTitleMarker","definitionTitleString")(f)}function s(f){return He(f)?Ve(e,c,"whitespace")(f):c(f)}function c(f){return f===null||Ae(f)?n(f):r(f)}}const fz={name:"hardBreakEscape",tokenize:dz};function dz(e,n,r){return i;function i(s){return e.enter("hardBreakEscape"),e.consume(s),o}function o(s){return Ae(s)?(e.exit("hardBreakEscape"),n(s)):r(s)}}const hz={name:"headingAtx",resolve:pz,tokenize:mz};function pz(e,n){let r=e.length-2,i=3,o,s;return e[i][1].type==="whitespace"&&(i+=2),r-2>i&&e[r][1].type==="whitespace"&&(r-=2),e[r][1].type==="atxHeadingSequence"&&(i===r-1||r-4>i&&e[r-2][1].type==="whitespace")&&(r-=i+1===r?2:4),r>i&&(o={type:"atxHeadingText",start:e[i][1].start,end:e[r][1].end},s={type:"chunkText",start:e[i][1].start,end:e[r][1].end,contentType:"text"},bn(e,i,r-i+1,[["enter",o,n],["enter",s,n],["exit",s,n],["exit",o,n]])),e}function mz(e,n,r){let i=0;return o;function o(m){return e.enter("atxHeading"),s(m)}function s(m){return e.enter("atxHeadingSequence"),c(m)}function c(m){return m===35&&i++<6?(e.consume(m),c):m===null||at(m)?(e.exit("atxHeadingSequence"),f(m)):r(m)}function f(m){return m===35?(e.enter("atxHeadingSequence"),h(m)):m===null||Ae(m)?(e.exit("atxHeading"),n(m)):He(m)?Ve(e,f,"whitespace")(m):(e.enter("atxHeadingText"),d(m))}function h(m){return m===35?(e.consume(m),h):(e.exit("atxHeadingSequence"),f(m))}function d(m){return m===null||m===35||at(m)?(e.exit("atxHeadingText"),f(m)):(e.consume(m),d)}}const gz=["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"],Ib=["pre","script","style","textarea"],yz={concrete:!0,name:"htmlFlow",resolveTo:bz,tokenize:wz},vz={partial:!0,tokenize:Ez},xz={partial:!0,tokenize:Sz};function bz(e){let n=e.length;for(;n--&&!(e[n][0]==="enter"&&e[n][1].type==="htmlFlow"););return n>1&&e[n-2][1].type==="linePrefix"&&(e[n][1].start=e[n-2][1].start,e[n+1][1].start=e[n-2][1].start,e.splice(n-2,2)),e}function wz(e,n,r){const i=this;let o,s,c,f,h;return d;function d(M){return m(M)}function m(M){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(M),y}function y(M){return M===33?(e.consume(M),b):M===47?(e.consume(M),s=!0,C):M===63?(e.consume(M),o=3,i.interrupt?n:E):Qt(M)?(e.consume(M),c=String.fromCharCode(M),T):r(M)}function b(M){return M===45?(e.consume(M),o=2,w):M===91?(e.consume(M),o=5,f=0,k):Qt(M)?(e.consume(M),o=4,i.interrupt?n:E):r(M)}function w(M){return M===45?(e.consume(M),i.interrupt?n:E):r(M)}function k(M){const se="CDATA[";return M===se.charCodeAt(f++)?(e.consume(M),f===se.length?i.interrupt?n:ae:k):r(M)}function C(M){return Qt(M)?(e.consume(M),c=String.fromCharCode(M),T):r(M)}function T(M){if(M===null||M===47||M===62||at(M)){const se=M===47,Se=c.toLowerCase();return!se&&!s&&Ib.includes(Se)?(o=1,i.interrupt?n(M):ae(M)):gz.includes(c.toLowerCase())?(o=6,se?(e.consume(M),A):i.interrupt?n(M):ae(M)):(o=7,i.interrupt&&!i.parser.lazy[i.now().line]?r(M):s?_(M):N(M))}return M===45||Vt(M)?(e.consume(M),c+=String.fromCharCode(M),T):r(M)}function A(M){return M===62?(e.consume(M),i.interrupt?n:ae):r(M)}function _(M){return He(M)?(e.consume(M),_):P(M)}function N(M){return M===47?(e.consume(M),P):M===58||M===95||Qt(M)?(e.consume(M),O):He(M)?(e.consume(M),N):P(M)}function O(M){return M===45||M===46||M===58||M===95||Vt(M)?(e.consume(M),O):z(M)}function z(M){return M===61?(e.consume(M),j):He(M)?(e.consume(M),z):N(M)}function j(M){return M===null||M===60||M===61||M===62||M===96?r(M):M===34||M===39?(e.consume(M),h=M,$):He(M)?(e.consume(M),j):G(M)}function $(M){return M===h?(e.consume(M),h=null,ee):M===null||Ae(M)?r(M):(e.consume(M),$)}function G(M){return M===null||M===34||M===39||M===47||M===60||M===61||M===62||M===96||at(M)?z(M):(e.consume(M),G)}function ee(M){return M===47||M===62||He(M)?N(M):r(M)}function P(M){return M===62?(e.consume(M),ne):r(M)}function ne(M){return M===null||Ae(M)?ae(M):He(M)?(e.consume(M),ne):r(M)}function ae(M){return M===45&&o===2?(e.consume(M),L):M===60&&o===1?(e.consume(M),K):M===62&&o===4?(e.consume(M),Z):M===63&&o===3?(e.consume(M),E):M===93&&o===5?(e.consume(M),J):Ae(M)&&(o===6||o===7)?(e.exit("htmlFlowData"),e.check(vz,oe,le)(M)):M===null||Ae(M)?(e.exit("htmlFlowData"),le(M)):(e.consume(M),ae)}function le(M){return e.check(xz,H,oe)(M)}function H(M){return e.enter("lineEnding"),e.consume(M),e.exit("lineEnding"),Q}function Q(M){return M===null||Ae(M)?le(M):(e.enter("htmlFlowData"),ae(M))}function L(M){return M===45?(e.consume(M),E):ae(M)}function K(M){return M===47?(e.consume(M),c="",U):ae(M)}function U(M){if(M===62){const se=c.toLowerCase();return Ib.includes(se)?(e.consume(M),Z):ae(M)}return Qt(M)&&c.length<8?(e.consume(M),c+=String.fromCharCode(M),U):ae(M)}function J(M){return M===93?(e.consume(M),E):ae(M)}function E(M){return M===62?(e.consume(M),Z):M===45&&o===2?(e.consume(M),E):ae(M)}function Z(M){return M===null||Ae(M)?(e.exit("htmlFlowData"),oe(M)):(e.consume(M),Z)}function oe(M){return e.exit("htmlFlow"),n(M)}}function Sz(e,n,r){const i=this;return o;function o(c){return Ae(c)?(e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),s):r(c)}function s(c){return i.parser.lazy[i.now().line]?r(c):n(c)}}function Ez(e,n,r){return i;function i(o){return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),e.attempt(Jo,n,r)}}const kz={name:"htmlText",tokenize:Cz};function Cz(e,n,r){const i=this;let o,s,c;return f;function f(E){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(E),h}function h(E){return E===33?(e.consume(E),d):E===47?(e.consume(E),z):E===63?(e.consume(E),N):Qt(E)?(e.consume(E),G):r(E)}function d(E){return E===45?(e.consume(E),m):E===91?(e.consume(E),s=0,k):Qt(E)?(e.consume(E),_):r(E)}function m(E){return E===45?(e.consume(E),w):r(E)}function y(E){return E===null?r(E):E===45?(e.consume(E),b):Ae(E)?(c=y,K(E)):(e.consume(E),y)}function b(E){return E===45?(e.consume(E),w):y(E)}function w(E){return E===62?L(E):E===45?b(E):y(E)}function k(E){const Z="CDATA[";return E===Z.charCodeAt(s++)?(e.consume(E),s===Z.length?C:k):r(E)}function C(E){return E===null?r(E):E===93?(e.consume(E),T):Ae(E)?(c=C,K(E)):(e.consume(E),C)}function T(E){return E===93?(e.consume(E),A):C(E)}function A(E){return E===62?L(E):E===93?(e.consume(E),A):C(E)}function _(E){return E===null||E===62?L(E):Ae(E)?(c=_,K(E)):(e.consume(E),_)}function N(E){return E===null?r(E):E===63?(e.consume(E),O):Ae(E)?(c=N,K(E)):(e.consume(E),N)}function O(E){return E===62?L(E):N(E)}function z(E){return Qt(E)?(e.consume(E),j):r(E)}function j(E){return E===45||Vt(E)?(e.consume(E),j):$(E)}function $(E){return Ae(E)?(c=$,K(E)):He(E)?(e.consume(E),$):L(E)}function G(E){return E===45||Vt(E)?(e.consume(E),G):E===47||E===62||at(E)?ee(E):r(E)}function ee(E){return E===47?(e.consume(E),L):E===58||E===95||Qt(E)?(e.consume(E),P):Ae(E)?(c=ee,K(E)):He(E)?(e.consume(E),ee):L(E)}function P(E){return E===45||E===46||E===58||E===95||Vt(E)?(e.consume(E),P):ne(E)}function ne(E){return E===61?(e.consume(E),ae):Ae(E)?(c=ne,K(E)):He(E)?(e.consume(E),ne):ee(E)}function ae(E){return E===null||E===60||E===61||E===62||E===96?r(E):E===34||E===39?(e.consume(E),o=E,le):Ae(E)?(c=ae,K(E)):He(E)?(e.consume(E),ae):(e.consume(E),H)}function le(E){return E===o?(e.consume(E),o=void 0,Q):E===null?r(E):Ae(E)?(c=le,K(E)):(e.consume(E),le)}function H(E){return E===null||E===34||E===39||E===60||E===61||E===96?r(E):E===47||E===62||at(E)?ee(E):(e.consume(E),H)}function Q(E){return E===47||E===62||at(E)?ee(E):r(E)}function L(E){return E===62?(e.consume(E),e.exit("htmlTextData"),e.exit("htmlText"),n):r(E)}function K(E){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(E),e.exit("lineEnding"),U}function U(E){return He(E)?Ve(e,J,"linePrefix",i.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(E):J(E)}function J(E){return e.enter("htmlTextData"),c(E)}}const cm={name:"labelEnd",resolveAll:_z,resolveTo:Nz,tokenize:Mz},Az={tokenize:jz},Tz={tokenize:Dz},Rz={tokenize:Oz};function _z(e){let n=-1;const r=[];for(;++n<e.length;){const i=e[n][1];if(r.push(e[n]),i.type==="labelImage"||i.type==="labelLink"||i.type==="labelEnd"){const o=i.type==="labelImage"?4:2;i.type="data",n+=o}}return e.length!==r.length&&bn(e,0,e.length,r),e}function Nz(e,n){let r=e.length,i=0,o,s,c,f;for(;r--;)if(o=e[r][1],s){if(o.type==="link"||o.type==="labelLink"&&o._inactive)break;e[r][0]==="enter"&&o.type==="labelLink"&&(o._inactive=!0)}else if(c){if(e[r][0]==="enter"&&(o.type==="labelImage"||o.type==="labelLink")&&!o._balanced&&(s=r,o.type!=="labelLink")){i=2;break}}else o.type==="labelEnd"&&(c=r);const h={type:e[s][1].type==="labelLink"?"link":"image",start:{...e[s][1].start},end:{...e[e.length-1][1].end}},d={type:"label",start:{...e[s][1].start},end:{...e[c][1].end}},m={type:"labelText",start:{...e[s+i+2][1].end},end:{...e[c-2][1].start}};return f=[["enter",h,n],["enter",d,n]],f=jn(f,e.slice(s+1,s+i+3)),f=jn(f,[["enter",m,n]]),f=jn(f,Rc(n.parser.constructs.insideSpan.null,e.slice(s+i+4,c-3),n)),f=jn(f,[["exit",m,n],e[c-2],e[c-1],["exit",d,n]]),f=jn(f,e.slice(c+1)),f=jn(f,[["exit",h,n]]),bn(e,s,e.length,f),e}function Mz(e,n,r){const i=this;let o=i.events.length,s,c;for(;o--;)if((i.events[o][1].type==="labelImage"||i.events[o][1].type==="labelLink")&&!i.events[o][1]._balanced){s=i.events[o][1];break}return f;function f(b){return s?s._inactive?y(b):(c=i.parser.defined.includes(Gn(i.sliceSerialize({start:s.end,end:i.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(b),e.exit("labelMarker"),e.exit("labelEnd"),h):r(b)}function h(b){return b===40?e.attempt(Az,m,c?m:y)(b):b===91?e.attempt(Tz,m,c?d:y)(b):c?m(b):y(b)}function d(b){return e.attempt(Rz,m,y)(b)}function m(b){return n(b)}function y(b){return s._balanced=!0,r(b)}}function jz(e,n,r){return i;function i(y){return e.enter("resource"),e.enter("resourceMarker"),e.consume(y),e.exit("resourceMarker"),o}function o(y){return at(y)?ko(e,s)(y):s(y)}function s(y){return y===41?m(y):LS(e,c,f,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(y)}function c(y){return at(y)?ko(e,h)(y):m(y)}function f(y){return r(y)}function h(y){return y===34||y===39||y===40?PS(e,d,r,"resourceTitle","resourceTitleMarker","resourceTitleString")(y):m(y)}function d(y){return at(y)?ko(e,m)(y):m(y)}function m(y){return y===41?(e.enter("resourceMarker"),e.consume(y),e.exit("resourceMarker"),e.exit("resource"),n):r(y)}}function Dz(e,n,r){const i=this;return o;function o(f){return zS.call(i,e,s,c,"reference","referenceMarker","referenceString")(f)}function s(f){return i.parser.defined.includes(Gn(i.sliceSerialize(i.events[i.events.length-1][1]).slice(1,-1)))?n(f):r(f)}function c(f){return r(f)}}function Oz(e,n,r){return i;function i(s){return e.enter("reference"),e.enter("referenceMarker"),e.consume(s),e.exit("referenceMarker"),o}function o(s){return s===93?(e.enter("referenceMarker"),e.consume(s),e.exit("referenceMarker"),e.exit("reference"),n):r(s)}}const Lz={name:"labelStartImage",resolveAll:cm.resolveAll,tokenize:zz};function zz(e,n,r){const i=this;return o;function o(f){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(f),e.exit("labelImageMarker"),s}function s(f){return f===91?(e.enter("labelMarker"),e.consume(f),e.exit("labelMarker"),e.exit("labelImage"),c):r(f)}function c(f){return f===94&&"_hiddenFootnoteSupport"in i.parser.constructs?r(f):n(f)}}const Pz={name:"labelStartLink",resolveAll:cm.resolveAll,tokenize:Iz};function Iz(e,n,r){const i=this;return o;function o(c){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(c),e.exit("labelMarker"),e.exit("labelLink"),s}function s(c){return c===94&&"_hiddenFootnoteSupport"in i.parser.constructs?r(c):n(c)}}const wh={name:"lineEnding",tokenize:Bz};function Bz(e,n){return r;function r(i){return e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),Ve(e,n,"linePrefix")}}const Hu={name:"thematicBreak",tokenize:Uz};function Uz(e,n,r){let i=0,o;return s;function s(d){return e.enter("thematicBreak"),c(d)}function c(d){return o=d,f(d)}function f(d){return d===o?(e.enter("thematicBreakSequence"),h(d)):i>=3&&(d===null||Ae(d))?(e.exit("thematicBreak"),n(d)):r(d)}function h(d){return d===o?(e.consume(d),i++,h):(e.exit("thematicBreakSequence"),He(d)?Ve(e,f,"whitespace")(d):f(d))}}const ln={continuation:{tokenize:Vz},exit:Gz,name:"list",tokenize:qz},Hz={partial:!0,tokenize:Yz},Fz={partial:!0,tokenize:$z};function qz(e,n,r){const i=this,o=i.events[i.events.length-1];let s=o&&o[1].type==="linePrefix"?o[2].sliceSerialize(o[1],!0).length:0,c=0;return f;function f(w){const k=i.containerState.type||(w===42||w===43||w===45?"listUnordered":"listOrdered");if(k==="listUnordered"?!i.containerState.marker||w===i.containerState.marker:ip(w)){if(i.containerState.type||(i.containerState.type=k,e.enter(k,{_container:!0})),k==="listUnordered")return e.enter("listItemPrefix"),w===42||w===45?e.check(Hu,r,d)(w):d(w);if(!i.interrupt||w===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),h(w)}return r(w)}function h(w){return ip(w)&&++c<10?(e.consume(w),h):(!i.interrupt||c<2)&&(i.containerState.marker?w===i.containerState.marker:w===41||w===46)?(e.exit("listItemValue"),d(w)):r(w)}function d(w){return e.enter("listItemMarker"),e.consume(w),e.exit("listItemMarker"),i.containerState.marker=i.containerState.marker||w,e.check(Jo,i.interrupt?r:m,e.attempt(Hz,b,y))}function m(w){return i.containerState.initialBlankLine=!0,s++,b(w)}function y(w){return He(w)?(e.enter("listItemPrefixWhitespace"),e.consume(w),e.exit("listItemPrefixWhitespace"),b):r(w)}function b(w){return i.containerState.size=s+i.sliceSerialize(e.exit("listItemPrefix"),!0).length,n(w)}}function Vz(e,n,r){const i=this;return i.containerState._closeFlow=void 0,e.check(Jo,o,s);function o(f){return i.containerState.furtherBlankLines=i.containerState.furtherBlankLines||i.containerState.initialBlankLine,Ve(e,n,"listItemIndent",i.containerState.size+1)(f)}function s(f){return i.containerState.furtherBlankLines||!He(f)?(i.containerState.furtherBlankLines=void 0,i.containerState.initialBlankLine=void 0,c(f)):(i.containerState.furtherBlankLines=void 0,i.containerState.initialBlankLine=void 0,e.attempt(Fz,n,c)(f))}function c(f){return i.containerState._closeFlow=!0,i.interrupt=void 0,Ve(e,e.attempt(ln,n,r),"linePrefix",i.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(f)}}function $z(e,n,r){const i=this;return Ve(e,o,"listItemIndent",i.containerState.size+1);function o(s){const c=i.events[i.events.length-1];return c&&c[1].type==="listItemIndent"&&c[2].sliceSerialize(c[1],!0).length===i.containerState.size?n(s):r(s)}}function Gz(e){e.exit(this.containerState.type)}function Yz(e,n,r){const i=this;return Ve(e,o,"listItemPrefixWhitespace",i.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function o(s){const c=i.events[i.events.length-1];return!He(s)&&c&&c[1].type==="listItemPrefixWhitespace"?n(s):r(s)}}const Bb={name:"setextUnderline",resolveTo:Kz,tokenize:Xz};function Kz(e,n){let r=e.length,i,o,s;for(;r--;)if(e[r][0]==="enter"){if(e[r][1].type==="content"){i=r;break}e[r][1].type==="paragraph"&&(o=r)}else e[r][1].type==="content"&&e.splice(r,1),!s&&e[r][1].type==="definition"&&(s=r);const c={type:"setextHeading",start:{...e[i][1].start},end:{...e[e.length-1][1].end}};return e[o][1].type="setextHeadingText",s?(e.splice(o,0,["enter",c,n]),e.splice(s+1,0,["exit",e[i][1],n]),e[i][1].end={...e[s][1].end}):e[i][1]=c,e.push(["exit",c,n]),e}function Xz(e,n,r){const i=this;let o;return s;function s(d){let m=i.events.length,y;for(;m--;)if(i.events[m][1].type!=="lineEnding"&&i.events[m][1].type!=="linePrefix"&&i.events[m][1].type!=="content"){y=i.events[m][1].type==="paragraph";break}return!i.parser.lazy[i.now().line]&&(i.interrupt||y)?(e.enter("setextHeadingLine"),o=d,c(d)):r(d)}function c(d){return e.enter("setextHeadingLineSequence"),f(d)}function f(d){return d===o?(e.consume(d),f):(e.exit("setextHeadingLineSequence"),He(d)?Ve(e,h,"lineSuffix")(d):h(d))}function h(d){return d===null||Ae(d)?(e.exit("setextHeadingLine"),n(d)):r(d)}}const Qz={tokenize:Zz};function Zz(e){const n=this,r=e.attempt(Jo,i,e.attempt(this.parser.constructs.flowInitial,o,Ve(e,e.attempt(this.parser.constructs.flow,o,e.attempt(nz,o)),"linePrefix")));return r;function i(s){if(s===null){e.consume(s);return}return e.enter("lineEndingBlank"),e.consume(s),e.exit("lineEndingBlank"),n.currentConstruct=void 0,r}function o(s){if(s===null){e.consume(s);return}return e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),n.currentConstruct=void 0,r}}const Wz={resolveAll:BS()},Jz=IS("string"),e3=IS("text");function IS(e){return{resolveAll:BS(e==="text"?t3:void 0),tokenize:n};function n(r){const i=this,o=this.parser.constructs[e],s=r.attempt(o,c,f);return c;function c(m){return d(m)?s(m):f(m)}function f(m){if(m===null){r.consume(m);return}return r.enter("data"),r.consume(m),h}function h(m){return d(m)?(r.exit("data"),s(m)):(r.consume(m),h)}function d(m){if(m===null)return!0;const y=o[m];let b=-1;if(y)for(;++b<y.length;){const w=y[b];if(!w.previous||w.previous.call(i,i.previous))return!0}return!1}}}function BS(e){return n;function n(r,i){let o=-1,s;for(;++o<=r.length;)s===void 0?r[o]&&r[o][1].type==="data"&&(s=o,o++):(!r[o]||r[o][1].type!=="data")&&(o!==s+2&&(r[s][1].end=r[o-1][1].end,r.splice(s+2,o-s-2),o=s+2),s=void 0);return e?e(r,i):r}}function t3(e,n){let r=0;for(;++r<=e.length;)if((r===e.length||e[r][1].type==="lineEnding")&&e[r-1][1].type==="data"){const i=e[r-1][1],o=n.sliceStream(i);let s=o.length,c=-1,f=0,h;for(;s--;){const d=o[s];if(typeof d=="string"){for(c=d.length;d.charCodeAt(c-1)===32;)f++,c--;if(c)break;c=-1}else if(d===-2)h=!0,f++;else if(d!==-1){s++;break}}if(n._contentTypeTextTrailing&&r===e.length&&(f=0),f){const d={type:r===e.length||h||f<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:s?c:i.start._bufferIndex+c,_index:i.start._index+s,line:i.end.line,column:i.end.column-f,offset:i.end.offset-f},end:{...i.end}};i.end={...d.start},i.start.offset===i.end.offset?Object.assign(i,d):(e.splice(r,0,["enter",d,n],["exit",d,n]),r+=2)}r++}return e}const n3={42:ln,43:ln,45:ln,48:ln,49:ln,50:ln,51:ln,52:ln,53:ln,54:ln,55:ln,56:ln,57:ln,62:MS},r3={91:oz},a3={[-2]:bh,[-1]:bh,32:bh},i3={35:hz,42:Hu,45:[Bb,Hu],60:yz,61:Bb,95:Hu,96:Pb,126:Pb},l3={38:DS,92:jS},o3={[-5]:wh,[-4]:wh,[-3]:wh,33:Lz,38:DS,42:lp,60:[PL,kz],91:Pz,92:[fz,jS],93:cm,95:lp,96:QL},s3={null:[lp,Wz]},u3={null:[42,95]},c3={null:[]},f3=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:u3,contentInitial:r3,disable:c3,document:n3,flow:i3,flowInitial:a3,insideSpan:s3,string:l3,text:o3},Symbol.toStringTag,{value:"Module"}));function d3(e,n,r){let i={_bufferIndex:-1,_index:0,line:r&&r.line||1,column:r&&r.column||1,offset:r&&r.offset||0};const o={},s=[];let c=[],f=[];const h={attempt:$(z),check:$(j),consume:_,enter:N,exit:O,interrupt:$(j,{interrupt:!0})},d={code:null,containerState:{},defineSkip:C,events:[],now:k,parser:e,previous:null,sliceSerialize:b,sliceStream:w,write:y};let m=n.tokenize.call(d,h);return n.resolveAll&&s.push(n),d;function y(ne){return c=jn(c,ne),T(),c[c.length-1]!==null?[]:(G(n,0),d.events=Rc(s,d.events,d),d.events)}function b(ne,ae){return p3(w(ne),ae)}function w(ne){return h3(c,ne)}function k(){const{_bufferIndex:ne,_index:ae,line:le,column:H,offset:Q}=i;return{_bufferIndex:ne,_index:ae,line:le,column:H,offset:Q}}function C(ne){o[ne.line]=ne.column,P()}function T(){let ne;for(;i._index<c.length;){const ae=c[i._index];if(typeof ae=="string")for(ne=i._index,i._bufferIndex<0&&(i._bufferIndex=0);i._index===ne&&i._bufferIndex<ae.length;)A(ae.charCodeAt(i._bufferIndex));else A(ae)}}function A(ne){m=m(ne)}function _(ne){Ae(ne)?(i.line++,i.column=1,i.offset+=ne===-3?2:1,P()):ne!==-1&&(i.column++,i.offset++),i._bufferIndex<0?i._index++:(i._bufferIndex++,i._bufferIndex===c[i._index].length&&(i._bufferIndex=-1,i._index++)),d.previous=ne}function N(ne,ae){const le=ae||{};return le.type=ne,le.start=k(),d.events.push(["enter",le,d]),f.push(le),le}function O(ne){const ae=f.pop();return ae.end=k(),d.events.push(["exit",ae,d]),ae}function z(ne,ae){G(ne,ae.from)}function j(ne,ae){ae.restore()}function $(ne,ae){return le;function le(H,Q,L){let K,U,J,E;return Array.isArray(H)?oe(H):"tokenize"in H?oe([H]):Z(H);function Z(he){return xe;function xe(Ee){const Qe=Ee!==null&&he[Ee],bt=Ee!==null&&he.null,Rt=[...Array.isArray(Qe)?Qe:Qe?[Qe]:[],...Array.isArray(bt)?bt:bt?[bt]:[]];return oe(Rt)(Ee)}}function oe(he){return K=he,U=0,he.length===0?L:M(he[U])}function M(he){return xe;function xe(Ee){return E=ee(),J=he,he.partial||(d.currentConstruct=he),he.name&&d.parser.constructs.disable.null.includes(he.name)?Se():he.tokenize.call(ae?Object.assign(Object.create(d),ae):d,h,se,Se)(Ee)}}function se(he){return ne(J,E),Q}function Se(he){return E.restore(),++U<K.length?M(K[U]):L}}}function G(ne,ae){ne.resolveAll&&!s.includes(ne)&&s.push(ne),ne.resolve&&bn(d.events,ae,d.events.length-ae,ne.resolve(d.events.slice(ae),d)),ne.resolveTo&&(d.events=ne.resolveTo(d.events,d))}function ee(){const ne=k(),ae=d.previous,le=d.currentConstruct,H=d.events.length,Q=Array.from(f);return{from:H,restore:L};function L(){i=ne,d.previous=ae,d.currentConstruct=le,d.events.length=H,f=Q,P()}}function P(){i.line in o&&i.column<2&&(i.column=o[i.line],i.offset+=o[i.line]-1)}}function h3(e,n){const r=n.start._index,i=n.start._bufferIndex,o=n.end._index,s=n.end._bufferIndex;let c;if(r===o)c=[e[r].slice(i,s)];else{if(c=e.slice(r,o),i>-1){const f=c[0];typeof f=="string"?c[0]=f.slice(i):c.shift()}s>0&&c.push(e[o].slice(0,s))}return c}function p3(e,n){let r=-1;const i=[];let o;for(;++r<e.length;){const s=e[r];let c;if(typeof s=="string")c=s;else switch(s){case-5:{c="\r";break}case-4:{c=`
|
|
387
387
|
`;break}case-3:{c=`\r
|
|
388
388
|
`;break}case-2:{c=n?" ":" ";break}case-1:{if(!n&&o)continue;c=" ";break}default:c=String.fromCharCode(s)}o=s===-2,i.push(c)}return i.join("")}function m3(e){const i={constructs:_S([f3,...(e||{}).extensions||[]]),content:o(NL),defined:[],document:o(jL),flow:o(Qz),lazy:{},string:o(Jz),text:o(e3)};return i;function o(s){return c;function c(f){return d3(i,s,f)}}}function g3(e){for(;!OS(e););return e}const Ub=/[\0\t\n\r]/g;function y3(){let e=1,n="",r=!0,i;return o;function o(s,c,f){const h=[];let d,m,y,b,w;for(s=n+(typeof s=="string"?s.toString():new TextDecoder(c||void 0).decode(s)),y=0,n="",r&&(s.charCodeAt(0)===65279&&y++,r=void 0);y<s.length;){if(Ub.lastIndex=y,d=Ub.exec(s),b=d&&d.index!==void 0?d.index:s.length,w=s.charCodeAt(b),!d){n=s.slice(y);break}if(w===10&&y===b&&i)h.push(-3),i=void 0;else switch(i&&(h.push(-5),i=void 0),y<b&&(h.push(s.slice(y,b)),e+=b-y),w){case 0:{h.push(65533),e++;break}case 9:{for(m=Math.ceil(e/4)*4,h.push(-2);e++<m;)h.push(-1);break}case 10:{h.push(-4),e=1;break}default:i=!0,e=1}y=b+1}return f&&(i&&h.push(-5),n&&h.push(n),h.push(null)),h}}const v3=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function x3(e){return e.replace(v3,b3)}function b3(e,n,r){if(n)return n;if(r.charCodeAt(0)===35){const o=r.charCodeAt(1),s=o===120||o===88;return NS(r.slice(s?2:1),s?16:10)}return um(r)||e}const US={}.hasOwnProperty;function w3(e,n,r){return typeof n!="string"&&(r=n,n=void 0),S3(r)(g3(m3(r).document().write(y3()(e,n,!0))))}function S3(e){const n={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:s(Jt),autolinkProtocol:ee,autolinkEmail:ee,atxHeading:s(Wn),blockQuote:s(bt),characterEscape:ee,characterReference:ee,codeFenced:s(Rt),codeFencedFenceInfo:c,codeFencedFenceMeta:c,codeIndented:s(Rt,c),codeText:s(It,c),codeTextData:ee,data:ee,codeFlowValue:ee,definition:s(Gt),definitionDestinationString:c,definitionLabelString:c,definitionTitleString:c,emphasis:s(ba),hardBreakEscape:s(Jn),hardBreakTrailing:s(Jn),htmlFlow:s(Dt,c),htmlFlowData:ee,htmlText:s(Dt,c),htmlTextData:ee,image:s(Br),label:c,link:s(Jt),listItem:s(mr),listItemValue:b,listOrdered:s(wn,y),listUnordered:s(wn),paragraph:s(Wa),reference:M,referenceString:c,resourceDestinationString:c,resourceTitleString:c,setextHeading:s(Wn),strong:s(wa),thematicBreak:s(Ur)},exit:{atxHeading:h(),atxHeadingSequence:z,autolink:h(),autolinkEmail:Qe,autolinkProtocol:Ee,blockQuote:h(),characterEscapeValue:P,characterReferenceMarkerHexadecimal:Se,characterReferenceMarkerNumeric:Se,characterReferenceValue:he,characterReference:xe,codeFenced:h(T),codeFencedFence:C,codeFencedFenceInfo:w,codeFencedFenceMeta:k,codeFlowValue:P,codeIndented:h(A),codeText:h(Q),codeTextData:P,data:P,definition:h(),definitionDestinationString:O,definitionLabelString:_,definitionTitleString:N,emphasis:h(),hardBreakEscape:h(ae),hardBreakTrailing:h(ae),htmlFlow:h(le),htmlFlowData:P,htmlText:h(H),htmlTextData:P,image:h(K),label:J,labelText:U,lineEnding:ne,link:h(L),listItem:h(),listOrdered:h(),listUnordered:h(),paragraph:h(),referenceString:se,resourceDestinationString:E,resourceTitleString:Z,resource:oe,setextHeading:h(G),setextHeadingLineSequence:$,setextHeadingText:j,strong:h(),thematicBreak:h()}};HS(n,(e||{}).mdastExtensions||[]);const r={};return i;function i(W){let ue={type:"root",children:[]};const ke={stack:[ue],tokenStack:[],config:n,enter:f,exit:d,buffer:c,resume:m,data:r},Re=[];let Ye=-1;for(;++Ye<W.length;)if(W[Ye][1].type==="listOrdered"||W[Ye][1].type==="listUnordered")if(W[Ye][0]==="enter")Re.push(Ye);else{const Yt=Re.pop();Ye=o(W,Yt,Ye)}for(Ye=-1;++Ye<W.length;){const Yt=n[W[Ye][0]];US.call(Yt,W[Ye][1].type)&&Yt[W[Ye][1].type].call(Object.assign({sliceSerialize:W[Ye][2].sliceSerialize},ke),W[Ye][1])}if(ke.tokenStack.length>0){const Yt=ke.tokenStack[ke.tokenStack.length-1];(Yt[1]||Hb).call(ke,void 0,Yt[0])}for(ue.position={start:ca(W.length>0?W[0][1].start:{line:1,column:1,offset:0}),end:ca(W.length>0?W[W.length-2][1].end:{line:1,column:1,offset:0})},Ye=-1;++Ye<n.transforms.length;)ue=n.transforms[Ye](ue)||ue;return ue}function o(W,ue,ke){let Re=ue-1,Ye=-1,Yt=!1,Pn,Bt,un,Ot;for(;++Re<=ke;){const mt=W[Re];switch(mt[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{mt[0]==="enter"?Ye++:Ye--,Ot=void 0;break}case"lineEndingBlank":{mt[0]==="enter"&&(Pn&&!Ot&&!Ye&&!un&&(un=Re),Ot=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Ot=void 0}if(!Ye&&mt[0]==="enter"&&mt[1].type==="listItemPrefix"||Ye===-1&&mt[0]==="exit"&&(mt[1].type==="listUnordered"||mt[1].type==="listOrdered")){if(Pn){let Ut=Re;for(Bt=void 0;Ut--;){const X=W[Ut];if(X[1].type==="lineEnding"||X[1].type==="lineEndingBlank"){if(X[0]==="exit")continue;Bt&&(W[Bt][1].type="lineEndingBlank",Yt=!0),X[1].type="lineEnding",Bt=Ut}else if(!(X[1].type==="linePrefix"||X[1].type==="blockQuotePrefix"||X[1].type==="blockQuotePrefixWhitespace"||X[1].type==="blockQuoteMarker"||X[1].type==="listItemIndent"))break}un&&(!Bt||un<Bt)&&(Pn._spread=!0),Pn.end=Object.assign({},Bt?W[Bt][1].start:mt[1].end),W.splice(Bt||Re,0,["exit",Pn,mt[2]]),Re++,ke++}if(mt[1].type==="listItemPrefix"){const Ut={type:"listItem",_spread:!1,start:Object.assign({},mt[1].start),end:void 0};Pn=Ut,W.splice(Re,0,["enter",Ut,mt[2]]),Re++,ke++,un=void 0,Ot=!0}}}return W[ue][1]._spread=Yt,ke}function s(W,ue){return ke;function ke(Re){f.call(this,W(Re),Re),ue&&ue.call(this,Re)}}function c(){this.stack.push({type:"fragment",children:[]})}function f(W,ue,ke){this.stack[this.stack.length-1].children.push(W),this.stack.push(W),this.tokenStack.push([ue,ke||void 0]),W.position={start:ca(ue.start),end:void 0}}function h(W){return ue;function ue(ke){W&&W.call(this,ke),d.call(this,ke)}}function d(W,ue){const ke=this.stack.pop(),Re=this.tokenStack.pop();if(Re)Re[0].type!==W.type&&(ue?ue.call(this,W,Re[0]):(Re[1]||Hb).call(this,W,Re[0]));else throw new Error("Cannot close `"+W.type+"` ("+Eo({start:W.start,end:W.end})+"): it’s not open");ke.position.end=ca(W.end)}function m(){return sm(this.stack.pop())}function y(){this.data.expectingFirstListItemValue=!0}function b(W){if(this.data.expectingFirstListItemValue){const ue=this.stack[this.stack.length-2];ue.start=Number.parseInt(this.sliceSerialize(W),10),this.data.expectingFirstListItemValue=void 0}}function w(){const W=this.resume(),ue=this.stack[this.stack.length-1];ue.lang=W}function k(){const W=this.resume(),ue=this.stack[this.stack.length-1];ue.meta=W}function C(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function T(){const W=this.resume(),ue=this.stack[this.stack.length-1];ue.value=W.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function A(){const W=this.resume(),ue=this.stack[this.stack.length-1];ue.value=W.replace(/(\r?\n|\r)$/g,"")}function _(W){const ue=this.resume(),ke=this.stack[this.stack.length-1];ke.label=ue,ke.identifier=Gn(this.sliceSerialize(W)).toLowerCase()}function N(){const W=this.resume(),ue=this.stack[this.stack.length-1];ue.title=W}function O(){const W=this.resume(),ue=this.stack[this.stack.length-1];ue.url=W}function z(W){const ue=this.stack[this.stack.length-1];if(!ue.depth){const ke=this.sliceSerialize(W).length;ue.depth=ke}}function j(){this.data.setextHeadingSlurpLineEnding=!0}function $(W){const ue=this.stack[this.stack.length-1];ue.depth=this.sliceSerialize(W).codePointAt(0)===61?1:2}function G(){this.data.setextHeadingSlurpLineEnding=void 0}function ee(W){const ke=this.stack[this.stack.length-1].children;let Re=ke[ke.length-1];(!Re||Re.type!=="text")&&(Re=Ja(),Re.position={start:ca(W.start),end:void 0},ke.push(Re)),this.stack.push(Re)}function P(W){const ue=this.stack.pop();ue.value+=this.sliceSerialize(W),ue.position.end=ca(W.end)}function ne(W){const ue=this.stack[this.stack.length-1];if(this.data.atHardBreak){const ke=ue.children[ue.children.length-1];ke.position.end=ca(W.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&n.canContainEols.includes(ue.type)&&(ee.call(this,W),P.call(this,W))}function ae(){this.data.atHardBreak=!0}function le(){const W=this.resume(),ue=this.stack[this.stack.length-1];ue.value=W}function H(){const W=this.resume(),ue=this.stack[this.stack.length-1];ue.value=W}function Q(){const W=this.resume(),ue=this.stack[this.stack.length-1];ue.value=W}function L(){const W=this.stack[this.stack.length-1];if(this.data.inReference){const ue=this.data.referenceType||"shortcut";W.type+="Reference",W.referenceType=ue,delete W.url,delete W.title}else delete W.identifier,delete W.label;this.data.referenceType=void 0}function K(){const W=this.stack[this.stack.length-1];if(this.data.inReference){const ue=this.data.referenceType||"shortcut";W.type+="Reference",W.referenceType=ue,delete W.url,delete W.title}else delete W.identifier,delete W.label;this.data.referenceType=void 0}function U(W){const ue=this.sliceSerialize(W),ke=this.stack[this.stack.length-2];ke.label=x3(ue),ke.identifier=Gn(ue).toLowerCase()}function J(){const W=this.stack[this.stack.length-1],ue=this.resume(),ke=this.stack[this.stack.length-1];if(this.data.inReference=!0,ke.type==="link"){const Re=W.children;ke.children=Re}else ke.alt=ue}function E(){const W=this.resume(),ue=this.stack[this.stack.length-1];ue.url=W}function Z(){const W=this.resume(),ue=this.stack[this.stack.length-1];ue.title=W}function oe(){this.data.inReference=void 0}function M(){this.data.referenceType="collapsed"}function se(W){const ue=this.resume(),ke=this.stack[this.stack.length-1];ke.label=ue,ke.identifier=Gn(this.sliceSerialize(W)).toLowerCase(),this.data.referenceType="full"}function Se(W){this.data.characterReferenceType=W.type}function he(W){const ue=this.sliceSerialize(W),ke=this.data.characterReferenceType;let Re;ke?(Re=NS(ue,ke==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):Re=um(ue);const Ye=this.stack[this.stack.length-1];Ye.value+=Re}function xe(W){const ue=this.stack.pop();ue.position.end=ca(W.end)}function Ee(W){P.call(this,W);const ue=this.stack[this.stack.length-1];ue.url=this.sliceSerialize(W)}function Qe(W){P.call(this,W);const ue=this.stack[this.stack.length-1];ue.url="mailto:"+this.sliceSerialize(W)}function bt(){return{type:"blockquote",children:[]}}function Rt(){return{type:"code",lang:null,meta:null,value:""}}function It(){return{type:"inlineCode",value:""}}function Gt(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function ba(){return{type:"emphasis",children:[]}}function Wn(){return{type:"heading",depth:0,children:[]}}function Jn(){return{type:"break"}}function Dt(){return{type:"html",value:""}}function Br(){return{type:"image",title:null,url:"",alt:null}}function Jt(){return{type:"link",title:null,url:"",children:[]}}function wn(W){return{type:"list",ordered:W.type==="listOrdered",start:null,spread:W._spread,children:[]}}function mr(W){return{type:"listItem",spread:W._spread,checked:null,children:[]}}function Wa(){return{type:"paragraph",children:[]}}function wa(){return{type:"strong",children:[]}}function Ja(){return{type:"text",value:""}}function Ur(){return{type:"thematicBreak"}}}function ca(e){return{line:e.line,column:e.column,offset:e.offset}}function HS(e,n){let r=-1;for(;++r<n.length;){const i=n[r];Array.isArray(i)?HS(e,i):E3(e,i)}}function E3(e,n){let r;for(r in n)if(US.call(n,r))switch(r){case"canContainEols":{const i=n[r];i&&e[r].push(...i);break}case"transforms":{const i=n[r];i&&e[r].push(...i);break}case"enter":case"exit":{const i=n[r];i&&Object.assign(e[r],i);break}}}function Hb(e,n){throw e?new Error("Cannot close `"+e.type+"` ("+Eo({start:e.start,end:e.end})+"): a different token (`"+n.type+"`, "+Eo({start:n.start,end:n.end})+") is open"):new Error("Cannot close document, a token (`"+n.type+"`, "+Eo({start:n.start,end:n.end})+") is still open")}function k3(e){const n=this;n.parser=r;function r(i){return w3(i,{...n.data("settings"),...e,extensions:n.data("micromarkExtensions")||[],mdastExtensions:n.data("fromMarkdownExtensions")||[]})}}function C3(e,n){const r={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(n),!0)};return e.patch(n,r),e.applyData(n,r)}function A3(e,n){const r={type:"element",tagName:"br",properties:{},children:[]};return e.patch(n,r),[e.applyData(n,r),{type:"text",value:`
|
|
@@ -484,4 +484,4 @@ ${J.content||""}`;i(E)}else i(null)}catch(K){console.error("Error fetching task:
|
|
|
484
484
|
${o}`,r&&`=== TASK CONTENT ===
|
|
485
485
|
${r}`].filter(Boolean),J=U.length>0?U.join(`
|
|
486
486
|
|
|
487
|
-
`):null;return{type:_.includes("/edit")?"tasks-edit":"tasks-view",content:J,displayId:Q,contextFiles:K}}return{type:"tasks",content:o,contextFiles:"project.md"}}return _.includes("/context")?_.includes("/architecture")?{type:"context-architecture",content:c,contextFiles:"architecture.md"}:_.includes("/project")?{type:"context-project",content:o,contextFiles:"project.md"}:_.includes("/knowledge")?{type:"context-knowledge",content:null}:{type:"context",content:null}:_.includes("/settings")?_.includes("/skills")?{type:"settings-skills",content:null}:_.includes("/integrations")?{type:"settings-integrations",content:null}:_.includes("/prompts")?{type:"settings-prompts",content:null}:_.includes("/rules")?{type:"settings-rules",content:null}:_.includes("/user")?{type:"settings-user",content:null}:{type:"settings",content:null}:_.includes("/terminal")?{type:"terminal",content:null}:{type:"dashboard",content:null}};return g.jsx(nS,{defaultOpen:!$,children:g.jsxs("div",{className:"flex min-h-screen w-full overflow-hidden",children:[g.jsx(M4,{}),g.jsxs(iS,{className:fe("flex-1 min-w-0 transition-all duration-300 ease-in-out",e&&"mr-96"),children:[g.jsxs("header",{className:"flex h-16 shrink-0 items-center gap-2 border-b border-content-border px-4 bg-background",children:[g.jsx(aS,{className:"-ml-1"}),g.jsxs("div",{className:"flex items-center justify-between flex-1",children:[g.jsx("h1",{className:"text-lg font-semibold",children:h||"Coconut"}),g.jsxs("div",{className:"flex items-center gap-2",children:[g.jsx(pt,{onClick:ne,size:"icon",className:"h-8 w-8 rounded-full",children:g.jsx(zu,{className:"h-4 w-4"})}),z&&N&&g.jsxs(k8,{children:[g.jsx(C8,{asChild:!0,children:g.jsx(pt,{size:"icon",variant:"outline",className:"h-8 w-8 rounded-full",children:g.jsx(EM,{className:"h-4 w-4"})})}),g.jsxs(yC,{align:"end",children:[g.jsx(xC,{children:g.jsxs("div",{className:"flex flex-col space-y-1",children:[g.jsx("p",{className:"text-sm font-medium leading-none",children:N.name}),g.jsx("p",{className:"text-xs leading-none text-muted-foreground",children:N.email})]})}),g.jsx(bC,{}),g.jsxs(vC,{onClick:ae,children:[g.jsx(jN,{className:"mr-2 h-4 w-4"}),"Logout"]})]})]})]})]})]}),g.jsx("main",{className:"flex flex-1 flex-col gap-4 p-4 overflow-auto bg-content-background",children:g.jsx(Ep,{})})]}),g.jsx(nI,{isOpen:e,onToggle:ne,contextInfo:le(),discussDocument:m,onDiscussDocumentHandled:()=>y(null),pendingPrompt:b,onPendingPromptHandled:()=>w(null),openInFullScreen:k,onFullScreenHandled:()=>C(!1),fullScreenNoEscape:P})]})})}const M8=[{title:"Coconut Profile",href:"/settings/user",icon:xM,description:"Manage the Coconut's profile information."},{title:"User Preferences",href:"/settings/preferences",icon:lM,description:"Configure individual workspace preferences"},{title:"Authentication",href:"/settings/authentication",icon:aM,description:"Configure authentication and user access"},{title:"API Keys",href:"/settings/api-keys",icon:_N,description:"Manage API keys for programmatic access"},{title:"Symlinks",href:"/settings/rules",icon:_o,description:"Manage symlinks for easy access to project rules and configurations"},{title:"AI & LLM",href:"/settings/integrations",icon:YN,description:"Connect Coconut to LLM providers and automation hooks"},{title:"Git",href:"/settings/git",icon:b1,description:"Configure repository defaults like worktree paths"},{title:"MCP",href:"/settings/mcp",icon:HN,description:"Model Context Protocol configuration and settings"},{title:"Notifications",href:"/settings/notifications",icon:Y_,description:"Configure Slack notifications for Coconut events"}];function j8(){const e=on();return g.jsxs("div",{className:"flex flex-col space-y-8 lg:flex-row lg:space-x-12 lg:space-y-0",children:[g.jsx("aside",{className:"lg:w-1/5",children:g.jsx("nav",{className:"flex overflow-x-auto pb-2 gap-1 lg:flex-col lg:gap-0 lg:space-y-1 lg:overflow-visible lg:pb-0",children:M8.map(n=>g.jsxs($n,{to:n.href,className:fe("inline-flex items-center whitespace-nowrap rounded-md text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 hover:text-accent-foreground h-9 px-2 sm:px-3 lg:px-4 py-2 hover:bg-accent justify-start flex-shrink-0",e.pathname===n.href?"bg-accent text-accent-foreground":"text-muted-foreground"),children:[g.jsx(n.icon,{className:"h-4 w-4 lg:mr-2"}),g.jsx("span",{className:"hidden lg:inline",children:n.title})]},n.href))})}),g.jsx("div",{className:"flex-1 lg:max-w-2xl",children:g.jsx("div",{className:"space-y-6",children:g.jsx(Ep,{})})})]})}const D8=[{title:"Inbox",href:"/mail/inbox",icon:TN,description:"Incoming emails"},{title:"Read",href:"/mail/read",icon:ON,description:"Emails you've already read"},{title:"Sent",href:"/mail/sent",icon:w1,description:"Emails you've sent"}];function O8(){const e=on();return g.jsxs("div",{className:"space-y-6",children:[g.jsxs("div",{children:[g.jsx("h2",{className:"text-2xl font-bold tracking-tight",children:"Mail"}),g.jsx("p",{className:"text-muted-foreground",children:"View and manage mail"})]}),g.jsxs("div",{className:"flex flex-col space-y-8 lg:flex-row lg:space-x-12 lg:space-y-0",children:[g.jsx("aside",{className:"lg:w-1/5",children:g.jsx("nav",{className:"flex overflow-x-auto pb-2 gap-1 lg:flex-col lg:gap-0 lg:space-y-1 lg:overflow-visible lg:pb-0",children:D8.map(n=>g.jsxs($n,{to:n.href,className:fe("inline-flex items-center whitespace-nowrap rounded-md text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 hover:text-accent-foreground h-9 px-2 sm:px-3 lg:px-4 py-2 hover:bg-accent justify-start flex-shrink-0",e.pathname===n.href?"bg-accent text-accent-foreground":"text-muted-foreground"),children:[g.jsx(n.icon,{className:"h-4 w-4 lg:mr-2"}),g.jsx("span",{className:"hidden lg:inline",children:n.title})]},n.href))})}),g.jsx("div",{className:"flex-1",children:g.jsx("div",{className:"space-y-6",children:g.jsx(Ep,{})})})]})]})}const L8=x.lazy(()=>De(()=>import("./DashboardPage-B9BZZfw6.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19]))),z8=x.lazy(()=>De(()=>import("./LoginPage-VQ3lcfLV.js"),__vite__mapDeps([20,4,1,21]))),P8=x.lazy(()=>De(()=>import("./CallbackPage-bROCGapx.js"),__vite__mapDeps([22,11,23]))),I8=x.lazy(()=>De(()=>import("./TasksPage-CD_eo0Bj.js"),__vite__mapDeps([24,1,2,5,6,3,13,12]))),B8=x.lazy(()=>De(()=>import("./TaskDetailPage-DpbRHnW_.js"),__vite__mapDeps([25,26,1,2,4,5,6,3,27,28,29,30,17,18,31]))),U8=x.lazy(()=>De(()=>import("./TaskEditPage-DssRbW0h.js"),__vite__mapDeps([32,4,5,6,1,33,34,35,36,37,2,27])).then(e=>({default:e.TaskEditPage}))),H8=x.lazy(()=>De(()=>import("./NewTaskPage-F5UX2WMc.js"),__vite__mapDeps([38,1,4,33,34,5,6,35,36,37,2,27])).then(e=>({default:e.NewTaskPage}))),F8=x.lazy(()=>De(()=>import("./TerminalPage-BG_wlccr.js"),__vite__mapDeps([39,1,7,8,9,10,40,41,6,17,42,43]))),q8=x.lazy(()=>De(()=>import("./TerminalSessionPage-CsK-LznK.js"),__vite__mapDeps([44,1,2,5,6,45,35,4,7,9,10,46,47,14,40,17,48,31,43]))),V8=x.lazy(()=>De(()=>import("./UtilitiesPage-BAxokhLh.js"),__vite__mapDeps([49,1,7,42,17]))),$8=x.lazy(()=>De(()=>import("./CodePage-CPCj64rX.js"),__vite__mapDeps([50,1,2,7,8,9,10,5,6,47,40,41,17,14]))),G8=x.lazy(()=>De(()=>import("./SkillsPage-DlWDhEjR.js"),__vite__mapDeps([51,1,26,52,2,53,13]))),Y8=x.lazy(()=>De(()=>import("./SkillDetailPage-k3Q2-NFd.js"),__vite__mapDeps([54,1,2,27]))),K8=x.lazy(()=>De(()=>import("./NewSkillPage-DwniHD6D.js"),__vite__mapDeps([55,1,4,2,26,27,28]))),X8=x.lazy(()=>De(()=>import("./SkillEditPage-urF4snjo.js"),__vite__mapDeps([56,1,4,2,26,27,28]))),Q8=x.lazy(()=>De(()=>import("./ResourcesPage-BP5tuAi-.js"),__vite__mapDeps([57,1,4,2,26,5,6,53,58,59,12,60,13]))),Z8=x.lazy(()=>De(()=>import("./ResourceDetailPage-DqHZ2KYD.js"),__vite__mapDeps([61,2,26,27,58,59,60]))),W8=x.lazy(()=>De(()=>import("./KnowledgePage-CGIVMS02.js"),__vite__mapDeps([62,1,2,26,52,53,13,29,63,46]))),J8=x.lazy(()=>De(()=>import("./KnowledgeDetailPage-DzHXBS7Q.js"),__vite__mapDeps([64,1,2,26,27,60,16]))),eB=x.lazy(()=>De(()=>import("./KnowledgeEditPage-BwGnUH_m.js"),__vite__mapDeps([65,1,4,33,34,37,2,66,16,27]))),tB=x.lazy(()=>De(()=>import("./NewKnowledgePage-BnVY7WUD.js"),__vite__mapDeps([67,1,4,33,34,37,2,66,16,27]))),nB=x.lazy(()=>De(()=>import("./ProjectPage-Unz9PQpA.js"),__vite__mapDeps([68,1,2,26,16]))),rB=x.lazy(()=>De(()=>import("./ProjectEditPage-DUUlIEqI.js"),__vite__mapDeps([69,1,4,5,6,33,34,27,19]))),aB=x.lazy(()=>De(()=>import("./ArchitecturePage-DYxC_aMR.js"),__vite__mapDeps([70,1,26]))),iB=x.lazy(()=>De(()=>import("./ArchitectureEditPage-CpowsIx2.js"),__vite__mapDeps([71,1,4,33,34,27,19]))),lB=x.lazy(()=>De(()=>import("./RolePage-Fed52Ov5.js"),__vite__mapDeps([72,1,26]))),oB=x.lazy(()=>De(()=>import("./RoleEditPage-BgKu8S0-.js"),__vite__mapDeps([73,1,4,5,6,33,34,27,19]))),sB=x.lazy(()=>De(()=>import("./IdentityPage-BC16skg6.js"),__vite__mapDeps([74,1,4,2,5,6,75,21,48,28]))),y0=x.lazy(()=>De(()=>import("./UserSettingsPage-CduI_MGS.js"),__vite__mapDeps([76,1,4,28]))),uB=x.lazy(()=>De(()=>import("./AuthSettingsPage-DtSo78Y_.js"),__vite__mapDeps([77,1,4,5,6,78,2,79]))),cB=x.lazy(()=>De(()=>import("./ApiKeysSettingsPage-B1YvVdmg.js"),__vite__mapDeps([80,1,4,2,75,30,79]))),fB=x.lazy(()=>De(()=>import("./SkillsSettingsPage-BViFgckG.js"),__vite__mapDeps([81,1,16]))),dB=x.lazy(()=>De(()=>import("./IntegrationsSettingsPage-CC_VKIQa.js"),__vite__mapDeps([82,1,4,5,6]))),hB=x.lazy(()=>De(()=>import("./GitSettingsPage-THm6wDjs.js"),__vite__mapDeps([83,1,4,45,40,16,11,23]))),pB=x.lazy(()=>De(()=>import("./McpSettingsPage-i9YHcu1s.js"),__vite__mapDeps([84,1,4,2,78,75,52,53,13,79,19]))),mB=x.lazy(()=>De(()=>import("./PromptsSettingsPage-DVpIuRKI.js"),__vite__mapDeps([85,1,4,5,6,2,48,59]))),gB=x.lazy(()=>De(()=>import("./RulesSettingsPage-BQ2O0u66.js"),__vite__mapDeps([86,1,4,2]))),yB=x.lazy(()=>De(()=>import("./NotificationsSettingsPage-C8kjcift.js"),__vite__mapDeps([87,1,4,78,5,6,31,11,23,40]))),vB=x.lazy(()=>De(()=>import("./GitPage-BiDtdSK1.js"),__vite__mapDeps([88,1,4,21,11,23,46,63,40,79,6,15]))),xB=x.lazy(()=>De(()=>import("./SchedulePage-jkxjuzBx.js"),__vite__mapDeps([89,1,2,5,6,4,78,21,40,17,90,18]))),bB=x.lazy(()=>De(()=>import("./JobDetailPage-z1QQYvmU.js"),__vite__mapDeps([91,26,1,2,27,17,28,40,6,90,18]))),wB=x.lazy(()=>De(()=>import("./UserPreferencesPage-CWUq3efu.js"),__vite__mapDeps([92,1,4,5,6]))),SB=x.lazy(()=>De(()=>import("./ActivityPage-k4I7Q53O.js"),__vite__mapDeps([93,1,2,40]))),EB=x.lazy(()=>De(()=>import("./MailInboxPage-DiZKqwdU.js"),__vite__mapDeps([94,1,2,95,18,40,96,6]))),kB=x.lazy(()=>De(()=>import("./MailReadPage-C8AACmZQ.js"),__vite__mapDeps([97,1,2,95,18,40,96,6]))),CB=x.lazy(()=>De(()=>import("./MailSentPage-C_5yFly_.js"),__vite__mapDeps([98,1,2,40,96,6]))),v0=x.lazy(()=>De(()=>import("./NotFoundPage-BbSZX_4L.js"),[]));function AB(){return g.jsxs(qR,{children:[g.jsx(nR,{children:g.jsx(x.Suspense,{fallback:g.jsx(pj,{}),children:g.jsxs(jT,{children:[g.jsx(Ce,{path:"/login",element:g.jsx(z8,{})}),g.jsx(Ce,{path:"/auth/github/callback",element:g.jsx(P8,{})}),g.jsxs(Ce,{path:"/",element:g.jsx(hj,{children:g.jsx(N8,{})}),children:[g.jsx(Ce,{index:!0,element:g.jsx(L8,{})}),g.jsx(Ce,{path:"tasks",element:g.jsx(I8,{})}),g.jsx(Ce,{path:"tasks/new",element:g.jsx(H8,{})}),g.jsx(Ce,{path:"tasks/:id",element:g.jsx(B8,{})}),g.jsx(Ce,{path:"tasks/:id/edit",element:g.jsx(U8,{})}),g.jsx(Ce,{path:"agents",element:g.jsx($8,{})}),g.jsx(Ce,{path:"utilities",element:g.jsx(V8,{})}),g.jsx(Ce,{path:"terminal",element:g.jsx(F8,{})}),g.jsx(Ce,{path:"terminal/:taskId",element:g.jsx(q8,{})}),g.jsx(Ce,{path:"git",element:g.jsx(vB,{})}),g.jsx(Ce,{path:"schedule",element:g.jsx(xB,{})}),g.jsx(Ce,{path:"schedule/:id",element:g.jsx(bB,{})}),g.jsx(Ce,{path:"identity",element:g.jsx(sB,{})}),g.jsx(Ce,{path:"skills",element:g.jsx(G8,{})}),g.jsx(Ce,{path:"skills/new",element:g.jsx(K8,{})}),g.jsx(Ce,{path:"skills/:id",element:g.jsx(Y8,{})}),g.jsx(Ce,{path:"skills/:id/edit",element:g.jsx(X8,{})}),g.jsx(Ce,{path:"activity",element:g.jsx(SB,{})}),g.jsx(Ce,{path:"resources",element:g.jsx(Q8,{})}),g.jsx(Ce,{path:"resources/:id",element:g.jsx(Z8,{})}),g.jsx(Ce,{path:"context/project",element:g.jsx(nB,{})}),g.jsx(Ce,{path:"context/project/edit",element:g.jsx(rB,{})}),g.jsx(Ce,{path:"context/architecture",element:g.jsx(aB,{})}),g.jsx(Ce,{path:"context/architecture/edit",element:g.jsx(iB,{})}),g.jsx(Ce,{path:"context/role",element:g.jsx(lB,{})}),g.jsx(Ce,{path:"context/role/edit",element:g.jsx(oB,{})}),g.jsx(Ce,{path:"knowledge",element:g.jsx(W8,{})}),g.jsx(Ce,{path:"knowledge/new",element:g.jsx(tB,{})}),g.jsx(Ce,{path:"knowledge/:filename",element:g.jsx(J8,{})}),g.jsx(Ce,{path:"knowledge/:filename/edit",element:g.jsx(eB,{})}),g.jsxs(Ce,{path:"mail",element:g.jsx(O8,{}),children:[g.jsx(Ce,{index:!0,element:g.jsx(N0,{to:"inbox",replace:!0})}),g.jsx(Ce,{path:"inbox",element:g.jsx(EB,{})}),g.jsx(Ce,{path:"read",element:g.jsx(kB,{})}),g.jsx(Ce,{path:"sent",element:g.jsx(CB,{})})]}),g.jsxs(Ce,{path:"settings",element:g.jsx(j8,{}),children:[g.jsx(Ce,{index:!0,element:g.jsx(y0,{})}),g.jsx(Ce,{path:"user",element:g.jsx(y0,{})}),g.jsx(Ce,{path:"preferences",element:g.jsx(wB,{})}),g.jsx(Ce,{path:"authentication",element:g.jsx(uB,{})}),g.jsx(Ce,{path:"api-keys",element:g.jsx(cB,{})}),g.jsx(Ce,{path:"skills",element:g.jsx(fB,{})}),g.jsx(Ce,{path:"integrations",element:g.jsx(dB,{})}),g.jsx(Ce,{path:"git",element:g.jsx(hB,{})}),g.jsx(Ce,{path:"mcp",element:g.jsx(pB,{})}),g.jsx(Ce,{path:"prompts",element:g.jsx(mB,{})}),g.jsx(Ce,{path:"rules",element:g.jsx(gB,{})}),g.jsx(Ce,{path:"notifications",element:g.jsx(yB,{})})]}),g.jsx(Ce,{path:"*",element:g.jsx(v0,{})})]}),g.jsx(Ce,{path:"*",element:g.jsx(v0,{})})]})})}),g.jsx(dj,{})]})}IA.createRoot(document.getElementById("root")).render(g.jsx(x.StrictMode,{children:g.jsx(AB,{})}));export{EM as $,xt as A,pt as B,rN as C,Ac as D,yM as E,_o as F,b1 as G,FE as H,I1 as I,qE as J,zB as K,$n as L,rh as M,$E as N,GE as O,XN as P,VE as Q,KE as R,zo as S,mM as T,YE as U,LB as V,hS as W,Yi as X,fM as Y,RM as Z,ns as _,KR as a,H1 as a$,ZN as a0,fj as a1,k8 as a2,C8 as a3,yC as a4,xC as a5,bC as a6,vC as a7,MB as a8,eM as a9,mm as aA,rm as aB,op as aC,cP as aD,G4 as aE,PB as aF,O4 as aG,Q4 as aH,B4 as aI,X4 as aJ,tp as aK,am as aL,wS as aM,Oo as aN,zP as aO,k3 as aP,vP as aQ,XS as aR,IB as aS,oL as aT,xh as aU,fa as aV,$t as aW,r0 as aX,_B as aY,HN as aZ,zN as a_,R8 as aa,Fu as ab,CM as ac,HR as ad,Dp as ae,oN as af,ol as ag,Qn as ah,Rp as ai,pe as aj,Fe as ak,Xe as al,Sm as am,O9 as an,jw as ao,R9 as ap,Yx as aq,qP as ar,d9 as as,n9 as at,mN as au,Nc as av,ac as aw,UB as ax,BB as ay,um as az,Xo as b,Bi as b0,_N as b1,pc as b2,wc as b3,Fw as b4,$a as b5,cr as b6,v_ as b7,qw as b8,fc as b9,oc as ba,kt as bb,W1 as bc,q1 as bd,Pp as be,Wi as bf,zp as bg,Fo as bh,Vw as bi,$w as bj,xk as bk,hI as bl,pI as bm,Zt as bn,iN as bo,w1 as bp,Y_ as bq,NB as br,Q_ as bs,wN as bt,$_ as bu,ub as bv,TN as bw,ON as bx,hM as by,Te as c,Qo as d,fe as e,Zo as f,xo as g,zu as h,aM as i,g as j,So as k,nM as l,W_ as m,tN as n,yk as o,gh as p,on as q,x as r,$0 as s,$u as t,Uo as u,Uh as v,RB as w,TB as x,C9 as y,A9 as z};
|
|
487
|
+
`):null;return{type:_.includes("/edit")?"tasks-edit":"tasks-view",content:J,displayId:Q,contextFiles:K}}return{type:"tasks",content:o,contextFiles:"project.md"}}return _.includes("/context")?_.includes("/architecture")?{type:"context-architecture",content:c,contextFiles:"architecture.md"}:_.includes("/project")?{type:"context-project",content:o,contextFiles:"project.md"}:_.includes("/knowledge")?{type:"context-knowledge",content:null}:{type:"context",content:null}:_.includes("/settings")?_.includes("/skills")?{type:"settings-skills",content:null}:_.includes("/integrations")?{type:"settings-integrations",content:null}:_.includes("/prompts")?{type:"settings-prompts",content:null}:_.includes("/rules")?{type:"settings-rules",content:null}:_.includes("/user")?{type:"settings-user",content:null}:{type:"settings",content:null}:_.includes("/terminal")?{type:"terminal",content:null}:{type:"dashboard",content:null}};return g.jsx(nS,{defaultOpen:!$,children:g.jsxs("div",{className:"flex min-h-screen w-full overflow-hidden",children:[g.jsx(M4,{}),g.jsxs(iS,{className:fe("flex-1 min-w-0 transition-all duration-300 ease-in-out",e&&"mr-96"),children:[g.jsxs("header",{className:"flex h-16 shrink-0 items-center gap-2 border-b border-content-border px-4 bg-background",children:[g.jsx(aS,{className:"-ml-1"}),g.jsxs("div",{className:"flex items-center justify-between flex-1",children:[g.jsx("h1",{className:"text-lg font-semibold",children:h||"Coconut"}),g.jsxs("div",{className:"flex items-center gap-2",children:[g.jsx(pt,{onClick:ne,size:"icon",className:"h-8 w-8 rounded-full",children:g.jsx(zu,{className:"h-4 w-4"})}),z&&N&&g.jsxs(k8,{children:[g.jsx(C8,{asChild:!0,children:g.jsx(pt,{size:"icon",variant:"outline",className:"h-8 w-8 rounded-full",children:g.jsx(EM,{className:"h-4 w-4"})})}),g.jsxs(yC,{align:"end",children:[g.jsx(xC,{children:g.jsxs("div",{className:"flex flex-col space-y-1",children:[g.jsx("p",{className:"text-sm font-medium leading-none",children:N.name}),g.jsx("p",{className:"text-xs leading-none text-muted-foreground",children:N.email})]})}),g.jsx(bC,{}),g.jsxs(vC,{onClick:ae,children:[g.jsx(jN,{className:"mr-2 h-4 w-4"}),"Logout"]})]})]})]})]})]}),g.jsx("main",{className:"flex flex-1 flex-col gap-4 p-4 overflow-auto bg-content-background",children:g.jsx(Ep,{})})]}),g.jsx(nI,{isOpen:e,onToggle:ne,contextInfo:le(),discussDocument:m,onDiscussDocumentHandled:()=>y(null),pendingPrompt:b,onPendingPromptHandled:()=>w(null),openInFullScreen:k,onFullScreenHandled:()=>C(!1),fullScreenNoEscape:P})]})})}const M8=[{title:"Coconut Profile",href:"/settings/user",icon:xM,description:"Manage the Coconut's profile information."},{title:"User Preferences",href:"/settings/preferences",icon:lM,description:"Configure individual workspace preferences"},{title:"Authentication",href:"/settings/authentication",icon:aM,description:"Configure authentication and user access"},{title:"API Keys",href:"/settings/api-keys",icon:_N,description:"Manage API keys for programmatic access"},{title:"Symlinks",href:"/settings/rules",icon:_o,description:"Manage symlinks for easy access to project rules and configurations"},{title:"AI & LLM",href:"/settings/integrations",icon:YN,description:"Connect Coconut to LLM providers and automation hooks"},{title:"Git",href:"/settings/git",icon:b1,description:"Configure repository defaults like worktree paths"},{title:"MCP",href:"/settings/mcp",icon:HN,description:"Model Context Protocol configuration and settings"},{title:"Notifications",href:"/settings/notifications",icon:Y_,description:"Configure Slack notifications for Coconut events"}];function j8(){const e=on();return g.jsxs("div",{className:"flex flex-col space-y-8 lg:flex-row lg:space-x-12 lg:space-y-0",children:[g.jsx("aside",{className:"lg:w-1/5",children:g.jsx("nav",{className:"flex overflow-x-auto pb-2 gap-1 lg:flex-col lg:gap-0 lg:space-y-1 lg:overflow-visible lg:pb-0",children:M8.map(n=>g.jsxs($n,{to:n.href,className:fe("inline-flex items-center whitespace-nowrap rounded-md text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 hover:text-accent-foreground h-9 px-2 sm:px-3 lg:px-4 py-2 hover:bg-accent justify-start flex-shrink-0",e.pathname===n.href?"bg-accent text-accent-foreground":"text-muted-foreground"),children:[g.jsx(n.icon,{className:"h-4 w-4 lg:mr-2"}),g.jsx("span",{className:"hidden lg:inline",children:n.title})]},n.href))})}),g.jsx("div",{className:"flex-1 lg:max-w-2xl",children:g.jsx("div",{className:"space-y-6",children:g.jsx(Ep,{})})})]})}const D8=[{title:"Inbox",href:"/mail/inbox",icon:TN,description:"Incoming emails"},{title:"Read",href:"/mail/read",icon:ON,description:"Emails you've already read"},{title:"Sent",href:"/mail/sent",icon:w1,description:"Emails you've sent"}];function O8(){const e=on();return g.jsxs("div",{className:"space-y-6",children:[g.jsxs("div",{children:[g.jsx("h2",{className:"text-2xl font-bold tracking-tight",children:"Mail"}),g.jsx("p",{className:"text-muted-foreground",children:"View and manage mail"})]}),g.jsxs("div",{className:"flex flex-col space-y-8 lg:flex-row lg:space-x-12 lg:space-y-0",children:[g.jsx("aside",{className:"lg:w-1/5",children:g.jsx("nav",{className:"flex overflow-x-auto pb-2 gap-1 lg:flex-col lg:gap-0 lg:space-y-1 lg:overflow-visible lg:pb-0",children:D8.map(n=>g.jsxs($n,{to:n.href,className:fe("inline-flex items-center whitespace-nowrap rounded-md text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 hover:text-accent-foreground h-9 px-2 sm:px-3 lg:px-4 py-2 hover:bg-accent justify-start flex-shrink-0",e.pathname===n.href?"bg-accent text-accent-foreground":"text-muted-foreground"),children:[g.jsx(n.icon,{className:"h-4 w-4 lg:mr-2"}),g.jsx("span",{className:"hidden lg:inline",children:n.title})]},n.href))})}),g.jsx("div",{className:"flex-1",children:g.jsx("div",{className:"space-y-6",children:g.jsx(Ep,{})})})]})]})}const L8=x.lazy(()=>De(()=>import("./DashboardPage-BdsK2Vor.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19]))),z8=x.lazy(()=>De(()=>import("./LoginPage-DVaToPHL.js"),__vite__mapDeps([20,4,1,21]))),P8=x.lazy(()=>De(()=>import("./CallbackPage-CYcV3OHa.js"),__vite__mapDeps([22,11,23]))),I8=x.lazy(()=>De(()=>import("./TasksPage-COvedmQz.js"),__vite__mapDeps([24,1,2,5,6,3,13,12]))),B8=x.lazy(()=>De(()=>import("./TaskDetailPage-D97oWW98.js"),__vite__mapDeps([25,26,1,2,4,5,6,3,27,28,29,30,17,18,31]))),U8=x.lazy(()=>De(()=>import("./TaskEditPage-BTfzRYwM.js"),__vite__mapDeps([32,4,5,6,1,33,34,35,36,37,2,27])).then(e=>({default:e.TaskEditPage}))),H8=x.lazy(()=>De(()=>import("./NewTaskPage-CrmiPuuw.js"),__vite__mapDeps([38,1,4,33,34,5,6,35,36,37,2,27])).then(e=>({default:e.NewTaskPage}))),F8=x.lazy(()=>De(()=>import("./TerminalPage-DhbOmISZ.js"),__vite__mapDeps([39,1,7,8,9,10,40,41,6,17,42,43]))),q8=x.lazy(()=>De(()=>import("./TerminalSessionPage-D2rZb8Ej.js"),__vite__mapDeps([44,1,2,5,6,45,35,4,7,9,10,46,47,14,40,17,48,31,43]))),V8=x.lazy(()=>De(()=>import("./UtilitiesPage-CxQkYrza.js"),__vite__mapDeps([49,1,7,42,17]))),$8=x.lazy(()=>De(()=>import("./CodePage-DxJYFhiT.js"),__vite__mapDeps([50,1,2,7,8,9,10,5,6,47,40,41,17,14]))),G8=x.lazy(()=>De(()=>import("./SkillsPage-Dr_uyKVB.js"),__vite__mapDeps([51,1,26,52,2,53,13]))),Y8=x.lazy(()=>De(()=>import("./SkillDetailPage-BFjBVPS8.js"),__vite__mapDeps([54,1,2,27]))),K8=x.lazy(()=>De(()=>import("./NewSkillPage-DesCsYgS.js"),__vite__mapDeps([55,1,4,2,26,27,28]))),X8=x.lazy(()=>De(()=>import("./SkillEditPage-CjpscD5K.js"),__vite__mapDeps([56,1,4,2,26,27,28]))),Q8=x.lazy(()=>De(()=>import("./ResourcesPage-YmerqN0J.js"),__vite__mapDeps([57,1,4,2,26,5,6,53,58,59,12,60,13]))),Z8=x.lazy(()=>De(()=>import("./ResourceDetailPage-BSeDQxri.js"),__vite__mapDeps([61,2,26,27,58,59,60]))),W8=x.lazy(()=>De(()=>import("./KnowledgePage-DJphs1Kg.js"),__vite__mapDeps([62,1,2,26,52,53,13,29,63,46]))),J8=x.lazy(()=>De(()=>import("./KnowledgeDetailPage-C1RHtPzz.js"),__vite__mapDeps([64,1,2,26,27,60,16]))),eB=x.lazy(()=>De(()=>import("./KnowledgeEditPage-D3gIqqKn.js"),__vite__mapDeps([65,1,4,33,34,37,2,66,16,27]))),tB=x.lazy(()=>De(()=>import("./NewKnowledgePage-WbN6BikQ.js"),__vite__mapDeps([67,1,4,33,34,37,2,66,16,27]))),nB=x.lazy(()=>De(()=>import("./ProjectPage-CKaHBZlw.js"),__vite__mapDeps([68,1,2,26,16]))),rB=x.lazy(()=>De(()=>import("./ProjectEditPage-DiHz-pYk.js"),__vite__mapDeps([69,1,4,5,6,33,34,27,19]))),aB=x.lazy(()=>De(()=>import("./ArchitecturePage-oB3FtdZ7.js"),__vite__mapDeps([70,1,26]))),iB=x.lazy(()=>De(()=>import("./ArchitectureEditPage-iflIJaCh.js"),__vite__mapDeps([71,1,4,33,34,27,19]))),lB=x.lazy(()=>De(()=>import("./RolePage-DoN5_uka.js"),__vite__mapDeps([72,1,26]))),oB=x.lazy(()=>De(()=>import("./RoleEditPage-Bm7HG4sg.js"),__vite__mapDeps([73,1,4,5,6,33,34,27,19]))),sB=x.lazy(()=>De(()=>import("./IdentityPage-vzzaKU2-.js"),__vite__mapDeps([74,1,4,2,5,6,75,21,48,28]))),y0=x.lazy(()=>De(()=>import("./UserSettingsPage-AXLWqe0G.js"),__vite__mapDeps([76,1,4,28]))),uB=x.lazy(()=>De(()=>import("./AuthSettingsPage-BY7x-6wd.js"),__vite__mapDeps([77,1,4,5,6,78,2,79]))),cB=x.lazy(()=>De(()=>import("./ApiKeysSettingsPage-DiBqSUMz.js"),__vite__mapDeps([80,1,4,2,75,30,79]))),fB=x.lazy(()=>De(()=>import("./SkillsSettingsPage-BknrbJBC.js"),__vite__mapDeps([81,1,16]))),dB=x.lazy(()=>De(()=>import("./IntegrationsSettingsPage-BzuUrHO1.js"),__vite__mapDeps([82,1,4,5,6]))),hB=x.lazy(()=>De(()=>import("./GitSettingsPage-sI4uzGzt.js"),__vite__mapDeps([83,1,4,45,40,16,11,23]))),pB=x.lazy(()=>De(()=>import("./McpSettingsPage-d66ZIwm7.js"),__vite__mapDeps([84,1,4,2,78,75,52,53,13,79,19]))),mB=x.lazy(()=>De(()=>import("./PromptsSettingsPage-B_Opt_KA.js"),__vite__mapDeps([85,1,4,5,6,2,48,59]))),gB=x.lazy(()=>De(()=>import("./RulesSettingsPage-yQELBKgb.js"),__vite__mapDeps([86,1,4,2]))),yB=x.lazy(()=>De(()=>import("./NotificationsSettingsPage-BeJw7gY7.js"),__vite__mapDeps([87,1,4,78,5,6,31,11,23,40]))),vB=x.lazy(()=>De(()=>import("./GitPage-CKIIMGjF.js"),__vite__mapDeps([88,1,4,21,11,23,46,63,40,79,6,15]))),xB=x.lazy(()=>De(()=>import("./SchedulePage-nmchdGUK.js"),__vite__mapDeps([89,1,2,5,6,4,78,21,40,17,90,18]))),bB=x.lazy(()=>De(()=>import("./JobDetailPage-C-IKmhAF.js"),__vite__mapDeps([91,26,1,2,27,17,28,40,6,90,18]))),wB=x.lazy(()=>De(()=>import("./UserPreferencesPage-CgtsVqvs.js"),__vite__mapDeps([92,1,4,5,6]))),SB=x.lazy(()=>De(()=>import("./ActivityPage-DxajSxG1.js"),__vite__mapDeps([93,1,2,40]))),EB=x.lazy(()=>De(()=>import("./MailInboxPage-I-MbS647.js"),__vite__mapDeps([94,1,2,95,18,40,96,6]))),kB=x.lazy(()=>De(()=>import("./MailReadPage-DUN8EQjl.js"),__vite__mapDeps([97,1,2,95,18,40,96,6]))),CB=x.lazy(()=>De(()=>import("./MailSentPage-DsGgBGBQ.js"),__vite__mapDeps([98,1,2,40,96,6]))),v0=x.lazy(()=>De(()=>import("./NotFoundPage-BcTtqwNP.js"),[]));function AB(){return g.jsxs(qR,{children:[g.jsx(nR,{children:g.jsx(x.Suspense,{fallback:g.jsx(pj,{}),children:g.jsxs(jT,{children:[g.jsx(Ce,{path:"/login",element:g.jsx(z8,{})}),g.jsx(Ce,{path:"/auth/github/callback",element:g.jsx(P8,{})}),g.jsxs(Ce,{path:"/",element:g.jsx(hj,{children:g.jsx(N8,{})}),children:[g.jsx(Ce,{index:!0,element:g.jsx(L8,{})}),g.jsx(Ce,{path:"tasks",element:g.jsx(I8,{})}),g.jsx(Ce,{path:"tasks/new",element:g.jsx(H8,{})}),g.jsx(Ce,{path:"tasks/:id",element:g.jsx(B8,{})}),g.jsx(Ce,{path:"tasks/:id/edit",element:g.jsx(U8,{})}),g.jsx(Ce,{path:"agents",element:g.jsx($8,{})}),g.jsx(Ce,{path:"utilities",element:g.jsx(V8,{})}),g.jsx(Ce,{path:"terminal",element:g.jsx(F8,{})}),g.jsx(Ce,{path:"terminal/:taskId",element:g.jsx(q8,{})}),g.jsx(Ce,{path:"git",element:g.jsx(vB,{})}),g.jsx(Ce,{path:"schedule",element:g.jsx(xB,{})}),g.jsx(Ce,{path:"schedule/:id",element:g.jsx(bB,{})}),g.jsx(Ce,{path:"identity",element:g.jsx(sB,{})}),g.jsx(Ce,{path:"skills",element:g.jsx(G8,{})}),g.jsx(Ce,{path:"skills/new",element:g.jsx(K8,{})}),g.jsx(Ce,{path:"skills/:id",element:g.jsx(Y8,{})}),g.jsx(Ce,{path:"skills/:id/edit",element:g.jsx(X8,{})}),g.jsx(Ce,{path:"activity",element:g.jsx(SB,{})}),g.jsx(Ce,{path:"resources",element:g.jsx(Q8,{})}),g.jsx(Ce,{path:"resources/:id",element:g.jsx(Z8,{})}),g.jsx(Ce,{path:"context/project",element:g.jsx(nB,{})}),g.jsx(Ce,{path:"context/project/edit",element:g.jsx(rB,{})}),g.jsx(Ce,{path:"context/architecture",element:g.jsx(aB,{})}),g.jsx(Ce,{path:"context/architecture/edit",element:g.jsx(iB,{})}),g.jsx(Ce,{path:"context/role",element:g.jsx(lB,{})}),g.jsx(Ce,{path:"context/role/edit",element:g.jsx(oB,{})}),g.jsx(Ce,{path:"knowledge",element:g.jsx(W8,{})}),g.jsx(Ce,{path:"knowledge/new",element:g.jsx(tB,{})}),g.jsx(Ce,{path:"knowledge/:filename",element:g.jsx(J8,{})}),g.jsx(Ce,{path:"knowledge/:filename/edit",element:g.jsx(eB,{})}),g.jsxs(Ce,{path:"mail",element:g.jsx(O8,{}),children:[g.jsx(Ce,{index:!0,element:g.jsx(N0,{to:"inbox",replace:!0})}),g.jsx(Ce,{path:"inbox",element:g.jsx(EB,{})}),g.jsx(Ce,{path:"read",element:g.jsx(kB,{})}),g.jsx(Ce,{path:"sent",element:g.jsx(CB,{})})]}),g.jsxs(Ce,{path:"settings",element:g.jsx(j8,{}),children:[g.jsx(Ce,{index:!0,element:g.jsx(y0,{})}),g.jsx(Ce,{path:"user",element:g.jsx(y0,{})}),g.jsx(Ce,{path:"preferences",element:g.jsx(wB,{})}),g.jsx(Ce,{path:"authentication",element:g.jsx(uB,{})}),g.jsx(Ce,{path:"api-keys",element:g.jsx(cB,{})}),g.jsx(Ce,{path:"skills",element:g.jsx(fB,{})}),g.jsx(Ce,{path:"integrations",element:g.jsx(dB,{})}),g.jsx(Ce,{path:"git",element:g.jsx(hB,{})}),g.jsx(Ce,{path:"mcp",element:g.jsx(pB,{})}),g.jsx(Ce,{path:"prompts",element:g.jsx(mB,{})}),g.jsx(Ce,{path:"rules",element:g.jsx(gB,{})}),g.jsx(Ce,{path:"notifications",element:g.jsx(yB,{})})]}),g.jsx(Ce,{path:"*",element:g.jsx(v0,{})})]}),g.jsx(Ce,{path:"*",element:g.jsx(v0,{})})]})})}),g.jsx(dj,{})]})}IA.createRoot(document.getElementById("root")).render(g.jsx(x.StrictMode,{children:g.jsx(AB,{})}));export{EM as $,xt as A,pt as B,rN as C,Ac as D,yM as E,_o as F,b1 as G,FE as H,I1 as I,qE as J,zB as K,$n as L,rh as M,$E as N,GE as O,XN as P,VE as Q,KE as R,zo as S,mM as T,YE as U,LB as V,hS as W,Yi as X,fM as Y,RM as Z,ns as _,KR as a,H1 as a$,ZN as a0,fj as a1,k8 as a2,C8 as a3,yC as a4,xC as a5,bC as a6,vC as a7,MB as a8,eM as a9,mm as aA,rm as aB,op as aC,cP as aD,G4 as aE,PB as aF,O4 as aG,Q4 as aH,B4 as aI,X4 as aJ,tp as aK,am as aL,wS as aM,Oo as aN,zP as aO,k3 as aP,vP as aQ,XS as aR,IB as aS,oL as aT,xh as aU,fa as aV,$t as aW,r0 as aX,_B as aY,HN as aZ,zN as a_,R8 as aa,Fu as ab,CM as ac,HR as ad,Dp as ae,oN as af,ol as ag,Qn as ah,Rp as ai,pe as aj,Fe as ak,Xe as al,Sm as am,O9 as an,jw as ao,R9 as ap,Yx as aq,qP as ar,d9 as as,n9 as at,mN as au,Nc as av,ac as aw,UB as ax,BB as ay,um as az,Xo as b,Bi as b0,_N as b1,pc as b2,wc as b3,Fw as b4,$a as b5,cr as b6,v_ as b7,qw as b8,fc as b9,oc as ba,kt as bb,W1 as bc,q1 as bd,Pp as be,Wi as bf,zp as bg,Fo as bh,Vw as bi,$w as bj,xk as bk,hI as bl,pI as bm,Zt as bn,iN as bo,w1 as bp,Y_ as bq,NB as br,Q_ as bs,wN as bt,$_ as bu,ub as bv,TN as bw,ON as bx,hM as by,Te as c,Qo as d,fe as e,Zo as f,xo as g,zu as h,aM as i,g as j,So as k,nM as l,W_ as m,tN as n,yk as o,gh as p,on as q,x as r,$0 as s,$u as t,Uo as u,Uh as v,RB as w,TB as x,C9 as y,A9 as z};
|