Creates all-day container in header renderer

Ensures all-day container is created as part of the standard header structure, rather than on-demand.

Removes the request listener and logic for ensuring all-day container existence.
This commit is contained in:
Janus C. H. Knudsen 2025-09-25 20:39:48 +02:00
parent 4daf1f6975
commit 274753936e
2 changed files with 4 additions and 37 deletions

View file

@ -30,6 +30,10 @@ export class DateHeaderRenderer implements HeaderRenderer {
render(calendarHeader: HTMLElement, context: HeaderRenderContext): void {
const { currentWeek, config } = context;
// FIRST: Always create all-day container as part of standard header structure
const allDayContainer = document.createElement('swp-allday-container');
calendarHeader.appendChild(allDayContainer);
// Initialize date calculator with config
DateCalculator.initialize(config);
this.dateCalculator = new DateCalculator();