aboutsummaryrefslogtreecommitdiff
path: root/less/type.less
diff options
context:
space:
mode:
authorMark Otto <[email protected]>2013-12-15 11:16:57 -0800
committerMark Otto <[email protected]>2013-12-15 11:16:57 -0800
commitfd62247bf8bbb1bce072f5ee03e996dfc4abed94 (patch)
tree487766325e03d40c7af16c58873b70d8638a72ba /less/type.less
parentfbf31f965e27a6665c7e0f2d97eb74c0df7585d4 (diff)
parent2b86e05a6150ef13905519070ea82ce895fbae85 (diff)
downloadbootstrap-fd62247bf8bbb1bce072f5ee03e996dfc4abed94.tar.xz
bootstrap-fd62247bf8bbb1bce072f5ee03e996dfc4abed94.zip
Merge branch 'master' into cover_template
Diffstat (limited to 'less/type.less')
-rw-r--r--less/type.less49
1 files changed, 43 insertions, 6 deletions
diff --git a/less/type.less b/less/type.less
index 24a581fe8..52f9b5b2b 100644
--- a/less/type.less
+++ b/less/type.less
@@ -81,7 +81,13 @@ small,
// Undo browser default styling
cite { font-style: normal; }
-// Contextual emphasis
+// Alignment
+.text-left { text-align: left; }
+.text-right { text-align: right; }
+.text-center { text-align: center; }
+.text-justify { text-align: justify; }
+
+// Contextual colors
.text-muted {
color: @text-muted;
}
@@ -116,11 +122,42 @@ cite { font-style: normal; }
}
}
-// Alignment
-.text-left { text-align: left; }
-.text-right { text-align: right; }
-.text-center { text-align: center; }
-.text-justify { text-align: justify; }
+// Contextual backgrounds
+// For now we'll leave these alongside the text classes until v4 when we can
+// safely shift things around (per SemVer rules).
+.bg-primary {
+ // Given the contrast here, this is the only class to have it's color inverted
+ // automatically.
+ color: #fff;
+ background-color: @brand-primary;
+ a&:hover {
+ background-color: darken(@brand-primary, 10%);
+ }
+}
+.bg-warning {
+ background-color: @state-warning-bg;
+ a&:hover {
+ background-color: darken(@state-warning-bg, 10%);
+ }
+}
+.bg-danger {
+ background-color: @state-danger-bg;
+ a&:hover {
+ background-color: darken(@state-danger-bg, 10%);
+ }
+}
+.bg-success {
+ background-color: @state-success-bg;
+ a&:hover {
+ background-color: darken(@state-success-bg, 10%);
+ }
+}
+.bg-info {
+ background-color: @state-info-bg;
+ a&:hover {
+ background-color: darken(@state-info-bg, 10%);
+ }
+}
// Page header