(key: string)
| 61 | } |
| 62 | |
| 63 | function parseKey(key: string): { key: string; type: string } { |
| 64 | let regexMatch = key.match(KeyTypeCodeRegex); |
| 65 | if (regexMatch != null && regexMatch.length > 1) { |
| 66 | let code = regexMatch[1]; |
| 67 | return { key: code, type: KeyTypeCode }; |
| 68 | } else if (regexMatch != null) { |
| 69 | console.log("error: regexMatch is not null yet there is no captured group: ", regexMatch, key); |
| 70 | } |
| 71 | return { key: key, type: KeyTypeKey }; |
| 72 | } |
| 73 | |
| 74 | function parseKeyDescription(keyDescription: string): KeyPressDecl { |
| 75 | let rtn = { key: "", mods: {} } as KeyPressDecl; |
no outgoing calls
no test coverage detected