Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Pseudo-element-using hover state messed up Re: Pseudo-element-using hover state messed up

#131241
wolfcry911
Participant

@dheeraj, my solution works even if the heading goes to two lines (shrink the viewport for my pen). I’ll explain it later as I’m off to work now…

Paulie is correct, the reason it doesn’t work in webkit is that it is positioned outside of its container (why it doesn’t work, I’m not exactly sure, it does in Firefox). A simple fix is to remove the relative positioning from the h3 and remove the bottom margin from the h2