+ 2

hover in css

https://code.sololearn.com/WI1k3PbQg9US/# while hovering hamburger menu background-color is not changing..

5th Aug 2020, 11:04 AM
Muralikrishnan
Muralikrishnan - avatar
5 Réponses
+ 5
If you're trying to access child then continue doing what you're doing: .myParent:hover .myChild {} Otherwise, you're gonna have to take help of JavaScript.
5th Aug 2020, 11:10 AM
Raj Chhatrala
Raj Chhatrala - avatar
+ 4
It would not work like that. .header is parent of .hamburger-menu not child. Syntax you're using is for child selector.
5th Aug 2020, 11:06 AM
Raj Chhatrala
Raj Chhatrala - avatar
+ 4
You can use pointer-events property for that! Basically you've to turn off pointer-events on parent, but not for child and attach hover event on parent. See the implementation: https://code.sololearn.com/W1Owl6Ik62JZ/#
5th Aug 2020, 11:32 AM
777
777 - avatar
+ 1
what can I use for change property of a element while hovering another element ?
5th Aug 2020, 11:08 AM
Muralikrishnan
Muralikrishnan - avatar
+ 1
ok thanks for help
5th Aug 2020, 11:14 AM
Muralikrishnan
Muralikrishnan - avatar