diff --git a/apps/client/src/print.tsx b/apps/client/src/print.tsx index 1ee44ac9e..16b41cd42 100644 --- a/apps/client/src/print.tsx +++ b/apps/client/src/print.tsx @@ -101,7 +101,9 @@ function SingleNoteRenderer({ note, onReady }: RendererProps) { await loadCustomCss(note); } - load().then(() => requestAnimationFrame(() => onReady({}))); + load().then(() => requestAnimationFrame(() => onReady({ + type: "single-note" + }))); }, [ note ]); return <> diff --git a/apps/client/src/widgets/collections/table/TablePrintView.tsx b/apps/client/src/widgets/collections/table/TablePrintView.tsx index 534ba5764..236d74159 100644 --- a/apps/client/src/widgets/collections/table/TablePrintView.tsx +++ b/apps/client/src/widgets/collections/table/TablePrintView.tsx @@ -1,10 +1,12 @@ +import "./TablePrintView.css"; + import { useEffect, useRef, useState } from "preact/hooks"; +import { ExportModule, FormatModule, Tabulator as VanillaTabulator} from 'tabulator-tables'; + +import { RawHtmlBlock } from "../../react/RawHtml"; import { ViewModeProps } from "../interface"; import useData, { TableConfig } from "./data"; -import { ExportModule, FormatModule, Tabulator as VanillaTabulator} from 'tabulator-tables'; import Tabulator from "./tabulator"; -import { RawHtmlBlock } from "../../react/RawHtml"; -import "./TablePrintView.css"; export default function TablePrintView({ note, noteIds, viewConfig, onReady }: ViewModeProps) { const tabulatorRef = useRef(null); @@ -13,7 +15,10 @@ export default function TablePrintView({ note, noteIds, viewConfig, onReady }: V useEffect(() => { if (!html) return; - onReady?.(); + onReady?.({ + type: "collection", + ignoredNoteIds: [] + }); }, [ html ]); return rowData && ( @@ -45,5 +50,5 @@ export default function TablePrintView({ note, noteIds, viewConfig, onReady }: V - ) + ); }