note list improvements

This commit is contained in:
zadam 2020-12-13 20:13:57 +01:00
parent 60e2026850
commit de1584eab8
3 changed files with 7 additions and 3 deletions

View File

@ -155,8 +155,8 @@ class NoteListRenderer {
this.page = 1;
this.pageSize = parseInt(parentNote.getLabelValue('pageSize'));
if (!this.pageSize || this.pageSize < 1 || this.pageSize > 10000) {
this.pageSize = 10;
if (!this.pageSize || this.pageSize < 1) {
this.pageSize = 20;
}
this.viewType = parentNote.getLabelValue('viewType');

View File

@ -262,6 +262,10 @@ class TreeCache {
}
getNoteFromCache(noteId) {
if (!noteId) {
throw new Error("Empty noteId");
}
return this.notes[noteId];
}

View File

@ -9,7 +9,7 @@ const TPL = `
flex-grow: 100000;
flex-shrink: 100000;
min-height: 0;
padding: 0 10px 10px 10px;
overflow: auto;
}
</style>