Slate: Firefox: wrong selection with double click on a text node

Created on 17 Dec 2019  Â·  2Comments  Â·  Source: ianstormtaylor/slate

Do you want to request a _feature_ or report a _bug_?

bug

What's the current behavior?

double click on a word in an unformatted paragraph (i.e. made of just one text node) and apply some formatting. then deselect and select it again. even if the browser shows the word as selected, slate has selected the whole paragraph. you can see it because the next style is applied to the whole line and not just the word. on Chrome it seems to work correctly.

Registrazione schermo 2019-12-17 alle 22 24 42

Slate: 0.55.2
Browser: Firefox
OS: Mac

What's the expected behavior?

slate should select the word, not the whole paragraph

bug ♥ help ⚑ cross platform

Most helpful comment

@sirgru yes, that should be fixed by #3374

All 2 comments

Just discovered this issue myself. In Firefox, anchor and cursor do not always return the path of the inner node when double clicking. Instead the paths seems to bleed into the previous/next node, What I've found is sometimes the selection works properly with manual drag.

@sirgru yes, that should be fixed by #3374

Was this page helpful?
0 / 5 - 0 ratings

Related issues

chrpeter picture chrpeter  Â·  3Comments

ianstormtaylor picture ianstormtaylor  Â·  3Comments

adrianclay picture adrianclay  Â·  3Comments

chriserickson picture chriserickson  Â·  3Comments

AlexeiAndreev picture AlexeiAndreev  Â·  3Comments