A date picker implemented with Airbnb's react-dates library. Any props available in the react-dates library are available in our wrapped component.
Navigate forward to interact with the calendar and select a date. Press the question mark key to get the keyboard shortcuts for changing dates.
Navigate forward to interact with the calendar and select a date. Press the question mark key to get the keyboard shortcuts for changing dates.
Navigate backward to interact with the calendar and select a date. Press the question mark key to get the keyboard shortcuts for changing dates.
Navigate forward to interact with the calendar and select a date. Press the question mark key to get the keyboard shortcuts for changing dates.
default| Property | Type | Required | Default | Description |
|---|---|---|---|---|
| placeholder | String | false | Date | Placeholder text for the DatePicker text field. |
| monthYearSelectionMode | Enum | false | NONE | Determine if year and/or month dropdowns should be shown in the calendar popup |
| yearSelectDates | Shape | false | { startYear: new moment().subtract(50, year).year(), endYear: new moment().year() } | The years that will be used to populate the year dropdown menu |
| numberOfMonths | Number | false | 1 | The number of months to show in the popup |
| date | Custom | false | - | The currently selected moment date object for the component. |
| onDateChange | Func | true | - | Callback function when the selected date is changed. |
| focused | Bool | false | - | Describe whether the DatePicker is currently focused; displays the calendar dropdown. |
| onFocusChange | Func | true | - | Callback function when the focus state of the DatePicker is changed. |
| id | String | true | - | An id supplied to the DatePicker. |
| hideInputIcon | Bool | false | - | Toggle visibility of the calendar icon in the input |
| Property | Type | Required | Default | Description |
|---|---|---|---|---|
| startDatePlaceholderText | String | false | Start Date | Placeholder text for the start date text field. |
| endDatePlaceholderText | String | false | End Date | Placeholder text for the end date text field. |
| monthYearSelectionMode | Enum | false | NONE | Determine if year and/or month dropdowns should be shown in the calendar popup |
| yearSelectDates | Shape | false | { startYear: new moment().subtract(50, year).year(), endYear: new moment().year() } | The years that will be used to populate the year dropdown menu |
| startDate | Custom | false | - | The currently selected moment date object for the start date. |
| startDateId | String | true | - | Id provided to the start date text field. |
| endDate | Custom | false | - | The currently selected moment date object for the end date. |
| endDateId | String | true | - | Id provided to the end date text field. |
| onDatesChange | Func | true | - | Callback function when the start or end date is changed. |
| focusedInput | Enum | false | - | The name of the currently focused text field. |
| onFocusChange | Func | true | - | Callback function when the focused input is changed. |
| hideInputIcon | Bool | false | - | Toggle visibility of the calendar icon in the input |