Jquery carousel animation jumping

I am using the jQuery plugin from CarouFredSel ( http://caroufredsel.dev7studios.com ) to create an animated carousel on my site. However, I noticed that the animation is not correct - it animates waaay too much (compared to the settings that I encoded), and then at the end of the animation it goes to the correct position.

Here is the page where the error occurs: http://mnogal.pl/kopernik/html/strona_glowna.html - the text should always be in the middle, and the animation should just go to the next text in the middle.

It is currently configured as PIC 1 - TEXT - PIC 2 - TEXT - PIC 1, etc., so it should alternate the position of the two images after each animation, if that makes sense.

I finish showing the right thing after the animation, it just animates too far and jumps to its end.

I checked the demo from the side and nothing like this happened, my code also seems to be correct, nothing unusual:

$("#carousel .overview").carouFredSel({ height: 507, items: { visible: 3, }, scroll: { items: 2, duration: 3000 }, auto: 6000 }); 

Can anyone help? I can’t figure it out.

+4
source share
3 answers

There are no scripts.js files on the server (http://mnogal.pl/kopernik/html/js/scripts.js). The generated error prevents another javascript from starting. Install it first!

+7
source

You can try the following: http://jsfiddle.net/mW5Y9/2/ . Live demo of what @MichaelCalkins means.

 <div id="myCarousel" class="carousel slide" data-interval="your_interval_in_secs"> <!-- Carousel items --> <div class="carousel-inner"> <div class="active item"></div> <div class="item"></div> <div class="item"></div> </div> <!-- Carousel nav --> <a class="carousel-control left" href="#myCarousel" data-slide="prev">&lsaquo;</a> <a class="carousel-control right" href="#myCarousel" data-slide="next">&rsaquo;</a> </div> 
0
source

Source: https://habr.com/ru/post/1441691/