mattlewis92/angular-bootstrap-calendar

Feature Request: Configuration to show/hide the week number label

ShrinivasKattimani opened this issue · 1 comments

Can we have a configuration to show/hide the week number label?
I tried the following and it worked.

  1. Added a new key under calendarConfig constants:
angular
  .module('mwl.calendar')
  .constant('calendarConfig', {
    .
    .
     showWeekNumberLabel: false,
    .
    .
   });
  1. And then included a condition in calendar month cell template:
    <div class=\"cal-week-box-cell\" ng-if=\"$first && rowHovered && calendarConfig.showWeekNumberLabel\">\n <span ng-bind=\"vm.getWeekNumberLabel(day)\"></span>\n </div>

Please do consider this feature.

You can hide this with CSS:

.cal-week-box-cell {
  display: none;
}

Hope that helps! :)