All plugins

DSH / BUNDLE / CLIENT-UI

dsh-chat-ctxmenu

v1.0.3kingofpowers / dsh-chat-ctxmenu3be37ad260

InstallableBundlesUI & client pluginsCommunity · Topic auto-analysisWeb UI

Overview

dsh-chat-ctxmenu

Right-click conversation content to copy text or images, open file paths, and reveal them in the file manager.

README / EN

Package documentation

Registry summary

Right-click conversation content to copy text or images, open file paths, and reveal them in the file manager.

dsh.pub verifies the pinned bundle contract, runtime facts, and distribution semantics. The complete README remains in the source repository.

Read the full README on GitHub

LIMITATIONS

Known limitations

- 依赖对话节点带 `data-chat-flow-kind` 标记;若未来 DSH 改动该标记,菜单会静默不触发(不会误弹)。诊断时先看 `/status` 与会话 DOM。 - 纯正文里无分隔符、无反引号的单词文件名(如「改一下 index.js」)只有在**会话工作目录下确实存在同名文件**时才会出现打开项;这是刻意避免误判。 - 一次菜单最多解析 8 个候选路径,取第一个真实存在的;同一文本块出现多个候选时只接受唯一的绝对路径,避免「点 A 打开 B」。 - 未加引号、含空格的 Windows 路径会同时提交「截断版 + 扩展版」两个候选,由 Host 取存在的那个。 - 代码块内的 `path:line` / `path:line:col` 会剥离行号后再解析,行号只用于菜单标题展示。 - `用其他应用打开 ▸` 的列表来自系统注册信息(默认程序会标注「默认」);列表为空时仍提供「选择其他程序…」(Windows)。 - **Windows 上「用其他应用打开」的实现**:系统注册信息里的应用 id 就是该应用的 exe 路径。Harness 原生的 `openFileApplication` 走 `IHandler::Invoke(IDataObject)`,多数 Win32 处理器没有实现该调用(会抛错或静默不启动),所以本插件对「已注册为打开方式且 id 是 exe 路径」的应用直接 `spawn(exe, [file])`;UWP/AUMID 等非 exe id 仍走原生通道。选择前会先用系统注册列表校验该 id 确实注册为此文件的打开方式,未注册的 id 一律拒绝(防止伪造请求拉起任意程序)。若直接启动失败,会再尝试一次原生通道并回报具体错误,不会假报成功。 - **修改插件代码后的生效方式**:`plugin_manager remove_bundle` → `install_bundle` 可让 Host 半边热更新;浏览器端需要刷新页面(client 半在页面引导时加载)。只改 `client.js` 也要重新安装,否则页面拿到的仍是旧 bundle。