From 986a8ef799d0ab68254841b1eaf5290556412322 Mon Sep 17 00:00:00 2001 From: Benni Mack Date: Tue, 6 Jan 2026 15:53:38 +0100 Subject: [PATCH] [TASK] Add TYPO3 v14 compatibility --- Configuration/Icons.php | 8 ++++++++ composer.json | 4 ++-- ext_emconf.php | 2 +- ext_localconf.php | 14 ++++++++------ 4 files changed, 19 insertions(+), 9 deletions(-) create mode 100644 Configuration/Icons.php diff --git a/Configuration/Icons.php b/Configuration/Icons.php new file mode 100644 index 0000000..bfe9cb9 --- /dev/null +++ b/Configuration/Icons.php @@ -0,0 +1,8 @@ + [ + 'provider' => \TYPO3\CMS\Core\Imaging\IconProvider\SvgIconProvider::class, + 'source' => 'EXT:cta/Resources/Public/Icons/Cta.svg', + ] +]; diff --git a/composer.json b/composer.json index 2d0f17a..07de89a 100644 --- a/composer.json +++ b/composer.json @@ -9,7 +9,7 @@ } }, "require": { - "typo3/cms-backend": "^10.4 || ^11.0 || ^12.4 || ^13.0", - "typo3/cms-fluid-styled-content": "^10.4 || ^11.0 || ^12.4 || ^13.0" + "typo3/cms-backend": "^10.4 || ^11.0 || ^12.4 || ^13.0 || ^14.0", + "typo3/cms-fluid-styled-content": "^10.4 || ^11.0 || ^12.4 || ^13.0 || ^14.0" } } diff --git a/ext_emconf.php b/ext_emconf.php index 2558022..1f3dfb4 100644 --- a/ext_emconf.php +++ b/ext_emconf.php @@ -12,7 +12,7 @@ 'constraints' => [ 'depends' => [ 'fluid_styled_content' => '*', - 'typo3' => '10.4.0-13.99.99', + 'typo3' => '10.4.0-14.99.99', ] ] ); diff --git a/ext_localconf.php b/ext_localconf.php index 0b57ddc..9211855 100644 --- a/ext_localconf.php +++ b/ext_localconf.php @@ -10,10 +10,12 @@ */ call_user_func(static function () { - $iconRegistry = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\TYPO3\CMS\Core\Imaging\IconRegistry::class); - $iconRegistry->registerIcon( - 'ctype-cta', - \TYPO3\CMS\Core\Imaging\IconProvider\SvgIconProvider::class, - ['source' => 'EXT:cta/Resources/Public/Icons/Cta.svg'] - ); + if ((new \TYPO3\CMS\Core\Information\Typo3Version())->getMajorVersion() < 12) { + $iconRegistry = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\TYPO3\CMS\Core\Imaging\IconRegistry::class); + $iconRegistry->registerIcon( + 'ctype-cta', + \TYPO3\CMS\Core\Imaging\IconProvider\SvgIconProvider::class, + ['source' => 'EXT:cta/Resources/Public/Icons/Cta.svg'] + ); + } });