Glin UI
Primitive / Moleculebeta

Circular Gallery

Tiles on a ring that rotates to the front with drag inertia, keys, click and optional autorotate.

Edit on GitHub

Installation

Install from
pnpm dlx @glinui/cli@latest add circular-gallery

Prefer the package?

Usage

Our own design (clean-room, no upstream code). Tiles sit on a ring seen from the front: the front tile is large and sharp, the others shrink, dim and blur toward the back.

Drag has inertia and eases to the nearest tile. Positions are computed in JS and written as CSS variables from a rAF loop, so a drag causes no React renders.

Compared with CylinderCarousel: the gallery is a continuous, draggable ring with a front caption and click to focus. The carousel is a step based slide show.

Variants

glinr, plain and solid tile surfaces.

Aurora
Voltage
Palette
Prism
Signal
Aurora
Voltage
Palette
Prism
Signal
Aurora
Voltage
Palette
Prism
Signal
<CircularGallery variant="plain" items={items} tileWidth={110} tileHeight={140} />

States

Auto rotate, paused by hover and focus.

Aurora
Voltage
Palette
Prism
Signal
Vault

Aurora

<CircularGallery autoRotate autoRotateInterval={2600} items={items} />

In a layout

A centered section under a heading.

Browse collections

Aurora
Voltage
Palette
Prism
Signal
Vault

Aurora

<section aria-labelledby="collections">
<h3 id="collections">Browse collections</h3>
<CircularGallery items={items} />
</section>

Accessibility

  • A listbox with option tiles, a roving tabindex and aria-current on the front tile. Back tiles are still focusable and clicking or focusing one brings it forward.
  • Arrow keys, Home and End move the front tile and focus together.
  • Drag and wheel are conveniences only, every action has a key and click equivalent.
  • Auto rotate pauses on hover, focus and drag and is off under reduced motion.

Keyboard Interactions

KeyAction
ArrowRight / ArrowLeftNext or previous tile (reversed in RTL).
Home / EndFirst or last tile.
Enter / clickBring a tile to the front.

ARIA Attributes

  • `role="listbox"` and `role="option"` tiles
  • `aria-current` and `aria-selected` on the front tile
  • `aria-posinset` and `aria-setsize`

Reduced Motion

Easing and auto rotate only run at motion level full. Otherwise the ring snaps to the chosen tile instantly.

Affected properties

rotation easinginertiaauto rotate

API Reference

PropTypeRequiredDefaultDescription
itemsCircularGalleryItem[]Yes-Tiles. The label names the tile and captions the front one.
value / defaultValue / onValueChangenumber / number / (index) => void-0Controlled or uncontrolled front tile index.
radiusnumberNofits the tilesRing radius in pixels.
tiltnumberNo8Camera tilt in degrees.
tileWidth / tileHeightnumber-150 / 190Tile size in pixels.
autoRotate / autoRotateIntervalboolean / number-false / 3200Rotate on a timer. Needs motion level full, pauses on hover, focus and drag.
wheelbooleanNofalseLet the wheel rotate the ring. Off so page scroll is never captured.
showCaptionbooleanNotrueCaption of the front tile.
variantSurfaceVariant | "default"Noambient (glinr)Tile surface.
autoRotatebooleanNofalseRotate on a timer. Needs motion level full. Pauses on hover, focus and drag.
autoRotateIntervalnumberNo3200Milliseconds between automatic steps.
defaultValuenumberNo0Auto-generated from TypeScript source.
labelstringNo"Gallery"Accessible name of the gallery.
onValueChange(index: number) => voidNo-Auto-generated from TypeScript source.
tileHeightnumberNo190Auto-generated from TypeScript source.
tileWidthnumberNo150Auto-generated from TypeScript source.
valuenumberNo-Controlled front item index.

Source

Import directly from the package or browse the source on GitHub. Click any file to view it.

Import

import { CircularGallery } from "@glinui/ui"

Dependencies

@glinui/ui@glinui/motion

Generated API Snapshot

Beta

Auto-extracted from TypeScript source in packages/ui/src/components/circular-gallery.tsx. This section is in beta and may lag behind hand-curated docs. Regenerate with pnpm --filter @glinui/docs api:generate.

Generated: 2026-10-08T01:41:21.546Z · Full index: /docs/api-metadata

Primary Props Type

CircularGalleryProps

CircularGalleryProps

PropTypeRequiredDefaultDescription
autoRotatebooleanNofalseRotate on a timer. Needs motion level full. Pauses on hover, focus and drag.
autoRotateIntervalnumberNo3200Milliseconds between automatic steps.
defaultValuenumberNo0-
itemsCircularGalleryItem[]Yes--
labelstringNo"Gallery"Accessible name of the gallery.
onValueChange(index: number) => voidNo--
radiusnumberNo-Ring radius in pixels. Defaults to a size that fits the tiles.
showCaptionbooleanNotrueShow the caption of the front tile under the ring.
tileHeightnumberNo190-
tileWidthnumberNo150-
tiltnumberNo8Camera tilt in degrees. Positive looks down on the ring.
valuenumberNo-Controlled front item index.
variantSurfaceVariant | "default"No--
wheelbooleanNofalseLet the wheel or trackpad rotate the ring. Off by default so page scroll is never captured.