问题描述
打开:hover
时,我试图使按钮背景变亮/变暗。
我尝试了类似的样式
background-color:rgba(0,0.5);
background-blend-mode:darken;
但是它不像我想要的那样工作。 我想要真的真的很亮,而想要变暗。
background: linear-gradient(173deg,rgba(255,121,218,1) 0%,rgba(214,108,219,1) 39%,rgba(171,94,220,1) 85%,rgba(155,89,1) 100%);
感谢您的帮助社区
解决方法
您可以添加不透明的线性渐变白色。
background: linear-gradient(rgba(255,255,0.1),rgba(255,0.1)),*your color of the btn*;
你可以像这样在线性渐变中使用 lighten:
background: linear-gradient(
356deg,lighten(*your color*,5%) 0%,5%) 33%,5%) 100%
);
例如:https://firebase.google.com/docs/functions/http-events#read_values_from_the_request