When calendar is in range mode, a second property could be defined such as "relativeRangeMax". This property accepts the first picked date and calculates the limit to the second date in the range field.
Conceptually
A => 01-01-2015
B => 31-01-2015
User picks
C => 20-01-2015
The plugins says relativeRangeMax: '+10d'
then the max is defined to be 30-01-2015
Because C + '+10d' is smaller than the global maxDate the value is accepted. Otherwise the range would be set to 31-01-2015 which is the global maxDate
This relativeRangeMax could also be a function that accepts the first selected date and passes to the function which interally defined the new global date if necessary and returns the new maxDate if smaller than the plugin maxDate property
A second and probably good feature would be to create a custom event that fires once a dateRange pick is finished. Why? In inline calendars I could not figure out when to handle the new value.
When calendar is in range mode, a second property could be defined such as "relativeRangeMax". This property accepts the first picked date and calculates the limit to the second date in the range field.
Conceptually
A => 01-01-2015
B => 31-01-2015
User picks
C => 20-01-2015
The plugins says relativeRangeMax: '+10d'
then the max is defined to be 30-01-2015
Because C + '+10d' is smaller than the global
maxDatethe value is accepted. Otherwise the range would be set to 31-01-2015 which is the globalmaxDateThis relativeRangeMax could also be a function that accepts the first selected date and passes to the function which interally defined the new global date if necessary and returns the new maxDate if smaller than the plugin
maxDatepropertyA second and probably good feature would be to create a custom event that fires once a dateRange pick is finished. Why? In inline calendars I could not figure out when to handle the new value.