« get me outta code hell

static, css: define tooltip show/hide 100% in JS - hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src/static/client3.js
diff options
context:
space:
mode:
author(quasar) nebula <qznebula@protonmail.com>2023-11-26 19:53:45 -0400
committer(quasar) nebula <qznebula@protonmail.com>2023-11-26 19:57:06 -0400
commit57c06ea665cf2c2ee4536cab70b2459457d05e15 (patch)
treefe7478e2cc74fc1f80499ee9d509eabd6a26ee7b /src/static/client3.js
parent511a26ddff981b866e7ccb6ecb0724c0a67d097e (diff)
static, css: define tooltip show/hide 100% in JS
Diffstat (limited to 'src/static/client3.js')
-rw-r--r--src/static/client3.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/static/client3.js b/src/static/client3.js
index 58687ec..a55361c 100644
--- a/src/static/client3.js
+++ b/src/static/client3.js
@@ -847,11 +847,11 @@ function hideCurrentlyShownTooltip(intendingToReplace = false) {
   // apparent in the interaction, and should be hidden with a transition.
   if (intendingToReplace) {
     cancelTransitioningTooltipHidden();
+    cssProp(tooltip, 'display', 'none');
   } else {
     beginTransitioningTooltipHidden(state.currentlyShownTooltip);
   }
 
-  tooltip.classList.remove('visible');
   tooltip.inert = true;
 
   state.currentlyShownTooltip = null;
@@ -879,7 +879,8 @@ function showTooltipFromHoverable(hoverable) {
   }
 
   hoverable.classList.add('has-visible-tooltip');
-  tooltip.classList.add('visible');
+
+  cssProp(tooltip, 'display', 'block');
   tooltip.inert = false;
 
   state.currentlyShownTooltip = tooltip;