@cerbur/clutch-dsh-worktree 0.1.6 → 0.1.7

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 (116) hide show
  1. package/README.md +107 -15
  2. package/README.zh.md +86 -10
  3. package/cordis.patch.yml +21 -0
  4. package/lib/client/WorktreeContext.d.ts.map +1 -1
  5. package/lib/client/WorktreeContext.js +2 -2
  6. package/lib/client/WorktreeContext.js.map +1 -1
  7. package/lib/client/WorktreeSurface.d.ts +2 -2
  8. package/lib/client/WorktreeSurface.d.ts.map +1 -1
  9. package/lib/client/WorktreeSurface.js +270 -65
  10. package/lib/client/WorktreeSurface.js.map +1 -1
  11. package/lib/client/entry.d.ts.map +1 -1
  12. package/lib/client/entry.js +84 -2
  13. package/lib/client/entry.js.map +1 -1
  14. package/lib/client/index.d.ts +3 -0
  15. package/lib/client/index.d.ts.map +1 -1
  16. package/lib/client/index.js +2 -0
  17. package/lib/client/index.js.map +1 -1
  18. package/lib/client/locales.d.ts +58 -0
  19. package/lib/client/locales.d.ts.map +1 -1
  20. package/lib/client/locales.js +58 -0
  21. package/lib/client/locales.js.map +1 -1
  22. package/lib/client/session-view.d.ts +34 -0
  23. package/lib/client/session-view.d.ts.map +1 -1
  24. package/lib/client/session-view.js +119 -1
  25. package/lib/client/session-view.js.map +1 -1
  26. package/lib/client/worktree-connection.d.ts +4 -2
  27. package/lib/client/worktree-connection.d.ts.map +1 -1
  28. package/lib/client/worktree-connection.js +4 -0
  29. package/lib/client/worktree-connection.js.map +1 -1
  30. package/lib/client/worktree-error-copy.d.ts +2 -0
  31. package/lib/client/worktree-error-copy.d.ts.map +1 -1
  32. package/lib/client/worktree-error-copy.js +16 -0
  33. package/lib/client/worktree-error-copy.js.map +1 -1
  34. package/lib/client/worktree-permission-icon.d.ts +7 -0
  35. package/lib/client/worktree-permission-icon.d.ts.map +1 -0
  36. package/lib/client/worktree-permission-icon.js +119 -0
  37. package/lib/client/worktree-permission-icon.js.map +1 -0
  38. package/lib/client/worktree-permission.d.ts +21 -0
  39. package/lib/client/worktree-permission.d.ts.map +1 -0
  40. package/lib/client/worktree-permission.js +70 -0
  41. package/lib/client/worktree-permission.js.map +1 -0
  42. package/lib/client/worktree-session-fork.d.ts +65 -0
  43. package/lib/client/worktree-session-fork.d.ts.map +1 -0
  44. package/lib/client/worktree-session-fork.js +174 -0
  45. package/lib/client/worktree-session-fork.js.map +1 -0
  46. package/lib/client/worktree-session-order.d.ts +36 -0
  47. package/lib/client/worktree-session-order.d.ts.map +1 -0
  48. package/lib/client/worktree-session-order.js +215 -0
  49. package/lib/client/worktree-session-order.js.map +1 -0
  50. package/lib/client/worktree-session.d.ts +34 -1
  51. package/lib/client/worktree-session.d.ts.map +1 -1
  52. package/lib/client/worktree-session.js +98 -2
  53. package/lib/client/worktree-session.js.map +1 -1
  54. package/lib/client/worktree-surface-rows.d.ts +4 -4
  55. package/lib/client/worktree-surface-rows.d.ts.map +1 -1
  56. package/lib/client/worktree-surface-rows.js +132 -47
  57. package/lib/client/worktree-surface-rows.js.map +1 -1
  58. package/lib/client/worktree-surface-selectors.d.ts +2 -0
  59. package/lib/client/worktree-surface-selectors.d.ts.map +1 -1
  60. package/lib/client/worktree-surface-selectors.js +8 -0
  61. package/lib/client/worktree-surface-selectors.js.map +1 -1
  62. package/lib/client/worktree-surface-types.d.ts +46 -3
  63. package/lib/client/worktree-surface-types.d.ts.map +1 -1
  64. package/lib/client/worktree-view-actions.d.ts +8 -3
  65. package/lib/client/worktree-view-actions.d.ts.map +1 -1
  66. package/lib/client/worktree-view-actions.js +28 -2
  67. package/lib/client/worktree-view-actions.js.map +1 -1
  68. package/lib/client/worktree-view-errors.d.ts +10 -0
  69. package/lib/client/worktree-view-errors.d.ts.map +1 -1
  70. package/lib/client/worktree-view-errors.js +22 -1
  71. package/lib/client/worktree-view-errors.js.map +1 -1
  72. package/lib/client.js +1473 -201
  73. package/lib/client.js.map +1 -1
  74. package/lib/contract/index.contract.js +2 -0
  75. package/lib/contract/index.contract.js.map +1 -1
  76. package/lib/contract/index.d.ts +6 -2
  77. package/lib/contract/index.d.ts.map +1 -1
  78. package/lib/contract/index.js +4 -0
  79. package/lib/contract/index.js.map +1 -1
  80. package/lib/contract/worktree-permission.d.ts +73 -0
  81. package/lib/contract/worktree-permission.d.ts.map +1 -0
  82. package/lib/contract/worktree-permission.js +32 -0
  83. package/lib/contract/worktree-permission.js.map +1 -0
  84. package/lib/host/index.d.ts +4 -0
  85. package/lib/host/index.d.ts.map +1 -1
  86. package/lib/host/index.js +2 -0
  87. package/lib/host/index.js.map +1 -1
  88. package/lib/host/remote.d.ts +2 -2
  89. package/lib/host/remote.d.ts.map +1 -1
  90. package/lib/host/remote.js +7 -1
  91. package/lib/host/remote.js.map +1 -1
  92. package/lib/host/service.d.ts +3 -1
  93. package/lib/host/service.d.ts.map +1 -1
  94. package/lib/host/service.js +36 -2
  95. package/lib/host/service.js.map +1 -1
  96. package/lib/host/worktree-permission-manager.d.ts +14 -0
  97. package/lib/host/worktree-permission-manager.d.ts.map +1 -0
  98. package/lib/host/worktree-permission-manager.js +111 -0
  99. package/lib/host/worktree-permission-manager.js.map +1 -0
  100. package/lib/host/worktree-permission.d.ts +38 -0
  101. package/lib/host/worktree-permission.d.ts.map +1 -0
  102. package/lib/host/worktree-permission.js +156 -0
  103. package/lib/host/worktree-permission.js.map +1 -0
  104. package/lib/index.d.ts +4 -3
  105. package/lib/index.d.ts.map +1 -1
  106. package/lib/index.js +2 -1
  107. package/lib/index.js.map +1 -1
  108. package/lib/manage/worktree-permission.d.ts +3 -0
  109. package/lib/manage/worktree-permission.d.ts.map +1 -0
  110. package/lib/manage/worktree-permission.js +3 -0
  111. package/lib/manage/worktree-permission.js.map +1 -0
  112. package/lib/typert.host.js +126 -27
  113. package/lib/typert.remote-client.d.ts +5 -1
  114. package/lib/typert.remote-client.d.ts.map +1 -1
  115. package/lib/typert.remote-client.js +126 -27
  116. package/package.json +1 -1
