@mcp-b/react-components 0.16.1 → 0.18.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/dist/{AgentActivity-BNUNrP9O.d.ts → AgentActivity-D2SHSGFX.d.ts} +1 -1
  2. package/dist/{AgentChat-CrlpbvQJ.d.ts → AgentChat-ClxViuUM.d.ts} +4 -29
  3. package/dist/AgentMessageParts-CyD2UB3V.d.ts +46 -0
  4. package/dist/AgentToolRunsContext-BVe4stgw.d.ts +21 -0
  5. package/dist/{Button-FX_hpqxm.d.ts → Button-DLGzHsjc.d.ts} +13 -7
  6. package/dist/{CodeBlock-BmB4Xaqq.js → CodeBlock-Bfp5PAg3.js} +9 -6
  7. package/dist/{CodeBlock-BRajW4QU.d.ts → CodeBlock-gV4kZeCI.d.ts} +2 -9
  8. package/dist/Collapsible-N64ASIQr.d.ts +119 -0
  9. package/dist/{Combobox-B9Fcd6q-.d.ts → Combobox-CYc37s5l.d.ts} +11 -33
  10. package/dist/{FileTree-CkVbIMWV.js → FileTree-3zYtrddG.js} +46 -20
  11. package/dist/{Menu-Bgu-ufb5.d.ts → Menu-L6MZm-7N.d.ts} +15 -56
  12. package/dist/{Message-BkMdE3bS.js → Message-BXtmfc9Q.js} +13 -20
  13. package/dist/{ModelSelector-SlJNgwKY.js → ModelSelector-Cqw_qrUG.js} +18 -25
  14. package/dist/{PromptInput-BWTuXMOD.d.ts → PromptInput-Bdh9pqlo.d.ts} +41 -71
  15. package/dist/{ResponsiveSidebarShell-Dd9DCcBT.d.ts → ResponsiveSidebarShell-CsAh4NyL.d.ts} +1 -0
  16. package/dist/{Select-BeEsefzh.d.ts → Select-B_13gg_J.d.ts} +16 -44
  17. package/dist/{Tabs-3Zc4tb9D.d.ts → Tabs-ColWK-XA.d.ts} +14 -20
  18. package/dist/{ThinkChat-CzC-zNGA.js → ThinkChat-15EhfvYJ.js} +123 -73
  19. package/dist/{ThinkChatActivity-BFQnb2ct.d.ts → ThinkChatActivity-Bzot45kX.d.ts} +9 -4
  20. package/dist/{ThinkChatActivitySummary-BPmu9a-c.d.ts → ThinkChatActivitySummary-D1xOrNrq.d.ts} +1 -1
  21. package/dist/{ThinkChatContext-C3Eb1Xpi.d.ts → ThinkChatContext-DrsZqdaO.d.ts} +1 -1
  22. package/dist/ThinkRecoveryNotice-DFIcG9UX.d.ts +19 -0
  23. package/dist/{Toggle-CAAlNl-M.d.ts → Toggle-JKZ43D5S.d.ts} +2 -2
  24. package/dist/{ToggleGroup-8hPv-b69.d.ts → ToggleGroup-DNd6cDJZ.d.ts} +4 -5
  25. package/dist/Workspace-Jez8ffUj.d.ts +274 -0
  26. package/dist/WorkspaceExplorer-B9dQWNVK.d.ts +32 -0
  27. package/dist/{WorkspaceFile-DOZkPwzu.d.ts → WorkspaceFile-CzyHnESE.d.ts} +1 -1
  28. package/dist/{WorkspaceFileView-rSN_yT0L.js → WorkspaceFileView-C68Ub8S8.js} +121 -128
  29. package/dist/{WorkspaceLink-DIPbXrUM.js → WorkspaceLink-BYYeTQLf.js} +20 -55
  30. package/dist/{WorkspaceLink-DK1DWMHe.d.ts → WorkspaceLink-O-EBKUJ8.d.ts} +6 -9
  31. package/dist/class-names-BiMDVpUo.js +14 -0
  32. package/dist/components/Accordion.d.ts +5 -15
  33. package/dist/components/Accordion.js +16 -10
  34. package/dist/components/Activity.d.ts +5 -10
  35. package/dist/components/Activity.js +2 -2
  36. package/dist/components/AgentActivity.d.ts +1 -1
  37. package/dist/components/AgentActivity.js +4 -5
  38. package/dist/components/AgentActivityPreview.d.ts +9 -9
  39. package/dist/components/AgentActivityPreview.js +8 -12
  40. package/dist/components/AgentAttention.d.ts +2 -2
  41. package/dist/components/AgentAttention.js +1 -1
  42. package/dist/components/AgentChat.d.ts +2 -2
  43. package/dist/components/AgentChat.js +113 -218
  44. package/dist/components/AgentChatMessageEditor.js +3 -3
  45. package/dist/components/AgentChatTurnError.js +2 -2
  46. package/dist/components/AgentConnection.js +4 -4
  47. package/dist/components/AgentMessageParts.d.ts +2 -0
  48. package/dist/components/AgentMessageParts.js +119 -0
  49. package/dist/components/AgentToolDetail.d.ts +57 -0
  50. package/dist/components/AgentToolDetail.js +100 -0
  51. package/dist/components/AgentToolRunsContext.d.ts +2 -0
  52. package/dist/components/AgentToolRunsContext.js +16 -0
  53. package/dist/components/AlertDialog.d.ts +7 -19
  54. package/dist/components/AlertDialog.js +21 -32
  55. package/dist/components/AppTopBar.d.ts +28 -8
  56. package/dist/components/AppTopBar.js +36 -12
  57. package/dist/components/Approval.d.ts +102 -0
  58. package/dist/components/Approval.js +227 -0
  59. package/dist/components/Artifact.d.ts +3 -5
  60. package/dist/components/Artifact.js +7 -5
  61. package/dist/components/Autocomplete.d.ts +11 -33
  62. package/dist/components/Autocomplete.js +23 -30
  63. package/dist/components/Avatar.d.ts +4 -12
  64. package/dist/components/Avatar.js +13 -12
  65. package/dist/components/Badge.js +3 -0
  66. package/dist/components/BrowserLiveView.js +27 -12
  67. package/dist/components/BrowserReplay.js +4 -3
  68. package/dist/components/BrowserRunPanel.js +58 -78
  69. package/dist/components/Button.d.ts +1 -1
  70. package/dist/components/Button.js +14 -16
  71. package/dist/components/Card.d.ts +7 -8
  72. package/dist/components/Card.js +19 -10
  73. package/dist/components/ChainOfThought.d.ts +5 -11
  74. package/dist/components/ChainOfThought.js +3 -2
  75. package/dist/components/ChatGptSignInScreen.js +8 -8
  76. package/dist/components/Checkbox.d.ts +2 -4
  77. package/dist/components/Checkbox.js +6 -5
  78. package/dist/components/CheckboxGroup.d.ts +1 -3
  79. package/dist/components/CheckboxGroup.js +15 -14
  80. package/dist/components/Checkpoint.d.ts +64 -0
  81. package/dist/components/Checkpoint.js +63 -0
  82. package/dist/components/CodeBlock.d.ts +1 -1
  83. package/dist/components/CodeBlock.js +1 -1
  84. package/dist/components/CodexModelSelector.d.ts +1 -1
  85. package/dist/components/CodexModelSelector.js +2 -2
  86. package/dist/components/Collapsible.d.ts +1 -124
  87. package/dist/components/Collapsible.js +7 -10
  88. package/dist/components/Combobox.d.ts +1 -1
  89. package/dist/components/Combobox.js +23 -30
  90. package/dist/components/Commit.d.ts +5 -11
  91. package/dist/components/Commit.js +6 -5
  92. package/dist/components/Context.js +1 -1
  93. package/dist/components/ContextMenu.d.ts +21 -37
  94. package/dist/components/ContextMenu.js +34 -51
  95. package/dist/components/Conversation.d.ts +3 -5
  96. package/dist/components/Conversation.js +5 -4
  97. package/dist/components/DescriptionListParts.js +1 -1
  98. package/dist/components/Dialog.d.ts +6 -17
  99. package/dist/components/Dialog.js +17 -24
  100. package/dist/components/EnvironmentVariables.d.ts +1 -1
  101. package/dist/components/EnvironmentVariables.js +4 -3
  102. package/dist/components/Field.d.ts +17 -20
  103. package/dist/components/Field.js +20 -17
  104. package/dist/components/Fieldset.d.ts +2 -7
  105. package/dist/components/Fieldset.js +7 -6
  106. package/dist/components/FileTree.d.ts +6 -0
  107. package/dist/components/FileTree.js +1 -1
  108. package/dist/components/Form.d.ts +1 -4
  109. package/dist/components/Form.js +3 -2
  110. package/dist/components/GithubMotionMark.js +1 -1
  111. package/dist/components/IconButton.d.ts +2 -3
  112. package/dist/components/IconButton.js +2 -1
  113. package/dist/components/InlineCitation.d.ts +66 -0
  114. package/dist/components/InlineCitation.js +142 -0
  115. package/dist/components/Input.d.ts +1 -4
  116. package/dist/components/Input.js +3 -2
  117. package/dist/components/Marker.js +1 -1
  118. package/dist/components/McpConnectionRequest.js +2 -2
  119. package/dist/components/McpServerPicker.d.ts +1 -1
  120. package/dist/components/McpServerPicker.js +6 -5
  121. package/dist/components/MediaPreviewCard.d.ts +103 -0
  122. package/dist/components/MediaPreviewCard.js +193 -0
  123. package/dist/components/Menu.d.ts +1 -1
  124. package/dist/components/Menu.js +33 -52
  125. package/dist/components/Menubar.d.ts +22 -43
  126. package/dist/components/Menubar.js +36 -53
  127. package/dist/components/Message.d.ts +7 -7
  128. package/dist/components/Message.js +1 -1
  129. package/dist/components/MessageScroller.d.ts +2 -2
  130. package/dist/components/MessageScroller.js +6 -5
  131. package/dist/components/Meter.d.ts +5 -20
  132. package/dist/components/Meter.js +11 -10
  133. package/dist/components/ModelSelector.d.ts +6 -9
  134. package/dist/components/ModelSelector.js +1 -1
  135. package/dist/components/NavigationMenu.d.ts +11 -33
  136. package/dist/components/NavigationMenu.js +23 -30
  137. package/dist/components/NumberField.d.ts +6 -24
  138. package/dist/components/NumberField.js +13 -12
  139. package/dist/components/Plan.d.ts +103 -0
  140. package/dist/components/Plan.js +113 -0
  141. package/dist/components/Popover.d.ts +9 -36
  142. package/dist/components/Popover.js +23 -34
  143. package/dist/components/PreviewCard.d.ts +6 -24
  144. package/dist/components/PreviewCard.js +13 -24
  145. package/dist/components/PricingBillingToggle.js +1 -1
  146. package/dist/components/PricingFAQ.js +1 -1
  147. package/dist/components/PricingPage.js +2 -1
  148. package/dist/components/PricingPlanCard.js +5 -4
  149. package/dist/components/PricingUsageCalculator.js +3 -3
  150. package/dist/components/Progress.d.ts +3 -8
  151. package/dist/components/Progress.js +7 -10
  152. package/dist/components/PromptInput.d.ts +2 -2
  153. package/dist/components/PromptInput.js +83 -218
  154. package/dist/components/Queue.d.ts +7 -17
  155. package/dist/components/Queue.js +2 -3
  156. package/dist/components/RadioGroup.d.ts +3 -8
  157. package/dist/components/RadioGroup.js +7 -10
  158. package/dist/components/Reasoning.d.ts +4 -8
  159. package/dist/components/Reasoning.js +3 -6
  160. package/dist/components/ResizableSidePanel.js +2 -2
  161. package/dist/components/ResponsiveSidebarShell.d.ts +1 -1
  162. package/dist/components/ResponsiveSidebarShell.js +18 -11
  163. package/dist/components/ScrollArea.d.ts +5 -20
  164. package/dist/components/ScrollArea.js +12 -10
  165. package/dist/components/SearchField.d.ts +43 -0
  166. package/dist/components/SearchField.js +52 -0
  167. package/dist/components/Select.d.ts +1 -1
  168. package/dist/components/Select.js +33 -57
  169. package/dist/components/Separator.d.ts +1 -5
  170. package/dist/components/Separator.js +3 -6
  171. package/dist/components/Slider.d.ts +6 -19
  172. package/dist/components/Slider.js +15 -14
  173. package/dist/components/Sources.d.ts +4 -9
  174. package/dist/components/Sources.js +3 -2
  175. package/dist/components/Stepper.js +16 -9
  176. package/dist/components/SubagentRunDetails.js +1 -1
  177. package/dist/components/SubagentRunIndicator.js +2 -2
  178. package/dist/components/SubagentRunList.d.ts +3 -5
  179. package/dist/components/SubagentRunList.js +3 -5
  180. package/dist/components/SubagentRunSelector.d.ts +9 -22
  181. package/dist/components/SubagentRunSelector.js +29 -31
  182. package/dist/components/Switch.d.ts +4 -7
  183. package/dist/components/Switch.js +6 -10
  184. package/dist/components/Tabs.d.ts +2 -2
  185. package/dist/components/Tabs.js +21 -18
  186. package/dist/components/Task.d.ts +4 -9
  187. package/dist/components/Task.js +4 -3
  188. package/dist/components/Terminal.d.ts +3 -4
  189. package/dist/components/Terminal.js +5 -4
  190. package/dist/components/TestResults.d.ts +4 -9
  191. package/dist/components/TestResults.js +11 -6
  192. package/dist/components/Textarea.js +1 -1
  193. package/dist/components/ThemeModeControl.js +1 -1
  194. package/dist/components/ThinkChat.d.ts +45 -22
  195. package/dist/components/ThinkChat.js +7 -5
  196. package/dist/components/ThinkChatActivity.d.ts +2 -2
  197. package/dist/components/ThinkChatActivity.js +24 -7
  198. package/dist/components/ThinkChatActivitySummary.d.ts +1 -1
  199. package/dist/components/ThinkChatActivitySummary.js +7 -3
  200. package/dist/components/ThinkChatContext.d.ts +1 -1
  201. package/dist/components/ThinkChatToolPanels.js +27 -17
  202. package/dist/components/ThinkExecutionDetail.js +2 -2
  203. package/dist/components/ThinkExecutionStatus.js +2 -2
  204. package/dist/components/ThinkExecutionWorkbench.d.ts +30 -8
  205. package/dist/components/ThinkExecutionWorkbench.js +70 -134
  206. package/dist/components/ThinkFullApp.d.ts +40 -15
  207. package/dist/components/ThinkFullApp.js +193 -117
  208. package/dist/components/ThinkFullAppViewSwitch.d.ts +1 -1
  209. package/dist/components/ThinkFullAppViewSwitch.js +2 -2
  210. package/dist/components/ThinkPendingApproval.d.ts +60 -0
  211. package/dist/components/ThinkPendingApproval.js +99 -0
  212. package/dist/components/ThinkRecoveryNotice.d.ts +2 -0
  213. package/dist/components/ThinkRecoveryNotice.js +46 -0
  214. package/dist/components/ThinkRoutine.js +1 -0
  215. package/dist/components/ThinkRoutineBrowser.d.ts +17 -9
  216. package/dist/components/ThinkRoutineBrowser.js +37 -44
  217. package/dist/components/ThinkRoutineDetail.d.ts +5 -2
  218. package/dist/components/ThinkRoutineDetail.js +4 -4
  219. package/dist/components/ThinkRoutineForm.d.ts +3 -2
  220. package/dist/components/ThinkRoutineForm.js +11 -10
  221. package/dist/components/ThinkRoutineLibrary.d.ts +27 -25
  222. package/dist/components/ThinkRoutineLibrary.js +104 -80
  223. package/dist/components/ThinkRoutineRuns.d.ts +3 -2
  224. package/dist/components/ThinkRoutineRuns.js +31 -24
  225. package/dist/components/ThinkThreadPicker.d.ts +17 -11
  226. package/dist/components/ThinkThreadPicker.js +163 -39
  227. package/dist/components/ThinkThreadShell.d.ts +1 -1
  228. package/dist/components/Toast.d.ts +7 -28
  229. package/dist/components/Toast.js +15 -14
  230. package/dist/components/Toggle.d.ts +1 -1
  231. package/dist/components/Toggle.js +10 -8
  232. package/dist/components/ToggleGroup.d.ts +1 -1
  233. package/dist/components/ToggleGroup.js +21 -26
  234. package/dist/components/ToolApproval.d.ts +28 -0
  235. package/dist/components/ToolApproval.js +35 -0
  236. package/dist/components/ToolInvocation.d.ts +26 -0
  237. package/dist/components/ToolInvocation.js +72 -0
  238. package/dist/components/Toolbar.d.ts +6 -24
  239. package/dist/components/Toolbar.js +13 -12
  240. package/dist/components/Tooltip.d.ts +11 -10
  241. package/dist/components/Tooltip.js +17 -11
  242. package/dist/components/TransitionSurface.d.ts +27 -0
  243. package/dist/components/TransitionSurface.js +20 -0
  244. package/dist/components/WebPreview.d.ts +6 -7
  245. package/dist/components/WebPreview.js +70 -55
  246. package/dist/components/Workspace.d.ts +2 -2
  247. package/dist/components/Workspace.js +361 -346
  248. package/dist/components/WorkspaceBrowser.d.ts +4 -7
  249. package/dist/components/WorkspaceBrowser.js +16 -26
  250. package/dist/components/WorkspaceExplorer.d.ts +5 -33
  251. package/dist/components/WorkspaceExplorer.js +19 -32
  252. package/dist/components/WorkspaceFile.d.ts +1 -1
  253. package/dist/components/WorkspaceFileView.d.ts +14 -2
  254. package/dist/components/WorkspaceFileView.js +1 -1
  255. package/dist/components/WorkspaceHeader.d.ts +0 -8
  256. package/dist/components/WorkspaceHeader.js +3 -15
  257. package/dist/components/WorkspaceLink.d.ts +1 -1
  258. package/dist/components/WorkspaceLink.js +1 -1
  259. package/dist/components/icons.d.ts +2 -2
  260. package/dist/components/icons.js +2 -2
  261. package/dist/{copy-button-DtPMgN7e.d.ts → copy-button-D7aAYA-2.d.ts} +2 -3
  262. package/dist/{copy-button-Dejn5heL.js → copy-button-DeK6KXEV.js} +3 -2
  263. package/dist/{icons-CpfUer49.js → icons-CQJ-aMnI.js} +7 -3
  264. package/dist/{icons-GQd1xF4e.d.ts → icons-CYXmvKlJ.d.ts} +22 -2
  265. package/dist/navigation-link-Cob7KBlM.js +19 -0
  266. package/dist/styles/accordion.css +4 -19
  267. package/dist/styles/activity.css +48 -56
  268. package/dist/styles/agent-activity-preview.css +6 -0
  269. package/dist/styles/agent-chat.css +14 -63
  270. package/dist/styles/agent-connection.css +0 -12
  271. package/dist/styles/agent-tool-detail.css +54 -0
  272. package/dist/styles/alert-dialog.css +16 -18
  273. package/dist/styles/app-top-bar.css +17 -9
  274. package/dist/styles/approval.css +177 -0
  275. package/dist/styles/artifact.css +6 -18
  276. package/dist/styles/autocomplete.css +2 -1
  277. package/dist/styles/avatar.css +35 -30
  278. package/dist/styles/badge.css +10 -10
  279. package/dist/styles/base-ui-motion.css +94 -39
  280. package/dist/styles/browser-control-overlay.css +0 -1
  281. package/dist/styles/browser-live-view.css +39 -22
  282. package/dist/styles/browser-replay.css +1 -1
  283. package/dist/styles/browser-run-panel.css +13 -6
  284. package/dist/styles/button.css +36 -33
  285. package/dist/styles/card.css +5 -6
  286. package/dist/styles/chain-of-thought.css +22 -24
  287. package/dist/styles/checkbox.css +18 -5
  288. package/dist/styles/checkpoint.css +58 -0
  289. package/dist/styles/codex-model-selector.css +3 -7
  290. package/dist/styles/collapsible.css +10 -10
  291. package/dist/styles/combobox.css +4 -3
  292. package/dist/styles/commit.css +19 -39
  293. package/dist/styles/composition-motion.css +83 -0
  294. package/dist/styles/context-menu.css +3 -11
  295. package/dist/styles/context.css +11 -10
  296. package/dist/styles/conversation.css +18 -23
  297. package/dist/styles/dialog.css +15 -15
  298. package/dist/styles/environment-variables.css +0 -13
  299. package/dist/styles/field.css +32 -12
  300. package/dist/styles/file-tree.css +66 -22
  301. package/dist/styles/form.css +1 -1
  302. package/dist/styles/index.css +13 -4
  303. package/dist/styles/inline-citation.css +107 -0
  304. package/dist/styles/input.css +2 -2
  305. package/dist/styles/marker.css +14 -13
  306. package/dist/styles/mcp-server-picker.css +20 -47
  307. package/dist/styles/media-preview-card.css +160 -0
  308. package/dist/styles/menu.css +11 -40
  309. package/dist/styles/menubar.css +12 -19
  310. package/dist/styles/message-scroller.css +0 -12
  311. package/dist/styles/message.css +25 -31
  312. package/dist/styles/meter.css +2 -2
  313. package/dist/styles/model-selector.css +16 -34
  314. package/dist/styles/motion-reduction.css +29 -0
  315. package/dist/styles/navigation-menu.css +14 -30
  316. package/dist/styles/number-field.css +22 -4
  317. package/dist/styles/plan.css +132 -0
  318. package/dist/styles/popover.css +15 -52
  319. package/dist/styles/preview-card.css +2 -32
  320. package/dist/styles/progress.css +8 -3
  321. package/dist/styles/prompt-input.css +76 -269
  322. package/dist/styles/queue.css +48 -32
  323. package/dist/styles/radio.css +19 -12
  324. package/dist/styles/reasoning.css +2 -1
  325. package/dist/styles/recipes.css +207 -26
  326. package/dist/styles/resizable-side-panel.css +4 -10
  327. package/dist/styles/responsive-sidebar-shell.css +32 -34
  328. package/dist/styles/scroll-area.css +32 -15
  329. package/dist/styles/search-field.css +21 -0
  330. package/dist/styles/select.css +19 -12
  331. package/dist/styles/slider.css +25 -29
  332. package/dist/styles/sources.css +3 -11
  333. package/dist/styles/stepper.css +36 -26
  334. package/dist/styles/subagent-run.css +13 -71
  335. package/dist/styles/switch.css +32 -29
  336. package/dist/styles/tabs.css +79 -23
  337. package/dist/styles/task.css +11 -23
  338. package/dist/styles/test-results.css +29 -36
  339. package/dist/styles/theme-mode-control.css +8 -0
  340. package/dist/styles/think-execution-workbench.css +18 -15
  341. package/dist/styles/think-full-app.css +51 -100
  342. package/dist/styles/think-routine-library.css +51 -40
  343. package/dist/styles/think-thread-picker.css +207 -50
  344. package/dist/styles/toast.css +48 -34
  345. package/dist/styles/toggle-group.css +2 -36
  346. package/dist/styles/toggle.css +29 -5
  347. package/dist/styles/toolbar.css +25 -27
  348. package/dist/styles/tooltip.css +2 -32
  349. package/dist/styles/transition-surface.css +55 -0
  350. package/dist/styles/utilities.css +31 -0
  351. package/dist/styles/web-preview.css +0 -21
  352. package/dist/styles/workspace-explorer.css +104 -99
  353. package/dist/summarize-tool-input-CqTcGRYy.js +15 -0
  354. package/dist/think-agent-Cip5KAPj.d.ts +7 -0
  355. package/dist/utils/codex-model-catalog.d.ts +4 -4
  356. package/dist/utils/mcp-server-catalog.d.ts +132 -0
  357. package/dist/utils/mcp-server-catalog.js +90 -0
  358. package/dist/utils/structured-code.d.ts +1 -1
  359. package/dist/workspace-path-L_KmjRjq.js +26 -0
  360. package/package.json +14 -9
  361. package/dist/Workspace-D39LxGvP.d.ts +0 -62
  362. package/dist/class-names-9UtZwb0J.js +0 -12
  363. package/dist/components/AppFrame.d.ts +0 -24
  364. package/dist/components/AppFrame.js +0 -25
  365. package/dist/components/Shell.d.ts +0 -163
  366. package/dist/components/Shell.js +0 -137
  367. package/dist/components/SubagentRun.d.ts +0 -86
  368. package/dist/components/SubagentRun.js +0 -108
  369. package/dist/styles/app-frame.css +0 -15
  370. package/dist/styles/shell.css +0 -122
  371. package/dist/summarize-tool-input-BUJsENSn.js +0 -12
