diff --git a/core/src/main/java/hudson/Functions.java b/core/src/main/java/hudson/Functions.java index c12d1846181e..86d9e9c55d29 100644 --- a/core/src/main/java/hudson/Functions.java +++ b/core/src/main/java/hudson/Functions.java @@ -2475,6 +2475,10 @@ public static String generateItemId() { return String.valueOf(Math.floor(Math.random() * 3000)); } + /** + * @param keyboardShortcut the shortcut to be translated + * @return the translated shortcut, e.g. CMD+K -> ⌘+K for macOS, CTRL+K for Windows + */ @Restricted(NoExternalUse.class) public static String translateModifierKeysForUsersPlatform(String keyboardShortcut) { StaplerRequest currentRequest = Stapler.getCurrentRequest(); diff --git a/core/src/main/resources/lib/layout/keyboard-shortcut.jelly b/core/src/main/resources/lib/layout/keyboard-shortcut.jelly index 92bbf4a59470..56dfa40c128e 100644 --- a/core/src/main/resources/lib/layout/keyboard-shortcut.jelly +++ b/core/src/main/resources/lib/layout/keyboard-shortcut.jelly @@ -32,11 +32,11 @@ THE SOFTWARE. Optional suffix to the shortcut Displays a keyboard shortcut chip based on the component's body. - CMD/CTRL will automatically be translated to the user's operating system's appropriate variant. + CMD will automatically be translated to the user's operating system's appropriate variant.