react-infinite-calendar
react-infinite-calendar copied to clipboard
Calendar does not renrer dates
I use Range Selection and calendar does not render dates till scrolling if it has more than one available month
<InfiniteCalendar
Component={withRange(Calendar)}
width={300}
height={240}
rowHeight={48}
displayOptions={{
showHeader: false,
showTodayHelper: false,
}}
onSelect={this.handleDateChange}/>
Any comments, updates?
I have this issue too
Was running into this issue before, there is another issue where the author suggested hiding and unhiding the calendar with something like this:
<div style={{display: this.state.visible ? 'block': 'none'}}> <InfiniteCalendar />
however when you render the calendar after changing display to block then the child elements aren't rendered.
i got around this by using:
{this.state.visible && <InfiniteCalendar />}
and handling this.visibile in state by having a function that calls this.setState({visible: !this.state.visible}) whenever i want to toggle it
To handle clicking outside the calendar to close i used the package react-onclickoutside then you just export your component as
export default onClickOutside(YourComponent)
hope this helps some people