diff --git a/src/carousel/Carousel.js b/src/carousel/Carousel.js index dae71a3da..cb8742c6d 100644 --- a/src/carousel/Carousel.js +++ b/src/carousel/Carousel.js @@ -1,5 +1,5 @@ import React, { Component } from 'react'; -import { Animated, Easing, FlatList, I18nManager, Platform, ScrollView, View, ViewPropTypes } from 'react-native'; +import { Animated, Easing, FlatList, I18nManager, Platform, ScrollView, View, ViewStyle, ViewPropTypes } from 'react-native'; import PropTypes from 'prop-types'; import shallowCompare from 'react-addons-shallow-compare'; import { @@ -43,8 +43,8 @@ export default class Carousel extends Component { autoplayDelay: PropTypes.number, autoplayInterval: PropTypes.number, callbackOffsetMargin: PropTypes.number, - containerCustomStyle: ViewPropTypes ? ViewPropTypes.style : View.propTypes.style, - contentContainerCustomStyle: ViewPropTypes ? ViewPropTypes.style : View.propTypes.style, + containerCustomStyle: ViewPropTypes ? ViewPropTypes.style : ViewStyle, + contentContainerCustomStyle: ViewPropTypes ? ViewPropTypes.style : ViewStyle, enableMomentum: PropTypes.bool, enableSnap: PropTypes.bool, firstItem: PropTypes.number, @@ -61,7 +61,7 @@ export default class Carousel extends Component { scrollEnabled: PropTypes.bool, scrollInterpolator: PropTypes.func, slideInterpolatedStyle: PropTypes.func, - slideStyle: ViewPropTypes ? ViewPropTypes.style : View.propTypes.style, + slideStyle: ViewPropTypes ? ViewPropTypes.style : ViewStyle, shouldOptimizeUpdates: PropTypes.bool, swipeThreshold: PropTypes.number, useScrollView: PropTypes.oneOfType([PropTypes.bool, PropTypes.func]), diff --git a/src/pagination/Pagination.js b/src/pagination/Pagination.js index 5c021cf36..7d48f3355 100644 --- a/src/pagination/Pagination.js +++ b/src/pagination/Pagination.js @@ -1,5 +1,5 @@ import React, { PureComponent } from 'react'; -import { I18nManager, Platform, View, ViewPropTypes } from 'react-native'; +import { I18nManager, Platform, View, ViewStyle, ViewPropTypes } from 'react-native'; import PropTypes from 'prop-types'; import PaginationDot from './PaginationDot'; import styles from './Pagination.style'; @@ -14,16 +14,16 @@ export default class Pagination extends PureComponent { dotsLength: PropTypes.number.isRequired, activeOpacity: PropTypes.number, carouselRef: PropTypes.object, - containerStyle: ViewPropTypes ? ViewPropTypes.style : View.propTypes.style, + containerStyle: ViewPropTypes ? ViewPropTypes.style : ViewStyle, dotColor: PropTypes.string, - dotContainerStyle: ViewPropTypes ? ViewPropTypes.style : View.propTypes.style, + dotContainerStyle: ViewPropTypes ? ViewPropTypes.style : ViewStyle, dotElement: PropTypes.element, - dotStyle: ViewPropTypes ? ViewPropTypes.style : View.propTypes.style, + dotStyle: ViewPropTypes ? ViewPropTypes.style : ViewStyle, inactiveDotColor: PropTypes.string, inactiveDotElement: PropTypes.element, inactiveDotOpacity: PropTypes.number, inactiveDotScale: PropTypes.number, - inactiveDotStyle: ViewPropTypes ? ViewPropTypes.style : View.propTypes.style, + inactiveDotStyle: ViewPropTypes ? ViewPropTypes.style : ViewStyle, renderDots: PropTypes.func, tappableDots: PropTypes.bool, vertical: PropTypes.bool, diff --git a/src/pagination/PaginationDot.js b/src/pagination/PaginationDot.js index e59d1969f..3a37de91a 100644 --- a/src/pagination/PaginationDot.js +++ b/src/pagination/PaginationDot.js @@ -1,5 +1,5 @@ import React, { PureComponent } from 'react'; -import { View, Animated, Easing, TouchableOpacity, ViewPropTypes } from 'react-native'; +import { View, Animated, Easing, TouchableOpacity, ViewStyle, ViewPropTypes } from 'react-native'; import PropTypes from 'prop-types'; import styles from './Pagination.style'; @@ -12,11 +12,11 @@ export default class PaginationDot extends PureComponent { activeOpacity: PropTypes.number, carouselRef: PropTypes.object, color: PropTypes.string, - containerStyle: ViewPropTypes ? ViewPropTypes.style : View.propTypes.style, + containerStyle: ViewPropTypes ? ViewPropTypes.style : ViewStyle, inactiveColor: PropTypes.string, - inactiveStyle: ViewPropTypes ? ViewPropTypes.style : View.propTypes.style, + inactiveStyle: ViewPropTypes ? ViewPropTypes.style : ViewStyle, index: PropTypes.number, - style: ViewPropTypes ? ViewPropTypes.style : View.propTypes.style, + style: ViewPropTypes ? ViewPropTypes.style : ViewStyle, tappable: PropTypes.bool }; diff --git a/src/parallaximage/ParallaxImage.js b/src/parallaximage/ParallaxImage.js index 8bc774a10..0f6a414bf 100644 --- a/src/parallaximage/ParallaxImage.js +++ b/src/parallaximage/ParallaxImage.js @@ -1,7 +1,7 @@ // Parallax effect inspired by https://github.com/oblador/react-native-parallax/ import React, { Component } from 'react'; -import { View, ViewPropTypes, Image, Animated, Easing, ActivityIndicator, findNodeHandle } from 'react-native'; +import { View, ViewStyle, ViewPropTypes, Image, Animated, Easing, ActivityIndicator, findNodeHandle } from 'react-native'; import PropTypes from 'prop-types'; import styles from './ParallaxImage.style'; @@ -16,7 +16,7 @@ export default class ParallaxImage extends Component { sliderHeight: PropTypes.number, // passed from sliderWidth: PropTypes.number, // passed from vertical: PropTypes.bool, // passed from - containerStyle: ViewPropTypes ? ViewPropTypes.style : View.propTypes.style, + containerStyle: ViewPropTypes ? ViewPropTypes.style : ViewStyle, dimensions: PropTypes.shape({ width: PropTypes.number, height: PropTypes.number