mirror of
https://github.com/TriliumNext/Notes.git
synced 2025-10-19 21:26:10 +08:00
fix(touchbar): hide read-only button after editing
This commit is contained in:
parent
cbc6e74d64
commit
d734ac9e45
@ -23,7 +23,6 @@ export default class EditButton extends OnClickButtonWidget {
|
|||||||
this.noteContext.viewScope.readOnlyTemporarilyDisabled = true;
|
this.noteContext.viewScope.readOnlyTemporarilyDisabled = true;
|
||||||
appContext.triggerEvent("readOnlyTemporarilyDisabled", { noteContext: this.noteContext });
|
appContext.triggerEvent("readOnlyTemporarilyDisabled", { noteContext: this.noteContext });
|
||||||
}
|
}
|
||||||
this.refresh();
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -68,6 +67,10 @@ export default class EditButton extends OnClickButtonWidget {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
readOnlyTemporarilyDisabledEvent() {
|
||||||
|
this.refresh();
|
||||||
|
}
|
||||||
|
|
||||||
async noteTypeMimeChangedEvent({ noteId }: { noteId: string }): Promise<void> {
|
async noteTypeMimeChangedEvent({ noteId }: { noteId: string }): Promise<void> {
|
||||||
if (this.isNote(noteId)) {
|
if (this.isNote(noteId)) {
|
||||||
await this.refresh();
|
await this.refresh();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user