Hongmu Notes
Home Language Notes animate.css – a complete CSS3 animation library
Language Notes CSS

animate.css – a complete CSS3 animation library

animate.css – a complete CSS3 animation library

Introduction

animate.css is a CSS3 animation library from abroad. It presets more than 60 animation effects such as shake, flash, bounce, flip, rotate (rotateIn/rotateOut), fadeIn/fadeOut, etc., including almost all common animation effects.

Although animate.css can be used to create CSS3 animation effects very conveniently and quickly, 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 the CSS3 animate attribute. They are: IE10+, Firefox, Chrome, Opera, and Safari.

How to use

1. Import files

<link rel="stylesheet" href="animate.min.css">

2. HTML and usage

<div class="animated bounce" id="dowebok"></div>

After adding a class to the element, refresh the page and you will see the animation effect. animated is similar to a global variable, 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.

If the animation plays infinitely, you can add class infinite.

You can also add these classes to elements through JavaScript or jQuery, such as:

$(function(){
    $('#dowebok').addClass('animated bounce');
});

Some animation effects will eventually make the element invisible, such as fading out, sliding to the left, etc. You may need to delete the class, such as:

$(function(){
    $('#dowebok').addClass('animated bounce');
    setTimeout(function(){
        $('#dowebok').removeClass('bounce');
    }, 1000);
});

The default settings of animate.css may not be what we want sometimes, so you can reset them, for example:

#dowebok {
    animate-duration: 2s;    //动画持续时间
    animate-delay: 1s;    //动画延迟时间
    animate-iteration-count: 2;    //动画执行次数
}

Note adding the browser prefix.

微信赞赏

WeChat

支付宝赞赏

Alipay

✍️ Author: Hong Mu

webmaster · Thanks for reading, stay tuned for more exciting content

Author homepage View home page →

Related articles

css positioning

css positioning Language Notes CSS

Syntax: position: static | relative | absolute | fixed | center | page | sticky Default value: static Applies to: All elements except the display attribute defined as table-column-group | table-column Inheritance: No Animation: No...
👁 119
css vh and vw adaptive

css vh and vw adaptive Language Notes CSS

In the mobile terminal, REM is used to change the root HTML, and the mobile terminal adaptation is realized through a piece of JS. This article uses pure CSS viewport units to self-adapt. Although the current compatibility is not fully acceptable, it does not prevent you from recognizing the power of vw and vh. The implementation of responsive layout relies on media queries (Media Queries). Select the width size of mainstream devices as breakpoints to target...
👁 356

Recommended reading

Responsive Business Registration and Company Website Template – 1158

Responsive Business Registration and Company Website Template – 1158 Practical Collection Yiyou template

This eyouCMS responsive template is ideal for the business registration and corporate services sector. Its professional and sophisticated design effectively showcases business registration services, business consulting offerings, successful case studies, and customer testimonials, helping business service providers attract startup clients online. Template Display | Installation Instructions | Website Backend: /login.php | Username: admin | Password: admin | Related Articles: Summary of Common Installation Issues for YouyouCMS | YouyouCMS...
👁 57
Business Service Product Website Template 1159

Business Service Product Website Template 1159 Practical Collection Yiyou template

An eYouCMS template designed specifically for commercial service product-based websites. Its professional and practical design style is ideal for showcasing commercial service offerings, product introductions, client testimonials, and corporate strength. This template helps commercial service companies effectively present their brand online and attract corporate clients. Template Display | Installation Instructions | Website Backend: /login.php | Username: admin | Password: admin | Related Articles: Summary of Common Installation Issues for eYouCMS | eYouCMS (...
👁 42
Responsive Tax Agency Business Website Template 1160

Responsive Tax Agency Business Website Template 1160 Practical Collection Yiyou template

This EyouCMS responsive template is ideal for the tax agency and business services industries. Its professional and sophisticated design effectively showcases tax agency services, business consulting offerings, successful case studies, and customer testimonials. It helps financial and tax service providers attract corporate clients online and expand their business reach. Template Display | Installation Instructions | Website Backend: /login.php | Username: admin | Password: admin | Related Articles: Summary of Common Installation Issues for EyouCMS...
👁 54
Resource website typecho001 template

Resource website typecho001 template Program Notes Typecho

typecho001 template template please do not modify the folder name of this template. The folder name is: typecho001 1.4 Fix the js output problem on the article page 1.3 Fix the error prompt when the plug-in is not installed Optimize the list page code output 1.2 Fix the comment function and add a custom homepage title 1.1 Fix the comment reply asymmetry function Add a separate title setting function on the homepage Add the website favicon.ico icon Add one...
👁 198
Responsive e-commerce company website template 1161

Responsive e-commerce company website template 1161 Practical Collection Yiyou template

An EYO CMS responsive website template designed specifically for e-commerce businesses. Its modern e-commerce design enables effective presentation of e-commerce platforms, product categories, checkout processes, and brand identity. This template helps e-commerce enterprises showcase their brands online and attract consumers. Template Overview | Installation Instructions | Website Backend: /login.php | Username: admin | Password: admin | Related Articles: Summary of Common Installation Issues for EYO CMS | EYO CMS (Eyo...
👁 36
Modification of typecho paging style

Modification of typecho paging style Program Notes Typecho

Sir, times have changed! Typecho is currently the most perfect solution, because Baidu can only see the code of fixed thinking. The actual generated HTML code is breathtakingly clean and fully customized, including adding classes to the li element, adding classes to the a element, adding classes to the previous page and next page, and removing the li tags that come with typecho to express more. I can even add some text to the content inside...
👁 517