feat(home): use the supplied hero artwork instead of a drawn one
PR Checks / Frontend Typecheck + Tests (pull_request) Successful in 1m3s
PR Checks / Backend Smoke (pull_request) Successful in 7s
PR Checks / Build Backend (no push) (pull_request) Successful in 11s
PR Checks / Build Frontend (no push) (pull_request) Successful in 46s
PR Checks / Build Pipeline (no push) (pull_request) Successful in 10s
PR Checks / AI Code Review (Claude) (pull_request) Successful in 2m29s
PR Checks / Frontend Typecheck + Tests (pull_request) Successful in 1m3s
PR Checks / Backend Smoke (pull_request) Successful in 7s
PR Checks / Build Backend (no push) (pull_request) Successful in 11s
PR Checks / Build Frontend (no push) (pull_request) Successful in 46s
PR Checks / Build Pipeline (no push) (pull_request) Successful in 10s
PR Checks / AI Code Review (Claude) (pull_request) Successful in 2m29s
Replaces the hand-drawn SVG landscape with the illustration supplied by the project owner. Master is assets/hero-source.png; everything under public/brand/hero-* comes from scripts/build-hero-images.js and should never be hand-edited. LAYOUT The artwork is composed as a full-bleed hero: it reserves an empty cream area down its left side for the headline. The old hero was a two-column grid with art in the right 0.88fr, which would have cropped that reserved area off and shrunk the scene into a thumbnail — the one thing the picture is built not to be. So the panel is now a single layered block: artwork behind, copy on top, and below the one-column breakpoint the artwork leaves the background and becomes a band under the search. Overlaying does not survive down to phone widths — the panel gets too narrow for the copy to stay inside the cream, so the scrim would have to cover nearly the whole image and you would be left with a tinted rectangle. Hence the switch at 860px rather than a single treatment stretched across every width. CONTRAST The copy sits on a gradient of --hero-ground, a new token sampled from the artwork's own cream (#FDF9F3) rather than from Sand. Sand is eight to thirteen points darker per channel, which leaves a visible seam straight down the hero. The scrim exists because the artwork is a fixed image on a fluid panel: past some width the headline would otherwise land on hillside green. Measured on rendered pixels, sampling background up to 120px beyond the right edge of each line, so a longer line still has margin: light title 14.36:1 body 6.52:1 dark title 11.01:1 body 6.44:1 The worst light case is hillside green showing through the scrim at 6.52:1. TWO CROPS The slot is two shapes: roughly 2.1:1–2.7:1 behind the desktop panel, and 2.6:1–4.9:1 as the band. A single file under object-fit: cover centre-crops, and at the band's extreme that slices a strip through the scene and loses the schoolhouse — exactly how the drawn hero failed on phones. <picture> switches crop, not just resolution: the band file is pre-cropped around the school and is already near 2.6:1, with the subject at ~65% across so squeezing toward 4.9:1 crops the empty sides instead. WEIGHT 1.6 MB PNG in, AVIF and WebP out; a browser fetches exactly one file — about 23–33 kB on desktop, 9–18 kB on a phone. The JPEG is only the <img> fallback. `sizes` describes the real panel box (max-width 1400 minus padding) rather than 100vw, which over-requested a candidate at every width on the LCP element. DARK THEME A raster cannot be re-graded token by token the way the drawing was, but it would reproduce the same failure — a bright illustration is the brightest object on a near-black page. It is dimmed in CSS to read as dusk, and the scrim fades it into the dark panel rather than into cream. TESTS The two illustration journeys are replaced by three, each covering a failure that still renders a valid-looking page: the artwork actually loading (naturalWidth, not src), the crop switching at the breakpoint, a modern format winning negotiation, and the dark theme dimming it. public/brand/CREDITS.md records provenance for every asset in that folder. The hero's licence line is marked unconfirmed — that one needs the owner. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
1 parent
f1819e9c4d
commit
3f0e05cc99
22 files changed
+379
-333
No files matched your search
+18
-51
@@ -188,33 +188,18 @@
|
||||
--section-gap: 4rem;
|
||||
--section-head-gap: 1.5rem;
|
||||
|
||||
/* ── Illustration ───────────────────────────────────────────────────
|
||||
The hero landscape's palette. These are tokens rather than literals in
|
||||
the SVG for one reason: the drawing previously kept a fixed light
|
||||
palette in both themes, which left a pale sky slab as the brightest
|
||||
object on a near-black page — it out-shouted the H1 and the search box.
|
||||
Artwork still shouldn't invert (that breaks the picture), so the dark
|
||||
values below are a re-grade, not an inversion: the same scene, lit at
|
||||
dusk, sitting a step above the panel it lives on. */
|
||||
--ill-sky-high: #DAEDF8;
|
||||
--ill-sky-low: #EFF8FB;
|
||||
--ill-cloud: #FFFFFF;
|
||||
--ill-hill-far: #D6EDE2;
|
||||
--ill-hill-mid: #A7D7C5;
|
||||
--ill-hill-near: #7FC3AC;
|
||||
--ill-hill-front: #5BA88F;
|
||||
--ill-path: #FAF6EE;
|
||||
--ill-path-edge: #E6DAC2;
|
||||
--ill-wall: #FCE8C3;
|
||||
--ill-roof: #F0A868;
|
||||
--ill-door: #0F766E;
|
||||
--ill-window: #C7EBF5;
|
||||
--ill-tree-dark: #2E7D6B;
|
||||
--ill-tree-mid: #3E8C74;
|
||||
--ill-tree-light: #4A9E85;
|
||||
--ill-tree-pale: #7FC3AC;
|
||||
--ill-pin: #F97360;
|
||||
--ill-pin-eye: #FFFFFF;
|
||||
/* ── Hero artwork ───────────────────────────────────────────────────
|
||||
The landing hero is now a supplied raster illustration rather than a
|
||||
drawn SVG, so its colours are in the file, not here. What is left is the
|
||||
ground the artwork sits on and fades into.
|
||||
|
||||
--hero-ground is sampled from the artwork's own copy area (#FDF9F3),
|
||||
not from Sand. The artwork reserves an empty cream region on the left
|
||||
for the headline, and the scrim that guarantees text contrast fades from
|
||||
this colour into it — a scrim in Sand (#F5EFE6, eight to thirteen points
|
||||
darker per channel) leaves a visible seam straight down the hero. */
|
||||
--hero-ground: #FDF9F3;
|
||||
--hero-ground-rgb: 253, 249, 243;
|
||||
|
||||
/* ── Geometry & motion ──────────────────────────────────────────────
|
||||
"Soft shapes, rounded corners" — the guideline's geometry is markedly
|
||||
@@ -340,30 +325,12 @@
|
||||
--medal-silver-rgb: 169, 182, 188;
|
||||
--medal-bronze-rgb: 201, 144, 112;
|
||||
|
||||
/* Dusk re-grade of the hero landscape. The sky sits one step above the
|
||||
Sand panel (#16222A) rather than 60 points above it, so the picture
|
||||
reads as a framed vignette instead of a light leak. The pin keeps
|
||||
the theme's coral and is the only bright thing left in the scene —
|
||||
which is the point, since it marks "you are here". */
|
||||
--ill-sky-high: #1B2C36;
|
||||
--ill-sky-low: #16242C;
|
||||
--ill-cloud: #2A3F4A;
|
||||
--ill-hill-far: #1E3A38;
|
||||
--ill-hill-mid: #234944;
|
||||
--ill-hill-near: #2A5A51;
|
||||
--ill-hill-front: #326B5E;
|
||||
--ill-path: #4A5A52;
|
||||
--ill-path-edge: #3A4842;
|
||||
--ill-wall: #45423A;
|
||||
--ill-roof: #8A5A3E;
|
||||
--ill-door: #5FC7BB;
|
||||
--ill-window: #2F5966;
|
||||
--ill-tree-dark: #16302C;
|
||||
--ill-tree-mid: #1B3A34;
|
||||
--ill-tree-light: #21453D;
|
||||
--ill-tree-pale: #2A5A51;
|
||||
--ill-pin: #F08A72;
|
||||
--ill-pin-eye: #16242C;
|
||||
/* The artwork is a fixed, bright raster — it cannot be re-graded by
|
||||
token the way the drawn version was. The dark theme instead dims it
|
||||
in CSS (see .heroArt in HomeView.module.css) and fades it into this
|
||||
ground, which is the panel colour rather than the artwork's cream. */
|
||||
--hero-ground: #16222A;
|
||||
--hero-ground-rgb: 22, 34, 42;
|
||||
|
||||
--shadow-soft: 0 1px 2px rgba(0, 0, 0, 0.4), 0 2px 8px rgba(0, 0, 0, 0.3);
|
||||
--shadow-medium: 0 4px 18px rgba(0, 0, 0, 0.45);
|
||||
|
||||
Reference in new issue
Block a user