()
| 13 | }; |
| 14 | |
| 15 | export const getRegisteredKeys = () => { |
| 16 | const keymaps = getDecoratedKeymaps(); |
| 17 | |
| 18 | return Object.keys(keymaps).reduce((result: Record<string, string>, actionName) => { |
| 19 | const commandKeys = keymaps[actionName]; |
| 20 | commandKeys.forEach((shortcut) => { |
| 21 | result[shortcut] = actionName; |
| 22 | }); |
| 23 | return result; |
| 24 | }, {}); |
| 25 | }; |
| 26 | |
| 27 | export const registerCommandHandlers = (cmds: typeof commands) => { |
| 28 | if (!cmds) { |
no test coverage detected