dsh-zen-remote 2.3.8 → 2.3.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (53) hide show
  1. package/CHANGELOG.md +41 -0
  2. package/README.md +2 -2
  3. package/README.zh-CN.md +2 -2
  4. package/docs/interface.md +1 -1
  5. package/docs/remote-access.en.md +1 -1
  6. package/docs/remote-access.md +1 -1
  7. package/lib/adapters/dsh-better-sidebar/index.js +21 -3
  8. package/lib/adapters/dsh-better-sidebar/index.js.map +1 -1
  9. package/lib/client.js +522 -89
  10. package/lib/types/adapters/dsh-better-sidebar/index.d.ts +1 -1
  11. package/lib/types/adapters/dsh-better-sidebar/index.d.ts.map +1 -1
  12. package/lib/types/client/MobileHome.d.ts.map +1 -1
  13. package/lib/types/client/MobileNavOverlay.d.ts.map +1 -1
  14. package/lib/types/client/MobileSessionHeader.d.ts.map +1 -1
  15. package/lib/types/client/effects/native-trigger-overlay.d.ts.map +1 -1
  16. package/lib/types/client/effects/permission-sheet.d.ts +51 -10
  17. package/lib/types/client/effects/permission-sheet.d.ts.map +1 -1
  18. package/lib/types/client/locales.d.ts +1 -0
  19. package/lib/types/client/locales.d.ts.map +1 -1
  20. package/lib/types/client/settings/SettingsSection.d.ts.map +1 -1
  21. package/lib/types/client/styles/chips.css.d.ts +1 -1
  22. package/lib/types/client/styles/chips.css.d.ts.map +1 -1
  23. package/lib/types/client/styles/composer.css.d.ts +1 -1
  24. package/lib/types/client/styles/composer.css.d.ts.map +1 -1
  25. package/lib/types/client/styles/header.css.d.ts +1 -1
  26. package/lib/types/client/styles/header.css.d.ts.map +1 -1
  27. package/lib/types/client/styles/home.css.d.ts +1 -1
  28. package/lib/types/client/styles/home.css.d.ts.map +1 -1
  29. package/lib/types/client/styles/layout.css.d.ts +1 -1
  30. package/lib/types/client/styles/layout.css.d.ts.map +1 -1
  31. package/lib/types/client/wizard/GatewayWizard.d.ts.map +1 -1
  32. package/lib/types/client-data/new-session.d.ts +26 -0
  33. package/lib/types/client-data/new-session.d.ts.map +1 -0
  34. package/lib/types/client-data/settings-form.d.ts +36 -0
  35. package/lib/types/client-data/settings-form.d.ts.map +1 -1
  36. package/package.json +1 -1
  37. package/scripts/check-settings-form.mjs +63 -0
  38. package/src/adapters/dsh-better-sidebar/index.ts +23 -3
  39. package/src/client/MobileHome.tsx +63 -8
  40. package/src/client/MobileNavOverlay.tsx +3 -1
  41. package/src/client/MobileSessionHeader.tsx +7 -1
  42. package/src/client/effects/native-trigger-overlay.ts +50 -11
  43. package/src/client/effects/permission-sheet.ts +199 -22
  44. package/src/client/locales.ts +2 -0
  45. package/src/client/settings/SettingsSection.tsx +43 -1
  46. package/src/client/styles/chips.css.ts +7 -2
  47. package/src/client/styles/composer.css.ts +24 -0
  48. package/src/client/styles/header.css.ts +58 -46
  49. package/src/client/styles/home.css.ts +6 -2
  50. package/src/client/styles/layout.css.ts +43 -2
  51. package/src/client/wizard/GatewayWizard.tsx +23 -1
  52. package/src/client-data/new-session.ts +30 -0
  53. package/src/client-data/settings-form.ts +57 -0
