Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 5eb6543587f658ba8b7f8cd110ef1089480c8ef2
https://github.com/WebKit/WebKit/commit/5eb6543587f658ba8b7f8cd110ef1089480c8ef2
Author: Phinehas Fuachie <[email protected]>
Date: 2026-04-15 (Wed, 15 Apr 2026)
Changed paths:
M Source/WebCore/page/IntersectionObserver.cpp
M Source/WebCore/page/LocalFrameView.cpp
M Source/WebCore/page/Page.h
M Source/WebCore/page/Quirks.cpp
M Source/WebCore/page/Quirks.h
M Source/WebCore/page/QuirksData.h
Log Message:
-----------
Spotify skips to next/previous song when Safari window is resized from
Desktop to mobile dimensions view or vice versa(or rotates ipad)n iPhone)
https://bugs.webkit.org/show_bug.cgi?id=312360
rdar://130996471
Reviewed by Jer Noble.
Spotify's mobile web player uses IntersectionObserver with scroll-snap
sentinels to implement
swipe-to-skip. When the iPad viewport resizes (Stage Manager, split-screen),
the scroll container
dimensions change, causing sentinel elements to become visible without any user
scroll gesture.
This triggers Spotify's skip-next/skip-previous dispatch, advancing the
playlist unexpectedly.
Fix: Record the resize timestamp on the Page when availableContentSizeChanged
fires, and suppress
isIntersecting=true IntersectionObserver entries and callbacks for 700ms after
the last resize for
spotify specifically.
Note: Spotify should guard their onChange handler to only skip on user scroll,
not resize.
* Source/WebCore/page/IntersectionObserver.cpp:
(WebCore::IntersectionObserver::updateObservations):
(WebCore::IntersectionObserver::notify):
* Source/WebCore/page/LocalFrameView.cpp:
(WebCore::LocalFrameView::availableContentSizeChanged):
* Source/WebCore/page/Page.h:
(WebCore::Page::recordResizeForIntersectionObserverQuirk):
(WebCore::Page::isWithinResizeDebounceWindow const):
* Source/WebCore/page/Quirks.cpp:
* Source/WebCore/page/Quirks.h:
* Source/WebCore/page/QuirksData.h:
Canonical link: https://commits.webkit.org/311309@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications