Public: anyone can read this; the crew can change it.

The command palette is great on a phone: one tap, type, go, like Spotlight #10651

Parked opened this in answer to
Closed without merging

The palette now opens as a full-screen sheet on a phone, but I haven't tried it on one. There's no Playwright run or screenshot in this pull, and no check of the sheet at 390×844 or as an installed PWA. The headless Chromium test in test/web-phone.test.ts skips here because no Chromium starts in this sandbox.

Notes

stopped parked by the crew deploy 7e01fa4

opened this

The palette now opens as a full-screen sheet on a phone, but I haven't tried it on one. There's no Playwright run or screenshot in this pull, and no check of the sheet at 390×844 or as an installed PWA. The headless Chromium test in test/web-phone.test.ts skips here because no Chromium starts in this sandbox. I didn't touch the existing palette tests, and the new ones in test/palette.test.ts pass. Type-check and scripts/gate.ts are clean, and the forge's check runs on the push. bun scripts/design-lint.ts still flags .keyhint, which isn't from this change. The side-by-side screenshots of the old mobile search and the palette that @trevato asked for are also missing, so I can't yet say what was kept from each.

What changed

  • One tap to open: a "Search" button sits bottom-right on screens under 720px, shown only when JavaScript is on. The topbar's phone search icon (it used to link to /search) now opens the palette too. Without JavaScript it still goes to /search. The input is focused in the same tap, and ⌘K, Ctrl-K and / still work on a keyboard.
  • Sheet layout (src/web/style/components.ts): the sheet fills the screen and the results scroll inside it. The page underneath doesn't scroll. It respects safe areas, rows are at least 44px tall, and a grip bar sits at the top.
  • Keyboard and swipe (src/web/client.ts): the sheet resizes to visualViewport, so the keyboard doesn't cover results. A downward swipe from the top of the list closes it. Escape already did.
  • Tests: test/palette.test.ts gains cases for these. Typing "paper" ranks trevato/morning-paper first. "mp" finds it. An empty query lists recents first. The shell script carries the visualViewport sheet code.
  • Design area: docs/design/areas/palette.md names .palette-fab, .palette-grip and the existing palette classes the design lint asked for.

Not done

  • Playwright run and screenshot: the phone-size run from the issue and the screenshot for the pull.
  • Merging the mobile search with the palette: the /search page remains a separate surface. I only pointed the phone search icon at the palette.
  • Result types: I didn't check that issues, pulls and people show up in the results. That depends on what the palette index and /api/v1/search already return.

To try it On the preview, open any page at phone width and tap Search. Type "paper" and open trevato/morning-paper. Then swipe down to close it, or check the keyboard on a real iPhone.

🤖 Generated with Claude Code

Closes #10435

3 earlier comments
commented

The palette now opens as a full-screen sheet on a phone, but I haven't tried it on one. There's no Playwright run or screenshot in this pull, and no check of the sheet at 390×844 or as an installed PWA. The headless Chromium test in test/web-phone.test.ts skips here because no Chromium starts in this sandbox. I didn't touch the existing palette tests, and the new ones in test/palette.test.ts pass. Type-check and scripts/gate.ts are clean, and the forge's check runs on the push. bun scripts/design-lint.ts still flags .keyhint, which isn't from this change. The side-by-side screenshots of the old mobile search and the palette that @trevato asked for are also missing, so I can't yet say what was kept from each.

What changed

  • One tap to open: a "Search" button sits bottom-right on screens under 720px, shown only when JavaScript is on. The topbar's phone search icon (it used to link to /search) now opens the palette too. Without JavaScript it still goes to /search. The input is focused in the same tap, and ⌘K, Ctrl-K and / still work on a keyboard.
  • Sheet layout (src/web/style/components.ts): the sheet fills the screen and the results scroll inside it. The page underneath doesn't scroll. It respects safe areas, rows are at least 44px tall, and a grip bar sits at the top.
  • Keyboard and swipe (src/web/client.ts): the sheet resizes to visualViewport, so the keyboard doesn't cover results. A downward swipe from the top of the list closes it. Escape already did.
  • Tests: test/palette.test.ts gains cases for these. Typing "paper" ranks trevato/morning-paper first. "mp" finds it. An empty query lists recents first. The shell script carries the visualViewport sheet code.
  • Design area: docs/design/areas/palette.md names .palette-fab, .palette-grip and the existing palette classes the design lint asked for.

Not done

  • Playwright run and screenshot: the phone-size run from the issue and the screenshot for the pull.
  • Merging the mobile search with the palette: the /search page remains a separate surface. I only pointed the phone search icon at the palette.
  • Result types: I didn't check that issues, pulls and people show up in the results. That depends on what the palette index and /api/v1/search already return.

To try it On the preview, open any page at phone width and tap Search. Type "paper" and open trevato/morning-paper. Then swipe down to close it, or check the keyboard on a real iPhone.

🤖 Generated with Claude Code

commented

On a phone (under 720px), the command palette is now a full-screen sheet that follows visualViewport, so the keyboard never covers results. This push fixes the design-check failures from the last run.

What changed

  • Sheet: A one-tap .palette-fab search button sits at the bottom right and a .palette-grip bar shows the sheet can be swiped down to close. The CSS is in src/web/style/components.ts, with the small script in src/web/client.ts and layout.ts.
  • Cause of the failures: My earlier commit had overwritten docs/design/areas/palette.md with a short stub. That erased the original class documentation, and the design lint then rejected .keyhint and the other palette classes.
  • Fix: I restored the original file and added a "On a phone" section naming .palette-fab and .palette-grip.

Checks run

  • bun scripts/design-lint.ts is clean.
  • bun x tsc --noEmit is clean.
  • test/design-lint.test.ts, test/shared-red.test.ts and test/palette.test.ts pass, 72 tests.

Not fixed

  • Three other failures from the check ran in shards 15 and 47: "SSH key-exchange order > a second KEX_ECDH_INIT…" and two pull-page tests, "the pull page's check is a line with a dot…" and "the pull list wears a dot per row…".
  • My diff touches none of the SSH or pull-page code, so I did not change them. I did not run them here, so I don't know if they fail on their own or only in the full run. If they come back red on this push, they need a separate look.

To try it: open the preview on a phone, tap Search at the bottom right, type "paper" and open trevato/morning-paper. Swiping down closes the sheet.

🤖 Generated with Claude Code

commented

On a phone (under 720px), the command palette is now a full-screen sheet that follows visualViewport, so the keyboard never covers results. The last check failed on two page-size tests; I've fixed those and pushed. I didn't see the result of the new check run.

What changed

  • Sheet: a .palette-fab button at the bottom right opens the palette with one tap. A swipe down from the top of the sheet closes it. The CSS is in src/web/style/components.ts, the script in src/web/client.ts, and the markup in src/web/layout.ts.
  • Cause of the failure: test/pull-quiet.test.ts caps the pull page and the pull list at a byte budget, and the new button and grip pushed both over it.
  • Fix: the grip is now a .palette::before pseudo-element instead of an extra element, so it no longer adds markup. I dropped the fab's redundant aria-label and type="button", and rewrote the swipe and keyboard script more compactly.
  • Docs: docs/design/areas/palette.md keeps its original content, with an "On a phone" section naming .palette-fab and the grip.

Checks run: bun x tsc --noEmit and bun scripts/design-lint.ts are clean. test/pull-quiet.test.ts and test/palette.test.ts pass, as does test/design-lint.test.ts (checked before the last trim).

Margin: the pull page now sits under its budget by only a few bytes. A later change to the page may need a budget bump.

To try it: on a phone, open the preview, tap Search at the bottom right, type "paper" and open trevato/morning-paper. Swiping down closes the sheet.

🤖 Generated with Claude Code

commented

Parked by the crew: the check stayed red through 2 automatic tries

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs