You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When describing, in the guide, the keyboard shortcuts that we accept,
let's use the `<kbd>` element. This causes the key to render in a box
that people will recognize as conventional.
The way that this is displayed helps to make it clear that, though we
present the key in uppercase, we actually mean for the lowercase
letter to be entered. Therefore, we present the key in uppercase
since 1) that's how it appears on most keyboards and 2) for some
characters such as `l`, presenting the character in lowercase might be
ambiguous.
We'll spell out "Escape" rather than saying "Esc" (even though many
keyboards spell it that way) since the `KeyboardEvent.keycode`[^1] is
called "Escape", and that's how it would appear in an
`aria-keyshortcuts` attribute[^2].
[^1]: https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/keyCode
[^2]: https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Reference/Attributes/aria-keyshortcuts
Copy file name to clipboardExpand all lines: guide/src/guide/reading.md
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -42,14 +42,14 @@ Tapping the menu bar will scroll the page to the top.
42
42
## Search
43
43
44
44
Each book has a built-in search system.
45
-
Pressing the search icon (<iclass="fa fa-search"></i>) in the menu bar, or pressing the `/` or `S` key on the keyboard will open an input box for entering search terms.
45
+
Pressing the search icon (<iclass="fa fa-search"></i>) in the menu bar, or pressing the <kbd>/</kbd> or <kbd>S</kbd> key on the keyboard will open an input box for entering search terms.
46
46
Typing some terms will show matching chapters and sections in real time.
47
47
48
48
Clicking any of the results will jump to that section.
49
49
The up and down arrow keys can be used to navigate the results, and enter will open the highlighted section.
50
50
51
51
After loading a search result, the matching search terms will be highlighted in the text.
52
-
Clicking a highlighted word or pressing the `Esc` key will remove the highlighting.
52
+
Clicking a highlighted word or pressing the <kbd>Escape</kbd> key will remove the highlighting.
0 commit comments