@agents-inc/cli 0.32.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +462 -0
- package/LICENSE +21 -0
- package/README.md +179 -0
- package/config/skills-matrix.yaml +926 -0
- package/config/stacks.yaml +2186 -0
- package/dist/chunk-3ZOIOVKT.js +365 -0
- package/dist/chunk-3ZOIOVKT.js.map +1 -0
- package/dist/chunk-4RAY5AOI.js +78 -0
- package/dist/chunk-4RAY5AOI.js.map +1 -0
- package/dist/chunk-5PIKNCZX.js +234 -0
- package/dist/chunk-5PIKNCZX.js.map +1 -0
- package/dist/chunk-66UDJBF6.js +96 -0
- package/dist/chunk-66UDJBF6.js.map +1 -0
- package/dist/chunk-7SOPVGDV.js +24 -0
- package/dist/chunk-7SOPVGDV.js.map +1 -0
- package/dist/chunk-A27LOC4Z.js +95 -0
- package/dist/chunk-A27LOC4Z.js.map +1 -0
- package/dist/chunk-B2UBHA66.js +301 -0
- package/dist/chunk-B2UBHA66.js.map +1 -0
- package/dist/chunk-BZN2Z5P7.js +882 -0
- package/dist/chunk-BZN2Z5P7.js.map +1 -0
- package/dist/chunk-BZQBJP34.js +186 -0
- package/dist/chunk-BZQBJP34.js.map +1 -0
- package/dist/chunk-DC5AK3LW.js +105 -0
- package/dist/chunk-DC5AK3LW.js.map +1 -0
- package/dist/chunk-DHET7RCE.js +50 -0
- package/dist/chunk-DHET7RCE.js.map +1 -0
- package/dist/chunk-EMJ2ZKS7.js +346 -0
- package/dist/chunk-EMJ2ZKS7.js.map +1 -0
- package/dist/chunk-FJQRVFMB.js +48 -0
- package/dist/chunk-FJQRVFMB.js.map +1 -0
- package/dist/chunk-FZGYSLJL.js +85 -0
- package/dist/chunk-FZGYSLJL.js.map +1 -0
- package/dist/chunk-H566H3MQ.js +87 -0
- package/dist/chunk-H566H3MQ.js.map +1 -0
- package/dist/chunk-IYG2LAIM.js +90 -0
- package/dist/chunk-IYG2LAIM.js.map +1 -0
- package/dist/chunk-IZZ4IIEG.js +29 -0
- package/dist/chunk-IZZ4IIEG.js.map +1 -0
- package/dist/chunk-JMVWYAHT.js +63 -0
- package/dist/chunk-JMVWYAHT.js.map +1 -0
- package/dist/chunk-LAPCUV4D.js +191 -0
- package/dist/chunk-LAPCUV4D.js.map +1 -0
- package/dist/chunk-LGUI3PMO.js +109 -0
- package/dist/chunk-LGUI3PMO.js.map +1 -0
- package/dist/chunk-MM7NK5N2.js +4542 -0
- package/dist/chunk-MM7NK5N2.js.map +1 -0
- package/dist/chunk-N6S7ZRIL.js +31 -0
- package/dist/chunk-N6S7ZRIL.js.map +1 -0
- package/dist/chunk-O4D67NN7.js +24 -0
- package/dist/chunk-O4D67NN7.js.map +1 -0
- package/dist/chunk-ODUOU55D.js +56 -0
- package/dist/chunk-ODUOU55D.js.map +1 -0
- package/dist/chunk-OGJIZ6QH.js +497 -0
- package/dist/chunk-OGJIZ6QH.js.map +1 -0
- package/dist/chunk-OMV7TLWD.js +340 -0
- package/dist/chunk-OMV7TLWD.js.map +1 -0
- package/dist/chunk-PBEHPQLK.js +146 -0
- package/dist/chunk-PBEHPQLK.js.map +1 -0
- package/dist/chunk-QPTOIZAT.js +32 -0
- package/dist/chunk-QPTOIZAT.js.map +1 -0
- package/dist/chunk-R3XFQKPG.js +111 -0
- package/dist/chunk-R3XFQKPG.js.map +1 -0
- package/dist/chunk-R74PZWQS.js +69 -0
- package/dist/chunk-R74PZWQS.js.map +1 -0
- package/dist/chunk-SO22IQPY.js +45 -0
- package/dist/chunk-SO22IQPY.js.map +1 -0
- package/dist/chunk-T4EXUIBY.js +19 -0
- package/dist/chunk-T4EXUIBY.js.map +1 -0
- package/dist/chunk-U3IGFMCY.js +31 -0
- package/dist/chunk-U3IGFMCY.js.map +1 -0
- package/dist/chunk-UICL22RT.js +318 -0
- package/dist/chunk-UICL22RT.js.map +1 -0
- package/dist/chunk-UX2H2K2G.js +183 -0
- package/dist/chunk-UX2H2K2G.js.map +1 -0
- package/dist/chunk-W2ZSCZ2U.js +93 -0
- package/dist/chunk-W2ZSCZ2U.js.map +1 -0
- package/dist/chunk-WEUVWHMA.js +189 -0
- package/dist/chunk-WEUVWHMA.js.map +1 -0
- package/dist/chunk-XY3XDVMI.js +15599 -0
- package/dist/chunk-XY3XDVMI.js.map +1 -0
- package/dist/chunk-YND42IXK.js +233 -0
- package/dist/chunk-YND42IXK.js.map +1 -0
- package/dist/chunk-YZTWZVGX.js +41 -0
- package/dist/chunk-YZTWZVGX.js.map +1 -0
- package/dist/chunk-Z4TWOP3H.js +81 -0
- package/dist/chunk-Z4TWOP3H.js.map +1 -0
- package/dist/cli/defaults/agent-mappings.yaml +271 -0
- package/dist/commands/build/marketplace.js +252 -0
- package/dist/commands/build/marketplace.js.map +1 -0
- package/dist/commands/build/plugins.js +114 -0
- package/dist/commands/build/plugins.js.map +1 -0
- package/dist/commands/build/stack.js +153 -0
- package/dist/commands/build/stack.js.map +1 -0
- package/dist/commands/compile.js +354 -0
- package/dist/commands/compile.js.map +1 -0
- package/dist/commands/config/get.js +61 -0
- package/dist/commands/config/get.js.map +1 -0
- package/dist/commands/config/index.js +23 -0
- package/dist/commands/config/index.js.map +1 -0
- package/dist/commands/config/path.js +34 -0
- package/dist/commands/config/path.js.map +1 -0
- package/dist/commands/config/set-project.js +61 -0
- package/dist/commands/config/set-project.js.map +1 -0
- package/dist/commands/config/show.js +14 -0
- package/dist/commands/config/show.js.map +1 -0
- package/dist/commands/config/unset-project.js +57 -0
- package/dist/commands/config/unset-project.js.map +1 -0
- package/dist/commands/diff.js +742 -0
- package/dist/commands/diff.js.map +1 -0
- package/dist/commands/doctor.js +370 -0
- package/dist/commands/doctor.js.map +1 -0
- package/dist/commands/edit.js +301 -0
- package/dist/commands/edit.js.map +1 -0
- package/dist/commands/eject.js +262 -0
- package/dist/commands/eject.js.map +1 -0
- package/dist/commands/import/skill.js +361 -0
- package/dist/commands/import/skill.js.map +1 -0
- package/dist/commands/info.js +217 -0
- package/dist/commands/info.js.map +1 -0
- package/dist/commands/init.js +443 -0
- package/dist/commands/init.js.map +1 -0
- package/dist/commands/list.js +49 -0
- package/dist/commands/list.js.map +1 -0
- package/dist/commands/new/agent.js +224 -0
- package/dist/commands/new/agent.js.map +1 -0
- package/dist/commands/new/skill.js +199 -0
- package/dist/commands/new/skill.js.map +1 -0
- package/dist/commands/outdated.js +176 -0
- package/dist/commands/outdated.js.map +1 -0
- package/dist/commands/search.js +288 -0
- package/dist/commands/search.js.map +1 -0
- package/dist/commands/uninstall.js +302 -0
- package/dist/commands/uninstall.js.map +1 -0
- package/dist/commands/update.js +304 -0
- package/dist/commands/update.js.map +1 -0
- package/dist/commands/validate.js +389 -0
- package/dist/commands/validate.js.map +1 -0
- package/dist/commands/version/bump.js +79 -0
- package/dist/commands/version/bump.js.map +1 -0
- package/dist/commands/version/index.js +54 -0
- package/dist/commands/version/index.js.map +1 -0
- package/dist/commands/version/set.js +86 -0
- package/dist/commands/version/set.js.map +1 -0
- package/dist/commands/version/show.js +54 -0
- package/dist/commands/version/show.js.map +1 -0
- package/dist/components/common/confirm.js +9 -0
- package/dist/components/common/confirm.js.map +1 -0
- package/dist/components/common/confirm.test.js +203 -0
- package/dist/components/common/confirm.test.js.map +1 -0
- package/dist/components/common/message.js +20 -0
- package/dist/components/common/message.js.map +1 -0
- package/dist/components/common/spinner.js +14 -0
- package/dist/components/common/spinner.js.map +1 -0
- package/dist/components/skill-search/skill-search.js +12 -0
- package/dist/components/skill-search/skill-search.js.map +1 -0
- package/dist/components/wizard/category-grid.js +11 -0
- package/dist/components/wizard/category-grid.js.map +1 -0
- package/dist/components/wizard/category-grid.test.js +997 -0
- package/dist/components/wizard/category-grid.test.js.map +1 -0
- package/dist/components/wizard/domain-selection.js +14 -0
- package/dist/components/wizard/domain-selection.js.map +1 -0
- package/dist/components/wizard/help-modal.js +10 -0
- package/dist/components/wizard/help-modal.js.map +1 -0
- package/dist/components/wizard/menu-item.js +10 -0
- package/dist/components/wizard/menu-item.js.map +1 -0
- package/dist/components/wizard/search-modal.js +11 -0
- package/dist/components/wizard/search-modal.js.map +1 -0
- package/dist/components/wizard/search-modal.test.js +218 -0
- package/dist/components/wizard/search-modal.test.js.map +1 -0
- package/dist/components/wizard/section-progress.js +10 -0
- package/dist/components/wizard/section-progress.js.map +1 -0
- package/dist/components/wizard/section-progress.test.js +192 -0
- package/dist/components/wizard/section-progress.test.js.map +1 -0
- package/dist/components/wizard/source-grid.js +14 -0
- package/dist/components/wizard/source-grid.js.map +1 -0
- package/dist/components/wizard/source-grid.test.js +504 -0
- package/dist/components/wizard/source-grid.test.js.map +1 -0
- package/dist/components/wizard/stack-selection.js +17 -0
- package/dist/components/wizard/stack-selection.js.map +1 -0
- package/dist/components/wizard/step-build.js +17 -0
- package/dist/components/wizard/step-build.js.map +1 -0
- package/dist/components/wizard/step-build.test.js +600 -0
- package/dist/components/wizard/step-build.test.js.map +1 -0
- package/dist/components/wizard/step-confirm.js +12 -0
- package/dist/components/wizard/step-confirm.js.map +1 -0
- package/dist/components/wizard/step-confirm.test.js +366 -0
- package/dist/components/wizard/step-confirm.test.js.map +1 -0
- package/dist/components/wizard/step-refine.js +10 -0
- package/dist/components/wizard/step-refine.js.map +1 -0
- package/dist/components/wizard/step-refine.test.js +237 -0
- package/dist/components/wizard/step-refine.test.js.map +1 -0
- package/dist/components/wizard/step-settings.js +17 -0
- package/dist/components/wizard/step-settings.js.map +1 -0
- package/dist/components/wizard/step-settings.test.js +243 -0
- package/dist/components/wizard/step-settings.test.js.map +1 -0
- package/dist/components/wizard/step-sources.js +20 -0
- package/dist/components/wizard/step-sources.js.map +1 -0
- package/dist/components/wizard/step-sources.test.js +294 -0
- package/dist/components/wizard/step-sources.test.js.map +1 -0
- package/dist/components/wizard/step-stack.js +19 -0
- package/dist/components/wizard/step-stack.js.map +1 -0
- package/dist/components/wizard/step-stack.test.js +357 -0
- package/dist/components/wizard/step-stack.test.js.map +1 -0
- package/dist/components/wizard/view-title.js +10 -0
- package/dist/components/wizard/view-title.js.map +1 -0
- package/dist/components/wizard/wizard-layout.js +16 -0
- package/dist/components/wizard/wizard-layout.js.map +1 -0
- package/dist/components/wizard/wizard-tabs.js +14 -0
- package/dist/components/wizard/wizard-tabs.js.map +1 -0
- package/dist/components/wizard/wizard-tabs.test.js +294 -0
- package/dist/components/wizard/wizard-tabs.test.js.map +1 -0
- package/dist/components/wizard/wizard.js +35 -0
- package/dist/components/wizard/wizard.js.map +1 -0
- package/dist/config/skills-matrix.yaml +926 -0
- package/dist/config/stacks.yaml +2186 -0
- package/dist/hooks/init.js +40 -0
- package/dist/hooks/init.js.map +1 -0
- package/dist/index.js +10 -0
- package/dist/index.js.map +1 -0
- package/dist/magic-string.es-RGXYGAW3.js +1316 -0
- package/dist/magic-string.es-RGXYGAW3.js.map +1 -0
- package/dist/source-manager-SBPPLOQQ.js +16 -0
- package/dist/source-manager-SBPPLOQQ.js.map +1 -0
- package/dist/src/agents/_templates/agent.liquid +140 -0
- package/dist/src/agents/developer/api-developer/agent.yaml +12 -0
- package/dist/src/agents/developer/api-developer/critical-reminders.md +23 -0
- package/dist/src/agents/developer/api-developer/critical-requirements.md +11 -0
- package/dist/src/agents/developer/api-developer/examples.md +72 -0
- package/dist/src/agents/developer/api-developer/intro.md +22 -0
- package/dist/src/agents/developer/api-developer/output-format.md +359 -0
- package/dist/src/agents/developer/api-developer/workflow.md +471 -0
- package/dist/src/agents/developer/cli-developer/agent.yaml +12 -0
- package/dist/src/agents/developer/cli-developer/critical-reminders.md +28 -0
- package/dist/src/agents/developer/cli-developer/critical-requirements.md +15 -0
- package/dist/src/agents/developer/cli-developer/examples.md +68 -0
- package/dist/src/agents/developer/cli-developer/intro.md +23 -0
- package/dist/src/agents/developer/cli-developer/output-format.md +216 -0
- package/dist/src/agents/developer/cli-developer/workflow.md +509 -0
- package/dist/src/agents/developer/web-architecture/agent.yaml +12 -0
- package/dist/src/agents/developer/web-architecture/critical-reminders.md +27 -0
- package/dist/src/agents/developer/web-architecture/critical-requirements.md +35 -0
- package/dist/src/agents/developer/web-architecture/examples.md +187 -0
- package/dist/src/agents/developer/web-architecture/intro.md +35 -0
- package/dist/src/agents/developer/web-architecture/output-format.md +261 -0
- package/dist/src/agents/developer/web-architecture/workflow.md +599 -0
- package/dist/src/agents/developer/web-developer/agent.yaml +12 -0
- package/dist/src/agents/developer/web-developer/critical-reminders.md +17 -0
- package/dist/src/agents/developer/web-developer/critical-requirements.md +15 -0
- package/dist/src/agents/developer/web-developer/examples.md +109 -0
- package/dist/src/agents/developer/web-developer/intro.md +5 -0
- package/dist/src/agents/developer/web-developer/output-format.md +213 -0
- package/dist/src/agents/developer/web-developer/workflow.md +459 -0
- package/dist/src/agents/meta/agent-summoner/agent.yaml +12 -0
- package/dist/src/agents/meta/agent-summoner/critical-reminders.md +31 -0
- package/dist/src/agents/meta/agent-summoner/critical-requirements.md +27 -0
- package/dist/src/agents/meta/agent-summoner/examples.md +176 -0
- package/dist/src/agents/meta/agent-summoner/intro.md +9 -0
- package/dist/src/agents/meta/agent-summoner/output-format.md +115 -0
- package/dist/src/agents/meta/agent-summoner/workflow.md +1540 -0
- package/dist/src/agents/meta/documentor/agent.yaml +11 -0
- package/dist/src/agents/meta/documentor/critical-reminders.md +23 -0
- package/dist/src/agents/meta/documentor/critical-requirements.md +13 -0
- package/dist/src/agents/meta/documentor/examples.md +147 -0
- package/dist/src/agents/meta/documentor/intro.md +11 -0
- package/dist/src/agents/meta/documentor/output-format.md +237 -0
- package/dist/src/agents/meta/documentor/workflow.md +1271 -0
- package/dist/src/agents/meta/skill-summoner/agent.yaml +13 -0
- package/dist/src/agents/meta/skill-summoner/critical-reminders.md +73 -0
- package/dist/src/agents/meta/skill-summoner/critical-requirements.md +62 -0
- package/dist/src/agents/meta/skill-summoner/examples.md +116 -0
- package/dist/src/agents/meta/skill-summoner/intro.md +5 -0
- package/dist/src/agents/meta/skill-summoner/output-format.md +279 -0
- package/dist/src/agents/meta/skill-summoner/workflow.md +1485 -0
- package/dist/src/agents/migration/cli-migrator/agent.yaml +12 -0
- package/dist/src/agents/migration/cli-migrator/anti-patterns.md +158 -0
- package/dist/src/agents/migration/cli-migrator/conversion-mappings.md +63 -0
- package/dist/src/agents/migration/cli-migrator/critical-reminders.md +17 -0
- package/dist/src/agents/migration/cli-migrator/critical-requirements.md +13 -0
- package/dist/src/agents/migration/cli-migrator/intro.md +15 -0
- package/dist/src/agents/migration/cli-migrator/output-format.md +164 -0
- package/dist/src/agents/migration/cli-migrator/workflow.md +230 -0
- package/dist/src/agents/pattern/pattern-scout/agent.yaml +10 -0
- package/dist/src/agents/pattern/pattern-scout/critical-reminders.md +58 -0
- package/dist/src/agents/pattern/pattern-scout/critical-requirements.md +17 -0
- package/dist/src/agents/pattern/pattern-scout/examples.md +93 -0
- package/dist/src/agents/pattern/pattern-scout/intro.md +3 -0
- package/dist/src/agents/pattern/pattern-scout/output-format.md +196 -0
- package/dist/src/agents/pattern/pattern-scout/workflow.md +1901 -0
- package/dist/src/agents/pattern/web-pattern-critique/agent.yaml +12 -0
- package/dist/src/agents/pattern/web-pattern-critique/critical-reminders.md +13 -0
- package/dist/src/agents/pattern/web-pattern-critique/critical-requirements.md +11 -0
- package/dist/src/agents/pattern/web-pattern-critique/examples.md +56 -0
- package/dist/src/agents/pattern/web-pattern-critique/intro.md +5 -0
- package/dist/src/agents/pattern/web-pattern-critique/output-format.md +257 -0
- package/dist/src/agents/pattern/web-pattern-critique/workflow.md +674 -0
- package/dist/src/agents/planning/web-pm/agent.yaml +12 -0
- package/dist/src/agents/planning/web-pm/critical-reminders.md +21 -0
- package/dist/src/agents/planning/web-pm/critical-requirements.md +17 -0
- package/dist/src/agents/planning/web-pm/examples.md +85 -0
- package/dist/src/agents/planning/web-pm/intro.md +3 -0
- package/dist/src/agents/planning/web-pm/output-format.md +228 -0
- package/dist/src/agents/planning/web-pm/workflow.md +393 -0
- package/dist/src/agents/researcher/api-researcher/agent.yaml +10 -0
- package/dist/src/agents/researcher/api-researcher/critical-reminders.md +27 -0
- package/dist/src/agents/researcher/api-researcher/critical-requirements.md +13 -0
- package/dist/src/agents/researcher/api-researcher/examples.md +116 -0
- package/dist/src/agents/researcher/api-researcher/intro.md +32 -0
- package/dist/src/agents/researcher/api-researcher/output-format.md +135 -0
- package/dist/src/agents/researcher/api-researcher/workflow.md +261 -0
- package/dist/src/agents/researcher/web-researcher/agent.yaml +10 -0
- package/dist/src/agents/researcher/web-researcher/critical-reminders.md +23 -0
- package/dist/src/agents/researcher/web-researcher/critical-requirements.md +11 -0
- package/dist/src/agents/researcher/web-researcher/examples.md +126 -0
- package/dist/src/agents/researcher/web-researcher/intro.md +31 -0
- package/dist/src/agents/researcher/web-researcher/output-format.md +112 -0
- package/dist/src/agents/researcher/web-researcher/workflow.md +322 -0
- package/dist/src/agents/reviewer/api-reviewer/agent.yaml +12 -0
- package/dist/src/agents/reviewer/api-reviewer/critical-reminders.md +16 -0
- package/dist/src/agents/reviewer/api-reviewer/critical-requirements.md +13 -0
- package/dist/src/agents/reviewer/api-reviewer/examples.md +54 -0
- package/dist/src/agents/reviewer/api-reviewer/intro.md +22 -0
- package/dist/src/agents/reviewer/api-reviewer/output-format.md +288 -0
- package/dist/src/agents/reviewer/api-reviewer/workflow.md +369 -0
- package/dist/src/agents/reviewer/cli-reviewer/agent.yaml +12 -0
- package/dist/src/agents/reviewer/cli-reviewer/critical-reminders.md +17 -0
- package/dist/src/agents/reviewer/cli-reviewer/critical-requirements.md +13 -0
- package/dist/src/agents/reviewer/cli-reviewer/examples.md +83 -0
- package/dist/src/agents/reviewer/cli-reviewer/intro.md +21 -0
- package/dist/src/agents/reviewer/cli-reviewer/output-format.md +330 -0
- package/dist/src/agents/reviewer/cli-reviewer/workflow.md +294 -0
- package/dist/src/agents/reviewer/web-reviewer/agent.yaml +12 -0
- package/dist/src/agents/reviewer/web-reviewer/critical-reminders.md +17 -0
- package/dist/src/agents/reviewer/web-reviewer/critical-requirements.md +11 -0
- package/dist/src/agents/reviewer/web-reviewer/examples.md +79 -0
- package/dist/src/agents/reviewer/web-reviewer/intro.md +20 -0
- package/dist/src/agents/reviewer/web-reviewer/output-format.md +253 -0
- package/dist/src/agents/reviewer/web-reviewer/workflow.md +228 -0
- package/dist/src/agents/tester/cli-tester/agent.yaml +12 -0
- package/dist/src/agents/tester/cli-tester/critical-reminders.md +19 -0
- package/dist/src/agents/tester/cli-tester/critical-requirements.md +17 -0
- package/dist/src/agents/tester/cli-tester/examples.md +80 -0
- package/dist/src/agents/tester/cli-tester/intro.md +19 -0
- package/dist/src/agents/tester/cli-tester/output-format.md +232 -0
- package/dist/src/agents/tester/cli-tester/workflow.md +304 -0
- package/dist/src/agents/tester/web-tester/agent.yaml +12 -0
- package/dist/src/agents/tester/web-tester/critical-reminders.md +15 -0
- package/dist/src/agents/tester/web-tester/critical-requirements.md +11 -0
- package/dist/src/agents/tester/web-tester/examples.md +68 -0
- package/dist/src/agents/tester/web-tester/intro.md +18 -0
- package/dist/src/agents/tester/web-tester/output-format.md +252 -0
- package/dist/src/agents/tester/web-tester/workflow.md +507 -0
- package/dist/stores/wizard-store.js +13 -0
- package/dist/stores/wizard-store.js.map +1 -0
- package/dist/stores/wizard-store.test.js +689 -0
- package/dist/stores/wizard-store.test.js.map +1 -0
- package/package.json +134 -0
- package/src/agents/_templates/agent.liquid +140 -0
- package/src/agents/developer/api-developer/agent.yaml +12 -0
- package/src/agents/developer/api-developer/critical-reminders.md +23 -0
- package/src/agents/developer/api-developer/critical-requirements.md +11 -0
- package/src/agents/developer/api-developer/examples.md +72 -0
- package/src/agents/developer/api-developer/intro.md +22 -0
- package/src/agents/developer/api-developer/output-format.md +359 -0
- package/src/agents/developer/api-developer/workflow.md +471 -0
- package/src/agents/developer/cli-developer/agent.yaml +12 -0
- package/src/agents/developer/cli-developer/critical-reminders.md +28 -0
- package/src/agents/developer/cli-developer/critical-requirements.md +15 -0
- package/src/agents/developer/cli-developer/examples.md +68 -0
- package/src/agents/developer/cli-developer/intro.md +23 -0
- package/src/agents/developer/cli-developer/output-format.md +216 -0
- package/src/agents/developer/cli-developer/workflow.md +509 -0
- package/src/agents/developer/web-architecture/agent.yaml +12 -0
- package/src/agents/developer/web-architecture/critical-reminders.md +27 -0
- package/src/agents/developer/web-architecture/critical-requirements.md +35 -0
- package/src/agents/developer/web-architecture/examples.md +187 -0
- package/src/agents/developer/web-architecture/intro.md +35 -0
- package/src/agents/developer/web-architecture/output-format.md +261 -0
- package/src/agents/developer/web-architecture/workflow.md +599 -0
- package/src/agents/developer/web-developer/agent.yaml +12 -0
- package/src/agents/developer/web-developer/critical-reminders.md +17 -0
- package/src/agents/developer/web-developer/critical-requirements.md +15 -0
- package/src/agents/developer/web-developer/examples.md +109 -0
- package/src/agents/developer/web-developer/intro.md +5 -0
- package/src/agents/developer/web-developer/output-format.md +213 -0
- package/src/agents/developer/web-developer/workflow.md +459 -0
- package/src/agents/meta/agent-summoner/agent.yaml +12 -0
- package/src/agents/meta/agent-summoner/critical-reminders.md +31 -0
- package/src/agents/meta/agent-summoner/critical-requirements.md +27 -0
- package/src/agents/meta/agent-summoner/examples.md +176 -0
- package/src/agents/meta/agent-summoner/intro.md +9 -0
- package/src/agents/meta/agent-summoner/output-format.md +115 -0
- package/src/agents/meta/agent-summoner/workflow.md +1540 -0
- package/src/agents/meta/documentor/agent.yaml +11 -0
- package/src/agents/meta/documentor/critical-reminders.md +23 -0
- package/src/agents/meta/documentor/critical-requirements.md +13 -0
- package/src/agents/meta/documentor/examples.md +147 -0
- package/src/agents/meta/documentor/intro.md +11 -0
- package/src/agents/meta/documentor/output-format.md +237 -0
- package/src/agents/meta/documentor/workflow.md +1271 -0
- package/src/agents/meta/skill-summoner/agent.yaml +13 -0
- package/src/agents/meta/skill-summoner/critical-reminders.md +73 -0
- package/src/agents/meta/skill-summoner/critical-requirements.md +62 -0
- package/src/agents/meta/skill-summoner/examples.md +116 -0
- package/src/agents/meta/skill-summoner/intro.md +5 -0
- package/src/agents/meta/skill-summoner/output-format.md +279 -0
- package/src/agents/meta/skill-summoner/workflow.md +1485 -0
- package/src/agents/migration/cli-migrator/agent.yaml +12 -0
- package/src/agents/migration/cli-migrator/anti-patterns.md +158 -0
- package/src/agents/migration/cli-migrator/conversion-mappings.md +63 -0
- package/src/agents/migration/cli-migrator/critical-reminders.md +17 -0
- package/src/agents/migration/cli-migrator/critical-requirements.md +13 -0
- package/src/agents/migration/cli-migrator/intro.md +15 -0
- package/src/agents/migration/cli-migrator/output-format.md +164 -0
- package/src/agents/migration/cli-migrator/workflow.md +230 -0
- package/src/agents/pattern/pattern-scout/agent.yaml +10 -0
- package/src/agents/pattern/pattern-scout/critical-reminders.md +58 -0
- package/src/agents/pattern/pattern-scout/critical-requirements.md +17 -0
- package/src/agents/pattern/pattern-scout/examples.md +93 -0
- package/src/agents/pattern/pattern-scout/intro.md +3 -0
- package/src/agents/pattern/pattern-scout/output-format.md +196 -0
- package/src/agents/pattern/pattern-scout/workflow.md +1901 -0
- package/src/agents/pattern/web-pattern-critique/agent.yaml +12 -0
- package/src/agents/pattern/web-pattern-critique/critical-reminders.md +13 -0
- package/src/agents/pattern/web-pattern-critique/critical-requirements.md +11 -0
- package/src/agents/pattern/web-pattern-critique/examples.md +56 -0
- package/src/agents/pattern/web-pattern-critique/intro.md +5 -0
- package/src/agents/pattern/web-pattern-critique/output-format.md +257 -0
- package/src/agents/pattern/web-pattern-critique/workflow.md +674 -0
- package/src/agents/planning/web-pm/agent.yaml +12 -0
- package/src/agents/planning/web-pm/critical-reminders.md +21 -0
- package/src/agents/planning/web-pm/critical-requirements.md +17 -0
- package/src/agents/planning/web-pm/examples.md +85 -0
- package/src/agents/planning/web-pm/intro.md +3 -0
- package/src/agents/planning/web-pm/output-format.md +228 -0
- package/src/agents/planning/web-pm/workflow.md +393 -0
- package/src/agents/researcher/api-researcher/agent.yaml +10 -0
- package/src/agents/researcher/api-researcher/critical-reminders.md +27 -0
- package/src/agents/researcher/api-researcher/critical-requirements.md +13 -0
- package/src/agents/researcher/api-researcher/examples.md +116 -0
- package/src/agents/researcher/api-researcher/intro.md +32 -0
- package/src/agents/researcher/api-researcher/output-format.md +135 -0
- package/src/agents/researcher/api-researcher/workflow.md +261 -0
- package/src/agents/researcher/web-researcher/agent.yaml +10 -0
- package/src/agents/researcher/web-researcher/critical-reminders.md +23 -0
- package/src/agents/researcher/web-researcher/critical-requirements.md +11 -0
- package/src/agents/researcher/web-researcher/examples.md +126 -0
- package/src/agents/researcher/web-researcher/intro.md +31 -0
- package/src/agents/researcher/web-researcher/output-format.md +112 -0
- package/src/agents/researcher/web-researcher/workflow.md +322 -0
- package/src/agents/reviewer/api-reviewer/agent.yaml +12 -0
- package/src/agents/reviewer/api-reviewer/critical-reminders.md +16 -0
- package/src/agents/reviewer/api-reviewer/critical-requirements.md +13 -0
- package/src/agents/reviewer/api-reviewer/examples.md +54 -0
- package/src/agents/reviewer/api-reviewer/intro.md +22 -0
- package/src/agents/reviewer/api-reviewer/output-format.md +288 -0
- package/src/agents/reviewer/api-reviewer/workflow.md +369 -0
- package/src/agents/reviewer/cli-reviewer/agent.yaml +12 -0
- package/src/agents/reviewer/cli-reviewer/critical-reminders.md +17 -0
- package/src/agents/reviewer/cli-reviewer/critical-requirements.md +13 -0
- package/src/agents/reviewer/cli-reviewer/examples.md +83 -0
- package/src/agents/reviewer/cli-reviewer/intro.md +21 -0
- package/src/agents/reviewer/cli-reviewer/output-format.md +330 -0
- package/src/agents/reviewer/cli-reviewer/workflow.md +294 -0
- package/src/agents/reviewer/web-reviewer/agent.yaml +12 -0
- package/src/agents/reviewer/web-reviewer/critical-reminders.md +17 -0
- package/src/agents/reviewer/web-reviewer/critical-requirements.md +11 -0
- package/src/agents/reviewer/web-reviewer/examples.md +79 -0
- package/src/agents/reviewer/web-reviewer/intro.md +20 -0
- package/src/agents/reviewer/web-reviewer/output-format.md +253 -0
- package/src/agents/reviewer/web-reviewer/workflow.md +228 -0
- package/src/agents/tester/cli-tester/agent.yaml +12 -0
- package/src/agents/tester/cli-tester/critical-reminders.md +19 -0
- package/src/agents/tester/cli-tester/critical-requirements.md +17 -0
- package/src/agents/tester/cli-tester/examples.md +80 -0
- package/src/agents/tester/cli-tester/intro.md +19 -0
- package/src/agents/tester/cli-tester/output-format.md +232 -0
- package/src/agents/tester/cli-tester/workflow.md +304 -0
- package/src/agents/tester/web-tester/agent.yaml +12 -0
- package/src/agents/tester/web-tester/critical-reminders.md +15 -0
- package/src/agents/tester/web-tester/critical-requirements.md +11 -0
- package/src/agents/tester/web-tester/examples.md +68 -0
- package/src/agents/tester/web-tester/intro.md +18 -0
- package/src/agents/tester/web-tester/output-format.md +252 -0
- package/src/agents/tester/web-tester/workflow.md +507 -0
- package/src/schemas/agent-frontmatter.schema.json +84 -0
- package/src/schemas/agent.schema.json +93 -0
- package/src/schemas/hooks.schema.json +47 -0
- package/src/schemas/marketplace.schema.json +119 -0
- package/src/schemas/metadata.schema.json +113 -0
- package/src/schemas/plugin.schema.json +130 -0
- package/src/schemas/project-config.schema.json +125 -0
- package/src/schemas/project-source-config.schema.json +81 -0
- package/src/schemas/skill-frontmatter.schema.json +42 -0
- package/src/schemas/skills-matrix.schema.json +467 -0
- package/src/schemas/stack.schema.json +191 -0
- package/src/schemas/stacks.schema.json +111 -0
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import {
|
|
3
|
+
init_esm_shims
|
|
4
|
+
} from "./chunk-DHET7RCE.js";
|
|
5
|
+
|
|
6
|
+
// src/cli/components/common/confirm.tsx
|
|
7
|
+
init_esm_shims();
|
|
8
|
+
import { Box, Text } from "ink";
|
|
9
|
+
import { ConfirmInput } from "@inkjs/ui";
|
|
10
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
11
|
+
var Confirm = ({
|
|
12
|
+
message,
|
|
13
|
+
onConfirm,
|
|
14
|
+
onCancel,
|
|
15
|
+
defaultValue = false
|
|
16
|
+
}) => /* @__PURE__ */ jsxs(Box, { flexDirection: "column", children: [
|
|
17
|
+
/* @__PURE__ */ jsx(Text, { children: message }),
|
|
18
|
+
/* @__PURE__ */ jsx(
|
|
19
|
+
ConfirmInput,
|
|
20
|
+
{
|
|
21
|
+
onConfirm,
|
|
22
|
+
onCancel,
|
|
23
|
+
defaultChoice: defaultValue ? "confirm" : "cancel"
|
|
24
|
+
}
|
|
25
|
+
)
|
|
26
|
+
] });
|
|
27
|
+
|
|
28
|
+
export {
|
|
29
|
+
Confirm
|
|
30
|
+
};
|
|
31
|
+
//# sourceMappingURL=chunk-N6S7ZRIL.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/cli/components/common/confirm.tsx"],"sourcesContent":["import React from \"react\";\nimport { Box, Text } from \"ink\";\nimport { ConfirmInput } from \"@inkjs/ui\";\n\ntype ConfirmProps = {\n message: string;\n onConfirm: () => void;\n onCancel: () => void;\n defaultValue?: boolean;\n};\n\nexport const Confirm: React.FC<ConfirmProps> = ({\n message,\n onConfirm,\n onCancel,\n defaultValue = false,\n}) => (\n <Box flexDirection=\"column\">\n <Text>{message}</Text>\n <ConfirmInput\n onConfirm={onConfirm}\n onCancel={onCancel}\n defaultChoice={defaultValue ? \"confirm\" : \"cancel\"}\n />\n </Box>\n);\n"],"mappings":";;;;;;AAAA;AACA,SAAS,KAAK,YAAY;AAC1B,SAAS,oBAAoB;AAe3B,SACE,KADF;AANK,IAAM,UAAkC,CAAC;AAAA,EAC9C;AAAA,EACA;AAAA,EACA;AAAA,EACA,eAAe;AACjB,MACE,qBAAC,OAAI,eAAc,UACjB;AAAA,sBAAC,QAAM,mBAAQ;AAAA,EACf;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA;AAAA,MACA,eAAe,eAAe,YAAY;AAAA;AAAA,EAC5C;AAAA,GACF;","names":[]}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import {
|
|
3
|
+
CLI_COLORS
|
|
4
|
+
} from "./chunk-LAPCUV4D.js";
|
|
5
|
+
import {
|
|
6
|
+
init_esm_shims
|
|
7
|
+
} from "./chunk-DHET7RCE.js";
|
|
8
|
+
|
|
9
|
+
// src/cli/components/wizard/view-title.tsx
|
|
10
|
+
init_esm_shims();
|
|
11
|
+
import { Text } from "ink";
|
|
12
|
+
import { jsxs } from "react/jsx-runtime";
|
|
13
|
+
var ViewTitle = ({ children }) => {
|
|
14
|
+
return /* @__PURE__ */ jsxs(Text, { backgroundColor: CLI_COLORS.WARNING, bold: true, color: "#000", children: [
|
|
15
|
+
" ",
|
|
16
|
+
children,
|
|
17
|
+
" "
|
|
18
|
+
] });
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
export {
|
|
22
|
+
ViewTitle
|
|
23
|
+
};
|
|
24
|
+
//# sourceMappingURL=chunk-O4D67NN7.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/cli/components/wizard/view-title.tsx"],"sourcesContent":["import React from \"react\";\nimport { Text } from \"ink\";\nimport { CLI_COLORS } from \"../../consts.js\";\n\ntype ViewTitleProps = {\n children: React.ReactNode;\n};\n\nexport const ViewTitle: React.FC<ViewTitleProps> = ({ children }) => {\n return (\n <Text backgroundColor={CLI_COLORS.WARNING} bold color=\"#000\">\n {\" \"}\n {children}{\" \"}\n </Text>\n );\n};\n"],"mappings":";;;;;;;;;AAAA;AACA,SAAS,YAAY;AASjB;AAFG,IAAM,YAAsC,CAAC,EAAE,SAAS,MAAM;AACnE,SACE,qBAAC,QAAK,iBAAiB,WAAW,SAAS,MAAI,MAAC,OAAM,QACnD;AAAA;AAAA,IACA;AAAA,IAAU;AAAA,KACb;AAEJ;","names":[]}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import {
|
|
3
|
+
getErrorMessage
|
|
4
|
+
} from "./chunk-BZN2Z5P7.js";
|
|
5
|
+
import {
|
|
6
|
+
init_esm_shims
|
|
7
|
+
} from "./chunk-DHET7RCE.js";
|
|
8
|
+
|
|
9
|
+
// src/cli/lib/exit-codes.ts
|
|
10
|
+
init_esm_shims();
|
|
11
|
+
var EXIT_CODES = {
|
|
12
|
+
SUCCESS: 0,
|
|
13
|
+
ERROR: 1,
|
|
14
|
+
INVALID_ARGS: 2,
|
|
15
|
+
NETWORK_ERROR: 3,
|
|
16
|
+
CANCELLED: 4
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
// src/cli/base-command.ts
|
|
20
|
+
init_esm_shims();
|
|
21
|
+
import { Command, Flags } from "@oclif/core";
|
|
22
|
+
var BaseCommand = class extends Command {
|
|
23
|
+
static baseFlags = {
|
|
24
|
+
"dry-run": Flags.boolean({
|
|
25
|
+
description: "Preview operations without executing",
|
|
26
|
+
default: false
|
|
27
|
+
}),
|
|
28
|
+
source: Flags.string({
|
|
29
|
+
char: "s",
|
|
30
|
+
description: "Skills source path or URL",
|
|
31
|
+
required: false
|
|
32
|
+
})
|
|
33
|
+
};
|
|
34
|
+
get sourceConfig() {
|
|
35
|
+
return this.config.sourceConfig;
|
|
36
|
+
}
|
|
37
|
+
handleError(error) {
|
|
38
|
+
const message = getErrorMessage(error);
|
|
39
|
+
this.error(message, { exit: EXIT_CODES.ERROR });
|
|
40
|
+
}
|
|
41
|
+
logSuccess(message) {
|
|
42
|
+
this.log(`\u2713 ${message}`);
|
|
43
|
+
}
|
|
44
|
+
logWarning(message) {
|
|
45
|
+
this.warn(message);
|
|
46
|
+
}
|
|
47
|
+
logInfo(message) {
|
|
48
|
+
this.log(message);
|
|
49
|
+
}
|
|
50
|
+
};
|
|
51
|
+
|
|
52
|
+
export {
|
|
53
|
+
EXIT_CODES,
|
|
54
|
+
BaseCommand
|
|
55
|
+
};
|
|
56
|
+
//# sourceMappingURL=chunk-ODUOU55D.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/cli/lib/exit-codes.ts","../src/cli/base-command.ts"],"sourcesContent":["export const EXIT_CODES = {\n SUCCESS: 0,\n ERROR: 1,\n INVALID_ARGS: 2,\n NETWORK_ERROR: 3,\n CANCELLED: 4,\n} as const;\n","import { Command, Flags } from \"@oclif/core\";\nimport { getErrorMessage } from \"./utils/errors.js\";\nimport { EXIT_CODES } from \"./lib/exit-codes.js\";\nimport type { ResolvedConfig } from \"./lib/configuration/index.js\";\n\n/** Narrow interface for the sourceConfig we attach to oclif's Config in the init hook. */\ninterface ConfigWithSource {\n sourceConfig?: ResolvedConfig;\n}\n\nexport abstract class BaseCommand extends Command {\n static baseFlags = {\n \"dry-run\": Flags.boolean({\n description: \"Preview operations without executing\",\n default: false,\n }),\n source: Flags.string({\n char: \"s\",\n description: \"Skills source path or URL\",\n required: false,\n }),\n };\n\n public get sourceConfig(): ResolvedConfig | undefined {\n // Boundary cast: oclif Config doesn't declare sourceConfig; we attach it in the init hook\n return (this.config as unknown as ConfigWithSource).sourceConfig;\n }\n\n protected handleError(error: unknown): never {\n const message = getErrorMessage(error);\n this.error(message, { exit: EXIT_CODES.ERROR });\n }\n\n protected logSuccess(message: string): void {\n this.log(`✓ ${message}`);\n }\n\n protected logWarning(message: string): void {\n this.warn(message);\n }\n\n protected logInfo(message: string): void {\n this.log(message);\n }\n}\n"],"mappings":";;;;;;;;;AAAA;AAAO,IAAM,aAAa;AAAA,EACxB,SAAS;AAAA,EACT,OAAO;AAAA,EACP,cAAc;AAAA,EACd,eAAe;AAAA,EACf,WAAW;AACb;;;ACNA;AAAA,SAAS,SAAS,aAAa;AAUxB,IAAe,cAAf,cAAmC,QAAQ;AAAA,EAChD,OAAO,YAAY;AAAA,IACjB,WAAW,MAAM,QAAQ;AAAA,MACvB,aAAa;AAAA,MACb,SAAS;AAAA,IACX,CAAC;AAAA,IACD,QAAQ,MAAM,OAAO;AAAA,MACnB,MAAM;AAAA,MACN,aAAa;AAAA,MACb,UAAU;AAAA,IACZ,CAAC;AAAA,EACH;AAAA,EAEA,IAAW,eAA2C;AAEpD,WAAQ,KAAK,OAAuC;AAAA,EACtD;AAAA,EAEU,YAAY,OAAuB;AAC3C,UAAM,UAAU,gBAAgB,KAAK;AACrC,SAAK,MAAM,SAAS,EAAE,MAAM,WAAW,MAAM,CAAC;AAAA,EAChD;AAAA,EAEU,WAAW,SAAuB;AAC1C,SAAK,IAAI,UAAK,OAAO,EAAE;AAAA,EACzB;AAAA,EAEU,WAAW,SAAuB;AAC1C,SAAK,KAAK,OAAO;AAAA,EACnB;AAAA,EAEU,QAAQ,SAAuB;AACvC,SAAK,IAAI,OAAO;AAAA,EAClB;AACF;","names":[]}
|
|
@@ -0,0 +1,497 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import {
|
|
3
|
+
useFocusedListItem
|
|
4
|
+
} from "./chunk-DC5AK3LW.js";
|
|
5
|
+
import {
|
|
6
|
+
CLI_COLORS,
|
|
7
|
+
SCROLL_VIEWPORT,
|
|
8
|
+
UI_SYMBOLS
|
|
9
|
+
} from "./chunk-LAPCUV4D.js";
|
|
10
|
+
import {
|
|
11
|
+
init_esm_shims
|
|
12
|
+
} from "./chunk-DHET7RCE.js";
|
|
13
|
+
|
|
14
|
+
// src/cli/components/wizard/category-grid.tsx
|
|
15
|
+
init_esm_shims();
|
|
16
|
+
import { useCallback as useCallback2, useMemo as useMemo2 } from "react";
|
|
17
|
+
import { Box, Text } from "ink";
|
|
18
|
+
import { sortBy } from "remeda";
|
|
19
|
+
|
|
20
|
+
// src/cli/components/hooks/use-virtual-scroll.ts
|
|
21
|
+
init_esm_shims();
|
|
22
|
+
import { useMemo } from "react";
|
|
23
|
+
function computeVirtualScroll({
|
|
24
|
+
items,
|
|
25
|
+
availableHeight,
|
|
26
|
+
focusedIndex,
|
|
27
|
+
estimateItemHeight,
|
|
28
|
+
terminalWidth
|
|
29
|
+
}) {
|
|
30
|
+
const totalItems = items.length;
|
|
31
|
+
if (totalItems === 0) {
|
|
32
|
+
return {
|
|
33
|
+
visibleItems: [],
|
|
34
|
+
startIndex: 0,
|
|
35
|
+
endIndex: 0,
|
|
36
|
+
hiddenAbove: 0,
|
|
37
|
+
hiddenBelow: 0,
|
|
38
|
+
isScrollable: false
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
const heights = items.map((item) => estimateItemHeight(item, terminalWidth));
|
|
42
|
+
const totalHeight = heights.reduce((sum, h) => sum + h, 0);
|
|
43
|
+
if (totalHeight <= availableHeight) {
|
|
44
|
+
return {
|
|
45
|
+
visibleItems: items,
|
|
46
|
+
startIndex: 0,
|
|
47
|
+
endIndex: totalItems,
|
|
48
|
+
hiddenAbove: 0,
|
|
49
|
+
hiddenBelow: 0,
|
|
50
|
+
isScrollable: false
|
|
51
|
+
};
|
|
52
|
+
}
|
|
53
|
+
const viewportHeight = Math.max(
|
|
54
|
+
SCROLL_VIEWPORT.MIN_VIEWPORT_ROWS,
|
|
55
|
+
availableHeight - SCROLL_VIEWPORT.SCROLL_INDICATOR_HEIGHT * 2
|
|
56
|
+
);
|
|
57
|
+
const safeFocused = Math.max(0, Math.min(focusedIndex, totalItems - 1));
|
|
58
|
+
let startIndex = safeFocused;
|
|
59
|
+
let endIndex = safeFocused + 1;
|
|
60
|
+
let usedHeight = heights[safeFocused] ?? 0;
|
|
61
|
+
while (endIndex < totalItems) {
|
|
62
|
+
const nextHeight = heights[endIndex] ?? 0;
|
|
63
|
+
if (usedHeight + nextHeight > viewportHeight) break;
|
|
64
|
+
usedHeight += nextHeight;
|
|
65
|
+
endIndex++;
|
|
66
|
+
}
|
|
67
|
+
while (startIndex > 0) {
|
|
68
|
+
const prevHeight = heights[startIndex - 1] ?? 0;
|
|
69
|
+
if (usedHeight + prevHeight > viewportHeight) break;
|
|
70
|
+
usedHeight += prevHeight;
|
|
71
|
+
startIndex--;
|
|
72
|
+
}
|
|
73
|
+
while (endIndex < totalItems) {
|
|
74
|
+
const nextHeight = heights[endIndex] ?? 0;
|
|
75
|
+
if (usedHeight + nextHeight > viewportHeight) break;
|
|
76
|
+
usedHeight += nextHeight;
|
|
77
|
+
endIndex++;
|
|
78
|
+
}
|
|
79
|
+
return {
|
|
80
|
+
visibleItems: items.slice(startIndex, endIndex),
|
|
81
|
+
startIndex,
|
|
82
|
+
endIndex,
|
|
83
|
+
hiddenAbove: startIndex,
|
|
84
|
+
hiddenBelow: totalItems - endIndex,
|
|
85
|
+
isScrollable: true
|
|
86
|
+
};
|
|
87
|
+
}
|
|
88
|
+
function useVirtualScroll(options) {
|
|
89
|
+
const { items, availableHeight, focusedIndex, estimateItemHeight, terminalWidth } = options;
|
|
90
|
+
return useMemo(
|
|
91
|
+
() => computeVirtualScroll(options),
|
|
92
|
+
[items, availableHeight, focusedIndex, estimateItemHeight, terminalWidth]
|
|
93
|
+
);
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
// src/cli/components/hooks/use-category-grid-input.ts
|
|
97
|
+
init_esm_shims();
|
|
98
|
+
import { useCallback, useEffect } from "react";
|
|
99
|
+
import { useInput } from "ink";
|
|
100
|
+
var FRAMEWORK_CATEGORY_ID = "framework";
|
|
101
|
+
var isSectionLocked = (categoryId, categories) => {
|
|
102
|
+
if (categoryId === FRAMEWORK_CATEGORY_ID) {
|
|
103
|
+
return false;
|
|
104
|
+
}
|
|
105
|
+
const frameworkCategory = categories.find((cat) => cat.id === FRAMEWORK_CATEGORY_ID);
|
|
106
|
+
if (!frameworkCategory) return false;
|
|
107
|
+
return !frameworkCategory.options.some((opt) => opt.selected);
|
|
108
|
+
};
|
|
109
|
+
var findValidStartColumn = (options) => {
|
|
110
|
+
for (let i = 0; i < options.length; i++) {
|
|
111
|
+
if (options[i] && options[i].state !== "disabled") {
|
|
112
|
+
return i;
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
return 0;
|
|
116
|
+
};
|
|
117
|
+
var findNextUnlockedIndex = (processed, currentIndex, allCategories) => {
|
|
118
|
+
const length = processed.length;
|
|
119
|
+
if (length === 0) return currentIndex;
|
|
120
|
+
let index = currentIndex;
|
|
121
|
+
let attempts = 0;
|
|
122
|
+
while (attempts < length) {
|
|
123
|
+
index += 1;
|
|
124
|
+
if (index >= length) index = 0;
|
|
125
|
+
const category = processed[index];
|
|
126
|
+
if (category && !isSectionLocked(category.id, allCategories)) {
|
|
127
|
+
return index;
|
|
128
|
+
}
|
|
129
|
+
attempts++;
|
|
130
|
+
}
|
|
131
|
+
return currentIndex;
|
|
132
|
+
};
|
|
133
|
+
function useCategoryGridInput({
|
|
134
|
+
processedCategories,
|
|
135
|
+
categories,
|
|
136
|
+
focusedRow,
|
|
137
|
+
focusedCol,
|
|
138
|
+
setFocused,
|
|
139
|
+
moveFocus,
|
|
140
|
+
onToggle,
|
|
141
|
+
onToggleDescriptions
|
|
142
|
+
}) {
|
|
143
|
+
const currentRow = processedCategories[focusedRow];
|
|
144
|
+
const currentOptions = currentRow?.sortedOptions || [];
|
|
145
|
+
const currentLocked = currentRow ? isSectionLocked(currentRow.id, categories) : false;
|
|
146
|
+
useEffect(() => {
|
|
147
|
+
if (!currentRow) return;
|
|
148
|
+
const maxCol = currentOptions.length - 1;
|
|
149
|
+
if (focusedCol > maxCol) {
|
|
150
|
+
const newCol = Math.max(0, maxCol);
|
|
151
|
+
setFocused(focusedRow, newCol);
|
|
152
|
+
} else if (currentOptions[focusedCol]?.state === "disabled") {
|
|
153
|
+
const validCol = findValidStartColumn(currentOptions);
|
|
154
|
+
if (validCol !== focusedCol) {
|
|
155
|
+
setFocused(focusedRow, validCol);
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
}, [focusedRow, currentOptions, focusedCol, setFocused, currentRow]);
|
|
159
|
+
useEffect(() => {
|
|
160
|
+
if (currentRow && currentLocked) {
|
|
161
|
+
const nextUnlocked = findNextUnlockedIndex(processedCategories, focusedRow, categories);
|
|
162
|
+
if (nextUnlocked !== focusedRow) {
|
|
163
|
+
const newRowOptions = processedCategories[nextUnlocked]?.sortedOptions || [];
|
|
164
|
+
const newCol = findValidStartColumn(newRowOptions);
|
|
165
|
+
setFocused(nextUnlocked, newCol);
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
}, [currentRow, currentLocked, focusedRow, processedCategories, categories, setFocused]);
|
|
169
|
+
useInput(
|
|
170
|
+
useCallback(
|
|
171
|
+
(input, key) => {
|
|
172
|
+
if (key.tab && key.shift) {
|
|
173
|
+
onToggleDescriptions();
|
|
174
|
+
return;
|
|
175
|
+
}
|
|
176
|
+
if (key.tab && !key.shift) {
|
|
177
|
+
const nextSection = findNextUnlockedIndex(processedCategories, focusedRow, categories);
|
|
178
|
+
if (nextSection !== focusedRow) {
|
|
179
|
+
const newRowOptions = processedCategories[nextSection]?.sortedOptions || [];
|
|
180
|
+
const newCol = findValidStartColumn(newRowOptions);
|
|
181
|
+
setFocused(nextSection, newCol);
|
|
182
|
+
}
|
|
183
|
+
return;
|
|
184
|
+
}
|
|
185
|
+
if (input === "d" || input === "D") {
|
|
186
|
+
onToggleDescriptions();
|
|
187
|
+
return;
|
|
188
|
+
}
|
|
189
|
+
if (input === " ") {
|
|
190
|
+
if (currentLocked) return;
|
|
191
|
+
const currentOption = currentOptions[focusedCol];
|
|
192
|
+
if (currentOption && currentOption.state !== "disabled") {
|
|
193
|
+
onToggle(currentRow.id, currentOption.id);
|
|
194
|
+
}
|
|
195
|
+
return;
|
|
196
|
+
}
|
|
197
|
+
const isLeft = key.leftArrow || input === "h";
|
|
198
|
+
const isRight = key.rightArrow || input === "l";
|
|
199
|
+
const isUp = key.upArrow || input === "k";
|
|
200
|
+
const isDown = key.downArrow || input === "j";
|
|
201
|
+
if (isLeft) {
|
|
202
|
+
if (currentLocked) return;
|
|
203
|
+
moveFocus("left");
|
|
204
|
+
} else if (isRight) {
|
|
205
|
+
if (currentLocked) return;
|
|
206
|
+
moveFocus("right");
|
|
207
|
+
} else if (isUp) {
|
|
208
|
+
moveFocus("up");
|
|
209
|
+
} else if (isDown) {
|
|
210
|
+
moveFocus("down");
|
|
211
|
+
}
|
|
212
|
+
},
|
|
213
|
+
[
|
|
214
|
+
focusedRow,
|
|
215
|
+
focusedCol,
|
|
216
|
+
currentOptions,
|
|
217
|
+
currentRow,
|
|
218
|
+
currentLocked,
|
|
219
|
+
processedCategories,
|
|
220
|
+
categories,
|
|
221
|
+
onToggle,
|
|
222
|
+
onToggleDescriptions,
|
|
223
|
+
setFocused,
|
|
224
|
+
moveFocus
|
|
225
|
+
]
|
|
226
|
+
)
|
|
227
|
+
);
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
// src/cli/components/wizard/category-grid.tsx
|
|
231
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
232
|
+
var SYMBOL_REQUIRED = "*";
|
|
233
|
+
var sortOptions = (options, expertMode) => {
|
|
234
|
+
if (expertMode) {
|
|
235
|
+
return options;
|
|
236
|
+
}
|
|
237
|
+
const stateOrder = {
|
|
238
|
+
recommended: 0,
|
|
239
|
+
normal: 1,
|
|
240
|
+
discouraged: 2,
|
|
241
|
+
disabled: 3
|
|
242
|
+
};
|
|
243
|
+
return sortBy([...options], (o) => stateOrder[o.state]);
|
|
244
|
+
};
|
|
245
|
+
var findNextValidOption = (options, currentIndex, direction, wrap = true) => {
|
|
246
|
+
const length = options.length;
|
|
247
|
+
if (length === 0) return currentIndex;
|
|
248
|
+
let index = currentIndex;
|
|
249
|
+
let attempts = 0;
|
|
250
|
+
while (attempts < length) {
|
|
251
|
+
index += direction;
|
|
252
|
+
if (wrap) {
|
|
253
|
+
if (index < 0) index = length - 1;
|
|
254
|
+
if (index >= length) index = 0;
|
|
255
|
+
} else {
|
|
256
|
+
if (index < 0) index = 0;
|
|
257
|
+
if (index >= length) index = length - 1;
|
|
258
|
+
}
|
|
259
|
+
if (options[index] && options[index].state !== "disabled") {
|
|
260
|
+
return index;
|
|
261
|
+
}
|
|
262
|
+
attempts++;
|
|
263
|
+
}
|
|
264
|
+
return currentIndex;
|
|
265
|
+
};
|
|
266
|
+
var getStateSuffix = (state, isLocked) => {
|
|
267
|
+
if (isLocked || state === "disabled") return "(disabled)";
|
|
268
|
+
if (state === "recommended") return "(recommended)";
|
|
269
|
+
if (state === "discouraged") return "(discouraged)";
|
|
270
|
+
return null;
|
|
271
|
+
};
|
|
272
|
+
var getStateSymbol = (option, isLocked) => {
|
|
273
|
+
if (isLocked || option.state === "disabled") return UI_SYMBOLS.DISABLED;
|
|
274
|
+
if (option.selected) return UI_SYMBOLS.SELECTED;
|
|
275
|
+
if (option.state === "discouraged") return UI_SYMBOLS.DISCOURAGED;
|
|
276
|
+
return UI_SYMBOLS.UNSELECTED;
|
|
277
|
+
};
|
|
278
|
+
var SkillTag = ({ option, isFocused, isLocked }) => {
|
|
279
|
+
const getColor = () => {
|
|
280
|
+
if (isLocked || option.state === "disabled") {
|
|
281
|
+
return {
|
|
282
|
+
text: CLI_COLORS.NEUTRAL,
|
|
283
|
+
border: CLI_COLORS.NEUTRAL
|
|
284
|
+
};
|
|
285
|
+
}
|
|
286
|
+
if (option.selected) {
|
|
287
|
+
return {
|
|
288
|
+
text: CLI_COLORS.PRIMARY,
|
|
289
|
+
border: CLI_COLORS.PRIMARY
|
|
290
|
+
};
|
|
291
|
+
}
|
|
292
|
+
if (option.state === "recommended") {
|
|
293
|
+
return {
|
|
294
|
+
text: CLI_COLORS.UNFOCUSED,
|
|
295
|
+
border: CLI_COLORS.NEUTRAL
|
|
296
|
+
};
|
|
297
|
+
}
|
|
298
|
+
if (option.state === "discouraged") {
|
|
299
|
+
return {
|
|
300
|
+
text: CLI_COLORS.WARNING,
|
|
301
|
+
border: CLI_COLORS.WARNING
|
|
302
|
+
};
|
|
303
|
+
}
|
|
304
|
+
return {
|
|
305
|
+
text: CLI_COLORS.NEUTRAL,
|
|
306
|
+
border: CLI_COLORS.NEUTRAL
|
|
307
|
+
};
|
|
308
|
+
};
|
|
309
|
+
const isBold = isFocused || option.selected;
|
|
310
|
+
const isDimmed = isLocked || option.state === "disabled";
|
|
311
|
+
const isBorderDimmed = isDimmed || !option.selected && !isFocused;
|
|
312
|
+
const focusBorderColor = option.selected ? CLI_COLORS.PRIMARY : CLI_COLORS.UNFOCUSED;
|
|
313
|
+
const colors = getColor();
|
|
314
|
+
const stateSuffix = getStateSuffix(option.state, isLocked);
|
|
315
|
+
const stateSymbol = getStateSymbol(option, isLocked);
|
|
316
|
+
return /* @__PURE__ */ jsx(
|
|
317
|
+
Box,
|
|
318
|
+
{
|
|
319
|
+
marginRight: 1,
|
|
320
|
+
borderColor: isFocused ? focusBorderColor : colors.border,
|
|
321
|
+
borderStyle: "single",
|
|
322
|
+
borderDimColor: isBorderDimmed,
|
|
323
|
+
children: /* @__PURE__ */ jsxs(Text, { color: colors.text, bold: isBold, dimColor: false, children: [
|
|
324
|
+
" ",
|
|
325
|
+
option.local && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
326
|
+
/* @__PURE__ */ jsx(Text, { backgroundColor: CLI_COLORS.NEUTRAL, children: " L " }),
|
|
327
|
+
" "
|
|
328
|
+
] }),
|
|
329
|
+
option.installed && /* @__PURE__ */ jsxs(Text, { dimColor: true, children: [
|
|
330
|
+
UI_SYMBOLS.SELECTED,
|
|
331
|
+
" "
|
|
332
|
+
] }),
|
|
333
|
+
!option.installed && /* @__PURE__ */ jsxs(Text, { dimColor: isDimmed, children: [
|
|
334
|
+
stateSymbol,
|
|
335
|
+
" "
|
|
336
|
+
] }),
|
|
337
|
+
option.label,
|
|
338
|
+
stateSuffix && /* @__PURE__ */ jsxs(Text, { dimColor: true, children: [
|
|
339
|
+
" ",
|
|
340
|
+
stateSuffix
|
|
341
|
+
] }),
|
|
342
|
+
" "
|
|
343
|
+
] })
|
|
344
|
+
}
|
|
345
|
+
);
|
|
346
|
+
};
|
|
347
|
+
var CategorySection = ({
|
|
348
|
+
category,
|
|
349
|
+
options,
|
|
350
|
+
isLocked,
|
|
351
|
+
isFocused,
|
|
352
|
+
focusedOptionIndex,
|
|
353
|
+
showDescriptions
|
|
354
|
+
}) => {
|
|
355
|
+
return /* @__PURE__ */ jsxs(Box, { flexDirection: "column", marginTop: 1, children: [
|
|
356
|
+
/* @__PURE__ */ jsxs(Box, { flexDirection: "row", children: [
|
|
357
|
+
/* @__PURE__ */ jsx(Text, { dimColor: isLocked, children: category.displayName }),
|
|
358
|
+
category.required && /* @__PURE__ */ jsxs(Text, { color: isLocked ? CLI_COLORS.NEUTRAL : CLI_COLORS.ERROR, dimColor: isLocked, children: [
|
|
359
|
+
" ",
|
|
360
|
+
SYMBOL_REQUIRED
|
|
361
|
+
] })
|
|
362
|
+
] }),
|
|
363
|
+
/* @__PURE__ */ jsx(Box, { flexDirection: "row", flexWrap: "wrap", marginTop: 0, children: options.map((option, index) => /* @__PURE__ */ jsxs(Box, { flexDirection: "column", children: [
|
|
364
|
+
/* @__PURE__ */ jsx(
|
|
365
|
+
SkillTag,
|
|
366
|
+
{
|
|
367
|
+
option,
|
|
368
|
+
isFocused: isFocused && index === focusedOptionIndex && !isLocked,
|
|
369
|
+
isLocked
|
|
370
|
+
}
|
|
371
|
+
),
|
|
372
|
+
showDescriptions && option.stateReason && !isLocked && /* @__PURE__ */ jsx(Box, { marginLeft: 1, marginBottom: 0, children: /* @__PURE__ */ jsx(Text, { dimColor: true, wrap: "truncate-end", children: option.stateReason }) })
|
|
373
|
+
] }, option.id)) })
|
|
374
|
+
] });
|
|
375
|
+
};
|
|
376
|
+
var estimateCategoryHeight = (category, terminalWidth) => {
|
|
377
|
+
const { CATEGORY_NAME_LINES, AVG_TAG_WIDTH, CATEGORY_MARGIN_LINES } = SCROLL_VIEWPORT;
|
|
378
|
+
const optionCount = category.sortedOptions.length;
|
|
379
|
+
const tagsPerRow = Math.max(1, Math.floor(terminalWidth / AVG_TAG_WIDTH));
|
|
380
|
+
const tagRows = Math.ceil(optionCount / tagsPerRow);
|
|
381
|
+
return CATEGORY_NAME_LINES + tagRows + CATEGORY_MARGIN_LINES;
|
|
382
|
+
};
|
|
383
|
+
var ScrollIndicator = ({ count, direction }) => {
|
|
384
|
+
if (count === 0) return null;
|
|
385
|
+
const arrow = direction === "above" ? UI_SYMBOLS.SCROLL_UP : UI_SYMBOLS.SCROLL_DOWN;
|
|
386
|
+
const label = `${arrow} ${count} more ${count === 1 ? "category" : "categories"} ${direction}`;
|
|
387
|
+
return /* @__PURE__ */ jsx(Box, { paddingLeft: 1, marginTop: direction === "below" ? 1 : 0, children: /* @__PURE__ */ jsx(Text, { dimColor: true, children: label }) });
|
|
388
|
+
};
|
|
389
|
+
var DEFAULT_TERMINAL_WIDTH = 80;
|
|
390
|
+
var CategoryGrid = ({
|
|
391
|
+
categories,
|
|
392
|
+
showDescriptions,
|
|
393
|
+
expertMode,
|
|
394
|
+
onToggle,
|
|
395
|
+
onToggleDescriptions,
|
|
396
|
+
defaultFocusedRow = 0,
|
|
397
|
+
defaultFocusedCol = 0,
|
|
398
|
+
onFocusChange,
|
|
399
|
+
availableHeight,
|
|
400
|
+
terminalWidth
|
|
401
|
+
}) => {
|
|
402
|
+
const processedCategories = useMemo2(
|
|
403
|
+
() => categories.map((category) => ({
|
|
404
|
+
...category,
|
|
405
|
+
sortedOptions: sortOptions(category.options, expertMode)
|
|
406
|
+
})),
|
|
407
|
+
[categories, expertMode]
|
|
408
|
+
);
|
|
409
|
+
const getColCount = useCallback2(
|
|
410
|
+
(row) => processedCategories[row]?.sortedOptions.length ?? 0,
|
|
411
|
+
[processedCategories]
|
|
412
|
+
);
|
|
413
|
+
const isRowLocked = useCallback2(
|
|
414
|
+
(row) => {
|
|
415
|
+
const cat = processedCategories[row];
|
|
416
|
+
return cat ? isSectionLocked(cat.id, categories) : false;
|
|
417
|
+
},
|
|
418
|
+
[processedCategories, categories]
|
|
419
|
+
);
|
|
420
|
+
const findValidCol = useCallback2(
|
|
421
|
+
(row, currentCol, direction) => {
|
|
422
|
+
const options = processedCategories[row]?.sortedOptions || [];
|
|
423
|
+
const catId = processedCategories[row]?.id;
|
|
424
|
+
if (catId && isSectionLocked(catId, categories)) return currentCol;
|
|
425
|
+
return findNextValidOption(options, currentCol, direction, true);
|
|
426
|
+
},
|
|
427
|
+
[processedCategories, categories]
|
|
428
|
+
);
|
|
429
|
+
const adjustCol = useCallback2(
|
|
430
|
+
(row, clampedCol) => {
|
|
431
|
+
const options = processedCategories[row]?.sortedOptions || [];
|
|
432
|
+
if (options[clampedCol]?.state === "disabled") {
|
|
433
|
+
return findValidStartColumn(options);
|
|
434
|
+
}
|
|
435
|
+
return clampedCol;
|
|
436
|
+
},
|
|
437
|
+
[processedCategories]
|
|
438
|
+
);
|
|
439
|
+
const { focusedRow, focusedCol, setFocused, moveFocus } = useFocusedListItem(
|
|
440
|
+
processedCategories.length,
|
|
441
|
+
getColCount,
|
|
442
|
+
{
|
|
443
|
+
wrap: true,
|
|
444
|
+
isRowLocked,
|
|
445
|
+
findValidCol,
|
|
446
|
+
adjustCol,
|
|
447
|
+
onChange: onFocusChange,
|
|
448
|
+
initialRow: defaultFocusedRow,
|
|
449
|
+
initialCol: defaultFocusedCol
|
|
450
|
+
}
|
|
451
|
+
);
|
|
452
|
+
useCategoryGridInput({
|
|
453
|
+
processedCategories,
|
|
454
|
+
categories,
|
|
455
|
+
focusedRow,
|
|
456
|
+
focusedCol,
|
|
457
|
+
setFocused,
|
|
458
|
+
moveFocus,
|
|
459
|
+
onToggle,
|
|
460
|
+
onToggleDescriptions
|
|
461
|
+
});
|
|
462
|
+
const { visibleItems, startIndex, hiddenAbove, hiddenBelow, isScrollable } = useVirtualScroll({
|
|
463
|
+
items: processedCategories,
|
|
464
|
+
availableHeight: availableHeight ?? Infinity,
|
|
465
|
+
focusedIndex: focusedRow,
|
|
466
|
+
estimateItemHeight: estimateCategoryHeight,
|
|
467
|
+
terminalWidth: terminalWidth ?? DEFAULT_TERMINAL_WIDTH
|
|
468
|
+
});
|
|
469
|
+
if (categories.length === 0) {
|
|
470
|
+
return /* @__PURE__ */ jsx(Box, { flexDirection: "column", children: /* @__PURE__ */ jsx(Text, { dimColor: true, children: "No categories to display." }) });
|
|
471
|
+
}
|
|
472
|
+
return /* @__PURE__ */ jsxs(Box, { flexDirection: "column", children: [
|
|
473
|
+
isScrollable && /* @__PURE__ */ jsx(ScrollIndicator, { count: hiddenAbove, direction: "above" }),
|
|
474
|
+
visibleItems.map((category, visibleIndex) => {
|
|
475
|
+
const originalIndex = startIndex + visibleIndex;
|
|
476
|
+
const isLocked = isSectionLocked(category.id, categories);
|
|
477
|
+
return /* @__PURE__ */ jsx(
|
|
478
|
+
CategorySection,
|
|
479
|
+
{
|
|
480
|
+
category,
|
|
481
|
+
options: category.sortedOptions,
|
|
482
|
+
isLocked,
|
|
483
|
+
isFocused: originalIndex === focusedRow,
|
|
484
|
+
focusedOptionIndex: focusedCol,
|
|
485
|
+
showDescriptions
|
|
486
|
+
},
|
|
487
|
+
category.id
|
|
488
|
+
);
|
|
489
|
+
}),
|
|
490
|
+
isScrollable && /* @__PURE__ */ jsx(ScrollIndicator, { count: hiddenBelow, direction: "below" })
|
|
491
|
+
] });
|
|
492
|
+
};
|
|
493
|
+
|
|
494
|
+
export {
|
|
495
|
+
CategoryGrid
|
|
496
|
+
};
|
|
497
|
+
//# sourceMappingURL=chunk-OGJIZ6QH.js.map
|