Skip to content

Commit

Permalink
Merge pull request fmoo#105 from rgoldfinger/rgoldfinger-shift-keydown
Browse files Browse the repository at this point in the history
Use upstream keydown handler if the user is pressing shift
  • Loading branch information
fmoo committed Sep 2, 2015
2 parents 56e0fc2 + 8d68654 commit e81ab6e
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/typeahead/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -264,8 +264,9 @@ var Typeahead = React.createClass({

_onKeyDown: function(event) {
// If there are no visible elements, don't perform selector navigation.
// Just pass this up to the upstream onKeydown handler
if (!this._hasHint()) {
// Just pass this up to the upstream onKeydown handler.
// Also skip if the user is pressing the shift key, since none of our handlers are looking for shift
if (!this._hasHint() || event.shiftKey) {
return this.props.onKeyDown(event);
}

Expand Down

0 comments on commit e81ab6e

Please sign in to comment.