The forums ran from 2008-2020 and are now closed and viewable here as an archive.
Home › Forums › CSS › The :not pseudoclass and direct descendant weirdness
Reduced test case: https://codepen.io/leland/pen/gxxJRL
I’ve noticed :not works as expected (i.e. the second link is blue) if it is a direct descendant of .widget-area, but unfortunately I need to keep .another-div in there for other reasons.
Any idea what’s going on?
Thank you in advance.
Wait, I think I just answered my own question.
After adding the direct descendant selector it now works as I want it to: https://codepen.io/leland/pen/XaawzO
Think I’m good now. Sorry for the trouble.