1
0
Fork 0
react-playground/node_modules/@mui/x-internals/esm/EventManager/EventManager.d.ts
Techognito fc0f69dacb Added Statistics calculation
Statistics now show calculated values
2025-09-04 17:30:00 +02:00

29 lines
No EOL
930 B
TypeScript

export type EventListener = (...args: any[]) => void;
export interface EventListenerOptions {
isFirst?: boolean;
}
interface EventListenerCollection {
/**
* List of listeners to run before the others
* They are run in the opposite order of the registration order
*/
highPriority: Map<EventListener, true>;
/**
* List of events to run after the high priority listeners
* They are run in the registration order
*/
regular: Map<EventListener, true>;
}
export declare class EventManager {
maxListeners: number;
warnOnce: boolean;
events: {
[eventName: string]: EventListenerCollection;
};
on(eventName: string, listener: EventListener, options?: EventListenerOptions): void;
removeListener(eventName: string, listener: EventListener): void;
removeAllListeners(): void;
emit(eventName: string, ...args: any[]): void;
once(eventName: string, listener: EventListener): void;
}
export {};