Form

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 TokenSemantic TokenDefault 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-secondaryLiteral valuetransparent
--button-bg-secondary-hover--secondary--color-zinc-100
--button-fg-secondary-hover--secondary-foreground--color-zinc-900
--button-border-secondary-hoverLiteral valuetransparent
--button-bg-secondary-expanded--secondary--color-zinc-100
--button-fg-secondary-expanded--secondary-foreground--color-zinc-900
--button-border-secondary-expandedLiteral valuetransparent
--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-ghostLiteral valuetransparent
--button-border-ghostLiteral valuetransparent
--button-bg-ghost-hover--accent--color-zinc-100
--button-fg-ghost-hover--accent-foreground--color-zinc-900
--button-border-ghost-hoverLiteral valuetransparent
--button-bg-ghost-expanded--accent--color-zinc-100
--button-fg-ghost-expanded--accent-foreground--color-zinc-900
--button-border-ghost-expandedLiteral valuetransparent
--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-linkLiteral valuetransparent
--button-fg-link--foreground--color-zinc-950
--button-bg-link-hoverLiteral valuetransparent
--button-fg-link-hover--primary--color-zinc-900
--button-radius-xsLiteral valuevar(--radius-xs)
--button-radius-sm--radius-smcalc(var(--radius) * 0.6)
--button-radius-md--radius-mdcalc(var(--radius) * 0.8)
--button-radius-lg--radius-lgvar(--radius)
--button-radius-xl--radius-xlcalc(var(--radius) * 1.4)

Composition exports

ButtonbuttonVariants

Usage 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`.