summaryrefslogtreecommitdiff
path: root/app/assets/javascripts/labels_select.js
diff options
context:
space:
mode:
authorPhil Hughes <me@iamphill.com>2018-01-31 09:27:30 +0000
committerPhil Hughes <me@iamphill.com>2018-01-31 09:27:30 +0000
commitf165bda4ae2a92528e6f4da25825c1e441094c54 (patch)
tree3c68c58a56cdc390dc75e83a786200cf0e3fa662 /app/assets/javascripts/labels_select.js
parent58eb3c55c9d15bd604b926ffeae9401f0b70c53c (diff)
downloadgitlab-ce-f165bda4ae2a92528e6f4da25825c1e441094c54.tar.gz
fixed failing specs
Diffstat (limited to 'app/assets/javascripts/labels_select.js')
-rw-r--r--app/assets/javascripts/labels_select.js12
1 files changed, 6 insertions, 6 deletions
diff --git a/app/assets/javascripts/labels_select.js b/app/assets/javascripts/labels_select.js
index 06b8333db27..5ecf81ad11d 100644
--- a/app/assets/javascripts/labels_select.js
+++ b/app/assets/javascripts/labels_select.js
@@ -102,28 +102,28 @@ export default class LabelsSelect {
}
$value.removeAttr('style').html(template);
$sidebarCollapsedValue.text(labelCount);
-
+
if (data.labels.length) {
labelTitles = data.labels.map(function(label) {
return label.title;
});
-
+
if (labelTitles.length > 5) {
labelTitles = labelTitles.slice(0, 5);
labelTitles.push('and ' + (data.labels.length - 5) + ' more');
}
-
+
labelTooltipTitle = labelTitles.join(', ');
}
else {
labelTooltipTitle = '';
$sidebarLabelTooltip.tooltip('destroy');
}
-
+
$sidebarLabelTooltip
.attr('title', labelTooltipTitle)
.tooltip('fixTitle');
-
+
$('.has-tooltip', $value).tooltip({
container: 'body'
});
@@ -168,7 +168,7 @@ export default class LabelsSelect {
data = extraData.concat(data);
}
}
-
+
callback(data);
if (showMenuAbove) {
$dropdown.data('glDropdown').positionMenuAbove();