overscroll-behavior-y

翻译不完整。 请帮助我们翻译这篇文章!

overscroll-behavior-y 这个CSS属性用来控制当滚动到区域的垂直边界时的浏览器行为。

Note: 详细的解释请访问 overscroll-behavior

/* Keyword values */
overscroll-behavior: auto; /* default */
overscroll-behavior: contain;
overscroll-behavior: none;

/* Global values */
overflow: inherit;
overflow: initial;
overflow: unset;
初始值auto
适用元素non-replaced block-level elements and non-replaced inline-block elements
是否是继承属性
适用媒体visual
计算值as specified
Animation typediscrete
正规顺序the unique non-ambiguous order defined by the formal grammar

语法

overscroll-behavior-y 属性可以选用下列值。

auto
默认的滚动溢出行为表现的和正常一样。 .
contain
默认的滚动溢出行为将被内部的元素观察到,(例如: “bounce”效果或者刷新),但是相邻的区域不会产生连续滚动效果,例如: 在下面的元素不会被滚动。
none
相邻的滚动区域不会有连续滚动效果,并且默认的滚动溢出行为会被阻止。

正式语法

contain | none | auto

示例

.messages {
  height: 220px;
  overflow: auto;
  overscroll-behavior-y: contain;
} 

详细的解释请访问 overscroll-behavior

规格

规格 状态值 备注
Unknown
overscroll-behavior-y
Unknown

浏览器兼容性

Update compatibility data on GitHub
DesktopMobile
ChromeEdgeFirefoxInternet ExplorerOperaSafariAndroid webviewChrome for AndroidFirefox for AndroidOpera for AndroidSafari on iOSSamsung Internet
overscroll-behavior-yChrome Full support 63Edge Partial support 18
Notes
Partial support 18
Notes
Notes Currently the none value incorrectly behaves as contain (allowing for the elastic bounce effect).
Firefox Full support 59IE No support NoOpera Full support 50Safari No support NoWebView Android Full support 63Chrome Android Full support 63Firefox Android Full support 59Opera Android Full support 46Safari iOS No support NoSamsung Internet Android Full support 8.0

Legend

Full support  
Full support
Partial support  
Partial support
No support  
No support
See implementation notes.
See implementation notes.

参见