Skip to content
Postkit

Device. A screenshot in a plain iPhone, iPad or Mac frame drawn with CSS, with an optional caption.

  • Media
  • Static
  • Stability · Experimental
  • ::postkit-device
Abstract Postkit editorial artwork on a phone screen
A screenshot in a plain, CSS-drawn frame.

Usage.

<Device
  kind="iphone"
  src="/component-preview.svg"
  alt="Abstract Postkit editorial artwork on a phone screen"
  caption="A screenshot in a plain, CSS-drawn frame."
/>

Props. Always in step with the code.

PropTypeDefaultDescription
kind"iphone" | "ipad" | "mac""iphone"The device frame: iphone (with a notch), ipad, or mac (a laptop with its base).
srcRequiredstringNoneThe screenshot URL.
altRequiredstringNoneAlternative text that describes what the screenshot shows.
captionstringNoneVisible supporting text below the device.
Appearance
size"sm" | "md" | "lg""md"The component density and type scale.
variant"outline" | "subtle" | "plain""subtle"The component visual treatment.

Every component also takes unstyled and the part-styling props. Change a default for your whole site with defaults in createPostkit. Part styles

Anatomy. Every part is yours to restyle.

Every part

  • root
  • frame
  • notch
  • screen
  • image
  • base
  • figcaption
  • number
  • caption

Renderers. One component, everywhere you publish.

  • Headless @postkit/reactSupported
  • Chakra @postkit/chakraSupported
  • Email @postkit/emailAs text
  • Astro @postkit/astroStatic
  • Web components @postkit/elementsPlanned
Postkit

Richer posts, written once, right everywhere.

© 2026 Postkit. MIT licensed.
LicensingPrivacy