react-native-autocomplete-dropdown
react-native-autocomplete-dropdown copied to clipboard
Dropdown not scrollable + Dropdown does not close when tapped outside
Versions: "react-native": "0.73.6", "react-native-autocomplete-dropdown": "3.1.5", "expo": "^50.0.17"
Issue: I am using the example from the documentation and the dropdown is not scrollable and does not close when I tap outside. I saw there were some tickets with the same issues, but they were either closed or unanswered.
Tested solutions:
- remove closeOnBlur which fixes the scroll, but I still need the dropdown to close when I tap outside
- handle the dropdown close with custom code using
controllerprop and"react-native-outside-press": "^1.2.2", but no luck because I couldn't choose an option anymore
The last RC ^4.0.0-rc.5 seems to work just fine in these cases, but is there any other solution besides using a release candidate?
<AutocompleteDropdown
clearOnFocus={false}
// closeOnBlur={true}
closeOnSubmit={false}
onSelectItem={setSelectedItem}
dataSet={[
{ id: '1', title: 'Alpha' },
{ id: '2', title: 'Beta' },
{ id: '3', title: 'Gamma' },
{ id: '4', title: 'Alpha' },
{ id: '5', title: 'Beta' },
{ id: '6', title: 'Gamma' }
]}
/>
+1