-
Bug
-
Resolution: Fixed
-
Major
-
4.3.7, 4.4, 4.5
In some situations the quicktoolbar of TinyMCE seems to be disabled. This happens especially when the editor text area has only a few lines (for example the introeditor in mod_resource).
When there is a tiny plugin trying to add items to the quicktoolbar in this case, tiny throws an error in the console and does not load.
Reason is that the check here https://github.com/moodle/moodle/blob/8a6e8563fdc9e9684ab628ea0274fd2277bc5265/lib/editor/tiny/amd/src/utils.js#L217 only works if the quicktoolbar object is null or undefined, but not, if it's false, which however seems to be the case for example in the introeditor when adding a mod_resource activity.
Yes, the plugins of course can do the check on their own. But the addQuickbarsToolbarItem function tries to do a check and I feel like it should also catch the case of quicktoolbar === false
Same for contextmenu.
To reproduce:
- As admin go to admin/settings.php?section=editorsettingstiny
- Enable "no auto-link" plugin
- Create a course
- Add activity "File"
- See that the intro editor is not loading and you have an error in the JS console
- has been marked as being related by
-
MDL-82728 PR only: MDL-82724 - TinyMCE adding quicktoolbar function throws error when quicktoolbar is disabled
-
- Closed
-
- will help resolve
-
MDL-82672 TinyMCE NOT loading into File and URL descriptions on Moodle 4.3, and various other editing areas in Quiz and quiz Questions
-
- Closed
-