"-webkit-overflow-scrolling: touch;" 无效属性值错误。

9

我不明白为什么这个不起作用。我将其放入了我的html和body中,但它仍然显示无效的属性值并被划掉。我最初尝试在媒体查询中使用它,但那里也不起作用。有人知道它不起作用的潜在原因吗?谢谢!

html, body {
    width:100%;
    height:100%;
    background-color:#FCF5F4;
    font-family:webfont;
    -webkit-overflow-scrolling: touch;

This is the error I get.


1
因为它在Firefox/IE/Edge/任何你用来查看的浏览器中都不受支持? - raina77ow
1个回答

2

它并不被任何浏览器支持。请查看此链接底部。


在 Chrome 浏览器上 - CarlosIsLazy
也许你的浏览器已经更新了?无论如何,你不应该使用它。 - Marco
2
我应该使用什么替代? - CarlosIsLazy
1
抱歉回复晚了。看起来它只适用于iOS,而且它所做的只是:“touch Use momentum-based scrolling, where the content continues to scroll for a while after finishing the scroll gesture and removing your finger from the touchscreen. The speed and duration of the continued scrolling is proportional to how vigorous the scroll gesture was. Also creates a new stacking context.”因此你最好不要使用它。 - Marco

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接