fix(client): intercept the alpha chat file-open funnel (remote.session.openWorkspacePath)

0.1.2-alpha 宿主删除了 ctx.workspaces.openPath,聊天文件点击全部改走
remote 命名空间,旧拦截成为死代码(点击穿透到 xdg-open)。改为在
ctx.inject(['remote.session']) 内以 defineProperty 遮蔽该方法(accessor
属性,赋值无效),接管时返回 RemoteResult 成功包络。语义不变,

设计:docs/plans/2026-08-31-openpath-intercept-alpha-design.md
This commit is contained in:
Cyancat authored and Menghuan1918 committed 2026-09-02 23:13:57 +08:00
1 parent dde0923980
commit 26d37c1a8f
9 files changed
+425 -126

No files matched your search

+4 -2
View File
@@ -34,8 +34,10 @@ import './layout.css'
* (rc.8+) is the client module system the chunk loader resolves its
* externals through; `connection` (0.1.2-alpha.2+) is the Remote transport's
* recovery lifecycle the side chat's disconnect banner reads — Cordis guards
* service access without inject. */
export const inject = ['slots', 'sessions', 'workspaces', 'locale', 'modules', 'connection']
* service access without inject. The `remote.session` namespace is NOT here:
* it mounts asynchronously, so the open-path interception reaches it through
* `ctx.inject` (see intercept.tsx). */
export const inject = ['slots', 'sessions', 'locale', 'modules', 'connection']
/**
* Error boundary over the sidebar tree (root scope): a render error in the