Home  >  Article  >  Web Front-end  >  Code sharing using css3 to realize the animation effect of a circle spreading from the center to the surroundings

Code sharing using css3 to realize the animation effect of a circle spreading from the center to the surroundings

黄舟
黄舟Original
2017-05-25 10:26:585239browse

Let’s take a simple example first, for example:

@
key
frames hovertreemove
{
from {
top
:30px;}
to {top:130px;}
}

You can create animation through @keyframes rules.

The principle of creating animation is to gradually change one set of CSS styles into another set of styles.
You can change this set of CSS styles multiple times during the animation.
Specify the time when the change occurs as a percentage, or through the keywords "from" and "to", which are equivalent to 0% and 100%.
0% is the start time of the animation, 100% is the end time of the animation.
For best browser support, you should always define 0% and 100% selectors.

The following is the code for up and down movement:


    
    css3使用animation和@keyframes制作动画_何问起
    
    
说明

The following is the code for circular diffusion movement:


    
    
    纯css3圆形从中心向四周扩散动画效果_何问起
    
说明

The above is the detailed content of Code sharing using css3 to realize the animation effect of a circle spreading from the center to the surroundings. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn