WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
NEW
265065
Window scrolls back to URL hash when adding <style> element to page with Safari extension <link> stylesheet
https://bugs.webkit.org/show_bug.cgi?id=265065
Summary
Window scrolls back to URL hash when adding <style> element to page with Safa...
Jeff Johnson
Reported
2023-11-17 13:33:47 PST
Created
attachment 468658
[details]
Sample Xcode project Steps to reproduce: 1. Unzip attached sample Safari extension project HashBug 2. Open HashBug in Xcode 15 3. Build and run 4. Open Safari Developer Settings 5. Allow unsigned extensions 6. Open Safari Extensions Settings 7. Enable HashBug Extension 8. Always Allow on Every Website 9. Open
https://www.webkit.org/#posts
10. Scroll down the page to the bottom 11. Open the Safari web inspector 12. In the web inspector console, add an Inspector Style Sheet, or enter the following in the console: document.head.append(document.createElement("style")); Expected results: The page does not scroll. Actual results: The page scrolls back to #posts from the URL hash.
Attachments
Sample Xcode project
(325.18 KB, application/zip)
2023-11-17 13:33 PST
,
Jeff Johnson
no flags
Details
View All
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2023-11-24 13:34:15 PST
<
rdar://problem/118777589
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug