Build your personal knowledge base with Trilium Notes
TypeScript electronelectron-appknowledge-baseknowledge-graphknowledge-managementknowledge-management-graphlocal-firstnote-managmentnote-takernote-takingnotebooknotesnotes-apppersonal-knowledge-basepersonal-wikiscriptableself-hostedself-hostingwiki
refactor(book/table): fix some lack of generics
Elian Dorandd379bf18d52
diff --git a/apps/client/src/services/note_list_renderer.ts b/apps/client/src/services/note_list_renderer.tsindex a55e93c8a3..04dc5b1327 100644--- a/apps/client/src/services/note_list_renderer.ts+++ b/apps/client/src/services/note_list_renderer.ts@@ -10,7 +10,7 @@ export type ViewTypeOptions = "list" | "grid" | "calendar" | "table";export default class NoteListRenderer {private viewType: ViewTypeOptions;- public viewMode: ViewMode | null;+ public viewMode: ViewMode<any> | null;constructor($parent: JQuery<HTMLElement>, parentNote: FNote, noteIds: string[], showNotePath: boolean = false) {this.viewType = this.#getViewType(parentNote);diff --git a/apps/client/src/widgets/note_list.ts b/apps/client/src/widgets/note_list.tsindex 73ebb358dc..ba1a028f2f 100644--- a/apps/client/src/widgets/note_list.ts+++ b/apps/client/src/widgets/note_list.ts@@ -36,7 +36,7 @@ export default class NoteListWidget extends NoteContextAwareWidget {private isIntersecting?: boolean;private noteIdRefreshed?: string;private shownNoteId?: string | null;- private viewMode?: ViewMode | null;+ private viewMode?: ViewMode<any> | null;isEnabled() {return super.isEnabled() && this.noteContext?.hasNoteList();