@codingame/monaco-vscode-chat-service-override 24.3.0 → 25.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +35 -35
- package/package.json +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatAccessibilityService.d.ts → accessibility/chatAccessibilityService.d.ts} +10 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatAccessibilityService.js → accessibility/chatAccessibilityService.js} +23 -11
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatResponseAccessibleView.d.ts → accessibility/chatResponseAccessibleView.d.ts} +6 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatResponseAccessibleView.js → accessibility/chatResponseAccessibleView.js} +38 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatTerminalOutputAccessibleView.js → accessibility/chatTerminalOutputAccessibleView.js} +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAccessibilityActions.js +7 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAccessibilityHelp.js +69 -60
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAgentRecommendationActions.js +2 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatClear.d.ts +3 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatClear.js +25 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCodeblockActions.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCodeblockActions.js +24 -22
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContextActions.js +13 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCopyActions.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatDeveloperActions.js +48 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatFileTreeActions.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatImportExport.js +7 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatLanguageModelActions.js +12 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatMoveActions.js +10 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatNewActions.js +16 -19
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatPromptNavigationActions.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQuickInputActions.js +9 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolActions.js +35 -19
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolPicker.d.ts +4 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolPicker.js +22 -17
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatTransfer.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatTransfer.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/codeBlockOperations.d.ts +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/codeBlockOperations.js +21 -21
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessions.contribution.js +31 -53
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsActions.d.ts +61 -25
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsActions.js +482 -125
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsControl.d.ts +16 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsControl.js +84 -93
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsFilter.d.ts +2 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsFilter.js +10 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsOpener.d.ts +7 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsOpener.js +41 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsPicker.d.ts +23 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsPicker.js +137 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsQuickAccess.d.ts +15 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsQuickAccess.js +92 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsViewer.d.ts +81 -32
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsViewer.js +335 -102
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/localAgentSessionsProvider.d.ts +3 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/localAgentSessionsProvider.js +47 -51
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/media/agentsessionsviewer.css +80 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatAttachmentResolveService.d.ts → attachments/chatAttachmentResolveService.d.ts} +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatAttachmentResolveService.js → attachments/chatAttachmentResolveService.js} +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatVariables.d.ts → attachments/chatVariables.d.ts} +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatVariables.js → attachments/chatVariables.js} +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatEditing → attachments}/simpleBrowserEditorOverlay.js +21 -21
- package/vscode/src/vs/workbench/contrib/chat/browser/chat.contribution.js +171 -206
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditing.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCheckpointTimeline.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCheckpointTimelineImpl.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCheckpointTimelineImpl.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCodeEditorIntegration.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCodeEditorIntegration.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorAccessibility.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorAccessibility.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorActions.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorActions.js +20 -20
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorOverlay.js +14 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedDocumentEntry.d.ts +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedDocumentEntry.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedFileEntry.d.ts +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedFileEntry.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedNotebookEntry.d.ts +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedNotebookEntry.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingOperations.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingOperations.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingServiceImpl.d.ts +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingServiceImpl.js +10 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingSession.d.ts +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingSession.js +6 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingSessionStorage.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingTextModelChangeService.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingTextModelChangeService.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingTextModelContentProviders.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingNotebookCellEntry.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingNotebookCellEntry.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingNotebookEditorIntegration.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingNotebookEditorIntegration.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingNotebookFileSystemProvider.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingNotebookFileSystemProvider.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagement.contribution.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditor.js +18 -18
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditorInput.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsViewModel.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsWidget.js +41 -41
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatUsageWidget.js +10 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/chatOutputItemRenderer.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatParticipant.contribution.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatParticipant.contribution.js +35 -35
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatSessions.contribution.d.ts → chatSessions/chatSessions.contribution.d.ts} +7 -11
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatSessions.contribution.js → chatSessions/chatSessions.contribution.js} +53 -106
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupContributions.js +18 -22
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupController.js +10 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupProviders.d.ts +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupProviders.js +29 -29
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupRunner.js +13 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusDashboard.d.ts +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusDashboard.js +64 -64
- package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusEntry.js +12 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/chatWindowNotifier.d.ts +22 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatWindowNotifier.js +90 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatContextService.d.ts → contextContrib/chatContextService.d.ts} +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatContextService.js → contextContrib/chatContextService.js} +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/chatModeActions.js +7 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptCodingAgentActionOverlay.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptToolsCodeLensProvider.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptUrlHandler.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/runPromptAction.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/saveAsPromptFileActions.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/{languageModelToolsConfirmationService.d.ts → tools/languageModelToolsConfirmationService.d.ts} +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/{languageModelToolsConfirmationService.js → tools/languageModelToolsConfirmationService.js} +47 -58
- package/vscode/src/vs/workbench/contrib/chat/browser/{languageModelToolsService.d.ts → tools/languageModelToolsService.d.ts} +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/{languageModelToolsService.js → tools/languageModelToolsService.js} +21 -21
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/toolSetsContribution.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/toolSetsContribution.js +16 -16
- package/vscode/src/vs/workbench/contrib/chat/browser/viewsWelcome/chatViewsWelcomeHandler.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatContentParts → widget/chatContentParts}/chatMarkdownAnchorService.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatLayoutService.d.ts → widget/chatLayoutService.d.ts} +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatWidgetService.d.ts → widget/chatWidgetService.d.ts} +6 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatWidgetService.js → widget/chatWidgetService.js} +27 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatStatusWidget.d.ts → widget/input/chatStatusWidget.d.ts} +4 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatStatusWidget.js → widget/input/chatStatusWidget.js} +17 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/{contrib → widget/input/editor}/chatInputEditorContrib.js +12 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/{contrib → widget/input/editor}/chatInputEditorHover.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/{contrib → widget/input/editor}/chatInputEditorHover.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatQuick.d.ts → widgetHosts/chatQuick.d.ts} +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatQuick.js → widgetHosts/chatQuick.js} +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatEditor.d.ts → widgetHosts/editor/chatEditor.d.ts} +4 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatEditor.js → widgetHosts/editor/chatEditor.js} +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatViewPane.d.ts → widgetHosts/viewPane/chatViewPane.d.ts} +46 -31
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatViewPane.js → widgetHosts/viewPane/chatViewPane.js} +258 -154
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatViewTitleControl.d.ts → widgetHosts/viewPane/chatViewTitleControl.d.ts} +5 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatViewTitleControl.js → widgetHosts/viewPane/chatViewTitleControl.js} +97 -85
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/media/chatViewPane.css +176 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/media/chatViewTitleControl.css +89 -0
- package/vscode/src/vs/workbench/contrib/chat/common/{chatServiceImpl.d.ts → chatService/chatServiceImpl.d.ts} +16 -20
- package/vscode/src/vs/workbench/contrib/chat/common/{chatServiceImpl.js → chatService/chatServiceImpl.js} +97 -151
- package/vscode/src/vs/workbench/contrib/chat/common/{chatServiceTelemetry.d.ts → chatService/chatServiceTelemetry.d.ts} +4 -4
- package/vscode/src/vs/workbench/contrib/chat/common/{chatServiceTelemetry.js → chatService/chatServiceTelemetry.js} +2 -2
- package/vscode/src/vs/workbench/contrib/chat/common/{chatCodeMapperService.d.ts → editing/chatCodeMapperService.d.ts} +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/{chatModelStore.d.ts → model/chatModelStore.d.ts} +2 -2
- package/vscode/src/vs/workbench/contrib/chat/common/{chatProgressTypes → model/chatProgressTypes}/chatToolInvocation.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/chat/common/{chatProgressTypes → model/chatProgressTypes}/chatToolInvocation.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/common/{chatSessionStore.d.ts → model/chatSessionStore.d.ts} +14 -7
- package/vscode/src/vs/workbench/contrib/chat/common/{chatSessionStore.js → model/chatSessionStore.js} +164 -39
- package/vscode/src/vs/workbench/contrib/chat/common/{chatTransferService.d.ts → model/chatTransferService.d.ts} +3 -3
- package/vscode/src/vs/workbench/contrib/chat/common/{chatTransferService.js → model/chatTransferService.js} +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/{chatSlashCommands.d.ts → participants/chatSlashCommands.d.ts} +2 -2
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/chatPromptFilesContribution.js +25 -49
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptBodyAutocompletion.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptBodyAutocompletion.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptCodeActions.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptCodeActions.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptHeaderAutocompletion.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptHeaderAutocompletion.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptHovers.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptHovers.js +29 -29
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptValidator.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptValidator.js +54 -54
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/service/promptsServiceImpl.d.ts +11 -4
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/service/promptsServiceImpl.js +83 -18
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/utils/promptFilesLocator.d.ts +11 -5
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/utils/promptFilesLocator.js +27 -10
- package/vscode/src/vs/workbench/contrib/chat/common/{chatTodoListService.d.ts → tools/chatTodoListService.d.ts} +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/{chatTodoListService.js → tools/chatTodoListService.js} +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/tools/languageModelToolsContribution.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/tools/languageModelToolsContribution.js +29 -29
- package/vscode/src/vs/workbench/contrib/chat/common/voiceChatService.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/chat/common/voiceChatService.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/common/{chatResponseResourceFileSystemProvider.d.ts → widget/chatResponseResourceFileSystemProvider.d.ts} +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/{chatResponseResourceFileSystemProvider.js → widget/chatResponseResourceFileSystemProvider.js} +4 -4
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChat.contribution.js +5 -5
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatAccessibilityHelp.js +1 -1
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatActions.js +23 -23
- package/vscode/src/vs/workbench/contrib/remoteCodingAgents/browser/remoteCodingAgents.contribution.js +7 -7
- package/vscode/src/vs/workbench/contrib/remoteCodingAgents/common/remoteCodingAgentsService.js +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/media/terminalChatWidget.css +1 -0
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatAccessibilityHelp.js +16 -16
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatActions.js +47 -30
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatController.js +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatEnabler.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatEnabler.js +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatService.d.ts +15 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatService.js +33 -11
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatWidget.d.ts +4 -3
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatWidget.js +6 -5
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/alternativeRecommendation.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/basicExecuteStrategy.js +12 -2
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/executeStrategy.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/noneExecuteStrategy.js +17 -2
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/richExecuteStrategy.js +12 -2
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/strategyHelpers.d.ts +10 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/strategyHelpers.js +22 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalHelpers.d.ts +3 -2
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalHelpers.js +100 -23
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/taskHelpers.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/terminal.chatAgentTools.contribution.js +6 -6
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/toolTerminalCreator.d.ts +2 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/toolTerminalCreator.js +19 -6
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/{commandLineAutoApprover.d.ts → tools/commandLineAnalyzer/autoApprove/commandLineAutoApprover.d.ts} +11 -12
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/{commandLineAutoApprover.js → tools/commandLineAnalyzer/autoApprove/commandLineAutoApprover.js} +83 -6
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/autoApprove/npmScriptAutoApprover.d.ts +45 -0
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/autoApprove/npmScriptAutoApprover.js +156 -0
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAnalyzer.d.ts +17 -2
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAnalyzer.js +10 -0
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAutoApproveAnalyzer.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAutoApproveAnalyzer.js +64 -26
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineFileWriteAnalyzer.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineFileWriteAnalyzer.js +16 -8
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineRewriter/commandLinePreventHistoryRewriter.d.ts +14 -0
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineRewriter/commandLinePreventHistoryRewriter.js +31 -0
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalLastCommandTool.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalLastCommandTool.js +4 -4
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalOutputTool.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalOutputTool.js +4 -4
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalSelectionTool.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalSelectionTool.js +4 -4
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/outputMonitor.d.ts +3 -2
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/outputMonitor.js +55 -23
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalConfirmationTool.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalConfirmationTool.js +3 -3
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.d.ts +3 -3
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.js +85 -46
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/createAndRunTaskTool.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/createAndRunTaskTool.js +16 -16
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/getTaskOutputTool.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/getTaskOutputTool.js +9 -9
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/runTaskTool.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/runTaskTool.js +16 -16
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/taskHelpers.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/taskHelpers.js +9 -5
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/terminalCommandArtifactCollector.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatSessionActions.d.ts +0 -46
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatSessionActions.js +0 -248
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsView.d.ts +0 -36
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsView.js +0 -184
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/media/agentsessionsview.css +0 -19
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/view/chatSessionsView.d.ts +0 -22
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/view/chatSessionsView.js +0 -229
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/view/sessionsTreeRenderer.d.ts +0 -102
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/view/sessionsTreeRenderer.js +0 -495
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/view/sessionsViewPane.d.ts +0 -64
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/view/sessionsViewPane.js +0 -386
- package/vscode/src/vs/workbench/contrib/chat/browser/media/chatSessions.css +0 -299
- package/vscode/src/vs/workbench/contrib/chat/browser/media/chatViewPane.css +0 -142
- package/vscode/src/vs/workbench/contrib/chat/browser/media/chatViewTitleControl.css +0 -39
- /package/vscode/src/vs/workbench/contrib/chat/browser/{chatTerminalOutputAccessibleView.d.ts → accessibility/chatTerminalOutputAccessibleView.d.ts} +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/browser/{media → attachments/media}/simpleBrowserOverlay.css +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/browser/{chatEditing → attachments}/simpleBrowserEditorOverlay.d.ts +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/browser/{media → chatEditing/media}/chatEditingEditorOverlay.css +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/browser/{media → chatEditing/media}/chatEditorController.css +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/browser/{chatContentParts → widget/chatContentParts}/chatMarkdownAnchorService.js +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/browser/{chatLayoutService.js → widget/chatLayoutService.js} +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/browser/{chatEdinputInputContentProvider.d.ts → widget/input/editor/chatEditorInputContentProvider.d.ts} +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/browser/{chatEdinputInputContentProvider.js → widget/input/editor/chatEditorInputContentProvider.js} +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/browser/{contrib → widget/input/editor}/chatInputEditorContrib.d.ts +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/browser/{contrib → widget/input/editor}/editorHoverWrapper.d.ts +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/browser/{contrib → widget/input/editor}/editorHoverWrapper.js +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/browser/{contrib → widget/input/editor}/media/editorHoverWrapper.css +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/browser/{media → widget/input/media}/chatStatusWidget.css +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/common/{chatCodeMapperService.js → editing/chatCodeMapperService.js} +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/common/{chatModelStore.js → model/chatModelStore.js} +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/common/{chatSlashCommands.js → participants/chatSlashCommands.js} +0 -0
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
|
|
2
|
+
import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib/tslib.es6';
|
|
3
|
+
import { renderAsPlaintext } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/markdownRenderer';
|
|
4
|
+
import { Codicon } from '@codingame/monaco-vscode-api/vscode/vs/base/common/codicons';
|
|
5
|
+
import { fromNow } from '@codingame/monaco-vscode-api/vscode/vs/base/common/date';
|
|
6
|
+
import { DisposableStore } from '@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle';
|
|
7
|
+
import { ThemeIcon } from '@codingame/monaco-vscode-api/vscode/vs/base/common/themables';
|
|
8
|
+
import { localize } from '@codingame/monaco-vscode-api/vscode/vs/nls';
|
|
9
|
+
import { ICommandService } from '@codingame/monaco-vscode-api/vscode/vs/platform/commands/common/commands.service';
|
|
10
|
+
import { IInstantiationService } from '@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation';
|
|
11
|
+
import { IQuickInputService } from '@codingame/monaco-vscode-api/vscode/vs/platform/quickinput/common/quickInput.service';
|
|
12
|
+
import { openSession } from './agentSessionsOpener.js';
|
|
13
|
+
import { isLocalAgentSessionItem } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsModel';
|
|
14
|
+
import { IAgentSessionsService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsService.service';
|
|
15
|
+
import { AgentSessionsSorter, groupAgentSessions } from './agentSessionsViewer.js';
|
|
16
|
+
import { AGENT_SESSION_RENAME_ACTION_ID, AGENT_SESSION_DELETE_ACTION_ID } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessions';
|
|
17
|
+
|
|
18
|
+
const archiveButton = {
|
|
19
|
+
iconClass: ThemeIcon.asClassName(Codicon.archive),
|
|
20
|
+
tooltip: ( localize(4903, "Archive"))
|
|
21
|
+
};
|
|
22
|
+
const unarchiveButton = {
|
|
23
|
+
iconClass: ThemeIcon.asClassName(Codicon.inbox),
|
|
24
|
+
tooltip: ( localize(4904, "Unarchive"))
|
|
25
|
+
};
|
|
26
|
+
const renameButton = {
|
|
27
|
+
iconClass: ThemeIcon.asClassName(Codicon.edit),
|
|
28
|
+
tooltip: ( localize(4905, "Rename"))
|
|
29
|
+
};
|
|
30
|
+
const deleteButton = {
|
|
31
|
+
iconClass: ThemeIcon.asClassName(Codicon.trash),
|
|
32
|
+
tooltip: ( localize(4906, "Delete"))
|
|
33
|
+
};
|
|
34
|
+
function getSessionDescription(session) {
|
|
35
|
+
const descriptionText = typeof session.description === 'string' ? session.description : session.description ? renderAsPlaintext(session.description) : undefined;
|
|
36
|
+
const timeAgo = fromNow(session.timing.endTime || session.timing.startTime);
|
|
37
|
+
const descriptionParts = [descriptionText, session.providerLabel, timeAgo].filter(part => !!part);
|
|
38
|
+
return descriptionParts.join(' • ');
|
|
39
|
+
}
|
|
40
|
+
function getSessionButtons(session) {
|
|
41
|
+
const buttons = [];
|
|
42
|
+
if (isLocalAgentSessionItem(session)) {
|
|
43
|
+
buttons.push(renameButton);
|
|
44
|
+
buttons.push(deleteButton);
|
|
45
|
+
}
|
|
46
|
+
buttons.push(session.isArchived() ? unarchiveButton : archiveButton);
|
|
47
|
+
return buttons;
|
|
48
|
+
}
|
|
49
|
+
let AgentSessionsPicker = class AgentSessionsPicker {
|
|
50
|
+
constructor(agentSessionsService, quickInputService, instantiationService, commandService) {
|
|
51
|
+
this.agentSessionsService = agentSessionsService;
|
|
52
|
+
this.quickInputService = quickInputService;
|
|
53
|
+
this.instantiationService = instantiationService;
|
|
54
|
+
this.commandService = commandService;
|
|
55
|
+
this.sorter = ( new AgentSessionsSorter());
|
|
56
|
+
}
|
|
57
|
+
async pickAgentSession() {
|
|
58
|
+
const disposables = ( new DisposableStore());
|
|
59
|
+
const picker = disposables.add(this.quickInputService.createQuickPick({ useSeparators: true }));
|
|
60
|
+
picker.items = this.createPickerItems();
|
|
61
|
+
picker.canAcceptInBackground = true;
|
|
62
|
+
picker.placeholder = ( localize(4907, "Search agent sessions by name"));
|
|
63
|
+
disposables.add(picker.onDidAccept(e => {
|
|
64
|
+
const pick = picker.selectedItems[0];
|
|
65
|
+
if (pick) {
|
|
66
|
+
this.instantiationService.invokeFunction(openSession, pick.session, {
|
|
67
|
+
sideBySide: e.inBackground,
|
|
68
|
+
editorOptions: {
|
|
69
|
+
preserveFocus: e.inBackground,
|
|
70
|
+
pinned: e.inBackground
|
|
71
|
+
}
|
|
72
|
+
});
|
|
73
|
+
}
|
|
74
|
+
if (!e.inBackground) {
|
|
75
|
+
picker.hide();
|
|
76
|
+
}
|
|
77
|
+
}));
|
|
78
|
+
disposables.add(picker.onDidTriggerItemButton(async (e) => {
|
|
79
|
+
const session = e.item.session;
|
|
80
|
+
let reopenResolved = false;
|
|
81
|
+
if (e.button === renameButton) {
|
|
82
|
+
reopenResolved = true;
|
|
83
|
+
await this.commandService.executeCommand(AGENT_SESSION_RENAME_ACTION_ID, session);
|
|
84
|
+
}
|
|
85
|
+
else if (e.button === deleteButton) {
|
|
86
|
+
reopenResolved = true;
|
|
87
|
+
await this.commandService.executeCommand(AGENT_SESSION_DELETE_ACTION_ID, session);
|
|
88
|
+
}
|
|
89
|
+
else {
|
|
90
|
+
const newArchivedState = !session.isArchived();
|
|
91
|
+
session.setArchived(newArchivedState);
|
|
92
|
+
}
|
|
93
|
+
if (reopenResolved) {
|
|
94
|
+
await this.agentSessionsService.model.resolve(session.providerType);
|
|
95
|
+
this.pickAgentSession();
|
|
96
|
+
}
|
|
97
|
+
else {
|
|
98
|
+
picker.items = this.createPickerItems();
|
|
99
|
+
}
|
|
100
|
+
}));
|
|
101
|
+
disposables.add(picker.onDidHide(() => disposables.dispose()));
|
|
102
|
+
picker.show();
|
|
103
|
+
}
|
|
104
|
+
createPickerItems() {
|
|
105
|
+
const sessions = this.agentSessionsService.model.sessions.sort(this.sorter.compare.bind(this.sorter));
|
|
106
|
+
const items = [];
|
|
107
|
+
const groupedSessions = groupAgentSessions(sessions);
|
|
108
|
+
for (const group of ( groupedSessions.values())) {
|
|
109
|
+
if (group.sessions.length > 0) {
|
|
110
|
+
items.push({ type: 'separator', label: group.label });
|
|
111
|
+
items.push(...( group.sessions.map(session => this.toPickItem(session))));
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
return items;
|
|
115
|
+
}
|
|
116
|
+
toPickItem(session) {
|
|
117
|
+
const description = getSessionDescription(session);
|
|
118
|
+
const buttons = getSessionButtons(session);
|
|
119
|
+
return {
|
|
120
|
+
id: ( session.resource.toString()),
|
|
121
|
+
label: session.label,
|
|
122
|
+
tooltip: session.tooltip,
|
|
123
|
+
description,
|
|
124
|
+
iconClass: ThemeIcon.asClassName(session.icon),
|
|
125
|
+
buttons,
|
|
126
|
+
session
|
|
127
|
+
};
|
|
128
|
+
}
|
|
129
|
+
};
|
|
130
|
+
AgentSessionsPicker = ( __decorate([
|
|
131
|
+
( __param(0, IAgentSessionsService)),
|
|
132
|
+
( __param(1, IQuickInputService)),
|
|
133
|
+
( __param(2, IInstantiationService)),
|
|
134
|
+
( __param(3, ICommandService))
|
|
135
|
+
], AgentSessionsPicker));
|
|
136
|
+
|
|
137
|
+
export { AgentSessionsPicker, archiveButton, deleteButton, getSessionButtons, getSessionDescription, renameButton, unarchiveButton };
|
package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsQuickAccess.d.ts
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { IQuickPickSeparator } from "@codingame/monaco-vscode-api/vscode/vs/platform/quickinput/common/quickInput";
|
|
2
|
+
import { PickerQuickAccessProvider, IPickerQuickAccessItem } from "@codingame/monaco-vscode-api/vscode/vs/platform/quickinput/browser/pickerQuickAccess";
|
|
3
|
+
import { IInstantiationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation";
|
|
4
|
+
import { IAgentSessionsService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsService.service";
|
|
5
|
+
import { ICommandService } from "@codingame/monaco-vscode-api/vscode/vs/platform/commands/common/commands.service";
|
|
6
|
+
export declare const AGENT_SESSIONS_QUICK_ACCESS_PREFIX = "agent ";
|
|
7
|
+
export declare class AgentSessionsQuickAccessProvider extends PickerQuickAccessProvider<IPickerQuickAccessItem> {
|
|
8
|
+
private readonly agentSessionsService;
|
|
9
|
+
private readonly instantiationService;
|
|
10
|
+
private readonly commandService;
|
|
11
|
+
private readonly sorter;
|
|
12
|
+
constructor(agentSessionsService: IAgentSessionsService, instantiationService: IInstantiationService, commandService: ICommandService);
|
|
13
|
+
protected _getPicks(filter: string): Promise<(IQuickPickSeparator | IPickerQuickAccessItem)[]>;
|
|
14
|
+
private toPickItem;
|
|
15
|
+
}
|
package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsQuickAccess.js
ADDED
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
|
|
2
|
+
import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib/tslib.es6';
|
|
3
|
+
import { PickerQuickAccessProvider, TriggerAction } from '@codingame/monaco-vscode-api/vscode/vs/platform/quickinput/browser/pickerQuickAccess';
|
|
4
|
+
import { localize } from '@codingame/monaco-vscode-api/vscode/vs/nls';
|
|
5
|
+
import { IInstantiationService } from '@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation';
|
|
6
|
+
import { matchesFuzzy } from '@codingame/monaco-vscode-api/vscode/vs/base/common/filters';
|
|
7
|
+
import { ThemeIcon } from '@codingame/monaco-vscode-api/vscode/vs/base/common/themables';
|
|
8
|
+
import { IAgentSessionsService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsService.service';
|
|
9
|
+
import { AgentSessionsSorter, groupAgentSessions } from './agentSessionsViewer.js';
|
|
10
|
+
import { openSession } from './agentSessionsOpener.js';
|
|
11
|
+
import { ICommandService } from '@codingame/monaco-vscode-api/vscode/vs/platform/commands/common/commands.service';
|
|
12
|
+
import { AGENT_SESSION_DELETE_ACTION_ID, AGENT_SESSION_RENAME_ACTION_ID } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessions';
|
|
13
|
+
import { getSessionDescription, getSessionButtons, unarchiveButton, archiveButton, deleteButton, renameButton } from './agentSessionsPicker.js';
|
|
14
|
+
|
|
15
|
+
const AGENT_SESSIONS_QUICK_ACCESS_PREFIX = 'agent ';
|
|
16
|
+
let AgentSessionsQuickAccessProvider = class AgentSessionsQuickAccessProvider extends PickerQuickAccessProvider {
|
|
17
|
+
constructor(agentSessionsService, instantiationService, commandService) {
|
|
18
|
+
super(AGENT_SESSIONS_QUICK_ACCESS_PREFIX, {
|
|
19
|
+
canAcceptInBackground: true,
|
|
20
|
+
noResultsPick: {
|
|
21
|
+
label: ( localize(4908, "No matching agent sessions"))
|
|
22
|
+
}
|
|
23
|
+
});
|
|
24
|
+
this.agentSessionsService = agentSessionsService;
|
|
25
|
+
this.instantiationService = instantiationService;
|
|
26
|
+
this.commandService = commandService;
|
|
27
|
+
this.sorter = ( new AgentSessionsSorter());
|
|
28
|
+
}
|
|
29
|
+
async _getPicks(filter) {
|
|
30
|
+
const picks = [];
|
|
31
|
+
const sessions = this.agentSessionsService.model.sessions.sort(this.sorter.compare.bind(this.sorter));
|
|
32
|
+
const groupedSessions = groupAgentSessions(sessions);
|
|
33
|
+
for (const group of ( groupedSessions.values())) {
|
|
34
|
+
if (group.sessions.length > 0) {
|
|
35
|
+
picks.push({ type: 'separator', label: group.label });
|
|
36
|
+
for (const session of group.sessions) {
|
|
37
|
+
const highlights = matchesFuzzy(filter, session.label, true);
|
|
38
|
+
if (highlights) {
|
|
39
|
+
picks.push(this.toPickItem(session, highlights));
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
return picks;
|
|
45
|
+
}
|
|
46
|
+
toPickItem(session, highlights) {
|
|
47
|
+
const description = getSessionDescription(session);
|
|
48
|
+
const buttons = getSessionButtons(session);
|
|
49
|
+
return {
|
|
50
|
+
label: session.label,
|
|
51
|
+
description,
|
|
52
|
+
highlights: { label: highlights },
|
|
53
|
+
iconClass: ThemeIcon.asClassName(session.icon),
|
|
54
|
+
buttons,
|
|
55
|
+
trigger: async (buttonIndex) => {
|
|
56
|
+
const button = buttons[buttonIndex];
|
|
57
|
+
switch (button) {
|
|
58
|
+
case renameButton:
|
|
59
|
+
await this.commandService.executeCommand(AGENT_SESSION_RENAME_ACTION_ID, session);
|
|
60
|
+
return TriggerAction.REFRESH_PICKER;
|
|
61
|
+
case deleteButton:
|
|
62
|
+
await this.commandService.executeCommand(AGENT_SESSION_DELETE_ACTION_ID, session);
|
|
63
|
+
return TriggerAction.REFRESH_PICKER;
|
|
64
|
+
case archiveButton:
|
|
65
|
+
case unarchiveButton: {
|
|
66
|
+
const newArchivedState = !session.isArchived();
|
|
67
|
+
session.setArchived(newArchivedState);
|
|
68
|
+
return TriggerAction.REFRESH_PICKER;
|
|
69
|
+
}
|
|
70
|
+
default:
|
|
71
|
+
return TriggerAction.NO_ACTION;
|
|
72
|
+
}
|
|
73
|
+
},
|
|
74
|
+
accept: (keyMods, event) => {
|
|
75
|
+
this.instantiationService.invokeFunction(openSession, session, {
|
|
76
|
+
sideBySide: event.inBackground,
|
|
77
|
+
editorOptions: {
|
|
78
|
+
preserveFocus: event.inBackground,
|
|
79
|
+
pinned: event.inBackground
|
|
80
|
+
}
|
|
81
|
+
});
|
|
82
|
+
}
|
|
83
|
+
};
|
|
84
|
+
}
|
|
85
|
+
};
|
|
86
|
+
AgentSessionsQuickAccessProvider = ( __decorate([
|
|
87
|
+
( __param(0, IAgentSessionsService)),
|
|
88
|
+
( __param(1, IInstantiationService)),
|
|
89
|
+
( __param(2, ICommandService))
|
|
90
|
+
], AgentSessionsQuickAccessProvider));
|
|
91
|
+
|
|
92
|
+
export { AGENT_SESSIONS_QUICK_ACCESS_PREFIX, AgentSessionsQuickAccessProvider };
|
|
@@ -5,7 +5,7 @@ import { ICompressedTreeNode } from "@codingame/monaco-vscode-api/vscode/vs/base
|
|
|
5
5
|
import { ICompressibleKeyboardNavigationLabelProvider, ICompressibleTreeRenderer } from "@codingame/monaco-vscode-api/vscode/vs/base/browser/ui/tree/objectTree";
|
|
6
6
|
import { ITreeNode, ITreeElementRenderDetails, IAsyncDataSource, ITreeSorter, ITreeDragAndDrop, ITreeDragOverReaction } from "@codingame/monaco-vscode-api/vscode/vs/base/browser/ui/tree/tree";
|
|
7
7
|
import { Disposable, DisposableStore, IDisposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle";
|
|
8
|
-
import { IAgentSession, IAgentSessionsModel } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsModel";
|
|
8
|
+
import { AgentSessionSection, IAgentSession, IAgentSessionSection, IAgentSessionsModel } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsModel";
|
|
9
9
|
import { IconLabel } from "@codingame/monaco-vscode-api/vscode/vs/base/browser/ui/iconLabel/iconLabel";
|
|
10
10
|
import { FuzzyScore } from "@codingame/monaco-vscode-api/vscode/vs/base/common/filters";
|
|
11
11
|
import { IMarkdownRendererService } from "@codingame/monaco-vscode-api/vscode/vs/platform/markdown/browser/markdownRenderer.service";
|
|
@@ -13,13 +13,12 @@ import { IProductService } from "@codingame/monaco-vscode-api/vscode/vs/platform
|
|
|
13
13
|
import { IDragAndDropData } from "@codingame/monaco-vscode-api/vscode/vs/base/browser/dnd";
|
|
14
14
|
import { ListViewTargetSector } from "@codingame/monaco-vscode-api/vscode/vs/base/browser/ui/list/listView";
|
|
15
15
|
import { IInstantiationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation";
|
|
16
|
-
import {
|
|
17
|
-
import { IWorkbenchLayoutService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/layout/browser/layoutService.service";
|
|
18
|
-
import { IViewDescriptorService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/common/views.service";
|
|
16
|
+
import { HoverPosition } from "@codingame/monaco-vscode-api/vscode/vs/base/browser/ui/hover/hoverWidget";
|
|
19
17
|
import { IHoverService } from "@codingame/monaco-vscode-api/vscode/vs/platform/hover/browser/hover.service";
|
|
20
18
|
import { MenuWorkbenchToolBar } from "@codingame/monaco-vscode-api/vscode/vs/platform/actions/browser/toolbar";
|
|
21
19
|
import { IContextKeyService } from "@codingame/monaco-vscode-api/vscode/vs/platform/contextkey/common/contextkey.service";
|
|
22
20
|
import { Event } from "@codingame/monaco-vscode-api/vscode/vs/base/common/event";
|
|
21
|
+
export type AgentSessionListItem = IAgentSession | IAgentSessionSection;
|
|
23
22
|
interface IAgentSessionItemTemplate {
|
|
24
23
|
readonly element: HTMLElement;
|
|
25
24
|
readonly icon: HTMLElement;
|
|
@@ -29,89 +28,139 @@ interface IAgentSessionItemTemplate {
|
|
|
29
28
|
readonly diffFilesSpan: HTMLSpanElement;
|
|
30
29
|
readonly diffAddedSpan: HTMLSpanElement;
|
|
31
30
|
readonly diffRemovedSpan: HTMLSpanElement;
|
|
31
|
+
readonly badge: HTMLElement;
|
|
32
32
|
readonly description: HTMLElement;
|
|
33
33
|
readonly status: HTMLElement;
|
|
34
34
|
readonly contextKeyService: IContextKeyService;
|
|
35
35
|
readonly elementDisposable: DisposableStore;
|
|
36
36
|
readonly disposables: IDisposable;
|
|
37
37
|
}
|
|
38
|
+
export interface IAgentSessionRendererOptions {
|
|
39
|
+
getHoverPosition(): HoverPosition;
|
|
40
|
+
}
|
|
38
41
|
export declare class AgentSessionRenderer implements ICompressibleTreeRenderer<IAgentSession, FuzzyScore, IAgentSessionItemTemplate> {
|
|
42
|
+
private readonly options;
|
|
39
43
|
private readonly markdownRendererService;
|
|
40
44
|
private readonly productService;
|
|
41
|
-
private readonly layoutService;
|
|
42
|
-
private readonly viewDescriptorService;
|
|
43
45
|
private readonly hoverService;
|
|
44
46
|
private readonly instantiationService;
|
|
45
47
|
private readonly contextKeyService;
|
|
46
|
-
private readonly chatSessionsService;
|
|
47
48
|
static readonly TEMPLATE_ID = "agent-session";
|
|
48
49
|
readonly templateId = "agent-session";
|
|
49
|
-
constructor(markdownRendererService: IMarkdownRendererService, productService: IProductService,
|
|
50
|
+
constructor(options: IAgentSessionRendererOptions, markdownRendererService: IMarkdownRendererService, productService: IProductService, hoverService: IHoverService, instantiationService: IInstantiationService, contextKeyService: IContextKeyService);
|
|
50
51
|
renderTemplate(container: HTMLElement): IAgentSessionItemTemplate;
|
|
51
52
|
renderElement(session: ITreeNode<IAgentSession, FuzzyScore>, index: number, template: IAgentSessionItemTemplate, details?: ITreeElementRenderDetails): void;
|
|
53
|
+
private renderBadge;
|
|
54
|
+
private renderMarkdownOrText;
|
|
52
55
|
private renderDiff;
|
|
53
56
|
private getIcon;
|
|
54
57
|
private renderDescription;
|
|
55
58
|
private toDuration;
|
|
56
59
|
private renderStatus;
|
|
57
60
|
private renderHover;
|
|
61
|
+
private buildTooltip;
|
|
58
62
|
renderCompressedElements(node: ITreeNode<ICompressedTreeNode<IAgentSession>, FuzzyScore>, index: number, templateData: IAgentSessionItemTemplate, details?: ITreeElementRenderDetails): void;
|
|
59
63
|
disposeElement(element: ITreeNode<IAgentSession, FuzzyScore>, index: number, template: IAgentSessionItemTemplate, details?: ITreeElementRenderDetails): void;
|
|
60
64
|
disposeTemplate(templateData: IAgentSessionItemTemplate): void;
|
|
61
65
|
}
|
|
62
|
-
|
|
66
|
+
interface IAgentSessionSectionTemplate {
|
|
67
|
+
readonly container: HTMLElement;
|
|
68
|
+
readonly label: HTMLSpanElement;
|
|
69
|
+
readonly toolbar: MenuWorkbenchToolBar;
|
|
70
|
+
readonly contextKeyService: IContextKeyService;
|
|
71
|
+
readonly disposables: IDisposable;
|
|
72
|
+
}
|
|
73
|
+
export declare class AgentSessionSectionRenderer implements ICompressibleTreeRenderer<IAgentSessionSection, FuzzyScore, IAgentSessionSectionTemplate> {
|
|
74
|
+
private readonly instantiationService;
|
|
75
|
+
private readonly contextKeyService;
|
|
76
|
+
static readonly TEMPLATE_ID = "agent-session-section";
|
|
77
|
+
readonly templateId = "agent-session-section";
|
|
78
|
+
constructor(instantiationService: IInstantiationService, contextKeyService: IContextKeyService);
|
|
79
|
+
renderTemplate(container: HTMLElement): IAgentSessionSectionTemplate;
|
|
80
|
+
renderElement(element: ITreeNode<IAgentSessionSection, FuzzyScore>, index: number, template: IAgentSessionSectionTemplate, details?: ITreeElementRenderDetails): void;
|
|
81
|
+
renderCompressedElements(node: ITreeNode<ICompressedTreeNode<IAgentSessionSection>, FuzzyScore>, index: number, templateData: IAgentSessionSectionTemplate, details?: ITreeElementRenderDetails): void;
|
|
82
|
+
disposeElement(element: ITreeNode<IAgentSessionSection, FuzzyScore>, index: number, template: IAgentSessionSectionTemplate, details?: ITreeElementRenderDetails): void;
|
|
83
|
+
disposeTemplate(templateData: IAgentSessionSectionTemplate): void;
|
|
84
|
+
}
|
|
85
|
+
export declare class AgentSessionsListDelegate implements IListVirtualDelegate<AgentSessionListItem> {
|
|
63
86
|
static readonly ITEM_HEIGHT = 52;
|
|
64
|
-
|
|
65
|
-
|
|
87
|
+
static readonly SECTION_HEIGHT = 26;
|
|
88
|
+
getHeight(element: AgentSessionListItem): number;
|
|
89
|
+
getTemplateId(element: AgentSessionListItem): string;
|
|
66
90
|
}
|
|
67
|
-
export declare class AgentSessionsAccessibilityProvider implements IListAccessibilityProvider<
|
|
91
|
+
export declare class AgentSessionsAccessibilityProvider implements IListAccessibilityProvider<AgentSessionListItem> {
|
|
68
92
|
getWidgetAriaLabel(): string;
|
|
69
|
-
getAriaLabel(element:
|
|
93
|
+
getAriaLabel(element: AgentSessionListItem): string | null;
|
|
70
94
|
}
|
|
71
95
|
export interface IAgentSessionsFilter {
|
|
72
|
-
|
|
96
|
+
/**
|
|
97
|
+
* An event that fires when the filter changes and sessions
|
|
98
|
+
* should be re-evaluated.
|
|
99
|
+
*/
|
|
100
|
+
readonly onDidChange: Event<void>;
|
|
73
101
|
/**
|
|
74
102
|
* Optional limit on the number of sessions to show.
|
|
75
103
|
*/
|
|
76
104
|
readonly limitResults?: () => number | undefined;
|
|
105
|
+
/**
|
|
106
|
+
* Whether to show section headers to group sessions.
|
|
107
|
+
* When false, sessions are shown as a flat list.
|
|
108
|
+
*/
|
|
109
|
+
readonly groupResults?: () => boolean | undefined;
|
|
77
110
|
/**
|
|
78
111
|
* A callback to notify the filter about the number of
|
|
79
112
|
* results after filtering.
|
|
80
113
|
*/
|
|
81
114
|
notifyResults?(count: number): void;
|
|
82
|
-
|
|
115
|
+
/**
|
|
116
|
+
* The logic to exclude sessions from the view.
|
|
117
|
+
*/
|
|
118
|
+
exclude(session: IAgentSession): boolean;
|
|
83
119
|
}
|
|
84
|
-
export declare class AgentSessionsDataSource implements IAsyncDataSource<IAgentSessionsModel,
|
|
120
|
+
export declare class AgentSessionsDataSource implements IAsyncDataSource<IAgentSessionsModel, AgentSessionListItem> {
|
|
85
121
|
private readonly filter;
|
|
86
122
|
private readonly sorter;
|
|
87
123
|
constructor(filter: IAgentSessionsFilter | undefined, sorter: ITreeSorter<IAgentSession>);
|
|
88
|
-
hasChildren(element: IAgentSessionsModel |
|
|
89
|
-
getChildren(element: IAgentSessionsModel |
|
|
124
|
+
hasChildren(element: IAgentSessionsModel | AgentSessionListItem): boolean;
|
|
125
|
+
getChildren(element: IAgentSessionsModel | AgentSessionListItem): Iterable<AgentSessionListItem>;
|
|
126
|
+
private groupSessionsIntoSections;
|
|
127
|
+
}
|
|
128
|
+
export declare const AgentSessionSectionLabels: {
|
|
129
|
+
inProgress: string;
|
|
130
|
+
today: string;
|
|
131
|
+
yesterday: string;
|
|
132
|
+
week: string;
|
|
133
|
+
older: string;
|
|
134
|
+
archived: string;
|
|
135
|
+
};
|
|
136
|
+
export declare function groupAgentSessions(sessions: IAgentSession[]): Map<AgentSessionSection, IAgentSessionSection>;
|
|
137
|
+
export declare class AgentSessionsIdentityProvider implements IIdentityProvider<IAgentSessionsModel | AgentSessionListItem> {
|
|
138
|
+
getId(element: IAgentSessionsModel | AgentSessionListItem): string;
|
|
90
139
|
}
|
|
91
|
-
export declare class
|
|
92
|
-
|
|
140
|
+
export declare class AgentSessionsCompressionDelegate implements ITreeCompressionDelegate<AgentSessionListItem> {
|
|
141
|
+
isIncompressible(element: AgentSessionListItem): boolean;
|
|
93
142
|
}
|
|
94
|
-
export
|
|
95
|
-
|
|
143
|
+
export interface IAgentSessionsSorterOptions {
|
|
144
|
+
overrideCompare?(sessionA: IAgentSession, sessionB: IAgentSession): number | undefined;
|
|
96
145
|
}
|
|
97
146
|
export declare class AgentSessionsSorter implements ITreeSorter<IAgentSession> {
|
|
98
|
-
private readonly
|
|
99
|
-
constructor(
|
|
147
|
+
private readonly options?;
|
|
148
|
+
constructor(options?: IAgentSessionsSorterOptions | undefined);
|
|
100
149
|
compare(sessionA: IAgentSession, sessionB: IAgentSession): number;
|
|
101
150
|
}
|
|
102
|
-
export declare class AgentSessionsKeyboardNavigationLabelProvider implements ICompressibleKeyboardNavigationLabelProvider<
|
|
103
|
-
getKeyboardNavigationLabel(element:
|
|
104
|
-
getCompressedNodeKeyboardNavigationLabel(elements:
|
|
151
|
+
export declare class AgentSessionsKeyboardNavigationLabelProvider implements ICompressibleKeyboardNavigationLabelProvider<AgentSessionListItem> {
|
|
152
|
+
getKeyboardNavigationLabel(element: AgentSessionListItem): string;
|
|
153
|
+
getCompressedNodeKeyboardNavigationLabel(elements: AgentSessionListItem[]): {
|
|
105
154
|
toString(): string | undefined;
|
|
106
155
|
} | undefined;
|
|
107
156
|
}
|
|
108
|
-
export declare class AgentSessionsDragAndDrop extends Disposable implements ITreeDragAndDrop<
|
|
157
|
+
export declare class AgentSessionsDragAndDrop extends Disposable implements ITreeDragAndDrop<AgentSessionListItem> {
|
|
109
158
|
private readonly instantiationService;
|
|
110
159
|
constructor(instantiationService: IInstantiationService);
|
|
111
160
|
onDragStart(data: IDragAndDropData, originalEvent: DragEvent): void;
|
|
112
|
-
getDragURI(element:
|
|
113
|
-
getDragLabel?(elements:
|
|
114
|
-
onDragOver(data: IDragAndDropData, targetElement:
|
|
115
|
-
drop(data: IDragAndDropData, targetElement:
|
|
161
|
+
getDragURI(element: AgentSessionListItem): string | null;
|
|
162
|
+
getDragLabel?(elements: AgentSessionListItem[], originalEvent: DragEvent): string | undefined;
|
|
163
|
+
onDragOver(data: IDragAndDropData, targetElement: AgentSessionListItem | undefined, targetIndex: number | undefined, targetSector: ListViewTargetSector | undefined, originalEvent: DragEvent): boolean | ITreeDragOverReaction;
|
|
164
|
+
drop(data: IDragAndDropData, targetElement: AgentSessionListItem | undefined, targetIndex: number | undefined, targetSector: ListViewTargetSector | undefined, originalEvent: DragEvent): void;
|
|
116
165
|
}
|
|
117
166
|
export {};
|