mirror of https://github.com/aredn/aredn.git
DHCP option focus on firt select (#1421)
This commit is contained in:
parent
5dde2a97ce
commit
c216d7dc34
|
@ -628,7 +628,7 @@ if (f) {
|
||||||
const fc = item.firstChild;
|
const fc = item.firstChild;
|
||||||
htmx.find("#ctrl-modal .dialog .dhcp-options .list").appendChild(fc);
|
htmx.find("#ctrl-modal .dialog .dhcp-options .list").appendChild(fc);
|
||||||
refreshAdvOptions();
|
refreshAdvOptions();
|
||||||
htmx.find(fc, "input").focus();
|
htmx.find(fc, "select").focus();
|
||||||
htmx.on(fc, "keypress", event => {
|
htmx.on(fc, "keypress", event => {
|
||||||
if (event.keyCode === 13 && event.target.nodeName == "INPUT" && htmx.closest(event.target, ".option") === htmx.find(".dhcp-options .list .option:last-child")) {
|
if (event.keyCode === 13 && event.target.nodeName == "INPUT" && htmx.closest(event.target, ".option") === htmx.find(".dhcp-options .list .option:last-child")) {
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
|
|
Loading…
Reference in New Issue