我有一個圓形影像。我想剪掉它的頂部,如圖所示。是否可以使用剪輯路徑來做到這一點?
謝謝。
.circle {
width: 75px;
height: 75px;
background-color: red;
border-radius: 50%;
}
<div class="circle">
</div>
uj5u.com熱心網友回復:
是的,您可以使用inset()
CSS 功能:
.circle {
width: 75px;
height: 75px;
background-color: red;
border-radius: 50%;
clip-path: inset(20px 0 0 0);
}
<div class="circle">
</div>
轉載請註明出處,本文鏈接:https://www.uj5u.com/yidong/508383.html
標籤:javascript html css
上一篇:畫布畫線不出現
下一篇:多詞搜索功能HTML串列過濾器