]>
Commit | Line | Data |
---|---|---|
1 | // | |
2 | // Labels | |
3 | // -------------------------------------------------- | |
4 | ||
5 | .label { | |
6 | display: inline; | |
7 | padding: .2em .6em .3em; | |
8 | font-size: 75%; | |
9 | font-weight: bold; | |
10 | line-height: 1; | |
11 | color: @label-color; | |
12 | text-align: center; | |
13 | white-space: nowrap; | |
14 | vertical-align: baseline; | |
15 | border-radius: .25em; | |
16 | ||
17 | // Add hover effects, but only for links | |
18 | &[href] { | |
19 | &:hover, | |
20 | &:focus { | |
21 | color: @label-link-hover-color; | |
22 | text-decoration: none; | |
23 | cursor: pointer; | |
24 | } | |
25 | } | |
26 | ||
27 | // Empty labels collapse automatically (not available in IE8) | |
28 | &:empty { | |
29 | display: none; | |
30 | } | |
31 | } | |
32 | ||
33 | // Colors | |
34 | // Contextual variations (linked labels get darker on :hover) | |
35 | ||
36 | .label-default { | |
37 | .label-variant(@label-default-bg); | |
38 | } | |
39 | ||
40 | .label-primary { | |
41 | .label-variant(@label-primary-bg); | |
42 | } | |
43 | ||
44 | .label-success { | |
45 | .label-variant(@label-success-bg); | |
46 | } | |
47 | ||
48 | .label-info { | |
49 | .label-variant(@label-info-bg); | |
50 | } | |
51 | ||
52 | .label-warning { | |
53 | .label-variant(@label-warning-bg); | |
54 | } | |
55 | ||
56 | .label-danger { | |
57 | .label-variant(@label-danger-bg); | |
58 | } |