Skip to content

Commit

Permalink
Improved appearance of details outline
Browse files Browse the repository at this point in the history
  • Loading branch information
squidfunk committed Sep 19, 2021
1 parent 726888c commit 3c352bd
Show file tree
Hide file tree
Showing 8 changed files with 13 additions and 7 deletions.
1 change: 0 additions & 1 deletion material/assets/stylesheets/main.4596ff4f.min.css.map

This file was deleted.

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions material/assets/stylesheets/main.665c42a3.min.css.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion material/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
{% endif %}
{% endblock %}
{% block styles %}
<link rel="stylesheet" href="{{ 'assets/stylesheets/main.4596ff4f.min.css' | url }}">
<link rel="stylesheet" href="{{ 'assets/stylesheets/main.665c42a3.min.css' | url }}">
{% if config.theme.palette %}
{% set palette = config.theme.palette %}
<link rel="stylesheet" href="{{ 'assets/stylesheets/palette.3f5d1f46.min.css' | url }}">
Expand Down
2 changes: 1 addition & 1 deletion src/assets/stylesheets/main/_typeset.scss
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ kbd {
color: var(--md-accent-fg-color);
}

// Text link on keyboard focus
// Show outline for keyboard devices
&.focus-visible {
outline-color: var(--md-accent-fg-color);
outline-offset: px2rem(4px);
Expand Down
6 changes: 6 additions & 0 deletions src/assets/stylesheets/main/extensions/pymdownx/_details.scss
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,12 @@
padding: px2rem(8px) px2rem(44px) px2rem(8px) px2rem(36px);
}

// Show outline for keyboard devices
&.focus-visible {
outline-color: var(--md-accent-fg-color);
outline-offset: px2rem(4px);
}

// Hide outline for pointer devices
&:not(.focus-visible) {
outline: none;
Expand Down
2 changes: 1 addition & 1 deletion src/assets/stylesheets/main/layout/_base.scss
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ body {
display: block;
}

// Show outline for pointer devices
// Show outline for keyboard devices
&.focus-visible + label {
outline-style: auto;
outline-color: var(--md-accent-fg-color);
Expand Down
2 changes: 1 addition & 1 deletion src/assets/stylesheets/main/layout/_nav.scss
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@
color: var(--md-accent-fg-color);
}

// Navigation link on keyboard focus
// Show outline for keyboard devices
&.focus-visible {
outline-color: var(--md-accent-fg-color);
outline-offset: px2rem(4px);
Expand Down

0 comments on commit 3c352bd

Please sign in to comment.