'Potential CSS scroll snap bug in Chrome

Please check this CodePen. The problem is described there. There is also a demo. I've tested it on Mac and Windows.

There is the same behavior in Chrome (on Mac and Windows).

Meanwhile, other browsers (even Safari and Opera which are on WebKit too) do not jump to the nearest snap point instantly.

It is a bug?

If so, what is the correct place where I can report it? Or what is the correct place (WebKit related) where I can ask about it?


// Snippet of code required by Stack Overflow to post a question
slider.addEventListener("scroll", _.debounce((e) => {
    const currentHeight = parseFloat(e.target.style["height"]);
    e.target.style["height"] = currentHeight + (flag ? 5 : -5) + "px";
    flag = !flag;
}, 50));


Solution 1:[1]

"Chrome introduced auto-snap after layout changes in M81." (from Scroll snapping after layout changes)

Issue 1181843: Scroll-snap jumps to the nearest snap position on repaint in Chrome

This behavior is intentional in Chrome, unfortunately.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Peter Mortensen