(hotkey: Hotkey | (string & {}))
| 136 | * ``` |
| 137 | */ |
| 138 | export function assertValidHotkey(hotkey: Hotkey | (string & {})): void { |
| 139 | const result = validateHotkey(hotkey) |
| 140 | if (!result.valid) { |
| 141 | throw new Error(`Invalid hotkey '${hotkey}': ${result.errors.join(', ')}`) |
| 142 | } |
| 143 | } |
| 144 | |
| 145 | /** |
| 146 | * Validates a hotkey and logs warnings to the console. |
no test coverage detected
searching dependent graphs…