@mcp-b/react-components 0.70.0 → 0.71.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 (96) hide show
  1. package/dist/AgentComputer-CpS9R2KG.d.ts +305 -0
  2. package/dist/{AgentComputer-CFJxjMFE.js → AgentComputer-DZCyQkcE.js} +1850 -478
  3. package/dist/CommandPalette-DDctKdpC.d.ts +53 -0
  4. package/dist/ComputerCalendar-Ci7tLASe.js +1360 -0
  5. package/dist/ComputerCustomWallpaper-CnGQYHp0.js +518 -0
  6. package/dist/ComputerCustomWallpaper-D4lgwj2k.d.ts +18 -0
  7. package/dist/ComputerNotifications-q7eeELZ8.d.ts +41 -0
  8. package/dist/ComputerPresentation-BEQKYAjc.js +888 -0
  9. package/dist/{ExecutionResult-C7SzVquo.js → ExecutionResult-CXnGcmM4.js} +1 -1
  10. package/dist/{WorkspaceBrowser-ojoZy0uO.js → WorkspaceBrowser-mRScUczT.js} +5 -5
  11. package/dist/WorkspaceFileTransfer-D2cOoVyO.js +1625 -0
  12. package/dist/{WorkspaceMessageResponse-BoeeltJM.js → WorkspaceMessageResponse-CXGOQgpo.js} +1 -1
  13. package/dist/components/agents-sdk/AgentComputer.d.ts +2 -276
  14. package/dist/components/agents-sdk/AgentComputer.js +1 -1
  15. package/dist/components/agents-sdk/BrowserReplay.js +1 -1
  16. package/dist/components/agents-sdk/ComputerAutomations.d.ts +5 -15
  17. package/dist/components/agents-sdk/ComputerAutomations.js +164 -145
  18. package/dist/components/agents-sdk/ComputerCalendar.d.ts +1 -1
  19. package/dist/components/agents-sdk/ComputerCalendar.js +1 -1344
  20. package/dist/components/agents-sdk/ComputerCustomWallpaper.d.ts +2 -39
  21. package/dist/components/agents-sdk/ComputerCustomWallpaper.js +2 -522
  22. package/dist/components/agents-sdk/ComputerFiles.d.ts +18 -81
  23. package/dist/components/agents-sdk/ComputerFiles.js +365 -89
  24. package/dist/components/agents-sdk/ComputerHome.d.ts +6 -11
  25. package/dist/components/agents-sdk/ComputerHome.js +1 -89
  26. package/dist/components/agents-sdk/ComputerHost.d.ts +43 -0
  27. package/dist/components/agents-sdk/ComputerHost.js +97 -0
  28. package/dist/components/agents-sdk/ComputerLayout.d.ts +1 -1
  29. package/dist/components/agents-sdk/ComputerNotifications.d.ts +2 -54
  30. package/dist/components/agents-sdk/ComputerNotifications.js +1 -668
  31. package/dist/components/agents-sdk/ComputerPresentation.d.ts +2 -0
  32. package/dist/components/agents-sdk/ComputerPresentation.js +2 -0
  33. package/dist/components/agents-sdk/ComputerScreen.d.ts +14 -14
  34. package/dist/components/agents-sdk/ComputerScreen.js +109 -50
  35. package/dist/components/agents-sdk/ComputerSettings.d.ts +12 -40
  36. package/dist/components/agents-sdk/ComputerSettings.js +249 -1038
  37. package/dist/components/agents-sdk/ComputerSpotlight.d.ts +13 -15
  38. package/dist/components/agents-sdk/ComputerSpotlight.js +1 -231
  39. package/dist/components/agents-sdk/ComputerViewer.d.ts +13 -17
  40. package/dist/components/agents-sdk/ComputerViewer.js +176 -187
  41. package/dist/components/agents-sdk/ComputerWallpapers.d.ts +1 -1
  42. package/dist/components/agents-sdk/EmployeeChat.js +2 -2
  43. package/dist/components/agents-sdk/EmployeeChrome.js +3 -3
  44. package/dist/components/agents-sdk/EmployeeSchedules.js +2 -2
  45. package/dist/components/agents-sdk/ExecutionBoard.js +1 -1
  46. package/dist/components/agents-sdk/ManagerOffice.js +1 -1
  47. package/dist/components/agents-sdk/ManagerOfficeScreens.js +2 -2
  48. package/dist/components/agents-sdk/McpPluginCatalog.js +1 -1
  49. package/dist/components/agents-sdk/ThinkChat.js +1 -1
  50. package/dist/components/agents-sdk/ThinkChatToolPanels.js +3 -3
  51. package/dist/components/agents-sdk/ThinkExecutionDetail.js +1 -1
  52. package/dist/components/agents-sdk/ThinkExecutionWorkbench.js +2 -2
  53. package/dist/components/agents-sdk/ThinkScheduleActions.js +1 -1
  54. package/dist/components/agents-sdk/ThinkScheduleBrowser.js +1 -1
  55. package/dist/components/agents-sdk/ThinkScheduleDetail.js +4 -4
  56. package/dist/components/agents-sdk/ThinkScheduleForm.js +3 -3
  57. package/dist/components/agents-sdk/WorkspaceAutomation.js +3 -3
  58. package/dist/components/agents-sdk/WorkspaceAutomationTable.js +1 -1
  59. package/dist/components/agents-sdk/WorkspaceBrowser.js +1 -1
  60. package/dist/components/agents-sdk/WorkspaceDesktop.d.ts +1 -5
  61. package/dist/components/agents-sdk/WorkspaceDesktop.js +53 -41
  62. package/dist/components/agents-sdk/WorkspaceExplorer.js +3 -3
  63. package/dist/components/agents-sdk/WorkspaceFileCommands.js +1 -924
  64. package/dist/components/agents-sdk/WorkspaceFileDetails.js +1 -1
  65. package/dist/components/agents-sdk/WorkspaceFileTransfer.js +1 -504
  66. package/dist/components/agents-sdk/WorkspaceFileView.js +6 -6
  67. package/dist/components/agents-sdk/WorkspaceLink.js +1 -1
  68. package/dist/components/agents-sdk/WorkspaceLive.d.ts +9 -0
  69. package/dist/components/agents-sdk/WorkspaceLive.js +2 -177
  70. package/dist/components/agents-sdk/WorkspaceMessageResponse.js +1 -1
  71. package/dist/components/agents-sdk/WorkspaceMountManager.js +1 -1
  72. package/dist/components/ai-sdk/Context.js +1 -1
  73. package/dist/components/ai-sdk/PromptInput.js +1 -1
  74. package/dist/components/extension/FirstRunSetup.js +2 -2
  75. package/dist/components/foundations/ThemeProvider.d.ts +2 -0
  76. package/dist/components/foundations/ThemeProvider.js +2 -1
  77. package/dist/components/general-purpose/CommandPalette.d.ts +2 -52
  78. package/dist/components/general-purpose/ResponsiveSidebarShell.js +1 -1
  79. package/dist/components/general-purpose/WallpaperPicker.d.ts +33 -2
  80. package/dist/components/nanites/AgentConnection.js +1 -1
  81. package/dist/components/nanites/AgentToolDetail.js +1 -1
  82. package/dist/context-BWJpR084.js +94 -0
  83. package/dist/{parts-CPVz9l31.js → parts-DuT5-rDz.js} +1 -1
  84. package/dist/styles/agent-computer.css +16 -0
  85. package/dist/styles/computer-files.css +5 -0
  86. package/dist/styles/computer-notifications.css +1 -0
  87. package/dist/{workspace-drag-B6hMXUNt.js → workspace-drag-BNhZIN8F.js} +1 -1
  88. package/dist/{workspace-quick-look-DODjsfhH.js → workspace-quick-look-8cbGu1Xf.js} +2 -2
  89. package/package.json +2 -2
  90. package/dist/WallpaperPicker-C-FItmDS.d.ts +0 -34
  91. package/dist/automations-host-DPORjdc7.js +0 -17
  92. package/dist/context-Ddsp8HgD.js +0 -43
  93. package/dist/minute-clock-CXpRGCMF.js +0 -35
  94. package/dist/{Context-DQDumCV8.js → Context-CYUxZrwW.js} +1 -1
  95. package/dist/{ManagerOffice-kSK7vTBl.js → ManagerOffice-BJ2vs-Lr.js} +2 -2
  96. package/dist/{WorkspaceLink-DK9kdMUH.js → WorkspaceLink-DDkj-Tq5.js} +1 -1
@@ -1,177 +1,2 @@
1
- import { a as workspaceDirname } from "../../workspace-path-TZggP-u4.js";
2
- import { refreshWorkspaceFileQueries, workspaceFileQueryKey } from "./Workspace.js";
3
- import "./WorkspaceFileCommands.js";
4
- import { invalidateWorkspaceConceptQueries, workspacePathsOverlap } from "./WorkspaceConcept.js";
5
- import { c } from "react/compiler-runtime";
6
- import * as React from "react";
7
- import { useQueryClient } from "@tanstack/react-query";
8
- //#region src/components/agents-sdk/WorkspaceLive.ts
9
- const DEFAULT_DEBOUNCE_MS = 200;
10
- /**
11
- * Listings the host's root does not own: a Finder folder, Recents and a
12
- * search each read under a root of their own (a dot root for the queries), so
13
- * a change refreshes the source's info (the volume's and each Get Info
14
- * file's), the listings of the changed folders, every query root's listings
15
- * since any change can move them, and whether the Trash is full when the
16
- * Trash changed. Without `directories`, every listing of the source and the
17
- * Trash refresh.
18
- */
19
- function invalidateEveryRoot(queryClient, sourceKey, directories) {
20
- return queryClient.invalidateQueries({
21
- queryKey: ["workspace", sourceKey],
22
- predicate: ({ queryKey: [, , root, segment, path] }) => root === "info" || root === "trash" && (!directories || directories.has("/.Trash")) || segment === "directory" && (!directories || typeof root === "string" && root.startsWith("/.") || typeof path === "string" && directories.has(path))
23
- });
24
- }
25
- async function invalidateWorkspaceResources(queryClient, sourceKey, root, source, selectedPath, resolveFileAsset, maxInlineAssetBytes, paths) {
26
- if (!source || !selectedPath || paths && !paths.some((path) => workspacePathsOverlap(selectedPath, path))) return;
27
- await queryClient.cancelQueries({ queryKey: workspaceFileQueryKey(sourceKey, root, selectedPath) });
28
- await refreshWorkspaceFileQueries(queryClient, {
29
- source,
30
- sourceKey,
31
- root,
32
- selectedPath,
33
- resolveFileAsset,
34
- maxInlineAssetBytes
35
- }).catch(() => {});
36
- }
37
- /**
38
- * Synchronize external workspace freshness with the design system's Query
39
- * resources. This is the one external-system effect: native observer events
40
- * and host revision ticks both land here as targeted invalidation against
41
- * stable query keys. Hosts only supply events; neither layer adds another
42
- * watcher.
43
- */
44
- function useWorkspaceLiveQueries(t0) {
45
- const $ = c(32);
46
- const { changes, maxInlineAssetBytes, resolveFileAsset, selectedPath, source, sourceKey, root, revision } = t0;
47
- const queryClient = useQueryClient();
48
- let t1;
49
- if ($[0] !== maxInlineAssetBytes || $[1] !== queryClient || $[2] !== resolveFileAsset || $[3] !== root || $[4] !== selectedPath || $[5] !== source || $[6] !== sourceKey) {
50
- t1 = (paths) => {
51
- if (!sourceKey) return;
52
- invalidateWorkspaceResources(queryClient, sourceKey, root, source, selectedPath, resolveFileAsset, maxInlineAssetBytes, paths);
53
- };
54
- $[0] = maxInlineAssetBytes;
55
- $[1] = queryClient;
56
- $[2] = resolveFileAsset;
57
- $[3] = root;
58
- $[4] = selectedPath;
59
- $[5] = source;
60
- $[6] = sourceKey;
61
- $[7] = t1;
62
- } else t1 = $[7];
63
- const refreshResources = React.useEffectEvent(t1);
64
- const previousRevisionRef = React.useRef(void 0);
65
- let t2;
66
- if ($[8] !== changes || $[9] !== queryClient || $[10] !== refreshResources || $[11] !== revision || $[12] !== root || $[13] !== sourceKey) {
67
- t2 = () => {
68
- if (!sourceKey || revision === void 0) return;
69
- const previous = previousRevisionRef.current;
70
- previousRevisionRef.current = {
71
- sourceKey,
72
- root,
73
- revision
74
- };
75
- if (previous?.sourceKey === sourceKey && previous.root === root && previous.revision === revision) return;
76
- if (changes?.live?.()) return;
77
- invalidateEveryRoot(queryClient, sourceKey);
78
- invalidateWorkspaceConceptQueries(queryClient, sourceKey, root);
79
- refreshResources();
80
- };
81
- $[8] = changes;
82
- $[9] = queryClient;
83
- $[10] = refreshResources;
84
- $[11] = revision;
85
- $[12] = root;
86
- $[13] = sourceKey;
87
- $[14] = t2;
88
- } else t2 = $[14];
89
- let t3;
90
- if ($[15] !== changes || $[16] !== queryClient || $[17] !== revision || $[18] !== root || $[19] !== sourceKey) {
91
- t3 = [
92
- changes,
93
- queryClient,
94
- revision,
95
- root,
96
- sourceKey
97
- ];
98
- $[15] = changes;
99
- $[16] = queryClient;
100
- $[17] = revision;
101
- $[18] = root;
102
- $[19] = sourceKey;
103
- $[20] = t3;
104
- } else t3 = $[20];
105
- React.useEffect(t2, t3);
106
- let t4;
107
- if ($[21] !== changes || $[22] !== queryClient || $[23] !== refreshResources || $[24] !== root || $[25] !== sourceKey) {
108
- t4 = () => {
109
- if (!changes || !sourceKey) return;
110
- Promise.resolve().then(() => changes.start?.()).catch(_temp);
111
- const pendingDirectories = /* @__PURE__ */ new Set();
112
- const pendingPaths = /* @__PURE__ */ new Set();
113
- let refreshAll = false;
114
- let timer;
115
- const flush = () => {
116
- timer = void 0;
117
- if (refreshAll) {
118
- refreshAll = false;
119
- pendingDirectories.clear();
120
- pendingPaths.clear();
121
- invalidateEveryRoot(queryClient, sourceKey);
122
- invalidateWorkspaceConceptQueries(queryClient, sourceKey, root);
123
- refreshResources();
124
- return;
125
- }
126
- invalidateEveryRoot(queryClient, sourceKey, new Set(pendingDirectories));
127
- const paths_0 = [...pendingPaths];
128
- pendingDirectories.clear();
129
- pendingPaths.clear();
130
- invalidateWorkspaceConceptQueries(queryClient, sourceKey, root, paths_0);
131
- refreshResources(paths_0);
132
- };
133
- const unsubscribe = changes.subscribe((change) => {
134
- if (change.type === "unknown") refreshAll = true;
135
- else {
136
- pendingDirectories.add(workspaceDirname(change.path));
137
- pendingPaths.add(change.path);
138
- if (change.movedFrom) {
139
- pendingDirectories.add(workspaceDirname(change.movedFrom));
140
- pendingPaths.add(change.movedFrom);
141
- }
142
- }
143
- if (timer === void 0) timer = setTimeout(flush, DEFAULT_DEBOUNCE_MS);
144
- });
145
- return () => {
146
- unsubscribe();
147
- if (timer !== void 0) clearTimeout(timer);
148
- };
149
- };
150
- $[21] = changes;
151
- $[22] = queryClient;
152
- $[23] = refreshResources;
153
- $[24] = root;
154
- $[25] = sourceKey;
155
- $[26] = t4;
156
- } else t4 = $[26];
157
- let t5;
158
- if ($[27] !== changes || $[28] !== queryClient || $[29] !== root || $[30] !== sourceKey) {
159
- t5 = [
160
- changes,
161
- queryClient,
162
- root,
163
- sourceKey
164
- ];
165
- $[27] = changes;
166
- $[28] = queryClient;
167
- $[29] = root;
168
- $[30] = sourceKey;
169
- $[31] = t5;
170
- } else t5 = $[31];
171
- React.useEffect(t4, t5);
172
- }
173
- function _temp(error) {
174
- console.error("The workspace change source failed to start.", error);
175
- }
176
- //#endregion
177
- export { useWorkspaceLiveQueries };
1
+ import { c as invalidateWorkspacePaths, l as useWorkspaceLiveQueries } from "../../WorkspaceFileTransfer-D2cOoVyO.js";
2
+ export { invalidateWorkspacePaths, useWorkspaceLiveQueries };
@@ -1,2 +1,2 @@
1
- import { n as WorkspaceMessageResponse, t as WorkspaceFileRendererProvider } from "../../WorkspaceMessageResponse-BoeeltJM.js";
1
+ import { n as WorkspaceMessageResponse, t as WorkspaceFileRendererProvider } from "../../WorkspaceMessageResponse-CXGOQgpo.js";
2
2
  export { WorkspaceFileRendererProvider, WorkspaceMessageResponse };
