react-native-modal-selector
Advanced tools
Comparing version 0.0.22 to 0.0.23
@@ -13,2 +13,3 @@ 'use strict'; | ||
TouchableWithoutFeedback, | ||
Platform, | ||
ViewPropTypes as RNViewPropTypes, | ||
@@ -23,3 +24,2 @@ } from 'react-native'; | ||
let componentIndex = 0; | ||
let rnVersion = Number.parseFloat(require('react-native/package.json').version); | ||
@@ -105,5 +105,8 @@ const propTypes = { | ||
onChange(item) { | ||
rnVersion < 0.50 && this.props.onChange(item); | ||
if (Platform.OS === 'android' || !Modal.propTypes.onDismiss) { | ||
// RN >= 0.50 on iOS comes with the onDismiss prop for Modal which solves RN issue #10471 | ||
this.props.onChange(item) | ||
} | ||
this.setState({selected: item.label, changedItem: item }); | ||
this.close() | ||
this.close(); | ||
} | ||
@@ -110,0 +113,0 @@ |
{ | ||
"name": "react-native-modal-selector", | ||
"version": "0.0.22", | ||
"version": "0.0.23", | ||
"description": "A cross-platform (iOS / Android), selector/picker component for React Native that is highly customizable and supports sections.", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
Sorry, the diff of this file is not supported yet
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
27422
11
260
0