#966
Autoplay
A looping three-quote carousel that advances every 4 seconds, with a Pause button and no arrows.
Hand this to your AI. It names the exact library parts, timings and accessibility promises of this demo.
Build the "Autoplay" pattern (@codeatlasdev/ui demo #966, display/carousel) in my app.
Call get_demo({ ids: ["#966"] }) first and keep its structure. It needs @codeatlasdev/[email protected].
Use: Rotating testimonials or announcements; autoplay is opt-in and always stoppable.
Keep these library parts, with the props and tokens the demo uses:
- Carousel, CarouselItem from "@codeatlasdev/ui"
Behaviour to keep:
- `<Carousel label="Customer quotes" autoplay={4000} loop arrows={false}>`
- Each slide is `<CarouselItem><blockquote class="quote">{quote}</blockquote></CarouselItem>`
- `quotes` holds three short strings
Reduced motion: the demo handles it; keep that branch.
Keyboard: operable; keep the focus order and key handling.
Change only the copy and the data. Use the theme tokens (--ca-*), never raw colours. Library parts
- Carousel
@codeatlasdev/ui - CarouselItem
@codeatlasdev/ui
How it is built
- `<Carousel label="Customer quotes" autoplay={4000} loop arrows={false}>`
- Each slide is `<CarouselItem><blockquote class="quote">{quote}</blockquote></CarouselItem>`
- `quotes` holds three short strings
Related
Loading source.