package/README.md CHANGED
@@ -26,14 +26,43 @@ the adjacent Import tab, and a standard dropdown containing safe example branch/
26
26
  - Remove plugin-created and imported Worktrees through real `git worktree remove`; removing an imported Worktree can delete its linked directory and is called out in the confirmation dialog.
27
27
  - Create a normal Session from Main or a Session whose runtime cwd is an active Worktree, then
28
28
  open it directly.
29
+ - For active Worktree Sessions, request the named `worktree-full-access` preset after an
30
+ explicit confirmation. It combines DSH `danger-full-access` with `ask`: it removes filesystem
31
+ confinement for linked Git metadata while keeping approval prompts enabled; network and
32
+ process policy are unchanged. The native Access menu marks `Worktree Full Access` with a
33
+ Worktree branch icon.
34
+ - Preserve an explicit restriction selected in DSH's native Access UI. If the custom preset is
35
+ unavailable, fall back to `workspace-write + ask` when possible; if the permission capability
36
+ cannot be verified, show a retryable degraded state instead of claiming Full Access.
37
+ - Reuse the native `StateDot` for Session status indicators. Running, running-subagent, warning,
38
+ and completed states occupy the trailing slot; idle Sessions show native relative time for the
39
+ last human-authored message there. Hover or an open menu gives the trailing slot back to the
40
+ existing actions menu.
41
+ - Show the native DSH Session hover detail card with the complete title, relative time, and current
42
+ status; the card yields to the Session actions menu and row dragging.
43
+ - Cover native waiting-for-approval, plan-review, question, completed, idle, and running-subagent
44
+ states without copying the animation implementation into the plugin.
45
+ - Show one native running indicator on a collapsed Workspace, Main, or Worktree when any of its
46
+ non-archived Sessions is active; expanded groups keep their normal action rail instead.
47
+ - Promote a Session to the head of its Main or Worktree visual group after a newer user message.
48
+ This ordering is browser-local and does not mutate DSH Workspace order or the Worktree sidecar.
49
+ - Fork a Session from the native DSH Workspace tab, the Worktree view, or the Conversation fork
50
+ action. When the parent has an active Worktree binding, the child is bound to the same Worktree,
51
+ then added to the browser-local Workspace membership projection after the binding refresh; the
52
+ child remains a normal DSH Session. The refresh ordering keeps it from briefly appearing in
53
+ Main/Local. A sidecar failure keeps the child available and exposes retryable binding recovery.
29
54
  - See ready, repair, active, and detached Worktree states, including retryable operation errors.
30
- - Remove an active Worktree from its options menu with confirmation. Main and detached rows do
31
- not expose that menu.
55
+ - Use the shared Main and Worktree row options menu to copy the selected row's absolute path.
56
+ Main and detached rows show only `Copy path`; active Worktree rows also show `Remove Worktree`
57
+ with confirmation.
58
+ - Create a new Worktree from the Local or an active Worktree's options menu. The Create dialog
59
+ uses the selected row's current branch as its base and suggests the next available numbered
60
+ name, such as `feature-2` or `feature-3`; detached Worktrees do not expose this action.
32
61
  - Continue using DSH-native Workspace rename/delete/reorder and Session menus. Worktree rows can
33
62
  be reordered within their owning Workspace; order is stored in the plugin sidecar and Main is
34
63
  fixed first.
35
64
  - Persist Workspace, Main, and Worktree expansion choices in browser-local storage; the five-row Session overflow state remains transient and resets after refresh or parent collapse.
36
- - Highlight the DSH current Session in Worktree view; entering Worktree mode or switching the current Session temporarily reveals its Workspace/Main/Worktree path, expands Session overflow, clears a hiding search, and scrolls the row into view; this browser-local behavior does not change persisted expansion choices.
65
+ - Highlight the DSH current Session in Worktree view; entering Worktree mode or switching the current Session temporarily reveals its Workspace/Main/Worktree path, expands Session overflow only when the row is outside the first five, clears a hiding search, and scrolls the row into view; this browser-local behavior does not change persisted expansion choices.
37
66
  - Keep the current local branch or Worktree branch visible as read-only context in the existing
38
67
  Conversation title row and in the blank-session Hero.
39
68
  - Keep Conversation and Hero context stable across same-Session snapshot updates and Session
@@ -43,6 +72,10 @@ the adjacent Import tab, and a standard dropdown containing safe example branch/
43
72
  `WT` button when the Sidebar is collapsed.
44
73
  - Keep Worktree Sessions in the original DSH Project/Workspace view; the plugin does not copy
45
74
  Session content or modify messages, prompts, transcripts, or history.
75
+ - Worktree fork membership is not written to DSH's durable `Workspace.sessionIds`. While this
76
+ plugin is loaded, the browser can show the child through its local projection; without the
77
+ plugin, the child remains in DSH's global Session management but is not durably attached to the
78
+ native Workspace root membership.
46
79
 
47
80
  ### Compatibility and prerequisites
48
81
 
@@ -200,12 +233,15 @@ blank-session Hero. The displayed language follows DSH's current language settin
200
233
 
201
234
  1. Select a Workspace, press its `+`, choose a baseline local branch, and enter a Worktree name.
202
235
  The default branch name is `dsh/<8-character-random-string>`.
203
- 2. The target Worktree path must be absolute, belong to the same Project, and differ from the
236
+ 2. To create a sibling from an existing Worktree, open that active Worktree's options menu and
237
+ choose `Create new Worktree`. The dialog preselects the Worktree branch as the base and
238
+ chooses the next available numeric suffix for the name; existing names are skipped.
239
+ 3. The target Worktree path must be absolute, belong to the same Project, and differ from the
204
240
  Project root. Relative paths, a different Project, or the Project root are rejected.
205
- 3. Git must be installed and available on `PATH`. A missing Git executable shows install guidance
241
+ 4. Git must be installed and available on `PATH`. A missing Git executable shows install guidance
206
242
  and no command block; install Git, restart DSH, and retry. If the repository, initial commit,
