docs / patterns / mockup-showcase
MockupShowcase
browser or device chrome around whatever you put inside: a next/image, a bare img, a video or a live iframe. the frame is the value.
intensity · structuresrsc · server
provenance
shaped from personal-websitelayer
core / patternsintensity
structures · organizes a region, stays out of the contentcomposition
the visual slot of HeroSplit, a case study, a feature sectionchildren keep their own alt text and semanticsnot a window manager. nothing inside the chrome is interactivenever nested in another MockupShowcasea11y
the chrome, dots and address bar are allaria-hidden · the media carries its own altjest-axelive demo · try it out
your screenshot here
customize
framewhich chrome to draw
aspectaspect-ratio of the media well
urladdress bar text, browser frame only
usage
import { MockupShowcase } from "@usva-ui/react/patterns/mockup-showcase";
<MockupShowcase url="usva.dev">
<Image src={shot} alt="The usva docs homepage" />
</MockupShowcase>props
| prop | type | default | notes |
|---|---|---|---|
| frame | "browser" | "device" | "none" | "browser" | which chrome to draw. |
| url | string | — | decorative text in the browser address bar. |
| aspect | string | "16/10" | any CSS aspect-ratio value. |
| children | ReactNode | — | the media. stretched to fill the well, whatever element it is. |
get it
bun add @usva-ui/reactusage
import { MockupShowcase } from "@usva-ui/react/patterns/mockup-showcase";
<MockupShowcase frame="browser" url="usva.dev">
<Image src={shot} alt="The usva docs homepage" />
</MockupShowcase>