7
0
Fork 0

Fix: w3c-validator, A-tag mag niet binnen BUTTON-tag

This commit is contained in:
Michael Boelen 2023-05-21 16:21:00 +02:00
parent 7ec53dcda4
commit aca9654527
2 changed files with 21 additions and 13 deletions

View file

@ -80,9 +80,9 @@ ul.menu li {
}
ul.menu li button {
font-size: inherit;
font-family: inherit;
font-weight: bold;
//font-size: inherit;
//font-family: inherit;
//font-weight: bold;
border: none;
background-color: transparent;
cursor: pointer;
@ -92,11 +92,14 @@ ul.menu li button {
ul.menu li a {
display: block;
color: inherit;
font-size: inherit;
font-family: inherit;
font-weight: 600;
text-decoration: none;
}
ul.menu li a, ul li button {
padding: 0.7rem 0.5rem;
padding: 0.7rem 0.8rem;
text-align: left;
}
@ -205,8 +208,8 @@ li:focus-within > button > .arrow {
// height: 135px;
height: auto;
}
ul.menu li:hover > button > .arrow {
transform: rotate(-225deg);
margin-top: 4px;
}
//ul.menu li:hover > button > .arrow {
// transform: rotate(-225deg);
// margin-top: 4px;
//}
}

View file

@ -19,9 +19,8 @@
{{ $.Scratch.Set "counter" (add ($.Scratch.Get "counter") 1) }}
{{ if .Children }}
<li>
<button type="button" aria-haspopup="true" aria-expanded="true" aria-controls="dropdown-{{ $.Scratch.Get "counter" }}">
<a href="{{ .URL }}">{{ .Name }}</a>
</button>
<button type="button" aria-haspopup="true" aria-expanded="true" aria-controls="dropdown-{{ $.Scratch.Get "counter" }}"></button>
<a href="{{ .URL }}">{{ .Name }}</a>
<ul class="dropdown" id="dropdown-{{ $.Scratch.Get "counter" }}">
{{ range .Children }}
<li><a href="{{ .URL }}">{{ .Name }}</a></li>
@ -29,10 +28,16 @@
</ul>
</li>
{{ else }}
<li><button type="button" aria-haspopup="true" aria-expanded="true"><a href="{{ .URL }}">{{ .Name }}</a></button></li>
<li>
<button type="button" aria-haspopup="true" aria-expanded="true"></button>
<a href="{{ .URL }}">{{ .Name }}</a>
</li>
{{ end }}
{{ end }}
<li><button type="button" aria-haspopup="false" aria-expanded="true"><a href="{{ relLangURL "/zoeken/"}}">{{ partial "show-svg-icon.html" (dict "context" . "icon" "magnifying-glass" "class" "shownormal") }}</a></button></li>
<li>
<button type="button" aria-haspopup="false" aria-expanded="true"></button>
<a href="{{ relLangURL "/zoeken/"}}">{{ partial "show-svg-icon.html" (dict "context" . "icon" "magnifying-glass" "class" "shownormal") }}</a>
</li>
</ul>
</nav>
</div>