207
- or local branch is missing, follow the copyable setup commands in the dialog. The plugin only
208
- renders this guidance; it does not run setup or installation commands or edit business files.
243
+ or local branch is missing, follow the copyable setup commands in the dialog. The plugin only
244
+ renders this guidance; it does not run setup or installation commands or edit business files.
209
245
 
210
246
  ### Import an existing Worktree
211
247
 
@@ -217,8 +253,9 @@ blank-session Hero. The displayed language follows DSH's current language settin
217
253
  diagnostic text.
218
254
  3. Choose an option and select `Import Worktree`. Registration writes only the plugin sidecar;
219
255
  the existing Worktree directory and Git working state remain in place. Import then creates or
220
- reuses a Session at that Worktree cwd and runs the same bind → membership projection open
221
- refresh flow as Create.
256
+ reuses a Session at that Worktree cwd and runs the same bind → openbinding refresh flow as
257
+ Create. Newly created Sessions are not projected into native Workspace membership before the
258
+ binding refresh.
222
259
  4. An active external import for the same Workspace and physical path is idempotent. A path already
223
260
  managed by the plugin returns `WORKTREE_ALREADY_MANAGED`; invalid or stale candidates return
224
261
  `WORKTREE_IMPORT_INVALID` and can be retried after the repository state is fixed.
@@ -228,31 +265,78 @@ blank-session Hero. The displayed language follows DSH's current language settin
228
265
  - Use Main's `+` to create a normal DSH Session in the Project-root view.
229
266
  - Use a Worktree's `+` to create or reuse a Session with that Worktree as its runtime cwd. The
230
267
  plugin calls the upstream runtime with `session.create({ cwd: worktreePath })`, then saves the
231
- external binding, applies a browser-local `{ workspaceId, sessionId }` membership projection,
232
- and opens the Session.
268
+ external binding and opens the Session. The browser-local `{ workspaceId, sessionId }` membership
269
+ projection is refreshed afterward, so the newly created Session does not briefly appear in Main.
233
270
  - The connector reuses an unarchived blank Session with the exact target cwd when possible. An
234
271
  already-bound Session opens directly; an unbound candidate is bound before projection and
235
- opening. Otherwise the flow is `create → bind → projectopen`, and concurrent clicks for the
236
- same Worktree are coalesced.
272
+ opening. Otherwise the new-Session flow is `create → bind → openrefresh`, and concurrent
273
+ clicks for the same Worktree are coalesced.
237
274
  - If binding fails after DSH has created the Session, the Session ID remains available for Retry
238
275
  or Open recovery. The plugin does not delete or mutate that DSH Session.
276
+ - Before opening an active Worktree Session, the plugin explains in a DSH-styled in-page dialog why
277
+ linked Git metadata may need access outside the Session directory. The dialog requires an explicit
278
+ risk acknowledgement; cancelling keeps the Session and binding, does not change permissions, and
279
+ leaves a retryable pending state. The native DSH Access selector remains the way to switch to
280
+ another permission mode.
239
281
  - A provisional blank Session follows DSH's native display rules: it is shown only in the
240
282
  selected view, uses the localized `New Session` label, hides its generated ID, and has no
241
283
  Rename, Fork, or Archive menu. After the first prompt is accepted, it becomes an ordinary
242
284
  Session row; hiding the blank row does not delete the Session or its Worktree binding.
243
285
 
286
+ ### Session activity and ordering
287
+
288
+ - Session rows reuse DSH's native `StateDot`: running Sessions, Sessions with running subagents,
289
+ waiting approval, plan review, question, and completed states show their status dot in the
290
+ trailing slot instead of relative time. Idle Sessions use that slot for the native compact
291
+ relative-time label.
292
+ - The trailing metadata uses the native compact buckets (`now`, minutes, hours, days, months, and
293
+ years). It is based on DSH's `updatedAt`, which advances with the latest human-authored message;
294
+ blank New Session rows have no time label. The display follows snapshot renders and does not add
295
+ an independent minute ticker.
296
+ - Hovering a Worktree Session row opens the native detail card after 500 ms with its full title,
297
+ relative time, and status; the card is suppressed while the Session menu is open or a row is
298
+ being dragged.
299
+ - A collapsed Workspace, Main group, or Worktree group shows the same running dot when any
300
+ non-archived member is ongoing, including activity hidden by search. Expanding the group hides
301
+ the aggregate dot; hover, focus, or an open menu reveals the existing action controls.
302
+ - A newer user message promotes its Session to the head of the current Main or Worktree visual
303
+ group. The promotion, observed timestamps, and per-group order live only in browser-local state;
304
+ successful manual drag still uses the native DSH ordering API before updating that local order.
305
+
306
+ ### Fork Worktree Sessions
307
+
308
+ - Use any native DSH fork entry point: a Session-list tab, a Worktree Session menu, or the
309
+ Conversation fork action. The plugin wraps the shared DSH `sessions.fork` service, so the
310
+ original fork cut, title increment, and child lineage stay native.
311
+ - After DSH creates the child, the plugin looks up the parent's active sidecar binding, writes the
312
+ child binding through the existing `/api` Manager. The Worktree view refreshes the binding before
313
+ replaying the browser-local Workspace membership projection, so the child does not briefly appear
314
+ in Main/Local; ready content is retained during that refresh.
315
+ - If the child is created but sidecar lookup or binding fails, DSH keeps the child and the plugin
316
+ shows Retry Binding/Open Created Session recovery. A later plugin initialization also retries
317
+ recoverable fork children from native Session lineage summaries; it never binds unrelated
318
+ subagents automatically.
319
+ - This flow does not persist the child into DSH `Workspace.sessionIds`. The native DSH Workspace
320
+ view can only see the temporary browser projection while the plugin is loaded; the durable native
321
+ Workspace data is unchanged.
322
+
244
323
  ### Reorder and manage Worktrees
245
324
 
246
325
  - Drag Worktrees within their owning Workspace. The ordered `worktrees` array is persisted in
247
326
  the plugin sidecar; Main is a fixed first row and Worktrees cannot move across Workspaces.
248
- - Use the active Worktree options menu and confirmation dialog to remove a Worktree. Main and
249
- detached Worktrees do not show this menu.
327
+ - Open the shared Main and Worktree options menu to copy the selected row's absolute path. Main
328
+ and detached/removed Worktrees show only `Copy path`; active Worktrees also show `Remove
329
+ Worktree` with a confirmation dialog.
250
330
  - Imported Worktrees expose the same active options menu as plugin-created Worktrees. Removing
251
331
  either source runs real `git worktree remove`; for an imported Worktree, the confirmation warns
252
332
  that the linked Worktree directory may be deleted. Sessions are retained as detached bindings.
253
333
  - Removing a Worktree does not delete its Sessions. The relationship remains detached until it
254
334
  is explicitly unbound. Deleting a Workspace removes only DSH's Workspace registration; its
