diff options
author | Fatih Acet <acetfatih@gmail.com> | 2019-07-09 22:44:20 +0300 |
---|---|---|
committer | Fatih Acet <acetfatih@gmail.com> | 2019-07-09 22:44:20 +0300 |
commit | 6e106f66ad9d692b88e90506c0b35c4281f2b600 (patch) | |
tree | daeed8ab74327dedbdba06514044a515231043a5 | |
parent | cd5117593f3db99f176b462319844641c7dd74dc (diff) | |
parent | 9c55031ff7e0b8442290892d6ad5abbaf8693ad9 (diff) |
Merge branch 'nfriend-add-delay-support-to-tooltip-js' into 'master'
Add delay customization to `app/assets/javascripts/vue_shared/directives/tooltip.js`
See merge request gitlab-org/gitlab-ce!30524
-rw-r--r-- | app/assets/javascripts/vue_shared/directives/tooltip.js | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/app/assets/javascripts/vue_shared/directives/tooltip.js b/app/assets/javascripts/vue_shared/directives/tooltip.js index 2d1f7a1cfd0..73e92728cb9 100644 --- a/app/assets/javascripts/vue_shared/directives/tooltip.js +++ b/app/assets/javascripts/vue_shared/directives/tooltip.js @@ -3,8 +3,12 @@ import '~/commons/bootstrap'; export default { bind(el) { + const glTooltipDelay = localStorage.getItem('gl-tooltip-delay'); + const delay = glTooltipDelay ? JSON.parse(glTooltipDelay) : 0; + $(el).tooltip({ trigger: 'hover', + delay, }); }, |