我已经为 chrome 和 mozilla 编写了媒体查询 css。它在 chrome 中工作正常。但在 mozilla 中不起作用
@media screen and (min-height:650px)
{
#customerspeak .flexslider .slides .customerBackground img {
height: 100vh;
}
#customerspeak .flex-direction-nav a {
margin-top: 37%;
}
#customerspeak .flex-next {
left: 62.5% !important;
}
#customerspeak .flex-prev {
left: 34% !important;
}
@-moz-document url-prefix() {
#customerspeak .flexslider .slides .customerBackground img {
height: 100vh;
}
#customerspeak .flex-direction-nav a {
margin-top: 37%;
}
#customerspeak .flex-next {
left: 62.5% !important;
}
#customerspeak .flex-prev {
left: 34% !important;
}
}
}
最佳答案
在 @media
查询之前先尝试使用 @-moz-document url-prefix()
。
@-moz-document url-prefix() {
@media screen and (min-height:650px) {
/* insert code here*/
}
}
关于html - 媒体查询在 mozilla 中不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42218255/