@codingame/monaco-vscode-api 10.1.0 → 10.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +27 -0
- package/package.json +8 -15
- package/vscode/src/vs/base/browser/ui/actionbar/actionViewItems.js +1 -1
- package/vscode/src/vs/base/browser/ui/dropdown/dropdownActionViewItem.js +1 -1
- package/vscode/src/vs/base/browser/ui/splitview/paneview.js +1 -1
- package/vscode/src/vs/base/browser/ui/toolbar/toolbar.js +1 -1
- package/vscode/src/vs/base/browser/ui/tree/abstractTree.js +9 -9
- package/vscode/src/vs/base/common/date.js +61 -61
- package/vscode/src/vs/editor/browser/controller/editContext/native/screenReaderSupport.js +1 -1
- package/vscode/src/vs/editor/browser/controller/editContext/screenReaderUtils.js +4 -4
- package/vscode/src/vs/editor/browser/gpu/viewGpuContext.js +1 -1
- package/vscode/src/vs/editor/browser/services/hoverService/hoverWidget.js +1 -1
- package/vscode/src/vs/editor/browser/services/hoverService/updatableHoverWidget.js +1 -1
- package/vscode/src/vs/editor/browser/widget/codeEditor/codeEditorWidget.js +2 -2
- package/vscode/src/vs/editor/browser/widget/diffEditor/commands.js +12 -12
- package/vscode/src/vs/editor/browser/widget/diffEditor/components/accessibleDiffViewer.js +14 -14
- package/vscode/src/vs/editor/browser/widget/diffEditor/components/diffEditorEditors.js +1 -1
- package/vscode/src/vs/editor/browser/widget/diffEditor/diffEditor.contribution.js +5 -5
- package/vscode/src/vs/editor/browser/widget/diffEditor/features/hideUnchangedRegionsFeature.js +7 -7
- package/vscode/src/vs/editor/browser/widget/diffEditor/features/movedBlocksLinesFeature.js +4 -4
- package/vscode/src/vs/editor/browser/widget/diffEditor/features/revertButtonsFeature.js +2 -2
- package/vscode/src/vs/editor/browser/widget/diffEditor/registrations.contribution.js +5 -5
- package/vscode/src/vs/editor/browser/widget/multiDiffEditor/colors.js +3 -3
- package/vscode/src/vs/editor/browser/widget/multiDiffEditor/multiDiffEditorWidgetImpl.js +2 -2
- package/vscode/src/vs/editor/common/config/editorConfigurationSchema.js +51 -51
- package/vscode/src/vs/editor/common/core/editorColorRegistry.js +71 -71
- package/vscode/src/vs/editor/common/model/editStack.js +1 -1
- package/vscode/src/vs/editor/common/standaloneStrings.js +32 -32
- package/vscode/src/vs/editor/common/viewLayout/viewLineRenderer.js +2 -2
- package/vscode/src/vs/editor/contrib/anchorSelect/browser/anchorSelect.js +6 -6
- package/vscode/src/vs/editor/contrib/bracketMatching/browser/bracketMatching.js +6 -6
- package/vscode/src/vs/editor/contrib/codeAction/browser/codeActionCommands.js +28 -28
- package/vscode/src/vs/editor/contrib/codeAction/browser/codeActionController.js +3 -3
- package/vscode/src/vs/editor/contrib/codeAction/browser/lightBulbWidget.js +9 -9
- package/vscode/src/vs/editor/contrib/colorPicker/browser/hoverColorPicker/hoverColorPickerParticipant.js +1 -1
- package/vscode/src/vs/editor/contrib/colorPicker/browser/standaloneColorPicker/standaloneColorPickerActions.js +7 -7
- package/vscode/src/vs/editor/contrib/dropOrPasteInto/browser/copyPasteController.js +7 -7
- package/vscode/src/vs/editor/contrib/dropOrPasteInto/browser/defaultProviders.js +8 -8
- package/vscode/src/vs/editor/contrib/dropOrPasteInto/browser/dropIntoEditorController.js +3 -3
- package/vscode/src/vs/editor/contrib/editorState/browser/keybindingCancellation.js +1 -1
- package/vscode/src/vs/editor/contrib/find/browser/findWidget.js +27 -27
- package/vscode/src/vs/editor/contrib/gotoError/browser/gotoErrorWidget.js +14 -14
- package/vscode/src/vs/editor/contrib/gotoSymbol/browser/referencesModel.js +8 -8
- package/vscode/src/vs/editor/contrib/gotoSymbol/browser/symbolNavigation.js +3 -3
- package/vscode/src/vs/editor/contrib/hover/browser/hoverAccessibleViews.js +2 -2
- package/vscode/src/vs/editor/contrib/hover/browser/hoverActions.js +23 -23
- package/vscode/src/vs/editor/contrib/hover/browser/markdownHoverParticipant.js +9 -9
- package/vscode/src/vs/editor/contrib/hover/browser/markerHoverParticipant.js +5 -5
- package/vscode/src/vs/editor/contrib/inlayHints/browser/inlayHintsHover.js +8 -8
- package/vscode/src/vs/editor/contrib/inlineCompletions/browser/controller/commands.js +14 -14
- package/vscode/src/vs/editor/contrib/inlineCompletions/browser/controller/inlineCompletionsController.js +1 -1
- package/vscode/src/vs/editor/contrib/inlineCompletions/browser/hintsWidget/hoverParticipant.js +2 -2
- package/vscode/src/vs/editor/contrib/message/browser/messageController.js +1 -1
- package/vscode/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.js +4 -4
- package/vscode/src/vs/editor/contrib/peekView/browser/peekView.js +17 -17
- package/vscode/src/vs/editor/contrib/quickAccess/browser/gotoLineQuickAccess.js +5 -5
- package/vscode/src/vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess.js +32 -32
- package/vscode/src/vs/editor/contrib/rename/browser/renameWidget.js +6 -6
- package/vscode/src/vs/editor/contrib/stickyScroll/browser/stickyScrollActions.js +11 -11
- package/vscode/src/vs/editor/contrib/suggest/browser/suggest.js +8 -8
- package/vscode/src/vs/editor/contrib/suggest/browser/suggestWidget.js +16 -16
- package/vscode/src/vs/editor/contrib/toggleTabFocusMode/browser/toggleTabFocusMode.js +4 -4
- package/vscode/src/vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter.js +24 -24
- package/vscode/src/vs/editor/contrib/wordHighlighter/browser/highlightDecorations.js +9 -9
- package/vscode/src/vs/platform/accessibilitySignal/browser/accessibilitySignalService.js +49 -49
- package/vscode/src/vs/platform/actions/browser/menuEntryActionViewItem.js +5 -5
- package/vscode/src/vs/platform/actions/browser/toolbar.js +2 -2
- package/vscode/src/vs/platform/actions/common/menuResetAction.js +1 -1
- package/vscode/src/vs/platform/actions/common/menuService.js +2 -2
- package/vscode/src/vs/platform/contextkey/browser/contextKeyService.js +1 -1
- package/vscode/src/vs/platform/contextkey/common/contextkey.js +11 -11
- package/vscode/src/vs/platform/contextkey/common/contextkeys.js +9 -9
- package/vscode/src/vs/platform/dialogs/common/dialogs.js +9 -9
- package/vscode/src/vs/platform/dnd/browser/dnd.js +1 -1
- package/vscode/src/vs/platform/extensionManagement/common/extensionManagement.js +2 -2
- package/vscode/src/vs/platform/keybinding/common/abstractKeybindingService.js +4 -4
- package/vscode/src/vs/platform/list/browser/listService.js +27 -27
- package/vscode/src/vs/platform/markers/common/markers.js +3 -3
- package/vscode/src/vs/platform/quickinput/browser/quickInput.js +8 -8
- package/vscode/src/vs/platform/quickinput/browser/quickInputController.js +6 -6
- package/vscode/src/vs/platform/request/common/request.js +14 -14
- package/vscode/src/vs/platform/theme/common/colors/baseColors.js +17 -17
- package/vscode/src/vs/platform/theme/common/colors/chartsColors.js +8 -8
- package/vscode/src/vs/platform/theme/common/iconRegistry.js +5 -5
- package/vscode/src/vs/platform/theme/common/tokenClassificationRegistry.js +42 -42
- package/vscode/src/vs/platform/undoRedo/common/undoRedoService.js +20 -20
- package/vscode/src/vs/platform/userDataSync/common/userDataSync.js +5 -5
- package/vscode/src/vs/platform/workspace/common/workspace.js +1 -1
- package/vscode/src/vs/workbench/browser/actions/layoutActions.js +129 -129
- package/vscode/src/vs/workbench/browser/actions/windowActions.js +25 -25
- package/vscode/src/vs/workbench/browser/actions/workspaceActions.js +21 -21
- package/vscode/src/vs/workbench/browser/actions/workspaceCommands.js +4 -4
- package/vscode/src/vs/workbench/browser/editor.js +2 -2
- package/vscode/src/vs/workbench/browser/parts/editor/breadcrumbs.js +41 -41
- package/vscode/src/vs/workbench/browser/parts/editor/editorCommands.js +16 -16
- package/vscode/src/vs/workbench/browser/parts/editor/editorTabsControl.js +2 -2
- package/vscode/src/vs/workbench/browser/parts/globalCompositeBar.js +15 -15
- package/vscode/src/vs/workbench/browser/parts/notifications/notificationsActions.js +17 -17
- package/vscode/src/vs/workbench/browser/parts/notifications/notificationsAlerts.js +3 -3
- package/vscode/src/vs/workbench/browser/parts/notifications/notificationsCenter.js +6 -6
- package/vscode/src/vs/workbench/browser/parts/notifications/notificationsCommands.js +9 -9
- package/vscode/src/vs/workbench/browser/parts/notifications/notificationsList.js +6 -6
- package/vscode/src/vs/workbench/browser/parts/notifications/notificationsStatus.js +13 -13
- package/vscode/src/vs/workbench/browser/parts/notifications/notificationsToasts.js +2 -2
- package/vscode/src/vs/workbench/browser/parts/titlebar/menubarControl.js +18 -18
- package/vscode/src/vs/workbench/browser/parts/titlebar/windowTitle.js +2 -2
- package/vscode/src/vs/workbench/browser/parts/views/viewFilter.js +1 -1
- package/vscode/src/vs/workbench/browser/parts/views/viewPane.js +4 -4
- package/vscode/src/vs/workbench/browser/parts/views/viewPaneContainer.js +6 -6
- package/vscode/src/vs/workbench/browser/quickaccess.js +1 -1
- package/vscode/src/vs/workbench/browser/workbench.contribution.js +217 -217
- package/vscode/src/vs/workbench/common/contextkeys.js +70 -70
- package/vscode/src/vs/workbench/common/editor/diffEditorInput.js +1 -1
- package/vscode/src/vs/workbench/common/editor/sideBySideEditorInput.js +1 -1
- package/vscode/src/vs/workbench/common/views.js +4 -4
- package/vscode/src/vs/workbench/contrib/accessibility/browser/accessibilityConfiguration.js +131 -131
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatActions.js +17 -18
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatConstants.js +5 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatExecuteActions.js +7 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatTitleActions.js +8 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/chat.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatAccessibilityProvider.js +9 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/chatAgentHover.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatContentParts/chatAttachmentsContentPart.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/chatContentParts/chatCodeCitationContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatContentParts/chatCommandContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatContentParts/chatConfirmationContentPart.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatContentParts/chatReferencesContentPart.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/chatContentParts/chatTextEditContentPart.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatContentParts/chatToolInvocationPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatContentParts/chatTreeContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDragAndDrop.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditingService.js +13 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditorInput.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatFollowups.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatImagePaste.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatInlineAnchorWidget.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/chatInputPart.js +12 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/chatListRenderer.js +12 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/chatWidget.js +3 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/codeBlockPart.js +15 -15
- package/vscode/src/vs/workbench/contrib/chat/browser/contrib/chatDynamicVariables.js +4 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/contrib/chatDynamicVariablesConstant.js +2 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/contrib/chatInputCompletions.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/chatColors.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/common/chatContextKeys.js +21 -21
- package/vscode/src/vs/workbench/contrib/chat/common/chatModel.js +3 -3
- package/vscode/src/vs/workbench/contrib/codeEditor/browser/dictation/editorDictation.js +4 -4
- package/vscode/src/vs/workbench/contrib/codeEditor/browser/find/simpleFindWidget.js +10 -10
- package/vscode/src/vs/workbench/contrib/codeEditor/browser/inspectEditorTokens/inspectEditorTokens.js +2 -2
- package/vscode/src/vs/workbench/contrib/codeEditor/browser/quickaccess/gotoSymbolQuickAccess.js +6 -6
- package/vscode/src/vs/workbench/contrib/codeEditor/browser/saveParticipants.js +4 -4
- package/vscode/src/vs/workbench/contrib/codeEditor/browser/toggleMinimap.js +2 -2
- package/vscode/src/vs/workbench/contrib/comments/browser/commentReply.js +4 -4
- package/vscode/src/vs/workbench/contrib/comments/browser/commentsAccessibility.js +12 -12
- package/vscode/src/vs/workbench/contrib/comments/browser/commentsController.js +5 -5
- package/vscode/src/vs/workbench/contrib/comments/browser/commentsModel.js +1 -1
- package/vscode/src/vs/workbench/contrib/comments/browser/commentsTreeViewer.js +9 -9
- package/vscode/src/vs/workbench/contrib/comments/browser/commentsView.js +13 -13
- package/vscode/src/vs/workbench/contrib/comments/common/commentContextKeys.js +10 -10
- package/vscode/src/vs/workbench/contrib/debug/browser/breakpointEditorContribution.js +29 -29
- package/vscode/src/vs/workbench/contrib/debug/browser/breakpointsView.js +65 -65
- package/vscode/src/vs/workbench/contrib/debug/browser/callStackEditorContribution.js +2 -2
- package/vscode/src/vs/workbench/contrib/debug/browser/debugColors.js +12 -12
- package/vscode/src/vs/workbench/contrib/debug/browser/debugCommands.js +34 -34
- package/vscode/src/vs/workbench/contrib/debug/browser/debugIcons.js +57 -57
- package/vscode/src/vs/workbench/contrib/debug/browser/debugSessionPicker.js +3 -3
- package/vscode/src/vs/workbench/contrib/debug/common/debugModel.js +6 -6
- package/vscode/src/vs/workbench/contrib/debug/common/debugSource.js +1 -1
- package/vscode/src/vs/workbench/contrib/debug/common/disassemblyViewInput.js +2 -2
- package/vscode/src/vs/workbench/contrib/debug/common/loadedScriptsPicker.js +1 -1
- package/vscode/src/vs/workbench/contrib/extensions/browser/extensionsActions.js +173 -173
- package/vscode/src/vs/workbench/contrib/extensions/browser/extensionsIcons.js +24 -24
- package/vscode/src/vs/workbench/contrib/extensions/common/extensionsFileTemplate.js +5 -5
- package/vscode/src/vs/workbench/contrib/extensions/common/extensionsInput.js +2 -2
- package/vscode/src/vs/workbench/contrib/extensions/common/extensionsUtils.js +3 -3
- package/vscode/src/vs/workbench/contrib/files/browser/editors/textFileSaveErrorHandler.js +18 -18
- package/vscode/src/vs/workbench/contrib/files/browser/explorerViewlet.js +14 -14
- package/vscode/src/vs/workbench/contrib/files/browser/fileActions.js +84 -84
- package/vscode/src/vs/workbench/contrib/files/browser/fileConstants.js +6 -6
- package/vscode/src/vs/workbench/contrib/files/browser/fileImportExport.js +33 -33
- package/vscode/src/vs/workbench/contrib/files/browser/files.contribution._editorPane.js +2 -2
- package/vscode/src/vs/workbench/contrib/files/browser/views/emptyView.js +1 -1
- package/vscode/src/vs/workbench/contrib/files/browser/views/explorerView.js +8 -8
- package/vscode/src/vs/workbench/contrib/files/browser/views/openEditorsView.js +7 -7
- package/vscode/src/vs/workbench/contrib/files/common/files.js +14 -14
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatActions.js +19 -19
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatController.js +6 -6
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatZoneWidget.js +1 -1
- package/vscode/src/vs/workbench/contrib/inlineChat/common/inlineChat.js +41 -41
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/mergeEditorInput.js +1 -1
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/mergeEditorInputModel.js +29 -29
- package/vscode/src/vs/workbench/contrib/mergeEditor/common/mergeEditor.js +8 -8
- package/vscode/src/vs/workbench/contrib/multiDiffEditor/browser/multiDiffEditorInput.js +2 -2
- package/vscode/src/vs/workbench/contrib/multiDiffEditor/browser/scmMultiDiffSourceResolver.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/executionStatusBarItemController.js +6 -6
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/find/notebookFindWidget.js +3 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/cellOperations.js +2 -2
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/cellOutputActions.js +3 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/notebookChatContext.js +5 -5
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/notebookChatController.js +2 -2
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/coreActions.js +4 -4
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/foldingController.js +3 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditor.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditorBrowser.js +5 -5
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffList.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookMultiDiffEditor.js +3 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/notebookAccessibilityProvider.js +4 -4
- package/vscode/src/vs/workbench/contrib/notebook/browser/notebookEditor.js +8 -8
- package/vscode/src/vs/workbench/contrib/notebook/browser/notebookEditorWidget.js +24 -24
- package/vscode/src/vs/workbench/contrib/notebook/browser/notebookIcons.js +28 -28
- package/vscode/src/vs/workbench/contrib/notebook/browser/view/cellParts/cellEditorOptions.js +4 -4
- package/vscode/src/vs/workbench/contrib/notebook/browser/view/cellParts/codeCell.js +2 -2
- package/vscode/src/vs/workbench/contrib/notebook/browser/view/cellParts/codeCellRunToolbar.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/view/cellParts/collapsedCellOutput.js +3 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/view/cellParts/foldedCellHint.js +2 -2
- package/vscode/src/vs/workbench/contrib/notebook/browser/view/cellParts/markupCell.js +2 -2
- package/vscode/src/vs/workbench/contrib/notebook/browser/view/renderers/backLayerWebView.js +4 -4
- package/vscode/src/vs/workbench/contrib/notebook/browser/view/renderers/cellRenderer.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/viewParts/notebookKernelQuickPickStrategy.js +15 -15
- package/vscode/src/vs/workbench/contrib/notebook/browser/viewParts/notebookKernelView.js +2 -2
- package/vscode/src/vs/workbench/contrib/notebook/common/notebookEditorInput.js +2 -2
- package/vscode/src/vs/workbench/contrib/preferences/browser/preferencesIcons.js +12 -12
- package/vscode/src/vs/workbench/contrib/preferences/browser/preferencesWidgets.js +10 -10
- package/vscode/src/vs/workbench/contrib/preferences/browser/settingsLayout.js +50 -50
- package/vscode/src/vs/workbench/contrib/scm/browser/dirtyDiffSwitcher.js +2 -2
- package/vscode/src/vs/workbench/contrib/scm/browser/dirtydiffDecorator.js +23 -23
- package/vscode/src/vs/workbench/contrib/search/browser/anythingQuickAccess.js +5 -1
- package/vscode/src/vs/workbench/contrib/search/browser/searchActionsFind.js +10 -10
- package/vscode/src/vs/workbench/contrib/snippets/browser/commands/fileTemplateSnippets.js +2 -2
- package/vscode/src/vs/workbench/contrib/snippets/browser/snippetCompletionProvider.js +3 -3
- package/vscode/src/vs/workbench/contrib/snippets/browser/snippetsFile.js +3 -3
- package/vscode/src/vs/workbench/contrib/snippets/browser/snippetsService.js +9 -9
- package/vscode/src/vs/workbench/contrib/speech/common/speechService.js +29 -29
- package/vscode/src/vs/workbench/contrib/tasks/common/taskDefinitionRegistry.js +5 -5
- package/vscode/src/vs/workbench/contrib/tasks/common/taskService.js +5 -5
- package/vscode/src/vs/workbench/contrib/terminal/browser/terminalEditorInput.js +4 -4
- package/vscode/src/vs/workbench/contrib/terminal/common/terminal.js +7 -7
- package/vscode/src/vs/workbench/contrib/terminal/common/terminalContextKey.js +16 -16
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatControllerHolder.js +5 -0
- package/vscode/src/vs/workbench/contrib/testing/common/testResult.js +2 -2
- package/vscode/src/vs/workbench/contrib/url/browser/trustedDomains.js +6 -6
- package/vscode/src/vs/workbench/contrib/webview/browser/webview.contribution.js +3 -3
- package/vscode/src/vs/workbench/contrib/workspace/common/workspace.js +2 -2
- package/vscode/src/vs/workbench/services/activity/common/activity.js +4 -4
- package/vscode/src/vs/workbench/services/authentication/browser/authenticationService.js +3 -3
- package/vscode/src/vs/workbench/services/auxiliaryWindow/browser/auxiliaryWindowService.js +5 -5
- package/vscode/src/vs/workbench/services/editor/common/editorResolverService.js +1 -1
- package/vscode/src/vs/workbench/services/extensionManagement/common/extensionManagement.js +1 -1
- package/vscode/src/vs/workbench/services/language/common/languageService.js +28 -28
- package/vscode/src/vs/workbench/services/preferences/browser/keybindingsEditorInput.js +2 -2
- package/vscode/src/vs/workbench/services/preferences/browser/keybindingsEditorModel.js +7 -7
- package/vscode/src/vs/workbench/services/preferences/common/preferencesEditorInput.js +2 -2
- package/vscode/src/vs/workbench/services/textMate/common/TMGrammars.js +9 -9
- package/vscode/src/vs/workbench/services/textfile/common/textFileEditorModel.js +3 -3
- package/vscode/src/vs/workbench/services/themes/common/colorThemeData.js +8 -8
- package/vscode/src/vs/workbench/services/userDataProfile/common/userDataProfile.js +3 -3
- package/vscode/src/vs/workbench/services/views/browser/viewsService.js +7 -7
- package/vscode/src/vs/workbench/services/workingCopy/common/storedFileWorkingCopy.js +17 -17
- package/vscode/src/vs/base/common/processes.js +0 -25
- package/vscode/src/vs/platform/terminal/common/capabilities/bufferMarkCapability.js +0 -41
- package/vscode/src/vs/platform/terminal/common/capabilities/commandDetection/promptInputModel.js +0 -345
- package/vscode/src/vs/platform/terminal/common/capabilities/commandDetection/terminalCommand.js +0 -296
- package/vscode/src/vs/platform/terminal/common/capabilities/commandDetectionCapability.js +0 -761
- package/vscode/src/vs/platform/terminal/common/capabilities/cwdDetectionCapability.js +0 -29
- package/vscode/src/vs/platform/terminal/common/capabilities/naiveCwdDetectionCapability.js +0 -22
- package/vscode/src/vs/platform/terminal/common/capabilities/partialCommandDetectionCapability.js +0 -48
- package/vscode/src/vs/platform/terminal/common/capabilities/terminalCapabilityStore.js +0 -94
- package/vscode/src/vs/platform/terminal/common/environmentVariable.js +0 -7
- package/vscode/src/vs/platform/terminal/common/environmentVariableCollection.js +0 -196
- package/vscode/src/vs/platform/terminal/common/terminalEnvironment.js +0 -40
- package/vscode/src/vs/platform/terminal/common/terminalProfiles.js +0 -107
- package/vscode/src/vs/platform/terminal/common/terminalRecorder.js +0 -67
- package/vscode/src/vs/platform/terminal/common/xterm/shellIntegrationAddon.js +0 -346
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQuickInputActions.js +0 -167
- package/vscode/src/vs/workbench/contrib/terminal/browser/environmentVariableInfo.js +0 -119
- package/vscode/src/vs/workbench/contrib/terminal/browser/terminalActions.js +0 -1770
- package/vscode/src/vs/workbench/contrib/terminal/browser/terminalContextMenu.js +0 -40
- package/vscode/src/vs/workbench/contrib/terminal/browser/terminalExtensions.js +0 -25
- package/vscode/src/vs/workbench/contrib/terminal/browser/terminalIconPicker.js +0 -72
- package/vscode/src/vs/workbench/contrib/terminal/browser/terminalIcons.js +0 -16
- package/vscode/src/vs/workbench/contrib/terminal/browser/terminalInstance.js +0 -2218
- package/vscode/src/vs/workbench/contrib/terminal/browser/terminalProcessManager.js +0 -628
- package/vscode/src/vs/workbench/contrib/terminal/browser/terminalQuickAccess.js +0 -143
- package/vscode/src/vs/workbench/contrib/terminal/browser/terminalResizeDebouncer.js +0 -61
- package/vscode/src/vs/workbench/contrib/terminal/browser/terminalRunRecentQuickPick.js +0 -315
- package/vscode/src/vs/workbench/contrib/terminal/browser/terminalStatusList.js +0 -121
- package/vscode/src/vs/workbench/contrib/terminal/browser/terminalUri.js +0 -39
- package/vscode/src/vs/workbench/contrib/terminal/browser/widgets/widgetManager.js +0 -36
- package/vscode/src/vs/workbench/contrib/terminal/browser/xterm/decorationAddon.js +0 -498
- package/vscode/src/vs/workbench/contrib/terminal/browser/xterm/decorationStyles.js +0 -123
- package/vscode/src/vs/workbench/contrib/terminal/browser/xterm/lineDataEventAddon.js +0 -55
- package/vscode/src/vs/workbench/contrib/terminal/browser/xterm/markNavigationAddon.js +0 -571
- package/vscode/src/vs/workbench/contrib/terminal/browser/xterm/xtermTerminal.js +0 -732
- package/vscode/src/vs/workbench/contrib/terminal/common/history.js +0 -378
- package/vscode/src/vs/workbench/contrib/terminal/common/terminalClipboard.js +0 -80
- package/vscode/src/vs/workbench/contrib/terminal/common/terminalEnvironment.js +0 -282
- package/vscode/src/vs/workbench/contrib/terminal/common/terminalStrings.js +0 -36
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/media/terminalChatWidget.css.js +0 -4
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChat.js +0 -46
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatController.js +0 -303
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatWidget.js +0 -203
- package/vscode/src/vs/workbench/contrib/terminalContrib/stickyScroll/browser/media/stickyScroll.css.js +0 -4
- package/vscode/src/vs/workbench/contrib/terminalContrib/stickyScroll/browser/terminalStickyScrollColorRegistry.js +0 -22
- package/vscode/src/vs/workbench/contrib/terminalContrib/stickyScroll/browser/terminalStickyScrollContribution.js +0 -97
- package/vscode/src/vs/workbench/contrib/terminalContrib/stickyScroll/browser/terminalStickyScrollOverlay.js +0 -372
|
@@ -1,282 +0,0 @@
|
|
|
1
|
-
import { basename, isAbsolute, join } from '../../../../base/common/path.js';
|
|
2
|
-
import { URI } from '../../../../base/common/uri.js';
|
|
3
|
-
import { sanitizeProcessEnvironment } from '../../../../base/common/processes.js';
|
|
4
|
-
import { isWindows, isMacintosh, language } from '../../../../base/common/platform.js';
|
|
5
|
-
import { escapeNonWindowsPath, sanitizeCwd } from '../../../../platform/terminal/common/terminalEnvironment.js';
|
|
6
|
-
import { isString } from '../../../../base/common/types.js';
|
|
7
|
-
function mergeEnvironments(parent, other) {
|
|
8
|
-
if (!other) {
|
|
9
|
-
return;
|
|
10
|
-
}
|
|
11
|
-
if (isWindows) {
|
|
12
|
-
for (const configKey in other) {
|
|
13
|
-
let actualKey = configKey;
|
|
14
|
-
for (const envKey in parent) {
|
|
15
|
-
if (configKey.toLowerCase() === envKey.toLowerCase()) {
|
|
16
|
-
actualKey = envKey;
|
|
17
|
-
break;
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
const value = other[configKey];
|
|
21
|
-
if (value !== undefined) {
|
|
22
|
-
_mergeEnvironmentValue(parent, actualKey, value);
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
else {
|
|
27
|
-
( Object.keys(other)).forEach((key) => {
|
|
28
|
-
const value = other[key];
|
|
29
|
-
if (value !== undefined) {
|
|
30
|
-
_mergeEnvironmentValue(parent, key, value);
|
|
31
|
-
}
|
|
32
|
-
});
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
function _mergeEnvironmentValue(env, key, value) {
|
|
36
|
-
if (typeof value === 'string') {
|
|
37
|
-
env[key] = value;
|
|
38
|
-
}
|
|
39
|
-
else {
|
|
40
|
-
delete env[key];
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
function addTerminalEnvironmentKeys(env, version, locale, detectLocale) {
|
|
44
|
-
env['TERM_PROGRAM'] = 'vscode';
|
|
45
|
-
if (version) {
|
|
46
|
-
env['TERM_PROGRAM_VERSION'] = version;
|
|
47
|
-
}
|
|
48
|
-
if (shouldSetLangEnvVariable(env, detectLocale)) {
|
|
49
|
-
env['LANG'] = getLangEnvVariable(locale);
|
|
50
|
-
}
|
|
51
|
-
env['COLORTERM'] = 'truecolor';
|
|
52
|
-
}
|
|
53
|
-
function mergeNonNullKeys(env, other) {
|
|
54
|
-
if (!other) {
|
|
55
|
-
return;
|
|
56
|
-
}
|
|
57
|
-
for (const key of ( Object.keys(other))) {
|
|
58
|
-
const value = other[key];
|
|
59
|
-
if (value !== undefined && value !== null) {
|
|
60
|
-
env[key] = value;
|
|
61
|
-
}
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
async function resolveConfigurationVariables(variableResolver, env) {
|
|
65
|
-
await Promise.all(( Object.entries(env).map(async ([key, value]) => {
|
|
66
|
-
if (typeof value === 'string') {
|
|
67
|
-
try {
|
|
68
|
-
env[key] = await variableResolver(value);
|
|
69
|
-
}
|
|
70
|
-
catch (e) {
|
|
71
|
-
env[key] = value;
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
})));
|
|
75
|
-
return env;
|
|
76
|
-
}
|
|
77
|
-
function shouldSetLangEnvVariable(env, detectLocale) {
|
|
78
|
-
if (detectLocale === 'on') {
|
|
79
|
-
return true;
|
|
80
|
-
}
|
|
81
|
-
if (detectLocale === 'auto') {
|
|
82
|
-
const lang = env['LANG'];
|
|
83
|
-
return !lang || (lang.search(/\.UTF\-8$/) === -1 && lang.search(/\.utf8$/) === -1 && lang.search(/\.euc.+/) === -1);
|
|
84
|
-
}
|
|
85
|
-
return false;
|
|
86
|
-
}
|
|
87
|
-
function getLangEnvVariable(locale) {
|
|
88
|
-
const parts = locale ? locale.split('-') : [];
|
|
89
|
-
const n = parts.length;
|
|
90
|
-
if (n === 0) {
|
|
91
|
-
return 'en_US.UTF-8';
|
|
92
|
-
}
|
|
93
|
-
if (n === 1) {
|
|
94
|
-
const languageVariants = {
|
|
95
|
-
af: 'ZA',
|
|
96
|
-
am: 'ET',
|
|
97
|
-
be: 'BY',
|
|
98
|
-
bg: 'BG',
|
|
99
|
-
ca: 'ES',
|
|
100
|
-
cs: 'CZ',
|
|
101
|
-
da: 'DK',
|
|
102
|
-
de: 'DE',
|
|
103
|
-
el: 'GR',
|
|
104
|
-
en: 'US',
|
|
105
|
-
es: 'ES',
|
|
106
|
-
et: 'EE',
|
|
107
|
-
eu: 'ES',
|
|
108
|
-
fi: 'FI',
|
|
109
|
-
fr: 'FR',
|
|
110
|
-
he: 'IL',
|
|
111
|
-
hr: 'HR',
|
|
112
|
-
hu: 'HU',
|
|
113
|
-
hy: 'AM',
|
|
114
|
-
is: 'IS',
|
|
115
|
-
it: 'IT',
|
|
116
|
-
ja: 'JP',
|
|
117
|
-
kk: 'KZ',
|
|
118
|
-
ko: 'KR',
|
|
119
|
-
lt: 'LT',
|
|
120
|
-
nl: 'NL',
|
|
121
|
-
no: 'NO',
|
|
122
|
-
pl: 'PL',
|
|
123
|
-
pt: 'BR',
|
|
124
|
-
ro: 'RO',
|
|
125
|
-
ru: 'RU',
|
|
126
|
-
sk: 'SK',
|
|
127
|
-
sl: 'SI',
|
|
128
|
-
sr: 'YU',
|
|
129
|
-
sv: 'SE',
|
|
130
|
-
tr: 'TR',
|
|
131
|
-
uk: 'UA',
|
|
132
|
-
zh: 'CN',
|
|
133
|
-
};
|
|
134
|
-
if (parts[0] in languageVariants) {
|
|
135
|
-
parts.push(languageVariants[parts[0]]);
|
|
136
|
-
}
|
|
137
|
-
}
|
|
138
|
-
else {
|
|
139
|
-
parts[1] = parts[1].toUpperCase();
|
|
140
|
-
}
|
|
141
|
-
return parts.join('_') + '.UTF-8';
|
|
142
|
-
}
|
|
143
|
-
async function getCwd(shell, userHome, variableResolver, root, customCwd, logService) {
|
|
144
|
-
if (shell.cwd) {
|
|
145
|
-
const unresolved = (typeof shell.cwd === 'object') ? shell.cwd.fsPath : shell.cwd;
|
|
146
|
-
const resolved = await _resolveCwd(unresolved, variableResolver);
|
|
147
|
-
return sanitizeCwd(resolved || unresolved);
|
|
148
|
-
}
|
|
149
|
-
let cwd;
|
|
150
|
-
if (!shell.ignoreConfigurationCwd && customCwd) {
|
|
151
|
-
if (variableResolver) {
|
|
152
|
-
customCwd = await _resolveCwd(customCwd, variableResolver, logService);
|
|
153
|
-
}
|
|
154
|
-
if (customCwd) {
|
|
155
|
-
if (isAbsolute(customCwd)) {
|
|
156
|
-
cwd = customCwd;
|
|
157
|
-
}
|
|
158
|
-
else if (root) {
|
|
159
|
-
cwd = join(root.fsPath, customCwd);
|
|
160
|
-
}
|
|
161
|
-
}
|
|
162
|
-
}
|
|
163
|
-
if (!cwd) {
|
|
164
|
-
cwd = root ? root.fsPath : userHome || '';
|
|
165
|
-
}
|
|
166
|
-
return sanitizeCwd(cwd);
|
|
167
|
-
}
|
|
168
|
-
async function _resolveCwd(cwd, variableResolver, logService) {
|
|
169
|
-
if (variableResolver) {
|
|
170
|
-
try {
|
|
171
|
-
return await variableResolver(cwd);
|
|
172
|
-
}
|
|
173
|
-
catch (e) {
|
|
174
|
-
logService?.error('Could not resolve terminal cwd', e);
|
|
175
|
-
return undefined;
|
|
176
|
-
}
|
|
177
|
-
}
|
|
178
|
-
return cwd;
|
|
179
|
-
}
|
|
180
|
-
function createVariableResolver(lastActiveWorkspace, env, configurationResolverService) {
|
|
181
|
-
if (!configurationResolverService) {
|
|
182
|
-
return undefined;
|
|
183
|
-
}
|
|
184
|
-
return (str) => configurationResolverService.resolveWithEnvironment(env, lastActiveWorkspace, str);
|
|
185
|
-
}
|
|
186
|
-
async function createTerminalEnvironment(shellLaunchConfig, envFromConfig, variableResolver, version, detectLocale, baseEnv) {
|
|
187
|
-
const env = {};
|
|
188
|
-
if (shellLaunchConfig.strictEnv) {
|
|
189
|
-
mergeNonNullKeys(env, shellLaunchConfig.env);
|
|
190
|
-
}
|
|
191
|
-
else {
|
|
192
|
-
mergeNonNullKeys(env, baseEnv);
|
|
193
|
-
const allowedEnvFromConfig = { ...envFromConfig };
|
|
194
|
-
if (variableResolver) {
|
|
195
|
-
if (allowedEnvFromConfig) {
|
|
196
|
-
await resolveConfigurationVariables(variableResolver, allowedEnvFromConfig);
|
|
197
|
-
}
|
|
198
|
-
if (shellLaunchConfig.env) {
|
|
199
|
-
await resolveConfigurationVariables(variableResolver, shellLaunchConfig.env);
|
|
200
|
-
}
|
|
201
|
-
}
|
|
202
|
-
if (isMacintosh) {
|
|
203
|
-
if (env['VSCODE_NODE_OPTIONS']) {
|
|
204
|
-
env['NODE_OPTIONS'] = env['VSCODE_NODE_OPTIONS'];
|
|
205
|
-
delete env['VSCODE_NODE_OPTIONS'];
|
|
206
|
-
}
|
|
207
|
-
if (env['VSCODE_NODE_REPL_EXTERNAL_MODULE']) {
|
|
208
|
-
env['NODE_REPL_EXTERNAL_MODULE'] = env['VSCODE_NODE_REPL_EXTERNAL_MODULE'];
|
|
209
|
-
delete env['VSCODE_NODE_REPL_EXTERNAL_MODULE'];
|
|
210
|
-
}
|
|
211
|
-
}
|
|
212
|
-
sanitizeProcessEnvironment(env, 'VSCODE_IPC_HOOK_CLI');
|
|
213
|
-
mergeEnvironments(env, allowedEnvFromConfig);
|
|
214
|
-
mergeEnvironments(env, shellLaunchConfig.env);
|
|
215
|
-
addTerminalEnvironmentKeys(env, version, language, detectLocale);
|
|
216
|
-
}
|
|
217
|
-
return env;
|
|
218
|
-
}
|
|
219
|
-
async function preparePathForShell(resource, executable, title, shellType, backend, os, isWindowsFrontend = isWindows) {
|
|
220
|
-
let originalPath;
|
|
221
|
-
if (isString(resource)) {
|
|
222
|
-
originalPath = resource;
|
|
223
|
-
}
|
|
224
|
-
else {
|
|
225
|
-
originalPath = resource.fsPath;
|
|
226
|
-
if (isWindowsFrontend && os !== 1 ) {
|
|
227
|
-
originalPath = originalPath.replace(/\\/g, '\/');
|
|
228
|
-
}
|
|
229
|
-
else if (!isWindowsFrontend && os === 1 ) {
|
|
230
|
-
originalPath = originalPath.replace(/\//g, '\\');
|
|
231
|
-
}
|
|
232
|
-
}
|
|
233
|
-
if (!executable) {
|
|
234
|
-
return originalPath;
|
|
235
|
-
}
|
|
236
|
-
const hasSpace = originalPath.includes(' ');
|
|
237
|
-
const hasParens = originalPath.includes('(') || originalPath.includes(')');
|
|
238
|
-
const pathBasename = basename(executable, '.exe');
|
|
239
|
-
const isPowerShell = pathBasename === 'pwsh' ||
|
|
240
|
-
title === 'pwsh' ||
|
|
241
|
-
pathBasename === 'powershell' ||
|
|
242
|
-
title === 'powershell';
|
|
243
|
-
if (isPowerShell && (hasSpace || originalPath.includes('\''))) {
|
|
244
|
-
return `& '${originalPath.replace(/'/g, '\'\'')}'`;
|
|
245
|
-
}
|
|
246
|
-
if (hasParens && isPowerShell) {
|
|
247
|
-
return `& '${originalPath}'`;
|
|
248
|
-
}
|
|
249
|
-
if (os === 1 ) {
|
|
250
|
-
if (shellType !== undefined) {
|
|
251
|
-
if (shellType === "gitbash" ) {
|
|
252
|
-
return escapeNonWindowsPath(originalPath.replace(/\\/g, '/'));
|
|
253
|
-
}
|
|
254
|
-
else if (shellType === "wsl" ) {
|
|
255
|
-
return backend?.getWslPath(originalPath, 'win-to-unix') || originalPath;
|
|
256
|
-
}
|
|
257
|
-
else if (hasSpace) {
|
|
258
|
-
return `"${originalPath}"`;
|
|
259
|
-
}
|
|
260
|
-
return originalPath;
|
|
261
|
-
}
|
|
262
|
-
const lowerExecutable = executable.toLowerCase();
|
|
263
|
-
if (lowerExecutable.includes('wsl') || (lowerExecutable.includes('bash.exe') && !lowerExecutable.toLowerCase().includes('git'))) {
|
|
264
|
-
return backend?.getWslPath(originalPath, 'win-to-unix') || originalPath;
|
|
265
|
-
}
|
|
266
|
-
else if (hasSpace) {
|
|
267
|
-
return `"${originalPath}"`;
|
|
268
|
-
}
|
|
269
|
-
return originalPath;
|
|
270
|
-
}
|
|
271
|
-
return escapeNonWindowsPath(originalPath);
|
|
272
|
-
}
|
|
273
|
-
function getWorkspaceForTerminal(cwd, workspaceContextService, historyService) {
|
|
274
|
-
const cwdUri = typeof cwd === 'string' ? ( URI.parse(cwd)) : cwd;
|
|
275
|
-
let workspaceFolder = cwdUri ? workspaceContextService.getWorkspaceFolder(cwdUri) ?? undefined : undefined;
|
|
276
|
-
if (!workspaceFolder) {
|
|
277
|
-
const activeWorkspaceRootUri = historyService.getLastActiveWorkspaceRoot();
|
|
278
|
-
workspaceFolder = activeWorkspaceRootUri ? workspaceContextService.getWorkspaceFolder(activeWorkspaceRootUri) ?? undefined : undefined;
|
|
279
|
-
}
|
|
280
|
-
return workspaceFolder;
|
|
281
|
-
}
|
|
282
|
-
export { addTerminalEnvironmentKeys, createTerminalEnvironment, createVariableResolver, getCwd, getLangEnvVariable, getWorkspaceForTerminal, mergeEnvironments, preparePathForShell, shouldSetLangEnvVariable };
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
import { localize, localize2 } from '../../../../nls.js';
|
|
2
|
-
const terminalStrings = {
|
|
3
|
-
terminal: ( localize(9328, "Terminal")),
|
|
4
|
-
new: ( localize(9329, "New Terminal")),
|
|
5
|
-
doNotShowAgain: ( localize(9330, 'Do Not Show Again')),
|
|
6
|
-
currentSessionCategory: ( localize(9331, 'current session')),
|
|
7
|
-
previousSessionCategory: ( localize(9332, 'previous session')),
|
|
8
|
-
typeTask: ( localize(9333, "Task")),
|
|
9
|
-
typeLocal: ( localize(9334, "Local")),
|
|
10
|
-
actionCategory: ( localize2(9335, "Terminal")),
|
|
11
|
-
focus: ( localize2(9336, "Focus Terminal")),
|
|
12
|
-
focusAndHideAccessibleBuffer: ( localize2(9337, "Focus Terminal and Hide Accessible Buffer")),
|
|
13
|
-
kill: {
|
|
14
|
-
...( localize2(9338, "Kill Terminal")),
|
|
15
|
-
short: ( localize(9339, "Kill")),
|
|
16
|
-
},
|
|
17
|
-
moveToEditor: ( localize2(9340, "Move Terminal into Editor Area")),
|
|
18
|
-
moveIntoNewWindow: ( localize2(9341, "Move Terminal into New Window")),
|
|
19
|
-
moveToTerminalPanel: ( localize2(9342, "Move Terminal into Panel")),
|
|
20
|
-
changeIcon: ( localize2(9343, "Change Icon...")),
|
|
21
|
-
changeColor: ( localize2(9344, "Change Color...")),
|
|
22
|
-
split: {
|
|
23
|
-
...( localize2(9345, "Split Terminal")),
|
|
24
|
-
short: ( localize(9346, "Split")),
|
|
25
|
-
},
|
|
26
|
-
unsplit: ( localize2(9347, "Unsplit Terminal")),
|
|
27
|
-
rename: ( localize2(9348, "Rename...")),
|
|
28
|
-
toggleSizeToContentWidth: ( localize2(9349, "Toggle Size to Content Width")),
|
|
29
|
-
focusHover: ( localize2(9350, "Focus Hover")),
|
|
30
|
-
sendSequence: ( localize2(9351, "Send Custom Sequence To Terminal")),
|
|
31
|
-
newWithCwd: ( localize2(9352, "Create New Terminal Starting in a Custom Working Directory")),
|
|
32
|
-
renameWithArgs: ( localize2(9353, "Rename the Currently Active Terminal")),
|
|
33
|
-
scrollToPreviousCommand: ( localize2(9354, "Scroll To Previous Command")),
|
|
34
|
-
scrollToNextCommand: ( localize2(9355, "Scroll To Next Command"))
|
|
35
|
-
};
|
|
36
|
-
export { terminalStrings };
|
package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/media/terminalChatWidget.css.js
DELETED
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import n from '../../../../../../../../../external/rollup-plugin-styles/dist/runtime/inject-css.js';
|
|
2
|
-
var css = ".terminal-inline-chat{bottom:0;height:auto!important;left:0;position:absolute;z-index:100}.terminal-inline-chat .inline-chat{margin-top:0!important}.terminal-inline-chat.hide{visibility:hidden}.terminal-inline-chat .chatMessageContent .value{padding-top:10px}.terminal-inline-chat .inline-chat-input .monaco-editor-background{background-color:var(--vscode-inlineChatInput-background)!important}";
|
|
3
|
-
n(css,{});
|
|
4
|
-
export { css, css as default };
|
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
import { localize } from '../../../../../nls.js';
|
|
2
|
-
import { MenuId } from '../../../../../platform/actions/common/actions.js';
|
|
3
|
-
import { RawContextKey } from '../../../../../platform/contextkey/common/contextkey.js';
|
|
4
|
-
const MENU_TERMINAL_CHAT_INPUT = MenuId.for('terminalChatInput');
|
|
5
|
-
const MENU_TERMINAL_CHAT_WIDGET = MenuId.for('terminalChatWidget');
|
|
6
|
-
const MENU_TERMINAL_CHAT_WIDGET_STATUS = MenuId.for('terminalChatWidget.status');
|
|
7
|
-
MenuId.for('terminalChatWidget.toolbar');
|
|
8
|
-
var TerminalChatContextKeys;
|
|
9
|
-
( ((function(TerminalChatContextKeys) {
|
|
10
|
-
TerminalChatContextKeys.focused = ( (new RawContextKey(
|
|
11
|
-
"terminalChatFocus" ,
|
|
12
|
-
false,
|
|
13
|
-
( localize(10685, "Whether the chat view is focused."))
|
|
14
|
-
)));
|
|
15
|
-
TerminalChatContextKeys.visible = ( (new RawContextKey(
|
|
16
|
-
"terminalChatVisible" ,
|
|
17
|
-
false,
|
|
18
|
-
( localize(10686, "Whether the chat view is visible."))
|
|
19
|
-
)));
|
|
20
|
-
TerminalChatContextKeys.requestActive = ( (new RawContextKey(
|
|
21
|
-
"terminalChatActiveRequest" ,
|
|
22
|
-
false,
|
|
23
|
-
( localize(10687, "Whether there is an active chat request."))
|
|
24
|
-
)));
|
|
25
|
-
TerminalChatContextKeys.inputHasText = ( (new RawContextKey(
|
|
26
|
-
"terminalChatInputHasText" ,
|
|
27
|
-
false,
|
|
28
|
-
( localize(10688, "Whether the chat input has text."))
|
|
29
|
-
)));
|
|
30
|
-
TerminalChatContextKeys.responseContainsCodeBlock = ( (new RawContextKey(
|
|
31
|
-
"terminalChatResponseContainsCodeBlock" ,
|
|
32
|
-
false,
|
|
33
|
-
( localize(10689, "Whether the chat response contains a code block."))
|
|
34
|
-
)));
|
|
35
|
-
TerminalChatContextKeys.responseContainsMultipleCodeBlocks = ( (new RawContextKey(
|
|
36
|
-
"terminalChatResponseContainsMultipleCodeBlocks" ,
|
|
37
|
-
false,
|
|
38
|
-
( localize(10690, "Whether the chat response contains multiple code blocks."))
|
|
39
|
-
)));
|
|
40
|
-
TerminalChatContextKeys.hasChatAgent = ( (new RawContextKey(
|
|
41
|
-
"terminalChatAgentRegistered" ,
|
|
42
|
-
false,
|
|
43
|
-
( localize(10691, "Whether a chat agent is registered for the terminal location."))
|
|
44
|
-
)));
|
|
45
|
-
})(TerminalChatContextKeys || (TerminalChatContextKeys = {}))));
|
|
46
|
-
export { MENU_TERMINAL_CHAT_INPUT, MENU_TERMINAL_CHAT_WIDGET, MENU_TERMINAL_CHAT_WIDGET_STATUS, TerminalChatContextKeys };
|
package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatController.js
DELETED
|
@@ -1,303 +0,0 @@
|
|
|
1
|
-
import { __decorate, __param } from '../../../../../../../../external/tslib/tslib.es6.js';
|
|
2
|
-
import { CancellationTokenSource } from '../../../../../base/common/cancellation.js';
|
|
3
|
-
import { Event, Emitter } from '../../../../../base/common/event.js';
|
|
4
|
-
import { Lazy } from '../../../../../base/common/lazy.js';
|
|
5
|
-
import { Disposable, MutableDisposable, toDisposable, DisposableStore } from '../../../../../base/common/lifecycle.js';
|
|
6
|
-
import { IContextKeyService } from '../../../../../platform/contextkey/common/contextkey.service.js';
|
|
7
|
-
import { IInstantiationService } from '../../../../../platform/instantiation/common/instantiation.js';
|
|
8
|
-
import { showChatView } from '../../../chat/browser/chat.js';
|
|
9
|
-
import { IChatCodeBlockContextProviderService } from '../../../chat/browser/chat.service.js';
|
|
10
|
-
import { IChatService } from '../../../chat/common/chatService.service.js';
|
|
11
|
-
import { isDetachedTerminalInstance } from '../../../terminal/browser/terminal.js';
|
|
12
|
-
import { ITerminalService } from '../../../terminal/browser/terminal.service.js';
|
|
13
|
-
import { TerminalChatWidget } from './terminalChatWidget.js';
|
|
14
|
-
import { MarkdownString } from '../../../../../base/common/htmlContent.js';
|
|
15
|
-
import { TerminalChatContextKeys } from './terminalChat.js';
|
|
16
|
-
import { IViewsService } from '../../../../services/views/common/viewsService.service.js';
|
|
17
|
-
import { IStorageService } from '../../../../../platform/storage/common/storage.service.js';
|
|
18
|
-
import { assertType } from '../../../../../base/common/types.js';
|
|
19
|
-
import { createCancelablePromise, DeferredPromise } from '../../../../../base/common/async.js';
|
|
20
|
-
import { ChatAgentLocation } from '../../../chat/common/chatAgents.js';
|
|
21
|
-
var TerminalChatController_1;
|
|
22
|
-
let TerminalChatController = class TerminalChatController extends Disposable {
|
|
23
|
-
static { TerminalChatController_1 = this; }
|
|
24
|
-
static { this.ID = 'terminal.chat'; }
|
|
25
|
-
static get(instance) {
|
|
26
|
-
return instance.getContribution(TerminalChatController_1.ID);
|
|
27
|
-
}
|
|
28
|
-
static { this._storageKey = 'terminal-inline-chat-history'; }
|
|
29
|
-
static { this._promptHistory = []; }
|
|
30
|
-
get terminalChatWidget() { return this._terminalChatWidget?.value; }
|
|
31
|
-
get chatWidget() { return this._terminalChatWidget?.value.inlineChatWidget?.chatWidget; }
|
|
32
|
-
get lastResponseContent() {
|
|
33
|
-
return this._lastResponseContent;
|
|
34
|
-
}
|
|
35
|
-
get onDidHide() { return this.terminalChatWidget?.onDidHide ?? Event.None; }
|
|
36
|
-
get scopedContextKeyService() {
|
|
37
|
-
return this._terminalChatWidget?.value.inlineChatWidget.scopedContextKeyService ?? this._contextKeyService;
|
|
38
|
-
}
|
|
39
|
-
constructor(_instance, processManager, widgetManager, _terminalService, _instantiationService, _contextKeyService, _chatService, _chatCodeBlockContextProviderService, _viewsService, _storageService) {
|
|
40
|
-
super();
|
|
41
|
-
this._instance = _instance;
|
|
42
|
-
this._terminalService = _terminalService;
|
|
43
|
-
this._instantiationService = _instantiationService;
|
|
44
|
-
this._contextKeyService = _contextKeyService;
|
|
45
|
-
this._chatService = _chatService;
|
|
46
|
-
this._chatCodeBlockContextProviderService = _chatCodeBlockContextProviderService;
|
|
47
|
-
this._viewsService = _viewsService;
|
|
48
|
-
this._storageService = _storageService;
|
|
49
|
-
this._messages = this._store.add(( new Emitter()));
|
|
50
|
-
this.onDidAcceptInput = Event.filter(this._messages.event, m => m === 32 , this._store);
|
|
51
|
-
this._terminalAgentName = 'terminal';
|
|
52
|
-
this._model = this._register(( new MutableDisposable()));
|
|
53
|
-
this._historyOffset = -1;
|
|
54
|
-
this._historyCandidate = '';
|
|
55
|
-
this._forcedPlaceholder = undefined;
|
|
56
|
-
this._requestActiveContextKey = TerminalChatContextKeys.requestActive.bindTo(this._contextKeyService);
|
|
57
|
-
this._responseContainsCodeBlockContextKey = TerminalChatContextKeys.responseContainsCodeBlock.bindTo(this._contextKeyService);
|
|
58
|
-
this._responseContainsMulitpleCodeBlocksContextKey = TerminalChatContextKeys.responseContainsMultipleCodeBlocks.bindTo(this._contextKeyService);
|
|
59
|
-
this._register(this._chatCodeBlockContextProviderService.registerProvider({
|
|
60
|
-
getCodeBlockContext: (editor) => {
|
|
61
|
-
if (!editor || !this._terminalChatWidget?.hasValue || !this.hasFocus()) {
|
|
62
|
-
return;
|
|
63
|
-
}
|
|
64
|
-
return {
|
|
65
|
-
element: editor,
|
|
66
|
-
code: editor.getValue(),
|
|
67
|
-
codeBlockIndex: 0,
|
|
68
|
-
languageId: editor.getModel().getLanguageId()
|
|
69
|
-
};
|
|
70
|
-
}
|
|
71
|
-
}, 'terminal'));
|
|
72
|
-
TerminalChatController_1._promptHistory = JSON.parse(this._storageService.get(TerminalChatController_1._storageKey, 0 , '[]'));
|
|
73
|
-
this._historyUpdate = (prompt) => {
|
|
74
|
-
const idx = TerminalChatController_1._promptHistory.indexOf(prompt);
|
|
75
|
-
if (idx >= 0) {
|
|
76
|
-
TerminalChatController_1._promptHistory.splice(idx, 1);
|
|
77
|
-
}
|
|
78
|
-
TerminalChatController_1._promptHistory.unshift(prompt);
|
|
79
|
-
this._historyOffset = -1;
|
|
80
|
-
this._historyCandidate = '';
|
|
81
|
-
this._storageService.store(TerminalChatController_1._storageKey, JSON.stringify(TerminalChatController_1._promptHistory), 0 , 0 );
|
|
82
|
-
};
|
|
83
|
-
}
|
|
84
|
-
xtermReady(xterm) {
|
|
85
|
-
this._terminalChatWidget = ( new Lazy(() => {
|
|
86
|
-
const chatWidget = this._register(this._instantiationService.createInstance(TerminalChatWidget, this._instance.domElement, this._instance, xterm));
|
|
87
|
-
this._register(chatWidget.focusTracker.onDidFocus(() => {
|
|
88
|
-
TerminalChatController_1.activeChatController = this;
|
|
89
|
-
if (!isDetachedTerminalInstance(this._instance)) {
|
|
90
|
-
this._terminalService.setActiveInstance(this._instance);
|
|
91
|
-
}
|
|
92
|
-
}));
|
|
93
|
-
this._register(chatWidget.focusTracker.onDidBlur(() => {
|
|
94
|
-
TerminalChatController_1.activeChatController = undefined;
|
|
95
|
-
this._instance.resetScrollbarVisibility();
|
|
96
|
-
}));
|
|
97
|
-
if (!this._instance.domElement) {
|
|
98
|
-
throw ( new Error('FindWidget expected terminal DOM to be initialized'));
|
|
99
|
-
}
|
|
100
|
-
return chatWidget;
|
|
101
|
-
}));
|
|
102
|
-
}
|
|
103
|
-
async _createSession() {
|
|
104
|
-
this._sessionCtor = createCancelablePromise(async (token) => {
|
|
105
|
-
if (!this._model.value) {
|
|
106
|
-
this._model.value = this._chatService.startSession(ChatAgentLocation.Terminal, token);
|
|
107
|
-
if (!this._model.value) {
|
|
108
|
-
throw ( new Error('Failed to start chat session'));
|
|
109
|
-
}
|
|
110
|
-
}
|
|
111
|
-
});
|
|
112
|
-
this._register(toDisposable(() => this._sessionCtor?.cancel()));
|
|
113
|
-
}
|
|
114
|
-
_updatePlaceholder() {
|
|
115
|
-
const inlineChatWidget = this._terminalChatWidget?.value.inlineChatWidget;
|
|
116
|
-
if (inlineChatWidget) {
|
|
117
|
-
inlineChatWidget.placeholder = this._getPlaceholderText();
|
|
118
|
-
}
|
|
119
|
-
}
|
|
120
|
-
_getPlaceholderText() {
|
|
121
|
-
return this._forcedPlaceholder ?? '';
|
|
122
|
-
}
|
|
123
|
-
setPlaceholder(text) {
|
|
124
|
-
this._forcedPlaceholder = text;
|
|
125
|
-
this._updatePlaceholder();
|
|
126
|
-
}
|
|
127
|
-
resetPlaceholder() {
|
|
128
|
-
this._forcedPlaceholder = undefined;
|
|
129
|
-
this._updatePlaceholder();
|
|
130
|
-
}
|
|
131
|
-
clear() {
|
|
132
|
-
this.cancel();
|
|
133
|
-
this._model.clear();
|
|
134
|
-
this._responseContainsCodeBlockContextKey.reset();
|
|
135
|
-
this._requestActiveContextKey.reset();
|
|
136
|
-
this._terminalChatWidget?.value.hide();
|
|
137
|
-
this._terminalChatWidget?.value.setValue(undefined);
|
|
138
|
-
}
|
|
139
|
-
async acceptInput(isVoiceInput) {
|
|
140
|
-
assertType(this._terminalChatWidget);
|
|
141
|
-
if (!this._model.value) {
|
|
142
|
-
await this.reveal();
|
|
143
|
-
}
|
|
144
|
-
assertType(this._model.value);
|
|
145
|
-
this._messages.fire(32 );
|
|
146
|
-
const lastInput = this._terminalChatWidget.value.inlineChatWidget.value;
|
|
147
|
-
if (!lastInput) {
|
|
148
|
-
return;
|
|
149
|
-
}
|
|
150
|
-
const model = this._model.value;
|
|
151
|
-
this._terminalChatWidget.value.inlineChatWidget.setChatModel(model);
|
|
152
|
-
this._historyUpdate(lastInput);
|
|
153
|
-
this._activeRequestCts?.cancel();
|
|
154
|
-
this._activeRequestCts = ( new CancellationTokenSource());
|
|
155
|
-
const store = ( new DisposableStore());
|
|
156
|
-
this._requestActiveContextKey.set(true);
|
|
157
|
-
let responseContent = '';
|
|
158
|
-
const response = await this._terminalChatWidget.value.inlineChatWidget.chatWidget.acceptInput(lastInput, isVoiceInput);
|
|
159
|
-
this._currentRequestId = response?.requestId;
|
|
160
|
-
const responsePromise = ( new DeferredPromise());
|
|
161
|
-
try {
|
|
162
|
-
this._requestActiveContextKey.set(true);
|
|
163
|
-
if (response) {
|
|
164
|
-
store.add(response.onDidChange(async () => {
|
|
165
|
-
responseContent += response.response.value;
|
|
166
|
-
if (response.isCanceled) {
|
|
167
|
-
this._requestActiveContextKey.set(false);
|
|
168
|
-
responsePromise.complete(undefined);
|
|
169
|
-
return;
|
|
170
|
-
}
|
|
171
|
-
if (response.isComplete) {
|
|
172
|
-
this._requestActiveContextKey.set(false);
|
|
173
|
-
this._requestActiveContextKey.set(false);
|
|
174
|
-
const containsCode = responseContent.includes('```');
|
|
175
|
-
this._terminalChatWidget.value.inlineChatWidget.updateChatMessage({ message: ( new MarkdownString(responseContent)), requestId: response.requestId }, false, containsCode);
|
|
176
|
-
const firstCodeBlock = await this.terminalChatWidget?.inlineChatWidget.getCodeBlockInfo(0);
|
|
177
|
-
const secondCodeBlock = await this.terminalChatWidget?.inlineChatWidget.getCodeBlockInfo(1);
|
|
178
|
-
this._responseContainsCodeBlockContextKey.set(!!firstCodeBlock);
|
|
179
|
-
this._responseContainsMulitpleCodeBlocksContextKey.set(!!secondCodeBlock);
|
|
180
|
-
this._terminalChatWidget?.value.inlineChatWidget.updateToolbar(true);
|
|
181
|
-
responsePromise.complete(response);
|
|
182
|
-
}
|
|
183
|
-
}));
|
|
184
|
-
}
|
|
185
|
-
await responsePromise.p;
|
|
186
|
-
return response;
|
|
187
|
-
}
|
|
188
|
-
catch {
|
|
189
|
-
return;
|
|
190
|
-
}
|
|
191
|
-
finally {
|
|
192
|
-
store.dispose();
|
|
193
|
-
}
|
|
194
|
-
}
|
|
195
|
-
updateInput(text, selectAll = true) {
|
|
196
|
-
const widget = this._terminalChatWidget?.value.inlineChatWidget;
|
|
197
|
-
if (widget) {
|
|
198
|
-
widget.value = text;
|
|
199
|
-
if (selectAll) {
|
|
200
|
-
widget.selectAll();
|
|
201
|
-
}
|
|
202
|
-
}
|
|
203
|
-
}
|
|
204
|
-
getInput() {
|
|
205
|
-
return this._terminalChatWidget?.value.input() ?? '';
|
|
206
|
-
}
|
|
207
|
-
focus() {
|
|
208
|
-
this._terminalChatWidget?.value.focus();
|
|
209
|
-
}
|
|
210
|
-
hasFocus() {
|
|
211
|
-
return this._terminalChatWidget?.rawValue?.hasFocus() ?? false;
|
|
212
|
-
}
|
|
213
|
-
populateHistory(up) {
|
|
214
|
-
if (!this._terminalChatWidget?.value) {
|
|
215
|
-
return;
|
|
216
|
-
}
|
|
217
|
-
const len = TerminalChatController_1._promptHistory.length;
|
|
218
|
-
if (len === 0) {
|
|
219
|
-
return;
|
|
220
|
-
}
|
|
221
|
-
if (this._historyOffset === -1) {
|
|
222
|
-
this._historyCandidate = this._terminalChatWidget.value.inlineChatWidget.value;
|
|
223
|
-
}
|
|
224
|
-
const newIdx = this._historyOffset + (up ? 1 : -1);
|
|
225
|
-
if (newIdx >= len) {
|
|
226
|
-
return;
|
|
227
|
-
}
|
|
228
|
-
let entry;
|
|
229
|
-
if (newIdx < 0) {
|
|
230
|
-
entry = this._historyCandidate;
|
|
231
|
-
this._historyOffset = -1;
|
|
232
|
-
}
|
|
233
|
-
else {
|
|
234
|
-
entry = TerminalChatController_1._promptHistory[newIdx];
|
|
235
|
-
this._historyOffset = newIdx;
|
|
236
|
-
}
|
|
237
|
-
this._terminalChatWidget.value.inlineChatWidget.value = entry;
|
|
238
|
-
this._terminalChatWidget.value.inlineChatWidget.selectAll();
|
|
239
|
-
}
|
|
240
|
-
cancel() {
|
|
241
|
-
this._sessionCtor?.cancel();
|
|
242
|
-
this._sessionCtor = undefined;
|
|
243
|
-
this._activeRequestCts?.cancel();
|
|
244
|
-
this._requestActiveContextKey.set(false);
|
|
245
|
-
const model = this._terminalChatWidget?.value.inlineChatWidget.getChatModel();
|
|
246
|
-
if (!model?.sessionId) {
|
|
247
|
-
return;
|
|
248
|
-
}
|
|
249
|
-
this._chatService.cancelCurrentRequestForSession(model?.sessionId);
|
|
250
|
-
}
|
|
251
|
-
async acceptCommand(shouldExecute) {
|
|
252
|
-
const code = await this.terminalChatWidget?.inlineChatWidget.getCodeBlockInfo(0);
|
|
253
|
-
if (!code) {
|
|
254
|
-
return;
|
|
255
|
-
}
|
|
256
|
-
this._terminalChatWidget?.value.acceptCommand(code.textEditorModel.getValue(), shouldExecute);
|
|
257
|
-
}
|
|
258
|
-
async reveal() {
|
|
259
|
-
await this._createSession();
|
|
260
|
-
this._terminalChatWidget?.value.reveal();
|
|
261
|
-
this._terminalChatWidget?.value.focus();
|
|
262
|
-
}
|
|
263
|
-
async viewInChat() {
|
|
264
|
-
const widget = await showChatView(this._viewsService);
|
|
265
|
-
const currentRequest = this.terminalChatWidget?.inlineChatWidget.chatWidget.viewModel?.model.getRequests().find(r => r.id === this._currentRequestId);
|
|
266
|
-
if (!widget || !currentRequest?.response) {
|
|
267
|
-
return;
|
|
268
|
-
}
|
|
269
|
-
const message = [];
|
|
270
|
-
for (const item of currentRequest.response.response.value) {
|
|
271
|
-
if (item.kind === 'textEditGroup') {
|
|
272
|
-
for (const group of item.edits) {
|
|
273
|
-
message.push({
|
|
274
|
-
kind: 'textEdit',
|
|
275
|
-
edits: group,
|
|
276
|
-
uri: item.uri
|
|
277
|
-
});
|
|
278
|
-
}
|
|
279
|
-
}
|
|
280
|
-
else {
|
|
281
|
-
message.push(item);
|
|
282
|
-
}
|
|
283
|
-
}
|
|
284
|
-
this._chatService.addCompleteRequest(widget.viewModel.sessionId,
|
|
285
|
-
`@${this._terminalAgentName} ${currentRequest.message.text}`, currentRequest.variableData, currentRequest.attempt, {
|
|
286
|
-
message,
|
|
287
|
-
result: currentRequest.response.result,
|
|
288
|
-
followups: currentRequest.response.followups
|
|
289
|
-
});
|
|
290
|
-
widget.focusLastMessage();
|
|
291
|
-
this._terminalChatWidget?.rawValue?.hide();
|
|
292
|
-
}
|
|
293
|
-
};
|
|
294
|
-
TerminalChatController = TerminalChatController_1 = ( __decorate([
|
|
295
|
-
( __param(3, ITerminalService)),
|
|
296
|
-
( __param(4, IInstantiationService)),
|
|
297
|
-
( __param(5, IContextKeyService)),
|
|
298
|
-
( __param(6, IChatService)),
|
|
299
|
-
( __param(7, IChatCodeBlockContextProviderService)),
|
|
300
|
-
( __param(8, IViewsService)),
|
|
301
|
-
( __param(9, IStorageService))
|
|
302
|
-
], TerminalChatController));
|
|
303
|
-
export { TerminalChatController };
|