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] keyboardBehavior="extend" and keyboardBlurBehavior="restore" not work together #1894

Open
zcmgyu opened this issue Jul 26, 2024 · 3 comments
Labels
bug Something isn't working no-issue-activity

Comments

@zcmgyu
Copy link

zcmgyu commented Jul 26, 2024

Bug

In version 4 of the @gorhom/bottom-sheet library, there appears to be a conflict between the keyboardBehavior set to "extend" and the keyboardBlurBehavior set to "restore". When the BottomSheetModal is initially at a snapPoint of "25%" and the keyboard is activated, the modal correctly extends to "60%". However, upon the keyboard's dismissal, the modal fails to restore back to the "25%" snap point as expected.

Environment info

Library Version
@gorhom/bottom-sheet 4.6.3
react-native 0.74.3
react-native-reanimated ^3.14.0
react-native-gesture-handler 4.6.3

Steps To Reproduce

  1. Initialize BottomSheetModal with snapPoints set to ["25%", "60%"].
  2. Set keyboardBehavior to "extend" and keyboardBlurBehavior to "restore".
  3. Set BottomSheetTextInput as children component
  4. Trigger the keyboard to appear by focusing on TextInput. Observe the modal extending to "60%".
  5. Dismiss the keyboard and observe the modal's failure to restore to "25%".

Describe what you expected to happen:

  1. When the keyboard is dismissed, the BottomSheetModal should restore back to the initial "25%" snap point.
  2. The modal's behavior should be consistent with the defined properties for keyboard interaction.

Reproducible sample code

https://github.com/zcmgyu/repoduce-bottom-sheet-issue

@zcmgyu zcmgyu added the bug Something isn't working label Jul 26, 2024
@longnguyen2508
Copy link

Bump

@sudhanshu-busy
Copy link

any solution?

Copy link

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.

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

No branches or pull requests

3 participants