@mcp-b/react-components 0.11.0 → 0.13.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 (253) hide show
  1. package/dist/{AgentChat-B9LD_WF1.d.ts → AgentChat-Br6tKEl8.d.ts} +38 -10
  2. package/dist/{BrowserLiveView-ZktFZiMD.d.ts → BrowserLiveView-BV5qgFgI.d.ts} +11 -10
  3. package/dist/{BrowserReplay-6G-mnwcn.d.ts → BrowserReplay-xWvRjRAC.d.ts} +2 -1
  4. package/dist/{Button-Ct5I6aTu.d.ts → Button-FX_hpqxm.d.ts} +8 -11
  5. package/dist/{CodeBlock-XNQOupQ3.js → CodeBlock-BUFXG8HW.js} +22 -12
  6. package/dist/{CodeBlock-CxQXv3C4.d.ts → CodeBlock-DUh9WOGo.d.ts} +13 -7
  7. package/dist/{Combobox-D9anamNr.d.ts → Combobox-B9Fcd6q-.d.ts} +4 -14
  8. package/dist/{FileTree-wMyZhhHO.js → FileTree-mpEIcfzA.js} +1 -1
  9. package/dist/{Menu-B5vDqZe_.d.ts → Menu-Bgu-ufb5.d.ts} +29 -65
  10. package/dist/{ModelSelector-DXtpcRmT.js → ModelSelector-DVgVBdvw.js} +23 -20
  11. package/dist/{PromptInput-D6-G24p7.d.ts → PromptInput-p5KmOmt1.d.ts} +313 -89
  12. package/dist/Select-Dl_vF_Bt.d.ts +213 -0
  13. package/dist/{Tabs-D9EAq09D.d.ts → Tabs-3Zc4tb9D.d.ts} +9 -6
  14. package/dist/ThinkChat-7DQ2CogF.js +222 -0
  15. package/dist/{ThinkChatActivity-B2UD95My.d.ts → ThinkChatActivity-Cuk28Js_.d.ts} +4 -4
  16. package/dist/ThinkChatContext-C3Eb1Xpi.d.ts +16 -0
  17. package/dist/{ThinkChatToolParts-DnUiZgCC.d.ts → ThinkChatToolParts-Cv4o7j6F.d.ts} +13 -5
  18. package/dist/{attachment-preview-ChtC3HiU.js → attachment-preview-DIs50Q0h.js} +3 -3
  19. package/dist/components/Accordion.d.ts +17 -6
  20. package/dist/components/Accordion.js +23 -36
  21. package/dist/components/Activity.d.ts +5 -5
  22. package/dist/components/Activity.js +9 -9
  23. package/dist/components/AgentChat.d.ts +1 -1
  24. package/dist/components/AgentChat.js +354 -132
  25. package/dist/components/AgentConnection.js +6 -22
  26. package/dist/components/AlertDialog.d.ts +40 -32
  27. package/dist/components/AlertDialog.js +46 -39
  28. package/dist/components/Artifact.d.ts +1 -1
  29. package/dist/components/Artifact.js +5 -5
  30. package/dist/components/Autocomplete.js +10 -2
  31. package/dist/components/Avatar.d.ts +2 -2
  32. package/dist/components/Avatar.js +3 -3
  33. package/dist/components/Badge.d.ts +11 -14
  34. package/dist/components/Badge.js +11 -33
  35. package/dist/components/BrowserLiveView.d.ts +1 -1
  36. package/dist/components/BrowserLiveView.js +39 -45
  37. package/dist/components/BrowserReplay.d.ts +1 -1
  38. package/dist/components/BrowserReplay.js +4 -4
  39. package/dist/components/BrowserRunPanel.js +91 -55
  40. package/dist/components/Button.d.ts +2 -2
  41. package/dist/components/Button.js +7 -30
  42. package/dist/components/ChainOfThought.d.ts +5 -5
  43. package/dist/components/ChainOfThought.js +8 -5
  44. package/dist/components/ChatGptSignInScreen.js +3 -3
  45. package/dist/components/Checkbox.d.ts +10 -2
  46. package/dist/components/Checkbox.js +13 -6
  47. package/dist/components/CheckboxGroup.d.ts +6 -6
  48. package/dist/components/CheckboxGroup.js +6 -6
  49. package/dist/components/CodeBlock.d.ts +1 -1
  50. package/dist/components/CodeBlock.js +1 -1
  51. package/dist/components/CodexModelSelector.d.ts +58 -0
  52. package/dist/components/CodexModelSelector.js +170 -0
  53. package/dist/components/Collapsible.d.ts +2 -4
  54. package/dist/components/Collapsible.js +9 -7
  55. package/dist/components/Combobox.d.ts +2 -2
  56. package/dist/components/Combobox.js +20 -22
  57. package/dist/components/Commit.d.ts +6 -6
  58. package/dist/components/Commit.js +14 -26
  59. package/dist/components/Context.js +5 -1
  60. package/dist/components/ContextMenu.d.ts +20 -72
  61. package/dist/components/ContextMenu.js +46 -56
  62. package/dist/components/Conversation.d.ts +3 -7
  63. package/dist/components/Conversation.js +3 -4
  64. package/dist/components/Dialog.d.ts +38 -30
  65. package/dist/components/Dialog.js +46 -34
  66. package/dist/components/EnvironmentVariables.d.ts +2 -7
  67. package/dist/components/EnvironmentVariables.js +13 -36
  68. package/dist/components/Field.d.ts +3 -3
  69. package/dist/components/Field.js +7 -8
  70. package/dist/components/Fieldset.d.ts +2 -2
  71. package/dist/components/Fieldset.js +2 -2
  72. package/dist/components/FileTree.js +1 -1
  73. package/dist/components/Label.d.ts +1 -1
  74. package/dist/components/Label.js +1 -1
  75. package/dist/components/Marker.js +1 -15
  76. package/dist/components/McpServerPicker.d.ts +31 -6
  77. package/dist/components/McpServerPicker.js +136 -72
  78. package/dist/components/Menu.d.ts +2 -2
  79. package/dist/components/Menu.js +41 -51
  80. package/dist/components/Menubar.d.ts +16 -52
  81. package/dist/components/Menubar.js +44 -56
  82. package/dist/components/Message.d.ts +4 -3
  83. package/dist/components/Message.js +16 -9
  84. package/dist/components/MessageScroller.d.ts +1 -1
  85. package/dist/components/MessageScroller.js +1 -1
  86. package/dist/components/Meter.js +5 -0
  87. package/dist/components/ModelSelector.d.ts +12 -9
  88. package/dist/components/ModelSelector.js +1 -1
  89. package/dist/components/NavigationMenu.d.ts +3 -14
  90. package/dist/components/NavigationMenu.js +22 -38
  91. package/dist/components/NumberField.js +6 -0
  92. package/dist/components/Popover.d.ts +21 -44
  93. package/dist/components/Popover.js +33 -23
  94. package/dist/components/PreviewCard.d.ts +20 -18
  95. package/dist/components/PreviewCard.js +30 -20
  96. package/dist/components/PricingPage.js +30 -29
  97. package/dist/components/Progress.d.ts +7 -3
  98. package/dist/components/Progress.js +9 -4
  99. package/dist/components/PromptInput.d.ts +2 -2
  100. package/dist/components/PromptInput.js +184 -148
  101. package/dist/components/Queue.d.ts +8 -19
  102. package/dist/components/Queue.js +6 -6
  103. package/dist/components/RadioGroup.d.ts +10 -9
  104. package/dist/components/RadioGroup.js +8 -9
  105. package/dist/components/Reasoning.d.ts +4 -4
  106. package/dist/components/Reasoning.js +12 -21
  107. package/dist/components/ScrollArea.d.ts +2 -9
  108. package/dist/components/ScrollArea.js +5 -23
  109. package/dist/components/Select.d.ts +2 -2
  110. package/dist/components/Select.js +100 -134
  111. package/dist/components/Slider.d.ts +10 -7
  112. package/dist/components/Slider.js +12 -11
  113. package/dist/components/Sources.d.ts +4 -4
  114. package/dist/components/Sources.js +8 -5
  115. package/dist/components/Stepper.js +2 -8
  116. package/dist/components/Switch.d.ts +6 -3
  117. package/dist/components/Switch.js +7 -4
  118. package/dist/components/Tabs.d.ts +2 -2
  119. package/dist/components/Tabs.js +9 -4
  120. package/dist/components/Task.d.ts +4 -4
  121. package/dist/components/Task.js +10 -6
  122. package/dist/components/Terminal.d.ts +2 -2
  123. package/dist/components/Terminal.js +5 -5
  124. package/dist/components/TestResults.d.ts +4 -4
  125. package/dist/components/TestResults.js +5 -5
  126. package/dist/components/ThinkChat.d.ts +37 -30
  127. package/dist/components/ThinkChat.js +1 -152
  128. package/dist/components/ThinkChatActivity.d.ts +2 -2
  129. package/dist/components/ThinkChatActivity.js +4 -11
  130. package/dist/components/ThinkChatContext.d.ts +2 -2
  131. package/dist/components/ThinkChatContext.js +9 -2
  132. package/dist/components/ThinkChatToolPanels.d.ts +1 -1
  133. package/dist/components/ThinkChatToolPanels.js +27 -15
  134. package/dist/components/ThinkChatToolParts.d.ts +1 -1
  135. package/dist/components/ThinkExecutionWorkbench.d.ts +10 -7
  136. package/dist/components/ThinkExecutionWorkbench.js +382 -359
  137. package/dist/components/ThinkFullApp.d.ts +16 -13
  138. package/dist/components/ThinkFullApp.js +35 -25
  139. package/dist/components/ThinkThreadPicker.d.ts +1 -31
  140. package/dist/components/ThinkThreadPicker.js +32 -171
  141. package/dist/components/ThinkThreadShell.d.ts +35 -0
  142. package/dist/components/ThinkThreadShell.js +146 -0
  143. package/dist/components/Toast.js +7 -0
  144. package/dist/components/ToggleGroup.d.ts +6 -2
  145. package/dist/components/ToggleGroup.js +6 -2
  146. package/dist/components/Toolbar.js +6 -0
  147. package/dist/components/Tooltip.d.ts +36 -27
  148. package/dist/components/Tooltip.js +45 -29
  149. package/dist/components/WebPreview.d.ts +1 -1
  150. package/dist/components/WebPreview.js +3 -3
  151. package/dist/components/WorkspaceExplorer.d.ts +6 -8
  152. package/dist/components/WorkspaceExplorer.js +9 -7
  153. package/dist/components/icons.d.ts +2 -2
  154. package/dist/components/icons.js +2 -2
  155. package/dist/{copy-button-C6JSKtFE.js → copy-button-DUMLYdsk.js} +7 -6
  156. package/dist/{copy-button-BKXqGiNm.d.ts → copy-button-DtPMgN7e.d.ts} +3 -2
  157. package/dist/icons-Ba9THQKz.js +64 -0
  158. package/dist/icons-CUCz_Sft.d.ts +210 -0
  159. package/dist/merge-refs-DF_7w2x_.js +18 -0
  160. package/dist/styles/accessibility.css +14 -0
  161. package/dist/styles/accordion.css +21 -61
  162. package/dist/styles/activity.css +23 -58
  163. package/dist/styles/agent-chat.css +49 -5
  164. package/dist/styles/agent-connection.css +8 -10
  165. package/dist/styles/alert-dialog.css +20 -26
  166. package/dist/styles/artifact.css +6 -6
  167. package/dist/styles/attachment-preview.css +1 -1
  168. package/dist/styles/autocomplete.css +5 -170
  169. package/dist/styles/avatar.css +8 -8
  170. package/dist/styles/badge.css +8 -10
  171. package/dist/styles/base-ui-motion.css +176 -0
  172. package/dist/styles/base.css +19 -25
  173. package/dist/styles/browser-live-view.css +7 -7
  174. package/dist/styles/browser-replay.css +5 -5
  175. package/dist/styles/browser-run-panel.css +59 -112
  176. package/dist/styles/button.css +48 -43
  177. package/dist/styles/card.css +3 -5
  178. package/dist/styles/chain-of-thought.css +14 -70
  179. package/dist/styles/chatgpt-sign-in-screen.css +3 -3
  180. package/dist/styles/checkbox-group.css +1 -1
  181. package/dist/styles/checkbox.css +3 -7
  182. package/dist/styles/code-block.css +10 -10
  183. package/dist/styles/codex-model-selector.css +186 -0
  184. package/dist/styles/collapsible.css +11 -27
  185. package/dist/styles/combobox.css +3 -149
  186. package/dist/styles/commit.css +19 -35
  187. package/dist/styles/context-menu.css +1 -77
  188. package/dist/styles/context.css +12 -12
  189. package/dist/styles/conversation.css +7 -7
  190. package/dist/styles/dialog.css +34 -55
  191. package/dist/styles/environment-variables.css +10 -10
  192. package/dist/styles/field.css +16 -58
  193. package/dist/styles/fieldset.css +2 -2
  194. package/dist/styles/file-tree.css +7 -9
  195. package/dist/styles/index.css +12 -2
  196. package/dist/styles/input.css +1 -51
  197. package/dist/styles/label.css +2 -2
  198. package/dist/styles/marker.css +2 -4
  199. package/dist/styles/mcp-server-picker.css +66 -19
  200. package/dist/styles/menu.css +6 -153
  201. package/dist/styles/menubar.css +6 -105
  202. package/dist/styles/message-scroller.css +1 -1
  203. package/dist/styles/message.css +87 -9
  204. package/dist/styles/meter.css +4 -20
  205. package/dist/styles/model-selector.css +32 -20
  206. package/dist/styles/navigation-menu.css +14 -54
  207. package/dist/styles/number-field.css +8 -23
  208. package/dist/styles/popover.css +13 -68
  209. package/dist/styles/preview-card.css +5 -46
  210. package/dist/styles/pricing-page.css +43 -43
  211. package/dist/styles/progress.css +7 -16
  212. package/dist/styles/prompt-input.css +100 -44
  213. package/dist/styles/queue.css +12 -28
  214. package/dist/styles/radio.css +4 -8
  215. package/dist/styles/reasoning.css +3 -62
  216. package/dist/styles/recipes.css +475 -0
  217. package/dist/styles/select.css +7 -103
  218. package/dist/styles/shell.css +3 -3
  219. package/dist/styles/slider.css +5 -7
  220. package/dist/styles/sources.css +9 -66
  221. package/dist/styles/stepper.css +16 -14
  222. package/dist/styles/streamdown.css +11 -57
  223. package/dist/styles/switch.css +4 -7
  224. package/dist/styles/tabs.css +7 -8
  225. package/dist/styles/task.css +13 -42
  226. package/dist/styles/terminal.css +7 -7
  227. package/dist/styles/test-results.css +21 -37
  228. package/dist/styles/think-execution-workbench.css +337 -0
  229. package/dist/styles/think-full-app.css +27 -410
  230. package/dist/styles/think-resize-handle.css +33 -0
  231. package/dist/styles/think-thread-picker.css +18 -247
  232. package/dist/styles/think-thread-shell.css +219 -0
  233. package/dist/styles/toast.css +14 -25
  234. package/dist/styles/toggle-group.css +16 -14
  235. package/dist/styles/toggle.css +14 -15
  236. package/dist/styles/toolbar.css +13 -25
  237. package/dist/styles/tooltip.css +6 -16
  238. package/dist/styles/web-preview.css +15 -15
  239. package/dist/styles/workspace-explorer.css +21 -14
  240. package/dist/summarize-tool-input-BUJsENSn.js +12 -0
  241. package/dist/utils/codex-model-catalog.d.ts +142 -0
  242. package/dist/utils/codex-model-catalog.js +112 -0
  243. package/dist/utils/structured-code.d.ts +1 -1
  244. package/package.json +8 -2
  245. package/dist/Select-CRsKCJ9x.d.ts +0 -200
  246. package/dist/ThinkChatContext-BLAAb8J5.d.ts +0 -28
  247. package/dist/components/McpServerConnections.d.ts +0 -41
  248. package/dist/components/McpServerConnections.js +0 -188
  249. package/dist/components/useStickToBottom.d.ts +0 -33
  250. package/dist/components/useStickToBottom.js +0 -107
  251. package/dist/icons-CbjtbIJK.d.ts +0 -51
  252. package/dist/icons-D2Q5n5C1.js +0 -291
  253. package/dist/styles/mcp-server-connections.css +0 -145
@@ -1,7 +1,7 @@
1
1
  import { t as cx } from "../class-names-9UtZwb0J.js";
2
- import { D as PlayIcon, T as PauseIcon } from "../icons-D2Q5n5C1.js";
2
+ import { E as PauseIcon, O as PlayIcon } from "../icons-Ba9THQKz.js";
3
3
  import { Button } from "./Button.js";
4
- import { Slider, SliderControl, SliderIndicator, SliderThumb, SliderTrack } from "./Slider.js";
4
+ import { Slider } from "./Slider.js";
5
5
  import * as React from "react";
6
6
  import { jsx, jsxs } from "react/jsx-runtime";
7
7
  import { Replayer } from "@rrweb/replay";
@@ -161,7 +161,7 @@ function BrowserReplay({ className, events, autoPlay, ref, ...props }) {
161
161
  onClick: handlePlayPause,
162
162
  children: isPlaying ? /* @__PURE__ */ jsx(PauseIcon, {}) : /* @__PURE__ */ jsx(PlayIcon, {})
163
163
  }),
164
- /* @__PURE__ */ jsx(Slider, {
164
+ /* @__PURE__ */ jsx(Slider.Root, {
165
165
  className: "browser-replay__scrubber",
166
166
  min: 0,
167
167
  max: Math.max(duration, 1),
@@ -169,7 +169,7 @@ function BrowserReplay({ className, events, autoPlay, ref, ...props }) {
169
169
  value: Math.min(currentTime, duration),
170
170
  disabled,
171
171
  onValueChange: handleScrub,
172
- children: /* @__PURE__ */ jsx(SliderControl, { children: /* @__PURE__ */ jsxs(SliderTrack, { children: [/* @__PURE__ */ jsx(SliderIndicator, {}), /* @__PURE__ */ jsx(SliderThumb, { "aria-label": "Replay position" })] }) })
172
+ children: /* @__PURE__ */ jsx(Slider.Control, { children: /* @__PURE__ */ jsxs(Slider.Track, { children: [/* @__PURE__ */ jsx(Slider.Indicator, {}), /* @__PURE__ */ jsx(Slider.Thumb, { "aria-label": "Replay position" })] }) })
173
173
  }),
174
174
  /* @__PURE__ */ jsxs("span", {
175
175
  className: "browser-replay__time",
@@ -1,7 +1,8 @@
1
1
  import { t as cx } from "../class-names-9UtZwb0J.js";
2
- import { C as MonitorIcon, L as XIcon, M as SpinnerIcon, k as RefreshIcon } from "../icons-D2Q5n5C1.js";
2
+ import { N as SpinnerIcon, z as XIcon } from "../icons-Ba9THQKz.js";
3
3
  import { Button } from "./Button.js";
4
4
  import { BrowserLiveView } from "./BrowserLiveView.js";
5
+ import { WebPreview, WebPreviewNavigation, WebPreviewNavigationButton, WebPreviewUrl } from "./WebPreview.js";
5
6
  import * as React from "react";
6
7
  import { jsx, jsxs } from "react/jsx-runtime";
7
8
  //#region src/components/BrowserRunPanel.tsx
@@ -12,12 +13,15 @@ function isInspectablePage(target) {
12
13
  function targetLabel(target) {
13
14
  return target.title || target.pageUrl || target.targetId;
14
15
  }
16
+ function targetGlyph(target) {
17
+ return (target.title || target.pageUrl || target.targetId).trim().charAt(0).toUpperCase() || "•";
18
+ }
15
19
  function pickTarget(targets, targetId) {
16
20
  return (targetId ? targets.find((target) => target.targetId === targetId) : void 0) ?? targets.find(isInspectablePage) ?? targets[0];
17
21
  }
18
22
  function BrowserRunPanelState({ children, role, tone = "neutral" }) {
19
23
  return /* @__PURE__ */ jsx("div", {
20
- className: "browser-run-panel__state",
24
+ className: "web-preview__body--empty browser-run-panel__state",
21
25
  "data-tone": tone,
22
26
  role: role ?? (tone === "danger" ? "alert" : void 0),
23
27
  children
@@ -33,84 +37,116 @@ function BrowserRunPanelState({ children, role, tone = "neutral" }) {
33
37
  function BrowserRunPanel({ liveView, onRefresh, onCloseSession, loading, error, label = "Browser", empty = "No live browser session", fallback, className, ref, ...props }) {
34
38
  const [selectedTargetId, setSelectedTargetId] = React.useState();
35
39
  const [receivedAt, setReceivedAt] = React.useState(() => Date.now());
40
+ const tabRefs = React.useRef(/* @__PURE__ */ new Map());
41
+ const tabListId = React.useId();
36
42
  React.useEffect(() => {
37
43
  if (liveView) setReceivedAt(Date.now());
38
44
  }, [liveView]);
39
45
  const targets = liveView?.targets ?? [];
40
46
  const target = pickTarget(targets, selectedTargetId);
41
- const pageLabel = target ? targetLabel(target) : "Waiting for a shared browser session";
42
- return /* @__PURE__ */ jsxs("section", {
47
+ const pageUrl = target?.pageUrl ?? "";
48
+ const selectTarget = React.useCallback((nextTarget) => {
49
+ setSelectedTargetId(nextTarget.targetId);
50
+ }, []);
51
+ const handleTabListKeyDown = (event) => {
52
+ const currentIndex = targets.findIndex((candidate) => candidate.targetId === target?.targetId);
53
+ if (currentIndex < 0) return;
54
+ let nextIndex;
55
+ if (event.key === "ArrowRight") nextIndex = (currentIndex + 1) % targets.length;
56
+ if (event.key === "ArrowLeft") nextIndex = (currentIndex - 1 + targets.length) % targets.length;
57
+ if (event.key === "Home") nextIndex = 0;
58
+ if (event.key === "End") nextIndex = targets.length - 1;
59
+ if (nextIndex === void 0) return;
60
+ event.preventDefault();
61
+ const nextTarget = targets[nextIndex];
62
+ if (!nextTarget) return;
63
+ selectTarget(nextTarget);
64
+ tabRefs.current.get(nextTarget.targetId)?.focus();
65
+ };
66
+ return /* @__PURE__ */ jsxs(WebPreview, {
43
67
  ref,
44
68
  className: cx("browser-run-panel", className),
69
+ url: pageUrl,
70
+ role: "region",
45
71
  "aria-label": typeof label === "string" ? label : "Browser",
46
72
  ...props,
47
73
  children: [
48
- /* @__PURE__ */ jsxs("header", {
49
- className: "browser-run-panel__header",
50
- children: [/* @__PURE__ */ jsxs("div", {
51
- className: "browser-run-panel__identity",
52
- children: [/* @__PURE__ */ jsx(MonitorIcon, { className: "browser-run-panel__icon" }), /* @__PURE__ */ jsxs("div", {
53
- className: "browser-run-panel__title-block",
54
- children: [/* @__PURE__ */ jsx("span", {
55
- className: "browser-run-panel__title",
56
- children: label
57
- }), /* @__PURE__ */ jsx("span", {
58
- className: "browser-run-panel__url",
59
- title: pageLabel,
60
- children: pageLabel
61
- })]
62
- })]
63
- }), /* @__PURE__ */ jsxs("div", {
64
- className: "browser-run-panel__actions",
65
- children: [onRefresh ? /* @__PURE__ */ jsx(Button, {
74
+ targets.length > 1 ? /* @__PURE__ */ jsx(WebPreviewNavigation, { children: /* @__PURE__ */ jsx("div", {
75
+ id: tabListId,
76
+ className: "browser-run-panel__tabs",
77
+ role: "tablist",
78
+ "aria-label": "Open browser pages",
79
+ onKeyDown: handleTabListKeyDown,
80
+ children: targets.map((candidate) => {
81
+ const selected = candidate.targetId === target?.targetId;
82
+ return /* @__PURE__ */ jsxs(Button, {
83
+ ref: (node) => {
84
+ if (node) tabRefs.current.set(candidate.targetId, node);
85
+ else tabRefs.current.delete(candidate.targetId);
86
+ },
66
87
  type: "button",
67
88
  variant: "ghost",
68
89
  color: "neutral",
69
- size: "icon-sm",
70
- "aria-label": "Refresh browser view",
90
+ size: "sm",
91
+ className: "browser-run-panel__tab",
92
+ role: "tab",
93
+ id: `${tabListId}-${candidate.targetId}`,
94
+ "aria-selected": selected,
95
+ "aria-controls": `${tabListId}-panel`,
96
+ tabIndex: selected ? 0 : -1,
97
+ onClick: () => selectTarget(candidate),
98
+ children: [/* @__PURE__ */ jsx("span", {
99
+ className: "browser-run-panel__tab-glyph",
100
+ "aria-hidden": "true",
101
+ children: targetGlyph(candidate)
102
+ }), /* @__PURE__ */ jsx("span", {
103
+ className: "browser-run-panel__tab-title",
104
+ children: targetLabel(candidate)
105
+ })]
106
+ }, candidate.targetId);
107
+ })
108
+ }) }) : null,
109
+ /* @__PURE__ */ jsxs(WebPreviewNavigation, {
110
+ className: "browser-run-panel__address-bar",
111
+ children: [
112
+ /* @__PURE__ */ jsx(WebPreviewUrl, {
113
+ "aria-label": "Browser page URL",
114
+ placeholder: "Waiting for browser session",
115
+ readOnly: true
116
+ }),
117
+ onRefresh ? /* @__PURE__ */ jsx(WebPreviewNavigationButton, {
118
+ action: "reload",
119
+ label: "Refresh browser view",
71
120
  disabled: loading,
72
- onClick: () => void onRefresh(),
73
- children: /* @__PURE__ */ jsx(RefreshIcon, {})
74
- }) : null, onCloseSession ? /* @__PURE__ */ jsx(Button, {
75
- type: "button",
76
- variant: "ghost",
77
- color: "neutral",
78
- size: "icon-sm",
79
- "aria-label": "Close browser session",
121
+ onClick: () => void onRefresh()
122
+ }) : null,
123
+ onCloseSession ? /* @__PURE__ */ jsx(WebPreviewNavigationButton, {
124
+ label: "Close browser session",
80
125
  onClick: () => void onCloseSession(),
81
126
  children: /* @__PURE__ */ jsx(XIcon, {})
82
- }) : null]
83
- })]
127
+ }) : null
128
+ ]
84
129
  }),
85
- targets.length > 1 ? /* @__PURE__ */ jsx("div", {
86
- className: "browser-run-panel__targets",
87
- "aria-label": "Browser tabs",
88
- children: targets.map((candidate) => /* @__PURE__ */ jsxs("button", {
89
- type: "button",
90
- className: "browser-run-panel__target",
91
- "aria-pressed": candidate.targetId === target?.targetId,
92
- onClick: () => setSelectedTargetId(candidate.targetId),
93
- children: [/* @__PURE__ */ jsx("span", {
94
- className: "browser-run-panel__target-title",
95
- children: targetLabel(candidate)
96
- }), candidate.pageUrl ? /* @__PURE__ */ jsx("span", {
97
- className: "browser-run-panel__target-url",
98
- children: candidate.pageUrl
99
- }) : null]
100
- }, candidate.targetId))
101
- }) : null,
102
130
  error ? /* @__PURE__ */ jsx(BrowserRunPanelState, {
103
131
  tone: "danger",
104
132
  children: error
105
133
  }) : null,
106
134
  /* @__PURE__ */ jsx("div", {
107
- className: "browser-run-panel__body",
135
+ id: `${tabListId}-panel`,
136
+ className: "web-preview__body browser-run-panel__body",
137
+ role: targets.length > 1 ? "tabpanel" : void 0,
138
+ "aria-labelledby": targets.length > 1 && target ? `${tabListId}-${target.targetId}` : void 0,
108
139
  "aria-busy": loading || void 0,
109
140
  children: target && liveView ? /* @__PURE__ */ jsx(BrowserLiveView, {
110
- url: target.url,
111
- expiresAt: receivedAt + liveView.expiresInMs,
141
+ source: {
142
+ url: target.url,
143
+ targetId: target.targetId,
144
+ expiresInMs: liveView.expiresInMs
145
+ },
146
+ receivedAt,
112
147
  pageTitle: target.title ?? target.pageUrl,
113
- fallback
148
+ fallback,
149
+ className: "browser-run-panel__live-view"
114
150
  }) : loading ? /* @__PURE__ */ jsxs(BrowserRunPanelState, {
115
151
  role: "status",
116
152
  children: [/* @__PURE__ */ jsx(SpinnerIcon, { className: "browser-run-panel__spinner" }), "Loading browser session"]
@@ -1,2 +1,2 @@
1
- import { a as ButtonVariant, c as ShadcnButtonVariant, i as ButtonSize, l as buttonVariants, n as ButtonColor, o as ButtonVariantsOptions, r as ButtonProps, s as ShadcnButtonSize, t as Button } from "../Button-Ct5I6aTu.js";
2
- export { Button, ButtonColor, ButtonProps, ButtonSize, ButtonVariant, ButtonVariantsOptions, ShadcnButtonSize, ShadcnButtonVariant, buttonVariants };
1
+ import { a as ButtonVariant, i as ButtonSize, n as ButtonColor, o as ButtonVariantsOptions, r as ButtonProps, s as buttonVariants, t as Button } from "../Button-FX_hpqxm.js";
2
+ export { Button, ButtonColor, ButtonProps, ButtonSize, ButtonVariant, ButtonVariantsOptions, buttonVariants };
@@ -1,34 +1,12 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
2
  import { Button as Button$1 } from "@base-ui/react/button";
3
3
  //#region src/components/Button.tsx
4
- const SHADCN_BUTTON_VARIANT = {
5
- default: ["normal", "primary"],
6
- destructive: ["normal", "destructive"],
7
- outline: ["outline", "neutral"],
8
- secondary: ["normal", "neutral"],
9
- ghost: ["ghost", "neutral"],
10
- link: ["link", "primary"]
11
- };
12
- const SHADCN_BUTTON_SIZE = {
13
- default: "md",
14
- xs: "xs",
15
- sm: "sm",
16
- lg: "lg",
17
- icon: "icon",
18
- "icon-xs": "icon-xs",
19
- "icon-sm": "icon-sm",
20
- "icon-lg": "icon-lg"
21
- };
22
- function buttonVariants({ variant = "default", color, size = "default", className } = {}) {
23
- const buttonVariant = variant ?? "default";
24
- const mapped = buttonVariant === "normal" || buttonVariant === "outline" || buttonVariant === "ghost" || buttonVariant === "link" ? [buttonVariant, color ?? "primary"] : SHADCN_BUTTON_VARIANT[buttonVariant];
25
- const requestedSize = size ?? "default";
26
- const buttonSize = requestedSize === "default" ? "md" : SHADCN_BUTTON_SIZE[requestedSize] ?? requestedSize;
4
+ function buttonVariants({ variant = "normal", color = "primary", size = "md", className } = {}) {
27
5
  return [
28
6
  "button",
29
- `button--${mapped[0]}`,
30
- `button--${color ?? mapped[1]}`,
31
- `button--${buttonSize}`,
7
+ `button--${variant ?? "normal"}`,
8
+ `button--${color ?? "primary"}`,
9
+ `button--${size ?? "md"}`,
32
10
  className
33
11
  ].filter(Boolean).join(" ");
34
12
  }
@@ -37,8 +15,8 @@ function buttonVariants({ variant = "default", color, size = "default", classNam
37
15
  *
38
16
  * Separates visual style (`variant`) from color intent (`color`) for
39
17
  * maximum flexibility. Supports keyboard navigation, focus management, and
40
- * accessibility out of the box. Keeps shadcn-compatible variant and size
41
- * aliases for migration, while styling through Sigvelo CSS tokens.
18
+ * accessibility out of the box. Styling uses the design system's canonical
19
+ * visual variant, semantic color, and size axes.
42
20
  *
43
21
  * @example
44
22
  * ```tsx
@@ -49,9 +27,8 @@ function buttonVariants({ variant = "default", color, size = "default", classNam
49
27
  * ```
50
28
  *
51
29
  * @see {@link https://base-ui.com/react/components/button | Base UI Button}
52
- * @see {@link https://ui.shadcn.com/docs/components/base/button | shadcn/ui Button}
53
30
  */
54
- function Button({ variant = "default", color, size = "default", className, nativeButton, ref, ...props }) {
31
+ function Button({ variant = "normal", color = "primary", size = "md", className, nativeButton, ref, ...props }) {
55
32
  return /* @__PURE__ */ jsx(Button$1, {
56
33
  ref,
57
34
  "data-slot": "button",
@@ -1,9 +1,9 @@
1
- import { CollapsiblePanelProps, CollapsibleRootProps, CollapsibleTriggerProps } from "./Collapsible.js";
2
- import { v as IconProps } from "../icons-CbjtbIJK.js";
1
+ import { Collapsible } from "./Collapsible.js";
2
+ import { v as IconProps } from "../icons-CUCz_Sft.js";
3
3
  import * as React from "react";
4
4
 
5
5
  //#region src/components/ChainOfThought.d.ts
6
- interface ChainOfThoughtProps extends Omit<CollapsibleRootProps, "className" | "unstyled"> {
6
+ interface ChainOfThoughtProps extends Omit<React.ComponentProps<typeof Collapsible.Root>, "className" | "unstyled"> {
7
7
  className?: string;
8
8
  }
9
9
  /**
@@ -38,7 +38,7 @@ declare function ChainOfThought({
38
38
  }: ChainOfThoughtProps & {
39
39
  ref?: React.Ref<HTMLDivElement>;
40
40
  }): React.JSX.Element;
41
- interface ChainOfThoughtHeaderProps extends Omit<CollapsibleTriggerProps, "className" | "unstyled"> {
41
+ interface ChainOfThoughtHeaderProps extends Omit<React.ComponentProps<typeof Collapsible.Trigger>, "className" | "unstyled"> {
42
42
  className?: string;
43
43
  }
44
44
  /**
@@ -52,7 +52,7 @@ declare function ChainOfThoughtHeader({
52
52
  }: ChainOfThoughtHeaderProps & {
53
53
  ref?: React.Ref<HTMLButtonElement>;
54
54
  }): React.JSX.Element;
55
- interface ChainOfThoughtContentProps extends Omit<CollapsiblePanelProps, "className" | "unstyled"> {
55
+ interface ChainOfThoughtContentProps extends Omit<React.ComponentProps<typeof Collapsible.Panel>, "className" | "unstyled"> {
56
56
  className?: string;
57
57
  }
58
58
  /**
@@ -1,6 +1,6 @@
1
- import { CollapsiblePanel, CollapsibleRoot, CollapsibleTrigger } from "./Collapsible.js";
1
+ import { Collapsible } from "./Collapsible.js";
2
2
  import { t as cx } from "../class-names-9UtZwb0J.js";
3
- import { M as SpinnerIcon, a as CheckIcon, c as ChevronRightIcon, u as DotIcon } from "../icons-D2Q5n5C1.js";
3
+ import { N as SpinnerIcon, a as CheckIcon, c as ChevronRightIcon, u as DotIcon } from "../icons-Ba9THQKz.js";
4
4
  import "react";
5
5
  import { jsx, jsxs } from "react/jsx-runtime";
6
6
  //#region src/components/ChainOfThought.tsx
@@ -30,7 +30,7 @@ import { jsx, jsxs } from "react/jsx-runtime";
30
30
  * ```
31
31
  */
32
32
  function ChainOfThought({ className, ref, ...props }) {
33
- return /* @__PURE__ */ jsx(CollapsibleRoot, {
33
+ return /* @__PURE__ */ jsx(Collapsible.Root, {
34
34
  ref,
35
35
  className: cx("chain-of-thought", className),
36
36
  ...props,
@@ -41,12 +41,14 @@ function ChainOfThought({ className, ref, ...props }) {
41
41
  * Clickable header row that toggles the reasoning trace.
42
42
  */
43
43
  function ChainOfThoughtHeader({ className, children = "Chain of Thought", ref, ...props }) {
44
- return /* @__PURE__ */ jsxs(CollapsibleTrigger, {
44
+ return /* @__PURE__ */ jsxs(Collapsible.Trigger, {
45
45
  ref,
46
+ "data-slot": "chain-of-thought-trigger",
46
47
  className: cx("chain-of-thought__header", className),
47
48
  ...props,
48
49
  unstyled: true,
49
50
  children: [/* @__PURE__ */ jsx("span", {
51
+ "data-slot": "chain-of-thought-trigger-icon",
50
52
  className: "chain-of-thought__header-icon",
51
53
  "aria-hidden": "true",
52
54
  children: /* @__PURE__ */ jsx(ChevronRightIcon, {})
@@ -60,8 +62,9 @@ function ChainOfThoughtHeader({ className, children = "Chain of Thought", ref, .
60
62
  * Collapsible panel containing step rows.
61
63
  */
62
64
  function ChainOfThoughtContent({ className, children, ref, ...props }) {
63
- return /* @__PURE__ */ jsx(CollapsiblePanel, {
65
+ return /* @__PURE__ */ jsx(Collapsible.Panel, {
64
66
  ref,
67
+ "data-slot": "chain-of-thought-content",
65
68
  className: cx("chain-of-thought__content", className),
66
69
  ...props,
67
70
  unstyled: true,
@@ -1,7 +1,7 @@
1
1
  import { t as cx } from "../class-names-9UtZwb0J.js";
2
- import { M as SpinnerIcon } from "../icons-D2Q5n5C1.js";
2
+ import { N as SpinnerIcon } from "../icons-Ba9THQKz.js";
3
3
  import { Button } from "./Button.js";
4
- import { u as ModelSelectorLogo } from "../ModelSelector-DXtpcRmT.js";
4
+ import { u as ModelSelectorLogo } from "../ModelSelector-DVgVBdvw.js";
5
5
  import "react";
6
6
  import { jsx, jsxs } from "react/jsx-runtime";
7
7
  //#region src/components/ChatGptSignInScreen.tsx
@@ -40,7 +40,7 @@ function ChatGptSignInScreen({ busy = false, error = false, label = "Sign in wit
40
40
  ] })]
41
41
  }), /* @__PURE__ */ jsxs(Button, {
42
42
  type: "button",
43
- variant: "default",
43
+ variant: "normal",
44
44
  color: error ? "destructive" : "primary",
45
45
  size: "lg",
46
46
  className: "chatgpt-sign-in__button",
@@ -1,5 +1,5 @@
1
1
  import * as React from "react";
2
- import { CheckboxRootProps } from "@base-ui/react/checkbox";
2
+ import { Checkbox as Checkbox$1, CheckboxRootProps } from "@base-ui/react/checkbox";
3
3
 
4
4
  //#region src/components/Checkbox.d.ts
5
5
  /**
@@ -24,12 +24,20 @@ interface CheckboxProps extends Omit<CheckboxRootProps, "className"> {
24
24
  *
25
25
  * @see {@link https://base-ui.com/react/components/checkbox | Base UI Checkbox}
26
26
  */
27
- declare function Checkbox({
27
+ declare function CheckboxRoot({
28
28
  className,
29
29
  ref,
30
30
  ...props
31
31
  }: CheckboxProps & {
32
32
  ref?: React.Ref<HTMLButtonElement>;
33
33
  }): React.JSX.Element;
34
+ declare function CheckboxIndicator({
35
+ children,
36
+ ...props
37
+ }: Checkbox$1.Indicator.Props): React.JSX.Element;
38
+ declare const Checkbox: {
39
+ Root: typeof CheckboxRoot;
40
+ Indicator: typeof CheckboxIndicator;
41
+ };
34
42
  //#endregion
35
43
  export { Checkbox, CheckboxProps };
@@ -29,19 +29,26 @@ function CheckIcon(props) {
29
29
  *
30
30
  * @see {@link https://base-ui.com/react/components/checkbox | Base UI Checkbox}
31
31
  */
32
- function Checkbox({ className = "", ref, ...props }) {
32
+ function CheckboxRoot({ className = "", ref, ...props }) {
33
33
  const classes = ["checkbox", className].filter(Boolean).join(" ");
34
34
  return /* @__PURE__ */ jsx(Checkbox$1.Root, {
35
35
  ref,
36
36
  "data-slot": "checkbox",
37
37
  className: classes,
38
+ ...props
39
+ });
40
+ }
41
+ function CheckboxIndicator({ children, ...props }) {
42
+ return /* @__PURE__ */ jsx(Checkbox$1.Indicator, {
43
+ "data-slot": "checkbox-indicator",
44
+ className: "checkbox__indicator",
38
45
  ...props,
39
- children: /* @__PURE__ */ jsx(Checkbox$1.Indicator, {
40
- "data-slot": "checkbox-indicator",
41
- className: "checkbox__indicator",
42
- children: /* @__PURE__ */ jsx(CheckIcon, {})
43
- })
46
+ children: children ?? /* @__PURE__ */ jsx(CheckIcon, {})
44
47
  });
45
48
  }
49
+ const Checkbox = {
50
+ Root: CheckboxRoot,
51
+ Indicator: CheckboxIndicator
52
+ };
46
53
  //#endregion
47
54
  export { Checkbox };
@@ -18,11 +18,11 @@ interface CheckboxGroupProps extends Omit<React.ComponentPropsWithoutRef<typeof
18
18
  * // Basic usage
19
19
  * <CheckboxGroup defaultValue={['option1']}>
20
20
  * <label>
21
- * <Checkbox name="option1" />
21
+ * <Checkbox.Root name="option1" ><Checkbox.Indicator /></Checkbox.Root>
22
22
  * Option 1
23
23
  * </label>
24
24
  * <label>
25
- * <Checkbox name="option2" />
25
+ * <Checkbox.Root name="option2" ><Checkbox.Indicator /></Checkbox.Root>
26
26
  * Option 2
27
27
  * </label>
28
28
  * </CheckboxGroup>
@@ -35,11 +35,11 @@ interface CheckboxGroupProps extends Omit<React.ComponentPropsWithoutRef<typeof
35
35
  *
36
36
  * <CheckboxGroup value={values} onValueChange={setValues}>
37
37
  * <label>
38
- * <Checkbox name="email" />
38
+ * <Checkbox.Root name="email" ><Checkbox.Indicator /></Checkbox.Root>
39
39
  * Email notifications
40
40
  * </label>
41
41
  * <label>
42
- * <Checkbox name="sms" />
42
+ * <Checkbox.Root name="sms" ><Checkbox.Indicator /></Checkbox.Root>
43
43
  * SMS notifications
44
44
  * </label>
45
45
  * </CheckboxGroup>
@@ -52,11 +52,11 @@ interface CheckboxGroupProps extends Omit<React.ComponentPropsWithoutRef<typeof
52
52
  * <Fieldset.Legend>Notifications</Fieldset.Legend>
53
53
  * <CheckboxGroup defaultValue={['updates']}>
54
54
  * <label>
55
- * <Checkbox name="updates" />
55
+ * <Checkbox.Root name="updates" ><Checkbox.Indicator /></Checkbox.Root>
56
56
  * Product updates
57
57
  * </label>
58
58
  * <label>
59
- * <Checkbox name="newsletter" />
59
+ * <Checkbox.Root name="newsletter" ><Checkbox.Indicator /></Checkbox.Root>
60
60
  * Newsletter
61
61
  * </label>
62
62
  * </CheckboxGroup>
@@ -11,11 +11,11 @@ import { CheckboxGroup as CheckboxGroup$1 } from "@base-ui/react/checkbox-group"
11
11
  * // Basic usage
12
12
  * <CheckboxGroup defaultValue={['option1']}>
13
13
  * <label>
14
- * <Checkbox name="option1" />
14
+ * <Checkbox.Root name="option1" ><Checkbox.Indicator /></Checkbox.Root>
15
15
  * Option 1
16
16
  * </label>
17
17
  * <label>
18
- * <Checkbox name="option2" />
18
+ * <Checkbox.Root name="option2" ><Checkbox.Indicator /></Checkbox.Root>
19
19
  * Option 2
20
20
  * </label>
21
21
  * </CheckboxGroup>
@@ -28,11 +28,11 @@ import { CheckboxGroup as CheckboxGroup$1 } from "@base-ui/react/checkbox-group"
28
28
  *
29
29
  * <CheckboxGroup value={values} onValueChange={setValues}>
30
30
  * <label>
31
- * <Checkbox name="email" />
31
+ * <Checkbox.Root name="email" ><Checkbox.Indicator /></Checkbox.Root>
32
32
  * Email notifications
33
33
  * </label>
34
34
  * <label>
35
- * <Checkbox name="sms" />
35
+ * <Checkbox.Root name="sms" ><Checkbox.Indicator /></Checkbox.Root>
36
36
  * SMS notifications
37
37
  * </label>
38
38
  * </CheckboxGroup>
@@ -45,11 +45,11 @@ import { CheckboxGroup as CheckboxGroup$1 } from "@base-ui/react/checkbox-group"
45
45
  * <Fieldset.Legend>Notifications</Fieldset.Legend>
46
46
  * <CheckboxGroup defaultValue={['updates']}>
47
47
  * <label>
48
- * <Checkbox name="updates" />
48
+ * <Checkbox.Root name="updates" ><Checkbox.Indicator /></Checkbox.Root>
49
49
  * Product updates
50
50
  * </label>
51
51
  * <label>
52
- * <Checkbox name="newsletter" />
52
+ * <Checkbox.Root name="newsletter" ><Checkbox.Indicator /></Checkbox.Root>
53
53
  * Newsletter
54
54
  * </label>
55
55
  * </CheckboxGroup>
@@ -1,2 +1,2 @@
1
- import { A as CodeBlockLanguage, C as CodeBlockLanguageSelectorValueProps, D as TokenizedCode, E as CodeBlockTitleProps, O as highlightCode, S as CodeBlockLanguageSelectorValue, T as CodeBlockTitle, _ as CodeBlockLanguageSelectorItem, a as CodeBlockContainerProps, b as CodeBlockLanguageSelectorTrigger, c as CodeBlockCopyButton, d as CodeBlockFilenameProps, f as CodeBlockHeader, g as CodeBlockLanguageSelectorContentProps, h as CodeBlockLanguageSelectorContent, i as CodeBlockContainer, k as CODE_BLOCK_LANGUAGES, l as CodeBlockCopyButtonProps, m as CodeBlockLanguageSelector, n as CodeBlockActions, o as CodeBlockContent, p as CodeBlockHeaderProps, r as CodeBlockActionsProps, s as CodeBlockContentProps, t as CodeBlock, u as CodeBlockFilename, v as CodeBlockLanguageSelectorItemProps, w as CodeBlockProps, x as CodeBlockLanguageSelectorTriggerProps, y as CodeBlockLanguageSelectorProps } from "../CodeBlock-CxQXv3C4.js";
1
+ import { A as CodeBlockLanguage, C as CodeBlockLanguageSelectorValueProps, D as TokenizedCode, E as CodeBlockTitleProps, O as highlightCode, S as CodeBlockLanguageSelectorValue, T as CodeBlockTitle, _ as CodeBlockLanguageSelectorItem, a as CodeBlockContainerProps, b as CodeBlockLanguageSelectorTrigger, c as CodeBlockCopyButton, d as CodeBlockFilenameProps, f as CodeBlockHeader, g as CodeBlockLanguageSelectorContentProps, h as CodeBlockLanguageSelectorContent, i as CodeBlockContainer, k as CODE_BLOCK_LANGUAGES, l as CodeBlockCopyButtonProps, m as CodeBlockLanguageSelector, n as CodeBlockActions, o as CodeBlockContent, p as CodeBlockHeaderProps, r as CodeBlockActionsProps, s as CodeBlockContentProps, t as CodeBlock, u as CodeBlockFilename, v as CodeBlockLanguageSelectorItemProps, w as CodeBlockProps, x as CodeBlockLanguageSelectorTriggerProps, y as CodeBlockLanguageSelectorProps } from "../CodeBlock-DUh9WOGo.js";
2
2
  export { CODE_BLOCK_LANGUAGES, CodeBlock, CodeBlockActions, CodeBlockActionsProps, CodeBlockContainer, CodeBlockContainerProps, CodeBlockContent, CodeBlockContentProps, CodeBlockCopyButton, CodeBlockCopyButtonProps, CodeBlockFilename, CodeBlockFilenameProps, CodeBlockHeader, CodeBlockHeaderProps, type CodeBlockLanguage, CodeBlockLanguageSelector, CodeBlockLanguageSelectorContent, CodeBlockLanguageSelectorContentProps, CodeBlockLanguageSelectorItem, CodeBlockLanguageSelectorItemProps, CodeBlockLanguageSelectorProps, CodeBlockLanguageSelectorTrigger, CodeBlockLanguageSelectorTriggerProps, CodeBlockLanguageSelectorValue, CodeBlockLanguageSelectorValueProps, CodeBlockProps, CodeBlockTitle, CodeBlockTitleProps, TokenizedCode, highlightCode };
@@ -1,2 +1,2 @@
1
- import { a as CodeBlockCopyButton, c as CodeBlockLanguageSelector, d as CodeBlockLanguageSelectorTrigger, f as CodeBlockLanguageSelectorValue, h as CODE_BLOCK_LANGUAGES, i as CodeBlockContent, l as CodeBlockLanguageSelectorContent, m as highlightCode, n as CodeBlockActions, o as CodeBlockFilename, p as CodeBlockTitle, r as CodeBlockContainer, s as CodeBlockHeader, t as CodeBlock, u as CodeBlockLanguageSelectorItem } from "../CodeBlock-XNQOupQ3.js";
1
+ import { a as CodeBlockCopyButton, c as CodeBlockLanguageSelector, d as CodeBlockLanguageSelectorTrigger, f as CodeBlockLanguageSelectorValue, h as CODE_BLOCK_LANGUAGES, i as CodeBlockContent, l as CodeBlockLanguageSelectorContent, m as highlightCode, n as CodeBlockActions, o as CodeBlockFilename, p as CodeBlockTitle, r as CodeBlockContainer, s as CodeBlockHeader, t as CodeBlock, u as CodeBlockLanguageSelectorItem } from "../CodeBlock-BUFXG8HW.js";
2
2
  export { CODE_BLOCK_LANGUAGES, CodeBlock, CodeBlockActions, CodeBlockContainer, CodeBlockContent, CodeBlockCopyButton, CodeBlockFilename, CodeBlockHeader, CodeBlockLanguageSelector, CodeBlockLanguageSelectorContent, CodeBlockLanguageSelectorItem, CodeBlockLanguageSelectorTrigger, CodeBlockLanguageSelectorValue, CodeBlockTitle, highlightCode };
@@ -0,0 +1,58 @@
1
+ import { d as MenuProps } from "../Menu-Bgu-ufb5.js";
2
+ import { CodexModel } from "../utils/codex-model-catalog.js";
3
+ import * as React from "react";
4
+
5
+ //#region src/components/CodexModelSelector.d.ts
6
+ type ModelId<ModelT extends CodexModel> = ModelT["id"];
7
+ type ReasoningEffort<ModelT extends CodexModel> = ModelT["supportedReasoningEfforts"][number]["reasoningEffort"];
8
+ type ServiceTier<ModelT extends CodexModel> = ModelT["serviceTiers"][number]["id"];
9
+ interface CodexModelSelectorProps<ModelT extends CodexModel = CodexModel> {
10
+ /** Whole Codex app-server `model/list` entries allowed for this account. */
11
+ readonly models: readonly ModelT[];
12
+ /** Current Codex catalog id. Use the selected entry's `model` field for inference. */
13
+ readonly selectedModelId?: ModelId<ModelT> | null;
14
+ /** Called only with an id from the supplied Codex catalog. */
15
+ readonly onSelectModel: (modelId: ModelId<ModelT>) => void;
16
+ /** Current reasoning effort advertised by the selected model. */
17
+ readonly selectedEffortId?: ReasoningEffort<ModelT> | null;
18
+ readonly onSelectEffort?: (effortId: ReasoningEffort<ModelT>) => void;
19
+ /** Current service tier advertised by the selected model. */
20
+ readonly selectedSpeedId?: ServiceTier<ModelT> | null;
21
+ readonly onSelectSpeed?: (speedId: ServiceTier<ModelT> | null) => void;
22
+ /** Restores all values to the consuming app's preferred defaults. */
23
+ readonly onReset?: () => void;
24
+ readonly disabled?: boolean;
25
+ readonly className?: string;
26
+ /** Controlled menu open state. */
27
+ readonly open?: boolean;
28
+ /** Initial menu state for uncontrolled usage. */
29
+ readonly defaultOpen?: boolean;
30
+ /** Receives Base UI's full open-change event details. */
31
+ readonly onOpenChange?: MenuProps["onOpenChange"];
32
+ readonly "aria-label"?: string;
33
+ }
34
+ /**
35
+ * A compact Codex-style response settings picker: model, reasoning effort,
36
+ * response speed, and reset are kept in one cascading menu.
37
+ *
38
+ * The consuming app supplies every selectable value. This component only
39
+ * renders those values and never guesses model ids or account entitlements.
40
+ */
41
+ declare function CodexModelSelector<ModelT extends CodexModel>({
42
+ models,
43
+ selectedModelId,
44
+ onSelectModel,
45
+ selectedEffortId,
46
+ onSelectEffort,
47
+ selectedSpeedId,
48
+ onSelectSpeed,
49
+ onReset,
50
+ disabled,
51
+ className,
52
+ open,
53
+ defaultOpen,
54
+ onOpenChange,
55
+ "aria-label": ariaLabel
56
+ }: CodexModelSelectorProps<ModelT>): React.JSX.Element;
57
+ //#endregion
58
+ export { CodexModelSelector, CodexModelSelectorProps };