tui: /sessions hides the current-session indicator when the current session is running
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 新手友好度
- 68/100
- Issue 类型
- 缺陷
- 描述清晰度
- 描述清楚
- 活跃度
- 活跃
- 技术栈
- typescript
- 领域
- frontend
调研方向
阅读 packages/tui/src/component/dialog-session-list.tsx 和 packages/tui/src/ui/dialog-select.tsx,然后比较会话状态栏和当前会话标记的呈现方式。查看 #63954 中相关的选择行为作为背景。完成标准是当前正在运行的会话在 /sessions 中仍能被清楚识别;验证运行中和需要关注状态的显示效果。
由索引模型根据 Issue 内容生成。
描述
Summary
When opening the TUI session switcher (/sessions / Ctrl+X L) while the current session is running, the current-session indicator (▪, the blue rectangle) disappears completely, leaving no visual indication of which session you were on. Combined with /sessions opening with the selection highlight on the top row rather than the current session (#63954), switching sessions while work is running is confusing and disorienting.
Environment
- opencode version: 2.4.2
- Client: TUI
- Model and provider: Not relevant
- OS: Linux 7.0.0-44-generic (x86_64)
- Terminal: TERM_PROGRAM=tmux, TERM=tmux-256color, COLORTERM=truecolor
- Shell: /bin/bash
- Install/channel: latest
- Active plugins:
~/.config/opencode/plugins/alice-and-bot/index.js(no terminal plugins incli.json)
Reproduction
- Open OpenCode TUI (
v2.4.2, defaultnew-designsenabled) with multiple sessions in the session list. - Send a prompt in the current session so it enters the
runningstate (or has a running child session). - While it is still running, open the session switcher with
/sessionsorCtrl+X L. - Observe the row for the session you were just viewing and which row is initially highlighted/marked.
Expected Behavior
- The current session should remain clearly marked (e.g., showing the current-session indicator
▪alongside or distinct from the running spinner, and/or distinct styling) even while it is running or awaiting attention. - The active/current-session marker and focus should clearly identify the session you are currently in, rather than leaving focus on another row at the top of the list with no current-session indicator visible.
Actual Behavior
- While the current session is running, the running spinner replaces the gutter and suppresses the current-session
▪indicator completely. - Because
new-designsalso does not tint the title text forprops.current, the current running session is visually indistinguishable from any other running session in the list. - Because
/sessionsalso passesfocusCurrent={false}, the selection bar (┃/ row highlight) sits on the top session in the list instead of the current session, making it easy to lose track of where you were.
Additional Context
- Reproducible consistently on
v2.4.2. - Code pointers (
v2.4.2):packages/tui/src/ui/dialog-select.tsx:DialogSelectRowrenders the▪current indicator only whenprops.current && !props.gutter, and only colors title text forprops.currentwhen!newDesigns().packages/tui/src/component/dialog-session-list.tsx:sessionStatusGutter(...)returns a<Spinner />(or!/?attention icon) asgutter, which makesprops.guttertruthy and hides the current-session indicator. The samesessionStatusGutterpattern is used inpackages/tui/src/component/dialog-open.tsx.- Related: #63954 (
focusCurrent={false}indialog-session-list.tsxplaces the initial selection on row 0 instead of the current session).
- 主要语言
- TypeScript
- 星标
- 228k
- 派生
- 31k
- 平均合并
- 5 小时 19 分钟
- 30 天内合并 PR
- 457
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
anomalyco/opencode 的其他 Issue
-
tui: Mermaid renderer displays <b>/<strong> tags literally and ignores \n line breaks可能已有人在做 @argszero 今天认领。 未关闭area/tui platform/wsl status/repro-simulated type/bug version/v2
难度 2/5 1-3 小时 新手友好度 82/100
anomalyco/opencode#66773 · 2 条评论 ·
维护者通常 1 天内回复
-
area/sdk-api platform/linux type/feature version/v2
难度 2/5 1-3 小时 新手友好度 76/100
anomalyco/opencode#66604 · 1 条评论 ·
维护者通常 1 天内回复
-
area/web inference/go reproduced type/bug
难度 2/5 1-3 小时 新手友好度 84/100
anomalyco/opencode#66475 · 1 条评论 ·
维护者通常 1 天内回复
-
[FEATURE]: More colorful built-in Dracula theme for the desktop app可能重新可做 关联的 PR 已关闭且未合并。 未关闭area/desktop type/feature version/v2
难度 2/5 1-3 小时 新手友好度 68/100
anomalyco/opencode#66446 · 1 条评论 ·
维护者通常 1 天内回复
-
scripts: path comparisons break on Windows (check-greys fails the pre-push hook, upgrade-opentui skips nothing)可能已有人在做 @deosiree 于 2 天前认领。 未关闭platform/windows status/repro-plausible type/bug version/v2
难度 2/5 1-3 小时 新手友好度 76/100
anomalyco/opencode#66192 · 2 条评论 ·
维护者通常 1 天内回复
查看 anomalyco/opencode 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 67/100
knaw-huc/textannoviz#742 ·
-
难度 2/5 1-3 小时 新手友好度 88/100
cloudflare/realtimekit-ui#219 ·
维护者通常 1 天内回复
-
ui
难度 2/5 1-3 小时 新手友好度 78/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 82/100
mermaid-js/mermaid-v13#1370 ·
维护者通常 1 天内回复
-
area:docs area:plugins bug documentation low-priority platform:windows
难度 1/5 1 小时以内 新手友好度 84/100
anthropics/claude-code#112676 ·