diff --git a/apps/client/src/widgets/react/hooks.tsx b/apps/client/src/widgets/react/hooks.tsx index 77119ce18..3646113cd 100644 --- a/apps/client/src/widgets/react/hooks.tsx +++ b/apps/client/src/widgets/react/hooks.tsx @@ -633,6 +633,8 @@ export function useTooltip(elRef: RefObject, config: Partial(); + /** * Similar to {@link useTooltip}, but doesn't expose methods to imperatively hide or show the tooltip. * @@ -645,7 +647,17 @@ export function useStaticTooltip(elRef: RefObject, config?: Partial { + // Hide all the other tooltips. + for (const otherTooltip of tooltips) { + if (otherTooltip === tooltip) continue; + otherTooltip.hide(); + } + }); + tooltips.add(tooltip); + return () => { + tooltips.delete(tooltip); tooltip.dispose(); // workaround for https://github.com/twbs/bootstrap/issues/37474 (tooltip as any)._activeTrigger = {};