91 lines
2.8 KiB
TypeScript
91 lines
2.8 KiB
TypeScript
import { AllDayEventRenderer } from '../renderers/AllDayEventRenderer';
|
|
import { EventManager } from './EventManager';
|
|
import { DateService } from '../utils/DateService';
|
|
/**
|
|
* AllDayManager - Handles all-day row height animations and management
|
|
* Uses AllDayLayoutEngine for all overlap detection and layout calculation
|
|
*/
|
|
export declare class AllDayManager {
|
|
private allDayEventRenderer;
|
|
private eventManager;
|
|
private dateService;
|
|
private layoutEngine;
|
|
private currentAllDayEvents;
|
|
private currentWeekDates;
|
|
private isExpanded;
|
|
private actualRowCount;
|
|
constructor(eventManager: EventManager, allDayEventRenderer: AllDayEventRenderer, dateService: DateService);
|
|
/**
|
|
* Setup event listeners for drag conversions
|
|
*/
|
|
private setupEventListeners;
|
|
private getAllDayContainer;
|
|
private getCalendarHeader;
|
|
private getHeaderSpacer;
|
|
/**
|
|
* Read current max row from DOM elements
|
|
* Excludes events marked as removing (data-removing attribute)
|
|
*/
|
|
private getMaxRowFromDOM;
|
|
/**
|
|
* Get current gridArea for an event from DOM
|
|
*/
|
|
private getGridAreaFromDOM;
|
|
/**
|
|
* Count events in a specific column by reading DOM
|
|
*/
|
|
private countEventsInColumnFromDOM;
|
|
/**
|
|
* Calculate all-day height based on number of rows
|
|
*/
|
|
private calculateAllDayHeight;
|
|
/**
|
|
* Check current all-day events and animate to correct height
|
|
* Reads max row directly from DOM elements
|
|
*/
|
|
checkAndAnimateAllDayHeight(): void;
|
|
/**
|
|
* Animate all-day container to specific number of rows
|
|
*/
|
|
animateToRows(targetRows: number): void;
|
|
/**
|
|
* Calculate layout for ALL all-day events using AllDayLayoutEngine
|
|
* This is the correct method that processes all events together for proper overlap detection
|
|
*/
|
|
private calculateAllDayEventsLayout;
|
|
private handleConvertToAllDay;
|
|
/**
|
|
* Handle drag move for all-day events - SPECIALIZED FOR ALL-DAY CONTAINER
|
|
*/
|
|
private handleColumnChange;
|
|
private fadeOutAndRemove;
|
|
/**
|
|
* Handle timed → all-day conversion on drop
|
|
*/
|
|
private handleTimedToAllDayDrop;
|
|
/**
|
|
* Handle all-day → all-day drop (moving within header)
|
|
*/
|
|
private handleDragEnd;
|
|
/**
|
|
* Update chevron button visibility and state
|
|
*/
|
|
private updateChevronButton;
|
|
/**
|
|
* Toggle between expanded and collapsed state
|
|
*/
|
|
private toggleExpanded;
|
|
/**
|
|
* Count number of events in a specific column using IColumnBounds
|
|
* Reads directly from DOM elements
|
|
*/
|
|
private countEventsInColumn;
|
|
/**
|
|
* Update overflow indicators for collapsed state
|
|
*/
|
|
private updateOverflowIndicators;
|
|
/**
|
|
* Clear overflow indicators and restore normal state
|
|
*/
|
|
private clearOverflowIndicators;
|
|
}
|