Skip to content

Commit

Permalink
[BUGFIX] Fix breadcrumb when "breadcrumbExtendedValue" is used
Browse files Browse the repository at this point in the history
fixes: #932
fixes: #690
  • Loading branch information
benjaminkott committed Sep 23, 2021
1 parent 04574fa commit ad45336
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions Resources/Private/Partials/Page/Navigation/Breadcrumb.html
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
<html xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers" data-namespace-typo3-fluid="true">
<f:if condition="{theme.breadcrumb.enable}">
<f:if condition="{breadcrumb}">
<nav class="breadcrumb-section" aria-label="{f:translate(key: 'breadcrumb.label', extensionName: 'bootstrap_package')}">
<div class="container">
<p class="visually-hidden" id="breadcrumb">{f:translate(key: 'breadcrumb', extensionName: 'bootstrap_package')}</p>
<ol class="breadcrumb">
<f:for each="{breadcrumb}" as="item">
<li class="breadcrumb-item{f:if(condition: item.current, then: ' active')}"{f:if(condition: item.current, then: ' aria-current="page"')}>
<f:if condition="{item.current} && {breadcrumbExtendedValue} == ''">
<f:variable name="isCurrent" value="0" />
<f:if condition="{item.current} && {breadcrumbExtendedValue} == ''">
<f:variable name="isCurrent" value="1" />
</f:if>
<li class="breadcrumb-item{f:if(condition: isCurrent, then: ' active')}"{f:if(condition: isCurrent, then: ' aria-current="page"')}>
<f:if condition="{isCurrent}">
<f:then>
<f:render section="BreadcrumbTitle" arguments="{item: item, theme: theme}" />
</f:then>
Expand Down Expand Up @@ -41,4 +44,3 @@
<span class="breadcrumb-text">{item.title}</span>
</span>
</f:section>
</html>

0 comments on commit ad45336

Please sign in to comment.