2-14 编程练习
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 | <!Doctype html> < html > < head > < meta charset = "UTF-8" > < title >空间移动</ title > < style > * { margin: 0; padding: 0; } .box { width: 200px; height: 200px; margin: 200px auto; perspective: 300px; position: relative; } .box p { position: absolute; left: 0; top: 0; width: 200px; height: 200px; } p:first-child{ background-color:purple; transform:rotateX(70deg); } p:nth-child(2){ background-color:lightgreen; transform:rotateX(70deg) translateZ(60px); } p:last-child{ background-color:pink; transform:rotateX(70deg) translateZ(120px); } </ style > </ head > < body > < div class = "box" > < p ></ p > < p ></ p > < p ></ p > </ div > </ body > </ html > |
老师,为什么不对?
7
收起
恭喜解决一个难题,获得1积分~
来为老师/同学的回答评分吧