Closed Bug 1731327 Opened 1 year ago Closed 1 year ago

[wpt-sync] Sync PR 30783 - Paint ::selection foreground over other pseudos

Categories

(Core :: CSS Parsing and Computation, task, P4)

task

Tracking

()

RESOLVED FIXED
95 Branch
Tracking Status
firefox95 --- fixed

People

(Reporter: mozilla.org, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

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

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

b'Fernando Fiori <ffiori@microsoft.com>' wrote:

Paint ::selection foreground over other pseudos

This CL paints ::selection foreground overlay following the spec that
says it should be painted on top (see
https://drafts.csswg.org/css-pseudo-4/#highlight-text).

Although this is not a complete fix that takes the code to comply with
the specifications, it makes it closer to them and it fixes cases like
the one in the example "Selecting highlighted text" from the set of
examples hosted here https://codepen.io/dazabani13/pen/KKqzOJp (note
that the example requires the flag --experimental-web-platform-features
to be enabled to see the highlights).

Also rebaselined tests that were painting underline squiggles over text
when it actually should be below (see
https://www.w3.org/TR/css-text-decor/#painting-order).

Bug: 1147859
Change-Id: Ie150fe3861807fcb74343d7371f1ee7009745272
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3155369
Commit-Queue: Fernando Fiori \<ffiori@microsoft.com>
Reviewed-by: Rune Lillesveen \<futhark@chromium.org>
Reviewed-by: Dan Clark \<daniec@microsoft.com>
Reviewed-by: Delan Azabani \<dazabani@igalia.com>
Cr-Commit-Position: refs/heads/main@{#922211}

Component: web-platform-tests → CSS Parsing and Computation
Product: Testing → Core

CI Results

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

Total 1 tests

Status Summary

Firefox

FAIL: 1

Chrome

FAIL: 1

Safari

FAIL: 1

Links

Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base

Details

New Tests That Don't Pass

/css/css-highlight-api/painting/custom-highlight-painting-below-selection.html: FAIL (Chrome: FAIL, Safari: FAIL)

Pushed by wptsync@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/5ba7ec3f8e64
[wpt PR 30783] - Paint ::selection foreground over other pseudos, a=testonly
https://hg.mozilla.org/integration/autoland/rev/772f7ddf79c0
[wpt PR 30783] - Update wpt metadata, a=testonly
Pushed by wptsync@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/55a48869b88e
[wpt PR 30783] - Paint ::selection foreground over other pseudos, a=testonly
https://hg.mozilla.org/integration/autoland/rev/c2324c09bd5f
[wpt PR 30783] - Update wpt metadata, a=testonly
Status: NEW → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → 95 Branch
You need to log in before you can comment on or make changes to this bug.