1.16 part 5/11: Games: shelf, shell and card games
Part 5 of 11 of Zimi 1.16: games: shelf, shell and card games.
The release is split into 11 parts so each one can be reviewed whole. Each part's base is the part before it, so this diff is only its own files; a part on its own is not a running state. CI runs once, on the release PR that carries every part into main.
Every part was reviewed before it was opened, and the full suite (quick tier, node tests, every browser test under software GL) ran on the combined tree.
Summary by cubic
Part 5 of 11 of the Zimi 1.16 release adds sixteen card games to the shelf — Courtier, the family games (Cheat, Go Fish, Oh Hell, Old Maid, Snap), and ten solitaire variants (Accordion, Aces Up, Beleaguered Castle, Calculation, Canfield, Eight Off, Forty Thieves, Monte Carlo, Scorpion, Yukon) — and fixes the card games already shipped. Each part is its own diff against the part before it; CI runs once on the combined release PR.
New Features
- Courtier is an original game with its own 16-card deck, playable by two to four; the rest are rule-as-pure-function implementations with computer players (Oh Hell seats up to five).
- Rooms now live in
shell.js(each with its own light),shelf.jsreads the registry, andtablesnap.jspaints a board game's table as an SVG so a game left under way keeps a picture on its shelf tile. - Tests cover every game: node tests for rules and computers, browser tests that play each game through on a 390 px phone, and a bake gate that builds a contact sheet of the new games.
Bug Fixes
- Card faces redraw as one French layout at every size; the back is quiet navy, and face-down piles keep a constant sliver instead of opening up when the table has room.
- Card tables fit short and narrow phones: Bridge's bidding box widens, Cribbage and Koikoi shrink on short tables, Blackjack and Teen Patti move their chip trays aside, Spades drops its hint line in landscape, and Freecell, Solitaire and Spider get wide layouts.
- Older games on phones: boards and status lines centre and shrink in landscape, the Menu holds in Hebrew and landscape, a tapped primary button keeps its label, small text and touch targets pass on the older families, every shelf tile is a drawing, and end sheets put the winner's line first and behave across reloads.
- Game strings now go through the translation table, discover cards speak the reader's language, Shut the Box says what is still needed, score bars fill from the reading side in Hebrew, and a test holds every
{placeholder}to its value at the call site.