Add minimum duration option

This commit is contained in:
Lartza
2020-01-24 01:02:23 +02:00
parent 2b7f940669
commit e6ef27936e
6 changed files with 51 additions and 3 deletions

View File

@@ -68,6 +68,20 @@ async function init() {
break;
case "display":
updateDisplayElement(optionsElements[i])
break;
case "number-change":
let numberChangeOption = optionsElements[i].getAttribute("sync-option");
let configValue = SB.config[numberChangeOption];
let numberInput = optionsElements[i].querySelector("input");
if (configValue != undefined) {
numberInput.value = configValue;
}
numberInput.addEventListener("input", () => {
SB.config[numberChangeOption] = numberInput.value;
});
}
}