@codingame/monaco-vscode-chat-service-override 23.3.0 → 24.1.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 +13 -10
- package/package.json +5 -41
- package/vscode/src/vs/platform/domWidget/browser/domWidget.d.ts +52 -0
- package/vscode/src/vs/platform/domWidget/browser/domWidget.js +53 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAccessibilityActions.js +10 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAccessibilityHelp.js +61 -50
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAgentRecommendationActions.d.ts +18 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAgentRecommendationActions.js +152 -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 +14 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContextActions.js +37 -28
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCopyActions.js +9 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatDeveloperActions.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatFileTreeActions.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatGettingStarted.d.ts +3 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatGettingStarted.js +7 -11
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatImportExport.js +10 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatLanguageModelActions.js +12 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatMoveActions.js +21 -18
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatNewActions.js +27 -18
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatPromptNavigationActions.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQuickInputActions.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQuickInputActions.js +11 -11
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatSessionActions.d.ts +6 -27
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatSessionActions.js +44 -208
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolActions.js +17 -17
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolPicker.js +17 -17
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/codeBlockOperations.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/codeBlockOperations.js +23 -24
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessions.contribution.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessions.contribution.js +140 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsActions.d.ts +85 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsActions.js +358 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsControl.d.ts +55 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsControl.js +222 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsFilter.d.ts +37 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsFilter.js +241 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsService.d.ts +13 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsService.js +27 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsView.d.ts +11 -19
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsView.js +67 -230
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsViewer.d.ts +65 -33
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsViewer.js +186 -62
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/localAgentSessionsProvider.d.ts +23 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/localAgentSessionsProvider.js +140 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/media/agentsessionsview.css +2 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/media/agentsessionsviewer.css +115 -29
- package/vscode/src/vs/workbench/contrib/chat/browser/chat.contribution.js +389 -166
- package/vscode/src/vs/workbench/contrib/chat/browser/chatAccessibilityService.d.ts +9 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/chatAccessibilityService.js +22 -16
- package/vscode/src/vs/workbench/contrib/chat/browser/chatAttachmentResolveService.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatAttachmentResolveService.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/chatContentParts/chatMarkdownAnchorService.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatContextService.d.ts +10 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatContextService.js +63 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCheckpointTimeline.d.ts +7 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCheckpointTimelineImpl.d.ts +14 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCheckpointTimelineImpl.js +173 -32
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCodeEditorIntegration.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCodeEditorIntegration.js +66 -17
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorActions.js +32 -29
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorOverlay.js +12 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedDocumentEntry.d.ts +4 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedDocumentEntry.js +9 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedFileEntry.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedFileEntry.js +6 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedNotebookEntry.d.ts +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedNotebookEntry.js +8 -18
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingOperations.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingOperations.js +12 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingServiceImpl.d.ts +5 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingServiceImpl.js +15 -24
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingSession.d.ts +13 -11
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingSession.js +66 -50
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingSessionStorage.d.ts +3 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingSessionStorage.js +6 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingTextModelChangeService.d.ts +3 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingTextModelChangeService.js +7 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingTextModelContentProviders.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingTextModelContentProviders.js +6 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingModifiedNotebookSnapshot.d.ts +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingModifiedNotebookSnapshot.js +4 -4
- 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 +15 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/overlayToolbarDecorator.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/overlayToolbarDecorator.js +3 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/simpleBrowserEditorOverlay.js +30 -37
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditor.d.ts +13 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditor.js +23 -32
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagement.contribution.js +8 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditor.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditor.js +20 -19
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditorInput.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsViewModel.d.ts +47 -15
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsViewModel.js +270 -143
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsWidget.d.ts +3 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsWidget.js +310 -170
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatUsageWidget.js +10 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/media/chatModelsWidget.css +12 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatOutputItemRenderer.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatOutputItemRenderer.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/chatParticipant.contribution.js +42 -42
- package/vscode/src/vs/workbench/contrib/chat/browser/chatQuick.d.ts +3 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatQuick.js +35 -25
- package/vscode/src/vs/workbench/contrib/chat/browser/chatResponseAccessibleView.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatResponseAccessibleView.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/view/chatSessionsView.d.ts +1 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/view/chatSessionsView.js +22 -26
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/view/sessionsTreeRenderer.d.ts +18 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/view/sessionsTreeRenderer.js +80 -72
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/view/sessionsViewPane.d.ts +2 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/view/sessionsViewPane.js +48 -77
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions.contribution.d.ts +16 -17
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions.contribution.js +257 -77
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetup.d.ts +55 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetup.js +34 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatSetup.d.ts → chatSetup/chatSetupContributions.d.ts} +4 -11
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupContributions.js +622 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupController.d.ts +53 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupController.js +359 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupProviders.d.ts +89 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupProviders.js +667 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupRunner.d.ts +37 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupRunner.js +260 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/{media → chatSetup/media}/chatSetup.css +4 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatus.d.ts +4 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatus.js +21 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusDashboard.d.ts +55 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatStatus.js → chatStatus/chatStatusDashboard.js} +193 -325
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatStatus.d.ts → chatStatus/chatStatusEntry.d.ts} +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusEntry.js +190 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/{chatStatusItemService.d.ts → chatStatus/chatStatusItemService.d.ts} +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/{media → chatStatus/media}/chatStatus.css +22 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatStatusWidget.d.ts +25 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatStatusWidget.js +108 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatTerminalOutputAccessibleView.d.ts +10 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatTerminalOutputAccessibleView.js +34 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatVariables.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatViewPane.d.ts +57 -18
- package/vscode/src/vs/workbench/contrib/chat/browser/chatViewPane.js +478 -146
- package/vscode/src/vs/workbench/contrib/chat/browser/chatViewTitleControl.d.ts +43 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatViewTitleControl.js +204 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatWidgetService.d.ts +44 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatWidgetService.js +187 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/codeBlockContextProviderService.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/contrib/chatInputEditorContrib.js +108 -62
- package/vscode/src/vs/workbench/contrib/chat/browser/contrib/chatInputEditorHover.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/contrib/chatInputEditorHover.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/languageModelToolsConfirmationService.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/languageModelToolsConfirmationService.js +37 -32
- package/vscode/src/vs/workbench/contrib/chat/browser/languageModelToolsService.d.ts +37 -20
- package/vscode/src/vs/workbench/contrib/chat/browser/languageModelToolsService.js +232 -97
- package/vscode/src/vs/workbench/contrib/chat/browser/media/chatStatusWidget.css +57 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/media/chatViewPane.css +142 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/media/chatViewTitleControl.css +39 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/chatModeActions.js +51 -35
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptCodingAgentActionContribution.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptCodingAgentActionOverlay.js +5 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptFileActions.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptToolsCodeLensProvider.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptUrlHandler.js +12 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/runPromptAction.js +19 -21
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/saveAsPromptFileActions.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/saveAsPromptFileActions.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/toolSetsContribution.js +16 -16
- package/vscode/src/vs/workbench/contrib/chat/browser/viewsWelcome/chatViewsWelcomeHandler.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/common/chatCodeMapperService.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/chatModelStore.d.ts +49 -0
- package/vscode/src/vs/workbench/contrib/chat/common/chatModelStore.js +100 -0
- package/vscode/src/vs/workbench/contrib/chat/common/chatProgressTypes/chatToolInvocation.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/chat/common/chatProgressTypes/chatToolInvocation.js +2 -1
- package/vscode/src/vs/workbench/contrib/chat/common/chatResponseResourceFileSystemProvider.js +3 -4
- package/vscode/src/vs/workbench/contrib/chat/common/chatServiceImpl.d.ts +41 -15
- package/vscode/src/vs/workbench/contrib/chat/common/chatServiceImpl.js +208 -162
- package/vscode/src/vs/workbench/contrib/chat/common/chatServiceTelemetry.d.ts +3 -3
- package/vscode/src/vs/workbench/contrib/chat/common/chatSessionStore.d.ts +15 -7
- package/vscode/src/vs/workbench/contrib/chat/common/chatSessionStore.js +61 -7
- package/vscode/src/vs/workbench/contrib/chat/common/chatSlashCommands.d.ts +3 -2
- package/vscode/src/vs/workbench/contrib/chat/common/chatSlashCommands.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/common/chatTodoListService.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/chatPromptFilesContribution.js +10 -10
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/PromptHeaderDefinitionProvider.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptBodyAutocompletion.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptCodeActions.d.ts +5 -1
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptCodeActions.js +60 -43
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptDocumentSemanticTokensProvider.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptHeaderAutocompletion.js +27 -4
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptHovers.js +37 -47
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptValidator.d.ts +5 -3
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptValidator.js +120 -87
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/promptFileContributions.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/service/promptsServiceImpl.d.ts +49 -42
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/service/promptsServiceImpl.js +293 -187
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/utils/promptFilesLocator.d.ts +17 -5
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/utils/promptFilesLocator.js +43 -9
- package/vscode/src/vs/workbench/contrib/chat/common/tools/languageModelToolsContribution.d.ts +2 -0
- package/vscode/src/vs/workbench/contrib/chat/common/tools/languageModelToolsContribution.js +48 -29
- package/vscode/src/vs/workbench/contrib/chat/common/voiceChatService.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/voiceChatService.js +2 -2
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChat.contribution.js +8 -13
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatAccessibilityHelp.js +1 -1
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatAccessibleView.js +2 -2
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatActions.d.ts +3 -3
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatActions.js +36 -41
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatNotebook.js +3 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookModifiedCellDecorator.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookModifiedCellDecorator.js +2 -2
- package/vscode/src/vs/workbench/contrib/remoteCodingAgents/browser/remoteCodingAgents.contribution.js +7 -7
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminal.chat.contribution.js +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatAccessibilityHelp.js +18 -18
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatAccessibleView.js +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatActions.js +142 -38
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatController.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatController.js +3 -7
- 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 +19 -2
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatService.js +78 -6
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatWidget.d.ts +7 -11
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatWidget.js +26 -44
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/commandLineAutoApprover.js +3 -3
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/basicExecuteStrategy.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/basicExecuteStrategy.js +9 -0
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/executeStrategy.d.ts +0 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/executeStrategy.js +23 -17
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/richExecuteStrategy.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/outputHelpers.js +4 -2
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalHelpers.d.ts +2 -0
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalHelpers.js +26 -5
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/taskHelpers.d.ts +3 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/taskHelpers.js +32 -4
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/terminal.chatAgentTools.contribution.js +15 -29
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/toolTerminalCreator.js +10 -7
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAnalyzer.d.ts +12 -0
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAutoApproveAnalyzer.d.ts +3 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAutoApproveAnalyzer.js +38 -19
- 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 +32 -7
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalLastCommandTool.js +5 -4
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalOutputTool.js +4 -3
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalSelectionTool.js +4 -3
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/outputMonitor.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/outputMonitor.js +128 -62
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/types.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalConfirmationTool.js +12 -2
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.d.ts +5 -2
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.js +68 -22
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/createAndRunTaskTool.js +20 -22
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/getTaskOutputTool.js +13 -12
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/runTaskTool.js +20 -19
- 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 +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/terminalCommandArtifactCollector.d.ts +12 -0
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/terminalCommandArtifactCollector.js +72 -0
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/treeSitterCommandParser.d.ts +1 -2
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/treeSitterCommandParser.js +5 -17
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionViewModel.d.ts +0 -53
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionViewModel.js +0 -154
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessions.d.ts +0 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessions.js +0 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessionTracker.d.ts +0 -25
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessionTracker.js +0 -135
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/localChatSessionsProvider.d.ts +0 -35
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/localChatSessionsProvider.js +0 -216
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup.js +0 -1617
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatCurrentLine.d.ts +0 -44
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatCurrentLine.js +0 -313
- /package/vscode/src/vs/workbench/contrib/chat/browser/{media → chatSetup/media}/apple-dark.svg +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/browser/{media → chatSetup/media}/apple-light.svg +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/browser/{media → chatSetup/media}/github.svg +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/browser/{media → chatSetup/media}/google.svg +0 -0
- /package/vscode/src/vs/workbench/contrib/chat/browser/{chatStatusItemService.js → chatStatus/chatStatusItemService.js} +0 -0
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { Lazy } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lazy";
|
|
2
|
+
import { ICommandService } from "@codingame/monaco-vscode-api/vscode/vs/platform/commands/common/commands.service";
|
|
3
|
+
import { IInstantiationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation";
|
|
4
|
+
import { ChatEntitlementContext } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/chat/common/chatEntitlementService";
|
|
5
|
+
import { ChatSetupController } from "./chatSetupController.js";
|
|
6
|
+
import { IChatSetupResult, ChatSetupAnonymous } from "./chatSetup.js";
|
|
7
|
+
export declare class ChatSetup {
|
|
8
|
+
private readonly context;
|
|
9
|
+
private readonly controller;
|
|
10
|
+
private readonly telemetryService;
|
|
11
|
+
private readonly layoutService;
|
|
12
|
+
private readonly keybindingService;
|
|
13
|
+
private readonly chatEntitlementService;
|
|
14
|
+
private readonly logService;
|
|
15
|
+
private readonly configurationService;
|
|
16
|
+
private readonly widgetService;
|
|
17
|
+
private readonly workspaceTrustRequestService;
|
|
18
|
+
private readonly markdownRendererService;
|
|
19
|
+
private static instance;
|
|
20
|
+
static getInstance(instantiationService: IInstantiationService, context: ChatEntitlementContext, controller: Lazy<ChatSetupController>): ChatSetup;
|
|
21
|
+
private pendingRun;
|
|
22
|
+
private skipDialogOnce;
|
|
23
|
+
private constructor();
|
|
24
|
+
skipDialog(): void;
|
|
25
|
+
run(options?: {
|
|
26
|
+
disableChatViewReveal?: boolean;
|
|
27
|
+
forceSignInDialog?: boolean;
|
|
28
|
+
additionalScopes?: readonly string[];
|
|
29
|
+
forceAnonymous?: ChatSetupAnonymous;
|
|
30
|
+
}): Promise<IChatSetupResult>;
|
|
31
|
+
private doRun;
|
|
32
|
+
private showDialog;
|
|
33
|
+
private getButtons;
|
|
34
|
+
private getDialogTitle;
|
|
35
|
+
private createDialogFooter;
|
|
36
|
+
}
|
|
37
|
+
export declare function refreshTokens(commandService: ICommandService): void;
|
|
@@ -0,0 +1,260 @@
|
|
|
1
|
+
|
|
2
|
+
import { registerCss } from '@codingame/monaco-vscode-api/css';
|
|
3
|
+
import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib/tslib.es6';
|
|
4
|
+
import * as chatSetup from './media/chatSetup.css';
|
|
5
|
+
import { $ } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/dom';
|
|
6
|
+
import { Dialog, DialogContentsAlignment } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/ui/dialog/dialog';
|
|
7
|
+
import { coalesce } from '@codingame/monaco-vscode-api/vscode/vs/base/common/arrays';
|
|
8
|
+
import { Codicon } from '@codingame/monaco-vscode-api/vscode/vs/base/common/codicons';
|
|
9
|
+
import { toErrorMessage } from '@codingame/monaco-vscode-api/vscode/vs/base/common/errorMessage';
|
|
10
|
+
import { MarkdownString } from '@codingame/monaco-vscode-api/vscode/vs/base/common/htmlContent';
|
|
11
|
+
import { DisposableStore } from '@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle';
|
|
12
|
+
import { IMarkdownRendererService } from '@codingame/monaco-vscode-api/vscode/vs/platform/markdown/browser/markdownRenderer.service';
|
|
13
|
+
import { localize } from '@codingame/monaco-vscode-api/vscode/vs/nls';
|
|
14
|
+
import { IConfigurationService } from '@codingame/monaco-vscode-api/vscode/vs/platform/configuration/common/configuration.service';
|
|
15
|
+
import { createWorkbenchDialogOptions } from '@codingame/monaco-vscode-api/vscode/vs/platform/dialogs/browser/dialog';
|
|
16
|
+
import { IKeybindingService } from '@codingame/monaco-vscode-api/vscode/vs/platform/keybinding/common/keybinding.service';
|
|
17
|
+
import { ILayoutService } from '@codingame/monaco-vscode-api/vscode/vs/platform/layout/browser/layoutService.service';
|
|
18
|
+
import { ILogService } from '@codingame/monaco-vscode-api/vscode/vs/platform/log/common/log.service';
|
|
19
|
+
import product from '@codingame/monaco-vscode-api/vscode/vs/platform/product/common/product';
|
|
20
|
+
import { TelemetryLevel } from '@codingame/monaco-vscode-api/vscode/vs/platform/telemetry/common/telemetry';
|
|
21
|
+
import { ITelemetryService } from '@codingame/monaco-vscode-api/vscode/vs/platform/telemetry/common/telemetry.service';
|
|
22
|
+
import { IWorkspaceTrustRequestService } from '@codingame/monaco-vscode-api/vscode/vs/platform/workspace/common/workspaceTrust.service';
|
|
23
|
+
import { IWorkbenchLayoutService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/layout/browser/layoutService.service';
|
|
24
|
+
import { isProUser, ChatEntitlement, ChatEntitlementRequests } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/chat/common/chatEntitlementService';
|
|
25
|
+
import { IChatEntitlementService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/chat/common/chatEntitlementService.service';
|
|
26
|
+
import { IChatWidgetService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/chat.service';
|
|
27
|
+
import { ChatSetupStrategy, ChatSetupAnonymous } from './chatSetup.js';
|
|
28
|
+
|
|
29
|
+
var ChatSetup_1;
|
|
30
|
+
registerCss(chatSetup);
|
|
31
|
+
const defaultChat = {
|
|
32
|
+
publicCodeMatchesUrl: product.defaultChatAgent?.publicCodeMatchesUrl ?? '',
|
|
33
|
+
provider: product.defaultChatAgent?.provider ?? { default: { name: '' }, enterprise: { id: '', name: '' }, apple: { name: '' }, google: { name: '' } },
|
|
34
|
+
manageSettingsUrl: product.defaultChatAgent?.manageSettingsUrl ?? '',
|
|
35
|
+
termsStatementUrl: product.defaultChatAgent?.termsStatementUrl ?? '',
|
|
36
|
+
privacyStatementUrl: product.defaultChatAgent?.privacyStatementUrl ?? ''
|
|
37
|
+
};
|
|
38
|
+
let ChatSetup = class ChatSetup {
|
|
39
|
+
static { ChatSetup_1 = this; }
|
|
40
|
+
static { this.instance = undefined; }
|
|
41
|
+
static getInstance(instantiationService, context, controller) {
|
|
42
|
+
let instance = ChatSetup_1.instance;
|
|
43
|
+
if (!instance) {
|
|
44
|
+
instance = ChatSetup_1.instance = instantiationService.invokeFunction(accessor => {
|
|
45
|
+
return ( new ChatSetup_1(
|
|
46
|
+
context,
|
|
47
|
+
controller,
|
|
48
|
+
accessor.get(ITelemetryService),
|
|
49
|
+
accessor.get(IWorkbenchLayoutService),
|
|
50
|
+
accessor.get(IKeybindingService),
|
|
51
|
+
accessor.get(IChatEntitlementService),
|
|
52
|
+
accessor.get(ILogService),
|
|
53
|
+
accessor.get(IConfigurationService),
|
|
54
|
+
accessor.get(IChatWidgetService),
|
|
55
|
+
accessor.get(IWorkspaceTrustRequestService),
|
|
56
|
+
accessor.get(IMarkdownRendererService)
|
|
57
|
+
));
|
|
58
|
+
});
|
|
59
|
+
}
|
|
60
|
+
return instance;
|
|
61
|
+
}
|
|
62
|
+
constructor(context, controller, telemetryService, layoutService, keybindingService, chatEntitlementService, logService, configurationService, widgetService, workspaceTrustRequestService, markdownRendererService) {
|
|
63
|
+
this.context = context;
|
|
64
|
+
this.controller = controller;
|
|
65
|
+
this.telemetryService = telemetryService;
|
|
66
|
+
this.layoutService = layoutService;
|
|
67
|
+
this.keybindingService = keybindingService;
|
|
68
|
+
this.chatEntitlementService = chatEntitlementService;
|
|
69
|
+
this.logService = logService;
|
|
70
|
+
this.configurationService = configurationService;
|
|
71
|
+
this.widgetService = widgetService;
|
|
72
|
+
this.workspaceTrustRequestService = workspaceTrustRequestService;
|
|
73
|
+
this.markdownRendererService = markdownRendererService;
|
|
74
|
+
this.pendingRun = undefined;
|
|
75
|
+
this.skipDialogOnce = false;
|
|
76
|
+
}
|
|
77
|
+
skipDialog() {
|
|
78
|
+
this.skipDialogOnce = true;
|
|
79
|
+
}
|
|
80
|
+
async run(options) {
|
|
81
|
+
if (this.pendingRun) {
|
|
82
|
+
return this.pendingRun;
|
|
83
|
+
}
|
|
84
|
+
this.pendingRun = this.doRun(options);
|
|
85
|
+
try {
|
|
86
|
+
return await this.pendingRun;
|
|
87
|
+
}
|
|
88
|
+
finally {
|
|
89
|
+
this.pendingRun = undefined;
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
async doRun(options) {
|
|
93
|
+
this.context.update({ later: false });
|
|
94
|
+
const dialogSkipped = this.skipDialogOnce;
|
|
95
|
+
this.skipDialogOnce = false;
|
|
96
|
+
const trusted = await this.workspaceTrustRequestService.requestWorkspaceTrust({
|
|
97
|
+
message: ( localize(5564, "AI features are currently only supported in trusted workspaces."))
|
|
98
|
+
});
|
|
99
|
+
if (!trusted) {
|
|
100
|
+
this.context.update({ later: true });
|
|
101
|
+
this.telemetryService.publicLog2('commandCenter.chatInstall', { installResult: 'failedNotTrusted', installDuration: 0, signUpErrorCode: undefined, provider: undefined });
|
|
102
|
+
return { dialogSkipped, success: undefined };
|
|
103
|
+
}
|
|
104
|
+
let setupStrategy;
|
|
105
|
+
if (!options?.forceSignInDialog && (dialogSkipped || isProUser(this.chatEntitlementService.entitlement) || this.chatEntitlementService.entitlement === ChatEntitlement.Free)) {
|
|
106
|
+
setupStrategy = ChatSetupStrategy.DefaultSetup;
|
|
107
|
+
}
|
|
108
|
+
else if (options?.forceAnonymous === ChatSetupAnonymous.EnabledWithoutDialog) {
|
|
109
|
+
setupStrategy = ChatSetupStrategy.DefaultSetup;
|
|
110
|
+
}
|
|
111
|
+
else {
|
|
112
|
+
setupStrategy = await this.showDialog(options);
|
|
113
|
+
}
|
|
114
|
+
if (setupStrategy === ChatSetupStrategy.DefaultSetup && ChatEntitlementRequests.providerId(this.configurationService) === defaultChat.provider.enterprise.id) {
|
|
115
|
+
setupStrategy = ChatSetupStrategy.SetupWithEnterpriseProvider;
|
|
116
|
+
}
|
|
117
|
+
if (setupStrategy !== ChatSetupStrategy.Canceled && !options?.disableChatViewReveal) {
|
|
118
|
+
this.widgetService.revealWidget();
|
|
119
|
+
}
|
|
120
|
+
let success = undefined;
|
|
121
|
+
try {
|
|
122
|
+
switch (setupStrategy) {
|
|
123
|
+
case ChatSetupStrategy.SetupWithEnterpriseProvider:
|
|
124
|
+
success = await this.controller.value.setupWithProvider({ useEnterpriseProvider: true, useSocialProvider: undefined, additionalScopes: options?.additionalScopes, forceAnonymous: options?.forceAnonymous });
|
|
125
|
+
break;
|
|
126
|
+
case ChatSetupStrategy.SetupWithoutEnterpriseProvider:
|
|
127
|
+
success = await this.controller.value.setupWithProvider({ useEnterpriseProvider: false, useSocialProvider: undefined, additionalScopes: options?.additionalScopes, forceAnonymous: options?.forceAnonymous });
|
|
128
|
+
break;
|
|
129
|
+
case ChatSetupStrategy.SetupWithAppleProvider:
|
|
130
|
+
success = await this.controller.value.setupWithProvider({ useEnterpriseProvider: false, useSocialProvider: 'apple', additionalScopes: options?.additionalScopes, forceAnonymous: options?.forceAnonymous });
|
|
131
|
+
break;
|
|
132
|
+
case ChatSetupStrategy.SetupWithGoogleProvider:
|
|
133
|
+
success = await this.controller.value.setupWithProvider({ useEnterpriseProvider: false, useSocialProvider: 'google', additionalScopes: options?.additionalScopes, forceAnonymous: options?.forceAnonymous });
|
|
134
|
+
break;
|
|
135
|
+
case ChatSetupStrategy.DefaultSetup:
|
|
136
|
+
success = await this.controller.value.setup({ ...options, forceAnonymous: options?.forceAnonymous });
|
|
137
|
+
break;
|
|
138
|
+
case ChatSetupStrategy.Canceled:
|
|
139
|
+
this.context.update({ later: true });
|
|
140
|
+
this.telemetryService.publicLog2('commandCenter.chatInstall', { installResult: 'failedMaybeLater', installDuration: 0, signUpErrorCode: undefined, provider: undefined });
|
|
141
|
+
break;
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
catch (error) {
|
|
145
|
+
this.logService.error(`[chat setup] Error during setup: ${toErrorMessage(error)}`);
|
|
146
|
+
success = false;
|
|
147
|
+
}
|
|
148
|
+
return { success, dialogSkipped };
|
|
149
|
+
}
|
|
150
|
+
async showDialog(options) {
|
|
151
|
+
const disposables = ( new DisposableStore());
|
|
152
|
+
const buttons = this.getButtons(options);
|
|
153
|
+
const dialog = disposables.add(( new Dialog(
|
|
154
|
+
this.layoutService.activeContainer,
|
|
155
|
+
this.getDialogTitle(options),
|
|
156
|
+
( buttons.map(button => button[0])),
|
|
157
|
+
createWorkbenchDialogOptions({
|
|
158
|
+
type: 'none',
|
|
159
|
+
extraClasses: ['chat-setup-dialog'],
|
|
160
|
+
detail: ' ',
|
|
161
|
+
icon: Codicon.copilotLarge,
|
|
162
|
+
alignment: DialogContentsAlignment.Vertical,
|
|
163
|
+
cancelId: buttons.length - 1,
|
|
164
|
+
disableCloseButton: true,
|
|
165
|
+
renderFooter: footer => footer.appendChild(this.createDialogFooter(disposables, options)),
|
|
166
|
+
buttonOptions: ( buttons.map(button => button[2]))
|
|
167
|
+
}, this.keybindingService, this.layoutService)
|
|
168
|
+
)));
|
|
169
|
+
const { button } = await dialog.show();
|
|
170
|
+
disposables.dispose();
|
|
171
|
+
return buttons[button]?.[1] ?? ChatSetupStrategy.Canceled;
|
|
172
|
+
}
|
|
173
|
+
getButtons(options) {
|
|
174
|
+
const styleButton = (...classes) => ({ styleButton: (button) => button.element.classList.add(...classes) });
|
|
175
|
+
let buttons;
|
|
176
|
+
if (!options?.forceAnonymous && (this.context.state.entitlement === ChatEntitlement.Unknown || options?.forceSignInDialog)) {
|
|
177
|
+
const defaultProviderButton = [( localize(5565, "Continue with {0}", defaultChat.provider.default.name)), ChatSetupStrategy.SetupWithoutEnterpriseProvider, styleButton('continue-button', 'default')];
|
|
178
|
+
const defaultProviderLink = [defaultProviderButton[0], defaultProviderButton[1], styleButton('link-button')];
|
|
179
|
+
const enterpriseProviderButton = [( localize(5565, "Continue with {0}", defaultChat.provider.enterprise.name)), ChatSetupStrategy.SetupWithEnterpriseProvider, styleButton('continue-button', 'default')];
|
|
180
|
+
const enterpriseProviderLink = [enterpriseProviderButton[0], enterpriseProviderButton[1], styleButton('link-button')];
|
|
181
|
+
const googleProviderButton = [( localize(5565, "Continue with {0}", defaultChat.provider.google.name)), ChatSetupStrategy.SetupWithGoogleProvider, styleButton('continue-button', 'google')];
|
|
182
|
+
const appleProviderButton = [( localize(5565, "Continue with {0}", defaultChat.provider.apple.name)), ChatSetupStrategy.SetupWithAppleProvider, styleButton('continue-button', 'apple')];
|
|
183
|
+
if (ChatEntitlementRequests.providerId(this.configurationService) !== defaultChat.provider.enterprise.id) {
|
|
184
|
+
buttons = coalesce([
|
|
185
|
+
defaultProviderButton,
|
|
186
|
+
googleProviderButton,
|
|
187
|
+
appleProviderButton,
|
|
188
|
+
enterpriseProviderLink
|
|
189
|
+
]);
|
|
190
|
+
}
|
|
191
|
+
else {
|
|
192
|
+
buttons = coalesce([
|
|
193
|
+
enterpriseProviderButton,
|
|
194
|
+
googleProviderButton,
|
|
195
|
+
appleProviderButton,
|
|
196
|
+
defaultProviderLink
|
|
197
|
+
]);
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
else {
|
|
201
|
+
buttons = [[( localize(5566, "Use AI Features")), ChatSetupStrategy.DefaultSetup, undefined]];
|
|
202
|
+
}
|
|
203
|
+
buttons.push([( localize(5567, "Skip for now")), ChatSetupStrategy.Canceled, styleButton('link-button', 'skip-button')]);
|
|
204
|
+
return buttons;
|
|
205
|
+
}
|
|
206
|
+
getDialogTitle(options) {
|
|
207
|
+
if (this.chatEntitlementService.anonymous) {
|
|
208
|
+
if (options?.forceAnonymous) {
|
|
209
|
+
return localize(5568, "Start using AI Features");
|
|
210
|
+
}
|
|
211
|
+
else {
|
|
212
|
+
return localize(5569, "Enable more AI features");
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
if (this.context.state.entitlement === ChatEntitlement.Unknown || options?.forceSignInDialog) {
|
|
216
|
+
return localize(5570, "Sign in to use AI Features");
|
|
217
|
+
}
|
|
218
|
+
return localize(5568, "Start using AI Features");
|
|
219
|
+
}
|
|
220
|
+
createDialogFooter(disposables, options) {
|
|
221
|
+
const element = $('.chat-setup-dialog-footer');
|
|
222
|
+
let footer;
|
|
223
|
+
if (options?.forceAnonymous || this.telemetryService.telemetryLevel === TelemetryLevel.NONE) {
|
|
224
|
+
footer = ( localize(
|
|
225
|
+
5571,
|
|
226
|
+
"By continuing, you agree to {0}'s [Terms]({1}) and [Privacy Statement]({2}).",
|
|
227
|
+
defaultChat.provider.default.name,
|
|
228
|
+
defaultChat.termsStatementUrl,
|
|
229
|
+
defaultChat.privacyStatementUrl
|
|
230
|
+
));
|
|
231
|
+
}
|
|
232
|
+
else {
|
|
233
|
+
footer = ( localize(
|
|
234
|
+
5572,
|
|
235
|
+
"By continuing, you agree to {0}'s [Terms]({1}) and [Privacy Statement]({2}). {3} Copilot may show [public code]({4}) suggestions and use your data to improve the product. You can change these [settings]({5}) anytime.",
|
|
236
|
+
defaultChat.provider.default.name,
|
|
237
|
+
defaultChat.termsStatementUrl,
|
|
238
|
+
defaultChat.privacyStatementUrl,
|
|
239
|
+
defaultChat.provider.default.name,
|
|
240
|
+
defaultChat.publicCodeMatchesUrl,
|
|
241
|
+
defaultChat.manageSettingsUrl
|
|
242
|
+
));
|
|
243
|
+
}
|
|
244
|
+
element.appendChild($('p', undefined, disposables.add(this.markdownRendererService.render(( new MarkdownString(footer, { isTrusted: true })))).element));
|
|
245
|
+
return element;
|
|
246
|
+
}
|
|
247
|
+
};
|
|
248
|
+
ChatSetup = ChatSetup_1 = ( __decorate([
|
|
249
|
+
( __param(2, ITelemetryService)),
|
|
250
|
+
( __param(3, ILayoutService)),
|
|
251
|
+
( __param(4, IKeybindingService)),
|
|
252
|
+
( __param(5, IChatEntitlementService)),
|
|
253
|
+
( __param(6, ILogService)),
|
|
254
|
+
( __param(7, IConfigurationService)),
|
|
255
|
+
( __param(8, IChatWidgetService)),
|
|
256
|
+
( __param(9, IWorkspaceTrustRequestService)),
|
|
257
|
+
( __param(10, IMarkdownRendererService))
|
|
258
|
+
], ChatSetup));
|
|
259
|
+
|
|
260
|
+
export { ChatSetup };
|
package/vscode/src/vs/workbench/contrib/chat/browser/{media → chatSetup/media}/chatSetup.css
RENAMED
|
@@ -51,12 +51,10 @@
|
|
|
51
51
|
}
|
|
52
52
|
}
|
|
53
53
|
|
|
54
|
-
.monaco-workbench.hc-
|
|
55
|
-
|
|
56
|
-
background-image: url('./apple-dark.svg');
|
|
54
|
+
.monaco-workbench.hc-light .chat-setup-dialog .dialog-buttons-row > .dialog-buttons > .monaco-button.continue-button.apple::before {
|
|
55
|
+
background-image: url('./apple-light.svg');
|
|
57
56
|
}
|
|
58
57
|
|
|
59
|
-
.
|
|
60
|
-
|
|
61
|
-
background-image: url('./apple-light.svg');
|
|
58
|
+
.chat-setup-dialog .dialog-buttons-row > .dialog-buttons > .monaco-button.continue-button.apple::before {
|
|
59
|
+
background-image: url('./apple-dark.svg');
|
|
62
60
|
}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { IChatEntitlementService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/chat/common/chatEntitlementService.service";
|
|
2
|
+
import { IConfigurationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/configuration/common/configuration.service";
|
|
3
|
+
export declare function isNewUser(chatEntitlementService: IChatEntitlementService): boolean;
|
|
4
|
+
export declare function isCompletionsEnabled(configurationService: IConfigurationService, modeId?: string): boolean;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
|
|
2
|
+
import { ChatEntitlement } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/chat/common/chatEntitlementService';
|
|
3
|
+
import product from '@codingame/monaco-vscode-api/vscode/vs/platform/product/common/product';
|
|
4
|
+
import { isObject } from '@codingame/monaco-vscode-api/vscode/vs/base/common/types';
|
|
5
|
+
|
|
6
|
+
function isNewUser(chatEntitlementService) {
|
|
7
|
+
return !chatEntitlementService.sentiment.installed ||
|
|
8
|
+
chatEntitlementService.entitlement === ChatEntitlement.Available;
|
|
9
|
+
}
|
|
10
|
+
function isCompletionsEnabled(configurationService, modeId = '*') {
|
|
11
|
+
const result = configurationService.getValue(product.defaultChatAgent.completionsEnablementSetting);
|
|
12
|
+
if (!isObject(result)) {
|
|
13
|
+
return false;
|
|
14
|
+
}
|
|
15
|
+
if (typeof result[modeId] !== 'undefined') {
|
|
16
|
+
return Boolean(result[modeId]);
|
|
17
|
+
}
|
|
18
|
+
return Boolean(result['*']);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export { isCompletionsEnabled, isNewUser };
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { IInlineCompletionsService } from "@codingame/monaco-vscode-api/vscode/vs/editor/browser/services/inlineCompletionsService.service";
|
|
2
|
+
import { ILanguageService } from "@codingame/monaco-vscode-api/vscode/vs/editor/common/languages/language.service";
|
|
3
|
+
import { ITextResourceConfigurationService } from "@codingame/monaco-vscode-api/vscode/vs/editor/common/services/textResourceConfiguration.service";
|
|
4
|
+
import { ILanguageFeaturesService } from "@codingame/monaco-vscode-api/vscode/vs/editor/common/services/languageFeatures.service";
|
|
5
|
+
import { IQuickInputService } from "@codingame/monaco-vscode-api/vscode/vs/platform/quickinput/common/quickInput.service";
|
|
6
|
+
import { ICommandService } from "@codingame/monaco-vscode-api/vscode/vs/platform/commands/common/commands.service";
|
|
7
|
+
import { IConfigurationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/configuration/common/configuration.service";
|
|
8
|
+
import { IHoverService } from "@codingame/monaco-vscode-api/vscode/vs/platform/hover/browser/hover.service";
|
|
9
|
+
import { IMarkdownRendererService } from "@codingame/monaco-vscode-api/vscode/vs/platform/markdown/browser/markdownRenderer.service";
|
|
10
|
+
import { IOpenerService } from "@codingame/monaco-vscode-api/vscode/vs/platform/opener/common/opener.service";
|
|
11
|
+
import { ITelemetryService } from "@codingame/monaco-vscode-api/vscode/vs/platform/telemetry/common/telemetry.service";
|
|
12
|
+
import { DomWidget } from "../../../../../platform/domWidget/browser/domWidget.js";
|
|
13
|
+
import { ChatEntitlementService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/chat/common/chatEntitlementService";
|
|
14
|
+
import { IEditorService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/editor/common/editorService.service";
|
|
15
|
+
import { IChatSessionsService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatSessionsService.service";
|
|
16
|
+
import { IChatStatusItemService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/chatStatus/chatStatusItemService.service";
|
|
17
|
+
import { IInstantiationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation";
|
|
18
|
+
export declare class ChatStatusDashboard extends DomWidget {
|
|
19
|
+
private readonly chatEntitlementService;
|
|
20
|
+
private readonly chatStatusItemService;
|
|
21
|
+
private readonly commandService;
|
|
22
|
+
private readonly configurationService;
|
|
23
|
+
private readonly editorService;
|
|
24
|
+
private readonly hoverService;
|
|
25
|
+
private readonly languageService;
|
|
26
|
+
private readonly openerService;
|
|
27
|
+
private readonly telemetryService;
|
|
28
|
+
private readonly textResourceConfigurationService;
|
|
29
|
+
private readonly inlineCompletionsService;
|
|
30
|
+
private readonly chatSessionsService;
|
|
31
|
+
private readonly markdownRendererService;
|
|
32
|
+
private readonly languageFeaturesService;
|
|
33
|
+
private readonly quickInputService;
|
|
34
|
+
private readonly instantiationService;
|
|
35
|
+
readonly element: HTMLElement;
|
|
36
|
+
private readonly dateFormatter;
|
|
37
|
+
private readonly dateTimeFormatter;
|
|
38
|
+
private readonly quotaPercentageFormatter;
|
|
39
|
+
private readonly quotaOverageFormatter;
|
|
40
|
+
constructor(chatEntitlementService: ChatEntitlementService, chatStatusItemService: IChatStatusItemService, commandService: ICommandService, configurationService: IConfigurationService, editorService: IEditorService, hoverService: IHoverService, languageService: ILanguageService, openerService: IOpenerService, telemetryService: ITelemetryService, textResourceConfigurationService: ITextResourceConfigurationService, inlineCompletionsService: IInlineCompletionsService, chatSessionsService: IChatSessionsService, markdownRendererService: IMarkdownRendererService, languageFeaturesService: ILanguageFeaturesService, quickInputService: IQuickInputService, instantiationService: IInstantiationService);
|
|
41
|
+
private render;
|
|
42
|
+
private canUseChat;
|
|
43
|
+
private renderHeader;
|
|
44
|
+
private renderContributedChatStatusItem;
|
|
45
|
+
private renderTextPlus;
|
|
46
|
+
private runCommandAndClose;
|
|
47
|
+
private createQuotaIndicator;
|
|
48
|
+
private createSettings;
|
|
49
|
+
private createSetting;
|
|
50
|
+
private createInlineSuggestionsSetting;
|
|
51
|
+
private getCompletionsSettingAccessor;
|
|
52
|
+
private createNextEditSuggestionsSetting;
|
|
53
|
+
private createCompletionsSnooze;
|
|
54
|
+
private showModelPicker;
|
|
55
|
+
}
|