Skip to content

Commit

Permalink
Fix focus state for links containing inline code
Browse files Browse the repository at this point in the history
Inheriting the background from the link means that the code block ends up with its own yellow background, which then clips the box-shadow used to give the focused link a black underline.

Rather than inherit the yellow background, set the background to transparent. The focused link still has its own yellow background which can be seen ‘through’ the transparent code element.
  • Loading branch information
36degrees committed Jul 9, 2021
1 parent 209d85a commit bffd69d
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@
}

a:focus code {
background: inherit;
background: transparent;
color: inherit;
}

Expand Down

0 comments on commit bffd69d

Please sign in to comment.