vkurko / calendar

Full-sized drag & drop JavaScript event calendar with resource & timeline views
https://vkurko.github.io/calendar/
MIT License
1.23k stars 108 forks source link

Can't add html in dayHeaderFormat? #173

Closed cipriano200 closed 1 year ago

cipriano200 commented 1 year ago

Cant add html inside dayHeaderFormat function

dayHeaderFormat: function(date) {
  return '<div class="wpfs-calendar-week-day-cell">Some text</div>';
}
vkurko commented 1 year ago

In v2.0.0 it is now possible to return HTML like this:

dayHeaderFormat: function(date) {
  return {html: '<div class="wpfs-calendar-week-day-cell">Some text</div>'};
}
cipriano200 commented 1 year ago

Thank you for your answer.

One more question if you dont mind: Is it possible to add html after header toolbar?

vkurko commented 1 year ago

The titleFormat in v2.0.0 also supports passing html from a function. There are no other options yet. In the future, the setting for Custom buttons will most likely suit you.

vkurko commented 1 year ago

I hope I can close this issue.

cipriano200 commented 1 year ago

Thank you for the release