UNPKG

1.43 kBTypeScriptView Raw
1/// <reference types="react" />
2import { LongPressGestureHandlerEventPayload } from './GestureHandlerEventPayload';
3import { BaseGestureHandlerProps } from './gestureHandlerCommon';
4export declare const longPressGestureHandlerProps: readonly ["minDurationMs", "maxDist", "numberOfPointers"];
5export interface LongPressGestureConfig {
6 /**
7 * Minimum time, expressed in milliseconds, that a finger must remain pressed on
8 * the corresponding view. The default value is 500.
9 */
10 minDurationMs?: number;
11 /**
12 * Maximum distance, expressed in points, that defines how far the finger is
13 * allowed to travel during a long press gesture. If the finger travels
14 * further than the defined distance and the handler hasn't yet activated, it
15 * will fail to recognize the gesture. The default value is 10.
16 */
17 maxDist?: number;
18 /**
19 * Determine exact number of points required to handle the long press gesture.
20 */
21 numberOfPointers?: number;
22}
23export interface LongPressGestureHandlerProps extends BaseGestureHandlerProps<LongPressGestureHandlerEventPayload>, LongPressGestureConfig {
24}
25export declare const longPressHandlerName = "LongPressGestureHandler";
26export type LongPressGestureHandler = typeof LongPressGestureHandler;
27export declare const LongPressGestureHandler: import("react").ComponentType<LongPressGestureHandlerProps & import("react").RefAttributes<any>>;