首页 > Web开发 > 详细

css浮动的白云

时间:2017-04-25 12:54:32      阅读:187      评论:0      收藏:0      [点我收藏+]

<!DOCTYPE html>
<html>
<head lang="en">
<meta charset="UTF-8">
<title></title>
<style>
.box{
position: relative;
height: 300px;
width: 500px;
}
.s1,.s2{
position: absolute;
height: 100%;
width: 100%;
background-size:cover;
animation: move 100s infinite linear alternate;
}
@keyframes move{
100%{background-position: 500% 0;}
}
.s1{
background-image: url(‘http://sandbox.runjs.cn/uploads/rs/26/ddzmgynp/cloud.png‘);
}
.s2{
background-image: url(‘http://sandbox.runjs.cn/uploads/rs/26/ddzmgynp/cloud1.png‘);
animation-duration: 10s;
}
</style>
</head>
<body>
<div class="box">
<div class="s1"></div>
<div class="s2"></div>
</div>
</body>
</html>

css浮动的白云

原文:http://www.cnblogs.com/w-gg/p/6761154.html

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