Review main Merged

90032[TASK] Update to CKEditor 5 46.1.1

Garvin Hicking CR +2 V +2 Nightmare +1575 −1448 updated 10/02/25, 11:34

Commit message

With the upgrade to CKEditor 5 46.x, three relevant changes
are made:

1.  The API naming of TypeScript imports has changed a lot. Custom
    CKEditor 5 plugins that utilize TypeScript build chains will
    need to be adapted to match update type imports. The created
    JavaScript modules however remain compatible, so this is not
    regarded as a breaking change.
    See [1] for a large table of "before->after" renames.

2.  A new opinionated default CSS is used by CKEditor to apply some
    improved styling over contents displayed within the RTE interface.
    Most of these are overruled by TYPO3's default CSS integration
    though. Possible customizations need to respect this.

3.  A few CSS classes have been renamed, see [2].
    These are for example referenced in custom CKEditor YAML
    configuration files.

Referenced CSS class names are updated.
The Core's custom plugin (LinkBrowser) is adapted to compile against
CKEditor 5 v46, but build output actually remains unchanged, as
only type imports had to be adapted, while runtime compatibility
was preserved.

Additionally, the naming of "CKEditor 5" (instead of "CKeditor"
or "CKEditor v5" or "CKEditor5") has been globally replaced
to match the proper product name. We also care to not be
called "typo v3". ;-)

Commands:

  cd Build
  npm --prefix overrides/ckeditor5 version 46.1.1
  npm install --save ./overrides/ckeditor5 $(
    grep @ckeditor/ package.json | \
    grep -v @ckeditor/ckeditor5-dev-utils | \
    grep -v @ckeditor/ckeditor5-inspector | \
    sed 's/^[^"]*"\([^"]*\)".*/\1@46.1.1/' \
  )
  npm install --save @ckeditor/ckeditor5-icons@^46.1.1
  npm install --save @ckeditor/ckeditor5-inspector@^5.0.0
  npm run build

[1] https://ckeditor.com/docs/ckeditor5/latest/updating/nim-migration/migrating-imports.html
[2] https://ckeditor.com/docs/ckeditor5/latest/updating/guides/update-to-46.html

Review

  • Code review CR +2 Done
    • Garvin Hicking +2
    • Benjamin Franzke +1
    • Simon Schaufelberger +1
  • Verified V +2 Done
    • Garvin Hicking +2
    • Benjamin Franzke +1
    • Simon Schaufelberger +1
    • core-ci +1 CI

Issues 1

Files 67

Show 47 more files

Review log 2941

