@namzu/cli 39.2.1 → 41.0.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 (457) hide show
  1. package/CHANGELOG.md +128 -0
  2. package/dist/bin.js +1 -1
  3. package/dist/checkpoints/manifest.d.ts +7 -0
  4. package/dist/checkpoints/manifest.d.ts.map +1 -1
  5. package/dist/checkpoints/rewind-stats.d.ts +31 -0
  6. package/dist/checkpoints/rewind-stats.d.ts.map +1 -0
  7. package/dist/checkpoints/store.d.ts +24 -3
  8. package/dist/checkpoints/store.d.ts.map +1 -1
  9. package/dist/chunks/{acp-VDM66X7T.js → acp-CLFVQCFH.js} +40 -39
  10. package/dist/chunks/acp-CLFVQCFH.js.map +6 -0
  11. package/dist/chunks/{activity-command-23DPNYXT.js → activity-command-XULXEUGH.js} +13 -12
  12. package/dist/chunks/activity-command-XULXEUGH.js.map +6 -0
  13. package/dist/chunks/{add-Y2UMHBTC.js → add-BALM5DGZ.js} +19 -17
  14. package/dist/chunks/add-BALM5DGZ.js.map +6 -0
  15. package/dist/chunks/{agent-LCCOMK5H.js → agent-CLYE4KWV.js} +33 -30
  16. package/dist/chunks/agent-session-2MVAYKJC.js +54 -0
  17. package/dist/chunks/{archive-YUZ62G7R.js → archive-FWXFWMZJ.js} +11 -10
  18. package/dist/chunks/archive-FWXFWMZJ.js.map +6 -0
  19. package/dist/chunks/{bin-main-LFPYUV3K.js → bin-main-HO4CMSMY.js} +5 -4
  20. package/dist/chunks/bin-main-HO4CMSMY.js.map +6 -0
  21. package/dist/chunks/{browser-X6UIDIQQ.js → browser-Z46YPGWH.js} +6 -6
  22. package/dist/chunks/{chat-EMEYQKRR.js → chat-NOXE5RTE.js} +14 -14
  23. package/dist/chunks/{chunk-MCXVRO4B.js → chunk-37S7MY2T.js} +66 -14
  24. package/dist/chunks/chunk-37S7MY2T.js.map +6 -0
  25. package/dist/chunks/{chunk-2PH7EQQP.js → chunk-3WAQN6DX.js} +2 -2
  26. package/dist/chunks/{chunk-HWM73622.js → chunk-4GJSW2KC.js} +12 -12
  27. package/dist/chunks/{chunk-DNHHMNVG.js → chunk-4JQUY3DT.js} +2 -2
  28. package/dist/chunks/{chunk-OVG3QY7U.js → chunk-5OVI35QS.js} +3 -3
  29. package/dist/chunks/{chunk-YZOR7643.js → chunk-65CAAE7I.js} +157 -4
  30. package/dist/chunks/chunk-65CAAE7I.js.map +6 -0
  31. package/dist/chunks/chunk-6CCX6DPQ.js +440 -0
  32. package/dist/chunks/chunk-6CCX6DPQ.js.map +6 -0
  33. package/dist/chunks/{chunk-FXMJ5NVM.js → chunk-6RNVFKSZ.js} +5 -5
  34. package/dist/chunks/{chunk-TACSPIUK.js → chunk-AGN45S6D.js} +2 -2
  35. package/dist/chunks/{chunk-AP4B5Z3D.js → chunk-AOHJCFG3.js} +2 -2
  36. package/dist/chunks/{chunk-7WUSJ454.js → chunk-AUZB4LKS.js} +4 -4
  37. package/dist/chunks/{chunk-BPDKRVGW.js → chunk-AX4Z3H7N.js} +2 -2
  38. package/dist/chunks/{chunk-7C6DG66T.js → chunk-B2RMIYPZ.js} +4 -4
  39. package/dist/chunks/{chunk-PV4ZAFVQ.js → chunk-B6BQ5ULO.js} +2 -2
  40. package/dist/chunks/{chunk-XJT5DL3I.js → chunk-BPRT5LV7.js} +2 -2
  41. package/dist/chunks/{chunk-A34Y6ZPM.js → chunk-CBL2FUHG.js} +2 -2
  42. package/dist/chunks/{chunk-N3JNFZOW.js → chunk-DMPPM3IA.js} +3 -3
  43. package/dist/chunks/{chunk-EXVGLN6V.js → chunk-EL6GXINV.js} +2 -2
  44. package/dist/chunks/{chunk-KONYGNG6.js → chunk-EUBCYTOK.js} +3 -152
  45. package/dist/chunks/chunk-EUBCYTOK.js.map +6 -0
  46. package/dist/chunks/{chunk-ONKQPPSY.js → chunk-FLYE25VX.js} +2 -2
  47. package/dist/chunks/{chunk-45GT626R.js → chunk-G4LCCGQR.js} +3 -3
  48. package/dist/chunks/{chunk-7OXYUJSY.js → chunk-HE7K6IZ2.js} +29 -29
  49. package/dist/chunks/{chunk-E6LQB5Z7.js → chunk-IR3AZZFJ.js} +60 -22
  50. package/dist/chunks/chunk-IR3AZZFJ.js.map +6 -0
  51. package/dist/chunks/{chunk-EEDZOGV4.js → chunk-IYUW2RAA.js} +27 -2
  52. package/dist/chunks/chunk-IYUW2RAA.js.map +6 -0
  53. package/dist/chunks/{chunk-3MT5KLBF.js → chunk-JSGZ4V7Y.js} +2 -2
  54. package/dist/chunks/{chunk-OPIC6ZIL.js → chunk-K5OXOYM5.js} +14090 -12711
  55. package/dist/chunks/chunk-K5OXOYM5.js.map +6 -0
  56. package/dist/chunks/{chunk-5NVONQBW.js → chunk-KD4Q2INM.js} +3 -3
  57. package/dist/chunks/{chunk-M3TJHQF7.js → chunk-LFI6O7WL.js} +5 -5
  58. package/dist/chunks/{chunk-T64F5OER.js → chunk-M5RW7JBV.js} +9 -9
  59. package/dist/chunks/{chunk-JII5GOH2.js → chunk-MDG3THRR.js} +2 -2
  60. package/dist/chunks/{chunk-IVZB7YKX.js → chunk-MNDFPZVQ.js} +3 -3
  61. package/dist/chunks/{chunk-2L3JDLC5.js → chunk-MZI4TLFB.js} +12 -12
  62. package/dist/chunks/{chunk-EGP3MB37.js → chunk-NQGMYAXK.js} +11 -5
  63. package/dist/chunks/chunk-NQGMYAXK.js.map +6 -0
  64. package/dist/chunks/{chunk-IYPP6HSK.js → chunk-O2B3B2TM.js} +1 -6
  65. package/dist/chunks/chunk-O2B3B2TM.js.map +6 -0
  66. package/dist/chunks/{chunk-YIFOFVWM.js → chunk-O6FOUL5S.js} +4 -4
  67. package/dist/chunks/{chunk-B2GM4GON.js → chunk-O6JILDEY.js} +6 -6
  68. package/dist/chunks/{chunk-OT5X76XI.js → chunk-OUQEMJ26.js} +3 -3
  69. package/dist/chunks/{chunk-QR5YS5QW.js → chunk-P3JHLZH4.js} +2 -2
  70. package/dist/chunks/{chunk-HLIXL5RK.js → chunk-PDZZ64IH.js} +7 -7
  71. package/dist/chunks/{chunk-WNVYEZUQ.js → chunk-PKLBJMCY.js} +4 -4
  72. package/dist/chunks/{chunk-KS5X3GMX.js → chunk-PPZKCA6K.js} +3 -3
  73. package/dist/chunks/{chunk-363DTX3M.js → chunk-PSZ44BRO.js} +4 -4
  74. package/dist/chunks/{chunk-M2PQMMDW.js → chunk-PTJI2QA4.js} +3 -3
  75. package/dist/chunks/{chunk-XNQI4ZDH.js → chunk-QSDPQR3F.js} +3 -3
  76. package/dist/chunks/{chunk-FKSIOYXA.js → chunk-QY77MJS4.js} +4 -4
  77. package/dist/chunks/{chunk-ISN4VZCX.js → chunk-RWOPUQNS.js} +2 -2
  78. package/dist/chunks/{chunk-A25FQQTW.js → chunk-SE5UKEXD.js} +2 -2
  79. package/dist/chunks/{chunk-BZIUFNYR.js → chunk-SEYEOYMT.js} +4 -4
  80. package/dist/chunks/{chunk-HBTPB6ON.js → chunk-SMR6TQN2.js} +2 -2
  81. package/dist/chunks/{chunk-MEHYOYTW.js → chunk-SPZWLMZY.js} +3 -3
  82. package/dist/chunks/{chunk-AXCOWIIH.js → chunk-U5UV2YRE.js} +2 -139
  83. package/dist/chunks/chunk-U5UV2YRE.js.map +6 -0
  84. package/dist/chunks/{chunk-QENCNE7Q.js → chunk-V2NG7LLL.js} +10 -10
  85. package/dist/chunks/{chunk-QENCNE7Q.js.map → chunk-V2NG7LLL.js.map} +1 -1
  86. package/dist/chunks/{chunk-B4DC7NC7.js → chunk-V2ZSQXYQ.js} +8 -8
  87. package/dist/chunks/{chunk-V6UEMLTT.js → chunk-V4PHIKLW.js} +2 -2
  88. package/dist/chunks/chunk-VUZYMKPD.js +3604 -0
  89. package/dist/chunks/chunk-VUZYMKPD.js.map +6 -0
  90. package/dist/chunks/{chunk-LS7PT6RY.js → chunk-WLAVNIFG.js} +10 -4
  91. package/dist/chunks/{chunk-LS7PT6RY.js.map → chunk-WLAVNIFG.js.map} +1 -1
  92. package/dist/chunks/{chunk-HHOTJDZW.js → chunk-WQRBEQ2P.js} +2 -2
  93. package/dist/chunks/{chunk-ESMVELWA.js → chunk-WV7XGYNQ.js} +5 -5
  94. package/dist/chunks/{chunk-JEHKZEIB.js → chunk-WZPN6PWE.js} +4 -4
  95. package/dist/chunks/chunk-XPS3W7FC.js +147 -0
  96. package/dist/chunks/chunk-XPS3W7FC.js.map +6 -0
  97. package/dist/chunks/{chunk-W6JEZMOJ.js → chunk-XRX3DHEW.js} +4 -4
  98. package/dist/chunks/chunk-XSCT3DLE.js +161 -0
  99. package/dist/chunks/chunk-XSCT3DLE.js.map +6 -0
  100. package/dist/chunks/{chunk-NUJCTZOM.js → chunk-XWLQH2NW.js} +7 -7
  101. package/dist/chunks/{chunk-MIM4YRP2.js → chunk-YGV3VBYL.js} +2 -2
  102. package/dist/chunks/{chunk-37YQDLHZ.js → chunk-YXZBHG5N.js} +5495 -4531
  103. package/dist/chunks/chunk-YXZBHG5N.js.map +6 -0
  104. package/dist/chunks/{cli-runtime-XHGO7QSK.js → cli-runtime-5H7CTXF2.js} +16 -14
  105. package/dist/chunks/cli-runtime-5H7CTXF2.js.map +6 -0
  106. package/dist/chunks/{commands-GDF5OOXO.js → commands-XC67PG6L.js} +5 -5
  107. package/dist/chunks/{crash-report-N7ZQ2UB4.js → crash-report-UE423ET4.js} +9 -8
  108. package/dist/chunks/{dist-TCILCQPG.js → dist-4ACX6FL7.js} +2 -2
  109. package/dist/chunks/{dist-IJ3AAED4.js → dist-DCOPEJDN.js} +2 -2
  110. package/dist/chunks/{dist-MZNKQTW4.js → dist-DSK2VZQB.js} +2 -2
  111. package/dist/chunks/{dist-547VSBMV.js → dist-OXUHOXCU.js} +2 -2
  112. package/dist/chunks/{dist-TCIDRGW5.js → dist-SN7QXPO2.js} +2 -2
  113. package/dist/chunks/{dist-T2NJ6SVO.js → dist-SY7OYS74.js} +44 -16
  114. package/dist/chunks/dist-SY7OYS74.js.map +6 -0
  115. package/dist/chunks/{dist-36LBIFJ6.js → dist-YZRXSX7C.js} +2 -2
  116. package/dist/chunks/{doctor-T7SC3VSE.js → doctor-VCCIYKNL.js} +8 -8
  117. package/dist/chunks/{drain-OA5MO7SQ.js → drain-QKEXEMCO.js} +10 -10
  118. package/dist/chunks/{eval-D5Q2WZ7S.js → eval-K47YMZVT.js} +2 -2
  119. package/dist/chunks/{exec-MG5S7OJN.js → exec-K3LRQU6R.js} +33 -28
  120. package/dist/chunks/exec-K3LRQU6R.js.map +6 -0
  121. package/dist/chunks/{home-Z7L4BJTW.js → home-OSHELFKX.js} +3 -3
  122. package/dist/chunks/{host-queries-LL56A6NY.js → host-queries-TV3XH3YV.js} +14 -14
  123. package/dist/chunks/{lifecycle-TCRLU6B5.js → lifecycle-R3QWZ664.js} +28 -26
  124. package/dist/chunks/{list-RBOLXDHG.js → list-L5QFDBPX.js} +16 -14
  125. package/dist/chunks/list-L5QFDBPX.js.map +6 -0
  126. package/dist/chunks/{login-RZCJNDAJ.js → login-N4EO2F45.js} +8 -8
  127. package/dist/chunks/{logs-KDEGF3FA.js → logs-264INNUN.js} +4 -4
  128. package/dist/chunks/{mcp-7L7NYLKG.js → mcp-7H3G3KLD.js} +21 -19
  129. package/dist/chunks/mcp-7H3G3KLD.js.map +6 -0
  130. package/dist/chunks/{message-command-NTLYNKUW.js → message-command-JOQ24TAL.js} +37 -36
  131. package/dist/chunks/message-command-JOQ24TAL.js.map +6 -0
  132. package/dist/chunks/{operator-tools-DXU6UK4S.js → operator-tools-O2MDVMJP.js} +12 -12
  133. package/dist/chunks/{output-schema-UMOAOTW2.js → output-schema-LKM35JS4.js} +3 -3
  134. package/dist/chunks/{pal-FDOF3S5J.js → pal-N56IUOUP.js} +13 -12
  135. package/dist/chunks/pal-N56IUOUP.js.map +6 -0
  136. package/dist/chunks/{providers-HOY5QHWL.js → providers-B352G4OM.js} +6 -6
  137. package/dist/chunks/{resident-XIM5KNNX.js → resident-SMWDKMJP.js} +24 -22
  138. package/dist/chunks/resident-SMWDKMJP.js.map +6 -0
  139. package/dist/chunks/resume-EXHKGQII.js +22 -0
  140. package/dist/chunks/{resume-command-DIVGMVMA.js → resume-command-OHQBIY5P.js} +6 -5
  141. package/dist/chunks/{schedule-YRHGK6CD.js → schedule-VHP2VGEF.js} +8 -8
  142. package/dist/chunks/{service-DRXVEYFA.js → service-RHWPRJJO.js} +27 -25
  143. package/dist/chunks/service-RHWPRJJO.js.map +6 -0
  144. package/dist/chunks/session-step-NJRR3Q2L.js +30 -0
  145. package/dist/chunks/{skills-C5ZXOJEA.js → skills-JS3FQPHU.js} +10 -9
  146. package/dist/chunks/skills-JS3FQPHU.js.map +6 -0
  147. package/dist/chunks/{state-BVKWZF6F.js → state-A56X2FGB.js} +4 -3
  148. package/dist/chunks/state-A56X2FGB.js.map +6 -0
  149. package/dist/chunks/{store-ZXFXXY4S.js → store-IMV6NZTT.js} +9 -9
  150. package/dist/chunks/{store-GKY55UEV.js → store-SEPPZ7H6.js} +4 -4
  151. package/dist/chunks/{store-A4VHV4I2.js → store-WJEK5ZI2.js} +6 -6
  152. package/dist/chunks/{tui-PY2FQXVO.js → tui-BP7MYQG2.js} +14415 -12525
  153. package/dist/chunks/tui-BP7MYQG2.js.map +6 -0
  154. package/dist/chunks/{upgrade-WSBGA3FW.js → upgrade-2A7CIVAY.js} +3 -4
  155. package/dist/chunks/upgrade-2A7CIVAY.js.map +6 -0
  156. package/dist/chunks/{worktree-HLE7PBLL.js → worktree-ERUU4NVZ.js} +13 -12
  157. package/dist/chunks/worktree-ERUU4NVZ.js.map +6 -0
  158. package/dist/config/load.d.ts +6 -1
  159. package/dist/config/load.d.ts.map +1 -1
  160. package/dist/config/schema.d.ts +45 -0
  161. package/dist/config/schema.d.ts.map +1 -1
  162. package/dist/config/user-config.d.ts.map +1 -1
  163. package/dist/context/doctrine.d.ts +2 -1
  164. package/dist/context/doctrine.d.ts.map +1 -1
  165. package/dist/context/environment.d.ts +37 -1
  166. package/dist/context/environment.d.ts.map +1 -1
  167. package/dist/context/identity.d.ts +27 -0
  168. package/dist/context/identity.d.ts.map +1 -0
  169. package/dist/context/project-tracker.d.ts.map +1 -1
  170. package/dist/context/system-prompt.d.ts +99 -0
  171. package/dist/context/system-prompt.d.ts.map +1 -0
  172. package/dist/index.js +16 -14
  173. package/dist/integrations/compaction/idle-compaction.d.ts +84 -0
  174. package/dist/integrations/compaction/idle-compaction.d.ts.map +1 -0
  175. package/dist/integrations/providers/prompt-cache-ttl.d.ts +14 -0
  176. package/dist/integrations/providers/prompt-cache-ttl.d.ts.map +1 -0
  177. package/dist/integrations/resident/runner-worker.js +20 -19
  178. package/dist/integrations/resident/runner-worker.js.map +1 -1
  179. package/dist/integrations/sessions/conversation-search.d.ts +1 -1
  180. package/dist/integrations/sessions/conversation-search.d.ts.map +1 -1
  181. package/dist/integrations/sessions/recap.d.ts +56 -0
  182. package/dist/integrations/sessions/recap.d.ts.map +1 -0
  183. package/dist/integrations/sessions/store.d.ts +7 -1
  184. package/dist/integrations/sessions/store.d.ts.map +1 -1
  185. package/dist/integrations/subagents/runtime.d.ts +2 -0
  186. package/dist/integrations/subagents/runtime.d.ts.map +1 -1
  187. package/dist/integrations/workflows/doctrine.d.ts.map +1 -1
  188. package/dist/integrations/workflows/host.d.ts +0 -5
  189. package/dist/integrations/workflows/host.d.ts.map +1 -1
  190. package/dist/integrations/workflows/offering.d.ts +0 -2
  191. package/dist/integrations/workflows/offering.d.ts.map +1 -1
  192. package/dist/integrations/workflows/size.d.ts +9 -1
  193. package/dist/integrations/workflows/size.d.ts.map +1 -1
  194. package/dist/memory/typed.d.ts +11 -0
  195. package/dist/memory/typed.d.ts.map +1 -1
  196. package/dist/permissions/session-allow.d.ts +10 -0
  197. package/dist/permissions/session-allow.d.ts.map +1 -1
  198. package/dist/reminders/environment.d.ts +20 -0
  199. package/dist/reminders/environment.d.ts.map +1 -0
  200. package/dist/reminders/frame.d.ts +1 -1
  201. package/dist/reminders/frame.d.ts.map +1 -1
  202. package/dist/reminders/index.d.ts +11 -1
  203. package/dist/reminders/index.d.ts.map +1 -1
  204. package/dist/reminders/mode.d.ts +11 -0
  205. package/dist/reminders/mode.d.ts.map +1 -0
  206. package/dist/tui/App.d.ts +17 -1
  207. package/dist/tui/App.d.ts.map +1 -1
  208. package/dist/tui/BrandHeader.d.ts.map +1 -1
  209. package/dist/tui/Checklist.d.ts +2 -0
  210. package/dist/tui/Checklist.d.ts.map +1 -1
  211. package/dist/tui/ChoicePicker.d.ts +4 -1
  212. package/dist/tui/ChoicePicker.d.ts.map +1 -1
  213. package/dist/tui/Composer.d.ts +15 -3
  214. package/dist/tui/Composer.d.ts.map +1 -1
  215. package/dist/tui/ComposerFrame.d.ts.map +1 -1
  216. package/dist/tui/ContextGridRow.d.ts +6 -0
  217. package/dist/tui/ContextGridRow.d.ts.map +1 -0
  218. package/dist/tui/LiveActivity.d.ts +11 -1
  219. package/dist/tui/LiveActivity.d.ts.map +1 -1
  220. package/dist/tui/Markdown.d.ts.map +1 -1
  221. package/dist/tui/PermissionOverlay.d.ts +25 -4
  222. package/dist/tui/PermissionOverlay.d.ts.map +1 -1
  223. package/dist/tui/ReadSearchGroup.d.ts +14 -0
  224. package/dist/tui/ReadSearchGroup.d.ts.map +1 -0
  225. package/dist/tui/RewindPicker.d.ts +14 -0
  226. package/dist/tui/RewindPicker.d.ts.map +1 -0
  227. package/dist/tui/StatusBar.d.ts +31 -12
  228. package/dist/tui/StatusBar.d.ts.map +1 -1
  229. package/dist/tui/ThemeSample.d.ts +5 -0
  230. package/dist/tui/ThemeSample.d.ts.map +1 -0
  231. package/dist/tui/Transcript.d.ts +13 -0
  232. package/dist/tui/Transcript.d.ts.map +1 -1
  233. package/dist/tui/TranscriptScreen.d.ts +24 -0
  234. package/dist/tui/TranscriptScreen.d.ts.map +1 -0
  235. package/dist/tui/agent-transcript-rows.d.ts.map +1 -1
  236. package/dist/tui/agent-view-commands.d.ts.map +1 -1
  237. package/dist/tui/agent.d.ts +84 -3
  238. package/dist/tui/agent.d.ts.map +1 -1
  239. package/dist/tui/away-recap.d.ts +73 -0
  240. package/dist/tui/away-recap.d.ts.map +1 -0
  241. package/dist/tui/connector-label.d.ts +19 -0
  242. package/dist/tui/connector-label.d.ts.map +1 -0
  243. package/dist/tui/context-grid.d.ts +121 -0
  244. package/dist/tui/context-grid.d.ts.map +1 -0
  245. package/dist/tui/context-meter.d.ts +9 -0
  246. package/dist/tui/context-meter.d.ts.map +1 -1
  247. package/dist/tui/context-usage.d.ts +70 -0
  248. package/dist/tui/context-usage.d.ts.map +1 -0
  249. package/dist/tui/diff-view.d.ts +1 -1
  250. package/dist/tui/edit-prompts.d.ts.map +1 -1
  251. package/dist/tui/focus-reporting.d.ts +45 -0
  252. package/dist/tui/focus-reporting.d.ts.map +1 -0
  253. package/dist/tui/group-rows.d.ts +10 -0
  254. package/dist/tui/group-rows.d.ts.map +1 -0
  255. package/dist/tui/index.d.ts.map +1 -1
  256. package/dist/tui/live-window.d.ts +5 -8
  257. package/dist/tui/live-window.d.ts.map +1 -1
  258. package/dist/tui/logo.d.ts +0 -1
  259. package/dist/tui/logo.d.ts.map +1 -1
  260. package/dist/tui/motion.d.ts +14 -0
  261. package/dist/tui/motion.d.ts.map +1 -0
  262. package/dist/tui/next-task.d.ts +11 -0
  263. package/dist/tui/next-task.d.ts.map +1 -0
  264. package/dist/tui/notifications.d.ts +69 -0
  265. package/dist/tui/notifications.d.ts.map +1 -0
  266. package/dist/tui/per-call-review.d.ts +50 -0
  267. package/dist/tui/per-call-review.d.ts.map +1 -0
  268. package/dist/tui/permission-asks.d.ts +68 -0
  269. package/dist/tui/permission-asks.d.ts.map +1 -0
  270. package/dist/tui/plain-interruption.d.ts +1 -1
  271. package/dist/tui/plain-interruption.d.ts.map +1 -1
  272. package/dist/tui/queued-calls.d.ts +47 -0
  273. package/dist/tui/queued-calls.d.ts.map +1 -0
  274. package/dist/tui/read-search-group.d.ts +97 -0
  275. package/dist/tui/read-search-group.d.ts.map +1 -0
  276. package/dist/tui/recap-setting.d.ts +36 -0
  277. package/dist/tui/recap-setting.d.ts.map +1 -0
  278. package/dist/tui/recap-turns.d.ts +13 -0
  279. package/dist/tui/recap-turns.d.ts.map +1 -0
  280. package/dist/tui/restored-rows.d.ts.map +1 -1
  281. package/dist/tui/rewind.d.ts +142 -0
  282. package/dist/tui/rewind.d.ts.map +1 -0
  283. package/dist/tui/slashCommands.d.ts +45 -0
  284. package/dist/tui/slashCommands.d.ts.map +1 -1
  285. package/dist/tui/spinner-tips-setting.d.ts +10 -0
  286. package/dist/tui/spinner-tips-setting.d.ts.map +1 -0
  287. package/dist/tui/spinner-tips.d.ts +39 -0
  288. package/dist/tui/spinner-tips.d.ts.map +1 -0
  289. package/dist/tui/stale-history-retry.d.ts +17 -0
  290. package/dist/tui/stale-history-retry.d.ts.map +1 -0
  291. package/dist/tui/system-rows.d.ts +4 -0
  292. package/dist/tui/system-rows.d.ts.map +1 -1
  293. package/dist/tui/terminal-display.d.ts +7 -0
  294. package/dist/tui/terminal-display.d.ts.map +1 -1
  295. package/dist/tui/terminal-focus.d.ts +29 -0
  296. package/dist/tui/terminal-focus.d.ts.map +1 -0
  297. package/dist/tui/terminal-title.d.ts +19 -0
  298. package/dist/tui/terminal-title.d.ts.map +1 -1
  299. package/dist/tui/theme-command.d.ts +20 -0
  300. package/dist/tui/theme-command.d.ts.map +1 -0
  301. package/dist/tui/theme-detect.d.ts +41 -0
  302. package/dist/tui/theme-detect.d.ts.map +1 -0
  303. package/dist/tui/theme-launch.d.ts +16 -0
  304. package/dist/tui/theme-launch.d.ts.map +1 -0
  305. package/dist/tui/theme-palettes.d.ts +121 -0
  306. package/dist/tui/theme-palettes.d.ts.map +1 -0
  307. package/dist/tui/theme-store.d.ts +35 -0
  308. package/dist/tui/theme-store.d.ts.map +1 -0
  309. package/dist/tui/theme.d.ts +35 -64
  310. package/dist/tui/theme.d.ts.map +1 -1
  311. package/dist/tui/tidy-tool-output.d.ts +22 -0
  312. package/dist/tui/tidy-tool-output.d.ts.map +1 -1
  313. package/dist/tui/tip-history.d.ts +25 -0
  314. package/dist/tui/tip-history.d.ts.map +1 -0
  315. package/dist/tui/title-frame.d.ts +7 -0
  316. package/dist/tui/title-frame.d.ts.map +1 -0
  317. package/dist/tui/tool-end-rows.d.ts +4 -1
  318. package/dist/tui/tool-end-rows.d.ts.map +1 -1
  319. package/dist/tui/tool-failure-text.d.ts.map +1 -1
  320. package/dist/tui/transcript-screen.d.ts +31 -0
  321. package/dist/tui/transcript-screen.d.ts.map +1 -0
  322. package/dist/tui/transcript-scroll.d.ts.map +1 -1
  323. package/dist/tui/types.d.ts +26 -1
  324. package/dist/tui/types.d.ts.map +1 -1
  325. package/dist/tui/update-notice.d.ts +12 -0
  326. package/dist/tui/update-notice.d.ts.map +1 -0
  327. package/dist/tui/use-idle-compaction.d.ts +29 -0
  328. package/dist/tui/use-idle-compaction.d.ts.map +1 -0
  329. package/dist/tui/use-spinner-tip.d.ts +23 -0
  330. package/dist/tui/use-spinner-tip.d.ts.map +1 -0
  331. package/dist/tui/useNotifications.d.ts +14 -0
  332. package/dist/tui/useNotifications.d.ts.map +1 -0
  333. package/dist/tui/useReadSearchGroup.d.ts +21 -0
  334. package/dist/tui/useReadSearchGroup.d.ts.map +1 -0
  335. package/package.json +7 -7
  336. package/skills/schedule-task/SKILL.md +6 -34
  337. package/dist/chunks/acp-VDM66X7T.js.map +0 -6
  338. package/dist/chunks/activity-command-23DPNYXT.js.map +0 -6
  339. package/dist/chunks/add-Y2UMHBTC.js.map +0 -6
  340. package/dist/chunks/agent-session-6ZFR55NO.js +0 -53
  341. package/dist/chunks/archive-YUZ62G7R.js.map +0 -6
  342. package/dist/chunks/bin-main-LFPYUV3K.js.map +0 -6
  343. package/dist/chunks/chunk-37YQDLHZ.js.map +0 -6
  344. package/dist/chunks/chunk-6YFMOYKD.js +0 -1796
  345. package/dist/chunks/chunk-6YFMOYKD.js.map +0 -6
  346. package/dist/chunks/chunk-AURV7PCK.js +0 -111
  347. package/dist/chunks/chunk-AURV7PCK.js.map +0 -6
  348. package/dist/chunks/chunk-AXCOWIIH.js.map +0 -6
  349. package/dist/chunks/chunk-CDYUGK7F.js +0 -70
  350. package/dist/chunks/chunk-CDYUGK7F.js.map +0 -6
  351. package/dist/chunks/chunk-E6LQB5Z7.js.map +0 -6
  352. package/dist/chunks/chunk-EEDZOGV4.js.map +0 -6
  353. package/dist/chunks/chunk-EGP3MB37.js.map +0 -6
  354. package/dist/chunks/chunk-IYPP6HSK.js.map +0 -6
  355. package/dist/chunks/chunk-KONYGNG6.js.map +0 -6
  356. package/dist/chunks/chunk-MCXVRO4B.js.map +0 -6
  357. package/dist/chunks/chunk-OPIC6ZIL.js.map +0 -6
  358. package/dist/chunks/chunk-YZOR7643.js.map +0 -6
  359. package/dist/chunks/cli-runtime-XHGO7QSK.js.map +0 -6
  360. package/dist/chunks/dist-T2NJ6SVO.js.map +0 -6
  361. package/dist/chunks/exec-MG5S7OJN.js.map +0 -6
  362. package/dist/chunks/list-RBOLXDHG.js.map +0 -6
  363. package/dist/chunks/mcp-7L7NYLKG.js.map +0 -6
  364. package/dist/chunks/message-command-NTLYNKUW.js.map +0 -6
  365. package/dist/chunks/pal-FDOF3S5J.js.map +0 -6
  366. package/dist/chunks/resident-XIM5KNNX.js.map +0 -6
  367. package/dist/chunks/resume-3OP5GB7S.js +0 -22
  368. package/dist/chunks/service-DRXVEYFA.js.map +0 -6
  369. package/dist/chunks/session-step-ZD3D55SM.js +0 -29
  370. package/dist/chunks/skills-C5ZXOJEA.js.map +0 -6
  371. package/dist/chunks/state-BVKWZF6F.js.map +0 -6
  372. package/dist/chunks/tui-PY2FQXVO.js.map +0 -6
  373. package/dist/chunks/upgrade-WSBGA3FW.js.map +0 -6
  374. package/dist/chunks/worktree-HLE7PBLL.js.map +0 -6
  375. package/dist/tui/EditPromptPicker.d.ts +0 -8
  376. package/dist/tui/EditPromptPicker.d.ts.map +0 -1
  377. package/dist/tui/ToolOutputViewer.d.ts +0 -11
  378. package/dist/tui/ToolOutputViewer.d.ts.map +0 -1
  379. /package/dist/chunks/{agent-LCCOMK5H.js.map → agent-CLYE4KWV.js.map} +0 -0
  380. /package/dist/chunks/{agent-session-6ZFR55NO.js.map → agent-session-2MVAYKJC.js.map} +0 -0
  381. /package/dist/chunks/{browser-X6UIDIQQ.js.map → browser-Z46YPGWH.js.map} +0 -0
  382. /package/dist/chunks/{chat-EMEYQKRR.js.map → chat-NOXE5RTE.js.map} +0 -0
  383. /package/dist/chunks/{chunk-2PH7EQQP.js.map → chunk-3WAQN6DX.js.map} +0 -0
  384. /package/dist/chunks/{chunk-HWM73622.js.map → chunk-4GJSW2KC.js.map} +0 -0
  385. /package/dist/chunks/{chunk-DNHHMNVG.js.map → chunk-4JQUY3DT.js.map} +0 -0
  386. /package/dist/chunks/{chunk-OVG3QY7U.js.map → chunk-5OVI35QS.js.map} +0 -0
  387. /package/dist/chunks/{chunk-FXMJ5NVM.js.map → chunk-6RNVFKSZ.js.map} +0 -0
  388. /package/dist/chunks/{chunk-TACSPIUK.js.map → chunk-AGN45S6D.js.map} +0 -0
  389. /package/dist/chunks/{chunk-AP4B5Z3D.js.map → chunk-AOHJCFG3.js.map} +0 -0
  390. /package/dist/chunks/{chunk-7WUSJ454.js.map → chunk-AUZB4LKS.js.map} +0 -0
  391. /package/dist/chunks/{chunk-BPDKRVGW.js.map → chunk-AX4Z3H7N.js.map} +0 -0
  392. /package/dist/chunks/{chunk-7C6DG66T.js.map → chunk-B2RMIYPZ.js.map} +0 -0
  393. /package/dist/chunks/{chunk-PV4ZAFVQ.js.map → chunk-B6BQ5ULO.js.map} +0 -0
  394. /package/dist/chunks/{chunk-XJT5DL3I.js.map → chunk-BPRT5LV7.js.map} +0 -0
  395. /package/dist/chunks/{chunk-A34Y6ZPM.js.map → chunk-CBL2FUHG.js.map} +0 -0
  396. /package/dist/chunks/{chunk-N3JNFZOW.js.map → chunk-DMPPM3IA.js.map} +0 -0
  397. /package/dist/chunks/{chunk-EXVGLN6V.js.map → chunk-EL6GXINV.js.map} +0 -0
  398. /package/dist/chunks/{chunk-ONKQPPSY.js.map → chunk-FLYE25VX.js.map} +0 -0
  399. /package/dist/chunks/{chunk-45GT626R.js.map → chunk-G4LCCGQR.js.map} +0 -0
  400. /package/dist/chunks/{chunk-7OXYUJSY.js.map → chunk-HE7K6IZ2.js.map} +0 -0
  401. /package/dist/chunks/{chunk-3MT5KLBF.js.map → chunk-JSGZ4V7Y.js.map} +0 -0
  402. /package/dist/chunks/{chunk-5NVONQBW.js.map → chunk-KD4Q2INM.js.map} +0 -0
  403. /package/dist/chunks/{chunk-M3TJHQF7.js.map → chunk-LFI6O7WL.js.map} +0 -0
  404. /package/dist/chunks/{chunk-T64F5OER.js.map → chunk-M5RW7JBV.js.map} +0 -0
  405. /package/dist/chunks/{chunk-JII5GOH2.js.map → chunk-MDG3THRR.js.map} +0 -0
  406. /package/dist/chunks/{chunk-IVZB7YKX.js.map → chunk-MNDFPZVQ.js.map} +0 -0
  407. /package/dist/chunks/{chunk-2L3JDLC5.js.map → chunk-MZI4TLFB.js.map} +0 -0
  408. /package/dist/chunks/{chunk-YIFOFVWM.js.map → chunk-O6FOUL5S.js.map} +0 -0
  409. /package/dist/chunks/{chunk-B2GM4GON.js.map → chunk-O6JILDEY.js.map} +0 -0
  410. /package/dist/chunks/{chunk-OT5X76XI.js.map → chunk-OUQEMJ26.js.map} +0 -0
  411. /package/dist/chunks/{chunk-QR5YS5QW.js.map → chunk-P3JHLZH4.js.map} +0 -0
  412. /package/dist/chunks/{chunk-HLIXL5RK.js.map → chunk-PDZZ64IH.js.map} +0 -0
  413. /package/dist/chunks/{chunk-WNVYEZUQ.js.map → chunk-PKLBJMCY.js.map} +0 -0
  414. /package/dist/chunks/{chunk-KS5X3GMX.js.map → chunk-PPZKCA6K.js.map} +0 -0
  415. /package/dist/chunks/{chunk-363DTX3M.js.map → chunk-PSZ44BRO.js.map} +0 -0
  416. /package/dist/chunks/{chunk-M2PQMMDW.js.map → chunk-PTJI2QA4.js.map} +0 -0
  417. /package/dist/chunks/{chunk-XNQI4ZDH.js.map → chunk-QSDPQR3F.js.map} +0 -0
  418. /package/dist/chunks/{chunk-FKSIOYXA.js.map → chunk-QY77MJS4.js.map} +0 -0
  419. /package/dist/chunks/{chunk-ISN4VZCX.js.map → chunk-RWOPUQNS.js.map} +0 -0
  420. /package/dist/chunks/{chunk-A25FQQTW.js.map → chunk-SE5UKEXD.js.map} +0 -0
  421. /package/dist/chunks/{chunk-BZIUFNYR.js.map → chunk-SEYEOYMT.js.map} +0 -0
  422. /package/dist/chunks/{chunk-HBTPB6ON.js.map → chunk-SMR6TQN2.js.map} +0 -0
  423. /package/dist/chunks/{chunk-MEHYOYTW.js.map → chunk-SPZWLMZY.js.map} +0 -0
  424. /package/dist/chunks/{chunk-B4DC7NC7.js.map → chunk-V2ZSQXYQ.js.map} +0 -0
  425. /package/dist/chunks/{chunk-V6UEMLTT.js.map → chunk-V4PHIKLW.js.map} +0 -0
  426. /package/dist/chunks/{chunk-HHOTJDZW.js.map → chunk-WQRBEQ2P.js.map} +0 -0
  427. /package/dist/chunks/{chunk-ESMVELWA.js.map → chunk-WV7XGYNQ.js.map} +0 -0
  428. /package/dist/chunks/{chunk-JEHKZEIB.js.map → chunk-WZPN6PWE.js.map} +0 -0
  429. /package/dist/chunks/{chunk-W6JEZMOJ.js.map → chunk-XRX3DHEW.js.map} +0 -0
  430. /package/dist/chunks/{chunk-NUJCTZOM.js.map → chunk-XWLQH2NW.js.map} +0 -0
  431. /package/dist/chunks/{chunk-MIM4YRP2.js.map → chunk-YGV3VBYL.js.map} +0 -0
  432. /package/dist/chunks/{commands-GDF5OOXO.js.map → commands-XC67PG6L.js.map} +0 -0
  433. /package/dist/chunks/{crash-report-N7ZQ2UB4.js.map → crash-report-UE423ET4.js.map} +0 -0
  434. /package/dist/chunks/{dist-TCILCQPG.js.map → dist-4ACX6FL7.js.map} +0 -0
  435. /package/dist/chunks/{dist-IJ3AAED4.js.map → dist-DCOPEJDN.js.map} +0 -0
  436. /package/dist/chunks/{dist-MZNKQTW4.js.map → dist-DSK2VZQB.js.map} +0 -0
  437. /package/dist/chunks/{dist-547VSBMV.js.map → dist-OXUHOXCU.js.map} +0 -0
  438. /package/dist/chunks/{dist-TCIDRGW5.js.map → dist-SN7QXPO2.js.map} +0 -0
  439. /package/dist/chunks/{dist-36LBIFJ6.js.map → dist-YZRXSX7C.js.map} +0 -0
  440. /package/dist/chunks/{doctor-T7SC3VSE.js.map → doctor-VCCIYKNL.js.map} +0 -0
  441. /package/dist/chunks/{drain-OA5MO7SQ.js.map → drain-QKEXEMCO.js.map} +0 -0
  442. /package/dist/chunks/{eval-D5Q2WZ7S.js.map → eval-K47YMZVT.js.map} +0 -0
  443. /package/dist/chunks/{home-Z7L4BJTW.js.map → home-OSHELFKX.js.map} +0 -0
  444. /package/dist/chunks/{host-queries-LL56A6NY.js.map → host-queries-TV3XH3YV.js.map} +0 -0
  445. /package/dist/chunks/{lifecycle-TCRLU6B5.js.map → lifecycle-R3QWZ664.js.map} +0 -0
  446. /package/dist/chunks/{login-RZCJNDAJ.js.map → login-N4EO2F45.js.map} +0 -0
  447. /package/dist/chunks/{logs-KDEGF3FA.js.map → logs-264INNUN.js.map} +0 -0
  448. /package/dist/chunks/{operator-tools-DXU6UK4S.js.map → operator-tools-O2MDVMJP.js.map} +0 -0
  449. /package/dist/chunks/{output-schema-UMOAOTW2.js.map → output-schema-LKM35JS4.js.map} +0 -0
  450. /package/dist/chunks/{providers-HOY5QHWL.js.map → providers-B352G4OM.js.map} +0 -0
  451. /package/dist/chunks/{resume-3OP5GB7S.js.map → resume-EXHKGQII.js.map} +0 -0
  452. /package/dist/chunks/{resume-command-DIVGMVMA.js.map → resume-command-OHQBIY5P.js.map} +0 -0
  453. /package/dist/chunks/{schedule-YRHGK6CD.js.map → schedule-VHP2VGEF.js.map} +0 -0
  454. /package/dist/chunks/{session-step-ZD3D55SM.js.map → session-step-NJRR3Q2L.js.map} +0 -0
  455. /package/dist/chunks/{store-A4VHV4I2.js.map → store-IMV6NZTT.js.map} +0 -0
  456. /package/dist/chunks/{store-GKY55UEV.js.map → store-SEPPZ7H6.js.map} +0 -0
  457. /package/dist/chunks/{store-ZXFXXY4S.js.map → store-WJEK5ZI2.js.map} +0 -0
@@ -16,6 +16,10 @@ export declare const DEFAULT_TERMINAL_TITLE = "Namzu";
16
16
  export declare const IDLE_TITLE_GLYPH = "\u2733";
17
17
  /** Before the title while a turn runs. */
18
18
  export declare const BUSY_TITLE_GLYPH = "\u25D0";
19
+ /** The two glyphs a running turn alternates between. */
20
+ export declare const BUSY_TITLE_FRAMES: readonly string[];
21
+ /** How long each frame shows while the terminal has focus. */
22
+ export declare const TITLE_ANIMATION_MS = 960;
19
23
  export interface TerminalTitleInput {
20
24
  /** The name a person gave the conversation. */
21
25
  readonly named?: string | undefined;
@@ -23,7 +27,22 @@ export interface TerminalTitleInput {
23
27
  readonly generated?: string | undefined;
24
28
  /** A turn is running. */
25
29
  readonly busy: boolean;
30
+ /** Which busy frame to show; counted up by the animation, any whole number. */
31
+ readonly frame?: number | undefined;
26
32
  }
33
+ /**
34
+ * Whether the busy glyph moves: only while a turn is working (not while it
35
+ * waits on a permission), the terminal has not reported losing focus, and no
36
+ * terminal multiplexer (`TMUX`, `STY`, `ZELLIJ`) would redraw its tab on every
37
+ * change. A stopped animation keeps the frame it stopped on.
38
+ */
39
+ export declare function titleAnimates(input: {
40
+ readonly working: boolean;
41
+ readonly focused: boolean;
42
+ readonly env: Readonly<Record<string, string | undefined>>;
43
+ }): boolean;
44
+ /** A terminal multiplexer is hosting this terminal. */
45
+ export declare function underMultiplexer(env: Readonly<Record<string, string | undefined>>): boolean;
27
46
  /** The title text for the current state: name, else generated title, else the product name. */
28
47
  export declare function terminalTitleText(input: TerminalTitleInput): string;
29
48
  export declare function setTerminalTitleSequence(text: string): string;
@@ -1 +1 @@
1
- {"version":3,"file":"terminal-title.d.ts","sourceRoot":"","sources":["../../src/tui/terminal-title.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,kBAAkB;IAClC,+CAA+C;IAC/C,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IACnC,uCAAuC;IACvC,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IACvC,yBAAyB;IACzB,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAA;IACtB,+EAA+E;IAC/E,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;CACnC;AAED;;;;;GAKG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE;IACpC,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAA;IACzB,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAA;IACzB,QAAQ,CAAC,GAAG,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,CAAC,CAAA;CAC1D,GAAG,OAAO,CAEV;AAED,uDAAuD;AACvD,wBAAgB,gBAAgB,CAAC,GAAG,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,CAAC,GAAG,OAAO,CAE3F;AAED,+FAA+F;AAC/F,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,kBAAkB,GAAG,MAAM,CAUnE;AAED,wBAAgB,wBAAwB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAE7D;AAED,yDAAyD;AACzD,eAAO,MAAM,6BAA6B,oBAAoC,CAAA;AAE9E,wBAAgB,oBAAoB,CACnC,GAAG,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,CAAC,EACjD,KAAK,EAAE,OAAO,GAAG,SAAS,GACxB,OAAO,CAIT"}
@@ -0,0 +1,20 @@
1
+ /**
2
+ * `/theme` and `/config motion`: change the setting for this run and keep it
3
+ * in the user config (`tui.theme`, `tui.reducedMotion`), then say what happened.
4
+ * A project file cannot set either, so the user file is the only place written.
5
+ */
6
+ import { type ThemeSetting } from './theme-palettes.js';
7
+ interface WriteOptions {
8
+ readonly home?: string;
9
+ readonly env?: NodeJS.ProcessEnv;
10
+ }
11
+ /** The word typed after `/theme`, as a setting. */
12
+ export declare function parseThemeArgument(args: readonly string[]): ThemeSetting | undefined;
13
+ export declare const THEME_USAGE: string;
14
+ /** Apply and save a theme. The screen follows even when the file cannot be written. */
15
+ export declare function saveTheme(setting: ThemeSetting, opts?: WriteOptions): string;
16
+ /** Apply and save reduced motion. */
17
+ export declare function saveReducedMotion(on: boolean, opts?: WriteOptions): string;
18
+ export declare function describeReducedMotion(): string;
19
+ export {};
20
+ //# sourceMappingURL=theme-command.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"theme-command.d.ts","sourceRoot":"","sources":["../../src/tui/theme-command.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAKH,OAAO,EAAe,KAAK,YAAY,EAAiC,MAAM,qBAAqB,CAAA;AAGnG,UAAU,YAAY;IACrB,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAA;IACtB,QAAQ,CAAC,GAAG,CAAC,EAAE,MAAM,CAAC,UAAU,CAAA;CAChC;AAED,mDAAmD;AACnD,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,SAAS,MAAM,EAAE,GAAG,YAAY,GAAG,SAAS,CAGpF;AAED,eAAO,MAAM,WAAW,QAAkD,CAAA;AAE1E,uFAAuF;AACvF,wBAAgB,SAAS,CAAC,OAAO,EAAE,YAAY,EAAE,IAAI,GAAE,YAAiB,GAAG,MAAM,CAQhF;AAED,qCAAqC;AACrC,wBAAgB,iBAAiB,CAAC,EAAE,EAAE,OAAO,EAAE,IAAI,GAAE,YAAiB,GAAG,MAAM,CAW9E;AAED,wBAAgB,qBAAqB,IAAI,MAAM,CAI9C"}
@@ -0,0 +1,41 @@
1
+ /**
2
+ * Whether the terminal's background is dark or light, for the `auto` theme.
3
+ *
4
+ * Two sources, in order: what the terminal itself reports (a background-colour
5
+ * query answered on stdin) and the `COLORFGBG` variable some terminals set.
6
+ * Neither answering means dark.
7
+ */
8
+ export type Background = 'dark' | 'light';
9
+ /** The query for the terminal's background colour (OSC 11), ended by BEL. */
10
+ export declare const BACKGROUND_QUERY = "\u001B]11;?\u0007";
11
+ /**
12
+ * `COLORFGBG` is `foreground;background` (some terminals add a middle field):
13
+ * the text after the last `;` is a colour number 0..15, and 0..6 and 8 are dark.
14
+ */
15
+ export declare function backgroundFromColorFgBg(value: string | undefined): Background | undefined;
16
+ /** The reply to the background query: `rgb:RRRR/GGGG/BBBB` (1 to 4 hex digits a channel) or `#rrggbb`. */
17
+ export declare function parseBackgroundReply(reply: string): Background | undefined;
18
+ export interface BackgroundQueryStreams {
19
+ readonly input: {
20
+ on(event: 'data', listener: (chunk: Buffer | string) => void): unknown;
21
+ off(event: 'data', listener: (chunk: Buffer | string) => void): unknown;
22
+ setRawMode?: (mode: boolean) => unknown;
23
+ isTTY?: boolean;
24
+ isRaw?: boolean;
25
+ pause?: () => unknown;
26
+ resume?: () => unknown;
27
+ };
28
+ readonly output: {
29
+ write(text: string): unknown;
30
+ isTTY?: boolean;
31
+ };
32
+ }
33
+ /**
34
+ * Ask the terminal and wait for its answer. `giveUp` resolves when the wait is
35
+ * over (a timer in production); the answer wins whichever comes first. Nothing
36
+ * is left listening afterwards, and raw mode is put back as it was.
37
+ */
38
+ export declare function queryTerminalBackground(streams: BackgroundQueryStreams, giveUp: Promise<void>): Promise<Background | undefined>;
39
+ /** The environment's answer: COLORFGBG, else dark. A live report, when there is one, comes first. */
40
+ export declare function detectBackground(reported: Background | undefined, env?: NodeJS.ProcessEnv): Background;
41
+ //# sourceMappingURL=theme-detect.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"theme-detect.d.ts","sourceRoot":"","sources":["../../src/tui/theme-detect.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,MAAM,MAAM,UAAU,GAAG,MAAM,GAAG,OAAO,CAAA;AAEzC,6EAA6E;AAC7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theme and motion the terminal UI starts with, from the user config.
3
+ * For `auto`, the terminal is asked for its background colour once, before the
4
+ * UI takes over the keyboard; no answer within a moment means the environment's
5
+ * hint, then dark.
6
+ */
7
+ import type { TuiConfig } from '../config/schema.js';
8
+ import { type BackgroundQueryStreams } from './theme-detect.js';
9
+ /** How long the terminal has to answer the background query. */
10
+ export declare const BACKGROUND_QUERY_WAIT_MS = 250;
11
+ /**
12
+ * Returns nothing to wait for unless the terminal has to be asked, so the
13
+ * ordinary start does not yield before the UI mounts.
14
+ */
15
+ export declare function applyLaunchTheme(tui: Pick<TuiConfig, 'theme' | 'reducedMotion'> | undefined, streams: BackgroundQueryStreams | undefined, env?: NodeJS.ProcessEnv): Promise<void> | undefined;
16
+ //# sourceMappingURL=theme-launch.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"theme-launch.d.ts","sourceRoot":"","sources":["../../src/tui/theme-launch.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAA;AAEpD,OAAO,EACN,KAAK,sBAAsB,EAG3B,MAAM,mBAAmB,CAAA;AAG1B,gEAAgE;AAChE,eAAO,MAAM,wBAAwB,MAAM,CAAA;AAE3C;;;GAGG;AACH,wBAAgB,gBAAgB,CAC/B,GAAG,EAAE,IAAI,CAAC,SAAS,EAAE,OAAO,GAAG,eAAe,CAAC,GAAG,SAAS,EAC3D,OAAO,EAAE,sBAAsB,GAAG,SAAS,EAC3C,GAAG,GAAE,MAAM,CAAC,UAAwB,GAClC,OAAO,CAAC,IAAI,CAAC,GAAG,SAAS,CAgB3B"}
@@ -0,0 +1,121 @@
1
+ /**
2
+ * The colour tables behind every theme. A palette is data only: `theme.ts`
3
+ * holds the live object the TUI reads, and `theme-store.ts` decides which
4
+ * palette fills it.
5
+ *
6
+ * `dark` is the look Namzu has always had (phosphor green on the terminal's
7
+ * own background) and is the default. `light` is its inverse: the same hues
8
+ * pulled darker so they read on a pale background. The two `-daltonized`
9
+ * variants move every red-versus-green meaning (done and failed, added and
10
+ * removed) onto a blue-versus-red axis. The two `-ansi` variants use only the
11
+ * terminal's own sixteen named colours, so they follow whatever colour scheme
12
+ * the terminal is set to.
13
+ */
14
+ export declare const THEME_NAMES: readonly ["dark", "light", "dark-daltonized", "light-daltonized", "dark-ansi", "light-ansi"];
15
+ export type ThemeName = (typeof THEME_NAMES)[number];
16
+ /** What the setting may hold: a concrete theme, or `auto` (follow the terminal). */
17
+ export type ThemeSetting = 'auto' | ThemeName;
18
+ /**
19
+ * The backgrounds a diff row is drawn on. Six tokens: a whole added or removed row, the same dimmed
20
+ * for a change that was refused, and the words that differ inside a changed pair of rows.
21
+ */
22
+ export interface DiffColors {
23
+ readonly added: string;
24
+ readonly removed: string;
25
+ readonly addedDimmed: string;
26
+ readonly removedDimmed: string;
27
+ readonly addedWord: string;
28
+ readonly removedWord: string;
29
+ }
30
+ export type Rgb = readonly [number, number, number];
31
+ export interface SemanticColors {
32
+ /** Canvas background — the whole UI sits on this. */
33
+ readonly background: string;
34
+ readonly text: {
35
+ readonly primary: string;
36
+ readonly secondary: string;
37
+ readonly muted: string;
38
+ };
39
+ readonly accent: {
40
+ readonly user: string;
41
+ readonly assistant: string;
42
+ readonly system: string;
43
+ readonly tool: string;
44
+ /**
45
+ * The hypermode session mode's own colour (violet), used wherever the
46
+ * mode is named: the effort slider's last stop and the composer tag.
47
+ * Never a status colour.
48
+ */
49
+ readonly hypermode: string;
50
+ /**
51
+ * An armed composer trigger (sky): its words in the draft and its tag
52
+ * row. Kept apart from the session mode's violet, which names what lasts
53
+ * for the session; a trigger lasts one message.
54
+ */
55
+ readonly trigger: string;
56
+ /** Plan mode in the footer's mode item (teal). */
57
+ readonly plan: string;
58
+ /** Background shells in the footer pill (cyan). */
59
+ readonly shells: string;
60
+ };
61
+ readonly status: {
62
+ readonly ok: string;
63
+ readonly warn: string;
64
+ readonly error: string;
65
+ /** A merged pull request (purple). */
66
+ readonly merged: string;
67
+ };
68
+ readonly border: {
69
+ readonly default: string;
70
+ readonly focus: string;
71
+ };
72
+ /**
73
+ * The working line's three letter states: already swept, the sweep's edge and
74
+ * not yet reached. `rgb` is where the stall tint starts from; absent for a
75
+ * palette that may only use named colours, which then never tints.
76
+ */
77
+ readonly live: {
78
+ readonly done: string;
79
+ readonly edge: string;
80
+ readonly ahead: string;
81
+ readonly rgb?: {
82
+ readonly done: Rgb;
83
+ readonly edge: Rgb;
84
+ readonly ahead: Rgb;
85
+ };
86
+ };
87
+ /** The `/context` grid and its legend: one colour for each category of the window. */
88
+ readonly context: {
89
+ readonly systemPrompt: string;
90
+ readonly systemTools: string;
91
+ readonly mcpTools: string;
92
+ readonly mcpInstructions: string;
93
+ readonly agents: string;
94
+ readonly memory: string;
95
+ readonly skills: string;
96
+ readonly messages: string;
97
+ readonly buffer: string;
98
+ readonly free: string;
99
+ };
100
+ /** The hypermode glow on the composer's rule: three steps, light to deep. */
101
+ readonly glow: readonly [string, string, string];
102
+ /** Diff row backgrounds: for a terminal with 24-bit colour, and for every other one. */
103
+ readonly diff: {
104
+ readonly truecolor: DiffColors;
105
+ readonly basic: DiffColors;
106
+ };
107
+ }
108
+ export declare const PALETTES: Readonly<Record<ThemeName, SemanticColors>>;
109
+ /** The picker's rows, in order: label and a plain line on what the theme is for. */
110
+ export declare const THEME_CHOICES: readonly {
111
+ readonly value: ThemeSetting;
112
+ readonly label: string;
113
+ readonly description: string;
114
+ }[];
115
+ /** The picker label for a setting, e.g. `Dark mode`. */
116
+ export declare function themeLabel(setting: ThemeSetting): string;
117
+ /** A setting from user input: the exact name, or undefined when it is not one. */
118
+ export declare function parseThemeSetting(value: unknown): ThemeSetting | undefined;
119
+ /** `auto` follows what was detected (dark when nothing was); a name is itself. */
120
+ export declare function resolveTheme(setting: unknown, detected: 'dark' | 'light' | undefined): ThemeName;
121
+ //# sourceMappingURL=theme-palettes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"theme-palettes.d.ts","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EAAE,MAAM,CAAA;QACzB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;QACvB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;KACrB,CAAA;IACD,6EAA6E;IAC7E,QAAQ,CAAC,IAAI,EAAE,SAAS,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,CAAA;IAChD,wFAAwF;IACxF,QAAQ,CAAC,IAAI,EAAE;QAAE,QAAQ,CAAC,SAAS,EAAE,UAAU,CAAC;QAAC,QAAQ,CAAC,KAAK,EAAE,UAAU,CAAA;KAAE,CAAA;CAC7E;AA8QD,eAAO,MAAM,QAAQ,EAAE,QAAQ,CAAC,MAAM,CAAC,SAAS,EAAE,cAAc,CAAC,CAOhE,CAAA;AAED,oFAAoF;AACpF,eAAO,MAAM,aAAa,EAAE,SAAS;IACpC,QAAQ,CAAC,KAAK,EAAE,YAAY,CAAA;IAC5B,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAA;IACtB,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAA;CAC5B,EA4BA,CAAA;AAED,wDAAwD;AACxD,wBAAgB,UAAU,CAAC,OAAO,EAAE,YAAY,GAAG,MAAM,CAExD;AAED,kFAAkF;AAClF,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,OAAO,GAAG,YAAY,GAAG,SAAS,CAG1E;AAED,kFAAkF;AAClF,wBAAgB,YAAY,CAAC,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,GAAG,OAAO,GAAG,SAAS,GAAG,SAAS,CAKhG"}
@@ -0,0 +1,35 @@
1
+ /**
2
+ * Which theme is showing, and the way to change it while the TUI runs.
3
+ *
4
+ * Three inputs decide it: the saved setting (`auto` or a name), what `auto`
5
+ * detected, and a preview (the picker's highlighted row, dropped when the
6
+ * picker closes). Applying a change fills the live `theme` object and bumps an
7
+ * epoch that `useThemeEpoch` subscribers redraw on, so a component that is
8
+ * memoised still repaints.
9
+ */
10
+ import { type Background } from './theme-detect.js';
11
+ import { type ThemeName, type ThemeSetting } from './theme-palettes.js';
12
+ /** Set the saved setting (and what `auto` has detected, if known). */
13
+ export declare function setThemeSetting(setting: ThemeSetting, options?: {
14
+ readonly reported?: Background;
15
+ readonly env?: NodeJS.ProcessEnv;
16
+ }): void;
17
+ /** Show `setting` without saving it; `undefined` goes back to the saved one. */
18
+ export declare function setThemePreview(setting: ThemeSetting | undefined, env?: NodeJS.ProcessEnv): void;
19
+ /** The setting that is saved (not a preview). */
20
+ export declare function savedThemeSetting(): ThemeSetting;
21
+ /** The theme on screen now. */
22
+ export declare function shownTheme(): ThemeName;
23
+ /**
24
+ * The epoch the App last drew with, handed down so that a memoised row, which
25
+ * skips a redraw when its props are unchanged, still repaints in new colours.
26
+ * Subscribing in every row would put a listener on each of them.
27
+ */
28
+ export declare const ThemeEpochContext: import("react").Context<number>;
29
+ /** Read inside a memoised component: it redraws when the shown theme changes. */
30
+ export declare function useThemeEpoch(): number;
31
+ /** The App's own subscription: its redraw is what carries a new theme to the screen. */
32
+ export declare function useThemeSubscription(): number;
33
+ /** For tests: back to the default with no listeners. */
34
+ export declare function resetThemeStore(): void;
35
+ //# sourceMappingURL=theme-store.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"theme-store.d.ts","sourceRoot":"","sources":["../../src/tui/theme-store.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAIH,OAAO,EAAE,KAAK,UAAU,EAAoB,MAAM,mBAAmB,CAAA;AACrE,OAAO,EAAE,KAAK,SAAS,EAAE,KAAK,YAAY,EAAgB,MAAM,qBAAqB,CAAA;AAqBrF,sEAAsE;AACtE,wBAAgB,eAAe,CAC9B,OAAO,EAAE,YAAY,EACrB,OAAO,GAAE;IAAE,QAAQ,CAAC,QAAQ,CAAC,EAAE,UAAU,CAAC;IAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,MAAM,CAAC,UAAU,CAAA;CAAO,GAChF,IAAI,CAIN;AAED,gFAAgF;AAChF,wBAAgB,eAAe,CAC9B,OAAO,EAAE,YAAY,GAAG,SAAS,EACjC,GAAG,GAAE,MAAM,CAAC,UAAwB,GAClC,IAAI,CAGN;AAED,iDAAiD;AACjD,wBAAgB,iBAAiB,IAAI,YAAY,CAEhD;AAED,+BAA+B;AAC/B,wBAAgB,UAAU,IAAI,SAAS,CAEtC;AAOD;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,iCAAmB,CAAA;AAEjD,iFAAiF;AACjF,wBAAgB,aAAa,IAAI,MAAM,CAEtC;AAED,wFAAwF;AACxF,wBAAgB,oBAAoB,IAAI,MAAM,CAM7C;AAED,wDAAwD;AACxD,wBAAgB,eAAe,IAAI,IAAI,CAQtC"}
@@ -1,73 +1,44 @@
1
1
  /**
2
- * Theme tokens for the TUI — phosphor green, neutral text and quiet graphite. We inherit the
3
- * terminal's own background rather than painting one, and only theme the
4
- * foreground. Explicit ANSI indices avoid Chalk's RGB cube approximation,
5
- * which can turn an intended palette color into a different hue.
6
- * `background` is kept for reference / a future light theme but is not
7
- * forced onto the canvas. A theme registry/picker is a follow-up.
2
+ * Theme tokens for the TUI. The default is `dark`: phosphor green, neutral
3
+ * text and quiet graphite. We inherit the terminal's own background rather
4
+ * than painting one, and only theme the foreground. Explicit ANSI indices
5
+ * avoid Chalk's RGB cube approximation, which can turn an intended palette
6
+ * color into a different hue.
7
+ *
8
+ * `theme` is read at render time (`theme.text.muted`), never copied into a
9
+ * module-level constant: the active theme can change while the TUI runs (see
10
+ * `theme-store.ts`), and a constant would keep the old colours. The palettes
11
+ * themselves live in `theme-palettes.ts`.
8
12
  */
9
- export interface SemanticColors {
10
- /** Canvas background — the whole UI sits on this. */
11
- readonly background: string;
12
- readonly text: {
13
- readonly primary: string;
14
- readonly secondary: string;
15
- readonly muted: string;
16
- };
17
- readonly accent: {
18
- readonly user: string;
19
- readonly assistant: string;
20
- readonly system: string;
21
- readonly tool: string;
22
- /**
23
- * The hypermode session mode's own colour (violet), used wherever the
24
- * mode is named: the effort slider's last stop and the composer tag.
25
- * Never a status colour.
26
- */
27
- readonly hypermode: string;
28
- /**
29
- * An armed composer trigger (sky): its words in the draft and its tag
30
- * row. Kept apart from the session mode's violet, which names what lasts
31
- * for the session; a trigger lasts one message.
32
- */
33
- readonly trigger: string;
34
- /** Plan mode in the footer's mode item (teal). */
35
- readonly plan: string;
36
- /** Background shells in the footer pill (cyan). */
37
- readonly shells: string;
38
- };
39
- readonly status: {
40
- readonly ok: string;
41
- readonly warn: string;
42
- readonly error: string;
43
- /** A merged pull request (purple). */
44
- readonly merged: string;
45
- };
46
- readonly border: {
47
- readonly default: string;
48
- readonly focus: string;
49
- };
50
- }
13
+ import { type DiffColors, type SemanticColors, type ThemeName } from './theme-palettes.js';
14
+ export type { DiffColors, SemanticColors, ThemeName };
15
+ /** The active palette. Mutated in place by `applyPalette`; read, never written, elsewhere. */
51
16
  export declare const theme: SemanticColors;
52
- /**
53
- * The backgrounds a diff row is drawn on. Six tokens: a whole added or removed row, the same dimmed
54
- * for a change that was
55
- * refused, and the words that differ inside a changed pair of rows.
56
- */
57
- export interface DiffColors {
58
- readonly added: string;
59
- readonly removed: string;
60
- readonly addedDimmed: string;
61
- readonly removedDimmed: string;
62
- readonly addedWord: string;
63
- readonly removedWord: string;
64
- }
65
- /** For a terminal that reports 24-bit colour: the dark-theme values. */
17
+ /** Make `name` the active palette. The store calls this and then tells the screen to redraw. */
18
+ export declare function applyPalette(name: ThemeName): void;
19
+ /** The name of the palette currently applied. */
20
+ export declare function activeThemeName(): ThemeName;
21
+ /** The dark theme's diff colours for a terminal that reports 24-bit colour. */
66
22
  export declare const DIFF_COLORS_TRUECOLOR: DiffColors;
67
- /** For every other terminal: the named ANSI colours, words in the bright variant. */
23
+ /** The dark theme's diff colours for every other terminal: named ANSI colours, words in the bright variant. */
68
24
  export declare const DIFF_COLORS_ANSI: DiffColors;
69
25
  /** Whether the terminal says it draws 24-bit colour. */
70
26
  export declare function reportsTruecolor(env?: NodeJS.ProcessEnv): boolean;
71
- /** The diff colours this terminal can draw. */
27
+ /** The diff colours the active theme draws on this terminal. */
72
28
  export declare function diffColors(env?: NodeJS.ProcessEnv): DiffColors;
29
+ /** The colour groups a row may name by token. */
30
+ type RowTokenGroup = 'text' | 'accent' | 'status' | 'border' | 'context';
31
+ /** A theme colour a row is allowed to carry, as `group.name` (`status.error`). */
32
+ export type ThemeToken = {
33
+ [G in RowTokenGroup]: `${G}.${keyof SemanticColors[G] & string}`;
34
+ }[RowTokenGroup];
35
+ /**
36
+ * A colour for a row that is stored and drawn later. It is the token's name,
37
+ * not its value, so a row already on screen is drawn in the colours of the theme
38
+ * that is active when it is drawn, not the one it was written under.
39
+ */
40
+ export declare function tokenColor(token: ThemeToken): string;
41
+ /** The colour to draw: a stored token is looked up in the active theme, any other colour is kept. */
42
+ export declare function paint(color: string): string;
43
+ export declare function paint(color: string | undefined): string | undefined;
73
44
  //# sourceMappingURL=theme.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../src/tui/theme.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,MAAM,WAAW,cAAc;IAC9B,qDAAqD;IACrD,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAA;IAC3B,QAAQ,CAAC,IAAI,EAAE;QACd,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAA;QACxB,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAA;QAC1B,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAA;KACtB,CAAA;IACD,QAAQ,CAAC,MAAM,EAAE;QAChB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;QACrB,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAA;QAC1B,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;QACvB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;QACrB;;;;WAIG;QACH,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAA;QAC1B;;;;WAIG;QACH,QAAQ,CAAC,OA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andOutput(facts: CommandFacts, raw: string): Tid
52
52
  * every internal tool name; the person needs one sentence.
53
53
  */
54
54
  export declare function unknownToolNotice(result: string): string | undefined;
55
+ /** The short row for a call whose arguments did not fit the tool's schema; the full text is in the detailed transcript. */
56
+ export declare const INVALID_PARAMETERS = "Invalid tool parameters";
55
57
  /** What the transcript says under a call the person answered No to. */
56
58
  export declare function declinedLine(note: string | undefined): string;
59
+ /**
60
+ * The sentence for a call that was not run because an earlier call was refused
61
+ * and the turn stopped, or `undefined` for any other result.
62
+ */
63
+ export declare function turnStoppedLine(result: string): string | undefined;
57
64
  /**
58
65
  * One sentence for a call the kernel refused or that could not do what it was
59
66
  * asked, from `ToolResult.facts` of kind `failure`, so the model's refusal text
@@ -63,6 +70,21 @@ export declare function declinedLine(note: string | undefined): string;
63
70
  export declare function failureFactsLine(facts: Extract<ToolFacts, {
64
71
  kind: 'failure';
65
72
  }>, cwd?: string): string;
73
+ /**
74
+ * The short text a refused call of a file, search or language tool reads as,
75
+ * only where a refusal is worth a label of its own: a missing file, a file
76
+ * that has to be read first, and a refusal made before the tool did its work
77
+ * (input it could not use, text that is not there, a copy gone stale). Every
78
+ * other failure, a permission error, a timeout or a directory read as a file,
79
+ * has no label and is drawn as the tool's own message. The full message stays
80
+ * behind ctrl+o. A file that has to be read first is advice, so it is drawn dim.
81
+ */
82
+ export declare function shortToolFailure(toolName: string, facts: Extract<ToolFacts, {
83
+ kind: 'failure';
84
+ }>): {
85
+ readonly text: string;
86
+ readonly tone: 'error' | 'muted';
87
+ } | undefined;
66
88
  /**
67
89
  * The one-line account of a finished read, search, write or edit, from the typed
68
90
  * facts the kernel reports (`ToolResult.facts`), not from the model's receipt:
@@ -1 +1 @@
1
- {"version":3,"file":"tidy-tool-output.d.ts","sourceRoot":"","sources":["../../src/tui/tidy-tool-output.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,SAAS,EAAkB,MAAM,YAAY,CAAA;AAI3D,OAAO,KAAK,EAAE,WAAW,EA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AAE,OAAO,CAAC,SAAS,EAAE;IAAE,IAAI,EAAE,SAAS,CAAA;CAAE,CAAC,EAC9C,GAAG,CAAC,EAAE,MAAM,GACV,MAAM,CA8CR;AAED;;;;;;;;GAQG;AACH,wBAAgB,gBAAgB,CAC/B,QAAQ,EAAE,MAAM,EAChB,KAAK,EAAE,OAAO,CAAC,SAAS,EAAE;IAAE,IAAI,EAAE,SAAS,CAAA;CAAE,CAAC,GAC5C;IAAE,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,IAAI,EAAE,OAAO,GAAG,OAAO,CAAA;CAAE,GAAG,SAAS,CA+BzE;AAoBD;;;;;;;GAOG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,SAAS,GAAG,SAAS,GAAG,MAAM,GAAG,SAAS,CAoD9E"}
@@ -0,0 +1,25 @@
1
+ export interface TipShown {
2
+ readonly lastLaunch: number;
3
+ readonly total: number;
4
+ }
5
+ export interface TipHistory {
6
+ readonly launches: number;
7
+ readonly shown: Readonly<Record<string, TipShown>>;
8
+ /** How many times each command was run, by name without the slash. */
9
+ readonly used: Readonly<Record<string, number>>;
10
+ }
11
+ /** The store the terminal and the picker share; the file one below is the real one. */
12
+ export interface TipHistoryStore {
13
+ read(): TipHistory;
14
+ /** Count one process start. Called once, by the interactive entry only. */
15
+ recordLaunch(): void;
16
+ /** A tip was picked: remember it at the current launch and count the showing. */
17
+ recordShown(id: string): void;
18
+ /** A command ran: count it. */
19
+ recordUse(command: string): void;
20
+ }
21
+ export declare const EMPTY_TIP_HISTORY: TipHistory;
22
+ export declare function tipHistoryPath(home?: string): string;
23
+ export declare function readTipHistory(path: string): TipHistory;
24
+ export declare function fileTipHistory(home?: string): TipHistoryStore;
25
+ //# sourceMappingURL=tip-history.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tip-history.d.ts","sourceRoot":"","sources":["../../src/tui/tip-history.ts"],"names":[],"mappings":"AAqBA,MAAM,WAAW,QAAQ;IACxB,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAA;IAC3B,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAA;CACtB;AAED,MAAM,WAAW,UAAU;IAC1B,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAA;IACzB,QAAQ,CAAC,KAAK,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,QAAQ,CAAC,CAAC,CAAA;IAClD,sEAAsE;IACtE,QAAQ,CAAC,IAAI,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAA;CAC/C;AAED,uFAAuF;AACvF,MAAM,WAAW,eAAe;IAC/B,IAAI,IAAI,UAAU,CAAA;IAClB,2EAA2E;IAC3E,YAAY,IAAI,IAAI,CAAA;IACpB,iFAAiF;IACjF,WAAW,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI,CAAA;IAC7B,+BAA+B;IAC/B,SAAS,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAA;CAChC;AAED,eAAO,MAAM,iBAAiB,EAAE,UAAiD,CAAA;AAEjF,wBAAgB,cAAc,CAAC,IAAI,CAAC,EAAE,MAAM,GAAG,MAAM,CAEpD;AAMD,wBAAgB,cAAc,CAAC,IAAI,EAAE,MAAM,GAAG,UAAU,CAsBvD;AAiBD,wBAAgB,cAAc,CAAC,IAAI,CAAC,EAAE,MAAM,GAAG,eAAe,CAuB7D"}
@@ -0,0 +1,7 @@
1
+ /**
2
+ * The frame counter behind the animated busy glyph in the terminal title.
3
+ * Advances every `TITLE_ANIMATION_MS` while `active`; when it stops the count
4
+ * stays where it was, so the title freezes on the frame it showed.
5
+ */
6
+ export declare function useTitleFrame(active: boolean): number;
7
+ //# sourceMappingURL=title-frame.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"title-frame.d.ts","sourceRoot":"","sources":["../../src/tui/title-frame.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAMH,wBAAgB,aAAa,CAAC,MAAM,EAAE,OAAO,GAAG,MAAM,CAQrD"}
@@ -1,5 +1,6 @@
1
1
  import type { AgentEvent } from './agent.js';
2
2
  import { type ProposedChange } from './diff-rows.js';
3
+ import { type FoldOp } from './read-search-group.js';
3
4
  import type { TranscriptMessage } from './types.js';
4
5
  import { type WebActivity } from './web-activity.js';
5
6
  /**
@@ -20,11 +21,13 @@ export interface ToolEndStart {
20
21
  readonly command?: string;
21
22
  readonly web?: WebActivity;
22
23
  readonly activity?: 'exploration';
24
+ /** The call only looks; it folds into a counted line with its neighbours. */
25
+ readonly fold?: FoldOp;
23
26
  /** What an edit or write asked for, drawn dimmed if the person refuses it. */
24
27
  readonly proposed?: ProposedChange;
25
28
  }
