Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
docs: Update tutorial section on documenting keyboard shortcuts.
Lauryn Menarde860d22d6172
diff --git a/docs/documentation/helpcenter.md b/docs/documentation/helpcenter.mdindex 6d1e9dc3b6a..5c7eb7e8ece 100644--- a/docs/documentation/helpcenter.md+++ b/docs/documentation/helpcenter.md@@ -226,18 +226,19 @@ and used liberally.### Keyboard shortcuts-Use backticks for each keyboard key in the shortcut (e.g. `Enter` or `R`).-For shortcuts with more than one key, add a plus sign (+) surrounded by-spaces in between the keys (e.g. `Ctrl` + `K`, instead of `Ctrl + K` or-`Ctrl`+`K` or `Ctrl` `K`).+Surround each keyboard key in the shortcut with `<kbd>` HTML element start and+end tags (e.g., `<kbd>Enter</kbd>` or `<kbd>R</kbd>`).++For shortcuts with more than one key, add a plus sign (+) surrounded by spaces+in between the keys (e.g., `<kbd>Ctrl</kbd> + <kbd>K</kbd>`). Any shortcut for+an arrow key (↑, ↓, ←, →) will also need the `"arrow-key"` CSS class included+in the `<kbd>` start tag (e.g., ` <kbd class="arrow-key">↑</kbd>`).Use the labels one sees on the actual keyboard rather than the letter theyproduce when pressed (e.g. `R` and `Shift` + `R` rather than `r` and `R`).-**Note**: The existing help center documentation is inconsistent about this-([see this UI redesign issue](https://github.com/zulip/zulip/issues/21753)).-Therefore, if there are already some keyboard shortcuts in the existing help-center article, then it is more important to be consistent with those than-with the global style.+For symbols, such as `?` or `@`, that are produced through key combinations that+change depending on the user's keyboard layout, you should use the symbol as it+appears on a keyboard instead of any specific combination of keys.Use non-Mac keyboard keys; for example `Enter`, instead of `Return`. Zulip willautomatically translate non-Mac keys to the Mac versions for users with a Mac@@ -247,6 +248,13 @@ change `has_mac_keyboard` in `/static/js/common.ts` to always return `True`.Then when you view your documentation changes in the development environment,the keyboard shortcuts should be rendered with Mac keys where appropriate.+If you're adding a tip to an article about a keyboard shortcut, you+should use the more specific keyboard [tip macro](#tips-and-warnings),+`!!! keyboard_tip ""`. In general, all keyboard shortcuts should be+documented on the [keyboard+shortcuts](https://zulip.com/help/keyboard-shortcuts) help center+article.+## Markdown featuresZulip's Markdown processor allows you to include several special features in@@ -380,6 +388,15 @@ users.instructions on how to reset it.```+A **keyboard tip** is a note for users to let them know that the same action+can also be accomplished via a [keyboard shortcut](#keyboard-shortcuts).++```md+!!! keyboard_tip ""++ Use <kbd>D</kbd> to bring up your list of drafts.+```+A **warning** is a note on what happens when there is some kind of problem.Tips are more common than warnings.