Loading
Override JSON Editor purify() to prevent CKEditor HTML stripping
JSON Editor >= 2.16.0 calls purify() in setValue(), which strips all
HTML tags when DOMPurify is unavailable. This silently removes
formatting markup (<strong>, <em>, etc.) from CKEditor field values.
Override purify() in DrupalCKEditor5 to return the value unchanged. CKEditor's own data pipeline and Drupal's processed_text filter handle sanitization.
Also improves test configuration:
- Explicit filter_html with allowed tags matching test assertions
- Use ckeditor5.smart_default_settings for valid toolbar config
- Reformat multi-line assertions for readability
Edited by Stephen Lucero