必須明白radius能夠設置爲兩個值,寬半徑、高半徑
,若是隻設置爲一個值,則寬半徑 = 高半徑
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>菜鳥教程(runoob.com)</title>
<style> #parent{ position:absolute; top:100px; left:100px; right:0px; } #content{ display:inline-block; background-color:blue; border-radius:5px; padding:20px } #content::before { content:''; border-bottom: 15px solid blue; border-left: 0px solid blue; border-bottom-left-radius: 20px 20px; height:20px; width:20px; position:absolute; top:5px; left:-15px; } </style>
</head>
<body>
<div id="parent">
<div id="content">asd</div>
</div>
</body>
</html>
複製代碼