Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 2874cfdad914dc82b9e27db23b297ef08a839e60
      
https://github.com/WebKit/WebKit/commit/2874cfdad914dc82b9e27db23b297ef08a839e60
  Author: Simon Fraser <[email protected]>
  Date:   2026-04-20 (Mon, 20 Apr 2026)

  Changed paths:
    A 
LayoutTests/fast/scrolling/ios/scroll-to-smooth-during-rubberband-expected.txt
    A LayoutTests/fast/scrolling/ios/scroll-to-smooth-during-rubberband.html
    M Source/WebKit/UIProcess/API/ios/WKWebViewIOS.mm

  Log Message:
  -----------
  [iOS] nfl.com rubberbanding behaves incorrectly
https://bugs.webkit.org/show_bug.cgi?id=312813
rdar://170705188

Reviewed by Abrar Rahman Protyasha.

The changes in 254640@main added code that, if scrolling to 0,0, replaces the 
target zero position
with the current scroll offset, in an attempt to fix an issue in Mail on iPad. 
This code behaved
poorly when the user scrolls to the top with a rubberband, and the site does a
`window.scrollTo({ top: 0, behavior: 'smooth' })`, (which nfl.com does), which 
interrupts
any running scroll animation; it captured the currently negative Y offset as 
the static scroll position.

Fix by removing the changes in `_scrollToContentScrollPosition:...`. I could 
not reproduce the original
bug with these changes removed; it's possible that other OS changes fixed the 
`CGRectNull` issues that
254640@main was working around.

Test: fast/scrolling/ios/scroll-to-smooth-during-rubberband.html

* 
LayoutTests/fast/scrolling/ios/scroll-to-smooth-during-rubberband-expected.txt: 
Added.
* LayoutTests/fast/scrolling/ios/scroll-to-smooth-during-rubberband.html: Added.
* Source/WebKit/UIProcess/API/ios/WKWebViewIOS.mm:
(-[WKWebView 
_scrollToContentScrollPosition:scrollOrigin:animated:interruptAnimation:]):

Canonical link: https://commits.webkit.org/311641@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to