mirror of
https://github.com/twbs/bootstrap.git
synced 2025-08-22 21:22:52 +02:00
v5/docs: reintroduce outline
for docs code samples, buttons when :not(:focus-visible)
(#36507)
* Remove outline suppression for focused `<pre>` Sighted keyboard users rely on knowing where their focus is. If the `<pre>` receives focus (so that it can be scrolled by keyboard users, for instance) then it's essential that they know this is the case * Only suppress outline for buttons when `:not(:focus-visible)` * Add right-hand margin to pre avoids having the focus outline awkwardly clipped by the copy button
This commit is contained in:
@@ -320,15 +320,11 @@
|
||||
pre {
|
||||
padding: 0;
|
||||
margin-top: .625rem;
|
||||
margin-right: 1.875rem;
|
||||
margin-bottom: .625rem;
|
||||
white-space: pre;
|
||||
background-color: transparent;
|
||||
border: 0;
|
||||
|
||||
// Undo tabindex that's automatically added by Hugo
|
||||
&:focus {
|
||||
outline: 0;
|
||||
}
|
||||
}
|
||||
|
||||
pre code {
|
||||
|
Reference in New Issue
Block a user