react-native-modal-picker
react-native-modal-picker copied to clipboard
modal doesn't close on selecting data inside condition. see the below code
{(this.state.modeOfPermission == 'SPECIFIC') &&
(<ModalPicker
data={this.state.mailList}
initValue="Select mail id"
onChange={(option) => { this.setState({selectedMail: option.label }) }}>
<TextInput
style={{ borderWidth: 1, borderColor: '#ccc', padding: 10, height: 50, marginLeft: 10, marginRight: 10, backgroundColor: '#FFF' }}
editable={false}
placeholder="Select E-mail id .."
value={this.state.selectedMail} />
</ModalPicker>
)}
without this.state.modeOfPermission == 'SPECIFIC' condition it is working properly
Not sure if I understand your problem. Is this iOS-only? If that is the case, then this may already be fixed in version 0.0.18 of react-native-modal-selector, see issue #4 in react-native-modal-selector