255
335
  directory, Sessions, Git Worktrees, and plugin sidecar remain.
336
+ - After a successful removal, detached Sessions that still have Full Access are normalized to
337
+ `workspace-write + ask` when the public DSH permission service is available. An unavailable
338
+ service is reported as an unverified, retryable warning; it never grants Full Access to a
339
+ detached Session.
256
340
  - DSH-native Workspace rename/delete/reorder and Session menus remain available. Session drag
257
341
  ordering is limited to the current visual Main or Worktree group.
258
342
  - The Main group shows the current local branch as `Local (branch)` and falls back to `Local` if
@@ -278,6 +362,9 @@ blank-session Hero. The displayed language follows DSH's current language settin
278
362
  commands, while repository, initial commit, or local branch failures show copyable setup
279
363
  commands. Connection, Gateway, and unexpected Worktree-domain failures remain visible as
280
364
  retryable errors rather than empty lists.
365
+ - Permission status is also explicit: Full Access, fallback `workspace-write`, preserved user
366
+ restriction, unverified capability, confirmation pending, and retryable setup failure are not
367
+ silently collapsed into an empty or falsely successful Worktree state.
281
368
  - Refreshing an already-ready view preserves its current projection until replacement data is
282
369
  available. Same-Session snapshot updates do not blank the context or trigger redundant reads;
283
370
  initial entry and explicit Retry may show a loading state when no cached view is available.
@@ -329,6 +416,11 @@ persistent DSH attach. It does not modify DSH source, Session metadata, or nativ
329
416
  storage. The projection is replayed after native list refreshes and removed when the binding
330
417
  disappears or the Client is disposed.
331
418
 
419
+ Permission changes use only the public DSH per-Session permission service and its
420
+ `permission/preset`, `sandbox/mode`, and `approval/policy` records. The plugin does not write
421
+ messages, prompts, transcripts, Workspace data, or Session metadata, and cannot enlarge a
422
+ filesystem sandbox imposed by the host running DSH.
423
+
332
424
  The blank Hero context is visual only. Because the current upstream DSH source checkout has no
333
425
  additive Hero headline slot, its placement depends on the native `[data-phase="hero"]` and title
334
426
  anchors; it disappears when those anchors are unavailable and should move to a formal DSH slot
package/README.zh.md CHANGED
@@ -25,12 +25,37 @@ Session 元数据、原生列表和会话历史的唯一事实来源。插件只
25
25
  - 导入只登记已有 Worktree,不移动、复制或编辑其目录;记录使用 `source: external`,之后与 plugin 创建的记录共享 Session、binding、health、排序、cwd、projection、刷新和恢复流程。
26
26
  - plugin 创建和导入的 Worktree 都通过真实的 `git worktree remove` 移除;移除导入的 Worktree 可能删除其关联目录,确认弹窗会明确提示。
27
27
  - 在 Main 或 active Worktree 下创建普通 Session 或 Worktree Session,并直接打开新会话。
28
+ - 对 active Worktree Session,先经明确确认,再请求命名的 `worktree-full-access` 预设。它将
29
+ DSH 的 `danger-full-access` 与 `ask` 组合:关闭关联 Git 元数据的文件系统限制,但保留
30
+ 审批提示;网络和进程策略不变。原生 Access 菜单中的 `Worktree Full Access` 会显示
31
+ Worktree branch 图标。
32
+ - 保留用户在 DSH 原生 Access 界面中选择的限制。如果自定义预设不可用,在可能时回退到
33
+ `workspace-write + ask`;如果无法验证权限能力,则显示可重试的降级状态,不伪称已获得完全访问。
34
+ - 复用原生动画 `StateDot` 展示运行中的 Session,并为最近一条用户发送的 Session 消息显示
35
+ 原生相对时间;hover 或打开菜单时,右侧位置让位给已有的操作菜单。
36
+ - 使用 DSH 原生 Session hover 详情卡片展示完整标题、相对时间和当前状态;打开 Session 操作
37
+ 菜单或拖拽行时,详情卡片让位。
38
+ - 补齐原生的等待审批、计划待审、等待回答、已完成、空闲和运行中子代理状态;插件不会复制
39
+ 原生动画实现。
40
+ - 当折叠的 Workspace、Main 或 Worktree 中存在任一未归档的活动 Session 时,在其右侧显示
41
+ 一个原生运行指示器;展开后恢复普通操作栏。
42
+ - 用户在 Session 中发送新消息后,该 Session 会移动到当前 Main 或 Worktree 视觉分组的队首。
43
+ 该排序只保存在浏览器本地,不修改 DSH Workspace 顺序或 Worktree sidecar。
44
+ - 从 DSH 原生 Workspace session list tab、Worktree view 或 Conversation fork 操作 fork
45
+ Session。parent 有 active Worktree binding 时,child 会先绑定到同一个 Worktree,再在 binding
46
+ refresh 完成后加入浏览器本地 Workspace membership projection;child 仍然是普通 DSH Session。
47
+ 这一时序避免 child 短暂出现在 Main/Local。sidecar 失败时 child 会保留,并显示可重试的
48
+ binding 恢复操作。
28
49
  - 查看 ready、repair、active 和 detached Worktree 状态,包括可重试的操作错误。
29
- - 通过 active Worktree 的选项菜单和确认弹窗移除 Worktree;Main 和 detached 行不显示该菜单。
50
+ - 通过 Main Worktree 共用的选项菜单复制所选行的绝对路径;Main 和 detached 行只显示“复制路径”,
51
+ active Worktree 额外显示“移除 Worktree”并要求确认。
52
+ - 通过 Local 或 active Worktree 的选项菜单创建新的 Worktree。创建弹窗会以所选行的当前 branch
53
+ 为基线,并预填下一个可用的递增名称,例如 `feature-2` 或 `feature-3`;detached Worktree
54
+ 不显示该动作。
30
55
  - 继续使用 DSH 原生的 Workspace rename/delete/reorder 和 Session 菜单。Worktree 可以在所属
31
56
  Workspace 内排序;顺序保存在插件 sidecar 中,Main 固定在第一位。
32
57
  - 将 Workspace、Main 和 Worktree 的展开选择保存到浏览器本地存储;Session 五行溢出展开保持临时状态,并在刷新或父级折叠后重置。
33
- - 在 Worktree view 高亮 DSH 当前 Session;进入 Worktree 模式或切换当前会话时,临时展开其 Workspace/Main/Worktree 路径和 Session 五行溢出,清空隐藏它的搜索并滚动定位;这一浏览器本地行为不改变已保存的展开选择。
58
+ - 在 Worktree view 高亮 DSH 当前 Session;进入 Worktree 模式或切换当前会话时,临时展开其 Workspace/Main/Worktree 路径;只有当前行不在前五行时才展开 Session 五行溢出,随后清空隐藏它的搜索并滚动定位;这一浏览器本地行为不改变已保存的展开选择。
34
59
  - 在已有 Conversation 的标题行以及新会话空白 Hero 中,以只读方式显示当前 local branch 或
