开发者

jquery elastic animation doesn't complete

开发者 https://www.devze.com 2023-01-20 15:00 出处:网络
http://www.thebraproject.com/collection If you slide the clothesline backwards every third item stops dea开发者_C百科d without completing the elastic animation.Can anyone see why that might be happen

http://www.thebraproject.com/collection

If you slide the clothesline backwards every third item stops dea开发者_C百科d without completing the elastic animation. Can anyone see why that might be happening?

I'm using the AnythingSlider for jQuery to make it work.


I think maybe the problem is that the way the slider counts when you go forward and backward it is thinking it is the beginning of the slider and not running the transition. Try changing your third case

case 3:
 var previous_index = 2;
 var next_index = 1;
 break; 

what happens if you change the next_index variable? Does that fix it?


The easing breaks every time AnythingSlider is forced to "rotate" its pages. (Put another way: any time the item being moved to is a "li.cloned", the easing is broken.)

It looks to me like this is a bug within AnythingSlider, I think some of the animation-complete callbacks are being called without waiting for animation to actually complete.

I hesitate to analyze any further because the current site is using version 1.2 of AnythingSlider, latest version is v1.5.x. I would try upgrading and see if that fixes your problem.

https://github.com/ProLoser/AnythingSlider/downloads


I also noticed that any item that stopped without completing the animation continues to behave in that manner even if its not the third item the next time you slide them backwards. Other items that finished the animation when sliding backwards initially, complete their animation the next time you slide backwards even if they are the third item. So whatever is going wrong is going wrong the first time you slide backwards I think. Hope this helps if you haven't already fixed this.

0

精彩评论

暂无评论...
验证码 换一张
取 消