software-mansion / react-native-screens

Native navigation primitives for your React Native app.
https://docs.swmansion.com/react-native-screens/
MIT License
3.08k stars 519 forks source link

formSheet behavior has changed #2347

Closed matinzd closed 1 week ago

matinzd commented 1 month ago

Description

formSheet presentation used to look different but recently it has changed.

Old:

New:

Has there been any breaking changes here? I know that there has been some efforts to introduce bottom sheets natively on iOS and Android with similar behavior but I really miss will really miss this one for iOS. Is there any way to bring this back? I feel like those changes have caused this issue.

Steps to reproduce

  1. Install latest version of react navigation and with native stack
  2. Install latest version of RN Screens

Snack or a link to a repository

https://github.com/software-mansion/react-native-screens/tree/main/Example

Screens version

3.34.0

React Native version

0.76.0-rc.1

Platforms

iOS

JavaScript runtime

Hermes

Workflow

React Native (without Expo)

Architecture

Fabric (New Architecture)

Build type

Debug mode

Device

iOS simulator

Device model

iPhone 16 Pro

Acknowledgements

Yes

github-actions[bot] commented 1 month ago

Hey! 👋

The issue doesn't seem to contain a minimal reproduction.

Could you provide a snack or a link to a GitHub repository under your username that reproduces the problem?

kkafar commented 1 month ago

Hey @matinzd, yeah if the default behaviour has changed it is unintended and should be considered a bug. You should be able to bring back old behaviour by setting sheetAllowedDetents: 'large' or sheetAllowedDetents: [1.0], depending on which line of react-native-screens you're on.

Thanks for noticing this.

matinzd commented 1 month ago

The last time I tried changing it to large didn't work. I assume that it's related to version mismatch and breaking changes. I am not really sure why this change has landed on v3. Since this is a breaking change it would have been better to be on beta v4 and now it's affecting users that are upgrading to the latest version of rn screens. I am not sure if react navigation is exposing the types directly from rn screens or not. I will do some more investigations when I get to the office.

kkafar commented 1 month ago

I'll have throughput to patch this only after v4 is released.