Components/Forms
Solid, outline, soft, ghost and link buttons that light up on hover.
Installation#
npx shadcn@latest add https://get-neonkit.vercel.app/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 swaps in a spinner and blocks clicks until it clears.
As a link
asChild hands the styles to its child, so links keep their semantics.
API reference#
Button
Also accepts every native button attribute.
| Prop | Type | Default |
|---|---|---|
variant | "solid" | "outline" | "soft" | "ghost" | "link"Visual style. | "outline" |
color | NeonColorPalette name or hex. Falls back to --neon-accent, then cyan. | inherited |
size | "sm" | "md" | "lg" | "icon"Height and padding. | "md" |
loading | booleanShows a spinner and disables the button. | false |
asChild | booleanMerges props onto the single child element instead of rendering a button. | false |
Accessibility#
- Icon-only buttons need an aria-label.
- loading sets aria-busy so screen readers announce the pending state.