stop settings from stranding a recording and losing its own state

This commit is contained in:
2026-09-21 06:18:50 +03:00
parent c9ee532bd3
commit 371c910068
4 changed files with 27 additions and 7 deletions
+7
View File
@@ -11,6 +11,11 @@
let warnings: string[] = $state([])
async function save() {
const keys = [start, stop, pause].filter(Boolean)
if (new Set(keys).size !== keys.length) {
warnings = ['Multiple actions assigned to the same key - each hotkey must be unique']
return
}
saving = true
warnings = []
try {
@@ -28,6 +33,8 @@
} else {
onDone()
}
} catch (e) {
warnings = [String(e)]
} finally { saving = false }
}