mirror of
https://github.com/mountain-loop/yaak.git
synced 2026-03-29 13:41:51 +02:00
Zoom, better sizes, color picker, sidebar footer
This commit is contained in:
@@ -1,22 +1,20 @@
|
||||
import classnames from 'classnames';
|
||||
import { forwardRef } from 'react';
|
||||
import type { IconProps } from './Icon';
|
||||
import { Icon } from './Icon';
|
||||
import type { ButtonProps } from './Button';
|
||||
import { Button } from './Button';
|
||||
import classnames from 'classnames';
|
||||
import type { IconProps } from './Icon';
|
||||
import { Icon } from './Icon';
|
||||
|
||||
type Props = Omit<IconProps, 'size'> &
|
||||
ButtonProps<typeof Button> & {
|
||||
iconClassName?: string;
|
||||
};
|
||||
type Props = IconProps & ButtonProps & { iconClassName?: string; iconSize?: IconProps['size'] };
|
||||
|
||||
export const IconButton = forwardRef<HTMLButtonElement, Props>(function IconButton(
|
||||
{ icon, spin, className, iconClassName, ...props }: Props,
|
||||
{ icon, spin, className, iconClassName, size, iconSize, ...props }: Props,
|
||||
ref,
|
||||
) {
|
||||
return (
|
||||
<Button ref={ref} className={classnames(className, 'group')} {...props}>
|
||||
<Button ref={ref} className={classnames(className, 'group')} size={size} {...props}>
|
||||
<Icon
|
||||
size={iconSize}
|
||||
icon={icon}
|
||||
spin={spin}
|
||||
className={classnames(
|
||||
|
||||
Reference in New Issue
Block a user