This commit is contained in:
Janus Knudsen 2025-08-04 23:22:31 +02:00
parent ce82b5286b
commit 42901212da
3 changed files with 23 additions and 2 deletions

View file

@ -263,6 +263,24 @@ export class GridManager {
const headerSectionRight = document.createElement('swp-header-section-right');
headerSectionRight.textContent = 'Right Section';
weekHeader.appendChild(headerSectionRight);
// Update spacer heights based on all-day events
this.updateSpacerHeights();
}
/**
* Update spacer heights based on all-day events presence
*/
private updateSpacerHeights(): void {
// TODO: Check for actual all-day events in current week
// For now, simulate having all-day events with 30px height
const hasAllDayEvents = true; // This should be determined from actual event data
const allDayHeight = hasAllDayEvents ? 30 : 0;
// Set CSS variable for dynamic spacer height
document.documentElement.style.setProperty('--all-day-row-height', `${allDayHeight}px`);
console.log('GridManager: Updated --all-day-row-height to', `${allDayHeight}px`);
}
/**