dshbase

插件目录 / UI & Skins / dsh-esc-enter

dsh-esc-enter

已验证 · 实测可装 Liangebra

✓ 持续维护

查看 GitHub ↗ ← 返回插件目录

0Stars
0Forks
0未关闭 issue
—语言
2026-08-22最近推送
跨平台平台

功能简介

opencode-style UX: Esc cancels the running turn in the DeepSeek Harness Web UI (Enter-while-busy handled by built-in setting)

✅
我们的评价
可用 — 实测通过,早期项目

opencode-style UX: Esc cancels the running turn in the DeepSeek Harness Web UI (Enter-while-busy handled by built-in setting) 实测能干净安装、正常启动。早期项目,但功能可用。

「已验证」表示我们的自动化 CI 在干净 profile 里实际执行了 dsh plugin add 并启动成功——仅此而已。功能描述与版本兼容性均为作者声明。这不是安全审计,也不代表对第三方代码的背书。

README

dsh-esc-enter

opencode 式 UX:Esc 取消当前任务 + composer 追加/停止按钮 — DeepSeek Harness Web UI 插件。

Press Esc while the agent is running to cancel the current turn — the same action as the Stop button (Session.cancel()), keeping queued work for later turns.

Esc 取消当前回合(与"停止"按钮同机制,队列里未跑的工作保留到下一回合)。运行时在输入框旁的 dock 槽渲染 追加 / 停止 两个按钮。

特性 / Features

  • Esc = 退出当前任务:agent 运行中按 Esc 立即取消当前回合
  • 追加按钮:agent 运行中把当前输入框草稿提交为队列指令(inputActions.submit(),busy-append 路径)——不打断当前回合,草稿为空时禁用
  • 停止按钮:agent 运行中取消当前回合(session.cancel(),同宿主停止/Esc 机制)
  • 两按钮仅运行中显示(与 Esc 守卫一致),空闲时隐藏保持 composer 干净
  • Enter 行为不重复实现:busy 时 Enter 是"追加指令"(queue)还是"打断"(steer),由 DSH 内置的「Enter behavior while busy」设置负责
  • 空闲时不拦截 Esc:命令菜单 / 弹层照常关闭
  • 挂载于 conversation.composer.dock 槽,无宿主逻辑,纯客户端

安装 / Install

dsh plugin --profile web add github:Liangebra/dsh-esc-enter

重启 dsh web 并硬刷新浏览器(Ctrl/Cmd+Shift+R)。

工作原理 / How it works

Client bundle 监听 conversation.composer.dock 槽位:

  • 当 ConversationSnapshot.running === true 时,渲染「追加 / 停止」两个按钮,并注册 document 级 capture 阶段的 keydown 监听,命中 Esc 即调用 sessions.binding(sessionId).session.cancel()(与停止按钮同一路径)。
  • 「追加」按钮调槽位标准 prop inputActions.submit()(提交当前草稿,busy 时按 DSH 的 queue 语义追加到待发队列);草稿为空时禁用。
  • 「停止」按钮调用 sessions.binding(sessionId).session.cancel();空闲时两按钮与 Esc 监听一并撤销。

协议 / License

MIT

安装

🧩 让 Agent 自动装(推荐)

装一次目录插件,之后本站所有插件都能让 DeepSeek Harness 自动找、自动装:

dsh plugin add dshbase-catalog

然后对 agent 说「帮我装 dsh-esc-enter」,它会在目录里找到并自动安装。文档:dshbase-catalog · 已验证场景包。

该插件是 GitHub 源码(未发 npm)——直接从仓库装:

Web profile:

dsh plugin --profile web add github:Liangebra/dsh-esc-enter

Headless(CLI)profile:

dsh plugin --profile headless add github:Liangebra/dsh-esc-enter

实测报告

验证通过:从 GitHub 源码完成 L1 安装 + L2 加载 + L3 运行(dsh 0.1.0-rc.6)。

安全:尚未扫描——我们的每日静态扫描将很快覆盖它。

分享徽章

UI & Skins 里更多

浏览全部 7819 个插件 →