update compact view default value.

This commit is contained in:
rebornix 2021-05-26 12:55:38 -07:00
parent 99bcc8e245
commit c88d575621
2 changed files with 3 additions and 3 deletions

View file

@ -613,7 +613,7 @@ configurationRegistry.registerConfiguration({
[CompactView]: {
description: nls.localize('notebook.compactView.description', "Control whether the notebook editor should be rendered in a compact form. "),
type: 'boolean',
default: false,
default: true,
tags: ['notebookLayout']
},
[FocusIndicator]: {

View file

@ -111,7 +111,7 @@ export class NotebookOptions {
const dragAndDropEnabled = this.configurationService.getValue<boolean | undefined>(DragAndDropEnabled) ?? true;
const cellToolbarLocation = this.configurationService.getValue<string | { [key: string]: string }>(CellToolbarLocKey);
const cellToolbarInteraction = this.configurationService.getValue<string>(CellToolbarVisibility);
const compactView = this.configurationService.getValue<boolean>(CompactView);
const compactView = this.configurationService.getValue<boolean | undefined>(CompactView) ?? true;
const focusIndicator = this._computeFocusIndicatorOption();
const insertToolbarPosition = this._computeInsertToolbarPositionOption();
const insertToolbarAlignment = this._computeInsertToolbarAlignmentOption();
@ -217,7 +217,7 @@ export class NotebookOptions {
}
if (compactView) {
const compactViewValue = this.configurationService.getValue<boolean>(CompactView);
const compactViewValue = this.configurationService.getValue<boolean | undefined>(CompactView) ?? true;
configuration = Object.assign(configuration, {
...(compactViewValue ? compactConfigConstants : defaultConfigConstants),
});