@mcp-b/react-components 0.40.0 → 0.41.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.
- package/dist/{AgentChat-CVO7xyLC.d.ts → AgentChat-DVr2giwD.d.ts} +1 -1
- package/dist/{AgentToolRunsContext-BCVqCtJ1.d.ts → AgentToolRunsContext-daY67hFM.d.ts} +12 -0
- package/dist/AppTopBar-ZdgmB_Lu.d.ts +97 -0
- package/dist/{CodeBlock-CWk1FVtm.js → CodeBlock-BjELA-_s.js} +1 -1
- package/dist/{FileTree-xqHYBw4g.js → FileTree-DMYRdT6R.js} +1 -1
- package/dist/McpConnectorForm-MRm1r59e.d.ts +39 -0
- package/dist/{Message-DBsHHhcM.d.ts → Message-D_vCVEGB.d.ts} +20 -1
- package/dist/{ThinkChatActivity-D6-_5Phw.d.ts → ThinkChatActivity-DyGHj01E.d.ts} +1 -1
- package/dist/{ThinkExecutionRun-lYYgyeE1.d.ts → ThinkExecutionRun-k8bpyXqt.d.ts} +3 -3
- package/dist/{ToggleGroup-_pQMyHGM.d.ts → ToggleGroup-BrQZOQn_.d.ts} +1 -1
- package/dist/Toolbar-CBOseBQr.d.ts +152 -0
- package/dist/{WorkspaceFileView-Lab3om3F.js → WorkspaceFileView-D0yFwoDr.js} +2 -2
- package/dist/{WorkspaceMessageResponse-Cy28WGSz.d.ts → WorkspaceMessageResponse-D66ty4FO.d.ts} +1 -1
- package/dist/components/agents-sdk/AgentActivity.js +1 -1
- package/dist/components/agents-sdk/AgentChat.d.ts +1 -1
- package/dist/components/agents-sdk/AgentChat.js +41 -18
- package/dist/components/agents-sdk/AgentToolRunsContext.d.ts +1 -1
- package/dist/components/agents-sdk/AgentToolRunsContext.js +12 -0
- package/dist/components/agents-sdk/BrowserLiveScreen.d.ts +135 -0
- package/dist/components/agents-sdk/BrowserLiveScreen.js +637 -0
- package/dist/components/agents-sdk/BrowserLiveView.d.ts +2 -2
- package/dist/components/agents-sdk/BrowserLiveView.js +6 -9
- package/dist/components/agents-sdk/BrowserReplay.js +1 -1
- package/dist/components/agents-sdk/BrowserRunPanel.d.ts +1 -1
- package/dist/components/agents-sdk/BrowserRunPanel.js +6 -12
- package/dist/components/agents-sdk/ManagerOffice.d.ts +156 -0
- package/dist/components/agents-sdk/ManagerOffice.js +662 -0
- package/dist/components/agents-sdk/McpConnectionRequest.js +3 -3
- package/dist/components/agents-sdk/McpConnectorForm.d.ts +1 -38
- package/dist/components/agents-sdk/McpPluginCatalog.d.ts +8 -2
- package/dist/components/agents-sdk/McpPluginCatalog.js +80 -62
- package/dist/components/agents-sdk/McpServerPicker.d.ts +1 -1
- package/dist/components/agents-sdk/McpServerPicker.js +2 -2
- package/dist/components/agents-sdk/ModelSelector.js +2 -2
- package/dist/components/agents-sdk/PromptInputCommands.js +1 -1
- package/dist/components/agents-sdk/SubagentRunDetails.d.ts +1 -9
- package/dist/components/agents-sdk/SubagentRunDetails.js +1 -9
- package/dist/components/agents-sdk/SubagentRunIndicator.js +1 -1
- package/dist/components/agents-sdk/SubagentRunSelector.d.ts +4 -2
- package/dist/components/agents-sdk/SubagentRunSelector.js +7 -6
- package/dist/components/agents-sdk/ThinkChat.d.ts +4 -4
- package/dist/components/agents-sdk/ThinkChat.js +1 -1
- package/dist/components/agents-sdk/ThinkChatActivity.d.ts +1 -1
- package/dist/components/agents-sdk/ThinkChatActivity.js +1 -1
- package/dist/components/agents-sdk/ThinkChatToolPanels.js +1 -1
- package/dist/components/agents-sdk/ThinkExecutionDetail.d.ts +1 -1
- package/dist/components/agents-sdk/ThinkExecutionDetail.js +43 -43
- package/dist/components/agents-sdk/ThinkExecutionRun.d.ts +2 -2
- package/dist/components/agents-sdk/ThinkExecutionRun.js +5 -6
- package/dist/components/agents-sdk/ThinkExecutionStatus.d.ts +1 -1
- package/dist/components/agents-sdk/ThinkExecutionStatus.js +8 -12
- package/dist/components/agents-sdk/ThinkExecutionWorkbench.d.ts +8 -1
- package/dist/components/agents-sdk/ThinkExecutionWorkbench.js +42 -37
- package/dist/components/agents-sdk/ThinkFullApp.d.ts +18 -6
- package/dist/components/agents-sdk/ThinkFullApp.js +113 -145
- package/dist/components/agents-sdk/ThinkFullAppViewSwitch.d.ts +1 -1
- package/dist/components/agents-sdk/ThinkFullAppViewSwitch.js +1 -1
- package/dist/components/agents-sdk/ThinkRoutine.d.ts +1 -1
- package/dist/components/agents-sdk/ThinkRoutineBrowser.js +1 -1
- package/dist/components/agents-sdk/ThinkRoutineDetail.js +5 -16
- package/dist/components/agents-sdk/ThinkRoutineForm.js +1 -1
- package/dist/components/agents-sdk/ThinkRoutineLibrary.js +69 -89
- package/dist/components/agents-sdk/ThinkRoutineRuns.d.ts +1 -1
- package/dist/components/agents-sdk/ThinkRoutineRuns.js +3 -10
- package/dist/components/agents-sdk/ThinkThreadPicker.js +2 -2
- package/dist/components/agents-sdk/WorkspaceBrowser.js +1 -1
- package/dist/components/agents-sdk/WorkspaceExplorer.js +1 -1
- package/dist/components/agents-sdk/WorkspaceFileView.js +1 -1
- package/dist/components/agents-sdk/WorkspaceHeader.js +2 -1
- package/dist/components/agents-sdk/WorkspaceMessageResponse.d.ts +1 -1
- package/dist/components/agents-sdk/WorkspaceMountManager.js +11 -11
- package/dist/components/ai-sdk/Activity.js +1 -1
- package/dist/components/ai-sdk/AgentAttention.d.ts +1 -1
- package/dist/components/ai-sdk/AgentChatStartScreen.js +1 -1
- package/dist/components/ai-sdk/Approval.js +1 -1
- package/dist/components/ai-sdk/Artifact.js +1 -1
- package/dist/components/ai-sdk/ChainOfThought.d.ts +1 -1
- package/dist/components/ai-sdk/ChainOfThought.js +1 -1
- package/dist/components/ai-sdk/Checkpoint.js +1 -1
- package/dist/components/ai-sdk/CodeBlock.js +1 -1
- package/dist/components/ai-sdk/Conversation.js +1 -1
- package/dist/components/ai-sdk/Goal.js +1 -1
- package/dist/components/ai-sdk/MediaPreviewCard.js +1 -1
- package/dist/components/ai-sdk/Message.d.ts +2 -2
- package/dist/components/ai-sdk/Message.js +25 -3
- package/dist/components/ai-sdk/MessageScroller.js +1 -1
- package/dist/components/ai-sdk/MessageScrollerVirtual.js +1 -1
- package/dist/components/ai-sdk/Plan.js +1 -1
- package/dist/components/ai-sdk/PromptInput.js +1 -1
- package/dist/components/ai-sdk/Queue.d.ts +4 -4
- package/dist/components/ai-sdk/Queue.js +6 -15
- package/dist/components/ai-sdk/Reasoning.js +1 -1
- package/dist/components/ai-sdk/Sources.js +1 -1
- package/dist/components/ai-sdk/Task.d.ts +2 -2
- package/dist/components/ai-sdk/Task.js +2 -2
- package/dist/components/extension/ChatGptSignInScreen.js +1 -1
- package/dist/components/extension/CodexModelSelector.js +1 -1
- package/dist/components/extension/ConversationTabPicker.js +1 -1
- package/dist/components/foundations/Avatar.d.ts +1 -10
- package/dist/components/foundations/Avatar.js +1 -10
- package/dist/components/foundations/Checkbox.js +1 -1
- package/dist/components/foundations/CheckboxGroup.js +1 -0
- package/dist/components/foundations/ContextMenu.js +1 -1
- package/dist/components/foundations/LinkButton.d.ts +12 -10
- package/dist/components/foundations/LinkButton.js +15 -11
- package/dist/components/foundations/Menubar.js +1 -1
- package/dist/components/foundations/SearchField.js +1 -1
- package/dist/components/foundations/Select.js +1 -1
- package/dist/components/foundations/Stepper.js +1 -1
- package/dist/components/foundations/Toast.js +1 -1
- package/dist/components/foundations/ToggleGroup.d.ts +1 -1
- package/dist/components/foundations/ToggleGroup.js +1 -1
- package/dist/components/foundations/Toolbar.d.ts +1 -151
- package/dist/components/foundations/icons.d.ts +2 -2
- package/dist/components/foundations/icons.js +2 -2
- package/dist/components/general-purpose/AppTopBar.d.ts +1 -90
- package/dist/components/general-purpose/AppTopBar.js +2 -1
- package/dist/components/general-purpose/Commit.d.ts +2 -2
- package/dist/components/general-purpose/Commit.js +5 -13
- package/dist/components/general-purpose/EnvironmentVariables.d.ts +2 -2
- package/dist/components/general-purpose/EnvironmentVariables.js +4 -7
- package/dist/components/general-purpose/FileTree.js +1 -1
- package/dist/components/general-purpose/PricingBillingToggle.js +5 -10
- package/dist/components/general-purpose/PricingPlanCard.js +15 -14
- package/dist/components/general-purpose/PricingUsageCalculator.js +1 -1
- package/dist/components/general-purpose/ResponsiveSidebarShell.d.ts +95 -2
- package/dist/components/general-purpose/ResponsiveSidebarShell.js +90 -34
- package/dist/components/general-purpose/SetupChecklist.js +1 -1
- package/dist/components/general-purpose/Terminal.d.ts +1 -1
- package/dist/components/general-purpose/Terminal.js +4 -12
- package/dist/components/general-purpose/TestResults.d.ts +1 -1
- package/dist/components/general-purpose/TestResults.js +8 -21
- package/dist/components/general-purpose/ThemeModeControl.js +1 -1
- package/dist/components/general-purpose/WebPreview.d.ts +1 -1
- package/dist/components/general-purpose/WebPreview.js +4 -12
- package/dist/components/nanites/AgentConnection.js +2 -2
- package/dist/components/nanites/AgentToolDetail.d.ts +1 -1
- package/dist/components/nanites/AgentToolDetail.js +7 -7
- package/dist/components/nanites/NaniteScene.js +11 -11
- package/dist/{copy-button-Bc7jsYv_.js → copy-button-lys9N_aI.js} +1 -1
- package/dist/{icons-DwgNir1Q.d.ts → icons-0corjfxR.d.ts} +1 -16
- package/dist/{icons-MmIXciMO.js → icons-CVFSeTJn.js} +2 -5
- package/dist/styles/agent-attention.css +5 -5
- package/dist/styles/agent-chat.css +47 -12
- package/dist/styles/agent-tool-detail.css +2 -12
- package/dist/styles/app-icon.css +12 -18
- package/dist/styles/app-top-bar.css +32 -6
- package/dist/styles/avatar.css +6 -22
- package/dist/styles/base.css +2 -8
- package/dist/styles/browser-live-screen.css +38 -0
- package/dist/styles/browser-live-view.css +12 -4
- package/dist/styles/browser-run-panel.css +20 -18
- package/dist/styles/chatgpt-sign-in-screen.css +5 -5
- package/dist/styles/commit.css +24 -1
- package/dist/styles/environment-variables.css +3 -0
- package/dist/styles/index.css +5 -4
- package/dist/styles/manager-office.css +486 -0
- package/dist/styles/mcp-plugin-catalog.css +39 -35
- package/dist/styles/mcp-server-picker.css +1 -1
- package/dist/styles/message.css +41 -18
- package/dist/styles/nanite-scene.css +9 -9
- package/dist/styles/pricing-page.css +12 -8
- package/dist/styles/prompt-input.css +8 -13
- package/dist/styles/recipes.css +1 -57
- package/dist/styles/responsive-sidebar-shell.css +70 -20
- package/dist/styles/subagent-run.css +20 -3
- package/dist/styles/terminal.css +19 -0
- package/dist/styles/test-results.css +10 -1
- package/dist/styles/think-execution-status.css +8 -24
- package/dist/styles/think-execution-workbench.css +98 -105
- package/dist/styles/think-full-app.css +81 -193
- package/dist/styles/think-routine-library.css +0 -40
- package/dist/styles/think-thread-picker.css +8 -3
- package/dist/styles/transition-surface.css +7 -8
- package/dist/styles/utilities.css +42 -0
- package/dist/styles/web-preview.css +28 -5
- package/dist/styles/workspace-explorer.css +4 -23
- package/dist/styles/workspace-mount-manager.css +22 -0
- package/package.json +37 -35
- package/dist/ResponsiveSidebarShell-DWjULskY.d.ts +0 -68
- package/dist/components/agents-sdk/AgentActivityPreview.d.ts +0 -46
- package/dist/components/agents-sdk/AgentActivityPreview.js +0 -93
- package/dist/components/agents-sdk/ThinkThreadShell.d.ts +0 -38
- package/dist/components/agents-sdk/ThinkThreadShell.js +0 -27
- package/dist/components/foundations/Badge.d.ts +0 -62
- package/dist/components/foundations/Badge.js +0 -55
- package/dist/components/foundations/StatusPill.d.ts +0 -43
- package/dist/components/foundations/StatusPill.js +0 -35
- package/dist/components/general-purpose/Shell.d.ts +0 -149
- package/dist/components/general-purpose/Shell.js +0 -116
- package/dist/styles/agent-activity-preview-overlay.css +0 -169
- package/dist/styles/agent-activity-preview.css +0 -209
- package/dist/styles/badge.css +0 -120
- package/dist/styles/shell.css +0 -122
- package/dist/styles/status-pill.css +0 -39
- package/dist/{ThinkChat-DkA4Wr71.js → ThinkChat-BES_3Mb-.js} +1 -1
|
@@ -1,2 +1,95 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { t as AppTopBar } from "../../AppTopBar-ZdgmB_Lu.js";
|
|
2
|
+
import * as React from "react";
|
|
3
|
+
|
|
4
|
+
//#region src/components/general-purpose/ResponsiveSidebarShell.d.ts
|
|
5
|
+
interface ResponsiveSidebarShellControls {
|
|
6
|
+
/** Close the sidebar and move focus to the main content. */
|
|
7
|
+
closeSidebar: () => void;
|
|
8
|
+
/** Close only when the shell is currently using its compact drawer layout. */
|
|
9
|
+
closeSidebarOnCompact: () => void;
|
|
10
|
+
}
|
|
11
|
+
interface ResponsiveSidebarShellProps extends Omit<React.HTMLAttributes<HTMLDivElement>, "children" | "title"> {
|
|
12
|
+
/**
|
|
13
|
+
* Navigation or other secondary surface shown beside the selected content.
|
|
14
|
+
* Omit for a shell that is only a bar row over content — the app bar then
|
|
15
|
+
* has one mount point whether or not a sidebar exists.
|
|
16
|
+
*/
|
|
17
|
+
sidebar?: React.ReactNode | ((controls: ResponsiveSidebarShellControls) => React.ReactNode);
|
|
18
|
+
/** Main content. */
|
|
19
|
+
children?: React.ReactNode;
|
|
20
|
+
/** Short noun used by the toggle and resize control, such as “threads” or “schedules”. */
|
|
21
|
+
sidebarLabel?: string;
|
|
22
|
+
/** Whether the sidebar is open. Omit for internal state. */
|
|
23
|
+
sidebarOpen?: boolean;
|
|
24
|
+
/** Initial sidebar state when `sidebarOpen` is uncontrolled. */
|
|
25
|
+
defaultSidebarOpen?: boolean;
|
|
26
|
+
/** Initial desktop sidebar width in CSS pixels. */
|
|
27
|
+
defaultSidebarWidth?: number;
|
|
28
|
+
/** Called when the sidebar is opened or closed. */
|
|
29
|
+
onSidebarOpenChange?: (open: boolean) => void;
|
|
30
|
+
/**
|
|
31
|
+
* No bar row at all — for content that brings its own application bar.
|
|
32
|
+
* Distinct from passing no slots: an empty shell with a sidebar still shows
|
|
33
|
+
* a bar carrying the toggle.
|
|
34
|
+
*/
|
|
35
|
+
topBarHidden?: boolean;
|
|
36
|
+
/** Props for the shell-owned bar root: `aria-label`, `className`, data hooks. */
|
|
37
|
+
topBarProps?: React.ComponentProps<typeof AppTopBar.Root> & {
|
|
38
|
+
[dataAttribute: `data-${string}`]: string | undefined;
|
|
39
|
+
};
|
|
40
|
+
/**
|
|
41
|
+
* App-owned leading navigation. When present it owns the single leading
|
|
42
|
+
* slot instead of sitting beside a second shell toggle; wide sidebars use
|
|
43
|
+
* their responsive default and compact sidebars remain available through
|
|
44
|
+
* `compactTitleTrigger`.
|
|
45
|
+
*/
|
|
46
|
+
topBarLeading?: React.ReactNode;
|
|
47
|
+
/** Compact-only navigation that replaces the drawer trigger without hiding the wide rail toggle. */
|
|
48
|
+
compactTopBarLeading?: React.ReactNode;
|
|
49
|
+
/** Bar title content. Hidden at compact widths when `compactTitleTrigger` stands in. */
|
|
50
|
+
topBarTitle?: React.ReactNode;
|
|
51
|
+
/** Element the bar title renders into, e.g. `<h1 id={…}/>` for a labelled page. */
|
|
52
|
+
topBarTitleRender?: React.ReactElement<Record<string, unknown>>;
|
|
53
|
+
/** Content placed in the bar's trailing group. */
|
|
54
|
+
topBarTrailing?: React.ReactNode;
|
|
55
|
+
/**
|
|
56
|
+
* Label content for a compact-width drawer trigger that replaces the plain
|
|
57
|
+
* title and the icon toggle: the title itself becomes the control that opens
|
|
58
|
+
* the sidebar. The shell renders the button and the disclosure chevron.
|
|
59
|
+
*/
|
|
60
|
+
compactTitleTrigger?: React.ReactNode;
|
|
61
|
+
/** Accessible name for the mobile peek target that returns to the main content. */
|
|
62
|
+
showMainLabel?: string;
|
|
63
|
+
}
|
|
64
|
+
/**
|
|
65
|
+
* The one application shell: responsive master-detail with a resizable desktop
|
|
66
|
+
* sidebar, a compact floating drawer that leaves the main content in place as
|
|
67
|
+
* a dismiss target, and a shell-owned application bar composed from slots.
|
|
68
|
+
* The root exposes `data-sidebar-open="true" | "false"` as its public styling hook.
|
|
69
|
+
*/
|
|
70
|
+
declare function ResponsiveSidebarShell({
|
|
71
|
+
sidebar,
|
|
72
|
+
sidebarLabel,
|
|
73
|
+
sidebarOpen,
|
|
74
|
+
defaultSidebarOpen,
|
|
75
|
+
defaultSidebarWidth,
|
|
76
|
+
onSidebarOpenChange,
|
|
77
|
+
topBarHidden,
|
|
78
|
+
topBarProps,
|
|
79
|
+
topBarLeading,
|
|
80
|
+
compactTopBarLeading,
|
|
81
|
+
topBarTitle,
|
|
82
|
+
topBarTitleRender,
|
|
83
|
+
topBarTrailing,
|
|
84
|
+
compactTitleTrigger,
|
|
85
|
+
showMainLabel,
|
|
86
|
+
className,
|
|
87
|
+
children,
|
|
88
|
+
ref,
|
|
89
|
+
style,
|
|
90
|
+
...props
|
|
91
|
+
}: ResponsiveSidebarShellProps & {
|
|
92
|
+
ref?: React.Ref<HTMLDivElement>;
|
|
93
|
+
}): React.JSX.Element;
|
|
94
|
+
//#endregion
|
|
95
|
+
export { ResponsiveSidebarShell, ResponsiveSidebarShellControls, ResponsiveSidebarShellProps };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { t as cx } from "../../class-names-BiMDVpUo.js";
|
|
2
|
-
import {
|
|
2
|
+
import { W as SidebarIcon, f as ChevronDownIcon } from "../../icons-CVFSeTJn.js";
|
|
3
3
|
import { Button } from "../foundations/Button.js";
|
|
4
4
|
import { t as capitalize } from "../../format-DB2mX9DA.js";
|
|
5
5
|
import { n as mergeRefs } from "../../merge-refs-DF_7w2x_.js";
|
|
@@ -15,30 +15,67 @@ const sidebarKeyboardStep = 24;
|
|
|
15
15
|
const compactSidebarWidthRem = 56;
|
|
16
16
|
function useControllableSidebar({ sidebarOpen, defaultSidebarOpen, onSidebarOpenChange }) {
|
|
17
17
|
const [innerOpen, setInnerOpen] = React.useState(defaultSidebarOpen ?? true);
|
|
18
|
-
return [
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
18
|
+
return [
|
|
19
|
+
sidebarOpen ?? innerOpen,
|
|
20
|
+
React.useCallback((next) => {
|
|
21
|
+
if (sidebarOpen === void 0) setInnerOpen(next);
|
|
22
|
+
onSidebarOpenChange?.(next);
|
|
23
|
+
}, [sidebarOpen, onSidebarOpenChange]),
|
|
24
|
+
setInnerOpen
|
|
25
|
+
];
|
|
22
26
|
}
|
|
23
27
|
function isCompactSidebar(root) {
|
|
24
28
|
const rootFontSize = Number.parseFloat(getComputedStyle(document.documentElement).fontSize) || 16;
|
|
25
|
-
return root.
|
|
29
|
+
return root.offsetWidth <= compactSidebarWidthRem * rootFontSize;
|
|
26
30
|
}
|
|
27
31
|
/**
|
|
28
|
-
*
|
|
29
|
-
* floating
|
|
32
|
+
* The one application shell: responsive master-detail with a resizable desktop
|
|
33
|
+
* sidebar, a compact floating drawer that leaves the main content in place as
|
|
34
|
+
* a dismiss target, and a shell-owned application bar composed from slots.
|
|
30
35
|
* The root exposes `data-sidebar-open="true" | "false"` as its public styling hook.
|
|
31
36
|
*/
|
|
32
|
-
function ResponsiveSidebarShell({ sidebar,
|
|
37
|
+
function ResponsiveSidebarShell({ sidebar, sidebarLabel = "sidebar", sidebarOpen, defaultSidebarOpen, defaultSidebarWidth = sidebarDefaultWidth, onSidebarOpenChange, topBarHidden = false, topBarProps, topBarLeading, compactTopBarLeading, topBarTitle, topBarTitleRender, topBarTrailing, compactTitleTrigger, showMainLabel = "Show main content", className, children, ref, style, ...props }) {
|
|
33
38
|
const sidebarId = React.useId();
|
|
34
39
|
const rootRef = React.useRef(null);
|
|
35
40
|
const mainRef = React.useRef(null);
|
|
36
41
|
const openerRef = React.useRef(null);
|
|
37
|
-
const
|
|
42
|
+
const compactRef = React.useRef(null);
|
|
43
|
+
const restoreSidebarOnWideRef = React.useRef(true);
|
|
44
|
+
const [isSidebarOpen, setSidebarOpen, primeSidebarOpen] = useControllableSidebar({
|
|
38
45
|
sidebarOpen,
|
|
39
46
|
defaultSidebarOpen,
|
|
40
47
|
onSidebarOpenChange
|
|
41
48
|
});
|
|
49
|
+
const wantsBuiltInDefault = sidebarOpen === void 0 && defaultSidebarOpen === void 0;
|
|
50
|
+
React.useLayoutEffect(() => {
|
|
51
|
+
const root = rootRef.current;
|
|
52
|
+
if (!root) return;
|
|
53
|
+
const syncLayout = () => {
|
|
54
|
+
if (root.offsetWidth <= 0) return;
|
|
55
|
+
const compact = isCompactSidebar(root);
|
|
56
|
+
const wasCompact = compactRef.current;
|
|
57
|
+
compactRef.current = compact;
|
|
58
|
+
if (wasCompact === null) {
|
|
59
|
+
if (wantsBuiltInDefault && compact) primeSidebarOpen(false);
|
|
60
|
+
return;
|
|
61
|
+
}
|
|
62
|
+
if (!wasCompact && compact) {
|
|
63
|
+
restoreSidebarOnWideRef.current = isSidebarOpen;
|
|
64
|
+
if (isSidebarOpen) setSidebarOpen(false);
|
|
65
|
+
} else if (wasCompact && !compact && restoreSidebarOnWideRef.current) setSidebarOpen(true);
|
|
66
|
+
};
|
|
67
|
+
syncLayout();
|
|
68
|
+
if (typeof ResizeObserver === "undefined") return;
|
|
69
|
+
const observer = new ResizeObserver(syncLayout);
|
|
70
|
+
observer.observe(root);
|
|
71
|
+
return () => observer.disconnect();
|
|
72
|
+
}, [
|
|
73
|
+
isSidebarOpen,
|
|
74
|
+
primeSidebarOpen,
|
|
75
|
+
setSidebarOpen,
|
|
76
|
+
wantsBuiltInDefault
|
|
77
|
+
]);
|
|
78
|
+
const hasSidebar = sidebar != null;
|
|
42
79
|
const toggleLabel = capitalize(sidebarLabel);
|
|
43
80
|
const toggleTooltip = `${isSidebarOpen ? "Hide" : "Show"} ${sidebarLabel}`;
|
|
44
81
|
const updateSidebar = React.useCallback((update, restoreFocus) => {
|
|
@@ -66,8 +103,9 @@ function ResponsiveSidebarShell({ sidebar, topBar, sidebarLabel, sidebarOpen, de
|
|
|
66
103
|
closeSidebar,
|
|
67
104
|
closeSidebarOnCompact
|
|
68
105
|
}) : sidebar;
|
|
69
|
-
const
|
|
70
|
-
|
|
106
|
+
const hasTitleTrigger = hasSidebar && compactTitleTrigger != null && compactTopBarLeading == null;
|
|
107
|
+
const renderSidebarToggle = (className) => hasSidebar ? /* @__PURE__ */ jsx(AppTopBar.Button, {
|
|
108
|
+
className: cx("responsive-sidebar-shell__toggle", className),
|
|
71
109
|
label: toggleLabel,
|
|
72
110
|
tooltip: toggleTooltip,
|
|
73
111
|
type: "button",
|
|
@@ -75,30 +113,22 @@ function ResponsiveSidebarShell({ sidebar, topBar, sidebarLabel, sidebarOpen, de
|
|
|
75
113
|
"aria-expanded": isSidebarOpen,
|
|
76
114
|
onClick: (event) => toggleSidebar(event.currentTarget),
|
|
77
115
|
children: /* @__PURE__ */ jsx(SidebarIcon, {})
|
|
78
|
-
});
|
|
79
|
-
const
|
|
80
|
-
|
|
81
|
-
sidebarOpen: isSidebarOpen,
|
|
82
|
-
sidebarToggle,
|
|
83
|
-
toggleSidebar
|
|
84
|
-
}) : topBar;
|
|
85
|
-
return /* @__PURE__ */ jsxs("div", {
|
|
116
|
+
}) : null;
|
|
117
|
+
const hasTopBar = !topBarHidden && (hasSidebar || topBarLeading != null || compactTopBarLeading != null || topBarTitle != null || topBarTrailing != null || topBarProps != null);
|
|
118
|
+
return /* @__PURE__ */ jsx("div", {
|
|
86
119
|
ref: mergeRefs(rootRef, ref),
|
|
87
120
|
className: cx("responsive-sidebar-shell", className),
|
|
88
121
|
style,
|
|
89
122
|
...props,
|
|
90
|
-
"data-sidebar-open": isSidebarOpen ? "true" : "false",
|
|
123
|
+
"data-sidebar-open": hasSidebar && isSidebarOpen ? "true" : "false",
|
|
91
124
|
onKeyDown: (event) => {
|
|
92
125
|
props.onKeyDown?.(event);
|
|
93
|
-
if (!event.defaultPrevented && event.key === "Escape" && isSidebarOpen && rootRef.current && isCompactSidebar(rootRef.current)) {
|
|
126
|
+
if (!event.defaultPrevented && event.key === "Escape" && hasSidebar && isSidebarOpen && rootRef.current && isCompactSidebar(rootRef.current)) {
|
|
94
127
|
event.preventDefault();
|
|
95
128
|
dismissSidebar();
|
|
96
129
|
}
|
|
97
130
|
},
|
|
98
|
-
children:
|
|
99
|
-
"aria-label": toolbarLabel,
|
|
100
|
-
children: /* @__PURE__ */ jsx(AppTopBar.Leading, { children: sidebarToggle })
|
|
101
|
-
}), /* @__PURE__ */ jsxs(ResizableSidePanel.Root, {
|
|
131
|
+
children: /* @__PURE__ */ jsxs(ResizableSidePanel.Root, {
|
|
102
132
|
className: "responsive-sidebar-shell__frame",
|
|
103
133
|
label: sidebarLabel,
|
|
104
134
|
side: "start",
|
|
@@ -107,22 +137,48 @@ function ResponsiveSidebarShell({ sidebar, topBar, sidebarLabel, sidebarOpen, de
|
|
|
107
137
|
maxSize: sidebarMaxWidth,
|
|
108
138
|
keyboardStep: sidebarKeyboardStep,
|
|
109
139
|
children: [
|
|
110
|
-
isSidebarOpen ? /* @__PURE__ */ jsx(ResizableSidePanel.Handle, { className: "responsive-sidebar-shell__resizer" }) : null,
|
|
111
|
-
/* @__PURE__ */ jsx("div", {
|
|
140
|
+
hasSidebar && isSidebarOpen ? /* @__PURE__ */ jsx(ResizableSidePanel.Handle, { className: "responsive-sidebar-shell__resizer" }) : null,
|
|
141
|
+
hasSidebar ? /* @__PURE__ */ jsx("div", {
|
|
112
142
|
id: sidebarId,
|
|
113
143
|
className: "responsive-sidebar-shell__sidebar",
|
|
114
144
|
"aria-hidden": isSidebarOpen ? void 0 : true,
|
|
115
145
|
inert: isSidebarOpen ? void 0 : true,
|
|
116
146
|
children: sidebarContent
|
|
117
|
-
}),
|
|
118
|
-
/* @__PURE__ */
|
|
147
|
+
}) : null,
|
|
148
|
+
/* @__PURE__ */ jsxs("div", {
|
|
119
149
|
ref: mainRef,
|
|
120
150
|
className: "responsive-sidebar-shell__main",
|
|
121
|
-
"data-recipe": "application-plane",
|
|
122
151
|
tabIndex: -1,
|
|
123
|
-
children
|
|
152
|
+
children: [hasTopBar ? /* @__PURE__ */ jsxs(AppTopBar.Root, {
|
|
153
|
+
"aria-label": "Application controls",
|
|
154
|
+
...topBarProps,
|
|
155
|
+
children: [
|
|
156
|
+
hasSidebar || topBarLeading != null || compactTopBarLeading != null ? /* @__PURE__ */ jsxs(AppTopBar.Leading, { children: [topBarLeading ?? renderSidebarToggle(hasTitleTrigger ? "responsive-sidebar-shell__toggle--replaced-by-title" : compactTopBarLeading != null ? "responsive-sidebar-shell__toggle--replaced-by-compact-leading" : void 0), topBarLeading == null && compactTopBarLeading != null ? /* @__PURE__ */ jsx("span", {
|
|
157
|
+
className: "responsive-sidebar-shell__compact-leading",
|
|
158
|
+
children: compactTopBarLeading
|
|
159
|
+
}) : null] }) : null,
|
|
160
|
+
topBarTitle != null || hasTitleTrigger ? /* @__PURE__ */ jsxs(AppTopBar.Title, {
|
|
161
|
+
render: topBarTitleRender,
|
|
162
|
+
children: [topBarTitle != null ? /* @__PURE__ */ jsx("span", {
|
|
163
|
+
className: cx("responsive-sidebar-shell__title-text", hasTitleTrigger && "responsive-sidebar-shell__title-text--replaced-by-trigger"),
|
|
164
|
+
children: topBarTitle
|
|
165
|
+
}) : null, hasTitleTrigger ? /* @__PURE__ */ jsxs(Button, {
|
|
166
|
+
type: "button",
|
|
167
|
+
variant: "ghost",
|
|
168
|
+
color: "neutral",
|
|
169
|
+
size: "sm",
|
|
170
|
+
className: "responsive-sidebar-shell__title-trigger",
|
|
171
|
+
"aria-controls": sidebarId,
|
|
172
|
+
"aria-expanded": isSidebarOpen,
|
|
173
|
+
onClick: (event) => toggleSidebar(event.currentTarget),
|
|
174
|
+
children: [compactTitleTrigger, /* @__PURE__ */ jsx(ChevronDownIcon, { "aria-hidden": "true" })]
|
|
175
|
+
}) : null]
|
|
176
|
+
}) : null,
|
|
177
|
+
topBarTrailing != null ? /* @__PURE__ */ jsx(AppTopBar.Trailing, { children: topBarTrailing }) : null
|
|
178
|
+
]
|
|
179
|
+
}) : null, children]
|
|
124
180
|
}),
|
|
125
|
-
isSidebarOpen ? /* @__PURE__ */ jsx(Button, {
|
|
181
|
+
hasSidebar && isSidebarOpen ? /* @__PURE__ */ jsx(Button, {
|
|
126
182
|
type: "button",
|
|
127
183
|
variant: "ghost",
|
|
128
184
|
color: "neutral",
|
|
@@ -131,7 +187,7 @@ function ResponsiveSidebarShell({ sidebar, topBar, sidebarLabel, sidebarOpen, de
|
|
|
131
187
|
onClick: closeSidebar
|
|
132
188
|
}) : null
|
|
133
189
|
]
|
|
134
|
-
})
|
|
190
|
+
})
|
|
135
191
|
});
|
|
136
192
|
}
|
|
137
193
|
//#endregion
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { n as mergeBaseClassName } from "../../class-names-BiMDVpUo.js";
|
|
2
|
-
import {
|
|
2
|
+
import { $ as WarningIcon, B as PlusIcon, d as CheckIcon, f as ChevronDownIcon } from "../../icons-CVFSeTJn.js";
|
|
3
3
|
import { Button } from "../foundations/Button.js";
|
|
4
4
|
import { Menu } from "../foundations/Menu.js";
|
|
5
5
|
import * as React from "react";
|
|
@@ -63,7 +63,7 @@ declare function TerminalTitle({
|
|
|
63
63
|
ref?: React.Ref<HTMLSpanElement>;
|
|
64
64
|
}): React.JSX.Element;
|
|
65
65
|
type TerminalStatusValue = "idle" | "running" | "success" | "error";
|
|
66
|
-
interface TerminalStatusProps extends
|
|
66
|
+
interface TerminalStatusProps extends React.HTMLAttributes<HTMLSpanElement> {
|
|
67
67
|
status: TerminalStatusValue;
|
|
68
68
|
}
|
|
69
69
|
declare function TerminalStatus({
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { t as cx } from "../../class-names-BiMDVpUo.js";
|
|
2
|
-
import {
|
|
2
|
+
import { Z as TerminalIcon, tt as XIcon } from "../../icons-CVFSeTJn.js";
|
|
3
3
|
import { IconButton } from "../foundations/IconButton.js";
|
|
4
|
-
import { t as CopyButton } from "../../copy-button-
|
|
5
|
-
import { Badge } from "../foundations/Badge.js";
|
|
4
|
+
import { t as CopyButton } from "../../copy-button-lys9N_aI.js";
|
|
6
5
|
import { ScrollArea } from "../foundations/ScrollArea.js";
|
|
7
6
|
import * as React from "react";
|
|
8
7
|
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -123,19 +122,12 @@ function TerminalTitle({ className, children, ref, ...props }) {
|
|
|
123
122
|
children: [/* @__PURE__ */ jsx(TerminalIcon, { "aria-hidden": "true" }), children ?? "Terminal"]
|
|
124
123
|
});
|
|
125
124
|
}
|
|
126
|
-
const STATUS_COLOR = {
|
|
127
|
-
idle: "neutral",
|
|
128
|
-
running: "primary",
|
|
129
|
-
success: "success",
|
|
130
|
-
error: "destructive"
|
|
131
|
-
};
|
|
132
125
|
function TerminalStatus({ className, status, ref, ...props }) {
|
|
133
|
-
return /* @__PURE__ */ jsx(
|
|
126
|
+
return /* @__PURE__ */ jsx("span", {
|
|
134
127
|
...props,
|
|
135
128
|
ref,
|
|
136
|
-
color: STATUS_COLOR[status],
|
|
137
|
-
size: "sm",
|
|
138
129
|
className: cx("terminal__status", className),
|
|
130
|
+
"data-status": status,
|
|
139
131
|
children: status
|
|
140
132
|
});
|
|
141
133
|
}
|
|
@@ -30,7 +30,7 @@ interface TestResultsProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
|
30
30
|
* Built internally for CI/test output in agent and developer workflows. Use it
|
|
31
31
|
* for structured test reports. Do not use it for generic status dashboards.
|
|
32
32
|
*
|
|
33
|
-
* Sigvelo changes: composes Collapsible
|
|
33
|
+
* Sigvelo changes: composes Collapsible and Progress; maps status
|
|
34
34
|
* color and spacing to Sigvelo CSS tokens; opens failed suites by default.
|
|
35
35
|
*
|
|
36
36
|
* Suite triggers inherit Collapsible keyboard behavior. Error stacks should be
|
|
@@ -1,23 +1,10 @@
|
|
|
1
1
|
import { t as cx } from "../../class-names-BiMDVpUo.js";
|
|
2
2
|
import { Collapsible } from "../foundations/Collapsible.js";
|
|
3
|
-
import {
|
|
4
|
-
import { Badge } from "../foundations/Badge.js";
|
|
3
|
+
import { K as SpinnerIcon, d as CheckIcon, p as ChevronRightIcon, tt as XIcon } from "../../icons-CVFSeTJn.js";
|
|
5
4
|
import { Progress } from "../foundations/Progress.js";
|
|
6
5
|
import * as React from "react";
|
|
7
6
|
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
8
7
|
//#region src/components/general-purpose/TestResults.tsx
|
|
9
|
-
const STATUS_COLOR = {
|
|
10
|
-
passed: "success",
|
|
11
|
-
failed: "destructive",
|
|
12
|
-
skipped: "warning",
|
|
13
|
-
running: "primary"
|
|
14
|
-
};
|
|
15
|
-
const STATUS_LABEL = {
|
|
16
|
-
passed: "PASS",
|
|
17
|
-
failed: "FAIL",
|
|
18
|
-
skipped: "SKIP",
|
|
19
|
-
running: "RUN"
|
|
20
|
-
};
|
|
21
8
|
const TestResultsContext = React.createContext({});
|
|
22
9
|
/**
|
|
23
10
|
* Displays a test suite report with summary stats, progress bar, and
|
|
@@ -26,7 +13,7 @@ const TestResultsContext = React.createContext({});
|
|
|
26
13
|
* Built internally for CI/test output in agent and developer workflows. Use it
|
|
27
14
|
* for structured test reports. Do not use it for generic status dashboards.
|
|
28
15
|
*
|
|
29
|
-
* Sigvelo changes: composes Collapsible
|
|
16
|
+
* Sigvelo changes: composes Collapsible and Progress; maps status
|
|
30
17
|
* color and spacing to Sigvelo CSS tokens; opens failed suites by default.
|
|
31
18
|
*
|
|
32
19
|
* Suite triggers inherit Collapsible keyboard behavior. Error stacks should be
|
|
@@ -85,8 +72,9 @@ function TestResultsSummary({ className, children, ref, ...props }) {
|
|
|
85
72
|
ref,
|
|
86
73
|
className: cx("test-results__summary", className),
|
|
87
74
|
...props,
|
|
88
|
-
children: children ?? /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx(
|
|
89
|
-
|
|
75
|
+
children: children ?? /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx("strong", {
|
|
76
|
+
className: "test-results__outcome",
|
|
77
|
+
"data-status": overall,
|
|
90
78
|
children: overall === "passed" ? "All tests passed" : `${summary.failed} failed`
|
|
91
79
|
}), /* @__PURE__ */ jsxs("span", {
|
|
92
80
|
className: "test-results__stats",
|
|
@@ -201,10 +189,9 @@ function TestSuiteName({ className, children, ref, ...props }) {
|
|
|
201
189
|
"aria-hidden": "true",
|
|
202
190
|
children: /* @__PURE__ */ jsx(ChevronRightIcon, {})
|
|
203
191
|
}),
|
|
204
|
-
/* @__PURE__ */ jsx(
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
children: STATUS_LABEL[status]
|
|
192
|
+
/* @__PURE__ */ jsx(TestStatus, {
|
|
193
|
+
status,
|
|
194
|
+
"aria-label": `${status} suite`
|
|
208
195
|
}),
|
|
209
196
|
/* @__PURE__ */ jsx("span", {
|
|
210
197
|
className: "test-results__suite-name sigvelo-truncate",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { N as MonitorIcon, P as MoonIcon, Y as SunIcon } from "../../icons-CVFSeTJn.js";
|
|
2
2
|
import { Radio, RadioGroup } from "../foundations/RadioGroup.js";
|
|
3
3
|
import { useTheme } from "../foundations/ThemeProvider.js";
|
|
4
4
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -35,7 +35,7 @@ interface WebPreviewProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
|
35
35
|
* known URL with local navigation controls. Do not use it for trusted app
|
|
36
36
|
* embedding that needs custom iframe permissions; add those explicitly here.
|
|
37
37
|
*
|
|
38
|
-
* Sigvelo changes: composes IconButton, Input,
|
|
38
|
+
* Sigvelo changes: composes IconButton, Input, and ScrollArea; keeps a
|
|
39
39
|
* conservative sandbox; and maps navigation and console UI to Sigvelo CSS
|
|
40
40
|
* tokens.
|
|
41
41
|
*
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { t as cx } from "../../class-names-BiMDVpUo.js";
|
|
2
2
|
import { Collapsible } from "../foundations/Collapsible.js";
|
|
3
|
-
import {
|
|
3
|
+
import { H as RefreshIcon, f as ChevronDownIcon, i as ArrowRightIcon, r as ArrowLeftIcon } from "../../icons-CVFSeTJn.js";
|
|
4
4
|
import { IconButton } from "../foundations/IconButton.js";
|
|
5
|
-
import { Badge } from "../foundations/Badge.js";
|
|
6
5
|
import { ScrollArea } from "../foundations/ScrollArea.js";
|
|
7
6
|
import { Input } from "../foundations/Input.js";
|
|
8
7
|
import * as React from "react";
|
|
@@ -23,7 +22,7 @@ function useWebPreviewContext() {
|
|
|
23
22
|
* known URL with local navigation controls. Do not use it for trusted app
|
|
24
23
|
* embedding that needs custom iframe permissions; add those explicitly here.
|
|
25
24
|
*
|
|
26
|
-
* Sigvelo changes: composes IconButton, Input,
|
|
25
|
+
* Sigvelo changes: composes IconButton, Input, and ScrollArea; keeps a
|
|
27
26
|
* conservative sandbox; and maps navigation and console UI to Sigvelo CSS
|
|
28
27
|
* tokens.
|
|
29
28
|
*
|
|
@@ -238,12 +237,6 @@ function WebPreviewBody({ className, loading, src, ref, interactive = true, ...p
|
|
|
238
237
|
...props
|
|
239
238
|
}, iframeSrc), loading] });
|
|
240
239
|
}
|
|
241
|
-
const LEVEL_COLOR = {
|
|
242
|
-
log: "neutral",
|
|
243
|
-
info: "primary",
|
|
244
|
-
warn: "warning",
|
|
245
|
-
error: "destructive"
|
|
246
|
-
};
|
|
247
240
|
function WebPreviewConsole({ className, logs = [], children, ref, ...props }) {
|
|
248
241
|
const { consoleOpen, setConsoleOpen } = useWebPreviewContext();
|
|
249
242
|
return /* @__PURE__ */ jsxs(Collapsible.Root, {
|
|
@@ -272,9 +265,8 @@ function WebPreviewConsole({ className, logs = [], children, ref, ...props }) {
|
|
|
272
265
|
}) : logs.map((log, index) => /* @__PURE__ */ jsxs("li", {
|
|
273
266
|
className: cx("web-preview__console-item", `web-preview__console-item--${log.level}`),
|
|
274
267
|
children: [
|
|
275
|
-
/* @__PURE__ */ jsx(
|
|
276
|
-
|
|
277
|
-
size: "sm",
|
|
268
|
+
/* @__PURE__ */ jsx("span", {
|
|
269
|
+
className: "web-preview__console-level",
|
|
278
270
|
children: log.level
|
|
279
271
|
}),
|
|
280
272
|
/* @__PURE__ */ jsx("span", {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { t as cx } from "../../class-names-BiMDVpUo.js";
|
|
2
|
-
import {
|
|
2
|
+
import { D as LinkIcon } from "../../icons-CVFSeTJn.js";
|
|
3
3
|
import { Button } from "../foundations/Button.js";
|
|
4
|
-
import { a as CodeBlockCopyButton, i as CodeBlockContent, n as CodeBlockActions, p as CodeBlockTitle, r as CodeBlockContainer, s as CodeBlockHeader, t as CodeBlock } from "../../CodeBlock-
|
|
4
|
+
import { a as CodeBlockCopyButton, i as CodeBlockContent, n as CodeBlockActions, p as CodeBlockTitle, r as CodeBlockContainer, s as CodeBlockHeader, t as CodeBlock } from "../../CodeBlock-BjELA-_s.js";
|
|
5
5
|
import { Popover } from "../foundations/Popover.js";
|
|
6
6
|
import { ToggleGroup } from "../foundations/ToggleGroup.js";
|
|
7
7
|
import * as React from "react";
|
|
@@ -22,7 +22,7 @@ interface AgentToolDetailProps<State = unknown, MessageT extends UIMessage = UIM
|
|
|
22
22
|
backLink?: React.ReactElement;
|
|
23
23
|
/**
|
|
24
24
|
* Route-owned run controls (the app's cancel callable, for example),
|
|
25
|
-
* rendered in
|
|
25
|
+
* rendered in the top bar's trailing slot after the status mark.
|
|
26
26
|
*/
|
|
27
27
|
actions?: React.ReactNode;
|
|
28
28
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { t as cx } from "../../class-names-BiMDVpUo.js";
|
|
2
|
-
import { r as ArrowLeftIcon } from "../../icons-
|
|
2
|
+
import { r as ArrowLeftIcon } from "../../icons-CVFSeTJn.js";
|
|
3
3
|
import { TransitionSurface } from "../foundations/TransitionSurface.js";
|
|
4
4
|
import { AppTopBar } from "../general-purpose/AppTopBar.js";
|
|
5
|
-
import {
|
|
5
|
+
import { SubagentRunMilestone, SubagentRunMilestones, SubagentRunProgress } from "../agents-sdk/SubagentRunDetails.js";
|
|
6
6
|
import { SubagentRunIndicator, getSubagentRunName } from "../agents-sdk/SubagentRunIndicator.js";
|
|
7
|
-
import {
|
|
8
|
-
import { t as ThinkChat } from "../../ThinkChat-
|
|
7
|
+
import { NaniteMark } from "./NaniteScene.js";
|
|
8
|
+
import { t as ThinkChat } from "../../ThinkChat-BES_3Mb-.js";
|
|
9
9
|
import * as React from "react";
|
|
10
10
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
11
11
|
import { useAgentChat } from "@cloudflare/think/react";
|
|
@@ -31,6 +31,7 @@ function AgentToolDetail({ actions, backLink, chat, className, messages, ref, ru
|
|
|
31
31
|
...props,
|
|
32
32
|
children: [
|
|
33
33
|
/* @__PURE__ */ jsxs(AppTopBar.Root, {
|
|
34
|
+
titleAlign: "start",
|
|
34
35
|
"aria-label": `${name} controls`,
|
|
35
36
|
children: [
|
|
36
37
|
/* @__PURE__ */ jsxs(AppTopBar.Leading, { children: [backLink ? /* @__PURE__ */ jsx(AppTopBar.Link, {
|
|
@@ -43,7 +44,7 @@ function AgentToolDetail({ actions, backLink, chat, className, messages, ref, ru
|
|
|
43
44
|
className: "agent-tool-detail__title",
|
|
44
45
|
children: name
|
|
45
46
|
}) }),
|
|
46
|
-
/* @__PURE__ */
|
|
47
|
+
/* @__PURE__ */ jsxs(AppTopBar.Trailing, { children: [/* @__PURE__ */ jsx(SubagentRunIndicator, { run }), actions] })
|
|
47
48
|
]
|
|
48
49
|
}),
|
|
49
50
|
progressLabel || run.milestones?.length || run.error || run.summary ? /* @__PURE__ */ jsxs("div", {
|
|
@@ -80,8 +81,7 @@ function AgentToolDetail({ actions, backLink, chat, className, messages, ref, ru
|
|
|
80
81
|
showComposer: false,
|
|
81
82
|
loading: true
|
|
82
83
|
})
|
|
83
|
-
})
|
|
84
|
-
actions ? /* @__PURE__ */ jsx(SubagentRunActions, { children: actions }) : null
|
|
84
|
+
})
|
|
85
85
|
]
|
|
86
86
|
});
|
|
87
87
|
}
|
|
@@ -16,8 +16,8 @@ const SCREEN_BORDER = "#3a5068";
|
|
|
16
16
|
const SCREEN_LINE = "#2e3d50";
|
|
17
17
|
const SCREEN_ICON_WARN = "#c87832";
|
|
18
18
|
const GLASS_STROKE = "#8ba7b8";
|
|
19
|
-
const
|
|
20
|
-
const
|
|
19
|
+
const STATUS_MARK_SUCCESS = "#0f7b6c";
|
|
20
|
+
const STATUS_MARK_FAIL = "#dc2626";
|
|
21
21
|
const TRIO_XS = [
|
|
22
22
|
40,
|
|
23
23
|
100,
|
|
@@ -108,8 +108,8 @@ function NaniteScene({ variant, mode = "trio", className, title }) {
|
|
|
108
108
|
}
|
|
109
109
|
const showBrowser = variant !== "idle" && variant !== "helmet";
|
|
110
110
|
const showGlass = variant === "working";
|
|
111
|
-
const
|
|
112
|
-
const
|
|
111
|
+
const showSuccessMark = variant === "celebrating";
|
|
112
|
+
const showFailMark = variant === "concerned";
|
|
113
113
|
const soloViewBox = showBrowser ? "0 0 120 56" : "0 0 52 56";
|
|
114
114
|
const soloWidth = showBrowser ? 120 : 52;
|
|
115
115
|
const naniteX = 24;
|
|
@@ -265,15 +265,15 @@ function NaniteScene({ variant, mode = "trio", className, title }) {
|
|
|
265
265
|
})]
|
|
266
266
|
})
|
|
267
267
|
}) : null,
|
|
268
|
-
|
|
268
|
+
showSuccessMark ? /* @__PURE__ */ jsx("g", {
|
|
269
269
|
transform: `translate(96, ${screenCy - 10})`,
|
|
270
270
|
children: /* @__PURE__ */ jsxs("g", {
|
|
271
|
-
className: "nanite-
|
|
271
|
+
className: "nanite-scene__status-mark",
|
|
272
272
|
children: [/* @__PURE__ */ jsx("circle", {
|
|
273
273
|
cx: "0",
|
|
274
274
|
cy: "0",
|
|
275
275
|
r: "7",
|
|
276
|
-
fill:
|
|
276
|
+
fill: STATUS_MARK_SUCCESS,
|
|
277
277
|
stroke: "#ffffff",
|
|
278
278
|
strokeWidth: "1.5"
|
|
279
279
|
}), /* @__PURE__ */ jsx("path", {
|
|
@@ -286,16 +286,16 @@ function NaniteScene({ variant, mode = "trio", className, title }) {
|
|
|
286
286
|
})]
|
|
287
287
|
})
|
|
288
288
|
}) : null,
|
|
289
|
-
|
|
289
|
+
showFailMark ? /* @__PURE__ */ jsx("g", {
|
|
290
290
|
transform: `translate(96, ${screenCy - 10})`,
|
|
291
291
|
children: /* @__PURE__ */ jsxs("g", {
|
|
292
|
-
className: "nanite-
|
|
292
|
+
className: "nanite-scene__status-mark",
|
|
293
293
|
children: [
|
|
294
294
|
/* @__PURE__ */ jsx("circle", {
|
|
295
295
|
cx: "0",
|
|
296
296
|
cy: "0",
|
|
297
297
|
r: "7",
|
|
298
|
-
fill:
|
|
298
|
+
fill: STATUS_MARK_FAIL,
|
|
299
299
|
stroke: "#ffffff",
|
|
300
300
|
strokeWidth: "1.5"
|
|
301
301
|
}),
|
|
@@ -320,7 +320,7 @@ function NaniteScene({ variant, mode = "trio", className, title }) {
|
|
|
320
320
|
]
|
|
321
321
|
})
|
|
322
322
|
}) : null,
|
|
323
|
-
|
|
323
|
+
showSuccessMark ? /* @__PURE__ */ jsxs("g", {
|
|
324
324
|
className: "nanite-scene__sparkles",
|
|
325
325
|
children: [
|
|
326
326
|
/* @__PURE__ */ jsx("circle", {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { d as CheckIcon,
|
|
1
|
+
import { d as CheckIcon, h as CopyIcon } from "./icons-CVFSeTJn.js";
|
|
2
2
|
import { IconButton } from "./components/foundations/IconButton.js";
|
|
3
3
|
import * as React from "react";
|
|
4
4
|
import { jsx } from "react/jsx-runtime";
|