35
60
  Worktree branch 上下文。
36
61
  - 在同一个 Session 的 snapshot 更新以及 Session 切换期间保持 Conversation 和 Hero 上下文
@@ -39,6 +64,9 @@ Session 元数据、原生列表和会话历史的唯一事实来源。插件只
39
64
  对齐原生字体和排版,Sidebar 折叠后不再额外显示 `WT` 按钮。
40
65
  - Worktree Session 仍出现在原始 DSH Project/Workspace 视角中;插件不复制 Session 内容,
41
66
  也不修改消息、prompt、transcript 或历史记录。
67
+ - Worktree fork 的 membership 不会写入 DSH 持久化的 `Workspace.sessionIds`。plugin 加载期间,
68
+ 浏览器可以通过本地 projection 显示 child;不加载 plugin 时,child 仍在 DSH 全局 Session 管理中,
69
+ 但不会被持久化挂到 native Workspace root membership 下。
42
70
 
43
71
  ### 兼容性与前置条件
44
72
 
@@ -190,9 +218,12 @@ pnpm dsh plugin --profile web remove @cerbur/clutch-dsh-worktree
190
218
 
191
219
  1. 选择 Workspace,点击它旁边的 `+`,选择基线 local branch,并填写 Worktree name。默认
192
220
  branch 名称为 `dsh/<8-character-random-string>`。
193
- 2. 目标 Worktree 路径必须是绝对路径,属于同一个 Project,且不能是 Project 根目录。相对
221
+ 2. 如果要从已有 Worktree 创建同级 Worktree,打开该 active Worktree 的选项菜单并选择
222
+ `创建新的 Worktree`。弹窗会以当前 Worktree branch 作为基线,并为名称选择下一个可用的
223
+ 递增序号;已有名称会被跳过。
224
+ 3. 目标 Worktree 路径必须是绝对路径,属于同一个 Project,且不能是 Project 根目录。相对
194
225
  路径、其他 Project 的路径或 Project 根目录都会被拒绝。
195
- 3. Git 必须已安装且可在 PATH 中使用。Git 可执行文件缺失时显示安装提示且不显示命令块;请
226
+ 4. Git 必须已安装且可在 PATH 中使用。Git 可执行文件缺失时显示安装提示且不显示命令块;请
196
227
  安装 Git、重启 DSH 后重试。如果缺少 repository、初始 commit 或本地 branch,按照弹窗中
197
228
  的可复制 setup 命令修复后重试。插件只展示这些提示,不会执行 setup 或安装命令或编辑
198
229
  业务文件。
@@ -206,7 +237,8 @@ pnpm dsh plugin --profile web remove @cerbur/clutch-dsh-worktree
206
237
  作为诊断信息。
207
238
  3. 在下拉框中选择一个选项并点击 `导入 Worktree`。登记只写入 plugin sidecar,已有 Worktree 目录和 Git
208
239
  工作状态保持不变。随后会在该 Worktree cwd 创建或复用 Session,并执行与创建相同的
209
- `bind → membership projection open refresh` 流程。
240
+ `bind → openbinding refresh` 流程;新建 Session 不会在 binding 刷新前投影到原生
241
+ Workspace membership。
210
242
  4. 同一 Workspace、同一物理路径的 active external 导入是幂等的。已经由 plugin 管理的路径
211
243
  返回 `WORKTREE_ALREADY_MANAGED`;无效或过期候选项返回 `WORKTREE_IMPORT_INVALID`,修复
212
244
  repository 状态后可以重试。
@@ -215,29 +247,67 @@ pnpm dsh plugin --profile web remove @cerbur/clutch-dsh-worktree
215
247
 
216
248
  - 使用 Main 的 `+`,在 Project 根目录视角中创建普通 DSH Session。
217
249
  - 使用 Worktree 的 `+`,创建或复用 runtime cwd 指向该 Worktree 的 Session。插件通过 upstream
218
- runtime 调用 `session.create({ cwd: worktreePath })`,随后保存外部 binding,在当前浏览器内
219
- 应用 `{ workspaceId, sessionId }` membership projection,并打开该 Session。
250
+ runtime 调用 `session.create({ cwd: worktreePath })`,随后保存外部 binding 并打开该 Session。
251
+ 当前浏览器内的 `{ workspaceId, sessionId }` membership projection 会在之后刷新,因此新建
252
+ Session 不会短暂出现在 Main 中。
220
253
  - 如果存在目标 cwd 完全匹配的未归档 blank Session,连接器会优先复用它。已绑定的 Session
221
254
  会直接打开;未绑定的候选会先 binding,再 projection 和打开。否则执行
222
- `create → bind → projectopen`,同一个 Worktree 的并发点击会合并。
255
+ 新建路径执行 `create → bind → openrefresh`,同一个 Worktree 的并发点击会合并。
223
256
  - 如果 DSH 创建 Session 后 binding 失败,Session ID 仍会保留,可用于 Retry 或 Open 恢复。
224
257
  插件不会删除或修改该 DSH Session。
258
+ - 打开 active Worktree Session 前,插件会在 DSH 风格的页面内弹窗中说明关联 Git 元数据为什么
259
+ 可能需要访问 Session 目录之外的内容。弹窗要求明确勾选风险确认;取消会保留 Session 和
260
+ binding,不改变权限,并留下可重试的待处理状态。需要切换到其他权限模式时,继续使用 DSH
261
+ 原生 Access 选择器。
225
262
  - provisional blank Session 遵循 DSH 原生显示规则:只在当前选中的视角中显示,使用本地化
226
263
  的 `New Session` 文案,不显示生成的 ID,也没有 Rename、Fork 或 Archive 菜单。接受第一条
227
264
  prompt 后,它会变为普通 Session 行;隐藏 blank 行不会删除 Session 或 Worktree binding。
228
265
 
