Remove hidden .site-nav from accessibility tree (#615)

This commit is contained in:
2023-03-01 14:13:02 +08:00 committed by GitHub
parent eb743c3b0f
commit dcc5868438
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -226,7 +226,9 @@ site-nav-hide-by-default() {
--scroll-height: 0; --scroll-height: 0;
height: 0; height: 0;
overflow: hidden; overflow: hidden;
transition: height $transition-ease; transition: $transition-ease;
transition-property: height, visibility;
visibility: hidden;
body:not(.site-nav-on) & .animated { body:not(.site-nav-on) & .animated {
animation: none; animation: none;
@ -234,6 +236,7 @@ site-nav-hide-by-default() {
body.site-nav-on & { body.site-nav-on & {
height: var(--scroll-height); height: var(--scroll-height);
visibility: unset;
} }
} }