課程
/前端開發(fā)
/CSS3
/CSS3 3D 特效
我想模仿學(xué)習(xí)
2017-05-10
源自:CSS3 3D 特效 1-1
正在回答
<!DOCTYPE?html> <html> <head> ????<meta?charset="UTF-8"> ????<title>css3六方塊繞Y軸旋轉(zhuǎn)</title> ????<style> ????????html,body{ ????????????perspective:?1000px; ????????} ????????.container{ ????????????width:?500px; ????????????height:?500px; ????????????transform-style:?preserve-3d; ????????????margin:100px?auto; ????????????position:?relative; ????????????animation:?move?10s?linear?infinite; ????????} ????????@keyframes?move?{ ????????????from{?transform:?rotateY(0deg)?} ????????????to{transform:?rotateY(360deg)} ????????} ????????.container:hover{ ????????????animation-play-state:?paused; ????????} ????????.square{ ????????????position:?absolute; ????????????width:?200px; ????????????height:?200px; ????????????left:?150px; ????????????top:150px; ????????????background-color:?#f05e6f; ????????????opacity:?0.3; ????????????font-size:?40px; ????????????color:?#FFFFFF; ????????????font-family:?"微軟雅黑",?Arial,?Helvetica,?sans-serif; ????????????line-height:?200px; ????????????text-align:?center; ????????} ????????#squ-1{??transform:?rotateY(0deg)?translateZ(250px);??} ????????#squ-2{??transform:?rotateY(60deg)?translateZ(250px);??} ????????#squ-3{??transform:?rotateY(120deg)?translateZ(250px);??} ????????#squ-4{??transform:?rotateY(180deg)?translateZ(250px);??} ????????#squ-5{??transform:?rotateY(240deg)?translateZ(250px);??} ????????#squ-6{??transform:?rotateY(300deg)?translateZ(250px);??} ????</style> </head> <body> <div> ????<div?id="squ-1">one</div> ????<div?id="squ-2">two</div> ????<div?id="squ-3">three</div> ????<div?id="squ-4">four</div> ????<div?id="squ-5">five</div> ????<div?id="squ-6">six</div> </div> </body> </html>
歡迎采納
舉報(bào)
使用CSS3當(dāng)中的屬性,創(chuàng)建真實(shí)可用的三維效果
2 回答為什么我的代碼沒任何效果,能翻頁但沒有3D效果
1 回答沒有3D效果!
2 回答css 3d效果ie也能實(shí)現(xiàn)嗎
1 回答CSS3 3D效果
2 回答3d翻頁效果js代碼相關(guān)問題
Copyright ? 2025 imooc.com All Rights Reserved | 京ICP備12003892號(hào)-11 京公網(wǎng)安備11010802030151號(hào)
購課補(bǔ)貼聯(lián)系客服咨詢優(yōu)惠詳情
慕課網(wǎng)APP您的移動(dòng)學(xué)習(xí)伙伴
掃描二維碼關(guān)注慕課網(wǎng)微信公眾號(hào)
2017-05-10
歡迎采納