export function isEventOneOf(e, data, types) {
    const t = e.type;
    const ev = e.event;
    const dt = data === null || data === void 0 ? void 0 : data.type;
    return types.some((type) => t === type || ev === type || dt === type);
}
export function getDeltaForEventTypes(e, data, eventTypes) {
    var _a, _b;
    if (eventTypes.includes((_a = e.type) !== null && _a !== void 0 ? _a : '') && typeof e.delta === 'string') {
        return e.delta;
    }
    if (!isEventOneOf(e, data, eventTypes)) {
        return null;
    }
    const delta = ((_b = data === null || data === void 0 ? void 0 : data.delta) !== null && _b !== void 0 ? _b : e.delta);
    return typeof delta === 'string' ? delta : null;
}
//# sourceMappingURL=eventTypeUtils.js.map
