go back to nuking id
disable auto-focus instead of jerking the user's view on every submit.
This commit is contained in:
parent
3fe3be3456
commit
df8c584caa
@ -505,10 +505,7 @@ quickReply = (e) ->
|
|||||||
}
|
}
|
||||||
clone.appendChild(input)
|
clone.appendChild(input)
|
||||||
qr.appendChild(clone)
|
qr.appendChild(clone)
|
||||||
inBefore(document.body.firstChild, qr)
|
document.body.appendChild(qr)
|
||||||
#XXX - put qr first in body, so `Recaptcha.reload()`,
|
|
||||||
# when using document.getElementById, sees and focuses this
|
|
||||||
# instead of the original.
|
|
||||||
|
|
||||||
if e
|
if e
|
||||||
e.preventDefault()
|
e.preventDefault()
|
||||||
@ -746,6 +743,12 @@ if getConfig('Quick Reply')
|
|||||||
quote.addEventListener('click', quickReply, true)
|
quote.addEventListener('click', quickReply, true)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
#hack - nuke id so it doesn't grab focus when reloading
|
||||||
|
console.log 'wat'
|
||||||
|
console.log $('#recaptcha_response_field')
|
||||||
|
$('#recaptcha_response_field').id = ''
|
||||||
|
#$('form[name=post] input[name=recaptcha_response_field]').id = ''
|
||||||
|
|
||||||
|
|
||||||
if getConfig('Quick Report')
|
if getConfig('Quick Report')
|
||||||
callbacks.push((root) ->
|
callbacks.push((root) ->
|
||||||
|
|||||||
@ -547,7 +547,7 @@
|
|||||||
clone.appendChild(input);
|
clone.appendChild(input);
|
||||||
}
|
}
|
||||||
qr.appendChild(clone);
|
qr.appendChild(clone);
|
||||||
inBefore(document.body.firstChild, qr);
|
document.body.appendChild(qr);
|
||||||
}
|
}
|
||||||
if (e) {
|
if (e) {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
@ -825,6 +825,9 @@
|
|||||||
}
|
}
|
||||||
return _result;
|
return _result;
|
||||||
});
|
});
|
||||||
|
console.log('wat');
|
||||||
|
console.log($('#recaptcha_response_field'));
|
||||||
|
$('#recaptcha_response_field').id = '';
|
||||||
}
|
}
|
||||||
if (getConfig('Quick Report')) {
|
if (getConfig('Quick Report')) {
|
||||||
callbacks.push(function(root) {
|
callbacks.push(function(root) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user