summaryrefslogtreecommitdiff
path: root/templates/public/index.html
diff options
context:
space:
mode:
authorLuke Shumaker <LukeShu@sbcglobal.net>2014-05-25 19:35:23 -0400
committerLuke Shumaker <LukeShu@sbcglobal.net>2014-05-25 19:35:23 -0400
commit824bd93116c4c0a48d7112ae0bceb46e70851df5 (patch)
tree21285571c08e286891b8e7740c543941798fe778 /templates/public/index.html
parent7ccaa7be630e50ce40182d168d41c2f333005443 (diff)
parent1a1fd4a3d6aa7f6b2338f7751f5f97a30a059a04 (diff)
Merge branch 'archweb-generic' into master-nomake
Conflicts: templates/public/download.html
Diffstat (limited to 'templates/public/index.html')
-rw-r--r--templates/public/index.html13
1 files changed, 12 insertions, 1 deletions
diff --git a/templates/public/index.html b/templates/public/index.html
index f5470d14..b97c7909 100644
--- a/templates/public/index.html
+++ b/templates/public/index.html
@@ -237,8 +237,19 @@ function setupTypeahead() {
matcher: function(item) { return true; },
sorter: function(items) { return items; },
menu: '<ul class="pkgsearch-typeahead"></ul>',
- items: 10
+ items: 10,
+ updater: function(item) {
+ $('#pkgsearch-field').val(item);
+ $('#pkgsearch-form').submit();
+ return item;
+ }
}).attr('autocomplete', 'off');
+ $('#pkgsearch-field').keyup(function(e) {
+ if (e.keyCode === 13 &&
+ $('ul.pkgsearch-typeahead li.active').size() === 0) {
+ $('#pkgsearch-form').submit();
+ }
+ });
}
function setupKonami() {
var konami = new Konami(function() {