我创建了一个图像摇动效果的循环动画片段。问题。
function afterReveal (el) {
//event listener when the animation finishes
el.addEventListener('animationend', function () {
$("#test").attr("data-wow-delay","6s");
new WOW().init();
});
}
new WOW({ callback: afterReveal }).init();
.course-img2 img{
width:30%;
}
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/wow/1.1.2/wow.min.js"></script>
<link href="https://cdnjs.cloudflare.com/ajax/libs/animate.css/3.5.2/animate.min.css" rel="stylesheet"/>
<div id="test" data-wow-delay="300ms" data-wow-iteration="2" data-wow-duration="0.60s" class="wow shake course-img2"> <img src="http://qnimate.com/wp-content/uploads/2014/03/images2.jpg" alt="Logo"> </div>
Wow.js
库在完成动画时似乎会循环visibility
。为了对抗此,将以下内容添加到您的CSS
jsfiddle
.course-img2{
visibility:visible !important;
}