Responsive Shell
FreeBuild an application shell that works at 390px and on a laptop: navigation, scroll, and safe targets.
Purpose
Prevent desktop-only sidebars that overflow or trap focus on a phone.
Procedure
--- name: responsive-shell description: Build an application shell that works at 390px and on a laptop: navigation, scroll, and safe targets. ---
Responsive Shell
Purpose
Prevent desktop-only sidebars that overflow or trap focus on a phone.
Procedure
Design the 390px width first.
Navigation:
- Persistent sidebar only from the large breakpoint up.
- Below that, the sidebar is a panel closed by default. Opening it traps interaction until it is dismissed. The control is a real button with a visible name ("Menu"), not a mystery icon.
- The current page is indicated by more than color (weight or a bar).
- Do not put more than one row of wrapping icon buttons in the header.
Page:
- The document itself does not scroll sideways. Wide tables scroll inside their own region with a caption.
- Sticky headers must not cover focused fields. Account for the header height.
- Primary actions stay reachable. Do not pin two competing bars to the bottom.
Check:
- 200% zoom still reaches the close control.
- The first focusable control in the panel is sensible.
- Content padding is at least 16px on the narrow width.
Do not build a separate mobile site or user-agent sniff.
Example requests
1. Make the shell usable on a phone
Request: Apply Responsive Shell. Keep the same destinations. No new pages. Expected: A dismissible navigation panel, no horizontal page scroll, and 44px targets.
Dependencies
None. Work in the repository that is already open. Do not add packages unless the procedure names one.
Compatibility
This document follows the Agent Skills layout (a folder named responsive-shell containing SKILL.md). Claude Code, Cursor, Codex, and Gemini CLI can load that file from the paths in the Skilling installation guide. GitHub Copilot does not load SKILL.md. Use the Copilot instructions copy, and narrow applyTo before you commit it.
Example prompts
Make the shell usable on a phone
Apply Responsive Shell. Keep the same destinations. No new pages.
Expected: A dismissible navigation panel, no horizontal page scroll, and 44px targets.
Choose the agent
This skill is installed for one agent at a time. Pick the section you are using.
Related
- Interface Craft
Design a screen around one job, one primary action, and the empty, loading, and error states before any decoration.
- Navigation IA
Name destinations by the user's job and keep the nav short enough to scan.
- SaaS Dashboard
Structure an operational dashboard: status first, then the queue of work, then detail. No vanity metrics.
Reviews
No reviews yet.
Sign in to review.
Report a problem
Inaccurate steps, an unsafe instruction, or a licensing concern.
Sign in to report.