@@ -1,7 +1,7 @@
1
1
  import { Button } from "../foundations/Button.js";
2
+ import { Popover } from "../foundations/Popover.js";
2
3
  import { EmptyState } from "../foundations/EmptyState.js";
3
4
  import { Card, CardFooter, CardHeader, CardTitle } from "../foundations/Card.js";
4
- import { Popover } from "../foundations/Popover.js";
5
5
  import { c } from "react/compiler-runtime";
6
6
  import { jsx, jsxs } from "react/jsx-runtime";
7
7
  //#region src/components/agents-sdk/WorkspaceMountManager.tsx
@@ -1,2 +1,2 @@
1
- import { a as ContextContentFooter, c as ContextOutputUsage, d as getContextUsage, f as getContextUsedTokens, i as ContextContentBody, l as ContextReasoningUsage, n as ContextCacheUsage, o as ContextContentHeader, r as ContextContent, s as ContextInputUsage, t as Context, u as ContextTrigger } from "../../Context-DQDumCV8.js";
1
+ import { a as ContextContentFooter, c as ContextOutputUsage, d as getContextUsage, f as getContextUsedTokens, i as ContextContentBody, l as ContextReasoningUsage, n as ContextCacheUsage, o as ContextContentHeader, r as ContextContent, s as ContextInputUsage, t as Context, u as ContextTrigger } from "../../Context-CYUxZrwW.js";
2
2
  export { Context, ContextCacheUsage, ContextContent, ContextContentBody, ContextContentFooter, ContextContentHeader, ContextInputUsage, ContextOutputUsage, ContextReasoningUsage, ContextTrigger, getContextUsage, getContextUsedTokens };
