30 lines
1.1 KiB
JavaScript
30 lines
1.1 KiB
JavaScript
// Module ID: 5622
|
|
// Function ID: 5623
|
|
// Name: transformLongPressProps
|
|
// Dependencies: [5601, 5616, 5592]
|
|
|
|
// Module 5622 (transformLongPressProps)
|
|
import ComposedGestureName from "ComposedGestureName" /* 5592 */;
|
|
import isGestureEnabled from "isGestureEnabled" /* 5601 */;
|
|
import useGesture from "useGesture" /* 5616 */;
|
|
|
|
require = arg1;
|
|
const dependencyMap = arg6;
|
|
function transformLongPressProps(shouldCancelWhenOutside) {
|
|
if (undefined === shouldCancelWhenOutside.shouldCancelWhenOutside) {
|
|
shouldCancelWhenOutside.shouldCancelWhenOutside = true;
|
|
}
|
|
return shouldCancelWhenOutside;
|
|
}
|
|
const items = [["minDuration", "minDurationMs"], ["maxDistance", "maxDist"]];
|
|
const map = new Map(items);
|
|
let closure_4 = {};
|
|
arg5.useLongPressGesture = function useLongPressGesture(gestureHandlerProps) {
|
|
let tmp = gestureHandlerProps;
|
|
if (gestureHandlerProps === undefined) {
|
|
tmp = closure_4;
|
|
}
|
|
const clonedAndRemappedConfig = isGestureEnabled.useClonedAndRemappedConfig(tmp, map, transformLongPressProps);
|
|
const obj = isGestureEnabled;
|
|
return useGesture.useGesture(ComposedGestureName.SingleGestureName.LongPress, clonedAndRemappedConfig);
|
|
};
|