Bug 303544

Summary: overflow: clip doesn't work on inline elements
Product: WebKit Reporter: Emilio Cobos Álvarez (:emilio) <emilio>
Component: Layout and RenderingAssignee: Nobody <webkit-unassigned>
Status: RESOLVED INVALID    
Severity: Normal CC: bfulgham, simon.fraser, webkit-bug-importer, zalan
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   

Emilio Cobos Álvarez (:emilio)
Reported 2025-12-04 05:31:42 PST
Test-case: data:text/html,<span style="overflow: clip">ABC <span style="display: inline-block; height: 50px; width: 50px; background: green; vertical-align: bottom"></span></span> The green square should be clipped to the inline's box. Firefox is correct. Chrome has the same issue: https://issues.chromium.org/issues/465987920
Attachments
Radar WebKit Bug Importer
Comment 1 2025-12-11 05:32:12 PST
alan
Comment 2 2025-12-20 15:50:16 PST
I didn't know overflow clip applied to inline boxes. Do you mind linking to the spec where it says that?
Emilio Cobos Álvarez (:emilio)
Comment 3 2025-12-21 04:15:17 PST
Yeah I guess per spec it shouldn't since https://drafts.csswg.org/css-overflow-3/#propdef-overflow-y has: > block containers [CSS2], flex containers [CSS3-FLEXBOX], grid containers [CSS3-GRID-LAYOUT] However that predates overflow: clip. Anyhow, I filed https://github.com/w3c/csswg-drafts/issues/13257 to discuss it on the spec side.
alan
Comment 4 2025-12-21 06:21:17 PST
👍
Note You need to log in before you can comment on or make changes to this bug.