2016-10-24 5 views
2

Trying to get next element after li.active class.activeクラスの後に次の要素を取得するにはどうすればCSSで.active要素</strong>後に次の要素<strong>を取得しようとしています

は、.activeクラスを取得する要素は、最初のリストです「Lightslider」の項目。

私は以下のコードを試してみた:

.lslide.active + li:nth-child(1) { 
    -ms-transform: scale(1.3); 
    -webkit-transform: scale(1.3); 
    transform: scale(1.3); 
} 

はCSSで可能なこのですか?

ありがとうございました。

.active + li { 
 
    color: red; 
 
}
<ul> 
 
    <li class="active">Item</li> 
 
    <li>Item</li> 
 
    <li>Item</li> 
 
</ul>

答えて

関連する問題