@qwen-code/web-shell 0.27.4 → 0.28.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (106) hide show
  1. package/dist/{PierreFilePreview-BMd8Nqyr.js → PierreFilePreview-D6shMVrF.js} +1 -1
  2. package/dist/{SpreadsheetPreview-MnZX4z-A.js → SpreadsheetPreview-CI7hXBn_.js} +11 -11
  3. package/dist/{WorkspaceFileBrowser-CvJS8MdL.js → WorkspaceFileBrowser-D2lUYsk2.js} +2 -2
  4. package/dist/agents-route-Cekk3UIP.js +1746 -0
  5. package/dist/daemon-react-sdk.js +1 -1
  6. package/dist/{index-ENe4NzKy.js → index-BNap2Fh4.js} +63368 -61131
  7. package/dist/index.js +3 -3
  8. package/dist/sw.js +1 -1
  9. package/dist/transcript.js +10397 -10160
  10. package/dist/types/adapters/toolClassification.d.ts +2 -1
  11. package/dist/types/browser-notifications/messages.d.ts +1 -0
  12. package/dist/types/browser-notifications/messages.transcript-stub.d.ts +1 -0
  13. package/dist/types/components/BranchPickerPopover.d.ts +11 -1
  14. package/dist/types/components/ChatContextHeader.d.ts +5 -1
  15. package/dist/types/components/ChatEditor.d.ts +4 -0
  16. package/dist/types/components/GoalStatusStrip.d.ts +14 -2
  17. package/dist/types/components/LocalFilesControl.d.ts +40 -1
  18. package/dist/types/components/ManagedLocalFilesControl.d.ts +3 -1
  19. package/dist/types/components/MessageItem.d.ts +2 -0
  20. package/dist/types/components/MessageList.d.ts +1 -0
  21. package/dist/types/components/ReportedArtifactRegistration.d.ts +25 -0
  22. package/dist/types/components/ToastHost.d.ts +27 -1
  23. package/dist/types/components/artifacts/ArtifactPanel.d.ts +11 -1
  24. package/dist/types/components/artifacts/ChangeOverviewPanel.d.ts +4 -0
  25. package/dist/types/components/artifacts/change-overview.d.ts +95 -0
  26. package/dist/types/components/artifacts/files-messages.d.ts +33 -0
  27. package/dist/types/components/artifacts/files-messages.transcript-stub.d.ts +1 -0
  28. package/dist/types/components/artifacts/token-usage-messages.d.ts +1 -0
  29. package/dist/types/components/artifacts/token-usage-messages.transcript-stub.d.ts +1 -0
  30. package/dist/types/components/artifacts/useChangeOverview.d.ts +21 -0
  31. package/dist/types/components/channels/channel-events-messages.d.ts +1 -0
  32. package/dist/types/components/dialogs/GoalsDialog.d.ts +2 -1
  33. package/dist/types/components/managed/generated/managed-agent-api.d.ts +1 -1
  34. package/dist/types/components/managed/managed-diagnostics-messages.d.ts +167 -167
  35. package/dist/types/components/managed/managed-extension-messages.d.ts +1 -0
  36. package/dist/types/components/managed/managed-lifecycle-messages.d.ts +40 -0
  37. package/dist/types/components/managed/managed-lifecycle-messages.transcript-stub.d.ts +1 -0
  38. package/dist/types/components/managed/managed-mcp-messages.d.ts +1 -0
  39. package/dist/types/components/managed/managed-mcp-messages.transcript-stub.d.ts +1 -0
  40. package/dist/types/components/managed/managed-recovery-messages.d.ts +1 -0
  41. package/dist/types/components/managed/managed-task-messages.d.ts +1 -0
  42. package/dist/types/components/managed/managed-task-messages.transcript-stub.d.ts +1 -0
  43. package/dist/types/components/managed/managed-workspace-messages.d.ts +1 -0
  44. package/dist/types/components/managed/managed-workspace-messages.transcript-stub.d.ts +1 -0
  45. package/dist/types/components/message-deletion-messages.d.ts +1 -0
  46. package/dist/types/components/message-deletion-messages.transcript-stub.d.ts +1 -0
  47. package/dist/types/components/messages/AssistantMessage.d.ts +2 -0
  48. package/dist/types/components/messages/HookStatistics.d.ts +4 -0
  49. package/dist/types/components/messages/HookStatistics.transcript-stub.d.ts +4 -0
  50. package/dist/types/components/messages/hook-statistics-context.d.ts +13 -0
  51. package/dist/types/components/messages/hook-statistics-turns.d.ts +3 -0
  52. package/dist/types/components/messages/session-link.d.ts +1 -0
  53. package/dist/types/components/panels/EnvironmentPanel.d.ts +7 -1
  54. package/dist/types/components/sidebar/ActivityDateSessions.d.ts +22 -0
  55. package/dist/types/components/sidebar/SessionGroupSection.d.ts +4 -2
  56. package/dist/types/components/sidebar/SessionSortMenu.d.ts +15 -1
  57. package/dist/types/components/sidebar/activity-messages.d.ts +1 -0
  58. package/dist/types/components/sidebar/activity-model.d.ts +1 -1
  59. package/dist/types/components/workspace-agents/add-runtime-dialog.d.ts +13 -5
  60. package/dist/types/components/workspace-agents/messages.d.ts +1 -0
  61. package/dist/types/components/workspace-agents/messages.transcript-stub.d.ts +1 -0
  62. package/dist/types/customization.d.ts +10 -2
  63. package/dist/types/daemon/session/types.d.ts +19 -2
  64. package/dist/types/hooks/useComposerCore.d.ts +18 -0
  65. package/dist/types/hooks/useSessionArtifacts.d.ts +1 -2
  66. package/dist/types/i18n-ru-part1.d.ts +1 -0
  67. package/dist/types/i18n-ru-part1.transcript-stub.d.ts +12 -0
  68. package/dist/types/i18n-ru-part2.d.ts +1 -0
  69. package/dist/types/i18n-ru-part2.transcript-stub.d.ts +12 -0
  70. package/dist/types/i18n-ru-part3.d.ts +1 -0
  71. package/dist/types/i18n-ru-part3.transcript-stub.d.ts +12 -0
  72. package/dist/types/i18n-ru-part4.d.ts +1 -0
  73. package/dist/types/i18n-ru-part4.transcript-stub.d.ts +12 -0
  74. package/dist/types/i18n-ru-part5.d.ts +1 -0
  75. package/dist/types/i18n-ru-part5.transcript-stub.d.ts +12 -0
  76. package/dist/types/i18n-ru-part6.d.ts +1 -0
  77. package/dist/types/i18n-ru-part6.transcript-stub.d.ts +12 -0
  78. package/dist/types/i18n-ru-remainder.d.ts +6 -0
  79. package/dist/types/i18n-ru-remainder.transcript-stub.d.ts +11 -0
  80. package/dist/types/i18n.d.ts +6 -0
  81. package/dist/types/live/messages.d.ts +1 -0
  82. package/dist/types/live/messages.transcript-stub.d.ts +1 -0
  83. package/dist/types/local-files/useLocalFilesBridge.d.ts +7 -1
  84. package/dist/types/local-files/useManagedLocalFilesBridge.d.ts +5 -1
  85. package/dist/types/mcp-app/messages.d.ts +1 -0
  86. package/dist/types/mcp-app/messages.transcript-stub.d.ts +1 -0
  87. package/dist/types/session-catalog/session-catalog-hooks.d.ts +4 -1
  88. package/dist/types/settings/messages.d.ts +1 -0
  89. package/dist/types/settings/messages.transcript-stub.d.ts +1 -0
  90. package/dist/types/trajectory/execution-messages.d.ts +1 -0
  91. package/dist/types/trajectory/execution-messages.transcript-stub.d.ts +1 -0
  92. package/dist/types/trajectory/filter-messages.d.ts +1 -0
  93. package/dist/types/trajectory/filter-messages.transcript-stub.d.ts +1 -0
  94. package/dist/types/trajectory/project-trajectory-lifecycle.d.ts +1 -1
  95. package/dist/types/trajectory/trajectory-live-store.d.ts +3 -1
  96. package/dist/types/trajectory/window-messages.d.ts +1 -0
  97. package/dist/types/trajectory/window-messages.transcript-stub.d.ts +1 -0
  98. package/dist/types/utils/gitModeIntent.d.ts +14 -4
  99. package/dist/types/utils/plural.d.ts +5 -0
  100. package/dist/types/voice/VoiceButton.d.ts +9 -1
  101. package/dist/types/voice/messages.d.ts +1 -0
  102. package/dist/types/voice/messages.transcript-stub.d.ts +1 -0
  103. package/dist/types/voice/useVoiceCapture.d.ts +8 -0
  104. package/dist/{useDaemonMidTurnInjected-BCExZTLK.js → useDaemonMidTurnInjected-FRZ0JLKH.js} +11301 -5741
  105. package/package.json +1 -1
  106. package/dist/agents-route-BYqfB9LM.js +0 -1727