266
+ ### Session 活动与排序
267
+
268
+ - Session 行复用 DSH 原生 `StateDot`:运行中的 Session 以及存在运行中子代理的 Session,使用
269
+ 右侧动画点替代相对时间。等待审批、计划待审和等待回答使用原生 warning 点;已完成 Session
270
+ 保留原生 completed 点。
271
+ - 右侧元数据使用原生紧凑时间单位(刚刚、分钟、小时、天、月、年),来源是 DSH 的
272
+ `updatedAt`,该字段随最近一条用户消息推进;空白 New Session 不显示时间。时间只在 snapshot
273
+ render 时按原生规则重新计算,不额外增加每分钟 ticker。
274
+ - 将鼠标悬停在 Worktree Session 行上 500 毫秒后,会打开原生详情卡片,展示完整标题、相对时间
275
+ 和状态;Session 菜单打开或行正在拖拽时不显示卡片。
276
+ - 折叠的 Workspace、Main 或 Worktree 分组,只要任一未归档成员正在运行就显示相同的原生运行点,
277
+ 即使该 Session 被搜索隐藏也会计入。展开后隐藏聚合点;hover、focus 或打开菜单时显示原有
278
+ 操作控件。
279
+ - 用户发送新消息后,Session 会移动到当前 Main 或 Worktree 视觉分组队首。promotion、已观察
280
+ 时间戳和每组顺序只存在浏览器本地;手动拖动仍先调用 DSH 原生排序 API,成功后再更新本地顺序。
281
+
282
+ ### Fork Worktree Session
283
+
284
+ - 可以使用任意 DSH 原生 fork 入口:Session list 中的 tab、Worktree Session 菜单或
285
+ Conversation fork 操作。插件包装共享的 DSH `sessions.fork` service,因此原生的 fork cut、
286
+ 标题递增和 child lineage 语义保持不变。
287
+ - DSH 创建 child 后,插件读取 parent 的 active sidecar binding,通过现有 `/api` Manager 写入
288
+ child binding。随后 Worktree view 先刷新 binding,再重放浏览器本地 Workspace membership
289
+ projection,因此 child 不会短暂出现在 Main/Local;刷新期间保留 ready 内容。
290
+ - 如果 child 已创建但 sidecar 查询或 binding 失败,DSH 仍保留 child,plugin 显示 Retry Binding/
291
+ Open Created Session 恢复操作。后续 plugin 初始化也会根据原生 Session lineage summary 重试可恢复
292
+ 的 fork child;不会自动绑定无关的 subagent。
293
+ - 这一流程不会把 child 持久化写入 DSH `Workspace.sessionIds`。native DSH Workspace view 只有在
294
+ plugin 加载期间才能看到临时浏览器 projection;native Workspace 持久化数据保持不变。
295
+
229
296
  ### 排序与管理 Worktree
230
297
 
231
298
  - 在所属 Workspace 内拖动 Worktree。排序持久化在 plugin sidecar 的有序 `worktrees` 数组中;
232
299
  Main 是固定的第一行,Worktree 不能跨 Workspace 移动。
233
- - 使用 active Worktree 的选项菜单和确认弹窗移除 Worktree。Main 和 detached Worktree 不显示
234
- 该菜单。
300
+ - 打开 Main Worktree 共用的选项菜单复制所选行的绝对路径。Main 和 detached/removed Worktree
301
+ 只显示“复制路径”;active Worktree 还显示“移除 Worktree”并要求确认。
235
302
  - 导入的 Worktree 与 plugin 创建的 Worktree 显示相同的 active 选项菜单。两种来源都执行真实
236
303
  `git worktree remove`;导入项的确认文案会警告关联 Worktree 目录可能被删除。Session 会
237
304
  保留为 detached binding。
238
305
  - 移除 Worktree 不会删除其 Session。关系会保留为 detached,直到显式解绑。删除 Workspace
239
306
  只会删除 DSH 的 Workspace registration;其目录、Session、Git Worktree 和 plugin
240
307
  sidecar 会保留。
308
+ - Worktree 成功移除后,如果公共 DSH 权限服务可用,仍处于完全访问的 detached Session 会
309
+ 归一化为 `workspace-write + ask`。权限服务不可用时显示未验证且可重试的警告;不会向
310
+ detached Session 自动授予完全访问。
241
311
  - DSH 原生的 Workspace rename/delete/reorder 和 Session 菜单继续可用。Session 拖动排序
242
312
  限定在当前视觉 Main 或 Worktree 分组中。
243
313
  - Main 分组显示当前 local branch:有分支时为 `本地(branch)`,DSH 没有返回当前分支时
@@ -263,6 +333,8 @@ pnpm dsh plugin --profile web remove @cerbur/clutch-dsh-worktree
263
333
  - 已经 ready 的视角刷新时会保留当前 projection,直到替换数据可用。同一个 Session 的
264
334
  snapshot 更新不会清空上下文,也不会触发重复读取;没有缓存视角时,首次进入和显式 Retry
265
335
  可以显示 loading 状态。
336
+ - 权限状态会明确显示为完全访问、回退到 `workspace-write`、保留用户限制、能力未验证、
337
+ 等待确认或可重试的设置失败,不会静默折叠为空列表或伪造成功。
266
338
 
267
339
  ## 界面语言
268
340
 
@@ -303,6 +375,10 @@ Worktree Session 流程将独立的 Worktree cwd 交给 upstream DSH runtime,
303
375
  attach。它不会修改 DSH 源码、Session metadata 或原生 Workspace 存储。native list 刷新后会
304
376
  重放 projection;binding 消失或 Client dispose 时会移除 projection。
305
377
 
378
+ 权限变更只使用 DSH 公共的 per-Session 权限服务及其 `permission/preset`、`sandbox/mode`、
379
+ `approval/policy` 记录。插件不会写入消息、prompt、transcript、Workspace 数据或 Session
380
+ metadata,也不能扩大运行 DSH 的宿主沙箱边界。
381
+
306
382
  空白 Hero 上下文只用于展示。由于当前 upstream DSH source checkout 没有 additive Hero
307
383
  headline slot,它的位置依赖原生 `[data-phase="hero"]` 和标题锚点;锚点不可用时浮层会消失,
308
384
  未来有正式 DSH slot 时应迁移到该 slot。
package/cordis.patch.yml CHANGED
@@ -1,3 +1,24 @@
1
+ - id: permission
2
+ # DSH patch rows replace the whole config. Keep the upstream presets and add
3
+ # one named bundle; the plugin applies it only after an active Worktree
4
+ # binding is confirmed by the Host.
5
+ config:
6
+ presets:
7
+ read-only:
8
+ sandbox: read-only
9
+ approval: ask
10
+ workspace-write:
11
+ sandbox: workspace-write
12
+ approval: ask
13
+ danger-full-access:
14
+ sandbox: danger-full-access
15
+ approval: never
16
+ worktree-full-access:
17
+ sandbox: danger-full-access
18
+ approval: ask
19
+ name: Worktree Full Access
20
+ description: Full file access for Worktree metadata while keeping approval prompts enabled.
21
+
1
22
  - insert:
2
23
  - id: clutch-dsh-worktree-host
3
24
  name: '@cerbur/clutch-dsh-worktree'
