Button
Solid, outline, soft, ghost and link buttons that light up on hover.
Built on Icons. Installs @radix-ui/react-slot.
Installation
npx shadcn@latest add https://neonkit.heyaadi.com/r/button.jsonUsage
import { Button } from "@/components/ui/button"
<Button color="magenta" variant="solid">Ship it</Button>Examples
Colors
Pass a palette name or any hex value to color.
Sizes
Loading and disabled
loading hides the label behind a spinner without changing the width, and ignores presses until it clears.
As a link
asChild hands the styles to its child, so links keep their semantics.
API reference
Also accepts every native button attribute.
| Prop | Type | Default |
|---|---|---|
variant | "solid"Visual style. | "outline" |
color | NeonColorPalette name or hex. Falls back to --neon-accent, then cyan. | inherited |
size | "sm"Height and padding. The icon sizes are square: 32, 40 and 48px. | "md" |
loading | booleanSwaps the label for a spinner at the same width and ignores presses. The button keeps focus and full color. | false |
asChild | booleanMerges props onto the single child element instead of rendering a button. | false |
render | ReactElementBase UI's spelling of asChild, render={<Link href="/" />}. The shadcn CLI rewrites asChild into it in base-* projects, so both work. | None |
Accessibility
- Icon-only buttons need an aria-label.
- loading sets aria-busy and aria-disabled instead of disabled, so keyboard focus stays on the button while it works.