Skip to content

Commit 42f7864

Browse files
committed
Unbreak arrow navigation of search results psch++
1 parent 2f802c5 commit 42f7864

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

html/js/main.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,9 @@ function setup_search_box() {
2121
*/
2222
$('#query').keydown( function(e){
2323
var el = $(this);
24-
if ( e.which == 32 && el.val().length ) { return true; }
24+
if ( el.val().length && ( e.which == 32 || e.which == 40) ) {
25+
return true;
26+
}
2527
if ( e.which == 32 || e.which == 34 || e.which == 40 ) { el.blur() ; }
2628
// key codes: 32: space; 34: pagedown; 40: down arrow
2729
});

0 commit comments

Comments
 (0)