@qwen-code/web-shell 0.24.4 → 0.24.5-nightly.20260924.ffea2d024e
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +152 -1
- package/dist/code-highlighter.js +4 -0
- package/dist/codeHighlighter-pfciSYNN.js +89 -0
- package/dist/daemon-react-sdk.js +1 -1
- package/dist/index.js +47299 -43736
- package/dist/sw.js +1 -1
- package/dist/{toolNames-Cnaa5VCB.js → toolNames-DIL221YO.js} +6421 -5852
- package/dist/transcript.js +11346 -10971
- package/dist/types/App.d.ts +15 -3
- package/dist/types/App.typecheck.d.ts +6 -0
- package/dist/types/adapters/toolClassification.d.ts +1 -0
- package/dist/types/adapters/transcriptToMessages.d.ts +3 -2
- package/dist/types/code-highlighter.d.ts +6 -0
- package/dist/types/components/BranchPickerPopover.d.ts +3 -1
- package/dist/types/components/ChatEditor.d.ts +2 -0
- package/dist/types/components/ChatPane.d.ts +5 -3
- package/dist/types/components/ConversationSearch.d.ts +18 -0
- package/dist/types/components/GlobalTurnNavigation.d.ts +3 -1
- package/dist/types/components/MessageList.d.ts +10 -2
- package/dist/types/components/MessageTimestamp.d.ts +4 -1
- package/dist/types/components/SplitView.d.ts +3 -1
- package/dist/types/components/WorkspaceSessionProvider.d.ts +2 -0
- package/dist/types/components/artifacts/ArtifactPanel.d.ts +18 -1
- package/dist/types/components/artifacts/SideTaskPanel.d.ts +5 -1
- package/dist/types/components/artifacts/TrajectoryOverview.d.ts +71 -0
- package/dist/types/components/artifacts/TurnCallPromptSelect.d.ts +9 -0
- package/dist/types/components/artifacts/TurnCallsPanel.d.ts +38 -0
- package/dist/types/components/artifacts/TurnOutputs.d.ts +6 -1
- package/dist/types/components/artifacts/loadTurnCalls.d.ts +4 -0
- package/dist/types/components/channels/channel-editor-state.d.ts +9 -3
- package/dist/types/components/conversation-search-i18n.d.ts +6 -0
- package/dist/types/components/dialogs/GitDialog.d.ts +6 -2
- package/dist/types/components/dialogs/GitWorktreesDialog.d.ts +11 -0
- package/dist/types/components/messages/AuthMessage.d.ts +2 -1
- package/dist/types/components/messages/ModelManagementSection.d.ts +3 -2
- package/dist/types/components/messages/PlanExecutionView.d.ts +14 -66
- package/dist/types/components/messages/SettingsMessage.d.ts +2 -2
- package/dist/types/components/messages/ToolFilePreviewButton.d.ts +2 -1
- package/dist/types/components/messages/ToolGroup.d.ts +3 -0
- package/dist/types/components/messages/codeHighlighter.d.ts +7 -0
- package/dist/types/components/messages/taskExecutionIndex.d.ts +80 -0
- package/dist/types/components/panels/EnvironmentPanel.d.ts +2 -1
- package/dist/types/components/sidebar/WorkspaceSection.d.ts +8 -1
- package/dist/types/components/workflow/SessionWorkflowCockpit.d.ts +8 -1
- package/dist/types/components/workflow/SessionWorkflowInspector.d.ts +8 -1
- package/dist/types/components/workflow/session-workflow-model.d.ts +9 -1
- package/dist/types/customization.d.ts +9 -1
- package/dist/types/daemon/session/transcript-page-table.d.ts +1 -1
- package/dist/types/daemon/session/turn-navigation-store.d.ts +32 -0
- package/dist/types/hooks/useMessageNavigation.d.ts +12 -0
- package/dist/types/hooks/useQueuedPrompts.d.ts +4 -1
- package/dist/types/hooks/useTranscriptViewport.d.ts +4 -1
- package/dist/types/index.d.ts +13 -1
- package/dist/types/live/live-presence.d.ts +14 -0
- package/dist/types/live/screen-feed-sampler.d.ts +12 -0
- package/dist/types/live/useLiveBrowserHost.d.ts +7 -0
- package/dist/types/live/useLiveVoice.d.ts +2 -0
- package/dist/types/modelManagement.d.ts +16 -0
- package/dist/types/navigation.d.ts +37 -0
- package/dist/types/trajectory/buildTimeline.d.ts +67 -0
- package/dist/types/trajectory/timelineRange.d.ts +27 -0
- package/dist/types/trajectory/transcriptPageLoader.d.ts +4 -2
- package/dist/types/trajectory/types.d.ts +3 -3
- package/dist/types/trajectory/useTrajectoryWindow.d.ts +55 -17
- package/dist/types/turnCallsContext.d.ts +12 -0
- package/dist/types/utils/navigationUrl.d.ts +21 -0
- package/dist/types/utils/popoverRoom.d.ts +22 -0
- package/dist/types/utils/sessionPath.d.ts +1 -0
- package/package.json +5 -1
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
interface AuthMessageProps {
|
|
2
|
+
allowAdd?: boolean;
|
|
2
3
|
onMessage: (text: string, type?: 'status' | 'error') => void;
|
|
3
4
|
onClose: () => void;
|
|
4
5
|
}
|
|
5
|
-
export declare function AuthMessage({ onMessage, onClose }: AuthMessageProps): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
export declare function AuthMessage({ onMessage, onClose, allowAdd, }: AuthMessageProps): import("react/jsx-runtime").JSX.Element;
|
|
6
7
|
export {};
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { WebShellModelManagementOptions } from '../../modelManagement';
|
|
1
2
|
import type { DaemonModelConfiguration, DaemonModelConfigurationUpdateResult } from '@qwen-code/sdk/daemon';
|
|
2
3
|
import type { DaemonWorkspaceProviderStatus } from '@qwen-code/web-shell/daemon-react-sdk';
|
|
3
4
|
export interface ModelDeleteTarget {
|
|
@@ -6,7 +7,7 @@ export interface ModelDeleteTarget {
|
|
|
6
7
|
modelId: string;
|
|
7
8
|
baseUrl?: string;
|
|
8
9
|
}
|
|
9
|
-
export interface ModelManagementProps {
|
|
10
|
+
export interface ModelManagementProps extends WebShellModelManagementOptions {
|
|
10
11
|
providers: DaemonWorkspaceProviderStatus[];
|
|
11
12
|
configurations?: DaemonModelConfiguration[];
|
|
12
13
|
onUpdateContextWindow?: (key: string, size: number | null) => Promise<DaemonModelConfigurationUpdateResult>;
|
|
@@ -20,4 +21,4 @@ export interface ModelManagementProps {
|
|
|
20
21
|
onDeleteModel: (target: ModelDeleteTarget) => void;
|
|
21
22
|
onAddModel: () => void;
|
|
22
23
|
}
|
|
23
|
-
export declare function ModelManagementSection({ providers, configurations, onUpdateContextWindow, currentModelId, loading, error, busy, onSelectModel, onDeleteModel, onAddModel, }: ModelManagementProps): import("react/jsx-runtime").JSX.Element;
|
|
24
|
+
export declare function ModelManagementSection({ allowAdd, allowDelete, providers, configurations, onUpdateContextWindow, currentModelId, loading, error, busy, onSelectModel, onDeleteModel, onAddModel, }: ModelManagementProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,6 +1,9 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { DaemonSessionTaskStatus } from '@qwen-code/sdk/daemon';
|
|
2
2
|
import type { ACPToolCall, TodoItem } from '../../adapters/types';
|
|
3
|
-
|
|
3
|
+
import { type PlanNodeStatus } from './taskExecutionIndex';
|
|
4
|
+
import type { SessionWorkflowProjection } from '../workflow/session-workflow-model';
|
|
5
|
+
export { createTaskExecutionIndex, getActiveAgents, getActiveAgentsFromIndex, getAttentionAgentStatuses, getAttentionAgentTool, getPlanNodeState, getPlanNodeStateFromIndex, nestedAgentToolsForTool, nestedTasksFromIndex, nestedTasksForTool, todoIdOf, } from './taskExecutionIndex';
|
|
6
|
+
export type { PlanNodeStatus, TaskExecutionIndex } from './taskExecutionIndex';
|
|
4
7
|
/**
|
|
5
8
|
* Status is carried by a glyph as well as a colour so the graph survives
|
|
6
9
|
* colour-blindness, high-contrast mode, and a greyscale screenshot. Every
|
|
@@ -8,73 +11,18 @@ export type PlanNodeStatus = 'running' | 'paused' | 'completed' | 'blocked' | 'i
|
|
|
8
11
|
*/
|
|
9
12
|
export declare const PLAN_STATUS_GLYPH: Record<PlanNodeStatus, string>;
|
|
10
13
|
export declare function layerPlanTodos(todos: readonly TodoItem[]): TodoItem[][];
|
|
11
|
-
export
|
|
12
|
-
rootByToolCallId: ReadonlyMap<string, DaemonSessionAgentTaskStatus>;
|
|
13
|
-
childrenByParentId: ReadonlyMap<string, DaemonSessionAgentTaskStatus[]>;
|
|
14
|
-
nestedByRootId: Map<string, Array<{
|
|
15
|
-
task: DaemonSessionAgentTaskStatus;
|
|
16
|
-
depth: number;
|
|
17
|
-
}>>;
|
|
18
|
-
}
|
|
19
|
-
export declare function createTaskExecutionIndex(tasks: readonly DaemonSessionTaskStatus[]): TaskExecutionIndex;
|
|
20
|
-
export declare function nestedTasksFromIndex(tool: ACPToolCall, taskIndex: TaskExecutionIndex): Array<{
|
|
21
|
-
task: DaemonSessionAgentTaskStatus;
|
|
22
|
-
depth: number;
|
|
23
|
-
}>;
|
|
24
|
-
export declare function nestedTasksForTool(tool: ACPToolCall, tasks: readonly DaemonSessionTaskStatus[]): Array<{
|
|
25
|
-
task: DaemonSessionAgentTaskStatus;
|
|
26
|
-
depth: number;
|
|
27
|
-
}>;
|
|
28
|
-
/**
|
|
29
|
-
* Deliberately uncached. Keying on the tool object would be wrong the moment
|
|
30
|
-
* a reused object gains a sub-tool — `appendSubTool` mutates `subTools` in
|
|
31
|
-
* place — and the only thing standing between that and a stale render is
|
|
32
|
-
* `useMessages`' prefix-reuse rule in another module. The callers' own
|
|
33
|
-
* derivations are memoized, so the repetition this would remove is bounded to
|
|
34
|
-
* a single derivation; a silent wrong subtree is not worth that.
|
|
35
|
-
*/
|
|
36
|
-
export declare function nestedAgentToolsForTool(tool: ACPToolCall): Array<{
|
|
37
|
-
tool: ACPToolCall;
|
|
38
|
-
depth: number;
|
|
39
|
-
}>;
|
|
40
|
-
/**
|
|
41
|
-
* Same agent-status walk as {@link attentionAgentStatuses}, for callers that
|
|
42
|
-
* hold the raw task list instead of a prebuilt index (the cockpit's stats
|
|
43
|
-
* strip, which must tally exactly what the attention queue shows).
|
|
44
|
-
*/
|
|
45
|
-
export declare function getAttentionAgentStatuses(tool: ACPToolCall, tasks: readonly DaemonSessionTaskStatus[]): string[];
|
|
46
|
-
/**
|
|
47
|
-
* One entry per agent the overview strip reports as active, and the single
|
|
48
|
-
* source the workflow inspector summary counts: the live daemon task when
|
|
49
|
-
* one exists, otherwise a transcript-derived stand-in for an in-flight tool
|
|
50
|
-
* call with no live task (the replay shape). The walk mirrors the node
|
|
51
|
-
* badges (executionStatus), so the strip, the badges, and the inspector can
|
|
52
|
-
* never contradict each other. An agent observed through BOTH a live task
|
|
53
|
-
* and a persisted transcript tool counts once (dedup by toolUseId).
|
|
54
|
-
*/
|
|
55
|
-
export declare function getActiveAgents(tools: readonly ACPToolCall[], tasks: readonly DaemonSessionTaskStatus[]): DaemonSessionAgentTaskStatus[];
|
|
56
|
-
/**
|
|
57
|
-
* {@link getActiveAgents} for callers that already hold an index. Building the
|
|
58
|
-
* index is O(tasks); doing it per todo and per tool — as the workflow
|
|
59
|
-
* projection used to — makes the walk O((todos + tools) x tasks) for a result
|
|
60
|
-
* that never varies with the todo or the tool.
|
|
61
|
-
*/
|
|
62
|
-
export declare function getActiveAgentsFromIndex(tools: readonly ACPToolCall[], taskIndex: TaskExecutionIndex): DaemonSessionAgentTaskStatus[];
|
|
63
|
-
export declare function getPlanNodeStateFromIndex(todo: TodoItem, todosById: ReadonlyMap<string, TodoItem>, tools: readonly ACPToolCall[], taskIndex: TaskExecutionIndex): {
|
|
64
|
-
status: PlanNodeStatus;
|
|
65
|
-
attention: boolean;
|
|
66
|
-
};
|
|
67
|
-
export declare function getPlanNodeState(todo: TodoItem, todosById: ReadonlyMap<string, TodoItem>, tools: readonly ACPToolCall[], tasks: readonly DaemonSessionTaskStatus[]): {
|
|
68
|
-
status: PlanNodeStatus;
|
|
69
|
-
attention: boolean;
|
|
70
|
-
};
|
|
71
|
-
/** The plan step a tool call was issued for, when it declares one. */
|
|
72
|
-
export declare function todoIdOf(tool: ACPToolCall): string | undefined;
|
|
73
|
-
export declare function getAttentionAgentTool(tool: ACPToolCall, tasks: readonly DaemonSessionTaskStatus[]): ACPToolCall | undefined;
|
|
74
|
-
export declare function PlanExecutionView({ todos, tools, tasks, onOpenSubagent, hideTitle, selection, showStepDetails, }: {
|
|
14
|
+
export declare function PlanExecutionView({ todos, tools, tasks, projection: sharedProjection, onOpenSubagent, hideTitle, selection, showStepDetails, }: {
|
|
75
15
|
todos: readonly TodoItem[];
|
|
76
16
|
tools: readonly ACPToolCall[];
|
|
77
17
|
tasks: readonly DaemonSessionTaskStatus[];
|
|
18
|
+
/**
|
|
19
|
+
* A host that already derives the workflow projection (the cockpit, which
|
|
20
|
+
* mounts this graph beside the inspector) passes its own, so the whole
|
|
21
|
+
* surface shares one projection — and one task-execution index — per
|
|
22
|
+
* render instead of each component privately rebuilding both. Standalone
|
|
23
|
+
* mounts derive it from `todos` / `tools` / `tasks` here.
|
|
24
|
+
*/
|
|
25
|
+
projection?: SessionWorkflowProjection;
|
|
78
26
|
onOpenSubagent?: (tool: ACPToolCall) => void;
|
|
79
27
|
/**
|
|
80
28
|
* Drop the "Plan execution" caption when the host already titles the region.
|
|
@@ -15,7 +15,7 @@ interface SettingsMessageProps {
|
|
|
15
15
|
chatWidthMode: ChatWidthMode;
|
|
16
16
|
onChatWidthModeChange: (mode: ChatWidthMode) => void;
|
|
17
17
|
/** Model list/add/delete/select, rendered inside the Model category. */
|
|
18
|
-
|
|
18
|
+
modelManagementSectionProps?: ModelManagementProps;
|
|
19
19
|
/** Browser-local remote computer catalog and connection controls. */
|
|
20
20
|
connections?: ReactNode;
|
|
21
21
|
embedded?: boolean;
|
|
@@ -45,5 +45,5 @@ export type FlatRow = {
|
|
|
45
45
|
localKey: 'chatWidth' | 'browserNotifications';
|
|
46
46
|
};
|
|
47
47
|
export declare function nextSettingIdx(rows: FlatRow[], current: number, dir: 1 | -1): number;
|
|
48
|
-
export declare function SettingsMessage({ settingsState, presentation, onLanguageChange, onSubDialog, onThemeChange, chatWidthMode, onChatWidthModeChange,
|
|
48
|
+
export declare function SettingsMessage({ settingsState, presentation, onLanguageChange, onSubDialog, onThemeChange, chatWidthMode, onChatWidthModeChange, modelManagementSectionProps, connections, embedded, initialCategory, }: SettingsMessageProps): import("react/jsx-runtime").JSX.Element;
|
|
49
49
|
export {};
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import type { ACPToolCall } from '../../adapters/types';
|
|
2
2
|
import type { TurnOutputOpenRequest } from '../artifacts/TurnOutputs';
|
|
3
|
-
export declare function ToolFilePreviewButton({ tool, workspaceCwd, onOpen, }: {
|
|
3
|
+
export declare function ToolFilePreviewButton({ tool, workspaceCwd, onOpen, iconOnly, }: {
|
|
4
4
|
tool: ACPToolCall;
|
|
5
5
|
workspaceCwd?: string;
|
|
6
6
|
onOpen?: (request: TurnOutputOpenRequest) => void;
|
|
7
|
+
iconOnly?: boolean;
|
|
7
8
|
}): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -43,6 +43,9 @@ export declare function getToolHeaderKind(tool: ACPToolCall): ToolHeaderKind;
|
|
|
43
43
|
export declare function getActiveTool(tools: ACPToolCall[]): ACPToolCall;
|
|
44
44
|
export declare function formatToolGroupSummary(tools: ACPToolCall[], t: ReturnType<typeof useI18n>['t'], workspaceCwd?: string, summarizeAgents?: boolean): string;
|
|
45
45
|
export declare function formatSingleToolSummary(tool: ACPToolCall, t: ReturnType<typeof useI18n>['t'], workspaceCwd?: string): string;
|
|
46
|
+
export declare function ToolSummaryIcon({ tool }: {
|
|
47
|
+
tool: ACPToolCall;
|
|
48
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
46
49
|
export declare function isWebFetchToolName(toolName: string): boolean;
|
|
47
50
|
export declare const ToolLine: import("react").NamedExoticComponent<ToolLineProps>;
|
|
48
51
|
export declare const ToolGroup: import("react").NamedExoticComponent<ToolGroupProps>;
|
|
@@ -23,3 +23,10 @@ export declare function isTooLargeToHighlight(code: string): boolean;
|
|
|
23
23
|
export declare function highlightToHtmlSync(code: string, lang: string, theme: string, persist?: boolean): string | null;
|
|
24
24
|
/** Resets all module-level highlighter state (incl. the HTML cache). Tests only. */
|
|
25
25
|
export declare function __resetForTesting(): void;
|
|
26
|
+
export interface CodeHighlightRequest {
|
|
27
|
+
code: string;
|
|
28
|
+
language: string;
|
|
29
|
+
theme: 'light' | 'dark';
|
|
30
|
+
}
|
|
31
|
+
/** Uses the same engine and cache as transcript code blocks. Null means plain text. */
|
|
32
|
+
export declare function highlightCode({ code, language, theme, }: CodeHighlightRequest): Promise<string | null>;
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
import type { DaemonSessionAgentTaskStatus, DaemonSessionTaskStatus } from '@qwen-code/sdk/daemon';
|
|
2
|
+
import type { ACPToolCall, TodoItem } from '../../adapters/types';
|
|
3
|
+
/**
|
|
4
|
+
* Shared task-execution lookups for the plan surfaces. Extracted from
|
|
5
|
+
* `PlanExecutionView` so the workflow projection (`session-workflow-model`)
|
|
6
|
+
* and the graph (`PlanExecutionView`) both depend on this module instead of
|
|
7
|
+
* on each other, and so one build of the index can be threaded from the
|
|
8
|
+
* projection into every consumer in a single render.
|
|
9
|
+
*/
|
|
10
|
+
export type PlanNodeStatus = 'running' | 'paused' | 'completed' | 'blocked' | 'in_progress' | 'ready';
|
|
11
|
+
export interface TaskExecutionIndex {
|
|
12
|
+
rootByToolCallId: ReadonlyMap<string, DaemonSessionAgentTaskStatus>;
|
|
13
|
+
childrenByParentId: ReadonlyMap<string, DaemonSessionAgentTaskStatus[]>;
|
|
14
|
+
nestedByRootId: Map<string, Array<{
|
|
15
|
+
task: DaemonSessionAgentTaskStatus;
|
|
16
|
+
depth: number;
|
|
17
|
+
}>>;
|
|
18
|
+
}
|
|
19
|
+
export declare function createTaskExecutionIndex(tasks: readonly DaemonSessionTaskStatus[]): TaskExecutionIndex;
|
|
20
|
+
export declare function taskForTool(tool: ACPToolCall, taskIndex: TaskExecutionIndex): DaemonSessionAgentTaskStatus | undefined;
|
|
21
|
+
export declare function executionStatus(tool: ACPToolCall, taskIndex: TaskExecutionIndex): string;
|
|
22
|
+
export declare function nestedTasksFromIndex(tool: ACPToolCall, taskIndex: TaskExecutionIndex): Array<{
|
|
23
|
+
task: DaemonSessionAgentTaskStatus;
|
|
24
|
+
depth: number;
|
|
25
|
+
}>;
|
|
26
|
+
export declare function nestedTasksForTool(tool: ACPToolCall, tasks: readonly DaemonSessionTaskStatus[]): Array<{
|
|
27
|
+
task: DaemonSessionAgentTaskStatus;
|
|
28
|
+
depth: number;
|
|
29
|
+
}>;
|
|
30
|
+
/**
|
|
31
|
+
* Deliberately uncached. Keying on the tool object would be wrong the moment
|
|
32
|
+
* a reused object gains a sub-tool — `appendSubTool` mutates `subTools` in
|
|
33
|
+
* place — and the only thing standing between that and a stale render is
|
|
34
|
+
* `useMessages`' prefix-reuse rule in another module. The callers' own
|
|
35
|
+
* derivations are memoized, so the repetition this would remove is bounded to
|
|
36
|
+
* a single derivation; a silent wrong subtree is not worth that.
|
|
37
|
+
*/
|
|
38
|
+
export declare function nestedAgentToolsForTool(tool: ACPToolCall): Array<{
|
|
39
|
+
tool: ACPToolCall;
|
|
40
|
+
depth: number;
|
|
41
|
+
}>;
|
|
42
|
+
/**
|
|
43
|
+
* Same agent-status walk as {@link attentionAgentStatuses}, for callers that
|
|
44
|
+
* hold the raw task list instead of a prebuilt index (the cockpit's stats
|
|
45
|
+
* strip, which must tally exactly what the attention queue shows).
|
|
46
|
+
*/
|
|
47
|
+
export declare function getAttentionAgentStatuses(tool: ACPToolCall, tasks: readonly DaemonSessionTaskStatus[]): string[];
|
|
48
|
+
/**
|
|
49
|
+
* One entry per agent the overview strip reports as active, and the single
|
|
50
|
+
* source the workflow inspector summary counts: the live daemon task when
|
|
51
|
+
* one exists, otherwise a transcript-derived stand-in for an in-flight tool
|
|
52
|
+
* call with no live task (the replay shape). The walk mirrors the node
|
|
53
|
+
* badges (executionStatus), so the strip, the badges, and the inspector can
|
|
54
|
+
* never contradict each other. An agent observed through BOTH a live task
|
|
55
|
+
* and a persisted transcript tool counts once (dedup by toolUseId).
|
|
56
|
+
*/
|
|
57
|
+
export declare function getActiveAgents(tools: readonly ACPToolCall[], tasks: readonly DaemonSessionTaskStatus[]): DaemonSessionAgentTaskStatus[];
|
|
58
|
+
/**
|
|
59
|
+
* {@link getActiveAgents} for callers that already hold an index. Building the
|
|
60
|
+
* index is O(tasks); doing it per todo and per tool — as the workflow
|
|
61
|
+
* projection used to — makes the walk O((todos + tools) x tasks) for a result
|
|
62
|
+
* that never varies with the todo or the tool.
|
|
63
|
+
*/
|
|
64
|
+
export declare function getActiveAgentsFromIndex(tools: readonly ACPToolCall[], taskIndex: TaskExecutionIndex): DaemonSessionAgentTaskStatus[];
|
|
65
|
+
export declare function getPlanNodeStateFromIndex(todo: TodoItem, todosById: ReadonlyMap<string, TodoItem>, tools: readonly ACPToolCall[], taskIndex: TaskExecutionIndex): {
|
|
66
|
+
status: PlanNodeStatus;
|
|
67
|
+
attention: boolean;
|
|
68
|
+
};
|
|
69
|
+
export declare function getPlanNodeState(todo: TodoItem, todosById: ReadonlyMap<string, TodoItem>, tools: readonly ACPToolCall[], tasks: readonly DaemonSessionTaskStatus[]): {
|
|
70
|
+
status: PlanNodeStatus;
|
|
71
|
+
attention: boolean;
|
|
72
|
+
};
|
|
73
|
+
/** The plan step a tool call was issued for, when it declares one. */
|
|
74
|
+
export declare function todoIdOf(tool: ACPToolCall): string | undefined;
|
|
75
|
+
/**
|
|
76
|
+
* A clickable stand-in for a live agent task that has no transcript tool
|
|
77
|
+
* call, so the graph's nested execution rows can still open its panel.
|
|
78
|
+
*/
|
|
79
|
+
export declare function toolForNestedTask(task: DaemonSessionAgentTaskStatus): ACPToolCall | undefined;
|
|
80
|
+
export declare function getAttentionAgentTool(tool: ACPToolCall, tasks: readonly DaemonSessionTaskStatus[]): ACPToolCall | undefined;
|
|
@@ -26,6 +26,7 @@ interface EnvironmentPanelProps {
|
|
|
26
26
|
items?: readonly WebShellEnvironmentPanelItem[];
|
|
27
27
|
onOpenGitDiff?: () => void;
|
|
28
28
|
onOpenGitCommit?: () => void;
|
|
29
|
+
onOpenGitWorktrees?: () => void;
|
|
29
30
|
onOpenGitLog?: () => void;
|
|
30
31
|
onOpenAgent?: (task: DaemonSessionAgentTaskStatus) => void;
|
|
31
32
|
onOpenAgentWorkflow?: () => void;
|
|
@@ -42,5 +43,5 @@ export type EnvironmentAgentTask = DaemonSessionAgentTaskStatus & {
|
|
|
42
43
|
color?: string;
|
|
43
44
|
lineageState?: 'complete' | 'orphaned' | 'cycle';
|
|
44
45
|
};
|
|
45
|
-
export declare function EnvironmentPanel({ sources, onOpenSource, retrySourceRegistration, floating, hidden, workspaceCwd, gitWorkspaceCwd, gitCwd, branch, gitStatus, tasks, agentTasks, attachments, attachmentsLoading, attachmentsError, onRetryAttachments, artifacts, artifactsLoading, items, onOpenGitDiff, onOpenGitCommit, onOpenGitLog, onOpenAgent, onOpenAgentWorkflow, onOpenTask, onReadImage, onImagePreview, onAttachmentPreview, onAttachmentPreviewError, onOpenArtifact, onDismiss, }: EnvironmentPanelProps): import("react/jsx-runtime").JSX.Element;
|
|
46
|
+
export declare function EnvironmentPanel({ sources, onOpenSource, retrySourceRegistration, floating, hidden, workspaceCwd, gitWorkspaceCwd, gitCwd, branch, gitStatus, tasks, agentTasks, attachments, attachmentsLoading, attachmentsError, onRetryAttachments, artifacts, artifactsLoading, items, onOpenGitDiff, onOpenGitCommit, onOpenGitWorktrees, onOpenGitLog, onOpenAgent, onOpenAgentWorkflow, onOpenTask, onReadImage, onImagePreview, onAttachmentPreview, onAttachmentPreviewError, onOpenArtifact, onDismiss, }: EnvironmentPanelProps): import("react/jsx-runtime").JSX.Element;
|
|
46
47
|
export {};
|
|
@@ -29,6 +29,7 @@ interface WorkspaceSectionProps {
|
|
|
29
29
|
searchQuery?: string;
|
|
30
30
|
expanded?: boolean;
|
|
31
31
|
autoExpandKey?: string;
|
|
32
|
+
forceAutoExpand?: boolean;
|
|
32
33
|
onExpandedChange?: (expanded: boolean) => void;
|
|
33
34
|
renderSessions?: boolean;
|
|
34
35
|
/**
|
|
@@ -41,6 +42,12 @@ interface WorkspaceSectionProps {
|
|
|
41
42
|
renderSession: (session: DaemonSessionSummary, options?: {
|
|
42
43
|
searchSnippet?: string | undefined;
|
|
43
44
|
}) => ReactNode;
|
|
45
|
+
pendingSession?: {
|
|
46
|
+
key: string;
|
|
47
|
+
sessionId?: string;
|
|
48
|
+
sourceId?: string;
|
|
49
|
+
node: ReactNode;
|
|
50
|
+
};
|
|
44
51
|
mapSession?: (session: DaemonSessionSummary) => DaemonSessionSummary;
|
|
45
52
|
showSessionDetails?: boolean;
|
|
46
53
|
/**
|
|
@@ -109,5 +116,5 @@ interface WorkspaceSectionProps {
|
|
|
109
116
|
/** Commit entry for the same picker; the row still opens without it. */
|
|
110
117
|
onOpenCommit?: (workspaceCwd: string) => void;
|
|
111
118
|
}
|
|
112
|
-
export declare function WorkspaceSection({ workspace, remote, renderHeader, client, reloadToken, untrustedLabel, readOnlyLabel, trustToOpenLabel, noSessionsLabel, loadErrorLabel, organizationEnabled, sessionCatalogRequestsEnabled, sessionGroupCatalog, sessionLiveStateEnabled, sourceType, channelGroupingEnabled, ungroupedLabel, searchQuery, expanded: controlledExpanded, autoExpandKey, onExpandedChange, renderSessions, renderSession, mapSession, showSessionDetails, headerActions, overviewEnabled, overviewMenuOpen, overviewItems, gitBranchWanted, sessionStats, onRenameGroup, onDeleteGroup, renameGroupLabel, deleteGroupLabel, groupActionsDisabled, excludePinned, limitSessions, isPinnedSectionMember, onOpenPathLocally, onOpenTerminalLocally, onOpenGitDiff, onOpenCommit, }: WorkspaceSectionProps): import("react/jsx-runtime").JSX.Element;
|
|
119
|
+
export declare function WorkspaceSection({ workspace, remote, renderHeader, client, reloadToken, untrustedLabel, readOnlyLabel, trustToOpenLabel, noSessionsLabel, loadErrorLabel, organizationEnabled, sessionCatalogRequestsEnabled, sessionGroupCatalog, sessionLiveStateEnabled, sourceType, channelGroupingEnabled, ungroupedLabel, searchQuery, expanded: controlledExpanded, autoExpandKey, forceAutoExpand, onExpandedChange, renderSessions, renderSession, pendingSession, mapSession, showSessionDetails, headerActions, overviewEnabled, overviewMenuOpen, overviewItems, gitBranchWanted, sessionStats, onRenameGroup, onDeleteGroup, renameGroupLabel, deleteGroupLabel, groupActionsDisabled, excludePinned, limitSessions, isPinnedSectionMember, onOpenPathLocally, onOpenTerminalLocally, onOpenGitDiff, onOpenCommit, }: WorkspaceSectionProps): import("react/jsx-runtime").JSX.Element;
|
|
113
120
|
export {};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { DaemonSessionTaskStatus } from '@qwen-code/sdk/daemon';
|
|
2
2
|
import type { ACPToolCall, TodoItem } from '../../adapters/types';
|
|
3
|
+
import { type SessionWorkflowProjection } from './session-workflow-model';
|
|
3
4
|
interface SessionWorkflowCockpitProps {
|
|
4
5
|
sessionId: string;
|
|
5
6
|
connected: boolean;
|
|
@@ -8,10 +9,16 @@ interface SessionWorkflowCockpitProps {
|
|
|
8
9
|
todos: readonly TodoItem[];
|
|
9
10
|
tools: readonly ACPToolCall[];
|
|
10
11
|
tasks: readonly DaemonSessionTaskStatus[];
|
|
12
|
+
/**
|
|
13
|
+
* The projection shared by every workflow surface for this render. The app
|
|
14
|
+
* derives it once (it also feeds the inspector beside this cockpit); when
|
|
15
|
+
* absent — a standalone mount, a test — it is derived from the raw props.
|
|
16
|
+
*/
|
|
17
|
+
projection?: SessionWorkflowProjection;
|
|
11
18
|
selectedTodoId?: string;
|
|
12
19
|
onSelectedTodoIdChange: (todoId: string | undefined) => void;
|
|
13
20
|
onBackToChat: () => void;
|
|
14
21
|
onOpenSubagent: (tool: ACPToolCall) => void;
|
|
15
22
|
}
|
|
16
|
-
export declare function SessionWorkflowCockpit({ sessionId, connected, sessionName, workspaceCwd, todos, tools, tasks, selectedTodoId, onSelectedTodoIdChange, onBackToChat, onOpenSubagent, }: SessionWorkflowCockpitProps): import("react/jsx-runtime").JSX.Element;
|
|
23
|
+
export declare function SessionWorkflowCockpit({ sessionId, connected, sessionName, workspaceCwd, todos, tools, tasks, projection: sharedProjection, selectedTodoId, onSelectedTodoIdChange, onBackToChat, onOpenSubagent, }: SessionWorkflowCockpitProps): import("react/jsx-runtime").JSX.Element;
|
|
17
24
|
export {};
|
|
@@ -1,9 +1,16 @@
|
|
|
1
1
|
import type { DaemonSessionArtifact, DaemonSessionTaskStatus } from '@qwen-code/sdk/daemon';
|
|
2
2
|
import type { ACPToolCall, TodoItem } from '../../adapters/types';
|
|
3
|
+
import { type SessionWorkflowProjection } from './session-workflow-model';
|
|
3
4
|
export interface SessionWorkflowInspectorProps {
|
|
4
5
|
todos: readonly TodoItem[];
|
|
5
6
|
tools: readonly ACPToolCall[];
|
|
6
7
|
tasks: readonly DaemonSessionTaskStatus[];
|
|
8
|
+
/**
|
|
9
|
+
* The projection shared by every workflow surface for this render. The app
|
|
10
|
+
* derives it once and hands the same object to the cockpit, the embedded
|
|
11
|
+
* graph and this inspector; when absent it is derived from the raw props.
|
|
12
|
+
*/
|
|
13
|
+
projection?: SessionWorkflowProjection;
|
|
7
14
|
artifacts: readonly DaemonSessionArtifact[];
|
|
8
15
|
selectedTodoId?: string;
|
|
9
16
|
onSelectedTodoIdChange: (todoId: string | undefined) => void;
|
|
@@ -12,4 +19,4 @@ export interface SessionWorkflowInspectorProps {
|
|
|
12
19
|
onOpenArtifact?: (artifactId: string) => void;
|
|
13
20
|
canvasMode?: boolean;
|
|
14
21
|
}
|
|
15
|
-
export declare function SessionWorkflowInspector({ todos, tools, tasks, artifacts, selectedTodoId, onSelectedTodoIdChange, onExpandGraph, onOpenSubagent, onOpenArtifact, canvasMode, }: SessionWorkflowInspectorProps): import("react/jsx-runtime").JSX.Element;
|
|
22
|
+
export declare function SessionWorkflowInspector({ todos, tools, tasks, projection: sharedProjection, artifacts, selectedTodoId, onSelectedTodoIdChange, onExpandGraph, onOpenSubagent, onOpenArtifact, canvasMode, }: SessionWorkflowInspectorProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,10 +1,18 @@
|
|
|
1
1
|
import type { DaemonSessionAgentTaskStatus, DaemonSessionTaskStatus } from '@qwen-code/sdk/daemon';
|
|
2
2
|
import type { ACPToolCall, TodoItem } from '../../adapters/types';
|
|
3
|
-
import { type PlanNodeStatus } from '../messages/
|
|
3
|
+
import { type PlanNodeStatus, type TaskExecutionIndex } from '../messages/taskExecutionIndex';
|
|
4
4
|
export interface SessionWorkflowProjection {
|
|
5
|
+
/**
|
|
6
|
+
* The task execution index this projection was built from, so a surface
|
|
7
|
+
* rendering per-tool live status (the graph's executions) reuses the one
|
|
8
|
+
* build instead of raising its own.
|
|
9
|
+
*/
|
|
10
|
+
taskIndex: TaskExecutionIndex;
|
|
5
11
|
todosById: ReadonlyMap<string, TodoItem>;
|
|
6
12
|
toolsByTaskId: ReadonlyMap<string, ACPToolCall>;
|
|
7
13
|
toolsByTodo: ReadonlyMap<string, readonly ACPToolCall[]>;
|
|
14
|
+
/** Tool calls whose `todo_id` is missing or points outside the plan. */
|
|
15
|
+
unassignedTools: readonly ACPToolCall[];
|
|
8
16
|
agentToolsByTodo: ReadonlyMap<string, readonly ACPToolCall[]>;
|
|
9
17
|
tasksByTool: ReadonlyMap<ACPToolCall, DaemonSessionAgentTaskStatus>;
|
|
10
18
|
states: ReadonlyMap<string, {
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { ArtifactFilter } from './components/artifacts/TurnOutputs';
|
|
1
2
|
import { type CSSProperties, type ComponentType, type ReactNode } from 'react';
|
|
2
3
|
import type { Components, Options } from 'react-markdown';
|
|
3
4
|
import type { ChartRendererRegistry, MarkdownChartLabelOverrides } from '@datafe-open/markdown-chart';
|
|
@@ -10,7 +11,11 @@ import type { WebShellTheme } from './themeContext';
|
|
|
10
11
|
export type MarkdownContentSource = 'assistant' | 'thinking';
|
|
11
12
|
export interface MarkdownRenderContext {
|
|
12
13
|
source: MarkdownContentSource;
|
|
13
|
-
/**
|
|
14
|
+
/**
|
|
15
|
+
* 当前消息的生成态;历史或静态内容为 false。所属 MessageList 空闲
|
|
16
|
+
* (isResponding=false)时,恢复 replay 中残留的 streaming 标记也会被
|
|
17
|
+
* 收口为 false,且已收口的行在会话重新响应时、内容不变的前提下保持收口。
|
|
18
|
+
*/
|
|
14
19
|
isStreaming: boolean;
|
|
15
20
|
}
|
|
16
21
|
export interface WebShellCodeBlockRenderInfo {
|
|
@@ -126,6 +131,8 @@ export type WelcomeHeaderRenderer = (props: WelcomeHeaderProps) => ReactNode;
|
|
|
126
131
|
export type WelcomeFooterRenderer = (props: WelcomeHeaderProps) => ReactNode;
|
|
127
132
|
export type WebShellChatHeaderItem = 'title' | 'environment' | 'rightPanel' | 'tokenUsage' | 'contextUsage';
|
|
128
133
|
export interface WebShellChatHeaderOptions {
|
|
134
|
+
/** Show the mobile-access QR entry in chat headers. Defaults to false. */
|
|
135
|
+
showMobileAccess?: boolean;
|
|
129
136
|
/** Built-in header actions to show. Token and context usage are opt-in. */
|
|
130
137
|
items?: readonly WebShellChatHeaderItem[];
|
|
131
138
|
}
|
|
@@ -494,6 +501,7 @@ export type FooterRenderer = ComponentType<WebShellFooterRenderInfo>;
|
|
|
494
501
|
*/
|
|
495
502
|
export type LoadingPhrasesResolver = (language: string) => readonly string[] | undefined | null;
|
|
496
503
|
export interface WebShellCustomization {
|
|
504
|
+
filterArtifact?: ArtifactFilter;
|
|
497
505
|
artifact?: WebShellArtifactCustomization;
|
|
498
506
|
/** Host-specific label for the Ask User Question free-text choice. */
|
|
499
507
|
askUserFreeTextLabel?: string;
|
|
@@ -118,7 +118,7 @@ export declare class HistoricalTranscriptPageTable {
|
|
|
118
118
|
clearSelection(): void;
|
|
119
119
|
setViewportAnchor(viewportId: string, pageId?: string): void;
|
|
120
120
|
admitBefore(beforeRecordId: string, snapshot: string, response: DaemonSessionTranscriptPage): AdmittedHistoricalTarget | undefined;
|
|
121
|
-
admitAnchor(ordinal: number, turnId: string, snapshot: string, response: DaemonSessionTranscriptPage): AdmittedHistoricalTarget;
|
|
121
|
+
admitAnchor(ordinal: number, turnId: string, snapshot: string, response: DaemonSessionTranscriptPage, targetRecordId?: string): AdmittedHistoricalTarget;
|
|
122
122
|
private admitAnchorPage;
|
|
123
123
|
beginBoundaryLoad(rangeId: string, direction: BoundaryDirection): FrozenTranscriptBoundaryRequest | undefined;
|
|
124
124
|
reopenLiveBoundary(rangeId: string, beforeRecordId: string, snapshot: string): void;
|
|
@@ -5,6 +5,35 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import type { DaemonEvent, DaemonSessionTranscriptPage, DaemonSessionTranscriptPageOptions, DaemonSessionTurnIndexEntry, DaemonSessionTurnIndexPage, DaemonSessionTurnIndexPageOptions, DaemonTranscriptBlock } from '@qwen-code/sdk/daemon';
|
|
7
7
|
import { type HistoricalTranscriptPage, type HistoricalTranscriptRange, type HistoricalViewportRange, type MaterializedTranscriptPage } from './transcript-page-table.js';
|
|
8
|
+
export interface ConversationSearchHit {
|
|
9
|
+
sessionId: string;
|
|
10
|
+
snapshot: string;
|
|
11
|
+
revision: number;
|
|
12
|
+
recordId: string;
|
|
13
|
+
liveBlockId?: string;
|
|
14
|
+
turnId: string;
|
|
15
|
+
turnOrdinal: number;
|
|
16
|
+
role: 'user' | 'assistant';
|
|
17
|
+
snippet: string;
|
|
18
|
+
matchStart: number;
|
|
19
|
+
matchEnd: number;
|
|
20
|
+
}
|
|
21
|
+
export interface ConversationSearchResult {
|
|
22
|
+
hits: ConversationSearchHit[];
|
|
23
|
+
messageCount: number;
|
|
24
|
+
matchCount: number;
|
|
25
|
+
complete: boolean;
|
|
26
|
+
truncated: boolean;
|
|
27
|
+
}
|
|
28
|
+
export interface ConversationSearchOptions extends HistoryViewportRequest {
|
|
29
|
+
onProgress?: (result: ConversationSearchResult) => void;
|
|
30
|
+
stopAfterMessages?: number;
|
|
31
|
+
}
|
|
32
|
+
export declare function createConversationSearchSnippet(text: string, query: string): {
|
|
33
|
+
snippet: string;
|
|
34
|
+
matchStart: number;
|
|
35
|
+
matchEnd: number;
|
|
36
|
+
} | undefined;
|
|
8
37
|
export interface DaemonTurnIndexPage {
|
|
9
38
|
start: number;
|
|
10
39
|
end: number;
|
|
@@ -94,6 +123,9 @@ export interface HistoryViewportRequest {
|
|
|
94
123
|
isCurrent(): boolean;
|
|
95
124
|
}
|
|
96
125
|
export interface DaemonHistoryNavigationStore extends DaemonTurnNavigationStore {
|
|
126
|
+
scanConversation(query: string, options: ConversationSearchOptions): Promise<ConversationSearchResult>;
|
|
127
|
+
resolveMessageRecord(recordId: string, request: HistoryViewportRequest): Promise<ConversationSearchHit | undefined>;
|
|
128
|
+
locateViewportSearchHit(hit: ConversationSearchHit, request: HistoryViewportRequest, releaseAnchor: () => void): Promise<DaemonTurnLocation>;
|
|
97
129
|
locateViewportOrdinal(ordinal: number, request: HistoryViewportRequest, releaseAnchor: () => void): Promise<DaemonTurnLocation>;
|
|
98
130
|
getViewportSnapshot(): DaemonHistoryViewportSnapshot;
|
|
99
131
|
captureLiveBoundary(): LiveHistoryBoundary;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { type RefObject } from 'react';
|
|
2
|
+
import type { MessageListHandle } from '../components/MessageList';
|
|
3
|
+
export interface WebShellMessageNavigationRequest {
|
|
4
|
+
sessionId: string;
|
|
5
|
+
/** JSONL 持久化记录 ID,不是渲染块 ID、摘要或时间戳。 */
|
|
6
|
+
recordId: string;
|
|
7
|
+
signal?: AbortSignal;
|
|
8
|
+
}
|
|
9
|
+
export type WebShellMessageNavigationResult = {
|
|
10
|
+
status: 'located' | 'not_found' | 'not_ready' | 'session_mismatch' | 'unsupported' | 'cancelled' | 'error';
|
|
11
|
+
};
|
|
12
|
+
export declare function useMessageNavigation(messageListRef: RefObject<MessageListHandle | null>, active?: boolean): ({ sessionId, recordId, signal, }: WebShellMessageNavigationRequest) => Promise<WebShellMessageNavigationResult>;
|
|
@@ -13,6 +13,9 @@ interface RefBox<T> {
|
|
|
13
13
|
current: T;
|
|
14
14
|
}
|
|
15
15
|
interface UseQueuedPromptsArgs {
|
|
16
|
+
/** Synchronous caller policy, checked again immediately before SDK dispatch.
|
|
17
|
+
* Return a message to reject locally; undefined permits dispatch. */
|
|
18
|
+
getPromptDispatchError?: (text: string) => string | undefined;
|
|
16
19
|
connected: boolean;
|
|
17
20
|
writeBlocked?: boolean;
|
|
18
21
|
runtimeStopped?: boolean;
|
|
@@ -71,5 +74,5 @@ export interface UseQueuedPromptsResult {
|
|
|
71
74
|
editLastQueuedPrompt: () => boolean;
|
|
72
75
|
clearQueuedPrompts: () => boolean;
|
|
73
76
|
}
|
|
74
|
-
export declare function useQueuedPrompts({ connected, writeBlocked, runtimeStopped, sessionId, workspaceCwd, clientId, canMutateMidTurn, canQueryMidTurn, canInjectMidTurnMedia, workspaceFileActions, streamingState, sessionHasActivePrompt, holdQueuedPromptsLocally, sessionActions, store, editorRef, reportError, t, }: UseQueuedPromptsArgs): UseQueuedPromptsResult;
|
|
77
|
+
export declare function useQueuedPrompts({ getPromptDispatchError, connected, writeBlocked, runtimeStopped, sessionId, workspaceCwd, clientId, canMutateMidTurn, canQueryMidTurn, canInjectMidTurnMedia, workspaceFileActions, streamingState, sessionHasActivePrompt, holdQueuedPromptsLocally, sessionActions: unguardedSessionActions, store, editorRef, reportError, t, }: UseQueuedPromptsArgs): UseQueuedPromptsResult;
|
|
75
78
|
export {};
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import { type Translator } from '../adapters/localizedMessages';
|
|
7
7
|
import type { Message } from '../adapters/types';
|
|
8
|
+
import type { ConversationSearchHit } from '../daemon/session/turn-navigation-store';
|
|
8
9
|
export declare function useTranscriptViewport(liveMessages: Message[], t: Translator): {
|
|
9
10
|
navigation: import("..").DaemonTurnNavigationSnapshot;
|
|
10
11
|
store: import("../daemon/session/turn-navigation-store").DaemonHistoryNavigationStore;
|
|
@@ -12,10 +13,12 @@ export declare function useTranscriptViewport(liveMessages: Message[], t: Transl
|
|
|
12
13
|
blockId: string;
|
|
13
14
|
token: number;
|
|
14
15
|
} | undefined;
|
|
15
|
-
selectOrdinal: (ordinal: number) => Promise<
|
|
16
|
+
selectOrdinal: (ordinal: number, hit?: ConversationSearchHit, isCurrent?: () => boolean) => Promise<boolean | "cancelled">;
|
|
17
|
+
selectSearchHit: (hit: ConversationSearchHit, isCurrent?: () => boolean) => Promise<boolean | "cancelled">;
|
|
16
18
|
cancelSelection: () => void;
|
|
17
19
|
continueLive: (blockId?: string) => void;
|
|
18
20
|
messages: import("../adapters/messageTypes").DaemonMessage[];
|
|
21
|
+
blocks: import("@qwen-code/sdk/daemon").DaemonTranscriptBlock[] | undefined;
|
|
19
22
|
toolSources: Map<string, string>;
|
|
20
23
|
historical: boolean;
|
|
21
24
|
viewKey: string;
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import type { WebShellUrlNavigationOptions } from './navigation';
|
|
2
|
+
export type { WebShellUrlNavigationOptions, WebShellPage } from './navigation';
|
|
1
3
|
import { type DaemonProductSessionContext } from '@qwen-code/web-shell/daemon-react-sdk';
|
|
2
4
|
import { type WebShellProps } from './App';
|
|
3
5
|
import { type WebShellBrowserNotificationsOptions } from './browser-turn-notifications';
|
|
@@ -6,6 +8,12 @@ export type { WebShellTranscriptProps } from './components/WebShellTranscript';
|
|
|
6
8
|
export * from './daemon-react-sdk';
|
|
7
9
|
export type { WebShellBrowserNotificationsOptions } from './browser-turn-notifications';
|
|
8
10
|
export interface WebShellWithProvidersProps extends WebShellProps {
|
|
11
|
+
/**
|
|
12
|
+
* Opt in to URL routing. Explicit initial session target props override the
|
|
13
|
+
* URL; later target prop changes replace it. Stop host history writes when
|
|
14
|
+
* enabled. Omit to keep host-owned navigation. basePath defaults to root.
|
|
15
|
+
*/
|
|
16
|
+
urlNavigation?: WebShellUrlNavigationOptions;
|
|
9
17
|
/** Connect browser notifications with optional branding and an initial preference (off by default). */
|
|
10
18
|
browserNotifications?: WebShellBrowserNotificationsOptions;
|
|
11
19
|
/** Daemon API base URL. Defaults to the browser origin when omitted. */
|
|
@@ -62,8 +70,12 @@ export type { ComposerToolbarAction } from './components/ChatEditor';
|
|
|
62
70
|
export type { CodeBlockRenderer, MarkdownContentSource, MarkdownTableMode, MarkdownRenderContext, ToolHeaderExtraRenderer, ToolHeaderExtraRenderInfo, ToolHeaderKind, ComposerTagClickHandler, ComposerTagRenderer, AssistantTurnFooterRenderer, UserMessageContentRenderer, UserMessageContentRenderInfo, UserMessageContentParser, ComposerHeaderRenderer, ComposerFooterRenderer, ComposerToolbarStartRenderer, ComposerToolbarRightRenderer, WebShellAtItemRenderInfo, WebShellAtItemRenderer, WebShellComposerApi, WebShellBuiltinComposerTagKind, WebShellBuiltinAtProviderId, WebShellBuiltinAtProvidersConfig, WebShellComposerInput, WebShellComposerTag, WebShellComposerTagIconMap, WebShellComposerTagKind, WebShellComposerTagOptions, WebShellComposerTagPlacement, WebShellComposerToolbarRenderInfo, WebShellComposerToolbarStartRenderInfo, WebShellComposerToolbarRightRenderInfo, WebShellComposerTextOptions, WelcomeFooterRenderer, WelcomeHeaderRenderer, ChatHeaderRenderer, ChatHeaderRenderInfo, WebShellChatHeaderItem, WebShellChatHeaderOptions, WebShellRightPanelItem, WebShellRightPanelOptions, WebShellEnvironmentPanelItem, WebShellEnvironmentPanelOptions, WebShellFooterRenderInfo, FooterRenderer, LoadingPhrasesResolver, WebShellAtProviderTab, WebShellAtItem, WebShellAtProvider, WebShellBottomStatusItem, WebShellCodeBlockRenderInfo, WebShellMarkdownChartCustomization, WebShellMarkdownCustomization, WebShellFootnote, WebShellSource, WebShellSourceReference, WebShellSourceIconResolver, WebShellFootnoteIconResolver, WebShellFootnotePreviewInfo, WebShellFootnotePreviewHandle, WebShellFootnotePreviewMount, WebShellAssistantMessageInfo, WebShellAssistantTurnOutcome, WebShellAssistantTurnSettledEvent, WebShellAssistantTurnFooterRenderInfo, ArtifactImageRenderer, WebShellArtifactCustomization, WebShellIconSource, WebShellTaskInfo, WebShellUserMessagePart, WebShellAgentTask, WebShellShellTask, WebShellMonitorTask, WebShellWorkflowTask, WebShellPreparedSubmit, WebShellSubmitSnapshot, WebShellSessionArtifactsChange, WebShellSessionArtifactsChangeReason, WebShellModelInfo, WebShellSkillInfo, WebShellAssistantFeedbackInfo, WebShellAssistantFeedbackOptions, WebShellAssistantFeedbackRating, WebShellAssistantFeedbackUserMessage, AssistantFeedbackHandler, } from './customization';
|
|
63
71
|
export type { WelcomeHeaderProps } from './components/WelcomeHeader';
|
|
64
72
|
export type { PaneHeaderActionsInfo, PaneHeaderActionsRenderer, } from './components/ChatPane';
|
|
65
|
-
export type { TurnOutputKind, TurnOutputOpenRequest, } from './components/artifacts/TurnOutputs';
|
|
73
|
+
export type { ArtifactFilter, TurnOutputKind, TurnOutputOpenRequest, } from './components/artifacts/TurnOutputs';
|
|
66
74
|
export { ECHARTS_FULLDATA_LANGUAGE, EchartsFullDataBlock, createMarkdownChartRegistry, createEchartsFullDataRenderer, } from './components/messages/MarkdownChartRenderer';
|
|
67
75
|
export type { DatasetCell, EchartsFullDataBlockProps, EchartsFullDataOption, EchartsFullDataRefMeta, EchartsFullDataRefResolver, EchartsFullDataResolvedDataset, EchartsFullDataRendererOptions, EchartsInstance, EchartsRuntime, EchartsRuntimeLoader, } from './components/messages/MarkdownChartRenderer';
|
|
68
76
|
export { WEB_SHELL_SETTING_ITEM_IDS } from './settings';
|
|
69
77
|
export type { WebShellSettingItemId, WebShellSettingsOptions, } from './settings';
|
|
78
|
+
export type { WebShellModelManagementOptions } from './modelManagement';
|
|
79
|
+
export type { WebShellMessageNavigationRequest, WebShellMessageNavigationResult, } from './hooks/useMessageNavigation';
|
|
80
|
+
export { highlightCode } from './components/messages/codeHighlighter';
|
|
81
|
+
export type { CodeHighlightRequest } from './components/messages/codeHighlighter';
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2025 Qwen
|
|
4
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
+
*/
|
|
6
|
+
import type { DaemonClient, DaemonLiveStatus } from '@qwen-code/sdk/daemon';
|
|
7
|
+
export interface LivePresence {
|
|
8
|
+
callId?: string;
|
|
9
|
+
state: 'connecting' | DaemonLiveStatus['state'];
|
|
10
|
+
coordinator?: DaemonLiveStatus['coordinator'];
|
|
11
|
+
}
|
|
12
|
+
export declare function setLivePresence(client: DaemonClient, presence: LivePresence | undefined): void;
|
|
13
|
+
export declare function getLivePresence(client: DaemonClient): LivePresence | undefined;
|
|
14
|
+
export declare function useLivePresence(client: DaemonClient): LivePresence | undefined;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Qwen Team
|
|
4
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
+
*/
|
|
6
|
+
import type { LiveScreenFrame } from './screen-share';
|
|
7
|
+
export declare function sampleScreen(options: {
|
|
8
|
+
grab: () => Promise<LiveScreenFrame>;
|
|
9
|
+
canSend: () => boolean;
|
|
10
|
+
send: (image: string) => void;
|
|
11
|
+
onError: (error: unknown) => void;
|
|
12
|
+
}): () => void;
|
|
@@ -76,6 +76,13 @@ export interface UseLiveBrowserHostResult {
|
|
|
76
76
|
/** Must run inside a user gesture: it asks which screen to share. */
|
|
77
77
|
startSharingScreen: () => Promise<void>;
|
|
78
78
|
stopSharingScreen: () => void;
|
|
79
|
+
screenFeed: LiveScreenFeedState;
|
|
80
|
+
}
|
|
81
|
+
export interface LiveScreenFeedState {
|
|
82
|
+
supported: boolean;
|
|
83
|
+
feedId?: string;
|
|
84
|
+
phase: 'idle' | 'starting' | 'streaming' | 'stopped' | 'error';
|
|
85
|
+
message?: string;
|
|
79
86
|
}
|
|
80
87
|
export interface LiveScreenShareState {
|
|
81
88
|
/** False where `getDisplayMedia` is unavailable, so the share is never offered. */
|
|
@@ -16,6 +16,8 @@ export interface UseLiveVoiceResult {
|
|
|
16
16
|
loading: boolean;
|
|
17
17
|
mutating: boolean;
|
|
18
18
|
refresh: () => Promise<void>;
|
|
19
|
+
begin: () => void;
|
|
20
|
+
cancelPending: () => void;
|
|
19
21
|
start: (mode?: 'resume' | 'new') => Promise<void>;
|
|
20
22
|
stop: () => Promise<void>;
|
|
21
23
|
setMute: (update: DaemonLiveMuteUpdate) => Promise<void>;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/** WebShell interaction controls only; daemon APIs and external provisioning remain available. */
|
|
2
|
+
export interface WebShellModelManagementOptions {
|
|
3
|
+
/** Allow provider/model setup, including /auth. Defaults to true. */
|
|
4
|
+
allowAdd?: boolean;
|
|
5
|
+
/** Allow model deletion. Defaults to true. */
|
|
6
|
+
allowDelete?: boolean;
|
|
7
|
+
}
|
|
8
|
+
export declare function resolveModelManagement(options?: WebShellModelManagementOptions): Required<WebShellModelManagementOptions>;
|
|
9
|
+
/** The command identity a session's command snapshot carries per entry. */
|
|
10
|
+
export interface ModelSetupCommandInfo {
|
|
11
|
+
name: string;
|
|
12
|
+
source?: string;
|
|
13
|
+
altNames?: readonly string[];
|
|
14
|
+
}
|
|
15
|
+
export declare function isModelCommandSnapshotReady(commands?: readonly ModelSetupCommandInfo[]): boolean;
|
|
16
|
+
export declare function isModelSetupCommand(input: string, commands?: readonly ModelSetupCommandInfo[]): boolean;
|