Skip to content

Conversation

@kmichalikk
Copy link
Collaborator

@kmichalikk kmichalikk commented Oct 29, 2025

Description

Closes https://github.com/software-mansion/react-native-screens-labs/issues/521

We previously removed the support for gestureResponseDistance on iOS 26, because it was seemingly conflicting with the new native behavior - now, each screen can be dismissed by swiping on the content, in addition to swiping from the edge. For the one case of animations, the old gesture recognizer is used, but to match the new one, it also didn't respond the the responseDistance.

After the changes, the recognizer is brought back to work as in ios 18, and the new interactiveContentPop has the check added.

Test code and steps to reproduce

Use Gestures test -- should work the same way as iOS 18. Use Test3093 with modifications in JS to test custom gestures.

animation: 'slide_from_bottom',
animationMatchesGesture: true,
// gestureResponseDistance: { ... }

Copy link
Member

@kkafar kkafar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks sensible, thank you!

I think we need to refactor this code with separated approach for each gesture recognizer. Currently these are all entangled & the code is hard to follow. Not in this PR obviously.

@kmichalikk kmichalikk merged commit 8c50ce7 into main Nov 3, 2025
6 checks passed
@kmichalikk kmichalikk deleted the @kmichalikk/gesture-response-distance-ios-26 branch November 3, 2025 11:12
t0maboro pushed a commit that referenced this pull request Nov 3, 2025
## Description

Closes
software-mansion/react-native-screens-labs#521

We previously removed the support for gestureResponseDistance on iOS 26,
because it was seemingly conflicting with the new native behavior - now,
each screen can be dismissed by swiping on the content, in addition to
swiping from the edge. For the one case of animations, the old gesture
recognizer is used, but to match the new one, it also didn't respond the
the responseDistance.

After the changes, the recognizer is brought back to work as in ios 18,
and the new interactiveContentPop has the check added.

## Test code and steps to reproduce

Use Gestures test -- should work the same way as iOS 18. Use Test3093
with modifications in JS to test custom gestures.
```ts
animation: 'slide_from_bottom',
animationMatchesGesture: true,
// gestureResponseDistance: { ... }
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants