aicodeman 1.40.0 → 1.41.1

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 (351) hide show
  1. package/README.md +81 -13
  2. package/dist/attachment-registry.d.ts +2 -0
  3. package/dist/attachment-registry.d.ts.map +1 -1
  4. package/dist/attachment-registry.js +14 -3
  5. package/dist/attachment-registry.js.map +1 -1
  6. package/dist/cli-agent.d.ts +227 -0
  7. package/dist/cli-agent.d.ts.map +1 -0
  8. package/dist/cli-agent.js +771 -0
  9. package/dist/cli-agent.js.map +1 -0
  10. package/dist/cli.d.ts +25 -1
  11. package/dist/cli.d.ts.map +1 -1
  12. package/dist/cli.js +103 -41
  13. package/dist/cli.js.map +1 -1
  14. package/dist/codeman-credentials.d.ts +27 -0
  15. package/dist/codeman-credentials.d.ts.map +1 -0
  16. package/dist/codeman-credentials.js +66 -0
  17. package/dist/codeman-credentials.js.map +1 -0
  18. package/dist/config/buffer-limits.d.ts +9 -0
  19. package/dist/config/buffer-limits.d.ts.map +1 -1
  20. package/dist/config/buffer-limits.js +9 -0
  21. package/dist/config/buffer-limits.js.map +1 -1
  22. package/dist/config/cli-registry/schema.d.ts +10 -0
  23. package/dist/config/cli-registry/schema.d.ts.map +1 -1
  24. package/dist/config/cli-registry/schema.js +15 -0
  25. package/dist/config/cli-registry/schema.js.map +1 -1
  26. package/dist/config/cli-registry/stock.d.ts.map +1 -1
  27. package/dist/config/cli-registry/stock.js +47 -0
  28. package/dist/config/cli-registry/stock.js.map +1 -1
  29. package/dist/config/cli-registry/types.d.ts +47 -1
  30. package/dist/config/cli-registry/types.d.ts.map +1 -1
  31. package/dist/folder-listing.d.ts +94 -0
  32. package/dist/folder-listing.d.ts.map +1 -0
  33. package/dist/folder-listing.js +241 -0
  34. package/dist/folder-listing.js.map +1 -0
  35. package/dist/git-clone.d.ts.map +1 -1
  36. package/dist/git-clone.js +4 -0
  37. package/dist/git-clone.js.map +1 -1
  38. package/dist/hooks-config.d.ts +36 -16
  39. package/dist/hooks-config.d.ts.map +1 -1
  40. package/dist/hooks-config.js +45 -20
  41. package/dist/hooks-config.js.map +1 -1
  42. package/dist/html-view-capabilities.d.ts +54 -0
  43. package/dist/html-view-capabilities.d.ts.map +1 -0
  44. package/dist/html-view-capabilities.js +103 -0
  45. package/dist/html-view-capabilities.js.map +1 -0
  46. package/dist/image-watcher.d.ts.map +1 -1
  47. package/dist/image-watcher.js +6 -2
  48. package/dist/image-watcher.js.map +1 -1
  49. package/dist/mcp-server.d.ts +114 -0
  50. package/dist/mcp-server.d.ts.map +1 -0
  51. package/dist/mcp-server.js +917 -0
  52. package/dist/mcp-server.js.map +1 -0
  53. package/dist/mcp-sync-targets.d.ts +34 -0
  54. package/dist/mcp-sync-targets.d.ts.map +1 -0
  55. package/dist/mcp-sync-targets.js +55 -0
  56. package/dist/mcp-sync-targets.js.map +1 -0
  57. package/dist/mcp-sync.d.ts +7 -1
  58. package/dist/mcp-sync.d.ts.map +1 -1
  59. package/dist/mcp-sync.js +113 -6
  60. package/dist/mcp-sync.js.map +1 -1
  61. package/dist/mux-interface.d.ts +36 -1
  62. package/dist/mux-interface.d.ts.map +1 -1
  63. package/dist/remote-files.d.ts +37 -0
  64. package/dist/remote-files.d.ts.map +1 -1
  65. package/dist/remote-files.js +103 -0
  66. package/dist/remote-files.js.map +1 -1
  67. package/dist/remote-pane-history.d.ts +103 -0
  68. package/dist/remote-pane-history.d.ts.map +1 -0
  69. package/dist/remote-pane-history.js +258 -0
  70. package/dist/remote-pane-history.js.map +1 -0
  71. package/dist/remote-ssh-limiter.d.ts +16 -3
  72. package/dist/remote-ssh-limiter.d.ts.map +1 -1
  73. package/dist/remote-ssh-limiter.js +37 -6
  74. package/dist/remote-ssh-limiter.js.map +1 -1
  75. package/dist/session.d.ts +29 -1
  76. package/dist/session.d.ts.map +1 -1
  77. package/dist/session.js +63 -4
  78. package/dist/session.js.map +1 -1
  79. package/dist/subagent-watcher.d.ts.map +1 -1
  80. package/dist/subagent-watcher.js +29 -6
  81. package/dist/subagent-watcher.js.map +1 -1
  82. package/dist/tab-layout-legacy-order.d.ts.map +1 -1
  83. package/dist/tab-layout-legacy-order.js +72 -13
  84. package/dist/tab-layout-legacy-order.js.map +1 -1
  85. package/dist/tab-layout-service.d.ts +33 -2
  86. package/dist/tab-layout-service.d.ts.map +1 -1
  87. package/dist/tab-layout-service.js +102 -7
  88. package/dist/tab-layout-service.js.map +1 -1
  89. package/dist/tab-layout.d.ts +9 -0
  90. package/dist/tab-layout.d.ts.map +1 -1
  91. package/dist/tab-layout.js +15 -2
  92. package/dist/tab-layout.js.map +1 -1
  93. package/dist/templates/case-template.md +2 -0
  94. package/dist/tmux-manager.d.ts +76 -2
  95. package/dist/tmux-manager.d.ts.map +1 -1
  96. package/dist/tmux-manager.js +216 -40
  97. package/dist/tmux-manager.js.map +1 -1
  98. package/dist/tui/tui-client.d.ts +3 -17
  99. package/dist/tui/tui-client.d.ts.map +1 -1
  100. package/dist/tui/tui-client.js +3 -44
  101. package/dist/tui/tui-client.js.map +1 -1
  102. package/dist/types/session.d.ts +53 -0
  103. package/dist/types/session.d.ts.map +1 -1
  104. package/dist/types/session.js.map +1 -1
  105. package/dist/usage-telemetry.d.ts +44 -7
  106. package/dist/usage-telemetry.d.ts.map +1 -1
  107. package/dist/usage-telemetry.js +72 -7
  108. package/dist/usage-telemetry.js.map +1 -1
  109. package/dist/utils/index.d.ts +1 -0
  110. package/dist/utils/index.d.ts.map +1 -1
  111. package/dist/utils/index.js +1 -0
  112. package/dist/utils/index.js.map +1 -1
  113. package/dist/utils/process-exit-wait.d.ts +40 -0
  114. package/dist/utils/process-exit-wait.d.ts.map +1 -0
  115. package/dist/utils/process-exit-wait.js +68 -0
  116. package/dist/utils/process-exit-wait.js.map +1 -0
  117. package/dist/web/approval-inbox.d.ts +12 -0
  118. package/dist/web/approval-inbox.d.ts.map +1 -1
  119. package/dist/web/approval-inbox.js +1 -0
  120. package/dist/web/approval-inbox.js.map +1 -1
  121. package/dist/web/middleware/auth.d.ts.map +1 -1
  122. package/dist/web/middleware/auth.js +33 -0
  123. package/dist/web/middleware/auth.js.map +1 -1
  124. package/dist/web/paste-image-gc.d.ts +46 -6
  125. package/dist/web/paste-image-gc.d.ts.map +1 -1
  126. package/dist/web/paste-image-gc.js +106 -32
  127. package/dist/web/paste-image-gc.js.map +1 -1
  128. package/dist/web/ports/session-port.d.ts +8 -1
  129. package/dist/web/ports/session-port.d.ts.map +1 -1
  130. package/dist/web/public/admin-ui.js.gz +0 -0
  131. package/dist/web/public/api-client.c9b1cddc.js.gz +0 -0
  132. package/dist/web/public/app.24689381.js +43 -0
  133. package/dist/web/public/app.24689381.js.br +0 -0
  134. package/dist/web/public/app.24689381.js.gz +0 -0
  135. package/dist/web/public/approvals-ui.js +4 -0
  136. package/dist/web/public/approvals-ui.js.br +0 -0
  137. package/dist/web/public/approvals-ui.js.gz +0 -0
  138. package/dist/web/public/{constants.c0f8f9de.js → constants.17d77b65.js} +690 -35
  139. package/dist/web/public/constants.17d77b65.js.br +0 -0
  140. package/dist/web/public/constants.17d77b65.js.gz +0 -0
  141. package/dist/web/public/cron-ui.js.gz +0 -0
  142. package/dist/web/public/entrance-animations.js +490 -43
  143. package/dist/web/public/entrance-animations.js.br +0 -0
  144. package/dist/web/public/entrance-animations.js.gz +0 -0
  145. package/dist/web/public/gesture/gesture-codeman.js +112 -6
  146. package/dist/web/public/git-status-ui.js.gz +0 -0
  147. package/dist/web/public/home-sessions.js +2 -1
  148. package/dist/web/public/home-sessions.js.br +0 -0
  149. package/dist/web/public/home-sessions.js.gz +0 -0
  150. package/dist/web/public/host-wake-ui.js.gz +0 -0
  151. package/dist/web/public/i18n.9afd8e4d.js +2 -0
  152. package/dist/web/public/i18n.9afd8e4d.js.br +0 -0
  153. package/dist/web/public/i18n.9afd8e4d.js.gz +0 -0
  154. package/dist/web/public/image-input.9ed1d0d2.js +453 -0
  155. package/dist/web/public/image-input.9ed1d0d2.js.br +0 -0
  156. package/dist/web/public/image-input.9ed1d0d2.js.gz +0 -0
  157. package/dist/web/public/index.html +223 -46
  158. package/dist/web/public/index.html.br +0 -0
  159. package/dist/web/public/index.html.gz +0 -0
  160. package/dist/web/public/input-cjk.8bc46081.js.gz +0 -0
  161. package/dist/web/public/{keyboard-accessory.c1e7c7b7.js → keyboard-accessory.c458eea8.js} +115 -35
  162. package/dist/web/public/keyboard-accessory.c458eea8.js.br +0 -0
  163. package/dist/web/public/keyboard-accessory.c458eea8.js.gz +0 -0
  164. package/dist/web/public/mobile-handlers.0ef9c311.js.gz +0 -0
  165. package/dist/web/public/mobile-ime-preview.2dbaf262.js.gz +0 -0
  166. package/dist/web/public/mobile-overview.js +11 -2
  167. package/dist/web/public/mobile-overview.js.br +0 -0
  168. package/dist/web/public/mobile-overview.js.gz +0 -0
  169. package/dist/web/public/mobile.2dff1580.css +1 -0
  170. package/dist/web/public/mobile.2dff1580.css.br +0 -0
  171. package/dist/web/public/mobile.2dff1580.css.gz +0 -0
  172. package/dist/web/public/{notification-manager.50bb87d8.js → notification-manager.feb82c04.js} +19 -2
  173. package/dist/web/public/notification-manager.feb82c04.js.br +0 -0
  174. package/dist/web/public/notification-manager.feb82c04.js.gz +0 -0
  175. package/dist/web/public/orchestrator-panel.js.gz +0 -0
  176. package/dist/web/public/{panels-ui.4735dfc2.js → panels-ui.73ec0137.js} +87 -87
  177. package/dist/web/public/panels-ui.73ec0137.js.br +0 -0
  178. package/dist/web/public/panels-ui.73ec0137.js.gz +0 -0
  179. package/dist/web/public/ralph-panel.b350e2ef.js.gz +0 -0
  180. package/dist/web/public/ralph-wizard.b6c0dd19.js.gz +0 -0
  181. package/dist/web/public/readmymind-ui.js.gz +0 -0
  182. package/dist/web/public/reboot-restore-ui.js.gz +0 -0
  183. package/dist/web/public/respawn-ui.ff0dae4c.js.gz +0 -0
  184. package/dist/web/public/sanitize-html.e7147e76.js.gz +0 -0
  185. package/dist/web/public/session-lineage.js.gz +0 -0
  186. package/dist/web/public/{session-ui.f731602c.js → session-ui.dbc6819b.js} +33 -33
  187. package/dist/web/public/session-ui.dbc6819b.js.br +0 -0
  188. package/dist/web/public/session-ui.dbc6819b.js.gz +0 -0
  189. package/dist/web/public/settings-ui.81ac264e.js +97 -0
  190. package/dist/web/public/settings-ui.81ac264e.js.br +0 -0
  191. package/dist/web/public/settings-ui.81ac264e.js.gz +0 -0
  192. package/dist/web/public/spreadsheet-preview-worker.js +11 -0
  193. package/dist/web/public/spreadsheet-preview-worker.js.br +0 -0
  194. package/dist/web/public/spreadsheet-preview-worker.js.gz +0 -0
  195. package/dist/web/public/{spreadsheet-preview.af82fa2f.js → spreadsheet-preview.75c751de.js} +1 -1
  196. package/dist/web/public/spreadsheet-preview.75c751de.js.br +0 -0
  197. package/dist/web/public/spreadsheet-preview.75c751de.js.gz +0 -0
  198. package/dist/web/public/spreadsheet-xlsx-core.js +110 -0
  199. package/dist/web/public/spreadsheet-xlsx-core.js.br +0 -0
  200. package/dist/web/public/spreadsheet-xlsx-core.js.gz +0 -0
  201. package/dist/web/public/styles.900a28e4.css +1 -0
  202. package/dist/web/public/styles.900a28e4.css.br +0 -0
  203. package/dist/web/public/styles.900a28e4.css.gz +0 -0
  204. package/dist/web/public/{subagent-windows.e6ca799f.js → subagent-windows.07277a58.js} +7 -5
  205. package/dist/web/public/subagent-windows.07277a58.js.br +0 -0
  206. package/dist/web/public/subagent-windows.07277a58.js.gz +0 -0
  207. package/dist/web/public/sw.js +6 -2
  208. package/dist/web/public/sw.js.br +0 -0
  209. package/dist/web/public/sw.js.gz +0 -0
  210. package/dist/web/public/tab-layout-browser.2d6189f7.js +1 -0
  211. package/dist/web/public/tab-layout-browser.2d6189f7.js.br +0 -0
  212. package/dist/web/public/tab-layout-browser.2d6189f7.js.gz +0 -0
  213. package/dist/web/public/{tab-rail-resize.a5867793.js → tab-rail-resize.7157e0bd.js} +1 -1
  214. package/dist/web/public/tab-rail-resize.7157e0bd.js.br +0 -0
  215. package/dist/web/public/tab-rail-resize.7157e0bd.js.gz +0 -0
  216. package/dist/web/public/terminal-keycode229-recovery.af09f99a.js.gz +0 -0
  217. package/dist/web/public/terminal-split.js.gz +0 -0
  218. package/dist/web/public/terminal-tile.js +135 -38
  219. package/dist/web/public/terminal-tile.js.br +0 -0
  220. package/dist/web/public/terminal-tile.js.gz +0 -0
  221. package/dist/web/public/terminal-ui.858f5da5.js +2 -0
  222. package/dist/web/public/terminal-ui.858f5da5.js.br +0 -0
  223. package/dist/web/public/terminal-ui.858f5da5.js.gz +0 -0
  224. package/dist/web/public/tile-grid.js +769 -137
  225. package/dist/web/public/tile-grid.js.br +0 -0
  226. package/dist/web/public/tile-grid.js.gz +0 -0
  227. package/dist/web/public/ultracode-panel.js.gz +0 -0
  228. package/dist/web/public/ultracode-windows.js +9 -6
  229. package/dist/web/public/ultracode-windows.js.br +0 -0
  230. package/dist/web/public/ultracode-windows.js.gz +0 -0
  231. package/dist/web/public/vendor/dompurify.min.js.gz +0 -0
  232. package/dist/web/public/vendor/exceljs.min.js.gz +0 -0
  233. package/dist/web/public/vendor/fflate.min.js.gz +0 -0
  234. package/dist/web/public/vendor/marked.min.js.gz +0 -0
  235. package/dist/web/public/vendor/xterm-addon-fit.min.js.gz +0 -0
  236. package/dist/web/public/vendor/xterm-addon-serialize.min.js.gz +0 -0
  237. package/dist/web/public/vendor/xterm-addon-unicode11.min.js.gz +0 -0
  238. package/dist/web/public/vendor/xterm-addon-webgl.min.js.gz +0 -0
  239. package/dist/web/public/vendor/xterm-predictive-echo.ae5e3d5d.js.gz +0 -0
  240. package/dist/web/public/vendor/xterm-zerolag-input.0b69623c.js +4 -0
  241. package/dist/web/public/vendor/xterm-zerolag-input.0b69623c.js.br +0 -0
  242. package/dist/web/public/vendor/xterm-zerolag-input.0b69623c.js.gz +0 -0
  243. package/dist/web/public/vendor/xterm.css.gz +0 -0
  244. package/dist/web/public/vendor/xterm.min.js.gz +0 -0
  245. package/dist/web/public/voice-input.2342c37b.js.gz +0 -0
  246. package/dist/web/public/voice-pcm-worklet.js.gz +0 -0
  247. package/dist/web/public/webview-tabs.js +12 -0
  248. package/dist/web/public/webview-tabs.js.br +0 -0
  249. package/dist/web/public/webview-tabs.js.gz +0 -0
  250. package/dist/web/route-helpers.d.ts +8 -0
  251. package/dist/web/route-helpers.d.ts.map +1 -1
  252. package/dist/web/route-helpers.js +8 -0
  253. package/dist/web/route-helpers.js.map +1 -1
  254. package/dist/web/routes/admin-routes.d.ts.map +1 -1
  255. package/dist/web/routes/admin-routes.js +4 -1
  256. package/dist/web/routes/admin-routes.js.map +1 -1
  257. package/dist/web/routes/approval-routes.d.ts.map +1 -1
  258. package/dist/web/routes/approval-routes.js +6 -8
  259. package/dist/web/routes/approval-routes.js.map +1 -1
  260. package/dist/web/routes/case-routes.js +1 -1
  261. package/dist/web/routes/case-routes.js.map +1 -1
  262. package/dist/web/routes/cli-registry-routes.d.ts +23 -4
  263. package/dist/web/routes/cli-registry-routes.d.ts.map +1 -1
  264. package/dist/web/routes/cli-registry-routes.js +92 -7
  265. package/dist/web/routes/cli-registry-routes.js.map +1 -1
  266. package/dist/web/routes/file-routes.d.ts +46 -1
  267. package/dist/web/routes/file-routes.d.ts.map +1 -1
  268. package/dist/web/routes/file-routes.js +214 -27
  269. package/dist/web/routes/file-routes.js.map +1 -1
  270. package/dist/web/routes/hook-event-routes.d.ts.map +1 -1
  271. package/dist/web/routes/hook-event-routes.js +8 -1
  272. package/dist/web/routes/hook-event-routes.js.map +1 -1
  273. package/dist/web/routes/html-view-routes.d.ts +60 -0
  274. package/dist/web/routes/html-view-routes.d.ts.map +1 -0
  275. package/dist/web/routes/html-view-routes.js +288 -0
  276. package/dist/web/routes/html-view-routes.js.map +1 -0
  277. package/dist/web/routes/index.d.ts +1 -0
  278. package/dist/web/routes/index.d.ts.map +1 -1
  279. package/dist/web/routes/index.js +1 -0
  280. package/dist/web/routes/index.js.map +1 -1
  281. package/dist/web/routes/mcp-sync-routes.d.ts +7 -2
  282. package/dist/web/routes/mcp-sync-routes.d.ts.map +1 -1
  283. package/dist/web/routes/mcp-sync-routes.js +10 -3
  284. package/dist/web/routes/mcp-sync-routes.js.map +1 -1
  285. package/dist/web/routes/reboot-restore-routes.js +3 -3
  286. package/dist/web/routes/reboot-restore-routes.js.map +1 -1
  287. package/dist/web/routes/session-routes.d.ts +1 -0
  288. package/dist/web/routes/session-routes.d.ts.map +1 -1
  289. package/dist/web/routes/session-routes.js +345 -90
  290. package/dist/web/routes/session-routes.js.map +1 -1
  291. package/dist/web/routes/status-telemetry-routes.d.ts.map +1 -1
  292. package/dist/web/routes/status-telemetry-routes.js +16 -2
  293. package/dist/web/routes/status-telemetry-routes.js.map +1 -1
  294. package/dist/web/schemas.d.ts +32 -0
  295. package/dist/web/schemas.d.ts.map +1 -1
  296. package/dist/web/schemas.js +74 -0
  297. package/dist/web/schemas.js.map +1 -1
  298. package/dist/web/server.d.ts +7 -2
  299. package/dist/web/server.d.ts.map +1 -1
  300. package/dist/web/server.js +77 -24
  301. package/dist/web/server.js.map +1 -1
  302. package/dist/web/sse-events.d.ts +5 -2
  303. package/dist/web/sse-events.d.ts.map +1 -1
  304. package/dist/web/sse-events.js +5 -2
  305. package/dist/web/sse-events.js.map +1 -1
  306. package/package.json +5 -4
  307. package/skills/codeman/SKILL.md +30 -7
  308. package/README.zh-CN.md +0 -1147
  309. package/dist/web/public/app.abadc970.js +0 -43
  310. package/dist/web/public/app.abadc970.js.br +0 -0
  311. package/dist/web/public/app.abadc970.js.gz +0 -0
  312. package/dist/web/public/constants.c0f8f9de.js.br +0 -0
  313. package/dist/web/public/constants.c0f8f9de.js.gz +0 -0
  314. package/dist/web/public/i18n.a31747a9.js +0 -2
  315. package/dist/web/public/i18n.a31747a9.js.br +0 -0
  316. package/dist/web/public/i18n.a31747a9.js.gz +0 -0
  317. package/dist/web/public/image-input.898a538b.js +0 -281
  318. package/dist/web/public/image-input.898a538b.js.br +0 -0
  319. package/dist/web/public/image-input.898a538b.js.gz +0 -0
  320. package/dist/web/public/keyboard-accessory.c1e7c7b7.js.br +0 -0
  321. package/dist/web/public/keyboard-accessory.c1e7c7b7.js.gz +0 -0
  322. package/dist/web/public/mobile.111b187d.css +0 -1
  323. package/dist/web/public/mobile.111b187d.css.br +0 -0
  324. package/dist/web/public/mobile.111b187d.css.gz +0 -0
  325. package/dist/web/public/notification-manager.50bb87d8.js.br +0 -0
  326. package/dist/web/public/notification-manager.50bb87d8.js.gz +0 -0
  327. package/dist/web/public/panels-ui.4735dfc2.js.br +0 -0
  328. package/dist/web/public/panels-ui.4735dfc2.js.gz +0 -0
  329. package/dist/web/public/session-ui.f731602c.js.br +0 -0
  330. package/dist/web/public/session-ui.f731602c.js.gz +0 -0
  331. package/dist/web/public/settings-ui.a97ab16f.js +0 -97
  332. package/dist/web/public/settings-ui.a97ab16f.js.br +0 -0
  333. package/dist/web/public/settings-ui.a97ab16f.js.gz +0 -0
  334. package/dist/web/public/spreadsheet-preview.af82fa2f.js.br +0 -0
  335. package/dist/web/public/spreadsheet-preview.af82fa2f.js.gz +0 -0
  336. package/dist/web/public/styles.8ee12666.css +0 -1
  337. package/dist/web/public/styles.8ee12666.css.br +0 -0
  338. package/dist/web/public/styles.8ee12666.css.gz +0 -0
  339. package/dist/web/public/subagent-windows.e6ca799f.js.br +0 -0
  340. package/dist/web/public/subagent-windows.e6ca799f.js.gz +0 -0
  341. package/dist/web/public/tab-layout-browser.065fcba4.js +0 -1
  342. package/dist/web/public/tab-layout-browser.065fcba4.js.br +0 -0
  343. package/dist/web/public/tab-layout-browser.065fcba4.js.gz +0 -0
  344. package/dist/web/public/tab-rail-resize.a5867793.js.br +0 -0
  345. package/dist/web/public/tab-rail-resize.a5867793.js.gz +0 -0
  346. package/dist/web/public/terminal-ui.5059b30e.js +0 -2
  347. package/dist/web/public/terminal-ui.5059b30e.js.br +0 -0
  348. package/dist/web/public/terminal-ui.5059b30e.js.gz +0 -0
  349. package/dist/web/public/vendor/xterm-zerolag-input.bbb5f84c.js +0 -4
  350. package/dist/web/public/vendor/xterm-zerolag-input.bbb5f84c.js.br +0 -0
  351. package/dist/web/public/vendor/xterm-zerolag-input.bbb5f84c.js.gz +0 -0
