diff options
author | wxiaoguang <wxiaoguang@gmail.com> | 2022-06-05 00:02:10 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-04 17:02:10 +0100 |
commit | d0a2c1e82bf7d6505c268bc106d2ff57be6eb7d7 (patch) | |
tree | 6eac679cd0ddcd2b7c13359623bb08d6a044f5c5 /web_src/js/features/repo-common.js | |
parent | df9612bb535c0f2b4540641ce2fba2c3d65de284 (diff) | |
download | gitea-d0a2c1e82bf7d6505c268bc106d2ff57be6eb7d7.tar.gz gitea-d0a2c1e82bf7d6505c268bc106d2ff57be6eb7d7.zip |
use exact search instead of fuzzy search for branch filter dropdown (#19885)
Diffstat (limited to 'web_src/js/features/repo-common.js')
-rw-r--r-- | web_src/js/features/repo-common.js | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/web_src/js/features/repo-common.js b/web_src/js/features/repo-common.js index 89dae26277..b0ecc5a651 100644 --- a/web_src/js/features/repo-common.js +++ b/web_src/js/features/repo-common.js @@ -110,14 +110,14 @@ export function initRepoCommonBranchOrTagDropdown(selector) { export function initRepoCommonFilterSearchDropdown(selector) { const $dropdown = $(selector); $dropdown.dropdown({ - fullTextSearch: true, + fullTextSearch: 'exact', selectOnKeydown: false, onChange(_text, _value, $choice) { - if ($choice.data('url')) { - window.location.href = $choice.data('url'); + if ($choice.attr('data-url')) { + window.location.href = $choice.attr('data-url'); } }, - message: {noResults: $dropdown.data('no-results')}, + message: {noResults: $dropdown.attr('data-no-results')}, }); } |