#95428different behaviour for "Standard" option in frame-class vs space-before/after classes
Description
I added a new frame_class option called ‘container’.
Then I have overridden the standard option for the frame_class and space_before_class / space_after_class fields in my_ext/Configuration/TCA/Overrides/tt_content.php like:
$GLOBALS[‘TCA’][‘tt_content’][‘types’][‘textmedia’][‘columnsOverrides’][‘frame_class’][‘config’][‘default’] = ‘container’;
$GLOBALS[‘TCA’][‘tt_content’][‘types’][‘textmedia’][‘columnsOverrides’][‘space_before_class’][‘config’][‘default’] = ‘medium’;
$GLOBALS[‘TCA’][‘tt_content’][‘types’][‘textmedia’][‘columnsOverrides’][‘space_after_class’][‘config’][‘default’] = ‘medium’;
So, if I create a new Text&Media content element, the default values for
*frame_class* would be container and
*space_before_class* = medium and space_after_class = medium
I can then change the option in the frame_class back to Standard or any other value that’s available in the dropdown.
The same can’t be done in the space_before/after_class fields.
If I choose the Standard option the value jumps back to medium. So, selecting the Standard option (which would mean zero space) is not possible anymore.
To solve this, I changed the TCA config for space_before_class / space_after_class in public/typo3/sysext/frontend/Configuration/TCA/tt_content.php to
‘space_before_class’ => [
‘exclude’ => true,
‘label’ => ‘LLL:EXT:frontend/Resources/Private/Language/locallang_ttc.xlf:space_before_class’,
‘config’ => [
‘type’ => ‘select’,
‘renderType’ => ‘selectSingle’,
‘items’ => [
[‘LLL:EXT:core/Resources/Private/Language/locallang_general.xlf:LGL.default_value’, ‘default’ ],
…..
],
‘default’ => *‘default’*
]
],
After changing the empty value to a string, I can now select the default value in the space_after/before_class field again.
It seems that the problem is the empty value…?
Because the Standard option has “no space” at all, I would suggest to rename the Standard option to “Kein Abstand” with the value “none”.
I assume that would solve the problem.
Or add default as value to the Standard option…
Reviews 2
Files 2
History 613
-
Benni Mack changed category <span data-processor="relativetime" data-value="2024-06-19T20:52:25+00:00" > 06/19/24, 20:52 </span>
-
Georg Ringer commented and changed attached Bildschirmfoto 2024-06-23 um 21.45.37.png status
NewClosed <span data-processor="relativetime" data-value="2024-06-23T19:46:27+00:00" > 06/23/24, 19:46 </span> -
Georg Ringer changed status
ClosedAccepted <span data-processor="relativetime" data-value="2024-06-26T14:11:25+00:00" > 06/26/24, 14:11 </span> -
Georg Ringer changed attached 2024-06-26 15-32-07.mp4 <span data-processor="relativetime" data-value="2024-06-26T17:23:27+00:00" > 06/26/24, 17:23 </span>
-
Gerrit Code Review pushed patch set 1 for main to change 84934 status
AcceptedUnder Review <span data-processor="relativetime" data-value="2024-06-26T17:42:05+00:00" > 06/26/24, 17:42 </span> -
Gerrit Code Review pushed patch set 2 for main to change 84934 <span data-processor="relativetime" data-value="2024-06-26T19:16:29+00:00" > 06/26/24, 19:16 </span>
-
Gerrit Code Review pushed patch set 3 for main to change 84934 <span data-processor="relativetime" data-value="2024-06-27T10:51:38+00:00" > 06/27/24, 10:51 </span>
-
Gerrit Code Review pushed patch set 4 for main to change 84934 <span data-processor="relativetime" data-value="2024-07-23T14:11:47+00:00" > 07/23/24, 14:11 </span>
-
Gerrit Code Review pushed patch set 5 for main to change 84934 <span data-processor="relativetime" data-value="2024-10-18T13:39:15+00:00" > 10/18/24, 13:39 </span>
-
Gerrit Code Review pushed patch set 6 for main to change 84934 <span data-processor="relativetime" data-value="2025-02-17T19:42:45+00:00" > 02/17/25, 19:42 </span>
-
Gerrit Code Review pushed patch set 1 for 13.4 to change 88266 <span data-processor="relativetime" data-value="2025-02-18T14:46:07+00:00" > 02/18/25, 14:46 </span>
-
Georg Ringer commented and changed status
Under ReviewResolved done0 %100 % <span data-processor="relativetime" data-value="2025-02-18T14:50:09+00:00" > 02/18/25, 14:50 </span>Applied in changeset commit:916e8564e3fa41432b48ac6e65415fb81c584b85.
-
Benni Mack changed status
ResolvedClosed <span data-processor="relativetime" data-value="2025-08-12T14:35:31+00:00" > 08/12/25, 14:35 </span>
thanks for creating the issue. checking that out in v13 seems that this now works (probably also in v12)
Bildschirmfoto%202024-06-23%20um%2021.45.37.png