@hanzo/dev 4.0.1 → 4.2.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 (371) hide show
  1. package/LICENSE +21 -0
  2. package/dist/{BinaryViewer-qn8xfPZp.js → BinaryViewer-CmFUK4zZ.js} +2 -2
  3. package/dist/{ChatMarkdown-Cyujn3JJ.js → ChatMarkdown-nvEI7iCv.js} +4 -4
  4. package/dist/{DiffCommentAnnotation-BZu1TP6E.js → DiffCommentAnnotation-BPTN_2a6.js} +1 -1
  5. package/dist/{DiffFileTree-CcJ91zOM.js → DiffFileTree-B_br90vY.js} +2 -2
  6. package/dist/{DiffPanel-BXC88NMs.js → DiffPanel-V5R5TPuK.js} +5 -5
  7. package/dist/{ExpandedImageDialog-BZnGRBJR.js → ExpandedImageDialog-CAorLacL.js} +1 -1
  8. package/dist/{FileExplorerPane-vBJS6V75.js → FileExplorerPane-CeHulcPz.js} +1 -1
  9. package/dist/{FilePreviewPanel-jJHWsMzm.js → FilePreviewPanel-BVNLvWOc.js} +8 -8
  10. package/dist/{MermaidDiagram-paNwQY33.js → MermaidDiagram-CTolIzQD.js} +1 -1
  11. package/dist/{MermaidFilePreview-B9KxfnIN.js → MermaidFilePreview-CP2zP4FU.js} +1 -1
  12. package/dist/{MermaidViewer-CAEGpLyD.js → MermaidViewer-BDfYkS9E.js} +2 -2
  13. package/dist/{NotebookPreview-D01mMCpR.js → NotebookPreview-Cybs5uM0.js} +1 -1
  14. package/dist/{OfficeFilePreview-DWaRgfQU.js → OfficeFilePreview-7JsmSoKU.js} +1 -1
  15. package/dist/{OfficeViewer-BudrZbBA.js → OfficeViewer-CJoojlJK.js} +1 -1
  16. package/dist/{OpenInPicker-Dd3ifHa1.js → OpenInPicker-BIMWUxBP.js} +7 -7
  17. package/dist/{OpenXmlOfficeViewer-CXcKdq7k.js → OpenXmlOfficeViewer-C24Kj8DM.js} +1 -1
  18. package/dist/{PreviewImage-C4Ku4z7v.js → PreviewImage-oY5YnuTr.js} +1 -1
  19. package/dist/{PreviewImageContent-BwOB9Lyd.js → PreviewImageContent-n6eLzY99.js} +1 -1
  20. package/dist/{PullRequestCodeTab-BcwyMk7d.js → PullRequestCodeTab-Dv_0kVad.js} +7 -7
  21. package/dist/{PullRequestReviewAnnotation-BU5t_1fC.js → PullRequestReviewAnnotation-LeuwO-iH.js} +4 -4
  22. package/dist/builder/activity.d.ts +16 -0
  23. package/dist/builder/activity.js +51 -0
  24. package/dist/builder/address.d.ts +11 -0
  25. package/dist/builder/address.js +50 -0
  26. package/dist/builder/ago.d.ts +2 -0
  27. package/dist/builder/ago.js +18 -0
  28. package/dist/builder/api/agents.d.ts +139 -0
  29. package/dist/builder/api/agents.js +253 -0
  30. package/dist/builder/api/auto.d.ts +166 -0
  31. package/dist/builder/api/auto.js +300 -0
  32. package/dist/builder/api/billing.d.ts +263 -0
  33. package/dist/builder/api/billing.js +401 -0
  34. package/dist/builder/api/call.d.ts +53 -0
  35. package/dist/builder/api/call.js +123 -0
  36. package/dist/builder/api/capabilities.d.ts +14 -0
  37. package/dist/builder/api/capabilities.js +41 -0
  38. package/dist/builder/api/changes.d.ts +74 -0
  39. package/dist/builder/api/changes.js +75 -0
  40. package/dist/builder/api/chat.d.ts +12 -0
  41. package/dist/builder/api/chat.js +28 -0
  42. package/dist/builder/api/cli.d.ts +59 -0
  43. package/dist/builder/api/cli.js +133 -0
  44. package/dist/builder/api/codebases.d.ts +46 -0
  45. package/dist/builder/api/codebases.js +100 -0
  46. package/dist/builder/api/coding.d.ts +117 -0
  47. package/dist/builder/api/coding.js +222 -0
  48. package/dist/builder/api/connectors.d.ts +76 -0
  49. package/dist/builder/api/connectors.js +111 -0
  50. package/dist/builder/api/consent.d.ts +22 -0
  51. package/dist/builder/api/consent.js +28 -0
  52. package/dist/builder/api/conversations.d.ts +20 -0
  53. package/dist/builder/api/conversations.js +23 -0
  54. package/dist/builder/api/draft.d.ts +38 -0
  55. package/dist/builder/api/draft.js +87 -0
  56. package/dist/builder/api/environment.d.ts +55 -0
  57. package/dist/builder/api/environment.js +126 -0
  58. package/dist/builder/api/gallery.d.ts +32 -0
  59. package/dist/builder/api/gallery.js +85 -0
  60. package/dist/builder/api/git.d.ts +59 -0
  61. package/dist/builder/api/git.js +117 -0
  62. package/dist/builder/api/github.d.ts +230 -0
  63. package/dist/builder/api/github.js +373 -0
  64. package/dist/builder/api/keys.d.ts +35 -0
  65. package/dist/builder/api/keys.js +72 -0
  66. package/dist/builder/api/library.d.ts +116 -0
  67. package/dist/builder/api/library.js +214 -0
  68. package/dist/builder/api/limits.d.ts +69 -0
  69. package/dist/builder/api/limits.js +86 -0
  70. package/dist/builder/api/links.d.ts +51 -0
  71. package/dist/builder/api/links.js +75 -0
  72. package/dist/builder/api/machines.d.ts +122 -0
  73. package/dist/builder/api/machines.js +238 -0
  74. package/dist/builder/api/mcp.d.ts +10 -0
  75. package/dist/builder/api/mcp.js +47 -0
  76. package/dist/builder/api/members.d.ts +35 -0
  77. package/dist/builder/api/members.js +95 -0
  78. package/dist/builder/api/memory.d.ts +14 -0
  79. package/dist/builder/api/memory.js +35 -0
  80. package/dist/builder/api/models.d.ts +17 -0
  81. package/dist/builder/api/models.js +20 -0
  82. package/dist/builder/api/places.d.ts +32 -0
  83. package/dist/builder/api/places.js +29 -0
  84. package/dist/builder/api/platform.d.ts +68 -0
  85. package/dist/builder/api/platform.js +87 -0
  86. package/dist/builder/api/plugins.d.ts +42 -0
  87. package/dist/builder/api/plugins.js +175 -0
  88. package/dist/builder/api/pref.d.ts +77 -0
  89. package/dist/builder/api/pref.js +93 -0
  90. package/dist/builder/api/profile.d.ts +11 -0
  91. package/dist/builder/api/profile.js +41 -0
  92. package/dist/builder/api/projects.d.ts +99 -0
  93. package/dist/builder/api/projects.js +166 -0
  94. package/dist/builder/api/provider.d.ts +49 -0
  95. package/dist/builder/api/provider.js +96 -0
  96. package/dist/builder/api/sandbox.d.ts +90 -0
  97. package/dist/builder/api/sandbox.js +223 -0
  98. package/dist/builder/api/sessions.d.ts +123 -0
  99. package/dist/builder/api/sessions.js +255 -0
  100. package/dist/builder/api/skills.d.ts +82 -0
  101. package/dist/builder/api/skills.js +117 -0
  102. package/dist/builder/api/sse.d.ts +24 -0
  103. package/dist/builder/api/sse.js +68 -0
  104. package/dist/builder/api/studio.d.ts +59 -0
  105. package/dist/builder/api/studio.js +91 -0
  106. package/dist/builder/api/talk.d.ts +48 -0
  107. package/dist/builder/api/talk.js +81 -0
  108. package/dist/builder/api/tools.d.ts +34 -0
  109. package/dist/builder/api/tools.js +37 -0
  110. package/dist/builder/api/turn.d.ts +202 -0
  111. package/dist/builder/api/turn.js +772 -0
  112. package/dist/builder/api/verdict.d.ts +3 -0
  113. package/dist/builder/api/verdict.js +21 -0
  114. package/dist/builder/api/webhooks.d.ts +47 -0
  115. package/dist/builder/api/webhooks.js +82 -0
  116. package/dist/builder/api/work.d.ts +110 -0
  117. package/dist/builder/api/work.js +218 -0
  118. package/dist/builder/ask.d.ts +51 -0
  119. package/dist/builder/ask.js +147 -0
  120. package/dist/builder/automations.d.ts +33 -0
  121. package/dist/builder/automations.js +453 -0
  122. package/dist/builder/awake.d.ts +24 -0
  123. package/dist/builder/awake.js +68 -0
  124. package/dist/builder/back.d.ts +30 -0
  125. package/dist/builder/back.js +105 -0
  126. package/dist/builder/builder.d.ts +12 -0
  127. package/dist/builder/builder.js +162 -0
  128. package/dist/builder/carry.d.ts +48 -0
  129. package/dist/builder/carry.js +278 -0
  130. package/dist/builder/choice.d.ts +134 -0
  131. package/dist/builder/choice.js +152 -0
  132. package/dist/builder/claims.d.ts +13 -0
  133. package/dist/builder/claims.js +35 -0
  134. package/dist/builder/clipboard.d.ts +2 -0
  135. package/dist/builder/clipboard.js +10 -0
  136. package/dist/builder/customize/agents.d.ts +11 -0
  137. package/dist/builder/customize/agents.js +513 -0
  138. package/dist/builder/customize/connectors.d.ts +2 -0
  139. package/dist/builder/customize/connectors.js +319 -0
  140. package/dist/builder/customize/drafted.d.ts +4 -0
  141. package/dist/builder/customize/drafted.js +92 -0
  142. package/dist/builder/customize/index.d.ts +8 -0
  143. package/dist/builder/customize/index.js +127 -0
  144. package/dist/builder/customize/inventory.d.ts +14 -0
  145. package/dist/builder/customize/inventory.js +127 -0
  146. package/dist/builder/customize/load.d.ts +9 -0
  147. package/dist/builder/customize/load.js +22 -0
  148. package/dist/builder/customize/ocean.d.ts +41 -0
  149. package/dist/builder/customize/ocean.js +332 -0
  150. package/dist/builder/customize/plugins.d.ts +2 -0
  151. package/dist/builder/customize/plugins.js +136 -0
  152. package/dist/builder/customize/roles.d.ts +4 -0
  153. package/dist/builder/customize/roles.js +105 -0
  154. package/dist/builder/customize/say.d.ts +13 -0
  155. package/dist/builder/customize/say.js +32 -0
  156. package/dist/builder/customize/skills.d.ts +2 -0
  157. package/dist/builder/customize/skills.js +208 -0
  158. package/dist/builder/customize/ui.d.ts +152 -0
  159. package/dist/builder/customize/ui.js +208 -0
  160. package/dist/builder/data.d.ts +57 -0
  161. package/dist/builder/data.js +322 -0
  162. package/dist/builder/design.d.ts +140 -0
  163. package/dist/builder/design.js +175 -0
  164. package/dist/builder/desk.d.ts +48 -0
  165. package/dist/builder/desk.js +449 -0
  166. package/dist/builder/dev-mode.d.ts +43 -0
  167. package/dist/builder/dev-mode.js +120 -0
  168. package/dist/builder/door.d.ts +11 -0
  169. package/dist/builder/door.js +126 -0
  170. package/dist/builder/environment.d.ts +23 -0
  171. package/dist/builder/environment.js +193 -0
  172. package/dist/builder/files.d.ts +23 -0
  173. package/dist/builder/files.js +175 -0
  174. package/dist/builder/find.d.ts +7 -0
  175. package/dist/builder/find.js +80 -0
  176. package/dist/builder/foot.d.ts +30 -0
  177. package/dist/builder/foot.js +79 -0
  178. package/dist/builder/forge.d.ts +4 -0
  179. package/dist/builder/forge.js +639 -0
  180. package/dist/builder/gear.d.ts +60 -0
  181. package/dist/builder/gear.js +180 -0
  182. package/dist/builder/git.d.ts +21 -0
  183. package/dist/builder/git.js +118 -0
  184. package/dist/builder/github-sync.d.ts +70 -0
  185. package/dist/builder/github-sync.js +435 -0
  186. package/dist/builder/gutter.d.ts +17 -0
  187. package/dist/builder/gutter.js +25 -0
  188. package/dist/builder/handoff.d.ts +8 -0
  189. package/dist/builder/handoff.js +22 -0
  190. package/dist/builder/host.d.ts +189 -0
  191. package/dist/builder/host.js +46 -0
  192. package/dist/builder/index.d.ts +108 -0
  193. package/dist/builder/index.js +99 -0
  194. package/dist/builder/landing.d.ts +34 -0
  195. package/dist/builder/landing.js +725 -0
  196. package/dist/builder/library.d.ts +21 -0
  197. package/dist/builder/library.js +526 -0
  198. package/dist/builder/local.d.ts +80 -0
  199. package/dist/builder/local.js +124 -0
  200. package/dist/builder/make.d.ts +10 -0
  201. package/dist/builder/make.js +120 -0
  202. package/dist/builder/markdown.d.ts +49 -0
  203. package/dist/builder/markdown.js +125 -0
  204. package/dist/builder/marks.d.ts +15 -0
  205. package/dist/builder/marks.js +18 -0
  206. package/dist/builder/merge.d.ts +223 -0
  207. package/dist/builder/merge.js +380 -0
  208. package/dist/builder/meter.d.ts +31 -0
  209. package/dist/builder/meter.js +54 -0
  210. package/dist/builder/mind.d.ts +107 -0
  211. package/dist/builder/mind.js +335 -0
  212. package/dist/builder/names.d.ts +40 -0
  213. package/dist/builder/names.js +189 -0
  214. package/dist/builder/nav.d.ts +28 -0
  215. package/dist/builder/nav.js +218 -0
  216. package/dist/builder/out.d.ts +16 -0
  217. package/dist/builder/out.js +24 -0
  218. package/dist/builder/page.d.ts +55 -0
  219. package/dist/builder/page.js +217 -0
  220. package/dist/builder/pane.d.ts +30 -0
  221. package/dist/builder/pane.js +21 -0
  222. package/dist/builder/panel.d.ts +101 -0
  223. package/dist/builder/panel.js +408 -0
  224. package/dist/builder/pdf.d.ts +139 -0
  225. package/dist/builder/pdf.js +847 -0
  226. package/dist/builder/pick.d.ts +10 -0
  227. package/dist/builder/pick.js +38 -0
  228. package/dist/builder/plain.d.ts +59 -0
  229. package/dist/builder/plain.js +209 -0
  230. package/dist/builder/plan.d.ts +63 -0
  231. package/dist/builder/plan.js +155 -0
  232. package/dist/builder/plans.d.ts +1 -0
  233. package/dist/builder/plans.js +157 -0
  234. package/dist/builder/plugin.d.ts +60 -0
  235. package/dist/builder/plugin.js +1 -0
  236. package/dist/builder/plugins/design.d.ts +8 -0
  237. package/dist/builder/plugins/design.js +71 -0
  238. package/dist/builder/plugins/index.d.ts +46 -0
  239. package/dist/builder/plugins/index.js +117 -0
  240. package/dist/builder/plugins/pdf.d.ts +18 -0
  241. package/dist/builder/plugins/pdf.js +83 -0
  242. package/dist/builder/plugins/project.d.ts +5 -0
  243. package/dist/builder/plugins/project.js +68 -0
  244. package/dist/builder/plugins/research.d.ts +24 -0
  245. package/dist/builder/plugins/research.js +147 -0
  246. package/dist/builder/plugins/sketch.d.ts +9 -0
  247. package/dist/builder/plugins/sketch.js +101 -0
  248. package/dist/builder/plugins/slides.d.ts +14 -0
  249. package/dist/builder/plugins/slides.js +55 -0
  250. package/dist/builder/plugins/template.d.ts +13 -0
  251. package/dist/builder/plugins/template.js +95 -0
  252. package/dist/builder/prefs.d.ts +29 -0
  253. package/dist/builder/prefs.js +91 -0
  254. package/dist/builder/preview-url.d.ts +47 -0
  255. package/dist/builder/preview-url.js +107 -0
  256. package/dist/builder/project.d.ts +18 -0
  257. package/dist/builder/project.js +604 -0
  258. package/dist/builder/prose.d.ts +4 -0
  259. package/dist/builder/prose.js +57 -0
  260. package/dist/builder/publish.d.ts +18 -0
  261. package/dist/builder/publish.js +141 -0
  262. package/dist/builder/question.d.ts +33 -0
  263. package/dist/builder/question.js +64 -0
  264. package/dist/builder/redesign.d.ts +32 -0
  265. package/dist/builder/redesign.js +117 -0
  266. package/dist/builder/removal.d.ts +71 -0
  267. package/dist/builder/removal.js +73 -0
  268. package/dist/builder/reply.d.ts +50 -0
  269. package/dist/builder/reply.js +196 -0
  270. package/dist/builder/roles.d.ts +10 -0
  271. package/dist/builder/roles.js +28 -0
  272. package/dist/builder/route.d.ts +85 -0
  273. package/dist/builder/route.js +126 -0
  274. package/dist/builder/run.d.ts +4 -0
  275. package/dist/builder/run.js +804 -0
  276. package/dist/builder/runmeta.d.ts +16 -0
  277. package/dist/builder/runmeta.js +69 -0
  278. package/dist/builder/say.d.ts +2 -0
  279. package/dist/builder/say.js +7 -0
  280. package/dist/builder/scheduled.d.ts +3 -0
  281. package/dist/builder/scheduled.js +328 -0
  282. package/dist/builder/section.d.ts +27 -0
  283. package/dist/builder/section.js +60 -0
  284. package/dist/builder/settings/account.d.ts +1 -0
  285. package/dist/builder/settings/account.js +111 -0
  286. package/dist/builder/settings/billing.d.ts +1 -0
  287. package/dist/builder/settings/billing.js +210 -0
  288. package/dist/builder/settings/capabilities.d.ts +1 -0
  289. package/dist/builder/settings/capabilities.js +66 -0
  290. package/dist/builder/settings/card.d.ts +31 -0
  291. package/dist/builder/settings/card.js +140 -0
  292. package/dist/builder/settings/code.d.ts +1 -0
  293. package/dist/builder/settings/code.js +70 -0
  294. package/dist/builder/settings/credits.d.ts +10 -0
  295. package/dist/builder/settings/credits.js +123 -0
  296. package/dist/builder/settings/environments.d.ts +1 -0
  297. package/dist/builder/settings/environments.js +60 -0
  298. package/dist/builder/settings/general.d.ts +1 -0
  299. package/dist/builder/settings/general.js +58 -0
  300. package/dist/builder/settings/index.d.ts +4 -0
  301. package/dist/builder/settings/index.js +25 -0
  302. package/dist/builder/settings/integrations.d.ts +8 -0
  303. package/dist/builder/settings/integrations.js +138 -0
  304. package/dist/builder/settings/keys.d.ts +1 -0
  305. package/dist/builder/settings/keys.js +114 -0
  306. package/dist/builder/settings/list.d.ts +10 -0
  307. package/dist/builder/settings/list.js +28 -0
  308. package/dist/builder/settings/machines.d.ts +4 -0
  309. package/dist/builder/settings/machines.js +243 -0
  310. package/dist/builder/settings/members.d.ts +1 -0
  311. package/dist/builder/settings/members.js +77 -0
  312. package/dist/builder/settings/memory.d.ts +1 -0
  313. package/dist/builder/settings/memory.js +62 -0
  314. package/dist/builder/settings/notifications.d.ts +1 -0
  315. package/dist/builder/settings/notifications.js +111 -0
  316. package/dist/builder/settings/plan.d.ts +17 -0
  317. package/dist/builder/settings/plan.js +131 -0
  318. package/dist/builder/settings/privacy.d.ts +1 -0
  319. package/dist/builder/settings/privacy.js +76 -0
  320. package/dist/builder/settings/sections.d.ts +16 -0
  321. package/dist/builder/settings/sections.js +34 -0
  322. package/dist/builder/settings/shared.d.ts +6 -0
  323. package/dist/builder/settings/shared.js +58 -0
  324. package/dist/builder/settings/ui.d.ts +50 -0
  325. package/dist/builder/settings/ui.js +53 -0
  326. package/dist/builder/settings/usage.d.ts +1 -0
  327. package/dist/builder/settings/usage.js +24 -0
  328. package/dist/builder/shared.d.ts +26 -0
  329. package/dist/builder/shared.js +15 -0
  330. package/dist/builder/shelf.d.ts +16 -0
  331. package/dist/builder/shelf.js +219 -0
  332. package/dist/builder/side.d.ts +40 -0
  333. package/dist/builder/side.js +208 -0
  334. package/dist/builder/site.d.ts +75 -0
  335. package/dist/builder/site.js +138 -0
  336. package/dist/builder/spend.d.ts +21 -0
  337. package/dist/builder/spend.js +80 -0
  338. package/dist/builder/standing.d.ts +36 -0
  339. package/dist/builder/standing.js +66 -0
  340. package/dist/builder/suggest.d.ts +238 -0
  341. package/dist/builder/suggest.js +463 -0
  342. package/dist/builder/suggestions.d.ts +49 -0
  343. package/dist/builder/suggestions.js +260 -0
  344. package/dist/builder/summary.d.ts +60 -0
  345. package/dist/builder/summary.js +81 -0
  346. package/dist/builder/sync.d.ts +1 -0
  347. package/dist/builder/sync.js +187 -0
  348. package/dist/builder/tabs.d.ts +85 -0
  349. package/dist/builder/tabs.js +288 -0
  350. package/dist/builder/talk.d.ts +5 -0
  351. package/dist/builder/talk.js +108 -0
  352. package/dist/builder/thread.d.ts +60 -0
  353. package/dist/builder/thread.js +302 -0
  354. package/dist/builder/tools.d.ts +22 -0
  355. package/dist/builder/tools.js +52 -0
  356. package/dist/builder/transcript.d.ts +47 -0
  357. package/dist/builder/transcript.js +108 -0
  358. package/dist/builder/voice.d.ts +8 -0
  359. package/dist/builder/voice.js +24 -0
  360. package/dist/{changedFileKind-DqgCCDUs.js → changedFileKind-D6QYvIez.js} +1 -1
  361. package/dist/core.js +1 -0
  362. package/dist/{decodeImagePreview-CesVZYP4.js → decodeImagePreview-DnfFEjhw.js} +1 -1
  363. package/dist/{embed-DYP-OUlb.js → embed-c030vUqM.js} +11 -11
  364. package/dist/index.d.ts +2 -0
  365. package/dist/index.js +2 -1
  366. package/dist/{micromark-util-decode-string-NQjVkmZH.js → micromark-util-decode-string-C-5AXkOV.js} +5 -3
  367. package/dist/{readBinaryPreview-D2X4Uahu.js → readBinaryPreview-BAQ4fFjm.js} +1 -1
  368. package/dist/{useTextFieldSpeech-CyOZZPrV.js → useTextFieldSpeech-COa9XcRx.js} +1 -1
  369. package/package.json +101 -11
  370. /package/{index.d.ts → dist/core.d.ts} +0 -0
  371. /package/{keymap.d.ts → dist/keymap.d.ts} +0 -0
