From 3f5b5d7d4d80a35d5aefa77b259cd2116ee46da3 Mon Sep 17 00:00:00 2001 From: phantom1003 Date: Mon, 8 May 2023 15:46:20 +0800 Subject: [PATCH] disable canvas when link is set --- src/main.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main.ts b/src/main.ts index 3a8733a..348c8e1 100644 --- a/src/main.ts +++ b/src/main.ts @@ -36,7 +36,8 @@ export default class SlideNotePlugin extends Plugin { registerPDFCanvas() { this.registerEvent(this.app.workspace.on("slidenote:mouseup", (event) => { - this.activeCanvas(event.target.toDataURL()); + if (event.target.parentElement.nodeName == "DIV") + this.activeCanvas(event.target.toDataURL()); })); this.registerView(