0
0
mirror of https://github.com/twbs/bootstrap.git synced 2025-02-06 04:08:22 +01:00

Merge pull request #12247 from twbs/text-emphasis-variant

refactoring: add & use .text-emphasis-variant() mixin
This commit is contained in:
Mark Otto 2014-01-18 14:28:33 -08:00
commit 9c9a2f3e08
2 changed files with 14 additions and 20 deletions

View File

@ -577,6 +577,15 @@
} }
} }
// Typography
// -------------------------
.text-emphasis-variant(@color) {
color: @color;
&:hover {
color: darken(@color, 10%);
}
}
// Navbar vertical align // Navbar vertical align
// ------------------------- // -------------------------
// Vertically center elements in the navbar. // Vertically center elements in the navbar.

View File

@ -92,34 +92,19 @@ cite { font-style: normal; }
color: @text-muted; color: @text-muted;
} }
.text-primary { .text-primary {
color: @brand-primary; .text-emphasis-variant(@brand-primary);
&:hover {
color: darken(@brand-primary, 10%);
}
} }
.text-success { .text-success {
color: @state-success-text; .text-emphasis-variant(@state-success-text);
&:hover {
color: darken(@state-success-text, 10%);
}
} }
.text-info { .text-info {
color: @state-info-text; .text-emphasis-variant(@state-info-text);
&:hover {
color: darken(@state-info-text, 10%);
}
} }
.text-warning { .text-warning {
color: @state-warning-text; .text-emphasis-variant(@state-warning-text);
&:hover {
color: darken(@state-warning-text, 10%);
}
} }
.text-danger { .text-danger {
color: @state-danger-text; .text-emphasis-variant(@state-danger-text);
&:hover {
color: darken(@state-danger-text, 10%);
}
} }
// Contextual backgrounds // Contextual backgrounds