[ Feature Request ] Richer UI options in mods (ANSI support, spinners, layout helpers)
还没有人认领这个 Issue。
评估
- 难度
- 5/5
- 预计耗时
- 一周以上
- 新手友好度
- 35/100
- Issue 类型
- 功能
- 描述清晰度
- 基本清楚
- 活跃度
- 冷清
- 技术栈
- bun, node.js, typescript
调研方向
首先跟踪 Mod Harness API cmd.ui.select() 和 cmd.ui.notify(),然后检查阻止 ora 和 @clack/prompts 控制 TTY 的 sandbox 约束。完成的标准是为 ANSI 标题、原生 spinner 以及通过 cmd.ui 暴露的 divider 或 panel helper 定义并测试出一种方案。
由索引模型根据 Issue 内容生成。
描述
Summary
When building interactive mods, we are limited to displaying raw text strings inside "cmd.ui.select()" and "cmd.ui.notify()". Creating structured layouts or showing background progress currently requires custom ASCII drawing or raw terminal printing, which is complex to keep aligned and does not support native-looking animations like spinners.
Expected Behavior
We would love to see the Mod Harness UI (cmd.ui) enriched with standard CLI primitives:
- ANSI Color Support: Allow titles inside selectors to parse standard color codes (e.g. using
chalkor ANSI codes) to highlight choices or display clean warnings. - Native Spinners: A simple loading indicator API for long-running processes (e.g., repository checks, configuration setups):
const spinner = cmd.ui.spinner("Loading configuration..."); await task(); spinner.success("Done!");
3.Layout Primitives: Simple helper functions to display dividers or panels without having to manually calculate character lengths and borders in strings.
Providing these primitives natively would allow developers to build premium, consistent community mods that look and feel like built-in features of Command Code.
Actual Behavior
Installing standard Node/Bun packages like ora or @clack/prompts, but they require direct TTY controls which the harness sandbox does not permit.
Steps to reproduce the issue
- create a mod
Command Code Version
1.4.2
Operating System
macOS
Terminal/IDE
ghostty
Shell
command
Additional context
No response
- 主要语言
- 没有语言数据
- 星标
- 4k
- 派生
- 350
- PR 合并指标
- 30 天内没有已合并 PR
贡献指南
这个仓库没有索引到贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
CommandCodeAI/command-code 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 68/100
CommandCodeAI/command-code#855 ·
-
难度 2/5 1-3 小时 新手友好度 78/100
CommandCodeAI/command-code#841 · 1 条评论 ·
-
难度 2/5 1-3 小时 新手友好度 68/100
CommandCodeAI/command-code#655 · 1 条评论 ·
-
难度 2/5 1-3 小时 新手友好度 68/100
CommandCodeAI/command-code#608 ·
-
难度 3/5 1-2 天 新手友好度 70/100
CommandCodeAI/command-code#893 ·
查看 CommandCodeAI/command-code 的全部 Issue
相似的 Issue
-
难度 1/5 1 小时以内 新手友好度 92/100
milvus-io/birdwatcher#545 ·
-
难度 2/5 1-3 小时 新手友好度 88/100
-
area:tools bug good first issue help wanted priority:P2
难度 2/5 1-3 小时 新手友好度 90/100
TaewoooPark/Motifcode#14 ·
-
bug
难度 2/5 1-3 小时 新手友好度 84/100
newrelic-experimental/preflight#793 · 1 条评论 ·
-
难度 2/5 1-3 小时 新手友好度 88/100
caddyserver/caddy#8046 ·