visual-living-plan 0.1.0 → 2.33.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/DESIGN.md +213 -0
- package/README.md +159 -28
- package/dist/AuthScreen.d.ts +9 -0
- package/dist/AuthScreen.js +7 -0
- package/dist/DesktopModeSwitch.d.ts +13 -0
- package/dist/DesktopModeSwitch.js +14 -0
- package/dist/OAuthMark.d.ts +6 -0
- package/dist/OAuthMark.js +8 -0
- package/dist/accountInitials.d.ts +5 -0
- package/dist/accountInitials.js +20 -0
- package/dist/accountLinking.d.ts +26 -0
- package/dist/accountLinking.js +46 -0
- package/dist/agentEvents.d.ts +31 -0
- package/dist/agentEvents.js +260 -0
- package/dist/agentPresence.d.ts +42 -0
- package/dist/agentPresence.js +69 -0
- package/dist/agentSkills.d.ts +35 -0
- package/dist/agentSkills.js +89 -0
- package/dist/agentStream.d.ts +35 -0
- package/dist/agentStream.js +133 -0
- package/dist/appearanceDom.d.ts +13 -0
- package/dist/appearanceDom.js +24 -0
- package/dist/appearanceSettings.d.ts +29 -0
- package/dist/appearanceSettings.js +293 -0
- package/dist/assets.d.ts +14 -0
- package/dist/assets.js +72 -0
- package/dist/authSearch.d.ts +11 -0
- package/dist/authSearch.js +30 -0
- package/dist/changelog.d.ts +11 -0
- package/dist/changelog.js +63 -0
- package/dist/changelogParse.d.ts +53 -0
- package/dist/changelogParse.js +226 -0
- package/dist/cli.d.ts +2 -0
- package/dist/cli.js +1727 -0
- package/dist/cliLauncher.d.ts +40 -0
- package/dist/cliLauncher.js +170 -0
- package/dist/cliToken.d.ts +11 -0
- package/dist/cliToken.js +15 -0
- package/dist/client/.vite/manifest.json +1780 -0
- package/dist/client/assets/BarChart-DtV3dIq4.js +1 -0
- package/dist/client/assets/BlockEditor-BklSUBjk.js +168 -0
- package/dist/client/assets/BlockEditor-K5h6xc4_.css +1 -0
- package/dist/client/assets/CodeBlock-BbI08MlQ.js +1 -0
- package/dist/client/assets/CodeBlock-BxRMnldw.js +175 -0
- package/dist/client/assets/LineChart-CQYMEbD6.js +1 -0
- package/dist/client/assets/Mermaid-Ciu9eIoG.js +1 -0
- package/dist/client/assets/Mermaid-jPWLXX7e.js +1 -0
- package/dist/client/assets/Popover-DbE4vUPG.js +1 -0
- package/dist/client/assets/ReactFlowExecutionCanvas-BhVs-adc.js +7 -0
- package/dist/client/assets/ReactFlowExecutionCanvas-DLioOiRN.css +1 -0
- package/dist/client/assets/StatusIcon-C_-Lm9b4.js +1 -0
- package/dist/client/assets/Workflow-C92OpLyf.js +1 -0
- package/dist/client/assets/agentPresence-D8asHrTp.js +1 -0
- package/dist/client/assets/andromeeda-DW8vo71h.js +1 -0
- package/dist/client/assets/andromeeda-vGVdxbeo.js +1 -0
- package/dist/client/assets/arrow-up-CEVVOXD5.js +1 -0
- package/dist/client/assets/arrow-up-down-BSjnQK2I.js +1 -0
- package/dist/client/assets/aurora-x-CDeNXAV0.js +1 -0
- package/dist/client/assets/aurora-x-rMvKqtYI.js +1 -0
- package/dist/client/assets/ayu-dark-CwczpL8O.js +1 -0
- package/dist/client/assets/ayu-dark-DluEY0Gj.js +1 -0
- package/dist/client/assets/ayu-light-C3h-C4tm.js +1 -0
- package/dist/client/assets/ayu-light-DSh22xiD.js +1 -0
- package/dist/client/assets/ayu-mirage-Bqwy1Gya.js +1 -0
- package/dist/client/assets/ayu-mirage-JE6hAyHG.js +1 -0
- package/dist/client/assets/browserStore-BDGKYoJj.js +435 -0
- package/dist/client/assets/button-BI07wqbi.css +1 -0
- package/dist/client/assets/button-DJWAGApe.js +1 -0
- package/dist/client/assets/catppuccin-frappe-C9Q5zVZY.js +1 -0
- package/dist/client/assets/catppuccin-frappe-pyXErRRU.js +1 -0
- package/dist/client/assets/catppuccin-latte-BILSUICr.js +1 -0
- package/dist/client/assets/catppuccin-latte-CtsyrtPq.js +1 -0
- package/dist/client/assets/catppuccin-macchiato-Ck60ZZQE.js +1 -0
- package/dist/client/assets/catppuccin-macchiato-R8nAf1vR.js +1 -0
- package/dist/client/assets/catppuccin-mocha-C_2G67cS.js +1 -0
- package/dist/client/assets/catppuccin-mocha-DjuaAJKi.js +1 -0
- package/dist/client/assets/ccount-nzzEXTrh.js +1 -0
- package/dist/client/assets/chartRows-CNjjLsAH.js +2 -0
- package/dist/client/assets/circle-x-BLGxA3gi.js +1 -0
- package/dist/client/assets/client-BsE_buVT.js +9 -0
- package/dist/client/assets/constants-CmGPilXJ.js +1 -0
- package/dist/client/assets/dark-plus-CHgc6GYj.js +1 -0
- package/dist/client/assets/dark-plus-Cs2F2srj.js +1 -0
- package/dist/client/assets/default-5FplaXL4.js +7 -0
- package/dist/client/assets/diffsTheme-PJJTu2Rq.js +1 -0
- package/dist/client/assets/dracula-BHWKrbxM.js +1 -0
- package/dist/client/assets/dracula-Cf1PG3MT.js +1 -0
- package/dist/client/assets/dracula-soft-5eyTD99u.js +1 -0
- package/dist/client/assets/dracula-soft-DXuNm1Kq.js +1 -0
- package/dist/client/assets/editSource-DQfw4nRm.js +1 -0
- package/dist/client/assets/editSource-U5AoD-Wo.js +14 -0
- package/dist/client/assets/engine-CLTPZlti.js +1 -0
- package/dist/client/assets/engine-DUyaiAMV.js +2 -0
- package/dist/client/assets/everforest-dark-CjdfwUBe.js +1 -0
- package/dist/client/assets/everforest-dark-sB-x3p7T.js +1 -0
- package/dist/client/assets/everforest-light-CfVwwCBP.js +1 -0
- package/dist/client/assets/everforest-light-Df2xbC6M.js +1 -0
- package/dist/client/assets/forgetDocuments-CIUBitCs.js +1 -0
- package/dist/client/assets/formatCSSVariablePrefix-KRh9vnZf.js +1 -0
- package/dist/client/assets/github-dark-BL6HSl_n.js +1 -0
- package/dist/client/assets/github-dark-C-LZuMrd.js +1 -0
- package/dist/client/assets/github-dark-default-DXG-b-1a.js +1 -0
- package/dist/client/assets/github-dark-default-zacuWV-M.js +1 -0
- package/dist/client/assets/github-dark-dimmed-Bx1FflLF.js +1 -0
- package/dist/client/assets/github-dark-dimmed-Mc0P9idi.js +1 -0
- package/dist/client/assets/github-dark-high-contrast-B_tTalzw.js +1 -0
- package/dist/client/assets/github-dark-high-contrast-IMKX2AVF.js +1 -0
- package/dist/client/assets/github-light-EUqPIrTm.js +1 -0
- package/dist/client/assets/github-light-default-BXViO-2h.js +1 -0
- package/dist/client/assets/github-light-default-DVlCqP3X.js +1 -0
- package/dist/client/assets/github-light-high-contrast-B68TUdTA.js +1 -0
- package/dist/client/assets/github-light-high-contrast-Dj6zTyWR.js +1 -0
- package/dist/client/assets/github-light-mYhEBkPo.js +1 -0
- package/dist/client/assets/gruvbox-dark-hard-C820rvS2.js +1 -0
- package/dist/client/assets/gruvbox-dark-hard-QTgQQZn-.js +1 -0
- package/dist/client/assets/gruvbox-dark-medium-9d5YdCTx.js +1 -0
- package/dist/client/assets/gruvbox-dark-medium-BPjhmG05.js +1 -0
- package/dist/client/assets/gruvbox-dark-soft-MrdJrrXF.js +1 -0
- package/dist/client/assets/gruvbox-dark-soft-XCkqeBhR.js +1 -0
- package/dist/client/assets/gruvbox-light-hard--5-nXqNp.js +1 -0
- package/dist/client/assets/gruvbox-light-hard-BC_s9l72.js +1 -0
- package/dist/client/assets/gruvbox-light-medium-BAWPOn9u.js +1 -0
- package/dist/client/assets/gruvbox-light-medium-COA1PZW2.js +1 -0
- package/dist/client/assets/gruvbox-light-soft-BSMLrYjP.js +1 -0
- package/dist/client/assets/gruvbox-light-soft-CIJpzjAO.js +1 -0
- package/dist/client/assets/hastToHtml-Dj8rXue9.js +11 -0
- package/dist/client/assets/highlight-cB-PkhyE.js +1 -0
- package/dist/client/assets/highlights-LLBF1DTm.js +1 -0
- package/dist/client/assets/horizon-Ba2cwkSy.js +1 -0
- package/dist/client/assets/horizon-CE9ld1lL.js +1 -0
- package/dist/client/assets/horizon-bright-DSNQnXHK.js +1 -0
- package/dist/client/assets/horizon-bright-DaEDgBmR.js +1 -0
- package/dist/client/assets/houston-B6x0XVpU.js +1 -0
- package/dist/client/assets/houston-CsvMBhTu.js +1 -0
- package/dist/client/assets/jsx-runtime-DKj5X9O4.js +1 -0
- package/dist/client/assets/kanagawa-dragon-Bozd7klA.js +1 -0
- package/dist/client/assets/kanagawa-dragon-DhTFvBMT.js +1 -0
- package/dist/client/assets/kanagawa-lotus--m8sdOxn.js +1 -0
- package/dist/client/assets/kanagawa-lotus-BmuOG9ZW.js +1 -0
- package/dist/client/assets/kanagawa-wave-BML5mF2J.js +1 -0
- package/dist/client/assets/kanagawa-wave-D-tTv4k2.js +1 -0
- package/dist/client/assets/laserwave-C_8bwKvT.js +1 -0
- package/dist/client/assets/laserwave-HSLx0L75.js +1 -0
- package/dist/client/assets/lib-COgu-QLX.js +33 -0
- package/dist/client/assets/lib-CdRiGVUZ.js +1 -0
- package/dist/client/assets/light-plus-CUjWrTSi.js +1 -0
- package/dist/client/assets/light-plus-DVQuIRkW.js +1 -0
- package/dist/client/assets/loader-CjL04K29.js +1 -0
- package/dist/client/assets/main-BGMX_GnZ.js +2 -0
- package/dist/client/assets/main-BTko4EvJ.css +1 -0
- package/dist/client/assets/material-theme-Bm3Qr25_.js +1 -0
- package/dist/client/assets/material-theme-CnthUGfg.js +1 -0
- package/dist/client/assets/material-theme-darker-2IIEA8gg.js +1 -0
- package/dist/client/assets/material-theme-darker-DUi03Qre.js +1 -0
- package/dist/client/assets/material-theme-lighter-D2-qr5Vw.js +1 -0
- package/dist/client/assets/material-theme-lighter-uhdI0v04.js +1 -0
- package/dist/client/assets/material-theme-ocean-CHQ94UKr.js +1 -0
- package/dist/client/assets/material-theme-ocean-CWR-LogA.js +1 -0
- package/dist/client/assets/material-theme-palenight-B5W6OYN7.js +1 -0
- package/dist/client/assets/material-theme-palenight-Cnv8m1ra.js +1 -0
- package/dist/client/assets/mdxEntries-BNTMP8ct.css +1 -0
- package/dist/client/assets/mdxEntries-L-V7bB6i.js +1 -0
- package/dist/client/assets/mermaid-Bjhs-krb.js +1 -0
- package/dist/client/assets/mermaid-Di4j-zgD.js +146 -0
- package/dist/client/assets/min-dark-BSWPekZh.js +1 -0
- package/dist/client/assets/min-dark-EXoM-6Xo.js +1 -0
- package/dist/client/assets/min-light-DDpmG2fV.js +1 -0
- package/dist/client/assets/min-light-DVOTDhnA.js +1 -0
- package/dist/client/assets/monokai-BscAjiQZ.js +1 -0
- package/dist/client/assets/monokai-DkggTbGy.js +1 -0
- package/dist/client/assets/mountChrome-BVWpsDCy.js +122 -0
- package/dist/client/assets/mountChrome-DhTDH3YM.css +1 -0
- package/dist/client/assets/night-owl-Bdcs0PMi.js +1 -0
- package/dist/client/assets/night-owl-DhmEMT88.js +1 -0
- package/dist/client/assets/night-owl-light-RoU30LE0.js +1 -0
- package/dist/client/assets/night-owl-light-eJ-hLW7d.js +1 -0
- package/dist/client/assets/noShiki-DB8hQ_W3.js +1 -0
- package/dist/client/assets/noShiki-GTG3tT8x.js +1 -0
- package/dist/client/assets/nord-Cb4Vim4T.js +1 -0
- package/dist/client/assets/nord-u7hMircQ.js +1 -0
- package/dist/client/assets/offlineSync-Cv3FVIlJ.js +1 -0
- package/dist/client/assets/one-dark-pro-08PdtLzi.js +1 -0
- package/dist/client/assets/one-dark-pro-C6YyR8OD.js +1 -0
- package/dist/client/assets/one-light-D7Lr4KcI.js +1 -0
- package/dist/client/assets/one-light-DgvUEtgI.js +1 -0
- package/dist/client/assets/opfs-worker-DuTOCgWR.js +5919 -0
- package/dist/client/assets/pierre-dark-B2jZWvHG.js +1 -0
- package/dist/client/assets/pierre-dark-CpLgRqie.js +1 -0
- package/dist/client/assets/pierre-dark-protanopia-deuteranopia-B35FxJx-.js +1 -0
- package/dist/client/assets/pierre-dark-protanopia-deuteranopia-CebgQdRf.js +1 -0
- package/dist/client/assets/pierre-dark-soft-DdE7dyP3.js +1 -0
- package/dist/client/assets/pierre-dark-soft-kZQmAZld.js +1 -0
- package/dist/client/assets/pierre-dark-tritanopia-CXimiT7X.js +1 -0
- package/dist/client/assets/pierre-dark-tritanopia-CpjhbsIL.js +1 -0
- package/dist/client/assets/pierre-dark-vibrant-CpQYzh95.js +1 -0
- package/dist/client/assets/pierre-dark-vibrant-DzBsxHvQ.js +1 -0
- package/dist/client/assets/pierre-light-CoaEpmwp.js +1 -0
- package/dist/client/assets/pierre-light-Vf__O3ev.js +1 -0
- package/dist/client/assets/pierre-light-protanopia-deuteranopia-0fSaH845.js +1 -0
- package/dist/client/assets/pierre-light-protanopia-deuteranopia-BUtWcCQC.js +1 -0
- package/dist/client/assets/pierre-light-soft-C3QCXKvN.js +1 -0
- package/dist/client/assets/pierre-light-soft-lWLdNTOI.js +1 -0
- package/dist/client/assets/pierre-light-tritanopia-CEbqgOJL.js +1 -0
- package/dist/client/assets/pierre-light-tritanopia-CKLy6XvA.js +1 -0
- package/dist/client/assets/pierre-light-vibrant-D80Fkn33.js +1 -0
- package/dist/client/assets/pierre-light-vibrant-DDuTEIhH.js +1 -0
- package/dist/client/assets/planEditButton-CbWGczbi.js +45 -0
- package/dist/client/assets/planEvents-cuzv9ELr.js +1 -0
- package/dist/client/assets/planMdx-Db1ze_nN.js +110 -0
- package/dist/client/assets/plastic-B8mE6BxX.js +1 -0
- package/dist/client/assets/plastic-DQwYfKfQ.js +1 -0
- package/dist/client/assets/poimandres-DRFjx7u4.js +1 -0
- package/dist/client/assets/poimandres-DUFjrgxT.js +1 -0
- package/dist/client/assets/preload-helper-Dx0-lKy1.js +1 -0
- package/dist/client/assets/queryClient-Bs5tSUJh.js +1 -0
- package/dist/client/assets/react-dom-DpzJPrWF.js +1 -0
- package/dist/client/assets/rebaseDraft-B2--cj1c.js +19 -0
- package/dist/client/assets/red-BJvdDEUx.js +1 -0
- package/dist/client/assets/red-CYlAq2b0.js +1 -0
- package/dist/client/assets/register-hZEIk3A9.css +1 -0
- package/dist/client/assets/register-htm5s8o9.js +1 -0
- package/dist/client/assets/rolldown-runtime-Dd_uD5pT.js +1 -0
- package/dist/client/assets/rose-pine-BSqRqUae.js +1 -0
- package/dist/client/assets/rose-pine-aMsaMD1D.js +1 -0
- package/dist/client/assets/rose-pine-dawn-8PwUyIlP.js +1 -0
- package/dist/client/assets/rose-pine-dawn-U6TBE82u.js +1 -0
- package/dist/client/assets/rose-pine-moon-CAU7u1h4.js +1 -0
- package/dist/client/assets/rose-pine-moon-DO-qXg-I.js +1 -0
- package/dist/client/assets/routeEdges-B2z8v0di.js +24 -0
- package/dist/client/assets/selector-C2KL2wxg.js +1 -0
- package/dist/client/assets/selector-CDsXW7SO.css +1 -0
- package/dist/client/assets/settingsChrome-NGUDtEIp.js +1 -0
- package/dist/client/assets/shiki-BOXJeUHI.js +2 -0
- package/dist/client/assets/slack-dark-CMu0smFa.js +1 -0
- package/dist/client/assets/slack-dark-DnToyrRv.js +1 -0
- package/dist/client/assets/slack-ochin-B2OO5cIa.js +1 -0
- package/dist/client/assets/slack-ochin-BBne7cjw.js +1 -0
- package/dist/client/assets/snazzy-light-4G7pJPwS.js +1 -0
- package/dist/client/assets/snazzy-light-CV8HUEmk.js +1 -0
- package/dist/client/assets/solarized-dark-CmYmhSgI.js +1 -0
- package/dist/client/assets/solarized-dark-b97czJOk.js +1 -0
- package/dist/client/assets/solarized-light-CjLLwxRp.js +1 -0
- package/dist/client/assets/solarized-light-DFPxpIYQ.js +1 -0
- package/dist/client/assets/stampPlanParts-DVXYCykw.js +15 -0
- package/dist/client/assets/stampPlanParts-ctZzxWdw.css +1 -0
- package/dist/client/assets/stream-tokenizer-C3n8hi1h.js +4 -0
- package/dist/client/assets/synthwave-84-nFMaYfgc.js +1 -0
- package/dist/client/assets/synthwave-84-wQeDKbzQ.js +1 -0
- package/dist/client/assets/textChildren-ZDSs1dod.js +1 -0
- package/dist/client/assets/themes-CdTJhjZf.js +2 -0
- package/dist/client/assets/tokyo-night-D4ZgDiA7.js +1 -0
- package/dist/client/assets/tokyo-night-oM2G3aXe.js +1 -0
- package/dist/client/assets/triangle-alert-C9Sgr3jF.js +1 -0
- package/dist/client/assets/unwrapDefault-ByDmBtHB.js +1 -0
- package/dist/client/assets/utils-C9Glzetk.js +2 -0
- package/dist/client/assets/versionView-zkSROPw7.js +1 -0
- package/dist/client/assets/vesper-DdrHHSXu.js +1 -0
- package/dist/client/assets/vesper-sUHevyKv.js +1 -0
- package/dist/client/assets/vitesse-black-CfklMpOb.js +1 -0
- package/dist/client/assets/vitesse-black-fwtXNY1n.js +1 -0
- package/dist/client/assets/vitesse-dark-BZCL-v6S.js +1 -0
- package/dist/client/assets/vitesse-dark-CJkzwmKT.js +1 -0
- package/dist/client/assets/vitesse-light-BxMp8E1Y.js +1 -0
- package/dist/client/assets/vitesse-light-VbXTXTou.js +1 -0
- package/dist/client/assets/wa-sqlite-Ba70bhIr.wasm +0 -0
- package/dist/client/assets/warmPlans-CYFrLwcX.js +1 -0
- package/dist/client/assets/with-selector-HIcjK0_d.js +1 -0
- package/dist/client/assets/workflowSource-LMsRuqF_.js +3 -0
- package/dist/client/favicon.png +0 -0
- package/dist/client/icons/apple-touch-icon-180x180.png +0 -0
- package/dist/client/icons/favicon.ico +0 -0
- package/dist/client/icons/maskable-icon-192x192.png +0 -0
- package/dist/client/icons/maskable-icon-512x512.png +0 -0
- package/dist/client/icons/pwa-16x16.png +0 -0
- package/dist/client/icons/pwa-192x192.png +0 -0
- package/dist/client/icons/pwa-32x32.png +0 -0
- package/dist/client/icons/pwa-512x512.png +0 -0
- package/dist/client/icons/pwa-64x64.png +0 -0
- package/dist/clientLog.d.ts +5 -0
- package/dist/clientLog.js +64 -0
- package/dist/cloudClient.d.ts +38 -0
- package/dist/cloudClient.js +185 -0
- package/dist/cloudCommand.d.ts +23 -0
- package/dist/cloudCommand.js +159 -0
- package/dist/cloudFrontmatter.d.ts +4 -0
- package/dist/cloudFrontmatter.js +30 -0
- package/dist/cloudStore.d.ts +28 -0
- package/dist/cloudStore.js +70 -0
- package/dist/cloudWatch.d.ts +12 -0
- package/dist/cloudWatch.js +103 -0
- package/dist/commentOrder.d.ts +19 -0
- package/dist/commentOrder.js +26 -0
- package/dist/commentReply.d.ts +25 -0
- package/dist/commentReply.js +17 -0
- package/dist/configHome.d.ts +34 -0
- package/dist/configHome.js +136 -0
- package/dist/dashboard.d.ts +67 -0
- package/dist/dashboard.js +86 -0
- package/dist/dashboardClientScript.d.ts +2 -0
- package/dist/dashboardClientScript.js +1006 -0
- package/dist/dashboardDocument.d.ts +13 -0
- package/dist/dashboardDocument.js +40 -0
- package/dist/dashboardFormat.d.ts +98 -0
- package/dist/dashboardFormat.js +199 -0
- package/dist/dashboardLoading.d.ts +19 -0
- package/dist/dashboardLoading.js +94 -0
- package/dist/dashboardOverview.d.ts +28 -0
- package/dist/dashboardOverview.js +333 -0
- package/dist/dashboardPage.d.ts +2 -0
- package/dist/dashboardPage.js +11 -0
- package/dist/dashboardParts.d.ts +4 -0
- package/dist/dashboardParts.js +367 -0
- package/dist/dashboardSearchView.d.ts +38 -0
- package/dist/dashboardSearchView.js +255 -0
- package/dist/desktopApp.d.ts +23 -0
- package/dist/desktopApp.js +110 -0
- package/dist/desktopBridge.d.ts +21 -0
- package/dist/desktopBridge.js +78 -0
- package/dist/desktopCommand.d.ts +61 -0
- package/dist/desktopCommand.js +172 -0
- package/dist/desktopConfig.d.ts +54 -0
- package/dist/desktopConfig.js +164 -0
- package/dist/desktopNotices.d.ts +105 -0
- package/dist/desktopNotices.js +427 -0
- package/dist/diff.d.ts +2 -0
- package/dist/diff.js +46 -0
- package/dist/diffsTheme.d.ts +51 -0
- package/dist/diffsTheme.js +86 -0
- package/dist/diffsThemeCatalog.d.ts +3 -0
- package/dist/diffsThemeCatalog.js +78 -0
- package/dist/elkRuntime.node.d.ts +7 -0
- package/dist/elkRuntime.node.js +63 -0
- package/dist/execution.d.ts +78 -0
- package/dist/execution.js +139 -0
- package/dist/expectedWorkflow.d.ts +11 -0
- package/dist/expectedWorkflow.js +99 -0
- package/dist/favicon.d.ts +4 -0
- package/dist/favicon.js +40 -0
- package/dist/favicon.png +0 -0
- package/dist/faviconBase64.d.ts +1 -0
- package/dist/faviconBase64.js +1 -0
- package/dist/fileVersion.d.ts +8 -0
- package/dist/fileVersion.js +20 -0
- package/dist/formatBytes.d.ts +2 -0
- package/dist/formatBytes.js +13 -0
- package/dist/gitStatus.d.ts +12 -0
- package/dist/gitStatus.js +88 -0
- package/dist/hostToolbar.d.ts +38 -0
- package/dist/hostToolbar.js +249 -0
- package/dist/http.d.ts +8 -0
- package/dist/http.js +38 -0
- package/dist/httpServer.d.ts +13 -0
- package/dist/httpServer.js +40 -0
- package/dist/icons/apple-touch-icon-180x180.png +0 -0
- package/dist/icons/favicon.ico +0 -0
- package/dist/icons/maskable-icon-192x192.png +0 -0
- package/dist/icons/maskable-icon-512x512.png +0 -0
- package/dist/icons/pwa-16x16.png +0 -0
- package/dist/icons/pwa-192x192.png +0 -0
- package/dist/icons/pwa-32x32.png +0 -0
- package/dist/icons/pwa-512x512.png +0 -0
- package/dist/icons/pwa-64x64.png +0 -0
- package/dist/lanAccess.d.ts +31 -0
- package/dist/lanAccess.js +110 -0
- package/dist/lanAddress.d.ts +24 -0
- package/dist/lanAddress.js +174 -0
- package/dist/lanCommand.d.ts +25 -0
- package/dist/lanCommand.js +159 -0
- package/dist/lanConfig.d.ts +40 -0
- package/dist/lanConfig.js +130 -0
- package/dist/lanFirewall.d.ts +17 -0
- package/dist/lanFirewall.js +221 -0
- package/dist/layoutGraph.d.ts +13 -0
- package/dist/layoutGraph.js +55 -0
- package/dist/localName.d.ts +9 -0
- package/dist/localName.js +28 -0
- package/dist/lockBanner.d.ts +2 -0
- package/dist/lockBanner.js +2 -0
- package/dist/mcp/endpoint.d.ts +20 -0
- package/dist/mcp/endpoint.js +61 -0
- package/dist/mcp/oauthServer.d.ts +33 -0
- package/dist/mcp/oauthServer.js +403 -0
- package/dist/mcp/oauthStore.d.ts +42 -0
- package/dist/mcp/oauthStore.js +138 -0
- package/dist/mcp/planTools.d.ts +27 -0
- package/dist/mcp/planTools.js +230 -0
- package/dist/mdnsPacket.d.ts +44 -0
- package/dist/mdnsPacket.js +384 -0
- package/dist/mdnsPublish.d.ts +12 -0
- package/dist/mdnsPublish.js +290 -0
- package/dist/offlineSync.d.ts +249 -0
- package/dist/offlineSync.js +477 -0
- package/dist/openUrl.d.ts +40 -0
- package/dist/openUrl.js +147 -0
- package/dist/openedPages.d.ts +14 -0
- package/dist/openedPages.js +48 -0
- package/dist/pageEditPull.d.ts +9 -0
- package/dist/pageEditPull.js +29 -0
- package/dist/pageRoutes.d.ts +3 -0
- package/dist/pageRoutes.js +34 -0
- package/dist/parse.d.ts +7 -0
- package/dist/parse.js +100 -0
- package/dist/pid.d.ts +2 -0
- package/dist/pid.js +13 -0
- package/dist/planArchive.d.ts +4 -0
- package/dist/planArchive.js +28 -0
- package/dist/planCheck.d.ts +22 -0
- package/dist/planCheck.js +30 -0
- package/dist/planEntries.d.ts +12 -0
- package/dist/planEntries.js +117 -0
- package/dist/planHost.d.ts +33 -0
- package/dist/planHost.js +290 -0
- package/dist/planId.d.ts +2 -0
- package/dist/planId.js +6 -0
- package/dist/planMdx/blockEdit.d.ts +41 -0
- package/dist/planMdx/blockEdit.js +60 -0
- package/dist/planMdx/cellPart.d.ts +14 -0
- package/dist/planMdx/cellPart.js +26 -0
- package/dist/planMdx/compilePlanMdx.d.ts +3 -0
- package/dist/planMdx/compilePlanMdx.js +22 -0
- package/dist/planMdx/editSource.d.ts +39 -0
- package/dist/planMdx/editSource.js +327 -0
- package/dist/planMdx/frontmatter.d.ts +5 -0
- package/dist/planMdx/frontmatter.js +15 -0
- package/dist/planMdx/markdown.d.ts +6 -0
- package/dist/planMdx/markdown.js +470 -0
- package/dist/planMdx/outline.d.ts +8 -0
- package/dist/planMdx/outline.js +548 -0
- package/dist/planMdx/payload.d.ts +4 -0
- package/dist/planMdx/payload.js +18 -0
- package/dist/planMdx/rebaseDraft.d.ts +54 -0
- package/dist/planMdx/rebaseDraft.js +675 -0
- package/dist/planMdx/recmaPlanComponents.d.ts +18 -0
- package/dist/planMdx/recmaPlanComponents.js +52 -0
- package/dist/planMdx/remarkBlockRanges.d.ts +104 -0
- package/dist/planMdx/remarkBlockRanges.js +275 -0
- package/dist/planMdx/remarkCodeMeta.d.ts +16 -0
- package/dist/planMdx/remarkCodeMeta.js +25 -0
- package/dist/planMdx/remarkGfmTable.d.ts +5 -0
- package/dist/planMdx/remarkGfmTable.js +15 -0
- package/dist/planMdx/remarkGfmTaskList.d.ts +5 -0
- package/dist/planMdx/remarkGfmTaskList.js +15 -0
- package/dist/planMdx/remarkMermaid.d.ts +16 -0
- package/dist/planMdx/remarkMermaid.js +56 -0
- package/dist/planMdx/source.d.ts +11 -0
- package/dist/planMdx/source.js +131 -0
- package/dist/planMdx/titleEdit.d.ts +35 -0
- package/dist/planMdx/titleEdit.js +112 -0
- package/dist/planPage.css +2125 -0
- package/dist/planProgress.d.ts +17 -0
- package/dist/planProgress.js +78 -0
- package/dist/planReady.d.ts +8 -0
- package/dist/planReady.js +20 -0
- package/dist/planRefNavigation.d.ts +4 -0
- package/dist/planRefNavigation.js +8 -0
- package/dist/planRoutes.d.ts +12 -0
- package/dist/planRoutes.js +141 -0
- package/dist/planSearch.d.ts +166 -0
- package/dist/planSearch.js +462 -0
- package/dist/planSession.d.ts +138 -0
- package/dist/planSession.js +1209 -0
- package/dist/planSnapshots.d.ts +34 -0
- package/dist/planSnapshots.js +113 -0
- package/dist/planStatus.d.ts +26 -0
- package/dist/planStatus.js +46 -0
- package/dist/planStepHeading.d.ts +16 -0
- package/dist/planStepHeading.js +34 -0
- package/dist/planTarget.d.ts +16 -0
- package/dist/planTarget.js +92 -0
- package/dist/planToc.d.ts +24 -0
- package/dist/planToc.js +258 -0
- package/dist/planVersionMenu.d.ts +12 -0
- package/dist/planVersionMenu.js +23 -0
- package/dist/processRecord.d.ts +108 -0
- package/dist/processRecord.js +68 -0
- package/dist/processesPanel.d.ts +7 -0
- package/dist/processesPanel.js +636 -0
- package/dist/pwaIconFile.d.ts +2 -0
- package/dist/pwaIconFile.js +42 -0
- package/dist/pwaIcons.d.ts +28 -0
- package/dist/pwaIcons.js +46 -0
- package/dist/registerServiceWorker.d.ts +25 -0
- package/dist/registerServiceWorker.js +26 -0
- package/dist/registryClient.d.ts +94 -0
- package/dist/registryClient.js +490 -0
- package/dist/registryConstants.d.ts +9 -0
- package/dist/registryConstants.js +9 -0
- package/dist/registryLock.d.ts +19 -0
- package/dist/registryLock.js +48 -0
- package/dist/registryPage.d.ts +2 -0
- package/dist/registryPage.js +284 -0
- package/dist/registryService.d.ts +23 -0
- package/dist/registryService.js +618 -0
- package/dist/registryStore.d.ts +63 -0
- package/dist/registryStore.js +398 -0
- package/dist/releaseNotes.d.ts +35 -0
- package/dist/releaseNotes.js +62 -0
- package/dist/render.d.ts +50 -0
- package/dist/render.js +1506 -0
- package/dist/requestGuard.d.ts +21 -0
- package/dist/requestGuard.js +42 -0
- package/dist/reviewRound.d.ts +12 -0
- package/dist/reviewRound.js +19 -0
- package/dist/runFollow.d.ts +28 -0
- package/dist/runFollow.js +33 -0
- package/dist/searchMatch.d.ts +35 -0
- package/dist/searchMatch.js +270 -0
- package/dist/server.d.ts +24 -0
- package/dist/server.js +114 -0
- package/dist/serviceLog.d.ts +56 -0
- package/dist/serviceLog.js +481 -0
- package/dist/shellCache.d.ts +69 -0
- package/dist/shellCache.js +289 -0
- package/dist/shellWorker.js +322 -0
- package/dist/shellWorkerResponse.d.ts +4 -0
- package/dist/shellWorkerResponse.js +15 -0
- package/dist/startServer.d.ts +2 -0
- package/dist/startServer.js +2 -0
- package/dist/store/meta.d.ts +53 -0
- package/dist/store/meta.js +140 -0
- package/dist/store/migrate.d.ts +3 -0
- package/dist/store/migrate.js +408 -0
- package/dist/store/rows.d.ts +4 -0
- package/dist/store/rows.js +100 -0
- package/dist/store/schema.d.ts +5 -0
- package/dist/store/schema.js +5 -0
- package/dist/store/sqlite.d.ts +19 -0
- package/dist/store/sqlite.js +57 -0
- package/dist/store/tables.d.ts +1892 -0
- package/dist/store/tables.js +136 -0
- package/dist/theme.d.ts +174 -0
- package/dist/theme.js +444 -0
- package/dist/themeBootstrap.d.ts +2 -0
- package/dist/themeBootstrap.js +11 -0
- package/dist/tui/DashboardApp.d.ts +19 -0
- package/dist/tui/DashboardApp.js +237 -0
- package/dist/tui/PaletteProvider.d.ts +12 -0
- package/dist/tui/PaletteProvider.js +36 -0
- package/dist/tui/PlanActions.d.ts +7 -0
- package/dist/tui/PlanActions.js +9 -0
- package/dist/tui/PlanCard.d.ts +13 -0
- package/dist/tui/PlanCard.js +31 -0
- package/dist/tui/PlanRow.d.ts +13 -0
- package/dist/tui/PlanRow.js +31 -0
- package/dist/tui/PlanTable.d.ts +13 -0
- package/dist/tui/PlanTable.js +24 -0
- package/dist/tui/ProcessCard.d.ts +9 -0
- package/dist/tui/ProcessCard.js +24 -0
- package/dist/tui/ProcessList.d.ts +9 -0
- package/dist/tui/ProcessList.js +12 -0
- package/dist/tui/SegmentButton.d.ts +7 -0
- package/dist/tui/SegmentButton.js +18 -0
- package/dist/tui/StatCard.d.ts +6 -0
- package/dist/tui/StatCard.js +17 -0
- package/dist/tui/dashboardView.d.ts +45 -0
- package/dist/tui/dashboardView.js +192 -0
- package/dist/tui/openExternal.d.ts +2 -0
- package/dist/tui/openExternal.js +5 -0
- package/dist/tui/palette.d.ts +27 -0
- package/dist/tui/palette.js +66 -0
- package/dist/tui/planColumns.d.ts +38 -0
- package/dist/tui/planColumns.js +14 -0
- package/dist/tui/readDashboard.d.ts +3 -0
- package/dist/tui/readDashboard.js +15 -0
- package/dist/tui/readProcesses.d.ts +3 -0
- package/dist/tui/readProcesses.js +23 -0
- package/dist/tui/registryView.d.ts +11 -0
- package/dist/tui/registryView.js +56 -0
- package/dist/tui/runTui.d.ts +21 -0
- package/dist/tui/runTui.js +86 -0
- package/dist/tui/systemTheme.d.ts +28 -0
- package/dist/tui/systemTheme.js +141 -0
- package/dist/types.d.ts +191 -0
- package/dist/types.js +0 -0
- package/dist/webManifest.d.ts +39 -0
- package/dist/webManifest.js +48 -0
- package/dist/workflow.d.ts +8 -0
- package/dist/workflow.js +42 -0
- package/dist/workflowLayoutShared.d.ts +25 -0
- package/dist/workflowLayoutShared.js +33 -0
- package/dist/workflowSource.d.ts +31 -0
- package/dist/workflowSource.js +90 -0
- package/docs/changelogs/changelog-2026-10-27.md +203 -0
- package/docs/changelogs/changelog-2026-10-28.md +181 -0
- package/docs/changelogs/changelog-2026-10-29.md +349 -0
- package/docs/changelogs/changelog-2026-10-30.md +303 -0
- package/docs/changelogs/changelog-2026-10-31.md +129 -0
- package/docs/changelogs/changelog-2026-11-01.md +155 -0
- package/docs/changelogs/changelog-2026-11-02.md +195 -0
- package/docs/changelogs/changelog-2026-11-03.md +209 -0
- package/docs/changelogs/changelog-2026-11-04.md +243 -0
- package/docs/changelogs/changelog-2026-11-05.md +172 -0
- package/docs/changelogs/changelog-2026-11-06.md +123 -0
- package/docs/changelogs/changelog-2026-11-07.md +138 -0
- package/docs/changelogs/changelog-2026-11-08.md +47 -0
- package/docs/changelogs/changelog-2026-11-10.md +219 -0
- package/docs/changelogs/changelog-2026-11-11.md +205 -0
- package/docs/changelogs/changelog-2026-11-12.md +44 -0
- package/docs/changelogs/changelog-2026-11-13.md +48 -0
- package/docs/changelogs/changelog-2026-11-14.md +116 -0
- package/docs/changelogs/changelog-2026-11-15.md +31 -0
- package/docs/changelogs/changelog-2026-11-16.md +41 -0
- package/docs/changelogs/changelog-2026-11-17.md +25 -0
- package/docs/changelogs/changelog-2026-11-18.md +71 -0
- package/docs/changelogs/changelog-2026-11-19.md +19 -0
- package/docs/changelogs/changelog-2026-11-20.md +23 -0
- package/docs/changelogs/changelog-2026-12-02.md +22 -0
- package/examples/cloud-showcase.plan.md +181 -0
- package/examples/component-showcase.plan.md +378 -0
- package/examples/component-tour.plan.md +168 -0
- package/examples/data-table.plan.md +917 -0
- package/examples/execution-graph.json +15 -5
- package/examples/form-controls.plan.md +51 -0
- package/examples/live-plan.config.json +5 -0
- package/examples/rate-limit.plan.md +110 -78
- package/examples/submission-delivery-runbook.md +122 -0
- package/examples/submission-delivery.plan.md +107 -0
- package/examples/tables.plan.md +61 -0
- package/package.json +90 -16
- package/skills/live-plan/SKILL.md +396 -0
- package/skills/live-plan/primitives.md +738 -0
- package/skills/living-plan/SKILL.md +0 -71
|
@@ -0,0 +1,548 @@
|
|
|
1
|
+
import { renderPlanMarkdown } from './markdown';
|
|
2
|
+
import { calloutKind, phaseStatus, slugify } from './payload';
|
|
3
|
+
import { parseWorkflowSource } from '../workflowSource';
|
|
4
|
+
const ENTRY_NAMES = new Set([
|
|
5
|
+
'phase',
|
|
6
|
+
'callout',
|
|
7
|
+
'choice',
|
|
8
|
+
'option',
|
|
9
|
+
'form',
|
|
10
|
+
'field',
|
|
11
|
+
'questions',
|
|
12
|
+
'item',
|
|
13
|
+
'approve',
|
|
14
|
+
'checklist',
|
|
15
|
+
'workflow',
|
|
16
|
+
]);
|
|
17
|
+
const LAYOUT_NAMES = new Set([
|
|
18
|
+
'Box',
|
|
19
|
+
'HStack',
|
|
20
|
+
'VStack',
|
|
21
|
+
'Stack',
|
|
22
|
+
'Row',
|
|
23
|
+
'ResponsiveStack',
|
|
24
|
+
'box',
|
|
25
|
+
'hstack',
|
|
26
|
+
'vstack',
|
|
27
|
+
'stack',
|
|
28
|
+
'row',
|
|
29
|
+
]);
|
|
30
|
+
const EMBED_NAMES = new Set([
|
|
31
|
+
'Mermaid',
|
|
32
|
+
'BarChart',
|
|
33
|
+
'LineChart',
|
|
34
|
+
'DataTable',
|
|
35
|
+
'Column',
|
|
36
|
+
'Row',
|
|
37
|
+
'Cell',
|
|
38
|
+
'Chip',
|
|
39
|
+
'chip',
|
|
40
|
+
'Pill',
|
|
41
|
+
'pill',
|
|
42
|
+
'Checkbox',
|
|
43
|
+
// Document blocks (ADR 0039, client/mdx/docBlocks.tsx). Their text joins the outline as markdown.
|
|
44
|
+
'FileTree',
|
|
45
|
+
'File',
|
|
46
|
+
'Endpoint',
|
|
47
|
+
'Param',
|
|
48
|
+
'Request',
|
|
49
|
+
'Response',
|
|
50
|
+
'DataModel',
|
|
51
|
+
'Entity',
|
|
52
|
+
'Attr',
|
|
53
|
+
'Relation',
|
|
54
|
+
'JsonView',
|
|
55
|
+
'AnnotatedCode',
|
|
56
|
+
'Note',
|
|
57
|
+
'Tabs',
|
|
58
|
+
'Tab',
|
|
59
|
+
'Compare',
|
|
60
|
+
'Pane',
|
|
61
|
+
'Update',
|
|
62
|
+
'Properties',
|
|
63
|
+
'Prop',
|
|
64
|
+
'Path',
|
|
65
|
+
]);
|
|
66
|
+
const KNOWN = new Set([...ENTRY_NAMES, ...LAYOUT_NAMES, ...EMBED_NAMES]);
|
|
67
|
+
const INTERACTION = new Set(['choice', 'approve', 'form', 'questions']);
|
|
68
|
+
const LEGACY_MESSAGE = 'Plan entries are MDX components such as <phase> and <choice>. {% tags %} and ```phase fences are not plan entries. A workflow graph is a structured body inside <workflow>.';
|
|
69
|
+
/** {% tags %} and entry fences are not the authoring contract. A ```workflow fence may stay inside <workflow>. */
|
|
70
|
+
export function legacyPlanSyntaxError(source) {
|
|
71
|
+
if (/\{%\s*(?:phase|choice|approve|form|questions|checklist|callout|workflow|option|item|field|status)\b/.test(source)) {
|
|
72
|
+
return LEGACY_MESSAGE;
|
|
73
|
+
}
|
|
74
|
+
if (/^```(?:phase|choice|approve|form|questions|checklist|callout)\b/m.test(source))
|
|
75
|
+
return LEGACY_MESSAGE;
|
|
76
|
+
if (hasTopLevelWorkflowFence(source))
|
|
77
|
+
return LEGACY_MESSAGE;
|
|
78
|
+
return undefined;
|
|
79
|
+
}
|
|
80
|
+
export function buildMdxOutline(body) {
|
|
81
|
+
const chunks = flatten(parseNodes(body));
|
|
82
|
+
const blocks = [];
|
|
83
|
+
const entries = [];
|
|
84
|
+
for (const chunk of chunks) {
|
|
85
|
+
const index = blocks.length;
|
|
86
|
+
if (chunk.kind === 'md') {
|
|
87
|
+
const text = chunk.text.trim();
|
|
88
|
+
blocks.push({
|
|
89
|
+
type: 'markdown',
|
|
90
|
+
html: markdownHtml(text, `markdown:${index}`),
|
|
91
|
+
source: text,
|
|
92
|
+
});
|
|
93
|
+
continue;
|
|
94
|
+
}
|
|
95
|
+
const built = blockFrom(chunk.node, index);
|
|
96
|
+
blocks.push(built.block);
|
|
97
|
+
entries.push(...built.entries);
|
|
98
|
+
}
|
|
99
|
+
return {
|
|
100
|
+
blocks,
|
|
101
|
+
entries,
|
|
102
|
+
interactionIds: entries.flatMap((entry) => (entry.id && INTERACTION.has(entry.type) ? [entry.id] : [])),
|
|
103
|
+
};
|
|
104
|
+
}
|
|
105
|
+
function hasTopLevelWorkflowFence(source) {
|
|
106
|
+
let depth = 0;
|
|
107
|
+
let index = 0;
|
|
108
|
+
while (index < source.length) {
|
|
109
|
+
const rest = source.slice(index);
|
|
110
|
+
const nextFence = /^```workflow\b/m.exec(rest);
|
|
111
|
+
const nextOpen = /<workflow\b[^>]*>/.exec(rest);
|
|
112
|
+
const nextClose = /<\/workflow\s*>/.exec(rest);
|
|
113
|
+
const fenceAt = nextFence ? index + nextFence.index : Number.POSITIVE_INFINITY;
|
|
114
|
+
const openAt = nextOpen ? index + nextOpen.index : Number.POSITIVE_INFINITY;
|
|
115
|
+
const closeAt = nextClose ? index + nextClose.index : Number.POSITIVE_INFINITY;
|
|
116
|
+
const next = Math.min(fenceAt, openAt, closeAt);
|
|
117
|
+
if (!Number.isFinite(next))
|
|
118
|
+
return false;
|
|
119
|
+
if (next === fenceAt) {
|
|
120
|
+
if (depth === 0)
|
|
121
|
+
return true;
|
|
122
|
+
index = fenceAt + (nextFence?.[0].length ?? 0);
|
|
123
|
+
continue;
|
|
124
|
+
}
|
|
125
|
+
if (next === openAt) {
|
|
126
|
+
depth += 1;
|
|
127
|
+
index = openAt + (nextOpen?.[0].length ?? 0);
|
|
128
|
+
continue;
|
|
129
|
+
}
|
|
130
|
+
depth = Math.max(0, depth - 1);
|
|
131
|
+
index = closeAt + (nextClose?.[0].length ?? 0);
|
|
132
|
+
}
|
|
133
|
+
return false;
|
|
134
|
+
}
|
|
135
|
+
function parseNodes(source) {
|
|
136
|
+
const nodes = [];
|
|
137
|
+
let text = '';
|
|
138
|
+
let index = 0;
|
|
139
|
+
const flush = () => {
|
|
140
|
+
if (!text)
|
|
141
|
+
return;
|
|
142
|
+
nodes.push(text);
|
|
143
|
+
text = '';
|
|
144
|
+
};
|
|
145
|
+
while (index < source.length) {
|
|
146
|
+
if (source.startsWith('```', index)) {
|
|
147
|
+
const end = source.indexOf('```', index + 3);
|
|
148
|
+
const close = end < 0 ? source.length : end + 3;
|
|
149
|
+
text += source.slice(index, close);
|
|
150
|
+
index = close;
|
|
151
|
+
continue;
|
|
152
|
+
}
|
|
153
|
+
if (source[index] === '<') {
|
|
154
|
+
const tag = readTag(source, index);
|
|
155
|
+
if (tag && KNOWN.has(tag.name)) {
|
|
156
|
+
flush();
|
|
157
|
+
if (tag.selfClosing) {
|
|
158
|
+
nodes.push({
|
|
159
|
+
name: tag.name,
|
|
160
|
+
kind: kindOf(tag.name),
|
|
161
|
+
attrs: tag.attrs,
|
|
162
|
+
children: [],
|
|
163
|
+
source: source.slice(index, tag.end),
|
|
164
|
+
});
|
|
165
|
+
index = tag.end;
|
|
166
|
+
continue;
|
|
167
|
+
}
|
|
168
|
+
const close = findClose(source, tag.end, tag.name);
|
|
169
|
+
if (!close) {
|
|
170
|
+
text += source[index];
|
|
171
|
+
index += 1;
|
|
172
|
+
continue;
|
|
173
|
+
}
|
|
174
|
+
nodes.push({
|
|
175
|
+
name: tag.name,
|
|
176
|
+
kind: kindOf(tag.name),
|
|
177
|
+
attrs: tag.attrs,
|
|
178
|
+
children: parseNodes(source.slice(tag.end, close.start)),
|
|
179
|
+
source: source.slice(index, close.end),
|
|
180
|
+
});
|
|
181
|
+
index = close.end;
|
|
182
|
+
continue;
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
text += source[index];
|
|
186
|
+
index += 1;
|
|
187
|
+
}
|
|
188
|
+
flush();
|
|
189
|
+
return nodes;
|
|
190
|
+
}
|
|
191
|
+
function flatten(nodes) {
|
|
192
|
+
const chunks = [];
|
|
193
|
+
let text = '';
|
|
194
|
+
const flush = () => {
|
|
195
|
+
if (text.trim())
|
|
196
|
+
chunks.push({ kind: 'md', text });
|
|
197
|
+
text = '';
|
|
198
|
+
};
|
|
199
|
+
for (const node of nodes) {
|
|
200
|
+
if (typeof node === 'string') {
|
|
201
|
+
text += node;
|
|
202
|
+
continue;
|
|
203
|
+
}
|
|
204
|
+
if (node.kind !== 'entry') {
|
|
205
|
+
flush();
|
|
206
|
+
chunks.push(...flatten(node.children));
|
|
207
|
+
continue;
|
|
208
|
+
}
|
|
209
|
+
flush();
|
|
210
|
+
chunks.push({ kind: 'entry', node });
|
|
211
|
+
}
|
|
212
|
+
flush();
|
|
213
|
+
return chunks;
|
|
214
|
+
}
|
|
215
|
+
function blockFrom(node, index) {
|
|
216
|
+
const entries = [];
|
|
217
|
+
collectEntries(node, entries, index);
|
|
218
|
+
return { block: toBlock(node, index), entries };
|
|
219
|
+
}
|
|
220
|
+
function collectEntries(node, entries, index) {
|
|
221
|
+
if (node.kind !== 'entry' || node.name === 'option' || node.name === 'field' || node.name === 'item') {
|
|
222
|
+
for (const child of node.children) {
|
|
223
|
+
if (typeof child !== 'string')
|
|
224
|
+
collectEntries(child, entries, index);
|
|
225
|
+
}
|
|
226
|
+
return;
|
|
227
|
+
}
|
|
228
|
+
entries.push(toEntry(node, index));
|
|
229
|
+
for (const child of node.children) {
|
|
230
|
+
if (typeof child !== 'string')
|
|
231
|
+
collectEntries(child, entries, index);
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
function toBlock(node, index) {
|
|
235
|
+
const name = node.name;
|
|
236
|
+
if (name === 'phase') {
|
|
237
|
+
const title = str(node.attrs.title) || 'Untitled phase';
|
|
238
|
+
const id = str(node.attrs.id) || slugify(title) || 'phase';
|
|
239
|
+
return {
|
|
240
|
+
type: 'phase',
|
|
241
|
+
id,
|
|
242
|
+
title,
|
|
243
|
+
status: phaseStatus(node.attrs.status),
|
|
244
|
+
bodyHtml: markdownHtml(entryMarkdown(node.children), `phase:${id}`),
|
|
245
|
+
source: node.source,
|
|
246
|
+
};
|
|
247
|
+
}
|
|
248
|
+
if (name === 'callout') {
|
|
249
|
+
const title = str(node.attrs.title) || undefined;
|
|
250
|
+
const id = str(node.attrs.id) || undefined;
|
|
251
|
+
return {
|
|
252
|
+
type: 'callout',
|
|
253
|
+
id,
|
|
254
|
+
kind: calloutKind(node.attrs.kind),
|
|
255
|
+
title,
|
|
256
|
+
bodyHtml: markdownHtml(entryMarkdown(node.children), `callout:${id ?? index}`),
|
|
257
|
+
source: node.source,
|
|
258
|
+
};
|
|
259
|
+
}
|
|
260
|
+
if (name === 'choice') {
|
|
261
|
+
const prompt = str(node.attrs.prompt) || 'Choose one';
|
|
262
|
+
const id = str(node.attrs.id) || slugify(prompt) || 'choice';
|
|
263
|
+
return { type: 'choice', id, prompt, options: optionsOf(node), source: node.source };
|
|
264
|
+
}
|
|
265
|
+
if (name === 'approve') {
|
|
266
|
+
const prompt = str(node.attrs.prompt) || 'Approve this step?';
|
|
267
|
+
const id = str(node.attrs.id) || slugify(prompt) || 'approve';
|
|
268
|
+
return {
|
|
269
|
+
type: 'approve',
|
|
270
|
+
id,
|
|
271
|
+
prompt,
|
|
272
|
+
bodyHtml: markdownHtml(entryMarkdown(node.children), `approve:${id}`),
|
|
273
|
+
source: node.source,
|
|
274
|
+
};
|
|
275
|
+
}
|
|
276
|
+
if (name === 'form') {
|
|
277
|
+
const prompt = str(node.attrs.prompt) || 'Provide details';
|
|
278
|
+
const id = str(node.attrs.id) || slugify(prompt) || 'form';
|
|
279
|
+
return { type: 'form', id, prompt, fields: fieldsOf(node), source: node.source };
|
|
280
|
+
}
|
|
281
|
+
if (name === 'questions') {
|
|
282
|
+
const prompt = str(node.attrs.prompt) || undefined;
|
|
283
|
+
const id = str(node.attrs.id) || slugify(prompt ?? 'questions') || 'questions';
|
|
284
|
+
return { type: 'questions', id, prompt, items: questionItems(node), source: node.source };
|
|
285
|
+
}
|
|
286
|
+
if (name === 'checklist') {
|
|
287
|
+
const title = str(node.attrs.title) || undefined;
|
|
288
|
+
const id = str(node.attrs.id) || undefined;
|
|
289
|
+
return { type: 'checklist', id, title, items: checklistItems(node), source: node.source };
|
|
290
|
+
}
|
|
291
|
+
const title = str(node.attrs.title) || undefined;
|
|
292
|
+
const id = str(node.attrs.id) || slugify(title ?? 'workflow') || 'workflow';
|
|
293
|
+
const graph = workflowOf(node);
|
|
294
|
+
return { type: 'workflow', id, title, nodes: graph.nodes, edges: graph.edges, source: node.source };
|
|
295
|
+
}
|
|
296
|
+
function toEntry(node, index) {
|
|
297
|
+
const block = toBlock(node, index);
|
|
298
|
+
if (block.type === 'markdown')
|
|
299
|
+
return { type: 'markdown' };
|
|
300
|
+
if (block.type === 'phase') {
|
|
301
|
+
return { type: 'phase', id: block.id, title: block.title, status: block.status, anchor: block.id };
|
|
302
|
+
}
|
|
303
|
+
if (block.type === 'callout') {
|
|
304
|
+
return { type: 'callout', id: block.id, title: block.title, kind: block.kind, anchor: block.id };
|
|
305
|
+
}
|
|
306
|
+
if (block.type === 'choice')
|
|
307
|
+
return { type: 'choice', id: block.id, prompt: block.prompt, anchor: block.id };
|
|
308
|
+
if (block.type === 'approve')
|
|
309
|
+
return { type: 'approve', id: block.id, prompt: block.prompt, anchor: block.id };
|
|
310
|
+
if (block.type === 'form')
|
|
311
|
+
return { type: 'form', id: block.id, prompt: block.prompt, anchor: block.id };
|
|
312
|
+
if (block.type === 'questions')
|
|
313
|
+
return { type: 'questions', id: block.id, prompt: block.prompt, anchor: block.id };
|
|
314
|
+
if (block.type === 'checklist') {
|
|
315
|
+
return { type: 'checklist', id: block.id, title: block.title, anchor: block.id };
|
|
316
|
+
}
|
|
317
|
+
return {
|
|
318
|
+
type: 'workflow',
|
|
319
|
+
id: block.id,
|
|
320
|
+
title: block.title,
|
|
321
|
+
nodes: block.nodes,
|
|
322
|
+
edges: block.edges,
|
|
323
|
+
anchor: block.id,
|
|
324
|
+
};
|
|
325
|
+
}
|
|
326
|
+
function optionsOf(node) {
|
|
327
|
+
const options = [];
|
|
328
|
+
visit(node.children, (child) => {
|
|
329
|
+
if (child.name !== 'option')
|
|
330
|
+
return;
|
|
331
|
+
const id = str(child.attrs.id);
|
|
332
|
+
const label = str(child.attrs.label);
|
|
333
|
+
if (!id || !label)
|
|
334
|
+
return;
|
|
335
|
+
const description = textOf(child.children).trim();
|
|
336
|
+
options.push({ id, label, ...(description ? { description } : {}) });
|
|
337
|
+
});
|
|
338
|
+
return options;
|
|
339
|
+
}
|
|
340
|
+
function fieldsOf(node) {
|
|
341
|
+
const fields = [];
|
|
342
|
+
visit(node.children, (child) => {
|
|
343
|
+
if (child.name !== 'field')
|
|
344
|
+
return;
|
|
345
|
+
const name = str(child.attrs.name);
|
|
346
|
+
const label = str(child.attrs.label);
|
|
347
|
+
if (!name || !label)
|
|
348
|
+
return;
|
|
349
|
+
const type = fieldType(str(child.attrs.type));
|
|
350
|
+
const required = child.attrs.required === true || child.attrs.required === 'true' || child.attrs.required === '';
|
|
351
|
+
let fallback = child.attrs.default;
|
|
352
|
+
if ((type === 'number' || type === 'stepper') && (typeof fallback === 'string' || typeof fallback === 'number')) {
|
|
353
|
+
const numeric = typeof fallback === 'number' ? fallback : Number(fallback);
|
|
354
|
+
if (fallback !== '' && Number.isFinite(numeric))
|
|
355
|
+
fallback = numeric;
|
|
356
|
+
}
|
|
357
|
+
const options = typeof child.attrs.options === 'string'
|
|
358
|
+
? child.attrs.options
|
|
359
|
+
.split(',')
|
|
360
|
+
.map((option) => option.trim())
|
|
361
|
+
.filter(Boolean)
|
|
362
|
+
: undefined;
|
|
363
|
+
const placeholder = str(child.attrs.placeholder);
|
|
364
|
+
const min = numericAttr(child.attrs.min);
|
|
365
|
+
const max = numericAttr(child.attrs.max);
|
|
366
|
+
const step = numericAttr(child.attrs.step);
|
|
367
|
+
fields.push({
|
|
368
|
+
name,
|
|
369
|
+
label,
|
|
370
|
+
type,
|
|
371
|
+
...(required ? { required: true } : {}),
|
|
372
|
+
...(fallback !== undefined && fallback !== '' ? { default: fallback } : {}),
|
|
373
|
+
...(options && options.length > 0 ? { options } : {}),
|
|
374
|
+
...(placeholder ? { placeholder } : {}),
|
|
375
|
+
...(min !== undefined ? { min } : {}),
|
|
376
|
+
...(max !== undefined ? { max } : {}),
|
|
377
|
+
...(step !== undefined ? { step } : {}),
|
|
378
|
+
});
|
|
379
|
+
});
|
|
380
|
+
return fields;
|
|
381
|
+
}
|
|
382
|
+
function questionItems(node) {
|
|
383
|
+
const items = [];
|
|
384
|
+
visit(node.children, (child) => {
|
|
385
|
+
if (child.name !== 'item')
|
|
386
|
+
return;
|
|
387
|
+
const text = textOf(child.children).trim();
|
|
388
|
+
if (text)
|
|
389
|
+
items.push(text);
|
|
390
|
+
});
|
|
391
|
+
return items;
|
|
392
|
+
}
|
|
393
|
+
function checklistItems(node) {
|
|
394
|
+
const items = [];
|
|
395
|
+
visit(node.children, (child) => {
|
|
396
|
+
if (child.name !== 'item')
|
|
397
|
+
return;
|
|
398
|
+
const text = textOf(child.children).trim();
|
|
399
|
+
if (!text)
|
|
400
|
+
return;
|
|
401
|
+
const status = str(child.attrs.status).toLowerCase();
|
|
402
|
+
const done = status ? status === 'done' : child.attrs.done === true || child.attrs.done === 'true';
|
|
403
|
+
items.push({ text, done, ...(status ? { status } : {}) });
|
|
404
|
+
});
|
|
405
|
+
return items;
|
|
406
|
+
}
|
|
407
|
+
function workflowOf(node) {
|
|
408
|
+
return parseWorkflowSource(textOf(node.children));
|
|
409
|
+
}
|
|
410
|
+
function visit(nodes, fn) {
|
|
411
|
+
for (const node of nodes) {
|
|
412
|
+
if (typeof node === 'string')
|
|
413
|
+
continue;
|
|
414
|
+
fn(node);
|
|
415
|
+
if (node.kind !== 'entry' || node.name === 'option' || node.name === 'field' || node.name === 'item') {
|
|
416
|
+
visit(node.children, fn);
|
|
417
|
+
}
|
|
418
|
+
}
|
|
419
|
+
}
|
|
420
|
+
function entryMarkdown(nodes) {
|
|
421
|
+
let text = '';
|
|
422
|
+
for (const node of nodes) {
|
|
423
|
+
if (typeof node === 'string')
|
|
424
|
+
text += node;
|
|
425
|
+
else if (node.kind !== 'entry')
|
|
426
|
+
text += entryMarkdown(node.children);
|
|
427
|
+
}
|
|
428
|
+
return text.trim();
|
|
429
|
+
}
|
|
430
|
+
function textOf(nodes) {
|
|
431
|
+
return nodes.map((node) => (typeof node === 'string' ? node : textOf(node.children))).join('');
|
|
432
|
+
}
|
|
433
|
+
function markdownHtml(markdown, scope) {
|
|
434
|
+
const trimmed = markdown.trim();
|
|
435
|
+
if (!trimmed)
|
|
436
|
+
return '';
|
|
437
|
+
return renderPlanMarkdown(trimmed, scope);
|
|
438
|
+
}
|
|
439
|
+
function kindOf(name) {
|
|
440
|
+
if (ENTRY_NAMES.has(name))
|
|
441
|
+
return 'entry';
|
|
442
|
+
if (LAYOUT_NAMES.has(name))
|
|
443
|
+
return 'layout';
|
|
444
|
+
return 'embed';
|
|
445
|
+
}
|
|
446
|
+
function readTag(source, at) {
|
|
447
|
+
const match = /^<([A-Za-z][\w]*)\b([^>]*)>/.exec(source.slice(at));
|
|
448
|
+
if (!match)
|
|
449
|
+
return null;
|
|
450
|
+
const name = match[1] ?? '';
|
|
451
|
+
let raw = match[2] ?? '';
|
|
452
|
+
const selfClosing = /\/\s*$/.test(raw);
|
|
453
|
+
if (selfClosing)
|
|
454
|
+
raw = raw.replace(/\/\s*$/, '');
|
|
455
|
+
return { name, attrs: parseAttrs(raw), end: at + match[0].length, selfClosing };
|
|
456
|
+
}
|
|
457
|
+
function findClose(source, from, name) {
|
|
458
|
+
let depth = 1;
|
|
459
|
+
let index = from;
|
|
460
|
+
const openRe = new RegExp(`<${name}\\b[^>]*>`, 'g');
|
|
461
|
+
const closeRe = new RegExp(`</${name}\\s*>`, 'g');
|
|
462
|
+
while (index < source.length) {
|
|
463
|
+
const fence = source.indexOf('```', index);
|
|
464
|
+
openRe.lastIndex = index;
|
|
465
|
+
closeRe.lastIndex = index;
|
|
466
|
+
const nextOpen = openRe.exec(source);
|
|
467
|
+
const nextClose = closeRe.exec(source);
|
|
468
|
+
if (!nextClose)
|
|
469
|
+
return null;
|
|
470
|
+
const openAt = nextOpen?.index ?? Infinity;
|
|
471
|
+
const closeAt = nextClose.index;
|
|
472
|
+
if (fence >= index && fence < openAt && fence < closeAt) {
|
|
473
|
+
const end = source.indexOf('```', fence + 3);
|
|
474
|
+
index = end < 0 ? source.length : end + 3;
|
|
475
|
+
continue;
|
|
476
|
+
}
|
|
477
|
+
if (nextOpen && openAt < closeAt) {
|
|
478
|
+
if (!nextOpen[0].endsWith('/>'))
|
|
479
|
+
depth += 1;
|
|
480
|
+
index = openAt + nextOpen[0].length;
|
|
481
|
+
continue;
|
|
482
|
+
}
|
|
483
|
+
depth -= 1;
|
|
484
|
+
if (depth === 0)
|
|
485
|
+
return { start: closeAt, end: closeAt + nextClose[0].length };
|
|
486
|
+
index = closeAt + nextClose[0].length;
|
|
487
|
+
}
|
|
488
|
+
return null;
|
|
489
|
+
}
|
|
490
|
+
function parseAttrs(raw) {
|
|
491
|
+
const attrs = {};
|
|
492
|
+
for (const match of raw.matchAll(/([A-Za-z_][\w:-]*)(?:\s*=\s*(?:"([^"]*)"|'([^']*)'|\{([^}]*)\}|([^\s"'=/>]+)))?/g)) {
|
|
493
|
+
const key = match[1];
|
|
494
|
+
if (!key)
|
|
495
|
+
continue;
|
|
496
|
+
if (match[2] !== undefined)
|
|
497
|
+
attrs[key] = match[2];
|
|
498
|
+
else if (match[3] !== undefined)
|
|
499
|
+
attrs[key] = match[3];
|
|
500
|
+
else if (match[4] !== undefined)
|
|
501
|
+
attrs[key] = parseExpr(match[4].trim());
|
|
502
|
+
else if (match[5] !== undefined)
|
|
503
|
+
attrs[key] = match[5];
|
|
504
|
+
else
|
|
505
|
+
attrs[key] = true;
|
|
506
|
+
}
|
|
507
|
+
return attrs;
|
|
508
|
+
}
|
|
509
|
+
function parseExpr(value) {
|
|
510
|
+
if (value === 'true')
|
|
511
|
+
return true;
|
|
512
|
+
if (value === 'false')
|
|
513
|
+
return false;
|
|
514
|
+
if (/^-?\d+(?:\.\d+)?$/.test(value))
|
|
515
|
+
return Number(value);
|
|
516
|
+
const quoted = /^["']([\s\S]*)["']$/.exec(value);
|
|
517
|
+
if (quoted)
|
|
518
|
+
return quoted[1] ?? '';
|
|
519
|
+
return value;
|
|
520
|
+
}
|
|
521
|
+
function fieldType(value) {
|
|
522
|
+
if (value === 'number' ||
|
|
523
|
+
value === 'textarea' ||
|
|
524
|
+
value === 'select' ||
|
|
525
|
+
value === 'checkbox' ||
|
|
526
|
+
value === 'stepper' ||
|
|
527
|
+
value === 'text') {
|
|
528
|
+
return value;
|
|
529
|
+
}
|
|
530
|
+
return 'text';
|
|
531
|
+
}
|
|
532
|
+
function numericAttr(value) {
|
|
533
|
+
if (typeof value === 'number' && Number.isFinite(value))
|
|
534
|
+
return value;
|
|
535
|
+
if (typeof value === 'string' && value.trim() !== '') {
|
|
536
|
+
const numeric = Number(value);
|
|
537
|
+
if (Number.isFinite(numeric))
|
|
538
|
+
return numeric;
|
|
539
|
+
}
|
|
540
|
+
return undefined;
|
|
541
|
+
}
|
|
542
|
+
function str(value) {
|
|
543
|
+
if (typeof value === 'string')
|
|
544
|
+
return value.trim();
|
|
545
|
+
if (typeof value === 'number' && Number.isFinite(value))
|
|
546
|
+
return String(value);
|
|
547
|
+
return '';
|
|
548
|
+
}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { PhaseStatus } from '../types';
|
|
2
|
+
export declare function slugify(value: string): string;
|
|
3
|
+
export declare function phaseStatus(value: unknown): PhaseStatus;
|
|
4
|
+
export declare function calloutKind(value: unknown): 'note' | 'tip' | 'risk' | 'decision' | 'warning';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
const PHASE_STATUSES = ['pending', 'active', 'blocked', 'done', 'failed'];
|
|
2
|
+
export function slugify(value) {
|
|
3
|
+
return value
|
|
4
|
+
.toLowerCase()
|
|
5
|
+
.replace(/[^a-z0-9]+/g, '-')
|
|
6
|
+
.replace(/^-|-$/g, '')
|
|
7
|
+
.slice(0, 48);
|
|
8
|
+
}
|
|
9
|
+
export function phaseStatus(value) {
|
|
10
|
+
const status = String(value ?? 'pending');
|
|
11
|
+
return PHASE_STATUSES.includes(status) ? status : 'pending';
|
|
12
|
+
}
|
|
13
|
+
export function calloutKind(value) {
|
|
14
|
+
const kind = String(value ?? 'note');
|
|
15
|
+
if (kind === 'tip' || kind === 'risk' || kind === 'decision' || kind === 'warning')
|
|
16
|
+
return kind;
|
|
17
|
+
return 'note';
|
|
18
|
+
}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Bring a person's unapplied block edits onto a plan the agent wrote meanwhile (ADR 0040).
|
|
3
|
+
*
|
|
4
|
+
* A three-way merge by block, at the grain the page edits by: the plan's top-level blocks, and
|
|
5
|
+
* the blocks directly inside a `<phase>`. `base` is the plan the edits started from, `mine` is
|
|
6
|
+
* that plan with the edits, and `theirs` is the plan the agent wrote since. The result is
|
|
7
|
+
* `theirs` with the person's edits on top; every byte of `theirs` they do not touch stays as written.
|
|
8
|
+
*/
|
|
9
|
+
export type DraftSide = 'mine' | 'theirs';
|
|
10
|
+
/** A block both sides changed, each in its own way. The merged source keeps the agent's. */
|
|
11
|
+
export type DraftConflict = {
|
|
12
|
+
/** Names this block for `keep`. The same base and mine give the same key whatever the agent writes. */
|
|
13
|
+
key: string;
|
|
14
|
+
/** The block's heading text, card title, or first line. */
|
|
15
|
+
label: string;
|
|
16
|
+
/** The phase the block sits in, when it is inside one. */
|
|
17
|
+
within?: string;
|
|
18
|
+
/** The block's text in the person's version, or '' when they removed it. */
|
|
19
|
+
mine: string;
|
|
20
|
+
/** The block's text in the agent's version, or '' when the agent removed it. */
|
|
21
|
+
theirs: string;
|
|
22
|
+
/** A short plain-text line of the person's version, for the Apply bar. */
|
|
23
|
+
minePreview: string;
|
|
24
|
+
};
|
|
25
|
+
export type RebaseInput = {
|
|
26
|
+
base: string;
|
|
27
|
+
mine: string;
|
|
28
|
+
theirs: string;
|
|
29
|
+
/** The side to keep for a conflict, by its key. A conflict with no choice keeps the agent's. */
|
|
30
|
+
keep?: Readonly<Record<string, DraftSide>>;
|
|
31
|
+
};
|
|
32
|
+
export type RebaseResult = {
|
|
33
|
+
source: string;
|
|
34
|
+
/** The overlapping blocks `keep` does not settle. */
|
|
35
|
+
conflicts: DraftConflict[];
|
|
36
|
+
};
|
|
37
|
+
/**
|
|
38
|
+
* The person's edits (`mine` against `base`) on top of the agent's plan (`theirs`).
|
|
39
|
+
*
|
|
40
|
+
* - A block the person did not change takes theirs.
|
|
41
|
+
* - A block the person changed that the agent did not change takes the person's.
|
|
42
|
+
* - A block the person added goes after the block before it, in theirs; when the agent removed that
|
|
43
|
+
* one, after the nearest block before it that theirs still has, or first when there is none.
|
|
44
|
+
* - A block the person removed that the agent did not change is removed.
|
|
45
|
+
* - A block both changed, each in its own way, is a conflict: the source keeps theirs and the
|
|
46
|
+
* conflict carries both texts, until `keep` picks a side. The same change on both sides is no conflict.
|
|
47
|
+
* - A phase both changed merges its attributes one by one and the blocks inside it one by one.
|
|
48
|
+
* - Front matter takes theirs unless only the person changed it.
|
|
49
|
+
* - When the person's workflow differs only by the steps for their new cards, the agent's
|
|
50
|
+
* workflow is kept and those cards are wired onto it again (`wireNewSteps`).
|
|
51
|
+
*
|
|
52
|
+
* Throws when a version does not parse as MDX.
|
|
53
|
+
*/
|
|
54
|
+
export declare function rebaseDraft(input: RebaseInput): RebaseResult;
|