website-astro/src/components/Header.astro

53 lines
990 B
Plaintext

---
import { t, l } from "astro-i18n";
import Navigation from "../components/Navigation.astro";
---
<header class="region" role="banner">
<a href="#skip-content" class="skip-link"> {t("header.skipLink")}</a>
<a class="logo" href={l("/")} aria-label={t("header.homeLink")}>nardu.in</a>
<Navigation />
</header>
<style>
header {
padding: var(--space-xs-s) 0;
margin: 0 auto var(--space-xs-s) 0;
display: flex;
flex-flow: row wrap;
gap: var(--space-xs-s);
}
header > .logo {
margin-inline-end: auto;
}
a {
text-decoration: none;
}
.skip-link {
position: absolute;
top: 20px;
left: 20px;
height: 1px;
width: 1px;
-webkit-clip: rect(0 0 0 0);
clip: rect(0 0 0 0);
overflow: hidden;
z-index: 99999;
background-color: #fff;
}
.skip-link:focus {
padding: 6px;
-webkit-clip: auto;
clip: auto;
overflow: visible;
width: auto;
height: auto;
}
.logo {
font-size: var(--size-1);
font-weight: bold;
color: var(--darkBlue);
}
</style>