aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornextgenthemes <[email protected]>2012-07-07 23:20:50 +0300
committernextgenthemes <[email protected]>2012-07-07 23:20:50 +0300
commit7d1c8c2a0ce16331583a965821690f7715e62908 (patch)
treeddd528d8fa1c7f5db9084f41f0d6b33456428bc5
parent7ff1b074eab5ccf341c3da3dac799bca864778b6 (diff)
downloadbootstrap-7d1c8c2a0ce16331583a965821690f7715e62908.tar.xz
bootstrap-7d1c8c2a0ce16331583a965821690f7715e62908.zip
Wrapped btn:hover, btn.disabled inside .btn
-rw-r--r--less/buttons.less72
1 files changed, 36 insertions, 36 deletions
diff --git a/less/buttons.less b/less/buttons.less
index 876d35926..26f77d7b3 100644
--- a/less/buttons.less
+++ b/less/buttons.less
@@ -27,47 +27,47 @@
.border-radius(4px);
.ie7-restore-left-whitespace(); // Give IE7 some love
.box-shadow(~"inset 0 1px 0 rgba(255,255,255,.2), 0 1px 2px rgba(0,0,0,.05)");
-}
-
-// Hover state
-.btn:hover {
- color: @grayDark;
- text-decoration: none;
- background-color: darken(@white, 10%);
- *background-color: darken(@white, 15%); /* Buttons in IE7 don't get borders, so darken on hover */
- background-position: 0 -15px;
- // transition is only when going to hover, otherwise the background
- // behind the gradient (there for IE<=9 fallback) gets mismatched
- .transition(background-position .1s linear);
-}
-
-// Focus state for keyboard and accessibility
-.btn:focus {
- .tab-focus();
-}
+ // Hover state
+ &:hover {
+ color: @grayDark;
+ text-decoration: none;
+ background-color: darken(@white, 10%);
+ *background-color: darken(@white, 15%); /* Buttons in IE7 don't get borders, so darken on hover */
+ background-position: 0 -15px;
+
+ // transition is only when going to hover, otherwise the background
+ // behind the gradient (there for IE<=9 fallback) gets mismatched
+ .transition(background-position .1s linear);
+ }
+
+ // Focus state for keyboard and accessibility
+ &:focus {
+ .tab-focus();
+ }
+
+ // Active state
+ &.active,
+ &:active {
+ background-color: darken(@white, 10%);
+ background-color: darken(@white, 15%) e("\9");
+ background-image: none;
+ outline: 0;
+ .box-shadow(~"inset 0 2px 4px rgba(0,0,0,.15), 0 1px 2px rgba(0,0,0,.05)");
+ }
-// Active state
-.btn.active,
-.btn:active {
- background-color: darken(@white, 10%);
- background-color: darken(@white, 15%) e("\9");
- background-image: none;
- outline: 0;
- .box-shadow(~"inset 0 2px 4px rgba(0,0,0,.15), 0 1px 2px rgba(0,0,0,.05)");
-}
+ // Disabled state
+ &.disabled,
+ &[disabled] {
+ cursor: default;
+ background-color: darken(@white, 10%);
+ background-image: none;
+ .opacity(65);
+ .box-shadow(none);
+ }
-// Disabled state
-.btn.disabled,
-.btn[disabled] {
- cursor: default;
- background-color: darken(@white, 10%);
- background-image: none;
- .opacity(65);
- .box-shadow(none);
}
-
// Button Sizes
// --------------------------------------------------