WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
NEW
284634
SVG elements with display: contents is visually hidden
https://bugs.webkit.org/show_bug.cgi?id=284634
Summary
SVG elements with display: contents is visually hidden
Gaël Poupard
Reported
2024-12-13 08:54:18 PST
1. With Epiphany on Ubuntu (also tested with Safari TP 209) 2. Open reduced test case on CodePen :
https://codepen.io/ffoodd/pen/WbeowEj?editors=1000
Three SVG <circle> are in the markup: 1. one without any style, 2. one with `style="display: contents` on <circle>, 3. and another with a `<g style="display: contents">` containing the `<circle>`. Expected: circle are shown. Actual: circles with `display: contents` are visually hidden. FWIW, both Chromium and Firefox renders the third circle (`display: contents` on `<g>`) but not the second circle. I ran onto this behaviour while trying to stop SMIL animations in CSS when `prefers-reduced-motion: reduce` is true, but it seems that this behavior is not related to animations at all.
Attachments
rendering in safari, firefox, chrome
(1.55 MB, image/png)
2024-12-17 21:52 PST
,
Karl Dubost
no flags
Details
Reference Screenshot (Local build with fix)
(268.29 KB, image/png)
2024-12-20 17:57 PST
,
Ahmad Saleem
no flags
Details
View All
Add attachment
proposed patch, testcase, etc.
Karl Dubost
Comment 1
2024-12-17 21:52:57 PST
Created
attachment 473591
[details]
rendering in safari, firefox, chrome Tested with Safari Technology Preview 208 20621.1.6 Firefox Nightly 135.0a1 13524.12.16 Google Chrome Canary 133.0.6902.0 6902.0
Radar WebKit Bug Importer
Comment 2
2024-12-20 08:55:13 PST
<
rdar://problem/141825746
>
Ahmad Saleem
Comment 3
2024-12-20 15:47:34 PST
FIXME here -
https://searchfox.org/wubkat/rev/146fa28a329d220785d2972c1d691555141e6406/Source/WebCore/style/StyleAdjuster.cpp#779
Ahmad Saleem
Comment 4
2024-12-20 17:55:12 PST
Pull request:
https://github.com/WebKit/WebKit/pull/38300
Ahmad Saleem
Comment 5
2024-12-20 17:57:25 PST
Created
attachment 473620
[details]
Reference Screenshot (Local build with fix)
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