Closed Bug 2089412 Opened 15 days ago Closed 7 days ago

[wpt-sync] Sync PR 64445 - WebKit export of https://bugs.webkit.org/show_bug.cgi?id=47815

Categories

(Core :: Layout: Generated Content, Lists, and Counters, task, P4)

task

Tracking

()

RESOLVED FIXED
162 Branch
Tracking Status
firefox162 --- fixed

People

(Reporter: wpt-sync, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 64445 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/64445
Details from upstream follow.

Alan Baradlay <zalan@apple.com> wrote:

WebKit export of https://bugs.webkit.org/show_bug.cgi?id=47815

WebKit export from bug: :<!---->:<!---->first-<!---->letter not updated when :<!---->:<!---->before pseudo-<!---->element is dynamically added

<pre>
first-letter not updated when ::before pseudo-element is dynamically added

When you have a block with ::first-letter styling and then dynamically add
a ::before pseudo-element to an element inside it, the ::before content
should become the new first letter.

In the render tree, the ::before renderer gets placed after the existing
first-letter wrapper (which already occupies the first-child slot):

first-letter wrapper -> "1"
::before -> "A"
remaining text -> "23"

After detecting staleness, the existing rebuild logic handles the rest:
it resets the remaining text (which tears down the old wrapper), re-walks
the tree to find the new first letter ("A" from ::before), and creates
the split.

Note that when the first letter were already from ::before
content, the wrapper would be inside the ::before renderer (as its
descendant), not beside it as a sibling.

WebKit-Bug: <a href="https://bugs.webkit.org/show_bug.cgi?id=47815">https://bugs.webkit.org/show_bug.cgi?id=47815</a>
WebKit-Canonical-Link: <a href="https://commits.webkit.org/310774@main">https://commits.webkit.org/310774@main</a>
</pre>

Whiteboard: [wptsync downstream] → [wptsync downstream error]
Component: web-platform-tests → Layout: Generated Content, Lists, and Counters
Product: Testing → Core
Whiteboard: [wptsync downstream error] → [wptsync downstream]

CI Results

Ran 11 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI

Total 359 tests and 41 subtests

Status Summary

Firefox

OK : 57
PASS : 4[GitHub] 26[Gecko-linux2204-64-wayland-debug, Gecko-linux2204-64-wayland-opt] 685[Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt] 882[Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt] 888[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview]
FAIL : 202[Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt] 272[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview] 278[Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt]
ERROR: 3

Chrome

PASS : 4

Safari

PASS : 4

Links

Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base

Details

New Tests That Don't Pass

Status: NEW → RESOLVED
Closed: 7 days ago
Resolution: --- → FIXED
Target Milestone: --- → 162 Branch
You need to log in before you can comment on or make changes to this bug.