Repository navigation
Dress the office for Christmas through December, pets included - #115
Merged
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
tuliren
marked this pull request as ready for review
November 30, 2026 06:13
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Requested by T · project thread
Builds on #114 (merged).
What
Until a viewer picks a theme, the season picks it: Christmas all December (the viewer's local time), the plain office the rest of the year. A theme picked in the settings card still wins and is remembered as before.
theme.ts:seasonalTheme(at)andpickedTheme(stored)(a stored id, or null when nothing was picked).renderer.ts: newRendererOptions.calendarclock. The app (main.ts) and the website hero (hero.ts) passsystemClock. The stories pass nothing, so they and Chromatic stay plain whatever the month. The renderer still never reads the ambient clock. The season is checked again each wall-clock minute, so an office left open over midnight on 30 November dresses itself.none · pickedwhile a pick holds.pet.ts): in the Christmas theme the dog wears a green zigzag sweater over its middle (DOG_SWEATER, drawn in the body's frame so it follows sitting and lying), and the cat a Santa hat between its ears. The hat's colours moved toSANTA_HATinsweater.ts, which the human's hat now shares.christmas-theme.md, because its "off by default" stopped being true.Testing
Drew the dog and the cat walking, sitting and napping with the theme on, to check the sweater and the hat in each pose.
yarn lint,yarn typecheck,yarn testall pass. New cases intheme.test.tscover the month edges (30 Nov 23:59, 1 Dec, 31 Dec 23:59, 1 Jan) and the stored picks.Ran the viewer in Playwright with a faked clock: 5 December with nothing stored shows
christmaswith reset disabled; 29 November showsnone; 5 December withnonestored showsnone · pickedwith reset enabled.