Skip to content

Commit

Permalink
fix: mode toggle not outlined when receiving keyboard focus (cotes202…
Browse files Browse the repository at this point in the history
…0#1690)

The Tab key focus
  • Loading branch information
cotes2020 authored and mill413 committed Apr 21, 2024
1 parent 0fecd50 commit ec5e2a5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion _includes/sidebar.html
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ <h1 class="site-title">

<div class="sidebar-bottom d-flex flex-wrap align-items-center w-100">
{% unless site.theme_mode %}
<button type="button" class="btn" aria-label="Switch Mode" id="mode-toggle">
<button type="button" class="btn btn-link nav-link" aria-label="Switch Mode" id="mode-toggle">
<i class="fas fa-adjust"></i>
</button>

Expand Down
8 changes: 4 additions & 4 deletions _sass/addon/commons.scss
Original file line number Diff line number Diff line change
Expand Up @@ -835,7 +835,10 @@ $btn-mb: 0.5rem;
display: flex;
align-items: center;
justify-content: center;
box-shadow: var(--sidebar-border-color) 0 0 0 1px;

&:not(:focus-visible) {
box-shadow: var(--sidebar-border-color) 0 0 0 1px;
}

&:hover {
background-color: var(--sidebar-hover-bg);
Expand All @@ -857,9 +860,6 @@ $btn-mb: 0.5rem;
}

#mode-toggle {
padding: 0;
border: 0;

@extend %button;
@extend %sidebar-links;
@extend %sidebar-link-hover;
Expand Down

0 comments on commit ec5e2a5

Please sign in to comment.