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
- 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 |
|---|---|---|---|
| value | string | '' | The text. Fires change with detail.value on every keystroke, and submit on Enter. |
| label | string | — | Lies in the field and lifts to the top edge on focus or once there is text. Without a label, set aria-label. |
| placeholder | string | — | Example text; with a label it appears only while the field is focused. |
| type | 'text' | 'email' | 'password' | 'search' | 'tel' | 'url' | 'number' | 'text' | Password adds a show / hide eye. |
| hint | string | — | A line under the field: help text, or the error message when status is error. |
| status | 'idle' | 'error' | 'success' | 'idle' | Error turns the light coral and shakes once; success turns it green and draws a check. |
| clearable | boolean | off | A pearl × that empties the field. |
| width | number (px) | CSS width | 300 | Field width; "100%" fills the parent. |
| size | number (px) | 54 | Field height; the text scales with it. |
| theme | 'light' | 'dark' | 'light' | White porcelain or a dark well. |
| name / autocomplete / maxlength / required / readonly | as on <input> | — | Passed to the real input inside, so forms, validation and autofill work. |
| disabled | boolean | off | Dims it and ignores input. |
| sound | boolean | off | A soft tick per character and a porcelain tap on the buttons. Also on for everything inside an element with data-ui-sound="on". |
| tint Pro | 'aurora' | 'sunset' | 'mint' | 'mono' | object | 'aurora' | Colours of the focus light, or a custom tint. Free build ships Aurora only. |
There is a real <input> inside, so the browser's autofill, password managers, form submission and validation all work, and screen readers read the label, the hint and the invalid state. Everything is CSS — no WebGL, no canvas — so a long form costs nothing. It matches Pearl Select, Pearl Check and Pearl Code in height and material, so they line up in one form. Reduced motion keeps the light and drops the flow, the shake and the label slide.
More components
- Tide Slide
- Pearl Code
- Pearl Dial
- Nova Rating
- Pearl Check
- Pearl Select
- Pearl Accordion
- Pearl Calendar
- Pearl Chip
- Glass Dock
- Pearl Slider
- Pearl Segmented
- Aurora Ring
- Glass Toggle
- Pearl Loader
- Ink Sphere
- Frost Card
- Holo Card
- Stream Text
- Lens Compare
- Glass Toast
- Glass Sheet
- Glass Tip
- Glass Nav
- Pearl Tabs
- Glass Command
- Halo Avatar
- Pearl Steps
- Pearl Skeleton
- Pearl Table
- Pearl Empty
- Roll Counter
- Glass Marquee
- Reveal Text
- 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
- Liquid Metal Button
- Mercury Orb
- Prompt Input
- Voice Orb
- Firefly Button
- Pearl Button
- Alien Face
- Prism Button
- Liquid Carousel
- Orbit Carousel
- Deck Carousel