@@ -16,7 +16,7 @@ import { PreviewCard } from "../foundations/PreviewCard.js";
16
16
  import { Tabs } from "../foundations/Tabs.js";
17
17
  import { n as groupCommands, t as commandMatchesQuery } from "../../command-search-1fjmCBBo.js";
18
18
  import { PromptInputComposerEditor } from "./PromptInputComposerEditor.js";
19
- import { i as workspaceDropFiles, n as readWorkspaceDrop } from "../../workspace-drag-B6hMXUNt.js";
19
+ import { i as workspaceDropFiles, n as readWorkspaceDrop } from "../../workspace-drag-BNhZIN8F.js";
20
20
  import { c } from "react/compiler-runtime";
21
21
  import * as React from "react";
22
22
  import { Fragment, jsx, jsxs } from "react/jsx-runtime";
@@ -8,16 +8,16 @@ import { AppIcon } from "../foundations/AppIcon.js";
8
8
  import { Kbd } from "../foundations/Kbd.js";
9
9
  import { Tabs } from "../foundations/Tabs.js";
10
10
  import { PromptInput, PromptInputBody, PromptInputButton, PromptInputDictation, PromptInputFooter, PromptInputFooterEnd, PromptInputProvider, PromptInputSubmit, PromptInputTextarea, PromptInputTools } from "../ai-sdk/PromptInput.js";
11
+ import { Radio, RadioGroup } from "../foundations/RadioGroup.js";
11
12
  import { Input } from "../foundations/Input.js";
12
13
  import { Avatar } from "../foundations/Avatar.js";
14
+ import { formatThinkScheduleRepeat, getThinkScheduleNextRun } from "../agents-sdk/ThinkSchedule.js";
13
15
  import { DescriptionList } from "../foundations/DescriptionList.js";
14
16
  import { a as executionResultSummary, n as executionErrorSummary, s as stepState, t as boardNotice } from "../../execution-result-DAuW4VWv.js";
15
17
  import { Card, CardContent } from "../foundations/Card.js";
16
18
  import { t as WorkspaceEntityCard } from "../../workspace-entity-card-9YcsNiqU.js";
