diff options
author | Clement Ho <ClemMakesApps@gmail.com> | 2018-04-19 22:16:18 +0300 |
---|---|---|
committer | Clement Ho <ClemMakesApps@gmail.com> | 2018-04-19 22:16:18 +0300 |
commit | f8705d4fa1891db32f7b4190f311b4950cdd3be3 (patch) | |
tree | d29dd0eb0cc57eacdd6a649b575a0766b71893da /app/assets | |
parent | cefeeaea3364c52afc8077c6eaa8914a4bb27852 (diff) |
Replace tooltip('destroy') with tooltip('dispose')
Diffstat (limited to 'app/assets')
-rw-r--r-- | app/assets/javascripts/awards_handler.js | 4 | ||||
-rw-r--r-- | app/assets/javascripts/boards/index.js | 2 | ||||
-rw-r--r-- | app/assets/javascripts/environments/components/environment_stop.vue | 2 | ||||
-rw-r--r-- | app/assets/javascripts/label_manager.js | 2 | ||||
-rw-r--r-- | app/assets/javascripts/main.js | 4 | ||||
-rw-r--r-- | app/assets/javascripts/vue_shared/directives/tooltip.js | 2 |
6 files changed, 8 insertions, 8 deletions
diff --git a/app/assets/javascripts/awards_handler.js b/app/assets/javascripts/awards_handler.js index 1ba46f4faef..eb0f06efab4 100644 --- a/app/assets/javascripts/awards_handler.js +++ b/app/assets/javascripts/awards_handler.js @@ -345,7 +345,7 @@ class AwardsHandler { counter.text(counterNumber - 1); this.removeYouFromUserList($emojiButton); } else if (emoji === 'thumbsup' || emoji === 'thumbsdown') { - $emojiButton.tooltip('destroy'); + $emojiButton.tooltip('dispose'); counter.text('0'); this.removeYouFromUserList($emojiButton); if ($emojiButton.parents('.note').length) { @@ -358,7 +358,7 @@ class AwardsHandler { } removeEmoji($emojiButton) { - $emojiButton.tooltip('destroy'); + $emojiButton.tooltip('dispose'); $emojiButton.remove(); const $votesBlock = this.getVotesBlock(); if ($votesBlock.find('.js-emoji-btn').length === 0) { diff --git a/app/assets/javascripts/boards/index.js b/app/assets/javascripts/boards/index.js index a6f8681cfac..29ab13b8e0b 100644 --- a/app/assets/javascripts/boards/index.js +++ b/app/assets/javascripts/boards/index.js @@ -214,7 +214,7 @@ export default () => { if (this.disabled) { $tooltip.tooltip(); } else { - $tooltip.tooltip('destroy'); + $tooltip.tooltip('dispose'); } }); }, diff --git a/app/assets/javascripts/environments/components/environment_stop.vue b/app/assets/javascripts/environments/components/environment_stop.vue index 04118168a2a..7055f208451 100644 --- a/app/assets/javascripts/environments/components/environment_stop.vue +++ b/app/assets/javascripts/environments/components/environment_stop.vue @@ -43,7 +43,7 @@ if (confirm('Are you sure you want to stop this environment?')) { this.isLoading = true; - $(this.$el).tooltip('destroy'); + $(this.$el).tooltip('dispose'); eventHub.$emit('postAction', this.stopUrl); } diff --git a/app/assets/javascripts/label_manager.js b/app/assets/javascripts/label_manager.js index e230dbbd4ac..6af22ecc990 100644 --- a/app/assets/javascripts/label_manager.js +++ b/app/assets/javascripts/label_manager.js @@ -35,7 +35,7 @@ export default class LabelManager { const $label = $(`#${$btn.data('domId')}`); const action = $btn.parents('.js-prioritized-labels').length ? 'remove' : 'add'; const $tooltip = $(`#${$btn.find('.has-tooltip:visible').attr('aria-describedby')}`); - $tooltip.tooltip('destroy'); + $tooltip.tooltip('dispose'); _this.toggleLabelPriority($label, action); _this.toggleEmptyState($label, $btn, action); } diff --git a/app/assets/javascripts/main.js b/app/assets/javascripts/main.js index 39a43265d5a..77f0fd61545 100644 --- a/app/assets/javascripts/main.js +++ b/app/assets/javascripts/main.js @@ -46,7 +46,7 @@ document.addEventListener('beforeunload', () => { // Unbind scroll events $(document).off('scroll'); // Close any open tooltips - $('.has-tooltip, [data-toggle="tooltip"]').tooltip('destroy'); + $('.has-tooltip, [data-toggle="tooltip"]').tooltip('dispose'); // Close any open popover $('[data-toggle="popover"]').popover('destroy'); }); @@ -108,7 +108,7 @@ document.addEventListener('DOMContentLoaded', () => { addSelectOnFocusBehaviour('.js-select-on-focus'); $('.remove-row').on('ajax:success', function removeRowAjaxSuccessCallback() { - $(this).tooltip('destroy') + $(this).tooltip('dispose') .closest('li') .fadeOut(); }); diff --git a/app/assets/javascripts/vue_shared/directives/tooltip.js b/app/assets/javascripts/vue_shared/directives/tooltip.js index eeaed5b656a..155e6b6698a 100644 --- a/app/assets/javascripts/vue_shared/directives/tooltip.js +++ b/app/assets/javascripts/vue_shared/directives/tooltip.js @@ -10,6 +10,6 @@ export default { }, unbind(el) { - $(el).tooltip('destroy'); + $(el).tooltip('dispose'); }, }; |