Details
-
Bug
-
Status: Closed
-
Top
-
Resolution: Available for testing
-
5.1.0
-
None
-
2
-
Tiger Sprint 166
Description
The CKEditor component does not treat the configuration object for HTML fields well. Several attributes are overwritten or wrongly appended to. As a result, certain customizations won't work.
In particular, the following CKEditor configuration properties can't be used by customers to tweak the HTML fields:
- extraPlugins (because it's overwritten entirely)
- removeButtons (because it's overwritten entirely)
- removePlugins (because it's appended to without checking whether a seperating comma should be added in between)
These configuration properties happen to be very common. See https://www.onehippo.org/library/concepts/document-types/html-fields/ckeditor-configuration-examples.html for examples of extraPlugins and removePlugins, and https://www.onehippo.org/library/concepts/document-types/html-fields/ckeditor-toolbar-configuration.html for the usages of removeButtons.
Example of 'extraPlugins' going wrong:
- Edit the 'news' document type in the HAP
- For the 'Content' field, set the property ckeditor.config.overlayed.json to
{ extraPlugins: 'smiley' }
- Edit a news document in the Content perspective. There should be an additional 'smiley' button visible that can be used to insert a Smiley face .
- Edit a news document in the Channel Manager. The smiley button is not visible, but it should be.
Example of 'removePlugins' going wrong:
- Edit the 'news' document type in the HAP
- For the 'Content' field, set the property ckeditor.config.overlayed.json to
{ removePlugins: 'basicstyles' }
- Edit a news document in the Content perspective. The buttons 'bold', 'italic' etc. are not visible.
- Edit a news document in the Channel Manager. The buttons 'bold', 'italic' etc. are still visible, but they shouldn't.
Example of 'removeButtons' going wrong:
- Edit the 'news' document type in the HAP
- For the 'Content' field, set the property ckeditor.config.overlayed.json to
{ removeButtons: 'Bold' }
- Edit a news document in the Content perspective. The 'bold' button is not visible.
- Edit a news document in the Channel Manager. The 'bold' button is still visible, but it shouldn't.
Attachments
Issue Links
- is backported by
-
CHANNELMGR-1495 [Backport to 5.0] CKEditor component overwrites various customizations
- Closed