Skip to main content

[BUGFIX] Apply correct default classes to `GenericButton`

The class `TYPO3\CMS\Backend\Template\Components\Buttons\GenericButton`
accidentally applied the wrong CSS classes on the rendered button.
This bugfix now applies the correct classes for buttons and provides
setter and getter methods for classes.

Resolves: #99841
Related: #99806
Releases: main
Change-Id: I3125a1208481da3d488b50847978171ca0b1f2bb
Tested-by: Benjamin Kott <>
Tested-by: Oliver Bartsch <>
Tested-by: Andreas Fernandez <>
Tested-by: core-ci <>
Reviewed-by: Benjamin Kott <>
Reviewed-by: Oliver Bartsch <>
Reviewed-by: Andreas Fernandez <>

[FEATURE] Streamline Template Buttons

This patch streamlines the behavior of template buttons. For this, we
sort all classes to match the same order. To be more flexible for the
usage of `DropDownButton` we now also allow the hiding of the label
text, but there must be a label text or an icon assigned.

We are introducing a `GenericButton` to cover more complex situations
while ensuring a unified output.

Adjust the `typo3-copy-to-clipboard` element to work like a normal
button element that allows keyboard navigation.

Resolves: #99806
Releases: main
Change-Id: Ic6e7d9036097bfd87493e51e5e128ab895af1731
Reviewed-by: Georg Ringer <>
Reviewed-by: Andreas Fernandez <>
Tested-by: Georg Ringer <>
Tested-by: core-ci <>
Tested-by: Andreas Fernandez <>