I'm using a loop to display my list.
<span v-for="freefeature in freefeatures" v-bind:key="freefeature">
<i class="fa fa-check-circle free-icons"></i>
<p>{{freefeature}}</p>
</span>
I want the first i (icon) to be of orange color and rest to be of grey color.
I'm using this loop at multiple places without the free-icons class on i where all the icons need to be orange only at this place they need to be grey except for the first one hence the class "free-icons"
What I've tried:
span i {
color: orange; }
span:nth-child(n+2) i.free-icons {
color: #333;
}
Just to check even first-child selector or any other css selector in that case doesn't work. What I might be doing wrong?
classfree-iconsis found only in this specific case, then docolor: orangeon all i's and then override the same withcolor: grayiffree-iconsclassis there except for the first child in the relevant rendered DOM set. I think this would do the trick for you.