village-builder

VB-1531: Options: a theme’s card previews from the theme’s own tokens, and the test counts THEMES

Status: done (2026-11-22) Priority: 2 Size: S Design ref: Kim, 22 November; VB-1161 Goal: Adding a theme needs no hand-written preview card and no edit to a test’s count. Acceptance criteria:

Notes

Builds on VB-1530’s tokens.

Done (VB-1531). The three token blocks lost :root ([data-theme="glass"], its dark block under the media query, [data-theme="mural"]); the bare :root after Glass’s block sets only color-scheme: light, and Glass dark’s block, now of equal weight, comes after it, so the root’s tokens are unchanged. Mural’s own pieces stay under :root[data-theme="mural"]. The sample is <span class="panel" data-theme="k"> with a head (--head, --head-style, --head-ink) and two buttons drawn with --btn-*, the first pressed; no colour of a theme is written in its rules. The checkerboard ground behind it stays (it stands for the map). tests/page.js exposes THEMES by a fourth patch of the built page, counts the cards against its keys and walks each (glass last): the root’s theme and icons, aria-checked, the kept choice, and the sample’s data-theme. Look: menu, Options, choice of whom to play and the played game, Glass light, Glass dark and Mural, 1440 by 900: identical by pixel but the two cards’ samples. They changed: Glass dark’s sample is now dark (it was always light); Glass’s sample has the panel’s blur and shadow and a taller padding (9px, Mural’s band needs it); Mural’s buttons are its leaf-shaped buttons (--btn-radius) instead of ringed medallions; the head is 15px in both (14 and 16 before).