// login : tabindex + ux
This commit is contained in:
1 parent
c68101653d
commit
cd5a308ad7
2 files changed
+38
-17
No files matched your search
+14
@@ -52,8 +52,22 @@ $(document).ready(function() {
|
||||
e.preventDefault();
|
||||
displayLogin();
|
||||
});
|
||||
|
||||
//Tab-index loop
|
||||
$('form').each(function(){
|
||||
var list = $(this).find('*[tabindex]').sort(function(a,b){ return a.tabIndex < b.tabIndex ? -1 : 1; }),
|
||||
first = list.first();
|
||||
list.last().on('keydown', function(e){
|
||||
if( e.keyCode === 9 ) {
|
||||
first.focus();
|
||||
return false;
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
|
||||
function displayForgotPassword() {
|
||||
$('#error').hide();
|
||||
$('#login_form').fadeOut('fast', function () {
|
||||
|
||||
Reference in new issue
Block a user