/** * @module seng-event/lib/IsomorphicBaseEvent */ import BaseEvent from './BaseEvent'; import { DataForIsomorphicEvent } from './EventTypings'; /** * Options object as passed to [[createIsomorphicEventClass]] */ export interface EventOptions { bubbles?: boolean; cancelable?: boolean; setTimeStamp?: boolean; } /** * @ignore */ export declare type EventOptionsMap = { [T in TTypes]: EventOptions; }; /** * Base class for classes generated by [[createIsomorphicEventClass]]. Thin abstraction of [[AbstractEvent]] * that adds an additional typed `data` field to events. * * @typeparam TTypes Tuple type of all possible `type` string literals * @typeparam TDataTypes Tuple type of all possible `data` objects * @typeparam TType The string literal `type` of this particular instance */ declare class IsomorphicBaseEvent, TDataTypes extends Array, TType extends TTypes[number]> extends BaseEvent, TType> { type: TType; data: DataForIsomorphicEvent; typeOptions: EventOptionsMap; constructor(type: TType, data: DataForIsomorphicEvent, typeOptions: EventOptionsMap); clone(): IsomorphicBaseEvent; } export default IsomorphicBaseEvent;