规定 3D 缩放转换。
scale3d(x, y, z)
| 值 | 描述 |
|---|---|
| x | 规定X轴上的缩放比例。。 |
| y | 规定Y轴上的缩放比例。。 |
| z | 规定Z轴上的缩放比例。。 |
HTML
<div class="stage"> <div class="box">transform:scale3d(2,1,3)</div> </div>
CSS
.stage{
width:100%;
height:200px;
background:#333;
text-align:center;
}
.box{
display:inline-block;
width:350px;
height:50px;
background:red;
font-size:20px;
color:#fff;
transform:scale3d(2,1,3);//在中心位置处scale3d(2,1,3)倍。
}
执行结果