@@ -32,11 +32,11 @@ import fastifyCookie from '@fastify/cookie';
32
32
  import fastifyStatic from '@fastify/static';
33
33
  import fastifyWebsocket from '@fastify/websocket';
34
34
  import fastifyMultipart from '@fastify/multipart';
35
- import { pasteImageDirInUseByOtherSession, startPasteImageGc } from './paste-image-gc.js';
35
+ import { pasteImageDirInUseByOtherSession, startPasteImageGc, uploadDirs } from './paste-image-gc.js';
36
36
  import { CLEAN_EXIT_CLOSE_REASON, shouldCloseCleanlyExitedSession } from '../pane-exit-sweep.js';
37
37
  import { join, dirname } from 'node:path';
38
38
  import { fileURLToPath } from 'node:url';
39
- import { existsSync, mkdirSync, readFileSync, chmodSync, rmSync, statSync } from 'node:fs';
39
+ import { existsSync, mkdirSync, readFileSync, chmodSync, statSync } from 'node:fs';
40
40
  import fs from 'node:fs/promises';
41
41
  import { execSync } from 'node:child_process';
42
42
  import { hostname as getHostname, uptime as osUptime } from 'node:os';
@@ -62,6 +62,7 @@ import { subagentWatcher, } from '../subagent-watcher.js';
62
62
  import { imageWatcher } from '../image-watcher.js';
