Skip to content
This repository has been archived by the owner on Jun 15, 2021. It is now read-only.

Pressing Enter while having a selection in inline-mode does not delete the range content #489

Closed
danburzo opened this issue Jul 22, 2016 · 1 comment

Comments

@danburzo
Copy link
Contributor

The code that handles inline mode (allowBlockElements=false) assumes that when pressing the Enter key, the range is always collapsed. When it happens not to be, the selected characters are not deleted when inserting the new line.

@danburzo danburzo changed the title Pressing Enter with selection in inline-mode behaves incorrectly Pressing Enter while having a selection in inline-mode behaves incorrectly Jul 22, 2016
@danburzo danburzo changed the title Pressing Enter while having a selection in inline-mode behaves incorrectly Pressing Enter while having a selection in inline-mode does not delete the range content Jul 22, 2016
@danburzo
Copy link
Contributor Author

Note: It's also now apparent that the check to see if there's content at the right of the cursor fails in both Chrome and Firefox, i.e. pressing Enter in the middle of a word will insert two <br> elements.

@danburzo danburzo mentioned this issue Jul 22, 2016
@katebee katebee closed this as completed in f0436c4 Mar 2, 2017
katebee added a commit that referenced this issue Mar 2, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant