Bug 236730

Summary: Remove non-standard display:block UA stylesheet rule for <layer>
Product: WebKit Reporter: Simon Pieters (:zcorpan) <zcorpan>
Component: CSSAssignee: zalan <zalan>
Status: RESOLVED FIXED    
Severity: Normal CC: esprehn+autocc, ews-watchlist, glenn, gyuyoung.kim, hi, koivisto, macpherson, menard, pangle, webkit-bug-importer, zalan
Priority: P2 Keywords: InRadar
Version: Safari Technology Preview   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch none

Description Simon Pieters (:zcorpan) 2022-02-16 12:46:35 PST
What steps will reproduce the problem?
(1) Open data:text/html,a<layer>b
(2)
(3)

What is the expected result?
"ab" should be on one line (because <layer> should be display:inline)

What happens instead?
"a" and "b" are on separate lines (because the UA stylesheet has layer { display:block })

https://github.com/WebKit/WebKit/blob/main/Source/WebCore/css/html.css#L53-L55

This is in violation with the HTML standard which doesn't say <layer> should have any UA style: https://html.spec.whatwg.org/multipage/rendering.html#rendering

Chromium also has this bug (https://bugs.chromium.org/p/chromium/issues/detail?id=1298197 ), but not Gecko.
Comment 1 Radar WebKit Bug Importer 2022-02-23 12:47:15 PST
<rdar://problem/89372670>
Comment 2 zalan 2022-03-05 06:14:04 PST
Created attachment 453909 [details]
Patch
Comment 3 zalan 2022-03-05 08:34:32 PST
Created attachment 453911 [details]
Patch
Comment 4 EWS 2022-03-05 13:25:22 PST
Committed r290870 (248101@main): <https://commits.webkit.org/248101@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 453911 [details].