@@ -0,0 +1,13 @@
1
+ import type { HookTurnPage, DaemonSessionTurnHooksPageOptions } from '@qwen-code/sdk/daemon';
2
+ import type { DaemonTurnNavigationStore } from '../../daemon/session/turn-navigation-store.js';
3
+ export interface HookStatisticsTurn {
4
+ sessionId: string;
5
+ promptId?: string;
6
+ recordId?: string;
7
+ }
8
+ export interface HookStatisticsSource {
9
+ sessionId: string;
10
+ navigation: DaemonTurnNavigationStore;
11
+ readPage(promptId: string, options: DaemonSessionTurnHooksPageOptions): Promise<HookTurnPage>;
12
+ }
13
+ export declare const HookStatisticsContext: import("react").Context<HookStatisticsSource | undefined>;
@@ -0,0 +1,3 @@
1
+ import type { Message } from '../../adapters/types';
2
+ import type { HookStatisticsTurn } from './hook-statistics-context';
3
+ export declare function collectHookStatisticsTurns(messages: readonly Message[], sessionId: string): ReadonlyMap<string, HookStatisticsTurn>;
@@ -0,0 +1 @@
1
+ export declare function openSessionLink(target: string): void;
@@ -24,6 +24,12 @@ interface EnvironmentPanelProps {
24
24
  onRetryAttachments?: () => void;
25
25
  artifacts?: readonly DaemonSessionArtifact[];
26
26
  artifactsLoading?: boolean;
27
+ /**
28
+ * Monotonic counter bumped by the header artifact entry. Each change forces
29
+ * the artifacts section open, so clicking the entry reveals the list even
30
+ * when the user had collapsed the section (the panel hides, not unmounts).
31
+ */
32
+ artifactsExpandSignal?: number;
27
33
  items?: readonly WebShellEnvironmentPanelItem[];
28
34
  onOpenGitDiff?: () => void;
29
35
  onOpenGitCommit?: () => void;
@@ -49,5 +55,5 @@ export type EnvironmentAgentTask = DaemonSessionAgentTaskStatus & {
49
55
  * off the same set, so the dot cannot promise a row the panel shows settled.
50
56
  */
51
57
  export declare function isTaskInProgress(status: DaemonSessionTaskWithWorkflowStatus['status']): boolean;
52
- export declare function EnvironmentPanel({ sources, onOpenSource, retrySourceRegistration, floating, hidden, workspaceCwd, gitWorkspaceCwd, gitCwd, gitSessionId, 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;
58
+ export declare function EnvironmentPanel({ sources, onOpenSource, retrySourceRegistration, floating, hidden, workspaceCwd, gitWorkspaceCwd, gitCwd, gitSessionId, branch, gitStatus, tasks, agentTasks, attachments, attachmentsLoading, attachmentsError, onRetryAttachments, artifacts, artifactsLoading, artifactsExpandSignal, items, onOpenGitDiff, onOpenGitCommit, onOpenGitWorktrees, onOpenGitLog, onOpenAgent, onOpenAgentWorkflow, onOpenTask, onReadImage, onImagePreview, onAttachmentPreview, onAttachmentPreviewError, onOpenArtifact, onDismiss, }: EnvironmentPanelProps): import("react/jsx-runtime").JSX.Element;
53
59
  export {};
@@ -0,0 +1,22 @@
1
+ import { type ReactNode } from 'react';
2
+ import type { DaemonSessionSummary } from '@qwen-code/sdk/daemon';
3
+ import { type ActivityEntry } from './activity-model';
4
+ import type { SessionSort } from './SessionSortMenu';
5
+ export type ActivityDateGroupId = 'today' | 'thisWeek' | 'last30Days' | 'older';
6
+ export declare function groupActivityDateSessions(entries: readonly ActivityEntry[], sortBy: SessionSort, now?: number): Array<{
7
+ id: ActivityDateGroupId;
8
+ entries: ActivityEntry[];
9
+ }>;
10
+ interface ActivityDateSessionsProps {
11
+ entries: readonly ActivityEntry[];
12
+ sortBy: SessionSort;
13
+ loading: boolean;
14
+ unavailable: boolean;
15
+ hasMore: boolean;
16
+ onRetry: () => void;
17
+ renderSession: (entry: ActivityEntry) => ReactNode;
18
+ editingSessionIdentity?: string | null;
19
+ sessionIdentity: (session: DaemonSessionSummary) => string;
20
+ }
21
+ export declare function ActivityDateSessions({ entries, sortBy, loading, unavailable, hasMore, onRetry, renderSession, editingSessionIdentity, sessionIdentity, }: ActivityDateSessionsProps): import("react/jsx-runtime").JSX.Element;
22
+ export {};
@@ -7,7 +7,9 @@ export interface SessionGroupSectionProps {
7
7
  expanded: boolean;
8
8
  color?: DaemonSessionGroupColor;
9
9
  icon?: ReactNode;
10
- children: ReactNode;
10
+ children?: ReactNode;
11
+ itemCount?: number;
12
+ renderChildren?: (visibleCount: number) => ReactNode;
11
13
  onToggle: () => void;
12
14
  onRename?: () => void;
13
15
  onDelete?: () => void;
@@ -16,4 +18,4 @@ export interface SessionGroupSectionProps {
16
18
  actionsDisabled?: boolean;
17
19
  limitSessions?: boolean;
18
20
  }
19
- export declare function SessionGroupSection({ label, count, expanded, color, icon, children, onToggle, onRename, onDelete, renameLabel, deleteLabel, actionsDisabled, limitSessions, }: SessionGroupSectionProps): import("react/jsx-runtime").JSX.Element;
21
+ export declare function SessionGroupSection({ label, count, expanded, color, icon, children, itemCount, renderChildren, onToggle, onRename, onDelete, renameLabel, deleteLabel, actionsDisabled, limitSessions, }: SessionGroupSectionProps): import("react/jsx-runtime").JSX.Element;
@@ -1,8 +1,22 @@
1
+ import type { DaemonWorkspaceCapability } from '@qwen-code/sdk/daemon';
1
2
  export type SessionSort = 'updatedAt' | 'lastUserPromptAt';
3
+ export type SessionGroupBy = 'workspace' | 'activityDate';
4
+ export type WorkspaceFilter = 'all' | 'standalone' | `workspace:${string}`;
2
5
  export declare function readSessionSort(host: string): SessionSort;
3
6
  export declare function writeSessionSort(host: string, sort: SessionSort): void;
4
- export declare function SessionSortMenu({ value, onChange, triggerClassName, }: {
7
+ export declare function readSessionGroupBy(host: string): SessionGroupBy;
8
+ export declare function writeSessionGroupBy(host: string, groupBy: SessionGroupBy): void;
9
+ export declare function readWorkspaceFilter(host: string): WorkspaceFilter;
10
+ export declare function writeWorkspaceFilter(host: string, filter: WorkspaceFilter): void;
11
+ export declare function SessionSortMenu({ value, onChange, workspaceValue, onWorkspaceChange, groupValue, onGroupChange, groupEnabled, workspaces, sortEnabled, triggerClassName, }: {
5
12
  value: SessionSort;
6
13
  onChange: (value: SessionSort) => void;
14
+ workspaceValue: WorkspaceFilter;
15
+ onWorkspaceChange: (value: WorkspaceFilter) => void;
16
+ groupValue: SessionGroupBy;
17
+ onGroupChange: (value: SessionGroupBy) => void;
18
+ groupEnabled: boolean;
19
+ workspaces: readonly DaemonWorkspaceCapability[];
20
+ sortEnabled?: boolean;
7
21
  triggerClassName?: string;
8
22
  }): import("react/jsx-runtime").JSX.Element;
@@ -1,4 +1,5 @@
1
1
  type Message = string | ((vars?: Record<string, string | number>) => string);
2
2
  export declare const ACTIVITY_MESSAGES_EN: Record<string, Message>;
3
3
  export declare const ACTIVITY_MESSAGES_ZH: Record<string, Message>;
4
+ export declare const ACTIVITY_MESSAGES_RU: Record<string, Message>;
4
5
  export {};
@@ -20,7 +20,7 @@ export declare function activityRecency({ session }: ActivityEntry): number;
20
20
  export declare function isActivityUnread(entry: ActivityEntry): boolean;
21
21
  export declare function activityState(entry: ActivityEntry): ActivityState;
22
22
  export declare function activityNeedsAttention(entry: ActivityEntry): boolean;
23
- export declare function isActivityEligible(entry: ActivityEntry, preferences: ActivityPreferences): boolean;
23
+ export declare function isActivityEligible(entry: ActivityEntry, preferences: ActivityPreferences, includeChildren?: boolean): boolean;
24
24
  export declare function openActivitySnapshot(entries: ActivityEntry[], preferences: ActivityPreferences, now?: number): ActivitySnapshot;
25
25
  export declare function updateActivitySnapshot(snapshot: ActivitySnapshot, entries: ActivityEntry[], preferences: ActivityPreferences): ActivitySnapshot;
26
26
  export declare function clearReadActivitySnapshot(snapshot: ActivitySnapshot, entries: ActivityEntry[], preferences: ActivityPreferences): ActivitySnapshot;
@@ -60,21 +60,29 @@ export declare function joinCommands(address: string, join: JoinToken): {
60
60
  /**
61
61
  * A join that went through, as the dialog sees it: whether the computer that
62
62
  * joined saved the connection. A `saveError` means it will not reconnect
63
- * after a restart or a workspace reload. `workspaceCwd`, from a remote
64
- * connect: the workspace the remote answered from, which its runtime
65
- * reports too. `false` is a connect that failed and was already reported
66
- * elsewhere; a failed join throws instead.
63
+ * after a restart or a workspace reload. The notice advises a rerun only on
64
+ * `recorded: true`: the credential then records this join's token, so the
65
+ * same join again goes on. Absent means unknown (an older daemon), and
66
+ * `recorded: false` means the rerun can be refused; neither earns the
67
+ * advice. `workspaceCwd`, from a remote connect: the workspace the remote
68
+ * answered from, which its runtime reports too. `false` is a connect that
69
+ * failed and was already reported elsewhere; a failed join throws instead.
67
70
  */
68
71
  export type RuntimeJoinOutcome = false | {
69
72
  saveError?: string;
70
73
  workspaceCwd?: string;
74
+ recorded?: boolean;
71
75
  };
72
76
  /**
73
77
  * Reads a `hosts/connect` answer, which `hosts/remote-connect` passes on. An
74
- * older daemon sends no `saved` field; it always claimed the save.
78
+ * older daemon sends no `saved` field; it always claimed the save. Nor
79
+ * `recorded`; absent means unknown, not recorded, and the notice then drops
80
+ * the remedy: a released daemon aborts the live connection on a token-bearing
81
+ * rerun and refuses the spent token.
75
82
  */
76
83
  export declare function joinOutcome(answer: unknown): {
77
84
  saveError?: string;
85
+ recorded?: boolean;
78
86
  };
79
87
  /**
80
88
  * The dialog's "I have its address and token" callback over `run`, which
@@ -13,4 +13,5 @@
13
13
  type CollabMessage = string | ((vars?: Record<string, string | number>) => string);
14
14
  export declare const COLLAB_MESSAGES_EN: Record<string, CollabMessage>;
15
15
  export declare const COLLAB_MESSAGES_ZH: Record<string, CollabMessage>;
16
+ export declare const COLLAB_MESSAGES_RU: Record<string, CollabMessage>;
16
17
  export {};
@@ -10,3 +10,4 @@
10
10
  */
11
11
  export declare const COLLAB_MESSAGES_EN: {};
12
12
  export declare const COLLAB_MESSAGES_ZH: {};
13
+ export declare const COLLAB_MESSAGES_RU: {};
@@ -136,14 +136,14 @@ export interface ToolHeaderExtraRenderInfo {
136
136
  export type ToolHeaderExtraRenderer = (info: ToolHeaderExtraRenderInfo) => ReactNode;
137
137
  export type WelcomeHeaderRenderer = (props: WelcomeHeaderProps) => ReactNode;
138
138
  export type WelcomeFooterRenderer = (props: WelcomeHeaderProps) => ReactNode;
139
- export type WebShellChatHeaderItem = 'title' | 'environment' | 'rightPanel' | 'tokenUsage' | 'contextUsage';
139
+ export type WebShellChatHeaderItem = 'title' | 'environment' | 'rightPanel' | 'artifacts' | 'tokenUsage' | 'contextUsage';
140
140
  export interface WebShellChatHeaderOptions {
141
141
  /** Show the mobile-access QR entry in chat headers. Defaults to false. */
142
142
  showMobileAccess?: boolean;
143
143
  /** Built-in header actions to show. Token and context usage are opt-in. */
144
144
  items?: readonly WebShellChatHeaderItem[];
145
145
  }
146
- export type WebShellRightPanelItem = 'files' | 'review' | 'sideTask' | 'terminal' | 'webPreview' | 'trajectory';
146
+ export type WebShellRightPanelItem = 'files' | 'review' | 'sideTask' | 'terminal' | 'webPreview' | 'trajectory' | 'changeOverview';
147
147
  export interface WebShellRightPanelOptions {
148
148
  /** Empty-state actions to show. Defaults to review and sideTask. */
149
149
  items?: readonly WebShellRightPanelItem[];
@@ -181,6 +181,14 @@ export interface ChatHeaderRenderInfo {
181
181
  onOpenTokenUsage?: () => void;
182
182
  /** Opens context usage for the current session, when available. */
183
183
  onOpenContextUsage?: () => void;
184
+ /**
185
+ * Number of session artifacts. Published together with `onOpenArtifacts`
186
+ * only when the artifacts section can actually be opened, so a count never
187
+ * appears without a way to act on it.
188
+ */
189
+ artifactCount?: number;
190
+ /** Opens the environment panel's artifacts section, when available. */
191
+ onOpenArtifacts?: () => void;
184
192
  /** Opens Settings deep-linked to Local Control (Daemon category). */
185
193
  onOpenLocalControlSettings?: () => void;
186
194
  }
@@ -4,7 +4,7 @@
4
4
  * SPDX-License-Identifier: Apache-2.0
5
5
  */
6
6
  import type { ReactNode } from 'react';
7
- import type { CreateSessionRequest, DaemonBranchSessionRequest, DaemonCapabilities, DaemonBackgroundTurn, DaemonEvent, DaemonApprovalMode, DaemonApprovalModeResult, DaemonAvailableCommand, DaemonForkSessionResult, DaemonInputAnnotation, DaemonSessionBtwResult, DaemonSessionGenerationEvent, DaemonSessionAttachmentReference, DaemonSessionAttachmentData, DaemonMidTurnMessageResult, DaemonMidTurnMessagesResult, DaemonRemoveMidTurnMessageResult, DaemonSendMidTurnMessagesNowResult, DaemonPendingPromptsResult, DaemonRemovePendingPromptResult, DaemonSessionContextStatus, DaemonSessionSavedWorkflowDetail, DaemonSessionContextUsageStatus, DaemonSessionRecapResult, DaemonRewindResult, DaemonRewindSnapshotInfo, DaemonSession, DaemonSessionClient, DaemonSessionPrInfo, DaemonSessionSummary, DaemonSessionSupportedCommandsStatus, DaemonSessionTaskRuntimeStatus, DaemonSessionTaskWithWorkflowStatus, DaemonSessionTasksStatus, DaemonSessionWorkflowTaskStatus, DaemonSessionWorkflowTasksStatus, DaemonSessionStatsStatus, DaemonSessionArtifactsEnvelope, DaemonSessionArtifactInput, DaemonSessionArtifactMutationResult, SessionSourceInput, SessionSourcesResult, SessionSourceUpsertResult, SessionSourceRemoveResult, DaemonSkillToggleMutation, DaemonShellCommandResult, DaemonTranscriptBlock, DaemonTranscriptStore, DaemonWorkspaceGitStatus, DaemonWorkspaceProvidersStatus, DaemonStandaloneCreationRecovery, DaemonStandaloneWorkingDirectory, HeartbeatResult, GoalControlRequest, GoalSnapshotV2, GoalStateResponse, PermissionResponse, PromptContentBlock, PromptResult, ReasoningSelection, SessionMetadataResult, SetModelResult } from '@qwen-code/sdk/daemon';
7
+ import type { CreateSessionRequest, DaemonBranchSessionRequest, DaemonWorktreeBranchResult, DaemonWorktreeHandoffResult, DaemonCapabilities, DaemonBackgroundTurn, DaemonEvent, DaemonApprovalMode, DaemonApprovalModeResult, DaemonAvailableCommand, DaemonForkSessionResult, DaemonInputAnnotation, DaemonSessionBtwResult, DaemonSessionGenerationEvent, DaemonSessionAttachmentReference, DaemonSessionAttachmentData, DaemonMidTurnMessageResult, DaemonMidTurnMessagesResult, DaemonRemoveMidTurnMessageResult, DaemonSendMidTurnMessagesNowResult, DaemonPendingPromptsResult, DaemonRemovePendingPromptResult, DaemonSessionContextStatus, DaemonSessionSavedWorkflowDetail, DaemonSessionContextUsageStatus, DaemonSessionRecapResult, DaemonRewindResult, DaemonRewindSnapshotInfo, DaemonSession, DaemonSessionClient, DaemonSessionPrInfo, DaemonSessionSummary, DaemonSessionSupportedCommandsStatus, DaemonSessionTaskRuntimeStatus, DaemonSessionTaskWithWorkflowStatus, DaemonSessionTasksStatus, DaemonSessionWorkflowTaskStatus, DaemonSessionWorkflowTasksStatus, DaemonSessionStatsStatus, DaemonSessionArtifact, DaemonSessionArtifactsEnvelope, DaemonSessionArtifactInput, DaemonSessionArtifactMutationResult, SessionSourceInput, SessionSourcesResult, SessionSourceUpsertResult, SessionSourceRemoveResult, DaemonSkillToggleMutation, DaemonShellCommandResult, DaemonTranscriptBlock, DaemonTranscriptStore, DaemonWorkspaceGitStatus, DaemonWorkspaceProvidersStatus, DaemonStandaloneCreationRecovery, DaemonStandaloneWorkingDirectory, HeartbeatResult, GoalControlRequest, GoalSnapshotV2, GoalStateResponse, PermissionResponse, PromptContentBlock, PromptResult, ReasoningSelection, SessionMetadataResult, SetModelResult } from '@qwen-code/sdk/daemon';
8
8
  export type DaemonConnectionStatus = 'idle' | 'connecting' | 'connected' | 'disconnected' | 'error';
9
9
  export interface DaemonSessionOwnerSnapshot {
10
10
  isCurrent(): boolean;
@@ -104,6 +104,19 @@ export interface DaemonConnectionState {
104
104
  loadingTranscript?: boolean;
105
105
  /** True while replaying buffered events after a reconnect. */
106
106
  catchingUp?: boolean;
107
+ /**
108
+ * Restored artifact snapshot embedded in the load response. Available before
109
+ * the replay renders so a session-level artifact entry can appear early;
110
+ * live updates still come from the gated artifact fetch.
111
+ */
112
+ restoredArtifacts?: DaemonSessionArtifact[];
113
+ /**
114
+ * Session the restoredArtifacts snapshot belongs to. The optimistic session
115
+ * switch moves sessionId before the new restore lands, so consumers must
116
+ * only use the snapshot when this matches the current sessionId — otherwise
117
+ * the previous session's artifacts leak under the new one.
118
+ */
119
+ restoredArtifactsSessionId?: string;
107
120
  error?: string;
108
121
  /** Latest HTTP error status kept for diagnostics; use missingSession for UI. */
109
122
  errorStatus?: number;
@@ -239,7 +252,7 @@ export type DaemonPromptSettledListener = (event: DaemonPromptSettledEvent) => v
239
252
  export type DaemonPromptSettlementSubscribe = (listener: DaemonPromptSettledListener) => () => void;
240
253
  export type DaemonNoticeSeverity = 'info' | 'warning' | 'error';
241
254
  export type DaemonNoticeCategory = 'validation' | 'user_action' | 'connection' | 'protocol' | 'lifecycle' | 'system';
242
- export type DaemonNoticeOperation = 'send_prompt' | 'continue_session' | 'send_shell_command' | 'switch_model' | 'set_reasoning_effort' | 'set_workflow_mode' | 'set_approval_mode' | 'submit_permission' | 'cancel_prompt' | 'attach_session' | 'load_session' | 'resume_session' | 'create_session' | 'close_session' | 'rename_session' | 'bind_session_pr' | 'release_session' | 'list_sessions' | 'load_context' | 'load_context_usage' | 'load_tasks' | 'load_artifacts' | 'read_attachment' | 'remove_attachment' | 'cancel_task' | 'control_workflow' | 'run_saved_workflow' | 'read_saved_workflow' | 'load_goal' | 'control_goal' | 'clear_goal' | 'load_stats' | 'rewind_snapshots' | 'rewind_session' | 'refresh_commands' | 'recap_session' | 'generate_session_content' | 'btw_session' | 'branch_session' | 'fork_session' | 'record_session' | 'stream' | 'normalize_event';
255
+ export type DaemonNoticeOperation = 'send_prompt' | 'continue_session' | 'send_shell_command' | 'switch_model' | 'set_reasoning_effort' | 'set_workflow_mode' | 'set_approval_mode' | 'submit_permission' | 'cancel_prompt' | 'attach_session' | 'load_session' | 'resume_session' | 'create_session' | 'close_session' | 'rename_session' | 'bind_session_pr' | 'release_session' | 'list_sessions' | 'load_context' | 'load_context_usage' | 'load_tasks' | 'load_artifacts' | 'read_attachment' | 'remove_attachment' | 'cancel_task' | 'control_workflow' | 'run_saved_workflow' | 'read_saved_workflow' | 'load_goal' | 'control_goal' | 'clear_goal' | 'load_stats' | 'rewind_snapshots' | 'rewind_session' | 'refresh_commands' | 'recap_session' | 'generate_session_content' | 'btw_session' | 'branch_session' | 'create_worktree_branch' | 'handoff_worktree' | 'fork_session' | 'record_session' | 'stream' | 'normalize_event';
243
256
  export interface DaemonSessionNotice {
244
257
  id: string;
245
258
  severity: DaemonNoticeSeverity;
@@ -640,6 +653,10 @@ export interface DaemonSessionActions {
640
653
  switchStarted: boolean;
641
654
  sourceWarnings?: string[];
642
655
  }>;
656
+ /** "Create branch here" on the session's detached managed worktree. */
657
+ createWorktreeBranch(name: string): Promise<DaemonWorktreeBranchResult>;
658
+ /** "Hand off" between the managed worktree and the local checkout. */
659
+ handoffWorktree(to: 'local' | 'worktree'): Promise<DaemonWorktreeHandoffResult>;
643
660
  forkSession(directive: string): Promise<DaemonForkSessionResult>;
644
661
  }
645
662
  export interface DaemonSessionContextValue {
@@ -63,6 +63,15 @@ export interface ComposerSubmitMetadata {
63
63
  }
64
64
  export interface UseComposerCoreOptions {
65
65
  onSubmit: (text: string, images?: PromptImage[], files?: PromptFile[], commitAccepted?: ComposerSubmitCommit, metadata?: ComposerSubmitMetadata) => boolean | void;
66
+ /**
67
+ * Awaited before a user-initiated submit (Send button or Enter) reads the
68
+ * draft, so the host can finalize pending input first — e.g. stop voice
69
+ * dictation and insert its final transcript. Submits stay synchronous when
70
+ * it is absent. While it runs, further user submits are ignored and
71
+ * `submitPreparing` is true; a session switch, unmount, or a rejecting
72
+ * finalizer cancels the submit.
73
+ */
74
+ prepareSubmit?: () => Promise<void>;
66
75
  onInputTextChange?: (text: string) => void;
67
76
  onCycleMode?: () => void;
68
77
  cycleModeOnTab?: boolean;
@@ -185,6 +194,15 @@ export interface UseComposerCoreReturn {
185
194
  hasAttachments: boolean;
186
195
  hasContent: boolean;
187
196
  canSubmit: boolean;
197
+ /**
198
+ * The content-independent submit guards (disabled, submitDisabled, draft
199
+ * restore, pending attachment batches, workspace upload). `canSubmit` is
200
+ * `!submitBlocked && hasContent`; render sites that relax the content term
201
+ * must keep these guards.
202
+ */
203
+ submitBlocked: boolean;
204
+ /** True while `prepareSubmit` is running ahead of a user-initiated submit. */
205
+ submitPreparing: boolean;
188
206
  pendingImageBatchCount: number;
189
207
  imageDragActive: boolean;
190
208
  clearImageDragState: () => void;
@@ -1,5 +1,4 @@
1
1
  import type { DaemonSessionArtifact } from '@qwen-code/sdk/daemon';
2
- import { type RegistrationErrorTranslator } from './useReportedArtifactRegistration';
3
2
  export interface SessionArtifactsState {
4
3
  artifacts: DaemonSessionArtifact[];
5
4
  artifactById: ReadonlyMap<string, DaemonSessionArtifact>;
@@ -8,4 +7,4 @@ export interface SessionArtifactsState {
8
7
  hydrated: boolean;
9
8
  refresh: () => Promise<void>;
10
9
  }
11
- export declare function useSessionArtifacts(translateError?: RegistrationErrorTranslator): SessionArtifactsState;
10
+ export declare function useSessionArtifacts(): SessionArtifactsState;
@@ -0,0 +1 @@
1
+ export declare const RU_PART1: Record<string, string | ((vars?: Record<string, string | number>) => string)>;
@@ -0,0 +1,12 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2025 Qwen
4
+ * SPDX-License-Identifier: Apache-2.0
5
+ */
6
+ /**
7
+ * Stands in for `./i18n-ru-part1` in the transcript build (`--mode transcript`).
8
+ * The Russian Web Shell catalog is interactive-only; exported transcripts
9
+ * fall back to English for these strings so every reader does not download
10
+ * a third full UI dictionary.
11
+ */
12
+ export declare const RU_PART1: {};
@@ -0,0 +1 @@
1
+ export declare const RU_PART2: Record<string, string | ((vars?: Record<string, string | number>) => string)>;
@@ -0,0 +1,12 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2025 Qwen
4
+ * SPDX-License-Identifier: Apache-2.0
5
+ */
6
+ /**
7
+ * Stands in for `./i18n-ru-part2` in the transcript build (`--mode transcript`).
8
+ * The Russian Web Shell catalog is interactive-only; exported transcripts
9
+ * fall back to English for these strings so every reader does not download
10
+ * a third full UI dictionary.
11
+ */
12
+ export declare const RU_PART2: {};
@@ -0,0 +1 @@
1
+ export declare const RU_PART3: Record<string, string | ((vars?: Record<string, string | number>) => string)>;
@@ -0,0 +1,12 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2025 Qwen
4
+ * SPDX-License-Identifier: Apache-2.0
5
+ */
6
+ /**
7
+ * Stands in for `./i18n-ru-part3` in the transcript build (`--mode transcript`).
8
+ * The Russian Web Shell catalog is interactive-only; exported transcripts
9
+ * fall back to English for these strings so every reader does not download
10
+ * a third full UI dictionary.
11
+ */
12
+ export declare const RU_PART3: {};
@@ -0,0 +1 @@
1
+ export declare const RU_PART4: Record<string, string | ((vars?: Record<string, string | number>) => string)>;
@@ -0,0 +1,12 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2025 Qwen
4
+ * SPDX-License-Identifier: Apache-2.0
5
+ */
6
+ /**
7
+ * Stands in for `./i18n-ru-part4` in the transcript build (`--mode transcript`).
8
+ * The Russian Web Shell catalog is interactive-only; exported transcripts
9
+ * fall back to English for these strings so every reader does not download
10
+ * a third full UI dictionary.
11
+ */
12
+ export declare const RU_PART4: {};
@@ -0,0 +1 @@
1
+ export declare const RU_PART5: Record<string, string | ((vars?: Record<string, string | number>) => string)>;
@@ -0,0 +1,12 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2025 Qwen
4
+ * SPDX-License-Identifier: Apache-2.0
5
+ */
6
+ /**
7
+ * Stands in for `./i18n-ru-part5` in the transcript build (`--mode transcript`).
8
+ * The Russian Web Shell catalog is interactive-only; exported transcripts
9
+ * fall back to English for these strings so every reader does not download
10
+ * a third full UI dictionary.
11
+ */
12
+ export declare const RU_PART5: {};
@@ -0,0 +1 @@
1
+ export declare const RU_PART6: Record<string, string | ((vars?: Record<string, string | number>) => string)>;
@@ -0,0 +1,12 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2025 Qwen
4
+ * SPDX-License-Identifier: Apache-2.0
5
+ */
6
+ /**
7
+ * Stands in for `./i18n-ru-part6` in the transcript build (`--mode transcript`).
8
+ * The Russian Web Shell catalog is interactive-only; exported transcripts
9
+ * fall back to English for these strings so every reader does not download
10
+ * a third full UI dictionary.
11
+ */
12
+ export declare const RU_PART6: {};
@@ -0,0 +1,6 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2025 Qwen
4
+ * SPDX-License-Identifier: Apache-2.0
5
+ */
6
+ export declare const RU_REMAINDER: Record<string, string | ((vars?: Record<string, string | number>) => string)>;
@@ -0,0 +1,11 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2025 Qwen
4
+ * SPDX-License-Identifier: Apache-2.0
5
+ */
6
+ /**
7
+ * Stands in for `./i18n-ru-remainder` in the transcript build
8
+ * (`--mode transcript`). Activity, channel-events, managed-extension, and
9
+ * GitHub bound-action Russian copy stay in the interactive shell only.
10
+ */
11
+ export declare const RU_REMAINDER: {};
@@ -1,6 +1,12 @@
1
1
  import { type PropsWithChildren } from 'react';
2
2
  export declare const WEB_SHELL_LANGUAGES: readonly ["en", "zh-CN", "ru"];
3
3
  export type WebShellLanguage = (typeof WEB_SHELL_LANGUAGES)[number];
4
+ /**
5
+ * Every local-files message key, derived from the EN catalog so the
6
+ * locale-parity test covers new keys automatically instead of drifting
7
+ * behind a hardcoded subset.
8
+ */
9
+ export declare const LOCAL_FILES_MESSAGE_KEYS: string[];
4
10
  export declare function normalizeLanguage(value: string | undefined | null): WebShellLanguage;
5
11
  export declare function languageSettingToWebShellLanguage(value: unknown): WebShellLanguage | undefined;
6
12
  export declare function languageLabel(language: WebShellLanguage): string;
@@ -13,4 +13,5 @@
13
13
  type LiveMessage = string | ((vars?: Record<string, string | number>) => string);
14
14
  export declare const LIVE_MESSAGES_EN: Record<string, LiveMessage>;
15
15
  export declare const LIVE_MESSAGES_ZH: Record<string, LiveMessage>;
16
+ export declare const LIVE_MESSAGES_RU: Record<string, LiveMessage>;
16
17
  export {};
@@ -10,3 +10,4 @@
10
10
  */
11
11
  export declare const LIVE_MESSAGES_EN: {};
12
12
  export declare const LIVE_MESSAGES_ZH: {};
13
+ export declare const LIVE_MESSAGES_RU: {};
@@ -58,7 +58,13 @@ export declare function useLocalFilesBridge(options: UseLocalFilesBridgeOptions)
58
58
  secureContext: boolean;
59
59
  frame: import("./capabilities.js").LocalFilesFrame;
60
60
  };
61
- connect: () => Promise<void>;
61
+ connect: (options?: {
62
+ forcePicker?: boolean;
63
+ }) => Promise<{
64
+ readonly kind: "repick-failed";
65
+ } | {
66
+ readonly kind: "change-deferred";
67
+ } | undefined>;
62
68
  disconnect: () => Promise<void>;
63
69
  restore: () => Promise<void>;
64
70
  };
@@ -24,6 +24,10 @@ export interface UseManagedLocalFilesBridgeOptions {
24
24
  }
25
25
  export declare function useManagedLocalFilesBridge(options: UseManagedLocalFilesBridgeOptions): {
26
26
  status: LocalFilesStatus;
27
- connect: () => Promise<void>;
27
+ connect: (options?: {
28
+ forcePicker?: boolean;
29
+ }) => Promise<{
30
+ kind: 'repick-failed';
31
+ } | undefined>;
28
32
  disconnect: () => Promise<void>;
29
33
  };
@@ -6,4 +6,5 @@
6
6
  type Message = string | ((vars?: Record<string, string | number>) => string);
7
7
  export declare const MCP_APP_MESSAGES_EN: Record<string, Message>;
8
8
  export declare const MCP_APP_MESSAGES_ZH: Record<string, Message>;
9
+ export declare const MCP_APP_MESSAGES_RU: Record<string, Message>;
9
10
  export {};
@@ -5,3 +5,4 @@
5
5
  */
6
6
  export declare const MCP_APP_MESSAGES_EN: {};
7
7
  export declare const MCP_APP_MESSAGES_ZH: {};
8
+ export declare const MCP_APP_MESSAGES_RU: {};
@@ -6,6 +6,9 @@ interface SessionCatalogHookOptions {
6
6
  maxAgeMs?: number;
7
7
  pollIntervalMs?: number;
8
8
  }
9
+ interface SessionCatalogQueriesOptions extends SessionCatalogHookOptions {
10
+ pollQueries?: (query: SessionCatalogQuery, index: number) => boolean;
11
+ }
9
12
  export interface WebShellSessionsOptions extends SessionCatalogHookOptions {
10
13
  sortBy?: 'updatedAt' | 'lastUserPromptAt';
11
14
  pageSize?: number;
@@ -32,7 +35,7 @@ export declare function useSessionCatalogQuery(client: DaemonClient, query: Sess
32
35
  error?: Error;
33
36
  updatedAt?: number;
34
37
  };
35
- export declare function useSessionCatalogQueries(client: DaemonClient, queries: readonly SessionCatalogQuery[], options?: SessionCatalogHookOptions): readonly SessionCatalogSnapshot[];
38
+ export declare function useSessionCatalogQueries(client: DaemonClient, queries: readonly SessionCatalogQuery[], options?: SessionCatalogQueriesOptions): readonly SessionCatalogSnapshot[];
36
39
  /**
37
40
  * Whether the daemon reports a prompt in flight for `sessionId`, together with
38
41
  * whether that answer is allowed to *settle* a running turn.
@@ -13,4 +13,5 @@
13
13
  type SettingsMessage = string | ((vars?: Record<string, string | number>) => string);
14
14
  export declare const SETTINGS_MESSAGES_EN: Record<string, SettingsMessage>;
15
15
  export declare const SETTINGS_MESSAGES_ZH: Record<string, SettingsMessage>;
16
+ export declare const SETTINGS_MESSAGES_RU: Record<string, SettingsMessage>;
16
17
  export {};
@@ -10,3 +10,4 @@
10
10
  */
11
11
  export declare const SETTINGS_MESSAGES_EN: {};
12
12
  export declare const SETTINGS_MESSAGES_ZH: {};
13
+ export declare const SETTINGS_MESSAGES_RU: {};
@@ -6,4 +6,5 @@
6
6
  type ExecutionMessage = string | ((vars?: Record<string, string | number>) => string);
7
7
  export declare const TRAJECTORY_EXECUTION_MESSAGES_EN: Record<string, ExecutionMessage>;
8
8
  export declare const TRAJECTORY_EXECUTION_MESSAGES_ZH: Record<string, ExecutionMessage>;
9
+ export declare const TRAJECTORY_EXECUTION_MESSAGES_RU: Record<string, ExecutionMessage>;
9
10
  export {};
@@ -5,3 +5,4 @@
5
5
  */
6
6
  export declare const TRAJECTORY_EXECUTION_MESSAGES_EN: {};
7
7
  export declare const TRAJECTORY_EXECUTION_MESSAGES_ZH: {};
8
+ export declare const TRAJECTORY_EXECUTION_MESSAGES_RU: {};
@@ -6,4 +6,5 @@
6
6
  type FilterMessage = string | ((vars?: Record<string, string | number>) => string);
7
7
  export declare const TRAJECTORY_FILTER_MESSAGES_EN: Record<string, FilterMessage>;
8
8
  export declare const TRAJECTORY_FILTER_MESSAGES_ZH: Record<string, FilterMessage>;
9
+ export declare const TRAJECTORY_FILTER_MESSAGES_RU: Record<string, FilterMessage>;
9
10
  export {};
@@ -5,3 +5,4 @@
5
5
  */
6
6
  export declare const TRAJECTORY_FILTER_MESSAGES_EN: {};
7
7
  export declare const TRAJECTORY_FILTER_MESSAGES_ZH: {};
8
+ export declare const TRAJECTORY_FILTER_MESSAGES_RU: {};
@@ -24,4 +24,4 @@ export declare function projectHistoricalLifecycle(events: readonly DaemonEvent[
24
24
  export declare function projectTrajectoryLifecycle(history: ReturnType<typeof projectHistoricalLifecycle>, trajectory: Trajectory | undefined, identity: {
25
25
  sessionId: string;
26
26
  scope?: string;
27
- } | undefined, live: TrajectoryLiveSnapshot): TrajectoryLifecycleProjection;
27
+ } | undefined, live: Omit<TrajectoryLiveSnapshot, 'hooks' | 'hookPromptIds'>): TrajectoryLifecycleProjection;
@@ -3,7 +3,7 @@
3
3
  * Copyright 2025 Qwen Team
4
4
  * SPDX-License-Identifier: Apache-2.0
5
5
  */
6
- import { type DaemonEvent, type ExecutionLifecycleState, type ToolLifecycleState } from '@qwen-code/sdk/daemon';
6
+ import { type HookLifecycleState, type DaemonEvent, type ExecutionLifecycleState, type ToolLifecycleState } from '@qwen-code/sdk/daemon';
7
7
  export interface TrajectoryLiveSnapshot {
8
8
  readonly sessionId?: string;
9
9
  readonly scope?: string;
@@ -13,6 +13,8 @@ export interface TrajectoryLiveSnapshot {
13
13
  readonly reason?: string;
14
14
  readonly requests: ExecutionLifecycleState;
15
15
  readonly tools: ToolLifecycleState;
16
+ readonly hooks: HookLifecycleState;
17
+ readonly hookPromptIds: ReadonlyMap<string, string>;
16
18
  readonly incomplete: boolean;
17
19
  readonly truncated: boolean;
18
20
  }
@@ -6,4 +6,5 @@
6
6
  type WindowMessage = string | ((vars?: Record<string, string | number>) => string);
7
7
  export declare const TRAJECTORY_WINDOW_MESSAGES_EN: Record<string, WindowMessage>;
8
8
  export declare const TRAJECTORY_WINDOW_MESSAGES_ZH: Record<string, WindowMessage>;
9
+ export declare const TRAJECTORY_WINDOW_MESSAGES_RU: Record<string, WindowMessage>;
9
10
  export {};
@@ -5,3 +5,4 @@
5
5
  */
6
6
  export declare const TRAJECTORY_WINDOW_MESSAGES_EN: {};
7
7
  export declare const TRAJECTORY_WINDOW_MESSAGES_ZH: {};
8
+ export declare const TRAJECTORY_WINDOW_MESSAGES_RU: {};