Repository navigation
feat(themes): add a settings card to the bedroom theme and keep dusk through a room re-send - #17528
Conversation
/bedroom alone, in the desktop app, now places a card in the conversation: a button per switch showing its state, steps for dim, glass and blur, a text field per title, and reset, calibrate and theme on or off. Every press runs the same command body the typed /bedroom runs, so a button and its command cannot drift, and the card redraws from a session state value so a click in the room shows on it without redrawing the room. Away from the desktop the answer stays text. /bedroom status keeps the old bare answer reachable. Co-Authored-By: Claude Opus 5.5 <[email protected]>
The click hook now fires the card refresh without waiting on it, as it does its store write, so a failed state write cannot fail a click. A press whose answer is the status line already on the card shows no second copy. The README states the press cost as the tests show it, and the card test is typed against the kit's Engine and command input. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 23904f8160
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
The minute tick and every card press redraw the settings card, and each title field was drawn from the saved title alone, so text typed and not yet set was lost. Each title now keeps a draft from onInput, read before the saved title; /bedroom title clears it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
@codex review |
|
Codex Review: Didn't find any major issues. What shall we delve into next? Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
|
claude-review reviewed Code review: bedroom settings card (#17528), incremental from
|
A typed command or a room click refreshed the card with no answer, and the last press's answer stayed, so the card could read "the theme is cleared" beside "theme: on". A refresh with no answer now clears it. The command description says the card is the desktop app's. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
claude-security-review reviewed Security review: PR #17528, incremental since
|
In the desktop app, bare /bedroom answered the status line and opened no card, because $.session.surfaces() listed no desktop at that moment. It now always places the row; the Placed and AbovePrompt hooks draw the card only on the desktop surface, so other surfaces keep the text answer. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
@codex review |
|
Codex Review: Didn't find any major issues. Already looking forward to the next diff. Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
… card With the ceiling light off, a dim step or a title change showed the lit room for seven seconds: after a re-send the mod drew the shader's lit input alone until the shader came back. The room shown in that wait is now the room as it stands, hand-drawn dusk included, and a click in it is drawn; the shader still restarts after seven seconds, as before. The console's title card shows only on the console's screen in that room. The settings card is five rows (actions, switches, dim/glass/blur, the titles two to a row), and a switch's button is inactive, dim with an ellipsis, until its change has had time to finish. A switch order moves the shader's number once unless a click in the room turned it since. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 49554be796
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
… room A dim step drew the room again with its veil baked in, so the shader had to stop for the 7-second hold and start over it, and the room flashed lit on the way back. The veil is now a Box over the Shader in the backdrop, so a dim step changes one colour and the room and shader stay as they are. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
@codex review |
|
Codex Review: Didn't find any major issues. Another round soon, please! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
|
The unattended merge path enqueued this pull request at head |
|
The post-merge check verified merge commit |
Post-merge mutation testingKilled 0, survived 1, timeout 0, no coverage 0, invalid 0, not run 0.
Surviving mutants
The run's summary has the full report. |
…evision that reacts to Claude and sound (#17675) No related issue: the next step for the bedroom theme after #17497 and #17528. ## Summary The bedroom theme gains time of day, weather, a hallway outside the door, a television that reacts to Claude working, and sound (off by default). The settings card gains controls for them. Draft on purpose: the owner is hand-testing this build in the desktop app, and more fixes to the sound and the outdoor art follow on this branch before it is marked ready. ## Fix - Time of day: the room follows the local clock (`/bedroom time auto`), or holds one of eight named hours. The view outside the window keeps the dusk scene's shapes at every hour, with a moon and stars at night. - Weather: clear, overcast, rain, downpour and storm in the window, each a different weight; `auto` changes every three hours and never picks a storm. `/bedroom weather strike` forces one lightning pulse in a storm. - Hallway: a passer-by's shadow crosses the door's gap now and then, and a hall light comes on some evenings. `/bedroom hall pass` and `/bedroom hall light` trigger them. - The television dims and flickers slightly while a turn runs (`/bedroom signal`). - Sound, off by default (`/bedroom sound on`): cicadas in dry weather from dusk through night, rain, downpour and storm beds, thunder, and the television's switch. One looping player per bed that stops at once; a volume setting; two recordings per kind to choose between. Each recording's source and licence statement is in `plugins/themes/sounds/bedroom/SOURCES.md`. - The wall switch's lever shows the ceiling light's state. - The shader's dusk reads more of the furniture in shadow, and the desk lamp lights part of the desk. - The card: six rows, the time row in order through the day, a `titles` toggle for the title fields, volume steps, and no shader button. - The code moves under `hooks/bedroom/core` and `hooks/bedroom/pieces`. `lights.ts` is generated and excluded from the size check. - Settings saved by 0.2.1 under `bedroom:saved` load unchanged. ## Verification - `claude plugin test plugins/themes`: 88 pass, 0 fail. - `claude plugin validate plugins/themes`: passes with warnings; shader cost 2.25 ms a frame and 2.49 ms the first frame. - `scripts/check-affected.sh`: 17 passed, 3 skipped. - Hand-tested by the owner in the desktop app on this head: time of day, the hallway triggers, the wall switch, evening and night, and the default cicadas accepted. - Known and still open on this branch: the daytime trees read as flat; the downpour and storm beds sound too close; one-shot sounds play late; the titles row overflows the card's width; no card buttons yet for the three triggers; thunder does not yet follow a forced strike. ## Related - #17497 - #17528 - #17575 - #17509 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
No related issue: an owner request ahead of a demo, a settings menu so a person need not know the
/bedroomwords, and the fixes from his hand test of the card.Summary
/bedroomalone, in the desktop app, places a five-row settings card in the conversation: the theme on or off, reset, calibrate and Close; a button per switch showing its state; dim, glass and blur steps side by side; and the four title fields two to a row. A switch's button is inactive until its change has had time to finish; clicks in the room are never held back. A dim step now darkens a veil over the backdrop and sends no room, so the shader keeps running through it. A title change still sends the room, and with the ceiling light off the wait shows the room as it stands, not the lit room. Every typed command works as before; the card's buttons run the same code. Away from the desktop app the answer stays text.Fix
plugins/themes/hooks/bedroom/register.tsx: thecommand.runbody moves intobedroomCommand($, args). The command hook and every card button call it with the words a person would type, so a button and its command cannot drift and a press costs what the command costs.Boxholding the Shader (or the Svg alone) and aveilBox, absolutely placed over it, whose background is the room's night blue#07080fat dim's opacity (veilColor(),#rrggbbaa). The veil stays in the tree at every dim, clear at 0, so a dim step changes one color. Both drawings, the room under the shader and the room drawn whole, are built at dim 0, so a dim step no longer changes either and starts no hold. A saveddimapplies from the first draw;/bedroom dim <n>and the card's steps sharebedroomCommand.wholeRoom()), hand-drawn dusk included, and a click in the wait is drawn into it; the shader then starts over the lit room as before and computes the dusk, seeded with the stored switch values on the same redraw. The hold is driven by$.clock.after, so the test kit can step it. The GLSL andlights.tsare unchanged.scene/parts/tv.ts); the room under the shader keeps it on every screen (underShaderinscene/lib.ts), so what the shader sees is unchanged.moves()), instead of to the middle and on 700 ms later. Only when the number already sits on the side asked for, because a click in the room turned the switch since, does it go to the middle first. Reset orders only the switches it changes.Placedrow ($.ui.place) drawn on the desktop surface only, with the band above the prompt as the fallback. Each/bedroomplaces a new row (bedroom-card-N). The status line is gone from the card (the buttons show state). A pressed switch's button is drawndimColorwith…after its state, and a press on it does nothing, forCHANGE_MS: the app's half second before the shader hears a number, the switch's change in the shader, and the console's two-second boot (0.8 to 1.1 s; 2.9 s for the console turning on), plus 0.7 s when its number had to turn back. The engine'sButtonhas no disabled prop.$.statevalue,themes.bedroom-card(declared intypes/index.d.ts, named inplugin.json). Titles use the engine'sInput; text typed and not yet set is kept per field across redraws./bedroom statusanswers what bare/bedroomanswered before; bare/bedroomgives that answer and places the card's row without asking$.session.surfaces()./bedroom statsbuild name issettings-card-3. Saved state (bedroom:saved), the shader and the click behaviour while the shader runs are unchanged.statusrow,.changes/themes/fragment.Verification
claude plugin test plugins/themes(2.1.328): 27 pass, 0 fail. New or changed inhooks/bedroom/card.test.tsx: the card is five rows, with theme, reset, calibrate and Close in the first, the six steps in one row and the title fields two to a row; a pressed switch drawstv: off…and dim, a second press is ignored, and it answers again exactlyCHANGE_MSlater (also the console's 2.9 s); a pressed switch moves the shader'stvvalue straight to 0, and a typedtv offwhen it already sits at 0 goes 0.5 then 0; a dim step from the card and a typeddim 30keep the shader and its room and set the veil to#07080f1aand#07080f4dwith no room sent; a title set from the card draws the whole dusk room alone (never the lit room) for 7000 ms and then the shader over the lit room; a saved dim of 0.2 gives a#07080f33veil over a room drawn at dim 0 on the first draw;veilColor()at 0, 0.1, 0.8 and 1; a switch sends no room while the shader runs and a title sends it once; reset puts switches, dim and glass back, keeps titles and holds the switches it changed; calibrate asks for the dresser click; the theme button clears and sets the theme and says so. Inregister.test.tsx:moves(),aspectFrom(), and the console title card drawn only on the console's screen without the shader.claude plugin validate plugins/themes(2.1.328): passed with warnings, the same TypeScript warning kinds as on main plus ICON_MISSING.scripts/check-affected.sh: 17 passed, 3 skipped over 9 changed files.#07080fveil composited on top, differ by RMSE 0.008 (mean brightness 0.0535 and 0.0529). The veil also darkens the shader's own lamp, screen and lava light, which the baked-in dim did not; side by side the two read as the same room.step(0.5, asked), and the light's stored value of 0 arrives on the same redraw, so the shader itself never draws the lit room. The engine's types say nothing about what shows before a shader's first frame, so the remaining suspect for the lit flash after a title's hold is the lit input Svg shown alone while the shader starts. Because the app eases each value in from 0 at a start, switches stored on are drawn off for about half a second and then snap on.Boxfills the window, whether the veil paints over the Shader, whether a veil change keeps the shader running and whether room clicks pass through the veil are UNVERIFIED until an in-app capture. The test kit cannot raiseui.pointer, so a click during the wait is not covered by a test; the calibration math is tested asaspectFrom(). Whether the card fits without scrolling at the owner's window is judged from his screenshot (390 px showed five button rows), not measured.Related
🤖 Generated with Claude Code