diff --git a/Configuration/user.tsconfig b/Configuration/user.tsconfig new file mode 100644 index 00000000..51f149c6 --- /dev/null +++ b/Configuration/user.tsconfig @@ -0,0 +1,3 @@ +# Allow backend users to drag and drop the new page type: +# 137 = T3G\AgencyPack\Blog\Constants::DOKTYPE_BLOG_POST +options.pageTree.doktypesToShowInNewPageDragArea := addToList(137) diff --git a/ext_tables.php b/ext_tables.php index 7aa2f8e1..a7016853 100644 --- a/ext_tables.php +++ b/ext_tables.php @@ -10,6 +10,7 @@ use T3G\AgencyPack\Blog\Constants; use TYPO3\CMS\Core\Imaging\IconProvider\SvgIconProvider; use TYPO3\CMS\Core\Imaging\IconRegistry; +use TYPO3\CMS\Core\Information\Typo3Version; use TYPO3\CMS\Core\Utility\ExtensionManagementUtility; use TYPO3\CMS\Core\Utility\GeneralUtility; @@ -63,7 +64,9 @@ $iconRegistry->registerIcon($identifier, SvgIconProvider::class, ['source' => $path]); } -// Allow backend users to drag and drop the new page type: -ExtensionManagementUtility::addUserTSConfig(' - options.pageTree.doktypesToShowInNewPageDragArea := addToList(' . Constants::DOKTYPE_BLOG_POST . ') -'); +// Replaced with Configuration/user.tsconfig in v13 +if ((new Typo3Version())->getMajorVersion() < 13) { + ExtensionManagementUtility::addUserTSConfig(' + options.pageTree.doktypesToShowInNewPageDragArea := addToList(' . Constants::DOKTYPE_BLOG_POST . ') + '); +}