mirror of
https://github.com/zadam/trilium.git
synced 2025-10-26 07:46:30 +01:00
feat(mermaid): hide layout switcher if in readonly mode
This commit is contained in:
@@ -15,6 +15,7 @@ export default class SwitchSplitOrientationButton extends NoteContextAwareWidget
|
||||
return super.isEnabled()
|
||||
&& ["mermaid"].includes(this.note?.type ?? "")
|
||||
&& this.note?.isContentAvailable()
|
||||
&& !this.note?.hasLabel("readOnly")
|
||||
&& this.noteContext?.viewScope?.viewMode === "default";
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user