Bug 255646 - [css-scroll-snap] search for text on page with scroll snap on html fails
Summary: [css-scroll-snap] search for text on page with scroll snap on html fails
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: Scrolling (show other bugs)
Version: Safari 16
Hardware: iPhone / iPad iOS 16
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2023-04-18 23:38 PDT by Johannes Odland
Modified: 2023-09-19 09:04 PDT (History)
2 users (show)

See Also:


Attachments
Screen recording of the issue (2.40 MB, video/mp4)
2023-04-18 23:38 PDT, Johannes Odland
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Johannes Odland 2023-04-18 23:38:11 PDT
Created attachment 465978 [details]
Screen recording of the issue

Searching for a text on a page with scroll-snap on html fails. 
The user can find the text, but after the browser has scrolled the text into view it snaps back to the previous snap position.

Steps to reproduce:
1. Open a page with scroll-snap on root (https://johannesodland.github.io/browserbugs/safari-scroll-snap-scroll-to-top-issue.html)
2. Tap the url-bar and enter a text. 
3. Under "On this page" select "Find <text>"

Expected result: 
The page is scrolled to a snap position where the text is visible and snaps to this position

Actual result: 
The page is scrolled to a scroll position where the text is visible, but then snaps back to the previous snap position
Comment 1 Radar WebKit Bug Importer 2023-04-25 23:39:21 PDT
<rdar://problem/108543679>
Comment 2 Johannes Odland 2023-05-22 04:27:05 PDT
Retested on iOS 16.5
The issue is still present
Comment 3 Johannes Odland 2023-09-19 09:04:44 PDT
Retested on iOS 17.
The page still snaps back to the top after scrolling to show the searched text.