[wpt-sync] Sync PR 21983 - Perform kNotInsideLink-related adjustments in ElementRuleCollector
Categories
(Core :: CSS Parsing and Computation, task, P4)
Tracking
()
Tracking | Status | |
---|---|---|
firefox75 | --- | fixed |
People
(Reporter: wpt-sync, Unassigned)
References
()
Details
(Whiteboard: [wptsync downstream])
Sync web-platform-tests PR 21983 into mozilla-central (this bug is closed when the sync is complete).
PR: https://github.com/web-platform-tests/wpt/pull/21983
Details from upstream follow.
Anders Hartvoll Ruud <andruud@chromium.org> wrote:
Perform kNotInsideLink-related adjustments in ElementRuleCollector
The link_match_type stored on the MatchedProperties object is only
relevant and correct if we're inside a link, hence we need to override
the effective link_match_type at some point.Previously, we would do this apply-time, and not as part of the rule-
collection. This CL instead proposes that ElementRuleCollector take
the link-status into account, and perform the adjustment before storing
the link_match_type on MatchedProperties, such that no further
adjustments are required later.This fixes a bug in the CSSCascade path, where we would incorrectly not
apply anything for selectors such as *:not(:link):not(:visited), even
for elements that are not inside links. (See AddLinkFilter in
cascade_expansion.cc. We would switch on the value 0, and then enter
the default case, causing a filter to be added on kProperty, which
causes all properties to be rejected. This is correct for elements
that are inside links, but not for elements that aren't).Bug: 1055715
Change-Id: I2b63de41753fb0fa7b637a4be5bd009c2f165fcf
Reviewed-on: https://chromium-review.googlesource.com/2072223
WPT-Export-Revision: 1d2a6d22f2c5eabfa73fdf5b0fa381a08ecd724f
Assignee | ||
Updated•5 years ago
|
Assignee | ||
Comment 1•5 years ago
|
||
Assignee | ||
Comment 2•5 years ago
|
||
CI Results
Ran 0 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI
Total 1 tests
Status Summary
Firefox
PASS: 1
Chrome
FAIL: 1
Safari
PASS: 1
Links
Comment 4•5 years ago
|
||
bugherder |
Description
•