@deepseek-harness-tui/dsh-tui 0.16.1 → 0.17.0

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 (394) hide show
  1. package/README.md +208 -31
  2. package/assets/plugin-icon.svg +13 -0
  3. package/assets/windows-installer.cs +308 -0
  4. package/assets/windows-installer.ps1 +17 -0
  5. package/bin/dsh-tui.js +64 -5
  6. package/cli/adapters/dsh/index.mjs +111 -0
  7. package/cli/adapters/dsh/locate.mjs +73 -0
  8. package/cli/adapters/dsh/management-plugin.mjs +111 -0
  9. package/cli/args.mjs +154 -0
  10. package/cli/contracts.d.ts +48 -0
  11. package/cli/engine.mjs +92 -0
  12. package/cli/entry.mjs +48 -0
  13. package/cli/process.mjs +118 -0
  14. package/cli/protocol.mjs +23 -0
  15. package/cli/schema-v1.json +33 -0
  16. package/cordis.patch.yml +3 -1
  17. package/cordis.yml +3 -1
  18. package/guide/dsh-tui-guide/SKILL.md +1 -0
  19. package/guide/dsh-tui-guide/cli.en.md +114 -0
  20. package/guide/dsh-tui-guide/cli.md +114 -0
  21. package/guide/dsh-tui-guide/configuration.en.md +6 -5
  22. package/guide/dsh-tui-guide/configuration.md +6 -5
  23. package/guide/dsh-tui-guide/getting-started.en.md +27 -1
  24. package/guide/dsh-tui-guide/getting-started.md +19 -1
  25. package/guide/dsh-tui-guide/interaction.en.md +22 -10
  26. package/guide/dsh-tui-guide/interaction.md +18 -8
  27. package/guide/dsh-tui-guide/plugins.en.md +35 -4
  28. package/guide/dsh-tui-guide/plugins.md +23 -2
  29. package/guide/dsh-tui-guide/user-guide.en.md +30 -23
  30. package/guide/dsh-tui-guide/user-guide.md +29 -22
  31. package/lib/settings.json +83 -40
  32. package/lib/types/adapter/channel/plugins.d.ts.map +1 -1
  33. package/lib/types/adapter/channel/plugins.js +8 -0
  34. package/lib/types/adapter/channel/ui-policy.d.ts +1 -1
  35. package/lib/types/adapter/channel/ui-policy.d.ts.map +1 -1
  36. package/lib/types/adapter/channel/ui-policy.js +3 -0
  37. package/lib/types/adapter/ports/channel-display.d.ts +10 -0
  38. package/lib/types/adapter/ports/channel-display.d.ts.map +1 -1
  39. package/lib/types/adapter/ports/channel-session.d.ts +2 -0
  40. package/lib/types/adapter/ports/channel-session.d.ts.map +1 -1
  41. package/lib/types/adapter/ports/channel-settings.d.ts +20 -0
  42. package/lib/types/adapter/ports/channel-settings.d.ts.map +1 -1
  43. package/lib/types/adapter/ports/channel-ui.d.ts +17 -2
  44. package/lib/types/adapter/ports/channel-ui.d.ts.map +1 -1
  45. package/lib/types/adapter/ports/channel-view.d.ts +8 -1
  46. package/lib/types/adapter/ports/channel-view.d.ts.map +1 -1
  47. package/lib/types/adapter/ports/channel.d.ts +7 -0
  48. package/lib/types/adapter/ports/channel.d.ts.map +1 -1
  49. package/lib/types/agent/capabilities.d.ts +2 -0
  50. package/lib/types/agent/capabilities.d.ts.map +1 -1
  51. package/lib/types/agent/events.d.ts +8 -0
  52. package/lib/types/agent/events.d.ts.map +1 -1
  53. package/lib/types/api.d.ts +2 -2
  54. package/lib/types/api.d.ts.map +1 -1
  55. package/lib/types/backends/claude/translate/events.d.ts.map +1 -1
  56. package/lib/types/backends/claude/translate/events.js +2 -1
  57. package/lib/types/backends/codex/auth/status.js +1 -1
  58. package/lib/types/backends/codex/session/controls.d.ts.map +1 -1
  59. package/lib/types/backends/codex/session/controls.js +6 -5
  60. package/lib/types/backends/codex/session/goals.d.ts.map +1 -1
  61. package/lib/types/backends/codex/session/side-query.d.ts.map +1 -1
  62. package/lib/types/backends/codex/translate/events.d.ts.map +1 -1
  63. package/lib/types/backends/codex/translate/events.js +3 -1
  64. package/lib/types/backends/shared/channel-tokens.d.ts.map +1 -1
  65. package/lib/types/backends/shared/channel-tokens.js +9 -8
  66. package/lib/types/channel/history-restore.d.ts.map +1 -1
  67. package/lib/types/channel/history-restore.js +2 -0
  68. package/lib/types/channel/interaction.d.ts.map +1 -1
  69. package/lib/types/channel/interaction.js +1 -0
  70. package/lib/types/channel/projection.d.ts +1 -1
  71. package/lib/types/channel/projection.d.ts.map +1 -1
  72. package/lib/types/channel/projection.js +19 -4
  73. package/lib/types/channel/questions.d.ts +2 -0
  74. package/lib/types/channel/questions.d.ts.map +1 -1
  75. package/lib/types/channel/sanitize.d.ts +14 -0
  76. package/lib/types/channel/sanitize.d.ts.map +1 -1
  77. package/lib/types/channel/sanitize.js +55 -0
  78. package/lib/types/channel/working-directory.d.ts +9 -0
  79. package/lib/types/channel/working-directory.d.ts.map +1 -0
  80. package/lib/types/channel/working-directory.js +7 -0
  81. package/lib/types/commands.d.ts +8 -1
  82. package/lib/types/commands.d.ts.map +1 -1
  83. package/lib/types/commands.js +13 -4
  84. package/lib/types/components/ChatTitle.d.ts +7 -0
  85. package/lib/types/components/ChatTitle.d.ts.map +1 -0
  86. package/lib/types/components/ChatTitle.js +15 -0
  87. package/lib/types/components/CodeBlockFrame.d.ts.map +1 -1
  88. package/lib/types/components/CodeBlockFrame.js +10 -5
  89. package/lib/types/components/CompactionStatusRow.d.ts.map +1 -1
  90. package/lib/types/components/CompactionStatusRow.js +24 -3
  91. package/lib/types/components/GoalTodoPanel.d.ts +3 -1
  92. package/lib/types/components/GoalTodoPanel.d.ts.map +1 -1
  93. package/lib/types/components/GoalTodoPanel.js +2 -2
  94. package/lib/types/components/Markdown.d.ts +9 -1
  95. package/lib/types/components/Markdown.d.ts.map +1 -1
  96. package/lib/types/components/Markdown.js +5 -4
  97. package/lib/types/components/MessageList.d.ts.map +1 -1
  98. package/lib/types/components/MessageList.js +17 -12
  99. package/lib/types/components/PromptInput.d.ts +13 -5
  100. package/lib/types/components/PromptInput.d.ts.map +1 -1
  101. package/lib/types/components/PromptInput.js +189 -107
  102. package/lib/types/components/SplitDiffView.d.ts.map +1 -1
  103. package/lib/types/components/SplitDiffView.js +232 -22
  104. package/lib/types/components/SubagentDetailScene.d.ts +3 -1
  105. package/lib/types/components/SubagentDetailScene.d.ts.map +1 -1
  106. package/lib/types/components/SubagentDetailScene.js +5 -1
  107. package/lib/types/components/Whale.d.ts.map +1 -1
  108. package/lib/types/components/Whale.js +8 -5
  109. package/lib/types/components/approvals/ApprovalPanel.d.ts +1 -1
  110. package/lib/types/components/approvals/ApprovalPanel.d.ts.map +1 -1
  111. package/lib/types/components/approvals/ApprovalPanel.js +93 -11
  112. package/lib/types/components/bigfont.d.ts.map +1 -1
  113. package/lib/types/components/bigfont.js +2 -1
  114. package/lib/types/components/messages/AssistantToolUseMessage.d.ts.map +1 -1
  115. package/lib/types/components/messages/AssistantToolUseMessage.js +13 -6
  116. package/lib/types/components/previewRows.d.ts +19 -0
  117. package/lib/types/components/previewRows.d.ts.map +1 -0
  118. package/lib/types/components/previewRows.js +46 -0
  119. package/lib/types/components/questions/AskUserQuestionPanel.d.ts.map +1 -1
  120. package/lib/types/components/questions/AskUserQuestionPanel.js +75 -10
  121. package/lib/types/components/sessions/ForeignSessionRow.d.ts +3 -9
  122. package/lib/types/components/sessions/ForeignSessionRow.d.ts.map +1 -1
  123. package/lib/types/components/sessions/ForeignSessionRow.js +6 -10
  124. package/lib/types/components/sessions/SessionListRow.d.ts +4 -9
  125. package/lib/types/components/sessions/SessionListRow.d.ts.map +1 -1
  126. package/lib/types/components/sessions/SessionListRow.js +18 -10
  127. package/lib/types/components/sidePanel/InfoPanel.d.ts.map +1 -1
  128. package/lib/types/components/sidePanel/InfoPanel.js +4 -3
  129. package/lib/types/components/sidePanel/SidePanelLayout.d.ts.map +1 -1
  130. package/lib/types/components/sidePanel/SidePanelLayout.js +5 -5
  131. package/lib/types/components/sidePanel/WorkspacePanel.d.ts.map +1 -1
  132. package/lib/types/components/sidePanel/WorkspacePanel.js +19 -7
  133. package/lib/types/components/sidePanel/builtinPanels.d.ts.map +1 -1
  134. package/lib/types/components/sidePanel/builtinPanels.js +22 -16
  135. package/lib/types/components/sidePanel/companion/CompanionPanel.d.ts.map +1 -1
  136. package/lib/types/components/sidePanel/companion/CompanionPanel.js +2 -1
  137. package/lib/types/components/sidePanel/panelMarkdown.d.ts +32 -0
  138. package/lib/types/components/sidePanel/panelMarkdown.d.ts.map +1 -0
  139. package/lib/types/components/sidePanel/panelMarkdown.js +45 -0
  140. package/lib/types/components/sidePanel/pluginPanelAdapter.d.ts.map +1 -1
  141. package/lib/types/components/sidePanel/pluginPanelAdapter.js +6 -1
  142. package/lib/types/components/sidePanel/subagentFailureRead.d.ts +21 -0
  143. package/lib/types/components/sidePanel/subagentFailureRead.d.ts.map +1 -0
  144. package/lib/types/components/sidePanel/subagentFailureRead.js +66 -0
  145. package/lib/types/components/sidePanel/useSidePanel.d.ts.map +1 -1
  146. package/lib/types/components/sidePanel/useSidePanel.js +24 -6
  147. package/lib/types/components/trajectory/MiniWake.d.ts +2 -2
  148. package/lib/types/components/trajectory/MiniWake.d.ts.map +1 -1
  149. package/lib/types/components/trajectory/MiniWake.js +7 -3
  150. package/lib/types/components/workspaces/HomeWorkspaceRow.d.ts.map +1 -1
  151. package/lib/types/components/workspaces/HomeWorkspaceRow.js +4 -7
  152. package/lib/types/dsh-adapter/backend/translate.d.ts.map +1 -1
  153. package/lib/types/dsh-adapter/backend/translate.js +11 -1
  154. package/lib/types/dsh-adapter/backend-admission.d.ts +3 -3
  155. package/lib/types/dsh-adapter/channel/binding-events.d.ts +5 -1
  156. package/lib/types/dsh-adapter/channel/binding-events.d.ts.map +1 -1
  157. package/lib/types/dsh-adapter/channel/binding-events.js +18 -1
  158. package/lib/types/dsh-adapter/channel/command-completions.d.ts.map +1 -1
  159. package/lib/types/dsh-adapter/channel/command-completions.js +6 -8
  160. package/lib/types/dsh-adapter/channel/composer-images.d.ts +9 -1
  161. package/lib/types/dsh-adapter/channel/composer-images.d.ts.map +1 -1
  162. package/lib/types/dsh-adapter/channel/composer-images.js +111 -111
  163. package/lib/types/dsh-adapter/channel/composer-mentions.d.ts.map +1 -1
  164. package/lib/types/dsh-adapter/channel/composer-mentions.js +16 -10
  165. package/lib/types/dsh-adapter/channel/core/actions.d.ts +1 -1
  166. package/lib/types/dsh-adapter/channel/core/actions.d.ts.map +1 -1
  167. package/lib/types/dsh-adapter/channel/core/actions.js +23 -2
  168. package/lib/types/dsh-adapter/channel/core/binding-feed.d.ts +4 -1
  169. package/lib/types/dsh-adapter/channel/core/binding-feed.d.ts.map +1 -1
  170. package/lib/types/dsh-adapter/channel/core/binding-feed.js +13 -2
  171. package/lib/types/dsh-adapter/channel/core/compose.d.ts +4 -1
  172. package/lib/types/dsh-adapter/channel/core/compose.d.ts.map +1 -1
  173. package/lib/types/dsh-adapter/channel/core/compose.js +2 -0
  174. package/lib/types/dsh-adapter/channel/core/files.d.ts.map +1 -1
  175. package/lib/types/dsh-adapter/channel/core/files.js +2 -1
  176. package/lib/types/dsh-adapter/channel/core/host.d.ts +14 -10
  177. package/lib/types/dsh-adapter/channel/core/host.d.ts.map +1 -1
  178. package/lib/types/dsh-adapter/channel/core/host.js +192 -13
  179. package/lib/types/dsh-adapter/channel/core/local-actions.d.ts +1 -0
  180. package/lib/types/dsh-adapter/channel/core/local-actions.d.ts.map +1 -1
  181. package/lib/types/dsh-adapter/channel/core/local-actions.js +32 -3
  182. package/lib/types/dsh-adapter/channel/extensions.d.ts.map +1 -1
  183. package/lib/types/dsh-adapter/channel/extensions.js +31 -5
  184. package/lib/types/dsh-adapter/channel/input-actions.d.ts.map +1 -1
  185. package/lib/types/dsh-adapter/channel/input-actions.js +4 -0
  186. package/lib/types/dsh-adapter/channel/input-delivery.d.ts +4 -1
  187. package/lib/types/dsh-adapter/channel/input-delivery.d.ts.map +1 -1
  188. package/lib/types/dsh-adapter/channel/input-delivery.js +24 -1
  189. package/lib/types/dsh-adapter/channel/model-actions.d.ts +1 -1
  190. package/lib/types/dsh-adapter/channel/model-actions.d.ts.map +1 -1
  191. package/lib/types/dsh-adapter/channel/model-actions.js +7 -1
  192. package/lib/types/dsh-adapter/channel/model-selection.d.ts.map +1 -1
  193. package/lib/types/dsh-adapter/channel/model-selection.js +6 -4
  194. package/lib/types/dsh-adapter/channel/session-fork.d.ts.map +1 -1
  195. package/lib/types/dsh-adapter/channel/session-fork.js +1 -0
  196. package/lib/types/dsh-adapter/channel/session-metadata.d.ts.map +1 -1
  197. package/lib/types/dsh-adapter/channel/session-metadata.js +15 -2
  198. package/lib/types/dsh-adapter/channel/session-reset.d.ts +1 -1
  199. package/lib/types/dsh-adapter/channel/session-reset.d.ts.map +1 -1
  200. package/lib/types/dsh-adapter/channel/session-reset.js +4 -0
  201. package/lib/types/dsh-adapter/channel/session-resume.d.ts.map +1 -1
  202. package/lib/types/dsh-adapter/channel/session-resume.js +46 -33
  203. package/lib/types/dsh-adapter/channel/settings-host.d.ts.map +1 -1
  204. package/lib/types/dsh-adapter/channel/settings-host.js +10 -3
  205. package/lib/types/dsh-adapter/channel/state.d.ts +1 -1
  206. package/lib/types/dsh-adapter/channel/state.d.ts.map +1 -1
  207. package/lib/types/dsh-adapter/channel/state.js +2 -2
  208. package/lib/types/dsh-adapter/channel/types.d.ts +13 -1
  209. package/lib/types/dsh-adapter/channel/types.d.ts.map +1 -1
  210. package/lib/types/dsh-adapter/compat/liveSession.d.ts +3 -3
  211. package/lib/types/dsh-adapter/compat/liveSession.js +3 -3
  212. package/lib/types/dsh-adapter/compat/sessionLog.d.ts +1 -1
  213. package/lib/types/dsh-adapter/compat/sessionLog.d.ts.map +1 -1
  214. package/lib/types/dsh-adapter/compat/sessionLog.js +17 -1
  215. package/lib/types/dsh-adapter/contract.d.ts +6 -5
  216. package/lib/types/dsh-adapter/contract.d.ts.map +1 -1
  217. package/lib/types/dsh-adapter/contract.js +7 -5
  218. package/lib/types/dsh-adapter/effect-ledger.d.ts +1 -1
  219. package/lib/types/dsh-adapter/effect-ledger.d.ts.map +1 -1
  220. package/lib/types/dsh-adapter/effect-ledger.js +1 -0
  221. package/lib/types/dsh-adapter/experimental-bundles.d.ts +26 -0
  222. package/lib/types/dsh-adapter/experimental-bundles.d.ts.map +1 -0
  223. package/lib/types/dsh-adapter/experimental-bundles.js +11 -0
  224. package/lib/types/dsh-adapter/host-contract.d.ts +1 -1
  225. package/lib/types/dsh-adapter/host-contract.js +1 -1
  226. package/lib/types/dsh-adapter/host-dsh.js +3 -3
  227. package/lib/types/dsh-adapter/index.d.ts +8 -4
  228. package/lib/types/dsh-adapter/index.d.ts.map +1 -1
  229. package/lib/types/dsh-adapter/index.js +9 -7
  230. package/lib/types/dsh-adapter/panels.d.ts +21 -7
  231. package/lib/types/dsh-adapter/panels.d.ts.map +1 -1
  232. package/lib/types/dsh-adapter/panels.js +11 -56
  233. package/lib/types/dsh-adapter/plugin.d.ts +81 -0
  234. package/lib/types/dsh-adapter/plugin.d.ts.map +1 -1
  235. package/lib/types/dsh-adapter/plugin.js +318 -70
  236. package/lib/types/dsh-adapter/plugins-info.d.ts.map +1 -1
  237. package/lib/types/dsh-adapter/plugins-info.js +65 -10
  238. package/lib/types/dsh-adapter/presets.d.ts +15 -6
  239. package/lib/types/dsh-adapter/presets.d.ts.map +1 -1
  240. package/lib/types/dsh-adapter/presets.js +51 -12
  241. package/lib/types/dsh-adapter/process-exit.d.ts +1 -1
  242. package/lib/types/dsh-adapter/process-exit.js +1 -1
  243. package/lib/types/dsh-adapter/session-tools.d.ts +34 -0
  244. package/lib/types/dsh-adapter/session-tools.d.ts.map +1 -0
  245. package/lib/types/dsh-adapter/session-tools.js +39 -0
  246. package/lib/types/dsh-adapter/settings-sections.d.ts +18 -1
  247. package/lib/types/dsh-adapter/settings-sections.d.ts.map +1 -1
  248. package/lib/types/dsh-adapter/settings-sections.js +73 -0
  249. package/lib/types/dsh-adapter/status.d.ts +88 -1
  250. package/lib/types/dsh-adapter/status.d.ts.map +1 -1
  251. package/lib/types/dsh-adapter/status.js +318 -3
  252. package/lib/types/dsh-adapter/team-mode.d.ts +42 -33
  253. package/lib/types/dsh-adapter/team-mode.d.ts.map +1 -1
  254. package/lib/types/dsh-adapter/team-mode.js +76 -112
  255. package/lib/types/extensions.d.ts +1 -1
  256. package/lib/types/extensions.d.ts.map +1 -1
  257. package/lib/types/force-production-react.js +3 -3
  258. package/lib/types/i18n.d.ts +195 -52
  259. package/lib/types/i18n.d.ts.map +1 -1
  260. package/lib/types/i18n.js +96 -30
  261. package/lib/types/ink/colorize.d.ts +7 -1
  262. package/lib/types/ink/colorize.d.ts.map +1 -1
  263. package/lib/types/ink/colorize.js +29 -8
  264. package/lib/types/ink/components/App.d.ts +2 -1
  265. package/lib/types/ink/components/App.d.ts.map +1 -1
  266. package/lib/types/ink/components/App.js +10 -3
  267. package/lib/types/ink/components/ScrollBox.d.ts.map +1 -1
  268. package/lib/types/ink/components/ScrollBox.js +1 -0
  269. package/lib/types/ink/dom.d.ts +1 -0
  270. package/lib/types/ink/dom.d.ts.map +1 -1
  271. package/lib/types/ink/hooks/use-program-status.d.ts +78 -0
  272. package/lib/types/ink/hooks/use-program-status.d.ts.map +1 -0
  273. package/lib/types/ink/hooks/use-program-status.js +96 -0
  274. package/lib/types/ink/ink.d.ts +13 -4
  275. package/lib/types/ink/ink.d.ts.map +1 -1
  276. package/lib/types/ink/ink.js +119 -25
  277. package/lib/types/ink/output.d.ts +17 -2
  278. package/lib/types/ink/output.d.ts.map +1 -1
  279. package/lib/types/ink/output.js +85 -2
  280. package/lib/types/ink/parse-keypress.d.ts +1 -0
  281. package/lib/types/ink/parse-keypress.d.ts.map +1 -1
  282. package/lib/types/ink/parse-keypress.js +5 -4
  283. package/lib/types/ink/render-node-to-output.d.ts +2 -0
  284. package/lib/types/ink/render-node-to-output.d.ts.map +1 -1
  285. package/lib/types/ink/render-node-to-output.js +79 -10
  286. package/lib/types/ink/root.d.ts +8 -0
  287. package/lib/types/ink/root.d.ts.map +1 -1
  288. package/lib/types/ink/root.js +12 -3
  289. package/lib/types/ink/screen.d.ts +11 -0
  290. package/lib/types/ink/screen.d.ts.map +1 -1
  291. package/lib/types/ink/screen.js +44 -0
  292. package/lib/types/ink/selection.d.ts +7 -2
  293. package/lib/types/ink/selection.d.ts.map +1 -1
  294. package/lib/types/ink/selection.js +187 -44
  295. package/lib/types/ink/shutdown-input.d.ts +15 -0
  296. package/lib/types/ink/shutdown-input.d.ts.map +1 -0
  297. package/lib/types/ink/shutdown-input.js +28 -0
  298. package/lib/types/ink/sixel-cursor-heal.d.ts +21 -0
  299. package/lib/types/ink/sixel-cursor-heal.d.ts.map +1 -0
  300. package/lib/types/ink/sixel-cursor-heal.js +62 -0
  301. package/lib/types/ink/sixel-graphics.d.ts +6 -0
  302. package/lib/types/ink/sixel-graphics.d.ts.map +1 -1
  303. package/lib/types/ink/sixel-graphics.js +18 -0
  304. package/lib/types/ink/styles.d.ts +8 -1
  305. package/lib/types/ink/styles.d.ts.map +1 -1
  306. package/lib/types/ink/terminal-notification-windows.d.ts +195 -0
  307. package/lib/types/ink/terminal-notification-windows.d.ts.map +1 -0
  308. package/lib/types/ink/terminal-notification-windows.js +433 -0
  309. package/lib/types/ink/terminal-notification.d.ts +3 -1
  310. package/lib/types/ink/terminal-notification.d.ts.map +1 -1
  311. package/lib/types/ink/terminal-notification.js +4 -1
  312. package/lib/types/ink/terminal-querier.d.ts +9 -1
  313. package/lib/types/ink/terminal-querier.d.ts.map +1 -1
  314. package/lib/types/ink/terminal-querier.js +32 -1
  315. package/lib/types/ink/terminal.d.ts +23 -2
  316. package/lib/types/ink/terminal.d.ts.map +1 -1
  317. package/lib/types/ink/terminal.js +32 -2
  318. package/lib/types/ink/termio/osc.d.ts +2 -1
  319. package/lib/types/ink/termio/osc.d.ts.map +1 -1
  320. package/lib/types/ink/termio/osc.js +37 -8
  321. package/lib/types/ink/termio/osc7501.d.ts +102 -0
  322. package/lib/types/ink/termio/osc7501.d.ts.map +1 -0
  323. package/lib/types/ink/termio/osc7501.js +229 -0
  324. package/lib/types/ink/termio/tokenize.js +5 -7
  325. package/lib/types/panels.d.ts +1 -1
  326. package/lib/types/panels.d.ts.map +1 -1
  327. package/lib/types/screens/AgentTranscriptScene.d.ts +3 -1
  328. package/lib/types/screens/AgentTranscriptScene.d.ts.map +1 -1
  329. package/lib/types/screens/AgentTranscriptScene.js +5 -1
  330. package/lib/types/screens/Chat.d.ts +6 -6
  331. package/lib/types/screens/Chat.d.ts.map +1 -1
  332. package/lib/types/screens/Chat.js +304 -111
  333. package/lib/types/screens/Launchpad.d.ts +8 -2
  334. package/lib/types/screens/Launchpad.d.ts.map +1 -1
  335. package/lib/types/screens/Launchpad.js +32 -12
  336. package/lib/types/screens/SessionSupervisor.d.ts.map +1 -1
  337. package/lib/types/screens/SessionSupervisor.js +31 -21
  338. package/lib/types/screens/Settings.d.ts +5 -1
  339. package/lib/types/screens/Settings.d.ts.map +1 -1
  340. package/lib/types/screens/Settings.js +528 -51
  341. package/lib/types/screens/StatusLine.d.ts +9 -3
  342. package/lib/types/screens/StatusLine.d.ts.map +1 -1
  343. package/lib/types/screens/StatusLine.js +91 -15
  344. package/lib/types/screens/StatusMetrics.d.ts +2 -11
  345. package/lib/types/screens/StatusMetrics.d.ts.map +1 -1
  346. package/lib/types/screens/StatusMetrics.js +20 -14
  347. package/lib/types/screens/sessionSupervisor/ForeignSessionPanes.d.ts.map +1 -1
  348. package/lib/types/screens/sessionSupervisor/ForeignSessionPanes.js +1 -1
  349. package/lib/types/screens/sessionSupervisor/useSessionSupervisor.d.ts +1 -1
  350. package/lib/types/screens/sessionSupervisor/useSessionSupervisor.d.ts.map +1 -1
  351. package/lib/types/screens/sessionSupervisor/useSessionSupervisor.js +13 -21
  352. package/lib/types/sessionMounts.d.ts +14 -0
  353. package/lib/types/sessionMounts.d.ts.map +1 -1
  354. package/lib/types/sessionMounts.js +20 -9
  355. package/lib/types/sessions/format.d.ts +39 -0
  356. package/lib/types/sessions/format.d.ts.map +1 -1
  357. package/lib/types/sessions/format.js +83 -0
  358. package/lib/types/sessions/resumeFailure.d.ts +4 -0
  359. package/lib/types/sessions/resumeFailure.d.ts.map +1 -1
  360. package/lib/types/sessions/resumeFailure.js +12 -4
  361. package/lib/types/sessions/workspaceCounts.d.ts +6 -0
  362. package/lib/types/sessions/workspaceCounts.d.ts.map +1 -0
  363. package/lib/types/sessions/workspaceCounts.js +24 -0
  364. package/lib/types/settings/definitions.d.ts +24 -0
  365. package/lib/types/settings/definitions.d.ts.map +1 -1
  366. package/lib/types/settings/definitions.js +38 -13
  367. package/lib/types/tips.js +2 -2
  368. package/lib/types/tuiDisplayPrefs.d.ts +113 -5
  369. package/lib/types/tuiDisplayPrefs.d.ts.map +1 -1
  370. package/lib/types/tuiDisplayPrefs.js +276 -14
  371. package/lib/types/update.d.ts +15 -14
  372. package/lib/types/update.d.ts.map +1 -1
  373. package/lib/types/update.js +163 -115
  374. package/lib/types/updateProcess.d.ts +28 -0
  375. package/lib/types/updateProcess.d.ts.map +1 -0
  376. package/lib/types/updateProcess.js +135 -0
  377. package/lib/types/utils/inputWordBoundary.d.ts +5 -0
  378. package/lib/types/utils/inputWordBoundary.d.ts.map +1 -0
  379. package/lib/types/utils/inputWordBoundary.js +18 -0
  380. package/lib/types/utils/keymap.d.ts +1 -1
  381. package/lib/types/utils/keymap.d.ts.map +1 -1
  382. package/lib/types/utils/keymap.js +6 -1
  383. package/lib/types/windowsInstaller.d.ts +4 -0
  384. package/lib/types/windowsInstaller.d.ts.map +1 -0
  385. package/lib/types/windowsInstaller.js +237 -0
  386. package/locale/en.json +6 -0
  387. package/locale/zh.json +6 -0
  388. package/package.json +127 -111
  389. package/presets/liangshen/custom-bash.mjs +13 -1
  390. package/presets/liangshen/instruction-hint.mjs +4 -1
  391. package/presets/liangshen/skill-search.mjs +14 -2
  392. package/presets/winbash.mjs +16 -4
  393. package/tui-profile/feed/README.md +17 -8
  394. package/tui-profile/feed/first-party.json +1 -1
