【发布时间】:2019-03-27 10:37:01
【问题描述】:
我正在尝试重新创建这个:
我正在使用 SVG 和 Polygon,有没有更简单的方法来修复边界半径?
<div class="showCaseVideo" style="background: none;">
<svg width="100%" height="100%" viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg" preserveAspectRatio="none" style="border-top-left-radius: 300px 70px; border-bottom-left-radius: 300px 70px; border-radius: 35px;">
<defs>
<linearGradient id="grad1" x1="0%" y1="0%" x2="100%" y2="0%">
<stop offset="0%" style="stop-color:#076FAD;stop-opacity:1"></stop>
<stop offset="100%" style="stop-color:#28AADD;stop-opacity:1"></stop>
</linearGradient>
</defs>
<polygon points="0,10 100,0 100,100 0,90" style="/*! display: none; *//*! color: white; *//*! stroke: white; */fill: url(#grad1);/*! display: M64.5 45.5 82.5 45.5 82.5 64.5 64.5 64.5 z; */" d="M64.5 45.5 82.5 45.5 82.5 64.5 64.5 64.5 z">
</polygon>
</svg>
</div>
【问题讨论】:
-
请提供适当的细节或jsfiddle
-
已编辑(我添加了 jsfiddle 来解释我所拥有的)