26
29
  /** One row to add, in the order of `pushMessage`'s arguments that matter. */
27
- export type ToolRow = Pick<TranscriptMessage, 'role' | 'content'> & Partial<Pick<TranscriptMessage, 'glyph' | 'glyphColor' | 'meta' | 'detail' | 'activity' | 'shell' | 'diff'>>;
30
+ export type ToolRow = Pick<TranscriptMessage, 'role' | 'content'> & Partial<Pick<TranscriptMessage, 'glyph' | 'glyphColor' | 'contentColor' | 'meta' | 'detail' | 'activity' | 'shell' | 'diff' | 'group'>>;
28
31
  export type ToolEndRows =
29
32
  /** Add these rows. */
30
33
  {
@@ -1 +1 @@
1
- {"version":3,"file":"tool-end-rows.d.ts","sourceRoot":"","sources":["../../src/tui/tool-end-rows.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAA;AAE5C,OAAO,EAAE,KAAK,cAAc,EAAgB,MAAM,gBAAgB,CAAA;AASlE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAEnD,OAAO,EAAE,KAAK,WAAW,EAAgC,MAAM,mBAAmB,CAAA;AAElF;;;;;;;GAOG;AAEH,MAAM,MAAM,YAAY,GAAG,OAAO,CAAC,UAAU,EAAE;IAAE,IAAI,EAAE,UAAU,CAAA;CAAE,CAAC,CAAA;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QAAQ,EAAE,OAAO,GAAG,MAAM,CAUrF;AAED,iFAAiF;AACjF,wBAAgB,WAAW,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAEhD"}
1
+ {"version":3,"file":"tool-failure-text.d.ts","sourceRoot":"","sources":["../../src/tui/tool-failure-text.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AASH,uFAAuF;AACvF,wBAAgB,eAAe,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,EAAE,QAAQ,EAAE,OAAO,GAAG,MAAM,CAUrF;AAED,iFAAiF;AACjF,wBAAgB,WAAW,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAEhD"}
@@ -0,0 +1,31 @@
1
+ /**
2
+ * The detailed transcript screen: which rows it shows and what its footer says.
3
+ *
4
+ * Pure functions, so the window rule, the divider and the footer line can be
5
+ * driven without a terminal. `TranscriptScreen.tsx` draws what these return.
6
+ */
7
+ import type { TranscriptMessage } from './types.js';
8
+ /** Rows the screen shows before the person asks for all of them. */
9
+ export declare const TRANSCRIPT_SCREEN_TAIL = 30;
10
+ /** The rows to draw, and how many older ones the window leaves out. */
11
+ export interface ScreenWindow {
12
+ readonly hiddenCount: number;
13
+ readonly shown: readonly TranscriptMessage[];
14
+ }
15
+ /** The last {@link TRANSCRIPT_SCREEN_TAIL} rows, or every row once `showAll` is on. */
16
+ export declare function screenWindow(messages: readonly TranscriptMessage[], showAll: boolean): ScreenWindow;
17
+ /**
18
+ * The divider above the window: `[before, count, after]`, where `count` is drawn
19
+ * bold. Null when the conversation fits and there is nothing to show or hide.
20
+ */
21
+ export declare function screenDivider(hiddenCount: number, showAll: boolean): readonly [string, string, string] | null;
22
+ /** The footer line's left side, cut to `columns` with an ellipsis. */
23
+ export declare function screenFooter(options: {
24
+ readonly showAll: boolean;
25
+ readonly dialogWaiting: boolean;
26
+ readonly columns: number;
27
+ }): {
28
+ readonly prefix: string;
29
+ readonly text: string;
30
+ };
31
+ //# sourceMappingURL=transcript-screen.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"transcript-screen.d.ts","sourceRoot":"","sources":["../../src/tui/transcript-screen.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAEnD,oEAAoE;AACpE,eAAO,MAAM,sBAAsB,KAAK,CAAA;AAExC,uEAAuE;AACvE,MAAM,WAAW,YAAY;IAC5B,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAA;IAC5B,QAAQ,CAAC,KAAK,EAAE,SAAS,iBAAiB,EAAE,CAAA;CAC5C;AAED,uFAAuF;AACvF,wBAAgB,YAAY,CAC3B,QAAQ,EAAE,SAAS,iBAAiB,EAAE,EACtC,OAAO,EAAE,OAAO,GACd,YAAY,CAWd;AAED;;;GAGG;AACH,wBAAgB,aAAa,CAC5B,WAAW,EAAE,MAAM,EACnB,OAAO,EAAE,OAAO,GACd,SAAS,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,GAAG,IAAI,CAQ1C;AAED,sEAAsE;AACtE,wBAAgB,YAAY,CAAC,OAAO,EAAE;IACrC,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAA;IACzB,QAAQ,CAAC,aAAa,EAAE,OAAO,CAAA;IAC/B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAA;CACxB,GAAG;IAAE,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;CAAE,CAMrD"}
@@ -1 +1 @@
1
- {"version":3,"file":"transcript-scroll.d.ts","sourceRoot":"","sources":["../../src/tui/transcript-scroll.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAOH,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAEnD,2CAA2C;AAC3C,MAAM,WAAW,SAAS;IACzB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAA;IACtB,QAAQ,CAAC,UAA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