Commit 53e06bde authored by Stefan Busemann's avatar Stefan Busemann
Browse files

Merge branch '653-show-crop-information-for-slider-items' into 'main'

Resolve "Show crop information for slider items"

Closes #653

See merge request !609
parents 54c16a66 aed9dc3d
<?php
$GLOBALS['TCA']['sys_file_reference']['palettes']['sliderImageOverlayPalette'] = [
'showitem' => 'title,alternative,--linebreak--,description,--linebreak--,crop'
];
return [
'ctrl' => [
'label' => 'header',
......@@ -47,63 +52,6 @@ return [
--palette--;LLL:EXT:frontend/Resources/Private/Language/locallang_ttc.xlf:palette.visibility;visibility,
--palette--;LLL:EXT:frontend/Resources/Private/Language/locallang_ttc.xlf:palette.access;access,
',
'columnsOverrides' => [
'media' => [
'config' => [
'maxitems' => '1',
'overrideChildTca' => [
'columns' => [
'crop' => [
'config' => [
'cropVariants' => [
'default' => [
'disabled' => true,
],
'desktopslider' => [
'title' => 'Desktop',
'allowedAspectRatios' => [
'1700:500' => [
'title' => '1700:500',
'value' => 1700 / 500
],
],
'selectedRatio' => '1700:500',
],
'tablet' => [
'disabled' => true,
],
'tabletslider' => [
'title' => 'Tablet',
'allowedAspectRatios' => [
'1200:500' => [
'title' => '1200:500',
'value' => 1200 / 500
],
],
'selectedRatio' => '1700:500',
],
'mobile' => [
'disabled' => true,
],
'mobileslider' => [
'title' => 'Mobile',
'allowedAspectRatios' => [
'4:3' => [
'title' => '4:3',
'value' => 4 / 3
],
],
'selectedRatio' => '1700:500',
],
],
],
],
],
],
],
],
],
],
],
'palettes' => [
......@@ -213,14 +161,6 @@ return [
'eval' => 'trim,required'
],
],
'showcontent' => [
'exclude' => 0,
'label' => 'Hide the Headline on the slide',
'config' => [
'type' => 'check',
],
],
'showcontent' => [
'exclude' => 1,
'label' => 'Content view:',
......@@ -276,40 +216,68 @@ return [
'config' => \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getFileFieldTCAConfig(
'media',
[
'foreign_types' => [
'0' => [
'showitem' => '
--palette--;LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;basicoverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_TEXT => [
'showitem' => '
--palette--;LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;basicoverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_IMAGE => [
'showitem' => '
--palette--;LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;imageoverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_AUDIO => [
'showitem' => '
--palette--;LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.audioOverlayPalette;audioOverlayPalette,
--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_VIDEO => [
'showitem' => '
--palette--;LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.videoOverlayPalette;videoOverlayPalette,
--palette--;;filePalette'
'overrideChildTca' => [
'types' => [
'0' => [
'showitem' => '--palette--;;basicoverlayPalette,--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_IMAGE => [
'showitem' => '--palette--;;sliderImageOverlayPalette,--palette--;;filePalette'
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_VIDEO => [
'showitem' => '--palette--;;videoOverlayPalette,--palette--;;filePalette'
],
],
\TYPO3\CMS\Core\Resource\File::FILETYPE_APPLICATION => [
'showitem' => '
--palette--;LLL:EXT:core/Resources/Private/Language/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;basicoverlayPalette,
--palette--;;filePalette'
'columns' => [
'crop' => [
'config' => [
'cropVariants' => [
'default' => [
'disabled' => true,
],
'desktopslider' => [
'title' => 'Desktop',
'allowedAspectRatios' => [
'1700:500' => [
'title' => '1700:500',
'value' => 1700 / 500
],
],
'selectedRatio' => '1700:500',
],
'tablet' => [
'disabled' => true,
],
'tabletslider' => [
'title' => 'Tablet',
'allowedAspectRatios' => [
'1200:500' => [
'title' => '1200:500',
'value' => 1200 / 500
],
],
'selectedRatio' => '1700:500',
],
'mobile' => [
'disabled' => true,
],
'mobileslider' => [
'title' => 'Mobile',
'allowedAspectRatios' => [
'4:3' => [
'title' => '4:3',
'value' => 4 / 3
],
],
'selectedRatio' => '1700:500',
],
],
]
]
]
]
]
)
],
'maxitems' => 1,
])
],
],
];
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment