FormidableLabs / nuka-carousel

Small, fast, and accessibility-first React carousel library with an easily customizable UI and behavior to fit your brand and site.
https://commerce.nearform.com/open-source/nuka-carousel
Other
3.02k stars 597 forks source link

[v6] Add new property which stops autoplay when user interacts with carousel buttons #918

Closed gksander closed 1 year ago

gksander commented 1 year ago

Add a carousel prop that will cancel autoplay when user interacts with carousel controls.

fritz-c commented 1 year ago

Related: #499

fritz-c commented 1 year ago

I'm in the process of adding an onUserNavigation callback that would make this behavior easily achievable while allowing for a bit more flexibility in exactly how the autoplay stops and starts. For example, rather than disabling autoplay completely, they could merely set a longer autoplayInterval temporarily, so autoplay eventually resumes.