[BUGFIX] Do not render <li> in section menu when CE has no header 97/53697/2
authorTymoteusz Motylewski <t.motylewski@gmail.com>
Mon, 14 Aug 2017 14:14:11 +0000 (16:14 +0200)
committerBenni Mack <benni@typo3.org>
Mon, 14 Aug 2017 18:54:15 +0000 (20:54 +0200)
Section menu is now not rendering empty <li> when CE has no header.

Resolves: #82099
Releases: master, 8.7
Change-Id: I095be0050ac9fa6c4a70ea4d4c942c01def0432f
Reviewed-on: https://review.typo3.org/53697
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Benni Mack <benni@typo3.org>
Tested-by: Benni Mack <benni@typo3.org>
typo3/sysext/fluid_styled_content/Resources/Private/Templates/MenuSection.html

index 93ae6b2..f725a2f 100644 (file)
                                        <f:if condition="{page.content}">
                                                <ul>
                                                        <f:for each="{page.content}" as="element">
+                                                               <f:if condition="{element.data.header}">
                                                                <li>
                                                                        <a href="{page.link}#c{element.data.uid}" target="{page.target}" title="{element.data.header}">
                                                                                <span>{element.data.header}</span>
                                                                        </a>
                                                                </li>
+                                                               </f:if>
                                                        </f:for>
                                                </ul>
                                        </f:if>