如何在 Android 浏览器中div
创建蒙版?border-radius
HTML
<div class="box">
<div class="item"></div>
<div class="item" style="width:300px;"></div>
</div>
CSS
.box {
position:relative;
width:240px;
height:120px;
-webkit-border-radius: 10px;
border-radius: 10px;
background:#123456;
overflow:hidden;
}
.item {
position:relative;
width:200px;
height:50px;
background:#654321;
margin: 0 0 20px 0;
}
在 iOS 中它可以正常工作。