diff --git a/web/components/button.tsx b/web/components/button.tsx index 57b2add9..d45c6555 100644 --- a/web/components/button.tsx +++ b/web/components/button.tsx @@ -1,31 +1,25 @@ -import { ReactNode } from 'react' import clsx from 'clsx' -export function Button(props: { - className?: string - onClick?: () => void - children?: ReactNode - size?: '2xs' | 'xs' | 'sm' | 'md' | 'lg' | 'xl' | '2xl' - color?: - | 'green' - | 'red' - | 'blue' - | 'indigo' - | 'yellow' - | 'gray' - | 'gradient' - | 'gray-white' - type?: 'button' | 'reset' | 'submit' - disabled?: boolean -}) { +export function Button( + props: { + size?: '2xs' | 'xs' | 'sm' | 'md' | 'lg' | 'xl' | '2xl' + color?: + | 'green' + | 'red' + | 'blue' + | 'indigo' + | 'yellow' + | 'gray' + | 'gradient' + | 'gray-white' + } & React.ButtonHTMLAttributes +) { const { children, className, - onClick, size = 'md', color = 'indigo', - type = 'button', - disabled = false, + ...buttonProps // onClick, disabled, type, etc. } = props const sizeClasses = { @@ -40,7 +34,6 @@ export function Button(props: { return (