import { Config } from "@grafana/faro-core"; export type FrustrationThresholds = Required>; export declare const defaultFrustrationThresholds: FrustrationThresholds; export type TrackedClick = { target: Element; clientX: number; clientY: number; time: number; timestamp: number; gotResponse: boolean; threwError: boolean; changedSelection: boolean; scrolled: boolean; }; export type FrustrationSignal = { type: "rage_click" | "dead_click" | "error_click"; click: TrackedClick; clickCount: number; durationMs: number; }; /** * Applies the configured thresholds over the defaults. Invalid values fall back to the default. */ export declare function resolveFrustrationThresholds(options: Config["frustrationInstrumentation"], warn: (message: string) => void): FrustrationThresholds; export declare function belongsToBurst(last: TrackedClick, next: TrackedClick, thresholds: FrustrationThresholds): boolean; /** * Turns a finished burst of clicks into frustration signals. * A rage burst produces a single signal. Otherwise every click is judged on its own. */ export declare function detectFrustrationSignals(burst: TrackedClick[], thresholds: FrustrationThresholds): FrustrationSignal[]; export declare function isRageBurst(burst: TrackedClick[], thresholds: FrustrationThresholds): boolean; export declare function isUnresponsive(click: TrackedClick): boolean;