"use client"; import { forwardRef, type ButtonHTMLAttributes, type ReactNode } from "react"; import { Spinner } from "@/components/ui/Spinner"; type Variant = "primary" | "secondary" | "danger" | "ghost"; type Size = "sm" | "md" | "lg"; interface ButtonProps extends ButtonHTMLAttributes { variant?: Variant; size?: Size; loading?: boolean; children: ReactNode; } const variantClasses: Record = { primary: "bg-accent text-black font-bold hover:bg-accent-hover active:bg-accent-hover", secondary: "bg-zinc-700 text-zinc-100 hover:bg-zinc-600 active:bg-zinc-500", danger: "bg-red-500 text-white hover:bg-red-600 active:bg-red-700", ghost: "bg-transparent text-zinc-100 hover:bg-zinc-800 active:bg-zinc-700", }; const sizeClasses: Record = { sm: "px-3 py-1.5 text-sm rounded-lg", md: "px-5 py-2.5 text-base rounded-lg", lg: "px-7 py-3.5 text-lg rounded-xl", }; const Button = forwardRef( ( { variant = "primary", size = "md", loading = false, disabled, className = "", children, ...rest }, ref ) => { const isDisabled = disabled || loading; return ( ); } ); Button.displayName = "Button"; export { Button }; export type { ButtonProps };