]> git.ipfire.org Git - thirdparty/foundation/foundation-sites.git/commitdiff
Hollow button disabled consistency fix #9832
authorharry <harmanmanchanda182@gmail.com>
Fri, 3 Mar 2017 19:21:46 +0000 (00:51 +0530)
committerharry <harmanmanchanda182@gmail.com>
Fri, 3 Mar 2017 19:21:46 +0000 (00:51 +0530)
docs/pages/button.md
scss/components/_button.scss

index 1b7318adf62ba0688c89342f669b38a8eee19a44..39cd969fa9e24a8148616da4b6b653786de25223 100644 (file)
@@ -108,9 +108,9 @@ The `.disabled` class will give buttons a faded appearance. The class is a purel
 
 ```html_example
 <a class="button disabled" href="#" aria-disabled>Disabled</a>
-<button type="button" class="button primary" disabled>Disabled</button>
+<button type="button" class="button primary hollow" disabled>Disabled</button>
 <button type="button" class="button secondary" disabled>Disabled</button>
-<button type="button" class="button success" disabled>Disabled</button>
+<button type="button" class="button success hollow" disabled>Disabled</button>
 <button type="button" class="button alert" disabled>Disabled</button>
 <button type="button" class="button warning" disabled>Disabled</button>
 ```
index 26170a3ae1d5c80fe260626617261b5174efcb27..5b9209cf6021d5254ddc7c5fefa0fe8d995ac5c6 100644 (file)
@@ -169,6 +169,11 @@ $button-transition: background-color 0.25s ease-out, color 0.25s ease-out !defau
   &:hover, &:focus {
     border-color: $color-hover;
     color: $color-hover;
+    &.disabled,
+    &[disabled] {
+      border: $border-width solid $color;
+      color: $color;
+    }
   }
 }
 
@@ -271,12 +276,31 @@ $button-transition: background-color 0.25s ease-out, color 0.25s ease-out !defau
       }
     }
 
+    // Disabled style
+    &.disabled,
+    &[disabled] {
+      @include button-disabled;
+
+      @each $name, $color in $button-palette {
+        &.#{$name} {
+          @include button-disabled($color, auto);
+        }
+      }
+    }
+
     // Hollow style
     @if $button-fill != hollow {
       &.hollow {
         @include button-hollow;
         @include button-hollow-style;
 
+        &.disabled,
+        &[disabled] {
+          &, &:hover, &:focus {
+            background-color: transparent;
+          }
+        }
+
         @each $name, $color in $button-palette {
           &.#{$name} {
             @include button-hollow-style($color);
@@ -285,18 +309,6 @@ $button-transition: background-color 0.25s ease-out, color 0.25s ease-out !defau
       }
     }
 
-    // Disabled style
-    &.disabled,
-    &[disabled] {
-      @include button-disabled;
-
-      @each $name, $color in $button-palette {
-        &.#{$name} {
-          @include button-disabled($color, auto);
-        }
-      }
-    }
-
     // Dropdown arrow
     &.dropdown {
       @include button-dropdown;