Loading bar on slider

Hey guys,

I am trying to create a custom slider that changes the slides every 5 seconds and has a loading bar.

However, after multiple hours trying to figure this out with custom code and webflow interaction, I think I hit a dead end.

If I let it alone it works fine, but if I click the arrows to manually change the slides it stops working.

Does somebody have any idea why the timer is not resetting after I manually change the slide?