Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Only underline logo on hover (with custom colours) #926

Merged
merged 2 commits into from
Jul 24, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@
can now be overwritten by setting the `assetUrl` variable.
([PR #847](https://github.com/alphagov/govuk-frontend/pull/847))

- Only underline the logo in the header on underline when users have overridden
colours in their browser, rather than it appearing underlined all the time
([PR #926](https://github.com/alphagov/govuk-frontend/pull/926))

🔧 Fixes:

- Replace conflicting `js-hidden` class used within the tabs component with a new modifier class.
Expand Down
8 changes: 5 additions & 3 deletions src/components/header/_header.scss
Original file line number Diff line number Diff line change
Expand Up @@ -101,14 +101,16 @@

&:link,
&:visited {
margin-bottom: -1px; // Negate transparent bottom border
border-bottom: 1px solid transparent;
text-decoration: none;
}

&:hover,
&:active {
border-bottom-color: currentColor;
// Negate the added border
margin-bottom: -1px;
// Omitting colour will use default value of currentColor – if we
// specified currentColor explicitly IE8 would ignore this rule.
border-bottom: 1px solid;
}
}

Expand Down