Skip to content

Commit

Permalink
issue react-dates#1530 - Fix date selection in the SDP
Browse files Browse the repository at this point in the history
  • Loading branch information
Samantha authored and ljharb committed Mar 13, 2019
1 parent bc5c736 commit a9fdd4b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@
- [] ([#](https://github.com/airbnb/react-dates/pull/))
-->

## [Unreleased]
- [fix] Fix date selection in the SDP ([#1530])


## 20.1.0
- [new] Add `renderKeyboardShortcutsButton` prop ([#1576](https://github.com/airbnb/react-dates/pull/1576))

Expand Down
2 changes: 1 addition & 1 deletion src/components/SingleDatePicker.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ class SingleDatePicker extends React.PureComponent {

onFocusOut(e) {
const { onFocusChange } = this.props;
if (this.dayPickerContainer.contains(e.relatedTarget || e.target)) return;
if (this.dayPickerContainer.contains(e.relatedTarget || e.target) || this.dayPickerContainer.contains(e.target)) return;
onFocusChange({ focused: false });
}

Expand Down

0 comments on commit a9fdd4b

Please sign in to comment.