AdelRedaa97/react-native-select-dropdown

Keyboard overlapping dropdown.

Closed this issue · 1 comments

Hi, great library!!

With statusBarTranslucent={true} The dropdown appears nicely in a right place but if the input is somewhere in the lower part of the screen and keyboard appears the dropdown is moved slightly up. Roughly the height of one row. That is not enough as most of the dropdown disappears beneath the keyboard and the overlay is not scrollable. My solution was to change the row height * 3 to row height * 6 which reflects on how many rows I display.
const safeDropdownViewUnderKeyboard = rowStyle && rowStyle.height ? rowStyle.height * 6 : 50 * 6; in useLayoutDropdown
It would be nice if that number could be set manually as props.
Best wishes!

Fixed in v4.0 take a look at the changes made in v4.0
https://github.com/AdelRedaa97/react-native-select-dropdown?tab=readme-ov-file#-major-changes

Feel free to open the issue again if it still exists