From 43dbfbcb581d9e844128a6f82442f0ab9b51a546 Mon Sep 17 00:00:00 2001 From: mjadobson Date: Tue, 5 Sep 2017 17:51:44 +0100 Subject: [PATCH] Fix drop contents insertion (#929) Now drop fragments insert at correct location --- src/plugins/core.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/plugins/core.js b/src/plugins/core.js index 80d5d8d72..c1c1ec93c 100644 --- a/src/plugins/core.js +++ b/src/plugins/core.js @@ -373,7 +373,7 @@ function Plugin(options = {}) { selection.endOffset < target.endOffset ) { target = target.move(selection.startKey == selection.endKey - ? 0 - selection.endOffset - selection.startOffset + ? 0 - selection.endOffset + selection.startOffset : 0 - selection.endOffset) } @@ -411,7 +411,7 @@ function Plugin(options = {}) { selection.endOffset < target.endOffset ) { target = target.move(selection.startKey == selection.endKey - ? 0 - selection.endOffset - selection.startOffset + ? 0 - selection.endOffset + selection.startOffset : 0 - selection.endOffset) }