用border作三角型
border4个边的颜色,一个有颜色,其它三个透明。
border-color: transparent #f66 transparent transparent;
border-style: solid;
border-width: 4px;
本文介绍了一种使用CSS border属性创建三角形的方法。通过设置四个边的颜色,其中一边为指定颜色而其余三边设为透明,可以轻松实现。具体样式设置包括:border-color, border-style 和 border-width。
用border作三角型
border4个边的颜色,一个有颜色,其它三个透明。
border-color: transparent #f66 transparent transparent;
border-style: solid;
border-width: 4px;
254
3540

被折叠的 条评论
为什么被折叠?