Carousel
A scrollable content slider with snap-point navigation, previous/next buttons, and keyboard support.
Default
Carousel with three slides and navigation buttons.
Slide 1
Slide 2
Slide 3
With Cards
Carousel slides containing Card components.
1
2
3
Loop
Carousel that loops back to the beginning.
Slide A
Slide B
Slide C
Usage
julia
using Suite
Carousel(
CarouselContent(
CarouselItem(Card(CardContent(P("Slide 1")))),
CarouselItem(Card(CardContent(P("Slide 2")))),
CarouselItem(Card(CardContent(P("Slide 3")))),
),
CarouselPrevious(),
CarouselNext(),
)API Reference
Carousel
| Prop | Type | Default | Description |
|---|---|---|---|
| orientation | String | "horizontal" | Scroll direction: "horizontal" or "vertical" |
| loop | Bool | false | Whether to loop back to start |
| autoplay | Bool | false | Whether to auto-advance slides |
| autoplay_interval | Int | 4000 | Milliseconds between auto-advance |
| children | Any | - | CarouselContent, CarouselPrevious, CarouselNext |
| class | String | "" | Additional CSS classes |
Sub-components
| Component | Description |
|---|---|
| CarouselContent | Scrollable container for carousel slides |
| CarouselItem | A single slide within the carousel |
| CarouselPrevious | Previous slide navigation button |
| CarouselNext | Next slide navigation button |