From c95cb79672e7c1a49c51013bd50bf39aa2738b6d Mon Sep 17 00:00:00 2001 From: Elian Doran Date: Thu, 20 Nov 2025 20:17:20 +0200 Subject: [PATCH] chore(print/list): enable print dialog --- .../src/widgets/collections/legacy/ListOrGridView.tsx | 8 +++++++- apps/client/src/widgets/ribbon/NoteActions.tsx | 2 +- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/apps/client/src/widgets/collections/legacy/ListOrGridView.tsx b/apps/client/src/widgets/collections/legacy/ListOrGridView.tsx index 55415e7c1..80087f584 100644 --- a/apps/client/src/widgets/collections/legacy/ListOrGridView.tsx +++ b/apps/client/src/widgets/collections/legacy/ListOrGridView.tsx @@ -35,7 +35,7 @@ export function ListView({ note, noteIds: unfilteredNoteIds, highlightedTokens } ); } -export function ListPrintView({ note, noteIds: unfilteredNoteIds, highlightedTokens }: ViewModeProps<{}>) { +export function ListPrintView({ note, noteIds: unfilteredNoteIds, highlightedTokens, onReady }: ViewModeProps<{}>) { const noteIds = useFilteredNoteIds(note, unfilteredNoteIds); const [ notes, setNotes ] = useState(); @@ -43,6 +43,12 @@ export function ListPrintView({ note, noteIds: unfilteredNoteIds, highlightedTok froca.getNotes(noteIds).then(setNotes); }, [noteIds]); + useEffect(() => { + if (notes && onReady) { + onReady(); + } + }, [ notes, onReady ]); + return (