Ensure cells in a readonly notebook cannot be edited (#228309)

This commit is contained in:
Don Jayamanne
2024-10-01 00:03:45 +02:00
committed by GitHub
parent 35183efe58
commit 287245b258
5 changed files with 18 additions and 4 deletions

View File

@@ -351,6 +351,7 @@ export class NotebookViewModel extends Disposable implements EditorFoldingStateD
updateOptions(newOptions: Partial<NotebookViewModelOptions>) {
this._options = { ...this._options, ...newOptions };
this._viewCells.forEach(cell => cell.updateOptions({ readonly: this._options.isReadOnly }));
this._onDidChangeOptions.fire();
}