Fix default focus behaviour

This commit is contained in:
Florine W. Dekker 2020-06-07 13:08:22 +02:00
parent 1a52c71ae2
commit 15dff54300
Signed by: FWDekker
GPG Key ID: B1B567AF58D6EE0F
1 changed files with 3 additions and 1 deletions

View File

@ -123,8 +123,10 @@ doAfterLoad(async () => {
});
checkButton.addEventListener("click", () => submit());
urlInput.input.focus() // Default focus
// Read inputs from cookies
if (Cookies.get("api-url") !== undefined) {
if (Cookies.get("api-url") || "" !== "") {
urlInput.setValue(Cookies.get("api-url"));
articleInput.input.focus();
}