react-native-sectioned-multi-select
Advanced tools
Comparing version 0.7.1 to 0.7.2
# Changelog | ||
## 0.7.2 - 2019-10-14 | ||
### Fixed | ||
- remove deprecated `componentWillReceiveProps` #147 | ||
- fix subitem `iconRenderer` usage #142 | ||
## 0.7.1 - 2019-08-01 | ||
@@ -20,3 +27,3 @@ | ||
## Changed | ||
### Changed | ||
@@ -48,4 +55,2 @@ - Made readme example more concise | ||
# Changelog | ||
## 0.6.4 - 2019-01-17 | ||
@@ -52,0 +57,0 @@ |
@@ -93,2 +93,3 @@ import React, { Component } from 'react' | ||
iconKey, | ||
iconRenderer: Icon, | ||
} = this.props | ||
@@ -127,7 +128,8 @@ | ||
{iconKey && subItem[iconKey] && ( | ||
<ItemIcon | ||
iconKey={iconKey} | ||
icon={subItem[iconKey]} | ||
style={mergedStyles.itemIconStyle} | ||
/> | ||
<ItemIcon | ||
iconRenderer={Icon} | ||
iconKey={iconKey} | ||
icon={subItem[iconKey]} | ||
style={mergedStyles.itemIconStyle} | ||
/> | ||
)} | ||
@@ -134,0 +136,0 @@ <Text |
@@ -268,8 +268,8 @@ import React, { PureComponent } from 'react' | ||
componentWillReceiveProps(nextProps) { | ||
if (!isEqual(this.props.styles, nextProps.styles)) { | ||
this.setState({ styles: StyleSheet.flatten([defaultStyles, nextProps.styles]) }) | ||
componentDidUpdate(prevProps) { | ||
if (!isEqual(prevProps.styles, this.props.styles)) { | ||
this.setState({ styles: StyleSheet.flatten([defaultStyles, this.props.styles]) }) | ||
} | ||
if (!isEqual(this.props.colors, nextProps.colors)) { | ||
this.setState({ colors: StyleSheet.flatten([defaultColors, nextProps.colors]) }) | ||
if (!isEqual(prevProps.colors, this.props.colors)) { | ||
this.setState({ colors: StyleSheet.flatten([defaultColors, this.props.colors]) }) | ||
} | ||
@@ -276,0 +276,0 @@ } |
{ | ||
"name": "react-native-sectioned-multi-select", | ||
"version": "0.7.1", | ||
"version": "0.7.2", | ||
"description": "a multi (or single) select component with support for sub categories, search, chips.", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -151,2 +151,8 @@ # react-native-sectioned-multi-select | ||
You can also pass in extra options to individual items: | ||
- `disabled: true` - the item will be disabled | ||
- Icons: the component prop `iconKey` is the name of the property that individual item icons will be derived from. E.g `icon: {uri: ...}`. See full example [here](https://github.com/renrizzolo/react-native-sectioned-multi-select/blob/master/Recipes.md#item-icons) | ||
## Props | ||
@@ -153,0 +159,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
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
3111022
2385
302
1