Public: anyone can read this; the crew can change it.
small: Review answers to the keys S, D and T on the focused reminder #280
Merged 25d 21h ago, live in production
Review now answers to S, D and T on the reminder card, and the pull is pushed. The review, a11y, design and security tests pass. I didn't run the whole suite, so the forge's check will be its first full run.
-
Reviews
Changes requested — before the latest pushThe keys work as designed and the hint, aria wiring, cache and size are right. One real bug and two small points to fix in one round:
- static/review.js builds a selector from e.key, so pressing a key such as a double quote or backslash throws a SyntaxError from querySelector on the card. Look the key up without a selector (for example a {s,d,t} map, or find the button by comparing its dataset.key to e.key.toLowerCase()).
- The test only checks script text. It never asserts the Tomorrow button carries data-key=t, so T could be lost unnoticed. Assert it, and drop the brittle substring checks in favour of the behaviour that matters.
- Scope: src/sample.ts and src/week.appointment.test.ts changes are unrelated to the keys. They fix real date-dependent failures, but say so as a separate follow-up issue and keep them minimal; the sample.ts SQL built by a conditional template should be two plain statements instead.
ApprovedEarlier asks met: review.js no longer builds a selector from e.key (it matches data-key), the test covers Tomorrow and runs the handler for odd keys and typing in a field, and the sample.ts/week test fixes are minimal and justified as keeping the pull green. No contract cell loosened, no new dependency, every mutation still goes through the real buttons. Non-blocking: the hint is in the card, fine as is.
-
Checks
shipped production is serving it deploy d2eada7
-
History
- Review keys look the button up without a selector; the test runs the script and asserts Tomorrow's key; sample stamp as two plain statements (#272) 53ed786
- Sample anniversary closing is stamped on its anniversary day even when the due rolls back; the week test counts only its own deals cfebb02
- Run the review-keys test while the queue still has a card (#272) 8ab411b
- Review answers to S, D and T on the focused reminder card, with a visible hint and a 618-byte script (#272) 192559f
- The review page's finished screen says when the next reminder will be drafted and for whom (#276) 33d0843
- Every drafted message for every sample deal is checked for leaks: no undefined, null, [object], unfilled braces, double spaces or a missing sign-off (#274) 67e145d
- Every route answers with the security headers and every mutation refuses a foreign origin, enumerated from routes.ts (#269) 7756f0c
- The review page and a deal page read on a phone-width screen with no sideways scroll, pinned by a test (#267) 09ab42b
- docs/TECHNICAL.md names every module in src/, and a test fails when a new one is left out (#268) 70811bf
- The signed-out first page offers one clear Sign in button under the example clock, and says what signing in shows (#265) 98c2738
- A test walks the README tour and fails when a button or heading it names is no longer on the page (#263) b0addfc
- small: README tour step 6 tells the realtor to start where Review says "Start here" (#262) c002df5
- People, Review and This week answer in under 50 ms with 200 deals, pinned by a test (#260) ef8a75e
- small: The review page's finished screen also says how many reminders were held until tomorrow (#257) 81d12a2
- The sample deals stay sensible when the app boots across a month or year end, pinned by a test (#256) 71e8e15
- small: The review page's finished screen says how many were sent and declined this round (#251) 9e41467
- People can be narrowed by typing a name, phone or address, like the clock's Find (#249) d5aef3a
- The printed week sheet ends with the sentence naming who has not yet been told about each overdue date (#250) fec1edc
- A date from another year says its year on the clock's Closed list, the deal page's "All done" line and the terminal's closed list (#239) f617d15
- On a fresh boot the clock's first reminder for today is one that is already late (#246) f1f5623
3 earlier comments
Review now answers to S, D and T on the reminder card, and the pull is pushed. The review, a11y, design and security tests pass. I didn't run the whole suite, so the forge's check will be its first full run.
I did not see the script run in a browser. The test checks the markup and the script's text, not the keypress behaviour.
My first push had one red test: it ran after earlier tests had emptied the queue. The second commit fixes that. The Bash tool also reported bun x tsc --noEmit as broken in this clone, and scripts/design-lint.ts doesn't exist here. The repo's lint is scripts/lint-design.ts, and I ran that. tsc printed its help text and checked nothing, because the clone has no tsconfig.json. docs/VISION.md is also missing, so I didn't read it.
What changed
static/review.js(new, 618 bytes): it is served with the existing immutable-cached/static/…?v=hashpath. The page loads it from the card, because Review's layout turns the shared scripts off.- Card focus: the card is focusable and takes focus when the page loads, so the keys work without a click. Keys only fire while focus is inside the card.
- S, D, T: they call
.click()on the real Send, Don't send and Tomorrow buttons. The same server actions and same-origin check run as for a mouse click. - Draft box: keys do nothing while focus is in an input, textarea, select or contenteditable element. Ctrl, Meta and Alt combinations and held-down repeats are ignored.
src/pages/review.ts: a visible hint line under the heading lists the keys. The card points to it witharia-describedby, and each button carriesaria-keyshortcuts.src/review.test.ts: one new test checks the hint, the threedata-keybuttons, the immutable cache header, the 1 KB limit and the typing guard. It fails without the script or the hint.
What I chose not to do
- D on an empty reason does not submit. The browser's required-field check focuses the reason box, which is how "opens the reason" works. If a reason is already typed, D submits.
- T does nothing on a status reminder, because that card has no Tomorrow button.
- No contract cell is loosened, and there are no new dependencies.
To try it
Open /reminders/today. The card is focused, so press S, D or T. Click into the Message box and type those letters to see nothing fire.
🤖 Generated with Claude Code
I changed nothing and pushed nothing, because I couldn't find a failure my change causes. The log you pasted ends on passing tests, so it doesn't show what failed.
I ran the full suite here: 713 pass, 3 fail. The three failures also fail on a clean checkout of origin/main, so my branch didn't cause them. Each one depends on today's date, which is 2026-11-10 in this sandbox:
src/sample.test.ts: "no finished sample date reads late…". It finds the sample closing due 2025-11-14 marked done on 2025-11-15 after a refresh to today+6.src/anniversary.test.ts: "a new database has one closed sample whose anniversary is today…". The anniversary draft comes back withon2026-11-09 anddue2025-11-09, but the test expects it to be today's.src/week.appointment.test.ts: "a day's timed dates come first…". The sample deal "1418 Alder Lane" has a walkthrough on today+2 and appears in the list the test expects to hold three deals.
My own tests pass: the new Review keys test in src/review.test.ts and the a11y, design and security suites.
I'd rather fix those three tests or the sample data on main than patch them on this branch. If the deploy ran on a day when these pass, a different test failed, so please send me the part of the log that has the (fail) line. I'll fix it as soon as I can see it.
Review answers to S, D and T on the focused reminder card, and the full suite now passes (716 tests). The last push failed the preview only on three date-dependent tests. They also fail on a clean main, and I fixed them here.
The keys
static/review.jsis 618 bytes and is served cached immutable through the usual/static/…?v=hashaddress.- The card takes focus on load, so the keys work without a click. Keys only act while focus is inside the card, never in an input, textarea, select or contenteditable. Ctrl, Meta and Alt combinations and held-down repeats are ignored.
- S, D and T call
.click()on the real Send, Don't send and Tomorrow buttons. The same server actions and same-origin check run as for a mouse click. - A visible hint line under the heading lists the keys. The card points to it with
aria-describedby, and each button carriesaria-keyshortcuts. - One test in
src/review.test.tschecks the hint, the threedata-keybuttons, the immutable header, the 1 KB limit and the typing guard. It fails without the script or the hint. - D with an empty reason doesn't submit; the browser's required-field check focuses the reason box. If a reason is already typed, D submits.
- T does nothing on a status reminder, which has no Tomorrow button.
- I didn't run the script in a browser; the test checks the markup and the script's text.
The failing tests
- Sample bug (two tests): the anniversary sample was marked done a day early whenever its due date rolled back to a business day. This year its due falls on Veterans Day, so the anniversary landed on 2026-11-09 instead of today and a refresh read it as late. In
src/sample.ts, the anniversary sample's closing is now stamped on its anniversary day. Other samples are stamped as before. - Week test: the sample "1418 Alder Lane" also has a walkthrough two days from today, so it showed up in
src/week.appointment.test.ts. The test now counts only its own three deals. The test was wrong, not the code.
I didn't run design-lint (it's scripts/lint-design.ts here) after the last commit, and bun x tsc --noEmit prints help text instead of checking because the clone has no tsconfig.json. No contract cell is loosened and there are no new dependencies.
To try it: open /reminders/today, press S, D or T, then click into the Message box and type those letters to see nothing fire.
🤖 Generated with Claude Code
All three points are fixed and pushed. The full suite passes (716 tests).
The keys fix
static/review.js(667 bytes) no longer builds a selector frome.key. It lowercases the key and finds the button whosedata-keymatches. A double quote, backslash or bracket now does nothing instead of throwing.- The test in
src/review.test.tsnow asserts that Tomorrow carriesdata-key="t", alongside Send and Don't send. I dropped the substring checks on the script text. - Instead, the test runs
review.jsagainst a stand-in card, which checks that:",\,]and Enter neither throw nor click.- S pressed inside a field does not click.
- s, D and t press their buttons.
Scope (point 3)
- I kept the
src/sample.tsandsrc/week.appointment.test.tschanges in this pull and did not split them out. Three tests fail on a cleanmaintoday and fail the preview, so this pull can't land green without them. Both changes are minimal and unrelated to the keys. - The anniversary sample's closing is now stamped on its anniversary day, because its due date rolls back to a business day. The SQL is two plain statements in place of the conditional template.
- The week test now counts only its own three deals; the sample deal "1418 Alder Lane" also has a walkthrough two days from today.
- Please open a follow-up issue for the date-dependent sample tests if you want them tracked separately.
No contract cell is loosened and there are no new dependencies.
To try it: open /reminders/today and press S, D or T. Type those letters in the Message box to see nothing fire.
🤖 Generated with Claude Code
Review now answers to S, D and T on the reminder card, and the pull is pushed. The review, a11y, design and security tests pass. I didn't run the whole suite, so the forge's check will be its first full run.
I did not see the script run in a browser. The test checks the markup and the script's text, not the keypress behaviour.
My first push had one red test: it ran after earlier tests had emptied the queue. The second commit fixes that. The Bash tool also reported
bun x tsc --noEmitas broken in this clone, andscripts/design-lint.tsdoesn't exist here. The repo's lint isscripts/lint-design.ts, and I ran that.tscprinted its help text and checked nothing, because the clone has notsconfig.json.docs/VISION.mdis also missing, so I didn't read it.What changed
static/review.js(new, 618 bytes): it is served with the existing immutable-cached/static/…?v=hashpath. The page loads it from the card, because Review's layout turns the shared scripts off..click()on the real Send, Don't send and Tomorrow buttons. The same server actions and same-origin check run as for a mouse click.src/pages/review.ts: a visible hint line under the heading lists the keys. The card points to it witharia-describedby, and each button carriesaria-keyshortcuts.src/review.test.ts: one new test checks the hint, the threedata-keybuttons, the immutable cache header, the 1 KB limit and the typing guard. It fails without the script or the hint.What I chose not to do
To try it Open
/reminders/today. The card is focused, so press S, D or T. Click into the Message box and type those letters to see nothing fire.🤖 Generated with Claude Code
Closes #272