Search
 
SCRIPT & CODE EXAMPLE
 

CSS

on class hover another class color change

/* For wrapper is a child of item */
.item:hover .wrapper {
    color: #fff;
    background-color: #000;
}

/* For wrapper is another div and item is another */
.item:hover ~ .wrapper {
    color: #fff;
    background-color: #000;
}
Comment

modify another class on hover

A child element hover cannot effect a parent class or a class elsewhere in the code besides children and siblings. You'll have to use Javascript for that. 
Comment

PREVIOUS NEXT
Code Example
Css :: map arrays 
Css :: images end then start text in css 
Css :: css class selector 
Css :: get element in list ocaml 
Css :: difference bw box and border box 
Css :: graident colors 
Css :: css hex to rgb 
Css :: scss import another file 
Css :: add css class c# 
Css :: css cursor 
Css :: css fonts 
Css :: learn css 
Css :: freeze input text css 
Css :: Night / dark mode css 
Css :: html color codes 
Css :: how to give rgba in tailwind 
Css :: transparent circle css 
Css :: beautiful scrollbar css 
Css :: css selector id class 
Css :: what is the difference between relative and absolute css 
Css :: Creating a project in pycharm using scrapy 
Css :: css all children of type 
Css :: css animation timing syntax 
Css :: inherit styles 
Css :: how to make code continue after a transition css 
Css :: moving nested element up css 
Css :: Use @use to load module scss - @forward in _index.scss 
Css :: Protéger les fichiers .htaccess et .htpasswds 
Css :: css code for flash messages flask 
Css :: css how to transform and stay on top of page 
ADD CONTENT
Topic
Content
Source link
Name
8+3 =