[Webkit-unassigned] [Bug 242798] New: Inline element with a block ::before following a floated element is cleared
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Fri Jul 15 07:50:39 PDT 2022
https://bugs.webkit.org/show_bug.cgi?id=242798
Bug ID: 242798
Summary: Inline element with a block ::before following a
floated element is cleared
Product: WebKit
Version: Safari Technology Preview
Hardware: Unspecified
OS: Unspecified
Status: NEW
Severity: Normal
Priority: P2
Component: Layout and Rendering
Assignee: webkit-unassigned at lists.webkit.org
Reporter: erik.brocko at letemsvetemapplem.eu
CC: bfulgham at webkit.org, simon.fraser at apple.com,
zalan at apple.com
Created attachment 460925
--> https://bugs.webkit.org/attachment.cgi?id=460925&action=review
Floated block followed by an inline element.
Elements with `float: right` followed by an inline container (set to `clear: both`) with ::before pseudo-element set to `display: block` inside it make the inline element truly cleared.
If `clear: both` is omitted, all works fine. If there is no `::before` block pseudoelement, it works fine. (Works fine = consistently with other browsers and previously observed behavior.)
Chrome, Firefox and Safari Technology Preview 142 render it the same way, with content immediately after the floated element wrapping around it. Safari Technology Preview 147+ and Safari 16.0 force the element to be cleared.
See my attached example.
I think this is because the ::before block pseudo-element gets put outside its parent inline element. I'm not sure if this is necessarily a bug. I couldn't test other versions of Safari, as they're impossible to download...
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20220715/1d625d16/attachment-0001.htm>
More information about the webkit-unassigned
mailing list