mirror of
https://github.com/jeffvli/feishin.git
synced 2026-06-21 03:14:16 +02:00
fix click propagation on PlayButton
This commit is contained in:
@@ -61,7 +61,7 @@ interface PlayButtonProps extends Omit<ActionIconProps, 'icon' | 'variant'> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export const PlayButton = forwardRef<HTMLButtonElement, PlayButtonProps>(
|
export const PlayButton = forwardRef<HTMLButtonElement, PlayButtonProps>(
|
||||||
({ isPaused, ...props }: PlayButtonProps, ref) => {
|
({ isPaused, onClick, ...props }: PlayButtonProps, ref) => {
|
||||||
return (
|
return (
|
||||||
<ActionIcon
|
<ActionIcon
|
||||||
className={styles.main}
|
className={styles.main}
|
||||||
@@ -69,6 +69,10 @@ export const PlayButton = forwardRef<HTMLButtonElement, PlayButtonProps>(
|
|||||||
iconProps={{
|
iconProps={{
|
||||||
size: 'lg',
|
size: 'lg',
|
||||||
}}
|
}}
|
||||||
|
onClick={(e) => {
|
||||||
|
e.stopPropagation();
|
||||||
|
onClick?.(e);
|
||||||
|
}}
|
||||||
ref={ref}
|
ref={ref}
|
||||||
tooltip={{
|
tooltip={{
|
||||||
label: isPaused
|
label: isPaused
|
||||||
|
|||||||
Reference in New Issue
Block a user