Skip to content

Commit 80bde01

Browse files
authored
Only hide tooltip tippy instances (#24688)
Fix regression from #24648 where it was hiding non-tooltip tippy instances, like for example in the review panel which itself is a tippy instance, but with a different `role`.
1 parent b20e5f9 commit 80bde01

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

web_src/js/modules/tippy.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,11 @@ export function createTippy(target, opts = {}) {
1818
visibleInstances.delete(instance);
1919
},
2020
onShow: (instance) => {
21+
// hide other tooltip instances so only one tooltip shows at a time
2122
for (const visibleInstance of visibleInstances) {
22-
visibleInstance.hide(); // hide other instances
23+
if (visibleInstance.role === 'tooltip') {
24+
visibleInstance.hide();
25+
}
2326
}
2427
visibleInstances.add(instance);
2528
},

0 commit comments

Comments
 (0)