在 CSS 中,渐变(Gradient)可谓是最为强大的一个属性之一。 但是,经常有同学在使用渐变的过程中会遇到渐变图形产生的锯齿问题。 何为渐变锯齿? 那么,什么是渐变图形产生的锯齿呢? 简单的一个
顺晟科技
2021-09-15 13:15:23
99
.linear {
width: 630px;
height: 120px;
line-height: 150px;
text-align: center;
font-size: 26px;
position: absolute;
bottom: 0;
color: #fff;
background: -webkit-linear-gradient( top, rgba(0, 0, 0, 0),rgba(0, 0, 0, 0.2) ); /* Safari 5.1 - 6 */
background: -o-linear-gradient(bottom,rgba(0, 0, 0, 0),rgba(0, 0, 0, 0.2)); /* Opera 11.1 - 12*/
background: -moz-linear-gradient( bottom, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.2)); /* Firefox 3.6 - 15*/
background: linear-gradient(to bottom,rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.2)); /* 标准的语法 */
}
09
2022-11
31
2022-10
20
2022-09
14
2022-09
14
2022-09
14
2022-09