Button
Triggers commands, submissions, and navigation-style actions.
Imports
Use the same component slug for React, Vue, and style token lookup. Do not import components from package roots.
import { Button, buttonVariants } from "@line/abc-def-react/button";<script setup lang="ts">
import { Button, buttonVariants } from "@line/abc-def-vue/button";
</script>Shadcn references
Compare the corresponding shadcn React and Vue documentation for the same component slug.
Basic usage
import { Button } from "@line/abc-def-react/button";
export function Example() {
return <Button variant="outline">Save changes</Button>;
}<script setup lang="ts">
import { Button } from "@line/abc-def-vue/button";
</script>
<template>
<Button variant="outline">Save changes</Button>
</template>Component tokens
| Component Token | Semantic Token | Default Primitive Token |
|---|---|---|
--button-ring | --ring | --color-zinc-400 |
--button-ring-destructive | --destructive | --color-red-50 |
--button-bg-primary | --primary | --color-zinc-900 |
--button-fg-primary | --primary-foreground | --color-zinc-50 |
--button-border-primary | --primary | --color-zinc-900 |
--button-bg-primary-hover | --primary | --color-zinc-900 |
--button-fg-primary-hover | --primary-foreground | --color-zinc-50 |
--button-border-primary-hover | --primary | --color-zinc-900 |
--button-bg-primary-expanded | --accent | --color-zinc-100 |
--button-fg-primary-expanded | --accent-foreground | --color-zinc-900 |
--button-border-primary-expanded | --primary | --color-zinc-900 |
--button-bg-secondary | --secondary | --color-zinc-100 |
--button-fg-secondary | --secondary-foreground | --color-zinc-900 |
--button-border-secondary | Literal value | transparent |
--button-bg-secondary-hover | --secondary | --color-zinc-100 |
--button-fg-secondary-hover | --secondary-foreground | --color-zinc-900 |
--button-border-secondary-hover | Literal value | transparent |
--button-bg-secondary-expanded | --secondary | --color-zinc-100 |
--button-fg-secondary-expanded | --secondary-foreground | --color-zinc-900 |
--button-border-secondary-expanded | Literal value | transparent |
--button-bg-outline | --background | --color-white |
--button-fg-outline | --foreground | --color-zinc-950 |
--button-border-outline | --border | --color-zinc-200 |
--button-bg-outline-hover | --accent | --color-zinc-100 |
--button-fg-outline-hover | --accent-foreground | --color-zinc-900 |
--button-border-outline-hover | --border | --color-zinc-200 |
--button-bg-outline-expanded | --accent | --color-zinc-100 |
--button-fg-outline-expanded | --accent-foreground | --color-zinc-900 |
--button-border-outline-expanded | --border | --color-zinc-200 |
--button-bg-ghost | Literal value | transparent |
--button-border-ghost | Literal value | transparent |
--button-bg-ghost-hover | --accent | --color-zinc-100 |
--button-fg-ghost-hover | --accent-foreground | --color-zinc-900 |
--button-border-ghost-hover | Literal value | transparent |
--button-bg-ghost-expanded | --accent | --color-zinc-100 |
--button-fg-ghost-expanded | --accent-foreground | --color-zinc-900 |
--button-border-ghost-expanded | Literal value | transparent |
--button-bg-destructive | --destructive | --color-red-50 |
--button-fg-destructive | --destructive-foreground | --color-red-500 |
--button-border-destructive | --destructive | --color-red-50 |
--button-bg-destructive-hover | --destructive | --color-red-50 |
--button-fg-destructive-hover | --destructive-foreground | --color-red-500 |
--button-border-destructive-hover | --destructive | --color-red-50 |
--button-bg-destructive-expanded | --destructive | --color-red-50 |
--button-fg-destructive-expanded | --destructive-foreground | --color-red-500 |
--button-border-destructive-expanded | --destructive | --color-red-50 |
--button-bg-link | Literal value | transparent |
--button-fg-link | --foreground | --color-zinc-950 |
--button-bg-link-hover | Literal value | transparent |
--button-fg-link-hover | --primary | --color-zinc-900 |
--button-radius-xs | Literal value | var(--radius-xs) |
--button-radius-sm | --radius-sm | calc(var(--radius) * 0.6) |
--button-radius-md | --radius-md | calc(var(--radius) * 0.8) |
--button-radius-lg | --radius-lg | var(--radius) |
--button-radius-xl | --radius-xl | calc(var(--radius) * 1.4) |
Composition exports
ButtonbuttonVariantsUsage notes
- Choose the variant by action priority.
- Prefer icons plus concise labels for repeated tool actions.
- Related component tokens use the `button` token group in `@line/abc-def-styles/css`.