small steps

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

View file

@ -255,14 +255,16 @@ export class GridManager {
weekHeader.appendChild(header); weekHeader.appendChild(header);
}); });
// Add orange header sections in row 2 // Add all-day events in row 2
const headerSectionLeft = document.createElement('swp-header-section-left'); const allDayEventLeft = document.createElement('swp-allday-event');
headerSectionLeft.textContent = 'Left Section'; allDayEventLeft.textContent = 'Left Section';
weekHeader.appendChild(headerSectionLeft); allDayEventLeft.style.gridColumn = '1 / 3'; // Span columns 1-2
weekHeader.appendChild(allDayEventLeft);
const headerSectionRight = document.createElement('swp-header-section-right'); const allDayEventRight = document.createElement('swp-allday-event');
headerSectionRight.textContent = 'Right Section'; allDayEventRight.textContent = 'Right Section';
weekHeader.appendChild(headerSectionRight); allDayEventRight.style.gridColumn = '3 / 8'; // Span columns 3-7
weekHeader.appendChild(allDayEventRight);
// Update spacer heights based on all-day events // Update spacer heights based on all-day events
this.updateSpacerHeights(); this.updateSpacerHeights();

View file

@ -277,9 +277,8 @@ swp-week-header::after {
z-index: 1; z-index: 1;
} }
/* Orange header sections in row 2 */ /* All-day events in row 2 */
swp-header-section-left { swp-allday-event {
grid-column: 1 / 3; /* Span columns 1-2 */
grid-row: 2; /* Row 2 only */ grid-row: 2; /* Row 2 only */
background: #ff9800; /* Orange background */ background: #ff9800; /* Orange background */
display: flex; display: flex;
@ -288,13 +287,8 @@ swp-header-section-left {
border-right: 1px solid rgba(0, 0, 0, 0.1); border-right: 1px solid rgba(0, 0, 0, 0.1);
} }
swp-header-section-right { swp-allday-event:last-child {
grid-column: 3 / 8; /* Span columns 3-7 */ border-right: none; /* Remove border from last all-day event */
grid-row: 2; /* Row 2 only */
background: #ff9800; /* Orange background */
display: flex;
align-items: center;
justify-content: center;
} }
/* Scrollable content */ /* Scrollable content */