请老师检查代码是否正确
来源:2-21 自由编程
慕先生9380059
2021-06-07 13:22:05
相关代码:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
<style>
* {
padding: 0;
margin: 0;
}
.box1 {
width: 88px;
height: 81px;
background-image: url(imgs/xin.png);
margin: 40px auto;
}
.box2 {
width: 88px;
height: 81px;
background-image: url(imgs/xin.png);
margin: 40px auto;
animation: xindong .5s linear 0s infinite;
}
@keyframes xindong {
from {
opacity: 1;
transform: scale(1);
}
to {
opacity: 0;
transform: scale(2);
}
}
</style>
</head>
<body>
<div class="box1">
<div class="box2"></div>
</div>
</body>
</html>
1回答
好帮手慕星星
2021-06-07
同学你好,代码实现动画效果很棒。继续加油,祝学习愉快!
相似问题