forked from brotkrueml/schema
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathext_tables.php
More file actions
29 lines (26 loc) · 1.02 KB
/
ext_tables.php
File metadata and controls
29 lines (26 loc) · 1.02 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
<?php
defined('TYPO3') or die();
(static function () {
// Since TYPO3 v11.4 icons can be registered in Configuration/Icons.php
if ((new TYPO3\CMS\Core\Information\Typo3Version())->getMajorVersion() > 10) {
return;
}
if (!TYPO3\CMS\Core\Utility\ExtensionManagementUtility::isLoaded('adminpanel')) {
return;
}
/** @var \TYPO3\CMS\Core\Imaging\IconRegistry $iconRegistry */
$iconRegistry = TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(TYPO3\CMS\Core\Imaging\IconRegistry::class);
foreach (['documentation-google', 'documentation-schema', 'documentation-yandex', 'module-adminpanel'] as $icon) {
$iconRegistry->registerIcon(
'ext-schema-' . $icon,
TYPO3\CMS\Core\Imaging\IconProvider\SvgIconProvider::class,
[
'source' => sprintf(
'EXT:%s/Resources/Public/Icons/%s.svg',
Brotkrueml\Schema\Extension::KEY,
$icon
),
]
);
}
})();