Как удалить класс в слайде после прокручивания?

голоса: 0

Для анимации текста в Swipe-slider использую скрипт

swiper.on('slideChangeTransitionStart', function () {
 var $el = $(this.slides[ this.activeIndex ]),
 $animate = $el.find('[data-animate]');

 $animate.each(function () {
 var $t = $(this);

 $t.removeClass( 'animated ' + $t.data('animate') );
 });
 }).on('slideChangeTransitionEnd', function () {
 var $el = $(this.slides[ this.activeIndex ]),
 $animate = $el.find('[data-animate]');

 $animate.each(function () {
 var $el = $(this),
 $duration = $el.data('duration'),
 $delay = $el.data('delay');

 $duration = typeof $duration === 'undefined' ? '0.6' : $duration;
 $delay = typeof $delay === 'undefined' ? '0' : $delay;

 $el.addClass( 'animated ' + $el.data('animate') ).css({
 'animation-duration': $duration + 's',
 'animation-delay': $delay + 's'
 });
 });
 });

но после прокручивания слайда класс fadeInDown не удаляется и получается дёрганье. Как исправить?

| Автор: | Категория: JavaScript

Ответов: 1

голоса: 0
С данным скриптом вам нужно обращаться к автору скрипта так как требуется настройка плагина.
| Автор:
...