Skip to content
caliper ui docs

Pro

Cylinder carousel

Items arranged around a rotating cylinder.

Pro
pnpm dlx shadcn@latest add @caliper/cylinder-carousel

Start the Northwind site

Dashboard opens in the editor

Launch page

Marketing

Docs home

Docs

Pricing

Marketing

Changelog

Docs

Dashboard

App

Settings

App

Sign in

Account

Empty state

App

Dashboard selected, 5 of 8

Installs components/ui/cylinder-carousel.tsxDepends on none beyond ReactMotion honours reduced motion

When to use

Use it for

  • A showpiece for a small set of visuals.
  • Playful landing pages.

Skip it when

  • The items carry detailed text.
  • Accessibility of every item must be quick to reach; prefer a list.

Installation

terminal
pnpm dlx shadcn@latest add @caliper/cylinder-carousel

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.

Usage

Import it from your copy of the source. The example behind the preview comes with the source.

example.tsx
import { CylinderCarousel } from "@/components/ui/cylinder-carousel"

The worked example comes with Pro

The 52-line example behind the preview opens here, ready to copy.

  • 626 Pro parts, blocks and page templates, all with source
  • $149 once, with lifetime updates. No renewal
  • A full refund within 14 days if it is not for you
Checking your licence…

API reference

CylinderCarousel

component
PropTypeDefaultDescription
label *string—
items *readonly CylinderItem[]—
valuestring—
defaultValuestring—
onValueChange((id: string) => void)—
itemWidthnumber150Card size in pixels; the ring's radius follows from it and the card count.
itemHeightnumber200
classNamestring—

Accessibility

It exposes listbox, option and status semantics, with aria-label, aria-orientation and aria-selected kept in step with state. Changes that matter are announced through a live region.

KeyBehaviour
→Moves to the next item or value.
↓Moves to the next item or value.
←Moves to the previous item or value.
↑Moves to the previous item or value.
HomeJumps to the first item or the minimum.
EndJumps to the last item or the maximum.

Motion

It checks prefers-reduced-motion itself and settles immediately instead of travelling. Every state is still reachable.

All Compare & browse examples