-
Notifications
You must be signed in to change notification settings - Fork 2.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Example with maps view #11
Comments
All the code related to The trick is to use the prop [...]
_centerMapOnMarker (markerIndex) {
const mapRef = this._mapView;
const markerData = this.state.markers[markerIndex];
if (!markerData || !mapRef) {
return;
}
mapRef.animateToRegion({
latitude: markerData.geolocation.latitude - CENTER_LAT_OFFSET,
longitude: markerData.geolocation.longitude,
latitudeDelta: 0.0315,
longitudeDelta: 0.0258
});
}
<Carousel
items={filteredMarkers}
renderItem={this._renderSwiperItem}
firstItem={firstItem}
sliderWidth={sliderWidth}
itemWidth={itemWidth}
snapOnAndroid={true}
showsHorizontalScrollIndicator={false}
slideStyle={styles.slide}
containerCustomStyle={styles.slider}
contentContainerCustomStyle={styles.sliderContainer}
inactiveSlideScale={1}
inactiveSlideOpacity={0.8}
removeClippedSubviews={false}
onSnapToItem={(index, marker) => this._centerMapOnMarker(marker.absoluteIndex)}
/>
I won't build a specific example, especially since |
Hi All contributors!! Great work! Just added in a project today! But In prototype on which I am working on have this carousal with continuous slow motion rather than jump from slide to slide..!! Is there any option to do the behavior in that way?? |
@umer990 Hi! You can use the prop |
I couldn't find any difference by using that property as I am using autoplay=true.I am looking for the slider/carousal with motion like rail(move continous instead of jumping from one slide to another) of pics!! |
Hi guys, I'm trying to implement the carousel inside of the |
|
Would love to see the example with the maps view (3rd gif) as well.
The text was updated successfully, but these errors were encountered: