Skip to content

Build your personal knowledge base with Trilium Notes

chore(pdfjs): fix type error after update

Elian Doran00a0315f12ae
diff --git a/packages/pdfjs-viewer/src/custom.ts b/packages/pdfjs-viewer/src/custom.ts
index 4cd1533455..9defae5264 100644
--- a/packages/pdfjs-viewer/src/custom.ts
+++ b/packages/pdfjs-viewer/src/custom.ts
@@ -7,9 +7,9 @@ import { setupPdfLayers } from "./layers";
async function main() {
const urlParams = new URLSearchParams(window.location.search);
const isEditable = urlParams.get("editable") === "1";
-
+
document.body.classList.toggle("read-only-document", !isEditable);
-
+
if (urlParams.get("sidebar") === "0") {
hideSidebar();
}
@@ -89,7 +89,7 @@ function manageSave() {
}
});
- app.pdfDocument.annotationStorage.onSetModified = () => {
+ (app.pdfDocument.annotationStorage as any).onSetModified = () => {
onChange();
}; // works great for most cases, including forms.
app.eventBus.on("switchannotationeditorparams", () => {