Allow TinyMCE to respect the template's options #14456
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Pull Request for improving the UX and making editing a bit easier.
Summary of Changes
TinyMCE out of the box comes with some very basic styling. Eg the
Bold
button is just a<strong>
around the selected text. But the editor gives the ability for further customisations e.g.: attach a class or inline styles etc...So this PR brings that functionality to Joomla.
It covers both styles and formats (styles are the ones that correspond to the buttons e.g. bold, align left, etc and formats are the ones that will be in the formats dropdown)
Testing Instructions
Grab the files from https://gist.github.com/dgt41/be9e16814371f43ce99e8dc74ef54e99
and place them in
administrator/templates/isis/css
directoryEdit tinyMCE's configuration and type the relative paths:
Edit an article and observe the code when selecting a format or applying a style (e.g. bold, align right)
Expected result
Styles (standard buttons):
Formats (Formats dropdown
):
Documentation Changes Required
Yup!
Inspired by @coolcat-creations post on @brianteeman 's site...