Image
Image with loading skeleton, fallback, aspect ratio, caption, and border radius.
Installation
Examples
Variants
cover, contain, and fallback modes.
Cover
Full radius
Fallback
With caption
Figure with accessible figcaption.
API Reference
| Prop | Type | Default | Description |
|---|---|---|---|
| src* | string | required | Image source URL. |
| alt* | string | required | Accessible description. |
| fallback | ReactNode | — | Shown when the image fails to load. |
| aspectRatio | number | — | Width/height ratio. |
| objectFit | 'cover'|'contain'|'fill' | 'cover' | CSS object-fit value. |
| caption | string | — | Figure caption. |
| rounded | 'none'|'sm'|'md'|'lg'|'xl'|'full' | 'md' | Border radius. |