mirror of
https://github.com/twbs/bootstrap.git
synced 2025-08-26 06:44:35 +02:00
docs(skippy): prevent skip links from overlapping header
This commit is contained in:
@@ -1,3 +1,8 @@
|
|||||||
<a class="skippy sr-only sr-only-focusable" href="#content">
|
<div class="skippy overflow-hidden">
|
||||||
<span class="skippy-text">Skip to main content</span>
|
<div class="container-xl">
|
||||||
</a>
|
<a class="sr-only sr-only-focusable d-inline-flex p-2 m-1" href="#content">Skip to main content</a>
|
||||||
|
{%- if page.layout == "docs" -%}
|
||||||
|
<a class="sr-only sr-only-focusable d-none d-md-inline-flex p-2 m-1" href="#bd-docs-nav">Skip to docs navigation</a>
|
||||||
|
{%- endif -%}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
@@ -1,17 +1,20 @@
|
|||||||
|
// stylelint-disable declaration-no-important
|
||||||
|
|
||||||
.skippy {
|
.skippy {
|
||||||
display: block;
|
|
||||||
padding: 1em;
|
|
||||||
color: $white;
|
|
||||||
text-align: center;
|
|
||||||
background-color: $bd-purple;
|
background-color: $bd-purple;
|
||||||
outline: 0;
|
|
||||||
|
|
||||||
@include hover() {
|
a {
|
||||||
color: $white;
|
color: $white;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
.skippy-text {
|
&:focus-within a {
|
||||||
padding: .5em;
|
position: static !important;
|
||||||
outline: 1px dotted;
|
width: auto !important;
|
||||||
|
height: auto !important;
|
||||||
|
padding: $spacer / 2 !important;
|
||||||
|
margin: $spacer / 4 !important;
|
||||||
|
overflow: visible !important;
|
||||||
|
clip: auto !important;
|
||||||
|
white-space: normal !important;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user