...
|
...
|
@@ -6,6 +6,7 @@ import Swiper from 'react-native-swiper'; |
|
|
import ImmutablePropTypes from 'react-immutable-proptypes';
|
|
|
import SlicedImage from '../../../common/components/SlicedImage';
|
|
|
import Immutable, {Map} from 'immutable';
|
|
|
import RecyclerSwiper from '../../../common/recycler-swiper/recyclerswiper'
|
|
|
|
|
|
const {
|
|
|
View,
|
...
|
...
|
@@ -15,6 +16,7 @@ const { |
|
|
Dimensions,
|
|
|
Platform,
|
|
|
} = ReactNative;
|
|
|
const YH_Swiper = (Platform.OS === 'ios') ? Swiper : RecyclerSwiper;
|
|
|
|
|
|
export default class ListBannerSwiper extends React.Component {
|
|
|
|
...
|
...
|
@@ -52,13 +54,12 @@ export default class ListBannerSwiper extends React.Component { |
|
|
|
|
|
return (
|
|
|
<View style={styles.container}>
|
|
|
<Swiper
|
|
|
<YH_Swiper
|
|
|
style={styles.banner}
|
|
|
showsButtons={false}
|
|
|
loop={true}
|
|
|
autoplay={true}
|
|
|
autoplayTimeout={2}
|
|
|
paginationStyle={{bottom: 8}}
|
|
|
dot={this.dot}
|
|
|
activeDot={(Platform.OS === 'ios')?this.activeDot:null}
|
|
|
width={width}
|
...
|
...
|
@@ -78,7 +79,7 @@ export default class ListBannerSwiper extends React.Component { |
|
|
</TouchableOpacity>
|
|
|
);
|
|
|
})}
|
|
|
</Swiper>
|
|
|
</YH_Swiper>
|
|
|
</View>
|
|
|
);
|
|
|
}
|
...
|
...
|
|