mirror of
https://github.com/zadam/trilium.git
synced 2025-03-01 14:22:32 +01:00
faster opening of the date notes (no animation)
This commit is contained in:
parent
71916b5e28
commit
1bd769827d
BIN
db/demo.tar
BIN
db/demo.tar
Binary file not shown.
@ -117,7 +117,7 @@ $("body").on("click", "a.external", function () {
|
||||
if (utils.isElectron()) {
|
||||
require('electron').ipcRenderer.on('create-day-sub-note', async function(event) {
|
||||
const todayNote = await dateNoteService.getTodayNote();
|
||||
const node = await treeService.expandToNote(todayNote.noteId);
|
||||
const node = await treeService.expandToNote(todayNote.noteId, {noAnimation: true});
|
||||
|
||||
await treeService.createNote(node, todayNote.noteId, 'into', {
|
||||
type: "text",
|
||||
|
@ -151,7 +151,7 @@ async function activateNote(notePath, noteLoadedListener) {
|
||||
glob.activeDialog.modal('hide');
|
||||
}
|
||||
|
||||
const node = await expandToNote(notePath);
|
||||
const node = await expandToNote(notePath, {noAnimation: true});
|
||||
|
||||
if (noteLoadedListener) {
|
||||
noteDetailService.addDetailLoadedListener(node.data.noteId, noteLoadedListener);
|
||||
|
@ -96,6 +96,10 @@ class TreeCache {
|
||||
const resp = await server.post('tree/load', { noteIds: missingNoteIds });
|
||||
|
||||
this.addResp(resp.notes, resp.branches, resp.relations);
|
||||
|
||||
for (const note of resp.notes) {
|
||||
await this.reloadParents(note.noteId);
|
||||
}
|
||||
}
|
||||
|
||||
return noteIds.map(noteId => {
|
||||
|
Loading…
x
Reference in New Issue
Block a user