17
19
  import { WorkspaceAutomationFile } from "../agents-sdk/WorkspaceAutomation.js";
18
- import { formatThinkScheduleRepeat, getThinkScheduleNextRun } from "../agents-sdk/ThinkSchedule.js";
19
20
  import { Switch } from "../foundations/Switch.js";
20
- import { Radio, RadioGroup } from "../foundations/RadioGroup.js";
21
21
  import { t as ProviderLogo } from "../../provider-logos-Ceu7iYFx.js";
22
22
  import { n as peopleListItems } from "../../workspace-person-ZwPqu5TX.js";
23
23
  import { WorkspacePersonFile } from "../agents-sdk/WorkspacePerson.js";
@@ -17,6 +17,8 @@ export interface ThemeContextValue {
17
17
  resolvedTheme: ResolvedTheme;
18
18
  setPreference: (preference: ThemePreference) => void;
19
19
  }
20
+ /** Null outside a ThemeProvider; `useTheme` throws there instead. */
21
+ export declare const ThemeContext: React.Context<ThemeContextValue | null>;
20
22
  /**
21
23
  * Owns the application-wide theme preference and keeps document metadata,
22
24
  * storage, cross-tab changes, and operating-system changes synchronized.
@@ -3,6 +3,7 @@ import { c } from "react/compiler-runtime";
3
3
  import * as React from "react";
4
4
  import { jsx } from "react/jsx-runtime";
5
5
  //#region src/components/foundations/ThemeProvider.tsx
6
+ /** Null outside a ThemeProvider; `useTheme` throws there instead. */
6
7
  const ThemeContext = React.createContext(null);
7
8
  const useClientLayoutEffect = typeof document === "undefined" ? React.useEffect : React.useLayoutEffect;
8
9
  /**
@@ -163,4 +164,4 @@ function useTheme() {
163
164
  return context;
164
165
  }
165
166
  //#endregion
166
- export { ThemeProvider, useTheme };
167
+ export { ThemeContext, ThemeProvider, useTheme };
@@ -1,52 +1,2 @@
1
- import { ReactNode } from "react";
2
- //#region src/components/general-purpose/CommandPalette.d.ts
3
- /** One searchable action or destination. */
4
- export interface CommandPaletteCommand {
5
- /** Stable identity, independent of the visible label. */
6
- id: string;
7
- /** The action or destination shown in search results. */
8
- label: string;
9
- /** Supporting context, such as a file path. Also searchable. */
10
- description?: string;
11
- /** Plain-text group heading, as on `PromptInputCommandDefinition`. Also searchable. */
12
- group?: string;
13
- /** Additional search terms, without changing the visible label. */
14
- keywords?: readonly string[];
15
- /** Decorative destination or action icon. */
16
- icon?: ReactNode;
17
- /** Runs after the dialog closes so it can move focus to its destination. */
18
- onSelect: () => void;
19
- /** Runs when the command is highlighted, to warm its destination before it is chosen. */
20
- preload?: () => void;
21
- }
22
- /** Props for {@link CommandPalette}. */
23
- export interface CommandPaletteProps {
24
- /** Commands available to the current user and workspace. */
25
- commands: readonly CommandPaletteCommand[];
26
- /** Whether the modal search is open. */
27
- open: boolean;
28
- /** Receives search dismissal; the host owns its trigger and shortcut. */
29
- onOpenChange: (open: boolean) => void;
30
- /** Visible loading, error, or source information beneath the results. */
31
- children?: ReactNode;
32
- /**
33
- * The element the search portals into; its containing block is the screen
34
- * the search centres on and blocks. Defaults to the document body.
35
- */
36
- container?: HTMLElement | null;
37
- /**
38
- * Receives the query as it is typed, for a host that searches a source of
39
- * its own. Its results still pass the palette's own match.
40
- */
41
- onQueryChange?: (query: string) => void;
42
- }
43
- /**
44
- * Modal command search using Base UI's inline Combobox and Dialog, shaped like
45
- * Spotlight: one floating field over the screen with its results under it, no
46
- * dimmed backdrop, no close button and no key legend. Arrow keys highlight
47
- * results, Enter executes, and Escape or a press outside restores the
48
- * initiating focus. The host owns commands and keyboard shortcuts; actions run
49
- * after dismissal.
50
- */
51
- export declare function CommandPalette({ commands, open, onOpenChange, children, container, onQueryChange }: CommandPaletteProps): import("react").JSX.Element;
52
- //#endregion
1
+ import { n as CommandPaletteCommand, r as CommandPaletteProps, t as CommandPalette } from "../../CommandPalette-DDctKdpC.js";
2
+ export { CommandPalette, CommandPaletteCommand, CommandPaletteProps };
@@ -4,8 +4,8 @@ import { t as capitalize } from "../../format-DL7f2rqp.js";
4
4
  import { Button } from "../foundations/Button.js";
5
5
  import { n as mergeRefs } from "../../merge-refs-DTX97mLp.js";
6
6
  import { t as isAtMostRem } from "../../container-width-C43ccJ84.js";
7
- import { n as ShellAppBarOutletContext, r as createAppBarOutlet, t as ContentAppBarOutletContext } from "../../app-bar-outlet-BEIGl9iF.js";
8
7
  import { AppTopBar } from "./AppTopBar.js";