@@ -3,22 +3,30 @@ import * as React from "react";
3
3
 
4
4
  //#region src/components/ThinkRoutineBrowser.d.ts
5
5
  type ThinkRoutineFilter = "all" | "active" | "paused";
6
- interface ThinkRoutineBrowserProps extends Omit<React.HTMLAttributes<HTMLElement>, "onSelect"> {
7
- routines: readonly ThinkRoutine[];
8
- selectedRoutineId?: string;
9
- onSelectedRoutineIdChange?: (routineId: string) => void;
10
- onCreateRoutine?: () => void;
6
+ interface ThinkRoutineBrowserProps<TRoutine extends ThinkRoutine = ThinkRoutine> extends Omit<React.HTMLAttributes<HTMLElement>, "onSelect"> {
7
+ routines: readonly TRoutine[];
8
+ /** Routine selected by the current application route. */
9
+ selectedRoutineId?: string | null;
10
+ showOwner?: boolean;
11
+ /** App-authored TanStack Router Link for each durable routine destination. */
12
+ renderRoutineLink: (routine: TRoutine) => React.ReactElement;
13
+ /** App-authored TanStack Router Link to the routine creation route. */
14
+ createRoutineLink?: React.ReactElement;
15
+ /** Optional UI-only response after a routine link is activated. */
16
+ onRoutineLinkClick?: React.MouseEventHandler<HTMLAnchorElement>;
11
17
  }
12
18
  /** Searchable, filterable navigation for an app-owned collection of Think routines. */
13
- declare function ThinkRoutineBrowser({
19
+ declare function ThinkRoutineBrowser<TRoutine extends ThinkRoutine = ThinkRoutine>({
14
20
  className,
15
21
  routines,
16
22
  selectedRoutineId,
17
- onSelectedRoutineIdChange,
18
- onCreateRoutine,
23
+ showOwner,
24
+ renderRoutineLink,
25
+ createRoutineLink,
26
+ onRoutineLinkClick,
19
27
  ref,
20
28
  ...props
21
- }: ThinkRoutineBrowserProps & {
29
+ }: ThinkRoutineBrowserProps<TRoutine> & {
22
30
  ref?: React.Ref<HTMLElement>;
23
31
  }): React.JSX.Element;
24
32
  //#endregion
@@ -1,8 +1,9 @@
1
- import { t as cx } from "../class-names-9UtZwb0J.js";
2
- import { F as PlusIcon, R as SearchIcon } from "../icons-CpfUer49.js";
3
- import { Button } from "./Button.js";
1
+ import { t as cx } from "../class-names-BiMDVpUo.js";
2
+ import { B as PlusIcon } from "../icons-CQJ-aMnI.js";
3
+ import { t as NavigationLink } from "../navigation-link-Cob7KBlM.js";
4
+ import { buttonVariants } from "./Button.js";
4
5
  import { Tooltip } from "./Tooltip.js";
5
- import { Field } from "./Field.js";
6
+ import { SearchField } from "./SearchField.js";
6
7
  import { ToggleGroup } from "./ToggleGroup.js";
7
8
  import { getThinkRoutineNextRun } from "./ThinkRoutine.js";
8
9
  import * as React from "react";
@@ -18,23 +19,17 @@ function filterRoutines(routines, filter, query) {
18
19
  });
19
20
  }
20
21
  /** Searchable, filterable navigation for an app-owned collection of Think routines. */
21
- function ThinkRoutineBrowser({ className, routines, selectedRoutineId, onSelectedRoutineIdChange, onCreateRoutine, ref, ...props }) {
22
+ function ThinkRoutineBrowser({ className, routines, selectedRoutineId, showOwner = true, renderRoutineLink, createRoutineLink, onRoutineLinkClick, ref, ...props }) {
22
23
  const [filter, setFilter] = React.useState("all");
23
24
  const [query, setQuery] = React.useState("");
24
25
  const visibleRoutines = filterRoutines(routines, filter, query);
25
- const retainVisibleSelection = (nextVisibleRoutines) => {
26
- if (selectedRoutineId && !nextVisibleRoutines.some((routine) => routine.id === selectedRoutineId)) {
27
- const nextSelectedId = nextVisibleRoutines[0]?.id;
28
- if (nextSelectedId) onSelectedRoutineIdChange?.(nextSelectedId);
29
- }
30
- };
31
26
  return /* @__PURE__ */ jsxs("nav", {
32
27
  ref,
33
28
  className: cx("think-routine-browser", "think-routine-library__browser", className),
34
29
  ...props,
35
30
  children: [
36
31
  /* @__PURE__ */ jsx("h2", {
37
- className: "think-routine-library__title",
32
+ className: "think-routine-library__title sigvelo-visually-hidden",
38
33
  children: "Schedules"
39
34
  }),
40
35
  /* @__PURE__ */ jsxs("div", {
@@ -48,7 +43,6 @@ function ThinkRoutineBrowser({ className, routines, selectedRoutineId, onSelecte
48
43
  const nextFilter = nextValue[0];
49
44
  if (!nextFilter) return;
50
45
  setFilter(nextFilter);
51
- retainVisibleSelection(filterRoutines(routines, nextFilter, query));
52
46
  },
53
47
  children: [
54
48
  "all",
@@ -59,14 +53,16 @@ function ThinkRoutineBrowser({ className, routines, selectedRoutineId, onSelecte
59
53
  value,
60
54
  children: value.charAt(0).toUpperCase() + value.slice(1)
61
55
  }, value))
62
- }), onCreateRoutine ? /* @__PURE__ */ jsxs(Tooltip.Root, { children: [/* @__PURE__ */ jsx(Tooltip.Trigger, {
63
- render: /* @__PURE__ */ jsx(Button, {
64
- type: "button",
65
- variant: "ghost",
66
- color: "neutral",
67
- size: "icon-sm",
68
- "aria-label": "New schedule",
69
- onClick: onCreateRoutine
56
+ }), createRoutineLink ? /* @__PURE__ */ jsxs(Tooltip.Root, { children: [/* @__PURE__ */ jsx(Tooltip.Trigger, {
57
+ render: /* @__PURE__ */ jsx(NavigationLink, {
58
+ render: createRoutineLink,
59
+ className: buttonVariants({
60
+ variant: "ghost",
61
+ color: "neutral",
62
+ size: "sm"
63
+ }),
64
+ "data-icon-only": "",
65
+ "aria-label": "New schedule"
70
66
  }),
71
67
  children: /* @__PURE__ */ jsx(PlusIcon, {})
72
68
  }), /* @__PURE__ */ jsx(Tooltip.Portal, { children: /* @__PURE__ */ jsx(Tooltip.Positioner, {
@@ -75,26 +71,20 @@ function ThinkRoutineBrowser({ className, routines, selectedRoutineId, onSelecte
75
71
  children: /* @__PURE__ */ jsx(Tooltip.Popup, { children: "Create schedule" })
76
72
  }) })] }) : null]
77
73
  }),
78
- /* @__PURE__ */ jsxs(Field.Root, {
74
+ /* @__PURE__ */ jsxs(SearchField.Root, {
79
75
  className: "think-routine-library__search",
80
76
  name: "routine-search",
81
- children: [/* @__PURE__ */ jsx(Field.Label, {
82
- className: "think-routine-library__title",
77
+ children: [/* @__PURE__ */ jsx(SearchField.Label, {
78
+ className: "think-routine-library__title sigvelo-visually-hidden",
83
79
  children: "Search schedules"
84
- }), /* @__PURE__ */ jsxs("div", { children: [/* @__PURE__ */ jsx(SearchIcon, {}), /* @__PURE__ */ jsx(Field.Control, {
85
- className: "think-routine-browser__search-control",
86
- type: "search",
80
+ }), /* @__PURE__ */ jsx(SearchField.Control, {
87
81
  value: query,
88
82
  placeholder: "Search schedules",
89
- onChange: (event) => {
90
- const nextQuery = event.currentTarget.value;
91
- setQuery(nextQuery);
92
- retainVisibleSelection(filterRoutines(routines, filter, nextQuery));
93
- }
94
- })] })]
83
+ onChange: (event) => setQuery(event.currentTarget.value)
84
+ })]
95
85
  }),
96
86
  /* @__PURE__ */ jsxs("p", {
97
- className: "think-routine-library__status",
87
+ className: "think-routine-library__status sigvelo-visually-hidden",
98
88
  role: "status",
99
89
  "aria-atomic": "true",
100
90
  children: [
@@ -111,14 +101,16 @@ function ThinkRoutineBrowser({ className, routines, selectedRoutineId, onSelecte
111
101
  const selected = routine.id === selectedRoutineId;
112
102
  return /* @__PURE__ */ jsx("li", {
113
103
  "data-selected": selected || void 0,
114
- children: /* @__PURE__ */ jsxs(Button, {
115
- className: "think-routine-browser__routine",
116
- type: "button",
117
- variant: "ghost",
118
- color: "neutral",
119
- size: "sm",
104
+ children: /* @__PURE__ */ jsxs(NavigationLink, {
105
+ render: renderRoutineLink(routine),
106
+ className: buttonVariants({
107
+ variant: "ghost",
108
+ color: "neutral",
109
+ size: "sm",
110
+ className: "think-routine-browser__routine"
111
+ }),
120
112
  "aria-current": selected ? "page" : void 0,
121
- onClick: () => onSelectedRoutineIdChange?.(routine.id),
113
+ onClick: onRoutineLinkClick,
122
114
  children: [
123
115
  /* @__PURE__ */ jsx("span", {
124
116
  className: "think-routine-library__routine-status",
@@ -126,7 +118,7 @@ function ThinkRoutineBrowser({ className, routines, selectedRoutineId, onSelecte
126
118
  "aria-hidden": "true"
127
119
  }),
128
120
  /* @__PURE__ */ jsx("span", {
129
- className: "think-routine-library__title",
121
+ className: "think-routine-library__title sigvelo-visually-hidden",
130
122
  children: routine.enabled ? "Active" : "Paused"
131
123
  }),
132
124
  /* @__PURE__ */ jsxs("span", {
@@ -135,8 +127,9 @@ function ThinkRoutineBrowser({ className, routines, selectedRoutineId, onSelecte
135
127
  /* @__PURE__ */ jsx("strong", { children: routine.name }),
136
128
  /* @__PURE__ */ jsx("span", { children: routine.task.schedule }),
137
129
  /* @__PURE__ */ jsxs("small", { children: [
138
- routine.owner.name,
139
- " · Next ",
130
+ showOwner ? `${routine.owner.name} · ` : null,
131
+ "Next",
132
+ " ",
140
133
  getThinkRoutineNextRun(routine)
141
134
  ] })
142
135
  ]
@@ -5,16 +5,19 @@ import * as React from "react";
5
5
  interface ThinkRoutineDetailProps<TRoutine extends ThinkRoutine = ThinkRoutine> extends React.HTMLAttributes<HTMLElement> {
6
6
  routine: TRoutine;
7
7
  busy?: boolean;
8
+ showOwner?: boolean;
8
9
  onEnabledChange?: (enabled: boolean) => void;
9
- onRunSelect?: (run: ThinkRoutineRunOf<TRoutine>) => void;
10
+ /** App-authored TanStack Router Link for each recent execution. */
11
+ renderRunLink?: (run: ThinkRoutineRunOf<TRoutine>) => React.ReactElement;
10
12
  }
11
13
  /** Readable definition, schedule settings, and recent executions for one routine. */
12
14
  declare function ThinkRoutineDetail<TRoutine extends ThinkRoutine = ThinkRoutine>({
13
15
  busy,
14
16
  className,
15
17
  routine,
18
+ showOwner,
16
19
  onEnabledChange,
17
- onRunSelect,
20
+ renderRunLink,
18
21
  ref,
19
22
  ...props
20
23
  }: ThinkRoutineDetailProps<TRoutine> & {
@@ -1,4 +1,4 @@
1
- import { t as cx } from "../class-names-9UtZwb0J.js";
1
+ import { t as cx } from "../class-names-BiMDVpUo.js";
2
2
  import { Badge } from "./Badge.js";
3
3
  import { Switch } from "./Switch.js";
4
4
  import { getThinkRoutineNextRun } from "./ThinkRoutine.js";
@@ -10,7 +10,7 @@ function taskInstructions(routine) {
10
10
  return typeof routine.task.prompt === "string" ? routine.task.prompt : "Runs an app-defined scheduled handler.";
11
11
  }
12
12
  /** Readable definition, schedule settings, and recent executions for one routine. */
13
- function ThinkRoutineDetail({ busy = false, className, routine, onEnabledChange, onRunSelect, ref, ...props }) {
13
+ function ThinkRoutineDetail({ busy = false, className, routine, showOwner = true, onEnabledChange, renderRunLink, ref, ...props }) {
14
14
  const titleId = React.useId();
15
15
  const definitionId = React.useId();
16
16
  const settingsId = React.useId();
@@ -72,7 +72,7 @@ function ThinkRoutineDetail({ busy = false, className, routine, onEnabledChange,
72
72
  children: [
73
73
  /* @__PURE__ */ jsxs("div", { children: [/* @__PURE__ */ jsx("dt", { children: "Repeats" }), /* @__PURE__ */ jsx("dd", { children: routine.task.schedule })] }),
74
74
  /* @__PURE__ */ jsxs("div", { children: [/* @__PURE__ */ jsx("dt", { children: "Next run" }), /* @__PURE__ */ jsx("dd", { children: getThinkRoutineNextRun(routine) })] }),
75
- /* @__PURE__ */ jsxs("div", { children: [/* @__PURE__ */ jsx("dt", { children: "Agent" }), /* @__PURE__ */ jsx("dd", { children: routine.owner.name })] })
75
+ showOwner ? /* @__PURE__ */ jsxs("div", { children: [/* @__PURE__ */ jsx("dt", { children: "Agent" }), /* @__PURE__ */ jsx("dd", { children: routine.owner.name })] }) : null
76
76
  ]
77
77
  }),
78
78
  /* @__PURE__ */ jsxs("div", {
@@ -93,7 +93,7 @@ function ThinkRoutineDetail({ busy = false, className, routine, onEnabledChange,
93
93
  }),
94
94
  /* @__PURE__ */ jsx(ThinkRoutineRuns, {
95
95
  runs: routine.runs,
96
- onRunSelect
96
+ renderRunLink
97
97
  })
98
98
  ]
99
99
  });
@@ -12,15 +12,16 @@ interface ThinkRoutineFormProps extends React.HTMLAttributes<HTMLElement> {
12
12
  * `getDefaultTimezone()` own wall-clock fallback behavior.
13
13
  */
14
14
  schedules: readonly ThinkScheduledTaskSchedule[];
15
- onCancel?: () => void;
15
+ /** App-authored TanStack Router Link to the routine catalog. */
16
+ cancelLink?: React.ReactElement;
16
17
  onCreate: (request: ThinkRoutineCreateRequest) => void;
17
18
  }
18
19
  /** Authoring surface for a serializable, prompt-based Think scheduled task. */
19
20
  declare function ThinkRoutineForm({
20
21
  busy,
22
+ cancelLink,
21
23
  className,
22
24
  owners,
23
- onCancel,
24
25
  onCreate,
25
26
  schedules,
26
27
  ref,
@@ -1,6 +1,7 @@
1
- import { t as cx } from "../class-names-9UtZwb0J.js";
2
- import { B as SpinnerIcon } from "../icons-CpfUer49.js";
3
- import { Button } from "./Button.js";
1
+ import { t as cx } from "../class-names-BiMDVpUo.js";
2
+ import { G as SpinnerIcon } from "../icons-CQJ-aMnI.js";
3
+ import { t as NavigationLink } from "../navigation-link-Cob7KBlM.js";
4
+ import { Button, buttonVariants } from "./Button.js";
4
5
  import { Field } from "./Field.js";
5
6
  import { Form } from "./Form.js";
6
7
  import { Textarea } from "./Textarea.js";
@@ -32,7 +33,7 @@ function RoutineSelect({ label, onValueChange, options, value }) {
32
33
  });
33
34
  }
34
35
  /** Authoring surface for a serializable, prompt-based Think scheduled task. */
35
- function ThinkRoutineForm({ busy = false, className, owners, onCancel, onCreate, schedules, ref, ...props }) {
36
+ function ThinkRoutineForm({ busy = false, cancelLink, className, owners, onCreate, schedules, ref, ...props }) {
36
37
  const [name, setName] = React.useState("");
37
38
  const [ownerId, setOwnerId] = React.useState(owners[0]?.id ?? "");
38
39
  const [prompt, setPrompt] = React.useState("");
@@ -131,12 +132,12 @@ function ThinkRoutineForm({ busy = false, className, owners, onCancel, onCreate,
131
132
  })
132
133
  ] }), /* @__PURE__ */ jsxs("footer", {
133
134
  className: "think-routine-library__form-actions",
134
- children: [onCancel ? /* @__PURE__ */ jsx(Button, {
135
- type: "button",
136
- variant: "ghost",
137
- color: "neutral",
138
- disabled: busy,
139
- onClick: onCancel,
135
+ children: [cancelLink ? /* @__PURE__ */ jsx(NavigationLink, {
136
+ render: cancelLink,
137
+ className: buttonVariants({
138
+ variant: "ghost",
139
+ color: "neutral"
140
+ }),
140
141
  children: "Cancel"
141
142
  }) : null, /* @__PURE__ */ jsxs(Button, {
142
143
  type: "submit",
@@ -1,7 +1,6 @@
1
1
  import { t as ThinkExecutionRun } from "../ThinkExecutionRun-ChhWhOoU.js";
2
2
  import { ThinkRoutine, ThinkRoutineCreateRequest, ThinkRoutineOwner, ThinkRoutineRunOf } from "./ThinkRoutine.js";
3
3
  import * as React from "react";
4
- import { ThinkScheduledTaskSchedule } from "@cloudflare/think";
5
4
 
6
5
  //#region src/components/ThinkRoutineLibrary.d.ts
7
6
  interface ThinkRoutineLibraryDetailRenderProps<TRoutine extends ThinkRoutine = ThinkRoutine> {
@@ -12,31 +11,33 @@ interface ThinkRoutineLibraryDetailRenderProps<TRoutine extends ThinkRoutine = T
12
11
  /** Custom detail surfaces must honor this while invoking the supplied actions. */
13
12
  busy: boolean;
14
13
  onEnabledChange?: (enabled: boolean) => void;
15
- onRunSelect?: (run: ThinkRoutineRunOf<TRoutine>) => void;
14
+ renderRunLink?: (run: ThinkRoutineRunOf<TRoutine>) => React.ReactElement;
16
15
  }
17
16
  interface ThinkRoutineLibraryProps<TRoutine extends ThinkRoutine = ThinkRoutine> extends Omit<React.HTMLAttributes<HTMLDivElement>, "onSelect"> {
18
17
  /** App-owned routine catalog assembled from native Think and Agents records. */
19
18
  routines: readonly TRoutine[];
20
- /** Agents available as owners when authoring a routine. */
21
- owners: readonly ThinkRoutineOwner[];
22
- /** Upstream Think schedule DSL values offered by the composed authoring form. */
23
- schedules: readonly ThinkScheduledTaskSchedule[];
24
- /** Selected routine id when selection is controlled by the host app. */
25
- selectedRoutineId?: string;
26
- /** Initial routine id when the library owns selection state. */
27
- defaultSelectedRoutineId?: string;
28
- /** Called when the user selects a routine from the collection. */
29
- onSelectedRoutineIdChange?: (routineId: string) => void;
30
- /** Creates an app-owned routine from a whole native Think scheduled task. */
31
- onCreateRoutine?: (request: ThinkRoutineCreateRequest) => void | Promise<void>;
19
+ /** Routine selected by the current application route. */
20
+ selectedRoutineId: string | null;
21
+ /** App-authored TanStack Router Link for every routine destination. */
22
+ renderRoutineLink: (routine: TRoutine) => React.ReactElement;
23
+ /** App-authored TanStack Router Link to the routine creation route. */
24
+ createRoutineLink?: React.ReactElement;
25
+ /** App-authored TanStack Router Link to edit the selected routine. */
26
+ renderEditRoutineLink?: (routine: TRoutine) => React.ReactElement;
27
+ /** App-authored TanStack Router Link for recent execution destinations. */
28
+ renderRunLink?: (routine: TRoutine, run: ThinkRoutineRunOf<TRoutine>) => React.ReactElement;
29
+ /** Whether to show routine owners in the browser and detail. Defaults to true. */
30
+ showOwner?: boolean;
31
+ /** Host-owned catalog error shown above the library without replacing loaded routines. */
32
+ error?: React.ReactNode;
33
+ /** Product navigation rendered after the built-in schedule navigation control. */
34
+ appBarLeading?: React.ReactNode;
32
35
  /** Starts the selected routine immediately. */
33
36
  onRunRoutine?: (routine: TRoutine) => void | Promise<void>;
34
37
  /** Activates or pauses the selected app-owned routine. */
35
38
  onRoutineEnabledChange?: (routine: TRoutine, enabled: boolean) => void | Promise<void>;
36
39
  /** Permanently removes the selected app-owned routine. */
37
40
  onDeleteRoutine?: (routine: TRoutine) => void | Promise<void>;
38
- /** Opens one native Workflow or submission from the selected routine history. */
39
- onRunSelect?: (routine: TRoutine, run: ThinkRoutineRunOf<TRoutine>) => void;
40
41
  /**
41
42
  * Replaces only the selected-routine surface while preserving the library
42
43
  * shell, navigation, actions, async state, and upstream routine contract.
@@ -46,26 +47,27 @@ interface ThinkRoutineLibraryProps<TRoutine extends ThinkRoutine = ThinkRoutine>
46
47
  /**
47
48
  * Full-page, cross-agent routine library. This intentionally does not live in
48
49
  * ThinkFullApp's per-thread workbench: the host app owns aggregation, routes,
49
- * authoring callables, and the association between schedules and native runs.
50
+ * authoring routes, and the association between schedules and native runs.
50
51
  * The application shell composes `ThinkRoutineBrowser`, `ThinkRoutineDetail`,
51
- * `ThinkRoutineRuns`, and `ThinkRoutineForm`; consumers may also use those
52
- * surfaces independently.
52
+ * and `ThinkRoutineRuns`; consumers compose `ThinkRoutineForm` in their create
53
+ * route and may also use these surfaces independently.
53
54
  */
54
55
  declare function ThinkRoutineLibrary<TRoutine extends ThinkRoutine = ThinkRoutine>({
56
+ appBarLeading,
55
57
  className,
56
- defaultSelectedRoutineId,
57
- onCreateRoutine,
58
+ createRoutineLink,
59
+ error: catalogError,
58
60
  onDeleteRoutine,
59
61
  onRoutineEnabledChange,
60
62
  onRunRoutine,
61
- onRunSelect,
62
- onSelectedRoutineIdChange,
63
- owners,
63
+ renderEditRoutineLink,
64
+ renderRoutineLink,
64
65
  renderRoutineDetail,
65
- schedules,
66
+ renderRunLink,
66
67
  ref,
67
68
  routines,
68
69
  selectedRoutineId,
70
+ showOwner,
69
71
  ...props
70
72
  }: ThinkRoutineLibraryProps<TRoutine> & {
71
73
  ref?: React.Ref<HTMLDivElement>;