63
63
  import { workflowRunWatcher, summarizeRun } from '../workflow-run-watcher.js';
64
64
  import { attachmentRegistry, buildFileThumbnailRoute, registerExternalAttachment } from '../attachment-registry.js';
65
+ import { folderGrants } from '../folder-listing.js';
65
66
  import { getCli, enabledClis, listClis } from '../config/cli-registry/registry.js';
66
67
  import { isCliEntryInstalled, probeStockCliAvailability } from '../utils/cli-installed-probes.js';
67
68
  import { readCustomModelHosts } from '../custom-model-hosts.js';
@@ -111,6 +112,7 @@ import { MAX_CONCURRENT_SESSIONS, MAX_SSE_CLIENTS } from '../config/map-limits.j
111
112
  import { MAX_PASTE_IMAGE_BYTES } from '../config/buffer-limits.js';
112
113
  import { resolveTerminalHistoryConfig } from '../config/terminal-history.js';
113
114
  import { SseEvent } from './sse-events.js';
115
+ import { MAX_ROUTE_PARAM_LENGTH } from './route-helpers.js';
114
116
  import { getLatestPlanUsage, setLatestCodexPlanUsage } from './plan-usage-latest.js';
115
117
  import { telemetrySignature } from '../usage-telemetry.js';
116
118
  import { readCodexPlanUsage, resolveCodexBinaryPath } from '../utils/codex-cli-resolver.js';
