This commit removes several contentious formatting options for now,
pending further consideration, in particular it removes:
- forecolor
- backcolor
- fontfamily
- styles
The two color plugins are written in such a way that the chosen colour
is embedded into a style tag in the generated content. This is not
ideal as it removes these decisions away from theme developers and upon
theme changes to a site, is likely to lead to inaccessible and/or broken
content.
We feel that a new colour plugin will be required which links to known
colour style classes within the theme to allow a subset of colours which
are guaranteed to work with the theme.
The fontfamily plugin is removed pending further administrator
configuration in a future release.
In the case of the 'styles' plugin, this duplicates large parts of the
Format menu into which it is placed but does so in a way that does
respect the configuration of other areas - for example the block_formats
tag is ignored in this menu.
Part of MDL-75966
The template plugin is a part of Tiny, and requires us to create an
administrator UI to configure the templates.
This requires much more thought on workflows, intent, and so on so we'll
park it for later.
Part of MDL-75966.
Part of MDL-75966
This commit adds a cache-busting loader API for use in the TinyMCE
plugin.
This is not for use in any TinyMCE subplugins at this time as we have no
use-case outside of AMD modules.
This loader ensures that only files within the js/tiny directory are
loaded, and it only supports either .js or .css files at this time.
The client-side of the loader makes use of the jsrevision as a
cache-buster, including for CSS files included with TinyMCE.
If the revision is negative, then files are not cached.
If the revision is positive, then the requested file is cached in a
candidate file and served using aggressive cache headers.
Part of MDL-75966
Add support for translation of the TinyMCE interface.
TinyMCE translates English language strings rather than keys, and a tool
to perform this translation is included.
Part of MDL-75966
This commit adds TinyMCE version 6.1 into Moodle core.
A basic editor implementation is included, along with Moodle loader, and
basic Plugin API for Moodle. The Plugin API will be extended and
improved in future changes.
A new subplugin is defined for this plugin.
- The current item should be focusable otherwise the focus will be lost
as soon as a user clicks on an item in the initials bar
- Modified behat tests to not mistakenly click on the 'All' link
- Use the nav tag because each item in the initials bar is a
navigation link within the current document
- The currently selected item is specified by aria-current
- Useed aria-current=true rather than =page because the links of each
item in the initials bar is missing the pagination information