【发布时间】:2019-01-13 17:18:49
【问题描述】:
在我的网站上,我正在构建一个自定义 HSV Color picker。 我决定不使用渐变,而是选择将在 HSV 滑块中使用的 .SVG 渐变图像。
我在将该图像适配到我的 DIV 的背景中时遇到问题。
Here's an example。 该图像在 Mozilla Firefox 和 Internet Explorer 中都非常适合,但在 Edge 中,它看起来好像只有“高度”是“100%”,而“宽度”是“自动”——至少不是这样不在 CSS 中:
#pvdivsliderhue {
position: absolute;
top: 10px;
left: 10px;
right: 10px;
width: auto;
height: 30px;
border-radius: 15px;
background-image: url('images/pvhue.svg');
background-size: 100% 100%;
background-color: green;
display: flex;
}
我该如何解决这个问题?
感谢所有帮助!
【问题讨论】:
标签: javascript html css