Cannot Have `::after` in area elements
Categories
(Core :: Layout: Generated Content, Lists, and Counters, defect)
Tracking
()
People
(Reporter: niente0, Unassigned)
References
Details
Attachments
(1 file)
496 bytes,
text/html
|
Details |
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/111.0.0.0 Safari/537.36
Steps to reproduce:
Just view the HTML file in attachment. The pseudo element keeps having a "static" position. If I set:
#a1 {position:absolute}
then position seems to be accepted (even if it is not), but the hover effect still refuses to work.
Actual results:
No hover animation visible
Expected results:
A hover animation should be visible when cursor is moved on rectangle, like in Chrome
Updated•2 years ago
|
Comment 1•2 years ago
|
||
Applying absolute positioning to div::after
works, so I don't think that's causing issues.
The root cause seems to be that we do not allow ::after on these elements (::after
never shows up in Inspector).
I think this is due to their Content Model in the standard being Nothing, which means no text or element nodes, and Chrome may be incorrect in this case?
Comment 2•2 years ago
|
||
<area>
is display: none
, so it's kind of expected that we don't allow pseudo-elements there... Maybe other browsers implement <area>
differently.
Comment 3•2 years ago
|
||
The severity field is not set for this bug.
:boris, could you have a look please?
For more information, please visit auto_nag documentation.
Comment 4•2 years ago
|
||
So this is an expected behavior in Firefox, and perhaps it's worth to discuss this behavior in the spec issue? Mark this as S3.
Description
•