diff --git a/public/typo3conf/ext/ep_events/Configuration/TCA/Overrides/tt_content_element_ytvideo.php b/public/typo3conf/ext/ep_events/Configuration/TCA/Overrides/tt_content_element_ytvideo.php new file mode 100644 index 00000000..bacae9a8 --- /dev/null +++ b/public/typo3conf/ext/ep_events/Configuration/TCA/Overrides/tt_content_element_ytvideo.php @@ -0,0 +1,38 @@ + ' + --palette--;' . $frontendLanguageFilePrefix . 'palette.general;general, + layout, header_link, + --div--;' . $frontendLanguageFilePrefix . 'tabs.access, + hidden;' . $frontendLanguageFilePrefix . 'field.default.hidden, + --div--;' . $frontendLanguageFilePrefix . 'tabs.extended + ', + 'columnsOverrides' => [ + 'header_link' => [ + 'label' => 'YouTube URL/Vimeo ID', + ], + 'layout' => [ + 'label' => 'Typ', + ], + ], + ]; + +}); diff --git a/public/typo3conf/ext/ep_events/Configuration/TSconfig/Page/TCEFORM.tsconfig b/public/typo3conf/ext/ep_events/Configuration/TSconfig/Page/TCEFORM.tsconfig index 3ccb5922..14859934 100644 --- a/public/typo3conf/ext/ep_events/Configuration/TSconfig/Page/TCEFORM.tsconfig +++ b/public/typo3conf/ext/ep_events/Configuration/TSconfig/Page/TCEFORM.tsconfig @@ -68,6 +68,14 @@ TCEFORM { removeItems = 2,3 } + layout.types.ep_events_ytvideo { + removeItems := addToList(2,3) + altLabels { + 0 = YouTube + 1 = Vimeo + } + } + header_layout { addItems { 10 = H1 (Icon, opt. Subheadline) diff --git a/public/typo3conf/ext/ep_events/Configuration/TSconfig/Page/Wizards/NewContentElement.tsconfig b/public/typo3conf/ext/ep_events/Configuration/TSconfig/Page/Wizards/NewContentElement.tsconfig index 211f2d96..0d7e0b7d 100644 --- a/public/typo3conf/ext/ep_events/Configuration/TSconfig/Page/Wizards/NewContentElement.tsconfig +++ b/public/typo3conf/ext/ep_events/Configuration/TSconfig/Page/Wizards/NewContentElement.tsconfig @@ -31,8 +31,14 @@ mod { description = Banner für Kategorieseiten tt_content_defValues.CType = banner } + ep_events_ytvideo { + iconIdentifier = content-image + title = YouTube/Vimeo Video + description = Responsiv eingebettetes Video + tt_content_defValues.CType = ep_events_ytvideo + } } - show := addToList(tile, statement, herounit, banner) + show := addToList(tile, statement, herounit, banner, ep_events_ytvideo) } } } diff --git a/public/typo3conf/ext/ep_events/Configuration/TypoScript/ContentElements/ep_events_ytvideo.typoscript b/public/typo3conf/ext/ep_events/Configuration/TypoScript/ContentElements/ep_events_ytvideo.typoscript new file mode 100644 index 00000000..88a349ec --- /dev/null +++ b/public/typo3conf/ext/ep_events/Configuration/TypoScript/ContentElements/ep_events_ytvideo.typoscript @@ -0,0 +1,4 @@ +tt_content.ep_events_ytvideo =< lib.contentElement +tt_content.ep_events_ytvideo { + templateName = YoutubeVideo +} diff --git a/public/typo3conf/ext/ep_events/Resources/Private/Assets/scss/_video.scss b/public/typo3conf/ext/ep_events/Resources/Private/Assets/scss/_video.scss new file mode 100644 index 00000000..9291bf07 --- /dev/null +++ b/public/typo3conf/ext/ep_events/Resources/Private/Assets/scss/_video.scss @@ -0,0 +1,30 @@ +.video { + @include container(); + padding-top: 32px; + padding-bottom: 32px; +} + +.video__inner { + position: relative; + width: 100%; + height: 0; + padding-bottom: 56.25%; + background-position: center; + background-size: cover; + + iframe { + position: absolute; + width: 100%; + height: 100%; + left: 0; + top: 0; + border: none; + } + + .consent { + position: absolute; + top: 50%; + left: 50%; + transform: translate(-50%, -50%); + } +} diff --git a/public/typo3conf/ext/ep_events/Resources/Private/Assets/scss/main.scss b/public/typo3conf/ext/ep_events/Resources/Private/Assets/scss/main.scss index 3c922f62..0959bd98 100644 --- a/public/typo3conf/ext/ep_events/Resources/Private/Assets/scss/main.scss +++ b/public/typo3conf/ext/ep_events/Resources/Private/Assets/scss/main.scss @@ -36,3 +36,4 @@ @import "news"; @import "datepicker"; @import "cookiefirst"; +@import "video"; diff --git a/public/typo3conf/ext/ep_events/Resources/Private/Templates/FluidStyledContent/YoutubeVideo.html b/public/typo3conf/ext/ep_events/Resources/Private/Templates/FluidStyledContent/YoutubeVideo.html new file mode 100644 index 00000000..fed248f7 --- /dev/null +++ b/public/typo3conf/ext/ep_events/Resources/Private/Templates/FluidStyledContent/YoutubeVideo.html @@ -0,0 +1,24 @@ + + + + + + + + + + + Bitte Marketing-Cookies akzeptieren, um dieses Video anzusehen. + + + + + + +