
<Stack style={{ maxWidth: "18rem" }}>
<ImageScrub
images={[{ url: "/share.png", alt: "Picture 1" }, { url: "/apple-touch-icon.png", alt: "Picture 2" }, { url: "/logo.svg", alt: "Picture 3" }]}
aspectRatio="1 / 1"
fit="contain"
rounded
/>
</Stack>import { ImageScrub } from "@dash/server";Prop | Type | Description |
|---|---|---|
| images (required) | ImageScrubItem[] | |
| aspectRatio | string | number | The box's shape, kept while scrubbing between pictures of any size: `"1 / 1"` (default), `"4 / 3"` or `1.5`. |
| fit | "cover" | "contain" | How each picture fills the box (default `cover`). |
| loading | "lazy" | "eager" | `lazy` (default) defers the first picture until it nears the viewport. The others load on first interaction. |
| rounded | boolean | "full" | Corners follow the theme: `true` is `--radius`, `"full"` is `--radius-full`. |
| positionLabel | string | The position announced to assistive technology, with `{{current}}` and `{{count}}`. Set by the client from `dash.imageScrub.position`. |