Files
remark42/frontend/app/components/icon-button/icon-button.tsx
T
2021-08-08 14:25:10 -05:00

15 lines
426 B
TypeScript

import clsx from 'clsx';
import { h, RenderableProps, JSX } from 'preact';
import styles from './icon-button.module.css';
type Props = JSX.HTMLAttributes<HTMLButtonElement> & RenderableProps<{ className?: string }>;
export function IconButton({ title, children, className, ...props }: Props) {
return (
<button className={clsx('icon-button', className, styles.root)} {...props}>
{children}
</button>
);
}