1
0
mirror of https://github.com/vrana/adminer.git synced 2025-08-30 01:30:12 +02:00

Fix highlighting default submit button in indexes form

This commit is contained in:
Peter Knut
2024-11-03 00:13:27 +01:00
parent d165cd9aec
commit 9eeeca6b0e

View File

@@ -1128,10 +1128,12 @@ function inputBlur() {
}
}
/** Find submit button used by Enter
* @param HTMLElement
* @return HTMLInputElement
*/
/**
* Finds submit button used by Enter.
*
* @param {HTMLElement} el
* @return {HTMLInputElement}
*/
function findDefaultSubmit(el) {
if (el.jushTextarea) {
el = el.jushTextarea;
@@ -1139,10 +1141,10 @@ function findDefaultSubmit(el) {
if (!el.form) {
return null;
}
var inputs = qsa('input', el.form);
for (var i = 0; i < inputs.length; i++) {
var input = inputs[i];
if (input.type === 'submit' && !input.style.zIndex) {
const inputs = qsa('input', el.form);
for (const input of inputs) {
if (input.type === 'submit' && !input.classList.contains("wayoff") && !input.style.zIndex) {
return input;
}
}