enableRichtext flag not working on site_language field after Update to TYPO3 12

After upgrading TYPO3 to V12 i have trouble doing the following:

In my extension in the file Configuration/SiteConfiguration/Overrides/site_language.php:

$GLOBALS['SiteConfiguration']['site_language']['columns']['test_field'] = [
    'label' => 'RTE Field',
    'config' => [
        'type' => 'text',
        'enableRichtext' => true,
        'richtextConfiguration' => 'minimal',
    ],
];

Is this a bug or do i have to add some configuration so TYPO3 will add the module instructions for ckeditor in the SiteConfiguration Context as well?

I dont understand the formEngine very well, is it possible, that i need to manipulate this TYPO3_CONF_VAR config?

$GLOBALS['TYPO3_CONF_VARS']['SYS']['formEngine']['formDataGroup']['siteConfiguration']

So i came up with 2 possible solutions:

  1. Override the SiteConfiguration/Edit Template: no, bad idea
  2. Add a dummy richtext field to the site record

Is this a bug? Shouldnā€™t it be possible without this hack?

Hi Philipp!

It looks like you have come across one of the limitations of the Site Configuration API:

However it is not possible to extend with complex TCA like inline relations, database driven select fields, FlexForm handling and similar.

Hacking it would be a recipe for problems down the road. Since the Site Configuration is accessible to admins only (and I assume you trust your admins), I guess you could use a plain text field and ask people to enter HTML. :innocent:

Best wishes

Mathias

No, i dont violate any limitation. RTE Fields in site_language worked in V11 without a problem.

I can make it work by adding a RTE field for site, then it will also work in site_language.

So this is simply a bug. It has to do with the migration to es modules. You are not able to load / modify the importmap after the initial page load. This is by design. So TYPO3 fixed the issue for TCEForms by addind the ā€œbackend.formā€ tag for JavaScriptModules. But there is no such tag for the Site Configuration. So this is simply a bug. Plain and simple.

Hacking it would be a recipe for problems down the road. Since the Site Configuration is accessible to admins only (and I assume you trust your admins), I guess you could use a plain text field and ask people to enter HTML. :innocent:

Not true. Not everyone who is allowed to make configuration in the site config module should now everything about HTML and typolink syntax and so on. Having an RTE helps a lot.

Hi Philipp!

Iā€™m only trying to help. As far as I know, this is a limitation.

If you think it is a bug, please submit a bug report. :slight_smile:

Best wishes

Mathias

1 Like

Feel free to test the pushed bugfix at https://review.typo3.org/c/Packages/TYPO3.CMS/+/83000.

Could not apply the patch in V12, so i made the adjustments manually, the fix works! But i can not verify it because of the testing workflow.