
Security News
Deno Goes the Way of the Dinosaur
Cloudflare is acquiring Deno’s team, which will provide another year of bug fixes and security updates before ending support for the runtime.
dsh-input-enhancer
Advanced tools
DeepSeek Harness plugin that enhances the web chat composer: lock Enter-send to prevent accidental sends. IME-safe and per-session.
中文 | English
一个 DeepSeek Harness Web 插件,让聊天输入框更适合长文本编辑。
| 功能 | 说明 | 触发方式 |
|---|---|---|
| 🔒 锁定 Enter 发送 | 锁定后按 Enter 不会误发消息,仍可正常编辑 | 点击锁按钮 / Cmd/Ctrl+Alt+L |
| ⚡ 三击发送 | 连按 3 次 Enter(每次间隔 ≤800ms)解锁并立即发送 | 锁定态按回车 |
| 🔢 字数统计 | 输入框非空时,锁按钮后方实时显示字符总数 | 自动 |
| ⚠️ 长文本提醒 | 超过 800 字时,字数徽标变琥珀色警示,发送前一眼看清长度 | 自动 |
| 🔐 自动锁定 / 解锁 | 字数超过 80 时自动锁定;输入框清空时自动解锁 | 自动 |
| ⇄ 草稿交换 | 在输入框与暂存区之间交换内容,暂存半成品草稿留到后续轮次再发 | 点击交换按钮 / Cmd/Ctrl+Opt+K |
conversation.input.right 槽位,位于输入框右下角、发送按钮附近;锁定为醒目红色填充,悬浮可看当前状态提示。也可用快捷键 Ctrl/Cmd+Alt+L 切换(仅在输入框聚焦时生效)。AUTO_LOCK_ENABLED / AUTO_LOCK_THRESHOLD)。字数从 ≤80 上升到 >80 的那一次变化(上升沿)自动锁定;输入框被完全清空(字数归 0)时自动解锁。锁没有「手动 / 自动」来源之分,锁上就是锁上了——两条沿只负责加锁/解锁,其他中间状态(删到非零字数、或在 80 上下波动)不改变锁状态。清空解锁后再次输入并越过 80 会重新自动锁。此「80 锁」与上一条「800 提醒」互相独立。| 状态 | 锁图标 | 输入框 | Enter 行为 |
|---|---|---|---|
| 解锁 | 灰色描边 | 默认大小 | 正常发送 |
| 锁定 | 红色填充 + 白色锁图标 | 默认大小 | 不发送(连按 3 次可解锁并发送) |
悬浮提示:
已解锁,输入框为默认大小,Enter 可正常发送已锁定,Enter 不会发送;连按 3 次 Enter 可解锁并立即发送锁定状态下临时想发送,无需先点锁:连按 3 次 Enter 即可解锁并立即发送。
三击仅对锁定态生效;空输入框不会发送空消息。
agent 还在思考/执行时,你往往想先把「下一轮要说的话」打在输入框里。但有时打到一半才意识到——这份草稿要等几轮之后才该发。此时用一个无方向的交换按钮(⇄)把它暂存起来,继续写别的、发送,等合适的轮次再取回继续编辑。
conversation.input.right 槽位,位于锁按钮左侧;图标为 ⇄(双箭头互换,无方向语义)。点一下即在「输入框」和「暂存区」之间交换内容。Cmd+Opt+K(macOS)/ Ctrl+Alt+K(Windows/Linux,另见下方相邻快捷键提示)等价于点击交换按钮,仅在输入框聚焦时生效。两个按钮都在输入框内时,若输入框有字、暂存区也有字,点交换会把两者对调,请按需使用。
Enter、Ctrl+Enter / Cmd+Enter、其他触发官方提交路径的 Enter 组合。Shift+Enter 换行、IME 候选词确认、编辑/复制/粘贴/附件、鼠标点发送按钮(锁只防键盘误触)。Ctrl+Alt+L(Windows/Linux)或 Cmd+Alt+L(macOS)可切换当前输入框的锁定状态,无需鼠标点锁按钮。仅在输入框聚焦时生效。
为什么不是
Ctrl/Cmd+L:Chrome / Edge 把Ctrl+L、macOS 把Cmd+L保留给地址栏,浏览器会先截获;故改用Ctrl/Cmd+Alt+L避开冲突。
Ctrl+Alt+K(Windows/Linux)或 Cmd+Opt+K(macOS)可触发草稿交换。仅在输入框聚焦时生效。
相邻快捷键提示:
Cmd/Ctrl+Opt/Alt+K(草稿交换)与Cmd/Ctrl+Opt/Alt+L(锁定)相邻,且 Opt 即 Alt,容易误触——若频繁误按,可优先用对应的图标按钮。
0.1.2-alpha.1(已验证版本;0.1.0-rc.6 亦可运行);web profile;本插件通过
[data-composer-card]、[data-composer-input]、[role="listbox"]等 DSH 内核内部 DOM 契约工作(源码里集中在src/client.js顶部的SEL常量表)。DSH0.1.2-alpha.1把输入框从<textarea>升级为 Lexicalcontenteditable宿主(data-composer-input/role="textbox"),插件已适配;升级 DSH 到更高版本后,若锁定/字数/暂存/候选菜单相关行为异常,请先对这些功能做一次回归,并核对SEL表中的选择器是否仍与内核一致。
dsh plugin --profile web add dsh-input-enhancer
建议锁定到具体版本以保证可重复安装:
dsh plugin --profile web add 'dsh-input-enhancer@1.1.0'
dsh plugin --profile web add github:qiqiangvae/dsh-input-enhancer
也可以显式使用 Git URL:
dsh plugin --profile web add https://github.com/qiqiangvae/dsh-input-enhancer.git
建议锁定到某个 commit 以保证可重复安装:
dsh plugin --profile web add 'github:qiqiangvae/dsh-input-enhancer#<commit-sha>'
git clone https://github.com/qiqiangvae/dsh-input-enhancer.git
dsh plugin --profile web add ./dsh-input-enhancer
dsh --profile web --dump-config | grep dsh-input-enhancer
应能看到类似输出:
# == dsh-input-enhancer
- id: dsh-input-enhancer
name: dsh-input-enhancer
安装完成后重启 dsh web 并刷新页面。
启动 DeepSeek Harness Web:
dsh web
在聊天输入框右下角、模型选择器和发送按钮附近找到锁形按钮。
锁定 / 解锁方式:
Ctrl+Alt+L(Windows/Linux)/ Cmd+Alt+L(macOS),仅在输入框聚焦时生效。锁定状态下:
Enter:不发送。Ctrl+Enter / Cmd+Enter:不发送。Shift+Enter:仍然插入换行。Enter(每次间隔 800ms 内):解锁并立即发送(前两下锁图标变「1」「2」闪烁,第三下触发解锁爆炸动画)。锁状态按会话独立保存,刷新页面或重启后自动清除。
字数统计与锁状态无关:只要输入框非空(无论锁没锁),锁按钮后方都会实时显示字符数徽标。
暂存半成品草稿:
Cmd+Opt+K(macOS)/ Ctrl+Alt+K(Windows/Linux);插件默认零配置,不需要填写 API Key、设置项或 settings.yaml。锁状态与暂存区内容仅保存在浏览器内存中。
settings.yaml,不发起网络请求。conversation.input.right 槽位,不替换官方 composer。确认插件已挂载:
dsh --profile web --dump-config | grep dsh-input-enhancer
重启 dsh web 并强制刷新页面(Ctrl+F5)。
确认当前使用的是 web profile。
Ctrl+Alt+L(Windows/Linux)或 Cmd+Alt+L(macOS),而不是 Ctrl/Cmd+L(被浏览器地址栏占用)。Ctrl+Alt+L 用于系统级操作(如锁屏/切换布局),此时该组合会被系统截获;请改用锁按钮。Shift+Enter 是换行,不是发送。dsh plugin --profile web remove dsh-input-enhancer
安装本仓库不需要构建:lib/ 已提交预构建产物,且没有 prepare / postinstall 脚本。
如需修改源码后重新生成构建产物:
npm run build # 生成 lib/index.js 与 lib/client.js
npm run check # 结构检查
dsh-input-enhancer/
├── package.json # dsh.bundle + dsh.client 插件声明
├── cordis.patch.yml # profile bundle patch
├── src/
│ ├── index.js # Host 半部(无依赖 no-op)
│ └── client.js # Web 半部:分层编排(锁 feature + 字数统计 + 长文本提醒 + 草稿交换)
├── lib/ # 构建产物
├── scripts/
│ ├── build.mjs
│ └── check.mjs
├── README.md
├── README.en.md
└── LICENSE
本插件由 dsh-enter-lock 更名并增强而来。若你之前安装了旧名插件,请先卸载再安装本插件:
dsh plugin --profile web remove dsh-enter-lock
dsh plugin --profile web add github:qiqiangvae/dsh-input-enhancer
相较 dsh-enter-lock,本插件新增:
Cmd/Ctrl+Opt/Alt+K,在输入框与暂存区之间交换半成品草稿(每会话单槽、内存态)。FAQs
DeepSeek Harness plugin that enhances the web chat composer: lock Enter-send to prevent accidental sends. IME-safe and per-session.
The npm package dsh-input-enhancer receives a total of 11 weekly downloads. As such, dsh-input-enhancer popularity was classified as not popular.
We found that dsh-input-enhancer demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.

Security News
Cloudflare is acquiring Deno’s team, which will provide another year of bug fixes and security updates before ending support for the runtime.

Security News
Anthropic’s free OSS Scanner uses Mythos and other Claude models to find open source vulnerabilities and send maintainers reports with proposed fixes.

Security News
On Front Lines’ Early Adopters: CISO podcast, Andrew Becherer shares lessons from Datadog, weighs the long-term costs of AI-built tools, and explains how founders can actually gain a CISO’s trust.