I am currently looking to use tiny-slider instead of OWLCarousel2. However, I have noticed a bug... when using the autoplay feature it will stop working if you use the nav buttons to change the slide.
How can I get it to work so the autoplay won't be stopped?
Similarly, the autoplay will also keep sliding the slides even when hovering the nav pagination buttons for the slider. Therefore,how can I make it so it pauses on hover with the nav then resumes when not?
also with me....
@jeffersonest Shame ain't it. Would be good if it worked as intended.
The same issue
ah, still no answer
same issue
I have the same issue aswell. Is this intended behaviour?
Discovered that there is already a closed ticket for this bug:
https://github.com/ganlanyuan/tiny-slider/issues/195
I just created my own autoPlay function to solve this. It's quite easy:
this.config = {
...,
onInit: () => {
this.autoPlay()
},
}
/**
* Create autoplay because tiny autoplay stops autoplay on user interaciton
*/
autoPlay() {
this.interval = setInterval(() => this.instance.goTo('next'), 5000)
}
/**
* Restarts autoplay of sliders
*/
restartAutoplay() {
clearInterval(this.interval)
this.autoPlay()
}
/**
* Bind general events
*/
bindEvents() {
this.controls.forEach(button =>
button.addEventListener('click', () => {
this.restartAutoplay()
}),
)
if (this.slider) {
this.slider.events.on('touchStart', () => {
this.restartAutoplay()
})
}
}
Most helpful comment
Discovered that there is already a closed ticket for this bug:
https://github.com/ganlanyuan/tiny-slider/issues/195
I just created my own autoPlay function to solve this. It's quite easy: