Cleanup
This commit is contained in:
parent
69495ce00f
commit
e838719d46
3 changed files with 4 additions and 122 deletions
|
|
@ -43,49 +43,6 @@ export const CoreEvents = {
|
|||
// Filter events (1)
|
||||
FILTER_CHANGED: 'filter:changed',
|
||||
|
||||
// Rendering events (1)
|
||||
// Rendering events (1)
|
||||
EVENTS_RENDERED: 'events:rendered'
|
||||
} as const;
|
||||
|
||||
// Type for the event values
|
||||
export type CoreEventType = typeof CoreEvents[keyof typeof CoreEvents];
|
||||
|
||||
/**
|
||||
* Migration map from old EventTypes to CoreEvents
|
||||
* This helps transition existing code gradually
|
||||
*/
|
||||
export const EVENT_MIGRATION_MAP: Record<string, string> = {
|
||||
// Lifecycle
|
||||
'calendar:initialized': CoreEvents.INITIALIZED,
|
||||
'calendar:ready': CoreEvents.READY,
|
||||
|
||||
// View
|
||||
'calendar:viewchanged': CoreEvents.VIEW_CHANGED,
|
||||
'calendar:viewrendered': CoreEvents.VIEW_RENDERED,
|
||||
'calendar:workweekchanged': CoreEvents.WORKWEEK_CHANGED,
|
||||
|
||||
// Navigation
|
||||
'calendar:datechanged': CoreEvents.DATE_CHANGED,
|
||||
'calendar:navigationcompleted': CoreEvents.NAVIGATION_COMPLETED,
|
||||
'calendar:periodinfoUpdate': CoreEvents.PERIOD_INFO_UPDATE,
|
||||
|
||||
// Data
|
||||
'calendar:datafetchstart': CoreEvents.DATA_LOADING,
|
||||
'calendar:datafetchsuccess': CoreEvents.DATA_LOADED,
|
||||
'calendar:datafetcherror': CoreEvents.DATA_ERROR,
|
||||
'calendar:eventsloaded': CoreEvents.DATA_LOADED,
|
||||
|
||||
// Grid
|
||||
'calendar:gridrendered': CoreEvents.GRID_RENDERED,
|
||||
'calendar:gridclick': CoreEvents.GRID_CLICKED,
|
||||
|
||||
// Event management
|
||||
'calendar:eventcreated': CoreEvents.EVENT_CREATED,
|
||||
'calendar:eventupdated': CoreEvents.EVENT_UPDATED,
|
||||
'calendar:eventdeleted': CoreEvents.EVENT_DELETED,
|
||||
'calendar:eventselected': CoreEvents.EVENT_SELECTED,
|
||||
|
||||
// System
|
||||
'calendar:error': CoreEvents.ERROR,
|
||||
'calendar:refreshrequested': CoreEvents.REFRESH_REQUESTED
|
||||
};
|
||||
} as const;
|
||||
Loading…
Add table
Add a link
Reference in a new issue