Code
In context
Install · Free Web Component
One file, no dependencies. Aurora preset, every other option included. Host it yourself so your visitors never load anything from our servers.
The shadcn command adds a typed React wrapper for you. Using the file directly? Custom elements work in React as-is; for type checking add:
Pro · React + TypeScript Pro
One payment of $4.99, yours forever. Use it in unlimited personal and commercial projects; no resale.
- React component with TypeScript types and the full source — items are ordinary children
- Sunset, Mint and Mono tints for the light caught in the glass, plus custom tints from Brand Fit
- The vanilla Web Component with every tint, a demo page, README and license
Attributes & props
| Name | Type | Default | Description |
|---|---|---|---|
| children | elements | — | Each child is one item: an image, a card, a tag. They repeat as often as needed to fill the width; the copies are hidden from screen readers and from Tab. |
| speed | number (px/s) | 40 | Cruise speed. The row always returns to it after a hover, a flick or a push. |
| direction | 'left' | 'right' | 'left' | Which way the row travels. |
| gap | number (px) | 48 | Space between items. |
| fade | number (px) | 96 | Width of each soft end, where items fade and blur. 0 turns it off. |
| pause-on-hover | 'slow' | 'stop' | 'none' | 'slow' | Under the pointer the row eases down to a drift, eases to a stop, or carries on. |
| drag | 'true' | 'false' | 'true' | Grab the row and flick it; it coasts and settles back to its cruise speed. Links inside still work on a plain click. |
| theme | 'light' | 'dark' | 'light' | White or dark glass at the ends. |
| tint Pro | 'aurora' | 'sunset' | 'mint' | 'mono' | object | 'aurora' | The faint colour caught in the glass ends, or a custom tint. Free build ships Aurora only. |
The glass blurs what is behind it, so the effect is the same on any background — a photo, a gradient or a flat colour — and there is nothing to colour-match. Items are measured with a ResizeObserver and re-cloned when they change; one animation frame moves one transform, and it stops while the row is off-screen or the tab is hidden. Keyboard focus stops the row and brings the focused item to the middle. Scrolling the page gives the row a short push. With reduced motion it becomes a still row you can scroll sideways. Add an aria-label to name the row.
More components
- Roll Counter
- Reveal Text
- Tide Slide
- Pearl Code
- Ink Sphere
- Frost Card
- Holo Card
- Stream Text
- Lens Compare
- Pearl Dial
- Nova Rating
- Pearl Check
- Pearl Input
- Glass Toast
- Pearl Select
- Glass Sheet
- Pearl Accordion
- Glass Tip
- Pearl Calendar
- Glass Nav
- Pearl Tabs
- Glass Command
- Halo Avatar
- Pearl Steps
- Pearl Skeleton
- Pearl Table
- Pearl Chip
- Pearl Empty
- Mesh Gradient
- Silk Waves
- Dot Field
- Plasma Orb
- Voice Wave
- Plush Buddy
- Gummy Agent
- Glass Tabbar
- Glass Menu
- Pearl Pricing
- Glass Bento
- Quote Wall
- Glass Cta
- Magnet Button
- Beam Border
- Spotlight Card
- Scratch Reveal
- Glass Sidebar
- Pearl Pagination
- Pearl Breadcrumb
- Glass Dock
- Pearl Slider
- Pearl Segmented
- Liquid Metal Button
- Mercury Orb
- Prompt Input
- Voice Orb
- Aurora Ring
- Glass Toggle
- Firefly Button
- Pearl Button
- Pearl Loader
- Alien Face
- Prism Button
- Liquid Carousel
- Orbit Carousel
- Deck Carousel