Skip to content

Commit 8afa29b

Browse files
committed
feat(Badge): add badge-sm
1 parent 55f4403 commit 8afa29b

File tree

2 files changed

+14
-1
lines changed

2 files changed

+14
-1
lines changed

scss/_badge.scss

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
color: var(--#{$variable-prefix}badge-color, $badge-color);
1313
text-align: center;
1414
white-space: nowrap;
15-
vertical-align: baseline;
15+
vertical-align: text-bottom;
1616
@include border-radius($badge-border-radius);
1717
@include gradient-bg();
1818

@@ -27,3 +27,12 @@
2727
position: relative;
2828
top: -1px;
2929
}
30+
31+
//
32+
// Badge Sizes
33+
//
34+
35+
.badge-sm {
36+
padding: $badge-padding-y-sm $badge-padding-x-sm;
37+
@include font-size($badge-font-size-sm);
38+
}

scss/_variables.scss

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1223,6 +1223,10 @@ $badge-color: $high-emphasis-light !default;
12231223
$badge-padding-y: .35em !default;
12241224
$badge-padding-x: .65em !default;
12251225
$badge-border-radius: $border-radius !default;
1226+
1227+
$badge-font-size-sm: .65em !default;
1228+
$badge-padding-y-sm: .3em !default;
1229+
$badge-padding-x-sm: .5em !default;
12261230
// scss-docs-end badge-variables
12271231

12281232

0 commit comments

Comments
 (0)