Skip to content

Commit

Permalink
Removes the need to force outline to be transparent
Browse files Browse the repository at this point in the history
  • Loading branch information
aliuk2012 committed May 9, 2019
1 parent ec74375 commit deb144c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/components/button/_button.scss
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@
padding: (govuk-spacing(2) - $govuk-border-width-form-element - ($button-shadow-size / 2)) govuk-spacing(2); // s1
border: $govuk-border-width-form-element solid transparent;
border-radius: 0;
outline: $govuk-focus-width solid transparent !important;
color: $govuk-button-text-colour;
background-color: $govuk-button-colour;
box-shadow: 0 $button-shadow-size 0 $govuk-button-shadow-colour; // s0
Expand Down Expand Up @@ -71,6 +70,7 @@
// text when focussed.
@include govuk-compatibility(govuk_template) {
&:link:focus {
outline-color: transparent;
color: $govuk-button-text-colour;
}
}
Expand All @@ -84,13 +84,13 @@
// Ordering of this pseudo selector is important to ensure
// It replaces hover state when element is focussed and mouse is hovering
&:hover {
color: govuk-colour("white");
background-color: $govuk-button-hover-colour;
}

// Ordering of this pseudo selector is important to ensure
// It replaces hover state when element is focussed and mouse is hovering
&:focus {
outline-color: transparent;
color: govuk-colour("black");
background-color: govuk-colour("yellow");
box-shadow: 0 2px 0 govuk-colour("black");
Expand Down

0 comments on commit deb144c

Please sign in to comment.