Clicking on a zero-width node and dragging does not select text
See original GitHub issueWhat’s the current behavior?
Clicking on an empty paragraph or next to a inline link (both have data-slate-zero-width
nodes) and then dragging to select text only moves the cursor and does not select text.
What’s the expected behavior?
I should be able to click and drag anywhere on the document to select text.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:12 (10 by maintainers)
Top Results From Across the Web
Selection and Range - The Modern JavaScript Tutorial
JavaScript can access an existing selection, select/deselect DOM ... If node is a text node, then offset must be the position in its...
Read more >Resize a div on border drag and drop without adding extra ...
It is certainly possible to do this without an extra div. Use css and ::after to create the border and change the cursor....
Read more >Zero-Width Space - CSS-Tricks
The name zero-width space is antithetical, but it's not without uses. In text, maybe you'd use it around slashes because you want to...
Read more >Options, Text Editor, General - Visual Studio - Microsoft Learn
Drag and drop text editing · Select subword on double click · Cut or Copy the current line without selection · Automatic delimiter...
Read more >Basic Editing in Visual Studio Code
Learn about the basic editing features of Visual Studio Code. Search, multiple selection, code formatting.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Seems like this was fixed at some point, but the bug is back in 5.x and reproducible on all of the demos.
@ianstormtaylor I think you are right. I commented out the updateSelection and then the problem does not happen.
I will have a look at updateSelection