GeekyAnts / NativeBase

Mobile-first, accessible components for React Native & Web to build consistent UI across Android, iOS and Web.
https://nativebase.io/
MIT License
20.2k stars 2.39k forks source link

Deck Swiper - Goto Index (wish/feature) #626

Closed fbacker closed 6 years ago

fbacker commented 7 years ago
"native-base": "2.0.7",
"react": "15.4.2",
"react-native": "^0.41.2",

Is it possible to choose 'selected index' for the Deck Swiper?

For e.g. Having a Deck Swiper showing images. Below a have a grid of thumbnails (ListView). When I press the thumbnail I would like the Deck Swiper to select the correct view.

this.refs.deckswiper.selectedIndex(2)

Also having the Deck Swiper event trigger when a deck is selected would be kickass

onSwipe={(index) => console.log('new card is selected',index)}
sankhadeeproy007 commented 7 years ago

We'll see if that can be done :)

ll0406 commented 7 years ago

YES!! please implement this feature!

philohelp commented 7 years ago

Yes onSwipe={(index) => console.log('new card is selected',index)} would be a huge gain, as I have no mean to know where I am (except with counting onSwipeRight / onSwipeLeft). My beta testers keep asking "how do you go back ?" but I have no idea...

cinder92 commented 7 years ago

is there any update on this? :)

if anyone want to use this feature before native base done, this is a really cool component for that, and has the onSwiped ={index => {}}

https://github.com/alexbrillant/react-native-deck-swiper

dienast commented 6 years ago

This would be a huge improvement. +1

miukki commented 6 years ago

image 8(

gupta-ji6 commented 6 years ago

Kindly add this as early as possible. This is a very useful feature

SupriyaKalghatgi commented 6 years ago

38

arjun-bhatt commented 4 years ago

Any update?