tinymce / tinymce

The world's #1 JavaScript library for rich text editing. Available for React, Vue and Angular
https://www.tiny.cloud
Other
15.12k stars 2.24k forks source link

4.7.10 - Cursor placement is incorrect when backspacing to a previous line #4325

Closed es11support closed 3 years ago

es11support commented 6 years ago

Do you want to request a feature or report a bug? Report a bug, possibly just an issue with Firefox.

What is the current behavior? Pasting unformatted, plain-text content into an editor with single line breaks (doesn't seem to happen with double line breaks), placing your cursor at the start of a line and backspacing to the previous line causes the cursor to appear in a different spot.

If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem via fiddle.tinymce.com or similar. Open a new fiddle, change to version 4.7.10 and copy/paste the following text:

This is line one of my content. This is line two of my content. This is line three of my content.

Place your cursor at the start of the third line and press backspace - the cursor doesn't stay in front of the "This" from the third line, but instead appears between the "h" and "i" in "This" (screenshot of cursor placement is attached below)

What is the expected behavior? Cursor should appear between the "content." and "This" on the line you backspaced to.

Which versions of TinyMCE, and which browser / OS are affected by this issue? Did this work in previous versions of TinyMCE? Just noticing this issue today, on version 4.7.10 (2018-04-03), in Firefox 59.0.2 (64-bit), but NOT in Chrome 65.0.3325.181 (Official Build) (64-bit) or IE 11 (Windows 7, latest version). So maybe something with Firefox and not Tinymce? Not sure, just figured I'd report it anyway,

tinymce-screenshot

fyrkant commented 6 years ago

This seems to be a problem in FireFox with contenteditable="true" and not TinyMCE, you can see this fiddle that the problem happens on the contenteditable="true" div also.

Reloecc commented 6 years ago

I've just reported it to https://bugzilla.mozilla.org/show_bug.cgi?id=1460273 as I am also affected.

thedrjim commented 3 years ago

This issue has been closed due to inactivity. Tiny will soon be working with members of the community to close other old issues on our GitHub repositories. Please note the official support window for TinyMCE 4 is ending on December 31, 2020. If you haven't already upgraded to TinyMCE 5 it is highly encouraged that you do so. Upgrading will give you access to the latest releases and updates made to our WYSIWYG editor focused on bringing the latest UX and developer features into the editing experience. To assist with upgrading the editor we have put together a migration guide you can use here - https://www.tiny.cloud/blog/how-to-migrate-from-tinymce-4-to-tinymce-5/ If you have any questions or concerns, you can contact me at community-qa@tiny.cloud. You can also join the discussion on our mailing list at the following link: community-qa+subscribe@tiny.cloud.