@@ -119,7 +121,7 @@ import { isMultiUserMode } from '../config/multiuser.js';
119
121
  import { bootstrapInitialAdmin, hasUsers, resolveClaudeModeForUsername } from '../user-store.js';
120
122
  import { installRouteErrorHandler } from './route-error-handler.js';
121
123
  import { isExplicitlyEnabled, isLoopbackBindHost, buildHostPolicy } from './network-auth-policy.js';
122
- import { registerPushRoutes, registerTeamRoutes, registerMuxRoutes, registerFileRoutes, registerScheduledRoutes, registerHookEventRoutes, registerApprovalRoutes, registerRebootRestoreRoutes, registerReadMyMindRoutes, registerGitStatusRoutes, registerStatusTelemetryRoutes, registerSystemRoutes, registerCaseRoutes, registerSessionRoutes, registerRespawnRoutes, registerRalphRoutes, registerPlanRoutes, registerClipboardRoutes, registerSearchRoutes, registerOrchestratorRoutes, registerCronRoutes, registerMeRoutes, registerAdminRoutes, registerWsRoutes, registerVoiceRoutes, registerWebviewRoutes, registerTabLayoutRoutes, registerMcpSyncRoutes, registerWebhookRoutes, registerDoctorRoutes, registerCustomModelRoutes, refreshAllCustomModelHosts, readCustomModelEndpointsEnabled, closeAllLlamaSwapLogTails, detectCustomModelSwapDisplacements, pruneIdleLlamaSwapLogTails, tryWebviewRefererFallback, registerCliRegistryRoutes, } from './routes/index.js';
124
+ import { registerPushRoutes, registerTeamRoutes, registerMuxRoutes, registerFileRoutes, registerHtmlViewRoutes, registerScheduledRoutes, registerHookEventRoutes, registerApprovalRoutes, registerRebootRestoreRoutes, registerReadMyMindRoutes, registerGitStatusRoutes, registerStatusTelemetryRoutes, registerSystemRoutes, registerCaseRoutes, registerSessionRoutes, registerRespawnRoutes, registerRalphRoutes, registerPlanRoutes, registerClipboardRoutes, registerSearchRoutes, registerOrchestratorRoutes, registerCronRoutes, registerMeRoutes, registerAdminRoutes, registerWsRoutes, registerVoiceRoutes, registerWebviewRoutes, registerTabLayoutRoutes, registerMcpSyncRoutes, registerWebhookRoutes, registerDoctorRoutes, registerCustomModelRoutes, refreshAllCustomModelHosts, readCustomModelEndpointsEnabled, closeAllLlamaSwapLogTails, detectCustomModelSwapDisplacements, pruneIdleLlamaSwapLogTails, tryWebviewRefererFallback, registerCliRegistryRoutes, } from './routes/index.js';
123
125
  import { isLostWebviewFrameNavigation } from './webview-proxy.js';
124
126
  import { CronService } from '../cron/cron-service.js';
125
127
  const __dirname = dirname(fileURLToPath(import.meta.url));
@@ -282,10 +284,15 @@ export class WebServer extends EventEmitter {
282
284
  const rewriteUrl = (req) => rewriteApiV1Url(stripBasePath(this.basePath, req.url || ''));
283
285
  if (https) {
284
286
  const { key, cert } = getOrCreateSelfSignedCert();
285
- this.app = Fastify({ logger: false, https: { key, cert }, rewriteUrl });
287
+ this.app = Fastify({
288
+ logger: false,
289
+ https: { key, cert },
290
+ rewriteUrl,
291
+ routerOptions: { maxParamLength: MAX_ROUTE_PARAM_LENGTH },
292
+ });
286
293
  }
287
294
  else {
288
- this.app = Fastify({ logger: false, rewriteUrl });
295
+ this.app = Fastify({ logger: false, rewriteUrl, routerOptions: { maxParamLength: MAX_ROUTE_PARAM_LENGTH } });
289
296
  }
290
297
  this.mux = createMultiplexer();
291
298
  this.sse = new SseStreamManager({
@@ -304,6 +311,9 @@ export class WebServer extends EventEmitter {
304
311
  this.cachedLightState = null;
305
312
  this.sse.broadcastSessionOrder(change);
306
313
  },
314
+ // Fresh, not the 2s cache: the settings PUT does not invalidate it, and a
315
+ // flip must apply to the very next spawn.
316
+ childrenFollowParent: async () => (await this.readSettings(true)).spawnedTabsFollowParent === true,
307
317
  });
308
318
  if (this.testMode)
309
319
  this.tabLayouts.markRestorationSkipped();
@@ -537,16 +547,20 @@ export class WebServer extends EventEmitter {
537
547
  this.teamWatcherHandlers = null;
538
548
  }
539
549
  }
