diff --git a/docs/assets/css/bootstrap.css b/docs/assets/css/bootstrap.css
index db65570fc0..cb8482a9f6 100644
--- a/docs/assets/css/bootstrap.css
+++ b/docs/assets/css/bootstrap.css
@@ -4263,6 +4263,58 @@ a.thumbnail:focus {
list-style: none;
}
+.label {
+ padding: .25em .6em;
+ font-size: 75%;
+ font-weight: 500;
+ line-height: 1;
+ color: #fff;
+ text-align: center;
+ white-space: nowrap;
+ vertical-align: middle;
+ background-color: #999999;
+ border-radius: .25em;
+}
+
+a.label:hover,
+a.label:focus {
+ color: #fff;
+ text-decoration: none;
+ cursor: pointer;
+}
+
+.label-danger {
+ background-color: #d9534f;
+}
+
+.label-danger[href] {
+ background-color: #c9302c;
+}
+
+.label-warning {
+ background-color: #f0ad4e;
+}
+
+.label-warning[href] {
+ background-color: #ec971f;
+}
+
+.label-success {
+ background-color: #5cb85c;
+}
+
+.label-success[href] {
+ background-color: #449d44;
+}
+
+.label-info {
+ background-color: #5bc0de;
+}
+
+.label-info[href] {
+ background-color: #31b0d5;
+}
+
.badge {
display: inline-block;
min-width: 10px;
diff --git a/docs/components.html b/docs/components.html
index 53b4a7e08e..f1b45159b7 100644
--- a/docs/components.html
+++ b/docs/components.html
@@ -28,6 +28,7 @@ title: Components
Navbar
Breadcrumbs
Pagination
+ Labels
Badges
Typography
Thumbnails
@@ -1274,6 +1275,84 @@ title: Components
+
+
+
+
+
+ Example
+
+
Example heading New
+ Example heading New
+ Example heading New
+ Example heading New
+ Example heading New
+ Example heading New
+
+{% highlight html linenos %}
+Example heading New
+{% endhighlight %}
+
+ Available variations
+ Add any of the below mentioned modifier classes to change the appearance of a label.
+
+
+
+ Labels |
+ Markup |
+
+
+
+
+
+ Default
+ |
+
+ <span class="label">Default</span>
+ |
+
+
+
+ Success
+ |
+
+ <span class="label label-success">Success</span>
+ |
+
+
+
+ Warning
+ |
+
+ <span class="label label-warning">Warning</span>
+ |
+
+
+
+ Danger
+ |
+
+ <span class="label label-danger">Danger</span>
+ |
+
+
+
+ Info
+ |
+
+ <span class="label label-info">Info</span>
+ |
+
+
+
+
+
+
+
+
diff --git a/less/bootstrap.less b/less/bootstrap.less
index d40984230c..60d166368c 100644
--- a/less/bootstrap.less
+++ b/less/bootstrap.less
@@ -49,6 +49,7 @@
@import "alerts.less";
@import "thumbnails.less";
@import "media.less";
+@import "labels.less";
@import "badges.less";
@import "progress-bars.less";
@import "accordion.less";
diff --git a/less/labels.less b/less/labels.less
new file mode 100644
index 0000000000..2592d04446
--- /dev/null
+++ b/less/labels.less
@@ -0,0 +1,46 @@
+//
+// Labels
+// --------------------------------------------------
+
+
+// Base classes
+.label {
+ padding: .25em .6em;
+ font-size: 75%;
+ font-weight: 500;
+ color: #fff;
+ line-height: 1;
+ vertical-align: middle;
+ white-space: nowrap;
+ text-align: center;
+ background-color: @grayLight;
+ border-radius: .25em;
+}
+
+// Hover state, but only for links
+a.label {
+ &:hover,
+ &:focus {
+ color: #fff;
+ text-decoration: none;
+ cursor: pointer;
+ }
+}
+
+// Colors
+// Only give background-color difference to links (and to simplify, we don't qualifty with `a` but [href] attribute)
+.label {
+ // Danger (red)
+ &-danger { background-color: @label-danger-background; }
+ &-danger[href] { background-color: darken(@label-danger-background, 10%); }
+ // Warnings (orange)
+ &-warning { background-color: @label-warning-background; }
+ &-warning[href] { background-color: darken(@label-warning-background, 10%); }
+ // Success (green)
+ &-success { background-color: @label-success-background; }
+ &-success[href] { background-color: darken(@label-success-background, 10%); }
+ // Info (turquoise)
+ &-info { background-color: @label-info-background; }
+ &-info[href] { background-color: darken(@label-info-background, 10%); }
+}
+
diff --git a/less/variables.less b/less/variables.less
index 9eb84ddaaa..2b6fa6e1bf 100644
--- a/less/variables.less
+++ b/less/variables.less
@@ -271,6 +271,14 @@
@popover-arrow-outer-color: rgba(0,0,0,.25);
+// Labels
+// -------------------------
+@label-success-background: @brand-success;
+@label-info-background: @brand-info;
+@label-warning-background: @brand-warning;
+@label-danger-background: @brand-danger;
+
+
// Modals
// -------------------------