diff --git a/js/src/common/components/Tooltip.tsx b/js/src/common/components/Tooltip.tsx index f266feaf0..e9a43e5c1 100644 --- a/js/src/common/components/Tooltip.tsx +++ b/js/src/common/components/Tooltip.tsx @@ -233,9 +233,8 @@ export default class Tooltip extends Component { text, } = this.attrs; - const trigger = (typeof tooltipVisible === 'boolean' - ? 'manual' - : classList('hover', [showOnFocus && 'focus'])) as TooltipCreationOptions['trigger']; + // Fancy "hack" to assemble the trigger string + const trigger = typeof tooltipVisible === 'boolean' ? 'manual' : classList('hover', [showOnFocus && 'focus']); const realText = this.getRealText(); this.childDomNode.setAttribute('title', realText); @@ -247,7 +246,6 @@ export default class Tooltip extends Component { html, delay, placement: position, - // Fancy "hack" to assemble the trigger string trigger, }, // @ts-expect-error We don't want this arg to be part of the public API. It only exists to prevent deprecation warnings when using `$.tooltip` in this component.