WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
NEW
304551
CSS anchor positioning with a fixed-positioned anchored element works incorrectly in the top layer
https://bugs.webkit.org/show_bug.cgi?id=304551
Summary
CSS anchor positioning with a fixed-positioned anchored element works incorre...
Pavel Pomerantsev
Reported
2025-12-20 11:26:42 PST
Created
attachment 477806
[details]
Chrome (correct) and Safari (incorrect) layouts side by side An element is positioned incorrectly if all of the following are true: * It's anchor-positioned (has a `position-anchor` set to an existing element). * It has `position: fixed`. * Both the element and its anchor are in the top layer. See example with a modal dialog and a fullscreen element (both examples of top layer usage):
https://codepen.io/pavelp/pen/ByzBKrE
Compare layout in latest Chrome (appears to be correct) vs latest Safari TP (appears incorrect). Note: this may or may not be a duplicate of
https://bugs.webkit.org/show_bug.cgi?id=289743
. Top layer is mentioned there, but it looks like currently all the top-layer tests in
https://wpt.fyi/results/css/css-anchor-position?label=experimental&label=master&aligned
are passing in Safari TP, so this might be a case for which a web platform test doesn't exist yet.
Attachments
Chrome (correct) and Safari (incorrect) layouts side by side
(410.18 KB, image/png)
2025-12-20 11:26 PST
,
Pavel Pomerantsev
no flags
Details
View All
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2025-12-27 11:27:12 PST
<
rdar://problem/167239379
>
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