edx-platform
edx-platform copied to clipboard
fix: Styling issue in TinyMCE editor in Studio
Description
- This PR fixes the issue in the TinyMCE editor in Studio.
- TinyMCE was upgraded from v4.0.20 to v5.5.1 under https://github.com/openedx/edx-platform/pull/30335.
- With these changes, we have also changed the way we get the text from the TinyMCE editor. We are passing
text
as format instead ofraw
to get the content from the editor object. - It returns plain text only. In the end, we just check for the plain text changes, and if plain text is not changed then the styling changes like bold, and italic text are not saved.
Hyperlinks
are also not working. - Changes will impact course authors.
Before these changes:
https://user-images.githubusercontent.com/52656433/198288326-58be7f45-0ed1-4d21-aae1-732ca27c81bb.mov
After these changes:
https://user-images.githubusercontent.com/52656433/198288964-6efc2b54-1e90-4ed5-91c7-5f77aca38451.mov
Supporting information
https://github.mit.edu/mitxonline/mitxonline-issues/issues/162
Testing instructions
- Edit course unit in the studio using the TinyMCE editor as in the supporting videos.
- Edit only the styles of the existing text and save the changes.
- Changes should be saved.
Deadline
"None"