From 1582b1e3a58cfccf3d8b7f636693ac57a91aa3dc Mon Sep 17 00:00:00 2001 From: "(quasar) nebula" Date: Tue, 18 Jun 2024 17:24:16 -0300 Subject: client: consider default tooltip placement as down-right --- src/static/js/client.js | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src') diff --git a/src/static/js/client.js b/src/static/js/client.js index 83459932..8299b63e 100644 --- a/src/static/js/client.js +++ b/src/static/js/client.js @@ -1765,6 +1765,11 @@ function showTooltipFromHoverable(hoverable) { positionTooltipFromHoverableWithBrains(hoverable); + // After a tooltip is shown, if we *didn't* specify an anchor, + // assume it was shown in its default position - generally presented + // as down and to the right. Successive repositioning will base on this. + state.dynamicTooltipAnchorDirection ??= ['down', 'right']; + cssProp(tooltip, 'display', 'block'); tooltip.inert = false; -- cgit 1.3.0-6-gf8a5