Skip to content

Commit

Permalink
Buttons in IE. Fixes #165. (Props @jomurgel)
Browse files Browse the repository at this point in the history
  • Loading branch information
gregrickaby committed Jul 29, 2016
1 parent 60db0e0 commit ac78ae0
Show file tree
Hide file tree
Showing 6 changed files with 103 additions and 68 deletions.
32 changes: 32 additions & 0 deletions assets/sass/modules/_buttons.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
//--------------------------------------------------------------
// Buttons
//--------------------------------------------------------------

button,
input[type="button"],
input[type="reset"],
input[type="submit"] {
background-color: $color-button-background;
border: none;
border-radius: 0;
border-width: 0;
color: $color-button-text;
line-height: 1.5;
margin: 0;
padding: $padding-input;
appearance: none;

// IE 11 helper.
body.ie & {
height: rem(35);
} // body.ie

&:hover {
background-color: $color-button-background-hover;
} // &:hover

&:active,
&:focus {
background-color: $color-button-background-hover;
} // &:active, &:focus
} // button, input[type="button"], input[type="reset"], input[type="submit"]
32 changes: 5 additions & 27 deletions assets/sass/modules/_forms.scss
Original file line number Diff line number Diff line change
Expand Up @@ -11,28 +11,6 @@ textarea {
vertical-align: baseline; // Improves appearance and consistency in all browsers
} // button, input, select, textarea

button,
input[type="button"],
input[type="reset"],
input[type="submit"] {
-webkit-appearance: none; // Remove iOS styles
background-color: $color-button-background;
border: none;
border-radius: 0;
color: $color-button-text;
min-height: rem(31);
vertical-align: top;

&:hover {
background-color: $color-button-background-hover;
} // &:hover

&:active,
&:focus {
background-color: $color-button-background-hover;
} // &:active, &:focus
} // button, input[type="button"], input[type="reset"], input[type="submit"]

input[type="checkbox"],
input[type="radio"] {
padding: 0; // Addresses excess padding in IE8/9
Expand Down Expand Up @@ -75,12 +53,12 @@ input[type="datetime"],
input[type="datetime-local"],
input[type="color"],
textarea {
-webkit-appearance: none; // Remove iOS styles
color: $color-input-text;
border: 1px solid $color-input-border;
border: rem(1) solid $color-input-border;
border-radius: 0;
line-height: 1.45;
padding: rem(3) rem(5);
color: $color-input-text;
line-height: 1.5;
padding: $padding-input;
appearance: none;

&:focus {
color: $color-input-focus-text;
Expand Down
1 change: 1 addition & 0 deletions assets/sass/modules/index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
@import "content";
@import "footer";
@import "forms";
@import "buttons";
@import "header";
@import "hero";
@import "icons";
Expand Down
2 changes: 1 addition & 1 deletion assets/sass/utilities/variables/_forms.scss
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ $color-input-border: $color-silver;
$color-input-focus-text: $color-cod-gray;
$color-input-text: $color-dove-gray;

$padding-input: rem(3) rem(5);
$padding-input: rem(6);
102 changes: 63 additions & 39 deletions style.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion style.min.css

Large diffs are not rendered by default.

0 comments on commit ac78ae0

Please sign in to comment.