feat: complete ANL lab web application with lossless data migration and SSG routes

This commit is contained in:
2026-07-30 10:34:22 +09:00
parent 293431c1e8
commit ea26ef503e
23 changed files with 5326 additions and 882 deletions
@@ -0,0 +1,45 @@
import React from "react";
import Link from "next/link";
import { PUB_CATEGORIES } from "../../../content/categories";
import { PubCategory } from "../../../content/types";
interface CategoryNavProps {
currentCategory?: PubCategory;
totalCount?: number;
}
export function CategoryNav({ currentCategory, totalCount }: CategoryNavProps) {
return (
<div className="space-y-4">
<div className="flex flex-wrap items-center gap-2 border-b border-line pb-4">
<Link
href="/publications"
className={`px-4 py-2 rounded text-xs font-mono tracking-wider transition-colors ${
!currentCategory
? "bg-ink text-ivory font-bold"
: "bg-paper text-ink border border-line hover:border-ink"
}`}
>
All Overview {!currentCategory && totalCount ? `(${totalCount})` : ""}
</Link>
{PUB_CATEGORIES.map((cat) => {
const isActive = currentCategory === cat.slug;
return (
<Link
key={cat.slug}
href={`/publications/${cat.slug}`}
className={`px-4 py-2 rounded text-xs font-mono tracking-wider transition-colors ${
isActive
? "bg-vermillion text-ivory font-bold"
: "bg-paper text-ink border border-line hover:border-vermillion"
}`}
>
{cat.label}
</Link>
);
})}
</div>
</div>
);
}