8
+ import { n as ShellAppBarOutletContext, r as createAppBarOutlet, t as ContentAppBarOutletContext } from "../../app-bar-outlet-BEIGl9iF.js";
9
9
  import { ResizableSidePanel } from "./ResizableSidePanel.js";
10
10
  import { c } from "react/compiler-runtime";
11
11
  import * as React from "react";
@@ -1,2 +1,33 @@
1
- import { n as WallpaperPicker, r as WallpaperPickerProps, t as WallpaperOption } from "../../WallpaperPicker-C-FItmDS.js";
2
- export { WallpaperOption, WallpaperPicker, WallpaperPickerProps };
1
+ import { ComponentPropsWithRef, ReactNode } from "react";
2
+ //#region src/components/general-purpose/WallpaperPicker.d.ts
3
+ /** One host-supplied background. */
4
+ export interface WallpaperOption {
5
+ /** Stable identifier stored by the consuming application. */
6
+ value: string;
7
+ /** Visible and accessible name for this background. */
8
+ label: string;
9
+ /** Trusted CSS background shorthand supplied by the host. */
10
+ background: string;
11
+ /**
12
+ * The same picture's dark variant, as a background shorthand. It fades in
13
+ * over `background` while the document is dark: `data-theme="dark"`, or no
14
+ * `data-theme` and a dark OS.
15
+ */
16
+ darkBackground?: string;
17
+ }
18
+ /** Props for {@link WallpaperPicker}. */
19
+ export interface WallpaperPickerProps extends Omit<ComponentPropsWithRef<"div">, "children" | "aria-label"> {
20
+ /** References a visible label for the thumbnail radio group. Defaults to its heading. */
21
+ "aria-labelledby"?: string;
22
+ /** Host-owned backgrounds. The picker owns no catalog or persistent state. */
23
+ wallpapers: readonly WallpaperOption[];
24
+ /** The selected wallpaper identifier. */
25
+ value: string;
26
+ /** Selection applies immediately. Arrow keys also select a background. */
27
+ onValueChange: (value: string) => void;
28
+ /** Host controls beside the current preview, such as a theme preference. */
29
+ selectionControls?: ReactNode;
30
+ }
31
+ /** A wallpaper preview and thumbnail gallery over the shared radio-group contract. */
32
+ export declare function WallpaperPicker({ wallpapers, value, onValueChange, selectionControls, className, "aria-labelledby": ariaLabelledBy, ...props }: WallpaperPickerProps): import("react").JSX.Element;
33
+ //#endregion
@@ -1,8 +1,8 @@
1
1
  import { t as cx } from "../../class-names-BiMDVpUo.js";
2
2
  import { F as LinkIcon } from "../../icons-nLTnB9kd.js";
3
3
  import { Button } from "../foundations/Button.js";
4
- import { ToggleGroup } from "../foundations/ToggleGroup.js";
5
4
  import { Popover } from "../foundations/Popover.js";
5
+ import { ToggleGroup } from "../foundations/ToggleGroup.js";
6
6
  import { a as CodeBlockCopyButton, i as CodeBlockContent, n as CodeBlockActions, p as CodeBlockTitle, r as CodeBlockContainer, s as CodeBlockHeader, t as CodeBlock } from "../../CodeBlock-dt0L8md0.js";
7
7
  import { c } from "react/compiler-runtime";
8
8
  import * as React from "react";
@@ -4,8 +4,8 @@ import { MessageActions } from "../ai-sdk/Message.js";
4
4
  import { SubagentRunIndicator, getSubagentRunName } from "../agents-sdk/SubagentRunIndicator.js";
5
5
  import { NaniteMark } from "./NaniteScene.js";
6
6
  import { AgentChat } from "../agents-sdk/AgentChat.js";
7
- import { TransitionSurface } from "../foundations/TransitionSurface.js";
8
7
  import { AppTopBar } from "../general-purpose/AppTopBar.js";
8
+ import { TransitionSurface } from "../foundations/TransitionSurface.js";
9
9
  import { ThinkChat } from "../agents-sdk/ThinkChat.js";
10
10
  import { c } from "react/compiler-runtime";
11
11
  import * as React from "react";
