@qwen-code/web-shell 0.28.4 → 0.28.7
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/NOTICES.txt +1 -1
- package/README.md +11 -1
- package/dist/{PierreFilePreview-Cn-K0sjp.js → PierreFilePreview-mjl-NyoO.js} +1 -1
- package/dist/{SpreadsheetPreview-9HeqwVPY.js → SpreadsheetPreview-CLwpWAHt.js} +2 -2
- package/dist/{WorkspaceFileBrowser-DKicahqO.js → WorkspaceFileBrowser-BUHjDcz5.js} +2 -2
- package/dist/{WorkspacePdfRangePreview-2_xkjgkQ.js → WorkspacePdfRangePreview-T1wFDszO.js} +2 -2
- package/dist/{agents-route-CgXJn9nH.js → agents-route-Cko0LJBS.js} +2 -2
- package/dist/daemon-react-sdk.js +1 -1
- package/dist/{i18n-ru-_WgXRbpi.js → i18n-ru-zX2HBIQv.js} +18 -10
- package/dist/{i18n-zh-cn-nzJpapgU.js → i18n-zh-cn-CqjpUMZJ.js} +18 -10
- package/dist/{i18n-zh-tw-DRUCD7h2.js → i18n-zh-tw-DyTerQIj.js} +29 -10
- package/dist/{index-Mt-5HQ-Q.js → index-BO8CdGLJ.js} +67694 -65705
- package/dist/index.js +3 -3
- package/dist/sw.js +1 -1
- package/dist/{terminal-runtime-BQaN1NCS.js → terminal-runtime-ubK12HhZ.js} +997 -997
- package/dist/transcript.js +10619 -10534
- package/dist/types/App.d.ts +8 -2
- package/dist/types/ManagedAgentWebShell.d.ts +2 -0
- package/dist/types/WebShellContexts.d.ts +8 -0
- package/dist/types/adapters/transcriptToMessages.d.ts +0 -20
- package/dist/types/chat-core/ChatSurface.d.ts +5 -1
- package/dist/types/chat-core/contract.d.ts +7 -0
- package/dist/types/components/BranchPickerPopover.d.ts +15 -1
- package/dist/types/components/ComposerTaskChips.d.ts +7 -4
- package/dist/types/components/GitBranchIndicator.d.ts +4 -2
- package/dist/types/components/GitModePopover.d.ts +10 -1
- package/dist/types/components/MessageItem.d.ts +1 -0
- package/dist/types/components/MessageList.d.ts +1 -0
- package/dist/types/components/SessionOverviewPanel.d.ts +3 -2
- package/dist/types/components/TranscriptViewport.d.ts +6 -0
- package/dist/types/components/WorkspaceSelector.d.ts +5 -1
- package/dist/types/components/artifacts/artifactUtils.d.ts +3 -1
- package/dist/types/components/channels/ChannelsManagerPage.d.ts +3 -1
- package/dist/types/components/dialogs/WorkspaceHooksDialog.d.ts +9 -0
- package/dist/types/components/extensions/ExtensionsManagerPage.d.ts +3 -1
- package/dist/types/components/managed/chat-capabilities.d.ts +3 -1
- package/dist/types/components/managed/chat-controller.d.ts +65 -0
- package/dist/types/components/managed/generated/managed-agent-api.d.ts +1 -1
- package/dist/types/components/managed/managed-agent-provider.d.ts +13 -1
- package/dist/types/components/managed/managed-question-response.d.ts +7 -0
- package/dist/types/components/managed/use-managed-actions.d.ts +1 -1
- package/dist/types/components/managed/use-managed-chat-controller.d.ts +9 -0
- package/dist/types/components/managed/use-managed-turn-cancel.d.ts +5 -2
- package/dist/types/components/messages/AskUserQuestion.d.ts +15 -2
- package/dist/types/components/messages/MemoryMessage.d.ts +2 -1
- package/dist/types/components/messages/SettingsMessage.d.ts +13 -5
- package/dist/types/components/messages/UserMessage.d.ts +1 -0
- package/dist/types/components/plugins/PluginManagerPage.d.ts +3 -1
- package/dist/types/components/sidebar/WebShellSidebar.d.ts +2 -4
- package/dist/types/components/sidebar/WorkspaceDetailsTooltip.d.ts +12 -1
- package/dist/types/components/sidebar/WorkspaceMenu.d.ts +9 -2
- package/dist/types/components/sidebar/WorkspaceSection.d.ts +5 -1
- package/dist/types/components/sidebar/sidebar-hover-suppression.d.ts +1 -0
- package/dist/types/components/sidebar/workspaceOverviewModel.d.ts +4 -2
- package/dist/types/components/workspaces/WorkspaceDirectoriesSection.d.ts +3 -1
- package/dist/types/components/workspaces/use-workspace-trust-grant.d.ts +18 -0
- package/dist/types/daemon/chat-controller.d.ts +5 -0
- package/dist/types/daemon/remotePromptSidechannel.d.ts +13 -0
- package/dist/types/daemon/session/DaemonSessionProvider.d.ts +1 -0
- package/dist/types/daemon/session/actions.d.ts +5 -2
- package/dist/types/daemon/session/index.d.ts +1 -1
- package/dist/types/daemon/session/types.d.ts +20 -1
- package/dist/types/daemon/workspace/hooks/useDaemonMemory.d.ts +5 -1
- package/dist/types/daemon/workspace/hooks/useDaemonSessions.d.ts +1 -0
- package/dist/types/daemon/workspace/hooks/useDaemonSettings.d.ts +5 -1
- package/dist/types/daemon/workspace/types.d.ts +23 -0
- package/dist/types/generated-ui/effects.d.ts +27 -0
- package/dist/types/hooks/composer-draft-session.d.ts +7 -3
- package/dist/types/hooks/useComposerCore.d.ts +14 -1
- package/dist/types/hooks/useInputHistory.d.ts +11 -1
- package/dist/types/hooks/useScopedSessions.d.ts +1 -0
- package/dist/types/session-catalog/session-catalog-hooks.d.ts +1 -0
- package/dist/types/settings.d.ts +3 -1
- package/dist/types/utils/promptAdmission.d.ts +2 -1
- package/dist/types/utils/rectangles.d.ts +8 -0
- package/dist/types/utils/sessionPreparation.d.ts +2 -1
- package/dist/{useDaemonMidTurnInjected-C7uv5N2a.js → useDaemonMidTurnInjected-K7Sl7y1O.js} +8282 -8004
- package/package.json +1 -1
- package/dist/types/components/managed/ManagedQuestionForm.d.ts +0 -13
package/dist/types/App.d.ts
CHANGED
|
@@ -237,6 +237,8 @@ export interface WebShellProps {
|
|
|
237
237
|
composerVariant?: 'default' | 'simple';
|
|
238
238
|
/** Show the composer focus glow and typing animation. Defaults to true. */
|
|
239
239
|
composerGlowEnabled?: boolean;
|
|
240
|
+
/** Turn off Up/Down prompt recall for this shell, regardless of the browser preference. */
|
|
241
|
+
disableArrowKeyHistory?: boolean;
|
|
240
242
|
/** Optionally filter main-model entries without changing shared defaults. */
|
|
241
243
|
mainModelFilter?: (model: ModelDialogModel) => boolean;
|
|
242
244
|
/** Stack completion details vertically for narrow embedded hosts. */
|
|
@@ -367,7 +369,11 @@ export interface WebShellProps {
|
|
|
367
369
|
* mobile CSS reordering to take effect.
|
|
368
370
|
*/
|
|
369
371
|
mobileWelcomeFooterMiddle?: boolean;
|
|
370
|
-
/**
|
|
372
|
+
/**
|
|
373
|
+
* Parse user-message text into display parts such as chips. Desktop composer
|
|
374
|
+
* drafts also use this parser to restore inline chips when its parts preserve
|
|
375
|
+
* the complete original text.
|
|
376
|
+
*/
|
|
371
377
|
parseUserMessageContent?: UserMessageContentParser;
|
|
372
378
|
/** Custom renderer for the inside of user chat bubbles. Defaults to plain text. */
|
|
373
379
|
renderUserMessageContent?: UserMessageContentRenderer;
|
|
@@ -487,4 +493,4 @@ export declare function canArchiveSideTaskSummary(session: Pick<DaemonSessionSum
|
|
|
487
493
|
export declare function mergeSideTaskCatalog(catalog: SideTaskCatalogState, parentSessionId: string, listedItems: SideTaskListItem[], optimisticIds: ReadonlySet<string>): SideTaskCatalogState;
|
|
488
494
|
export declare function getEnvironmentAgentTasks(messages: readonly Message[], sessionTasks: readonly DaemonSessionTaskWithWorkflowStatus[]): EnvironmentAgentTask[];
|
|
489
495
|
export declare function mergeAgentTrace(liveAgents: readonly EnvironmentAgentTask[], trace: DaemonAgentTrace | undefined, now?: number): EnvironmentAgentTask[];
|
|
490
|
-
export declare function App({ onRefreshModels, askUserFreeTextLabel, onSessionIdChange, onSessionInfoChange, onModelChange, 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, alignManagedChatWithHost, showManagedSessionHeader, 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, modelPicker, unavailableModels, mountUnavailableModelTooltip, header, rightPanel, showToolCalls, environmentPanel, splitSessionIds: externalSplitSessionIds, onSplitSessionIdsChange, renderPaneHeaderActions, onRightPanelOpen, onFileReviewOpen, onWorkspaceFileOpen, onPickWorkspaceDirectory, onInsightReportOpen, onContextUsageOpen, messageTurnOutputs, filterArtifact, shellRef, composerToolbarActions, hostOwnsAddMenu, allowedApprovalModes: allowedApprovalModesProp, composerVariant, composerGlowEnabled, mainModelFilter, compactComposerOverlays, autoSubmitSlashCommands, additionalSlashCommands, contextUsageAlwaysVisible, userMessageEditing, onUserMessageEditRequest, cycleModeOnTab, sessionSourceType, subscriptionDraft, composerToolbarAdditionalActions, composerPlaceholders, compactThinking, hostOwnsEditDiffPreview, collapseCompletedTurns, markdownTableMode, virtualScrollThreshold, overscan, 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;
|
|
496
|
+
export declare function App({ onRefreshModels, askUserFreeTextLabel, onSessionIdChange, onSessionInfoChange, onModelChange, 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, alignManagedChatWithHost, showManagedSessionHeader, 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, modelPicker, unavailableModels, mountUnavailableModelTooltip, header, rightPanel, showToolCalls, environmentPanel, splitSessionIds: externalSplitSessionIds, onSplitSessionIdsChange, renderPaneHeaderActions, onRightPanelOpen, onFileReviewOpen, onWorkspaceFileOpen, onPickWorkspaceDirectory, onInsightReportOpen, onContextUsageOpen, messageTurnOutputs, filterArtifact, shellRef, composerToolbarActions, hostOwnsAddMenu, allowedApprovalModes: allowedApprovalModesProp, composerVariant, composerGlowEnabled, disableArrowKeyHistory, mainModelFilter, compactComposerOverlays, autoSubmitSlashCommands, additionalSlashCommands, contextUsageAlwaysVisible, userMessageEditing, onUserMessageEditRequest, cycleModeOnTab, sessionSourceType, subscriptionDraft, composerToolbarAdditionalActions, composerPlaceholders, compactThinking, hostOwnsEditDiffPreview, collapseCompletedTurns, markdownTableMode, virtualScrollThreshold, overscan, 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;
|
|
@@ -22,6 +22,8 @@ export interface ManagedAgentWebShellProps extends Omit<JavaManagedAgentProvider
|
|
|
22
22
|
baseUrl?: string;
|
|
23
23
|
/** Only open the existing Session explicitly selected by the host. */
|
|
24
24
|
hostSessionOnly?: boolean;
|
|
25
|
+
/** Turn off Up/Down prompt recall for this shell, regardless of the browser preference. */
|
|
26
|
+
disableArrowKeyHistory?: boolean;
|
|
25
27
|
sessionId?: string;
|
|
26
28
|
onSessionChange?: (sessionId: string | undefined) => void;
|
|
27
29
|
language?: WebShellLanguage;
|
|
@@ -6,6 +6,14 @@
|
|
|
6
6
|
import { type ReactNode } from 'react';
|
|
7
7
|
import type { TodoDetail, TodoSnapshotDiff } from './utils/todos';
|
|
8
8
|
export declare const CompactModeContext: import("react").Context<boolean>;
|
|
9
|
+
export declare const ArrowKeyHistoryContext: import("react").Context<{
|
|
10
|
+
enabled: boolean;
|
|
11
|
+
setEnabled?: (enabled: boolean) => void;
|
|
12
|
+
} | null>;
|
|
13
|
+
export declare function ArrowKeyHistoryProvider({ children, disabledByHost, }: {
|
|
14
|
+
children: ReactNode;
|
|
15
|
+
disabledByHost?: boolean;
|
|
16
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
9
17
|
/**
|
|
10
18
|
* Per-snapshot status diffs (keyed by tool callId or plan message id), so a
|
|
11
19
|
* history row can render what changed in that snapshot without re-deriving it
|
|
@@ -28,26 +28,6 @@ export declare function isRetryableTurnErrorKind(errorKind: string | undefined):
|
|
|
28
28
|
export declare function assistantBlockRendersAsSystemNotice(block: DaemonTranscriptBlock): boolean;
|
|
29
29
|
export declare function transcriptBlocksToDaemonMessages(blocks: readonly DaemonTranscriptBlock[], options?: TranscriptMessageOptions): DaemonMessage[];
|
|
30
30
|
export declare function daemonToolBlockToToolCall(block: DaemonToolTranscriptBlock, safeToolProjection: boolean): DaemonMessageToolCall;
|
|
31
|
-
type ParsedInsight = {
|
|
32
|
-
type: 'insight_progress';
|
|
33
|
-
stage: string;
|
|
34
|
-
progress: number;
|
|
35
|
-
detail?: string;
|
|
36
|
-
} | {
|
|
37
|
-
type: 'insight_ready';
|
|
38
|
-
path: string;
|
|
39
|
-
} | {
|
|
40
|
-
type: 'insight_error';
|
|
41
|
-
error: string;
|
|
42
|
-
};
|
|
43
|
-
type InsightSegment = {
|
|
44
|
-
kind: 'text';
|
|
45
|
-
text: string;
|
|
46
|
-
} | {
|
|
47
|
-
kind: 'insight';
|
|
48
|
-
data: ParsedInsight;
|
|
49
|
-
};
|
|
50
|
-
export declare function splitInsightSegments(text: string): InsightSegment[] | null;
|
|
51
31
|
/**
|
|
52
32
|
* The visible assistant text of a block's text, with insight protocol frames
|
|
53
33
|
* (`insight_progress` / `insight_ready` / `insight_error`) stripped exactly as
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
import { type ReactNode } from 'react';
|
|
7
7
|
import type { CommandInfo, TodoItem } from '../adapters/types.js';
|
|
8
8
|
import type { SessionContentGenerator } from '../components/messages/AssistantMessage.js';
|
|
9
|
+
import { type ComposerToolbarAction } from '../components/ChatEditor.js';
|
|
9
10
|
import type { SessionChatController } from './contract.js';
|
|
10
11
|
export interface ChatSurfaceProps {
|
|
11
12
|
readonly controller: SessionChatController;
|
|
@@ -33,6 +34,9 @@ export interface ChatSurfaceProps {
|
|
|
33
34
|
readonly atWorkspaceCwd?: string;
|
|
34
35
|
readonly composerScopeKey?: string;
|
|
35
36
|
readonly composerSubmitBlocked?: boolean;
|
|
37
|
+
readonly sessionViewportEnabled?: boolean;
|
|
38
|
+
readonly workspaceFeaturesEnabled?: boolean;
|
|
39
|
+
readonly visibleToolbarActions?: readonly ComposerToolbarAction[];
|
|
36
40
|
}
|
|
37
41
|
/**
|
|
38
42
|
* The backend-neutral chat column (unified chat surface, slice 2). It renders
|
|
@@ -42,4 +46,4 @@ export interface ChatSurfaceProps {
|
|
|
42
46
|
* establishment — the composer defers its draft commit to admission, while turn
|
|
43
47
|
* and decision outcomes are reflected through the controller's observable state.
|
|
44
48
|
*/
|
|
45
|
-
export declare function ChatSurface({ controller, header, panels, composerStatus, transcriptError, commands, onError, hasOlderHistory, onLoadOlderHistory, historyPaginationError, loadingOlderHistory, historyCapacityReached, planTodos, planExecutionMode, approvalDisabled, approvalKeyboardActive, showBrowserNotifications, generateContent, askUserFreeTextLabel, askUserDetails, atWorkspaceCwd, composerScopeKey, composerSubmitBlocked, }: ChatSurfaceProps): import("react/jsx-runtime").JSX.Element;
|
|
49
|
+
export declare function ChatSurface({ controller, header, panels, composerStatus, transcriptError, commands, onError, hasOlderHistory, onLoadOlderHistory, historyPaginationError, loadingOlderHistory, historyCapacityReached, planTodos, planExecutionMode, approvalDisabled, approvalKeyboardActive, showBrowserNotifications, generateContent, askUserFreeTextLabel, askUserDetails, atWorkspaceCwd, composerScopeKey, composerSubmitBlocked, sessionViewportEnabled, workspaceFeaturesEnabled, visibleToolbarActions, }: ChatSurfaceProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -35,6 +35,8 @@ export interface PendingQuestion {
|
|
|
35
35
|
export interface QuestionAnswer {
|
|
36
36
|
readonly questionId: string;
|
|
37
37
|
readonly value: string;
|
|
38
|
+
readonly optionIds?: readonly string[];
|
|
39
|
+
readonly text?: string;
|
|
38
40
|
}
|
|
39
41
|
export interface ComposerSubmit {
|
|
40
42
|
readonly text: string;
|
|
@@ -88,9 +90,14 @@ export interface SessionChatController {
|
|
|
88
90
|
readonly kind: 'daemon' | 'managed';
|
|
89
91
|
readonly sessionId: string;
|
|
90
92
|
readonly storageKey: string;
|
|
93
|
+
readonly activeTurnId?: string;
|
|
91
94
|
readonly operations: readonly ChatOperation[];
|
|
92
95
|
readonly messages: readonly Message[];
|
|
93
96
|
readonly transcriptState: 'loading' | 'ready' | 'error';
|
|
97
|
+
readonly hasOlderHistory?: boolean;
|
|
98
|
+
readonly loadingOlderHistory?: boolean;
|
|
99
|
+
readonly historyCapacityReached?: boolean;
|
|
100
|
+
readonly historyPaginationError?: boolean;
|
|
94
101
|
loadOlder?(options?: {
|
|
95
102
|
force?: boolean;
|
|
96
103
|
}): Promise<void>;
|
|
@@ -6,6 +6,19 @@
|
|
|
6
6
|
import type { DaemonGitBranchesResult, DaemonWorkspaceGitStatus } from '@qwen-code/sdk/daemon';
|
|
7
7
|
import { useI18n } from '../i18n';
|
|
8
8
|
export declare const GIT_REMOTE_MUTATION_FETCH_TIMEOUT_MS = 600000;
|
|
9
|
+
export interface BranchPickerPreservedState {
|
|
10
|
+
scopeKey: string;
|
|
11
|
+
search: string;
|
|
12
|
+
newBranchMode: boolean;
|
|
13
|
+
newBranchName: string;
|
|
14
|
+
checkoutRefMode: boolean;
|
|
15
|
+
checkoutRefValue: string;
|
|
16
|
+
createBranchMode: boolean;
|
|
17
|
+
createBranchValue: string;
|
|
18
|
+
view: 'branches' | 'remotes';
|
|
19
|
+
remoteName: string;
|
|
20
|
+
remoteUrl: string;
|
|
21
|
+
}
|
|
9
22
|
interface BranchPickerPopoverProps {
|
|
10
23
|
open: boolean;
|
|
11
24
|
onOpenChange: (open: boolean) => void;
|
|
@@ -14,6 +27,7 @@ interface BranchPickerPopoverProps {
|
|
|
14
27
|
gitSessionId?: string;
|
|
15
28
|
side?: 'top' | 'right' | 'bottom' | 'left';
|
|
16
29
|
onBranchChanged?: () => void;
|
|
30
|
+
preservedStateRef?: React.MutableRefObject<BranchPickerPreservedState | null>;
|
|
17
31
|
/**
|
|
18
32
|
* Working-tree summary from the trigger chip. Seeds the hints beside the
|
|
19
33
|
* Update / Commit / Push actions (dirty counts, in-progress operation) until
|
|
@@ -84,5 +98,5 @@ export declare function deriveActionHints(t: TranslateFn, data: DaemonGitBranche
|
|
|
84
98
|
* re-fetched. Exported for tests.
|
|
85
99
|
*/
|
|
86
100
|
export declare function listingContradictsStatus(data: DaemonGitBranchesResult, status: DaemonWorkspaceGitStatus): boolean;
|
|
87
|
-
export declare function BranchPickerPopover({ open, onOpenChange, workspaceCwd, gitCwd, gitSessionId, side, onBranchChanged, status, onStatusRefreshed, onOpenDiff, onOpenCommit, onOpenWorktrees, onOpenLog, onCreateWorktreeBranch, onHandoff, children, }: BranchPickerPopoverProps): import("react/jsx-runtime").JSX.Element;
|
|
101
|
+
export declare function BranchPickerPopover({ open, onOpenChange, workspaceCwd, gitCwd, gitSessionId, side, onBranchChanged, status, onStatusRefreshed, onOpenDiff, onOpenCommit, onOpenWorktrees, onOpenLog, onCreateWorktreeBranch, onHandoff, preservedStateRef, children, }: BranchPickerPopoverProps): import("react/jsx-runtime").JSX.Element;
|
|
88
102
|
export {};
|
|
@@ -8,8 +8,10 @@ export interface ComposerTaskChipsProps {
|
|
|
8
8
|
tasks: readonly ComposerChipTask[];
|
|
9
9
|
/** Whether background agents get a chip (hosts without agent surfaces opt out). */
|
|
10
10
|
includeAgents: boolean;
|
|
11
|
-
/**
|
|
12
|
-
onSelectTask: (task: ComposerChipTask) => void;
|
|
11
|
+
/** Select a task; direct single-chip activation also allows collapsing it. */
|
|
12
|
+
onSelectTask: (task: ComposerChipTask, toggle?: boolean) => void;
|
|
13
|
+
/** Whether a single-task chip's target panel or dialog is currently open. */
|
|
14
|
+
isTaskOpen?: (task: ComposerChipTask) => boolean;
|
|
13
15
|
/** Ask the model to explain the task as a side question, without opening it. */
|
|
14
16
|
onExplainTask?: (task: DaemonSessionTaskWithWorkflowStatus) => void;
|
|
15
17
|
/** Hand focus back to the composer, optionally with a typed character. */
|
|
@@ -18,7 +20,8 @@ export interface ComposerTaskChipsProps {
|
|
|
18
20
|
/**
|
|
19
21
|
* Chips above the composer for this session's unfinished background work —
|
|
20
22
|
* one per kind ("1 workflow", "2 shells"). A chip that stands for a single
|
|
21
|
-
* task
|
|
22
|
-
* row to pick from
|
|
23
|
+
* task toggles its detail; one that stands for several opens a list above the
|
|
24
|
+
* row to pick from and collapses that list on repeat activation. Finished
|
|
25
|
+
* tasks have no chip, so the row clears itself.
|
|
23
26
|
*/
|
|
24
27
|
export declare const ComposerTaskChips: import("react").ForwardRefExoticComponent<ComposerTaskChipsProps & import("react").RefAttributes<ComposerTaskChipsHandle>>;
|
|
@@ -50,16 +50,18 @@ export declare function gitBranchAriaLabel(branch: string, status: DaemonWorkspa
|
|
|
50
50
|
* replica. The replica must render the same indicators or it under-measures the
|
|
51
51
|
* expanded chip, which makes the responsive compact/expanded toggle oscillate.
|
|
52
52
|
*/
|
|
53
|
-
export declare function GitBranchChipContent({ branch, status, compact, worktree, }: {
|
|
53
|
+
export declare function GitBranchChipContent({ branch, status, compact, showDetails, worktree, }: {
|
|
54
54
|
branch: string;
|
|
55
55
|
status?: DaemonWorkspaceGitStatus;
|
|
56
56
|
compact: boolean;
|
|
57
|
+
showDetails?: boolean;
|
|
57
58
|
worktree?: boolean;
|
|
58
59
|
}): import("react/jsx-runtime").JSX.Element;
|
|
59
|
-
export declare function GitBranchIndicator({ branch, status, compact, onOpenDiff, worktree, }: {
|
|
60
|
+
export declare function GitBranchIndicator({ branch, status, compact, showDetails, onOpenDiff, worktree, }: {
|
|
60
61
|
branch: string;
|
|
61
62
|
status?: DaemonWorkspaceGitStatus;
|
|
62
63
|
compact?: boolean;
|
|
64
|
+
showDetails?: boolean;
|
|
63
65
|
onOpenDiff?: () => void;
|
|
64
66
|
worktree?: boolean;
|
|
65
67
|
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -14,12 +14,21 @@ export type SessionGitIntent = {
|
|
|
14
14
|
slug?: string;
|
|
15
15
|
};
|
|
16
16
|
export declare function validateBranchName(name: string): boolean;
|
|
17
|
+
export interface GitModePopoverDraft {
|
|
18
|
+
selectedMode: SessionGitIntent['mode'];
|
|
19
|
+
branchName: string;
|
|
20
|
+
}
|
|
17
21
|
interface GitModePopoverProps {
|
|
18
22
|
branch: string;
|
|
19
23
|
status?: DaemonWorkspaceGitStatus;
|
|
20
24
|
compact?: boolean;
|
|
25
|
+
showDetails?: boolean;
|
|
21
26
|
intent: SessionGitIntent;
|
|
22
27
|
onIntentChange: (intent: SessionGitIntent) => void;
|
|
28
|
+
open?: boolean;
|
|
29
|
+
onOpenChange?: (open: boolean) => void;
|
|
30
|
+
draft?: GitModePopoverDraft;
|
|
31
|
+
onDraftChange?: (update: (current: GitModePopoverDraft) => GitModePopoverDraft) => void;
|
|
23
32
|
}
|
|
24
|
-
export declare function GitModePopover({ branch, status, compact, intent, onIntentChange, }: GitModePopoverProps): import("react/jsx-runtime").JSX.Element;
|
|
33
|
+
export declare function GitModePopover({ branch, status, compact, showDetails, intent, onIntentChange, open: openProp, onOpenChange, draft, onDraftChange, }: GitModePopoverProps): import("react/jsx-runtime").JSX.Element;
|
|
25
34
|
export {};
|
|
@@ -24,6 +24,7 @@ interface MessageItemProps {
|
|
|
24
24
|
showRetryHint?: boolean;
|
|
25
25
|
onRetryClick?: () => void;
|
|
26
26
|
sendFailed?: boolean;
|
|
27
|
+
sendFailedStatus?: 'failed' | 'uncertain';
|
|
27
28
|
onRetrySend?: () => void;
|
|
28
29
|
/**
|
|
29
30
|
* Open the in-place editor for this user message. Return `true` when a host
|
|
@@ -95,6 +95,7 @@ export interface MessageListProps {
|
|
|
95
95
|
showRetryHint?: boolean;
|
|
96
96
|
onRetryClick?: () => void;
|
|
97
97
|
failedPromptMessageId?: string;
|
|
98
|
+
failedPromptStatus?: 'failed' | 'uncertain';
|
|
98
99
|
onRetryFailedPrompt?: () => void;
|
|
99
100
|
onBranchSession?: (branchRecordId?: string) => void | Promise<void>;
|
|
100
101
|
onCanScrollToBottomChange?: (canScrollToBottom: boolean) => void;
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* SPDX-License-Identifier: Apache-2.0
|
|
5
5
|
*/
|
|
6
6
|
import { type DaemonProductSessionContext } from '@qwen-code/web-shell/daemon-react-sdk';
|
|
7
|
-
import { type DaemonSessionGroupPresetColor, type DaemonSessionPrInfo, type DaemonSessionSummary, type DaemonStatusReportSession } from '@qwen-code/sdk/daemon';
|
|
7
|
+
import { type DaemonSessionGroupPresetColor, type DaemonSessionPrInfo, type DaemonSessionSummary, type DaemonStatusReportSession, type DaemonSessionClient } from '@qwen-code/sdk/daemon';
|
|
8
8
|
export type SessionCardStatus = 'needsApproval' | 'askUserQuestion' | 'running' | 'idle';
|
|
9
9
|
export interface SessionCard {
|
|
10
10
|
sessionId: string;
|
|
@@ -20,6 +20,7 @@ export interface SessionCard {
|
|
|
20
20
|
workspaceCwd: string;
|
|
21
21
|
/** Catalog the session came from; 'standalone' has no workspace of its own. */
|
|
22
22
|
sourceType?: string;
|
|
23
|
+
worktree?: DaemonSessionSummary['worktree'];
|
|
23
24
|
}
|
|
24
25
|
type SessionIdentity = Pick<SessionCard, 'sessionId' | 'workspaceCwd'>;
|
|
25
26
|
/**
|
|
@@ -39,7 +40,7 @@ export declare function deriveSessionCards(sessions: DaemonSessionSummary[], cur
|
|
|
39
40
|
* render throw to the panel, mirroring DaemonStatusDialog.
|
|
40
41
|
*/
|
|
41
42
|
export declare function SessionOverviewPanel({ onOpenSession, onOpenSplit, onCurrentSessionRemoved, includeOtherWorkspaces, workspaceCwd, manageLiveState, onLiveStateWorkspaceCwdsChange, }: {
|
|
42
|
-
onOpenSession: (sessionId: string, workspaceCwd?: string, sessionContext?: DaemonProductSessionContext) => void;
|
|
43
|
+
onOpenSession: (sessionId: string, workspaceCwd?: string, sessionContext?: DaemonProductSessionContext, restoredSession?: DaemonSessionClient) => void;
|
|
43
44
|
onOpenSplit?: (sessionIds: string[]) => void;
|
|
44
45
|
onCurrentSessionRemoved?: (session: SessionIdentity) => Promise<boolean | void> | boolean | void;
|
|
45
46
|
includeOtherWorkspaces?: boolean;
|
|
@@ -16,5 +16,11 @@ export declare function followRangeFromRows(rows: readonly {
|
|
|
16
16
|
}[], viewportTop: number, viewportBottom: number): TurnFollowRange | undefined;
|
|
17
17
|
export interface TranscriptViewportProps extends MessageListProps {
|
|
18
18
|
approvalOverlayActive?: boolean;
|
|
19
|
+
/**
|
|
20
|
+
* Enables session-context historical turn navigation and message deletion.
|
|
21
|
+
* Defaults to `true` for daemon callers; pass `false` for flat live hosts
|
|
22
|
+
* (including non-daemon surfaces co-mounted inside a daemon provider tree).
|
|
23
|
+
*/
|
|
24
|
+
sessionViewportEnabled?: boolean;
|
|
19
25
|
}
|
|
20
26
|
export declare const TranscriptViewport: import("react").ForwardRefExoticComponent<TranscriptViewportProps & import("react").RefAttributes<MessageListHandle>>;
|
|
@@ -33,10 +33,14 @@ interface WorkspaceSelectorProps {
|
|
|
33
33
|
onOpenExistingFolder: () => void;
|
|
34
34
|
/** Touch activation can otherwise release over a newly opened option. */
|
|
35
35
|
contentSide?: 'top' | 'bottom';
|
|
36
|
+
open?: boolean;
|
|
37
|
+
onOpenChange?: (open: boolean) => void;
|
|
38
|
+
newWorkspaceOpen?: boolean;
|
|
39
|
+
onNewWorkspaceOpenChange?: (open: boolean) => void;
|
|
36
40
|
}
|
|
37
41
|
/**
|
|
38
42
|
* Composer workspace menu. Capability-gated creation actions and disabled
|
|
39
43
|
* untrusted entries keep presentation aligned with daemon authorization.
|
|
40
44
|
*/
|
|
41
|
-
export declare function WorkspaceSelector({ workspaces, selectedWorkspaceCwd, disabled, busy, alwaysVisible, menuItems, scratchSupported, existingFolderSupported, standaloneSupported, selectedStandalone, className, onSelectWorkspace, onSelectHostedWorkspace, onSelectStandalone, onCreateScratch, onOpenExistingFolder, contentSide, }: WorkspaceSelectorProps): import("react/jsx-runtime").JSX.Element | null;
|
|
45
|
+
export declare function WorkspaceSelector({ workspaces, selectedWorkspaceCwd, disabled, busy, alwaysVisible, menuItems, scratchSupported, existingFolderSupported, standaloneSupported, selectedStandalone, className, onSelectWorkspace, onSelectHostedWorkspace, onSelectStandalone, onCreateScratch, onOpenExistingFolder, contentSide, open: openProp, onOpenChange, newWorkspaceOpen: newWorkspaceOpenProp, onNewWorkspaceOpenChange, }: WorkspaceSelectorProps): import("react/jsx-runtime").JSX.Element | null;
|
|
42
46
|
export {};
|
|
@@ -124,6 +124,7 @@ export interface ArtifactLibrarySessionJumpDeps {
|
|
|
124
124
|
}>;
|
|
125
125
|
getPendingJumpArtifactOpen: () => PendingArtifactJumpOpenRequest | undefined;
|
|
126
126
|
setPendingJumpArtifactOpen: (request: PendingArtifactJumpOpenRequest | undefined) => void;
|
|
127
|
+
isCurrent: () => boolean;
|
|
127
128
|
loadSidebarSession: (sessionId: string, workspaceCwd?: string) => Promise<void>;
|
|
128
129
|
reportError: (error: unknown, fallbackMessage: string) => void;
|
|
129
130
|
}
|
|
@@ -133,7 +134,8 @@ export interface ArtifactLibrarySessionJumpDeps {
|
|
|
133
134
|
* pending artifact open is armed only AFTER unarchive resolves and immediately
|
|
134
135
|
* before `loadSidebarSession`, so `resolvePendingArtifactJumpOpen` does not
|
|
135
136
|
* cancel the request while the shell is still parked on the old session during
|
|
136
|
-
* the awaited unarchive RPC.
|
|
137
|
+
* the awaited unarchive RPC. `isCurrent()` is checked after the awaited
|
|
138
|
+
* unarchive so a navigation started meanwhile is never overridden.
|
|
137
139
|
*/
|
|
138
140
|
export declare function runArtifactLibrarySessionJump(deps: ArtifactLibrarySessionJumpDeps): Promise<void>;
|
|
139
141
|
export {};
|
|
@@ -16,6 +16,8 @@ interface ChannelsManagerPageProps {
|
|
|
16
16
|
* different workspace is a hard `400 invalid_client_id`.
|
|
17
17
|
*/
|
|
18
18
|
sessionWorkspaceCwd?: string;
|
|
19
|
+
initialWorkspaceCwd?: string;
|
|
20
|
+
navigationRequest?: number;
|
|
19
21
|
}
|
|
20
|
-
export declare function ChannelsManagerPage({ onClose, initialFocusRef, clientId, sessionWorkspaceCwd, }: ChannelsManagerPageProps): import("react/jsx-runtime").JSX.Element;
|
|
22
|
+
export declare function ChannelsManagerPage({ onClose, initialFocusRef, clientId, sessionWorkspaceCwd, initialWorkspaceCwd, navigationRequest, }: ChannelsManagerPageProps): import("react/jsx-runtime").JSX.Element;
|
|
21
23
|
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Qwen Team
|
|
4
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
+
*/
|
|
6
|
+
export interface WorkspaceHooksDialogProps {
|
|
7
|
+
workspaceCwd: string;
|
|
8
|
+
}
|
|
9
|
+
export declare function WorkspaceHooksDialog({ workspaceCwd, }: WorkspaceHooksDialogProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { ManagedAgentProvider } from '../managed/managed-agent-provider';
|
|
2
|
-
import { type Ref } from 'react';
|
|
2
|
+
import { type ReactNode, type Ref } from 'react';
|
|
3
3
|
import type { EmbeddedManagerPage } from '../plugins/manager-page';
|
|
4
4
|
interface ExtensionsManagerPageProps {
|
|
5
5
|
managed?: {
|
|
@@ -10,6 +10,8 @@ interface ExtensionsManagerPageProps {
|
|
|
10
10
|
onClose: () => void;
|
|
11
11
|
initialFocusRef?: Ref<HTMLHeadingElement>;
|
|
12
12
|
embedded?: EmbeddedManagerPage;
|
|
13
|
+
workspaceCwd?: string;
|
|
14
|
+
workspaceControl?: ReactNode;
|
|
13
15
|
}
|
|
14
16
|
export declare function ExtensionsManagerPage(props: ExtensionsManagerPageProps): import("react/jsx-runtime").JSX.Element;
|
|
15
17
|
export {};
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import type { ManagedAgentSessionSummary } from './managed-agent-provider.js';
|
|
2
|
-
import type {
|
|
2
|
+
import type { ChatCapabilities } from '../../chat-core/contract.js';
|
|
3
|
+
import { type ChatRegion } from '../../chat-core/capabilities.js';
|
|
3
4
|
export type ManagedCapabilityKey = keyof ManagedAgentSessionSummary['capabilities'];
|
|
4
5
|
export declare const MANAGED_CHAT_CAPABILITY_MAP: Record<ManagedCapabilityKey, readonly ChatRegion[]>;
|
|
5
6
|
export declare function isManagedCapabilityOn(value: boolean | null | undefined): boolean;
|
|
7
|
+
export declare function managedCapabilitiesFromSummary(capabilities: Partial<ManagedAgentSessionSummary['capabilities']> | undefined): ChatCapabilities;
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Qwen Team
|
|
4
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
+
*/
|
|
6
|
+
import type { Message, PermissionRequest } from '../../adapters/types.js';
|
|
7
|
+
import type { Admission, ApprovalSelectionController, ChatCapabilities, ChatOperation, ChatStatusFacts, ComposerSubmit, ContextUsageController, ModelSelectionController, QuestionAnswer, SessionChatController, SessionOpsController } from '../../chat-core/contract.js';
|
|
8
|
+
import type { ManagedAgentPendingAction, ManagedAgentPendingQuestionAction, ManagedAgentQuestionAnswer, ManagedAgentSessionPhase } from './managed-agent-provider.js';
|
|
9
|
+
import { MAX_MANAGED_QUESTION_TEXT_LENGTH } from './managed-question-response.js';
|
|
10
|
+
export { MAX_MANAGED_QUESTION_TEXT_LENGTH };
|
|
11
|
+
type OperationState = ChatOperation['state'];
|
|
12
|
+
export interface ManagedTransportAdmission {
|
|
13
|
+
readonly admission: Admission;
|
|
14
|
+
readonly operationId?: string;
|
|
15
|
+
readonly turnId?: string;
|
|
16
|
+
}
|
|
17
|
+
export interface ManagedOperationSettlement {
|
|
18
|
+
readonly operationId: string;
|
|
19
|
+
readonly status: 'completed' | 'failed' | 'cancelled' | 'recovery_blocked';
|
|
20
|
+
}
|
|
21
|
+
export interface ManagedTurnSettlement {
|
|
22
|
+
readonly turnId: string;
|
|
23
|
+
readonly outcome: 'completed' | 'cancelled' | 'failed';
|
|
24
|
+
}
|
|
25
|
+
export interface ManagedActionSettlement {
|
|
26
|
+
readonly actionId: string;
|
|
27
|
+
readonly outcome: 'resolved' | 'expired' | 'superseded' | 'failed';
|
|
28
|
+
}
|
|
29
|
+
export interface ManagedChatControllerDeps {
|
|
30
|
+
readonly sessionId: string;
|
|
31
|
+
readonly storageKey: string;
|
|
32
|
+
readonly activeTurnId?: string;
|
|
33
|
+
readonly sessionPhase: ManagedAgentSessionPhase;
|
|
34
|
+
readonly messages: readonly Message[];
|
|
35
|
+
readonly transcriptState: 'loading' | 'ready' | 'error';
|
|
36
|
+
readonly hasOlderHistory?: boolean;
|
|
37
|
+
readonly loadingOlderHistory?: boolean;
|
|
38
|
+
readonly historyCapacityReached?: boolean;
|
|
39
|
+
readonly historyPaginationError?: boolean;
|
|
40
|
+
loadOlder?(options?: {
|
|
41
|
+
force?: boolean;
|
|
42
|
+
}): Promise<void>;
|
|
43
|
+
readonly pendingActions: readonly ManagedAgentPendingAction[];
|
|
44
|
+
readonly now?: () => number;
|
|
45
|
+
readonly statusFacts: ChatStatusFacts;
|
|
46
|
+
readonly capabilities: ChatCapabilities;
|
|
47
|
+
readonly modelSelection?: ModelSelectionController;
|
|
48
|
+
readonly approvalSelection?: ApprovalSelectionController;
|
|
49
|
+
readonly contextUsage?: ContextUsageController;
|
|
50
|
+
readonly sessionOps?: SessionOpsController;
|
|
51
|
+
submitPrompt(input: ComposerSubmit): Promise<ManagedTransportAdmission>;
|
|
52
|
+
cancelTurn(turnId: string): Promise<ManagedTransportAdmission>;
|
|
53
|
+
submitApproval(actionId: string, optionId: string): Promise<ManagedTransportAdmission>;
|
|
54
|
+
submitQuestion(actionId: string, answers: readonly ManagedAgentQuestionAnswer[]): Promise<ManagedTransportAdmission>;
|
|
55
|
+
subscribeOperationSettlement?(listener: (event: ManagedOperationSettlement) => void): () => void;
|
|
56
|
+
subscribeTurnSettlement?(listener: (event: ManagedTurnSettlement) => void): () => void;
|
|
57
|
+
subscribeActionSettlement?(listener: (event: ManagedActionSettlement) => void): () => void;
|
|
58
|
+
readonly signal?: AbortSignal;
|
|
59
|
+
}
|
|
60
|
+
export declare const MANAGED_QUESTION_SUBMIT_OPTION_ID = "submit";
|
|
61
|
+
export declare function mapManagedPhase(phase: ManagedAgentSessionPhase): 'idle' | 'running' | 'cancelling' | 'failed';
|
|
62
|
+
export declare function mapManagedOperationStatus(status: ManagedOperationSettlement['status']): Exclude<OperationState, 'pending'>;
|
|
63
|
+
export declare function toManagedQuestionPermissionRequest(action: ManagedAgentPendingQuestionAction): PermissionRequest;
|
|
64
|
+
export declare function normalizeManagedQuestionAnswers(action: ManagedAgentPendingQuestionAction, answers: readonly QuestionAnswer[]): ManagedAgentQuestionAnswer[] | null;
|
|
65
|
+
export declare function createManagedChatController(deps: ManagedChatControllerDeps): SessionChatController;
|
|
@@ -822,7 +822,7 @@ export interface paths {
|
|
|
822
822
|
};
|
|
823
823
|
get?: never;
|
|
824
824
|
put?: never;
|
|
825
|
-
/** @description Recheck only the latest original Turn under the existing cancellation/cleanup authorization. Repeated requests coalesce and may only advance existing cancellation/reconciliation or retry settled cleanup; they never resubmit input, replay effects, reset retry budgets or change claim generations. A stale Turn returns recovery_target_changed and ineligible work returns recovery_recheck_unavailable. A cleanup recheck that no Hosted Harness can serve returns 503 recovery_runtime_unavailable; a typed terminal decline returns 409 hosted_turn_recovery_declined, and retrying cannot change a decline. 202 means requested, not cancelled or ready. For a terminal Java Turn whose Harness attachment is cold or whose status cannot be read, this POST may attempt a narrow cleanup-only load. It must verify the original prompt has a durable native terminal, covered continuation checkpoint or lawful initial state, and no pending input before retrying only its existing cleanup. It never resumes models, tools, MCP or Hooks, clears a permanent journal block, or treats a historical SQL failure as native settlement. */
|
|
825
|
+
/** @description Recheck only the latest original Turn under the existing cancellation/cleanup authorization. Repeated requests coalesce and may only advance existing cancellation/reconciliation or retry settled cleanup; they never resubmit input, replay effects, reset retry budgets or change claim generations. A stale Turn returns recovery_target_changed and ineligible work returns recovery_recheck_unavailable. A cleanup recheck that no Hosted Harness can serve returns 503 recovery_runtime_unavailable; a typed terminal decline returns 409 hosted_turn_recovery_declined, and retrying cannot change a decline. 202 means requested, not cancelled or ready. For a terminal Java Turn whose Harness attachment is cold or whose status cannot be read, this POST may attempt a narrow cleanup-only load. It must verify the original prompt has a durable native terminal, covered continuation checkpoint or lawful initial state, and no pending input before retrying only its existing cleanup. A Turn cancelled before Harness admission keeps its public Turn id, while its cleanup recheck targets the settled prompt the Harness names for the Session. It never resumes models, tools, MCP or Hooks, clears a permanent journal block, or treats a historical SQL failure as native settlement. */
|
|
826
826
|
post: operations["recheckWebShellSessionRecovery"];
|
|
827
827
|
delete?: never;
|
|
828
828
|
options?: never;
|
|
@@ -214,6 +214,18 @@ export interface ManagedAgentRequestOptions {
|
|
|
214
214
|
export interface ManagedAgentCommandOptions extends ManagedAgentRequestOptions {
|
|
215
215
|
idempotencyKey: string;
|
|
216
216
|
}
|
|
217
|
+
export interface ManagedAgentOperationAdmission {
|
|
218
|
+
readonly sessionId: string;
|
|
219
|
+
readonly operationId: string;
|
|
220
|
+
readonly turnId?: string;
|
|
221
|
+
}
|
|
222
|
+
export interface ManagedAgentOperationSettlement extends ManagedAgentOperationAdmission {
|
|
223
|
+
readonly status: components['schemas']['WebShellOperation']['status'];
|
|
224
|
+
}
|
|
225
|
+
export interface ManagedAgentOperationObserver {
|
|
226
|
+
readonly onAccepted?: (admission: ManagedAgentOperationAdmission) => void;
|
|
227
|
+
readonly onSettlement?: (settlement: ManagedAgentOperationSettlement) => void;
|
|
228
|
+
}
|
|
217
229
|
export type ManagedContextCompressionOperation = components['schemas']['WebShellContextCompressionOperation'];
|
|
218
230
|
export type ManagedTask = components['schemas']['WebShellTask'];
|
|
219
231
|
export type ManagedTaskPage = components['schemas']['WebShellTaskPage'];
|
|
@@ -348,7 +360,7 @@ export interface ManagedAgentProvider {
|
|
|
348
360
|
listPending(sessionId: string, options: ManagedAgentRequestOptions & {
|
|
349
361
|
includeChildren?: boolean;
|
|
350
362
|
}): Promise<ManagedAgentPendingAction[]>;
|
|
351
|
-
respond(action: ManagedAgentPendingAction, response: ManagedAgentActionResponse, options: ManagedAgentCommandOptions): Promise<void>;
|
|
363
|
+
respond(action: ManagedAgentPendingAction, response: ManagedAgentActionResponse, options: ManagedAgentCommandOptions & ManagedAgentOperationObserver): Promise<void>;
|
|
352
364
|
};
|
|
353
365
|
readonly toolResults?: ManagedToolResultReader;
|
|
354
366
|
/** Present when the provider can list a Workspace's artifacts across Sessions. */
|
|
@@ -1,4 +1,11 @@
|
|
|
1
1
|
import type { ManagedAgentPendingQuestionAction, ManagedAgentQuestionAnswer } from './managed-agent-provider';
|
|
2
2
|
export declare const MAX_MANAGED_QUESTION_ANSWER_BYTES: number;
|
|
3
|
+
export declare const MAX_MANAGED_QUESTION_TEXT_LENGTH = 8192;
|
|
4
|
+
export type ManagedQuestionDraft = Record<string, {
|
|
5
|
+
optionIds: string[];
|
|
6
|
+
text: string;
|
|
7
|
+
}>;
|
|
8
|
+
export declare function managedQuestionAnswersFromDraft(action: ManagedAgentPendingQuestionAction, draft: ManagedQuestionDraft): ManagedAgentQuestionAnswer[];
|
|
9
|
+
export declare function exceedsManagedQuestionAnswerLimits(answers: readonly ManagedAgentQuestionAnswer[]): boolean;
|
|
3
10
|
export declare function canonicalQuestionAnswers(action: ManagedAgentPendingQuestionAction, answers: readonly ManagedAgentQuestionAnswer[]): ManagedAgentQuestionAnswer[];
|
|
4
11
|
export declare function questionResponseKey(action: ManagedAgentPendingQuestionAction, answers: readonly ManagedAgentQuestionAnswer[]): string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { ManagedAgentPendingAction, ManagedAgentActionResponse, ManagedAgentProvider, ManagedAgentSessionEvent } from './managed-agent-provider';
|
|
2
|
-
import type { ManagedQuestionDraft } from './
|
|
2
|
+
import type { ManagedQuestionDraft } from './managed-question-response';
|
|
3
3
|
export declare function managedActionKey(action: ManagedAgentPendingAction): string;
|
|
4
4
|
export interface ManagedActionsState {
|
|
5
5
|
actions: readonly ManagedAgentPendingAction[];
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { SessionChatController } from '../../chat-core/contract';
|
|
2
|
+
import type { ManagedAgentProvider } from './managed-agent-provider';
|
|
3
|
+
interface ManagedChatControllerOptions {
|
|
4
|
+
readonly provider: ManagedAgentProvider;
|
|
5
|
+
readonly clientId: string;
|
|
6
|
+
readonly sessionId: string | undefined;
|
|
7
|
+
}
|
|
8
|
+
export declare function useManagedChatController({ provider, clientId, sessionId, }: ManagedChatControllerOptions): SessionChatController | undefined;
|
|
9
|
+
export {};
|
|
@@ -1,5 +1,8 @@
|
|
|
1
|
-
import type { ManagedAgentProvider, ManagedAgentSessionSummary } from './managed-agent-provider';
|
|
2
|
-
export
|
|
1
|
+
import type { ManagedAgentOperationObserver, ManagedAgentProvider, ManagedAgentSessionSummary } from './managed-agent-provider';
|
|
2
|
+
export interface ManagedTurnCancelObserver extends ManagedAgentOperationObserver {
|
|
3
|
+
readonly onError?: (error: unknown) => void;
|
|
4
|
+
}
|
|
5
|
+
export declare function useManagedTurnCancel(provider: ManagedAgentProvider, clientId: string, sessionId: string | undefined, summary: ManagedAgentSessionSummary | undefined, interactive: boolean, refreshSummary: () => Promise<ManagedAgentSessionSummary | undefined>, observer?: ManagedTurnCancelObserver): {
|
|
3
6
|
request: () => Promise<void>;
|
|
4
7
|
retry: () => Promise<void>;
|
|
5
8
|
status: "failed" | "stopping" | "unconfirmed" | undefined;
|
|
@@ -1,9 +1,22 @@
|
|
|
1
1
|
import type { PermissionRequest } from '../../adapters/types';
|
|
2
|
+
import type { QuestionAnswer } from '../../chat-core/contract';
|
|
3
|
+
export type AskUserQuestionDraft = Record<string, {
|
|
4
|
+
optionIds: string[];
|
|
5
|
+
text: string;
|
|
6
|
+
}>;
|
|
2
7
|
interface AskUserQuestionProps {
|
|
3
8
|
request: PermissionRequest;
|
|
4
|
-
onConfirm: (id: string, selectedOption: string, answers?: Record<string, string
|
|
9
|
+
onConfirm: (id: string, selectedOption: string, answers?: Record<string, string>, structuredAnswers?: readonly QuestionAnswer[]) => Promise<boolean>;
|
|
5
10
|
onError: (error: unknown, fallback: string) => void;
|
|
6
11
|
variant?: 'inline' | 'floating';
|
|
12
|
+
/** Disables answering and submitting while keeping questions inspectable. */
|
|
13
|
+
disabled?: boolean;
|
|
14
|
+
/** Blocks only submission (Submit button and submit shortcuts) while keeping inputs editable. */
|
|
15
|
+
submitDisabled?: boolean;
|
|
16
|
+
/** Optional initial draft hydrated when a request mounts or changes identity. */
|
|
17
|
+
initialDraft?: AskUserQuestionDraft;
|
|
18
|
+
/** Emitted after user-driven answer edits so a host can preserve drafts across switches. */
|
|
19
|
+
onDraftChange?: (draft: AskUserQuestionDraft) => void;
|
|
7
20
|
customInputLabel?: string;
|
|
8
21
|
/**
|
|
9
22
|
* Opens a side task that explains the pending question before the user
|
|
@@ -20,5 +33,5 @@ interface AskUserQuestionProps {
|
|
|
20
33
|
*/
|
|
21
34
|
keyboardActive?: boolean;
|
|
22
35
|
}
|
|
23
|
-
export declare function AskUserQuestion({ request, onConfirm, onError, variant, keyboardActive, customInputLabel, onAskDetails, }: AskUserQuestionProps): import("react/jsx-runtime").JSX.Element | null;
|
|
36
|
+
export declare function AskUserQuestion({ request, onConfirm, onError, variant, disabled, submitDisabled, initialDraft, onDraftChange, keyboardActive, customInputLabel, onAskDetails, }: AskUserQuestionProps): import("react/jsx-runtime").JSX.Element | null;
|
|
24
37
|
export {};
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { type DaemonContextFileScope } from '@qwen-code/web-shell/daemon-react-sdk';
|
|
2
2
|
interface MemoryMessageProps {
|
|
3
|
+
workspaceCwd?: string;
|
|
3
4
|
addSignal?: number;
|
|
4
5
|
addScope?: DaemonContextFileScope;
|
|
5
6
|
onMessage?: (message: string, type?: 'status' | 'error') => void;
|
|
6
7
|
}
|
|
7
|
-
export declare function MemoryMessage({ addSignal, addScope, onMessage, }: MemoryMessageProps): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export declare function MemoryMessage({ workspaceCwd, addSignal, addScope, onMessage, }: MemoryMessageProps): import("react/jsx-runtime").JSX.Element;
|
|
8
9
|
export {};
|
|
@@ -30,6 +30,8 @@ interface SettingsMessageProps {
|
|
|
30
30
|
* the Workspace scope tab; omitted when the daemon cannot manage them.
|
|
31
31
|
*/
|
|
32
32
|
workspaceDirectoriesSection?: ReactNode;
|
|
33
|
+
/** Optional workspace switcher rendered beside the scope tabs. */
|
|
34
|
+
workspaceControl?: ReactNode;
|
|
33
35
|
embedded?: boolean;
|
|
34
36
|
/** Category to select on open (deep link, e.g. 'Daemon'). */
|
|
35
37
|
initialCategory?: string;
|
|
@@ -53,16 +55,22 @@ export interface SettingsMessageSettingsState {
|
|
|
53
55
|
type Scope = 'user' | 'workspace';
|
|
54
56
|
type Translator = (key: string, vars?: Record<string, string | number>) => string;
|
|
55
57
|
export declare function formatSettingLabel(setting: DaemonSettingDescriptor, t: Translator): string;
|
|
58
|
+
declare const LOCAL_SETTING_IDS: {
|
|
59
|
+
readonly chatWidth: "builtin:chat-width";
|
|
60
|
+
readonly arrowKeyHistory: "builtin:arrow-key-history";
|
|
61
|
+
readonly browserNotifications: "builtin:browser-notifications";
|
|
62
|
+
};
|
|
63
|
+
type LocalSettingItem = {
|
|
64
|
+
type: 'local';
|
|
65
|
+
localKey: keyof typeof LOCAL_SETTING_IDS;
|
|
66
|
+
};
|
|
56
67
|
export type FlatRow = {
|
|
57
68
|
type: 'header';
|
|
58
69
|
category: string;
|
|
59
70
|
} | {
|
|
60
71
|
type: 'setting';
|
|
61
72
|
setting: DaemonSettingDescriptor;
|
|
62
|
-
} |
|
|
63
|
-
type: 'local';
|
|
64
|
-
localKey: 'chatWidth' | 'browserNotifications';
|
|
65
|
-
};
|
|
73
|
+
} | LocalSettingItem;
|
|
66
74
|
export declare function nextSettingIdx(rows: FlatRow[], current: number, dir: 1 | -1): number;
|
|
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;
|
|
75
|
+
export declare function SettingsMessage({ settingsState, presentation, onLanguageChange, onOutputLanguageChange, onSubDialog, onThemeChange, chatWidthMode, onChatWidthModeChange, modelManagementSectionProps, connections, archivedSessions, workspaceDirectoriesSection, workspaceControl, embedded, initialCategory, workspaceSettingsWritable, }: SettingsMessageProps): import("react/jsx-runtime").JSX.Element;
|
|
68
76
|
export {};
|