我如何将鼠标悬停在内容上来更改容器

我试图通过将鼠标悬停在内容上来了解如何更改容器

.container {
   width:100vw;
   height:100vh;
}
.content:hover .container {
   background-color:#fff;
}
<div class="container">
   <div class="content">content</div>
</div>
i459612852 回答:我如何将鼠标悬停在内容上来更改容器

.container{
    width:100vw;
    height:100vh;
    background: red;
}    
.container:hover{
    background: white;
}
本文链接:https://www.f2er.com/3166408.html

大家都在问