Skip to content

Commit

Permalink
Use #site-navigation instead of #site-links so that siblings also
Browse files Browse the repository at this point in the history
get the updated outline.

Also remove the `list-group-item` outer selector.  Just make the focused
`.nav-link` have the elevated `z-index` so that the outline doesn't go
under the active link when the `.nav-link` before it is focused in the
siblings..
  • Loading branch information
drgrice1 committed Aug 8, 2023
1 parent e306038 commit 532e633
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 6 deletions.
4 changes: 4 additions & 0 deletions htdocs/themes/math4-yellow/_theme-overrides.scss
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,7 @@ a:not(.btn):focus {
--ww-site-nav-link-active-background-color: #{$primary};
--ww-site-nav-link-active-color: #{color-contrast($primary)};
}

#site-navigation a:not(.btn):focus {
outline-width: 2px;
}
2 changes: 1 addition & 1 deletion htdocs/themes/math4/bootstrap.scss
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ a:not(.btn):focus {
outline-width: 1px;
}

#site-links a:not(.btn):focus {
#site-navigation a:not(.btn):focus {
outline-width: 2px;
}

Expand Down
9 changes: 4 additions & 5 deletions htdocs/themes/math4/math4.scss
Original file line number Diff line number Diff line change
Expand Up @@ -219,11 +219,10 @@ $site-nav-width: 250px !default;

}
}
&.list-group-item {
.nav-link:focus {
position: relative;
z-index: 2;
}

.nav-link:focus {
position: relative;
z-index: 2;
}
}
}
Expand Down

0 comments on commit 532e633

Please sign in to comment.