mirror of
https://github.com/zadam/trilium.git
synced 2025-06-06 18:08:33 +02:00
fix display of buttons for revisions when there is none
This commit is contained in:
parent
115879ec4a
commit
a3661cb763
@ -37,6 +37,7 @@ export async function showNoteRevisionsDialog(noteId, noteRevisionId) {
|
|||||||
async function loadNoteRevisions(noteId, noteRevId) {
|
async function loadNoteRevisions(noteId, noteRevId) {
|
||||||
$list.empty();
|
$list.empty();
|
||||||
$content.empty();
|
$content.empty();
|
||||||
|
$titleButtons.empty();
|
||||||
|
|
||||||
note = appContext.tabManager.getActiveTabNote();
|
note = appContext.tabManager.getActiveTabNote();
|
||||||
revisionItems = await server.get(`notes/${noteId}/revisions`);
|
revisionItems = await server.get(`notes/${noteId}/revisions`);
|
||||||
@ -62,6 +63,8 @@ async function loadNoteRevisions(noteId, noteRevId) {
|
|||||||
$title.text("No revisions for this note yet...");
|
$title.text("No revisions for this note yet...");
|
||||||
noteRevisionId = null;
|
noteRevisionId = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$eraseAllRevisionsButton.toggle(revisionItems.length > 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
$dialog.on('shown.bs.modal', () => {
|
$dialog.on('shown.bs.modal', () => {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user