Feature #37822

Reduce delay in displaying tooltips with icon-only links

Added by Mizuki ISHIKAWA about 1 month ago. Updated about 1 month ago.

Status:NewStart date:
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:UI
Target version:-
Resolution:

Description

Redmine has the feature to display a tooltip when you hover over an element with a title.
However, this tooltip is not displayed easily because the delay is set to 400.
I would like to reduce the delay, especially for links and buttons that only display icons that require explanation.

tooltip.png (76.8 KB) Mizuki ISHIKAWA, 2022-10-25 04:35

sample.gif (382 KB) Mizuki ISHIKAWA, 2022-10-25 04:36

History

#1 Updated by Mizuki ISHIKAWA about 1 month ago

This code sets the delay to 30 for .icon-only.

diff --git a/public/javascripts/application.js b/public/javascripts/application.js
index 4d039cde12..811b8f03bd 100644
--- a/public/javascripts/application.js
+++ b/public/javascripts/application.js
@@ -1109,7 +1109,16 @@ function setupWikiTableSortableHeader() {
 }

 $(function () {
-  $("[title]:not(.no-tooltip)").tooltip({
+  $(".icon-only[title]:not(.no-tooltip)").tooltip({
+    show: {
+      delay: 30
+    },
+    position: {
+      my: "center bottom-5",
+      at: "center top" 
+    }
+  });
+  $(":not(.icon-only)[title]:not(.no-tooltip)").tooltip({
     show: {
       delay: 400
     },

Also available in: Atom PDF