javascript calendar column header height auto fit

Column header auto-fit feature will automatically adjust the column header height to fit all the text. It is enabled by default. You can disable it using headerHeightAutoFit property.

Note that header text wrapping is disabled by default. The height auto-fit only work correctly if you enable text wrapping using headerTextWrappingEnabled: true (see also headerTextWrappingEnabled in the API docs).

JavaScript

<div id="dp"></div>

<script type="text/javascript">
  const dp = new DayPilot.Calendar("dp", {
    headerHeightAutoFit: true,
    headerTextWrappingEnabled: true
    // ...
  });
  dp.init();
</script>

ASP.NET WebForms

<DayPilot:DayPilotCalendar 
  runat="server" 
  ID="DayPilotCalendar1"
  HeaderHeightAutoFit="false"
  ...
/>

Demo

ASP.NET MVC

MVC View

@Html.DayPilotCalendar("dpc", new DayPilotCalendarConfig { 

  // ...
  HeaderHeightAutoFit = false,
  // ...
	
})