Component evidence

ui/button.tsx

termcn · apps/web/components/ui/button.tsx · typescript · MIT
ui

Accessible button component with variants, sizes, and sound/haptic feedback for React apps

Source preview first 800 characters · full source over MCP
// Source: https://github.com/shadcn-labs/termcn | License: MIT | Copyright 2026 Aniket Pawar
// Provided via justclaw.it.com; keep this notice with the code.
"use client";

import { cva } from "class-variance-authority";
import type { VariantProps } from "class-variance-authority";
import { Slot } from "radix-ui";

import type { FeedbackType } from "@/hooks/use-feedback";
import { useFeedback } from "@/hooks/use-feedback";
import { cn } from "@/lib/utils";

const buttonVariants = cva(
  "inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:rin

... (truncated -- full source via MCP)