Bug 240235

Summary: overscroll-behavior: none doesn't prevent rubberbanding reliably in scroll-snap containers
Product: WebKit Reporter: Bruno Stasse <augus.dupin>
Component: ScrollingAssignee: Nobody <webkit-unassigned>
Status: NEW ---    
Severity: Normal CC: nmouchtaris, simon.fraser, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: Safari Technology Preview   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
testcase
none
testcase_video
none
testcase_video2 none

Description Bruno Stasse 2022-05-09 08:26:35 PDT
Created attachment 459044 [details]
testcase

Hello. Here is a bug related to `overscroll-behavior: none`, which is not working as intended in Safari TP.

`overscroll-behavior: none` should prevent all rubberbanding, and indeed does in a normal scroll container. In a scroll-snap container however, it doesn't prevent it reliably.

How to reproduce the issue in the test case:
- in the vertical scroll container, scroll all the way up or down relatively fast, and see rubberbanding
- in the horizontal scroll container, scroll all the way left or right relatively fast, and see rubberbanding

See the video for what to look for.

Note, as indicated in the test case, that you might encounter this other bug related to rubberbanding: https://bugs.webkit.org/show_bug.cgi?id=236536, as well as this one related to overscroll-behavior in horizontal scroll containers: https://bugs.webkit.org/show_bug.cgi?id=240183.

Please let me know if you need more information.
Comment 1 Bruno Stasse 2022-05-09 08:27:59 PDT
Created attachment 459045 [details]
testcase_video

Video of the testcase.
Comment 2 Radar WebKit Bug Importer 2022-05-09 11:54:16 PDT
<rdar://problem/92977409>
Comment 3 Bruno Stasse 2022-05-10 06:38:42 PDT
Created attachment 459116 [details]
testcase_video2

On top of the initial bug, an additional one makes it even worse: in horizontal scroll containers, if you scroll horizontally during rubberbanding (which should not occur), then history navigation is triggered, causing you to either go to the previous or to the next page.

This adds to the problem caused by this bug, and should not occur for two reasons:
1. rubberbanding should not occur (this bug);
2. history navigation should be prevented (but is not at all because of this bug: https://bugs.webkit.org/show_bug.cgi?id=240183).

See the second attached video where the problem is visible.