Refactors calendar data management and sync infrastructure
Introduces comprehensive data management system for calendar V2 - Adds IndexedDB storage with pluggable entity services - Implements EventBus for decoupled event communication - Creates data seeding mechanism for initial application setup - Establishes sync and repository abstractions for flexible data handling
This commit is contained in:
parent
dee977d4df
commit
e581039b62
17 changed files with 1076 additions and 4 deletions
47
src/v2/constants/CoreEvents.ts
Normal file
47
src/v2/constants/CoreEvents.ts
Normal file
|
|
@ -0,0 +1,47 @@
|
|||
/**
|
||||
* CoreEvents - Consolidated essential events for the calendar V2
|
||||
*/
|
||||
export const CoreEvents = {
|
||||
// Lifecycle events
|
||||
INITIALIZED: 'core:initialized',
|
||||
READY: 'core:ready',
|
||||
DESTROYED: 'core:destroyed',
|
||||
|
||||
// View events
|
||||
VIEW_CHANGED: 'view:changed',
|
||||
VIEW_RENDERED: 'view:rendered',
|
||||
|
||||
// Navigation events
|
||||
DATE_CHANGED: 'nav:date-changed',
|
||||
NAVIGATION_COMPLETED: 'nav:navigation-completed',
|
||||
|
||||
// Data events
|
||||
DATA_LOADING: 'data:loading',
|
||||
DATA_LOADED: 'data:loaded',
|
||||
DATA_ERROR: 'data:error',
|
||||
|
||||
// Grid events
|
||||
GRID_RENDERED: 'grid:rendered',
|
||||
GRID_CLICKED: 'grid:clicked',
|
||||
|
||||
// Event management
|
||||
EVENT_CREATED: 'event:created',
|
||||
EVENT_UPDATED: 'event:updated',
|
||||
EVENT_DELETED: 'event:deleted',
|
||||
EVENT_SELECTED: 'event:selected',
|
||||
|
||||
// System events
|
||||
ERROR: 'system:error',
|
||||
|
||||
// Sync events
|
||||
SYNC_STARTED: 'sync:started',
|
||||
SYNC_COMPLETED: 'sync:completed',
|
||||
SYNC_FAILED: 'sync:failed',
|
||||
|
||||
// Entity events - for audit and sync
|
||||
ENTITY_SAVED: 'entity:saved',
|
||||
ENTITY_DELETED: 'entity:deleted',
|
||||
|
||||
// Rendering events
|
||||
EVENTS_RENDERED: 'events:rendered'
|
||||
} as const;
|
||||
Loading…
Add table
Add a link
Reference in a new issue