From 537d0d495b9baa33be3e9a9f849e54457ff44674 Mon Sep 17 00:00:00 2001 From: Arnaud Levy <contact@arnaudlevy.com> Date: Mon, 3 Oct 2022 12:00:11 +0200 Subject: [PATCH] fix breadcrumb --- layouts/partials/header/breadcrumbs.html | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/layouts/partials/header/breadcrumbs.html b/layouts/partials/header/breadcrumbs.html index 6f4c83b5..b1822704 100644 --- a/layouts/partials/header/breadcrumbs.html +++ b/layouts/partials/header/breadcrumbs.html @@ -47,18 +47,14 @@ {{- end -}} {{- $title = chomp $title }} <li itemprop="itemListElement" itemscope itemtype="https://schema.org/ListItem" class="breadcrumb-item{{- if .active }} active{{ end }}"{{- if .active }} aria-current="page"{{ end }}> - {{ if .active -}} - <span itemprop="item"> - {{- else -}} + {{ if not .active -}} <a itemprop="item" href="{{ .page.Permalink }}"> {{- end }} <span itemprop="name">{{- partial "PrepareHTML" $title -}}</span> - <meta itemprop="position" content="{{- .position -}}"> - {{ if .active -}} - </span> - {{- else -}} - </a> + {{ if not .active -}} + </a> {{- end }} + <meta itemprop="position" content="{{- .position -}}"> </li> {{- end -}} {{- end -}} \ No newline at end of file -- GitLab