Skipperlla / rn-swiper-list

⚡ Lightning fast and customizable tinder-like swiper for React Native
https://www.npmjs.com/package/rn-swiper-list
MIT License
102 stars 9 forks source link

Swipe amount #29

Closed pekanct closed 1 week ago

pekanct commented 2 weeks ago

Please, can you add the amount of the swipe to the onSwipeActive event? I would like to add an animation that is played based on the swipe but at the moment I have not found any way to derive this value.

Thankyou 🙏🏻

Skipperlla commented 2 weeks ago

by scroll amount you mean activeIndex, right? I don't quite understand what you said @pekanct

pekanct commented 2 weeks ago

I mean the amount of movement performed. For example, if I hold my finger down and stop the animation halfway, this value will be 50%. 100% is when the final event (eg. onSwipeRight) is triggered.. The same principle that is currently used for the opacity of the overlay, the further you swipe the card, the more the opacity of the overlay label increases. @Skipperlla I hope I was clearer now

Skipperlla commented 1 week ago

I'm a little busy at the moment, if I have time I will add it