@codingame/monaco-vscode-katex-common 34.1.3 → 35.0.1
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/package.json +2 -2
- package/vscode/src/vs/base/browser/animationSync.d.ts +36 -0
- package/vscode/src/vs/base/browser/animationSync.js +23 -0
- package/vscode/src/vs/base/browser/ui/pixelSpinner/pixelSpinner.js +23 -2
- package/vscode/src/vs/platform/actions/browser/buttonbar.js +3 -2
- package/vscode/src/vs/platform/agentHost/common/claudeSessionConfigKeys.d.ts +5 -5
- package/vscode/src/vs/platform/agentHost/common/fileEditDiff.d.ts +32 -0
- package/vscode/src/vs/platform/agentHost/common/fileEditDiff.js +33 -0
- package/vscode/src/vs/platform/agentHost/common/meta/agentFeedbackAnnotations.d.ts +90 -0
- package/vscode/src/vs/platform/agentHost/common/meta/agentFeedbackAttachments.d.ts +30 -0
- package/vscode/src/vs/platform/agentHost/common/meta/agentToolCallMeta.d.ts +65 -0
- package/vscode/src/vs/platform/agentHost/common/sessionConfigKeys.d.ts +16 -5
- package/vscode/src/vs/platform/agentHost/common/sessionConfigKeys.js +3 -2
- package/vscode/src/vs/platform/agentHost/common/state/protocol/channels-resource-watch/reducer.d.ts +21 -0
- package/vscode/src/vs/platform/agentHost/common/state/protocol/reducers.d.ts +8 -0
- package/vscode/src/vs/platform/agentHost/common/state/sessionReducers.d.ts +9 -0
- package/vscode/src/vs/platform/mcp/common/modelContextProtocolApps.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/accessibility/chatAccessibilityProvider.js +16 -16
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContinueInAction.d.ts +29 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContinueInAction.js +105 -28
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatElicitationActions.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatExecuteActions.d.ts +15 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatExecuteActions.js +74 -44
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatTitleActions.js +10 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolActions.js +11 -11
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolPicker.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolPicker.js +98 -24
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostChatInputPicker.contribution.d.ts +8 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostChatInputPicker.contribution.js +31 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostChatInputPicker.d.ts +45 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostChatInputPicker.js +163 -37
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostFolderPickerActionItem.d.ts +47 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostFolderPickerActionItem.js +172 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostGenericConfigChips.d.ts +3 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostGenericConfigChips.js +7 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostSessionReferenceAttachment.d.ts +12 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostSnapshotController.d.ts +116 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostSnapshotController.js +348 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/media/agentHostChatInputPicker.css +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/stateToProgressAdapter.d.ts +211 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/stateToProgressAdapter.js +64 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionApprovalModel.d.ts +18 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionApprovalModel.js +13 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionHoverWidget.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionHoverWidget.js +30 -18
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsControl.d.ts +4 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsControl.js +29 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsFilter.js +9 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsOpener.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsViewer.d.ts +24 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsViewer.js +119 -41
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/media/agentsessionsviewer.css +27 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/sessionTypeAvailability.d.ts +63 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/sessionTypeAvailability.js +97 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentWidgets.d.ts +5 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentWidgets.js +105 -88
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/implicitContextAttachment.js +13 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingActions.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingActions.js +46 -48
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingTextModelContentProviders.d.ts +28 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingTextModelContentProviders.js +98 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessionPickerActionItem.d.ts +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessionPickerActionItem.js +9 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/media/chatTurnPills.css +162 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/chatToolRiskAssessmentService.d.ts +9 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/chatToolRiskAssessmentService.js +95 -24
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/toolSetsContribution.d.ts +22 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/toolSetsContribution.js +151 -20
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatAgentHover.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatArtifactsWidget.js +10 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentMarkdownRenderer.js +20 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAgentCommandContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAnonymousRateLimitedPart.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAttachmentsContentPart.d.ts +5 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAttachmentsContentPart.js +61 -17
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAutoModeResolutionContentPart.d.ts +20 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAutoModeResolutionContentPart.js +55 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatChangesSummaryPart.d.ts +6 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatChangesSummaryPart.js +81 -30
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCodeCitationContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCommandContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatConfirmationContentPart.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatConfirmationWidget.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatDisabledClaudeHooksContentPart.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatEditPillElement.d.ts +11 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatEditPillElement.js +13 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatElicitationContentPart.js +9 -33
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatExtensionsContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatExternalEditContentPart.d.ts +6 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatExternalEditContentPart.js +21 -11
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatHookContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatInlineAnchorWidget.js +13 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMarkdownContentPart.d.ts +6 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMarkdownContentPart.js +40 -19
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMcpAuthenticationContentPart.d.ts +35 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMcpAuthenticationContentPart.js +140 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMcpServersInteractionContentPart.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMcpServersStartingContentPart.d.ts +24 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMcpServersStartingContentPart.js +58 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMultiDiffContentPart.d.ts +3 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMultiDiffContentPart.js +29 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatPlanReviewPart.js +30 -30
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatProgressContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuestionCarouselPart.js +44 -44
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuotaExceededPart.d.ts +1 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuotaExceededPart.js +12 -66
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatReferencesContentPart.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatResourceGroupWidget.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatSubagentContentPart.d.ts +39 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatSubagentContentPart.js +167 -43
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatSuggestNextWidget.d.ts +1 -15
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatSuggestNextWidget.js +9 -86
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatSystemNotificationContentPart.d.ts +12 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatSystemNotificationContentPart.js +23 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTextEditContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatThinkingContentPart.d.ts +9 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatThinkingContentPart.js +141 -72
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTipContentPart.js +9 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTodoListWidget.js +17 -17
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatToolInputOutputContentPart.d.ts +2 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatToolInputOutputContentPart.js +17 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTreeContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTurnPillsPart.d.ts +29 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTurnPillsPart.js +110 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatWorkspaceEditContentPart.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/codeBlockPart.js +14 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatAgentFeedbackReviewConfirmation.css +133 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatAutoModeResolution.css +30 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatCodeBlockPill.css +4 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatConfirmationWidget.css +18 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatPlanReview.css +23 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatQuestionCarousel.css +33 -18
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatSubagentContent.css +23 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatTerminalToolProgressPart.css +44 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatThinkingContent.css +2 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatToolConfirmationCarousel.css +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/abstractToolConfirmationSubPart.d.ts +9 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/abstractToolConfirmationSubPart.js +21 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatAgentFeedbackReviewConfirmationSubPart.d.ts +48 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatAgentFeedbackReviewConfirmationSubPart.js +279 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatExtensionsInstallToolSubPart.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMcpAppModel.d.ts +43 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMcpAppModel.js +53 -15
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMcpAppSubPart.d.ts +7 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMcpAppSubPart.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatModifiedFilesConfirmationSubPart.d.ts +4 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatModifiedFilesConfirmationSubPart.js +24 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/{chatMissingSandboxDepsConfirmationSubPart.d.ts → chatSandboxPrerequisiteConfirmationSubPart.d.ts} +3 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/{chatMissingSandboxDepsConfirmationSubPart.js → chatSandboxPrerequisiteConfirmationSubPart.js} +14 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolConfirmationSubPart.d.ts +0 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolConfirmationSubPart.js +30 -59
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolProgressPart.d.ts +2 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolProgressPart.js +41 -29
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolConfirmationCarouselPart.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolConfirmationSubPart.d.ts +2 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolConfirmationSubPart.js +12 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolInvocationPart.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolInvocationPart.js +43 -35
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolOutputPart.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolPartUtilities.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolPostExecuteConfirmationPart.d.ts +2 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolPostExecuteConfirmationPart.js +11 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/toolRiskBadgeHelper.d.ts +18 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/toolRiskBadgeHelper.js +51 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/toolRiskBadgeWidget.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatDragAndDrop.js +11 -11
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListRenderer.d.ts +18 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListRenderer.js +266 -98
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListWidget.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListWidget.js +8 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatRestoreCheckpointActionViewItem.d.ts +32 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatRestoreCheckpointActionViewItem.js +135 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatTurnPills.d.ts +85 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatTurnPills.js +275 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatWidget.d.ts +18 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatWidget.js +84 -37
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatFollowups.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatGoalBannerWidget.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputNotificationService.d.ts +14 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputNotificationWidget.d.ts +6 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputNotificationWidget.js +52 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPart.d.ts +187 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPart.js +435 -139
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputStatePersistence.d.ts +6 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputStatePersistence.js +21 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatModelConfigurationLogic.d.ts +50 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatModelConfigurationLogic.js +49 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatModelConfigurationStore.d.ts +79 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatModelConfigurationStore.js +127 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatModelPicker.d.ts +84 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatModelPicker.js +658 -430
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatModelSelectionLogic.d.ts +72 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatModelSelectionLogic.js +82 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatPhoneInputPresenter.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatSelectedTools.d.ts +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatSelectedTools.js +6 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/delegationSessionPickerActionItem.d.ts +2 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/delegationSessionPickerActionItem.js +23 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/media/chatGoalBannerWidget.css +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/media/chatInputNotificationWidget.css +28 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modePickerActionItem.d.ts +3 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modePickerActionItem.js +15 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modelPickerActionItem.d.ts +60 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modelPickerActionItem.js +18 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/permissionPickerActionItem.d.ts +49 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/permissionPickerActionItem.js +141 -81
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/sessionTargetPickerActionItem.d.ts +7 -15
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/sessionTargetPickerActionItem.js +30 -47
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/workspacePickerActionItem.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/workspacePickerInputActionItem.d.ts +20 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/workspacePickerInputActionItem.js +18 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/media/chat.css +469 -148
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatContextUsageDetails.d.ts +11 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatContextUsageDetails.js +79 -28
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatContextUsageWidget.d.ts +71 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatContextUsageWidget.js +107 -45
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/media/chatContextUsageDetails.css +20 -0
- package/vscode/src/vs/workbench/contrib/chat/common/chatErrorMessages.d.ts +110 -0
- package/vscode/src/vs/workbench/contrib/chat/common/chatErrorMessages.js +37 -0
- package/vscode/src/vs/workbench/contrib/chat/common/chatImageExtraction.d.ts +4 -1
- package/vscode/src/vs/workbench/contrib/chat/common/chatImageExtraction.js +13 -11
- package/vscode/src/vs/workbench/contrib/chat/common/chatPermissionWarnings.d.ts +8 -1
- package/vscode/src/vs/workbench/contrib/chat/common/chatPermissionWarnings.js +57 -21
- package/vscode/src/vs/workbench/contrib/chat/common/widget/chatColors.js +18 -18
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatController.js +4 -4
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatWidget.js +5 -5
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatZoneWidget.js +1 -1
- package/vscode/src/vs/workbench/contrib/inlineChat/common/inlineChat.js +30 -30
- package/vscode/src/vs/workbench/contrib/interactive/browser/replInputHintContentWidget.js +3 -3
- package/vscode/src/vs/workbench/contrib/mcp/browser/mcpToolCallUI.d.ts +39 -8
- package/vscode/src/vs/workbench/contrib/mcp/browser/mcpToolCallUI.js +168 -72
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/executionStatusBarItemController.js +7 -7
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/find/notebookFindWidget.js +2 -2
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/cellOperations.js +2 -2
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/insertCellActions.js +24 -24
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffComponents.js +3 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffElementOutputs.js +7 -7
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditor.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditorBrowser.js +5 -5
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffList.js +1 -1
- package/vscode/src/vs/workbench/contrib/replNotebook/browser/replEditor.js +1 -1
- package/vscode/src/vs/workbench/contrib/replNotebook/browser/replEditorInput.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputStatusActionViewItem.d.ts +0 -30
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputStatusActionViewItem.js +0 -147
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
|
|
2
2
|
import { registerCss } from '@codingame/monaco-vscode-api/css';
|
|
3
3
|
import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib/tslib.es6';
|
|
4
|
-
import { $, scheduleAtNextAnimationFrame, getWindow, DisposableResizeObserver, clearNode, hide } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/dom';
|
|
4
|
+
import { $, scheduleAtNextAnimationFrame, getWindow, DisposableResizeObserver, clearNode, isHTMLElement, hide } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/dom';
|
|
5
5
|
import { alert } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/ui/aria/aria';
|
|
6
6
|
import { DomScrollableElement } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/ui/scrollbar/scrollableElement';
|
|
7
7
|
import { ScrollbarVisibility } from '@codingame/monaco-vscode-api/vscode/vs/base/common/scrollable';
|
|
@@ -62,11 +62,30 @@ function isGenericEditToolId(toolId) {
|
|
|
62
62
|
}
|
|
63
63
|
return lowerToolId.includes("replace") || lowerToolId.includes("patch") || lowerToolId.includes("insertedit") || lowerToolId.includes("insert_edit") || lowerToolId.includes("editfile");
|
|
64
64
|
}
|
|
65
|
-
function
|
|
65
|
+
function isProblemsToolId(toolId) {
|
|
66
|
+
switch (toolId?.toLowerCase()) {
|
|
67
|
+
case "problems":
|
|
68
|
+
case "get_errors":
|
|
69
|
+
case "copilot_geterrors":
|
|
70
|
+
return true;
|
|
71
|
+
default:
|
|
72
|
+
return false;
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
function isNoProblemsFoundResult(toolId, resultText) {
|
|
76
|
+
return isProblemsToolId(toolId) && resultText?.toLowerCase().includes("no problems found") === true;
|
|
77
|
+
}
|
|
78
|
+
function getToolInvocationIcon(toolId, registeredIcon, resultText) {
|
|
79
|
+
if (isNoProblemsFoundResult(toolId, resultText)) {
|
|
80
|
+
return Codicon.search;
|
|
81
|
+
}
|
|
66
82
|
if (registeredIcon) {
|
|
67
83
|
return registeredIcon;
|
|
68
84
|
}
|
|
69
85
|
const lowerToolId = toolId.toLowerCase();
|
|
86
|
+
if (lowerToolId.includes("comment")) {
|
|
87
|
+
return Codicon.comment;
|
|
88
|
+
}
|
|
70
89
|
if (lowerToolId.includes("search") || lowerToolId.includes("grep") || lowerToolId.includes("find") || lowerToolId.includes("list") || lowerToolId.includes("semantic") || lowerToolId.includes("changes") || lowerToolId.includes("codebase") || lowerToolId.includes("checked")) {
|
|
71
90
|
return Codicon.search;
|
|
72
91
|
}
|
|
@@ -86,6 +105,10 @@ function createThinkingIcon(icon) {
|
|
|
86
105
|
iconElement.classList.add(...ThemeIcon.asClassNameArray(icon));
|
|
87
106
|
return iconElement;
|
|
88
107
|
}
|
|
108
|
+
function setThinkingIcon(iconElement, icon) {
|
|
109
|
+
iconElement.className = "chat-thinking-icon";
|
|
110
|
+
iconElement.classList.add(...ThemeIcon.asClassNameArray(icon));
|
|
111
|
+
}
|
|
89
112
|
function extractTitleFromThinkingContent(content) {
|
|
90
113
|
const headerMatch = content.match(/^\*\*([^*]+)\*\*/);
|
|
91
114
|
return headerMatch ? headerMatch[1] : undefined;
|
|
@@ -100,13 +123,13 @@ var WorkingMessageCategory;
|
|
|
100
123
|
WorkingMessageCategory["Terminal"] = "terminal";
|
|
101
124
|
WorkingMessageCategory["Tool"] = "tool";
|
|
102
125
|
})(WorkingMessageCategory || (WorkingMessageCategory = {}));
|
|
103
|
-
const defaultThinkingMessages = [( localize(
|
|
104
|
-
const terminalMessages = [( localize(
|
|
105
|
-
const toolMessages = [( localize(
|
|
126
|
+
const defaultThinkingMessages = [( localize(7977, "Thinking")), ( localize(7978, "Reasoning")), ( localize(7979, "Considering")), ( localize(7980, "Analyzing")), ( localize(7981, "Evaluating")), ( localize(7982, "Working"))];
|
|
127
|
+
const terminalMessages = [( localize(7983, "Executing")), ( localize(7984, "Running")), ( localize(7985, "Processing"))];
|
|
128
|
+
const toolMessages = [( localize(7986, "Processing")), ( localize(7987, "Preparing")), ( localize(7988, "Loading")), ( localize(7989, "Analyzing")), ( localize(7990, "Evaluating"))];
|
|
106
129
|
const funWorkingMessages = [(
|
|
107
|
-
localize(
|
|
108
|
-
localize(
|
|
109
|
-
localize(
|
|
130
|
+
localize(7991, "Bribing the hamster")), ( localize(7992, "Reticulating splines")), ( localize(7993, "Untangling the spaghetti")), ( localize(7994, "Communing with the codebase")), (
|
|
131
|
+
localize(7995, "Mining diamonds")), (
|
|
132
|
+
localize(7996, "Summoning Clippy"))];
|
|
110
133
|
const FUN_WORKING_MESSAGE_RATE = 50;
|
|
111
134
|
function getCustomThinkingPhrases(configurationService) {
|
|
112
135
|
const config = configurationService.getValue(ChatConfiguration.ThinkingPhrases);
|
|
@@ -185,7 +208,7 @@ let ChatThinkingContentPart = ChatThinkingContentPart_1 = class ChatThinkingCont
|
|
|
185
208
|
contextKeyService
|
|
186
209
|
) {
|
|
187
210
|
const initialText = extractTextFromPart(content);
|
|
188
|
-
const extractedTitle = extractTitleFromThinkingContent(initialText) ?? ( localize(
|
|
211
|
+
const extractedTitle = extractTitleFromThinkingContent(initialText) ?? ( localize(7997, "Thinking"));
|
|
189
212
|
super(extractedTitle, context, undefined, hoverService, configurationService);
|
|
190
213
|
this.chatContentMarkdownRenderer = chatContentMarkdownRenderer;
|
|
191
214
|
this.streamingCompleted = streamingCompleted;
|
|
@@ -196,8 +219,8 @@ let ChatThinkingContentPart = ChatThinkingContentPart_1 = class ChatThinkingCont
|
|
|
196
219
|
this.storageService = storageService;
|
|
197
220
|
this._onDidChangeHeight = this._register(( new Emitter()));
|
|
198
221
|
this._asyncRenderCallback = () => this._onDidChangeHeight.fire();
|
|
199
|
-
this.defaultTitle = ( localize(
|
|
200
|
-
this.workingTitle = ( localize(
|
|
222
|
+
this.defaultTitle = ( localize(7998, "Thinking"));
|
|
223
|
+
this.workingTitle = ( localize(7999, "Working"));
|
|
201
224
|
this._markdownResult = this._register(( new MutableDisposable()));
|
|
202
225
|
this.fixedScrollingMode = false;
|
|
203
226
|
this.autoScrollEnabled = true;
|
|
@@ -220,6 +243,7 @@ let ChatThinkingContentPart = ChatThinkingContentPart_1 = class ChatThinkingCont
|
|
|
220
243
|
this.isUpdatingDimensions = false;
|
|
221
244
|
this.lastKnownContentHeight = 0;
|
|
222
245
|
this.lastKnownScrollTop = 0;
|
|
246
|
+
this._pendingExternalResources = ( new Map());
|
|
223
247
|
this._titleDetailRendered = this._register(( new MutableDisposable()));
|
|
224
248
|
this._pendingAppendRefresh = this._register(( new MutableDisposable()));
|
|
225
249
|
this.diffStatsByPartId = ( new Map());
|
|
@@ -243,7 +267,7 @@ let ChatThinkingContentPart = ChatThinkingContentPart_1 = class ChatThinkingCont
|
|
|
243
267
|
this.appendedItemCount++;
|
|
244
268
|
}
|
|
245
269
|
if (this.configurationService.getValue(AccessibilityWorkbenchSettingId.VerboseChatProgressUpdates)) {
|
|
246
|
-
alert(( localize(
|
|
270
|
+
alert(( localize(8000, "Thinking")));
|
|
247
271
|
}
|
|
248
272
|
if (configuredMode === ThinkingDisplayMode.Collapsed) {
|
|
249
273
|
this.setExpanded(false);
|
|
@@ -604,9 +628,9 @@ let ChatThinkingContentPart = ChatThinkingContentPart_1 = class ChatThinkingCont
|
|
|
604
628
|
diffContainer.appendChild($("span.label-added", {}, `+${added}`));
|
|
605
629
|
diffContainer.appendChild($("span.label-removed", {}, `-${removed}`));
|
|
606
630
|
labelElement.appendChild(diffContainer);
|
|
607
|
-
const insertionsFragment = added === 1 ? ( localize(
|
|
608
|
-
const deletionsFragment = removed === 1 ? ( localize(
|
|
609
|
-
this._collapseButton.element.ariaLabel = ( localize(
|
|
631
|
+
const insertionsFragment = added === 1 ? ( localize(8001, "1 insertion")) : ( localize(8002, "{0} insertions", added));
|
|
632
|
+
const deletionsFragment = removed === 1 ? ( localize(8003, "1 deletion")) : ( localize(8004, "{0} deletions", removed));
|
|
633
|
+
this._collapseButton.element.ariaLabel = ( localize(8005, "{0}, {1}, {2}", title, insertionsFragment, deletionsFragment));
|
|
610
634
|
} else {
|
|
611
635
|
this._collapseButton.element.ariaLabel = title;
|
|
612
636
|
}
|
|
@@ -768,6 +792,7 @@ let ChatThinkingContentPart = ChatThinkingContentPart_1 = class ChatThinkingCont
|
|
|
768
792
|
this.domNode.classList.remove("chat-thinking-persistent-streaming");
|
|
769
793
|
this.domNode.classList.remove("chat-thinking-fade-top", "chat-thinking-fade-bottom");
|
|
770
794
|
this.streamingCompleted = true;
|
|
795
|
+
this.flushPendingExternalResources();
|
|
771
796
|
if (this.wrapperResizeObserverDisposable) {
|
|
772
797
|
this.wrapperResizeObserverDisposable.dispose();
|
|
773
798
|
this.wrapperResizeObserverDisposable = undefined;
|
|
@@ -796,19 +821,17 @@ let ChatThinkingContentPart = ChatThinkingContentPart_1 = class ChatThinkingCont
|
|
|
796
821
|
this.setFinalizedTitle(existingTitle);
|
|
797
822
|
return;
|
|
798
823
|
}
|
|
799
|
-
const
|
|
800
|
-
if (
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
return;
|
|
811
|
-
}
|
|
824
|
+
const allToolsSerialized = this.toolInvocations.every(t => t.kind === "toolInvocationSerialized");
|
|
825
|
+
if (allToolsSerialized && !LocalChatSessionUri.isLocalSession(this.element.sessionResource)) {
|
|
826
|
+
const cacheId = this.getTitleCacheId();
|
|
827
|
+
if (cacheId) {
|
|
828
|
+
const cachedTitle = this.getCachedTitle(cacheId);
|
|
829
|
+
if (cachedTitle) {
|
|
830
|
+
this.currentTitle = cachedTitle;
|
|
831
|
+
this.content.generatedTitle = cachedTitle;
|
|
832
|
+
this.setGeneratedTitleOnAllParts(cachedTitle);
|
|
833
|
+
this.setFinalizedTitle(cachedTitle);
|
|
834
|
+
return;
|
|
812
835
|
}
|
|
813
836
|
}
|
|
814
837
|
}
|
|
@@ -818,12 +841,12 @@ let ChatThinkingContentPart = ChatThinkingContentPart_1 = class ChatThinkingCont
|
|
|
818
841
|
if (lazyItem && lazyItem.kind === "tool") {
|
|
819
842
|
const toolInvocation = lazyItem.toolInvocationOrMarkdown && (lazyItem.toolInvocationOrMarkdown.kind === "toolInvocation" || lazyItem.toolInvocationOrMarkdown.kind === "toolInvocationSerialized") ? lazyItem.toolInvocationOrMarkdown : undefined;
|
|
820
843
|
const result = lazyItem.lazy.value;
|
|
821
|
-
this.
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
844
|
+
this.appendItemToDOM(
|
|
845
|
+
result.domNode,
|
|
846
|
+
lazyItem.toolInvocationId,
|
|
847
|
+
lazyItem.toolInvocationOrMarkdown,
|
|
848
|
+
lazyItem.originalParent
|
|
849
|
+
);
|
|
827
850
|
if (result.disposable) {
|
|
828
851
|
const toolCallId = toolInvocation?.toolCallId;
|
|
829
852
|
if (toolCallId) {
|
|
@@ -834,8 +857,7 @@ let ChatThinkingContentPart = ChatThinkingContentPart_1 = class ChatThinkingCont
|
|
|
834
857
|
}
|
|
835
858
|
}
|
|
836
859
|
}
|
|
837
|
-
|
|
838
|
-
if (toolIsComplete && this.singleItemInfo && this.restoreSingleItemToOriginalPosition()) {
|
|
860
|
+
if (this.singleItemInfo && this.restoreSingleItemToOriginalPosition()) {
|
|
839
861
|
return;
|
|
840
862
|
}
|
|
841
863
|
}
|
|
@@ -877,17 +899,24 @@ let ChatThinkingContentPart = ChatThinkingContentPart_1 = class ChatThinkingCont
|
|
|
877
899
|
);
|
|
878
900
|
}
|
|
879
901
|
}
|
|
880
|
-
getTitleCacheKey(
|
|
881
|
-
return `${chatSessionResourceToId(this.element.sessionResource)}:${
|
|
902
|
+
getTitleCacheKey(id) {
|
|
903
|
+
return `${chatSessionResourceToId(this.element.sessionResource)}:${id}`;
|
|
904
|
+
}
|
|
905
|
+
getTitleCacheId() {
|
|
906
|
+
const lastTool = this.toolInvocations[this.toolInvocations.length - 1];
|
|
907
|
+
if (lastTool) {
|
|
908
|
+
return lastTool.toolCallId;
|
|
909
|
+
}
|
|
910
|
+
return this.allThinkingParts.find(t => t.id)?.id ?? this.content.id;
|
|
882
911
|
}
|
|
883
|
-
getCachedTitle(
|
|
884
|
-
const entry = this.loadTitleCache()[this.getTitleCacheKey(
|
|
912
|
+
getCachedTitle(id) {
|
|
913
|
+
const entry = this.loadTitleCache()[this.getTitleCacheKey(id)];
|
|
885
914
|
if (!entry || (Date.now() - entry.storedAt) > TITLE_CACHE_TTL_MS) {
|
|
886
915
|
return undefined;
|
|
887
916
|
}
|
|
888
917
|
return entry.title;
|
|
889
918
|
}
|
|
890
|
-
setCachedTitle(
|
|
919
|
+
setCachedTitle(id, title) {
|
|
891
920
|
const cache = this.loadTitleCache();
|
|
892
921
|
const now = Date.now();
|
|
893
922
|
for (const key of ( Object.keys(cache))) {
|
|
@@ -895,7 +924,7 @@ let ChatThinkingContentPart = ChatThinkingContentPart_1 = class ChatThinkingCont
|
|
|
895
924
|
delete cache[key];
|
|
896
925
|
}
|
|
897
926
|
}
|
|
898
|
-
cache[this.getTitleCacheKey(
|
|
927
|
+
cache[this.getTitleCacheKey(id)] = {
|
|
899
928
|
title,
|
|
900
929
|
storedAt: now
|
|
901
930
|
};
|
|
@@ -1059,9 +1088,9 @@ ${this.hookCount > 0 ? `EXAMPLES WITH BLOCKED CONTENT (from hooks):
|
|
|
1059
1088
|
this.content.generatedTitle = generatedTitle;
|
|
1060
1089
|
this.setGeneratedTitleOnAllParts(generatedTitle);
|
|
1061
1090
|
if (!LocalChatSessionUri.isLocalSession(this.element.sessionResource)) {
|
|
1062
|
-
const
|
|
1063
|
-
if (
|
|
1064
|
-
this.setCachedTitle(
|
|
1091
|
+
const cacheId = this.getTitleCacheId();
|
|
1092
|
+
if (cacheId) {
|
|
1093
|
+
this.setCachedTitle(cacheId, generatedTitle);
|
|
1065
1094
|
}
|
|
1066
1095
|
}
|
|
1067
1096
|
return;
|
|
@@ -1078,20 +1107,34 @@ ${this.hookCount > 0 ? `EXAMPLES WITH BLOCKED CONTENT (from hooks):
|
|
|
1078
1107
|
}
|
|
1079
1108
|
const {
|
|
1080
1109
|
element,
|
|
1110
|
+
thinkingWrapper,
|
|
1081
1111
|
originalParent,
|
|
1082
1112
|
originalNextSibling,
|
|
1083
1113
|
toolInvocation
|
|
1084
1114
|
} = this.singleItemInfo;
|
|
1085
|
-
|
|
1115
|
+
const hasOtherThinkingItems = this.wrapper && ( Array.from(this.wrapper.children).some(child => child !== thinkingWrapper && child !== this.workingSpinnerElement));
|
|
1116
|
+
if (hasOtherThinkingItems) {
|
|
1086
1117
|
this.singleItemInfo = undefined;
|
|
1087
1118
|
return false;
|
|
1088
1119
|
}
|
|
1089
|
-
|
|
1120
|
+
const precedingToolInvocationPart = isHTMLElement(originalNextSibling) && originalNextSibling.parentElement === originalParent ? originalNextSibling.previousElementSibling : originalParent.lastElementChild;
|
|
1121
|
+
if (toolInvocation) {
|
|
1122
|
+
if (originalNextSibling && originalNextSibling.parentNode === originalParent) {
|
|
1123
|
+
originalParent.insertBefore(element, originalNextSibling);
|
|
1124
|
+
} else {
|
|
1125
|
+
originalParent.appendChild(element);
|
|
1126
|
+
}
|
|
1127
|
+
} else if (precedingToolInvocationPart?.classList.contains("chat-tool-invocation-part")) {
|
|
1128
|
+
precedingToolInvocationPart.appendChild(element);
|
|
1129
|
+
} else if (originalNextSibling && originalNextSibling.parentNode === originalParent) {
|
|
1090
1130
|
originalParent.insertBefore(element, originalNextSibling);
|
|
1091
1131
|
} else {
|
|
1092
1132
|
originalParent.appendChild(element);
|
|
1093
1133
|
}
|
|
1134
|
+
thinkingWrapper.remove();
|
|
1094
1135
|
if (toolInvocation) {
|
|
1136
|
+
this.toolWrappersByCallId.delete(toolInvocation.toolCallId);
|
|
1137
|
+
this.toolIconsByCallId.delete(toolInvocation.toolCallId);
|
|
1095
1138
|
toolInvocation.isAttachedToThinking = false;
|
|
1096
1139
|
}
|
|
1097
1140
|
hide(this.domNode);
|
|
@@ -1114,7 +1157,7 @@ ${this.hookCount > 0 ? `EXAMPLES WITH BLOCKED CONTENT (from hooks):
|
|
|
1114
1157
|
}
|
|
1115
1158
|
}
|
|
1116
1159
|
setFallbackTitle() {
|
|
1117
|
-
const finalLabel = this.appendedItemCount > 0 ? this.appendedItemCount === 1 ? ( localize(
|
|
1160
|
+
const finalLabel = this.appendedItemCount > 0 ? this.appendedItemCount === 1 ? ( localize(8006, "Finished with 1 step")) : ( localize(8007, "Finished with {0} steps", this.appendedItemCount)) : ( localize(8008, "Finished Working"));
|
|
1118
1161
|
this.currentTitle = finalLabel;
|
|
1119
1162
|
if (this.wrapper) {
|
|
1120
1163
|
this.wrapper.classList.remove("chat-thinking-streaming");
|
|
@@ -1122,6 +1165,7 @@ ${this.hookCount > 0 ? `EXAMPLES WITH BLOCKED CONTENT (from hooks):
|
|
|
1122
1165
|
this.domNode.classList.remove("chat-thinking-active");
|
|
1123
1166
|
this.domNode.classList.remove("chat-thinking-persistent-streaming");
|
|
1124
1167
|
this.streamingCompleted = true;
|
|
1168
|
+
this.flushPendingExternalResources();
|
|
1125
1169
|
if (this._collapseButton) {
|
|
1126
1170
|
this._collapseButton.icon = Codicon.check;
|
|
1127
1171
|
this.setFinalizedTitle(finalLabel);
|
|
@@ -1202,6 +1246,7 @@ ${this.hookCount > 0 ? `EXAMPLES WITH BLOCKED CONTENT (from hooks):
|
|
|
1202
1246
|
this.toolInvocations.splice(toolInvocationsIndex, 1);
|
|
1203
1247
|
}
|
|
1204
1248
|
this.toolLabelsByCallId.delete(toolCallId);
|
|
1249
|
+
this._pendingExternalResources.delete(toolCallId);
|
|
1205
1250
|
this._externalResourceWidget.removeToolInvocation(toolCallId);
|
|
1206
1251
|
this.updateWorkingSpinnerVisibility();
|
|
1207
1252
|
this.updateDropdownClickability();
|
|
@@ -1240,6 +1285,7 @@ ${this.hookCount > 0 ? `EXAMPLES WITH BLOCKED CONTENT (from hooks):
|
|
|
1240
1285
|
if (removedItem.kind === "tool" && removedItem.toolInvocationOrMarkdown && (removedItem.toolInvocationOrMarkdown.kind === "toolInvocation" || removedItem.toolInvocationOrMarkdown.kind === "toolInvocationSerialized")) {
|
|
1241
1286
|
removedItem.toolInvocationOrMarkdown.isAttachedToThinking = false;
|
|
1242
1287
|
const toolCallId = removedItem.toolInvocationOrMarkdown.toolCallId;
|
|
1288
|
+
this._pendingExternalResources.delete(toolCallId);
|
|
1243
1289
|
this._externalResourceWidget.removeToolInvocation(toolCallId);
|
|
1244
1290
|
const label = this.toolLabelsByCallId.get(toolCallId);
|
|
1245
1291
|
if (label) {
|
|
@@ -1317,6 +1363,7 @@ ${this.hookCount > 0 ? `EXAMPLES WITH BLOCKED CONTENT (from hooks):
|
|
|
1317
1363
|
this.extractedTitles.splice(titleIndex, 1);
|
|
1318
1364
|
}
|
|
1319
1365
|
this.toolLabelsByCallId.delete(toolCallId);
|
|
1366
|
+
this._pendingExternalResources.delete(toolCallId);
|
|
1320
1367
|
this._externalResourceWidget.removeToolInvocation(toolCallId);
|
|
1321
1368
|
this.updateWorkingSpinnerVisibility();
|
|
1322
1369
|
this.updateDropdownClickability();
|
|
@@ -1341,7 +1388,7 @@ ${this.hookCount > 0 ? `EXAMPLES WITH BLOCKED CONTENT (from hooks):
|
|
|
1341
1388
|
const message = typeof toolInvocationOrMarkdown.invocationMessage === "string" ? toolInvocationOrMarkdown.invocationMessage : toolInvocationOrMarkdown.invocationMessage.value;
|
|
1342
1389
|
const isStreamingEditTool = toolInvocationOrMarkdown.kind === "toolInvocation" && IChatToolInvocation.isStreaming(toolInvocationOrMarkdown) && isGenericEditToolId(toolInvocationOrMarkdown.toolId);
|
|
1343
1390
|
if (isStreamingEditTool) {
|
|
1344
|
-
toolCallLabel = ( localize(
|
|
1391
|
+
toolCallLabel = ( localize(8009, "Editing files"));
|
|
1345
1392
|
} else {
|
|
1346
1393
|
toolCallLabel = message;
|
|
1347
1394
|
}
|
|
@@ -1398,8 +1445,7 @@ ${this.hookCount > 0 ? `EXAMPLES WITH BLOCKED CONTENT (from hooks):
|
|
|
1398
1445
|
const iconEl = this.toolIconsByCallId.get(toolCallId);
|
|
1399
1446
|
if (iconEl) {
|
|
1400
1447
|
const newIcon = termData.commandLine?.isSandboxWrapped ? Codicon.terminalSecure : Codicon.terminal;
|
|
1401
|
-
iconEl
|
|
1402
|
-
iconEl.classList.add(...ThemeIcon.asClassNameArray(newIcon));
|
|
1448
|
+
setThinkingIcon(iconEl, newIcon);
|
|
1403
1449
|
}
|
|
1404
1450
|
}
|
|
1405
1451
|
if (toolInvocationOrMarkdown.presentation === "hidden") {
|
|
@@ -1422,6 +1468,12 @@ ${this.hookCount > 0 ? `EXAMPLES WITH BLOCKED CONTENT (from hooks):
|
|
|
1422
1468
|
}
|
|
1423
1469
|
if (currentState.type === IChatToolInvocation.StateKind.Completed) {
|
|
1424
1470
|
this.updateExternalResourceParts(toolInvocationOrMarkdown);
|
|
1471
|
+
const completedMessage = toolInvocationOrMarkdown.pastTenseMessage ?? toolInvocationOrMarkdown.invocationMessage;
|
|
1472
|
+
const completedText = typeof completedMessage === "string" ? completedMessage : completedMessage.value;
|
|
1473
|
+
const iconElement = this.toolIconsByCallId.get(toolCallId);
|
|
1474
|
+
if (iconElement && isNoProblemsFoundResult(toolInvocationOrMarkdown.toolId, completedText)) {
|
|
1475
|
+
setThinkingIcon(iconElement, Codicon.search);
|
|
1476
|
+
}
|
|
1425
1477
|
}
|
|
1426
1478
|
isComplete = true;
|
|
1427
1479
|
return;
|
|
@@ -1461,24 +1513,24 @@ ${this.hookCount > 0 ? `EXAMPLES WITH BLOCKED CONTENT (from hooks):
|
|
|
1461
1513
|
const codeblockInfo = extractCodeblockUrisFromText(toolInvocationOrMarkdown.content.value);
|
|
1462
1514
|
if (codeblockInfo?.uri) {
|
|
1463
1515
|
const filename = basename(codeblockInfo.uri);
|
|
1464
|
-
toolCallLabel = ( localize(
|
|
1516
|
+
toolCallLabel = ( localize(8010, "Edited {0}", filename));
|
|
1465
1517
|
} else {
|
|
1466
|
-
toolCallLabel = ( localize(
|
|
1518
|
+
toolCallLabel = ( localize(8011, "Edited file"));
|
|
1467
1519
|
}
|
|
1468
1520
|
} else if (toolInvocationOrMarkdown?.kind === "externalEdit") {
|
|
1469
1521
|
const filename = basename(toolInvocationOrMarkdown.uri);
|
|
1470
1522
|
switch (toolInvocationOrMarkdown.editKind) {
|
|
1471
1523
|
case "create":
|
|
1472
|
-
toolCallLabel = ( localize(
|
|
1524
|
+
toolCallLabel = ( localize(8012, "Created {0}", filename));
|
|
1473
1525
|
break;
|
|
1474
1526
|
case "delete":
|
|
1475
|
-
toolCallLabel = ( localize(
|
|
1527
|
+
toolCallLabel = ( localize(8013, "Deleted {0}", filename));
|
|
1476
1528
|
break;
|
|
1477
1529
|
case "rename":
|
|
1478
|
-
toolCallLabel = ( localize(
|
|
1530
|
+
toolCallLabel = ( localize(8014, "Renamed {0}", filename));
|
|
1479
1531
|
break;
|
|
1480
1532
|
case "edit":
|
|
1481
|
-
toolCallLabel = ( localize(
|
|
1533
|
+
toolCallLabel = ( localize(8010, "Edited {0}", filename));
|
|
1482
1534
|
break;
|
|
1483
1535
|
}
|
|
1484
1536
|
} else {
|
|
@@ -1493,6 +1545,10 @@ ${this.hookCount > 0 ? `EXAMPLES WITH BLOCKED CONTENT (from hooks):
|
|
|
1493
1545
|
}
|
|
1494
1546
|
}
|
|
1495
1547
|
updateExternalResourceParts(toolInvocation) {
|
|
1548
|
+
if (this.fixedScrollingMode && !this.streamingCompleted && !this.element.isComplete) {
|
|
1549
|
+
this._pendingExternalResources.set(toolInvocation.toolCallId, toolInvocation);
|
|
1550
|
+
return;
|
|
1551
|
+
}
|
|
1496
1552
|
const extractedImages = extractImagesFromToolInvocationOutputDetails(toolInvocation, this.element.sessionResource);
|
|
1497
1553
|
if (extractedImages.length === 0) {
|
|
1498
1554
|
return;
|
|
@@ -1505,21 +1561,20 @@ ${this.hookCount > 0 ? `EXAMPLES WITH BLOCKED CONTENT (from hooks):
|
|
|
1505
1561
|
})));
|
|
1506
1562
|
this._externalResourceWidget.setToolInvocationParts(toolInvocation.toolCallId, parts);
|
|
1507
1563
|
}
|
|
1564
|
+
flushPendingExternalResources() {
|
|
1565
|
+
if (this._pendingExternalResources.size === 0) {
|
|
1566
|
+
return;
|
|
1567
|
+
}
|
|
1568
|
+
const pending = Array.from(( this._pendingExternalResources.values()));
|
|
1569
|
+
this._pendingExternalResources.clear();
|
|
1570
|
+
for (const toolInvocation of pending) {
|
|
1571
|
+
this.updateExternalResourceParts(toolInvocation);
|
|
1572
|
+
}
|
|
1573
|
+
}
|
|
1508
1574
|
appendItemToDOM(content, toolInvocationId, toolInvocationOrMarkdown, originalParent) {
|
|
1509
1575
|
if (!content.hasChildNodes() || content.textContent?.trim() === "") {
|
|
1510
1576
|
return;
|
|
1511
1577
|
}
|
|
1512
|
-
if (this.toolInvocationCount === 1 && this.hookCount === 0 && originalParent) {
|
|
1513
|
-
const toolInvocation = toolInvocationOrMarkdown && (toolInvocationOrMarkdown.kind === "toolInvocation" || toolInvocationOrMarkdown.kind === "toolInvocationSerialized") ? toolInvocationOrMarkdown : undefined;
|
|
1514
|
-
this.singleItemInfo = {
|
|
1515
|
-
element: content,
|
|
1516
|
-
originalParent,
|
|
1517
|
-
originalNextSibling: this.domNode,
|
|
1518
|
-
toolInvocation
|
|
1519
|
-
};
|
|
1520
|
-
} else {
|
|
1521
|
-
this.singleItemInfo = undefined;
|
|
1522
|
-
}
|
|
1523
1578
|
const itemWrapper = $(".chat-thinking-tool-wrapper");
|
|
1524
1579
|
const isMarkdownEdit = toolInvocationOrMarkdown?.kind === "markdownContent";
|
|
1525
1580
|
const isExternalEdit = toolInvocationOrMarkdown?.kind === "externalEdit";
|
|
@@ -1527,7 +1582,9 @@ ${this.hookCount > 0 ? `EXAMPLES WITH BLOCKED CONTENT (from hooks):
|
|
|
1527
1582
|
const isSearchTool = toolInvocationOrMarkdown && (toolInvocationOrMarkdown.kind === "toolInvocation" || toolInvocationOrMarkdown.kind === "toolInvocationSerialized") && toolInvocationOrMarkdown.toolSpecificData?.kind === "search";
|
|
1528
1583
|
const toolInvocationIcon = toolInvocationOrMarkdown && (toolInvocationOrMarkdown.kind === "toolInvocation" || toolInvocationOrMarkdown.kind === "toolInvocationSerialized") ? toolInvocationOrMarkdown.icon : undefined;
|
|
1529
1584
|
let icon;
|
|
1530
|
-
if (
|
|
1585
|
+
if (isNoProblemsFoundResult(toolInvocationId, content.textContent ?? undefined)) {
|
|
1586
|
+
icon = Codicon.search;
|
|
1587
|
+
} else if (isMarkdownEdit || isExternalEdit) {
|
|
1531
1588
|
icon = Codicon.pencil;
|
|
1532
1589
|
} else if (isSearchTool) {
|
|
1533
1590
|
icon = Codicon.search;
|
|
@@ -1547,11 +1604,23 @@ ${this.hookCount > 0 ? `EXAMPLES WITH BLOCKED CONTENT (from hooks):
|
|
|
1547
1604
|
} else if (content.classList.contains("chat-hook-outcome-warning")) {
|
|
1548
1605
|
icon = Codicon.warning;
|
|
1549
1606
|
} else {
|
|
1550
|
-
icon = toolInvocationId ? getToolInvocationIcon(toolInvocationId, toolInvocationIcon) : Codicon.tools;
|
|
1607
|
+
icon = toolInvocationId ? getToolInvocationIcon(toolInvocationId, toolInvocationIcon, content.textContent ?? undefined) : Codicon.tools;
|
|
1551
1608
|
}
|
|
1552
1609
|
const iconElement = createThinkingIcon(icon);
|
|
1553
1610
|
itemWrapper.appendChild(iconElement);
|
|
1554
1611
|
itemWrapper.appendChild(content);
|
|
1612
|
+
if (this.toolInvocationCount === 1 && this.hookCount === 0 && originalParent) {
|
|
1613
|
+
const toolInvocation = toolInvocationOrMarkdown && (toolInvocationOrMarkdown.kind === "toolInvocation" || toolInvocationOrMarkdown.kind === "toolInvocationSerialized") ? toolInvocationOrMarkdown : undefined;
|
|
1614
|
+
this.singleItemInfo = {
|
|
1615
|
+
element: content,
|
|
1616
|
+
thinkingWrapper: itemWrapper,
|
|
1617
|
+
originalParent,
|
|
1618
|
+
originalNextSibling: this.domNode,
|
|
1619
|
+
toolInvocation
|
|
1620
|
+
};
|
|
1621
|
+
} else {
|
|
1622
|
+
this.singleItemInfo = undefined;
|
|
1623
|
+
}
|
|
1555
1624
|
const isToolInvocation = toolInvocationOrMarkdown && (toolInvocationOrMarkdown.kind === "toolInvocation" || toolInvocationOrMarkdown.kind === "toolInvocationSerialized");
|
|
1556
1625
|
if (isToolInvocation && toolInvocationOrMarkdown.toolCallId) {
|
|
1557
1626
|
this.toolWrappersByCallId.set(toolInvocationOrMarkdown.toolCallId, itemWrapper);
|
|
@@ -1682,7 +1751,7 @@ ${this.hookCount > 0 ? `EXAMPLES WITH BLOCKED CONTENT (from hooks):
|
|
|
1682
1751
|
return;
|
|
1683
1752
|
}
|
|
1684
1753
|
this.lastExtractedTitle = title;
|
|
1685
|
-
const thinkingLabel = ( localize(
|
|
1754
|
+
const thinkingLabel = ( localize(8015, "{0}: {1}", this.defaultTitle, title));
|
|
1686
1755
|
this.currentTitle = thinkingLabel;
|
|
1687
1756
|
if (!this._collapseButton) {
|
|
1688
1757
|
return;
|
|
@@ -1693,7 +1762,7 @@ ${this.hookCount > 0 ? `EXAMPLES WITH BLOCKED CONTENT (from hooks):
|
|
|
1693
1762
|
this.titleShimmerSpan = $("span.chat-thinking-title-shimmer");
|
|
1694
1763
|
labelElement.appendChild(this.titleShimmerSpan);
|
|
1695
1764
|
}
|
|
1696
|
-
this.titleShimmerSpan.textContent = ( localize(
|
|
1765
|
+
this.titleShimmerSpan.textContent = ( localize(8016, "{0}: ", this.defaultTitle));
|
|
1697
1766
|
this._titleDetailRendered.clear();
|
|
1698
1767
|
this._titleFileWidgetStore.clear();
|
|
1699
1768
|
const result = this.chatContentMarkdownRenderer.render(( new MarkdownString(title)));
|
package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTipContentPart.js
CHANGED
|
@@ -57,7 +57,7 @@ let ChatTipContentPart = class ChatTipContentPart extends Disposable {
|
|
|
57
57
|
this.domNode = $(".chat-tip-widget");
|
|
58
58
|
this.domNode.tabIndex = 0;
|
|
59
59
|
this.domNode.setAttribute("role", "region");
|
|
60
|
-
this.domNode.setAttribute("aria-roledescription", ( localize(
|
|
60
|
+
this.domNode.setAttribute("aria-roledescription", ( localize(8017, "tip")));
|
|
61
61
|
this._inChatTipContextKey = ChatContextKeys.inChatTip.bindTo(this._contextKeyService);
|
|
62
62
|
this._multipleChatTipsContextKey = ChatContextKeys.multipleChatTips.bindTo(this._contextKeyService);
|
|
63
63
|
const focusTracker = this._register(trackFocus(this.domNode));
|
|
@@ -119,9 +119,9 @@ let ChatTipContentPart = class ChatTipContentPart extends Disposable {
|
|
|
119
119
|
}
|
|
120
120
|
});
|
|
121
121
|
this.domNode.appendChild(toolbarContainer);
|
|
122
|
-
const textContent = markdownContent.element.textContent ?? ( localize(
|
|
122
|
+
const textContent = markdownContent.element.textContent ?? ( localize(8018, "Chat tip"));
|
|
123
123
|
const hasLink = /\[.*?\]\(.*?\)/.test(tip.content.value);
|
|
124
|
-
const ariaLabel = hasLink ? ( localize(
|
|
124
|
+
const ariaLabel = hasLink ? ( localize(8019, "{0} Tab to reach the action.", textContent)) : textContent;
|
|
125
125
|
this.domNode.setAttribute("aria-label", ariaLabel);
|
|
126
126
|
}
|
|
127
127
|
async _handleTipAction(link, mdStr) {
|
|
@@ -149,7 +149,7 @@ registerAction2(class PreviousTipAction extends Action2 {
|
|
|
149
149
|
constructor() {
|
|
150
150
|
super({
|
|
151
151
|
id: "workbench.action.chat.previousTip",
|
|
152
|
-
title: ( localize2(
|
|
152
|
+
title: ( localize2(8020, "Previous tip")),
|
|
153
153
|
icon: Codicon.chevronLeft,
|
|
154
154
|
precondition: ChatContextKeys.multipleChatTips,
|
|
155
155
|
f1: false,
|
|
@@ -169,7 +169,7 @@ registerAction2(class NextTipAction extends Action2 {
|
|
|
169
169
|
constructor() {
|
|
170
170
|
super({
|
|
171
171
|
id: "workbench.action.chat.nextTip",
|
|
172
|
-
title: ( localize2(
|
|
172
|
+
title: ( localize2(8021, "Next tip")),
|
|
173
173
|
icon: Codicon.chevronRight,
|
|
174
174
|
precondition: ChatContextKeys.multipleChatTips,
|
|
175
175
|
f1: false,
|
|
@@ -189,7 +189,7 @@ registerAction2(class DismissTipToolbarAction extends Action2 {
|
|
|
189
189
|
constructor() {
|
|
190
190
|
super({
|
|
191
191
|
id: "workbench.action.chat.dismissTipToolbar",
|
|
192
|
-
title: ( localize2(
|
|
192
|
+
title: ( localize2(8022, "Dismiss tip")),
|
|
193
193
|
icon: Codicon.check,
|
|
194
194
|
f1: false,
|
|
195
195
|
menu: [{
|
|
@@ -207,7 +207,7 @@ registerAction2(class DismissTipAction extends Action2 {
|
|
|
207
207
|
constructor() {
|
|
208
208
|
super({
|
|
209
209
|
id: "workbench.action.chat.dismissTip",
|
|
210
|
-
title: ( localize2(
|
|
210
|
+
title: ( localize2(8023, "Dismiss this tip")),
|
|
211
211
|
f1: false,
|
|
212
212
|
menu: [{
|
|
213
213
|
id: MenuId.ChatTipContext,
|
|
@@ -224,7 +224,7 @@ registerAction2(class DisableTipsAction extends Action2 {
|
|
|
224
224
|
constructor() {
|
|
225
225
|
super({
|
|
226
226
|
id: "workbench.action.chat.disableTips",
|
|
227
|
-
title: ( localize2(
|
|
227
|
+
title: ( localize2(8024, "Disable tips")),
|
|
228
228
|
icon: Codicon.bellSlash,
|
|
229
229
|
f1: false,
|
|
230
230
|
menu: [{
|
|
@@ -249,7 +249,7 @@ registerAction2(class ResetDismissedTipsAction extends Action2 {
|
|
|
249
249
|
constructor() {
|
|
250
250
|
super({
|
|
251
251
|
id: "workbench.action.chat.resetDismissedTips",
|
|
252
|
-
title: ( localize2(
|
|
252
|
+
title: ( localize2(8025, "Reset Dismissed Tips")),
|
|
253
253
|
f1: true,
|
|
254
254
|
precondition: ChatContextKeys.enabled
|
|
255
255
|
});
|