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 (controlled or uncontrolled) with TypeScript types and the full source — panels take any React content
- Sunset, Mint and Mono tints, 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 |
|---|---|---|---|
| <section title="…"> | children | — | One child per tab: its title is the label, its content the panel (any HTML). value="…" sets what change reports (default: the title); disabled greys the tab out. |
| value | string | first tab | The open tab — a section's value or title. Fires change with detail.value and detail.index when the user picks another. |
| align | 'start' | 'center' | 'stretch' | 'start' | Tabs at the start of the row, centred, or sharing its full width. |
| size | number (px) | 15 | Label size; the padding and the panel text scale with it. |
| width | number (px) | CSS width | '100%' | Width of the whole component. When the tabs do not fit, the row scrolls sideways and keeps the open tab in view. |
| aria-label | string | — | Accessible name of the tab list. |
| theme | 'light' | 'dark' | 'light' | For a light or a dark page; the component has no background of its own. |
| sound | boolean | off | A porcelain tap, higher when you move forward. Also on for everything inside an element with data-ui-sound="on". |
| tint Pro | 'aurora' | 'sunset' | 'mint' | 'mono' | object | 'aurora' | Colours of the strand of light, or a custom tint. Free build ships Aurora only. |
Real tabs: a tablist of tab buttons wired to their tabpanels, one tab stop for the row, Left / Right to move (mirrored in right-to-left pages), Home and End to jump; moving selects. Hidden panels stay in the page with hidden, so their content is still there for search engines. The panel area animates its height between tabs, so the content below glides instead of jumping. Because form fields inside a panel also fire a native change that bubbles through the element, check e.detail in your listener. For two to four short options that switch a view in place, Pearl Segmented is the smaller control; reach for tabs when each choice owns a panel of content. All CSS, no WebGL. Reduced motion swaps panels with a plain fade.
More components
- Glass Nav
- Glass Command
- Glass Tabbar
- Glass Sidebar
- Pearl Pagination
- Pearl Breadcrumb
- 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
- Halo Avatar
- Pearl Steps
- Pearl Skeleton
- Pearl Table
- Pearl Chip
- Pearl Empty
- Roll Counter
- Glass Marquee
- Reveal Text
- Mesh Gradient
- Silk Waves
- Dot Field
- Plasma Orb
- Voice Wave
- Plush Buddy
- Gummy Agent
- Glass Menu
- Pearl Pricing
- Glass Bento
- Quote Wall
- Glass Cta
- Magnet Button
- Beam Border
- Spotlight Card
- Scratch Reveal
- 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