@@ -1 +1 @@
1
- {"version":3,"file":"WorktreeContext.d.ts","sourceRoot":"","sources":["../../src/client/WorktreeContext.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,EACV,UAAU,EACV,WAAW,EACX,YAAY,EAEb,MAAM,kCAAkC,CAAC;AAI1C,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,6BAA6B,CAAC;AACxE,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAG3C,mEAAmE;AACnE,MAAM,WAAW,uBAAuB;IACtC,QAAQ,CAAC,KAAK,EAAE;QACd,QAAQ,CAAC,eAAe,EAAE,aAAa,CAAC,oBAAoB,CAAC,CAAC;KAC/D,CAAC;CACH;AAID,0DAA0D;AAC1D,MAAM,MAAM,0BAA0B,GACpC,YAAY,CAAC,qCAAqC,CAAC,GACnD,WAAW,CAAC,OAAO,WAAW,CAAC,GAC/B,UAAU,CAAC,uBAAuB,CAAC,CAAC;AAqBtC,oFAAoF;AACpF,wBAAgB,qBAAqB,CAAC,EACpC,SAAS,EACT,kBAAkB,EAClB,CAAC,GACF,EAAE,0BAA0B,sCAI5B"}
1
+ {"version":3,"file":"WorktreeContext.d.ts","sourceRoot":"","sources":["../../src/client/WorktreeContext.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,EACV,UAAU,EACV,WAAW,EACX,YAAY,EAEb,MAAM,kCAAkC,CAAC;AAI1C,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,6BAA6B,CAAC;AACxE,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAG3C,mEAAmE;AACnE,MAAM,WAAW,uBAAuB;IACtC,QAAQ,CAAC,KAAK,EAAE;QACd,QAAQ,CAAC,eAAe,EAAE,aAAa,CAAC,oBAAoB,CAAC,CAAC;KAC/D,CAAC;CACH;AAID,0DAA0D;AAC1D,MAAM,MAAM,0BAA0B,GACpC,YAAY,CAAC,qCAAqC,CAAC,GACnD,WAAW,CAAC,OAAO,WAAW,CAAC,GAC/B,UAAU,CAAC,uBAAuB,CAAC,CAAC;AA2BtC,oFAAoF;AACpF,wBAAgB,qBAAqB,CAAC,EACpC,SAAS,EACT,kBAAkB,EAClB,CAAC,GACF,EAAE,0BAA0B,sCAI5B"}
@@ -1,5 +1,5 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { IconBranchOutline16 } from '@deepseek-ai/dsh-client-ui-primitives';
2
+ import { HoverCard, IconBranchOutline16 } from '@deepseek-ai/dsh-client-ui-primitives';
3
3
  import styles from './worktree-context.css';
4
4
  function WorktreeContextLabel({ value, t, }) {
5
5
  if (value.kind === 'none')
@@ -7,7 +7,7 @@ function WorktreeContextLabel({ value, t, }) {
7
7
  const ariaLabel = value.kind === 'main'
8
8
  ? t('context.main', { name: value.label })
9
9
  : t('context.worktree', { name: value.label });
10
- return (_jsxs("span", { className: styles.headerContext, title: value.label, "aria-label": ariaLabel, children: [_jsx(IconBranchOutline16, { size: 14, className: styles.contextIcon, "aria-hidden": "true" }), _jsx("span", { className: styles.contextLabel, children: value.label })] }));
10
+ return (_jsx(HoverCard, { anchor: _jsxs("span", { className: styles.headerContext, title: value.label, "aria-label": ariaLabel, children: [_jsx(IconBranchOutline16, { size: 14, className: styles.contextIcon, "aria-hidden": "true" }), _jsx("span", { className: styles.contextLabel, children: value.label })] }), content: _jsx("div", { className: styles.contextHoverTitle, children: value.label }), openDelayMs: 500 }));
11
11
  }
12
12
  /** Render the current branch or active Worktree branch beside the Session title. */
13
13
  export function WorktreeHeaderContext({ sessionId, useWorktreeContext, t, }) {
@@ -1 +1 @@
1
- {"version":3,"file":"WorktreeContext.js","sourceRoot":"","sources":["../../src/client/WorktreeContext.tsx"],"names":[],"mappings":";AAOA,OAAO,EAAE,mBAAmB,EAAE,MAAM,uCAAuC,CAAC;AAK5E,OAAO,MAAM,MAAM,wBAAwB,CAAC;AAiB5C,SAAS,oBAAoB,CAAC,EAC5B,KAAK,EACL,CAAC,GAIF;IACC,IAAI,KAAK,CAAC,IAAI,KAAK,MAAM;QAAE,OAAO,IAAI,CAAC;IACvC,MAAM,SAAS,GAAG,KAAK,CAAC,IAAI,KAAK,MAAM;QACrC,CAAC,CAAC,CAAC,CAAC,cAAc,EAAE,EAAE,IAAI,EAAE,KAAK,CAAC,KAAK,EAAE,CAAC;QAC1C,CAAC,CAAC,CAAC,CAAC,kBAAkB,EAAE,EAAE,IAAI,EAAE,KAAK,CAAC,KAAK,EAAE,CAAC,CAAC;IACjD,OAAO,CACL,gBAAM,SAAS,EAAE,MAAM,CAAC,aAAa,EAAE,KAAK,EAAE,KAAK,CAAC,KAAK,gBAAc,SAAS,aAC9E,KAAC,mBAAmB,IAAC,IAAI,EAAE,EAAE,EAAE,SAAS,EAAE,MAAM,CAAC,WAAW,iBAAc,MAAM,GAAG,EACnF,eAAM,SAAS,EAAE,MAAM,CAAC,YAAY,YAAG,KAAK,CAAC,KAAK,GAAQ,IACrD,CACR,CAAC;AACJ,CAAC;AAED,oFAAoF;AACpF,MAAM,UAAU,qBAAqB,CAAC,EACpC,SAAS,EACT,kBAAkB,EAClB,CAAC,GAC0B;IAC3B,MAAM,KAAK,GAAG,kBAAkB,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,QAAQ,CAAC,CAAC;IACzD,IAAI,KAAK,CAAC,SAAS,KAAK,SAAS;QAAE,OAAO,IAAI,CAAC;IAC/C,OAAO,KAAC,oBAAoB,IAAC,KAAK,EAAE,KAAK,CAAC,KAAK,EAAE,CAAC,EAAE,CAAC,GAAI,CAAC;AAC5D,CAAC"}
1
+ {"version":3,"file":"WorktreeContext.js","sourceRoot":"","sources":["../../src/client/WorktreeContext.tsx"],"names":[],"mappings":";AAOA,OAAO,EAAE,SAAS,EAAE,mBAAmB,EAAE,MAAM,uCAAuC,CAAC;AAKvF,OAAO,MAAM,MAAM,wBAAwB,CAAC;AAiB5C,SAAS,oBAAoB,CAAC,EAC5B,KAAK,EACL,CAAC,GAIF;IACC,IAAI,KAAK,CAAC,IAAI,KAAK,MAAM;QAAE,OAAO,IAAI,CAAC;IACvC,MAAM,SAAS,GAAG,KAAK,CAAC,IAAI,KAAK,MAAM;QACrC,CAAC,CAAC,CAAC,CAAC,cAAc,EAAE,EAAE,IAAI,EAAE,KAAK,CAAC,KAAK,EAAE,CAAC;QAC1C,CAAC,CAAC,CAAC,CAAC,kBAAkB,EAAE,EAAE,IAAI,EAAE,KAAK,CAAC,KAAK,EAAE,CAAC,CAAC;IACjD,OAAO,CACL,KAAC,SAAS,IACR,MAAM,EACJ,gBAAM,SAAS,EAAE,MAAM,CAAC,aAAa,EAAE,KAAK,EAAE,KAAK,CAAC,KAAK,gBAAc,SAAS,aAC9E,KAAC,mBAAmB,IAAC,IAAI,EAAE,EAAE,EAAE,SAAS,EAAE,MAAM,CAAC,WAAW,iBAAc,MAAM,GAAG,EACnF,eAAM,SAAS,EAAE,MAAM,CAAC,YAAY,YAAG,KAAK,CAAC,KAAK,GAAQ,IACrD,EAET,OAAO,EAAE,cAAK,SAAS,EAAE,MAAM,CAAC,iBAAiB,YAAG,KAAK,CAAC,KAAK,GAAO,EACtE,WAAW,EAAE,GAAG,GAChB,CACH,CAAC;AACJ,CAAC;AAED,oFAAoF;AACpF,MAAM,UAAU,qBAAqB,CAAC,EACpC,SAAS,EACT,kBAAkB,EAClB,CAAC,GAC0B;IAC3B,MAAM,KAAK,GAAG,kBAAkB,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,QAAQ,CAAC,CAAC;IACzD,IAAI,KAAK,CAAC,SAAS,KAAK,SAAS;QAAE,OAAO,IAAI,CAAC;IAC/C,OAAO,KAAC,oBAAoB,IAAC,KAAK,EAAE,KAAK,CAAC,KAAK,EAAE,CAAC,EAAE,CAAC,GAAI,CAAC;AAC5D,CAAC"}
@@ -1,8 +1,8 @@
1
1
  import type { WorktreeSurfaceProps } from './worktree-surface-types.js';
2
- export type { WorktreeSurfaceInjected, WorktreeSurfaceProps, } from './worktree-surface-types.js';
2
+ export type { WorktreeSurfaceInjected, WorktreeSurfaceProps } from './worktree-surface-types.js';
3
3
  /**
4
4
  * Peer Worktree navigation surface. It keeps the original DSH Workspace mode
5
5
  * intact and renders a browser-local Workspace → Worktree → Session projection.
6
6
  */
7
- export declare function WorktreeSurface({ useStore, actions, useSessions, useWorkspaces, t, available, expandState, manager, invalidateWorktreeContext, createWorkspace, createSessionForWorktree: createSessionCallback, createMainSession, renameWorkspace, deleteWorkspace, insertWorkspaceBefore, insertSessionBefore, insertWorktreeBefore, renameSession, forkSession, archiveSession, ensureSessionWorkspace, syncSessionWorkspaces, openSession, }: WorktreeSurfaceProps): import("react").JSX.Element | null;
7
+ export declare function WorktreeSurface({ useStore, actions, useSessions, useWorkspaces, t, available, expandState, sessionOrder, manager, permission, confirmFullAccess, fullAccessConfirmation, onPermissionResult, onPermissionNotice, permissionNotice, invalidateWorktreeContext, createWorkspace, createSessionForWorktree: createSessionCallback, createMainSession, renameWorkspace, deleteWorkspace, insertWorkspaceBefore, insertSessionBefore, insertWorktreeBefore, renameSession, forkSession, archiveSession, forkRecovery, retryForkSession, ensureSessionWorkspace, syncSessionWorkspaces, openSession, }: WorktreeSurfaceProps): import("react").JSX.Element | null;
8
8
  //# sourceMappingURL=WorktreeSurface.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"WorktreeSurface.d.ts","sourceRoot":"","sources":["../../src/client/WorktreeSurface.tsx"],"names":[],"mappings":"AAqDA,OAAO,KAAK,EAQV,oBAAoB,EAQrB,MAAM,6BAA6B,CAAC;AAsBrC,YAAY,EACV,uBAAuB,EACvB,oBAAoB,GACrB,MAAM,6BAA6B,CAAC;AAwBrC;;;GAGG;AACH,wBAAgB,eAAe,CAAC,EAC9B,QAAQ,EACR,OAAO,EACP,WAAW,EACX,aAAa,EACb,CAAC,EACD,SAAS,EACT,WAAW,EACX,OAAO,EACP,yBAAyB,EACzB,eAAe,EACf,wBAAwB,EAAE,qBAAqB,EAC/C,iBAAiB,EACjB,eAAe,EACf,eAAe,EACf,qBAAqB,EACrB,mBAAmB,EACnB,oBAAoB,EACpB,aAAa,EACb,WAAW,EACX,cAAc,EACd,sBAAsB,EACtB,qBAAqB,EACrB,WAAW,GACZ,EAAE,oBAAoB,sCAu5CtB"}
1
+ {"version":3,"file":"WorktreeSurface.d.ts","sourceRoot":"","sources":["../../src/client/WorktreeSurface.tsx"],"names":[],"mappings":"AAiEA,OAAO,KAAK,EAQV,oBAAoB,EASrB,MAAM,6BAA6B,CAAC;AA6BrC,YAAY,EAAE,uBAAuB,EAAE,oBAAoB,EAAE,MAAM,6BAA6B,CAAC;AAoEjG;;;GAGG;AACH,wBAAgB,eAAe,CAAC,EAC9B,QAAQ,EACR,OAAO,EACP,WAAW,EACX,aAAa,EACb,CAAC,EACD,SAAS,EACT,WAAW,EACX,YAAY,EACZ,OAAO,EACP,UAAU,EACV,iBAAiB,EACjB,sBAAsB,EACtB,kBAAkB,EAClB,kBAAkB,EAClB,gBAAgB,EAChB,yBAAyB,EACzB,eAAe,EACf,wBAAwB,EAAE,qBAAqB,EAC/C,iBAAiB,EACjB,eAAe,EACf,eAAe,EACf,qBAAqB,EACrB,mBAAmB,EACnB,oBAAoB,EACpB,aAAa,EACb,WAAW,EACX,cAAc,EACd,YAAY,EACZ,gBAAgB,EAChB,sBAAsB,EACtB,qBAAqB,EACrB,WAAW,GACZ,EAAE,oBAAoB,sCA4tDtB"}