@qwen-code/web-shell 0.26.2-preview.1 → 0.26.3-nightly.20261028.ca204559a7
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/README.md +39 -2
- package/dist/{PierreFilePreview-Cf76KkJc.js → PierreFilePreview-gL1oCaFW.js} +1 -1
- package/dist/{SpreadsheetPreview-BXxrs6FZ.js → SpreadsheetPreview-CUn1GBWK.js} +2 -2
- package/dist/{WorkspaceFileBrowser-Cfi_Fx8Q.js → WorkspaceFileBrowser-CRQ4kvpc.js} +2 -2
- package/dist/{agents-route-Dc73Pt04.js → agents-route-BnbsQlQd.js} +2 -2
- package/dist/daemon-react-sdk.js +1 -1
- package/dist/{index-DjRVj9L_.js → index--8imD68R.js} +61948 -60550
- package/dist/index.js +3 -3
- package/dist/sw.js +1 -1
- package/dist/transcript.js +8297 -8129
- package/dist/types/App.d.ts +3 -1
- package/dist/types/adapters/messageTypes.d.ts +9 -0
- package/dist/types/components/autofixPr/AutofixPrWatchSummary.d.ts +30 -0
- package/dist/types/components/composer/AddMenu.d.ts +2 -1
- package/dist/types/components/dialogs/AutofixPrWatchesDialog.d.ts +27 -0
- package/dist/types/components/dialogs/ScheduledTasksDialog.d.ts +9 -3
- package/dist/types/components/messages/McpApp.d.ts +8 -1
- package/dist/types/components/messages/SettingsMessage.d.ts +2 -1
- package/dist/types/components/sidebar/SessionRenameEditor.d.ts +20 -0
- package/dist/types/components/sidebar/WebShellSidebar.d.ts +7 -2
- package/dist/types/components/sidebar/WorkspaceSection.d.ts +10 -1
- package/dist/types/components/sidebar/sessionTree.d.ts +37 -0
- package/dist/types/components/sidebar/useSessionTree.d.ts +19 -0
- package/dist/types/customization.d.ts +1 -0
- package/dist/types/daemon/index.d.ts +1 -1
- package/dist/types/daemon/session/actions.d.ts +3 -1
- package/dist/types/daemon/session/types.d.ts +14 -1
- package/dist/types/daemon/workspace/index.d.ts +1 -1
- package/dist/types/daemon/workspace/types.d.ts +71 -0
- package/dist/types/daemon-react-sdk.d.ts +4 -0
- package/dist/types/generated-ui/GeneratedUiRuntimeProvider.d.ts +12 -0
- package/dist/types/generated-ui/instance-store.d.ts +92 -0
- package/dist/types/hooks/useAutofixPrWatches.d.ts +25 -0
- package/dist/types/mcpAppHostContext.d.ts +27 -1
- package/dist/types/session-catalog/session-catalog-hooks.d.ts +1 -0
- package/dist/types/session-catalog/session-catalog-store.d.ts +20 -0
- package/dist/types/settings.d.ts +1 -1
- package/dist/types/utils/autofixPrWatches.d.ts +45 -0
- package/dist/types/utils/navigationUrl.d.ts +1 -1
- package/dist/types/utils/sessionTitleFromPrompt.d.ts +11 -0
- package/dist/{useDaemonMidTurnInjected-DY7azBbC.js → useDaemonMidTurnInjected-Du9Zxaez.js} +5988 -5628
- package/package.json +1 -1
package/dist/types/App.d.ts
CHANGED
|
@@ -220,6 +220,8 @@ export interface WebShellProps {
|
|
|
220
220
|
composerToolbarActions?: readonly ComposerToolbarAction[];
|
|
221
221
|
/** Execution mode choices. Overrides ui.allowedApprovalModes; [] offers none. Presentation only. */
|
|
222
222
|
allowedApprovalModes?: readonly WebShellApprovalMode[];
|
|
223
|
+
/** Composer presentation shared by the main chat, split panes, and side tasks. */
|
|
224
|
+
composerVariant?: 'default' | 'simple';
|
|
223
225
|
/** Optionally filter main-model entries without changing shared defaults. */
|
|
224
226
|
mainModelFilter?: (model: ModelDialogModel) => boolean;
|
|
225
227
|
/** Stack completion details vertically for narrow embedded hosts. */
|
|
@@ -456,4 +458,4 @@ export declare function canArchiveSideTaskSummary(session: Pick<DaemonSessionSum
|
|
|
456
458
|
export declare function mergeSideTaskCatalog(catalog: SideTaskCatalogState, parentSessionId: string, listedItems: SideTaskListItem[], optimisticIds: ReadonlySet<string>): SideTaskCatalogState;
|
|
457
459
|
export declare function getEnvironmentAgentTasks(messages: readonly Message[], sessionTasks: readonly DaemonSessionTaskWithWorkflowStatus[]): EnvironmentAgentTask[];
|
|
458
460
|
export declare function mergeAgentTrace(liveAgents: readonly EnvironmentAgentTask[], trace: DaemonAgentTrace | undefined, now?: number): EnvironmentAgentTask[];
|
|
459
|
-
export declare function App({ onRefreshModels, askUserFreeTextLabel, onSessionIdChange, onSessionInfoChange, onSessionCreated, managedAgentProvider, theme: providedTheme, onThemeChange, onThemeResolved, language: providedLanguage, onLanguageChange, onLanguageResolved, brand: providedBrand, onBrandResolved, className: externalClassName, style: externalStyle, shadowDom, onConnectionChange, onStreamingStateChange, onError, onBugReport, hiddenSlashCommands, slashCommandCategoryOrder, onSlashCommand, builtinAtProviders, atProviders, composerTagIcons, fileUploadEnabled, fileUploadDirectory, artifact, fileDropAction, renderToolHeaderExtra, renderWelcomeHeader, renderWelcomeFooter, mobileWelcomeFooterMiddle, parseUserMessageContent, renderUserMessageContent, renderComposerTag, renderComposerTagTooltip, onComposerTagClick, renderAssistantTurnFooter, assistantFeedback, getAssistantSourcesIcon, sourceReferences, renderComposerToolbarStart, renderComposerToolbarEnd, renderComposerToolbarRight, renderComposerHeader, renderComposerFooter, renderChatHeader, renderFooter, bottomStatusItems, chatMaxWidth, sidebar, settings: settingsPresentation, modelManagement, unavailableModels, mountUnavailableModelTooltip, header, rightPanel, showToolCalls, environmentPanel, splitSessionIds: externalSplitSessionIds, onSplitSessionIdsChange, renderPaneHeaderActions, onRightPanelOpen, onFileReviewOpen, onWorkspaceFileOpen, onInsightReportOpen, onContextUsageOpen, messageTurnOutputs, filterArtifact, shellRef, composerToolbarActions, allowedApprovalModes: allowedApprovalModesProp, mainModelFilter, compactComposerOverlays, autoSubmitSlashCommands, additionalSlashCommands, contextUsageAlwaysVisible, userMessageEditing, onUserMessageEditRequest, cycleModeOnTab, sessionSourceType, composerToolbarAdditionalActions, composerPlaceholders, compactThinking, hostOwnsEditDiffPreview, collapseCompletedTurns, markdownTableMode, virtualScrollThreshold, conversationSearchThreshold, markdown, loadingPhrases, onAgentTasksChange, onTranscriptChange, onSessionArtifactsChange, onToast, composerRef, onComposerReady, composerInput, composerInputVersion, onSessionChange, onAssistantTurnSettled, prepareSubmit, onSubmitBefore, restartSseOnPrompt, historyPageSize, initialSelectedWorkspaceCwd, lockedWorkspaceCwd, lockedWorkspaceCapability, }?: AppProps): import("react/jsx-runtime").JSX.Element;
|
|
461
|
+
export declare function App({ onRefreshModels, askUserFreeTextLabel, onSessionIdChange, onSessionInfoChange, onSessionCreated, managedAgentProvider, theme: providedTheme, onThemeChange, onThemeResolved, language: providedLanguage, onLanguageChange, onLanguageResolved, brand: providedBrand, onBrandResolved, className: externalClassName, style: externalStyle, shadowDom, onConnectionChange, onStreamingStateChange, onError, onBugReport, hiddenSlashCommands, slashCommandCategoryOrder, onSlashCommand, builtinAtProviders, atProviders, composerTagIcons, fileUploadEnabled, fileUploadDirectory, artifact, fileDropAction, renderToolHeaderExtra, renderWelcomeHeader, renderWelcomeFooter, mobileWelcomeFooterMiddle, parseUserMessageContent, renderUserMessageContent, renderComposerTag, renderComposerTagTooltip, onComposerTagClick, renderAssistantTurnFooter, assistantFeedback, getAssistantSourcesIcon, sourceReferences, renderComposerToolbarStart, renderComposerToolbarEnd, renderComposerToolbarRight, renderComposerHeader, renderComposerFooter, renderChatHeader, renderFooter, bottomStatusItems, chatMaxWidth, sidebar, settings: settingsPresentation, modelManagement, unavailableModels, mountUnavailableModelTooltip, header, rightPanel, showToolCalls, environmentPanel, splitSessionIds: externalSplitSessionIds, onSplitSessionIdsChange, renderPaneHeaderActions, onRightPanelOpen, onFileReviewOpen, onWorkspaceFileOpen, onInsightReportOpen, onContextUsageOpen, messageTurnOutputs, filterArtifact, shellRef, composerToolbarActions, allowedApprovalModes: allowedApprovalModesProp, composerVariant, mainModelFilter, compactComposerOverlays, autoSubmitSlashCommands, additionalSlashCommands, contextUsageAlwaysVisible, userMessageEditing, onUserMessageEditRequest, cycleModeOnTab, sessionSourceType, composerToolbarAdditionalActions, composerPlaceholders, compactThinking, hostOwnsEditDiffPreview, collapseCompletedTurns, markdownTableMode, virtualScrollThreshold, conversationSearchThreshold, markdown, loadingPhrases, onAgentTasksChange, onTranscriptChange, onSessionArtifactsChange, onToast, composerRef, onComposerReady, composerInput, composerInputVersion, onSessionChange, onAssistantTurnSettled, prepareSubmit, onSubmitBefore, restartSseOnPrompt, historyPageSize, initialSelectedWorkspaceCwd, lockedWorkspaceCwd, lockedWorkspaceCapability, }?: AppProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -42,6 +42,8 @@ export interface DaemonMessageToolCall {
|
|
|
42
42
|
parentToolCallId?: string;
|
|
43
43
|
/** The producer's own call ID when `callId` is keyed by something else. */
|
|
44
44
|
toolCallId?: string;
|
|
45
|
+
/** Stable producer identity from the daemon tool-block projection only. */
|
|
46
|
+
generatedUiToolCallId?: string;
|
|
45
47
|
title?: string;
|
|
46
48
|
content?: readonly DaemonMessageToolCallContent[];
|
|
47
49
|
rawOutput?: unknown;
|
|
@@ -53,6 +55,13 @@ export interface DaemonMessageToolCall {
|
|
|
53
55
|
endTime?: number;
|
|
54
56
|
wasCancelled?: boolean;
|
|
55
57
|
subContent?: string;
|
|
58
|
+
/**
|
|
59
|
+
* Path-style identity of the agent that produced this call's sub-content,
|
|
60
|
+
* e.g. `/root/general-purpose`. Carried from the transcript block's `agent`
|
|
61
|
+
* field so the panel can name a subagent precisely instead of by type alone
|
|
62
|
+
* — two parallel subagents of the same type are otherwise indistinguishable.
|
|
63
|
+
*/
|
|
64
|
+
agentPath?: string;
|
|
56
65
|
subTools?: DaemonMessageToolCall[];
|
|
57
66
|
/** Transcript blocks folded into this tool presentation. */
|
|
58
67
|
sourceBlockIds?: string[];
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Qwen Team
|
|
4
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
+
*/
|
|
6
|
+
import type { DaemonAutofixPrWatch } from '../../daemon/workspace/types';
|
|
7
|
+
interface AutofixPrWatchSummaryProps {
|
|
8
|
+
watch: DaemonAutofixPrWatch;
|
|
9
|
+
/** The scheduled task showing it no longer drives the watch. */
|
|
10
|
+
stale?: boolean;
|
|
11
|
+
/** Show the PR as a link heading (the PR watches page); a scheduled-task
|
|
12
|
+
* card names it in its own title. */
|
|
13
|
+
showPr?: boolean;
|
|
14
|
+
/** Open the session that owns the watch; absent when it is no session of
|
|
15
|
+
* this Web Shell. */
|
|
16
|
+
onOpenSession?: () => void;
|
|
17
|
+
/** Run `/autofix-pr stop <n>` in the session that owns the watch; absent
|
|
18
|
+
* when it is no session of this Web Shell. */
|
|
19
|
+
onStop?: () => void;
|
|
20
|
+
stopping?: boolean;
|
|
21
|
+
/** Its session is no session of this Web Shell: say where to stop it. */
|
|
22
|
+
outsideDaemon?: boolean;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* One watch's state, as `qwen autofix-pr status` reports it: where the watch
|
|
26
|
+
* is, its pushes and last check, and the items left for a person. Shared by
|
|
27
|
+
* the scheduled-task card of a watch and the PR watches page.
|
|
28
|
+
*/
|
|
29
|
+
export declare function AutofixPrWatchSummary({ watch, stale, showPr, onOpenSession, onStop, stopping, outsideDaemon, }: AutofixPrWatchSummaryProps): import("react/jsx-runtime").JSX.Element;
|
|
30
|
+
export {};
|
|
@@ -36,6 +36,7 @@ export interface AddMenuProps {
|
|
|
36
36
|
onLiveVoice?: () => void;
|
|
37
37
|
};
|
|
38
38
|
commandsOnly?: boolean;
|
|
39
|
+
simpleMode?: boolean;
|
|
39
40
|
}
|
|
40
41
|
export interface AddMenuPlanControl {
|
|
41
42
|
checked: boolean;
|
|
@@ -43,4 +44,4 @@ export interface AddMenuPlanControl {
|
|
|
43
44
|
disabled?: boolean;
|
|
44
45
|
onToggle: () => void;
|
|
45
46
|
}
|
|
46
|
-
export declare function AddMenu({ disabled, availabilityKey, addFileAvailable, uploadAvailable, onAddFiles, onFilePickerCancel, onInsertReference, onPrependSkill, getWorkspaceActions, skills, onSkillsOpenChange, skillsLoading, skillsLoadError, skillsLoaded, plan, btw, mobileActions, commandsOnly, }: AddMenuProps): import("react/jsx-runtime").JSX.Element;
|
|
47
|
+
export declare function AddMenu({ disabled, availabilityKey, addFileAvailable, uploadAvailable, onAddFiles, onFilePickerCancel, onInsertReference, onPrependSkill, getWorkspaceActions, skills, onSkillsOpenChange, skillsLoading, skillsLoadError, skillsLoaded, plan, btw, mobileActions, commandsOnly, simpleMode, }: AddMenuProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Qwen Team
|
|
4
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
+
*/
|
|
6
|
+
import type { DaemonWorkspaceCapability } from '@qwen-code/sdk/daemon';
|
|
7
|
+
interface AutofixPrWatchesDialogProps {
|
|
8
|
+
/** Run a prompt in a session of this Web Shell, as the scheduled-tasks
|
|
9
|
+
* page runs a task: `/autofix-pr stop <n>` in the watch's own session. */
|
|
10
|
+
onRunPrompt: (prompt: string, sessionId: string, workspaceCwd?: string) => void | Promise<void>;
|
|
11
|
+
/** `workspaceCwd`: the workspace of the session's task, where its
|
|
12
|
+
* session is restored (absent on a single-workspace page). */
|
|
13
|
+
onOpenSession: (sessionId: string, workspaceCwd?: string) => void;
|
|
14
|
+
/** Registered workspaces (multi-workspace daemons): every operable one's
|
|
15
|
+
* watches are listed, each under its workspace. */
|
|
16
|
+
workspaces?: DaemonWorkspaceCapability[];
|
|
17
|
+
/** Reads only this workspace's, by its own route. */
|
|
18
|
+
lockedWorkspace?: DaemonWorkspaceCapability;
|
|
19
|
+
onError: (error: unknown, fallback: string) => void;
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* The PR watches page: every `/autofix-pr` watch of the workspaces' clones,
|
|
23
|
+
* as `qwen autofix-pr status` lists them, with the session that runs each
|
|
24
|
+
* one. Stopping one runs the skill in that session.
|
|
25
|
+
*/
|
|
26
|
+
export declare function AutofixPrWatchesDialog({ onRunPrompt, onOpenSession, workspaces, lockedWorkspace, onError, }: AutofixPrWatchesDialogProps): import("react/jsx-runtime").JSX.Element;
|
|
27
|
+
export {};
|
|
@@ -8,13 +8,16 @@ interface ScheduledTasksDialogProps {
|
|
|
8
8
|
/** Manual "run now": execute the task's prompt in its bound session (so it
|
|
9
9
|
* lands in the same transcript as its scheduled runs), or in the current
|
|
10
10
|
* session for an unbound task. The App wiring switches to that session. */
|
|
11
|
-
onRunPrompt: (prompt: string, sessionId: string | null
|
|
11
|
+
onRunPrompt: (prompt: string, sessionId: string | null,
|
|
12
|
+
/** The task's workspace, on a multi-workspace page: its session is
|
|
13
|
+
* restored there, not in the current conversation's. */
|
|
14
|
+
workspaceCwd?: string) => void | Promise<void>;
|
|
12
15
|
/** Switch to the chat view with the composer primed to describe a task, so
|
|
13
16
|
* the agent can create it conversationally via its cron_create tool. */
|
|
14
17
|
onCreateViaChat: () => void;
|
|
15
18
|
/** Open a task's bound session — its transcript IS the task's run history.
|
|
16
19
|
* When absent, tasks fall back to the inline fire-timestamp list. */
|
|
17
|
-
onOpenSession?: (sessionId: string) => void;
|
|
20
|
+
onOpenSession?: (sessionId: string, workspaceCwd?: string) => void;
|
|
18
21
|
/** Registered workspaces on a multi-workspace daemon (from capabilities).
|
|
19
22
|
* When more than one is present the page aggregates every trusted workspace's
|
|
20
23
|
* tasks (each card tagged with its workspace) and the New-task form offers a
|
|
@@ -28,7 +31,10 @@ interface ScheduledTasksDialogProps {
|
|
|
28
31
|
* command and the request carries it. An older daemon would drop the field
|
|
29
32
|
* silently, so it is never sent without the capability. */
|
|
30
33
|
gateAvailable?: boolean;
|
|
34
|
+
/** The daemon advertises `autofix_pr_watches`: the card of an
|
|
35
|
+
* `/autofix-pr` watch's task shows the watch's state, and can stop it. */
|
|
36
|
+
autofixPrWatchesAvailable?: boolean;
|
|
31
37
|
onError: (error: unknown, fallback: string) => void;
|
|
32
38
|
}
|
|
33
|
-
export declare function ScheduledTasksDialog({ onRunPrompt, onCreateViaChat, onOpenSession, workspaces, lockedWorkspace, currentSession, currentSessionSchedulingAvailable, gateAvailable, onError, }: ScheduledTasksDialogProps): import("react/jsx-runtime").JSX.Element;
|
|
39
|
+
export declare function ScheduledTasksDialog({ onRunPrompt, onCreateViaChat, onOpenSession, workspaces, lockedWorkspace, currentSession, currentSessionSchedulingAvailable, gateAvailable, autofixPrWatchesAvailable, onError, }: ScheduledTasksDialogProps): import("react/jsx-runtime").JSX.Element;
|
|
34
40
|
export {};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { AppBridge } from '@modelcontextprotocol/ext-apps/app-bridge';
|
|
2
|
+
import type { GeneratedUiInstance } from '../../generated-ui/instance-store';
|
|
2
3
|
type SandboxResource = Parameters<AppBridge['sendSandboxResourceReady']>[0];
|
|
3
4
|
type AppToolResult = Parameters<AppBridge['sendToolResult']>[0];
|
|
4
5
|
export interface McpAppDisplay {
|
|
@@ -19,7 +20,13 @@ export declare function applySandboxCspQuery(sandboxUrl: string, cspJson: string
|
|
|
19
20
|
export declare function GeneratedUiFallback({ display }: {
|
|
20
21
|
display: McpAppDisplay;
|
|
21
22
|
}): import("react/jsx-runtime").JSX.Element;
|
|
22
|
-
export declare function McpApp({ display }: {
|
|
23
|
+
export declare function McpApp({ display, toolId, visible, }: {
|
|
23
24
|
display: McpAppDisplay;
|
|
25
|
+
toolId?: string;
|
|
26
|
+
visible?: boolean;
|
|
27
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
28
|
+
export declare function McpAppRuntime({ display, retained, }: {
|
|
29
|
+
display: McpAppDisplay;
|
|
30
|
+
retained?: GeneratedUiInstance['runtime'];
|
|
24
31
|
}): import("react/jsx-runtime").JSX.Element;
|
|
25
32
|
export {};
|
|
@@ -24,6 +24,7 @@ interface SettingsMessageProps {
|
|
|
24
24
|
modelManagementSectionProps?: ModelManagementProps;
|
|
25
25
|
/** Browser-local remote computer catalog and connection controls. */
|
|
26
26
|
connections?: ReactNode;
|
|
27
|
+
archivedSessions?: ReactNode;
|
|
27
28
|
/**
|
|
28
29
|
* Extra-directory management for the selected workspace. Rendered only on
|
|
29
30
|
* the Workspace scope tab; omitted when the daemon cannot manage them.
|
|
@@ -63,5 +64,5 @@ export type FlatRow = {
|
|
|
63
64
|
localKey: 'chatWidth' | 'browserNotifications';
|
|
64
65
|
};
|
|
65
66
|
export declare function nextSettingIdx(rows: FlatRow[], current: number, dir: 1 | -1): number;
|
|
66
|
-
export declare function SettingsMessage({ settingsState, presentation, onLanguageChange, onOutputLanguageChange, onSubDialog, onThemeChange, chatWidthMode, onChatWidthModeChange, modelManagementSectionProps, connections, workspaceDirectoriesSection, embedded, initialCategory, workspaceSettingsWritable, }: SettingsMessageProps): import("react/jsx-runtime").JSX.Element;
|
|
67
|
+
export declare function SettingsMessage({ settingsState, presentation, onLanguageChange, onOutputLanguageChange, onSubDialog, onThemeChange, chatWidthMode, onChatWidthModeChange, modelManagementSectionProps, connections, archivedSessions, workspaceDirectoriesSection, embedded, initialCategory, workspaceSettingsWritable, }: SettingsMessageProps): import("react/jsx-runtime").JSX.Element;
|
|
67
68
|
export {};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2025 Qwen Team
|
|
4
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
+
*/
|
|
6
|
+
export interface SessionRenameEditorProps {
|
|
7
|
+
label: string;
|
|
8
|
+
/** Restores an in-progress draft after the row moves or remounts. */
|
|
9
|
+
initialName?: string;
|
|
10
|
+
/** Records the draft outside the editor so a remount cannot lose it. */
|
|
11
|
+
onDraftChange?: (displayName: string) => void;
|
|
12
|
+
onCommit: (displayName: string) => void;
|
|
13
|
+
onCancel: () => void;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* Keeps the draft local to the input. Lifting it into WebShellSidebar made
|
|
17
|
+
* every keystroke rebuild the whole (fully expanded) session list, because
|
|
18
|
+
* the row renderer depends on the sidebar's editing state.
|
|
19
|
+
*/
|
|
20
|
+
export declare function SessionRenameEditor({ label, initialName, onDraftChange, onCommit, onCancel, }: SessionRenameEditorProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -17,7 +17,7 @@ export interface WebShellSidebarLockedWorkspace {
|
|
|
17
17
|
expanded: boolean;
|
|
18
18
|
}) => ReactNode;
|
|
19
19
|
}
|
|
20
|
-
export type WebShellSidebarPrimaryNavItem = 'newTask' | 'agents' | 'plugins' | 'channels' | 'live' | 'scheduledTasks' | 'workflows' | 'goals' | 'managed';
|
|
20
|
+
export type WebShellSidebarPrimaryNavItem = 'newTask' | 'agents' | 'plugins' | 'channels' | 'live' | 'scheduledTasks' | 'prWatches' | 'workflows' | 'goals' | 'managed';
|
|
21
21
|
export interface WebShellSidebarPrimaryNavOptions {
|
|
22
22
|
/** Built-in primary nav entries to show. Embedded hosts default to New task only. */
|
|
23
23
|
items?: readonly WebShellSidebarPrimaryNavItem[];
|
|
@@ -77,6 +77,9 @@ interface WebShellSidebarProps {
|
|
|
77
77
|
onOpenManagedSessions?: () => void;
|
|
78
78
|
onOpenDaemonStatus: () => void;
|
|
79
79
|
onOpenScheduledTasks: () => void;
|
|
80
|
+
/** Opens the PR watches page; absent when the daemon does not list
|
|
81
|
+
* `/autofix-pr` watches (`autofix_pr_watches`). */
|
|
82
|
+
onOpenPrWatches?: () => void;
|
|
80
83
|
onOpenWorkflows: () => void;
|
|
81
84
|
onOpenGoals: () => void;
|
|
82
85
|
onOpenSessions: () => void;
|
|
@@ -143,6 +146,8 @@ interface WebShellSidebarProps {
|
|
|
143
146
|
sessionContent?: ReactNode;
|
|
144
147
|
sessionHeader?: ReactNode;
|
|
145
148
|
managedWorkspaces?: ReactNode;
|
|
149
|
+
canOpenSettings?: boolean;
|
|
150
|
+
archivedSessionsTarget?: HTMLElement | null;
|
|
146
151
|
managedArchivedSessions?: ManagedArchivedSessionsStatus & {
|
|
147
152
|
content: ReactNode;
|
|
148
153
|
};
|
|
@@ -176,4 +181,4 @@ interface WebShellSidebarProps {
|
|
|
176
181
|
onLoadStandaloneSession?: (sessionId: string, displayName?: string) => Promise<void> | void;
|
|
177
182
|
onStandaloneNotice?: (message: string) => void;
|
|
178
183
|
}
|
|
179
|
-
export declare function WebShellSidebar({ collapsed, layout, activePage, containerWidth, onOpenHome, onCollapsedChange, onOpenSettings, onOpenAgents, onOpenPlugins, onOpenChannels, onOpenLive, onLiveVoiceSlotChange, onOpenManagedSessions, onOpenDaemonStatus, onOpenScheduledTasks, onOpenWorkflows, onOpenGoals, onOpenSessions, canOpenSessionsOverview, onOpenWorkspacesOverview, onOpenSplitView, canOpenSplitView, onNewSession, onNewStandaloneSession, onLoadSession, onOpenHostSession, onSelectCurrentSession, onSessionRenameConfirmed, onSessionsDeleted, onError, theme, onThemeChange, mobileOpen, onMobileClose, selectedWorkspaceCwd, onSelectWorkspace, onOpenGitDiff, onOpenCommit, onOpenAddWorkspace, workspaces: providedWorkspaces, lockedWorkspaceCwd, lockedWorkspace: lockedWorkspaceOptions, branding, primaryNav: primaryNavOptions, sessionContent, sessionHeader, managedWorkspaces, managedArchivedSessions, onSearchQueryChange, currentSessionActive, showSessionSourceSwitch, showLive, hideProjectHeader, sessionActions: sessionActionsOptions, footer, workspaceOverview, onOpenWorkspaceManagement, onNewWorktreeSession, projectFeaturesEnabled, onLoadStandaloneSession, onStandaloneNotice, }: WebShellSidebarProps): import("react/jsx-runtime").JSX.Element;
|
|
184
|
+
export declare function WebShellSidebar({ collapsed, layout, activePage, containerWidth, onOpenHome, onCollapsedChange, onOpenSettings, canOpenSettings, onOpenAgents, onOpenPlugins, onOpenChannels, onOpenLive, onLiveVoiceSlotChange, onOpenManagedSessions, onOpenDaemonStatus, onOpenScheduledTasks, onOpenPrWatches, onOpenWorkflows, onOpenGoals, onOpenSessions, canOpenSessionsOverview, onOpenWorkspacesOverview, onOpenSplitView, canOpenSplitView, onNewSession, onNewStandaloneSession, onLoadSession, onOpenHostSession, onSelectCurrentSession, onSessionRenameConfirmed, onSessionsDeleted, onError, theme, onThemeChange, mobileOpen, onMobileClose, selectedWorkspaceCwd, onSelectWorkspace, onOpenGitDiff, onOpenCommit, onOpenAddWorkspace, workspaces: providedWorkspaces, lockedWorkspaceCwd, lockedWorkspace: lockedWorkspaceOptions, branding, primaryNav: primaryNavOptions, sessionContent, sessionHeader, managedWorkspaces, managedArchivedSessions, archivedSessionsTarget, onSearchQueryChange, currentSessionActive, showSessionSourceSwitch, showLive, hideProjectHeader, sessionActions: sessionActionsOptions, footer, workspaceOverview, onOpenWorkspaceManagement, onNewWorktreeSession, projectFeaturesEnabled, onLoadStandaloneSession, onStandaloneNotice, }: WebShellSidebarProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { type ReactNode } from 'react';
|
|
2
2
|
import type { DaemonClient, DaemonSessionGroupCatalog } from '@qwen-code/sdk/daemon';
|
|
3
3
|
import type { DaemonSessionGroup, DaemonSessionSummary, DaemonWorkspaceCapability } from '@qwen-code/sdk/daemon';
|
|
4
|
+
import type { SessionTreeRenderOptions } from './sessionTree';
|
|
4
5
|
import { type WorkspaceOverviewItem, type WorkspaceOverviewSnapshot, type WorkspaceSessionStats } from './workspaceOverviewModel';
|
|
5
6
|
export declare function isAbsolutePath(cwd: string): boolean;
|
|
6
7
|
export interface WorkspaceHeaderActionsContext {
|
|
@@ -51,6 +52,7 @@ interface WorkspaceSectionProps {
|
|
|
51
52
|
*/
|
|
52
53
|
renderSession: (session: DaemonSessionSummary, options?: {
|
|
53
54
|
searchSnippet?: string | undefined;
|
|
55
|
+
tree?: SessionTreeRenderOptions;
|
|
54
56
|
}) => ReactNode;
|
|
55
57
|
pendingSession?: {
|
|
56
58
|
key: string;
|
|
@@ -99,6 +101,13 @@ interface WorkspaceSectionProps {
|
|
|
99
101
|
groupActionsDisabled?: boolean;
|
|
100
102
|
excludePinned?: boolean;
|
|
101
103
|
limitSessions?: boolean;
|
|
104
|
+
/**
|
|
105
|
+
* The session currently being renamed in the sidebar, when this section owns
|
|
106
|
+
* it. A catalog refresh can reorder rows while the editor is open; revealing
|
|
107
|
+
* only the list that would truncate the edited row keeps it mounted. The
|
|
108
|
+
* sidebar leaves this undefined when the Pinned section hosts the editor.
|
|
109
|
+
*/
|
|
110
|
+
editingSessionId?: string;
|
|
102
111
|
/**
|
|
103
112
|
* Whether the sidebar-level Pinned section renders this session. Pinned
|
|
104
113
|
* rows have one owner: a pinned content-search ghost is kept in this
|
|
@@ -126,5 +135,5 @@ interface WorkspaceSectionProps {
|
|
|
126
135
|
/** Commit entry for the same picker; the row still opens without it. */
|
|
127
136
|
onOpenCommit?: (workspaceCwd: string) => void;
|
|
128
137
|
}
|
|
129
|
-
export declare function WorkspaceSection({ workspace, executionLabel, storageKey, remote, renderHeader, hideHeader, client, reloadToken, untrustedLabel, readOnlyLabel, trustToOpenLabel, noSessionsLabel, loadErrorLabel, organizationEnabled, sessionCatalogRequestsEnabled, sessionGroupCatalog, sessionLiveStateEnabled, sourceType, channelGroupingEnabled, ungroupedLabel, searchQuery, expanded: controlledExpanded, autoExpandKey, forceAutoExpand, onExpandedChange, renderSessions, renderSession, pendingSession, mapSession, showSessionDetails, headerActions, overviewEnabled, overviewMenuOpen, overviewItems, gitBranchWanted, sessionStats, onRenameGroup, onDeleteGroup, renameGroupLabel, deleteGroupLabel, groupActionsDisabled, excludePinned, limitSessions, isPinnedSectionMember, onOpenPathLocally, onOpenTerminalLocally, onOpenGitDiff, onOpenCommit, }: WorkspaceSectionProps): import("react/jsx-runtime").JSX.Element;
|
|
138
|
+
export declare function WorkspaceSection({ workspace, executionLabel, storageKey, remote, renderHeader, hideHeader, client, reloadToken, untrustedLabel, readOnlyLabel, trustToOpenLabel, noSessionsLabel, loadErrorLabel, organizationEnabled, sessionCatalogRequestsEnabled, sessionGroupCatalog, sessionLiveStateEnabled, sourceType, channelGroupingEnabled, ungroupedLabel, searchQuery, expanded: controlledExpanded, autoExpandKey, forceAutoExpand, onExpandedChange, renderSessions, renderSession, pendingSession, mapSession, showSessionDetails, headerActions, overviewEnabled, overviewMenuOpen, overviewItems, gitBranchWanted, sessionStats, onRenameGroup, onDeleteGroup, renameGroupLabel, deleteGroupLabel, groupActionsDisabled, excludePinned, limitSessions, editingSessionId, isPinnedSectionMember, onOpenPathLocally, onOpenTerminalLocally, onOpenGitDiff, onOpenCommit, }: WorkspaceSectionProps): import("react/jsx-runtime").JSX.Element;
|
|
130
139
|
export {};
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Qwen Team
|
|
4
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
+
*/
|
|
6
|
+
import type { DaemonSessionSummary } from '@qwen-code/sdk/daemon';
|
|
7
|
+
export interface SessionTreeOptions {
|
|
8
|
+
expandedParentIds?: ReadonlySet<string>;
|
|
9
|
+
/**
|
|
10
|
+
* Parent ids rendered expanded regardless of the stored toggle. A search
|
|
11
|
+
* uses this so a matched child is never hidden behind a collapsed parent.
|
|
12
|
+
*/
|
|
13
|
+
forceExpandedParentIds?: ReadonlySet<string>;
|
|
14
|
+
}
|
|
15
|
+
export interface SessionTreeRow {
|
|
16
|
+
session: DaemonSessionSummary;
|
|
17
|
+
depth: 0 | 1;
|
|
18
|
+
childCount: number;
|
|
19
|
+
expanded: boolean;
|
|
20
|
+
}
|
|
21
|
+
/** Tree state a session row needs to render its chevron and indentation. */
|
|
22
|
+
export interface SessionTreeRenderOptions {
|
|
23
|
+
depth: 0 | 1;
|
|
24
|
+
childCount: number;
|
|
25
|
+
expanded: boolean;
|
|
26
|
+
onToggle: () => void;
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* Orders a page of sessions so derived sessions render under their spawner.
|
|
30
|
+
* The daemon caps nesting at one level, so the result never has a depth above
|
|
31
|
+
* one. A child is emitted right after its parent and only when the parent is
|
|
32
|
+
* expanded; roots keep the page's activity order. A child whose parent is not
|
|
33
|
+
* in the page keeps its own row (depth 0) so it stays reachable.
|
|
34
|
+
*/
|
|
35
|
+
export declare function buildSessionTree(sessions: readonly DaemonSessionSummary[], options?: SessionTreeOptions): SessionTreeRow[];
|
|
36
|
+
export declare function readSessionTreeExpanded(storageId: string): Set<string>;
|
|
37
|
+
export declare function writeSessionTreeExpanded(storageId: string, parentIds: ReadonlySet<string>): void;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Qwen Team
|
|
4
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
+
*/
|
|
6
|
+
import type { DaemonSessionSummary } from '@qwen-code/sdk/daemon';
|
|
7
|
+
import { type SessionTreeRenderOptions, type SessionTreeRow } from './sessionTree';
|
|
8
|
+
export interface SessionTreeControllers {
|
|
9
|
+
/** Rows for one surface (a flat list or one group section). */
|
|
10
|
+
buildRows: (sessions: readonly DaemonSessionSummary[]) => SessionTreeRow[];
|
|
11
|
+
/** Per-row state to hand to the session row renderer. */
|
|
12
|
+
renderOptions: (row: SessionTreeRow) => SessionTreeRenderOptions;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* Expansion state for the sidebar's session tree, persisted per surface
|
|
16
|
+
* (`storageId` is the workspace's sidebar storage id). Search results force
|
|
17
|
+
* every matched parent open so a matched child is never hidden.
|
|
18
|
+
*/
|
|
19
|
+
export declare function useSessionTree(storageId: string, searchedSessions: readonly DaemonSessionSummary[], searchActive: boolean): SessionTreeControllers;
|
|
@@ -526,6 +526,7 @@ export interface WebShellCustomization {
|
|
|
526
526
|
parseUserMessageContent?: UserMessageContentParser;
|
|
527
527
|
renderUserMessageContent?: UserMessageContentRenderer;
|
|
528
528
|
composerTagIcons?: WebShellComposerTagIconMap;
|
|
529
|
+
composerVariant?: 'default' | 'simple';
|
|
529
530
|
/**
|
|
530
531
|
* Built-in / host @ mention providers. Split-view panes share this context
|
|
531
532
|
* so they match the main composer without ChatPane prop drilling.
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
export { DaemonSessionProvider, useDaemonActions, useDaemonActiveTodoList, useDaemonConnection, useDaemonPendingPermissions, useDaemonPromptStatus, useDaemonSessionNotices, useDaemonSessionOwnerGuard, useDaemonStreamingState, useDaemonSession, useDaemonTranscriptBlocks, useDaemonTranscriptHistory, useDaemonTranscriptState, useDaemonTranscriptStore, useDaemonTurnNavigationState, useDaemonTurnNavigationStore, useDaemonWorkspaceEventSignals, extractDaemonTodosFromToolBlock, hasDaemonActiveTodos, isDaemonSubAgentToolBlock, parseDaemonTodoItemsFromEntries, selectDaemonActiveTodoList, selectDaemonLatestTodoList, selectDaemonPendingPermissions, selectDaemonSubAgentToolBlocks, selectDaemonStreamingState, selectDaemonTodoLists, selectDaemonTranscriptStreamingState, isMissingSessionHttpStatus, toDaemonPromptContent, } from './session/index.js';
|
|
7
7
|
export type { DaemonCommandInfo, DaemonConnectionState, DaemonConnectionStatus, DaemonModelInfo, DaemonProductSessionContext, DaemonStandaloneConnectionState, DaemonNoticeCategory, DaemonNoticeOperation, DaemonNoticeSeverity, DaemonPromptFile, DaemonPromptImage, DaemonPromptStatus, DaemonReasoningControls, DaemonSessionActions, DaemonSessionContextValue, DaemonSessionNotice, DaemonSessionOwnerGuard, DaemonSessionOwnerSnapshot, DaemonSessionProviderProps, DaemonTranscriptHistory, DaemonPromptAdmission, DaemonProvisionalTurn, DaemonSelectedTurnState, DaemonTurnIndexPage, DaemonTurnLocation, DaemonTurnNavigationClient, DaemonTurnNavigationError, DaemonTurnNavigationSession, DaemonTurnNavigationSnapshot, DaemonTurnNavigationStore, HistoricalTranscriptPage, HistoricalTranscriptRange, TranscriptBoundary, DaemonTokenUsage, DaemonTodoItem, DaemonTodoList, DaemonTodoPriority, DaemonTodoStatus, DaemonStreamingState, DaemonWorkspaceEventSignals, PendingPromptActionOptions, SendPromptOptions, SubmitPromptOptions, SubmitPromptResult, } from './session/index.js';
|
|
8
8
|
export { DaemonWorkspaceProvider, useDaemonWorkspace, useDaemonWorkspaceActions, useOptionalDaemonWorkspace, useDaemonAgents, useDaemonAuth, useDaemonChannels, useDaemonDiagnostics, useDaemonFiles, useDaemonGlob, useDaemonMcp, useDaemonMemory, useDaemonResource, useDaemonSessions, useDaemonSkills, useDaemonStatusReport, useDaemonUsageDashboard, useDaemonTools, useDaemonSettings, useDaemonProviders, } from './workspace/index.js';
|
|
9
|
-
export type { DaemonDirectoryEntry, DaemonDirectoryListing, DaemonFileStat, DaemonGlobOptions, DaemonGlobResult, DaemonGoal, DaemonGoalList, DaemonScheduledTask, DaemonScheduledTaskGateStatus, DaemonScheduledTaskRun, DaemonCreateScheduledTaskRequest, DaemonUpdateScheduledTaskRequest, DaemonResourceOptions, DaemonChannelPairingActions, DaemonChannelsResource, DaemonStatusReportOptions, DaemonUsageDashboardOptions, DaemonWorkspaceActions, DaemonWorkspaceContextValue, DaemonWorkspaceProviderProps, DaemonWorkspaceStatus, ResourceResult, ResourceState, } from './workspace/index.js';
|
|
9
|
+
export type { DaemonDirectoryEntry, DaemonDirectoryListing, DaemonFileStat, DaemonGlobOptions, DaemonGlobResult, DaemonGoal, DaemonGoalList, DaemonAutofixPrWatch, DaemonAutofixPrWatchList, DaemonScheduledTask, DaemonScheduledTaskGateStatus, DaemonScheduledTaskRun, DaemonCreateScheduledTaskRequest, DaemonUpdateScheduledTaskRequest, DaemonResourceOptions, DaemonChannelPairingActions, DaemonChannelsResource, DaemonStatusReportOptions, DaemonUsageDashboardOptions, DaemonWorkspaceActions, DaemonWorkspaceContextValue, DaemonWorkspaceProviderProps, DaemonWorkspaceStatus, ResourceResult, ResourceState, } from './workspace/index.js';
|
|
10
10
|
export { useDaemonFollowupSuggestion, type UseDaemonFollowupSuggestionReturn, } from './useDaemonFollowupSuggestion.js';
|
|
11
11
|
export { useDaemonMidTurnInjected } from './useDaemonMidTurnInjected.js';
|
|
12
12
|
export { getPendingPromptVersion, getPendingPromptEvents, consumePendingPromptEvents, subscribePendingPromptEvents, subscribePendingPromptVersion, } from './pendingPromptVersion.js';
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
* SPDX-License-Identifier: Apache-2.0
|
|
5
5
|
*/
|
|
6
6
|
import type { Dispatch, SetStateAction } from 'react';
|
|
7
|
+
import type { McpAppGeneratedUiInvalidation } from '../../mcpAppHostContext.js';
|
|
7
8
|
import type { DaemonClient, DaemonSessionClient, CreateSessionRequest, DaemonTranscriptStore, DaemonCapabilities } from '@qwen-code/sdk/daemon';
|
|
8
9
|
import { type TimerRef } from '../timing.js';
|
|
9
10
|
import type { ActivePrompt, AddDaemonSessionNotice, DaemonActivePromptState, DaemonConnectionState, DaemonPromptStatus, DaemonSessionActions, SettledPrompt, PendingSessionLoad, DaemonProductSessionContext } from './types.js';
|
|
@@ -77,6 +78,7 @@ export interface CreateDaemonSessionActionsArgs {
|
|
|
77
78
|
setAttachSessionNonce: Dispatch<SetStateAction<number>>;
|
|
78
79
|
setNewSessionNonce: Dispatch<SetStateAction<number>>;
|
|
79
80
|
clearLiveJournalRepair?: () => void;
|
|
81
|
+
onGeneratedUiInvalidated?: (owner: DaemonSessionClient, reason: McpAppGeneratedUiInvalidation['reason'], sessionId?: string) => void;
|
|
80
82
|
onPromptAdmitted?: (owner: DaemonSessionClient, admission: {
|
|
81
83
|
promptId: string;
|
|
82
84
|
label: string;
|
|
@@ -88,7 +90,7 @@ export interface CreateDaemonSessionActionsArgs {
|
|
|
88
90
|
export declare function getWorkspaceModelsAfterSessionClear(current: DaemonConnectionState): DaemonConnectionState['models'];
|
|
89
91
|
export declare function getConnectionAfterSessionClear(current: DaemonConnectionState, clearedSessionId: string | undefined, preserveWorkspaceMetadata?: boolean, dropSessionContext?: boolean): DaemonConnectionState;
|
|
90
92
|
export declare function advanceSessionRecoveryGeneration(generations: WeakMap<DaemonSessionClient, number>, session: DaemonSessionClient): number;
|
|
91
|
-
export declare function createDaemonSessionActions({ store, sessionRef, activePromptsRef, settledPromptsRef, pendingSessionLoadRef, pendingSessionLoadIdRef, sessionConfigGeneration, sessionRecoveryGeneration, heartbeatSupportedRef, manualSessionClearRef, skipNextCleanupDetachSessionRef, passiveAssistantDoneTimerRef, daemonActivePromptRef, settleRestoredActivePrompt, flushTranscript, getCreateSessionRequest, createDetachedSession, createDetachedStandaloneSession, getDefaultSessionContext, getClient, getConnection, getEventDetailMode, hasSessionActivePrompt, resetCurrentSessionActivePrompt, restartEventStream, addNotice, setConnection, setPromptStatus, setRestoreSessionId, setRestoreSessionContext, setRestoreMode, setRestoreSessionNonce, setAttachSessionNonce, setNewSessionNonce, clearLiveJournalRepair, onPromptAdmitted, onContinuationAdmitted, onPromptRemoved, }: CreateDaemonSessionActionsArgs): DaemonSessionActions;
|
|
93
|
+
export declare function createDaemonSessionActions({ store, sessionRef, activePromptsRef, settledPromptsRef, pendingSessionLoadRef, pendingSessionLoadIdRef, sessionConfigGeneration, sessionRecoveryGeneration, heartbeatSupportedRef, manualSessionClearRef, skipNextCleanupDetachSessionRef, passiveAssistantDoneTimerRef, daemonActivePromptRef, settleRestoredActivePrompt, flushTranscript, getCreateSessionRequest, createDetachedSession, createDetachedStandaloneSession, getDefaultSessionContext, getClient, getConnection, getEventDetailMode, hasSessionActivePrompt, resetCurrentSessionActivePrompt, restartEventStream, addNotice, setConnection, setPromptStatus, setRestoreSessionId, setRestoreSessionContext, setRestoreMode, setRestoreSessionNonce, setAttachSessionNonce, setNewSessionNonce, clearLiveJournalRepair, onGeneratedUiInvalidated, onPromptAdmitted, onContinuationAdmitted, onPromptRemoved, }: CreateDaemonSessionActionsArgs): DaemonSessionActions;
|
|
92
94
|
/**
|
|
93
95
|
* Key under which a shell command tracks its prompt in the active-prompt map.
|
|
94
96
|
* Shell commands run as their own prompt alongside a conversation turn, so they
|
|
@@ -268,6 +268,12 @@ export interface SendPromptOptions {
|
|
|
268
268
|
submittedPrompt?: string;
|
|
269
269
|
source?: 'mcp-app';
|
|
270
270
|
optimisticUserMessage?: boolean;
|
|
271
|
+
/**
|
|
272
|
+
* Existing transcript user block the admitted prompt binds to. Needed when
|
|
273
|
+
* `optimisticUserMessage: false` reuses the block a failed attempt already
|
|
274
|
+
* appended, so admission still has a block to bind.
|
|
275
|
+
*/
|
|
276
|
+
bindBlockId?: string;
|
|
271
277
|
images?: DaemonPromptImage[];
|
|
272
278
|
files?: DaemonPromptFile[];
|
|
273
279
|
inputAnnotations?: DaemonInputAnnotation[];
|
|
@@ -293,7 +299,7 @@ export interface SendPromptOptions {
|
|
|
293
299
|
promptId: string;
|
|
294
300
|
}) => void;
|
|
295
301
|
}
|
|
296
|
-
export interface SubmitPromptOptions extends Omit<SendPromptOptions, 'beforeDispatch' | 'source'> {
|
|
302
|
+
export interface SubmitPromptOptions extends Omit<SendPromptOptions, 'beforeDispatch' | 'source' | 'bindBlockId'> {
|
|
297
303
|
sessionId?: string;
|
|
298
304
|
signal?: AbortSignal;
|
|
299
305
|
}
|
|
@@ -471,6 +477,13 @@ export interface DaemonSessionActions {
|
|
|
471
477
|
* callers that fall back on their own. */
|
|
472
478
|
silent?: boolean;
|
|
473
479
|
}): Promise<DaemonRewindResult>;
|
|
480
|
+
btwSessionStream(question: string, opts?: {
|
|
481
|
+
signal?: AbortSignal;
|
|
482
|
+
}): AsyncGenerator<{
|
|
483
|
+
type: 'answer' | 'done';
|
|
484
|
+
answer: string;
|
|
485
|
+
}>;
|
|
486
|
+
/** Legacy JSON action retained for existing daemon-react-sdk consumers. */
|
|
474
487
|
btwSession(question: string, opts?: {
|
|
475
488
|
signal?: AbortSignal;
|
|
476
489
|
}): Promise<DaemonSessionBtwResult>;
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* SPDX-License-Identifier: Apache-2.0
|
|
5
5
|
*/
|
|
6
6
|
export { DaemonWorkspaceProvider, useDaemonWorkspace, useDaemonWorkspaceActions, useOptionalDaemonWorkspace, } from './DaemonWorkspaceProvider.js';
|
|
7
|
-
export type { DaemonDirectoryEntry, DaemonDirectoryListing, DaemonFileStat, DaemonGlobOptions, DaemonGlobResult, DaemonGoal, DaemonGoalList, DaemonScheduledTask, DaemonScheduledTaskGateStatus, DaemonScheduledTaskRun, DaemonCreateScheduledTaskRequest, DaemonUpdateScheduledTaskRequest, DaemonResourceOptions, DaemonChannelPairingActions, DaemonChannelsResource, DaemonWorkspaceActions, DaemonWorkspaceContextValue, DaemonWorkspaceProviderProps, DaemonWorkspaceStatus, ResourceResult, ResourceState, } from './types.js';
|
|
7
|
+
export type { DaemonDirectoryEntry, DaemonDirectoryListing, DaemonFileStat, DaemonGlobOptions, DaemonGlobResult, DaemonGoal, DaemonGoalList, DaemonAutofixPrWatch, DaemonAutofixPrWatchList, DaemonScheduledTask, DaemonScheduledTaskGateStatus, DaemonScheduledTaskRun, DaemonCreateScheduledTaskRequest, DaemonUpdateScheduledTaskRequest, DaemonResourceOptions, DaemonChannelPairingActions, DaemonChannelsResource, DaemonWorkspaceActions, DaemonWorkspaceContextValue, DaemonWorkspaceProviderProps, DaemonWorkspaceStatus, ResourceResult, ResourceState, } from './types.js';
|
|
8
8
|
export { useDaemonAgents, useDaemonAuth, useDaemonChannels, useDaemonDiagnostics, useDaemonFiles, useDaemonGlob, useDaemonMcp, useDaemonMemory, useDaemonResource, useDaemonSessions, useDaemonSkills, useDaemonStatusReport, useDaemonUsageDashboard, useDaemonTools, useDaemonSettings, useDaemonProviders, } from './hooks/index.js';
|
|
9
9
|
export type { DaemonStatusReportOptions } from './hooks/index.js';
|
|
10
10
|
export type { DaemonUsageDashboardOptions } from './hooks/index.js';
|
|
@@ -274,6 +274,74 @@ export interface DaemonGoalList {
|
|
|
274
274
|
*/
|
|
275
275
|
droppedCount: number;
|
|
276
276
|
}
|
|
277
|
+
/**
|
|
278
|
+
* One `/autofix-pr` watch of a workspace's clone, as `qwen autofix-pr status`
|
|
279
|
+
* lists it (`GET /autofix-pr/watches`, advertised as `autofix_pr_watches`).
|
|
280
|
+
*/
|
|
281
|
+
export interface DaemonAutofixPrWatch {
|
|
282
|
+
pr: number;
|
|
283
|
+
/** `<owner>/<repo>`. */
|
|
284
|
+
repo: string;
|
|
285
|
+
host: string;
|
|
286
|
+
url: string;
|
|
287
|
+
headRefName: string;
|
|
288
|
+
/** The PR head the watch knows of. */
|
|
289
|
+
headSha: string;
|
|
290
|
+
pushes: number;
|
|
291
|
+
maxPushes: number;
|
|
292
|
+
/** The session that owns the watch: maybe no session of this daemon. */
|
|
293
|
+
session: string;
|
|
294
|
+
preparedAt: string | null;
|
|
295
|
+
/** The last run of the watch's own gate. */
|
|
296
|
+
lastCheck: string | null;
|
|
297
|
+
/** Whether `lastCheck` is within two of the watch's intervals. */
|
|
298
|
+
checkedRecently: boolean;
|
|
299
|
+
/** The last round's snapshot. */
|
|
300
|
+
lastRound: string | null;
|
|
301
|
+
/** The gate saw the PR end, and the watch was not cleaned up. */
|
|
302
|
+
stopped: 'merged' | 'closed' | null;
|
|
303
|
+
/** The task `schedule` recorded, or null for a `--once` round. */
|
|
304
|
+
watch: {
|
|
305
|
+
every: number;
|
|
306
|
+
reply: boolean;
|
|
307
|
+
instructions: string;
|
|
308
|
+
task?: string;
|
|
309
|
+
} | null;
|
|
310
|
+
/** A `cleanup` that kept the worktree ended the watch. */
|
|
311
|
+
ended: {
|
|
312
|
+
at: string;
|
|
313
|
+
reason: string;
|
|
314
|
+
} | null;
|
|
315
|
+
/** Items the watch left for a person, newest last. */
|
|
316
|
+
needsHuman: Array<{
|
|
317
|
+
sha: string;
|
|
318
|
+
at: string;
|
|
319
|
+
text: string;
|
|
320
|
+
}>;
|
|
321
|
+
worktreeExists: boolean;
|
|
322
|
+
/** A background fix's attempt: `fresh` while it has not ended. */
|
|
323
|
+
fix: {
|
|
324
|
+
attempt: string | null;
|
|
325
|
+
startedAt: string | null;
|
|
326
|
+
fresh: boolean;
|
|
327
|
+
} | null;
|
|
328
|
+
}
|
|
329
|
+
/** The `GET /autofix-pr/watches` payload. */
|
|
330
|
+
export interface DaemonAutofixPrWatchList {
|
|
331
|
+
/** False when no git repository is found for the workspace. */
|
|
332
|
+
available: boolean;
|
|
333
|
+
/** The clone's main worktree: two workspaces of one clone list the same
|
|
334
|
+
* watches. */
|
|
335
|
+
root?: string;
|
|
336
|
+
/** When the daemon read the files, for comparing `lastCheck` with. */
|
|
337
|
+
now?: string;
|
|
338
|
+
watches: DaemonAutofixPrWatch[];
|
|
339
|
+
/** State files that could not be read, with the reason. */
|
|
340
|
+
unreadable?: Array<{
|
|
341
|
+
pr: number;
|
|
342
|
+
error: string;
|
|
343
|
+
}>;
|
|
344
|
+
}
|
|
277
345
|
export interface DaemonWorkspacePathSuggestion {
|
|
278
346
|
name: string;
|
|
279
347
|
path: string;
|
|
@@ -403,6 +471,9 @@ export interface DaemonWorkspaceActions {
|
|
|
403
471
|
* caller; per-run tasks are dispatched into a fresh daemon session. */
|
|
404
472
|
runScheduledTask(id: string, workspaceId?: string): Promise<DaemonScheduledTask>;
|
|
405
473
|
deleteScheduledTask(id: string, workspaceId?: string): Promise<void>;
|
|
474
|
+
/** The `/autofix-pr` watches of a workspace's clone; `workspaceId` as for
|
|
475
|
+
* `listScheduledTasks`. Only to a daemon advertising `autofix_pr_watches`. */
|
|
476
|
+
listAutofixPrWatches(workspaceId?: string): Promise<DaemonAutofixPrWatchList>;
|
|
406
477
|
listGoals(): Promise<DaemonGoalList>;
|
|
407
478
|
controlGoal(sessionId: string, request: GoalControlRequest): Promise<GoalStateResponse>;
|
|
408
479
|
/** Drop a session's goal hook. No-op when that session has no active goal. */
|
|
@@ -221,6 +221,10 @@ DaemonGlobResult,
|
|
|
221
221
|
DaemonGoal,
|
|
222
222
|
/** The `GET /goals` payload: the goals plus a count of unreachable sessions. */
|
|
223
223
|
DaemonGoalList,
|
|
224
|
+
/** One `/autofix-pr` watch of a workspace's clone, as `status` lists it. */
|
|
225
|
+
DaemonAutofixPrWatch,
|
|
226
|
+
/** The `GET /autofix-pr/watches` payload. */
|
|
227
|
+
DaemonAutofixPrWatchList,
|
|
224
228
|
/** A durable scheduled task (cron) as returned by the daemon. */
|
|
225
229
|
DaemonScheduledTask,
|
|
226
230
|
/** Summary of a gated task's recent gate runs. */
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { type ReactNode } from 'react';
|
|
2
|
+
import { type McpAppDisplay } from '../components/messages/McpApp';
|
|
3
|
+
import { GeneratedUiInstanceStore } from './instance-store';
|
|
4
|
+
export declare function GeneratedUiRuntimeProvider({ children, }: {
|
|
5
|
+
children: ReactNode;
|
|
6
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export declare function useGeneratedUiRetention(): GeneratedUiInstanceStore | undefined;
|
|
8
|
+
export declare function GeneratedUiSlot({ display, toolId, visible, }: {
|
|
9
|
+
display: McpAppDisplay;
|
|
10
|
+
toolId: string;
|
|
11
|
+
visible: boolean;
|
|
12
|
+
}): import("react/jsx-runtime").JSX.Element;
|