Update CKEditor 5 to 38.1.0

Created on 28 June 2023, almost 2 years ago
Updated 28 July 2023, over 1 year ago

Problem/Motivation

https://github.com/ckeditor/ckeditor5/releases/tag/v38.1.0

Proposed resolution

  1. Update core/package.json
  2. cd core
  3. yarn install
  4. yarn build
  5. yarn build:ckeditor5-types

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet

📌 Task
Status

Fixed

Version

10.1 ✨

Component
CKEditor 5  →

Last updated 4 days ago

Created by

đŸ‡Ģ🇮Finland lauriii Finland

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @lauriii
  • Status changed to Needs review almost 2 years ago
  • last update almost 2 years ago
    29,562 pass
  • đŸ‡Ģ🇮Finland lauriii Finland

    Checking what testbot thinks 🤞

  • 🇧đŸ‡ĒBelgium wim leers Ghent 🇧đŸ‡ĒđŸ‡ĒđŸ‡ē

    Thank you, you beat me to it! 😄

    If all is well, then this release with NO major breaking changes (which they explicitly did at our request to address as many of

    1. the most-upgrade-blocking problems in 🌱 [meta] [upstream] Prioritized CKEditor 5 upstream blockers Active during 10.1 rather than waiting for Drupal 10.2 in December! 🙏👍) fixes:
    2. the widely reported Style-support-for-<div> problem: applying a class to a div now works using the UI! #3326261-51: [upstream] [Style] Unable to apply styles to
      ,
        ,
          , etc. in CKEditor 5 — and allows applying it to all elements →
        1. the often reported "bleeding" of styles: #3326261-51: [upstream] [Style] Unable to apply styles to
          ,
            ,
              ,
        2. etc. in CKEditor 5 — and allows applying it to all elements →
        3. 🐛 [upstream] [GHS] CKEditor 5 removes s that wrap HTML elements not natively supported by CKEditor 5 Fixed
        4. That's 3 issues that are often blocking the switch from CKEditor 4 to 5 solved, one of which is a data loss bug.

          Ideally, this release would ship in Drupal 10.1.1!

        5. Status changed to RTBC almost 2 years ago
        6. 🇧đŸ‡ĒBelgium wim leers Ghent 🇧đŸ‡ĒđŸ‡ĒđŸ‡ē

          Given that this fixes a critical data loss bug ( 🐛 [upstream] [GHS] CKEditor 5 removes s that wrap HTML elements not natively supported by CKEditor 5 Fixed ), bumping to .

          Since this passes tests, RTBC'ing.

        7. đŸ‡Ģ🇮Finland lauriii Finland

          MINOR BREAKING CHANGES ℹī¸
          html-support: The htmlAttributes model property has been replaced by html*Attributes, where the * represents the name of the view element. Clients will need to modify their code accordingly by replacing all instances of htmlAttributes with html*Attributes for the respective view elements.

          It looks like core is not impacted by this even though we are using htmlAttributes for Drupal Media. It does look like this will break at least UI Styles contrib module but it's used by 414 sites. Ideal way to address this would be to remove their usage of htmlAttributes and use the CKEditor 5 core APIs instead.

        8. đŸ‡Ŧ🇧United Kingdom catch

          Can we open an issue against UI Styles (not necessarily with a patch but at least a heads up)?

        9. đŸ‡Ŧ🇧United Kingdom catch

          Spoke to @lauriii in irc, UI Styles is still in the progress of updating for 10.1, so we wouldn't be breaking existing sites that use it. Given this fixes critical data loss bugs, I think we should just go ahead and commit it to 10.1.x - but asap so it gets into 10.1.1 and the minimal number of sites go from 10.1.0 to 10.1.1 vs 10.0.x to 10.1.1

        10. đŸ‡Ģ🇮Finland lauriii Finland

          I did some manual testing to confirm that the issues mentioned in #3 are indeed solved. It looks like there's really good progress there! I wasn't able to convert an existing element to a <div> which is needed to be able to close 🐛 [Style] Add tests for inability to apply styles to , , , etc. in CKEditor 5 — and allows applying it to all elements Fixed . Applying styles to <ul> and <table> worked just as I would have expected. 🤩 Confirmed also that wrapping <a> for elements not supported by CKEditor 5 are retained.

          • catch → committed 139732ef on 10.1.x
            Issue #3370989 by lauriii, Wim Leers: Update CKEditor 5 to 38.1.0
            
            (...
          • catch → committed fb6023c3 on 11.x
            Issue #3370989 by lauriii, Wim Leers: Update CKEditor 5 to 38.1.0
            
        11. Status changed to Fixed almost 2 years ago
        12. đŸ‡Ŧ🇧United Kingdom catch

          Committed/pushed to 11.x and cherry-picked to 10.1.x, thanks!

        13. 🇧đŸ‡ĒBelgium wim leers Ghent 🇧đŸ‡ĒđŸ‡ĒđŸ‡ē

          #7++ — that's exactly the rationale I mentioned to @lauriii too :)

          #8:

          I wasn't able to convert an existing element to a
          which is needed to be able to close [â€Ļ]

          Yes, I called that out in detail over at #3326261-51: [upstream] [Style] Unable to apply styles to

        14. etc. in CKEditor 5 — and allows applying it to all elements →. But the critical data loss part is solved 👍

        15. Automatically closed - issue fixed for 2 weeks with no activity.

        16. Status changed to Fixed over 1 year ago
        17. 🇧đŸ‡ĒBelgium wim leers Ghent 🇧đŸ‡ĒđŸ‡ĒđŸ‡ē
        18. Production build 0.71.5 2024