mirror of
https://gh.wpcy.net/https://github.com/discourse/discourse.git
synced 2026-05-22 17:41:55 +08:00
* Apply these rules to the display of all keyboard shortcuts in the app: * No shortcuts show a + between keys * On Windows and Linux, show Ctrl and Alt words, but show ⇧ for Shift * On macOS, show ⌃ for Control, ⌘ for Command, ⌥ for Option, and ⇧ for Shift * Use capital letters for the shortcut keys, e.g. Ctrl+S instead of Ctrl+s * Add a filter to the keyboard shortcut help modal to allow searching * Add aria-keyshortcuts attributes to the keyboard shortcuts in the composer toolbar and popup menu options * Adds Ctrl+Enter + Esc shortcuts for composer --------- Co-authored-by: Renato Atilio <renato@discourse.org>
11 lines
385 B
JavaScript
Vendored
11 lines
385 B
JavaScript
Vendored
import Controller from "@ember/controller";
|
|
import { PLATFORM_KEY_MODIFIER } from "discourse/lib/keyboard-shortcuts";
|
|
import { translateModKey } from "discourse/lib/utilities";
|
|
|
|
export default class AdminSearchIndexController extends Controller {
|
|
queryParams = ["filter"];
|
|
|
|
get shortcutHTML() {
|
|
return `<kbd>${translateModKey(PLATFORM_KEY_MODIFIER)}</kbd> <kbd>/</kbd>`;
|
|
}
|
|
}
|