Public: anyone can read this; the crew can change it.
Migrated from github.com/amirmushichge/pixel-plays
Add Patchwork Quilt: the playable page and its place in the catalogue, on the rules in `quilt/patch.js` #245
Check · Review · Land · Live done — Landed and live in production.
Patchwork Quilt is now playable at /quilt/, built on quilt/patch.js, which it drives through start, rotate, swap, matches and solution. One change from the issue. The issue says a tap turns a patch.
shipped production is serving it deploy ab54f53
Patchwork Quilt is now playable at /quilt/, built on quilt/patch.js, which it drives through start, rotate, swap, matches and solution.
One change from the issue. The issue says a tap turns a patch. Here the first tap picks a patch and draws a yellow outline, with no move spent. Tapping the picked patch turns it a quarter and costs a move. With one picked, tapping another patch swaps the two. This way a swap never wastes a turn on the first patch. Tapping off the quilt or pressing Escape lets go. Arrows move a cursor and Space or Enter does what a tap does.
The page.
- Scene: the 3x3 quilt on a cottage bed, with a 360x280 canvas, the fixed camera and hard shadows falling screen-right. Each patch is a fabric colour with four stitch patterns (running stitch, dots, zigzag, ticks) along its edges.
- Seams: a matching seam shows three cross-stitches and a mismatched one shows an open dark gap, so neither depends on colour alone.
- HUD: moves left, matching edges and score are read straight from the rules state.
- Motion: only the window curtain moves, and it is still under
prefers-reduced-motion. - Accessibility and sound: the canvas aria-label says how to play, the rules popup is three lines, there is a
#mutebutton and no.mp3.
Catalogue.
- Listing: I added the
shell.jsentry exactly as given and the matching<li>in the rootindex.html. - README: the Games table row, the games-without-music list and the ambient-motion list are updated.
- Town and cards: the town builds from
GAMES, so it needed no edit of its own.bun scripts/og.mjshas been run, givingog/quilt.pngand a refreshedog/home.png. - Tests:
rounds.mjshas a scripted round that playsQuilt.solution(seed)to the win line.serve.test.mjsasserts that/quilt/and/quilt/patch.jsanswer 200.quilt/page.test.mjsadds 7 tests for pick, turn, swap, release, keyboard, HUD and win-then-restart.
Checks.
- Passed:
quilt/page.test.mjs(7), the quilt cases inplaytest.test.mjs(5),serve.test.mjs(74) andshell.test.mjsplustown.test.mjs(44 together with the quilt tests). - Not run:
bun scripts/design-lint.ts,scripts/gate.tsandbun x tsc --noEmit. The repository has nodesign-lint.ts, nogate.tsand nopackage.json. - Not run: the full
bun test, only the files above. The forge runs the full check on the push.
Not done. I did not look at the page in a browser, only the generated share card. I did no animated curtain screenshot or Lighthouse pass.
To try it. Run the app and open /quilt/. Tap a patch twice to turn it, or tap two patches to swap them.
Rebase. git pull --rebase found nothing to rebase onto, because the branch only existed locally until this push, and the push was clean. Later pulls that append to the same lists may still conflict.
Preview serves /quilt/, /quilt/patch.js and og/quilt.png (200). Drives only quilt/patch.js, cross-stitch and gap marks are shape not colour, the selection is outlined, keyboard play works (arrows, Space, Escape), the curtain stops under reduced motion, and the shell, index, README, rounds and serve test entries are all in. One note: a tap picks and a second tap turns, where the issue said a tap turns; this is stated in the pull and keeps swaps free, so I accept it. Next two things: (1) show the picked state in the status line for screen readers with the patch's row and column, not only its number; (2) add a small touch hint on first load until a patch is picked.
Patchwork Quilt is now playable at
/quilt/, built onquilt/patch.js, which it drives throughstart,rotate,swap,matchesandsolution.One change from the issue. The issue says a tap turns a patch. Here the first tap picks a patch and draws a yellow outline, with no move spent. Tapping the picked patch turns it a quarter and costs a move. With one picked, tapping another patch swaps the two. This way a swap never wastes a turn on the first patch. Tapping off the quilt or pressing Escape lets go. Arrows move a cursor and Space or Enter does what a tap does.
The page.
prefers-reduced-motion.#mutebutton and no.mp3.Catalogue.
shell.jsentry exactly as given and the matching<li>in the rootindex.html.GAMES, so it needed no edit of its own.bun scripts/og.mjshas been run, givingog/quilt.pngand a refreshedog/home.png.rounds.mjshas a scripted round that playsQuilt.solution(seed)to the win line.serve.test.mjsasserts that/quilt/and/quilt/patch.jsanswer 200.quilt/page.test.mjsadds 7 tests for pick, turn, swap, release, keyboard, HUD and win-then-restart.Checks.
quilt/page.test.mjs(7), the quilt cases inplaytest.test.mjs(5),serve.test.mjs(74) andshell.test.mjsplustown.test.mjs(44 together with the quilt tests).bun scripts/design-lint.ts,scripts/gate.tsandbun x tsc --noEmit. The repository has nodesign-lint.ts, nogate.tsand nopackage.json.bun test, only the files above. The forge runs the full check on the push.Not done. I did not look at the page in a browser, only the generated share card. I did no animated curtain screenshot or Lighthouse pass.
To try it. Run the app and open
/quilt/. Tap a patch twice to turn it, or tap two patches to swap them.Rebase.
git pull --rebasefound nothing to rebase onto, because the branch only existed locally until this push, and the push was clean. Later pulls that append to the same lists may still conflict.Closes #218