首页 > Web开发 > 详细

[ css 动画 animation ] animation新增动画属性的实例演示

时间:2016-06-27 13:45:40      阅读:201      评论:0      收藏:0      [点我收藏+]
<!DOCTYPE html>
<html lang=‘zh-cn‘>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>[ animation ] 新增动画属性的实例演示</title>
<meta http-equiv=‘description‘ content=‘this is my page‘>
<meta http-equiv=‘keywords‘ content=‘keyword1,keyword2,keyword3‘>

<style type=‘text/css‘>
div {
  margin: 0; padding: 0;
}
#box {
  width: 100px; height: 100px; background:red;animation:move 3s 3 alternate forwards;position:absolute;left:0;top:0; 
}
@keyframes move{
  0%{
    left:0;
    top:0;
  }
  10%{
    left:300px;
    top:450px;
  }
  50%{
    left:0px;
    top:500px;
  }
  75%{
    left:900px;
     top:50px;
  }
  100%{
     left:70px;
     top:230px;
  }
}

</style>
</head>
<body>
  <div id=‘box‘></div>
</body>
</html>

 

[ css 动画 animation ] animation新增动画属性的实例演示

原文:http://www.cnblogs.com/mysearchblog/p/5619805.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!