Skip to content

Remove the remaining capsule buttons and fix the crushed suggestion card - #89

Merged
mohabbis merged 1 commit into
mainfrom
claude/marketing-site-redesign-1us9ro
Sep 6, 2026
Merged

Remove the remaining capsule buttons and fix the crushed suggestion card#89
mohabbis merged 1 commit into
mainfrom
claude/marketing-site-redesign-1us9ro

Conversation

@mohabbis

@mohabbis mohabbis commented Sep 6, 2026

Copy link
Copy Markdown
Owner

Follow-up to #88, which missed both of these.

Capsule buttons

In #88 I filed everything in simulator.css as "in-phone, so iOS convention applies" and left it. That was wrong twice over.

Two of those buttons are not in the phone at all — "Expand preview" and the focus-mode "Close" are the site's own preview chrome and have no native counterpart.

The in-phone ones were wrong on the facts. All three Swift consent sheets build their confirm button with RoundedRectangle(cornerRadius: 18):

// SceneApprovalSheet.swift:98, LumenActionView.swift:98, LumenReasoningView.swift:173
.background(Color.lumenAccent, in: RoundedRectangle(cornerRadius: 18))

The Capsule() calls sitting near them are the sheet grab handles. So the mock's fully-rounded Apply button — the most prominent control in the whole preview — was a fidelity bug against the app it mirrors, not a deliberate convention.

Button Was Now Why
.demo-openapp "Expand preview" 99px 12px Site chrome, no native counterpart
.app-fullscreen-close "Close" 99px 10px Site chrome
.sheet-apply / -static "Apply" 99px 7px Stage-scale equivalent of the native 18pt
.room-empty-cta "Add a device" 99px 7px Mirrors EmptyStateView

EmptyStateView was the one native button still using Capsule(); it is now RoundedRectangle(18) like every other primary button in the app, so the mock and the app still agree rather than the web quietly diverging.

Everything still capsule is capsule in the native app too: progress bars, slider tracks, sheet grab handles, the iOS switch, the toast. Four unreferenced rules (.chat-chip, .chapter-strip button, .try-it-pill, .coming-pill) are deleted — they rendered nowhere and were the confusing part of auditing this file for capsules.

The crushed "Lumen noticed" card

.app-screen is a column flex container, and its children default to flex-shrink: 1. A screen taller than the stage therefore squeezed the last row instead of scrolling, and overflow-y: auto never engaged because flexbox shrinks before it scrolls.

The card carrying the entire product pitch was collapsing from 106px of content into a 14px sliver:

Viewport .noticed-card before After
1440×900 106 → 70px (clipped) full, above the fold
1024×800 106 → 14px full, screen scrolls
1280×720 106 → 14px full, screen scrolls

Children now hold their natural height and the screen scrolls, which is what the real phone does.

That alone still left the card below the fold on load — and it was missing by only 5px at 1440×900, the most common laptop size. Tightening the preview's own gap/padding and lifting the stage from 80vh to 82vh brings it fully into view at 1440×900, 1512×982 (MacBook Pro 14"), taller desktops, and mobile. Below ~1050px of viewport height it sits below the fold and the screen scrolls to it, same as a real phone.

Tests

Two e2e tests added. Each was confirmed to fail against the old CSS before being kept, so neither is vacuous:

  • preview rows keep their height instead of being crushed — asserts no .app-screen child has scrollHeight > clientHeight at 1280×720

  • no button in the preview or its chrome is capsule-shaped — walks every visible button with the reasoning sheet open (percentage radii skipped, so circular icon buttons still pass)

  • npm run lint clean

  • npm run test 29/29

  • npm run build clean

  • npm run e2e 10/10

Note for review

The EmptyStateView.swift change is a one-line shape swap and is unverified — the iOS lane cannot be built on Linux, so it has not been compiled. Worth a glance.

🤖 Generated with Claude Code

https://claude.ai/code/session_01WmouTty4UranwAXwByjsKy


Generated by Claude Code

Two problems the first pass missed.

Capsule buttons. I filed everything in simulator.css as "in-phone, so iOS
convention applies" and left it. Two of those were not in the phone at all:
"Expand preview" and the focus-mode "Close" are the site's own preview chrome
and had no native counterpart. The in-phone ones were wrong on the facts as
well: all three Swift consent sheets build their confirm button with
RoundedRectangle(cornerRadius: 18), and the Capsule() calls near them are the
sheet grab handles. So the mock's fully-rounded Apply button was a fidelity bug
against the app it mirrors, not a deliberate convention.

Site chrome moves onto the site's radius scale, and the sheet buttons to the
stage-scale equivalent of 18pt. EmptyStateView was the one native button using
Capsule(); it is now RoundedRectangle(18) like every other primary button in
the app, so the mock and the app still agree. That Swift change is unverified
here, since the iOS lane cannot be built on Linux.

What remains capsule is capsule in the native app too: progress bars, slider
tracks, grab handles, the switch and the toast. Four unreferenced rules
(.chat-chip, .chapter-strip button, .try-it-pill, .coming-pill) are deleted;
they rendered nowhere and were the confusing part of auditing this file.

Crushed card. .app-screen is a column flex container whose children default to
flex-shrink: 1, so a screen taller than the stage squeezed the last row instead
of scrolling: the "Lumen noticed" card collapsed from 106px of content into a
14px sliver at 1024x800 and 1280x720, and clipped at 1440x900. overflow-y: auto
never engaged because flexbox shrinks before it scrolls. Children now hold
their natural height and the screen scrolls.

That leaves the card below the fold on shorter viewports, which is what a real
phone does, but it was also missing the fold by 5px at 1440x900. Tightening the
preview's gap and padding and lifting the stage from 80vh to 82vh brings the
card fully into view at 1440x900, 1512x982 and above, and on mobile.

Both defects are now covered by e2e tests, each confirmed to fail against the
old CSS before being kept.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WmouTty4UranwAXwByjsKy
@vercel

vercel Bot commented Sep 6, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
lumen-idpz Ready Ready Preview Sep 6, 2026 4:08am UTC

Request Review

@mohabbis
mohabbis marked this pull request as ready for review September 6, 2026 04:09
@mohabbis
mohabbis merged commit 846120b into main Sep 6, 2026
5 checks passed
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-09-06T04:09:55.191547Z 827d9df Draft marked ready
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants