MCPcopy
hub / github.com/github/hotkey / normalizeHotkey

Function normalizeHotkey

src/hotkey.ts:82–87  ·  view source on GitHub ↗
(hotkey: string, platform?: string | undefined)

Source from the content-addressed store, hash-verified

80 * @returns {string} normalized representation of the given hotkey string
81 */
82export function normalizeHotkey(hotkey: string, platform?: string | undefined): NormalizedHotkeyString {
83 let result: string
84 result = localizeMod(hotkey, platform)
85 result = sortModifiers(result)
86 return result as NormalizedHotkeyString
87}
88
89const matchApplePlatform = /Mac|iPod|iPhone|iPad/i
90

Callers 3

normalizeSequenceFunction · 0.85
expandHotkeyToEdgesFunction · 0.85

Calls 2

localizeModFunction · 0.85
sortModifiersFunction · 0.85

Tested by

no test coverage detected