Blur image
An image that sharpens into place over a blurred placeholder at its final size, and shows its description if it fails.
When to use
- Galleries, product images and avatars from slow sources.
- Feeds where layout must not jump.
When not to use
- Icons and small UI images; they load instantly.
Installation
terminal
pnpm dlx shadcn@latest add @caliper/blur-image
Adds its 2 files to components/ui/, each with its own stylesheet, and installs their packages. Pro installs with your access token, set up once per project. See Pro access. The first part also adds Caliper UI’s tokens; import them once as in Installation.
API reference
BlurImage
4 props
Also accepts the native props of its root element and a ref.
PropTypeDefaultDescription
width *number—Intrinsic size, so the space is held before it loads.
height *number—
placeholderstring—A tiny data URL or a CSS colour shown blurred until the image arrives.
imgClassNamestring—
Keyboard
- No custom key handling; Tab and the native activation keys do the work.
Accessibility
It exposes img semantics, with aria-label and aria-hidden kept in step with state.
Notes for AI
Give your coding assistant this page as Markdown instead of screenshots: the props, keyboard and examples in one file.
/docs/components/blur-image.mdThe index of every part is at /llms.txt.
More in Media
RevealUncovers an image or a section as it scrolls into view, or when told to: a wipe from any edge, an iris from the middle, or blinds that open in stripes. Every effect cuts the content itself, and the content settles from a touch larger behind the edge.Moon phaseThe moon for a date, or for a phase you give it. The lit part is a half disc closed by the terminator; when the date changes, the terminator sweeps to the new phase by the shortest way round.Tilt cardA card that tilts toward the pointer with a soft highlight.