我正在使用nth-child选择器为不同的社交添加边框颜色list-group-item。我究竟做错了什么?
.list-group-item:nth-child(1) {
border-right: 3px solid yellow;
}
.list-group-item:nth-child(2) {
border-right: 3px solid red;
}
.list-group-item:nth-child(3) {
border-right: 3px solid green;
}
.list-group-item:nth-child(4) {
border-right: 3px solid blue;
}
.list-group-item:nth-child(5) {
border-right: 3px solid lime;
}
.list-group-item:nth-child(6) {
border-right: 3px solid red;
}Run Code Online (Sandbox Code Playgroud)
<div class=" col-xs-12 col-sm-6 col-md-4 col-lg-6">
<div class="views-field views-field-title">
<span class="field-content list-group-item">Yahoo<a href="/app/wall/content/"></a></span>
</div>
</div>
<div class=" col-xs-12 col-sm-6 col-md-4 col-lg-6">
<div class="views-field views-field-title">
<span class="field-content list-group-item">Googke<a href="/app/wall/content/"></a></span>
</div>
</div>Run Code Online (Sandbox Code Playgroud)