我记得,在工作中直接使用animation,只要能做出动画就完了,根本没有看每一个细节。
其实,这样做对于我们来说,的确没有错,因为工作中没有时间给你看每一个细节,大致看一篇就没下文了。
当我们想要好好理清头绪时,我才会想起以前见过的每一个知识点,然而这样做也没有错,但是这样做很明显不是明智的选择。
我觉得做一件事,都有一个计划,只有计划好,不懂得标记好,后面慢慢的一个个地解决,才会不落下学习的要点,好了,不说了,要睡了
animation-name表示为 @keyframes 动画规定名称;
语法:animation-name :keyframename|none;
animation-duration表示动画完成一个周期所需要的时间;
语法:animation-duration: time;
animation-timing-function 表示规定动画的速度(speed);
语法:animation-timing-function: value;
value有哪些:linear、ease、ease-in、ease-out、ease-in-out、cubic-bezier(n,n,n,n);
animation-fill-mode表示填充模式;
语法:animation-fill-mode : none | forwards | backwards | both;
animation-delay 表示动画即将开始。
语法:animation-delay: time;
animation-iteration-count表示播放动画次数;
语法:animation-iteration-count:n|infinite(无限循环);
animation-direction表示重复一次动画,也可以来回的运动并重复。
语法:animation-direction: normal|alternate;
animation: name duration timing-function delay iteration-count direction;
<!-- 参考学习http://www.w3school.com.cn/cssref/pr_animation.asp -->

<html>
<head>
<style>
body{
background-color:rgba(31,11,71,.8)
}
.circle{
position:absolute;
left:46%;
top:30%;
width:20px;
height:20px;
border-radius:15px;
background-color:rgba(21,21,29,.7);
-webkit-animation:myname 2s linear infinite;
animation:myname 7s linear infinite;
}
@keyframes myname {
0% {
left:46%;
top:30%;
} 25% {
left:56%;
top:20%;
} 50% {
left:66%;
top:40%;
} 75% {
left:56%;
top:60%;
} 100% {
left:46%;
top:30%;
}
}
@-webkit-keyframes myname {
0% {
left:46%;
top:30%;
} 25% {
left:56%;
top:20%;
} 50% {
left:66%;
top:40%;
} 75% {
left:56%;
top:60%;
} 100% {
left:46%;
top:30%;
}
}
h1{
animation-fill-mode:forwards;
-webkit-animation-fill-mode:forwards;
}
</style>
</head>
<body>
<div class="circle"></div>
</body>
</html>

CSS中animate属性的更多相关文章

  1. 深入理解css中position属性及z-index属性

    深入理解css中position属性及z-index属性 在网页设计中,position属性的使用是非常重要的.有时如果不能认识清楚这个属性,将会给我们带来很多意想不到的困难. position属性共 ...

  2. CSS中Position属性

    也许你看到这个标题觉得很简单,确实这是一篇关于CSS中Position属性基础知识的文章,但是关于Position的一些细节也许你不了解. 1.简介 position有五个属性: static | r ...

  3. CSS中 Zoom属性

    CSS中 Zoom属性 其实Zoom属性是IE浏览器的专有属性,Firefox等浏览器不支撑.它可以设置或检索对象的缩放比例.除此之外,它还有其他一些小感化,比如触发ie的hasLayout属性,清除 ...

  4. DIV css中cursor属性详解-鼠标移到图片变换鼠标形状 (转)

    css中cursor属性详解-鼠标移到图片变换鼠标形状   语法: cursor : auto | all-scroll | col-resize| crosshair | default | han ...

  5. CSS中Position属性static、absolute、fixed、relative

    在html中网页可以看成一个立体的空间,一个完整的页面是由很多个页面堆积形成的,如下图所示   CSS中Position属性有四个可选值,它们分别是:static.absolute.fixed.rel ...

  6. 深入理解css中position属性及z-index属性 https://www.cnblogs.com/zhuzhenwei918/p/6112034.html

    深入理解css中position属性及z-index属性 请看出处:https://www.cnblogs.com/zhuzhenwei918/p/6112034.html 在网页设计中,positi ...

  7. CSS中box-sizing属性的理解与部分用法

    今天看了一些关于box-sizing的一些资料,在这里整理一下,希望也能对大家有所帮助. box-sizing是CSS的一个属性,很好的解决了盒模型的相关问题.CSS中的盒模型(Box model)分 ...

  8. css中clip-path属性的运用

    今天看到一位同学的需求,要在一个div中加一个小尖尖,对话时发的图片,旁边这个三角是怎么实现与图片的颜色一致,效果如下: 当然,解决这个问题有各种奇淫巧技,现在我们来看一个css属性clip-path ...

  9. 区分html与css中的属性

    CSS中id与Class的区别 1.在CSS文件里书写时,ID加前缀"#":CLASS用"." 2.id一个页面只可以使用一次:class可以多次引用. 3.I ...

随机推荐

  1. opencv显示鼠标所在位置的rgb值

    #include"highgui.h" #include"cv.h" #include"cxcore.h" #include<stdl ...

  2. Linux屏幕录制gif的工具及教程

    准备 要两个工具配合使用.它们可以用命令行安装,也可以用软件管理器安装. 1,byzanz     安装后有两个命令 byzanz-record   录制,既能录制 Gif 动画,又可录制 Ogv 视 ...

  3. [CFGym101061G] Repeat it(逆元)

    题目链接:http://codeforces.com/gym/101061/problem/G 题意:给一个数字n,让你重复m次,求最后这个数对1e9+7取模的结果. 思路:设数字n长度为k,重复m次 ...

  4. [CCF2015.12]题解

    201512-1 数位之和 水题一个,取模除以10胡搞即可(不知道字符串为什么不行 #include <algorithm> #include <iostream> #incl ...

  5. leetcode Database2 (四)

    一.Duplicate Emails Write a SQL query to find all duplicate emails in a table named Person. +----+--- ...

  6. hadoop1常见配置含义

    参数                            取值                                         备注 fs.default.name NameNode ...

  7. Asp.Net验证码3

    using System; using System.Collections.Generic; using System.Web; using System.Web.UI; using System. ...

  8. libserialport: cross-platform library for accessing serial ports

    /*********************************************************************************** * libserialport ...

  9. (二)深入梯度下降(Gradient Descent)算法

    一直以来都以为自己对一些算法已经理解了,直到最近才发现,梯度下降都理解的不好. 1 问题的引出 对于上篇中讲到的线性回归,先化一个为一个特征θ1,θ0为偏置项,最后列出的误差函数如下图所示: 手动求解 ...

  10. dubbo-admin在jdk 1.8上部署出错问题

    今天在linux上部署dubbo-admin-2.5.4,一直报错: ERROR context.ContextLoader - Context initialization failedorg.sp ...