nav: add a Learn tab pointing at the teaching site, and drop the scroll-spy underline - tracking the active section as you scrolled read as clunky, so the underline is hover-only now; also refresh the public CV
build-and-deploy / build (push) Failing after 15m10s

This commit is contained in:
2026-08-18 10:05:49 +10:00
parent f6b683713e
commit 21616762e6
3 changed files with 19 additions and 67 deletions
+16 -12
View File
@@ -2,16 +2,15 @@
import ThemeToggle from "./ThemeToggle.astro";
import { site } from "../data/site";
// `id` ties a nav link to a homepage section so the Motion layer animates its
// underline as that section scrolls through (scroll-spy). Projects/Blog navigate
// to their own pages on click, but on the homepage they track the #projects and
// #writing sections so every nav item gets the underline - in both directions.
// Plain links. Hover shows the underline; there is no scroll-spy - tracking the
// active section as you scrolled read as clunky, so the underline is hover-only.
const links = [
{ label: "About", href: "/#about", id: "about" },
{ label: "Skills", href: "/#skills", id: "skills" },
{ label: "Projects", href: "/projects/", id: "projects" },
{ label: "Blog", href: "/blog/", id: "writing" },
{ label: "Contact", href: "/#contact", id: "contact" },
{ label: "About", href: "/#about" },
{ label: "Skills", href: "/#skills" },
{ label: "Projects", href: "/projects/" },
{ label: "Blog", href: "/blog/" },
{ label: "Contact", href: "/#contact" },
{ label: "Learn", href: "https://learn.bztmon.com", external: true },
];
---
@@ -23,7 +22,11 @@ const links = [
<nav class="nav__links" aria-label="Primary">
{links.map((l) => (
<a href={l.href} data-nav-id={l.id}>
<a
href={l.href}
target={l.external ? "_blank" : undefined}
rel={l.external ? "noopener noreferrer" : undefined}
>
{l.label}<span class="nav__ul" aria-hidden="true"></span>
</a>
))}
@@ -95,8 +98,9 @@ const links = [
color: var(--text);
text-decoration: none;
}
/* Active-section / hover underline - scaleX scrubbed by the Motion layer
(spring). transform-origin left so it grows from the start of the label. */
/* Hover underline - scaleX sprung by the Motion layer, growing from the
start of the label. No scroll-spy: it tracked the active section as you
scrolled, which read as clunky on a page this short. */
.nav__ul {
position: absolute;
left: 0;