Improves drag and drop all-day event handling

Refines drag and drop behavior for all-day events.

Removes unnecessary logging and conditional logic in the
AllDayManager.

Simplifies column change handling in the EventRendererManager.
This commit is contained in:
Janus C. H. Knudsen 2025-10-02 17:40:58 +02:00
parent 5cdcd12e0a
commit 88702e574a
2 changed files with 2 additions and 9 deletions

View file

@ -97,16 +97,10 @@ export class AllDayManager {
if (draggedClone == null)
return;
// Filter: Only handle events where clone IS an all-day event
if (!draggedClone.hasAttribute('data-allday')) {
return; // This is not an all-day event, let EventRendererManager handle it
return; // This is not an all-day event
}
console.log('🔄 AllDayManager: Handling drag:column-change for all-day event', {
eventId: draggedElement.dataset.eventId,
cloneId: draggedClone.dataset.eventId
});
this.handleColumnChange(draggedClone, mousePosition);
});
@ -404,7 +398,7 @@ export class AllDayManager {
// Update clone position - ALWAYS keep in row 1 during drag
// Use simple grid positioning that matches all-day container structure
dragClone.style.gridColumn = targetColumn.index.toString();
dragClone.style.gridRow = '1'; // Force row 1 during drag
//dragClone.style.gridRow = '1'; // Force row 1 during drag
dragClone.style.gridArea = `1 / ${targetColumn.index} / 2 / ${targetColumn.index + 1}`;
}