Twitter Bootstrap 3.0 how do I “badge badge-important” now

后端 未结 9 1723
执念已碎
执念已碎 2021-01-29 19:01

In version two I could use

badge badge-important

I see that the .badge element no longer has contextual (-success,-primary,etc..) c

9条回答
  •  囚心锁ツ
    2021-01-29 19:47

    Like the answer above but here is using bootstrap 3 names and colours:

    /*css to add back colours for badges and make use of the colours*/
    .badge-default {
      background-color: #999999;
    }
    
    .badge-primary {
      background-color: #428bca;
    }
    
    .badge-success {
      background-color: #5cb85c;
    }
    
    .badge-info {
      background-color: #5bc0de;
    }
    
    .badge-warning {
      background-color: #f0ad4e;
    }
    
    .badge-danger {
      background-color: #d9534f;
    }

提交回复
热议问题