package/CHANGELOG.md CHANGED
@@ -5,6 +5,47 @@
5
5
  [GitHub Releases](https://github.com/KyoMio/dsh-zen-remote/releases)(tag 驱动自动生成)。
6
6
  界面半边的细节叙事另见 [`docs/interface.md`](docs/interface.md) 的「更新日志」一节。
7
7
 
8
+ ## 2.3.10(2026-11-06)
9
+
10
+ ### 修复
11
+
12
+ - **适配 DSH 0.2.2-rc.1 移动端会话页空屏与首页设置按钮失灵**:DSH 0.2.2-rc.1 的
13
+ `AppFrame` 给主栏显式设置 `grid-area: 1/2`(落入移动端单列网格的 `0px` 第 2 列导致进入
14
+ 会话一片空白),并在 `< 768px` 新增 `[data-sidebar-mask]`(作为首个子元素挤掉原先
15
+ `:first-child` 侧栏选择器)、`[data-shell-leading]` 左上角悬浮按钮与侧栏 `inert` /
16
+ `visibility: hidden`。现将主栏显式钉回第 1 列(`grid-area: 1 / 1`)、按稳定类名后缀
17
+ `[class$="_sidebarCol"]` 匹配侧栏并隐藏宿主遮罩与左上角悬浮按钮,同时在手机壳下剥离侧栏
18
+ `inert` 属性,恢复会话页正常渲染及首页设置按钮、底部芯片代点。
19
+
20
+ ## 2.3.9(2026-11-05)
21
+
22
+ ### 新增
23
+
24
+ - **适配 `dsh-better-sidebar` 0.30.0**:适配器新增 `/sidebar/sidechat-image` 旁聊图片路由适配,
25
+ 并为多图载荷设置转发上限,旧版侧边栏插件的行为不受影响。
26
+ - **手机端新建会话先定工作区(UX-3)**:点「+ 新建会话」直接进无工作区空会话时,
27
+ 手机端此前会卡在英雄区 inert 的「选择工作区」状态。现在点下 FAB 先做决定:
28
+ 已选工作区直接开;零或一个工作区直接用唯一值(无工作区的宿主保持原样可用);
29
+ 多个工作区且未选时,FAB 先弹出与标题栏一致的工作区底部抽屉,选好才开始会话。
30
+ 工作区切换瞬间(建会话 → `replaceMain` 重挂载)输入栏短暂锁定置灰
31
+ (上限 1.5s 自动解锁),防止消息落在旧空会话上被重挂载抹掉、界面弹回占位态。
32
+ - **首次激活子客户端后自动重载页面(UX-1)**:页面三条常驻全局流在加载时打开,
33
+ 后端的流拦截器要等插件行重载后才装上——已打开的流不被包装,服务端的远程会话
34
+ 从此进不了侧边栏。现在首次配对或保存把角色切到 client 后,等待
35
+ `client/status` 就绪(最多 3 秒)即自动重载;已是 client 的重新配对、写盘未落、
36
+ 旧服务端(无诊断应答)都保持不重载。
37
+
38
+ ### 修复
39
+
40
+ - **手机端任务/子代理弹出层点错位(UX-2)**:活动胶囊的触发器选择器此前先命中
41
+ 面包屑的父会话切换器(同为 tree 弹层、文档序更靠前),胶囊上盖的是错误按钮;
42
+ 弹出层也不再跟随胶囊位置。现在按类名后缀精确锁定目录触发器,并把触发器及其
43
+ 锚点容器(同步 `z-index: 3` 层叠上下文)钉在活动胶囊的固定视口矩形上,弹出层
44
+ 即随胶囊出现;同时固定左上角返回按钮在智能体团队按钮左侧并隐去后者文字标签。
45
+ - **手机端右侧栏初始引导页纵向滚动**:当注册的侧边栏标签页变多超出屏幕高度时,
46
+ 宿主引导页(`[data-sidebar-right-guide]`)此前因居中溢出与外层 `overflow: hidden`
47
+ 裁切导致排在前面的入口无法看到或点击,现支持完整上下滚动。
48
+
8
49
  ## 2.3.8(2026-11-03)
9
50
 
10
51
  ### 兼容
package/README.md CHANGED
@@ -66,7 +66,7 @@ dsh plugin --profile web add dsh-zen-remote
66
66
  // ~/.dsh/profiles/desktop/package.json
67
67
  {
68
68
  "dependencies": {
69
- "dsh-zen-remote": "^2.3.8" // for local development: "link:/path/to/dsh-zen-remote"
69
+ "dsh-zen-remote": "^2.3.10" // for local development: "link:/path/to/dsh-zen-remote"
70
70
  }
71
71
  }
72
72
  ```
@@ -295,7 +295,7 @@ Legacy environment variables (outrank row settings): `LAN_GATE_PORT`, `LAN_GATE_
295
295
 
296
296
  | Plugin | Adaptation summary | Version tested |
297
297
  | --- | --- | --- |
298
- | [dsh-better-sidebar](https://github.com/omdsh-dev/DSH-better-sidebar) | Full-screen mobile right-sidebar drawer with notch safe-area padding and swipe-back; **Plugin Bridge** built-in adapter for `0.25.0` through `0.28.2` (seven versions) (reads/writes host file/Git/task panels in remote sessions with host owner consent) | 0.19.1 / adapter 0.25–0.28.2 |
298
+ | [dsh-better-sidebar](https://github.com/omdsh-dev/DSH-better-sidebar) | Full-screen mobile right-sidebar drawer with notch safe-area padding and swipe-back; **Plugin Bridge** built-in adapter for `0.25.0` through `0.30.0` (eight versions) (reads/writes host file/Git/task panels in remote sessions with host owner consent) | 0.19.1 / adapter 0.25–0.30.0 |
299
299
  | [@nanmicoder/dsh-agent-teams](https://github.com/NanmiCoder/dsh-agent-teams) | Repositions AgentTeams floating pill below session header and preserves parent session back-link | 0.1.9 |
300
300
  | [@ychris12138/dsh-usage-stats](https://github.com/Ychris12138/dsh-usage-stats) | Moves usage & balance entry into the mobile home chips bar | 0.2.9 |
301
301
  | [@opendsh/dsh-plugin-scheduled-tasks](https://github.com/Ceelog/dsh-plugins) | Moves scheduled tasks entry into the mobile home chips bar | 0.2.3 |
package/README.zh-CN.md CHANGED
@@ -66,7 +66,7 @@ dsh plugin --profile web add dsh-zen-remote
66
66
  // ~/.dsh/profiles/desktop/package.json
67
67
  {
68
68
  "dependencies": {
69
- "dsh-zen-remote": "^2.3.8" // 本地开发换成 "link:/path/to/dsh-zen-remote"
69
+ "dsh-zen-remote": "^2.3.10" // 本地开发换成 "link:/path/to/dsh-zen-remote"
70
70
  }
71
71
  }
72
72
  ```
@@ -296,7 +296,7 @@ cd ~/.dsh/profiles/desktop && pnpm install
296
296
 
297
297
  | 插件 | 移动端与远程适配内容 | 实测版本 |
298
298
  | --- | --- | --- |
299
- | [dsh-better-sidebar](https://github.com/omdsh-dev/DSH-better-sidebar) | 移动端右栏全屏抽屉、左缘滑回与安全区避让;**插件桥**内置适配 `0.25.0` 至 `0.28.2` 七版(服务端授权后远程会话可直接读写服务端文件/Git/任务面板) | 0.19.1 / 适配器 0.25–0.28.2 |
299
+ | [dsh-better-sidebar](https://github.com/omdsh-dev/DSH-better-sidebar) | 移动端右栏全屏抽屉、左缘滑回与安全区避让;**插件桥**内置适配 `0.25.0` 至 `0.30.0` 八版(服务端授权后远程会话可直接读写服务端文件/Git/任务面板) | 0.19.1 / 适配器 0.25–0.30.0 |
300
300
  | [@nanmicoder/dsh-agent-teams](https://github.com/NanmiCoder/dsh-agent-teams) | AgentTeams 活动浮层避让会话顶栏、子代理头部保留父会话一键返回 | 0.1.9 |
301
301
  | [@ychris12138/dsh-usage-stats](https://github.com/Ychris12138/dsh-usage-stats) | 用量与余额入口收进手机主屏 chips 行 | 0.2.9 |
302
302
  | [@opendsh/dsh-plugin-scheduled-tasks](https://github.com/Ceelog/dsh-plugins) | 定时任务入口收进手机主屏 chips 行 | 0.2.3 |
package/docs/interface.md CHANGED
@@ -391,7 +391,7 @@ PWA,再进来就是冷启动。插件自己的边缘手势也触发不了—
391
391
  ## 兼容插件
392
392
 
393
393
  - [dsh-better-sidebar](https://github.com/omdsh-dev/DSH-better-sidebar)(0.19+:它的全部 tab 都在 DSH 0.1.5 官方右侧栏里,手机上宿主自己切全屏,本插件在会话页头部给它留入口位、左缘回退手势收它、文件树里点 @ 引用后自动收起——面板全屏盖住会话页,草稿变化看不见,收起本身就是点击反馈;≤ 0.18 自绘右栏的老版本:全宽抽屉 + 安全区 + 底部关闭 pill,只在 DSH < 0.1.5 上还会走到)——本机实测 **0.19.1**(老版规则实测 0.15.0)
394
- - dsh-better-sidebar 的**远程会话处理**(PB-12 起分两档):**0.25.0、0.26.0、0.26.1、0.28.0-alpha.0、0.28.0、0.28.1 与 0.28.2** 七版由 zen-remote 的内置适配器(`src/adapters/dsh-better-sidebar/`)**代理**——它的文件浏览、编辑器、git 变动、任务等界面在远程会话里读写的是主服务端的数据(整机数据,需主服务端主人在设置页同意;`open.external` 远程拒绝、`settings.*` 与 `/sidebar/bundle` 留本机、侧聊转发(子会话继承父会话共享);0.26 新方法已一并接入(`fs.readPage` 分页读、`sidechat.dequeue` 撤回排队消息、`sidechat.model`/`sidechat.models` 线程切模型、`/sidebar/write` 编辑器保存;0.28.1 再添 `git.history` 分页提交历史读;0.28.2 接口面不变,只把 detached 会话的 cwd 改为读存储 header(不再整份解码会话日志);`ws/sidechat` 侧聊推送也已桥接(PB-26b:升级 URL 不带参数、会话 id 在连接后的 JSON 帧里,客户端把 watch 帧里的虚拟 id 还原成真实 id 才转发,插件推送的 `threadId` 换算回虚拟 id 才给浏览器,未共享的线程 id 在两侧都会被拒、连接即断)))。**其他版本维持隐藏**:那些版本的界面都带 `{sessionId, cwd}` 语境调它自己的 `/sidebar/api/*` 接口,远程会话里这些请求落到子客户端本机——文件树会显示本机同名文件、编辑会真的写本机文件;远程会话(`html[data-zr-remote-session="1"]`)里按插件自己的挂载/渲染标记隐藏这些界面,选择器在 `src/client/styles/remote-session.css.ts`,未安装时一条都不命中。因为它接管了宿主的「文件」标签,未桥接的远程会话里暂时没有侧栏文件浏览;聊天或交付物里的文件链接(`dsh-resource://file/**`)会被它的编辑器注册抢先接住,展开一个空的右栏(根治要等 zen-remote 自己的远程文件树)。隐藏档的定位仍是**隐藏而非代理**:插件组件保持挂载并继续静默发只读请求,但所有写控件都在被隐藏的界面里,不会误写本机。PB-14 起显示规则按桥接状态生效:已桥接(0.25.0/0.26.0 且主服务端同意)时远程会话里**照常显示**(面板数据经适配器来自主服务端,隐藏规则全部让位);未桥接时维持隐藏,已打开的 tab 空态改为一行说明占位(better-sidebar 未在远程会话桥接——中英双语,随浏览器语言),空白工作台浮动按钮一并隐藏
394
+ - dsh-better-sidebar 的**远程会话处理**(PB-12 起分两档):**0.25.0、0.26.0、0.26.1、0.28.0-alpha.0、0.28.0、0.28.1、0.28.2 与 0.30.0** 八版由 zen-remote 的内置适配器(`src/adapters/dsh-better-sidebar/`)**代理**——它的文件浏览、编辑器、git 变动、任务等界面在远程会话里读写的是主服务端的数据(整机数据,需主服务端主人在设置页同意;`open.external` 远程拒绝、`settings.*` 与 `/sidebar/bundle` 留本机、侧聊转发(子会话继承父会话共享);0.26 新方法已一并接入(`fs.readPage` 分页读、`sidechat.dequeue` 撤回排队消息、`sidechat.model`/`sidechat.models` 线程切模型、`/sidebar/write` 编辑器保存;0.28.1 再添 `git.history` 分页提交历史读;0.28.2 接口面不变,只把 detached 会话的 cwd 改为读存储 header(不再整份解码会话日志);`ws/sidechat` 侧聊推送也已桥接(PB-26b:升级 URL 不带参数、会话 id 在连接后的 JSON 帧里,客户端把 watch 帧里的虚拟 id 还原成真实 id 才转发,插件推送的 `threadId` 换算回虚拟 id 才给浏览器,未共享的线程 id 在两侧都会被拒、连接即断)))。**其他版本维持隐藏**:那些版本的界面都带 `{sessionId, cwd}` 语境调它自己的 `/sidebar/api/*` 接口,远程会话里这些请求落到子客户端本机——文件树会显示本机同名文件、编辑会真的写本机文件;远程会话(`html[data-zr-remote-session="1"]`)里按插件自己的挂载/渲染标记隐藏这些界面,选择器在 `src/client/styles/remote-session.css.ts`,未安装时一条都不命中。因为它接管了宿主的「文件」标签,未桥接的远程会话里暂时没有侧栏文件浏览;聊天或交付物里的文件链接(`dsh-resource://file/**`)会被它的编辑器注册抢先接住,展开一个空的右栏(根治要等 zen-remote 自己的远程文件树)。隐藏档的定位仍是**隐藏而非代理**:插件组件保持挂载并继续静默发只读请求,但所有写控件都在被隐藏的界面里,不会误写本机。PB-14 起显示规则按桥接状态生效:已桥接(0.25.0/0.26.0 且主服务端同意)时远程会话里**照常显示**(面板数据经适配器来自主服务端,隐藏规则全部让位);未桥接时维持隐藏,已打开的 tab 空态改为一行说明占位(better-sidebar 未在远程会话桥接——中英双语,随浏览器语言),空白工作台浮动按钮一并隐藏
395
395
  - [@nanmicoder/dsh-agent-teams](https://github.com/NanmiCoder/dsh-agent-teams)(AgentTeams 活动浮层:手机端挪到会话头部下方、避开安全区,会话列表页隐藏;子代理会话头部保留可点的父会话面包屑用于切回)——本机实测 **0.1.9**
396
396
  - [@ychris12138/dsh-usage-stats](https://github.com/Ychris12138/dsh-usage-stats)(用量与余额,主屏 chips 行可直接打开;旧包名 `dsh-usage-stats` 已废弃,两个名字同时留在 profile 里会因重复的 `usage-stats` 行让 DSH 起不来)——本机实测 **0.2.9**
397
397
  - [@opendsh/dsh-plugin-scheduled-tasks](https://github.com/Ceelog/dsh-plugins)(定时任务,主屏 chips 行自动收割入口)——本机实测 **0.2.3**
@@ -335,7 +335,7 @@ The `/v1/http` route is a second allowlist, keyed by **route name** (not part of
335
335
  - Terminals are deliberate (a desktop client is a trusted device): what opens is a **server-side** PTY running as the server user, without the agent sandbox or approval restrictions; closing the session's remote access kills its terminal streams with it;
336
336
  - `workspaceFiles/read` and friends are not contained to the session directory (DSH itself does not contain them) — anything the server process can read is readable, under the same trusted-device premise as terminals;
337
337
  - The plugin bridge's whole-machine data requires the server owner's per-plugin consent — the toggles in the settings page's Plugin bridge section, everything OFF by default; the loopback carries the operator's cookie, so a bridged plugin sees the same permissions the local browser sees. The bridge's boundary is therefore the DECLARED route set (exact equality, plus a `prefix: true` route's sub-paths under the PB-23b raw-byte tail red line) plus the share table — there is **no** parameter-level scanning;
338
- - **Adapters (better-sidebar)**: beyond cooperative declarations, zen-remote ships a built-in adapter for `dsh-better-sidebar` **the seven versions 0.25.0 through 0.28.2** (`src/adapters/` — non-cooperative third-party plugins are bridged by it, with prefix/path-segment route matching and session-id rewriting in JSON bodies and path segments). A prefix hit's tail passes the shape red line: `?`/`#`/`..` (encoded forms included) or whitespace answers 400 `bad-request` (PB-23b, the same rule as the cooperative segment). **Consenting to its whole-machine toggle hands the paired desktop client whole-disk file read/write on the server, git write operations (commit, push, revert, …), and model spend through commit-message generation** — the product decision is "both directions forward, no path fencing", and a server owner should treat that toggle as terminal-grade trust in the paired machine; `open.external` (launching processes on the host) refuses for remote sessions, `settings.*` and `/sidebar/bundle` stay on the sub-client's own machine; the three WebSockets (`/sidebar/ws/fs-watch` file-tree watch, `/sidebar/ws/agent-opens` open push, `/sidebar/ws/sidechat` side-chat push) bridge over the byte tunnel — the first two carry the session id in their upgrade URL's query and their frames pass through untouched (the browser never reads the session id inside a push); `ws/sidechat`'s upgrade URL carries NO parameter at all — the ids ride the JSON text frames sent after the handshake (`{"op":"watch","threadIds":[…]}`), through the per-frame gate (PB-26b): the client rewrites every virtual id in a watch frame back to its real form before forwarding (an empty array = unsubscribe-all, passes verbatim), the server share-checks EVERY text frame before the plugin sees one (an unshared thread id never reaches the plugin — the connection dies), and the plugin's pushed `{"threadId":…}` top-level id is virtualized before it reaches the browser (better-sidebar's subscription comparison demands the exact virtual id); side chat (`sidechat.*`) forwards — its child sessions carry `meta.parentSession`, so they inherit the parent's share through the ancestor chain, and the `childId` in `sidechat.start`'s answer is virtualized before it reaches the browser; 0.28's (alpha.0 and stable) `changes.ops` long-poll (`wait: true`, parks up to 25 s — past the relay's 15 s header wait) has `wait` stripped on the server, so a remote session's "this round's files" view polls on 0.26's 2.5 s cadence; `sidechat.models` shows the **sub-client's own** model catalog in the picker while the choice goes through `sidechat.model` and takes effect on the **server** — when the two machines' catalogs differ, what the server actually applies is authoritative;
338
+ - **Adapters (better-sidebar)**: beyond cooperative declarations, zen-remote ships a built-in adapter for `dsh-better-sidebar` **the eight versions 0.25.0 through 0.30.0** (`src/adapters/` — non-cooperative third-party plugins are bridged by it, with prefix/path-segment route matching and session-id rewriting in JSON bodies and path segments). A prefix hit's tail passes the shape red line: `?`/`#`/`..` (encoded forms included) or whitespace answers 400 `bad-request` (PB-23b, the same rule as the cooperative segment). **Consenting to its whole-machine toggle hands the paired desktop client whole-disk file read/write on the server, git write operations (commit, push, revert, …), and model spend through commit-message generation** — the product decision is "both directions forward, no path fencing", and a server owner should treat that toggle as terminal-grade trust in the paired machine; `open.external` (launching processes on the host) refuses for remote sessions, `settings.*` and `/sidebar/bundle` stay on the sub-client's own machine; the three WebSockets (`/sidebar/ws/fs-watch` file-tree watch, `/sidebar/ws/agent-opens` open push, `/sidebar/ws/sidechat` side-chat push) bridge over the byte tunnel — the first two carry the session id in their upgrade URL's query and their frames pass through untouched (the browser never reads the session id inside a push); `ws/sidechat`'s upgrade URL carries NO parameter at all — the ids ride the JSON text frames sent after the handshake (`{"op":"watch","threadIds":[…]}`), through the per-frame gate (PB-26b): the client rewrites every virtual id in a watch frame back to its real form before forwarding (an empty array = unsubscribe-all, passes verbatim), the server share-checks EVERY text frame before the plugin sees one (an unshared thread id never reaches the plugin — the connection dies), and the plugin's pushed `{"threadId":…}` top-level id is virtualized before it reaches the browser (better-sidebar's subscription comparison demands the exact virtual id); side chat (`sidechat.*`) forwards — its child sessions carry `meta.parentSession`, so they inherit the parent's share through the ancestor chain, and the `childId` in `sidechat.start`'s answer is virtualized before it reaches the browser; 0.28's (alpha.0 and stable) `changes.ops` long-poll (`wait: true`, parks up to 25 s — past the relay's 15 s header wait) has `wait` stripped on the server, so a remote session's "this round's files" view polls on 0.26's 2.5 s cadence; `sidechat.models` shows the **sub-client's own** model catalog in the picker while the choice goes through `sidechat.model` and takes effect on the **server** — when the two machines' catalogs differ, what the server actually applies is authoritative;
339
339
  - Concurrent streams are budgeted per device (32), and so are invokes kept in flight at once — past the per-device cap the invoke answers 429 `too-many-invokes`. Error codes shaped `*/internal` (`gateway/internal` and friends) are returned as the bare code with no message — that kind of message quotes server-side internals. Event answers are matched against the subscription and device they were forwarded to. Approval/question forwarding is **first come, first served**: whichever of the server's own UI and the sub-client answers first wins; the later answer is refused by the gateway and the client syncs to "already handled". The relay **never answers on the client's behalf**: an unshared session's approval/question events are not forwarded at all, and with the server's own UI offline too, the approval simply keeps waiting — the gateway re-delivers still-pending events to the next `$events` subscriber. A wait, never a rejection (an abstention would fail every pending approval of the session at once and break the push → wake → approve flow). Notification-type events (EMIT frames: session-list summaries, account expirations and other server-wide state) of an unshared session are never forwarded.
340
340
 
341
341
 
@@ -372,7 +372,7 @@ sudo cloudflared service install # 通了再装成常驻服务
372
372
  - 终端是有意开放的(桌面应用端是可信设备):开的是**服务端**的 PTY,以服务端用户身份运行、不受智能体沙箱与审批限制;关闭会话的远程时终端流一并终止;
373
373
  - `workspaceFiles/read` 等文件预览接口不限制在会话目录内(DSH 自身就不限制),服务端进程可读的文件都能读——信任前提与终端相同;
374
374
  - 插件桥的整机数据需要主服务端主人逐插件同意——设置页「插件桥」里的开关,缺省全部关闭;回环执行带操作者 cookie,插件接口看到的权限与本机浏览器相同,因此桥接的边界就是声明登记的路径(exact 相等,`prefix: true` 路由含其子路径,前缀尾巴还要过 PB-23b 的原样字节形状红线)加会话共享表,**不做**参数级扫描;
375
- - **适配器(better-sidebar)**:协作声明之外,zen-remote 为 `dsh-better-sidebar` **0.25.0 至 0.28.2 的七个版本**内置了一个适配器(`src/adapters/`,不配合的第三方插件由它代为桥接,路由按前缀/路径段匹配、会话 id 在 JSON 体与路径段里改写)。前缀命中的尾巴过形状红线:`?`/`#`/`..`(含编码形态)或空白一律 400 `bad-request`(PB-23b,与协作段同一条)。**同意它的整机数据开关,等于让已配对的桌面应用端读写主服务端整盘文件、执行 git 写操作(提交、推送、回滚……),并通过提交信息生成消耗主服务端的模型额度**——产品上的决定就是「读写都接、不加路径围栏」,主服务端主人应当把它当成给对方一台本机终端级别的信任来开;`open.external`(在宿主机起进程)对远程会话拒绝,`settings.*` 与 `/sidebar/bundle` 留在子客户端本机;三条 WebSocket(`/sidebar/ws/fs-watch` 文件树监视、`/sidebar/ws/agent-opens` 打开推送、`/sidebar/ws/sidechat` 侧聊推送)经字节隧道桥接——前两条的升级 URL 带会话 query,帧原样透传(浏览器不消费推送里的会话 id);`ws/sidechat` 的升级 URL 不带任何参数,会话 id 在连接建立后的 JSON 文本帧里(`{"op":"watch","threadIds":[…]}`),走逐帧闸门(PB-26b):客户端把 watch 帧里的虚拟 id 逐个还原成真实 id 再转发(空数组 = 全部退订,原样放行),服务端对每个文本帧先按共享表核对、通过才交给插件(未共享的线程 id 到不了插件,连接即断),插件推回的 `{"threadId":…}` 顶层 id 换算回虚拟 id 才给浏览器(better-sidebar 的订阅比对要求虚拟 id 精确匹配);侧聊(`sidechat.*`)转发——侧聊子会话带 `meta.parentSession`,按祖先链自动继承父会话的共享,`sidechat.start` 响应里的 `childId` 会换算成虚拟 id 回给浏览器;0.28(alpha.0 与正式版)的 `changes.ops` 长轮询(`wait: true`,最长挂 25 秒,超过中继 15 秒的响应头等待)在服务端去掉 `wait`,远程会话的「本轮文件」退回 0.26 的 2.5 秒轮询;`sidechat.models` 的模型选择器显示的是**子客户端本机**的模型目录,而选择经 `sidechat.model` 作用在**服务端**——两机目录不一致时以服务端实际生效为准;
375
+ - **适配器(better-sidebar)**:协作声明之外,zen-remote 为 `dsh-better-sidebar` **0.25.0 至 0.30.0 的八个版本**内置了一个适配器(`src/adapters/`,不配合的第三方插件由它代为桥接,路由按前缀/路径段匹配、会话 id 在 JSON 体与路径段里改写)。前缀命中的尾巴过形状红线:`?`/`#`/`..`(含编码形态)或空白一律 400 `bad-request`(PB-23b,与协作段同一条)。**同意它的整机数据开关,等于让已配对的桌面应用端读写主服务端整盘文件、执行 git 写操作(提交、推送、回滚……),并通过提交信息生成消耗主服务端的模型额度**——产品上的决定就是「读写都接、不加路径围栏」,主服务端主人应当把它当成给对方一台本机终端级别的信任来开;`open.external`(在宿主机起进程)对远程会话拒绝,`settings.*` 与 `/sidebar/bundle` 留在子客户端本机;三条 WebSocket(`/sidebar/ws/fs-watch` 文件树监视、`/sidebar/ws/agent-opens` 打开推送、`/sidebar/ws/sidechat` 侧聊推送)经字节隧道桥接——前两条的升级 URL 带会话 query,帧原样透传(浏览器不消费推送里的会话 id);`ws/sidechat` 的升级 URL 不带任何参数,会话 id 在连接建立后的 JSON 文本帧里(`{"op":"watch","threadIds":[…]}`),走逐帧闸门(PB-26b):客户端把 watch 帧里的虚拟 id 逐个还原成真实 id 再转发(空数组 = 全部退订,原样放行),服务端对每个文本帧先按共享表核对、通过才交给插件(未共享的线程 id 到不了插件,连接即断),插件推回的 `{"threadId":…}` 顶层 id 换算回虚拟 id 才给浏览器(better-sidebar 的订阅比对要求虚拟 id 精确匹配);侧聊(`sidechat.*`)转发——侧聊子会话带 `meta.parentSession`,按祖先链自动继承父会话的共享,`sidechat.start` 响应里的 `childId` 会换算成虚拟 id 回给浏览器;0.28(alpha.0 与正式版)的 `changes.ops` 长轮询(`wait: true`,最长挂 25 秒,超过中继 15 秒的响应头等待)在服务端去掉 `wait`,远程会话的「本轮文件」退回 0.26 的 2.5 秒轮询;`sidechat.models` 的模型选择器显示的是**子客户端本机**的模型目录,而选择经 `sidechat.model` 作用在**服务端**——两机目录不一致时以服务端实际生效为准;
376
376
  - 每台设备并发流数有上限(32)、同时在途的 invoke 数也有上限(32,超出 429 `too-many-invokes`);`*/internal` 形状的错误码(`gateway/internal` 等)只回码不带消息——那类消息引用的是服务端内部细节。事件应答按「转发时的订阅 + 设备」核对归属。审批/提问的转发是**先到先得**:服务端自己的界面和子客户端谁先应答谁生效,后答的一方被网关拒绝、同步成「已处理」。中继**不代答**:未共享会话的审批/提问事件不会被转发,服务端界面也不在线时这个审批就一直等待——网关会把仍未应答的事件转交给下一个连上来的订阅,等,而不是替你拒绝(代答会把整批待审批一次性判死,砸掉「推送 → 唤醒 → 审批」链路)。未共享会话的**通知类**事件(EMIT 帧:会话列表摘要、账号到期之类的服务端全局状态)一律不转发;唯一的例外是已共享会话(含其子会话)的 `api-session/status`——它只描述单个会话的运行/空闲,逐帧按共享表判定,子客户端靠它在主机侧一轮开始或结束时同步运行状态徽标(断线期间的翻转由重连后补拉列表纠正)。
377
377
 
378
378
 
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * The dsh-better-sidebar adapter (PB-12), written against EXACTLY
3
- * versions 0.25.0, 0.26.0, 0.26.1, 0.28.0-alpha.0, 0.28.0, 0.28.1 and 0.28.2 (PB-15 widened the list; 0.26.1 is a
3
+ * versions 0.25.0, 0.26.0, 0.26.1, 0.28.0-alpha.0, 0.28.0, 0.28.1, 0.28.2 and 0.30.0 (PB-15 widened the list; 0.26.1 is a
4
4
  * perf-only patch with the same wire surface as 0.26.0; 0.26.0 is a JSON-api
5
5
  * superset of 0.25.0 — it grows fs.readPage and the sidechat dequeue/model/
6
6
  * models methods, and moves fs.write's content onto the new raw-text
@@ -38,6 +38,13 @@ import { SIDEBAR_METHODS, sidebarMethodNameOf } from './methods.js';
38
38
  * `MAX_BODY_BYTES = 1 << 20`) — the adapter forwards at most what the
39
39
  * backend would accept anyway. */
40
40
  const SIDEBAR_MAX_BODY_BYTES = 1024 * 1024;
41
+ /** 0.30.0: a `sidechat.prompt` carrying images reads its body under
42
+ * `sidechatPromptBodyLimit` (lib/index.js:7004) — 1 MiB of metadata plus the
43
+ * base64 of at most SIDECHAT_MAX_MESSAGE_IMAGE_BYTES = 20 MiB of images and
44
+ * 4 bytes per image (≤ 8). Every other method keeps the plugin's own 1 MiB
45
+ * (`readJsonBody`'s default), so the route cap only has to admit this one
46
+ * ceiling; the backend still enforces the per-method limit itself. */
47
+ const SIDEBAR_IMAGE_PROMPT_MAX_BODY_BYTES = SIDEBAR_MAX_BODY_BYTES + 4 * Math.ceil((20 * 1024 * 1024) / 3) + 4 * 8;
41
48
  /** The method name out of a `/sidebar/api/*` pathname, or `''`. */
42
49
  const apiMethodOf = (pathname) => sidebarMethodNameOf(pathname) ?? '';
43
50
  export const dshBetterSidebarAdapter = {
@@ -65,7 +72,13 @@ export const dshBetterSidebarAdapter = {
65
72
  // full-log `sessionQuery.observeSession`, then the host defaultDirectory,
66
73
  // and only then a client `cwd` hint — so the server hook's cwd stripping
67
74
  // below stays correct (if anything, the client hint matters less).
68
- versions: ['0.25.0', '0.26.0', '0.26.1', '0.28.0-alpha.0', '0.28.0', '0.28.1', '0.28.2'],
75
+ // 0.30.0 (DSH 0.2.2-rc.1+): same JSON-api method set and WebSockets; one
76
+ // new EXACT GET route, `/sidebar/sidechat-image?childId&messageId&blockIndex`
77
+ // (lib/index.js:9869-9896), which streams a saved side-chat image — bridged
78
+ // below on its `childId`. `sidechat.prompt` grows an `images` array (base64,
79
+ // up to ~27.7 MiB body) — the api route cap widens to that. GenUI, quote
80
+ // chips and editor draft backup are client-only (no new host routes).
81
+ versions: ['0.25.0', '0.26.0', '0.26.1', '0.28.0-alpha.0', '0.28.0', '0.28.1', '0.28.2', '0.30.0'],
69
82
  // PB-19 (ADR-0003): the wire-surface whitelist. Keys are digest16 over the
70
83
  // PB-18 extractor's reduction (`surface.ts` beside this file) of the npm
71
84
  // builds' lib/index.js, computed off /tmp/bs-versions/{version}/lib/index.js:
@@ -73,6 +86,7 @@ export const dshBetterSidebarAdapter = {
73
86
  // 96465143373a31a7 — the 0.26.0 generation (0.26.1 hashes identically)
74
87
  // 6ed29a896101e681 — the 0.28.0 generation (0.28.0-alpha.0 identically)
75
88
  // 65a0acaeb56f87d9 — the 0.28.1 generation (0.28.2 identically)
89
+ // 394de9f588d37092 — the 0.30.0 generation (+ /sidebar/sidechat-image)
76
90
  // An installed version outside `versions` still registers when its build
77
91
  // hashes into one of these (a wire-identical patch release bridges without
78
92
  // a zen-remote release); anything else fails closed to the unlisted-version
@@ -83,6 +97,7 @@ export const dshBetterSidebarAdapter = {
83
97
  '96465143373a31a7': 'the 0.26.0 generation (0.26.1 identical)',
84
98
  '6ed29a896101e681': 'the 0.28.0 generation (0.28.0-alpha.0 identical)',
85
99
  '65a0acaeb56f87d9': 'the 0.28.1 generation (0.28.2 identical)',
100
+ '394de9f588d37092': 'the 0.30.0 generation',
86
101
  },
87
102
  routes: [
88
103
  {
@@ -92,7 +107,7 @@ export const dshBetterSidebarAdapter = {
92
107
  path: '/sidebar/api',
93
108
  match: 'prefix',
94
109
  methods: ['POST'],
95
- maxBody: SIDEBAR_MAX_BODY_BYTES,
110
+ maxBody: SIDEBAR_IMAGE_PROMPT_MAX_BODY_BYTES,
96
111
  locator: { in: 'json-body', fields: ['sessionId', 'rootSessionId', 'childId'] },
97
112
  deny: ({ pathname, currentSessionId }) => {
98
113
  const name = apiMethodOf(pathname);
@@ -117,6 +132,9 @@ export const dshBetterSidebarAdapter = {
117
132
  // claims the EXACT documented path — a sub-path (if a future version
118
133
  // grows one) stays local rather than being guessed at.
119
134
  { path: '/sidebar/file', match: 'exact', methods: ['GET'], locator: { in: 'query', name: 'sessionId' } },
135
+ // 0.30.0: a saved side-chat image (lib/index.js:9869-9896) — the child
136
+ // session id rides the query; the answer is raw image bytes with no ids.
137
+ { path: '/sidebar/sidechat-image', match: 'exact', methods: ['GET'], locator: { in: 'query', name: 'childId' } },
120
138
  // The archive download (lib/index.js:6949-6985).
121
139
  { path: '/sidebar/archive', match: 'exact', methods: ['GET'], locator: { in: 'query', name: 'sessionId' } },
122
140
  // The raw upload (lib/index.js:6905-6948): binary bytes, capped by the
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/adapters/dsh-better-sidebar/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgCG;AAGH,OAAO,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAA;AAC/C,OAAO,EAAE,g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