@@ -0,0 +1,94 @@
1
+ import { c } from "react/compiler-runtime";
2
+ import * as React from "react";
3
+ //#region src/components/_internal/agent-computer/context.ts
4
+ /** The computer's controller: its state and every transition between states. */
5
+ const ComputerContext = React.createContext(null);
6
+ function useComputer() {
7
+ return React.use(ComputerContext);
8
+ }
9
+ /**
10
+ * A slice of the computer's state. `select` must return a primitive or a value
11
+ * the controller caches, so an unrelated change leaves this component alone.
12
+ */
13
+ function useComputerSlice(select) {
14
+ const $ = c(3);
15
+ const computer = useComputer();
16
+ let t0;
17
+ if ($[0] !== computer || $[1] !== select) {
18
+ t0 = () => select(computer);
19
+ $[0] = computer;
20
+ $[1] = select;
21
+ $[2] = t0;
22
+ } else t0 = $[2];
23
+ return React.useSyncExternalStore(computer.subscribe, t0);
24
+ }
25
+ /** The window an app part is rendered in. Memoized per window. */
26
+ const WindowContext = React.createContext(null);
27
+ /**
28
+ * Whether that window is key, apart from the window itself: focus moves on
29
+ * every window action, and only the parts that draw it should render again.
30
+ */
31
+ const WindowActiveContext = React.createContext(null);
32
+ /** The computer's actions: one object for the computer's lifetime. */
33
+ const ActionsContext = React.createContext(null);
34
+ /** Where a running app registers its keyboard commands and quit guard. */
35
+ const HandlersContext = React.createContext(null);
36
+ /**
37
+ * The element an overlay inside the computer portals into, so it stays on the
38
+ * computer's screen above its windows: null until the computer has mounted
39
+ * it, which a Base UI portal waits for, and undefined outside a computer.
40
+ */
41
+ const PortalContext = React.createContext(void 0);
42
+ /** The computer mounted under a `ComputerHost`, while it is. */
43
+ var MountedComputer = class {
44
+ current = null;
45
+ attach(computer) {
46
+ this.current = computer;
47
+ return () => {
48
+ if (this.current === computer) this.current = null;
49
+ };
50
+ }
51
+ };
52
+ const HostContext = React.createContext(null);
53
+ /** `ComputerHost`'s value. Throws outside one, naming the part that needs it. */
54
+ function useComputerHost(part) {
55
+ const host = React.use(HostContext);
56
+ if (!host) throw new Error(`${part} needs a ComputerHost above it.`);
57
+ return host;
58
+ }
59
+ const AppHostsContext = React.createContext({});
60
+ /** One app Host's part of the computer, beside what the Hosts above it added. */
61
+ function useAppHosts(key, value) {
62
+ const $ = c(4);
63
+ const hosts = React.use(AppHostsContext);
64
+ let t0;
65
+ if ($[0] !== hosts || $[1] !== key || $[2] !== value) {
66
+ t0 = {
67
+ ...hosts,
68
+ [key]: value
69
+ };
70
+ $[0] = hosts;
71
+ $[1] = key;
72
+ $[2] = value;
73
+ $[3] = t0;
74
+ } else t0 = $[3];
75
+ return t0;
76
+ }
77
+ /** The computer's presentation: layout, wallpaper, Dock and folder views. */
78
+ const PresentationContext = React.createContext(null);
79
+ function usePresentation(select) {
80
+ const $ = c(3);
81
+ const store = React.use(PresentationContext);
82
+ let t0;
83
+ if ($[0] !== select || $[1] !== store) {
84
+ t0 = () => select(store);
85
+ $[0] = select;
86
+ $[1] = store;
87
+ $[2] = t0;
88
+ } else t0 = $[2];
89
+ return React.useSyncExternalStore(store.subscribe, t0);
90
+ }
91
+ /** The wallpaper the computer shows, and Settings' controls for it. */
92
+ const AppearanceContext = React.createContext(null);
93
+ //#endregion
94
+ export { HandlersContext as a, PortalContext as c, WindowContext as d, useAppHosts as f, usePresentation as g, useComputerSlice as h, ComputerContext as i, PresentationContext as l, useComputerHost as m, AppHostsContext as n, HostContext as o, useComputer as p, AppearanceContext as r, MountedComputer as s, ActionsContext as t, WindowActiveContext as u };
@@ -1,4 +1,4 @@
1
- import { a as useAgentComputerWindow, r as useAgentComputerAppHandlers } from "./AgentComputer-CFJxjMFE.js";
1
+ import { a as useAgentComputerWindow, r as useAgentComputerAppHandlers } from "./AgentComputer-DZCyQkcE.js";
2
2
  import { c } from "react/compiler-runtime";
3
3
  import * as React from "react";
4
4
  import { jsx } from "react/jsx-runtime";
@@ -359,6 +359,22 @@
359
359
  .agent-computer__employee {
360
360
  min-inline-size: 0;
361
361
  }
362
+ /* The connection warning is a symbol, named by its title and hidden text. */
363
+ .agent-computer__connection {
364
+ display: inline-flex;
365
+ align-items: center;
366
+ gap: var(--sigvelo-spacing-2);
367
+ }
368
+ @container agent-computer (inline-size <= 48rem) {
369
+ .agent-computer__connection {
370
+ display: none;
371
+ }
372
+ }
373
+ /* On the phone the band is Home's widget area: the widget's own control opens
374
+ the conversation, so the menu bar's copy of it goes. */
375
+ [data-slot="agent-computer"][data-phone][data-home-widget] .agent-computer__conversation-toggle {
376
+ display: none;
377
+ }
362
378
  /* ---- the body: the stage --------------------------------------------- */
