-
Notifications
You must be signed in to change notification settings - Fork 0
/
ext_localconf.php
43 lines (38 loc) · 1.46 KB
/
ext_localconf.php
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
<?php
declare(strict_types=1);
use Sitegeist\MediaComponents\Interfaces\ConstructibleFromArea;
use Sitegeist\MediaComponents\Interfaces\ConstructibleFromFloat;
use Sitegeist\MediaComponents\Interfaces\ConstructibleFromImage;
use SMS\FluidComponents\Domain\Model\Image;
use SMS\FluidComponents\Utility\ComponentArgumentConverter;
use TYPO3\CMS\Core\Imaging\ImageManipulation\Area;
use TYPO3\CMS\Core\Utility\ExtensionManagementUtility;
use TYPO3\CMS\Core\Utility\GeneralUtility;
defined('TYPO3') or die();
$GLOBALS['TYPO3_CONF_VARS']['SYS']['fluid']['namespaces']['fc'] ??= [];
$GLOBALS['TYPO3_CONF_VARS']['SYS']['fluid']['namespaces']['fc'][] = 'Sitegeist\\MediaComponents\\Components';
$GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['fluid_components']['namespaces']['Sitegeist\\MediaComponents\\Components'] =
ExtensionManagementUtility::extPath('media_components', 'Resources/Private/Components');
$componentArgumentConverter = GeneralUtility::makeInstance(
ComponentArgumentConverter::class
);
$componentArgumentConverter->addConversionInterface(
'float',
ConstructibleFromFloat::class,
'fromFloat'
);
$componentArgumentConverter->addConversionInterface(
'double',
ConstructibleFromFloat::class,
'fromFloat'
);
$componentArgumentConverter->addConversionInterface(
Area::class,
ConstructibleFromArea::class,
'fromArea'
);
$componentArgumentConverter->addConversionInterface(
Image::class,
ConstructibleFromImage::class,
'fromImage'
);