Repository navigation
feat(serving): viewers can turn off single-key shortcuts, from a patch's sheet or the account menu - #1301
Conversation
0554f0d to
f773e03
Compare
1d6860c to
7fbf4e9
Compare
|
Restacked onto Changed in behaviour or look:
Changed only to fit
Unchanged from the reviewed version:
Evidence:
|
f773e03 to
a7fc936
Compare
7fbf4e9 to
06476fe
Compare
|
Review of the restack (GPT 6.1 Sol, xhigh), at #1276
The chain is being rebased once more onto main with |
|
Re-chained onto Checks at
|
Acceptance: PASS with notesChecked This run covered the whole chain end to end on today's main, with the most attention on #1301's port to the overhaul and the switcher. I used a throwaway
No key test clicked into the frame first: since #1298, the frame takes focus as it loads. Done means
Screenshots
Golden journeys
Rollback answers: they match the diff.
Not run
Notes
|
|
The acceptance nit is fixed in 7ea83a9. A new browser case asks with an object, a number and a list. Each gets |
a7fc936 to
2aa48ec
Compare
…h's sheet or the account menu Co-Authored-By: Claude Opus 5.5 <[email protected]>
7ea83a9 to
a7aeeea
Compare
…ey shortcuts (#1421) ## What changed This adds release 42's What's new entry, written from `1cd6d12`. It covers everything merged since release 41's `through` (`a25a9c5`), and sets the `patchy` release to `0.42.0` in `packages/patchy/package.json` and `CURRENT_RELEASE`. | Change | PRs | | --- | --- | | New: Tell Patchy what it's missing | #1217, #1218, #1219, #1227, #1228 | | New: Turn off single-key shortcuts | #1276, #1279, #1301 | | Fixed: Typing reaches the patch again | #1407, #1412 | | Fixed: Dialogs in patches keep your place | #1420, #1255 | | Behind the scenes: plainer facts for agents building patches | #1249, #1256, #1297, #1418 | | Behind the scenes: Patchy stores teams and audiences ahead of teams | #1416 | | Patch changes: Mod+/ and `client.close()` in patchy/hotkeys; single-key shortcuts can be off; Tab wraps in plain modal dialogs | #1279, #1301, #1420 | #1376 is release 41's own entry. #1400, #1406, #1414, #1415, #1302, #1413 and #1419 are test, CI and dev tooling and need no line. The teams bridge (#1416) ships alone in this release so teams (#1417) can follow in the next one with a release to roll back to that reads its data closed. ## Look at - **The entry**, at the top of `releases` in `packages/core/src/whatsNew.ts`. - **Rollback safety, from the live commit `7f93b91` (release 41) to this PR's merge.** No PR in the range is labelled `one-way`, and every Release impact answer says release 41 still works: - **#1217** adds migration `0037_feedback`, a schema release 41 never reads. **#1227** and **#1228** write into it. - **#1276** adds migration `0038_single_key_shortcuts`, a column with a default that release 41 never selects. - **#1416** adds migrations `0039_company_teams` to `0041_connection_audiences`, which hold tables that stay empty until teams ship, and widens one scope check. Its CI rehearsal ran `7f93b91 → head → 7f93b91 → head` on one set of data, and all four steps passed. - **#1279**, **#1301**, **#1255** and **#1420** change the SDK and the shell. Patches built on this release carry a `shortcutSetting` manifest field that release 41 reads without refusing, and its shell names no frame, so every shortcut stays on. - **#1218** and **#1219** add CLI commands and an optional `feedbackHint` in `--json` failures. A CLI from this release refuses to publish to an older instance before sending anything, as any mismatched release does. - Everything else is skill text, docs, tests and CI. If this release misbehaves, roll back to `7f93b91` (release 41). Written by Claude Opus 5.5 in Claude Code, through T3 Code. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Opus 5.5 <[email protected]>









What changed
Speech input can type a letter that fires a patch's single-key shortcut. #1224 lets each person turn those off. #1276 stores the choice and #1279 taught
patchy/hotkeysto obey it, but nothing passed the choice to a patch yet. Now Patchy's shell does:This is the top of the stack
main ← #1297 ← #1255 ← #1256 ← #1279 ← #1276 ← this, and the six land together. #1302, CI's move to desktop Chromium, waits on #1402 and lands later. It's restacked ontomainafter the UI overhaul (#1332–#1354) and the switcher (#1298, #1304), and ported to both. The restack comment says what changed beyond conflict resolution.Closes #1275
Closes #1224
Look at
1. The frame is named in the shell's static markup, not by a script that creates it. A parser-created iframe gets its
nameattribute before its browsing context exists. So the server rendersname="patchy:shortcuts=on|off"on the existing static iframe, aftermain'sdata-waiting, and only for a company or local shell rendered for its viewer (shell.ts,Pages.ts). A public shell is everyone's document, a member's included since #1339, so it never carries one, andrenderPatchWrapperthrows if asked to. Probed before choosing, in Chromium and Firefox:srca deferred script setsname: first load, a reload after the value changed, back after it changedoff,on,onoff,on,on<template>cloned by script, as the ticket's creator wouldIn desktop Chromium, where the frame runs in its own process, the patch reads
window.name === "patchy:shortcuts=off"on first load and after a new version's Reload re-creates the frame. Static markup keeps three things:main's plus one attribute (anddata-shortcuts-note), so an older broker mounts it unchanged, and this broker mounts an older unnamed shell as before.render.test.tspins that the frame differs from the unnamed one only by its name.2. Patchy's dialog (
packages/serving/src/shortcuts.ts), from the mock's direction C. A running patch's shell keeps its own pinned style subset onmain(servedStyles; the overhaul left patch shells alone). So the dialog stays ashell-scrimover onenote-infonote-float, withglyph-sm, the primary button and a quiet Cancel. The setting's On or Off is a servedtagafter the question. The oldpillisn't in that subset, andmain's pin test would refuse it, so it's gone.The sheet is the SDK's, drawn in the patch's own frame by #1279, and
mainhasn't touched it.The copy and the failure pattern are as reviewed:
{ value }and an empty 200 all turn the notenote-warn, with the alert line "Couldn't save. Nothing changed." and Try again.The abuse rules, each a step of the browser spec:
navigator.userActivation.isActivein the shell.isTrustedclick saves.3. The account menu's switch, a no-script form in
main's personal menu: name, Your agents, the switch, Sign out. It posts the value it switches to, withreturnset to the page. On the overhaul's component set, the item is the switch: amenu-itemwithrole="switch"andaria-checked, thekeyboardicon, and core'sswitchdrawn at its end in the item's state. Core'sfieldsandmenuschunks gained the two selectors that draw it. The account menu is 248px wide, up from 220, so the label stays on one line beside the switch."Before" is this branch's page with the switch's form removed in the browser, which is exactly
main's account menu.ViewerApi.tsreads the form before the session, so a signed-out post that namesreturngoes back to that page, whose own door signs in there.4. D1's note. The note shows to a viewer whose setting is Off, on a version from 0.33.0 on that doesn't claim
shortcutSetting, unless its recorded imports leave outpatchy/hotkeys.shortcutSetting: 1(MANIFEST_CAPABILITIESin@patchy/api). A single HTML file may carry an older SDK bundled inline, so it claims nothing.patchy/hotkeysinsdkImportsgets no note. A single file records no imports, so the release rule decides: from 0.33.0 on, the note shows.localStorage.5. The flow, desktop then phone. The sheet's row leads to Patchy's dialog, Turn off brings the sheet back on its row reading Off, then the account menu turns them back on.
flow-desktop.mp4
flow-phone.mp4
How it was verified
Unit (vitest), with the rest of the stack's touched files: 35 files, 330 tests, plus core's style rules, gallery and served-style pin (358 with
render.test.ts):render.test.ts: the frame's name afterdata-waitingin static markup, and that it is the only difference from an unnamed frame. A public shell refuses a viewer's setting.ignoresShortcutSetting's cases.html.test.ts: the account menu's switch, its value, itsreturn, and escaping.ViewerApi.test.ts: a signed-out form post goes back to its page.devServer.test.ts: each dev person's own setting, and the route, which writes the file before it changes what shells read.executeConfig.test.ts: a repo build's manifest recordsshortcutSetting.served-styles.test.ts: the served styles' digest moved on purpose, for the one rule that keeps the dialog's tag whole.The browser tier (
test/browser-tier1/shortcut-setting.spec.ts): thirteen tests on published patches through the real shell and broker, as reviewed. That includes the committed 0.38 bundle (hotkeys-0.38.html), whose shortcuts still fire under this shell with Off stored, with no row and with the note.channel: "chromium", frame isolated, from a local confighotkeys.spec.tsandfocus.spec.tspass in both as well. Company patches put the setting's row first in the sheet's Tab order. The unnamed-frame test opens a public patch.The whole tier 1 suite at this stack's top (
06476fe), aspnpm verifyruns it in CI's headless shell: 168 of 168. At the previous push, with ci: the browser tier runs desktop Chromium, where a patch's frame has its own process #1302's desktop project as well, it also passed 168 of 168.The rollback rehearsal, against the live release 41 (
7f93b91):7f93b91 → 06476fe → 7f93b91 → 06476fe, all four steps passed in 116 s. It covers feat(companies): Patchy stores each person's single-key shortcut setting #1276's migration, and the live release serving a repo build that this head's CLI wrote withshortcutSetting.pnpm verifyat this head: format, lint, typecheck, synth, postgres-concurrency, cli-smoke, install, tier2-smoke and browser pass.testandtest (bun)had 15 timeouts while the machine's load average was near 30. All 11 files rerun alone pass (216 tests), as does Bun'sPatchesApi(63). The previous push'spnpm verifypassed every step. The served shell's page state is exempt from the page-markup rules in.oxlintrc.json, andshortcuts.tsjoinsstream-status.tsanddownloads.tsthere for the same reason.Hit every surface.
docs/API.mdis regenerated and current.patchy-hotkeysproject skill and the capability catalogue. No command, flag or exit code changed.docs/DEVELOPMENT.mdand thepatchy-dev-loopskill.docs/product.md.ui-consistencyspec names the menu's switch, the dialog and note in the shell's exception, andshortcuts.tsin the lint exemption.Not run on this head: Firefox and WebKit. Firefox passed 12 of 13 before the port, the tier 2 test being Chromium-only. WebKit can't launch here, and CI has no WebKit.
Release impact
The release that carries this carries the whole stack. Nothing needs action. A viewer's shortcuts stay on until they turn them off, and patches published before it behave as they did until rebuilt.
Suggested
patchChangesline for the release, beside #1279's:Landing note: #1276's migration is
0038_single_key_shortcuts, above #1217's0037_feedback. If another migration lands first, it renumbers.shortcutSetting: 1in the manifests of repo builds published meanwhile. The release before reads stored manifests without refusing extra keys, and in the rehearsal it served a version that carried the field.localStorage.Built by Claude Opus 5.5 (
claude-opus-5-5) in Claude Code, through T3 Code.