Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[v4] BottomSheet didn't go back to it's initial position after close the keyboard #1417

Closed
YuryDG opened this issue Jun 24, 2023 · 3 comments
Labels
bug Something isn't working

Comments

@YuryDG
Copy link

YuryDG commented Jun 24, 2023

Bug

When interacting with BottomSheetTextInput inside the BottomSheet, the BottomSheet changes its height when the keyboard is shown but when the keyboard is hidden, the BottomSheet didn't go back to its initial position.

I guess this behavior is not the expected one, I copy-paste the example from the documentation and it is not working as expected.

Did I miss something?

Environment info

Library Version
@gorhom/bottom-sheet 4.4.7
react-native 0.71.8
react-native-reanimated ~2.14.4
react-native-gesture-handler ~2.9.0

Steps To Reproduce

  1. Create a new app using npx create-expo-app@latest --example with-router
  2. Copy the example from the Documentation Keyboard handling
  3. Interact with the BottomSheetTextInput
Simulator.Screen.Recording.-.iPhone.14.Pro.-.2023-06-25.at.00.51.33.mp4

Describe what you expected to happen:

  1. BottomSheet should go back to its initial position after we close the keyboard

Reproducible sample code

I took the example from the documentation Keyboard handling

@YuryDG YuryDG added the bug Something isn't working label Jun 24, 2023
@YuryDG
Copy link
Author

YuryDG commented Jun 24, 2023

Hi team,
Thanks for the awesome Job with this package

I just solved the problem. There is a property missing for the BottomSheet on the example keyboardBlurBehavior="restore" . That is why is not working as expected.

Simulator.Screen.Recording.-.iPhone.14.Pro.-.2023-06-25.at.02.18.37.mp4

@gorhom I'm wondering why the default value of keyboardBlurBehavior prop is none instead of restore.
Is there any reason behind it?

If it's not possible to change it to restore, we could add them to the examples on the documentation.
I'm open to help 😄

Thanks in advance

@gorhom gorhom closed this as completed Jun 25, 2023
@bugra-kara
Copy link

Hi team, Thanks for the awesome Job with this package

I just solved the problem. There is a property missing for the BottomSheet on the example keyboardBlurBehavior="restore" . That is why is not working as expected.

Simulator.Screen.Recording.-.iPhone.14.Pro.-.2023-06-25.at.02.18.37.mp4

@gorhom I'm wondering why the default value of keyboardBlurBehavior prop is none instead of restore. Is there any reason behind it?

If it's not possible to change it to restore, we could add them to the examples on the documentation. I'm open to help 😄

Thanks in advance

thanks my man, it works clearly

@Ainul-Hossain
Copy link

Hi team, Thanks for the awesome Job with this package

I just solved the problem. There is a property missing for the BottomSheet on the example keyboardBlurBehavior="restore" . That is why is not working as expected.

Simulator.Screen.Recording.-.iPhone.14.Pro.-.2023-06-25.at.02.18.37.mp4
@gorhom I'm wondering why the default value of keyboardBlurBehavior prop is none instead of restore. Is there any reason behind it?

If it's not possible to change it to restore, we could add them to the examples on the documentation. I'm open to help 😄

Thanks in advance

Great!! Thanks, man. Working fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants