feat: wordlists user interface
This commit is contained in:
32
src/components/ui/Button.tsx
Normal file
32
src/components/ui/Button.tsx
Normal file
@@ -0,0 +1,32 @@
|
||||
import type { ButtonHTMLAttributes, DetailedHTMLProps, FC } from 'react'
|
||||
import type { MergeOmitting } from '@/types/helpers'
|
||||
import '@/components/ui/button.css'
|
||||
|
||||
export type ButtonProps = MergeOmitting<
|
||||
DetailedHTMLProps<ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>,
|
||||
{
|
||||
neutral?: boolean
|
||||
icon?: boolean
|
||||
}
|
||||
>
|
||||
|
||||
const Button: FC<ButtonProps> = ({
|
||||
children,
|
||||
className,
|
||||
neutral,
|
||||
icon,
|
||||
...buttonProps
|
||||
}) => {
|
||||
return (
|
||||
<button
|
||||
className={`st-rnd-button${neutral === true ? ' button-neutral' : ''}${icon === true ? ' button-icon' : ''}${
|
||||
className ? ` ${className}` : ''
|
||||
}`}
|
||||
{...buttonProps}
|
||||
>
|
||||
{children}
|
||||
</button>
|
||||
)
|
||||
}
|
||||
|
||||
export default Button
|
||||
Reference in New Issue
Block a user