mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-05-03 10:00:07 -04:00
Refactor: Modify fewer components.
This commit is contained in:
parent
7246a6b17a
commit
1089cdb278
4 changed files with 64 additions and 59 deletions
|
@ -43,7 +43,6 @@ type ToolButtonProps =
|
|||
type: "icon";
|
||||
children?: React.ReactNode;
|
||||
onClick?(): void;
|
||||
onContextMenu?: React.MouseEventHandler;
|
||||
})
|
||||
| (ToolButtonBaseProps & {
|
||||
type: "radio";
|
||||
|
@ -121,7 +120,6 @@ export const ToolButton = React.forwardRef((props: ToolButtonProps, ref) => {
|
|||
aria-label={props["aria-label"]}
|
||||
type={type}
|
||||
onClick={onClick}
|
||||
onContextMenu={props.type === "icon" ? props.onContextMenu : undefined}
|
||||
ref={innerRef}
|
||||
disabled={isLoading || props.isLoading}
|
||||
>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue