Skip to content

TinyMCE: Clean TinyMCE internal DOM state on blur#8879

Closed
aduth wants to merge 1 commit intomasterfrom
fix/8877-tinymce-clean-dom-blur
Closed

TinyMCE: Clean TinyMCE internal DOM state on blur#8879
aduth wants to merge 1 commit intomasterfrom
fix/8877-tinymce-clean-dom-blur

Conversation

@aduth
Copy link
Member

@aduth aduth commented Aug 11, 2018

Fixes #8877

In Progress: Still needs unit tests, documentation, and evaluation of whether this is the best approach. Other options include calling setContent from RichText to just replace the content, though this may be more intensive since it requires TinyMCE to re-parse. There may be room for improvement to refactor shared behaviors between "dom" and "content" formats in formats.js. Also not sure we want to expose this as a proper format for RichText.

This pull request seeks to resolve an issue where lingering TinyMCE DOM state when a RichText field is blurred can occasionally cause forced re-focuses.

Testing instructions:

Repeat steps to reproduce from #8877, verifying that caret placement occurs as expected.

Ensure end-to-end tests pass:

npm run test-e2e

@aduth aduth added [Type] Bug An existing feature does not function as intended [Feature] Writing Flow Block selection, navigation, splitting, merging, deletion... labels Aug 11, 2018
@aduth
Copy link
Member Author

aduth commented Aug 15, 2018

Related: Implementing some of the ideas with on-demand TinyMCE in #8822 / #341 may require the same sort of "clean-up" to occur when leaving a RichText field.

@ellatrix
Copy link
Member

Closing this PR as #8877 is fixed.

@ellatrix ellatrix closed this Nov 27, 2018
@ellatrix ellatrix deleted the fix/8877-tinymce-clean-dom-blur branch November 27, 2018 08:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

[Feature] Writing Flow Block selection, navigation, splitting, merging, deletion... [Type] Bug An existing feature does not function as intended

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Writing Flow: Pressing enter while within inline boundary forces caret position to revert

2 participants