aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Otto <[email protected]>2014-09-18 19:15:01 -0700
committerMark Otto <[email protected]>2014-09-18 19:15:01 -0700
commit2cc9e773c57e389e8fcb797148fb850433144c3e (patch)
tree6f2d30aa5f7397709264c288b5af23bc6dcbf14c
parent073389ca5eafd0972a8e9e32b6a64c97d9340083 (diff)
downloadbootstrap-2cc9e773c57e389e8fcb797148fb850433144c3e.tar.xz
bootstrap-2cc9e773c57e389e8fcb797148fb850433144c3e.zip
Move text and background utilties from _type to _utilities
-rw-r--r--less/_type.less57
-rw-r--r--less/_utilities.less64
2 files changed, 57 insertions, 64 deletions
diff --git a/less/_type.less b/less/_type.less
index 4cd727bae..2b331555d 100644
--- a/less/_type.less
+++ b/less/_type.less
@@ -80,63 +80,6 @@ mark,
padding: .2em;
}
-// Alignment
-.text-left { text-align: left; }
-.text-right { text-align: right; }
-.text-center { text-align: center; }
-.text-justify { text-align: justify; }
-.text-nowrap { white-space: nowrap; }
-
-// Transformation
-.text-lowercase { text-transform: lowercase; }
-.text-uppercase { text-transform: uppercase; }
-.text-capitalize { text-transform: capitalize; }
-
-// Contextual colors
-.text-muted {
- color: @text-muted;
-}
-.text-primary {
- .text-emphasis-variant(@brand-primary);
-}
-.text-success {
- .text-emphasis-variant(@state-success-text);
-}
-.text-info {
- .text-emphasis-variant(@state-info-text);
-}
-.text-warning {
- .text-emphasis-variant(@state-warning-text);
-}
-.text-danger {
- .text-emphasis-variant(@state-danger-text);
-}
-
-// 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 its color inverted
- // automatically.
- color: #fff;
- .bg-variant(@brand-primary);
-}
-.bg-success {
- .bg-variant(@state-success-bg);
-}
-.bg-info {
- .bg-variant(@state-info-bg);
-}
-.bg-warning {
- .bg-variant(@state-warning-bg);
-}
-.bg-danger {
- .bg-variant(@state-danger-bg);
-}
-.bg-gray-dark {
- .bg-variant(@gray-dark);
-}
-
// Page header
// -------------------------
diff --git a/less/_utilities.less b/less/_utilities.less
index d24e7e281..9f2eef28a 100644
--- a/less/_utilities.less
+++ b/less/_utilities.less
@@ -4,8 +4,6 @@
// Floats
-// -------------------------
-
.clearfix {
.clearfix();
}
@@ -50,8 +48,6 @@
// Toggling content
-// -------------------------
-
.show {
display: block !important;
}
@@ -66,7 +62,6 @@
// Hide from screenreaders and browsers
//
// Credit: HTML5 Boilerplate
-
.hidden {
display: none !important;
visibility: hidden !important;
@@ -74,8 +69,63 @@
// For Affix plugin
-// -------------------------
-
.affix {
position: fixed;
}
+
+// Alignment
+.text-left { text-align: left; }
+.text-right { text-align: right; }
+.text-center { text-align: center; }
+.text-justify { text-align: justify; }
+.text-nowrap { white-space: nowrap; }
+
+// Transformation
+.text-lowercase { text-transform: lowercase; }
+.text-uppercase { text-transform: uppercase; }
+.text-capitalize { text-transform: capitalize; }
+
+// Contextual colors
+.text-muted {
+ color: @text-muted;
+}
+.text-primary {
+ .text-emphasis-variant(@brand-primary);
+}
+.text-success {
+ .text-emphasis-variant(@state-success-text);
+}
+.text-info {
+ .text-emphasis-variant(@state-info-text);
+}
+.text-warning {
+ .text-emphasis-variant(@state-warning-text);
+}
+.text-danger {
+ .text-emphasis-variant(@state-danger-text);
+}
+
+// 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 its color inverted
+ // automatically.
+ color: #fff;
+ .bg-variant(@brand-primary);
+}
+.bg-success {
+ .bg-variant(@state-success-bg);
+}
+.bg-info {
+ .bg-variant(@state-info-bg);
+}
+.bg-warning {
+ .bg-variant(@state-warning-bg);
+}
+.bg-danger {
+ .bg-variant(@state-danger-bg);
+}
+.bg-gray-dark {
+ .bg-variant(@gray-dark);
+}