@qwen-code/web-shell 0.28.3 → 0.28.6-nightly.20261126.6b0cd79b
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-CxOZ1g2v.js → PierreFilePreview-DEWuPKoz.js} +1 -1
- package/dist/{SpreadsheetPreview--Hpv2uJo.js → SpreadsheetPreview-Cyor3Mdu.js} +2 -2
- package/dist/{WorkspaceFileBrowser-DQ_nK8CO.js → WorkspaceFileBrowser-CWjB1-hU.js} +2 -2
- package/dist/{WorkspacePdfRangePreview-B9zOI3Db.js → WorkspacePdfRangePreview-BuJXSlFE.js} +2 -2
- package/dist/{agents-route-D1nhKzzl.js → agents-route-B_dty2Xs.js} +2 -2
- package/dist/daemon-react-sdk.js +1 -1
- package/dist/{i18n-ru-CfZvlNRX.js → i18n-ru-zX2HBIQv.js} +44 -22
- package/dist/{i18n-zh-cn-oYBQlyci.js → i18n-zh-cn-CqjpUMZJ.js} +44 -20
- package/dist/{i18n-zh-tw-meIHyJiH.js → i18n-zh-tw-DyTerQIj.js} +63 -10
- package/dist/{index-ChjMzQ_r.js → index-YiM1lMIr.js} +71720 -66968
- 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 +12041 -11754
- 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/messageTypes.d.ts +4 -0
- package/dist/types/adapters/transcriptAdapter.d.ts +10 -0
- package/dist/types/adapters/transcriptToMessages.d.ts +0 -20
- package/dist/types/chat-core/ChatSurface.d.ts +81 -0
- package/dist/types/chat-core/contract.d.ts +13 -2
- 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 +12 -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/SessionPrBadge.d.ts +3 -1
- package/dist/types/components/TranscriptViewport.d.ts +6 -0
- package/dist/types/components/WorkspaceSelector.d.ts +7 -1
- package/dist/types/components/artifacts/ArtifactPanel.d.ts +8 -0
- package/dist/types/components/artifacts/WorkspaceArtifactLibraryPage.d.ts +12 -0
- package/dist/types/components/artifacts/artifactUtils.d.ts +84 -1
- package/dist/types/components/artifacts/workspace-artifact-library-messages.d.ts +8 -0
- package/dist/types/components/artifacts/workspace-artifact-library-messages.transcript-stub.d.ts +8 -0
- 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 +66 -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 +7 -3
- package/dist/types/components/managed/use-managed-chat-controller.d.ts +40 -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/AssistantMessage.d.ts +5 -1
- package/dist/types/components/messages/MemoryMessage.d.ts +2 -1
- package/dist/types/components/messages/ModAssistantMessage.d.ts +8 -1
- package/dist/types/components/messages/SettingsMessage.d.ts +13 -5
- package/dist/types/components/messages/ThinkingBody.d.ts +20 -0
- package/dist/types/components/messages/ThinkingBody.transcript-stub.d.ts +8 -0
- package/dist/types/components/messages/ToolGroup.d.ts +2 -6
- package/dist/types/components/messages/UserMessage.d.ts +2 -0
- package/dist/types/components/plugins/PluginManagerPage.d.ts +3 -1
- package/dist/types/components/preview/SavedWebPreview.d.ts +3 -2
- package/dist/types/components/sidebar/WebShellSidebar.d.ts +10 -7
- 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 +8 -1
- package/dist/types/daemon/index.d.ts +1 -1
- 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 +27 -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/index.d.ts +1 -1
- package/dist/types/daemon/workspace/types.d.ts +31 -2
- 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 +26 -1
- package/dist/types/hooks/useInputHistory.d.ts +11 -1
- package/dist/types/hooks/useScopedSessions.d.ts +1 -0
- package/dist/types/hooks/useWorkspaceArtifactLibrary.d.ts +47 -0
- package/dist/types/i18n.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/automatic-trigger.d.ts +2 -0
- package/dist/types/utils/navigationUrl.d.ts +1 -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/types/utils/touchCaret.d.ts +33 -0
- package/dist/types/utils/visualViewportInset.d.ts +13 -0
- package/dist/{useDaemonMidTurnInjected-BjQ9zxRv.js → useDaemonMidTurnInjected-K7Sl7y1O.js} +8324 -7933
- 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
|
|
@@ -169,6 +169,8 @@ export interface DaemonThinkingMessage extends DaemonMessageMeta {
|
|
|
169
169
|
role: 'thinking';
|
|
170
170
|
content: string;
|
|
171
171
|
isStreaming?: boolean;
|
|
172
|
+
/** Identifies a subagent's thought rendered without its parent tool card. */
|
|
173
|
+
parentToolCallId?: string;
|
|
172
174
|
}
|
|
173
175
|
export interface DaemonToolGroupMessage extends DaemonMessageMeta {
|
|
174
176
|
id: string;
|
|
@@ -183,9 +185,11 @@ export interface DaemonToolGroupMessage extends DaemonMessageMeta {
|
|
|
183
185
|
* trail the last tool.
|
|
184
186
|
*/
|
|
185
187
|
thoughts?: Array<{
|
|
188
|
+
id?: string;
|
|
186
189
|
content: string;
|
|
187
190
|
isStreaming?: boolean;
|
|
188
191
|
beforeToolCallId?: string;
|
|
192
|
+
parentToolCallId?: string;
|
|
189
193
|
}>;
|
|
190
194
|
}
|
|
191
195
|
export interface DaemonPlanMessage extends DaemonMessageMeta {
|
|
@@ -9,4 +9,14 @@ export declare function extractPendingPermission(blocks: readonly DaemonTranscri
|
|
|
9
9
|
* delta does not re-serialize each outstanding approval's payload.
|
|
10
10
|
*/
|
|
11
11
|
export declare function isAskUserPermissionBlock(block: DaemonTranscriptBlock): boolean;
|
|
12
|
+
/**
|
|
13
|
+
* Cheap content revision for a pending permission block, used to key the
|
|
14
|
+
* binding's split cache. A re-emitted `permission.request` under the same
|
|
15
|
+
* request id can change the title/options while id and classification stay
|
|
16
|
+
* put, so id+classification alone would serve a stale render-ready request.
|
|
17
|
+
* Reads only scalar/option-id fields (no payload serialization) so a streaming
|
|
18
|
+
* delta does not re-serialize the payload; `updatedAt` additionally catches
|
|
19
|
+
* raw-input-only updates that bump the block's revision.
|
|
20
|
+
*/
|
|
21
|
+
export declare function pendingPermissionRevision(block: DaemonTranscriptBlock): string;
|
|
12
22
|
export declare function escapePreviewText(text: string): string;
|
|
@@ -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
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Qwen Team
|
|
4
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
+
*/
|
|
6
|
+
import { type ComponentProps, type ReactNode, type Ref } from 'react';
|
|
7
|
+
import type { CommandInfo, TodoItem } from '../adapters/types.js';
|
|
8
|
+
import { type TranscriptViewportProps } from '../components/TranscriptViewport.js';
|
|
9
|
+
import type { SessionContentGenerator } from '../components/messages/AssistantMessage.js';
|
|
10
|
+
import { type AskUserQuestionDraft } from '../components/messages/AskUserQuestion.js';
|
|
11
|
+
import { ChatEditor, type ComposerToolbarAction } from '../components/ChatEditor.js';
|
|
12
|
+
import type { EditorHandle } from '../hooks/useComposerCore.js';
|
|
13
|
+
import type { SessionChatController } from './contract.js';
|
|
14
|
+
type SurfaceOwnedTranscriptKeys = 'messages' | 'pendingApproval' | 'approvalOverlayActive' | 'sessionViewportEnabled' | 'loadingTranscript' | 'isResponding' | 'sessionKey' | 'hasOlderHistory' | 'onLoadOlderHistory' | 'historyPaginationError' | 'loadingOlderHistory' | 'historyCapacityReached';
|
|
15
|
+
export type ChatSurfaceTranscriptProps = Omit<TranscriptViewportProps, SurfaceOwnedTranscriptKeys>;
|
|
16
|
+
type ChatEditorComponentProps = ComponentProps<typeof ChatEditor>;
|
|
17
|
+
type SurfaceOwnedComposerKeys = 'ref' | 'commands' | 'atWorkspaceCwd' | 'composerScopeKey' | 'workspaceFeaturesEnabled' | 'visibleToolbarActions' | 'submitDisabled' | 'onCancel' | 'onSubmit';
|
|
18
|
+
export type ChatSurfaceComposerProps = Omit<ChatEditorComponentProps, SurfaceOwnedComposerKeys>;
|
|
19
|
+
export interface ChatSurfaceProps {
|
|
20
|
+
readonly controller: SessionChatController;
|
|
21
|
+
readonly className?: string;
|
|
22
|
+
readonly header?: ReactNode;
|
|
23
|
+
readonly panels?: ReactNode;
|
|
24
|
+
readonly transcriptClassName?: string;
|
|
25
|
+
readonly transcriptProps?: ChatSurfaceTranscriptProps;
|
|
26
|
+
readonly composerStatus?: ReactNode;
|
|
27
|
+
readonly composerFooter?: ReactNode;
|
|
28
|
+
readonly transcriptError?: ReactNode;
|
|
29
|
+
readonly commands?: readonly CommandInfo[];
|
|
30
|
+
readonly onError?: (error: unknown, fallback: string) => void;
|
|
31
|
+
readonly hasOlderHistory?: boolean;
|
|
32
|
+
readonly onLoadOlderHistory?: (options?: {
|
|
33
|
+
force?: boolean;
|
|
34
|
+
}) => Promise<void>;
|
|
35
|
+
readonly historyPaginationError?: boolean;
|
|
36
|
+
readonly loadingOlderHistory?: boolean;
|
|
37
|
+
readonly historyCapacityReached?: boolean;
|
|
38
|
+
readonly decisionClassName?: string;
|
|
39
|
+
readonly decisionTestId?: string;
|
|
40
|
+
readonly decisionHeader?: ReactNode;
|
|
41
|
+
readonly decisionFooter?: ReactNode;
|
|
42
|
+
readonly approvalKey?: string;
|
|
43
|
+
readonly approvalExtraDescriptionId?: string;
|
|
44
|
+
readonly planTodos?: readonly TodoItem[];
|
|
45
|
+
readonly planExecutionMode?: string;
|
|
46
|
+
readonly approvalDisabled?: boolean;
|
|
47
|
+
readonly approvalKeyboardActive?: boolean;
|
|
48
|
+
readonly showBrowserNotifications?: boolean;
|
|
49
|
+
readonly generateContent?: SessionContentGenerator;
|
|
50
|
+
readonly questionKey?: string;
|
|
51
|
+
readonly askUserFreeTextLabel?: string;
|
|
52
|
+
readonly askUserDetails?: () => void;
|
|
53
|
+
readonly askUserInitialDraft?: AskUserQuestionDraft;
|
|
54
|
+
readonly askUserOnDraftChange?: (draft: AskUserQuestionDraft) => void;
|
|
55
|
+
readonly askUserSubmitDisabled?: boolean;
|
|
56
|
+
readonly hideComposerWhenCardActive?: boolean;
|
|
57
|
+
readonly atWorkspaceCwd?: string;
|
|
58
|
+
readonly composerScopeKey?: string;
|
|
59
|
+
readonly composerSubmitBlocked?: boolean;
|
|
60
|
+
readonly composerClassName?: string;
|
|
61
|
+
readonly composerVisible?: boolean;
|
|
62
|
+
readonly composerKey?: string;
|
|
63
|
+
readonly composerRef?: Ref<EditorHandle>;
|
|
64
|
+
readonly composerContainerRef?: Ref<HTMLDivElement>;
|
|
65
|
+
readonly composerCancelEnabled?: boolean;
|
|
66
|
+
readonly onComposerSubmit?: ChatEditorComponentProps['onSubmit'];
|
|
67
|
+
readonly composerProps?: ChatSurfaceComposerProps;
|
|
68
|
+
readonly sessionViewportEnabled?: boolean;
|
|
69
|
+
readonly workspaceFeaturesEnabled?: boolean;
|
|
70
|
+
readonly visibleToolbarActions?: readonly ComposerToolbarAction[];
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* The backend-neutral chat column (unified chat surface, slice 2). It renders
|
|
74
|
+
* every chat column from a {@link SessionChatController} view model and never
|
|
75
|
+
* branches on `controller.kind`: a region renders only when its facts are
|
|
76
|
+
* present. Backend-specific panels and chrome arrive as slots. Admission is not
|
|
77
|
+
* establishment — the composer defers its draft commit to admission, while turn
|
|
78
|
+
* and decision outcomes are reflected through the controller's observable state.
|
|
79
|
+
*/
|
|
80
|
+
export declare function ChatSurface({ controller, className, header, panels, transcriptClassName, transcriptProps, composerStatus, composerFooter, transcriptError, commands, onError, hasOlderHistory, onLoadOlderHistory, historyPaginationError, loadingOlderHistory, historyCapacityReached, decisionClassName, decisionTestId, decisionHeader, decisionFooter, approvalKey, approvalExtraDescriptionId, planTodos, planExecutionMode, approvalDisabled, approvalKeyboardActive, showBrowserNotifications, generateContent, questionKey, askUserFreeTextLabel, askUserDetails, askUserInitialDraft, askUserOnDraftChange, askUserSubmitDisabled, hideComposerWhenCardActive, atWorkspaceCwd, composerScopeKey, composerSubmitBlocked, composerClassName, composerVisible, composerKey, composerRef, composerContainerRef, composerCancelEnabled, onComposerSubmit, composerProps, sessionViewportEnabled, workspaceFeaturesEnabled, visibleToolbarActions, }: ChatSurfaceProps): import("react/jsx-runtime").JSX.Element;
|
|
81
|
+
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { Message } from '../adapters/types.js';
|
|
1
|
+
import type { Message, PermissionRequest } from '../adapters/types.js';
|
|
2
2
|
import type { PromptFile, PromptImage } from '../adapters/promptTypes.js';
|
|
3
3
|
import type { ComposerSubmitMetadata } from '../hooks/useComposerCore.js';
|
|
4
4
|
export type Admission = 'accepted' | 'rejected' | 'unknown';
|
|
@@ -26,13 +26,17 @@ export type ChatPhase = 'idle' | 'submitting' | 'running' | 'cancelling' | 'fail
|
|
|
26
26
|
export interface PendingApproval {
|
|
27
27
|
readonly id: string;
|
|
28
28
|
readonly status: 'pending' | 'superseded';
|
|
29
|
+
readonly request: PermissionRequest;
|
|
29
30
|
}
|
|
30
31
|
export interface PendingQuestion {
|
|
31
32
|
readonly id: string;
|
|
33
|
+
readonly request: PermissionRequest;
|
|
32
34
|
}
|
|
33
35
|
export interface QuestionAnswer {
|
|
34
36
|
readonly questionId: string;
|
|
35
37
|
readonly value: string;
|
|
38
|
+
readonly optionIds?: readonly string[];
|
|
39
|
+
readonly text?: string;
|
|
36
40
|
}
|
|
37
41
|
export interface ComposerSubmit {
|
|
38
42
|
readonly text: string;
|
|
@@ -86,10 +90,17 @@ export interface SessionChatController {
|
|
|
86
90
|
readonly kind: 'daemon' | 'managed';
|
|
87
91
|
readonly sessionId: string;
|
|
88
92
|
readonly storageKey: string;
|
|
93
|
+
readonly activeTurnId?: string;
|
|
89
94
|
readonly operations: readonly ChatOperation[];
|
|
90
95
|
readonly messages: readonly Message[];
|
|
91
96
|
readonly transcriptState: 'loading' | 'ready' | 'error';
|
|
92
|
-
|
|
97
|
+
readonly hasOlderHistory?: boolean;
|
|
98
|
+
readonly loadingOlderHistory?: boolean;
|
|
99
|
+
readonly historyCapacityReached?: boolean;
|
|
100
|
+
readonly historyPaginationError?: boolean;
|
|
101
|
+
loadOlder?(options?: {
|
|
102
|
+
force?: boolean;
|
|
103
|
+
}): Promise<void>;
|
|
93
104
|
readonly phase: ChatPhase;
|
|
94
105
|
submit(input: ComposerSubmit): Promise<IntentResult>;
|
|
95
106
|
cancel(): Promise<IntentResult>;
|
|
@@ -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;
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
* Copyright 2026 Qwen Team
|
|
4
4
|
* SPDX-License-Identifier: Apache-2.0
|
|
5
5
|
*/
|
|
6
|
+
import type { DaemonWorkspaceGitStatus } from '@qwen-code/sdk/daemon';
|
|
6
7
|
export type SessionGitIntent = {
|
|
7
8
|
mode: 'current';
|
|
8
9
|
} | {
|
|
@@ -13,11 +14,21 @@ export type SessionGitIntent = {
|
|
|
13
14
|
slug?: string;
|
|
14
15
|
};
|
|
15
16
|
export declare function validateBranchName(name: string): boolean;
|
|
17
|
+
export interface GitModePopoverDraft {
|
|
18
|
+
selectedMode: SessionGitIntent['mode'];
|
|
19
|
+
branchName: string;
|
|
20
|
+
}
|
|
16
21
|
interface GitModePopoverProps {
|
|
17
22
|
branch: string;
|
|
23
|
+
status?: DaemonWorkspaceGitStatus;
|
|
18
24
|
compact?: boolean;
|
|
25
|
+
showDetails?: boolean;
|
|
19
26
|
intent: SessionGitIntent;
|
|
20
27
|
onIntentChange: (intent: SessionGitIntent) => void;
|
|
28
|
+
open?: boolean;
|
|
29
|
+
onOpenChange?: (open: boolean) => void;
|
|
30
|
+
draft?: GitModePopoverDraft;
|
|
31
|
+
onDraftChange?: (update: (current: GitModePopoverDraft) => GitModePopoverDraft) => void;
|
|
21
32
|
}
|
|
22
|
-
export declare function GitModePopover({ branch, 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;
|
|
23
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;
|
|
@@ -12,6 +12,8 @@ interface SessionPrBadgeProps {
|
|
|
12
12
|
* owns roving-tabindex keyboard navigation (e.g. picker dialogs).
|
|
13
13
|
*/
|
|
14
14
|
tabIndex?: number;
|
|
15
|
+
/** Uses less spacing and no pill background in sidebar session rows. */
|
|
16
|
+
compact?: boolean;
|
|
15
17
|
}
|
|
16
18
|
/**
|
|
17
19
|
* The bound PRs the badge can open, in the order given. Bindings whose URL
|
|
@@ -27,5 +29,5 @@ export declare function openableSessionPrs(prs: DaemonSessionPrInfo[]): DaemonSe
|
|
|
27
29
|
* PR with an overflow count and opens it through the desktop-aware
|
|
28
30
|
* external-link opener.
|
|
29
31
|
*/
|
|
30
|
-
export declare function SessionPrBadge({ prs, tabIndex }: SessionPrBadgeProps): import("react/jsx-runtime").JSX.Element | null;
|
|
32
|
+
export declare function SessionPrBadge({ prs, tabIndex, compact, }: SessionPrBadgeProps): import("react/jsx-runtime").JSX.Element | null;
|
|
31
33
|
export {};
|
|
@@ -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>>;
|
|
@@ -31,10 +31,16 @@ interface WorkspaceSelectorProps {
|
|
|
31
31
|
onSelectStandalone?: () => void;
|
|
32
32
|
onCreateScratch: () => void;
|
|
33
33
|
onOpenExistingFolder: () => void;
|
|
34
|
+
/** Touch activation can otherwise release over a newly opened option. */
|
|
35
|
+
contentSide?: 'top' | 'bottom';
|
|
36
|
+
open?: boolean;
|
|
37
|
+
onOpenChange?: (open: boolean) => void;
|
|
38
|
+
newWorkspaceOpen?: boolean;
|
|
39
|
+
onNewWorkspaceOpenChange?: (open: boolean) => void;
|
|
34
40
|
}
|
|
35
41
|
/**
|
|
36
42
|
* Composer workspace menu. Capability-gated creation actions and disabled
|
|
37
43
|
* untrusted entries keep presentation aligned with daemon authorization.
|
|
38
44
|
*/
|
|
39
|
-
export declare function WorkspaceSelector({ workspaces, selectedWorkspaceCwd, disabled, busy, alwaysVisible, menuItems, scratchSupported, existingFolderSupported, standaloneSupported, selectedStandalone, className, onSelectWorkspace, onSelectHostedWorkspace, onSelectStandalone, onCreateScratch, onOpenExistingFolder, }: 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;
|
|
40
46
|
export {};
|
|
@@ -10,6 +10,7 @@ import type { SessionWorkflowProjection } from '../workflow/session-workflow-mod
|
|
|
10
10
|
import type { WebPreviewState } from '../preview/web-preview';
|
|
11
11
|
import type { TrajectoryPageLoader } from '../../trajectory/useTrajectoryWindow';
|
|
12
12
|
import type { ContextUsageControls } from '../../hooks/useContextUsageControls';
|
|
13
|
+
import { type ArtifactWorkspaceActions } from './useArtifactWorkspaceTarget';
|
|
13
14
|
export type ImageTabSource = {
|
|
14
15
|
kind: 'attachment';
|
|
15
16
|
attachmentId: string;
|
|
@@ -329,4 +330,11 @@ interface ArtifactPanelProps {
|
|
|
329
330
|
onToggleFullscreen?: () => void;
|
|
330
331
|
}
|
|
331
332
|
export declare function ArtifactPanel({ contextUsageControls, artifacts, sessionArtifacts, onOpenArtifact, tabs, activeTabId, reviewChanges, selectedReviewPath, panelWidth, workspaceCwd, loading, restoring, error, onSelectTab, onSelectTurnCallsPrompt, onCloseTab, onOpenFilePreview, onOpenMemoryFile, latestReviewAvailable, onOpenLatestReview, changeOverviewAvailable, onOpenChangeOverview, onOpenTerminal, onOpenTrajectory, trajectoryTabId, onOpenFiles, onReferenceFile, onOpenWebPreview, onWebPreviewChange, items, sideTaskAvailable, sideTasks, archivedSideTasks, sideTasksLoading, onCreateSideTask, onOpenSideTask, onArchiveSideTasks, onUnarchiveSideTasks, onSideTaskMenuOpen, onCreateSideTaskSession, onSideTaskCreated, onSideTaskTitleChange, onSideTaskInitialPromptRefused, onNestedRightPanelOpen, onNestedArtifactsChange, onOpenNestedSubagent, agentTasks, explainTask, onExplainTask, taskExplanation, agentTraceLoading, agentTraceError, onOpenWorkflowAgent, onError, sessionWorkflowEnabled, modelManagement, unavailableModels, mountUnavailableModelTooltip, workflow, onImageIngestionNotice, deferSubagentMount, onClose, variant, fullscreen, onToggleFullscreen, }: ArtifactPanelProps): import("react/jsx-runtime").JSX.Element;
|
|
333
|
+
export declare function ArtifactDetail({ artifact, sourceSessionId, workspaceActions, previewContent, onSnapshotSessionNotFound, }: {
|
|
334
|
+
artifact: DaemonSessionArtifact;
|
|
335
|
+
sourceSessionId?: string;
|
|
336
|
+
workspaceActions: ArtifactWorkspaceActions;
|
|
337
|
+
previewContent?: string;
|
|
338
|
+
onSnapshotSessionNotFound?: () => void;
|
|
339
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
332
340
|
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { type WorkspaceArtifactLibraryReader } from '../../hooks/useWorkspaceArtifactLibrary';
|
|
2
|
+
export declare const DEFAULT_ARTIFACT_LIBRARY_RENDER_STEP = 50;
|
|
3
|
+
export interface WorkspaceArtifactLibraryPageProps {
|
|
4
|
+
workspaceCwd: string | undefined;
|
|
5
|
+
onOpenSession: (sessionId: string, archiveState: 'active' | 'archived') => void;
|
|
6
|
+
onJumpToSessionArtifact: (sessionId: string, artifactId: string, archiveState: 'active' | 'archived') => void;
|
|
7
|
+
reader?: WorkspaceArtifactLibraryReader;
|
|
8
|
+
features?: readonly string[];
|
|
9
|
+
isSessionLive?: (sessionId: string) => boolean;
|
|
10
|
+
renderLimitStep?: number;
|
|
11
|
+
}
|
|
12
|
+
export declare function WorkspaceArtifactLibraryPage({ workspaceCwd, onOpenSession, onJumpToSessionArtifact, reader: readerProp, features: featuresProp, isSessionLive: isSessionLiveProp, renderLimitStep, }: WorkspaceArtifactLibraryPageProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type
|
|
1
|
+
import { type DaemonSessionArtifact, type DaemonWorkspaceFileBytes } from '@qwen-code/sdk/daemon';
|
|
2
2
|
import type { DaemonWorkspaceActions } from '@qwen-code/web-shell/daemon-react-sdk';
|
|
3
3
|
export declare function artifactKindLabel(kind: string, workspacePath?: string): string;
|
|
4
4
|
export declare function isOfficeDocumentPath(workspacePath?: string): boolean;
|
|
@@ -55,4 +55,87 @@ export declare function stripWorkspacePath(path: string, workspaceCwd?: string):
|
|
|
55
55
|
export declare function isSamePath(left: string | undefined, right: string | undefined, workspaceCwd?: string): boolean;
|
|
56
56
|
export declare function artifactPreviewDocument(html: string, title: string): string;
|
|
57
57
|
export declare function loadArtifactPreviewDocument(html: string, title: string, signal: AbortSignal): Promise<string>;
|
|
58
|
+
export declare function isWebPreviewSnapshotArtifact(artifact: Pick<DaemonSessionArtifact, 'metadata'>): boolean;
|
|
59
|
+
export declare function isCodeReviewArtifact(artifact: Pick<DaemonSessionArtifact, 'metadata'>): boolean;
|
|
60
|
+
export declare function isAutomationSnapshotArtifact(artifact: Pick<DaemonSessionArtifact, 'metadata'>): boolean;
|
|
61
|
+
export declare function canPreviewWorkspaceArtifact(artifact: Pick<DaemonSessionArtifact, 'storage' | 'workspacePath'>): boolean;
|
|
62
|
+
export type WorkspaceArtifactDispatchAction = {
|
|
63
|
+
kind: 'workspace_preview';
|
|
64
|
+
} | {
|
|
65
|
+
kind: 'live_web_preview_snapshot';
|
|
66
|
+
} | {
|
|
67
|
+
kind: 'jump_web_preview_snapshot';
|
|
68
|
+
} | {
|
|
69
|
+
kind: 'metadata_detail';
|
|
70
|
+
};
|
|
71
|
+
/**
|
|
72
|
+
* Shared dispatch classification for session and workspace artifact views.
|
|
73
|
+
* Saved web-preview snapshots (`metadata.artifactType === 'web_preview_snapshot'`,
|
|
74
|
+
* stored with `storage: 'published'`) require a live attached session for the
|
|
75
|
+
* snapshot content route; cold/archived sessions must jump to the session
|
|
76
|
+
* first. Metadata-only `storage: 'managed'` artifacts render straight from the
|
|
77
|
+
* envelope descriptor without loading a session or hitting the content route.
|
|
78
|
+
*/
|
|
79
|
+
export declare function classifyWorkspaceArtifactDispatch(artifact: DaemonSessionArtifact, isSessionLive: boolean): WorkspaceArtifactDispatchAction;
|
|
80
|
+
export interface DaemonHttpErrorInfo {
|
|
81
|
+
status?: number;
|
|
82
|
+
code?: string;
|
|
83
|
+
message: string;
|
|
84
|
+
}
|
|
85
|
+
export declare function readDaemonHttpErrorInfo(error: unknown): DaemonHttpErrorInfo;
|
|
86
|
+
export declare function isSessionNotFoundArtifactError(error: unknown): boolean;
|
|
87
|
+
export declare function isArtifactSnapshotUnavailableError(error: unknown): boolean;
|
|
88
|
+
export interface PendingArtifactJumpOpenRequest {
|
|
89
|
+
readonly sessionId: string;
|
|
90
|
+
readonly artifactId: string;
|
|
91
|
+
}
|
|
92
|
+
/**
|
|
93
|
+
* Decides whether a session-keyed post-jump artifact open request should wait,
|
|
94
|
+
* open now, or be canceled because the user switched to another session
|
|
95
|
+
* mid-load. Opening before the target session's right-panel restore commits
|
|
96
|
+
* would have its tab wiped by the restore effect's reset.
|
|
97
|
+
*/
|
|
98
|
+
export declare function resolvePendingArtifactJumpOpen(pending: PendingArtifactJumpOpenRequest | undefined, state: {
|
|
99
|
+
currentSessionId: string | undefined;
|
|
100
|
+
switchingSessionId: string | null | undefined;
|
|
101
|
+
panelStateKey: string | undefined;
|
|
102
|
+
restoredSessionKey: string | undefined;
|
|
103
|
+
panelRestoring: boolean;
|
|
104
|
+
loadingTranscript: boolean | undefined;
|
|
105
|
+
artifactsLoading: boolean;
|
|
106
|
+
connected: boolean;
|
|
107
|
+
}): 'none' | 'wait' | 'open' | 'cancel';
|
|
108
|
+
export interface ArtifactLibrarySessionJumpDeps {
|
|
109
|
+
sessionId: string;
|
|
110
|
+
archiveState: 'active' | 'archived';
|
|
111
|
+
artifactId?: string;
|
|
112
|
+
targetCwd: string | undefined;
|
|
113
|
+
primaryCwd: string | undefined;
|
|
114
|
+
showChat: () => void;
|
|
115
|
+
unarchivePrimarySession: (sessionId: string) => Promise<unknown>;
|
|
116
|
+
unarchiveWorkspaceSessions: (workspaceCwd: string, sessionIds: string[]) => Promise<{
|
|
117
|
+
unarchived: string[];
|
|
118
|
+
alreadyActive: string[];
|
|
119
|
+
notFound: string[];
|
|
120
|
+
errors: Array<{
|
|
121
|
+
sessionId: string;
|
|
122
|
+
error: string;
|
|
123
|
+
}>;
|
|
124
|
+
}>;
|
|
125
|
+
getPendingJumpArtifactOpen: () => PendingArtifactJumpOpenRequest | undefined;
|
|
126
|
+
setPendingJumpArtifactOpen: (request: PendingArtifactJumpOpenRequest | undefined) => void;
|
|
127
|
+
isCurrent: () => boolean;
|
|
128
|
+
loadSidebarSession: (sessionId: string, workspaceCwd?: string) => Promise<void>;
|
|
129
|
+
reportError: (error: unknown, fallbackMessage: string) => void;
|
|
130
|
+
}
|
|
131
|
+
/**
|
|
132
|
+
* Orchestrates opening a session (and optionally arming a post-jump artifact
|
|
133
|
+
* tab open) from the workspace artifact library. For archived sessions, the
|
|
134
|
+
* pending artifact open is armed only AFTER unarchive resolves and immediately
|
|
135
|
+
* before `loadSidebarSession`, so `resolvePendingArtifactJumpOpen` does not
|
|
136
|
+
* cancel the request while the shell is still parked on the old session during
|
|
137
|
+
* the awaited unarchive RPC. `isCurrent()` is checked after the awaited
|
|
138
|
+
* unarchive so a navigation started meanwhile is never overridden.
|
|
139
|
+
*/
|
|
140
|
+
export declare function runArtifactLibrarySessionJump(deps: ArtifactLibrarySessionJumpDeps): Promise<void>;
|
|
58
141
|
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Qwen Team
|
|
4
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
+
*/
|
|
6
|
+
export declare const WORKSPACE_ARTIFACT_LIBRARY_MESSAGES_EN: Record<string, string>;
|
|
7
|
+
export declare const WORKSPACE_ARTIFACT_LIBRARY_MESSAGES_ZH: Record<string, string>;
|
|
8
|
+
export declare const WORKSPACE_ARTIFACT_LIBRARY_MESSAGES_RU: Record<string, string>;
|
package/dist/types/components/artifacts/workspace-artifact-library-messages.transcript-stub.d.ts
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Qwen Team
|
|
4
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
+
*/
|
|
6
|
+
export declare const WORKSPACE_ARTIFACT_LIBRARY_MESSAGES_EN: {};
|
|
7
|
+
export declare const WORKSPACE_ARTIFACT_LIBRARY_MESSAGES_ZH: {};
|
|
8
|
+
export declare const WORKSPACE_ARTIFACT_LIBRARY_MESSAGES_RU: {};
|
|
@@ -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;
|