[wpt-sync] Sync PR 36344 - Make sure ::first-letter is always reached for re-attach
Categories
(Core :: Layout: Generated Content, Lists, and Counters, task, P4)
Tracking
()
Tracking | Status | |
---|---|---|
firefox108 | --- | fixed |
People
(Reporter: wpt-sync, Unassigned)
References
()
Details
(Whiteboard: [wptsync downstream])
Sync web-platform-tests PR 36344 into mozilla-central (this bug is closed when the sync is complete).
PR: https://github.com/web-platform-tests/wpt/pull/36344
Details from upstream follow.
Rune Lillesveen <futhark@chromium.org> wrote:
Make sure ::first-letter is always reached for re-attach
Generally we do not store ComputedStyle for elements which are not
rendered. In some cases we do not know this at recalc time and get a
non-rendered subtree with ComputedStyles. One such case is when the
content property makes a non-replaced element render as a replaced
image.In such cases we will not traverse this subtree unless there are dirty
bits to be cleared. If there is a ::first-letter pseudo element in the
subtree that needs style recalc, it may be left a NeedsStyleRecalc()
flag set to be handled and cleared for AttachLayoutTree().We cannot clear the style-dirty bit because we need to know if we need
to do a recalc when AttachLayoutTree() happens. Instead, make sure we
reach the ::first-letter in all cases for AttachLayoutTree() by
explicitly marking it for re-attachment.Bug: 1370386
Change-Id: I9b482d0ded063678b34289165160c8f32a8395e6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3936848
Reviewed-by: Anders Hartvoll Ruud \<andruud@chromium.org>
Commit-Queue: Rune Lillesveen \<futhark@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1056289}
Assignee | ||
Updated•2 years ago
|
Assignee | ||
Comment 1•2 years ago
|
||
Assignee | ||
Comment 3•2 years ago
|
||
Comment 4•2 years ago
|
||
bugherder |
Description
•