Skip to content

feat(workbench): 工程列自动展开与 Preview 标签(#1964 #1966) - #1979

Merged
DeliciousBuding merged 2 commits into
masterfrom
feat/engineering-column-surface
Aug 25, 2026
Merged

feat(workbench): 工程列自动展开与 Preview 标签(#1964 #1966)#1979
DeliciousBuding merged 2 commits into
masterfrom
feat/engineering-column-surface

Conversation

@DeliciousBuding

Copy link
Copy Markdown
Collaborator

背景

UIUX 基准(docs/reference/ux-benchmark-2026-08.md)F4/F9 两个 P1 项。同一文件域(workbench 工程列/auxPanel/布局偏好),按域分组集成例外合为一个 PR。

Closes #1964
Closes #1966

#1964 active run 自动展开工程列(UX F4)

  • 新增 useEngineeringColumnAutoOpenengineeringColumnActivitySignal 聚合 isAgentRunning 与 runtime evidence(diff/artifacts/previews loading、最新产物);信号出现且视口允许时自动展开工程列。
  • 偏好持久化:workbenchPreferences.ts 新增按会话的 {collapsed, autoOpenSuppressed}(localStorage,坏数据 fail-closed,不跨会话泄漏)。用户在运行中手动收回 → 本会话抑制后续自动弹出;纯聊天收回不产生抑制;切换会话恢复各自选择。
  • 窄视口保护:Desktop < 880 / Web < 720 不自动展开;头部按钮与全局快捷键(toggle-run-panel)走同一手动 toggle 合同,quick-open 始终展开。
  • 无 active run/产物的纯聊天不改变现有默认布局。
  • 测试:useEngineeringColumnAutoOpen.test.tsx + workbenchPreferences.test.ts(含持久化、抑制、会话隔离、窄视口)。

terminal dock 口径:terminal dock 无折叠状态(shouldRenderTerminalDock 仅按 isChatPage + localTerminal 能力门控,Desktop 聊天页恒显,#1182/#1825),因此自动展开合同落在工程列(inspector 列);dock 不存在"默认不展开"的缺口。

#1966 工程列 Preview 标签(UX F9)

  • auxPanel 新增 preview 标签(会话/文件/变更/预览/提交,resolveAvailableAuxTabs 新维度 previewAvailable)。
  • 最新规范化 preview/artifact evidence 出现时自动聚焦 Preview;同一 evidence 不打断用户已选标签;新产物才重新聚焦。
  • 两表面同步规则(写入 docs/architecture/04-frontend-data-flow.md §工程列焦点合同):Preview 不修改 RightInspector 详情标签;仅显式"在详情中查看 / View details"经 WORKBENCH_INSPECTOR_QUICK_OPEN_EVENT 请求 inspector 切换 Browser/Files。
  • 诚实降级:无 evidence 时 Preview 显示不可用占位并禁用详情按钮,不构造 URL/内容;Web 仅在 Hub 提供规范化 evidence 时挂载 Preview 表面(保持 Hub-only,不获得本地文件能力)。
  • i18n:engineering.* 中英键位一致;原硬编码中文标签全部收口 i18n。
  • 测试:ChatEngineeringColumn.test.tsx(聚焦/不打架/键盘可达/详情桥接/诚实空态)、resolveAuxTabs.test.tsAuxPanel.test.tsxWorkbenchFrameParts.test.tsx(Web Hub-only 挂载)、inspector.test.tsx 断言更新。

验证

  • 串行 vitest(--no-file-parallelism --maxWorkers=1):workbench 全量 142 files / 1399 tests 绿;shared 全量 152 files / 2636 tests 绿。
  • pnpm --filter @agenthub/workbench typecheck@agenthub/shared typecheck 绿。
  • python scripts/verify/verify-i18n-callsites.py PASS;python scripts/verify/verify-doc-ssot.py ok(04-frontend-data-flow.md 新合同段已压缩至 150 行预算内);openapi.yaml parse ok。
  • Visual QA shell(1440x810 light+dark,另含 Web 768x900 / Desktop 800x900 窄视口合同):web + desktop capture + assert 均 ok,无横向溢出。Preview 标签仅在有 evidence 时出现(诚实口径),其行为由上述单测覆盖,shell gate 覆盖工程列表面几何。

隐私

diff 已扫描:无内部主机名、真实服务器路径、密钥。

Co-authored-by: Codex <codex@vectorcontrol.tech>
@coderabbitai

coderabbitai Bot commented Aug 25, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 57bb98a8-eee6-48a1-b4c9-aeb4e6796c83

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Co-authored-by: Codex <codex@vectorcontrol.tech>
@DeliciousBuding
DeliciousBuding force-pushed the feat/engineering-column-surface branch from 344b3c1 to 229e8ae Compare August 25, 2026 07:31
@DeliciousBuding
DeliciousBuding merged commit 528b869 into master Aug 25, 2026
40 checks passed
@DeliciousBuding
DeliciousBuding deleted the feat/engineering-column-surface branch August 25, 2026 07:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(workbench): 工程列 Preview 标签(UX F9) feat(workbench): active run 自动展开工程列(UX F4)

1 participant