作者热门文章
- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我的 html 代码中有以下按钮
<input type="button" id="button" title="button" name="button" class="button" value="button" />
附上这个 CSS
.button{
width:200px;
height:;50px;
position:relative;
top:50px;
left:200px;
background:-webkit-linear-gradient(180deg,white 33%,blue 67%)
}
https://jsfiddle.net/mudkcuqj/
现在我的精神渴望消除由 gradient
引起的令人发指的褪色
最佳答案
如果您想要消除从蓝色到白色的淡入淡出,并让它变成蓝色直到一个点,然后变为白色,让颜色在同一点开始和结束。
.button{
width:200px;
height:50px;
position:relative;
top:50px;
left:200px;
background:linear-gradient(180deg,white 33%,blue 33%);
background:-webkit-linear-gradient(180deg,white 33%,blue 33%);
}
<input type="button" id="button" title="button" name="button" class="button" value="button" />
关于css - 如何从CSS中的渐变中去除淡入淡出,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41526420/
我是一名优秀的程序员,十分优秀!