Introduction
animate.css is a CSS3 animation library from abroad. It has preset shake and flash. There are more than 60 animation effects such as , bounce, flip, rotate (rotateIn/rotateOut), fadeIn/fadeOut, etc., covering almost all common animation effects.
Although it is very convenient and fast to create CSS3 animation effects with the help of animate.css, it is still recommended to take a look at the code of animate.css. Maybe you can learn something from it.
Compatible
Browser compatibility: Of course, it is only compatible with browsers that support CSS3 animateproperty. They are: IE10+, Firefox, Chrome, Opera, and Safari.
Usage method
1. Import the file
2. HTML and use
to addclass## to the element # After refreshing the page, you can see the animation effect. animated is similar to the globalvariable, which defines the duration of the animation; bounce is the name of the specific animation effect of the animation, and you can choose any effect.
JavaScriptorjQuery, such as:
$(function(){ $('#dowebok').addClass('animated bounce'); });
$(function(){ $('#dowebok').addClass('animated bounce'); setTimeout(function(){ $('#dowebok').removeClass('bounce'); }, 1000); });
#dowebok { animate-duration: 2s; //动画持续时间 animate-delay: 1s; //动画延迟时间 animate-iteration-count: 2; //动画执行次数 }
CSS3 Learning Animation Detailed Explanation
3.CSS3 Teaching Animation Production Learning
4.Detailed analysis of the new features in CSS3##5.
Detailed explanation about the new features of css3The above is the detailed content of Share a CSS3 animation library. For more information, please follow other related articles on the PHP Chinese website!