diff --git a/Configuration/PageTSconfig/Mod/Wizards/0_NewContentElement.tsconfig b/Configuration/PageTSconfig/Mod/Wizards/0_NewContentElement.tsconfig index e373d7e..188cf4e 100644 --- a/Configuration/PageTSconfig/Mod/Wizards/0_NewContentElement.tsconfig +++ b/Configuration/PageTSconfig/Mod/Wizards/0_NewContentElement.tsconfig @@ -12,7 +12,7 @@ mod.wizards.newContentElement.wizardItems { } } menu { - show = menu_abstract + show = menu_abstract, menu_subpages } special { show = @@ -26,6 +26,6 @@ mod.wizards.newContentElement.wizardItems { } TCEFORM.tt_content { CType { - keepItems := addToList(text, image, menu_abstract) + keepItems := addToList(text, image, menu_abstract, menu_subpages) } } diff --git a/Configuration/TypoScript/Setup/ContentElements/MenuSubpages.typoscript b/Configuration/TypoScript/Setup/ContentElements/MenuSubpages.typoscript new file mode 100644 index 0000000..84b158a --- /dev/null +++ b/Configuration/TypoScript/Setup/ContentElements/MenuSubpages.typoscript @@ -0,0 +1,16 @@ +tt_content.menu_subpages =< lib.contentElement +tt_content.menu_subpages { + templateName = MenuSubpages + dataProcessing { + 10 = TYPO3\CMS\Frontend\DataProcessing\MenuProcessor + 10 { + special = directory + special.value.field = pages + levels = 3 + } + } + + stdWrap { + editIcons := appendString(header, header_layout, pages, layout) + } +} diff --git a/Resources/Private/Partials/Menu/BlogPostAbstract.html b/Resources/Private/Partials/Menu/BlogPostAbstract.html new file mode 100644 index 0000000..693d41c --- /dev/null +++ b/Resources/Private/Partials/Menu/BlogPostAbstract.html @@ -0,0 +1,19 @@ + +
+ {f:render(partial: 'BlogPostHeader', arguments: { + link: page.link, + title: page.title, + blogPost : page.data, + compatibleWith: page.compatibleWith, + topics: page.topics + })} + +
+ {page.data.abstract -> f:format.html(parseFuncTSPath: 'lib.parseFunc_abstract')} +
+ + +
+ diff --git a/Resources/Private/Partials/Menu/Page.html b/Resources/Private/Partials/Menu/Page.html index 693d41c..d3a09a9 100644 --- a/Resources/Private/Partials/Menu/Page.html +++ b/Resources/Private/Partials/Menu/Page.html @@ -1,19 +1,11 @@ -
- {f:render(partial: 'BlogPostHeader', arguments: { - link: page.link, - title: page.title, - blogPost : page.data, - compatibleWith: page.compatibleWith, - topics: page.topics - })} +
  • + {page.title} -
    - {page.data.abstract -> f:format.html(parseFuncTSPath: 'lib.parseFunc_abstract')} -
    + {page.data.abstract -> f:format.html(parseFuncTSPath: 'lib.parseFunc_abstract')} - -
  • + + {f:render(partial: 'Menu/Pages', arguments: {pages: page.children})} + + diff --git a/Resources/Private/Partials/Menu/Pages.html b/Resources/Private/Partials/Menu/Pages.html new file mode 100644 index 0000000..0fd3854 --- /dev/null +++ b/Resources/Private/Partials/Menu/Pages.html @@ -0,0 +1,10 @@ + + +
      + + {f:render(partial: 'Menu/Page', arguments: {page: page})} + +
    + + diff --git a/Resources/Private/Templates/ContentElements/MenuAbstract.html b/Resources/Private/Templates/ContentElements/MenuAbstract.html index 44f338b..053b744 100644 --- a/Resources/Private/Templates/ContentElements/MenuAbstract.html +++ b/Resources/Private/Templates/ContentElements/MenuAbstract.html @@ -13,7 +13,7 @@ - {f:render(partial: 'Menu/Page', arguments: {page: page})} + {f:render(partial: 'Menu/BlogPostAbstract', arguments: {page: page})} diff --git a/Resources/Private/Templates/ContentElements/MenuSubpages.html b/Resources/Private/Templates/ContentElements/MenuSubpages.html new file mode 100644 index 0000000..9c9006b --- /dev/null +++ b/Resources/Private/Templates/ContentElements/MenuSubpages.html @@ -0,0 +1,17 @@ + + + {f:layout(name: 'Default')} + + + {f:render(partial: 'Header', arguments: { + uid: data.uid, + layout: headerLayout, + header: '{data.header} {topic.0.data.title}' + })} + + + + {f:render(partial: 'Menu/Pages', arguments: {pages: menu})} + +