CSS3动画 3DBOX
内容导读
互联网集市收集整理的这篇技术教程文章主要介绍了CSS3动画 3DBOX,小编现在分享给大家,供广大互联网技能从业者学习和参考。文章包含3166字,纯文字阅读大概需要5分钟。
内容图文
<!DOCTYPE html>
2 <html>
3 <head>
4 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
5 <title>旋转盒子
</title>
6 <meta charset="utf-8" />
7 <style>
8 * {
9 margin: 0px;
10 padding: 0px;
11 }
12 @keyframes box {
13 100% {
14 transform: rotate3d(100,100,100,360deg);
15 }
16 }
17 #box {
18 position: absolute;
19 top: 30%;
20 left: 50%;
21 /*position:relative;*/
22 perspective: 2000px;
23 perspective-origin: 500px -300px;
24 animation: box 5s linear 7s infinite both;
25 transform-style: preserve-3d;
26 }
27 .item {
28 position: absolute;
29 border: 1px solid #000000;
30 opacity: 0.5;
31 width: 200px;
32 height: 200px;
33 font-size: 100px;
34 background-color: #7b8efb;
35 text-align: center;
36 line-height: 200px;
37 }
38 @keyframes box1 {
39 100% {
40 transform: rotateY(-90deg);
41 }
42 }
43 #box1 {
44 z-index: 6;
45 transform-origin: left;
46 animation: box1 1s linear 1s both;
47 }
48 @keyframes box2 {
49 100% {
50 transform: rotateY(90deg);
51 }
52 }
53 #box2 {
54 z-index: 5;
55 transform-origin: right;
56 animation: box2 1s linear 2s both;
57 }
58 @keyframes box3 {
59 100% {
60 transform: rotateX(90deg);
61 }
62 }
63 #box3 {
64 z-index: 4;
65 transform-origin: top;
66 animation: box3 1s linear 3s both;
67 }
68 @keyframes box4 {
69 100% {
70 transform: rotateX(-90deg);
71 }
72 }
73 #box4 {
74 z-index: 3;
75 transform-origin: bottom;
76 animation: box4 1s linear 4s both;
77 }
78 @keyframes box5 {
79 100% {
80 transform: translateZ(200px);
81 }
82 }
83 #box5 {
84 z-index: 2;
85 animation: box5 1s linear 5s both;
86 }
87 @keyframes box6 {
88 100% {
89 transform: rotateY(180deg);
90 }
91 }
92 #box6 {
93 animation: box6 1s linear 6s both;
94 }
95 </style>
96 </head>
97 <body>
98 <div id="box">
99 <div class="item" id="box1">1
</div>
100 <div class="item" id="box2">2
</div>
101 <div class="item" id="box3">3
</div>
102 <div class="item" id="box4">4
</div>
103 <div class="item" id="box5">5
</div>
104 <div class="item" id="box6">6
</div>
105 </div>
106 </body>
107 </html>
CSS3动画 3DBOX
标签:form net res ext com pre text abs logs
本文系统来源:http://www.cnblogs.com/cxd1008/p/6377673.html
内容总结
以上是互联网集市为您收集整理的CSS3动画 3DBOX全部内容,希望文章能够帮你解决CSS3动画 3DBOX所遇到的程序开发问题。
如果觉得互联网集市技术教程内容还不错,欢迎将互联网集市网站推荐给程序员好友。
内容备注
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 gblab@vip.qq.com 举报,一经查实,本站将立刻删除。
内容手机端
来源:【匿名】