霸剑道txt全集下载,常青林,中金黄金吧
3d坐标概念
旋转立方体的效果
分析
代码
<!doctype html> <html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta http-equiv="x-ua-compatible" content="ie=edge"> <title>document</title> <style> *{ margin: 0px; padding: 0px; } body{ perspective: 800px; background: #000000; } #container{ height: 200px; width: 200px; margin: 100px auto 0; position: relative; transform-style: preserve-3d; animation: move 1s ease infinite; } @keyframes move{ from{ transform: rotatey(0deg) rotatez(0deg); } to{ transform: rotatey(360deg) rotatez(360deg); } } #container>div{ height: 100%; width: 100%; border-radius: 5px; background: rgba(255,255,255,0.5); position: absolute; left: 0px; right: 0px; text-align: center; line-height: 200px; font-size: 30px; } #one{ transform:rotatex(-90deg) translatez(100px); } #two{ transform:translatez(100px) ; } #three{ transform: rotatey(-90deg) translatez(100px); } #four{ transform: rotatey(-180deg) translatez(100px); } #five{ transform: rotatey(90deg) translatez(100px); } #six{ transform: translatez(-100px); } </style> </head> <body> <div id="container"> <div id="one">1</div> <div id="two">2</div> <div id="three">3</div> <div id="four">4</div> <div id="five">5</div> <div id="six">6</div> </div> </body> </html>
以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持移动技术网。
如对本文有疑问,请在下面进行留言讨论,广大热心网友会与你互动!! 点击进行留言回复
css3 flex布局 justify-content:space-between 最后一行左对齐
网友评论