@@ -0,0 +1,189 @@
1
+ /**
2
+ * What the builder needs from the page that mounts it.
3
+ *
4
+ * The builder is ONE component with several hosts: its own page (hanzo.build,
5
+ * which signs in through Hanzo IAM and routes with react-router) and the Hanzo
6
+ * app's Dev section (hanzo.ai/dev and hanzo.app/dev, which already have a
7
+ * session, a router and a rail). Everything that differs between them is here,
8
+ * as values, so no host forks the builder and the builder imports no host.
9
+ */
10
+ import { type ComponentType, type ReactNode } from 'react';
11
+ import type { Cast } from './api/agents.ts';
12
+ import type { Target } from './api/call.ts';
13
+ import type { Theme } from './api/pref.ts';
14
+ import type { Local } from './local.ts';
15
+ import type { Site } from './site.ts';
16
+ export interface Person {
17
+ name: string;
18
+ email: string;
19
+ /** An https image, or '' for the initial. */
20
+ avatar: string;
21
+ }
22
+ /**
23
+ * A page tab's address, drawn by the host rather than in a frame: what the
24
+ * window can show of any site, where a browser page can frame only the sites
25
+ * that allow it. `onGo` is a move the page made itself (a link followed), and
26
+ * `onTitle` the title it gave itself.
27
+ */
28
+ export type Browse = ComponentType<{
29
+ url: string;
30
+ title: string;
31
+ onGo: (url: string) => void;
32
+ onTitle?: (title: string) => void;
33
+ }>;
34
+ /** A page as the host's browser is asked about it: the tab, and what it shows. */
35
+ export interface Shown {
36
+ id: string;
37
+ url: string;
38
+ title: string;
39
+ }
40
+ /**
41
+ * What the host's browser can do to the page a tab shows, each the row of the
42
+ * same name in the tab's menu. A host draws only the rows it supplies, so the
43
+ * menu offers nothing the window cannot do; a browser page supplies none and
44
+ * draws what a page itself can (panel.tsx).
45
+ */
46
+ export interface Browser {
47
+ find?: (page: Shown) => void;
48
+ print?: (page: Shown) => void;
49
+ /** Zoom the page to `percent` (100 is its own size). */
50
+ zoom?: (page: Shown, percent: number) => void;
51
+ devices?: (page: Shown) => void;
52
+ /** The page's pixels, as an image. */
53
+ capture?: (page: Shown) => Promise<Blob>;
54
+ /** What the reader has selected in the page. */
55
+ selection?: (page: Shown) => Promise<string>;
56
+ passwords?: () => void;
57
+ downloads?: () => void;
58
+ history?: () => void;
59
+ clear?: () => void;
60
+ settings?: () => void;
61
+ }
62
+ /**
63
+ * What kind of spend a press is: `task-run` one run of a scheduled task now,
64
+ * `task` a task switched on (or made on) to run by itself, `bot` a 24/7 bot
65
+ * made, `run` a coding run started, `machine` a suspended cloud computer woken,
66
+ * `publish` a site built and published (a template copied, a project published again).
67
+ */
68
+ export type SpendKind = 'run' | 'task-run' | 'task' | 'bot' | 'machine' | 'publish';
69
+ /** What a press must say before it spends, already in the person's language. */
70
+ export interface Ask {
71
+ kind: SpendKind;
72
+ /** The question: "Run Monday summary now?" */
73
+ title: string;
74
+ /** What will start, one sentence. */
75
+ what: string;
76
+ /** The yes button's words: the act itself ("Run now"). */
77
+ yes: string;
78
+ /** `computer`: it starts a cloud computer. `credits`: it counts against the plan or credits and starts no computer. */
79
+ uses: 'computer' | 'credits';
80
+ }
81
+ /**
82
+ * A question as the host is asked it. `again` is the key a host may remember a "Don't ask again" under, or null to
83
+ * ask every time. It is `<kind>.<uses>` (`task-run.credits`, `run.computer`), so one yes covers only the same kind of
84
+ * spend on the same kind of thing. A host keeps nothing it is not given a key for. A 24/7 bot's is null by its TYPE:
85
+ * each has its own budget and period, so no yes is ever remembered for one.
86
+ */
87
+ export type Spend = (Ask & {
88
+ kind: Exclude<SpendKind, 'bot'>;
89
+ again: string | null;
90
+ }) | (Ask & {
91
+ kind: 'bot';
92
+ again: null;
93
+ });
94
+ export interface Host {
95
+ /** The product's name, drawn at the top left: `Hanzo Build` on hanzo.build, `Hanzo` on hanzo.ai. */
96
+ name: string;
97
+ /** The platform origin, no trailing slash. */
98
+ api: string;
99
+ /** The signed-in person's bearer, or null. Read at call time, so a refresh is picked up. */
100
+ token: () => string | null;
101
+ /** The org every call is scoped to. */
102
+ org: string | null;
103
+ /** The org's own logo, an https address, when it has chosen one; its mark is drawn from it. */
104
+ logo?: string;
105
+ /** The organizations this person belongs to. The switcher lists these and no others. */
106
+ memberships?: readonly string[];
107
+ /** Stay on this page and scope every read to `org`. */
108
+ chooseOrg?: (org: string) => void;
109
+ /** The page's theme as last chosen, for a host that can change it. */
110
+ theme?: Theme;
111
+ /** Paint the page in `theme`. A host without it keeps its own, and Settings offers no choice. */
112
+ chooseTheme?: (theme: Theme) => void;
113
+ /** Who is signed in, or null. */
114
+ person: Person | null;
115
+ /** Whether the person administers `org` (its owner or an admin): they publish to main and change its money; anyone else opens a review and reads. */
116
+ admin: boolean;
117
+ /** The address under the mount, in route.ts's grammar: '' | a session id | `<org>/<repo>` | a slug | '-/projects' | '-/issues' | … */
118
+ path: string;
119
+ /** Move under the mount. */
120
+ go: (path: string, how?: {
121
+ replace?: boolean;
122
+ }) => void;
123
+ /** Where the builder links out. On hanzo.build these are addresses of this page. */
124
+ links: {
125
+ /** GitHub for this page: bringing repositories onto the forge. */
126
+ github: string;
127
+ /** Customize, an address of this host. */
128
+ customize: string;
129
+ /** Account settings, an address of this host. */
130
+ settings: string;
131
+ /** This host's home. On hanzo.build it is the page itself. */
132
+ home: string;
133
+ };
134
+ /** Open a host address in this window. hanzo.build keeps the window on its own origin. */
135
+ open: (href: string) => void;
136
+ /**
137
+ * Take the person to top the prepaid balance up, returning to this page with the
138
+ * model they chose (`?model=`) once paid. Another maker's models are paid from the
139
+ * balance on any plan, so a host that offers a top-up has them selectable on Free.
140
+ * Absent, they follow the plan as before.
141
+ */
142
+ topUp?: (model?: string) => void;
143
+ signIn?: () => void;
144
+ signOut?: () => void;
145
+ /** A page tab's remote address, shown by the host (Hanzo Desktop: a native webview). Absent, a browser frames what it may. */
146
+ browse?: Browse;
147
+ /** What the host's browser does to a page, row by row in the tab's menu. */
148
+ browser?: Browser;
149
+ /** The host's sidebar lists Settings' sections and Customize's tabs, so the pages draw neither. */
150
+ sections?: boolean;
151
+ /** The default agents Customize › Agents offers to start from. Absent, none. */
152
+ cast?: readonly Cast[];
153
+ /** Every persona Customize › Agents offers to start from, read when Browse opens. Absent, none. */
154
+ personas?: () => Promise<readonly Cast[]>;
155
+ /**
156
+ * The folders of the computer the host runs on, and a run in one of them (local.ts): Hanzo Desktop has them, so New
157
+ * offers This computer with Auto picking the folder used last. A browser page has no folder of its own: absent.
158
+ */
159
+ local?: Local;
160
+ /**
161
+ * Opening a site, saving a copy of it for the agent, and serving its redesign live in the person's browser (site.ts):
162
+ * Hanzo Desktop can, so New on This computer offers to redesign a site from its address. A browser page cannot: absent.
163
+ */
164
+ site?: Site;
165
+ /**
166
+ * Asks the person before a press spends (spend.tsx), and answers whether they said yes. A host that gives it is the
167
+ * only asker: the builder draws no question of its own and spends only on `true`. Absent (this package's own page),
168
+ * the builder asks in its own dialog. A no, a throw, an answer after the asking screen has gone, or one a newer
169
+ * question on that screen superseded spends nothing; one left unanswered blocks nothing.
170
+ */
171
+ confirm?: (spend: Spend) => Promise<boolean>;
172
+ }
173
+ export declare function HostProvider({ host, children }: {
174
+ host: Host;
175
+ children: ReactNode;
176
+ }): import("react").JSX.Element;
177
+ export declare function useHost(): Host;
178
+ /** The host, or null where none is mounted: a surface that may be drawn without one (the first run's card in Chat). */
179
+ export declare function useHosted(): Host | null;
180
+ /** The host's way of showing a page, where one is mounted and has one. The side panel is drawn without a host too (hanzo.team's rooms). */
181
+ export declare function useBrowse(): Browse | null;
182
+ /** The host's computer and its folders, where the host runs on one (Hanzo Desktop). */
183
+ export declare function useLocal(): Local | null;
184
+ /** The host's way of redesigning a site, where the host runs on a computer that can (Hanzo Desktop). */
185
+ export declare function useSite(): Site | null;
186
+ /** The host's browser, where one is mounted and has one. */
187
+ export declare function useBrowser(): Browser | null;
188
+ /** The call target for this host — stable while the host's api, token reader and org are. */
189
+ export declare function useTarget(): Target;
@@ -0,0 +1,46 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ /**
3
+ * What the builder needs from the page that mounts it.
4
+ *
5
+ * The builder is ONE component with several hosts: its own page (hanzo.build,
6
+ * which signs in through Hanzo IAM and routes with react-router) and the Hanzo
7
+ * app's Dev section (hanzo.ai/dev and hanzo.app/dev, which already have a
8
+ * session, a router and a rail). Everything that differs between them is here,
9
+ * as values, so no host forks the builder and the builder imports no host.
10
+ */
11
+ import { createContext, useContext, useMemo } from 'react';
12
+ const Context = createContext(null);
13
+ export function HostProvider({ host, children }) {
14
+ return _jsx(Context.Provider, { value: host, children: children });
15
+ }
16
+ export function useHost() {
17
+ const h = useContext(Context);
18
+ if (!h)
19
+ throw new Error('The builder was rendered without a host');
20
+ return h;
21
+ }
22
+ /** The host, or null where none is mounted: a surface that may be drawn without one (the first run's card in Chat). */
23
+ export function useHosted() {
24
+ return useContext(Context);
25
+ }
26
+ /** The host's way of showing a page, where one is mounted and has one. The side panel is drawn without a host too (hanzo.team's rooms). */
27
+ export function useBrowse() {
28
+ return useContext(Context)?.browse ?? null;
29
+ }
30
+ /** The host's computer and its folders, where the host runs on one (Hanzo Desktop). */
31
+ export function useLocal() {
32
+ return useContext(Context)?.local ?? null;
33
+ }
34
+ /** The host's way of redesigning a site, where the host runs on a computer that can (Hanzo Desktop). */
35
+ export function useSite() {
36
+ return useContext(Context)?.site ?? null;
37
+ }
38
+ /** The host's browser, where one is mounted and has one. */
39
+ export function useBrowser() {
40
+ return useContext(Context)?.browser ?? null;
41
+ }
42
+ /** The call target for this host — stable while the host's api, token reader and org are. */
43
+ export function useTarget() {
44
+ const { api, token, org } = useHost();
45
+ return useMemo(() => ({ api, token, org }), [api, token, org]);
46
+ }
@@ -0,0 +1,108 @@
1
+ /**
2
+ * @hanzo/build — the builder as a component.
3
+ *
4
+ * Mount `<Builder host={…} />` under a gui root in a box with a height. The
5
+ * host says where the platform is, who is signed in, and how to move; the
6
+ * builder does everything else. hanzo.build hosts it whole. A host with a rail
7
+ * of its own mounts it with `rail={false}` and draws the builder's parts in that
8
+ * rail: its places (`nav`), its runs (`useSessions`, or `DevSection` for both),
9
+ * and at the foot the Slack card and the account menu (`Slack`, `Who`), under
10
+ * `HostProvider`. `Grip` (the kit's, passed on) sizes that rail.
11
+ *
12
+ * The side panel's column, for a host that draws it beside its own middle
13
+ * column (Chat): `useSplit`, `SideProvider` and `PrefsProvider` above both, so
14
+ * the width the person drags is kept in their preferences (side.tsx).
15
+ *
16
+ * The plan, once for every surface that shows one: `label` names it (`Max` with
17
+ * `20x` beside it), `useStanding` reads where an account stands, `Meter` is the
18
+ * block an account menu leads with, `Plan` the Usage view and `Credits` the
19
+ * Billing one. Each reads as a `Target`, so a host without a builder mounts it.
20
+ * The pure half — naming, shares, the banner's words — is also `@hanzo/build/plan`,
21
+ * which loads in Node without the components.
22
+ */
23
+ export { Builder } from './builder.tsx';
24
+ export { Library, Outputs, Preview, Thumb, want } from './library.tsx';
25
+ /** The Library's one reader, for a host that lists what a person made itself: `items(target, filter)` answers one page. */
26
+ export { items, SOURCE, type Filter as ItemFilter, type Item, type Kind as ItemKind, type Page as ItemPage, type Scope as ItemScope, type Source } from './api/library.ts';
27
+ export { Scheduled, schedule } from './scheduled.tsx';
28
+ export { Editor } from './automations.tsx';
29
+ /**
30
+ * The screens a host draws in its own pane, each under `HostProvider` alone, so
31
+ * they sit inside the host's one look (theme and text size) and never under the
32
+ * builder's own `Look`: Library, Scheduled tasks and one task's `Editor` above,
33
+ * `Customize` (one tab), an agent's `Profile`, and the `Forge`'s screens
34
+ * (Projects, Issues, Sync, Connectors).
35
+ */
36
+ export { Customize } from './customize/index.tsx';
37
+ export { Profile } from './customize/agents.tsx';
38
+ export { Forge } from './forge.tsx';
39
+ export { library, nav, NEW, own, sections, tabs, useScheduled, type Group } from './nav.tsx';
40
+ export { MARKS, type Icon, type Mark } from './marks.tsx';
41
+ export { useFunds, type Funds } from './mind.ts';
42
+ export { DevSection, dot, DOTS, useSessions } from './section.tsx';
43
+ export { HostProvider } from './host.tsx';
44
+ export { Slack, useWho, Who } from './foot.tsx';
45
+ export { Grip, type GripProps } from '@hanzo/ui';
46
+ export { Gutter, type GutterProps } from './gutter.tsx';
47
+ export { administers } from './claims.ts';
48
+ export { Meter, Title } from './meter.tsx';
49
+ export { Plan } from './settings/plan.tsx';
50
+ export { Credits, SEPARATE } from './settings/credits.tsx';
51
+ export { useStanding, rows, left, type Standing, type Row } from './standing.ts';
52
+ export { kind, label, said, share, spent, ways, when, type Label, type Share, type State } from './plan.ts';
53
+ export type { Limits } from './api/limits.ts';
54
+ export type { Target } from './api/call.ts';
55
+ export type { Browse, Browser, Host, Person, Shown, Ask, Spend, SpendKind } from './host.tsx';
56
+ export type { Done, Folder, Local } from './local.ts';
57
+ export type { Live, Saved, Site } from './site.ts';
58
+ export type { Session, Status } from './api/sessions.ts';
59
+ export { mark as markRun, marks as runMarks, useMarks as useRunMarks, type RunMark, type RunMarks } from './runmeta.ts';
60
+ export { cleanErrorText, groupSessions, isAlreadyRunningError, isSessionActive, isSessionLive, linkThread, resolveSessionState, threadChain, threadRoot, useThreadLinks, type ThreadLinks, } from './thread.ts';
61
+ export { cacheBustUrl, hasUnpublishedEdits, previewRevision, resolvePreviewSource, type PreviewInputs, type PreviewKind, type PreviewSource } from './preview-url.ts';
62
+ export { talks } from './api/talk.ts';
63
+ export { detect, type Detected } from './api/skills.ts';
64
+ export { Roles } from './customize/roles.tsx';
65
+ export { recommend, WORK } from './roles.ts';
66
+ export type { Read } from './data.ts';
67
+ export { href, parse, path, PLACES, route, SESSION, SLUG, type Route, type Screen } from './route.ts';
68
+ /**
69
+ * What Chat draws the same way (@hanzo/rooms imports these): the model and
70
+ * effort (`useMind`, one choice kept for both), the row under an answer
71
+ * (`Reply`), and the side panel (`Panel` over a `Deck` of tabs). The composer is
72
+ * @hanzo/ui/chat's, for Chat and Dev alike.
73
+ */
74
+ export { catalog, EFFORTS, FIRST, grants, isFree, keep, kept, level, nameOf, pacing, useCatalog, useChoice, useMind, type Choice, type Effort, type Mind } from './mind.ts';
75
+ export { DEV_HANDOFF, takeHandoff } from './handoff.ts';
76
+ export { useEar } from './voice.ts';
77
+ export { BARE, CHAT_MODES, DEV_MODES, gearOf, MODES, useGear, useLanguage, type Gear, type GearState, type Mode as GearMode } from './gear.ts';
78
+ export { skillsSaid, useCarry, type Carry } from './carry.tsx';
79
+ export { artifacts, blob, lead, renders, Reply, Served, speakable, speaker, type Artifact, type Listen } from './reply.tsx';
80
+ export { frames, Page, Panel, PanelToggle, type Kind, type PageProps, type PanelProps, type Suggestion } from './panel.tsx';
81
+ export { SideProvider, useSplit, type Split } from './side.tsx';
82
+ export { PrefsProvider } from './prefs.tsx';
83
+ export { deviceKey, friendly, heldNames, NAMES_KEY, rename, shellKey, useDeviceNames, type Names } from './names.ts';
84
+ export { DEV_MODE_EVENT, DEV_MODE_KEY, DEV_MODE_NOTE, formatDeviceLabel, getDevMode, setDevMode, useDevMode, type DeviceLabelOptions } from './dev-mode.ts';
85
+ export { plainPath } from './plain.ts';
86
+ export { Rename } from './ask.tsx';
87
+ export { kinds, Summary, useKinds, type Entry, type Section } from './summary.tsx';
88
+ /**
89
+ * The composer's plugins, the same in Chat and Dev: `usePlugins` answers those
90
+ * that run for this person, `shelf` is the `+` menu's Plugins shelf, and `prep`
91
+ * asks the ones that are on what a message carries (Deep research is the
92
+ * Research switch, `research`).
93
+ */
94
+ export { active, BUILD, merge, prep, shelf, usePlugins, research, type Plugins } from './plugins/index.ts';
95
+ export type { Composer as PluginComposer, Plugin, Prep, Turn } from './plugin.ts';
96
+ export { address, destination, located, name, PAGE, SEARCH, useDeck, useKey, usePanel, useShown, type Deck, type Tab, type Tabs } from './tabs.ts';
97
+ /**
98
+ * Up to three suggestions under the composer (above it on a phone), each from
99
+ * the person's own activity: `useSuggestions` reads and makes them (a model call
100
+ * when they are due; never signed out, never while the account's `suggestions`
101
+ * preference is off), `setSuggestions` is the one way to switch them, and
102
+ * `Suggestions` draws them with the sentence that says so and its Turn off. A
103
+ * `schedule` row's task is made by `book`, which asks through the host's confirm.
104
+ * The row is `Hint` here: `Suggestion` is the side panel's.
105
+ */
106
+ export { hand, setSuggestions, Suggestions, taken, useSuggestions, type Suggested, type SuggestionsProps, type Switch as SuggestionsSwitch } from './suggestions.tsx';
107
+ export { book } from './suggest.ts';
108
+ export type { Act, Suggestion as Hint } from './suggest.ts';
@@ -0,0 +1,99 @@
1
+ /**
2
+ * @hanzo/build — the builder as a component.
3
+ *
4
+ * Mount `<Builder host={…} />` under a gui root in a box with a height. The
5
+ * host says where the platform is, who is signed in, and how to move; the
6
+ * builder does everything else. hanzo.build hosts it whole. A host with a rail
7
+ * of its own mounts it with `rail={false}` and draws the builder's parts in that
8
+ * rail: its places (`nav`), its runs (`useSessions`, or `DevSection` for both),
9
+ * and at the foot the Slack card and the account menu (`Slack`, `Who`), under
10
+ * `HostProvider`. `Grip` (the kit's, passed on) sizes that rail.
11
+ *
12
+ * The side panel's column, for a host that draws it beside its own middle
13
+ * column (Chat): `useSplit`, `SideProvider` and `PrefsProvider` above both, so
14
+ * the width the person drags is kept in their preferences (side.tsx).
15
+ *
16
+ * The plan, once for every surface that shows one: `label` names it (`Max` with
17
+ * `20x` beside it), `useStanding` reads where an account stands, `Meter` is the
18
+ * block an account menu leads with, `Plan` the Usage view and `Credits` the
19
+ * Billing one. Each reads as a `Target`, so a host without a builder mounts it.
20
+ * The pure half — naming, shares, the banner's words — is also `@hanzo/build/plan`,
21
+ * which loads in Node without the components.
22
+ */
23
+ export { Builder } from './builder.js';
24
+ export { Library, Outputs, Preview, Thumb, want } from './library.js';
25
+ /** The Library's one reader, for a host that lists what a person made itself: `items(target, filter)` answers one page. */
26
+ export { items, SOURCE } from './api/library.js';
27
+ export { Scheduled, schedule } from './scheduled.js';
28
+ export { Editor } from './automations.js';
29
+ /**
30
+ * The screens a host draws in its own pane, each under `HostProvider` alone, so
31
+ * they sit inside the host's one look (theme and text size) and never under the
32
+ * builder's own `Look`: Library, Scheduled tasks and one task's `Editor` above,
33
+ * `Customize` (one tab), an agent's `Profile`, and the `Forge`'s screens
34
+ * (Projects, Issues, Sync, Connectors).
35
+ */
36
+ export { Customize } from './customize/index.js';
37
+ export { Profile } from './customize/agents.js';
38
+ export { Forge } from './forge.js';
39
+ export { library, nav, NEW, own, sections, tabs, useScheduled } from './nav.js';
40
+ export { MARKS } from './marks.js';
41
+ export { useFunds } from './mind.js';
42
+ export { DevSection, dot, DOTS, useSessions } from './section.js';
43
+ export { HostProvider } from './host.js';
44
+ export { Slack, useWho, Who } from './foot.js';
45
+ export { Grip } from '@hanzo/ui';
46
+ export { Gutter } from './gutter.js';
47
+ export { administers } from './claims.js';
48
+ export { Meter, Title } from './meter.js';
49
+ export { Plan } from './settings/plan.js';
50
+ export { Credits, SEPARATE } from './settings/credits.js';
51
+ export { useStanding, rows, left } from './standing.js';
52
+ export { kind, label, said, share, spent, ways, when } from './plan.js';
53
+ export { mark as markRun, marks as runMarks, useMarks as useRunMarks } from './runmeta.js';
54
+ export { cleanErrorText, groupSessions, isAlreadyRunningError, isSessionActive, isSessionLive, linkThread, resolveSessionState, threadChain, threadRoot, useThreadLinks, } from './thread.js';
55
+ export { cacheBustUrl, hasUnpublishedEdits, previewRevision, resolvePreviewSource } from './preview-url.js';
56
+ export { talks } from './api/talk.js';
57
+ export { detect } from './api/skills.js';
58
+ export { Roles } from './customize/roles.js';
59
+ export { recommend, WORK } from './roles.js';
60
+ export { href, parse, path, PLACES, route, SESSION, SLUG } from './route.js';
61
+ /**
62
+ * What Chat draws the same way (@hanzo/rooms imports these): the model and
63
+ * effort (`useMind`, one choice kept for both), the row under an answer
64
+ * (`Reply`), and the side panel (`Panel` over a `Deck` of tabs). The composer is
65
+ * @hanzo/ui/chat's, for Chat and Dev alike.
66
+ */
67
+ export { catalog, EFFORTS, FIRST, grants, isFree, keep, kept, level, nameOf, pacing, useCatalog, useChoice, useMind } from './mind.js';
68
+ export { DEV_HANDOFF, takeHandoff } from './handoff.js';
69
+ export { useEar } from './voice.js';
70
+ export { BARE, CHAT_MODES, DEV_MODES, gearOf, MODES, useGear, useLanguage } from './gear.js';
71
+ export { skillsSaid, useCarry } from './carry.js';
72
+ export { artifacts, blob, lead, renders, Reply, Served, speakable, speaker } from './reply.js';
73
+ export { frames, Page, Panel, PanelToggle } from './panel.js';
74
+ export { SideProvider, useSplit } from './side.js';
75
+ export { PrefsProvider } from './prefs.js';
76
+ export { deviceKey, friendly, heldNames, NAMES_KEY, rename, shellKey, useDeviceNames } from './names.js';
77
+ export { DEV_MODE_EVENT, DEV_MODE_KEY, DEV_MODE_NOTE, formatDeviceLabel, getDevMode, setDevMode, useDevMode } from './dev-mode.js';
78
+ export { plainPath } from './plain.js';
79
+ export { Rename } from './ask.js';
80
+ export { kinds, Summary, useKinds } from './summary.js';
81
+ /**
82
+ * The composer's plugins, the same in Chat and Dev: `usePlugins` answers those
83
+ * that run for this person, `shelf` is the `+` menu's Plugins shelf, and `prep`
84
+ * asks the ones that are on what a message carries (Deep research is the
85
+ * Research switch, `research`).
86
+ */
87
+ export { active, BUILD, merge, prep, shelf, usePlugins, research } from './plugins/index.js';
88
+ export { address, destination, located, name, PAGE, SEARCH, useDeck, useKey, usePanel, useShown } from './tabs.js';
89
+ /**
90
+ * Up to three suggestions under the composer (above it on a phone), each from
91
+ * the person's own activity: `useSuggestions` reads and makes them (a model call
92
+ * when they are due; never signed out, never while the account's `suggestions`
93
+ * preference is off), `setSuggestions` is the one way to switch them, and
94
+ * `Suggestions` draws them with the sentence that says so and its Turn off. A
95
+ * `schedule` row's task is made by `book`, which asks through the host's confirm.
96
+ * The row is `Hint` here: `Suggestion` is the side panel's.
97
+ */
98
+ export { hand, setSuggestions, Suggestions, taken, useSuggestions } from './suggestions.js';
99
+ export { book } from './suggest.js';
@@ -0,0 +1,34 @@
1
+ import { type Attached } from './tools.tsx';
2
+ /** One vocabulary for the mode, on New and in a workspace: English, marked (`phrase`), drawn through `t`. */
3
+ export declare const MODES: readonly [{
4
+ readonly id: 'build';
5
+ readonly label: string;
6
+ readonly hint: string;
7
+ }, {
8
+ readonly id: 'plan';
9
+ readonly label: string;
10
+ readonly hint: string;
11
+ }];
12
+ /**
13
+ * What was typed here and not sent, kept in this tab.
14
+ *
15
+ * Signing in leaves the page for hanzo.id and comes back (app/enter.ts), and the
16
+ * sentence is still in the composer after. A draft its person SENT while signed
17
+ * out is sent on the return: pressing Send was the ask, and the sign-in stood
18
+ * between it and the run. Only this page writes `sent`, so no link can start a
19
+ * run on somebody's behalf — an address carrying words only fills the composer.
20
+ *
21
+ * sessionStorage, because a draft belongs to the tab it was typed in and not to
22
+ * the next person at this browser; a browser that refuses storage keeps it for
23
+ * the life of the page, as before.
24
+ */
25
+ export interface Unsent {
26
+ draft: string;
27
+ files: Attached[];
28
+ sent?: boolean;
29
+ }
30
+ /** Hold what New has unsent, or forget it once there is nothing. */
31
+ export declare function hold(u: Unsent): void;
32
+ export declare function Landing({ onStarted }: {
33
+ onStarted: (session: string) => void;
34
+ }): import("react").JSX.Element;