Merge pull request #5 from 2kool4idkwhat/main
a11y: add a "skip to main content" link
This commit is contained in:
commit
6f2e7d0c6f
@ -145,3 +145,18 @@ h3.blog-filter {
|
|||||||
cursor: not-allowed;
|
cursor: not-allowed;
|
||||||
opacity: 0.7;
|
opacity: 0.7;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* "skip to main content" link */
|
||||||
|
.skiplink {
|
||||||
|
position: absolute;
|
||||||
|
top: 5;
|
||||||
|
transform: translateY(-600%);
|
||||||
|
transition: transform 0.5s;
|
||||||
|
background-color: #121212;
|
||||||
|
font-size: larger;
|
||||||
|
padding: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.skiplink:focus {
|
||||||
|
transform: translateY(0%);
|
||||||
|
}
|
@ -36,7 +36,7 @@
|
|||||||
<header>
|
<header>
|
||||||
{{- partial "header.html" . -}}
|
{{- partial "header.html" . -}}
|
||||||
</header>
|
</header>
|
||||||
<main>
|
<main id="maincontent">
|
||||||
{{- block "main" . }}{{- end }}
|
{{- block "main" . }}{{- end }}
|
||||||
</main>
|
</main>
|
||||||
<footer>
|
<footer>
|
||||||
|
@ -1,2 +1,4 @@
|
|||||||
|
<a class="skiplink" href="#maincontent">Skip to Main Content</a>
|
||||||
|
|
||||||
<a href="{{ relURL .Site.Home.Permalink }}" class="title"><h1>{{ .Site.Title }}</h1></a>
|
<a href="{{ relURL .Site.Home.Permalink }}" class="title"><h1>{{ .Site.Title }}</h1></a>
|
||||||
<nav>{{- partial "nav.html" . -}}</nav>
|
<nav>{{- partial "nav.html" . -}}</nav>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user