Show 1016 earlier messages
  1. Garvin Hicking uploaded patch set 1 07/09/25, 10:34

  2. core-ci voted on patch set 1 V +1 07/09/25, 10:42 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/81522

  3. Garvin Hicking uploaded patch set 2 V +1 07/30/25, 08:05

  4. Garvin Hicking uploaded patch set 3 07/30/25, 08:10

  5. core-ci voted on patch set 2 V -1 07/30/25, 08:13 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/82543

  6. core-ci voted on patch set 3 V -1 07/30/25, 08:17 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/82544

  7. Göran Bodenschatz updated the commit message in patch set 4 V -1 08/01/25, 15:37

  8. core-ci voted on patch set 4 V -1 08/01/25, 15:45 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/82639

  9. Göran Bodenschatz commented on patch set 4 08/01/25, 15:52

    Breaking-107063-CKEditor5-v46.rst:6

    I suggest we use the official naming in running text - which is "CKEditor 5".
  10. Garvin Hicking uploaded patch set 5 V -1 08/19/25, 10:03

  11. Garvin Hicking commented on patch set 5 08/19/25, 10:04

    Breaking-107063-CKEditor5-v46.rst:6 Reply

    You are right, I unified the naming to be called like this. As a project that pays attention to its proper product naming, I think we deserve to also use the proper spelling for our dependencies. Thank you for pointing this out!
  12. Garvin Hicking commented on patch set 5 08/19/25, 10:04

    Breaking-107063-CKEditor5-v46.rst:6 Reply

    Done
  13. core-ci voted on patch set 5 V +1 08/19/25, 10:12 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/83602

  14. Garvin Hicking uploaded patch set 6 V +1 09/03/25, 07:57

  15. Garvin Hicking uploaded patch set 7 09/03/25, 08:01

  16. core-ci voted on patch set 6 V -1 09/03/25, 08:06 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/84305

  1. core-ci voted on patch set 7 V +1 09/03/25, 08:09 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/84306

  2. Garvin Hicking uploaded patch set 8 V +1 09/10/25, 08:10

    v46 1 0
  3. core-ci voted on patch set 8 V +1 09/10/25, 08:18 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/84764

  4. Göran Bodenschatz voted on patch set 8 CR +1 09/10/25, 12:25

  5. Garvin Hicking uploaded patch set 9 CR +1 V +1 09/15/25, 09:21

    Groundhog day for 46 1 1
  6. core-ci voted on patch set 9 V +1 09/15/25, 09:28 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/84978

  7. Benjamin Franzke commented on patch set 9 09/23/25, 07:20

    Let's try to bring this into v13 as well, I commented on the Breaking.rst and think that this can be downgraded to an Important.rst (or even completely omitted by "migrating" CSS on-the-fly)

    Breaking-107063-CKEditor5-v46.rst:16

    We basically prepared for the entirety of this change with https://review.typo3.org/c/Packages/TYPO3.CMS/+/81323 That means: We do *only* use named exports of the main entry point npm-packages, and we only expose those as API to be usable for extensions (via our importmap). That means: The exports that are not being removed/unsupported were not supported in our environment at all. => Not a breaking change. Users that compile via TypeScript against ckeditor sources may need to adapt some *type* (so compile-time) imports upgrading from 45 to 46, but that upgrade happens in their NPM toolchain and is unrelated to our update. We're fine to see this as non-breaking.

    Breaking-107063-CKEditor5-v46.rst:21

    Ack, upstream basically did the same as we did previously with https://review.typo3.org/c/Packages/TYPO3.CMS/+/89862 – but it applied it to all elements. The reason is dark mode as described in https://github.com/ckeditor/ckeditor5/issues/18710 I'd not see this as a blocker, since it is opiniated, yes, but it will not heavily break since everyone with custom stylings (that did not just wanted their fonts to look like default TYPO3 backend – which will not break) will overrule the new default anyway. This can be seen as non-breaking.

    Breaking-107063-CKEditor5-v46.rst:26

    This could be an Important.rst if we want to. We could also see if we could "hotfix" defined variables within `./Build/Sources/TypeScript/rte-ckeditor/css-prefixer.ts` and provide a automatic migration in v13/main, but that's probably out of scope?
  8. Garvin Hicking commented on patch set 9 09/23/25, 08:01

    Reply

    Thanks for writing this down. I agree and will rework the patch (likely on friday). I have no strong opinion about CSS on-the-fly migration, but I feel that could be flakey and much work for little gain. Advising to change custom CSS via important sounds more helpful to me to prevent side-effects and carrying around legacy migrations for a long time.
  9. Garvin Hicking marked it work in progress 09/23/25, 08:01

  10. Garvin Hicking uploaded patch set 10 V +1 09/26/25, 06:35

  11. Garvin Hicking marked it ready for review 09/26/25, 06:35

  12. Garvin Hicking commented on patch set 10 09/26/25, 06:36

    Reply

    I've reworked the RST file and commit message, could you check if you find this reasonable?

    Breaking-107063-CKEditor5-v46.rst:16 Reply

    Acknowledged

    Breaking-107063-CKEditor5-v46.rst:21 Reply

    Acknowledged

    Breaking-107063-CKEditor5-v46.rst:26 Reply

    Acknowledged
  13. core-ci voted on patch set 10 V +1 09/26/25, 06:41 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/85567

  14. Benjamin Franzke uploaded patch set 11 V +1 09/26/25, 07:25

  15. Benjamin Franzke commented on patch set 11 09/26/25, 07:26

    Reply

    I only added minor clarifications that only type imports changed. Good to go now :) Thanks a bunch!
  16. core-ci voted on patch set 11 V +1 09/26/25, 07:33 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/85574

  17. Andreas Kienast commented on patch set 11 09/30/25, 05:48

    Important-107063-CKEditor5-v46.rst:36

    One minor note: we could use an actual diff here which makes it easier to see the actual changes. Opinions?
  18. Andreas Kienast commented on patch set 11 09/30/25, 05:50

    CKEditor5Migrator.php:923

    ```suggestion // CKEditor 4 used `wordcount` (lowercase), which is `wordCount` in CKEditor 5. ```
  19. Garvin Hicking uploaded patch set 12 CR +1 V +1 09/30/25, 06:54

  20. Garvin Hicking commented on patch set 12 09/30/25, 06:55

    Important-107063-CKEditor5-v46.rst:36 Reply

    Good point. Made it multiline, and I like it.

    CKEditor5Migrator.php:923 Reply

    Hehe. Alright, unified that, too. :)
  21. core-ci voted on patch set 12 V +1 09/30/25, 07:01 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/85730

  22. Simon Schaufelberger voted on patch set 12 CR +1 V +1 10/01/25, 19:25

  23. Benjamin Franzke voted on patch set 12 CR +1 V +1 10/02/25, 08:59

  24. Garvin Hicking voted on patch set 12 CR +2 V +2 10/02/25, 10:50

  25. Garvin Hicking merged patch set 13 10/02/25, 11:34