From a77b1605dfec8e1a2a819f475a8b60db5d4936a0 Mon Sep 17 00:00:00 2001
From: chris <kokosias@yahoo.gr>
Date: Thu, 1 Oct 2020 02:27:42 +0300
Subject: [PATCH] fix marker

---
 wax-prosemirror-plugins/src/WaxSelectionPlugin.js | 9 ---------
 1 file changed, 9 deletions(-)

diff --git a/wax-prosemirror-plugins/src/WaxSelectionPlugin.js b/wax-prosemirror-plugins/src/WaxSelectionPlugin.js
index 100f9c20e..6be0677f0 100644
--- a/wax-prosemirror-plugins/src/WaxSelectionPlugin.js
+++ b/wax-prosemirror-plugins/src/WaxSelectionPlugin.js
@@ -9,13 +9,6 @@ const WaxSelectionPlugin = new Plugin({
     apply(transaction, state, prevEditorState, editorState) {
       const sel = transaction.curSelection;
 
-      // TODO fix the selection when a note is present.
-      let flag = false;
-      const difference = sel.$to.pos - sel.$from.pos;
-      editorState.doc.nodesBetween(sel.$from.pos, sel.$to.pos, (node, from) => {
-        if (node.type.name === 'footnote') flag = true;
-      });
-
       const decos = [
         Decoration.inline(sel.$from.pos, sel.$to.pos, {
           class: 'wax-selection-marker',
@@ -23,8 +16,6 @@ const WaxSelectionPlugin = new Plugin({
       ];
       const deco = DecorationSet.create(editorState.doc, decos);
       return { deco };
-
-      return state;
     },
   },
   props: {
-- 
GitLab