It is hard to tell if you are asking for adding active
class to the sccs
side or dynamically adding a CSS class to ion-slide
element. I assume you are asking for scss
side. If not so, please let me know and I will update the answer.
You can add .active
class to scss
file like this:
.swiper-slide {
// Assuming "slider_selected_text" is covered by "swiper-slide" class
& .slider_selected_text{ // note that there is a space between & and class name
color : #ed1a3b
}
& .slider_unselected_text{
}
&.active{ // note that there is NOT a space between & and class name means this will apply to the elements having both classes
& .slider_selected_text{ // note that there is a space between & and class name
color : #ed1a3b
}
& .slider_unselected_text{
}
}
}
Hope this will give you a clue.