Project

General

Profile

Actions

Bug #100650

closed

CKEditor 5 in TYPO3 v12 removes mutiple css classes

Added by Samuel Heinz over 1 year ago. Updated over 1 year ago.

Status:
Closed
Priority:
Should have
Category:
RTE (rtehtmlarea + ckeditor)
Target version:
Start date:
2023-04-18
Due date:
% Done:

0%

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

Description

In the current TYPO3 v12.3.0 it isn't possible to set multiple classes in the CKEditor 5 for example for a button.

- { name: "Button: Sekundär", element: "a", classes: ['btn btn-primary'] }

The second class is automatically removed if you save the content element.
In the old CKEditor 4 in TYPO3 v11 LTS the multiple classes were no problem.

Best regards
Sam


Related issues 2 (0 open2 closed)

Related to TYPO3 Core - Bug #100841: CkEditor Migrator should respect multiple allowedClassesClosedStefan Froemken2023-05-09

Actions
Related to TYPO3 Core - Task #104310: Add example for multiple css classesClosed2024-07-04

Actions
Actions #1

Updated by Samuel Heinz over 1 year ago

:) Should be "btn btn-secondary" haha

Actions #2

Updated by Samuel Heinz over 1 year ago

  • Category set to RTE (rtehtmlarea + ckeditor)
Actions #3

Updated by Wittkiel Gruppe over 1 year ago

Did you try this?

- { name: "Button: Sekundär", element: "a", classes: ['btn', 'btn-primary'] }

Actions #4

Updated by Samuel Heinz over 1 year ago

Wittkiel Gruppe wrote in #note-3:

Did you try this?
[...]

Thanks, tested with anchors and it works :)
Still got the problem to set a individual class to lists and tables.
Not sure if this is a generally problem in CKEditor 5...

Actions #5

Updated by Wittkiel Gruppe over 1 year ago

Samuel Heinz wrote in #note-4:

Still got the problem to set a individual class to lists and tables.
Not sure if this is a generally problem in CKEditor 5...

This is also a huge problem for us, especially tables. It's sadly a general problem with CKEditor 5, see for example #99681 and #99669 and https://github.com/ckeditor/ckeditor5/issues/11577 and https://github.com/ckeditor/ckeditor5/issues/13208 ..

Actions #6

Updated by Stefan Froemken over 1 year ago

  • Status changed from New to Closed
  • Assignee set to Stefan Froemken

It's official CKEditor 5 API to add multiple CSS classes as String<array>:
https://ckeditor.com/docs/ckeditor5/latest/api/module_style_styleconfig-StyleDefinition.html

I will create a new issue for Migrator to respect that, too.

Actions #7

Updated by Stefan Froemken over 1 year ago

  • Related to Bug #100841: CkEditor Migrator should respect multiple allowedClasses added
Actions #8

Updated by Guido Schmechel 5 months ago

  • Related to Task #104310: Add example for multiple css classes added
Actions

Also available in: Atom PDF