feat: Demoted nav brand to span, promoted page headings to h1, added sk…

- "frontend/src/App.tsx"
- "frontend/src/App.css"
- "frontend/src/pages/Home.tsx"
- "frontend/src/pages/SearchResults.tsx"
- "frontend/src/pages/TopicsBrowse.tsx"
- "frontend/src/pages/CreatorsBrowse.tsx"
- "frontend/src/pages/SubTopicPage.tsx"
- "frontend/src/pages/AdminReports.tsx"

GSD-Task: S04/T01
This commit is contained in:
jlightner 2026-03-31 08:52:48 +00:00
parent 85712c15eb
commit 6845f5c349
9 changed files with 52 additions and 16 deletions

View file

@ -13,7 +13,7 @@
/* Text */ /* Text */
--color-text-primary: #e2e2ea; --color-text-primary: #e2e2ea;
--color-text-secondary: #8b8b9a; --color-text-secondary: #8b8b9a;
--color-text-muted: #6b6b7a; --color-text-muted: #828291;
--color-text-active: #e2e2ea; --color-text-active: #e2e2ea;
--color-text-on-header: rgba(255, 255, 255, 0.8); --color-text-on-header: rgba(255, 255, 255, 0.8);
--color-text-on-header-hover: #fff; --color-text-on-header-hover: #fff;
@ -155,6 +155,20 @@ body {
background: var(--color-bg-page); background: var(--color-bg-page);
} }
/* ── Utility ──────────────────────────────────────────────────────────────── */
.sr-only {
position: absolute;
width: 1px;
height: 1px;
padding: 0;
margin: -1px;
overflow: hidden;
clip: rect(0, 0, 0, 0);
white-space: nowrap;
border: 0;
}
/* ── App shell ────────────────────────────────────────────────────────────── */ /* ── App shell ────────────────────────────────────────────────────────────── */
.app { .app {
@ -163,6 +177,26 @@ body {
min-height: 100vh; min-height: 100vh;
} }
/* ── Skip-to-content link ─────────────────────────────────────────────────── */
.skip-link {
position: absolute;
left: -9999px;
top: 0;
z-index: 999;
padding: 0.5rem 1rem;
background: var(--color-accent);
color: var(--color-bg-page);
font-size: 0.875rem;
font-weight: 600;
text-decoration: none;
border-radius: 0 0 0.375rem 0;
}
.skip-link:focus {
left: 0;
}
.app-header { .app-header {
display: flex; display: flex;
align-items: center; align-items: center;
@ -172,7 +206,7 @@ body {
color: var(--color-text-on-header-hover); color: var(--color-text-on-header-hover);
} }
.app-header h1 { .app-header__brand span {
font-size: 1.125rem; font-size: 1.125rem;
font-weight: 600; font-weight: 600;
letter-spacing: -0.01em; letter-spacing: -0.01em;

View file

@ -58,9 +58,10 @@ export default function App() {
return ( return (
<div className="app"> <div className="app">
<a href="#main-content" className="skip-link">Skip to content</a>
<header className="app-header" ref={headerRef}> <header className="app-header" ref={headerRef}>
<Link to="/" className="app-header__brand"> <Link to="/" className="app-header__brand">
<h1>Chrysopedia</h1> <span>Chrysopedia</span>
</Link> </Link>
{showNavSearch && ( {showNavSearch && (
<SearchAutocomplete <SearchAutocomplete
@ -111,7 +112,7 @@ export default function App() {
</div> </div>
</header> </header>
<main className="app-main"> <main className="app-main" id="main-content">
<Routes> <Routes>
{/* Public routes */} {/* Public routes */}
<Route path="/" element={<Home />} /> <Route path="/" element={<Home />} />

View file

@ -574,7 +574,7 @@ export default function AdminPipeline() {
<div className="admin-pipeline"> <div className="admin-pipeline">
<div className="admin-pipeline__header"> <div className="admin-pipeline__header">
<div> <div>
<h2 className="admin-pipeline__title">Pipeline Management</h2> <h1 className="admin-pipeline__title">Pipeline Management</h1>
<p className="admin-pipeline__subtitle"> <p className="admin-pipeline__subtitle">
{videos.length} video{videos.length !== 1 ? "s" : ""} {videos.length} video{videos.length !== 1 ? "s" : ""}
</p> </p>

View file

@ -113,7 +113,7 @@ export default function AdminReports() {
return ( return (
<div className="admin-reports"> <div className="admin-reports">
<h2 className="admin-reports__title">Content Reports</h2> <h1 className="admin-reports__title">Content Reports</h1>
<p className="admin-reports__subtitle"> <p className="admin-reports__subtitle">
{total} report{total !== 1 ? "s" : ""} total {total} report{total !== 1 ? "s" : ""} total
</p> </p>

View file

@ -86,7 +86,7 @@ export default function CreatorsBrowse() {
return ( return (
<div className="creators-browse"> <div className="creators-browse">
<h2 className="creators-browse__title">Creators</h2> <h1 className="creators-browse__title">Creators</h1>
<p className="creators-browse__subtitle"> <p className="creators-browse__subtitle">
Discover creators and their technique libraries Discover creators and their technique libraries
</p> </p>

View file

@ -117,21 +117,21 @@ export default function Home() {
<div className="home-how-it-works"> <div className="home-how-it-works">
<div className="home-how-it-works__step"> <div className="home-how-it-works__step">
<span className="home-how-it-works__number">1</span> <span className="home-how-it-works__number">1</span>
<h3 className="home-how-it-works__title">Creators Share Techniques</h3> <h2 className="home-how-it-works__title">Creators Share Techniques</h2>
<p className="home-how-it-works__desc"> <p className="home-how-it-works__desc">
Real producers and sound designers publish in-depth tutorials Real producers and sound designers publish in-depth tutorials
</p> </p>
</div> </div>
<div className="home-how-it-works__step"> <div className="home-how-it-works__step">
<span className="home-how-it-works__number">2</span> <span className="home-how-it-works__number">2</span>
<h3 className="home-how-it-works__title">AI Extracts Key Moments</h3> <h2 className="home-how-it-works__title">AI Extracts Key Moments</h2>
<p className="home-how-it-works__desc"> <p className="home-how-it-works__desc">
We distill hours of video into structured, searchable knowledge We distill hours of video into structured, searchable knowledge
</p> </p>
</div> </div>
<div className="home-how-it-works__step"> <div className="home-how-it-works__step">
<span className="home-how-it-works__number">3</span> <span className="home-how-it-works__number">3</span>
<h3 className="home-how-it-works__title">You Find Answers Fast</h3> <h2 className="home-how-it-works__title">You Find Answers Fast</h2>
<p className="home-how-it-works__desc"> <p className="home-how-it-works__desc">
Search by topic, technique, or creator get straight to the insight Search by topic, technique, or creator get straight to the insight
</p> </p>
@ -161,13 +161,13 @@ export default function Home() {
{/* Navigation cards */} {/* Navigation cards */}
<section className="nav-cards"> <section className="nav-cards">
<Link to="/topics" className="nav-card card-stagger" style={{ '--stagger-index': 0 } as React.CSSProperties}> <Link to="/topics" className="nav-card card-stagger" style={{ '--stagger-index': 0 } as React.CSSProperties}>
<h3 className="nav-card__title"><IconTopics /> Topics</h3> <h2 className="nav-card__title"><IconTopics /> Topics</h2>
<p className="nav-card__desc"> <p className="nav-card__desc">
Browse techniques organized by category and sub-topic Browse techniques organized by category and sub-topic
</p> </p>
</Link> </Link>
<Link to="/creators" className="nav-card card-stagger" style={{ '--stagger-index': 1 } as React.CSSProperties}> <Link to="/creators" className="nav-card card-stagger" style={{ '--stagger-index': 1 } as React.CSSProperties}>
<h3 className="nav-card__title"><IconCreators /> Creators</h3> <h2 className="nav-card__title"><IconCreators /> Creators</h2>
<p className="nav-card__desc"> <p className="nav-card__desc">
Discover creators and their technique libraries Discover creators and their technique libraries
</p> </p>
@ -188,7 +188,7 @@ export default function Home() {
{/* Featured Technique Spotlight */} {/* Featured Technique Spotlight */}
{featured && ( {featured && (
<section className="home-featured"> <section className="home-featured">
<h3 className="home-featured__label">Featured Technique</h3> <h2 className="home-featured__label">Featured Technique</h2>
<Link to={`/techniques/${featured.slug}`} className="home-featured__title"> <Link to={`/techniques/${featured.slug}`} className="home-featured__title">
{featured.title} {featured.title}
</Link> </Link>
@ -218,7 +218,7 @@ export default function Home() {
{/* Recently Added */} {/* Recently Added */}
<section className="recent-section"> <section className="recent-section">
<h3 className="recent-section__title">Recently Added</h3> <h2 className="recent-section__title">Recently Added</h2>
{recentLoading ? ( {recentLoading ? (
<div className="loading">Loading</div> <div className="loading">Loading</div>
) : recent.length === 0 ? ( ) : recent.length === 0 ? (

View file

@ -52,6 +52,7 @@ export default function SearchResults() {
return ( return (
<div className="search-results-page"> <div className="search-results-page">
<h1 className="sr-only">Search Results</h1>
{/* Inline search bar */} {/* Inline search bar */}
<SearchAutocomplete <SearchAutocomplete
variant="inline" variant="inline"

View file

@ -109,7 +109,7 @@ export default function SubTopicPage() {
<span className="breadcrumbs__current" aria-current="page">{subtopicDisplay}</span> <span className="breadcrumbs__current" aria-current="page">{subtopicDisplay}</span>
</nav> </nav>
<h2 className="subtopic-page__title">{subtopicDisplay}</h2> <h1 className="subtopic-page__title">{subtopicDisplay}</h1>
<p className="subtopic-page__subtitle"> <p className="subtopic-page__subtitle">
<span className={`badge badge--cat-${slug}`}>{categoryDisplay}</span> <span className={`badge badge--cat-${slug}`}>{categoryDisplay}</span>
<span className="subtopic-page__subtitle-sep">·</span> <span className="subtopic-page__subtitle-sep">·</span>

View file

@ -93,7 +93,7 @@ export default function TopicsBrowse() {
return ( return (
<div className="topics-browse"> <div className="topics-browse">
<h2 className="topics-browse__title">Topics</h2> <h1 className="topics-browse__title">Topics</h1>
<p className="topics-browse__subtitle"> <p className="topics-browse__subtitle">
Browse techniques organized by category and sub-topic Browse techniques organized by category and sub-topic
</p> </p>