@@ -0,0 +1,229 @@
1
+ /**
2
+ * OSC 7501 — Program Status Protocol
3
+ *
4
+ * A terminal escape sequence that lets a program tell the terminal what it is
5
+ * doing: idle, working, blocked on the user, done, or failed. The terminal
6
+ * owns presentation; the program only shares state.
7
+ *
8
+ * Spec: https://www.superlogical.com/rex/docs/build/program-status
9
+ *
10
+ * Wire format (the body is `:`-separated `key=value` pairs):
11
+ *
12
+ * ESC ] 7501 ; state=working:app=dsh-tui:msg=<base64> ESC \
13
+ * ESC ] 7501 ; ? ESC \ (detection)
14
+ *
15
+ * Every report REPLACES the addressed record, so a key that must survive has
16
+ * to be repeated on every report. Terminals that do not know the sequence
17
+ * ignore it, which is why reports are sent blind — no detection round trip.
18
+ *
19
+ * This module is pure encoding/parsing: no I/O, no React, no channel imports.
20
+ * The value charset excludes `:` and `;`, so nothing needs escaping; free-text
21
+ * values (`msg`, `title`) are base64 of single-line, control-free UTF-8.
22
+ */
23
+ import { Buffer } from 'buffer';
24
+ import { isEnvTruthy } from '../../utils/envUtils.js';
25
+ import { ESC, ESC_TYPE } from './ansi.js';
26
+ import { OSC } from './osc.js';
27
+ /** The OSC command number for the Program Status Protocol. */
28
+ const PROGRAM_STATUS = OSC.PROGRAM_STATUS;
29
+ /** `ESC ]` — the OSC introducer. */
30
+ const OSC_PREFIX = ESC + String.fromCharCode(ESC_TYPE.OSC);
31
+ /**
32
+ * Protocol hard caps. A report that breaks one is discarded whole by the
33
+ * terminal, so the encoder refuses to build it instead of truncating into a
34
+ * half-applied record.
35
+ */
36
+ const PROGRAM_STATUS_LIMITS = {
37
+ /** Whole sequence, OSC through ST. The largest legal report is under 3300. */
38
+ sequenceBytes: 4096,
39
+ /** Encoded `msg` bytes (base64 of at most 2048 decoded). */
40
+ msgEncodedBytes: 2732,
41
+ /** Decoded `msg` bytes. */
42
+ msgDecodedBytes: 2048,
43
+ /** Encoded `title` bytes (base64 of at most 192 decoded). */
44
+ titleEncodedBytes: 256,
45
+ /** Decoded `title` bytes. */
46
+ titleDecodedBytes: 192,
47
+ /** `app` bytes. */
48
+ appBytes: 32,
49
+ /** Total `id` bytes. */
50
+ idBytes: 128,
51
+ /** `id` bytes per `/`-separated segment. */
52
+ idSegmentBytes: 32,
53
+ };
54
+ /**
55
+ * Collapse free text to the single control-free line the protocol requires.
56
+ * Control characters (C0/C1, DEL) and line breaks would be rejected by a
57
+ * conforming terminal and can smuggle sequence boundaries, so they are
58
+ * dropped rather than escaped — there is no escape mechanism in the format.
59
+ * Bidi overrides and isolates are also removed to keep untrusted labels
60
+ * from changing the direction of surrounding status text.
61
+ * @param text - untrusted text (session titles, tool commands, model output).
62
+ * @returns the text with control characters and line breaks removed.
63
+ */
64
+ export function sanitizeProgramText(text) {
65
+ // eslint-disable-next-line no-control-regex
66
+ return text.replace(/[\x00-\x1f\x7f-\x9f\u202a-\u202e\u2066-\u2069]/g, ' ').replace(/\s+/g, ' ').trim();
67
+ }
68
+ /**
69
+ * Truncate to a byte budget on a code-point boundary, so a multi-byte
70
+ * character is never split into invalid UTF-8.
71
+ * @param text - the text to bound.
72
+ * @param maxBytes - the UTF-8 byte budget.
73
+ * @returns the longest prefix within the budget.
74
+ */
75
+ function truncateUtf8(text, maxBytes) {
76
+ if (Buffer.byteLength(text, 'utf8') <= maxBytes)
77
+ return text;
78
+ let out = '';
79
+ let used = 0;
80
+ for (const char of text) {
81
+ const size = Buffer.byteLength(char, 'utf8');
82
+ if (used + size > maxBytes)
83
+ break;
84
+ out += char;
85
+ used += size;
86
+ }
87
+ return out;
88
+ }
89
+ /**
90
+ * Base64 of sanitized, byte-bounded UTF-8 text.
91
+ *
92
+ * The protocol caps free text twice — on the decoded bytes and on the encoded
93
+ * base64 — and the decoded cap is the binding one (base64 of 2048 bytes is
94
+ * exactly 2732, of 192 exactly 256). Both are enforced so a future cap change
95
+ * cannot silently produce an over-long value.
96
+ * @param text - the raw text to encode.
97
+ * @param decodedMaxBytes - the decoded UTF-8 byte budget.
98
+ * @param encodedMaxBytes - the encoded base64 byte budget.
99
+ * @returns the base64 value, or `''` when the text is empty after sanitizing.
100
+ */
101
+ function encodeText(text, decodedMaxBytes, encodedMaxBytes) {
102
+ const clean = truncateUtf8(sanitizeProgramText(text), decodedMaxBytes);
103
+ if (clean === '')
104
+ return '';
105
+ const encoded = Buffer.from(clean, 'utf8').toString('base64');
106
+ return encoded.length > encodedMaxBytes ? '' : encoded;
107
+ }
108
+ /** `id` grammar: `/`-separated `[A-Za-z0-9_.+-]` segments. */
109
+ function isValidRecordId(id) {
110
+ if (id.length === 0 || Buffer.byteLength(id, 'utf8') > PROGRAM_STATUS_LIMITS.idBytes)
111
+ return false;
112
+ const segments = id.split('/');
113
+ if (segments.length > 8)
114
+ return false;
115
+ return segments.every(segment => segment.length > 0
116
+ && Buffer.byteLength(segment, 'utf8') <= PROGRAM_STATUS_LIMITS.idSegmentBytes
117
+ && /^[A-Za-z0-9_.+-]+$/.test(segment));
118
+ }
119
+ /** `app` grammar: `[A-Za-z0-9_.+-]{1,32}`. */
120
+ function isValidApp(app) {
121
+ return app.length > 0
122
+ && Buffer.byteLength(app, 'utf8') <= PROGRAM_STATUS_LIMITS.appBytes
123
+ && /^[A-Za-z0-9_.+-]+$/.test(app);
124
+ }
125
+ /**
126
+ * Build one OSC 7501 report.
127
+ *
128
+ * Returns `''` when the record cannot be encoded legally (unknown state,
129
+ * `kind`/`progress` on a state that forbids it, an `app`/`id` outside its
130
+ * grammar, or a body past the sequence cap) — callers skip the write rather
131
+ * than send a report the terminal would discard.
132
+ *
133
+ * The sequence is NOT wrapped for tmux/screen passthrough on purpose: a
134
+ * passthrough report would reach the outer terminal, which cannot tell panes
135
+ * apart and cannot see the program exit, breaking the protocol's record
136
+ * lifetime. A multiplexer that implements OSC 7501 receives it directly.
137
+ *
138
+ * @param record - the report to encode.
139
+ * @returns the complete sequence, or `''` when it cannot be encoded.
140
+ */
141
+ export function programStatus(record) {
142
+ const { state } = record;
143
+ // Forward `id`: dropping it would widen a targeted clear into "remove every
144
+ // record on the terminal", wiping records other programs own.
145
+ if (state === 'clear')
146
+ return clearProgramStatus(record.id);
147
+ const pairs = [`state=${state}`];
148
+ if (record.id !== undefined) {
149
+ if (!isValidRecordId(record.id))
150
+ return '';
151
+ pairs.push(`id=${record.id}`);
152
+ }
153
+ if (record.kind !== undefined) {
154
+ // `kind` is only defined for `blocked`; anything else must not carry it.
155
+ if (state !== 'blocked')
156
+ return '';
157
+ if (record.kind !== 'permission' && record.kind !== 'question' && record.kind !== 'auth')
158
+ return '';
159
+ pairs.push(`kind=${record.kind}`);
160
+ }
161
+ if (record.progress !== undefined) {
162
+ // `progress` is only defined for `working`/`blocked`.
163
+ if (state !== 'working' && state !== 'blocked')
164
+ return '';
165
+ if (!Number.isInteger(record.progress) || record.progress < 0 || record.progress > 100)
166
+ return '';
167
+ pairs.push(`progress=${record.progress}`);
168
+ }
169
+ if (record.app !== undefined) {
170
+ if (!isValidApp(record.app))
171
+ return '';
172
+ pairs.push(`app=${record.app}`);
173
+ }
174
+ if (record.title !== undefined) {
175
+ const encoded = encodeText(record.title, PROGRAM_STATUS_LIMITS.titleDecodedBytes, PROGRAM_STATUS_LIMITS.titleEncodedBytes);
176
+ if (encoded !== '')
177
+ pairs.push(`title=${encoded}`);
178
+ }
179
+ if (record.msg !== undefined) {
180
+ const encoded = encodeText(record.msg, PROGRAM_STATUS_LIMITS.msgDecodedBytes, PROGRAM_STATUS_LIMITS.msgEncodedBytes);
181
+ if (encoded !== '')
182
+ pairs.push(`msg=${encoded}`);
183
+ }
184
+ const body = pairs.join(':');
185
+ // ST-terminate: the spec allows BEL or ST, and ST avoids BEL side effects
186
+ // (tmux bell-action, terminal beeps) on the terminals that implement this.
187
+ const sequence = `${OSC_PREFIX}${PROGRAM_STATUS};${body}${ESC}\\`;
188
+ if (Buffer.byteLength(sequence, 'utf8') > PROGRAM_STATUS_LIMITS.sequenceBytes)
189
+ return '';
190
+ return sequence;
191
+ }
192
+ /**
193
+ * Build a `clear` report. With an `id`, removes that record and every record
194
+ * beneath it; without one, removes every record on the terminal.
195
+ *
196
+ * Note the protocol already drops `working`/`blocked` records when the process
197
+ * exits or the next shell prompt begins, and deliberately keeps `done`/`error`
198
+ * for the user to find — so a normal exit must NOT clear.
199
+ * @param id - the record path to remove; omitted clears every record.
200
+ * @returns the complete sequence, or `''` when the id is malformed.
201
+ */
202
+ export function clearProgramStatus(id) {
203
+ if (id === undefined)
204
+ return `${OSC_PREFIX}${PROGRAM_STATUS};state=clear${ESC}\\`;
205
+ if (!isValidRecordId(id))
206
+ return '';
207
+ return `${OSC_PREFIX}${PROGRAM_STATUS};state=clear:id=${id}${ESC}\\`;
208
+ }
209
+ /**
210
+ * Whether to report program status.
211
+ *
212
+ * On by default: the protocol is a no-op on terminals that do not implement
213
+ * it (unknown OSCs are ignored), so the only hard requirement is an
214
+ * interactive stdout — a piped or redirected one has no terminal to report
215
+ * to. `DSH_TUI_PROGRAM_STATUS` disables it with any falsy spelling
216
+ * (`0`, `false`, `no`, `off`).
217
+ *
218
+ * @param stdoutIsTTY - whether stdout is an interactive terminal.
219
+ * @param env - the environment to read the opt-out from.
220
+ * @returns true when reports should be emitted.
221
+ */
222
+ export function supportsProgramStatus(stdoutIsTTY = process.stdout.isTTY === true, env = process.env) {
223
+ if (!stdoutIsTTY)
224
+ return false;
225
+ const flag = env.DSH_TUI_PROGRAM_STATUS;
226
+ if (flag === undefined || flag === '')
227
+ return true;
228
+ return isEnvTruthy(flag);
229
+ }
@@ -132,13 +132,11 @@ function tokenize(input, initialState, initialBuffer, flush, x10Mouse, splitInpu
132
132
  i++;
133
133
  emitSequence(data.slice(seqStart, i));
134
134
  }
