From bd2087366aa068eaf6d4e94fbc35c702a478f668 Mon Sep 17 00:00:00 2001 From: Vlad Date: Wed, 5 Feb 2020 11:03:52 +0200 Subject: [PATCH] fix: Add minimum and maximum dates prop types (#359) --- src/DateTimePickerModal.android.js | 4 +++- src/DateTimePickerModal.ios.js | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/DateTimePickerModal.android.js b/src/DateTimePickerModal.android.js index 8044d60..0ecfc69 100644 --- a/src/DateTimePickerModal.android.js +++ b/src/DateTimePickerModal.android.js @@ -8,7 +8,9 @@ export default class DateTimePickerModal extends React.PureComponent { isVisible: PropTypes.bool, onCancel: PropTypes.func.isRequired, onConfirm: PropTypes.func.isRequired, - onHide: PropTypes.func + onHide: PropTypes.func, + maximumDate: PropTypes.instanceOf(Date), + minimumDate: PropTypes.instanceOf(Date) }; static defaultProps = { diff --git a/src/DateTimePickerModal.ios.js b/src/DateTimePickerModal.ios.js index 38e2cc9..b7e95cc 100644 --- a/src/DateTimePickerModal.ios.js +++ b/src/DateTimePickerModal.ios.js @@ -52,7 +52,9 @@ export default class DateTimePickerModal extends React.PureComponent { onCancel: PropTypes.func.isRequired, onConfirm: PropTypes.func.isRequired, onChange: PropTypes.func, - onHide: PropTypes.func + onHide: PropTypes.func, + maximumDate: PropTypes.instanceOf(Date), + minimumDate: PropTypes.instanceOf(Date) }; static defaultProps = {