React Datepicker Component
An elegant customizable react datepicker component.
Installation
yarn add awesome-react-datepicker
Example
A sample example here..
;; { superprops; thisstate = date: ; } { return <div className='App'> <Datepicker initDate=thisstatedate onDateSelect= { this; } /> </div> ; } ;
Customizations
Custom children
To rendar custom children elements inside the input...
<Datepicker initDate=thisstatedate onDateSelect= { this; }> <h3>thisstatedate</h3></Datepicker>
Custom Props
Property | Type | Default | Description | Required |
---|---|---|---|---|
uniqueId | String | undefined | HTML id attribute, unique for each Datepicker component | true |
onDateSelect | Function | undefined | To handle date selection | true |
textColor | String | #606060 | Color code for html elements | false |
borderColor | String | #bbbbbb | Color code for Input and Calendar borders | false |
themeColor | String | #ffcb05 | themeColor | false |
hoverBackground | String | #e5e5e5 | Background color on date & nav-button hover | false |
backgroundColor | String | #ffffff | Datepicker background color | false |
customZIndex | Number | 20 | Z-index of modal | false |
Thank you & Good luck..