Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(platform): detect and ignore scrollBehavior polyfills
We use the `supportsScrollBehavior` function to check whether to try and pass in the scroll options object to `Scrollable.scrollTo` since passing it in on a browser that doesn't support it won't do anything. The problem is that the only way to detect if scroll behavior is supported is to look for the `scrollBehavior` property on a DOM element's CSS styles, however this will cause scroll behavior polyfills to be ignored since they only modify `Element.prototype.scrollTo`. These changes try to detect whether `scrollTo` has been polyfilled, and if it has, we consider it as being supported. Fixes #17847.
- Loading branch information