@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
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { ManagedAgentProvider } from '../managed/managed-agent-provider';
|
|
2
|
-
import { type Ref } from 'react';
|
|
2
|
+
import { type ReactNode, type Ref } from 'react';
|
|
3
3
|
import type { EmbeddedManagerPage } from '../plugins/manager-page';
|
|
4
4
|
interface ExtensionsManagerPageProps {
|
|
5
5
|
managed?: {
|
|
@@ -10,6 +10,8 @@ interface ExtensionsManagerPageProps {
|
|
|
10
10
|
onClose: () => void;
|
|
11
11
|
initialFocusRef?: Ref<HTMLHeadingElement>;
|
|
12
12
|
embedded?: EmbeddedManagerPage;
|
|
13
|
+
workspaceCwd?: string;
|
|
14
|
+
workspaceControl?: ReactNode;
|
|
13
15
|
}
|
|
14
16
|
export declare function ExtensionsManagerPage(props: ExtensionsManagerPageProps): import("react/jsx-runtime").JSX.Element;
|
|
15
17
|
export {};
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import type { ManagedAgentSessionSummary } from './managed-agent-provider.js';
|
|
2
|
-
import type {
|
|
2
|
+
import type { ChatCapabilities } from '../../chat-core/contract.js';
|
|
3
|
+
import { type ChatRegion } from '../../chat-core/capabilities.js';
|
|
3
4
|
export type ManagedCapabilityKey = keyof ManagedAgentSessionSummary['capabilities'];
|
|
4
5
|
export declare const MANAGED_CHAT_CAPABILITY_MAP: Record<ManagedCapabilityKey, readonly ChatRegion[]>;
|
|
5
6
|
export declare function isManagedCapabilityOn(value: boolean | null | undefined): boolean;
|
|
7
|
+
export declare function managedCapabilitiesFromSummary(capabilities: Partial<ManagedAgentSessionSummary['capabilities']> | undefined): ChatCapabilities;
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Qwen Team
|
|
4
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
+
*/
|
|
6
|
+
import type { Message, PermissionRequest } from '../../adapters/types.js';
|
|
7
|
+
import type { Admission, ApprovalSelectionController, ChatCapabilities, ChatOperation, ChatStatusFacts, ComposerSubmit, ContextUsageController, ModelSelectionController, QuestionAnswer, SessionChatController, SessionOpsController } from '../../chat-core/contract.js';
|
|
8
|
+
import type { ManagedAgentPendingAction, ManagedAgentPendingQuestionAction, ManagedAgentQuestionAnswer, ManagedAgentSessionPhase } from './managed-agent-provider.js';
|
|
9
|
+
import { MAX_MANAGED_QUESTION_TEXT_LENGTH } from './managed-question-response.js';
|
|
10
|
+
export { MAX_MANAGED_QUESTION_TEXT_LENGTH };
|
|
11
|
+
type OperationState = ChatOperation['state'];
|
|
12
|
+
export interface ManagedTransportAdmission {
|
|
13
|
+
readonly admission: Admission;
|
|
14
|
+
readonly operationId?: string;
|
|
15
|
+
readonly turnId?: string;
|
|
16
|
+
}
|
|
17
|
+
export interface ManagedOperationSettlement {
|
|
18
|
+
readonly operationId: string;
|
|
19
|
+
readonly status: 'completed' | 'failed' | 'cancelled' | 'recovery_blocked';
|
|
20
|
+
}
|
|
21
|
+
export interface ManagedTurnSettlement {
|
|
22
|
+
readonly turnId: string;
|
|
23
|
+
readonly outcome: 'completed' | 'cancelled' | 'failed';
|
|
24
|
+
}
|
|
25
|
+
export interface ManagedActionSettlement {
|
|
26
|
+
readonly actionId: string;
|
|
27
|
+
readonly outcome: 'resolved' | 'expired' | 'superseded' | 'failed';
|
|
28
|
+
}
|
|
29
|
+
export interface ManagedChatControllerDeps {
|
|
30
|
+
readonly sessionId: string;
|
|
31
|
+
readonly storageKey: string;
|
|
32
|
+
readonly activeTurnId?: string;
|
|
33
|
+
readonly sessionPhase: ManagedAgentSessionPhase;
|
|
34
|
+
readonly messages: readonly Message[];
|
|
35
|
+
readonly transcriptState: 'loading' | 'ready' | 'error';
|
|
36
|
+
readonly hasOlderHistory?: boolean;
|
|
37
|
+
readonly loadingOlderHistory?: boolean;
|
|
38
|
+
readonly historyCapacityReached?: boolean;
|
|
39
|
+
readonly historyPaginationError?: boolean;
|
|
40
|
+
loadOlder?(options?: {
|
|
41
|
+
force?: boolean;
|
|
42
|
+
}): Promise<void>;
|
|
43
|
+
readonly pendingActions: readonly ManagedAgentPendingAction[];
|
|
44
|
+
readonly now?: () => number;
|
|
45
|
+
readonly retainExpiredActions?: boolean;
|
|
46
|
+
readonly statusFacts: ChatStatusFacts;
|
|
47
|
+
readonly capabilities: ChatCapabilities;
|
|
48
|
+
readonly modelSelection?: ModelSelectionController;
|
|
49
|
+
readonly approvalSelection?: ApprovalSelectionController;
|
|
50
|
+
readonly contextUsage?: ContextUsageController;
|
|
51
|
+
readonly sessionOps?: SessionOpsController;
|
|
52
|
+
submitPrompt(input: ComposerSubmit): Promise<ManagedTransportAdmission>;
|
|
53
|
+
cancelTurn(turnId: string): Promise<ManagedTransportAdmission>;
|
|
54
|
+
submitApproval(actionId: string, optionId: string): Promise<ManagedTransportAdmission>;
|
|
55
|
+
submitQuestion(actionId: string, answers: readonly ManagedAgentQuestionAnswer[]): Promise<ManagedTransportAdmission>;
|
|
56
|
+
subscribeOperationSettlement?(listener: (event: ManagedOperationSettlement) => void): () => void;
|
|
57
|
+
subscribeTurnSettlement?(listener: (event: ManagedTurnSettlement) => void): () => void;
|
|
58
|
+
subscribeActionSettlement?(listener: (event: ManagedActionSettlement) => void): () => void;
|
|
59
|
+
readonly signal?: AbortSignal;
|
|
60
|
+
}
|
|
61
|
+
export declare const MANAGED_QUESTION_SUBMIT_OPTION_ID = "submit";
|
|
62
|
+
export declare function mapManagedPhase(phase: ManagedAgentSessionPhase): 'idle' | 'running' | 'cancelling' | 'failed';
|
|
63
|
+
export declare function mapManagedOperationStatus(status: ManagedOperationSettlement['status']): Exclude<OperationState, 'pending'>;
|
|
64
|
+
export declare function toManagedQuestionPermissionRequest(action: ManagedAgentPendingQuestionAction): PermissionRequest;
|
|
65
|
+
export declare function normalizeManagedQuestionAnswers(action: ManagedAgentPendingQuestionAction, answers: readonly QuestionAnswer[]): ManagedAgentQuestionAnswer[] | null;
|
|
66
|
+
export declare function createManagedChatController(deps: ManagedChatControllerDeps): SessionChatController;
|
|
@@ -822,7 +822,7 @@ export interface paths {
|
|
|
822
822
|
};
|
|
823
823
|
get?: never;
|
|
824
824
|
put?: never;
|
|
825
|
-
/** @description Recheck only the latest original Turn under the existing cancellation/cleanup authorization. Repeated requests coalesce and may only advance existing cancellation/reconciliation or retry settled cleanup; they never resubmit input, replay effects, reset retry budgets or change claim generations. A stale Turn returns recovery_target_changed and ineligible work returns recovery_recheck_unavailable. A cleanup recheck that no Hosted Harness can serve returns 503 recovery_runtime_unavailable; a typed terminal decline returns 409 hosted_turn_recovery_declined, and retrying cannot change a decline. 202 means requested, not cancelled or ready. For a terminal Java Turn whose Harness attachment is cold or whose status cannot be read, this POST may attempt a narrow cleanup-only load. It must verify the original prompt has a durable native terminal, covered continuation checkpoint or lawful initial state, and no pending input before retrying only its existing cleanup. It never resumes models, tools, MCP or Hooks, clears a permanent journal block, or treats a historical SQL failure as native settlement. */
|
|
825
|
+
/** @description Recheck only the latest original Turn under the existing cancellation/cleanup authorization. Repeated requests coalesce and may only advance existing cancellation/reconciliation or retry settled cleanup; they never resubmit input, replay effects, reset retry budgets or change claim generations. A stale Turn returns recovery_target_changed and ineligible work returns recovery_recheck_unavailable. A cleanup recheck that no Hosted Harness can serve returns 503 recovery_runtime_unavailable; a typed terminal decline returns 409 hosted_turn_recovery_declined, and retrying cannot change a decline. 202 means requested, not cancelled or ready. For a terminal Java Turn whose Harness attachment is cold or whose status cannot be read, this POST may attempt a narrow cleanup-only load. It must verify the original prompt has a durable native terminal, covered continuation checkpoint or lawful initial state, and no pending input before retrying only its existing cleanup. A Turn cancelled before Harness admission keeps its public Turn id, while its cleanup recheck targets the settled prompt the Harness names for the Session. It never resumes models, tools, MCP or Hooks, clears a permanent journal block, or treats a historical SQL failure as native settlement. */
|
|
826
826
|
post: operations["recheckWebShellSessionRecovery"];
|
|
827
827
|
delete?: never;
|
|
828
828
|
options?: never;
|
|
@@ -214,6 +214,18 @@ export interface ManagedAgentRequestOptions {
|
|
|
214
214
|
export interface ManagedAgentCommandOptions extends ManagedAgentRequestOptions {
|
|
215
215
|
idempotencyKey: string;
|
|
216
216
|
}
|
|
217
|
+
export interface ManagedAgentOperationAdmission {
|
|
218
|
+
readonly sessionId: string;
|
|
219
|
+
readonly operationId: string;
|
|
220
|
+
readonly turnId?: string;
|
|
221
|
+
}
|
|
222
|
+
export interface ManagedAgentOperationSettlement extends ManagedAgentOperationAdmission {
|
|
223
|
+
readonly status: components['schemas']['WebShellOperation']['status'];
|
|
224
|
+
}
|
|
225
|
+
export interface ManagedAgentOperationObserver {
|
|
226
|
+
readonly onAccepted?: (admission: ManagedAgentOperationAdmission) => void;
|
|
227
|
+
readonly onSettlement?: (settlement: ManagedAgentOperationSettlement) => void;
|
|
228
|
+
}
|
|
217
229
|
export type ManagedContextCompressionOperation = components['schemas']['WebShellContextCompressionOperation'];
|
|
218
230
|
export type ManagedTask = components['schemas']['WebShellTask'];
|
|
219
231
|
export type ManagedTaskPage = components['schemas']['WebShellTaskPage'];
|
|
@@ -348,7 +360,7 @@ export interface ManagedAgentProvider {
|
|
|
348
360
|
listPending(sessionId: string, options: ManagedAgentRequestOptions & {
|
|
349
361
|
includeChildren?: boolean;
|
|
350
362
|
}): Promise<ManagedAgentPendingAction[]>;
|
|
351
|
-
respond(action: ManagedAgentPendingAction, response: ManagedAgentActionResponse, options: ManagedAgentCommandOptions): Promise<void>;
|
|
363
|
+
respond(action: ManagedAgentPendingAction, response: ManagedAgentActionResponse, options: ManagedAgentCommandOptions & ManagedAgentOperationObserver): Promise<void>;
|
|
352
364
|
};
|
|
353
365
|
readonly toolResults?: ManagedToolResultReader;
|
|
354
366
|
/** Present when the provider can list a Workspace's artifacts across Sessions. */
|
|
@@ -1,4 +1,11 @@
|
|
|
1
1
|
import type { ManagedAgentPendingQuestionAction, ManagedAgentQuestionAnswer } from './managed-agent-provider';
|
|
2
2
|
export declare const MAX_MANAGED_QUESTION_ANSWER_BYTES: number;
|
|
3
|
+
export declare const MAX_MANAGED_QUESTION_TEXT_LENGTH = 8192;
|
|
4
|
+
export type ManagedQuestionDraft = Record<string, {
|
|
5
|
+
optionIds: string[];
|
|
6
|
+
text: string;
|
|
7
|
+
}>;
|
|
8
|
+
export declare function managedQuestionAnswersFromDraft(action: ManagedAgentPendingQuestionAction, draft: ManagedQuestionDraft): ManagedAgentQuestionAnswer[];
|
|
9
|
+
export declare function exceedsManagedQuestionAnswerLimits(answers: readonly ManagedAgentQuestionAnswer[]): boolean;
|
|
3
10
|
export declare function canonicalQuestionAnswers(action: ManagedAgentPendingQuestionAction, answers: readonly ManagedAgentQuestionAnswer[]): ManagedAgentQuestionAnswer[];
|
|
4
11
|
export declare function questionResponseKey(action: ManagedAgentPendingQuestionAction, answers: readonly ManagedAgentQuestionAnswer[]): string;
|
|
@@ -1,6 +1,10 @@
|
|
|
1
|
-
import type { ManagedAgentPendingAction, ManagedAgentActionResponse, ManagedAgentProvider, ManagedAgentSessionEvent } from './managed-agent-provider';
|
|
2
|
-
import type { ManagedQuestionDraft } from './
|
|
1
|
+
import type { ManagedAgentOperationObserver, ManagedAgentPendingAction, ManagedAgentActionResponse, ManagedAgentProvider, ManagedAgentSessionEvent } from './managed-agent-provider';
|
|
2
|
+
import type { ManagedQuestionDraft } from './managed-question-response';
|
|
3
3
|
export declare function managedActionKey(action: ManagedAgentPendingAction): string;
|
|
4
|
+
export type ManagedActionRespondOutcome = 'responded' | 'ended' | 'skipped';
|
|
5
|
+
export interface ManagedActionRespondOptions extends ManagedAgentOperationObserver {
|
|
6
|
+
readonly signal?: AbortSignal;
|
|
7
|
+
}
|
|
4
8
|
export interface ManagedActionsState {
|
|
5
9
|
actions: readonly ManagedAgentPendingAction[];
|
|
6
10
|
/** The selected pending request; answered ones stay hidden while they settle. */
|
|
@@ -27,7 +31,7 @@ export interface ManagedActionsState {
|
|
|
27
31
|
* re-probes instead of treating one 403 as permanent for the mount.
|
|
28
32
|
*/
|
|
29
33
|
respondForbidden: boolean;
|
|
30
|
-
respond(action: ManagedAgentPendingAction, response: ManagedAgentActionResponse): Promise<
|
|
34
|
+
respond(action: ManagedAgentPendingAction, response: ManagedAgentActionResponse, options?: ManagedActionRespondOptions): Promise<ManagedActionRespondOutcome>;
|
|
31
35
|
/** Reads the pending approvals again now. */
|
|
32
36
|
retry(): void;
|
|
33
37
|
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import type { Message } from '../../adapters/types';
|
|
2
|
+
import type { SessionChatController } from '../../chat-core/contract';
|
|
3
|
+
import type { ManagedAgentPendingAction, ManagedAgentProvider } from './managed-agent-provider';
|
|
4
|
+
import { useManagedActions } from './use-managed-actions';
|
|
5
|
+
import { useManagedSession } from './use-managed-session';
|
|
6
|
+
import { useManagedTurnCancel, type ManagedTurnCancelObserver } from './use-managed-turn-cancel';
|
|
7
|
+
interface ManagedChatControllerOptions {
|
|
8
|
+
readonly provider: ManagedAgentProvider;
|
|
9
|
+
readonly clientId: string;
|
|
10
|
+
readonly sessionId: string | undefined;
|
|
11
|
+
}
|
|
12
|
+
export interface ManagedChatControllerFromStateOptions {
|
|
13
|
+
readonly provider: ManagedAgentProvider;
|
|
14
|
+
readonly clientId: string;
|
|
15
|
+
readonly sessionId: string | undefined;
|
|
16
|
+
readonly detail: ReturnType<typeof useManagedSession>;
|
|
17
|
+
readonly pending: ReturnType<typeof useManagedActions>;
|
|
18
|
+
readonly turnCancel: ReturnType<typeof useManagedTurnCancel>;
|
|
19
|
+
readonly cancelObserverRef: {
|
|
20
|
+
current: ManagedTurnCancelObserver | undefined;
|
|
21
|
+
};
|
|
22
|
+
readonly messages: readonly Message[];
|
|
23
|
+
/**
|
|
24
|
+
* The single pending action currently selected by the host (root or child
|
|
25
|
+
* session). Keeping this singular makes bare-`actionId` submission routing
|
|
26
|
+
* unambiguous even when multiple child sessions share an `actionId`.
|
|
27
|
+
*/
|
|
28
|
+
readonly selectedAction: ManagedAgentPendingAction | undefined;
|
|
29
|
+
readonly retainExpiredActions?: boolean;
|
|
30
|
+
readonly canRespondAction?: () => boolean;
|
|
31
|
+
readonly canCancel?: boolean;
|
|
32
|
+
}
|
|
33
|
+
export declare function useManagedChatController({ provider, clientId, sessionId, }: ManagedChatControllerOptions): SessionChatController | undefined;
|
|
34
|
+
/**
|
|
35
|
+
* Binds an already-mounted set of Managed session hooks (`useManagedSession`,
|
|
36
|
+
* `useManagedActions`, `useManagedTurnCancel`) to {@link SessionChatController}
|
|
37
|
+
* without opening duplicate SSE streams or polling loops.
|
|
38
|
+
*/
|
|
39
|
+
export declare function useManagedChatControllerFromState({ provider, clientId, sessionId, detail, pending, turnCancel, cancelObserverRef, messages, selectedAction, retainExpiredActions, canRespondAction, canCancel, }: ManagedChatControllerFromStateOptions): SessionChatController;
|
|
40
|
+
export {};
|
|
@@ -1,5 +1,8 @@
|
|
|
1
|
-
import type { ManagedAgentProvider, ManagedAgentSessionSummary } from './managed-agent-provider';
|
|
2
|
-
export
|
|
1
|
+
import type { ManagedAgentOperationObserver, ManagedAgentProvider, ManagedAgentSessionSummary } from './managed-agent-provider';
|
|
2
|
+
export interface ManagedTurnCancelObserver extends ManagedAgentOperationObserver {
|
|
3
|
+
readonly onError?: (error: unknown) => void;
|
|
4
|
+
}
|
|
5
|
+
export declare function useManagedTurnCancel(provider: ManagedAgentProvider, clientId: string, sessionId: string | undefined, summary: ManagedAgentSessionSummary | undefined, interactive: boolean, refreshSummary: () => Promise<ManagedAgentSessionSummary | undefined>, observer?: ManagedTurnCancelObserver): {
|
|
3
6
|
request: () => Promise<void>;
|
|
4
7
|
retry: () => Promise<void>;
|
|
5
8
|
status: "failed" | "stopping" | "unconfirmed" | undefined;
|
|
@@ -1,9 +1,22 @@
|
|
|
1
1
|
import type { PermissionRequest } from '../../adapters/types';
|
|
2
|
+
import type { QuestionAnswer } from '../../chat-core/contract';
|
|
3
|
+
export type AskUserQuestionDraft = Record<string, {
|
|
4
|
+
optionIds: string[];
|
|
5
|
+
text: string;
|
|
6
|
+
}>;
|
|
2
7
|
interface AskUserQuestionProps {
|
|
3
8
|
request: PermissionRequest;
|
|
4
|
-
onConfirm: (id: string, selectedOption: string, answers?: Record<string, string
|
|
9
|
+
onConfirm: (id: string, selectedOption: string, answers?: Record<string, string>, structuredAnswers?: readonly QuestionAnswer[]) => Promise<boolean>;
|
|
5
10
|
onError: (error: unknown, fallback: string) => void;
|
|
6
11
|
variant?: 'inline' | 'floating';
|
|
12
|
+
/** Disables answering and submitting while keeping questions inspectable. */
|
|
13
|
+
disabled?: boolean;
|
|
14
|
+
/** Blocks only submission (Submit button and submit shortcuts) while keeping inputs editable. */
|
|
15
|
+
submitDisabled?: boolean;
|
|
16
|
+
/** Optional initial draft hydrated when a request mounts or changes identity. */
|
|
17
|
+
initialDraft?: AskUserQuestionDraft;
|
|
18
|
+
/** Emitted after user-driven answer edits so a host can preserve drafts across switches. */
|
|
19
|
+
onDraftChange?: (draft: AskUserQuestionDraft) => void;
|
|
7
20
|
customInputLabel?: string;
|
|
8
21
|
/**
|
|
9
22
|
* Opens a side task that explains the pending question before the user
|
|
@@ -20,5 +33,5 @@ interface AskUserQuestionProps {
|
|
|
20
33
|
*/
|
|
21
34
|
keyboardActive?: boolean;
|
|
22
35
|
}
|
|
23
|
-
export declare function AskUserQuestion({ request, onConfirm, onError, variant, keyboardActive, customInputLabel, onAskDetails, }: AskUserQuestionProps): import("react/jsx-runtime").JSX.Element | null;
|
|
36
|
+
export declare function AskUserQuestion({ request, onConfirm, onError, variant, disabled, submitDisabled, initialDraft, onDraftChange, keyboardActive, customInputLabel, onAskDetails, }: AskUserQuestionProps): import("react/jsx-runtime").JSX.Element | null;
|
|
24
37
|
export {};
|
|
@@ -31,6 +31,8 @@ interface ThinkingMessageProps {
|
|
|
31
31
|
content: string;
|
|
32
32
|
author?: DaemonMessageAuthor;
|
|
33
33
|
isStreaming?: boolean;
|
|
34
|
+
/** A subagent's thought, drawn outside its tool card. */
|
|
35
|
+
fromSubagent?: boolean;
|
|
34
36
|
timestamp?: number;
|
|
35
37
|
isLocateFlashing?: boolean;
|
|
36
38
|
generateContent?: SessionContentGenerator;
|
|
@@ -44,8 +46,10 @@ interface ThinkingTranslateButtonProps {
|
|
|
44
46
|
generateContent?: SessionContentGenerator;
|
|
45
47
|
className?: string;
|
|
46
48
|
mode?: 'translate' | 'explain-shell';
|
|
49
|
+
hideWhenClosed?: boolean;
|
|
50
|
+
fallbackFocusRef?: RefObject<HTMLButtonElement | null>;
|
|
47
51
|
}
|
|
48
|
-
export declare function ThinkingTranslateButton({ content, generateContent, className, mode, }: ThinkingTranslateButtonProps): import("react/jsx-runtime").JSX.Element;
|
|
52
|
+
export declare function ThinkingTranslateButton({ content, generateContent, className, mode, hideWhenClosed, fallbackFocusRef, }: ThinkingTranslateButtonProps): import("react/jsx-runtime").JSX.Element | null;
|
|
49
53
|
export declare function getThinkingSummaryKey({ isStreaming, durationMs, }: {
|
|
50
54
|
isStreaming?: boolean;
|
|
51
55
|
durationMs?: number;
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { type DaemonContextFileScope } from '@qwen-code/web-shell/daemon-react-sdk';
|
|
2
2
|
interface MemoryMessageProps {
|
|
3
|
+
workspaceCwd?: string;
|
|
3
4
|
addSignal?: number;
|
|
4
5
|
addScope?: DaemonContextFileScope;
|
|
5
6
|
onMessage?: (message: string, type?: 'status' | 'error') => void;
|
|
6
7
|
}
|
|
7
|
-
export declare function MemoryMessage({ addSignal, addScope, onMessage, }: MemoryMessageProps): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export declare function MemoryMessage({ workspaceCwd, addSignal, addScope, onMessage, }: MemoryMessageProps): import("react/jsx-runtime").JSX.Element;
|
|
8
9
|
export {};
|
|
@@ -6,10 +6,17 @@
|
|
|
6
6
|
import type { ReactNode } from 'react';
|
|
7
7
|
import type { Message } from '../../adapters/types';
|
|
8
8
|
import { type AssistantMessageProps } from './AssistantMessage';
|
|
9
|
-
|
|
9
|
+
import { type ThinkingBodyProps } from './ThinkingBody';
|
|
10
|
+
/** Draws the Mods' rewrites of this transcript's reply and thinking rows. */
|
|
11
|
+
export declare function ModRowsProvider({ messages, children, }: {
|
|
10
12
|
messages: readonly Message[];
|
|
11
13
|
children: ReactNode;
|
|
12
14
|
}): import("react/jsx-runtime").JSX.Element;
|
|
15
|
+
/**
|
|
16
|
+
* An expanded thought's body: once complete and on screen, a thought of the
|
|
17
|
+
* session's own model is asked for, and drawn with the text its hooks wrote.
|
|
18
|
+
*/
|
|
19
|
+
export declare function ModThinkingBody({ content, isStreaming, fromSubagent, onRewrittenChange, }: ThinkingBodyProps): import("react/jsx-runtime").JSX.Element;
|
|
13
20
|
export declare function ModAssistantMessage({ messageId, ...props }: AssistantMessageProps & {
|
|
14
21
|
messageId: string;
|
|
15
22
|
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -30,6 +30,8 @@ interface SettingsMessageProps {
|
|
|
30
30
|
* the Workspace scope tab; omitted when the daemon cannot manage them.
|
|
31
31
|
*/
|
|
32
32
|
workspaceDirectoriesSection?: ReactNode;
|
|
33
|
+
/** Optional workspace switcher rendered beside the scope tabs. */
|
|
34
|
+
workspaceControl?: ReactNode;
|
|
33
35
|
embedded?: boolean;
|
|
34
36
|
/** Category to select on open (deep link, e.g. 'Daemon'). */
|
|
35
37
|
initialCategory?: string;
|
|
@@ -53,16 +55,22 @@ export interface SettingsMessageSettingsState {
|
|
|
53
55
|
type Scope = 'user' | 'workspace';
|
|
54
56
|
type Translator = (key: string, vars?: Record<string, string | number>) => string;
|
|
55
57
|
export declare function formatSettingLabel(setting: DaemonSettingDescriptor, t: Translator): string;
|
|
58
|
+
declare const LOCAL_SETTING_IDS: {
|
|
59
|
+
readonly chatWidth: "builtin:chat-width";
|
|
60
|
+
readonly arrowKeyHistory: "builtin:arrow-key-history";
|
|
61
|
+
readonly browserNotifications: "builtin:browser-notifications";
|
|
62
|
+
};
|
|
63
|
+
type LocalSettingItem = {
|
|
64
|
+
type: 'local';
|
|
65
|
+
localKey: keyof typeof LOCAL_SETTING_IDS;
|
|
66
|
+
};
|
|
56
67
|
export type FlatRow = {
|
|
57
68
|
type: 'header';
|
|
58
69
|
category: string;
|
|
59
70
|
} | {
|
|
60
71
|
type: 'setting';
|
|
61
72
|
setting: DaemonSettingDescriptor;
|
|
62
|
-
} |
|
|
63
|
-
type: 'local';
|
|
64
|
-
localKey: 'chatWidth' | 'browserNotifications';
|
|
65
|
-
};
|
|
73
|
+
} | LocalSettingItem;
|
|
66
74
|
export declare function nextSettingIdx(rows: FlatRow[], current: number, dir: 1 | -1): number;
|
|
67
|
-
export declare function SettingsMessage({ settingsState, presentation, onLanguageChange, onOutputLanguageChange, onSubDialog, onThemeChange, chatWidthMode, onChatWidthModeChange, modelManagementSectionProps, connections, archivedSessions, workspaceDirectoriesSection, embedded, initialCategory, workspaceSettingsWritable, }: SettingsMessageProps): import("react/jsx-runtime").JSX.Element;
|
|
75
|
+
export declare function SettingsMessage({ settingsState, presentation, onLanguageChange, onOutputLanguageChange, onSubDialog, onThemeChange, chatWidthMode, onChatWidthModeChange, modelManagementSectionProps, connections, archivedSessions, workspaceDirectoriesSection, workspaceControl, embedded, initialCategory, workspaceSettingsWritable, }: SettingsMessageProps): import("react/jsx-runtime").JSX.Element;
|
|
68
76
|
export {};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Qwen Team
|
|
4
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
+
*/
|
|
6
|
+
import { type ComponentType } from 'react';
|
|
7
|
+
export interface ThinkingBodyProps {
|
|
8
|
+
content: string;
|
|
9
|
+
isStreaming?: boolean;
|
|
10
|
+
/** A subagent's thought, drawn outside its tool card. */
|
|
11
|
+
fromSubagent?: boolean;
|
|
12
|
+
/** Reports the source text of the displayed rewrite, if any. */
|
|
13
|
+
onRewrittenChange?: (source: string | undefined) => void;
|
|
14
|
+
}
|
|
15
|
+
export declare const ThinkingBodyComponentContext: import("react").Context<{
|
|
16
|
+
Body: ComponentType<ThinkingBodyProps>;
|
|
17
|
+
} | undefined>;
|
|
18
|
+
export declare function useThinkingBodyRewrite(content: string): readonly [boolean, (source: string | undefined) => void];
|
|
19
|
+
/** The body an expanded thought shows. */
|
|
20
|
+
export declare function ThinkingBody(props: ThinkingBodyProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Qwen Team
|
|
4
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
+
*/
|
|
6
|
+
import type { ThinkingBodyProps } from './ThinkingBody';
|
|
7
|
+
export declare function useThinkingBodyRewrite(): readonly [false, undefined];
|
|
8
|
+
export declare function ThinkingBody({ content, isStreaming }: ThinkingBodyProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ACPToolCall, PermissionRequest } from '../../adapters/types';
|
|
1
|
+
import type { ACPToolCall, PermissionRequest, ToolGroupMessage } from '../../adapters/types';
|
|
2
2
|
import type { SessionContentGenerator } from './AssistantMessage';
|
|
3
3
|
import { useI18n } from '../../i18n';
|
|
4
4
|
import { type ToolHeaderKind } from '../../customization';
|
|
@@ -11,11 +11,7 @@ interface ToolGroupProps {
|
|
|
11
11
|
* the original order. Streaming entries drive the "Thinking…" summary;
|
|
12
12
|
* each entry renders as a click-to-expand row.
|
|
13
13
|
*/
|
|
14
|
-
thoughts?:
|
|
15
|
-
content: string;
|
|
16
|
-
isStreaming?: boolean;
|
|
17
|
-
beforeToolCallId?: string;
|
|
18
|
-
}>;
|
|
14
|
+
thoughts?: ToolGroupMessage['thoughts'];
|
|
19
15
|
pendingApproval?: PermissionRequest | null;
|
|
20
16
|
workspaceCwd?: string;
|
|
21
17
|
onTurnOutputOpen?: (request: TurnOutputOpenRequest) => void;
|
|
@@ -16,11 +16,13 @@ interface UserMessageFile {
|
|
|
16
16
|
}
|
|
17
17
|
interface UserMessageProps {
|
|
18
18
|
content: string;
|
|
19
|
+
source?: string;
|
|
19
20
|
images?: UserMessageImage[];
|
|
20
21
|
files?: UserMessageFile[];
|
|
21
22
|
inputAnnotations?: readonly DaemonInputAnnotation[];
|
|
22
23
|
isLocateFlashing?: boolean;
|
|
23
24
|
sendFailed?: boolean;
|
|
25
|
+
sendFailedStatus?: 'failed' | 'uncertain';
|
|
24
26
|
onRetrySend?: () => void;
|
|
25
27
|
/** Render the message as an in-place editor instead of rendered content. */
|
|
26
28
|
editing?: boolean;
|
|
@@ -8,11 +8,13 @@ interface PluginManagerPageProps {
|
|
|
8
8
|
showBackButton?: boolean;
|
|
9
9
|
initialFocusRef?: Ref<HTMLButtonElement>;
|
|
10
10
|
initialTab?: PluginTab;
|
|
11
|
+
initialWorkspaceCwd?: string;
|
|
12
|
+
navigationRequest?: number;
|
|
11
13
|
skillsWorkspaceCwd?: string;
|
|
12
14
|
onSkillsWorkspaceChange?: (cwd: string) => void;
|
|
13
15
|
managedSkills?: boolean;
|
|
14
16
|
managedExtensions?: Omit<ManagedExtensionsManagerPageProps, 'onClose'>;
|
|
15
17
|
managedMcp?: ManagedMcpManagerPageProps;
|
|
16
18
|
}
|
|
17
|
-
export declare function PluginManagerPage({ onClose, onUseSkill, showBackButton, initialFocusRef, initialTab, skillsWorkspaceCwd, onSkillsWorkspaceChange, managedSkills, managedExtensions, managedMcp, }: PluginManagerPageProps): import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
export declare function PluginManagerPage({ onClose, onUseSkill, showBackButton, initialFocusRef, initialTab, initialWorkspaceCwd, navigationRequest, skillsWorkspaceCwd, onSkillsWorkspaceChange, managedSkills, managedExtensions, managedMcp, }: PluginManagerPageProps): import("react/jsx-runtime").JSX.Element;
|
|
18
20
|
export {};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare function SavedWebPreview({ artifact, sourceSessionId, }: {
|
|
1
|
+
import type { DaemonSessionArtifact } from '@qwen-code/sdk/daemon';
|
|
2
|
+
export declare function SavedWebPreview({ artifact, sourceSessionId, onSessionNotFound, }: {
|
|
3
3
|
artifact: DaemonSessionArtifact;
|
|
4
4
|
sourceSessionId?: string;
|
|
5
|
+
onSessionNotFound?: () => void;
|
|
5
6
|
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -17,7 +17,7 @@ export interface WebShellSidebarLockedWorkspace {
|
|
|
17
17
|
expanded: boolean;
|
|
18
18
|
}) => ReactNode;
|
|
19
19
|
}
|
|
20
|
-
export type WebShellSidebarPrimaryNavItem = 'newTask' | 'agents' | 'plugins' | 'channels' | 'channelEvents' | 'live' | 'scheduledTasks' | 'prWatches' | 'workflows' | 'goals' | 'managed';
|
|
20
|
+
export type WebShellSidebarPrimaryNavItem = 'newTask' | 'agents' | 'plugins' | 'channels' | 'channelEvents' | 'live' | 'scheduledTasks' | 'prWatches' | 'workflows' | 'goals' | 'artifacts' | 'managed';
|
|
21
21
|
export interface WebShellSidebarPrimaryNavOptions {
|
|
22
22
|
/** Built-in primary nav entries to show. Embedded hosts default to New session only. */
|
|
23
23
|
items?: readonly WebShellSidebarPrimaryNavItem[];
|
|
@@ -41,7 +41,8 @@ export interface WebShellSidebarSessionActionsOptions {
|
|
|
41
41
|
items?: readonly WebShellSidebarSessionActionItem[];
|
|
42
42
|
/**
|
|
43
43
|
* Which items appear as inline buttons on standard session rows (on hover).
|
|
44
|
-
* Defaults to
|
|
44
|
+
* Defaults to none so titles keep the available width. Coarse-pointer
|
|
45
|
+
* devices always keep these actions in the dropdown instead.
|
|
45
46
|
* archive stays in the dropdown so a stray click on the hover slot cannot
|
|
46
47
|
* archive a session.
|
|
47
48
|
* Only items that also pass their built-in visibility condition are rendered.
|
|
@@ -54,6 +55,7 @@ export interface WebShellSidebarSessionActionsOptions {
|
|
|
54
55
|
inlineItems?: readonly WebShellSidebarSessionInlineActionItem[];
|
|
55
56
|
}
|
|
56
57
|
export declare const DEFAULT_SESSION_ACTION_ITEMS: readonly WebShellSidebarSessionActionItem[];
|
|
58
|
+
export declare const DEFAULT_INLINE_ACTION_ITEMS: readonly WebShellSidebarSessionInlineActionItem[];
|
|
57
59
|
export interface WebShellSidebarWorkspaceOverviewOptions {
|
|
58
60
|
/**
|
|
59
61
|
* Facet chips under an expanded workspace row. Defaults to every facet
|
|
@@ -86,6 +88,9 @@ interface WebShellSidebarProps {
|
|
|
86
88
|
onOpenPrWatches?: () => void;
|
|
87
89
|
onOpenWorkflows: () => void;
|
|
88
90
|
onOpenGoals: () => void;
|
|
91
|
+
/** Opens the workspace artifact library page; absent when the daemon does
|
|
92
|
+
* not advertise `workspace_artifact_library`. */
|
|
93
|
+
onOpenArtifacts?: () => void;
|
|
89
94
|
onOpenSessions: () => void;
|
|
90
95
|
/**
|
|
91
96
|
* Whether to offer the Session Overview entry point. The table handles
|
|
@@ -177,10 +182,8 @@ interface WebShellSidebarProps {
|
|
|
177
182
|
*/
|
|
178
183
|
workspaceOverview?: false | WebShellSidebarWorkspaceOverviewOptions;
|
|
179
184
|
/**
|
|
180
|
-
* Open a management page (MCP, skills,
|
|
181
|
-
*
|
|
182
|
-
* connection's bound workspace, so another workspace's row cannot open its
|
|
183
|
-
* own view yet (#10399, layer B1).
|
|
185
|
+
* Open a management page (MCP, skills, extensions, channels, settings,
|
|
186
|
+
* context, hooks) scoped to the clicked workspace.
|
|
184
187
|
*/
|
|
185
188
|
onOpenWorkspaceManagement?: (target: WorkspaceManagementTarget, workspaceCwd: string) => void;
|
|
186
189
|
/** Start a new session that works in an isolated git worktree. */
|
|
@@ -189,4 +192,4 @@ interface WebShellSidebarProps {
|
|
|
189
192
|
onLoadStandaloneSession?: (sessionId: string, displayName?: string) => Promise<void> | void;
|
|
190
193
|
onStandaloneNotice?: (message: string) => void;
|
|
191
194
|
}
|
|
192
|
-
export declare function WebShellSidebar({ collapsed, layout, activePage, containerWidth, onOpenHome, onCollapsedChange, onOpenSettings, canOpenSettings, onOpenAgents, onOpenPlugins, onOpenChannels, onOpenChannelEvents, onOpenLive, onLiveVoiceSlotChange, onOpenManagedSessions, onOpenDaemonStatus, onOpenScheduledTasks, onOpenPrWatches, onOpenWorkflows, onOpenGoals, onOpenSessions, canOpenSessionsOverview, onOpenWorkspacesOverview, onOpenSplitView, onAddSessionToSplitView, splitSessionIds, canOpenSplitView, onNewSession, onNewStandaloneSession, standaloneSessionsReloadToken, onLoadSession, onOpenHostSession, onSelectCurrentSession, onSessionArchived, onSessionRenameConfirmed, onSessionsDeleted, onError, theme, onThemeChange, mobileOpen, onMobileClose, selectedWorkspaceCwd, onSelectWorkspace, onOpenGitDiff, onOpenCommit, onOpenAddWorkspace, workspaces: providedWorkspaces, lockedWorkspaceCwd, lockedWorkspace: lockedWorkspaceOptions, branding, primaryNav: primaryNavOptions, sessionContent, sessionHeader, managedWorkspaces, managedArchivedSessions, archivedSessionsTarget, onSearchQueryChange, currentSessionActive, showSessionSourceSwitch, showLive, hideProjectHeader, sessionActions: sessionActionsOptions, footer, workspaceOverview, onOpenWorkspaceManagement, onNewWorktreeSession, projectFeaturesEnabled, onLoadStandaloneSession, onStandaloneNotice, }: WebShellSidebarProps): import("react/jsx-runtime").JSX.Element;
|
|
195
|
+
export declare function WebShellSidebar({ collapsed, layout, activePage, containerWidth, onOpenHome, onCollapsedChange, onOpenSettings, canOpenSettings, onOpenAgents, onOpenPlugins, onOpenChannels, onOpenChannelEvents, onOpenLive, onLiveVoiceSlotChange, onOpenManagedSessions, onOpenDaemonStatus, onOpenScheduledTasks, onOpenPrWatches, onOpenWorkflows, onOpenGoals, onOpenArtifacts, onOpenSessions, canOpenSessionsOverview, onOpenWorkspacesOverview, onOpenSplitView, onAddSessionToSplitView, splitSessionIds, canOpenSplitView, onNewSession, onNewStandaloneSession, standaloneSessionsReloadToken, onLoadSession, onOpenHostSession, onSelectCurrentSession, onSessionArchived, onSessionRenameConfirmed, onSessionsDeleted, onError, theme, onThemeChange, mobileOpen, onMobileClose, selectedWorkspaceCwd, onSelectWorkspace, onOpenGitDiff, onOpenCommit, onOpenAddWorkspace, workspaces: providedWorkspaces, lockedWorkspaceCwd, lockedWorkspace: lockedWorkspaceOptions, branding, primaryNav: primaryNavOptions, sessionContent, sessionHeader, managedWorkspaces, managedArchivedSessions, archivedSessionsTarget, onSearchQueryChange, currentSessionActive, showSessionSourceSwitch, showLive, hideProjectHeader, sessionActions: sessionActionsOptions, footer, workspaceOverview, onOpenWorkspaceManagement, onNewWorktreeSession, projectFeaturesEnabled, onLoadStandaloneSession, onStandaloneNotice, }: WebShellSidebarProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -37,6 +37,17 @@ interface WorkspaceDetailsTooltipProps {
|
|
|
37
37
|
onBranchChanged: () => void;
|
|
38
38
|
};
|
|
39
39
|
onOpenChange?: (open: boolean) => void;
|
|
40
|
+
/**
|
|
41
|
+
* Optional handler invoked when the user clicks a manageable overview row
|
|
42
|
+
* (MCP, skills, extensions, channels, context, hooks). Rows without a
|
|
43
|
+
* handler or excluded by `manageableItems` stay read-only.
|
|
44
|
+
*/
|
|
45
|
+
onOpenOverviewItem?: (item: WorkspaceOverviewItem) => void;
|
|
46
|
+
/**
|
|
47
|
+
* Subset of overview facets that render as clickable management rows when
|
|
48
|
+
* `onOpenOverviewItem` is provided. Defaults to all items when omitted.
|
|
49
|
+
*/
|
|
50
|
+
manageableItems?: ReadonlySet<WorkspaceOverviewItem>;
|
|
40
51
|
children: ReactElement;
|
|
41
52
|
}
|
|
42
53
|
/**
|
|
@@ -45,5 +56,5 @@ interface WorkspaceDetailsTooltipProps {
|
|
|
45
56
|
* takes no persistent space, so known facets show even when their count is
|
|
46
57
|
* zero; only unknown (unreported) facets stay hidden.
|
|
47
58
|
*/
|
|
48
|
-
export declare function WorkspaceDetailsTooltip({ label, cwd, branch, gitStatus, sessions, overview, items, onOpenPathLocally, onOpenTerminalLocally, gitActions, onOpenChange, children, }: WorkspaceDetailsTooltipProps): import("react/jsx-runtime").JSX.Element;
|
|
59
|
+
export declare function WorkspaceDetailsTooltip({ label, cwd, branch, gitStatus, sessions, overview, items, onOpenPathLocally, onOpenTerminalLocally, gitActions, onOpenChange, onOpenOverviewItem, manageableItems, children, }: WorkspaceDetailsTooltipProps): import("react/jsx-runtime").JSX.Element;
|
|
49
60
|
export {};
|
|
@@ -6,13 +6,15 @@
|
|
|
6
6
|
import { type ComponentProps, type CSSProperties } from 'react';
|
|
7
7
|
import type { DaemonWorkspaceCapability } from '@qwen-code/sdk/daemon';
|
|
8
8
|
import { DropdownMenuContent } from '../ui/dropdown-menu';
|
|
9
|
-
import { type
|
|
9
|
+
import { type WorkspaceMenuManagementTarget, type WorkspaceOverviewSnapshot } from './workspaceOverviewModel';
|
|
10
10
|
/**
|
|
11
11
|
* Every action is optional: the sidebar passes only what the workspace's
|
|
12
12
|
* trust, lock and registration state allows, and the menu lays out whatever
|
|
13
13
|
* it gets. An empty action set renders nothing.
|
|
14
14
|
*/
|
|
15
15
|
export interface WorkspaceMenuActions {
|
|
16
|
+
trust?: () => void;
|
|
17
|
+
trustPending?: boolean;
|
|
16
18
|
rename?: () => void;
|
|
17
19
|
copyPath?: () => void;
|
|
18
20
|
openFolder?: () => void;
|
|
@@ -22,7 +24,12 @@ export interface WorkspaceMenuActions {
|
|
|
22
24
|
createGroup?: () => void;
|
|
23
25
|
moveUp?: () => void;
|
|
24
26
|
moveDown?: () => void;
|
|
25
|
-
openManagement?: (target:
|
|
27
|
+
openManagement?: (target: WorkspaceMenuManagementTarget) => void;
|
|
28
|
+
/**
|
|
29
|
+
* Subset of menu management targets offered for this workspace. When
|
|
30
|
+
* omitted, all five targets are offered whenever `openManagement` is set.
|
|
31
|
+
*/
|
|
32
|
+
managementTargets?: readonly WorkspaceMenuManagementTarget[];
|
|
26
33
|
reload?: () => void;
|
|
27
34
|
remove?: () => void;
|
|
28
35
|
}
|
|
@@ -142,6 +142,10 @@ interface WorkspaceSectionProps {
|
|
|
142
142
|
onOpenGitDiff?: (workspaceCwd: string) => void;
|
|
143
143
|
/** Commit entry for the same picker; the row still opens without it. */
|
|
144
144
|
onOpenCommit?: (workspaceCwd: string) => void;
|
|
145
|
+
/** Opens the management view for a clicked overview facet in this workspace. */
|
|
146
|
+
onOpenOverviewItem?: (item: WorkspaceOverviewItem, workspaceCwd: string) => void;
|
|
147
|
+
/** Facets that render as interactive rows in the hover details popover. */
|
|
148
|
+
manageableOverviewItems?: ReadonlySet<WorkspaceOverviewItem>;
|
|
145
149
|
}
|
|
146
|
-
export declare function WorkspaceSection({ workspace, executionLabel, storageKey, remote, renderHeader, hideHeader, client, reloadToken, untrustedLabel, readOnlyLabel, trustToOpenLabel, noSessionsLabel, loadErrorLabel, untitledSessionLabel, organizationEnabled, sessionCatalogRequestsEnabled, sessionGroupCatalog, sessionLiveStateEnabled, sortBy, sourceType, channelGroupingEnabled, ungroupedLabel, searchQuery, expanded: controlledExpanded, expansionRequest, temporarilyCollapsed, dragHandleProps, autoExpandKey, forceAutoExpand, onExpandedChange, renderSessions, renderSession, pendingSession, mapSession, showSessionDetails, headerActions, overviewEnabled, overviewMenuOpen, overviewItems, gitBranchWanted, sessionStats, onRenameGroup, onDeleteGroup, renameGroupLabel, deleteGroupLabel, groupActionsDisabled, excludePinned, limitSessions, editingSessionId, isPinnedSectionMember, onOpenPathLocally, onOpenTerminalLocally, onOpenGitDiff, onOpenCommit, }: WorkspaceSectionProps): import("react/jsx-runtime").JSX.Element;
|
|
150
|
+
export declare function WorkspaceSection({ workspace, executionLabel, storageKey, remote, renderHeader, hideHeader, client, reloadToken, untrustedLabel, readOnlyLabel, trustToOpenLabel, noSessionsLabel, loadErrorLabel, untitledSessionLabel, organizationEnabled, sessionCatalogRequestsEnabled, sessionGroupCatalog, sessionLiveStateEnabled, sortBy, sourceType, channelGroupingEnabled, ungroupedLabel, searchQuery, expanded: controlledExpanded, expansionRequest, temporarilyCollapsed, dragHandleProps, autoExpandKey, forceAutoExpand, onExpandedChange, renderSessions, renderSession, pendingSession, mapSession, showSessionDetails, headerActions, overviewEnabled, overviewMenuOpen, overviewItems, gitBranchWanted, sessionStats, onRenameGroup, onDeleteGroup, renameGroupLabel, deleteGroupLabel, groupActionsDisabled, excludePinned, limitSessions, editingSessionId, isPinnedSectionMember, onOpenPathLocally, onOpenTerminalLocally, onOpenGitDiff, onOpenCommit, onOpenOverviewItem, manageableOverviewItems, }: WorkspaceSectionProps): import("react/jsx-runtime").JSX.Element;
|
|
147
151
|
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const SidebarHoverSuppressionContext: import("react").Context<boolean>;
|
|
@@ -14,8 +14,10 @@ export declare const WORKSPACE_OVERVIEW_ITEMS: readonly ["mcp", "skills", "exten
|
|
|
14
14
|
export type WorkspaceOverviewItem = (typeof WORKSPACE_OVERVIEW_ITEMS)[number];
|
|
15
15
|
/** Hooks are opt-in: most workspaces have none and the chip would only add noise. */
|
|
16
16
|
export declare const DEFAULT_WORKSPACE_OVERVIEW_ITEMS: readonly WorkspaceOverviewItem[];
|
|
17
|
-
/** Management pages
|
|
18
|
-
export type
|
|
17
|
+
/** Management pages exposed inside the workspace `⋮` menu. */
|
|
18
|
+
export type WorkspaceMenuManagementTarget = 'mcp' | 'skills' | 'extensions' | 'channels' | 'settings';
|
|
19
|
+
/** Management targets a workspace row or hover details popover can open. */
|
|
20
|
+
export type WorkspaceManagementTarget = WorkspaceMenuManagementTarget | 'context' | 'hooks';
|
|
19
21
|
export interface WorkspaceSessionStats {
|
|
20
22
|
/** Sessions in the list the stats were computed from. */
|
|
21
23
|
total: number;
|
|
@@ -8,4 +8,6 @@
|
|
|
8
8
|
* panel. Adds and removes go through the daemon's workspace-directory route,
|
|
9
9
|
* which applies them to live sessions and persists the workspace setting.
|
|
10
10
|
*/
|
|
11
|
-
export declare function WorkspaceDirectoriesSection(
|
|
11
|
+
export declare function WorkspaceDirectoriesSection({ workspaceCwd: requestedWorkspaceCwd, }?: {
|
|
12
|
+
workspaceCwd?: string;
|
|
13
|
+
}): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Qwen Team
|
|
4
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
+
*/
|
|
6
|
+
import type { DaemonClient, DaemonWorkspaceCapability } from '@qwen-code/sdk/daemon';
|
|
7
|
+
export interface UseWorkspaceTrustGrantOptions {
|
|
8
|
+
client: DaemonClient;
|
|
9
|
+
workspaces: readonly DaemonWorkspaceCapability[];
|
|
10
|
+
refreshCapabilities?: () => Promise<unknown>;
|
|
11
|
+
onError: (error: unknown, message: string) => void;
|
|
12
|
+
errorMessage: string;
|
|
13
|
+
}
|
|
14
|
+
export interface WorkspaceTrustGrantState {
|
|
15
|
+
trustPendingCwd: string | null;
|
|
16
|
+
grantTrust: (ws: DaemonWorkspaceCapability) => void;
|
|
17
|
+
}
|
|
18
|
+
export declare function useWorkspaceTrustGrant({ client, workspaces, refreshCapabilities, onError, errorMessage, }: UseWorkspaceTrustGrantOptions): WorkspaceTrustGrantState;
|