diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-08-24 21:10:19 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-08-24 21:10:19 +0300 |
commit | 9b14160725d91f8824b35223f16bf073a97bf7de (patch) | |
tree | 121f5165f80d2c921b4135566b3c9e620531434d /app/assets/javascripts/search_autocomplete.js | |
parent | 27622f7417713cbd2057a7f642e9ce128d9fc169 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/assets/javascripts/search_autocomplete.js')
-rw-r--r-- | app/assets/javascripts/search_autocomplete.js | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/app/assets/javascripts/search_autocomplete.js b/app/assets/javascripts/search_autocomplete.js index 990c8faf253..8898d533c86 100644 --- a/app/assets/javascripts/search_autocomplete.js +++ b/app/assets/javascripts/search_autocomplete.js @@ -13,6 +13,7 @@ import { spriteIcon, } from './lib/utils/common_utils'; import Tracking from '~/tracking'; +import initDeprecatedJQueryDropdown from '~/deprecated_jquery_dropdown'; /** * Search input in top navigation bar. @@ -119,7 +120,7 @@ export class SearchAutocomplete { } createAutocomplete() { - return this.searchInput.glDropdown({ + return initDeprecatedJQueryDropdown(this.searchInput, { filterInputBlur: false, filterable: true, filterRemote: true, @@ -145,10 +146,10 @@ export class SearchAutocomplete { if (!term) { const contents = this.getCategoryContents(); if (contents) { - const glDropdownInstance = this.searchInput.data('glDropdown'); + const deprecatedJQueryDropdownInstance = this.searchInput.data('deprecatedJQueryDropdown'); - if (glDropdownInstance) { - glDropdownInstance.filter.options.callback(contents); + if (deprecatedJQueryDropdownInstance) { + deprecatedJQueryDropdownInstance.filter.options.callback(contents); } this.enableAutocomplete(); } @@ -463,7 +464,7 @@ export class SearchAutocomplete { } highlightFirstRow() { - this.searchInput.data('glDropdown').highlightRowAtIndex(null, 0); + this.searchInput.data('deprecatedJQueryDropdown').highlightRowAtIndex(null, 0); } getAvatar(item) { |