react-native-bottom-sheet icon indicating copy to clipboard operation
react-native-bottom-sheet copied to clipboard

[Bug]: Keyboard adjust doesn't work in Android 13 if Devices locks/Unlocks

Open NaudyDev opened this issue 2 months ago • 4 comments

Version

v5

Reanimated Version

v3

Gesture Handler Version

v2

Platforms

Android

What happened?

We are using gorhom/react-native-bottom-sheet: 5.2.6 and using this library we are using TextInput inside the bottomsheet Modal where we are trying to adjust the bottomsheetModal using runOnUI(() => { internal.shouldHandleKeyboardEvents.value = true })()

on focus but this is working fine in all versions, but in android 13 if i lock my device and unlock try to adjust the bottomsheet modal again keyboard is not not getting adjusted its overlapping the modal.

<BottomSheetModal ref={modalRef} snapPoints={snapPoints} onDismiss={() => { onClose?.() onModalClosed?.() }} onAnimate={handleOpen} overrideReduceMotion={ReduceMotion.Never} animatedPosition={animatedPosition} keyboardBehavior="interactive" keyboardBlurBehavior="restore" accessibilityLabel={'close'} accessibilityHint={'bottomsheet modal'} android_keyboardInputMode={Platform.OS === 'android' && Platform.Version >= 34 ? 'adjustPan' : 'adjustResize'} importantForAccessibility="yes">

<InputText/></BottomSheetModal>

@gorhom @thecodedrift

Please help in this. issue.

Reproduction steps

  • start the modal with input text, it will adjust properly.
  • lock the phone and unlock it.
  • try to open the modal and focus on the input text.

this is working demo when we initially run it. https://github.com/user-attachments/assets/8ef7df7c-1c2a-447a-a08f-b6534370fefc

this is after lock.unlock device its not working https://github.com/user-attachments/assets/d6aa7447-801c-4b7f-addb-ba5d6f980315

Reproduction sample

https://snack.expo.dev/@nounreal/bottom-sheet---issue-reproduction-template

Relevant log output


NaudyDev avatar Nov 05 '25 15:11 NaudyDev

@gorhom please check its kinda major issue for me now.

NaudyDev avatar Nov 05 '25 15:11 NaudyDev

Up

thiagoemanoel98 avatar Nov 06 '25 17:11 thiagoemanoel98

"react-native-reanimated": "3.19.3", "@gorhom/bottom-sheet": "5.2.6",

in this version internal.shouldHandleKeyboardEvents.value = true this has been removed how should we now adjust the TextInput in bottomsheetModal and it lags

NaudyDev avatar Nov 11 '25 18:11 NaudyDev

+1

enchorb avatar Nov 16 '25 14:11 enchorb

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.

github-actions[bot] avatar Dec 17 '25 09:12 github-actions[bot]

+1

jguipi avatar Dec 18 '25 22:12 jguipi