Skip to content

Commit

Permalink
Update tabs component to WCAG 2.1 compliant focus style
Browse files Browse the repository at this point in the history
Iterates on #1245
  • Loading branch information
hannalaakso committed May 9, 2019
1 parent 608d2c5 commit 9476898
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions src/components/tabs/_tabs.scss
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,11 @@
color: govuk-colour("black");
background-color: govuk-colour("light-grey", $legacy: "grey-4");
text-align: center;
text-decoration: none;
text-decoration: underline;

&:hover {
box-shadow: inset 0 4px 0 0 govuk-colour("light-blue");
}

&--selected {
margin-top: - govuk-spacing(1);
Expand All @@ -96,13 +100,18 @@
padding-bottom: govuk-spacing(3) + 1px;
padding-left: govuk-spacing(4) - 1px;

border: 1px solid $govuk-border-colour;
border-bottom: 0;
border-top: 1px solid transparent;
border-right: 1px solid $govuk-border-colour;
border-bottom: 1px solid transparent;
border-left: 1px solid $govuk-border-colour;

color: govuk-colour("black");
background-color: govuk-colour("white");
box-shadow: inset 0 4px 0 0 govuk-colour("blue");
text-decoration: none;

&:focus {
background-color: transparent;
box-shadow: inset 0 4px 0 0 govuk-colour("yellow"), inset 0 8px 0 0 govuk-colour("black");
}
}
}
Expand Down

0 comments on commit 9476898

Please sign in to comment.