You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+10
Original file line number
Diff line number
Diff line change
@@ -250,6 +250,16 @@ scrollIntoView(target, {
250
250
})
251
251
```
252
252
253
+
#### skipOverflowHiddenElements
254
+
255
+
Type: `Boolean`<br> Default: `false`
256
+
257
+
> Introduced in `v2.2.0`
258
+
259
+
By default the [spec](https://drafts.csswg.org/cssom-view/#scrolling-box) states that `overflow: hidden` elements should be scrollable because it has [been used to allow programatic scrolling](https://drafts.csswg.org/css-overflow-3/#valdef-overflow-hidden). This behavior can sometimes lead to [scrolling issues](https://github.com/stipsan/scroll-into-view-if-needed/pull/225#issue-186419520) when you have a node that is a child of an `overflow: hidden` node.
260
+
261
+
This package follows the convention [adopted by Firefox](https://hg.mozilla.org/integration/fx-team/rev/c48c3ec05012#l7.18) of setting a boolean option to _not_ scroll all nodes with `overflow: hidden` set.
262
+
253
263
# TypeScript support
254
264
255
265
When the library itself is built on TypeScript there's no excuse for not publishing great library definitions!
0 commit comments