Project

General

Profile

Actions

Bug #102230

closed

Epic #99669: CKEditor5 Collection

Former CKEditor definitions no longer work after updating to TYPO3 v12.4.7

Added by Jasmina Ließmann 6 months ago. Updated 6 months ago.

Status:
Resolved
Priority:
Should have
Category:
RTE (rtehtmlarea + ckeditor)
Target version:
-
Start date:
2023-10-23
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
12
PHP Version:
8.1
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

I have a project with various custom RTE presets to arrange the toolbars according to their intended use. After updating to TYPO3 v12.4.7, the RTEs no longer work and result in an empty text area without RTE.
I found out that the spelling/definition needs to be adjusted.

Old definition, which worked in version 12.4.6:

imports:
  - { resource: "EXT:sitepackage/Configuration/Yaml/Editor/Default.yaml" }

editor:
  config:
    toolbar:
      - { name: clipboard, items: [ 'Cut', 'Copy', 'Paste', 'PasteText', 'PasteFromWord' ] }
      - { name: formating, items: [ 'RemoveFormat' ] }
      - { name: undo, items: [ 'Undo', 'Redo' ] }
      - { name: editing, items: [ 'Find', 'Replace', 'Scayt' ] }
      - { name: tools, items: [ 'ShowBlocks' ] }
      - { name: document, items: [ 'Source' ] }
      - '/'
      - { name: basicstyles, items: [ 'Bold', 'Italic', 'Underline', 'Strike', 'Subscript', 'Superscript' ] }
      - { name: insert, items: [ 'SpecialChar' ] }
      - { name: language, items: [ 'Language' ] }

    removePlugins:
      - quicktable

New definition, which now works in version 12.4.7:

imports:
  - { resource: "EXT:sitepackage/Configuration/Yaml/Editor/Default.yaml" }

editor:
  config:
    toolbar:
      items:
        - clipboard
        - removeFormat
        - '|'
        - undo
        - redo
        - '|'
        - find
        - selectAll
        - '|'
        - showBlocks
        - sourceEditing
        - '-'
        - bold
        - italic
        - underline
        - strikethrough
        - subscript
        - superscript
        - softhyphen
        - '|'
        - specialCharacters

As addition:
The referenced EXT:sitepackage/Configuration/Yaml/Editor/Default.yaml file includes configuration like:

imports:
  - { resource: "EXT:rte_ckeditor/Configuration/RTE/Processing.yaml" }
  - { resource: "EXT:rte_ckeditor/Configuration/RTE/Editor/Base.yaml" }
  - { resource: "EXT:rte_ckeditor/Configuration/RTE/Editor/Plugins.yaml" }

editor:
  config:
    #contentsCss
    #wordCount
    #heading
    #stylesSet
    #removePlugins
    #extraPlugins

#buttons
#classesAnchor

Files

old-config-12-4-7.png (6.46 KB) old-config-12-4-7.png Benjamin Franzke, 2023-10-24 08:48
new-config-12-4-7.png (6.31 KB) new-config-12-4-7.png Benjamin Franzke, 2023-10-24 08:48
sitepackage.zip (4.02 KB) sitepackage.zip Jasmina Ließmann, 2023-10-24 19:33

Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Bug #102245: CKEditor5 removePlugins configuration is not properly serialized as JSON array when some array items are migratedResolvedBenjamin Franzke2023-10-24

Actions
Actions #1

Updated by Benjamin Franzke 6 months ago

  • Assignee set to Benjamin Franzke
Actions #2

Updated by Jasmina Ließmann 6 months ago

  • Description updated (diff)

Updated by Benjamin Franzke 6 months ago

Thanks for the report.
I tried to reproduce the config on a clean install, but found only one (expected) difference between v12.4.6 and v12.4.7 using those configs:

The "showblocks" Button that is included in the old-style config does not appear in v12.4.7 which was actually intended because it was added in v12.4.6 to the bundling, without taking into account that it wasn't automatically loaded in v11 – so we "changed"/fixed that.
But other than that the toolbar and RTE works in v12.4.7, see following screenshots:

Old config:

New config:

Can you share the exact contents of EXT:sitepackage/Configuration/Yaml/Editor/Default.yaml or reproduce it locally with the old config and see if there are any browser console errors that might be of help?

Actions #4

Updated by Benjamin Franzke 6 months ago

  • Status changed from New to Needs Feedback
Actions #5

Updated by Jasmina Ließmann 6 months ago

Thanks for checking. I created a stripped-down sitepackage with two yaml files. Once with the old and with the new spelling. In the Default.yaml I have excluded irrelevant areas except for 'heading', 'removePlugins' and 'extraPlugins'. It contains:

imports:
  - { resource: "EXT:rte_ckeditor/Configuration/RTE/Processing.yaml" }
  - { resource: "EXT:rte_ckeditor/Configuration/RTE/Editor/Base.yaml" }
  - { resource: "EXT:rte_ckeditor/Configuration/RTE/Editor/Plugins.yaml" }

editor:
  config:
    removePlugins:
      - autolinking
      - image

    extraPlugins:
      - bidi
      - find
      - language
      - specialchar
      - showblocks

The active CKEditor configuration can be changed in ext_localconf.php.

With this setup I tested in a clean current TYPO3 12.4.x-dev. The RTE does not work with any of the spellings if the following lines are included:

editor:
   config:
     removePlugins:
       - quicktable

If I leave out removePlugins/quicktable, both the old and new spellings work.

Actions #6

Updated by Jasmina Ließmann 6 months ago

  • Related to Bug #102245: CKEditor5 removePlugins configuration is not properly serialized as JSON array when some array items are migrated added
Actions #7

Updated by Benjamin Franzke 6 months ago

  • Status changed from Needs Feedback to Accepted

ACK, thank you. I can confirm it's the same bug as in #102245.
With the configuration you mentioned we end up with removePlugins = {0: 'autolinking', 2: 'quicktable'} instead of removePlugins = ['autolinking', 'quicktable'] which would be correct.

Actions #8

Updated by Gerrit Code Review 6 months ago

  • Status changed from Accepted to Under Review

Patch set 2 for branch 12.4 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/81538

Actions #9

Updated by Gerrit Code Review 6 months ago

Patch set 2 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/81552

Actions #10

Updated by Gerrit Code Review 6 months ago

Patch set 3 for branch 12.4 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/81538

Actions #11

Updated by Anonymous 6 months ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
Actions

Also available in: Atom PDF