This page as markdown: /phone.md · Index for agents: /llms.txt · Everything in one file: /llms-full.txt

Phone

Status: stable

A current smartphone frame at iPhone proportions: a dark body with a titanium band, thin bezels, an island, an optional status bar and a scrollable screen.

Keywords: phone, device mockup, mobile preview, frame

Usage

Use Phone to frame a mobile product preview when the device context is useful.

Best practices

Props

Name Type Default Description
children ReactNode — Content rendered inside the scrollable screen region.
statusBar boolean true Draw a status bar (time, signal, battery) across the top of the screen. Turn it off to frame a screenshot that already has one.
systemChrome boolean true Draw the camera pill and home indicator. Turn it off when the content draws its own system chrome, such as an iOS prototype framed by PhoneFrame from @sableui/react/ios/preview.
className string — Additional classes merged onto the outer wrapper (set the width here; the screen keeps its proportions).

Tokens used

background, foreground

Accessibility

Related

Examples

Framing a mobile layout

import { Phone } from "@sableui/react"

<Phone><div className="p-4"><h2 className="text-title-lg">Activity</h2><p className="text-body-sm text-muted-foreground">3 new orders today.</p></div></Phone>

Mockup, not a responsive preview

import { Phone } from "@sableui/react"

// Phone is DECORATIVE framing for a mobile screenshot on a marketing surface.

<Phone>
  <img src="/screenshots/mobile.png" alt="The mobile app" />
</Phone>

// ✗ Using it to test responsive layout. The frame is a fixed aspect box, not a
//   viewport — media queries inside it key off the real window, so what you see
//   is not what a phone renders. Resize the browser, or use device emulation.
// ✗ Wrapping live, interactive app UI (forms, buttons that act). Same as Browser: the frame says "picture of
//   software", so real controls inside it read as a screenshot that moves. Static composed content is fine.
//   The exception is a clickable iOS prototype: PhoneFrame (@sableui/react/ios/preview)
//   frames a whole phone-sized document in an iframe, where the frame is the device.