Skip to content

Commit

Permalink
fix(autocomplete): auto select top result
Browse files Browse the repository at this point in the history
Use autocomplete.js's autoselect=true option to select the top
suggestion on <ENTER> even if you don't move the cursor.

Fix #81
  • Loading branch information
acodereviewersbestfriend52 authored and redox committed Mar 15, 2016
1 parent 89e55d7 commit 86ffdd9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/lib/DocSearch.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ class DocSearch {
},
autocompleteOptions = {
debug: false,
hint: false
hint: false,
autoselect: true
}
}) {
DocSearch.checkArguments({apiKey, indexName, inputSelector, algoliaOptions, autocompleteOptions});
Expand Down

0 comments on commit 86ffdd9

Please sign in to comment.