css support for has() selector is producing unexpected results
Categories
(Core :: CSS Parsing and Computation, defect)
Tracking
()
People
(Reporter: jmeurer986, Unassigned)
References
Details
Attachments
(1 file)
1.35 MB,
image/png
|
Details |
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:107.0) Gecko/20100101 Firefox/107.0
Steps to reproduce:
am working on refactoring the UI of a legacy application. I implemented the has() selector in my css and in firefox the selector is matching elements that should not be matched.
Actual results:
The css style is being applied to elements that don't actually match the criteria in the rule
Expected results:
only elements that match the rule criteria should receive the style. In the screenshot the same page in my app is shown on the left in firefox and on the right in Chrome. The page should be styled as it is in Chrome.
Comment 1•2 years ago
|
||
Please attach a minimal testcase to the bug.
Updated•2 years ago
|
Comment 2•2 years ago
|
||
This is not unexpected, that's why it's disabled by default. We don't invalidate :has()
yet and style sharing is broken.
Comment 3•2 years ago
|
||
Sounds like this is approximately bug 1793012 then.
(If it's not too much trouble to share an affected URL or a minimized testcase to demonstrate the issue you're hitting, that may end up being handy to validate that this is indeed fixed once bug 1793012 and other associated work is fixed. No worries if that's not easy to provide, though; per comment 2, it sounds like the deficiencies here are reasonably well-understood.)
Description
•