Components
A multi-variant action component with loading state and size variants.
Use Button for primary actions, inline confirmations, and lightweight toolbar interactions.
pnpm dlx shadcn@latest add https://react.tileui.zmorg.cn/r/button.jsonimport { Button } from '@tile-ui/react';
export function SaveChanges() {
return <Button>Save changes</Button>;
}asChild support for router links and custom wrappers| Item | Purpose |
|---|---|
button | Component source |
styles | Shared SCSS tokens and globals |
| Prop | Type | Default | Notes |
|---|---|---|---|
variant | default | destructive | outline | secondary | ghost | link | default | Chooses the button visual treatment. |
size | default | sm | lg | icon | default | Controls height and padding. |
loading | boolean | false | Disables interaction and shows the inline spinner. |
asChild | boolean | false | Renders via Radix Slot for composition. |