mirror of
https://github.com/CharaChorder/DeviceManager.git
synced 2026-01-22 01:42:47 +00:00
feat: enable stricter type checking options
feat: make the app more fault tolerant
This commit is contained in:
@@ -13,11 +13,11 @@ export function csvChordsToJson(csv: string): CharaChordFile {
|
||||
.map((line) => {
|
||||
const [input, output] = line.split(/,(?=[^,]*$)/, 2);
|
||||
return [
|
||||
input
|
||||
input!
|
||||
.split("+")
|
||||
.map((it) => KEYMAP_IDS.get(it.trim())?.code ?? 0)
|
||||
.sort((a, b) => a - b),
|
||||
output
|
||||
output!
|
||||
.trim()
|
||||
.split("")
|
||||
.map((it) => KEYMAP_IDS.get(SPECIAL_KEYS.get(it) ?? it)?.code ?? 0),
|
||||
|
||||
Reference in New Issue
Block a user