Fix tooltip for Copy to clipboard button.
Fix "Copy to clipboard" tooltip to say "Copied!" when clipboard button is clicked. Closes #22022
This commit is contained in:
parent
80fef70bb7
commit
1bde1985c2
2 changed files with 10 additions and 9 deletions
|
@ -22,6 +22,7 @@ v 8.13.0 (unreleased)
|
|||
- Fix broken repository 500 errors in project list
|
||||
|
||||
v 8.12.4 (unreleased)
|
||||
- Fix "Copy to clipboard" tooltip to say "Copied!" when clipboard button is clicked. (lukehowell)
|
||||
|
||||
v 8.12.3
|
||||
- Update Gitlab Shell to support low IO priority for storage moves
|
||||
|
|
|
@ -26,15 +26,15 @@
|
|||
};
|
||||
|
||||
showTooltip = function(target, title) {
|
||||
return $(target).tooltip({
|
||||
container: 'body',
|
||||
html: 'true',
|
||||
placement: 'auto bottom',
|
||||
title: title,
|
||||
trigger: 'manual'
|
||||
}).tooltip('show').one('mouseleave', function() {
|
||||
return $(this).tooltip('hide');
|
||||
});
|
||||
var $target = $(target);
|
||||
var originalTitle = $target.data('original-title');
|
||||
|
||||
$target
|
||||
.attr('title', 'Copied!')
|
||||
.tooltip('fixTitle')
|
||||
.tooltip('show')
|
||||
.attr('title', originalTitle)
|
||||
.tooltip('fixTitle');
|
||||
};
|
||||
|
||||
$(function() {
|
||||
|
|
Loading…
Reference in a new issue