fix(editor): should not select or open latex editor when readonly (#10601)
This commit is contained in:
@@ -76,6 +76,11 @@ export class LatexBlockComponent extends CaptionedBlockComponent<LatexBlockModel
|
|||||||
);
|
);
|
||||||
|
|
||||||
this.disposables.addFromEvent(this, 'click', () => {
|
this.disposables.addFromEvent(this, 'click', () => {
|
||||||
|
// should not open editor or select block in readonly mode
|
||||||
|
if (this.doc.readonly) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (this.isBlockSelected) {
|
if (this.isBlockSelected) {
|
||||||
this.toggleEditor();
|
this.toggleEditor();
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user