Skip to content

Commit 706af28

Browse files
committed
doc: add "Skip to content" button
PR-URL: #56750 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ulises Gascón <ulisesgascongonzalez@gmail.com> Reviewed-By: Claudio Wunder <cwunder@gnome.org>
1 parent 634a6b3 commit 706af28

File tree

2 files changed

+14
-0
lines changed

2 files changed

+14
-0
lines changed

doc/api_assets/style.css

+13
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,19 @@ a.type {
128128
font-size: .9em;
129129
}
130130

131+
.skip-to-content {
132+
position: fixed;
133+
top: -300%;
134+
}
135+
.skip-to-content:focus {
136+
display: block;
137+
top: 0;
138+
left: 0;
139+
background-color: var(--green1);
140+
padding: 1rem;
141+
z-index: 999999;
142+
}
143+
131144
#content {
132145
position: relative;
133146
}

doc/template.html

+1
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
__JS_FLAVORED_DYNAMIC_CSS__
2727
</head>
2828
<body class="alt apidoc" id="api-section-__FILENAME__">
29+
<a href="#apicontent" class="skip-to-content">Skip to content</a>
2930
<div id="content" class="clearfix">
3031
<div role="navigation" id="column2" class="interior">
3132
<div id="intro" class="interior">

0 commit comments

Comments
 (0)