0

I'm trying to apply dividers to a Bootstrap tab component. Basically, I want horizontal dividers when the class is not active:

.nav-tabs > li:not(.active) a{
     border-right:1px solid #ddd;
     margin-right:0px; 
     border-radius:0;
}

This works except for the adjacent tab (next to the active one). This one doubles up the border.

Is there some trickery to allow me to test whether an element does not have a border-right or border-left property so I can assign one? Something like:

.nav-tabs > li:not(.active)[!border~]{}
fumeng
  • 1,771
  • 5
  • 22
  • 61

1 Answers1

0

Kind of. If it's an inline style you can (again, kind of).

div[style="border-right:1px solid #ddd"]

More details here. Duplicate question of CSS selector by style attribute

Radu Andrei
  • 1,075
  • 10
  • 19