540
- /** Add a tentative session only after its owner layout accepts the creation. */
541
- async registerSessionWithLayout(session) {
542
- this.sessions.set(session.id, session);
543
- try {
544
- await this.tabLayouts.sessionCreated(ownerLayoutKey(session.owner));
545
- }
546
- catch (error) {
547
- this.sessions.delete(session.id);
548
- throw error;
549
- }
550
+ /**
551
+ * Add a tentative session only after its owner layout accepts the creation.
552
+ * The session enters the live map inside the layout service's owner lock, so
553
+ * the placement it asked for (`tabGroupId`) lands in the same versioned write
554
+ * that first records it.
555
+ */
556
+ async registerSessionWithLayout(session, placement) {
557
+ return this.tabLayouts.sessionCreated(ownerLayoutKey(session.owner), session.id, placement, () => {
558
+ this.sessions.set(session.id, session);
559
+ return () => {
560
+ if (this.sessions.get(session.id) === session)
561
+ this.sessions.delete(session.id);
562
+ };
563
+ });
550
564
  }
551
565
  /**
552
566
  * Build a route context object satisfying all 5 port interfaces.
@@ -944,6 +958,7 @@ export class WebServer extends EventEmitter {
944
958
  registerTeamRoutes(this.app, ctx);
945
959
  registerMuxRoutes(this.app, ctx);
946
960
  registerFileRoutes(this.app, ctx);
961
+ registerHtmlViewRoutes(this.app, ctx);
947
962
  registerScheduledRoutes(this.app, ctx);
948
963
  registerHookEventRoutes(this.app, ctx);
949
964
  registerApprovalRoutes(this.app, ctx);
@@ -1296,6 +1311,7 @@ export class WebServer extends EventEmitter {
1296
1311
  fileStreamManager.closeSessionStreams(sessionId);
1297
1312
  // Drop live external attachment registrations for this session
1298
1313
  attachmentRegistry.clearSession(sessionId);
1314
+ folderGrants.clearSession(sessionId);
1299
1315
  // Stop watching for images in this session's directory
1300
1316
  imageWatcher.unwatchSession(sessionId);
1301
1317
  // Clean up pasted images directory for this session. The dir belongs to the
@@ -1314,12 +1330,17 @@ export class WebServer extends EventEmitter {
1314
1330
  workingDir: session.workingDir,
1315
1331
  killing: this.killingSessions,
1316
1332
  })) {
1317
- const pasteImageDir = join(session.workingDir, '.claude-images');
1318
- try {
1319
- rmSync(pasteImageDir, { recursive: true, force: true });
1320
- }
1321
- catch {
1322
- // Best-effort cleanup
1333
+ // Both upload dirs, the pre-move one too; uploadDirs() lists only real
1334
+ // directories that are not the data dir and do not contain it, none for a
1335
+ // remote session, and nothing on a workspace whose bounded probe did not
1336
+ // answer (pastCap: this acts on one path at the user's request).
1337
+ for (const uploadDir of await uploadDirs(session, { pastCap: true })) {
1338
+ try {
1339
+ await fs.rm(uploadDir, { recursive: true, force: true });
1340
+ }
1341
+ catch {
1342
+ // Best-effort cleanup
1343
+ }
1323
1344
  }
1324
1345
  }
1325
1346
  // Drop the agent skill's preamble cache for this session (seeded at create).
@@ -1528,6 +1549,16 @@ export class WebServer extends EventEmitter {
1528
1549
  gutterClis[entry.id] = columns;
1529
1550
  }
1530
1551
  html = html.replace('</head>', () => `<script>window.__codemanTranscriptGutter=${JSON.stringify(gutterClis)};</script>\n</head>`);
1552
+ // Which run modes page their own transcript on PageUp/PageDown, for the scroll
1553
+ // fallback over a pane with no local history (`_maybePageCliTranscript`). Read off
1554
+ // the `transcriptPageKeys` capability, never an id list here, and injected for a
1555
+ // solo window too for the same reason as the gutter map: it scrolls a terminal.
1556
+ // Ids only, which the registry schema bounds to kebab tokens, so JSON.stringify
1557
+ // alone is enough.
1558
+ const pageKeyClis = enabledClis()
1559
+ .filter((entry) => entry.capabilities.transcriptPageKeys === true)
1560
+ .map((entry) => entry.id);
1561
+ html = html.replace('</head>', () => `<script>window.__codemanTranscriptPageKeys=${JSON.stringify(pageKeyClis)};</script>\n</head>`);
1531
1562
  if (!soloSessionId && process.env.CODEMAN_GESTURE === '1') {
1532
1563
  html = html.replace('</head>', () => `<script>window.__codemanGestureAvailable=true;</script>\n</head>`);
1533
1564
  if (settings.gestureControlEnabled === true) {
@@ -2396,9 +2427,12 @@ export class WebServer extends EventEmitter {
2396
2427
  // Approvals Inbox item id: lets sw.js answer an Approve/Deny action
2397
2428
  // click directly (POST /api/approvals/:id/answer) with no tab open.
2398
2429
  // Gated on the opt-in setting together with the action buttons.
2430
+ // Approve/Deny only when we also have an approvalId to answer with.
2431
+ // Supervised-hook CLIs (DeepSeek) omit approvalId upstream so this also
2432
+ // strips their action buttons — buttons without an id can never answer.
2399
2433
  approvalId: approvalsEnabled && typeof data.approvalId === 'string' ? data.approvalId : undefined,
2400
2434
  urgency: template.urgency,
2401
- actions: approvalsEnabled ? template.actions : undefined,
2435
+ actions: approvalsEnabled && typeof data.approvalId === 'string' ? template.actions : undefined,
2402
2436
  });
2403
2437
  for (const sub of subscriptions) {
2404
2438
  // Check per-subscription preferences
@@ -2558,7 +2592,7 @@ export class WebServer extends EventEmitter {
2558
2592
  });
2559
2593
  }
2560
2594
  // Bound disk use under heavy paste-image traffic: delete `paste-*` files
2561
- // older than 7 days from each live session's .claude-images/ hourly.
2595
+ // older than 7 days from each live session's upload dirs hourly.
2562
2596
  if (!this.testMode) {
2563
2597
  this._pasteImageGcStop = startPasteImageGc({ sessions: this.sessions });
2564
2598
  // Surface event-loop stalls (e.g. a slow synchronous tmux/ps call) so the
@@ -2946,7 +2980,7 @@ export class WebServer extends EventEmitter {
2946
2980
  * path adds the session's token totals to the lifetime figures, demotes a
2947
2981
  * pinned record to `stopped` (the durable marker of an intentional kill, which
2948
2982
  * would make the session permanently ineligible for a reboot restore), drops
2949
- * the persisted Ralph state, and recursively removes `.claude-images` from the
2983
+ * the persisted Ralph state, and recursively removes the upload dirs from the
2950
2984
  * WORKING DIRECTORY, which belongs to the workspace rather than to this session
2951
2985
  * and may hold another live session's pasted images.
2952
2986
  *
@@ -3000,6 +3034,7 @@ export class WebServer extends EventEmitter {
3000
3034
  // otherwise meet the retry, which reuses the same session id by design.
3001
3035
  this.stopTranscriptWatcher(sessionId);
3002
3036
  attachmentRegistry.clearSession(sessionId);
3037
+ folderGrants.clearSession(sessionId);
3003
3038
  sessionWaits.notifySignal(sessionId, 'exit');
3004
3039
  sessionWaits.cancelAll(sessionId);
3005
3040
  approvalInbox.resolveForSession(sessionId, 'session_ended');
@@ -3140,6 +3175,11 @@ export class WebServer extends EventEmitter {
3140
3175
  // tile header keeps naming it until the next report; an idle claude
3141
3176
  // session re-renders its statusline only on its next turn.
3142
3177
  displayModel: savedState?.displayModel,
3178
+ // The last prompt-cache report, restored for the same reason: an idle claude
3179
+ // session re-renders its statusline only on its next turn, so without this the
3180
+ // Session Options readout would read "not reported yet" after every restart. The
3181
+ // readout is time-aware, so a value past its expiry shows as cold, not stale-warm.
3182
+ promptCache: savedState?.promptCache,
3143
3183
  // A record rebuilt from the socket has no provenance, so its
3144
3184
  // apparent locality is a guess (see `MuxSession.discovered`).
3145
3185
  discoveredMuxSession: muxSession.discovered,
@@ -3238,6 +3278,19 @@ export class WebServer extends EventEmitter {
3238
3278
  if (savedState.flickerFilterEnabled !== undefined) {
3239
3279
  session.flickerFilterEnabled = savedState.flickerFilterEnabled;
3240
3280
  }
3281
+ // Tab colour, pin and the image watcher are user-set and persisted like the settings
3282
+ // above, but this path never read them back: after a restart every surviving pane came
3283
+ // back uncoloured and unpinned with its image watcher off, and the next persist
3284
+ // overwrote the saved values. `reapplyPersistedSessionState()` (the reboot-restore
3285
+ // path) already restores all three. The watcher flag has to be set before
3286
+ // `setupSessionListeners()` below, which reads it to decide whether to start one.
3287
+ if (savedState.color)
3288
+ session.setColor(savedState.color);
3289
+ if (savedState.pinned)
3290
+ session.restorePin(true, savedState.pinnedAt);
3291
+ if (savedState.imageWatcherEnabled !== undefined) {
3292
+ session.imageWatcherEnabled = savedState.imageWatcherEnabled;
3293
+ }
3241
3294
  // Respawn controller (not supported for external-CLI sessions)
3242
3295
  if (!isExternalCliMode(session.mode) && savedState.respawnEnabled && savedState.respawnConfig) {
3243
3296
  try {