Make use of aria-current as selector and remove use of active class.

This commit is contained in:
Fredrik Jonsson 2023-05-30 08:57:59 +02:00
commit 93728f1e9e

View file

@ -4,10 +4,10 @@
<aside class="sidebar layout__second-sidebar">
{{ range site.Sections -}}
<section class="menu">
<p class="title"><strong><a href="{{ .RelPermalink }}"{{ if eq $currentSection .Section }} class="active" aria-current="page"{{ end }}>{{ .Title }}</a></strong></p>
<p class="title"><strong><a href="{{ .RelPermalink }}"{{ if eq $currentSection .Section }} aria-current="page"{{ end }}>{{ .Title }}</a></strong></p>
<ul>
{{ range .Pages -}}
<li><a href="{{ .RelPermalink }}"{{ if eq $currentID .File.UniqueID }} class="active" aria-current="page"{{ end }}>{{ .Title }}</a></li>
<li><a href="{{ .RelPermalink }}"{{ if eq $currentID .File.UniqueID }} aria-current="page"{{ end }}>{{ .Title }}</a></li>
{{ end -}}
</ul>
</section>