transform动画 3D旋转立体正方形
在一个大的div里放置六个小div,分别向前后,向左右,向上下移动相等位置,再将平面div旋转,添加animation动画
<!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>
.wrap {
width: 100px;
height: 100px;
margin: 100px auto;
transform-style: preserve-3d;
position: relative;
animation: run 5s linear infinite;
}
.wrap div {
width: 100px;
height: 100px;