1 |
|
2 |
|
3 |
|
4 |
|
5 |
|
6 |
|
7 |
|
8 |
|
9 |
|
10 |
|
11 | $label-background: $primary-color !default;
|
12 |
|
13 |
|
14 |
|
15 | $label-color: $white !default;
|
16 |
|
17 |
|
18 |
|
19 | $label-color-alt: $black !default;
|
20 |
|
21 |
|
22 |
|
23 | $label-palette: $foundation-palette !default;
|
24 |
|
25 |
|
26 |
|
27 | $label-font-size: 0.8rem !default;
|
28 |
|
29 |
|
30 |
|
31 | $label-padding: 0.33333rem 0.5rem !default;
|
32 |
|
33 |
|
34 |
|
35 | $label-radius: $global-radius !default;
|
36 |
|
37 |
|
38 | @mixin label {
|
39 | display: inline-block;
|
40 | padding: $label-padding;
|
41 |
|
42 | border-radius: $label-radius;
|
43 |
|
44 | font-size: $label-font-size;
|
45 | line-height: 1;
|
46 | white-space: nowrap;
|
47 | cursor: default;
|
48 | }
|
49 |
|
50 | @mixin foundation-label {
|
51 | .label {
|
52 | @include label;
|
53 |
|
54 | background: $label-background;
|
55 | color: $label-color;
|
56 |
|
57 | @each $name, $color in $label-palette {
|
58 | &.#{$name} {
|
59 | background: $color;
|
60 | color: color-pick-contrast($color, ($label-color, $label-color-alt));
|
61 | }
|
62 | }
|
63 | }
|
64 | }
|