Files
blitzkit/packages/website-ue/src/components/Navbar.astro
T

76 lines
1.5 KiB
Plaintext
Raw Normal View History

2026-01-12 13:46:58 -06:00
---
import { HamburgerMenuIcon, MagnifyingGlassIcon } from "@radix-ui/react-icons";
import { BlitzKitIcon } from "../icons/BlitzKit";
2026-01-13 20:33:14 -06:00
import { LinkI18n } from "./LinkI18n";
interface Props {
locale: string;
}
const { locale } = Astro.props;
2026-01-12 13:46:58 -06:00
---
<style>
.navbar {
position: sticky;
top: 0;
2026-01-13 20:33:14 -06:00
left: 0;
2026-01-12 13:46:58 -06:00
display: flex;
2026-01-13 20:33:14 -06:00
justify-content: center;
2026-01-12 13:46:58 -06:00
z-index: 1;
2026-01-14 13:30:12 -06:00
backdrop-filter: var(--blur-glass) brightness(25%);
box-shadow: var(--shadow-subtle);
2026-01-13 20:33:14 -06:00
.content {
flex: 1;
max-width: calc(var(--page-width) + 2 * var(--space-4));
2026-01-12 13:46:58 -06:00
display: flex;
2026-01-13 20:33:14 -06:00
align-items: center;
justify-content: space-between;
2026-01-12 13:46:58 -06:00
2026-01-13 20:33:14 -06:00
.side {
2026-01-12 13:46:58 -06:00
display: flex;
2026-01-13 20:33:14 -06:00
.action {
padding: var(--space-4);
cursor: pointer;
color: var(--color-regular);
&:focus {
outline: var(--outline-focus);
}
.icon {
width: 1.25em;
height: 1.25em;
vertical-align: top;
}
2026-01-12 13:46:58 -06:00
}
}
}
}
</style>
<div class="navbar">
2026-01-13 20:33:14 -06:00
<div class="content">
<div class="side">
2026-01-13 20:49:40 -06:00
<LinkI18n {locale} href="/" className="action" tabIndex={0}>
2026-01-13 20:33:14 -06:00
<BlitzKitIcon className="icon" />
</LinkI18n>
2026-01-12 13:46:58 -06:00
</div>
2026-01-13 20:33:14 -06:00
<div class="side">
<div class="action" tabindex="0">
<MagnifyingGlassIcon className="icon" />
</div>
<div class="action" tabindex="0">
<HamburgerMenuIcon className="icon" />
</div>
2026-01-12 13:46:58 -06:00
</div>
</div>
</div>