Buttons
CreativeSpotlight Button
A soft pool of light on the face and a brighter line on the nearest edge. For dense toolbars and dark landing pages.
Install
Included with Creative: needs your API key. Initialize and log in once.
npx @galactrex/ui add spotlight-buttonUsage
import { SpotlightButton } from "@/components/galactrex/spotlight-button";
<SpotlightButton onClick={share}>Share</SpotlightButton>Source
Installs to components/galactrex/spotlight-button.tsx, with the shared motion primitives beside it.
Source for this component comes with its plan. Install it with the command above, or open your licensed copy here.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
children | ReactNode | — | Label. |
size | number | 90 | Radius of the light in px. |
...button props | ButtonHTMLAttributes | — | onClick, disabled, type and the rest. |
Variants
- Toolbar. A row of them over a dark surface.
Accessibility
- A real button; light layers are aria-hidden and off on touch.
Motion and reduced motion
- Motion values drive the light without re-rendering.