summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlfredo Sumaran <alfredo@gitlab.com>2016-06-16 12:52:11 -0500
committerAlfredo Sumaran <alfredo@gitlab.com>2016-06-16 12:53:21 -0500
commit39e77651a272ce0aa61265d61e853d4e0cd19ac5 (patch)
treec73abf95923af2a85c4b61e1e486b816f4e9fb52
parent666b5651689d3a5a7e6b2e7c18c7c818c81ead84 (diff)
downloadgitlab-ce-18707-label-tooltips-dont-dissapear-firefox.tar.gz
This fixes the not dissapearing tooltip issue on Firefox after toggling label priority
-rw-r--r--app/assets/javascripts/LabelManager.js.coffee5
1 files changed, 5 insertions, 0 deletions
diff --git a/app/assets/javascripts/LabelManager.js.coffee b/app/assets/javascripts/LabelManager.js.coffee
index b06bcf0fcbf..6d8faba40d7 100644
--- a/app/assets/javascripts/LabelManager.js.coffee
+++ b/app/assets/javascripts/LabelManager.js.coffee
@@ -27,6 +27,11 @@ class @LabelManager
$btn = $(e.currentTarget)
$label = $("##{$btn.data('domId')}")
action = if $btn.parents('.js-prioritized-labels').length then 'remove' else 'add'
+
+ # Make sure tooltip will hide
+ $tooltip = $ "##{$btn.find('.has-tooltip:visible').attr('aria-describedby')}"
+ $tooltip.tooltip 'destroy'
+
_this.toggleLabelPriority($label, action)
toggleLabelPriority: ($label, action, persistState = true) ->