Problem/Motivation
When the CKEditor5 editor is in source editing mode it no longer emits the data change event which is being monitored to update the related JSON Editor field and the final instance config field on the form. Once the editor is changed back to regular mode, the change event fires and everything is updated, but if the form is submitted without changing this back, the data may be lost.
This issue is split from and builds on top of the CKEditor5 functionality added in #3312164: Incompatible with CKEditor 5 in Drupal 9.5.
Steps to reproduce
During these test steps, make sure to open your browser console and monitor for errors being logged.
- Install a fresh drupal 9.5/10 site
- Enable Patternkit, Patternkit Example, CKEditor5, and Layout Builder modules
- Go to /admin/config/user-interface/patternkit/json
- Set Wysiwyg editor to "CKEditor 5" and Basic HTML from CKEditor toolbar.
- Create a basic page content type and add PK [Example block] from layout builder.
- Add content in the "Formatted Text" field with CKEditor
- Click the "..." and click the "Source" button to edit markup
- Click the form's "Add block" button to place the block on the page
- Expect to see no console errors and the block with the formatted content present on the page
Proposed resolution
Remaining tasks
User interface changes
None
API changes
None
Data model changes
None
| Comment | File | Size | Author |
|---|---|---|---|
| #5 | DAT 3996_Retest.odt | 1.09 MB | minsharm |
Issue fork patternkit-3347660
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
sluceroI'm planning to push back the Beta 7 release for #3327256: Beta 7 Release Plan to the end of April, and I would like to include this in it. Ideally that will allow us to get everything tested more completely and include a more complete and functional release of the CKEditor 5 support.
Comment #4
sluceroComment #5
minsharm commentedRetested the issue and content is being updated now in source view mode within the sidebar layout builder as well as in the new window on both D9 and D10.
Attaching Screenshots.
Comment #6
sluceroThis has been re-tested and verified internally at Red Hat. Merging for inclusion in the Beta 7 release.
Comment #8
sluceroMerged for inclusion in the Beta 7 release.