135
- else if (code === C0.CR || code === C0.LF) {
136
- // Meta+Enter: ESC CR / ESC LF is how Option+Enter arrives from
137
- // terminals without extended key reporting ("Use Option as Meta").
138
- // CR/LF aren't ESC final bytes, but emitting the pair as a
139
- // sequence lets the keypress parser recognize it — otherwise it
140
- // merges with following text ('\x1b\rabc') and the CR submits
141
- // the prompt instead of inserting a newline (#110).
135
+ else if (code === C0.CR || code === C0.LF || code === C0.BS || code === C0.DEL) {
136
+ // Option-as-Meta prefixes Enter and Backspace with ESC. These
137
+ // controls are not ESC final bytes; keep each pair intact so it
138
+ // cannot become a bare Escape followed by an editing key (#110,
139
+ // #1448), including when stdin splits the pair across reads.
142
140
  i++;
143
141
  emitSequence(data.slice(seqStart, i));
144
142
  }
@@ -1,4 +1,4 @@
1
1
  export { name, TuiPanelRuntime, TUI_PANEL_API_VERSION } from './dsh-adapter/panels.js';
2
- export type { TuiPanelDescriptor, TuiPanelProps, TuiPanelCompactProps, TuiPanelHostApi, TuiPanelSnapshot, TuiPanelKeyEvent, TuiPanelUi, TuiPanelEvent, TuiPanelSummary, } from './dsh-adapter/panels.js';
2
+ export type { TuiPanelDescriptor, TuiPanelProps, TuiPanelCompactProps, TuiPanelMarkdownProps, TuiPanelCodeBlockProps, TuiPanelHostApi, TuiPanelSnapshot, TuiPanelKeyEvent, TuiPanelUi, TuiPanelEvent, TuiPanelSummary, } from './dsh-adapter/panels.js';
3
3
  export { default } from './dsh-adapter/panels.js';
4
4
  //# sourceMappingURL=panels.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"panels.d.ts","sourceRoot":"","sources":["../../src/panels.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,IAAI,EAAE,eAAe,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAA;AACtF,YAAY,EACV,kBAAkB,EAClB,aAAa,EACb,oBAAoB,EACpB,eAAe,EACf,gBAAgB,EAChB,gBAAgB,EAChB,UAAU,EACV,aAAa,EACb,eAAe,GAChB,MAAM,yBAAyB,CAAA;AAChC,OAAO,EAAE,OAAO,EAAE,MAAM,yBAAyB,CAAA"}
1
+ {"version":3,"file":"panels.d.ts","sourceRoot":"","sources":["../../src/panels.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,IAAI,EAAE,eAAe,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAA;AACtF,YAAY,EACV,kBAAkB,EAClB,aAAa,EACb,oBAAoB,EACpB,qBAAqB,EACrB,sBAAsB,EACtB,eAAe,EACf,gBAAgB,EAChB,gBAAgB,EAChB,UAAU,EACV,aAAa,EACb,eAAe,GAChB,MAAM,yBAAyB,CAAA;AAChC,OAAO,EAAE,OAAO,EAAE,MAAM,yBAAyB,CAAA"}
@@ -6,6 +6,8 @@ export interface AgentTranscriptSceneProps {
6
6
  /** The child this view reads. Readonly by contract — the scene never
7
7
  * mutates the roster, the Channel or the parent's queues. */
8
8
  readonly subagent: SubagentState;
9
+ /** Called when this failed child is shown, never for its siblings. */
10
+ onFailureRead?: (subagent: SubagentState) => void;
9
11
  /** Where Esc returns to. */
10
12
  readonly source: AgentViewSource;
11
13
  onExit(): void;
@@ -38,5 +40,5 @@ export interface AgentTranscriptSceneProps {
38
40
  * The body uses the same transcript pager as the Detail page, with the
39
41
  * live SubagentState tail merged in.
40
42
  */
41
- export declare function AgentTranscriptScene({ subagent, source, onExit, loadTranscript, messages, compose, roster, onSwitchAgent }: AgentTranscriptSceneProps): React.ReactNode;
43
+ export declare function AgentTranscriptScene({ subagent, onFailureRead, source, onExit, loadTranscript, messages, compose, roster, onSwitchAgent }: AgentTranscriptSceneProps): React.ReactNode;
42
44
  //# sourceMappingURL=AgentTranscriptScene.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"AgentTranscriptScene.d.ts","sourceRoot":"","sources":["../../../src/screens/AgentTranscriptScene.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,6BAA6B,CAAA;AAEhE,OAAO,EAKL,KAAK,gBAAgB,EACtB,MAAM,8CAA8C,CAAA;AAIrD,OAAO,KAAK,EAAE,kBAAkB,EAAE,mBAAmB,EAAE,gBAAgB,EAAE,eAAe,EAAE,MAAM,qCAAqC,CAAA;AAwDrI,MAAM,WAAW,yBAAyB;IACxC;kEAC8D;IAC9D,QAAQ,CAAC,QAAQ,EAAE,aAAa,CAAA;IAChC,4BAA4B;IAC5B,QAAQ,CAAC,MAAM,EAAE,eAAe,CAAA;IAChC,MAAM,IAAI,IAAI,CAAA;IACd;;gCAE4B;IAC5B,cAAc,CAAC,EAAE,gBAAgB,CAAA;IACjC,yEAAyE;IACzE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BAAgB,CAAA;IACjC,yEAAyE;IACzE,QAAQ,CAAC,QAAQ,CAAC,EAAE,SAAS,gBAAgB,EAAE,CAAA;IAC/C;6DACyD;IACzD,QAAQ,CAAC,OAAO,CAAC,EAAE;QAAE,QAAQ,CAAC,OAAO,EAAE,mBAAmB,CAAC;QAAC,QAAQ,CAAC,MAAM,EAAE,kBAAkB,CAAA;KAAE,CAAA;IACjG;;6BAEyB;IACzB,QAAQ,CAAC,MAAM,CAAC,EAAE,SAAS,aAAa,EAAE,CAAA;IAC1C;;8EAE0E;IAC1E,aAAa,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAA;CAC1C;AAED;;;;;;;GAOG;AACH,wBAAgB,oBAAoB,CAAC,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,EAAE,MAAM,EAAE,cAAc,EAAE,QAAa,EAAE,OAAO,EAAE,MAAM,EAAE,aAAa,EAAE,EAAE,yBAAyB,GAAG,KAAK,CAAC,SAAS,CAwT3L"}
@@ -53,7 +53,11 @@ const sourceLabel = (source) => source.kind === 'chat' ? t('agent-view-source-ch
53
53
  * The body uses the same transcript pager as the Detail page, with the
54
54
  * live SubagentState tail merged in.
55
55
  */
56
- export function AgentTranscriptScene({ subagent, source, onExit, loadTranscript, messages = [], compose, roster, onSwitchAgent }) {
56
+ export function AgentTranscriptScene({ subagent, onFailureRead, source, onExit, loadTranscript, messages = [], compose, roster, onSwitchAgent }) {
57
+ React.useEffect(() => {
58
+ if (subagent.status === 'failed')
59
+ onFailureRead?.(subagent);
60
+ }, [subagent, onFailureRead]);
57
61
  const scrollRef = React.useRef(null);
58
62
  const followRef = React.useRef(true);
59
63
  React.useEffect(() => {
@@ -14,7 +14,7 @@ import type { InjectController } from '../dsh-adapter/inject-channel.js';
14
14
  import type { SdkInstallSurface } from '../agent/backend.js';
15
15
  import type { PluginInstallFlow, PluginInstallSink } from '../dsh-adapter/plugin-install.js';
16
16
  import type { PluginManageFlow, PluginManageSink } from '../dsh-adapter/plugin-manage.js';
17
- import type { TeamCommandOutcome, TeamCommandSink } from '../dsh-adapter/team-mode.js';
17
+ import type { TeamCommandSink } from '../dsh-adapter/team-mode.js';
18
18
  import type { KernelEntry, KernelStatus } from '../components/kernelCatalog.js';
19
19
  import type { KernelBackendId } from '../kernelPrefs.js';
20
20
  export declare function Chat({ channel, questionStore, approvalStore, extensionDialogs, bonusNotices, extensionStatus, activityStore, extensionShortcuts, themeHost, onExit, onUpdate, onRestart, onSwitchBackend, onRestartFreshSession, onProbeKernels, kernelEntries, onResolveSdkInstall, onPluginInstall, onPluginManage, onTeamCommand, kernelPinned, fullscreen, trajectorySeen: trajectorySeenProp, injectControllerRef, promptControllerRef: promptControllerRefProp, renderScene, openHomeOnBoot, launchpadOnBoot, onboardingOnBoot, starPrompt, }: {
@@ -112,11 +112,11 @@ export declare function Chat({ channel, questionStore, approvalStore, extensionD
112
112
  */
113
113
  onPluginManage?: (args: string, sink: PluginManageSink) => PluginManageFlow | undefined;
114
114
  /**
115
- * `/team [status] | on | off`, wired to `createTeamCommandEntry`: on/off
116
- * hand back a lifecycle flow on the Agent Teams bundle (same pane as
117
- * `/plugin`), status a report. `undefined` on a backend without it.
115
+ * `/team [status]`, wired to `createTeamCommandEntry`: a report, or the
116
+ * enable/migration hint when the team service is not mounted. `undefined`
117
+ * on a backend without it.
118
118
  */
119
- onTeamCommand?: (args: string, sink: TeamCommandSink) => TeamCommandOutcome;
119
+ onTeamCommand?: (args: string, sink: TeamCommandSink) => Promise<readonly string[]>;
120
120
  /** 启动参数(Config 行 / DSH_TUI_BACKEND)压过了记忆:选择器明说。 */
121
121
  kernelPinned?: boolean;
122
122
  /**
@@ -192,5 +192,5 @@ export declare function Chat({ channel, questionStore, approvalStore, extensionD
192
192
  * question (does a screen swap lose it?) is about state, not about pixels.
193
193
  */
194
194
  promptControllerRef?: React.RefObject<PromptController | null>;
195
- }): React.JSX.Element | null;
195
+ }): React.ReactNode;
196
196
  //# sourceMappingURL=Ch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