iPhone

A responsive iPhone frame component that wraps any content inside a realistic iPhone 18 Pro or 18 Pro Max display, with portrait and landscape orientations.

iphone-01

iphone-02

iphone-03

iphone-04

iphone-05

Installation

pnpm dlx shadcn@latest add https://designali.com/r/iphone.json

Usage

import { IPhone } from "@/components/ui/iphone"
<IPhone>
  <div className="p-6">Your content here</div>
</IPhone>

Variant

<IPhone variant="18-pro-max">
  <div className="p-6">iPhone 18 Pro Max</div>
</IPhone>

Size

<IPhone size="lg">
  <div className="p-6">Large iPhone</div>
</IPhone>

Orientation

<IPhone orientation="landscape">
  <div className="p-6">Landscape iPhone</div>
</IPhone>

Color

<IPhone color="burgundy">
  <div className="p-6">Burgundy iPhone</div>
</IPhone>

Custom frame image

<IPhone>
  <div className="p-6">Custom frame</div>
</IPhone>

Props

PropTypeDefault
childrenReactNode—
classNamestring—
variant"18-pro" | "18-pro-max""18-pro"
size"sm" | "md" | "lg" | "xl""md"
orientation"portrait" | "landscape""portrait"
color"black" | "glacier" | "silver" | "burgundy""silver"

Notes

  • The screen area is an absolutely positioned container, so children scroll vertically inside it when they overflow.
  • The iPhone is sized by height, and the width follows from the aspect ratio (9/19.5 in portrait, 19.5/9 in landscape).
  • All four colors are available for both variants.
  • Passing image overrides variant, orientation and color for the frame.