363
379
  .agent-computer__body {
364
380
  display: grid;
@@ -595,3 +595,8 @@
595
595
  .computer-finder .workspace-browser__entries[data-layout="list"] .computer-file-thumbnail {
596
596
  zoom: 0.3;
597
597
  }
598
+
599
+ /* The desktop's files fill the stage behind the windows. */
600
+ .computer-files-desktop {
601
+ block-size: 100%;
602
+ }
@@ -111,6 +111,7 @@
111
111
  @media (any-pointer: coarse) {
112
112
  :where(.agent-computer[data-phone]) .computer-notifications__trigger {
113
113
  min-block-size: var(--sigvelo-touch-target);
114
+ min-inline-size: var(--sigvelo-touch-target);
114
115
  }
115
116
  }
116
117
  .computer-notifications__count {
@@ -1,5 +1,5 @@
1
1
  import { n as isWorkspacePathWithinRoot } from "./workspace-path-TZggP-u4.js";
2
- import { readWorkspaceFile } from "./components/agents-sdk/WorkspaceFileTransfer.js";
2
+ import { i as readWorkspaceFile } from "./WorkspaceFileTransfer-D2cOoVyO.js";
3
3
  import { c } from "react/compiler-runtime";
4
4
  import * as React from "react";
5
5
  //#region src/components/_internal/workspace-drag.ts
@@ -2,11 +2,11 @@ import { g as ChevronRightIcon, gt as XIcon, h as ChevronLeftIcon } from "./icon
2
2
  import { Button } from "./components/foundations/Button.js";
3
3
  import { Dialog } from "./components/foundations/Dialog.js";
4
4
  import { i as workspaceBasename } from "./workspace-path-TZggP-u4.js";
5
- import { i as PortalContext } from "./context-Ddsp8HgD.js";
5
+ import { g as workspaceFileCommandForKey } from "./WorkspaceFileTransfer-D2cOoVyO.js";
6
+ import { c as PortalContext } from "./context-BWJpR084.js";
6
7
  import { AppTopBar } from "./components/general-purpose/AppTopBar.js";
7
8
  import { a as hasModifier, r as FileGridArtwork, t as ComputerFileThumbnail } from "./ComputerFileThumbnail-CXHy127c.js";
8
9
  import { ContextMenu } from "./components/foundations/ContextMenu.js";
9
- import { workspaceFileCommandForKey } from "./components/agents-sdk/WorkspaceFileCommands.js";
10
10
  import { r as WorkspacePreviewFrame } from "./workspace-media-preview-B4iB5Tvi.js";
11
11
  import { c } from "react/compiler-runtime";
12
12
  import * as React from "react";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mcp-b/react-components",
3
- "version": "0.70.0",
3
+ "version": "0.71.0",
4
4
  "description": "MCP-B React components built on Base UI and shared design tokens, including Cloudflare Think chat primitives.",
5
5
  "homepage": "https://design-system.sigvelo.com",
6
6
  "bugs": {
@@ -55,7 +55,7 @@
55
55
  "streamdown": "^2.7.0",
56
56
  "unist-util-visit": "^5.1.0",
57
57
  "yet-another-react-lightbox": "^3.32.2",
58
- "@mcp-b/design-tokens": "0.70.0"
58
+ "@mcp-b/design-tokens": "0.71.0"
59
59
  },
60
60
  "devDependencies": {
61
61
  "@ai-sdk/react": "^4.0.136",
@@ -1,34 +0,0 @@
1
- import { ComponentPropsWithRef, ReactNode } from "react";
2
- //#region src/components/general-purpose/WallpaperPicker.d.ts
3
- /** One host-supplied background. */
4
- interface WallpaperOption {
5
- /** Stable identifier stored by the consuming application. */
6
- value: string;
7
- /** Visible and accessible name for this background. */
8
- label: string;
9
- /** Trusted CSS background shorthand supplied by the host. */
10
- background: string;
11
- /**
12
- * The same picture's dark variant, as a background shorthand. It fades in
13
- * over `background` while the document is dark: `data-theme="dark"`, or no
14
- * `data-theme` and a dark OS.
15
- */
16
- darkBackground?: string;
17
- }
18
- /** Props for {@link WallpaperPicker}. */
19
- interface WallpaperPickerProps extends Omit<ComponentPropsWithRef<"div">, "children" | "aria-label"> {
20
- /** References a visible label for the thumbnail radio group. Defaults to its heading. */
21
- "aria-labelledby"?: string;
22
- /** Host-owned backgrounds. The picker owns no catalog or persistent state. */
23
- wallpapers: readonly WallpaperOption[];
24
- /** The selected wallpaper identifier. */
25
- value: string;
26
- /** Selection applies immediately. Arrow keys also select a background. */
27
- onValueChange: (value: string) => void;
28
- /** Host controls beside the current preview, such as a theme preference. */
29
- selectionControls?: ReactNode;
30
- }
31
- /** A wallpaper preview and thumbnail gallery over the shared radio-group contract. */
32
- declare function WallpaperPicker({ wallpapers, value, onValueChange, selectionControls, className, "aria-labelledby": ariaLabelledBy, ...props }: WallpaperPickerProps): import("react").JSX.Element;
33
- //#endregion
34
- export { WallpaperPicker as n, WallpaperPickerProps as r, WallpaperOption as t };
@@ -1,17 +0,0 @@
1
- import * as React from "react";
2
- //#region src/components/_internal/computer-apps/automations-host.ts
3
- const ComputerAutomationsContext = React.createContext(null);
4
- function useComputerAutomationsContext() {
5
- const value = React.use(ComputerAutomationsContext);
6
- if (!value) throw new Error("Automations and Calendar need ComputerAutomations.Host.");
7
- return value;
8
- }
9
- /** A formatter in the employee's working timezone. */
10
- function zonedFormat(timeZone, options) {
11
- return new Intl.DateTimeFormat("en-US", {
12
- ...options,
13
- timeZone
14
- });
15
- }
16
- //#endregion
17
- export { useComputerAutomationsContext as n, zonedFormat as r, ComputerAutomationsContext as t };