Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 2c1af1cba4b0334b7932780e7f2239adbac781ac
https://github.com/WebKit/WebKit/commit/2c1af1cba4b0334b7932780e7f2239adbac781ac
Author: Yulun Wu <[email protected]>
Date: 2026-04-30 (Thu, 30 Apr 2026)
Changed paths:
A
LayoutTests/fast/lists/list-marker-with-empty-inline-before-blockquote-expected.html
A
LayoutTests/fast/lists/list-marker-with-empty-inline-before-blockquote.html
M Source/WebCore/rendering/updating/RenderTreeBuilderList.cpp
Log Message:
-----------
[List Marker] Search past empty inline items when parenting list markers
https://bugs.webkit.org/show_bug.cgi?id=313568
<rdar://172762578>
Reviewed by Alan Baradlay.
This PR fixes a bug where a list item starting with an empty inline element
causes
findParentOfEmptyOrFirstLineBox to always use the blockContainer as the list
marker parent.
The PR updates findParentOfEmptyOrFirstLineBox to skip empty inlines with an
explicit continue
after setting the block container as the fallback parent. This way we continue
iterating over
the blockContainer's other children to try and find a valid parent instead of
falling through
with the assumption the child is not inline and falsely triggering
failedDueToBlockification.
Also skip collapsible whitespace-only RenderText children that are not valid
marker parents.
This change was added as the empty inline fix broke
imported/w3c/web-platform-tests/css/css-lists/add-inline-child-after-marker-002.html
which exposed the bug where we incorrectly parented the list marker to
collapsible whitespace.
*
LayoutTests/fast/lists/list-marker-with-empty-inline-before-blockquote-expected.html:
Added.
* LayoutTests/fast/lists/list-marker-with-empty-inline-before-blockquote.html:
Added.
* Source/WebCore/rendering/updating/RenderTreeBuilderList.cpp:
(WebCore::findParentOfEmptyOrFirstLineBox):
Canonical link: https://commits.webkit.org/312356@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications