editor.js
editor.js copied to clipboard
[Bug]Uncaught TypeError: Cannot read property 'parentNode' of null
Describe a bug.
When a user creates the header block and select substring of text and try to drag and put again in the same block, the user gets Uncaught TypeError: Cannot read property 'parentNode' of null on the console.
Steps to reproduce: 1.Go to editor.js sample document. (https://editorjs.io/) 2. Create a new Header Block 3. fill the block with some text 4. try to select substring of that text and drag that substring. 5.Release the text in the same block 6.You get an error 7.Caret behaves strangely after releasing that text.
Expected behaviour: You shouldn't get an error.
Screenshots:

Device, Browser, OS: PC ,Chrome 85.0.4183.121 ,Windows 10
Editor.js version: 2.18.0
Fixed with this for now
onMouseOver={() => {}}
where do i put that event in react-editor-js??
Bug still exists
where do i put that event in react-editor-js??
I encountered same issue, you should attach onMouseOver={() => {}} to the div which is used as EditorJs instance
example:
<div id={editorJsID} onMouseOver={() => {}} />
Sure, this solution is just a workaround, but at least it removed the error for my case