fix(richtext-slate, ui): use PointerEvents to show tooltips on enabled / disabled buttons (#9006)
Fixes #9005 Note: I did not replace all instances of `onMouseEnter`, just the ones that can be disabled and have `tooltip` set.
This commit is contained in:
@@ -54,8 +54,8 @@ export const ElementButton: React.FC<ButtonProps> = (props) => {
|
||||
.filter(Boolean)
|
||||
.join(' ')}
|
||||
onClick={onClick || defaultOnClick}
|
||||
onMouseEnter={() => setShowTooltip(true)}
|
||||
onMouseLeave={() => setShowTooltip(false)}
|
||||
onPointerEnter={() => setShowTooltip(true)}
|
||||
onPointerLeave={() => setShowTooltip(false)}
|
||||
>
|
||||
{tooltip && <Tooltip show={showTooltip}>{tooltip}</Tooltip>}
|
||||
{children}
|
||||
|
||||
Reference in New Issue
Block a user