Skip to content

fix: make the playground responsive on mobile - #350

Merged
Ghadi8 merged 2 commits into
mainfrom
ghadi/playground-mobile
Sep 23, 2026
Merged

Ghadi8 merged 2 commits into
mainfrom
ghadi/playground-mobile

Conversation

@Ghadi8

@Ghadi8 Ghadi8 commented Sep 23, 2026

Copy link
Copy Markdown
Member

What

The playground (/core and /wagmi) now works on phones. Below 768px the method list fills the screen,
tapping a method opens it full screen with a "‹ Methods" back button, and going back returns you to the
same spot in the list. Desktop looks exactly as before.

Why

The shell used a fixed two-column grid (334px | 1fr) inside an h-screen overflow-hidden wrapper. On a
phone that left the method panel about 50px wide, so the playground could not be used at all.

The sidebar is the navigation, so mobile shows the list and the detail one at a time instead of hiding
the sidebar in a drawer. The page scrolls normally on mobile instead of inside a locked full-height box.
The Dialog Theme view stacks the controls above the previews rather than using the list/detail flow,
because the two are meant to be used together.

Every mobile change is a max-md: / max-sm: class, or a base class whose desktop value moved behind
md:, so layout from 768px up is unchanged. The other mobile fixes:

  • Info popovers open as a sheet along the bottom of the screen. Their fixed widths (352px / 290px),
    anchored to the right of the trigger, ran off the left edge.
  • The header's SDK row hides its "SDK" label and uses less padding on its package buttons. Without this
    it was 343px wide and scrolled sideways on 320px screens.
  • Method titles are smaller and can break anywhere, so long names like wallet_revokePermissions wrap.

The landing page already fit phone screens and is untouched.

Closes

How to test

bun install
bunx nx run-many -t typecheck lint test --projects=@jaw-mono/playground
bunx nx build @jaw-mono/playground

Run bunx nx dev @jaw-mono/playground and check both /core and /wagmi.

Desktop (≥768px): should look exactly as before. Before and after screenshots at 1440, 1024 and 768px are
pixel-identical for the landing page, both SDK pages with a method open, and the Dialog Theme view.

Mobile (devtools at 390px and 320px, or a real phone):

  • The method list fills the screen and nothing scrolls sideways.
  • Tapping a method opens it full screen, scrolled to the top, with "‹ Methods" at the top left.
  • "‹ Methods" returns to the list at the scroll position you left.
  • The ⓘ next to a method, and the one next to the SDK switch, open a sheet along the bottom of the
    screen, inside the viewport.
  • Dialog Theme shows the controls with the previews below them.
  • Code Snippet, View Config and a Utility method all fit the width. Wide code scrolls inside its own box.

@vercel

vercel Bot commented Sep 23, 2026 •

Copy link
Copy Markdown

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

Project Deployment Actions Updated
demo Ready Ready Preview Sep 23, 2026 12:55pm UTC
jaw-docs Ready Ready Preview Sep 23, 2026 12:55pm UTC
keys-jaw-id Ready Ready Preview Sep 23, 2026 12:55pm UTC
playground Ready Ready Preview Sep 23, 2026 12:55pm UTC

Request Review

@justalab-agents justalab-agents Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Findings outside the diff

These sit on lines this PR did not change, but this PR is what makes them wrong. They cannot be posted as inline comments.

Reviewer callouts (1)

Non-blocking observations. Nothing here needs to change before merge.

  • .github:1 — "The ubuntu-latest label will migrate to Ubuntu 26 beginning October 19, 2026. For more information, see actions/runner-images#14748"

This branch was successfully deployed

4 active deployments
Preview – jaw-docs — 48a0e4ff Deployed Sep 23, 2026 by vercel[bot]
Preview – demo — 48a0e4ff Deployed Sep 23, 2026 by vercel[bot]
Preview – playground — 48a0e4ff Deployed Sep 23, 2026 by vercel[bot]
Preview – keys-jaw-id — 48a0e4ff Deployed Sep 23, 2026 by vercel[bot]
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.

1 participant