Hide keyboard shortcut hint until keyboard is triggered

This commit is contained in:
Lim Chee Aun 2023-02-19 22:07:46 +08:00
parent 91ee0da8ef
commit 6c63fb14b4
2 changed files with 10 additions and 1 deletions

View file

@ -95,7 +95,9 @@ function Shortcuts() {
<span class="menu-grow">
<AsyncText>{title}</AsyncText>
</span>
<span class="menu-shortcut">{i + 1}</span>
<span class="menu-shortcut hide-until-focus-visible">
{i + 1}
</span>
</MenuLink>
);
})}

View file

@ -299,6 +299,13 @@ code {
color: var(--text-insignificant-color);
}
.hide-until-focus-visible {
display: none;
}
:has(:focus-visible) .hide-until-focus-visible {
display: initial;
}
/* KEYFRAMES */
@keyframes appear {