import { EditorState, Transaction } from 'prosemirror-state';
import { HigherOrderCommand } from '../../types/command';
import { InputRuleWithHandler } from '../../utils/input-rules';
import { AnalyticsEventPayload } from './types';
import { AnalyticsEventPayloadWithChannel } from './types/events';
import { SELECTION_POSITION, SELECTION_TYPE } from './types/utils';
export declare function getStateContext(state: EditorState, payload: AnalyticsEventPayload): AnalyticsEventPayload;
export declare function getSelectionType(state: EditorState): {
    type: SELECTION_TYPE;
    position?: SELECTION_POSITION;
};
export declare function findInsertLocation(state: EditorState): string;
export declare function addAnalytics(state: EditorState, tr: Transaction, payload: AnalyticsEventPayload, channel?: string): Transaction;
export declare function withAnalytics(payload: AnalyticsEventPayload | ((state: EditorState) => AnalyticsEventPayload | undefined), channel?: string): HigherOrderCommand;
export declare function ruleWithAnalytics(getPayload: (state: EditorState, match: string[], start: number, end: number) => AnalyticsEventPayload): (rule: InputRuleWithHandler) => InputRuleWithHandler;
export declare function getAnalyticsEventsFromTransaction(tr: Transaction): AnalyticsEventPayloadWithChannel[];
