We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ios 渐变色 会出现黑色 如下代码:
background-image: linear-gradient(180deg, rgba(0, 0, 0, 0), 1%, #f6f6f6);
background-image: linear-gradient(180deg, rgba(246, 246, 246, 0), 1%, #f6f6f6);
Safari在渐变中对颜色的处理是同时渐变rgba()中的每一个参数,因此该例子中实际上是在渐变从黑色到颜色,从全透明到不透明。因此,中间出现了灰色。
将rgba()中的前三个参数,设置成背景色的颜色值即可。
The text was updated successfully, but these errors were encountered:
No branches or pull requests
问题出现
ios 渐变色 会出现黑色
如下代码:
解决
产生原因
Safari在渐变中对颜色的处理是同时渐变rgba()中的每一个参数,因此该例子中实际上是在渐变从黑色到颜色,从全透明到不透明。因此,中间出现了灰色。
解决方法
将rgba()中的前三个参数,设置成背景色的颜色值即可。
The text was updated successfully, but these errors were encountered: