Skip to content

Commit 2713cb1

Browse files
author
Mark Jamieson
committed
Change ScrollView to InvertibleScrollView
1 parent eca9a44 commit 2713cb1

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

viewpager/ViewPager.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66

77
import React, {Component} from 'react';
88
import {StyleSheet, View, ViewPagerAndroid, ScrollView, Platform, PanResponder} from 'react-native';
9+
import InvertibleScrollView from 'react-native-invertible-scroll-view';
910

1011
const SCROLLVIEW_REF = 'scrollView';
1112
const VIEWPAGER_REF = 'viewPager';
@@ -86,10 +87,10 @@ export default class ViewPager extends Component {
8687
marginHorizontal: -this.props.pageMargin / 2,
8788
};
8889
if (this.props.style && !this.props.style.height)
89-
return <ScrollView {...props} style={[this.props.style, scrollViewStyle]}/>;
90+
return <InvertibleScrollView {...props} style={[this.props.style, scrollViewStyle]}/>;
9091
else return (
9192
<View style={this.props.style}>
92-
<ScrollView {...props} style={scrollViewStyle}/>
93+
<InvertibleScrollView {...props} style={scrollViewStyle}/>
9394
</View>
9495
);
9596
}

0 commit comments

Comments
 (0)