diff --git a/assets/css/main.css b/assets/css/main.css index d5d4a51..14fd251 100644 --- a/assets/css/main.css +++ b/assets/css/main.css @@ -41,8 +41,9 @@ --term: var(--accent); --term-fg: var(--accent-fg); /* console: fills, banner, prompt, caret */ --focus: var(--accent); /* focus-visible outline */ - /* pop palette — themes remap these; also feed syntax + mermaid diagrams */ - --c-red: #c0392b; --c-orange: #cc6a1a; --c-yellow: #b8860b; --c-green: #2e8b57; + /* pop palette — themes remap these; also feed syntax + mermaid diagrams. + Light-base yellow/green are darkened to clear WCAG AA (4.5:1) as code text. */ + --c-red: #c0392b; --c-orange: #cc6a1a; --c-yellow: #8a6100; --c-green: #1f7a4d; --c-cyan: #1f7a8c; --c-blue: #2c5f8a; --c-purple: #7b4bc4; --c-pink: #b83280; --measure: 68ch; @@ -87,6 +88,15 @@ * { box-sizing: border-box; } +/* visually hidden but readable by screen readers (e.g. the home-page h1) */ +.visually-hidden { + position: absolute; + width: 1px; height: 1px; + margin: -1px; padding: 0; border: 0; + clip: rect(0 0 0 0); clip-path: inset(50%); + overflow: hidden; white-space: nowrap; +} + html { -webkit-text-size-adjust: 100%; } body { diff --git a/assets/css/themes/paper.css b/assets/css/themes/paper.css index b49deb1..64c2412 100644 --- a/assets/css/themes/paper.css +++ b/assets/css/themes/paper.css @@ -2,9 +2,9 @@ Concatenated after main.css (see baseof.html); :root[...] matches the dark media query's specificity and wins by source order. */ :root[data-theme="paper"] { - --bg: #faf4e8; --fg: #2b2b2b; --muted: #8a7f6a; --border: #e4d8c0; + --bg: #faf4e8; --fg: #2b2b2b; --muted: #6f6449; --border: #e4d8c0; --accent: #c0392b; --accent-fg: #ffffff; --selection: #efe2c6; --code: #b83280; - --c-red: #c0392b; --c-orange: #cc6a1a; --c-yellow: #b8860b; --c-green: #2e8b57; + --c-red: #c0392b; --c-orange: #cc6a1a; --c-yellow: #8a6100; --c-green: #1f7a4d; --c-cyan: #1f7a8c; --c-blue: #2c5f8a; --c-purple: #7b4bc4; --c-pink: #b83280; /* sets: each surface its own hue */ --link: var(--c-red); diff --git a/assets/css/themes/valentine.css b/assets/css/themes/valentine.css index 010dc79..42846a3 100644 --- a/assets/css/themes/valentine.css +++ b/assets/css/themes/valentine.css @@ -1,7 +1,7 @@ /* Valentine — blush ground, burgundy ink, all pinks + rose/crimson pops (no purple). Concatenated after main.css (see baseof.html). */ :root[data-theme="valentine"] { - --bg: #fff0f5; --fg: #4a0d20; --muted: #a86b7e; --border: #f3cdd9; + --bg: #fff0f5; --fg: #4a0d20; --muted: #8a4f63; --border: #f3cdd9; --accent: #c71f5d; --accent-fg: #ffffff; --selection: #ffd6e5; --code: #b0185a; --c-red: #a4133c; --c-orange: #d81159; --c-yellow: #b23a48; --c-green: #7b2d43; --c-cyan: #c9184a; --c-blue: #8c1c3f; --c-purple: #e05780; --c-pink: #ff5c8a; diff --git a/assets/js/console.js b/assets/js/console.js index 8f4f4bf..19ada56 100644 --- a/assets/js/console.js +++ b/assets/js/console.js @@ -257,7 +257,7 @@ // ↑/↓ walk previous commands (shell-style). Down past the newest clears the line. input.addEventListener("keydown", function (e) { - if (e.key !== "ArrowUp" && e.key !== "ArrowDown" || !cmdHistory.length) return; + if ((e.key !== "ArrowUp" && e.key !== "ArrowDown") || !cmdHistory.length) return; e.preventDefault(); if (e.key === "ArrowUp") { if (histIdx > 0) histIdx--; } else if (histIdx < cmdHistory.length) histIdx++; diff --git a/layouts/index.html b/layouts/index.html index acd5fd4..c25c305 100644 --- a/layouts/index.html +++ b/layouts/index.html @@ -4,6 +4,9 @@ {{ $posts := where site.RegularPages "Type" "posts" }} {{ $intro := or .Content site.Params.description }} + {{/* The front door has no visible page title by design; give it a real h1 for + the document outline / screen readers without changing the visible layout. */}} +