Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: eec3a9a6a86a091749dfd01de6d167d4988c0b73
https://github.com/WebKit/WebKit/commit/eec3a9a6a86a091749dfd01de6d167d4988c0b73
Author: Alan Baradlay <[email protected]>
Date: 2026-10-11 (Sun, 11 Oct 2026)
Changed paths:
M LayoutTests/TestExpectations
M
Source/WebCore/layout/formattingContexts/inline/InlineFormattingContext.cpp
M Source/WebCore/rendering/LineClampUpdater.cpp
M Source/WebCore/rendering/LineClampUpdater.h
M Source/WebCore/rendering/RenderBlockFlow.cpp
Log Message:
-----------
[line-clamp] Abspos whose containing block is an inline after the clamp point
is visible
https://bugs.webkit.org/show_bug.cgi?id=327059
<rdar://problem/189671905>
Reviewed by Antti Koivisto.
<div style="line-clamp: 1">Line 1<br><span style="position: relative">Line
2<div style="position: absolute; width: 20px; height: 20px; background:
blue"></div></span></div>
The absolutely positioned box shows up at the top-left of the line-clamp
container.
"Within a line-clamp container, the following boxes and line boxes become
invisible boxes:
- Any in-flow or floating boxes that follow the clamp point in the box tree. ...
- Any absolutely positioned box which has an invisible box within its
containing block chain, and all of its descendants."
https://drafts.csswg.org/css-overflow-4/#line-clamp-containers
Inline layout only marked the floats it discarded with the content after the
clamp point as invisible boxes. Inline boxes
after the clamp point have no display boxes, but an out-of-flow box whose
containing block is such an inline box still paints.
Now inline layout marks discarded inline boxes as invisible boxes too, and the
invisible box marking follows the containing
block of out-of-flow boxes through inline boxes (container() rather than
containingBlock()).
* LayoutTests/TestExpectations:
* Source/WebCore/layout/formattingContexts/inline/InlineFormattingContext.cpp:
(WebCore::Layout::InlineFormattingContext::resetBoxGeometriesForDiscardedContent):
* Source/WebCore/rendering/LineClampUpdater.cpp:
(WebCore::isInsideInvisibleBox):
(WebCore::setIsForceHiddenByLineClamp):
(WebCore::LineClampUpdater::setIsForcedHidden):
* Source/WebCore/rendering/LineClampUpdater.h:
* Source/WebCore/rendering/RenderBlockFlow.cpp:
(WebCore::RenderBlockFlow::markInlineContentDirtyForLayout):
Canonical link: https://commits.webkit.org/323395@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications