Skip to content

Commit 9dd42e1

Browse files
mdopatrickhlauke
andauthoredFeb 14, 2023
Attempt to fix focus ring being cut off in table of contents (#37965)
* Attempt to fix focus ring being cut off in table of contents * Update _toc.scss --------- Co-authored-by: Patrick H. Lauke <redux@splintered.co.uk>
1 parent d0fece9 commit 9dd42e1

File tree

3 files changed

+7
-13
lines changed

3 files changed

+7
-13
lines changed
 

‎site/assets/scss/_toc.scss

+3-9
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// stylelint-disable selector-max-type, selector-no-qualifying-type, selector-max-compound-selectors
1+
// stylelint-disable selector-max-type, selector-no-qualifying-type
22

33
.bd-toc {
44
@include media-breakpoint-up(lg) {
@@ -16,22 +16,16 @@
1616
ul {
1717
padding-left: 0;
1818
margin-bottom: 0;
19-
margin-left: -.75rem;
2019
list-style: none;
2120

2221
ul {
2322
padding-left: 1rem;
24-
margin-left: -1rem;
25-
26-
a {
27-
padding-left: 1.375rem;
28-
}
2923
}
3024
}
3125

3226
a {
3327
display: block;
34-
padding: .125rem 0 .125rem .625rem;
28+
padding: .125rem 0 .125rem .75rem;
3529
color: inherit;
3630
text-decoration: none;
3731
border-left: .125rem solid transparent;
@@ -86,7 +80,7 @@
8680
.bd-toc-collapse {
8781
@include media-breakpoint-down(md) {
8882
nav {
89-
padding: 1.25rem;
83+
padding: 1.25rem 1.25rem 1.25rem 1rem;
9084
background-color: var(--bs-tertiary-bg);
9185
border: 1px solid var(--bs-border-color);
9286
@include border-radius(var(--bs-border-radius));

‎site/content/docs/5.3/getting-started/introduction.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ Bootstrap requires the use of the HTML5 doctype. Without it, you'll see some fun
119119
</html>
120120
```
121121

122-
### Responsive meta tag
122+
### Viewport meta
123123

124124
Bootstrap is developed *mobile first*, a strategy in which we optimize code for mobile devices first and then scale up components as necessary using CSS media queries. To ensure proper rendering and touch zooming for all devices, add the responsive viewport meta tag to your `<head>`.
125125

‎site/layouts/_default/docs.html

+3-3
Original file line numberDiff line numberDiff line change
@@ -32,13 +32,13 @@ <h1 class="bd-title mb-0" id="content">{{ .Title | markdownify }}</h1>
3232
</div>
3333

3434
{{ if (eq .Page.Params.toc true) }}
35-
<div class="bd-toc mt-3 mb-5 my-lg-0 ps-xl-3 mb-lg-5 text-body-secondary">
35+
<div class="bd-toc mt-3 mb-5 my-lg-0 mb-lg-5 px-sm-1 text-body-secondary">
3636
<button class="btn btn-link p-md-0 mb-2 mb-md-0 text-decoration-none bd-toc-toggle d-md-none" type="button" data-bs-toggle="collapse" data-bs-target="#tocContents" aria-expanded="false" aria-controls="tocContents">
3737
On this page
3838
<svg class="bi d-md-none ms-2" aria-hidden="true"><use xlink:href="#chevron-expand"></use></svg>
3939
</button>
40-
<strong class="d-none d-md-block h6 my-2">On this page</strong>
41-
<hr class="d-none d-md-block my-2">
40+
<strong class="d-none d-md-block h6 my-2 ms-3">On this page</strong>
41+
<hr class="d-none d-md-block my-2 ms-3">
4242
<div class="collapse bd-toc-collapse" id="tocContents">
4343
{{ .TableOfContents }}
4444
</div>

0 commit comments

Comments
 (0)
Please sign in to comment.