'use client'; import { forwardRef, HTMLAttributes, ReactNode } from 'react'; export interface DeadButtonProps extends HTMLAttributes { children: ReactNode; icon?: ReactNode; gradient?: 1 | 2 | 3 | 4; size?: 'sm' | 'md' | 'lg'; showStrike?: boolean; } const gradientClasses: Record = { 1: 'bg-gradient-to-br from-indigo-500 to-purple-600 shadow-[0_4px_15px_rgba(102,126,234,0.4)]', 2: 'bg-gradient-to-br from-fuchsia-400 to-rose-500 shadow-[0_4px_15px_rgba(245,87,108,0.4)]', 3: 'bg-gradient-to-br from-blue-400 to-cyan-400 shadow-[0_4px_15px_rgba(79,172,254,0.4)]', 4: 'bg-gradient-to-br from-pink-400 to-yellow-300 shadow-[0_4px_15px_rgba(250,112,154,0.4)]', }; const sizeClasses: Record = { sm: { container: 'w-[200px] h-[45px]', text: 'text-sm', rounded: 'rounded-xl' }, md: { container: 'w-[280px] h-[60px]', text: 'text-base', rounded: 'rounded-2xl' }, lg: { container: 'w-[340px] h-[70px]', text: 'text-lg', rounded: 'rounded-[20px]' }, }; export const DeadButton = forwardRef( ({ children, icon, gradient = 1, size = 'md', showStrike = true, className, ...props }, ref) => { const sizes = sizeClasses[size]; return ( {/* Clean button layer */} {icon && {icon}} {children} {/* Destruction layer */} {/* Noise layer */} {/* Glitch layers */} {/* Strikethrough */} {showStrike && ( )} ); } ); DeadButton.displayName = 'DeadButton'; export default DeadButton;