Paul-DS / bootstrap-year-calendar

[DEPRECATED] A fully customizable year calendar widget, for boostrap !
Apache License 2.0
294 stars 243 forks source link

Set different styles for different dates in selected date range #189

Open nsmahajan opened 6 years ago

nsmahajan commented 6 years ago

Is there any callback event triggered when the datasource of a calendar changes.

Scenario: When user clicks on a day, the next 15 calendar days are selected automatically which is achieved by using the startDate and endDate property in the datasource array. But I cannot style individual dates in that selected 15 days.

e.g: datasource = { [ startDate: 15 May 2018, endDate: 30 May 2018, color: "#00FF00" ] }

Calendar style is set to use border.

What I want to achieve: Use different background color for dates 15 May 2018 till 20 May 2018 and use different background color for dates 21 May 2018 till 30 May 2018 and all of them would use color: "#00FF00" as border.