Some ignored filles was missing

This commit is contained in:
Janus C. H. Knudsen 2026-02-03 00:02:25 +01:00
parent 7db22245e2
commit fd5ab6bc0d
268 changed files with 31970 additions and 4 deletions

58
wwwroot/js/strategies/ViewStrategy.d.ts vendored Normal file
View file

@ -0,0 +1,58 @@
/**
* ViewStrategy - Strategy pattern for different calendar view types
* Allows clean separation between week view, month view, day view etc.
*/
import { ResourceCalendarData } from '../types/CalendarTypes';
/**
* Context object passed to strategy methods
*/
export interface ViewContext {
currentDate: Date;
container: HTMLElement;
resourceData: ResourceCalendarData | null;
}
/**
* Layout configuration specific to each view type
*/
export interface ViewLayoutConfig {
needsTimeAxis: boolean;
columnCount: number;
scrollable: boolean;
eventPositioning: 'time-based' | 'cell-based';
}
/**
* Base strategy interface for all view types
*/
export interface ViewStrategy {
/**
* Get the layout configuration for this view
*/
getLayoutConfig(): ViewLayoutConfig;
/**
* Render the grid structure for this view
*/
renderGrid(context: ViewContext): void;
/**
* Calculate next period for navigation
*/
getNextPeriod(currentDate: Date): Date;
/**
* Calculate previous period for navigation
*/
getPreviousPeriod(currentDate: Date): Date;
/**
* Get display label for current period
*/
getPeriodLabel(date: Date): string;
/**
* Get the dates that should be displayed in this view
*/
getDisplayDates(baseDate: Date): Date[];
/**
* Get the period start and end dates for event filtering
*/
getPeriodRange(baseDate: Date): {
startDate: Date;
endDate: Date;
};
}