mirror of
https://github.com/billz/raspap-webgui.git
synced 2025-12-26 23:26:47 +01:00
Auto-populate DNS field when gateway loses focus
This commit is contained in:
@@ -99,6 +99,15 @@ document.addEventListener('DOMContentLoaded', function() {
|
||||
bridgeInputs.forEach(input => input.removeAttribute('required'));
|
||||
}
|
||||
});
|
||||
|
||||
// auto-populate DNS when gateway loses focus
|
||||
gatewayInput.addEventListener('blur', function() {
|
||||
const gatewayVal = this.value.trim();
|
||||
if (gatewayVal !== '' && dnsInput.value.trim() === '') {
|
||||
dnsInput.value = gatewayVal;
|
||||
}
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user