We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d0fbb1f commit ceba97fCopy full SHA for ceba97f
src/components/Tooltip/Tooltip.tsx
@@ -475,7 +475,7 @@ export const Tooltip: FC<TooltipProps> = React.memo(
475
'aria-controls': tooltipId?.current,
476
'aria-expanded': mergedVisible,
477
'aria-haspopup': true,
478
- role: 'button',
+ ...(trigger !== 'hover' && { role: 'button' }),
479
'data-reference-id': tooltipReferenceId?.current,
480
tabIndex: `${tabIndex}`,
481
};
@@ -516,7 +516,7 @@ export const Tooltip: FC<TooltipProps> = React.memo(
516
? toggle(true, showTooltip)
517
: null
518
}
519
- role="button"
+ {...(trigger !== 'hover' && { role: 'button' })}
520
tab-index={tabIndex}
521
>
522
{node}
0 commit comments