-
-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Description
I have a screen using ScrollView from react-native-gesture-handler.
Inside it, I’m rendering a pressable created with createAnimatedPressable:
const AnimatedPressable = createAnimatedPressable((progress) => {
'worklet'
return {
opacity: interpolate(progress, [0, 1], [1, 0.5]),
transform: [{ scale: interpolate(progress, [0, 1], [1, 0.95]) }],
elevation: IS_ANDROID ? 0 : interpolate(progress, [0, 1], [204, 74]),
}
})The problem: press feedback is noticeably delayed.
When I tap the component, opacity + scale don’t react immediately.
There’s roughly a ~20ms pause before the animation starts.
This only happens when the component is inside an RNGH ScrollView. Maybe this is intentional, to make a delay to decide whether the interaction is a scroll or a tap before sending the press event, so the animation can’t start right away.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels