mirror of
https://github.com/microsoft/vscode.git
synced 2026-09-06 05:38:13 +01:00
enable enhanced text diff view for notebook by default.
This commit is contained in:
@@ -30,7 +30,7 @@ import { NotebookEditor } from 'vs/workbench/contrib/notebook/browser/notebookEd
|
||||
import { NotebookEditorInput } from 'vs/workbench/contrib/notebook/browser/notebookEditorInput';
|
||||
import { INotebookService } from 'vs/workbench/contrib/notebook/common/notebookService';
|
||||
import { NotebookService } from 'vs/workbench/contrib/notebook/browser/notebookServiceImpl';
|
||||
import { CellKind, CellToolbarLocKey, CellUri, DisplayOrderKey, getCellUndoRedoComparisonKey, NotebookDocumentBackupData, NotebookEditorPriority, ShowCellStatusbarKey } from 'vs/workbench/contrib/notebook/common/notebookCommon';
|
||||
import { CellKind, CellToolbarLocKey, CellUri, DisplayOrderKey, getCellUndoRedoComparisonKey, NotebookDocumentBackupData, NotebookEditorPriority, NotebookTextDiffEditorPreview, ShowCellStatusbarKey } from 'vs/workbench/contrib/notebook/common/notebookCommon';
|
||||
import { NotebookProviderInfo } from 'vs/workbench/contrib/notebook/common/notebookProvider';
|
||||
import { IEditorGroup } from 'vs/workbench/services/editor/common/editorGroupsService';
|
||||
import { IEditorService, IOpenEditorOverride } from 'vs/workbench/services/editor/common/editorService';
|
||||
@@ -249,7 +249,7 @@ export class NotebookContribution extends Disposable implements IWorkbenchContri
|
||||
return undefined;
|
||||
}
|
||||
|
||||
if (originalInput instanceof DiffEditorInput && this.configurationService.getValue('notebook.diff.enablePreview')) {
|
||||
if (originalInput instanceof DiffEditorInput && this.configurationService.getValue(NotebookTextDiffEditorPreview)) {
|
||||
return this._handleDiffEditorInput(originalInput, options, group);
|
||||
}
|
||||
|
||||
@@ -546,6 +546,11 @@ configurationRegistry.registerConfiguration({
|
||||
description: nls.localize('notebook.showCellStatusbar.description', "Whether the cell statusbar should be shown."),
|
||||
type: 'boolean',
|
||||
default: true
|
||||
},
|
||||
[NotebookTextDiffEditorPreview]: {
|
||||
description: nls.localize('notebook.diff.enablePreview.description', "Whether to use the enhanced text diff editor for notebook."),
|
||||
type: 'boolean',
|
||||
default: true
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
@@ -789,6 +789,7 @@ export interface INotebookCellStatusBarEntry {
|
||||
export const DisplayOrderKey = 'notebook.displayOrder';
|
||||
export const CellToolbarLocKey = 'notebook.cellToolbarLocation';
|
||||
export const ShowCellStatusbarKey = 'notebook.showCellStatusbar';
|
||||
export const NotebookTextDiffEditorPreview = 'notebook.diff.enablePreview';
|
||||
|
||||
export const enum CellStatusbarAlignment {
|
||||
LEFT,
|
||||
|
||||
Reference in New Issue
Block a user