Skip to content

Build your personal knowledge base with Trilium Notes

fix(client): printing triggers twice

Elian Doran377de59df9d7
diff --git a/apps/client/src/widgets/dialogs/popup_editor.ts b/apps/client/src/widgets/dialogs/popup_editor.ts
index bb0b5ca34d..3c06dd5dfa 100644
--- a/apps/client/src/widgets/dialogs/popup_editor.ts
+++ b/apps/client/src/widgets/dialogs/popup_editor.ts
@@ -151,7 +151,7 @@ export default class PopupEditorDialog extends Container<BasicWidget> {
handleEventInChildren<T extends EventNames>(name: T, data: EventData<T>): Promise<unknown[] | unknown> | null {
// Avoid events related to the current tab interfere with our popup.
- if (["noteSwitched", "noteSwitchedAndActivated"].includes(name)) {
+ if (["noteSwitched", "noteSwitchedAndActivated", "exportAsPdf", "printActiveNote"].includes(name)) {
return Promise.resolve();
}