aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaio Lente <7017340+clente@users.noreply.github.com>2023-09-29 19:57:55 -0300
committerCaio Lente <7017340+clente@users.noreply.github.com>2023-09-29 19:57:55 -0300
commit6f981964e0ec959fb34fd365b3e29988cc51e062 (patch)
treee93f15abd482cde390ca18742486c176d940c826
parent64583d8a0a1ad7c76d49e93922c75b6de3dc5133 (diff)
downloadhugo-bearcub-6f981964e0ec959fb34fd365b3e29988cc51e062.tar.gz
hugo-bearcub-6f981964e0ec959fb34fd365b3e29988cc51e062.tar.bz2
Add i18n to skiplink
-rw-r--r--.gitignore3
-rw-r--r--assets/style.css11
-rw-r--r--i18n/en.toml5
-rw-r--r--i18n/pt.toml5
-rw-r--r--layouts/_default/baseof.html2
-rw-r--r--layouts/partials/header.html2
6 files changed, 17 insertions, 11 deletions
diff --git a/.gitignore b/.gitignore
index 6274ee4..305d231 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,3 +1,4 @@
.hugo_build.lock
.DS_Store
-resources/ \ No newline at end of file
+resources/
+todo.md \ No newline at end of file
diff --git a/assets/style.css b/assets/style.css
index c36c7e1..afa00b3 100644
--- a/assets/style.css
+++ b/assets/style.css
@@ -146,17 +146,16 @@ h3.blog-filter {
opacity: 0.7;
}
-/* "skip to main content" link */
-.skiplink {
+/* "Skip to main content" link */
+.skip-link {
position: absolute;
top: 5;
transform: translateY(-600%);
transition: transform 0.5s;
- background-color: #121212;
- font-size: larger;
+ background-color: #1d1f27;
padding: 6px;
}
-.skiplink:focus {
+.skip-link:focus {
transform: translateY(0%);
-} \ No newline at end of file
+}
diff --git a/i18n/en.toml b/i18n/en.toml
index 1a89360..b7738dd 100644
--- a/i18n/en.toml
+++ b/i18n/en.toml
@@ -5,4 +5,7 @@
other = "No posts yet"
[email-subject]
- other = "Reply to " \ No newline at end of file
+ other = "Reply to "
+
+[skip-link]
+ other = "Skip to main content" \ No newline at end of file
diff --git a/i18n/pt.toml b/i18n/pt.toml
index a139b0f..33fc65f 100644
--- a/i18n/pt.toml
+++ b/i18n/pt.toml
@@ -5,4 +5,7 @@
other = "Nenhum post ainda"
[email-subject]
- other = "Resposta a " \ No newline at end of file
+ other = "Resposta a "
+
+[skip-link]
+ other = "Pular para conteúdo principal" \ No newline at end of file
diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html
index 06d71c3..fdfa47c 100644
--- a/layouts/_default/baseof.html
+++ b/layouts/_default/baseof.html
@@ -36,7 +36,7 @@
<header>
{{- partial "header.html" . -}}
</header>
- <main id="maincontent">
+ <main id="main-content">
{{- block "main" . }}{{- end }}
</main>
<footer>
diff --git a/layouts/partials/header.html b/layouts/partials/header.html
index 1db41b2..5a66907 100644
--- a/layouts/partials/header.html
+++ b/layouts/partials/header.html
@@ -1,4 +1,4 @@
-<a class="skiplink" href="#maincontent">Skip to Main Content</a>
+<a class="skip-link" href="#main-content">{{ i18n "skip-link" }}</a>
<a href="{{ relURL .Site.Home.Permalink }}" class="title"><h1>{{ .Site.Title }}</h1></a>
<nav>{{- partial "nav.html" . -}}</nav>