Skip to content

Commit

Permalink
Fixed #1272 - Calendar closes right away in Chrome when it has showTi…
Browse files Browse the repository at this point in the history
…me={true}
  • Loading branch information
mertsincan committed Mar 16, 2020
1 parent 129e6a4 commit f2530f8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/components/calendar/Calendar.js
Original file line number Diff line number Diff line change
Expand Up @@ -1323,13 +1323,13 @@ export class Calendar extends Component {
}
};

document.addEventListener('click', this.documentClickListener);
document.addEventListener('mousedown', this.documentClickListener);
}
}

unbindDocumentClickListener() {
if (this.documentClickListener) {
document.removeEventListener('click', this.documentClickListener);
document.removeEventListener('mousedown', this.documentClickListener);
this.documentClickListener = null;
}
}
Expand Down

0 comments on commit f2530f8

Please sign in to comment.