@codingame/monaco-vscode-api 4.5.2 → 5.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/api.js +1 -1
- package/extensions.d.ts +2 -3
- package/lifecycle.js +6 -0
- package/localExtensionHost.d.ts +4 -1
- package/missing-services.js +41 -25
- package/package.json +8 -8
- package/service-override/tools/editor.js +31 -8
- package/service-override/tools/views.d.ts +1 -1
- package/service-override/tools/views.js +2 -3
- package/service-override/views.d.ts +0 -1
- package/services.d.ts +3 -3
- package/services.js +3 -3
- package/vscode/src/vs/base/browser/markdownRenderer.js +9 -3
- package/vscode/src/vs/base/browser/ui/actionbar/actionViewItems.js +2 -2
- package/vscode/src/vs/base/browser/ui/button/button.js +3 -3
- package/vscode/src/vs/base/browser/ui/codicons/codicon/codicon.css.js +1 -1
- package/vscode/src/vs/base/browser/ui/contextview/contextview.js +1 -1
- package/vscode/src/vs/base/browser/ui/dropdown/dropdown.js +2 -2
- package/vscode/src/vs/base/browser/ui/dropdown/dropdownActionViewItem.js +2 -2
- package/vscode/src/vs/base/browser/ui/highlightedlabel/highlightedLabel.js +2 -2
- package/vscode/src/vs/{platform/hover/browser → base/browser/ui/hover}/hover.d.ts +64 -4
- package/vscode/src/vs/base/browser/ui/hover/hoverDelegate.d.ts +1 -1
- package/vscode/src/vs/base/browser/ui/hover/hoverDelegate2.js +13 -0
- package/vscode/src/vs/base/browser/ui/hover/hoverWidget.css.js +1 -1
- package/vscode/src/vs/base/browser/ui/hover/hoverWidget.js +30 -14
- package/vscode/src/vs/base/browser/ui/iconLabel/iconLabel.js +15 -2
- package/vscode/src/vs/base/browser/ui/iconLabel/simpleIconLabel.js +2 -2
- package/vscode/src/vs/base/browser/ui/icons/iconSelectBox.css.js +4 -0
- package/vscode/src/vs/base/browser/ui/icons/iconSelectBox.js +239 -0
- package/vscode/src/vs/base/browser/ui/inputbox/inputBox.js +2 -2
- package/vscode/src/vs/base/browser/ui/keybindingLabel/keybindingLabel.js +2 -2
- package/vscode/src/vs/base/browser/ui/list/listView.js +5 -3
- package/vscode/src/vs/base/browser/ui/list/listWidget.d.ts +33 -0
- package/vscode/src/vs/base/browser/ui/list/listWidget.js +4 -1
- package/vscode/src/vs/base/browser/ui/menu/menu.js +1 -0
- package/vscode/src/vs/base/browser/ui/menu/menubar.css.js +1 -1
- package/vscode/src/vs/base/browser/ui/progressbar/progressAccessibilitySignal.js +13 -0
- package/vscode/src/vs/base/browser/ui/progressbar/progressbar.js +7 -1
- package/vscode/src/vs/base/browser/ui/selectBox/selectBoxCustom.js +2 -2
- package/vscode/src/vs/base/browser/ui/table/tableWidget.js +2 -2
- package/vscode/src/vs/base/browser/ui/toggle/toggle.js +8 -2
- package/vscode/src/vs/base/browser/ui/toolbar/toolbar.d.ts +1 -1
- package/vscode/src/vs/base/browser/ui/tree/abstractTree.js +11 -4
- package/vscode/src/vs/base/browser/ui/tree/media/tree.css.js +1 -1
- package/vscode/src/vs/base/browser/ui/tree/objectTree.js +6 -4
- package/vscode/src/vs/base/common/arraysFind.js +7 -7
- package/vscode/src/vs/base/common/async.js +8 -3
- package/vscode/src/vs/base/common/cache.js +29 -10
- package/vscode/src/vs/base/common/cancellation.js +6 -1
- package/vscode/src/vs/base/common/codicons.d.ts +3 -0
- package/vscode/src/vs/base/common/codiconsLibrary.js +3 -0
- package/vscode/src/vs/base/common/controlFlow.js +48 -0
- package/vscode/src/vs/base/common/equals.js +44 -0
- package/vscode/src/vs/base/common/event.d.ts +11 -1
- package/vscode/src/vs/base/common/event.js +26 -1
- package/vscode/src/vs/base/common/jsonEdit.js +1 -1
- package/vscode/src/vs/base/common/lifecycle.js +1 -1
- package/vscode/src/vs/base/common/map.js +53 -4
- package/vscode/src/vs/base/common/network.js +2 -0
- package/vscode/src/vs/base/common/objects.js +3 -0
- package/vscode/src/vs/base/common/observableInternal/autorun.js +1 -10
- package/vscode/src/vs/base/common/observableInternal/base.js +22 -10
- package/vscode/src/vs/base/common/observableInternal/derived.js +8 -8
- package/vscode/src/vs/base/common/observableInternal/promise.js +19 -1
- package/vscode/src/vs/base/common/observableInternal/utils.js +30 -52
- package/vscode/src/vs/base/common/product.d.ts +1 -0
- package/vscode/src/vs/base/common/strings.js +1 -1
- package/vscode/src/vs/base/common/types.d.ts +5 -1
- package/vscode/src/vs/editor/browser/config/editorConfiguration.js +3 -2
- package/vscode/src/vs/editor/browser/observableUtilities.js +58 -0
- package/vscode/src/vs/editor/browser/services/hoverService/hoverService.js +121 -2
- package/vscode/src/vs/editor/browser/services/hoverService/updatableHoverWidget.js +80 -0
- package/vscode/src/vs/editor/browser/stableEditorScroll.js +37 -1
- package/vscode/src/vs/editor/browser/widget/codeEditor/codeEditorWidget.js +10 -3
- package/vscode/src/vs/editor/browser/widget/codeEditor/editor.css.js +1 -1
- package/vscode/src/vs/editor/browser/widget/diffEditor/components/diffEditorDecorations.js +1 -0
- package/vscode/src/vs/editor/browser/widget/diffEditor/components/diffEditorEditors.js +7 -5
- package/vscode/src/vs/editor/browser/widget/diffEditor/components/diffEditorSash.js +1 -0
- package/vscode/src/vs/editor/browser/widget/diffEditor/diffEditorOptions.js +1 -0
- package/vscode/src/vs/editor/browser/widget/diffEditor/diffEditorViewModel.js +3 -0
- package/vscode/src/vs/editor/browser/widget/diffEditor/diffEditorWidget.js +3 -10
- package/vscode/src/vs/editor/browser/widget/diffEditor/diffProviderFactoryService.js +8 -0
- package/vscode/src/vs/editor/browser/widget/diffEditor/features/gutterFeature.js +6 -6
- package/vscode/src/vs/editor/browser/widget/diffEditor/features/hideUnchangedRegionsFeature.js +1 -0
- package/vscode/src/vs/editor/browser/widget/diffEditor/features/movedBlocksLinesFeature.js +2 -2
- package/vscode/src/vs/editor/browser/widget/diffEditor/features/overviewRulerFeature.js +1 -0
- package/vscode/src/vs/editor/browser/widget/diffEditor/features/revertButtonsFeature.js +1 -0
- package/vscode/src/vs/editor/browser/widget/diffEditor/utils/editorGutter.js +1 -0
- package/vscode/src/vs/editor/browser/widget/diffEditor/utils.js +1 -0
- package/vscode/src/vs/editor/browser/widget/multiDiffEditor/diffEditorItemTemplate.js +3 -2
- package/vscode/src/vs/editor/browser/widget/multiDiffEditor/multiDiffEditorViewModel.js +17 -8
- package/vscode/src/vs/editor/browser/widget/multiDiffEditor/multiDiffEditorWidget.js +1 -0
- package/vscode/src/vs/editor/browser/widget/multiDiffEditor/multiDiffEditorWidgetImpl.js +27 -19
- package/vscode/src/vs/editor/browser/widget/multiDiffEditor/style.css.js +1 -1
- package/vscode/src/vs/editor/common/core/editorColorRegistry.js +4 -4
- package/vscode/src/vs/editor/common/core/lineRange.d.ts +12 -0
- package/vscode/src/vs/editor/common/core/lineRange.js +28 -0
- package/vscode/src/vs/editor/common/core/textEdit.d.ts +21 -0
- package/vscode/src/vs/editor/common/core/textEdit.js +13 -1
- package/vscode/src/vs/editor/common/core/textLength.d.ts +29 -0
- package/vscode/src/vs/editor/common/core/textLength.js +6 -0
- package/vscode/src/vs/editor/common/cursor/cursorCollection.js +3 -3
- package/vscode/src/vs/editor/common/diff/defaultLinesDiffComputer/defaultLinesDiffComputer.js +11 -1
- package/vscode/src/vs/editor/common/diff/rangeMapping.d.ts +11 -0
- package/vscode/src/vs/editor/common/diff/rangeMapping.js +34 -3
- package/vscode/src/vs/editor/common/languages.d.ts +50 -10
- package/vscode/src/vs/editor/common/languages.js +11 -1
- package/vscode/src/vs/editor/common/services/languageFeatureDebounce.js +1 -1
- package/vscode/src/vs/editor/common/services/languageFeatures.d.ts +2 -2
- package/vscode/src/vs/editor/common/services/languageFeaturesService.js +1 -1
- package/vscode/src/vs/editor/common/standalone/standaloneEnums.js +11 -1
- package/vscode/src/vs/editor/common/viewModel/viewModelImpl.js +3 -0
- package/vscode/src/vs/editor/contrib/codeAction/browser/codeActionController.js +22 -6
- package/vscode/src/vs/editor/contrib/codeAction/browser/codeActionModel.js +5 -0
- package/vscode/src/vs/editor/contrib/codeAction/browser/lightBulbWidget.js +1 -0
- package/vscode/src/vs/editor/contrib/colorPicker/browser/colorContributions.js +1 -1
- package/vscode/src/vs/editor/contrib/colorPicker/browser/standaloneColorPickerActions.js +20 -3
- package/vscode/src/vs/editor/contrib/colorPicker/browser/standaloneColorPickerWidget.js +1 -1
- package/vscode/src/vs/editor/contrib/contextmenu/browser/contextmenu.js +2 -2
- package/vscode/src/vs/editor/contrib/dropOrPasteInto/browser/defaultProviders.js +4 -4
- package/vscode/src/vs/editor/contrib/dropOrPasteInto/browser/dropIntoEditorController.js +2 -2
- package/vscode/src/vs/editor/contrib/dropOrPasteInto/browser/postEditWidget.js +7 -0
- package/vscode/src/vs/editor/contrib/find/browser/findController.js +11 -6
- package/vscode/src/vs/editor/contrib/find/browser/findWidget.js +10 -10
- package/vscode/src/vs/editor/contrib/hover/browser/contentHoverComputer.js +74 -0
- package/vscode/src/vs/editor/contrib/hover/browser/contentHoverController.js +332 -0
- package/vscode/src/vs/editor/contrib/hover/browser/contentHoverStatusBar.js +34 -0
- package/vscode/src/vs/editor/contrib/hover/browser/contentHoverTypes.js +39 -0
- package/vscode/src/vs/editor/contrib/hover/browser/contentHoverWidget.js +355 -0
- package/vscode/src/vs/editor/contrib/hover/browser/getHover.js +11 -14
- package/vscode/src/vs/editor/contrib/hover/browser/hover.css.js +1 -1
- package/vscode/src/vs/editor/contrib/hover/browser/hoverActionIds.js +13 -0
- package/vscode/src/vs/editor/contrib/hover/browser/hoverActions.js +354 -0
- package/vscode/src/vs/editor/contrib/hover/browser/hoverContribution.js +42 -0
- package/vscode/src/vs/editor/contrib/hover/browser/hoverController.js +320 -0
- package/vscode/src/vs/editor/contrib/hover/browser/marginHoverComputer.js +48 -0
- package/vscode/src/vs/editor/contrib/hover/browser/{marginHover.js → marginHoverWidget.js} +14 -48
- package/vscode/src/vs/editor/contrib/hover/browser/markdownHoverParticipant.js +250 -41
- package/vscode/src/vs/editor/contrib/hover/browser/markerHoverParticipant.js +1 -0
- package/vscode/src/vs/editor/contrib/indentation/browser/indentation.js +44 -20
- package/vscode/src/vs/editor/contrib/inlayHints/browser/inlayHintsHover.js +11 -7
- package/vscode/src/vs/editor/contrib/inlineCompletions/browser/commands.js +1 -0
- package/vscode/src/vs/editor/contrib/inlineCompletions/browser/ghostTextWidget.js +1 -0
- package/vscode/src/vs/editor/contrib/inlineCompletions/browser/hoverParticipant.js +2 -3
- package/vscode/src/vs/editor/contrib/inlineCompletions/browser/inlineCompletionContextKeys.js +1 -0
- package/vscode/src/vs/editor/contrib/inlineCompletions/browser/inlineCompletionsController.js +26 -13
- package/vscode/src/vs/editor/contrib/inlineCompletions/browser/inlineCompletionsHintsWidget.js +5 -11
- package/vscode/src/vs/editor/contrib/inlineCompletions/browser/inlineCompletionsModel.js +24 -22
- package/vscode/src/vs/editor/contrib/inlineCompletions/browser/inlineCompletionsSource.js +39 -70
- package/vscode/src/vs/editor/contrib/inlineCompletions/browser/suggestWidgetInlineCompletionProvider.js +3 -3
- package/vscode/src/vs/editor/contrib/inlineCompletions/browser/utils.js +1 -0
- package/vscode/src/vs/editor/contrib/inlineEdit/browser/ghostTextWidget.js +1 -0
- package/vscode/src/vs/editor/contrib/inlineEdit/browser/hoverParticipant.js +1 -0
- package/vscode/src/vs/editor/contrib/inlineEdit/browser/inlineEditController.js +4 -2
- package/vscode/src/vs/editor/contrib/inlineEdit/browser/inlineEditHintsWidget.js +5 -3
- package/vscode/src/vs/editor/contrib/inlineProgress/browser/inlineProgressWidget.css.js +1 -1
- package/vscode/src/vs/editor/contrib/rename/browser/rename.js +18 -6
- package/vscode/src/vs/editor/contrib/rename/browser/renameWidget.css.js +1 -1
- package/vscode/src/vs/editor/contrib/rename/browser/renameWidget.js +165 -40
- package/vscode/src/vs/editor/contrib/sectionHeaders/browser/sectionHeaders.js +5 -0
- package/vscode/src/vs/editor/contrib/snippet/browser/snippetController2.js +3 -3
- package/vscode/src/vs/editor/contrib/stickyScroll/browser/stickyScrollActions.js +15 -8
- package/vscode/src/vs/editor/contrib/stickyScroll/browser/stickyScrollController.js +13 -6
- package/vscode/src/vs/editor/contrib/stickyScroll/browser/stickyScrollModelProvider.js +0 -2
- package/vscode/src/vs/editor/contrib/toggleTabFocusMode/browser/toggleTabFocusMode.js +9 -2
- package/vscode/src/vs/editor/standalone/browser/standaloneCodeEditor.js +23 -18
- package/vscode/src/vs/editor/standalone/browser/standaloneServices.js +33 -11
- package/vscode/src/vs/platform/accessibility/common/accessibility.d.ts +1 -9
- package/vscode/src/vs/platform/accessibility/common/accessibility.js +2 -1
- package/vscode/src/vs/platform/accessibilitySignal/browser/accessibilitySignalService.d.ts +15 -9
- package/vscode/src/vs/platform/accessibilitySignal/browser/accessibilitySignalService.js +133 -132
- package/vscode/src/vs/platform/accessibilitySignal/browser/accessibilitySignalService.service.d.ts +12 -5
- package/vscode/src/vs/platform/accessibilitySignal/browser/progressAccessibilitySignalScheduler.js +25 -0
- package/vscode/src/vs/platform/actionWidget/browser/actionWidget.js +4 -4
- package/vscode/src/vs/platform/actions/browser/buttonbar.js +10 -7
- package/vscode/src/vs/platform/actions/browser/dropdownWithPrimaryActionViewItem.js +1 -1
- package/vscode/src/vs/platform/actions/browser/toolbar.d.ts +4 -1
- package/vscode/src/vs/platform/actions/browser/toolbar.js +53 -36
- package/vscode/src/vs/platform/actions/common/actions.d.ts +3 -1
- package/vscode/src/vs/platform/actions/common/actions.js +14 -4
- package/vscode/src/vs/platform/actions/common/menuService.js +30 -8
- package/vscode/src/vs/platform/configuration/common/configuration.js +4 -0
- package/vscode/src/vs/platform/configuration/common/configurationModels.js +43 -32
- package/vscode/src/vs/platform/configuration/common/configurations.js +12 -10
- package/vscode/src/vs/platform/contextview/browser/contextView.d.ts +4 -1
- package/vscode/src/vs/platform/contextview/browser/contextView.service.d.ts +2 -3
- package/vscode/src/vs/platform/contextview/browser/contextViewService.js +10 -8
- package/vscode/src/vs/platform/extensionManagement/common/extensionManagement.d.ts +0 -1
- package/vscode/src/vs/platform/extensionManagement/common/extensionManagement.js +1 -0
- package/vscode/src/vs/platform/extensionManagement/common/extensionsScannerService.js +1 -0
- package/vscode/src/vs/platform/extensions/common/extensions.d.ts +5 -0
- package/vscode/src/vs/platform/files/common/files.d.ts +14 -1
- package/vscode/src/vs/platform/hover/browser/hover.service.d.ts +2 -31
- package/vscode/src/vs/platform/instantiation/common/instantiation.d.ts +9 -0
- package/vscode/src/vs/platform/instantiation/common/instantiationService.js +42 -8
- package/vscode/src/vs/platform/log/common/log.js +3 -1
- package/vscode/src/vs/platform/markers/common/markerService.js +7 -3
- package/vscode/src/vs/platform/opener/browser/link.js +6 -4
- package/vscode/src/vs/platform/quickinput/browser/quickInput.js +2 -2
- package/vscode/src/vs/platform/quickinput/browser/quickInputTree.js +15 -7
- package/vscode/src/vs/platform/telemetry/common/gdprTypings.d.ts +0 -1
- package/vscode/src/vs/platform/telemetry/common/telemetryUtils.js +1 -0
- package/vscode/src/vs/platform/terminal/common/capabilities/capabilities.d.ts +5 -0
- package/vscode/src/vs/platform/terminal/common/capabilities/commandDetection/promptInputModel.d.ts +30 -0
- package/vscode/src/vs/platform/theme/browser/defaultStyles.js +6 -0
- package/vscode/src/vs/platform/theme/browser/iconsStyleSheet.js +13 -11
- package/vscode/src/vs/platform/userDataProfile/common/userDataProfile.js +1 -1
- package/vscode/src/vs/workbench/api/common/extHost.api.impl.js +28 -28
- package/vscode/src/vs/workbench/api/common/extHost.protocol.js +2 -6
- package/vscode/src/vs/workbench/api/common/extHostBulkEdits.js +2 -1
- package/vscode/src/vs/workbench/api/common/extHostChatAgents2.js +104 -96
- package/vscode/src/vs/workbench/api/common/extHostChatVariables.js +4 -4
- package/vscode/src/vs/workbench/api/common/extHostConfiguration.js +9 -3
- package/vscode/src/vs/workbench/api/common/extHostDebugService.js +3 -3
- package/vscode/src/vs/workbench/api/common/extHostDocumentSaveParticipant.js +2 -1
- package/vscode/src/vs/workbench/api/common/extHostEditorTabs.js +1 -1
- package/vscode/src/vs/workbench/api/common/extHostFileSystemEventService.js +19 -1
- package/vscode/src/vs/workbench/api/common/extHostLanguageFeatures.js +87 -17
- package/vscode/src/vs/workbench/api/common/extHostLanguageModels.js +39 -2
- package/vscode/src/vs/workbench/api/common/extHostNotebookDocumentSaveParticipant.js +2 -1
- package/vscode/src/vs/workbench/api/common/extHostTerminalShellIntegration.js +52 -36
- package/vscode/src/vs/workbench/api/common/extHostTesting.js +10 -28
- package/vscode/src/vs/workbench/api/common/extHostTreeViews.js +6 -1
- package/vscode/src/vs/workbench/api/common/extHostTypeConverters.js +132 -136
- package/vscode/src/vs/workbench/api/common/extHostTypes.js +72 -18
- package/vscode/src/vs/workbench/api/common/extHostWindow.js +3 -5
- package/vscode/src/vs/workbench/browser/actions/layoutActions.js +86 -76
- package/vscode/src/vs/workbench/browser/actions/media/actions.css.js +1 -1
- package/vscode/src/vs/workbench/browser/actions/widgetNavigationCommands.js +30 -6
- package/vscode/src/vs/workbench/browser/labels.js +4 -1
- package/vscode/src/vs/workbench/browser/parts/compositePart.d.ts +3 -1
- package/vscode/src/vs/workbench/browser/parts/editor/diffEditorCommands.js +19 -7
- package/vscode/src/vs/workbench/browser/parts/editor/editorGroupView.js +16 -3
- package/vscode/src/vs/workbench/browser/parts/editor/media/editorquickaccess.css.js +1 -1
- package/vscode/src/vs/workbench/browser/parts/editor/media/multieditortabscontrol.css.js +1 -1
- package/vscode/src/vs/workbench/browser/parts/editor/multiEditorTabsControl.js +14 -33
- package/vscode/src/vs/workbench/browser/parts/globalCompositeBar.js +33 -13
- package/vscode/src/vs/workbench/browser/parts/notifications/notificationsViewer.js +7 -5
- package/vscode/src/vs/workbench/browser/parts/paneCompositePart.d.ts +4 -3
- package/vscode/src/vs/workbench/browser/parts/panel/panelPart.d.ts +2 -1
- package/vscode/src/vs/workbench/browser/parts/sidebar/sidebarPart.d.ts +3 -1
- package/vscode/src/vs/workbench/browser/parts/views/checkbox.js +3 -3
- package/vscode/src/vs/workbench/browser/parts/views/media/views.css.js +1 -1
- package/vscode/src/vs/workbench/browser/parts/views/treeView.js +182 -63
- package/vscode/src/vs/workbench/browser/parts/views/viewPane.d.ts +14 -3
- package/vscode/src/vs/workbench/browser/parts/views/viewPane.js +61 -34
- package/vscode/src/vs/workbench/browser/workbench.contribution.js +16 -10
- package/vscode/src/vs/workbench/common/theme.js +144 -98
- package/vscode/src/vs/workbench/common/views.d.ts +2 -0
- package/vscode/src/vs/workbench/contrib/accessibility/browser/accessibilityConfiguration.js +190 -138
- package/vscode/src/vs/workbench/contrib/accessibility/browser/accessibleView.js +876 -0
- package/vscode/src/vs/workbench/contrib/accessibility/browser/accessibleViewActions.js +59 -7
- package/vscode/src/vs/workbench/contrib/accessibility/browser/{accessibilityContributions.js → accessibleViewContributions.js} +160 -6
- package/vscode/src/vs/workbench/contrib/accessibility/browser/editorAccessibilityHelp.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatActions.js +66 -150
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatExecuteActions.js +75 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQuickInputActions.js +21 -22
- package/vscode/src/vs/workbench/contrib/chat/browser/chat.js +6 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatAgentHover.js +101 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditorInput.js +6 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/chatInputPart.js +30 -23
- package/vscode/src/vs/workbench/contrib/chat/browser/chatListRenderer.js +201 -47
- package/vscode/src/vs/workbench/contrib/chat/browser/chatMarkdownDecorationsRenderer.js +42 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/chatWidget.js +13 -28
- package/vscode/src/vs/workbench/contrib/chat/browser/codeBlockPart.css.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/codeBlockPart.js +366 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/contrib/chatDynamicVariables.js +35 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/media/chat.css.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/media/chatAgentHover.css.js +4 -0
- package/vscode/src/vs/workbench/contrib/chat/common/annotations.js +4 -9
- package/vscode/src/vs/workbench/contrib/chat/common/chatAgents.js +95 -5
- package/vscode/src/vs/workbench/contrib/chat/common/chatAgents.service.js +2 -1
- package/vscode/src/vs/workbench/contrib/chat/common/chatColors.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/chatContextKeys.js +11 -6
- package/vscode/src/vs/workbench/contrib/chat/common/chatModel.js +94 -79
- package/vscode/src/vs/workbench/contrib/chat/common/chatParserTypes.js +0 -13
- package/vscode/src/vs/workbench/contrib/chat/common/chatParticipantContribTypes.js +2 -0
- package/vscode/src/vs/workbench/contrib/chat/common/chatViewModel.js +7 -9
- package/vscode/src/vs/workbench/contrib/chat/common/languageModelStats.service.js +3 -0
- package/vscode/src/vs/workbench/contrib/codeEditor/browser/dictation/editorDictation.js +1 -1
- package/vscode/src/vs/workbench/contrib/codeEditor/browser/diffEditorHelper.js +1 -0
- package/vscode/src/vs/workbench/contrib/codeEditor/browser/find/simpleFindWidget.js +4 -4
- package/vscode/src/vs/workbench/contrib/comments/browser/commentNode.js +30 -26
- package/vscode/src/vs/workbench/contrib/comments/browser/commentReply.js +30 -29
- package/vscode/src/vs/workbench/contrib/comments/browser/commentThreadBody.js +4 -4
- package/vscode/src/vs/workbench/contrib/comments/browser/commentThreadWidget.js +5 -4
- package/vscode/src/vs/workbench/contrib/comments/browser/commentThreadZoneWidget.js +3 -3
- package/vscode/src/vs/workbench/contrib/comments/browser/commentsController.js +13 -13
- package/vscode/src/vs/workbench/contrib/comments/browser/commentsTreeViewer.js +26 -16
- package/vscode/src/vs/workbench/contrib/comments/browser/commentsView.js +107 -26
- package/vscode/src/vs/workbench/contrib/comments/browser/media/review.css.js +1 -1
- package/vscode/src/vs/workbench/contrib/comments/browser/simpleCommentEditor.js +23 -2
- package/vscode/src/vs/workbench/contrib/comments/browser/timestamp.js +2 -3
- package/vscode/src/vs/workbench/contrib/debug/browser/baseDebugView.js +39 -11
- package/vscode/src/vs/workbench/contrib/debug/browser/breakpointsView.js +53 -33
- package/vscode/src/vs/workbench/contrib/debug/browser/debugCommands.js +967 -0
- package/vscode/src/vs/workbench/contrib/debug/browser/debugSessionPicker.js +101 -0
- package/vscode/src/vs/workbench/contrib/debug/common/debug.js +4 -1
- package/vscode/src/vs/workbench/contrib/debug/common/loadedScriptsPicker.js +82 -0
- package/vscode/src/vs/workbench/contrib/extensions/browser/extensionsActions.js +10 -9
- package/vscode/src/vs/workbench/contrib/files/browser/fileActions.js +79 -45
- package/vscode/src/vs/workbench/contrib/files/browser/{fileCommands.save.js → fileCommands._save.js} +4 -4
- package/vscode/src/vs/workbench/contrib/files/browser/{files.configuration.contribution.js → files.contribution._configuration.js} +1 -1
- package/vscode/src/vs/workbench/contrib/files/browser/{files.editorPane.contribution.js → files.contribution._editorPane.js} +18 -18
- package/vscode/src/vs/workbench/contrib/files/browser/views/emptyView.js +5 -3
- package/vscode/src/vs/workbench/contrib/files/browser/views/explorerView.js +19 -14
- package/vscode/src/vs/workbench/contrib/files/browser/views/media/openeditors.css.js +1 -1
- package/vscode/src/vs/workbench/contrib/files/browser/views/openEditorsView.js +8 -8
- package/vscode/src/vs/workbench/contrib/files/browser/workspaceWatcher.js +15 -2
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatActions.js +29 -112
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatContentWidget.js +10 -7
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatController.js +99 -91
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSession.js +9 -31
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionServiceImpl.js +345 -104
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatStrategies.js +62 -69
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatWidget.js +63 -46
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatZoneWidget.js +18 -10
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/media/inlineChat.css.js +1 -1
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/media/inlineChatContentWidget.css.js +1 -1
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/utils.js +1 -31
- package/vscode/src/vs/workbench/contrib/inlineChat/common/inlineChat.js +7 -3
- package/vscode/src/vs/workbench/contrib/interactive/browser/interactiveEditorInput.js +5 -1
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/mergeEditorInput.js +1 -0
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/mergeEditorInputModel.js +1 -0
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/mergeMarkers/mergeMarkersController.js +1 -0
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/model/textModelDiffs.js +4 -4
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/utils.js +2 -48
- package/vscode/src/vs/workbench/contrib/multiDiffEditor/browser/multiDiffEditorInput.js +28 -23
- package/vscode/src/vs/workbench/contrib/multiDiffEditor/browser/multiDiffSourceResolverService.js +5 -9
- package/vscode/src/vs/workbench/contrib/multiDiffEditor/browser/scmMultiDiffSourceResolver.js +112 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/find/notebookFindReplaceWidget.js +18 -10
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/find/notebookFindWidget.js +4 -4
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/cellOutputActions.js +7 -2
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/notebookChatController.js +4 -5
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/editActions.js +8 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/notebookAccessibilityProvider.js +1 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/notebookEditor.js +36 -4
- package/vscode/src/vs/workbench/contrib/notebook/browser/notebookEditorWidget.js +9 -6
- package/vscode/src/vs/workbench/contrib/notebook/browser/notebookOptions.js +17 -5
- package/vscode/src/vs/workbench/contrib/notebook/browser/view/cellParts/cellActionView.js +6 -4
- package/vscode/src/vs/workbench/contrib/notebook/browser/view/cellParts/cellComments.js +5 -5
- package/vscode/src/vs/workbench/contrib/notebook/browser/view/cellParts/cellEditorOptions.js +3 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/view/cellParts/cellStatusPart.js +5 -4
- package/vscode/src/vs/workbench/contrib/notebook/browser/view/cellParts/cellToolbars.js +2 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/view/cellParts/foldedCellHint.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/view/notebookCellAnchor.js +2 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/view/renderers/backLayerWebView.js +22 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/view/renderers/webviewPreloads.js +34 -6
- package/vscode/src/vs/workbench/contrib/notebook/browser/viewModel/baseCellViewModel.js +15 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/viewModel/cellEditorOptions.js +6 -4
- package/vscode/src/vs/workbench/contrib/notebook/browser/viewModel/notebookOutlineProviderFactory.service.js +3 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/viewParts/notebookEditorStickyScroll.js +17 -14
- package/vscode/src/vs/workbench/contrib/notebook/browser/viewParts/notebookEditorToolbar.js +2 -1
- package/vscode/src/vs/workbench/contrib/notebook/common/model/notebookCellTextModel.js +52 -16
- package/vscode/src/vs/workbench/contrib/notebook/common/notebookCommon.js +3 -1
- package/vscode/src/vs/workbench/contrib/notebook/common/notebookContextKeys.js +2 -2
- package/vscode/src/vs/workbench/contrib/notebook/common/notebookEditorModel.js +25 -12
- package/vscode/src/vs/workbench/contrib/preferences/browser/preferencesWidgets.js +6 -4
- package/vscode/src/vs/workbench/contrib/remote/browser/remoteExplorer.js +0 -2
- package/vscode/src/vs/workbench/contrib/remote/browser/tunnelView.js +6 -4
- package/vscode/src/vs/workbench/contrib/scm/browser/dirtydiffDecorator.js +24 -2
- package/vscode/src/vs/workbench/contrib/search/browser/searchActionsFind.js +38 -8
- package/vscode/src/vs/workbench/contrib/search/browser/searchModel.js +0 -1
- package/vscode/src/vs/workbench/contrib/speech/common/speechService.js +1 -0
- package/vscode/src/vs/workbench/contrib/terminal/browser/terminal.d.ts +7 -14
- package/vscode/src/vs/workbench/contrib/terminal/browser/terminal.service.d.ts +24 -6
- package/vscode/src/vs/workbench/contrib/terminal/browser/terminal.service.js +2 -1
- package/vscode/src/vs/workbench/contrib/terminal/browser/xterm/xtermTerminal.d.ts +8 -9
- package/vscode/src/vs/workbench/contrib/terminal/browser/xterm-private.d.ts +2 -20
- package/vscode/src/vs/workbench/contrib/terminal/common/terminal.d.ts +3 -1
- package/vscode/src/vs/workbench/contrib/terminal/common/terminalColorRegistry.js +2 -2
- package/vscode/src/vs/workbench/contrib/testing/common/testCoverage.js +1 -0
- package/vscode/src/vs/workbench/contrib/testing/common/testItemCollection.js +10 -0
- package/vscode/src/vs/workbench/contrib/testing/common/testResult.js +15 -3
- package/vscode/src/vs/workbench/services/accessibility/common/accessibleViewInformationService.service.d.ts +9 -0
- package/vscode/src/vs/workbench/services/accessibility/common/accessibleViewInformationService.service.js +3 -0
- package/vscode/src/vs/workbench/services/editor/common/customEditorLabelService.js +30 -16
- package/vscode/src/vs/workbench/services/editor/common/editorGroupsService.d.ts +15 -4
- package/vscode/src/vs/workbench/services/editor/common/editorGroupsService.service.d.ts +20 -1
- package/vscode/src/vs/workbench/services/extensionManagement/common/extensionManagement.service.d.ts +0 -1
- package/vscode/src/vs/workbench/services/extensions/common/abstractExtensionService.d.ts +4 -1
- package/vscode/src/vs/workbench/services/extensions/common/extensionHostManagers.d.ts +4 -1
- package/vscode/src/vs/workbench/services/extensions/common/extensionRunningLocation.d.ts +1 -1
- package/vscode/src/vs/workbench/services/extensions/common/extensions.d.ts +8 -2
- package/vscode/src/vs/workbench/services/extensions/common/extensions.js +2 -1
- package/vscode/src/vs/workbench/services/extensions/common/extensions.service.d.ts +4 -1
- package/vscode/src/vs/workbench/services/extensions/common/extensionsApiProposals.js +3 -3
- package/vscode/src/vs/workbench/services/language/common/languageService.js +23 -18
- package/vscode/src/vs/workbench/services/layout/browser/layoutService.js +6 -4
- package/vscode/src/vs/workbench/services/preferences/browser/keybindingsEditorModel.js +50 -9
- package/vscode/src/vs/workbench/services/themes/common/workbenchThemeService.js +1 -0
- package/vscode/src/vs/workbench/services/userDataProfile/browser/iconSelectBox.js +97 -0
- package/vscode/src/vs/workbench/services/workingCopy/common/fileWorkingCopy.d.ts +7 -2
- package/vscode/src/vs/workbench/services/workingCopy/common/storedFileWorkingCopy.js +2 -2
- package/vscode-dts/vscode.proposed.chatParticipant.d.ts +23 -45
- package/vscode-dts/vscode.proposed.chatParticipantAdditions.d.ts +65 -91
- package/vscode-dts/vscode.proposed.chatProvider.d.ts +9 -0
- package/vscode-dts/vscode.proposed.chatTab.d.ts +1 -5
- package/vscode-dts/vscode.proposed.contribAccessibilityHelpContent.d.ts +15 -0
- package/vscode-dts/vscode.proposed.debugFocus.d.ts +4 -4
- package/vscode-dts/vscode.proposed.defaultChatParticipant.d.ts +2 -2
- package/vscode-dts/vscode.proposed.documentPaste.d.ts +144 -43
- package/vscode-dts/vscode.proposed.editorHoverVerbosityLevel.d.ts +76 -0
- package/vscode-dts/vscode.proposed.interactive.d.ts +1 -17
- package/vscode-dts/vscode.proposed.languageModels.d.ts +56 -11
- package/vscode-dts/vscode.proposed.newSymbolNamesProvider.d.ts +12 -1
- package/vscode-dts/vscode.proposed.scmHistoryProvider.d.ts +4 -4
- package/vscode-dts/vscode.proposed.speech.d.ts +2 -1
- package/vscode-dts/vscode.proposed.terminalShellIntegration.d.ts +144 -38
- package/vscode-dts/vscode.proposed.testPreserveFocus.d.ts +28 -0
- package/vscode/src/vs/base/browser/ui/hover/updatableHoverWidget.d.ts +0 -21
- package/vscode/src/vs/base/browser/ui/hover/updatableHoverWidget.js +0 -214
- package/vscode/src/vs/editor/browser/services/hoverService/hoverService.d.ts +0 -32
- package/vscode/src/vs/editor/contrib/hover/browser/contentHover.js +0 -838
- package/vscode/src/vs/editor/contrib/hover/browser/hover.js +0 -621
- package/vscode/src/vs/platform/accessibility/common/accessibility.service.d.ts +0 -19
- package/vscode/src/vs/workbench/api/common/extHostChat.js +0 -54
- package/vscode/src/vs/workbench/api/common/extHostIssueReporter.js +0 -70
- package/vscode/src/vs/workbench/contrib/accessibilitySignals/browser/accessibilitySignal.contribution.js +0 -237
- package/vscode/src/vs/workbench/contrib/accessibilitySignals/browser/accessibilitySignalDebuggerContribution.js +0 -49
- package/vscode/src/vs/workbench/contrib/accessibilitySignals/browser/accessibilitySignalLineFeatureContribution.js +0 -178
- package/vscode/src/vs/workbench/contrib/accessibilitySignals/browser/commands.js +0 -141
- package/vscode/src/vs/workbench/contrib/chat/common/chatContributionService.service.js +0 -3
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatFileCreationWidget.js +0 -212
- package/vscode/src/vs/workbench/contrib/notebook/browser/viewModel/OutlineEntry.js +0 -95
- package/vscode/src/vs/workbench/contrib/notebook/browser/viewModel/notebookOutlineEntryFactory.js +0 -110
- package/vscode/src/vs/workbench/contrib/notebook/browser/viewModel/notebookOutlineProvider.js +0 -224
- package/vscode/src/vs/workbench/contrib/terminal/browser/terminalConfigHelper.d.ts +0 -48
- package/vscode/src/vs/workbench/contrib/terminal/browser/terminalEvents.js +0 -47
- package/vscode-dts/vscode.proposed.dropMetadata.d.ts +0 -65
- package/vscode-dts/vscode.proposed.handleIssueUri.d.ts +0 -57
- package/vscode-dts/vscode.proposed.windowActivity.d.ts +0 -17
- /package/vscode/src/vs/workbench/browser/parts/editor/{editor.autosave.contribution.js → editor.contribution._autosave.js} +0 -0
- /package/vscode/src/vs/workbench/contrib/files/browser/{files.fileEditorFactory.contribution.js → files.contribution._fileEditorFactory.js} +0 -0
|
@@ -1,36 +1,6 @@
|
|
|
1
1
|
import { EditOperation } from '../../../../editor/common/core/editOperation.js';
|
|
2
|
-
import { LineRange } from '../../../../editor/common/core/lineRange.js';
|
|
3
|
-
import { Range } from '../../../../editor/common/core/range.js';
|
|
4
2
|
import { AsyncIterableSource } from '../../../../base/common/async.js';
|
|
5
3
|
import { getNWords } from '../../chat/common/chatWordCounter.js';
|
|
6
|
-
function invertLineRange(range, model) {
|
|
7
|
-
if (range.isEmpty) {
|
|
8
|
-
return [];
|
|
9
|
-
}
|
|
10
|
-
const result = [];
|
|
11
|
-
if (range.startLineNumber > 1) {
|
|
12
|
-
result.push(( new LineRange(1, range.startLineNumber)));
|
|
13
|
-
}
|
|
14
|
-
if (range.endLineNumberExclusive < model.getLineCount() + 1) {
|
|
15
|
-
result.push(( new LineRange(range.endLineNumberExclusive, model.getLineCount() + 1)));
|
|
16
|
-
}
|
|
17
|
-
return result.filter(r => !r.isEmpty);
|
|
18
|
-
}
|
|
19
|
-
function asRange(lineRange, model) {
|
|
20
|
-
return lineRange.isEmpty
|
|
21
|
-
? ( new Range(
|
|
22
|
-
lineRange.startLineNumber,
|
|
23
|
-
1,
|
|
24
|
-
lineRange.startLineNumber,
|
|
25
|
-
model.getLineLength(lineRange.startLineNumber)
|
|
26
|
-
))
|
|
27
|
-
: ( new Range(
|
|
28
|
-
lineRange.startLineNumber,
|
|
29
|
-
1,
|
|
30
|
-
lineRange.endLineNumberExclusive - 1,
|
|
31
|
-
model.getLineLength(lineRange.endLineNumberExclusive - 1)
|
|
32
|
-
));
|
|
33
|
-
}
|
|
34
4
|
async function performAsyncTextEdit(model, edit, progress, obs) {
|
|
35
5
|
const [id] = model.deltaDecorations([], [{
|
|
36
6
|
range: edit.range,
|
|
@@ -86,4 +56,4 @@ function asProgressiveEdit(interval, edit, wordsPerSec, token) {
|
|
|
86
56
|
newText: stream.asyncIterable
|
|
87
57
|
};
|
|
88
58
|
}
|
|
89
|
-
export { asProgressiveEdit,
|
|
59
|
+
export { asProgressiveEdit, performAsyncTextEdit };
|
|
@@ -67,12 +67,11 @@ const ACTION_VIEW_IN_CHAT = 'inlineChat.viewInChat';
|
|
|
67
67
|
const ACTION_TOGGLE_DIFF = 'inlineChat.toggleDiff';
|
|
68
68
|
const MENU_INLINE_CHAT_WIDGET = MenuId.for('inlineChatWidget');
|
|
69
69
|
const MENU_INLINE_CHAT_WIDGET_STATUS = MenuId.for('inlineChatWidget.status');
|
|
70
|
-
const MENU_INLINE_CHAT_WIDGET_FEEDBACK = MenuId.for('inlineChatWidget.feedback');
|
|
71
70
|
const MENU_INLINE_CHAT_WIDGET_DISCARD = MenuId.for('inlineChatWidget.undo');
|
|
72
71
|
const inlineChatBackground = registerColor('inlineChat.background', { dark: editorWidgetBackground, light: editorWidgetBackground, hcDark: editorWidgetBackground, hcLight: editorWidgetBackground }, ( localizeWithPath(_moduleId, 21, "Background color of the interactive editor widget")));
|
|
73
72
|
registerColor('inlineChat.border', { dark: editorWidgetBorder, light: editorWidgetBorder, hcDark: editorWidgetBorder, hcLight: editorWidgetBorder }, ( localizeWithPath(_moduleId, 22, "Border color of the interactive editor widget")));
|
|
74
73
|
registerColor('inlineChat.shadow', { dark: widgetShadow, light: widgetShadow, hcDark: widgetShadow, hcLight: widgetShadow }, ( localizeWithPath(_moduleId, 23, "Shadow color of the interactive editor widget")));
|
|
75
|
-
|
|
74
|
+
registerColor('inlineChat.regionHighlight', { dark: editorHoverHighlight, light: editorHoverHighlight, hcDark: editorHoverHighlight, hcLight: editorHoverHighlight }, ( localizeWithPath(
|
|
76
75
|
_moduleId,
|
|
77
76
|
24,
|
|
78
77
|
"Background highlighting of the current interactive region. Must be transparent."
|
|
@@ -95,6 +94,11 @@ const overviewRulerInlineChatDiffInserted = registerColor('editorOverviewRuler.i
|
|
|
95
94
|
30,
|
|
96
95
|
'Overview ruler marker color for inline chat inserted content.'
|
|
97
96
|
)));
|
|
97
|
+
const minimapInlineChatDiffInserted = registerColor('editorOverviewRuler.inlineChatInserted', { dark: ( (transparent(diffInserted, 0.6))), light: ( (transparent(diffInserted, 0.8))), hcDark: ( (transparent(diffInserted, 0.6))), hcLight: ( (transparent(diffInserted, 0.8))) }, ( localizeWithPath(
|
|
98
|
+
_moduleId,
|
|
99
|
+
30,
|
|
100
|
+
'Overview ruler marker color for inline chat inserted content.'
|
|
101
|
+
)));
|
|
98
102
|
registerColor('inlineChatDiff.removed', { dark: ( (transparent(diffRemoved, .5))), light: ( (transparent(diffRemoved, .5))), hcDark: ( (transparent(diffRemoved, .5))), hcLight: ( (transparent(diffRemoved, .5))) }, ( localizeWithPath(
|
|
99
103
|
_moduleId,
|
|
100
104
|
31,
|
|
@@ -180,4 +184,4 @@ registerColor('editorOverviewRuler.inlineChatRemoved', { dark: ( (transparent(di
|
|
|
180
184
|
}
|
|
181
185
|
}
|
|
182
186
|
});
|
|
183
|
-
export { ACTION_ACCEPT_CHANGES, ACTION_REGENERATE_RESPONSE, ACTION_TOGGLE_DIFF, ACTION_VIEW_IN_CHAT, CTX_INLINE_CHAT_CHANGE_HAS_DIFF, CTX_INLINE_CHAT_CHANGE_SHOWS_DIFF, CTX_INLINE_CHAT_DID_EDIT, CTX_INLINE_CHAT_DOCUMENT_CHANGED, CTX_INLINE_CHAT_EDIT_MODE, CTX_INLINE_CHAT_EMPTY, CTX_INLINE_CHAT_FOCUSED, CTX_INLINE_CHAT_HAS_PROVIDER, CTX_INLINE_CHAT_HAS_STASHED_SESSION, CTX_INLINE_CHAT_INNER_CURSOR_FIRST, CTX_INLINE_CHAT_INNER_CURSOR_LAST, CTX_INLINE_CHAT_LAST_FEEDBACK, CTX_INLINE_CHAT_LAST_RESPONSE_TYPE, CTX_INLINE_CHAT_OUTER_CURSOR_POSITION, CTX_INLINE_CHAT_RESPONSE_FOCUSED, CTX_INLINE_CHAT_RESPONSE_TYPES, CTX_INLINE_CHAT_SUPPORT_ISSUE_REPORTING, CTX_INLINE_CHAT_USER_DID_EDIT, CTX_INLINE_CHAT_VISIBLE, INLINE_CHAT_ID, INTERACTIVE_EDITOR_ACCESSIBILITY_HELP_ID, MENU_INLINE_CHAT_WIDGET, MENU_INLINE_CHAT_WIDGET_DISCARD,
|
|
187
|
+
export { ACTION_ACCEPT_CHANGES, ACTION_REGENERATE_RESPONSE, ACTION_TOGGLE_DIFF, ACTION_VIEW_IN_CHAT, CTX_INLINE_CHAT_CHANGE_HAS_DIFF, CTX_INLINE_CHAT_CHANGE_SHOWS_DIFF, CTX_INLINE_CHAT_DID_EDIT, CTX_INLINE_CHAT_DOCUMENT_CHANGED, CTX_INLINE_CHAT_EDIT_MODE, CTX_INLINE_CHAT_EMPTY, CTX_INLINE_CHAT_FOCUSED, CTX_INLINE_CHAT_HAS_PROVIDER, CTX_INLINE_CHAT_HAS_STASHED_SESSION, CTX_INLINE_CHAT_INNER_CURSOR_FIRST, CTX_INLINE_CHAT_INNER_CURSOR_LAST, CTX_INLINE_CHAT_LAST_FEEDBACK, CTX_INLINE_CHAT_LAST_RESPONSE_TYPE, CTX_INLINE_CHAT_OUTER_CURSOR_POSITION, CTX_INLINE_CHAT_RESPONSE_FOCUSED, CTX_INLINE_CHAT_RESPONSE_TYPES, CTX_INLINE_CHAT_SUPPORT_ISSUE_REPORTING, CTX_INLINE_CHAT_USER_DID_EDIT, CTX_INLINE_CHAT_VISIBLE, INLINE_CHAT_ID, INTERACTIVE_EDITOR_ACCESSIBILITY_HELP_ID, MENU_INLINE_CHAT_WIDGET, MENU_INLINE_CHAT_WIDGET_DISCARD, MENU_INLINE_CHAT_WIDGET_STATUS, inlineChatBackground, minimapInlineChatDiffInserted, overviewRulerInlineChatDiffInserted };
|
|
@@ -138,7 +138,11 @@ let InteractiveEditorInput = class InteractiveEditorInput extends EditorInput {
|
|
|
138
138
|
if (!target) {
|
|
139
139
|
return undefined;
|
|
140
140
|
}
|
|
141
|
-
|
|
141
|
+
const saved = await this._editorModelReference.saveAs(target);
|
|
142
|
+
if (saved && 'resource' in saved && saved.resource) {
|
|
143
|
+
this._notebookService.getNotebookTextModel(saved.resource)?.dispose();
|
|
144
|
+
}
|
|
145
|
+
return saved;
|
|
142
146
|
}
|
|
143
147
|
matches(otherInput) {
|
|
144
148
|
if (super.matches(otherInput)) {
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { __decorate, __param } from '../../../../../../../external/tslib/tslib.es6.js';
|
|
2
2
|
import { assertFn } from '../../../../base/common/assert.js';
|
|
3
|
+
import '../../../../base/common/arrays.js';
|
|
3
4
|
import '../../../../base/common/observableInternal/derived.js';
|
|
4
5
|
import { autorun } from '../../../../base/common/observableInternal/autorun.js';
|
|
5
6
|
import '../../../../base/common/observableInternal/utils.js';
|
|
@@ -8,6 +8,7 @@ import { derived } from '../../../../base/common/observableInternal/derived.js';
|
|
|
8
8
|
import '../../../../base/common/observableInternal/autorun.js';
|
|
9
9
|
import { observableFromEvent } from '../../../../base/common/observableInternal/utils.js';
|
|
10
10
|
import '../../../../base/common/cancellation.js';
|
|
11
|
+
import '../../../../base/common/arrays.js';
|
|
11
12
|
import { basename, isEqual } from '../../../../base/common/resources.js';
|
|
12
13
|
import Severity$1 from '../../../../base/common/severity.js';
|
|
13
14
|
import { IModelService } from '../../../../editor/common/services/model.js';
|
package/vscode/src/vs/workbench/contrib/mergeEditor/browser/mergeMarkers/mergeMarkersController.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import '../../../../../base/browser/dom.js';
|
|
2
2
|
import '../../../../../base/common/lifecycle.js';
|
|
3
|
+
import '../../../../../base/common/arrays.js';
|
|
3
4
|
import '../../../../../base/common/observableInternal/derived.js';
|
|
4
5
|
import '../../../../../base/common/observableInternal/autorun.js';
|
|
5
6
|
import '../../../../../base/common/observableInternal/utils.js';
|
|
@@ -4,7 +4,7 @@ import { Disposable, toDisposable } from '../../../../../base/common/lifecycle.j
|
|
|
4
4
|
import { DetailedLineRangeMapping } from './mapping.js';
|
|
5
5
|
import { LineRangeEdit } from './editing.js';
|
|
6
6
|
import { LineRange } from './lineRange.js';
|
|
7
|
-
import { ReentrancyBarrier } from '
|
|
7
|
+
import { ReentrancyBarrier } from '../../../../../base/common/controlFlow.js';
|
|
8
8
|
import { observableValue, transaction } from '../../../../../base/common/observableInternal/base.js';
|
|
9
9
|
import '../../../../../base/common/observableInternal/derived.js';
|
|
10
10
|
import { autorun } from '../../../../../base/common/observableInternal/autorun.js';
|
|
@@ -12,7 +12,7 @@ import { observableSignal } from '../../../../../base/common/observableInternal/
|
|
|
12
12
|
import '../../../../../base/common/cancellation.js';
|
|
13
13
|
class TextModelDiffs extends Disposable {
|
|
14
14
|
get isApplyingChange() {
|
|
15
|
-
return this._barrier.
|
|
15
|
+
return this._barrier.isOccupied;
|
|
16
16
|
}
|
|
17
17
|
constructor(baseTextModel, textModel, diffComputer) {
|
|
18
18
|
super();
|
|
@@ -30,10 +30,10 @@ class TextModelDiffs extends Disposable {
|
|
|
30
30
|
recomputeSignal.read(reader);
|
|
31
31
|
this._recompute(reader);
|
|
32
32
|
}));
|
|
33
|
-
this._register(baseTextModel.onDidChangeContent(this._barrier.
|
|
33
|
+
this._register(baseTextModel.onDidChangeContent(this._barrier.makeExclusiveOrSkip(() => {
|
|
34
34
|
recomputeSignal.trigger(undefined);
|
|
35
35
|
})));
|
|
36
|
-
this._register(textModel.onDidChangeContent(this._barrier.
|
|
36
|
+
this._register(textModel.onDidChangeContent(this._barrier.makeExclusiveOrSkip(() => {
|
|
37
37
|
recomputeSignal.trigger(undefined);
|
|
38
38
|
})));
|
|
39
39
|
this._register(toDisposable(() => {
|
|
@@ -1,58 +1,12 @@
|
|
|
1
1
|
import { __decorate, __param } from '../../../../../../../external/tslib/tslib.es6.js';
|
|
2
2
|
import { CompareResult, ArrayQueue } from '../../../../base/common/arrays.js';
|
|
3
|
-
import { onUnexpectedError
|
|
3
|
+
import { onUnexpectedError } from '../../../../base/common/errors.js';
|
|
4
4
|
import { toDisposable, DisposableStore } from '../../../../base/common/lifecycle.js';
|
|
5
5
|
import '../../../../base/common/observableInternal/derived.js';
|
|
6
6
|
import { autorunOpts } from '../../../../base/common/observableInternal/autorun.js';
|
|
7
7
|
import { observableFromEvent } from '../../../../base/common/observableInternal/utils.js';
|
|
8
8
|
import '../../../../base/common/cancellation.js';
|
|
9
9
|
import { IStorageService } from '../../../../platform/storage/common/storage.service.js';
|
|
10
|
-
class ReentrancyBarrier {
|
|
11
|
-
constructor() {
|
|
12
|
-
this._isActive = false;
|
|
13
|
-
}
|
|
14
|
-
get isActive() {
|
|
15
|
-
return this._isActive;
|
|
16
|
-
}
|
|
17
|
-
makeExclusive(fn) {
|
|
18
|
-
return ((...args) => {
|
|
19
|
-
if (this._isActive) {
|
|
20
|
-
return;
|
|
21
|
-
}
|
|
22
|
-
this._isActive = true;
|
|
23
|
-
try {
|
|
24
|
-
return fn(...args);
|
|
25
|
-
}
|
|
26
|
-
finally {
|
|
27
|
-
this._isActive = false;
|
|
28
|
-
}
|
|
29
|
-
});
|
|
30
|
-
}
|
|
31
|
-
runExclusively(fn) {
|
|
32
|
-
if (this._isActive) {
|
|
33
|
-
return;
|
|
34
|
-
}
|
|
35
|
-
this._isActive = true;
|
|
36
|
-
try {
|
|
37
|
-
fn();
|
|
38
|
-
}
|
|
39
|
-
finally {
|
|
40
|
-
this._isActive = false;
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
runExclusivelyOrThrow(fn) {
|
|
44
|
-
if (this._isActive) {
|
|
45
|
-
throw ( new BugIndicatingError());
|
|
46
|
-
}
|
|
47
|
-
this._isActive = true;
|
|
48
|
-
try {
|
|
49
|
-
fn();
|
|
50
|
-
}
|
|
51
|
-
finally {
|
|
52
|
-
this._isActive = false;
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
}
|
|
56
10
|
function setStyle(element, style) {
|
|
57
11
|
Object.entries(style).forEach(([key, value]) => {
|
|
58
12
|
element.style.setProperty(key, toSize(value));
|
|
@@ -169,4 +123,4 @@ function observableConfigValue(key, defaultValue, configurationService) {
|
|
|
169
123
|
}
|
|
170
124
|
}), () => configurationService.getValue(key) ?? defaultValue);
|
|
171
125
|
}
|
|
172
|
-
export { PersistentStore,
|
|
126
|
+
export { PersistentStore, applyObservableDecorations, concatArrays, deepMerge, join, leftJoin, observableConfigValue, setFields, setStyle, thenIfNotDisposed };
|
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
import { __decorate, __param } from '../../../../../../../external/tslib/tslib.es6.js';
|
|
2
2
|
import { LazyStatefulPromise, raceTimeout } from '../../../../base/common/async.js';
|
|
3
3
|
import { BugIndicatingError, onUnexpectedError } from '../../../../base/common/errors.js';
|
|
4
|
-
import {
|
|
4
|
+
import { ValueWithChangeEvent, Event } from '../../../../base/common/event.js';
|
|
5
5
|
import { Disposable, DisposableStore, toDisposable } from '../../../../base/common/lifecycle.js';
|
|
6
6
|
import { parse } from '../../../../base/common/marshalling.js';
|
|
7
7
|
import { Schemas } from '../../../../base/common/network.js';
|
|
8
8
|
import { deepClone } from '../../../../base/common/objects.js';
|
|
9
|
+
import { observableValue } from '../../../../base/common/observableInternal/base.js';
|
|
9
10
|
import { derived } from '../../../../base/common/observableInternal/derived.js';
|
|
10
11
|
import { autorun } from '../../../../base/common/observableInternal/autorun.js';
|
|
11
|
-
import {
|
|
12
|
+
import { observableFromValueWithChangeEvent, constObservable, mapObservableArrayCached, recomputeInitiallyAndOnChange, ValueWithChangeEventFromObservable, observableFromEvent } from '../../../../base/common/observableInternal/utils.js';
|
|
12
13
|
import { ObservableLazyPromise } from '../../../../base/common/observableInternal/promise.js';
|
|
13
14
|
import { isDefined, isObject } from '../../../../base/common/types.js';
|
|
14
15
|
import { URI } from '../../../../base/common/uri.js';
|
|
@@ -21,7 +22,7 @@ import { IInstantiationService } from '../../../../platform/instantiation/common
|
|
|
21
22
|
import { DEFAULT_EDITOR_ASSOCIATION } from '../../../common/editor.js';
|
|
22
23
|
import { EditorInput } from '../../../common/editor/editorInput.js';
|
|
23
24
|
import { MultiDiffEditorIcon } from './icons.contribution.js';
|
|
24
|
-
import { MultiDiffEditorItem
|
|
25
|
+
import { MultiDiffEditorItem } from './multiDiffSourceResolverService.js';
|
|
25
26
|
import { IMultiDiffSourceResolverService } from './multiDiffSourceResolverService.service.js';
|
|
26
27
|
import { RegisteredEditorPriority } from '../../../services/editor/common/editorResolverService.js';
|
|
27
28
|
import { IEditorResolverService } from '../../../services/editor/common/editorResolverService.service.js';
|
|
@@ -78,19 +79,19 @@ let MultiDiffEditorInput = class MultiDiffEditorInput extends EditorInput {
|
|
|
78
79
|
})));
|
|
79
80
|
this._resolvedSource = ( (new ObservableLazyPromise(async () => {
|
|
80
81
|
const source = this.initialResources
|
|
81
|
-
?
|
|
82
|
+
? { resources: ValueWithChangeEvent.const(this.initialResources) }
|
|
82
83
|
: await this._multiDiffSourceResolverService.resolve(this.multiDiffSource);
|
|
83
84
|
return {
|
|
84
85
|
source,
|
|
85
|
-
resources: source ?
|
|
86
|
+
resources: source ? observableFromValueWithChangeEvent(this, source.resources) : constObservable([]),
|
|
86
87
|
};
|
|
87
88
|
})));
|
|
88
|
-
this.
|
|
89
|
-
this._isDirtyObservables = mapObservableArrayCached(this, ( (this.
|
|
89
|
+
this.resources = derived(this, reader => this._resolvedSource.cachedPromiseResult.read(reader)?.data?.resources.read(reader));
|
|
90
|
+
this._isDirtyObservables = mapObservableArrayCached(this, ( (this.resources.map(r => r ?? []))), res => {
|
|
90
91
|
const isModifiedDirty = res.modified ? isUriDirty(this._textFileService, res.modified) : constObservable(false);
|
|
91
92
|
const isOriginalDirty = res.original ? isUriDirty(this._textFileService, res.original) : constObservable(false);
|
|
92
93
|
return derived(reader => isModifiedDirty.read(reader) || isOriginalDirty.read(reader));
|
|
93
|
-
}, i =>
|
|
94
|
+
}, i => i.getKey());
|
|
94
95
|
this._isDirtyObservable = derived(this, reader => ( (this._isDirtyObservables.read(reader).some(isDirty => isDirty.read(reader)))))
|
|
95
96
|
.keepObserved(this._store);
|
|
96
97
|
this.onDidChangeDirty = Event.fromObservableLight(this._isDirtyObservable);
|
|
@@ -103,9 +104,14 @@ let MultiDiffEditorInput = class MultiDiffEditorInput extends EditorInput {
|
|
|
103
104
|
}
|
|
104
105
|
};
|
|
105
106
|
this._register(autorun((reader) => {
|
|
106
|
-
const resources = this.
|
|
107
|
+
const resources = this.resources.read(reader);
|
|
107
108
|
const label = this.label ?? ( localizeWithPath(_moduleId, 0, "Multi Diff Editor"));
|
|
108
|
-
|
|
109
|
+
if (resources) {
|
|
110
|
+
this._name = label + ( localizeWithPath(_moduleId, 1, " ({0} files)", resources.length));
|
|
111
|
+
}
|
|
112
|
+
else {
|
|
113
|
+
this._name = label;
|
|
114
|
+
}
|
|
109
115
|
this._onDidChangeLabel.fire();
|
|
110
116
|
}));
|
|
111
117
|
}
|
|
@@ -138,7 +144,7 @@ let MultiDiffEditorInput = class MultiDiffEditorInput extends EditorInput {
|
|
|
138
144
|
const source = await this._resolvedSource.getPromise();
|
|
139
145
|
const textResourceConfigurationService = this._textResourceConfigurationService;
|
|
140
146
|
const garbage = ( (new DisposableStore()));
|
|
141
|
-
const documentsWithPromises = mapObservableArrayCached(
|
|
147
|
+
const documentsWithPromises = mapObservableArrayCached(this, source.resources, async (r, store) => {
|
|
142
148
|
let original;
|
|
143
149
|
let modified;
|
|
144
150
|
const store2 = ( (new DisposableStore()));
|
|
@@ -151,10 +157,10 @@ let MultiDiffEditorInput = class MultiDiffEditorInput extends EditorInput {
|
|
|
151
157
|
r.modified ? this._textModelService.createModelReference(r.modified) : undefined,
|
|
152
158
|
]);
|
|
153
159
|
if (original) {
|
|
154
|
-
|
|
160
|
+
store2.add(original);
|
|
155
161
|
}
|
|
156
162
|
if (modified) {
|
|
157
|
-
|
|
163
|
+
store2.add(modified);
|
|
158
164
|
}
|
|
159
165
|
}
|
|
160
166
|
catch (e) {
|
|
@@ -181,26 +187,25 @@ let MultiDiffEditorInput = class MultiDiffEditorInput extends EditorInput {
|
|
|
181
187
|
}))
|
|
182
188
|
);
|
|
183
189
|
}, i => JSON.stringify([i.modified?.toString(), i.original?.toString()]));
|
|
184
|
-
|
|
185
|
-
const
|
|
186
|
-
const p = Event.toPromise(documentChangeEmitter.event);
|
|
187
|
-
const a = autorun(async (reader) => {
|
|
190
|
+
const documents = observableValue('documents', []);
|
|
191
|
+
const updateDocuments = derived(async (reader) => {
|
|
188
192
|
const docsPromises = documentsWithPromises.read(reader);
|
|
189
193
|
const docs = await Promise.all(docsPromises);
|
|
190
|
-
|
|
191
|
-
|
|
194
|
+
const newDocuments = docs.filter(isDefined);
|
|
195
|
+
documents.set(newDocuments, undefined);
|
|
192
196
|
garbage.clear();
|
|
193
197
|
});
|
|
194
|
-
|
|
195
|
-
|
|
198
|
+
const a = recomputeInitiallyAndOnChange(updateDocuments);
|
|
199
|
+
await updateDocuments.get();
|
|
200
|
+
const result = {
|
|
196
201
|
dispose: () => {
|
|
197
202
|
a.dispose();
|
|
198
203
|
garbage.dispose();
|
|
199
204
|
},
|
|
200
|
-
|
|
201
|
-
get documents() { return documents; },
|
|
205
|
+
documents: ( (new ValueWithChangeEventFromObservable(documents))),
|
|
202
206
|
contextKeys: source.source?.contextKeys,
|
|
203
207
|
};
|
|
208
|
+
return result;
|
|
204
209
|
}
|
|
205
210
|
matches(otherInput) {
|
|
206
211
|
if (super.matches(otherInput)) {
|
package/vscode/src/vs/workbench/contrib/multiDiffEditor/browser/multiDiffSourceResolverService.js
CHANGED
|
@@ -1,12 +1,5 @@
|
|
|
1
|
-
import { Event } from '../../../../base/common/event.js';
|
|
2
|
-
import { toDisposable } from '../../../../base/common/lifecycle.js';
|
|
3
1
|
import { BugIndicatingError } from '../../../../base/common/errors.js';
|
|
4
|
-
|
|
5
|
-
constructor(resources) {
|
|
6
|
-
this.resources = resources;
|
|
7
|
-
this.onDidChange = Event.None;
|
|
8
|
-
}
|
|
9
|
-
}
|
|
2
|
+
import { toDisposable } from '../../../../base/common/lifecycle.js';
|
|
10
3
|
class MultiDiffEditorItem {
|
|
11
4
|
constructor(original, modified) {
|
|
12
5
|
this.original = original;
|
|
@@ -15,6 +8,9 @@ class MultiDiffEditorItem {
|
|
|
15
8
|
throw ( new BugIndicatingError('Invalid arguments'));
|
|
16
9
|
}
|
|
17
10
|
}
|
|
11
|
+
getKey() {
|
|
12
|
+
return JSON.stringify([this.modified?.toString(), this.original?.toString()]);
|
|
13
|
+
}
|
|
18
14
|
}
|
|
19
15
|
class MultiDiffSourceResolverService {
|
|
20
16
|
constructor() {
|
|
@@ -36,4 +32,4 @@ class MultiDiffSourceResolverService {
|
|
|
36
32
|
return Promise.resolve(undefined);
|
|
37
33
|
}
|
|
38
34
|
}
|
|
39
|
-
export {
|
|
35
|
+
export { MultiDiffEditorItem, MultiDiffSourceResolverService };
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
import { __decorate, __param } from '../../../../../../../external/tslib/tslib.es6.js';
|
|
2
|
+
import { Disposable } from '../../../../base/common/lifecycle.js';
|
|
3
|
+
import '../../../../base/common/arrays.js';
|
|
4
|
+
import '../../../../base/common/observableInternal/derived.js';
|
|
5
|
+
import '../../../../base/common/observableInternal/autorun.js';
|
|
6
|
+
import { observableFromEvent, ValueWithChangeEventFromObservable } from '../../../../base/common/observableInternal/utils.js';
|
|
7
|
+
import { waitForState } from '../../../../base/common/observableInternal/promise.js';
|
|
8
|
+
import { URI } from '../../../../base/common/uri.js';
|
|
9
|
+
import { localize2WithPath } from '../../../../nls.js';
|
|
10
|
+
import { Action2 } from '../../../../platform/actions/common/actions.js';
|
|
11
|
+
import { IInstantiationService } from '../../../../platform/instantiation/common/instantiation.js';
|
|
12
|
+
import { MultiDiffEditorItem } from './multiDiffSourceResolverService.js';
|
|
13
|
+
import { IMultiDiffSourceResolverService } from './multiDiffSourceResolverService.service.js';
|
|
14
|
+
import { ISCMService } from '../../scm/common/scm.service.js';
|
|
15
|
+
import { IEditorService } from '../../../services/editor/common/editorService.service.js';
|
|
16
|
+
var ScmMultiDiffSourceResolver_1;
|
|
17
|
+
const _moduleId = "vs/workbench/contrib/multiDiffEditor/browser/scmMultiDiffSourceResolver";
|
|
18
|
+
let ScmMultiDiffSourceResolver = class ScmMultiDiffSourceResolver {
|
|
19
|
+
static { ScmMultiDiffSourceResolver_1 = this; }
|
|
20
|
+
static { this._scheme = 'scm-multi-diff-source'; }
|
|
21
|
+
static getMultiDiffSourceUri(repositoryUri, groupId) {
|
|
22
|
+
return (
|
|
23
|
+
(URI.from({
|
|
24
|
+
scheme: ScmMultiDiffSourceResolver_1._scheme,
|
|
25
|
+
query: JSON.stringify({ repositoryUri, groupId }),
|
|
26
|
+
}))
|
|
27
|
+
);
|
|
28
|
+
}
|
|
29
|
+
static parseUri(uri) {
|
|
30
|
+
if (uri.scheme !== ScmMultiDiffSourceResolver_1._scheme) {
|
|
31
|
+
return undefined;
|
|
32
|
+
}
|
|
33
|
+
let query;
|
|
34
|
+
try {
|
|
35
|
+
query = JSON.parse(uri.query);
|
|
36
|
+
}
|
|
37
|
+
catch (e) {
|
|
38
|
+
return undefined;
|
|
39
|
+
}
|
|
40
|
+
if (typeof query !== 'object' || query === null) {
|
|
41
|
+
return undefined;
|
|
42
|
+
}
|
|
43
|
+
const { repositoryUri, groupId } = query;
|
|
44
|
+
if (typeof repositoryUri !== 'string' || typeof groupId !== 'string') {
|
|
45
|
+
return undefined;
|
|
46
|
+
}
|
|
47
|
+
return { repositoryUri: ( (URI.parse(repositoryUri))), groupId };
|
|
48
|
+
}
|
|
49
|
+
constructor(_scmService) {
|
|
50
|
+
this._scmService = _scmService;
|
|
51
|
+
}
|
|
52
|
+
canHandleUri(uri) {
|
|
53
|
+
return ScmMultiDiffSourceResolver_1.parseUri(uri) !== undefined;
|
|
54
|
+
}
|
|
55
|
+
async resolveDiffSource(uri) {
|
|
56
|
+
const { repositoryUri, groupId } = ScmMultiDiffSourceResolver_1.parseUri(uri);
|
|
57
|
+
const repository = await waitForState(observableFromEvent(this._scmService.onDidAddRepository, () => [...this._scmService.repositories].find(r => r.provider.rootUri?.toString() === ( (repositoryUri.toString())))));
|
|
58
|
+
const group = await waitForState(observableFromEvent(repository.provider.onDidChangeResourceGroups, () => repository.provider.groups.find(g => g.id === groupId)));
|
|
59
|
+
return (
|
|
60
|
+
(new ScmResolvedMultiDiffSource(group, repository))
|
|
61
|
+
);
|
|
62
|
+
}
|
|
63
|
+
};
|
|
64
|
+
ScmMultiDiffSourceResolver = ScmMultiDiffSourceResolver_1 = ( (__decorate([
|
|
65
|
+
( (__param(0, ISCMService)))
|
|
66
|
+
], ScmMultiDiffSourceResolver)));
|
|
67
|
+
class ScmResolvedMultiDiffSource {
|
|
68
|
+
constructor(_group, _repository) {
|
|
69
|
+
this._group = _group;
|
|
70
|
+
this._repository = _repository;
|
|
71
|
+
this._resources = observableFromEvent(this._group.onDidChangeResources, () => ( (this._group.resources.map(
|
|
72
|
+
e => ( (new MultiDiffEditorItem(e.multiDiffEditorOriginalUri, e.multiDiffEditorModifiedUri)))
|
|
73
|
+
))));
|
|
74
|
+
this.resources = ( (new ValueWithChangeEventFromObservable(this._resources)));
|
|
75
|
+
this.contextKeys = {
|
|
76
|
+
scmResourceGroup: this._group.id,
|
|
77
|
+
scmProvider: this._repository.provider.contextValue,
|
|
78
|
+
};
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
let ScmMultiDiffSourceResolverContribution = class ScmMultiDiffSourceResolverContribution extends Disposable {
|
|
82
|
+
static { this.ID = 'workbench.contrib.scmMultiDiffSourceResolver'; }
|
|
83
|
+
constructor(instantiationService, multiDiffSourceResolverService) {
|
|
84
|
+
super();
|
|
85
|
+
this._register(multiDiffSourceResolverService.registerResolver(instantiationService.createInstance(ScmMultiDiffSourceResolver)));
|
|
86
|
+
}
|
|
87
|
+
};
|
|
88
|
+
ScmMultiDiffSourceResolverContribution = ( (__decorate([
|
|
89
|
+
( (__param(0, IInstantiationService))),
|
|
90
|
+
( (__param(1, IMultiDiffSourceResolverService)))
|
|
91
|
+
], ScmMultiDiffSourceResolverContribution)));
|
|
92
|
+
class OpenScmGroupAction extends Action2 {
|
|
93
|
+
static async openMultiFileDiffEditor(editorService, label, repositoryRootUri, resourceGroupId, options) {
|
|
94
|
+
if (!repositoryRootUri) {
|
|
95
|
+
return;
|
|
96
|
+
}
|
|
97
|
+
const multiDiffSource = ScmMultiDiffSourceResolver.getMultiDiffSourceUri(( (repositoryRootUri.toString())), resourceGroupId);
|
|
98
|
+
return await editorService.openEditor({ label, multiDiffSource, options });
|
|
99
|
+
}
|
|
100
|
+
constructor() {
|
|
101
|
+
super({
|
|
102
|
+
id: '_workbench.openScmMultiDiffEditor',
|
|
103
|
+
title: ( localize2WithPath(_moduleId, 0, 'View Changes')),
|
|
104
|
+
f1: false
|
|
105
|
+
});
|
|
106
|
+
}
|
|
107
|
+
async run(accessor, options) {
|
|
108
|
+
const editorService = accessor.get(IEditorService);
|
|
109
|
+
await OpenScmGroupAction.openMultiFileDiffEditor(editorService, options.title, URI.revive(options.repositoryUri), options.resourceGroupId);
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
export { OpenScmGroupAction, ScmMultiDiffSourceResolver, ScmMultiDiffSourceResolverContribution };
|
package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/find/notebookFindReplaceWidget.js
CHANGED
|
@@ -29,6 +29,7 @@ import { Sash } from '../../../../../../base/browser/ui/sash/sash.js';
|
|
|
29
29
|
import { defaultProgressBarStyles, defaultInputBoxStyles, defaultToggleStyles } from '../../../../../../platform/theme/browser/defaultStyles.js';
|
|
30
30
|
import { Disposable } from '../../../../../../base/common/lifecycle.js';
|
|
31
31
|
import { NotebookSetting } from '../../../common/notebookCommon.js';
|
|
32
|
+
import { IHoverService } from '../../../../../../platform/hover/browser/hover.service.js';
|
|
32
33
|
const _moduleId = "vs/workbench/contrib/notebook/browser/contrib/find/notebookFindReplaceWidget";
|
|
33
34
|
const NLS_FIND_INPUT_LABEL = ( localizeWithPath(_moduleId, 0, "Find"));
|
|
34
35
|
const NLS_FIND_INPUT_PLACEHOLDER = ( localizeWithPath(_moduleId, 1, "Find"));
|
|
@@ -152,7 +153,7 @@ class NotebookFindInputFilterButton extends Disposable {
|
|
|
152
153
|
get container() {
|
|
153
154
|
return this._filterButtonContainer;
|
|
154
155
|
}
|
|
155
|
-
|
|
156
|
+
width() {
|
|
156
157
|
return 2 + 2 + 2 + 16 ;
|
|
157
158
|
}
|
|
158
159
|
enable() {
|
|
@@ -161,6 +162,12 @@ class NotebookFindInputFilterButton extends Disposable {
|
|
|
161
162
|
disable() {
|
|
162
163
|
this.container.setAttribute('aria-disabled', String(true));
|
|
163
164
|
}
|
|
165
|
+
set visible(visible) {
|
|
166
|
+
this._filterButtonContainer.style.display = visible ? '' : 'none';
|
|
167
|
+
}
|
|
168
|
+
get visible() {
|
|
169
|
+
return this._filterButtonContainer.style.display !== 'none';
|
|
170
|
+
}
|
|
164
171
|
applyStyles(filterChecked) {
|
|
165
172
|
const toggleStyles = this._toggleStyles;
|
|
166
173
|
this._filterButtonContainer.style.border = '1px solid transparent';
|
|
@@ -190,7 +197,7 @@ class NotebookFindInput extends FindInput {
|
|
|
190
197
|
this._filterChecked = false;
|
|
191
198
|
this._register(registerAndCreateHistoryNavigationContext(contextKeyService, this.inputBox));
|
|
192
199
|
this._findFilter = this._register(( (new NotebookFindInputFilterButton(filters, contextMenuService, instantiationService, options))));
|
|
193
|
-
this.inputBox.paddingRight = (this.caseSensitive?.width() ?? 0) + (this.wholeWords?.width() ?? 0) + (this.regex?.width() ?? 0) + this._findFilter.width;
|
|
200
|
+
this.inputBox.paddingRight = (this.caseSensitive?.width() ?? 0) + (this.wholeWords?.width() ?? 0) + (this.regex?.width() ?? 0) + this._findFilter.width();
|
|
194
201
|
this.controls.appendChild(this._findFilter.container);
|
|
195
202
|
}
|
|
196
203
|
setEnabled(enabled) {
|
|
@@ -227,7 +234,7 @@ class NotebookFindInput extends FindInput {
|
|
|
227
234
|
}
|
|
228
235
|
}
|
|
229
236
|
let SimpleFindReplaceWidget = class SimpleFindReplaceWidget extends Widget {
|
|
230
|
-
constructor(_contextViewService, contextKeyService, _configurationService, contextMenuService, instantiationService, _state = ( (new FindReplaceState())), _notebookEditor) {
|
|
237
|
+
constructor(_contextViewService, contextKeyService, _configurationService, contextMenuService, instantiationService, hoverService, _state = ( (new FindReplaceState())), _notebookEditor) {
|
|
231
238
|
super();
|
|
232
239
|
this._contextViewService = _contextViewService;
|
|
233
240
|
this._configurationService = _configurationService;
|
|
@@ -267,7 +274,7 @@ let SimpleFindReplaceWidget = class SimpleFindReplaceWidget extends Widget {
|
|
|
267
274
|
this._state.change({ isReplaceRevealed: this._isReplaceVisible }, false);
|
|
268
275
|
this._updateReplaceViewDisplay();
|
|
269
276
|
}
|
|
270
|
-
}))));
|
|
277
|
+
}, hoverService))));
|
|
271
278
|
this._toggleReplaceBtn.setEnabled(!isInteractiveWindow);
|
|
272
279
|
this._toggleReplaceBtn.setExpanded(this._isReplaceVisible);
|
|
273
280
|
this._domNode.appendChild(this._toggleReplaceBtn.domNode);
|
|
@@ -337,21 +344,21 @@ let SimpleFindReplaceWidget = class SimpleFindReplaceWidget extends Widget {
|
|
|
337
344
|
onTrigger: () => {
|
|
338
345
|
this.find(true);
|
|
339
346
|
}
|
|
340
|
-
}))));
|
|
347
|
+
}, hoverService))));
|
|
341
348
|
this.nextBtn = this._register(( (new SimpleButton({
|
|
342
349
|
label: NLS_NEXT_MATCH_BTN_LABEL,
|
|
343
350
|
icon: findNextMatchIcon,
|
|
344
351
|
onTrigger: () => {
|
|
345
352
|
this.find(false);
|
|
346
353
|
}
|
|
347
|
-
}))));
|
|
354
|
+
}, hoverService))));
|
|
348
355
|
const closeBtn = this._register(( (new SimpleButton({
|
|
349
356
|
label: NLS_CLOSE_BTN_LABEL,
|
|
350
357
|
icon: widgetClose,
|
|
351
358
|
onTrigger: () => {
|
|
352
359
|
this.hide();
|
|
353
360
|
}
|
|
354
|
-
}))));
|
|
361
|
+
}, hoverService))));
|
|
355
362
|
this._innerFindDomNode.appendChild(this._findInput.domNode);
|
|
356
363
|
this._innerFindDomNode.appendChild(this._matchesCount);
|
|
357
364
|
this._innerFindDomNode.appendChild(this.prevBtn.domNode);
|
|
@@ -398,14 +405,14 @@ let SimpleFindReplaceWidget = class SimpleFindReplaceWidget extends Widget {
|
|
|
398
405
|
onTrigger: () => {
|
|
399
406
|
this.replaceOne();
|
|
400
407
|
}
|
|
401
|
-
}))));
|
|
408
|
+
}, hoverService))));
|
|
402
409
|
this._replaceAllBtn = this._register(( (new SimpleButton({
|
|
403
410
|
label: NLS_REPLACE_ALL_BTN_LABEL,
|
|
404
411
|
icon: findReplaceAllIcon,
|
|
405
412
|
onTrigger: () => {
|
|
406
413
|
this.replaceAll();
|
|
407
414
|
}
|
|
408
|
-
}))));
|
|
415
|
+
}, hoverService))));
|
|
409
416
|
this._innerReplaceDomNode.appendChild(this._replaceBtn.domNode);
|
|
410
417
|
this._innerReplaceDomNode.appendChild(this._replaceAllBtn.domNode);
|
|
411
418
|
this._resizeSash = this._register(( (new Sash(
|
|
@@ -594,7 +601,8 @@ SimpleFindReplaceWidget = ( (__decorate([
|
|
|
594
601
|
( (__param(1, IContextKeyService))),
|
|
595
602
|
( (__param(2, IConfigurationService))),
|
|
596
603
|
( (__param(3, IContextMenuService))),
|
|
597
|
-
( (__param(4, IInstantiationService)))
|
|
604
|
+
( (__param(4, IInstantiationService))),
|
|
605
|
+
( (__param(5, IHoverService)))
|
|
598
606
|
], SimpleFindReplaceWidget)));
|
|
599
607
|
registerThemingParticipant((theme, collector) => {
|
|
600
608
|
collector.addRule(`
|
|
@@ -8,10 +8,10 @@ import { MATCHES_LIMIT } from '../../../../../../editor/contrib/find/browser/fin
|
|
|
8
8
|
import { FindReplaceState } from '../../../../../../editor/contrib/find/browser/findState.js';
|
|
9
9
|
import { NLS_NO_RESULTS, NLS_MATCHES_LOCATION } from '../../../../../../editor/contrib/find/browser/findWidget.js';
|
|
10
10
|
import { localizeWithPath } from '../../../../../../nls.js';
|
|
11
|
-
import { IMenuService } from '../../../../../../platform/actions/common/actions.service.js';
|
|
12
11
|
import { IConfigurationService } from '../../../../../../platform/configuration/common/configuration.service.js';
|
|
13
12
|
import { IContextKeyService } from '../../../../../../platform/contextkey/common/contextkey.service.js';
|
|
14
13
|
import { IContextViewService, IContextMenuService } from '../../../../../../platform/contextview/browser/contextView.service.js';
|
|
14
|
+
import { IHoverService } from '../../../../../../platform/hover/browser/hover.service.js';
|
|
15
15
|
import { IInstantiationService } from '../../../../../../platform/instantiation/common/instantiation.js';
|
|
16
16
|
import { FindModel } from './findModel.js';
|
|
17
17
|
import { SimpleFindReplaceWidget } from './notebookFindReplaceWidget.js';
|
|
@@ -46,8 +46,8 @@ NotebookFindContrib = ( (__decorate([
|
|
|
46
46
|
( (__param(1, IInstantiationService)))
|
|
47
47
|
], NotebookFindContrib)));
|
|
48
48
|
let NotebookFindWidget = class NotebookFindWidget extends SimpleFindReplaceWidget {
|
|
49
|
-
constructor(_notebookEditor, contextViewService, contextKeyService, configurationService, contextMenuService,
|
|
50
|
-
super(contextViewService, contextKeyService, configurationService, contextMenuService, instantiationService, ( (new FindReplaceState())), _notebookEditor);
|
|
49
|
+
constructor(_notebookEditor, contextViewService, contextKeyService, configurationService, contextMenuService, hoverService, instantiationService) {
|
|
50
|
+
super(contextViewService, contextKeyService, configurationService, contextMenuService, instantiationService, hoverService, ( (new FindReplaceState())), _notebookEditor);
|
|
51
51
|
this._showTimeout = null;
|
|
52
52
|
this._hideTimeout = null;
|
|
53
53
|
this._findModel = ( (new FindModel(this._notebookEditor, this._state, this._configurationService)));
|
|
@@ -293,7 +293,7 @@ NotebookFindWidget = ( (__decorate([
|
|
|
293
293
|
( (__param(2, IContextKeyService))),
|
|
294
294
|
( (__param(3, IConfigurationService))),
|
|
295
295
|
( (__param(4, IContextMenuService))),
|
|
296
|
-
( (__param(5,
|
|
296
|
+
( (__param(5, IHoverService))),
|
|
297
297
|
( (__param(6, IInstantiationService)))
|
|
298
298
|
], NotebookFindWidget)));
|
|
299
299
|
export { NotebookFindContrib };
|
|
@@ -24,9 +24,14 @@ registerAction2(class CopyCellOutputAction extends Action2 {
|
|
|
24
24
|
icon: copyIcon,
|
|
25
25
|
});
|
|
26
26
|
}
|
|
27
|
+
getNoteboookEditor(editorService, outputContext) {
|
|
28
|
+
if (outputContext && 'notebookEditor' in outputContext) {
|
|
29
|
+
return outputContext.notebookEditor;
|
|
30
|
+
}
|
|
31
|
+
return getNotebookEditorFromEditorPane(editorService.activeEditorPane);
|
|
32
|
+
}
|
|
27
33
|
async run(accessor, outputContext) {
|
|
28
|
-
const
|
|
29
|
-
const notebookEditor = getNotebookEditorFromEditorPane(editorService.activeEditorPane);
|
|
34
|
+
const notebookEditor = this.getNoteboookEditor(accessor.get(IEditorService), outputContext);
|
|
30
35
|
if (!notebookEditor) {
|
|
31
36
|
return;
|
|
32
37
|
}
|