From 0d2f364dcbe80348f56b446b61b98e3fd69ec774 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Philipp=20Ku=CC=88hn?= Date: Mon, 13 May 2019 12:53:54 +0200 Subject: [PATCH] check for children in ignoreMutation, fix #304 --- packages/tiptap/src/Utils/ComponentView.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/packages/tiptap/src/Utils/ComponentView.js b/packages/tiptap/src/Utils/ComponentView.js index 88af52ec..17bbb386 100644 --- a/packages/tiptap/src/Utils/ComponentView.js +++ b/packages/tiptap/src/Utils/ComponentView.js @@ -106,8 +106,11 @@ export default class ComponentView { // prevent a full re-render of the vue component on update // we'll handle prop updates in `update()` - ignoreMutation() { - return true + ignoreMutation(mutation) { + if (!this.contentDOM) { + return true + } + return !this.contentDOM.contains(mutation.target) } // disable (almost) all prosemirror event listener for node views