Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 7 additions & 5 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ export default class ModalPicker extends BaseComponent {
return (
<View style={[styles.overlayStyle, this.props.overlayStyle]} key={'modalPicker'+(componentIndex++)}>
<View style={styles.optionContainer}>
<ScrollView keyboardShouldPersistTaps>
<ScrollView keyboardShouldPersistTaps="always">
<View style={{paddingHorizontal:10}}>
{options}
</View>
Expand All @@ -151,7 +151,11 @@ export default class ModalPicker extends BaseComponent {
renderChildren() {

if(this.props.children) {
return this.props.children;
return (
<TouchableOpacity style={this.props.selectStyle} onPress={this.open}>
{this.props.children}
</TouchableOpacity>
);
}
return (
<View style={[styles.selectStyle, this.props.selectStyle]}>
Expand All @@ -171,9 +175,7 @@ export default class ModalPicker extends BaseComponent {
return (
<View style={this.props.style}>
{dp}
<TouchableOpacity onPress={this.open}>
{this.renderChildren()}
</TouchableOpacity>
{this.renderChildren()}
</View>
);
}
Expand Down