Semantic-UI-Calendar
Semantic-UI-Calendar copied to clipboard
Date range problem
Hi, I'm having a problem with the calendar. I'm using it as a date range picker but if I select a date in the first calendar it doesn't block out the date in the second calendar.
How would I achieve this behavior?
Code is;
$checkin.calendar({
type: 'date',
endCalendar: $checkout,
minDate: new Date(),
formatter: {
date: handler.dateFormatter
},
onChange: function(date, text){
searchQuery.checkin = text;
}
});
$checkout.calendar({
type: 'date',
startCalendar: $checkin,
formatter: {
date: handler.dateFormatter
},
onChange: function(date, text){
searchQuery.checkout = text;
}
});
It looks like you're doing the right thing. Could you please provide an example JSBin that reproduces the issue?