|
@ -557,13 +557,15 @@ $.fn.modal = function(parameters) { |
|
|
autofocus: function() { |
|
|
autofocus: function() { |
|
|
if(settings.autofocus) { |
|
|
if(settings.autofocus) { |
|
|
var |
|
|
var |
|
|
$inputs = $module.find(':input:visible'), |
|
|
|
|
|
|
|
|
$inputs = $module.filter(':input').filter(':visible'), |
|
|
$autofocus = $inputs.filter('[autofocus]'), |
|
|
$autofocus = $inputs.filter('[autofocus]'), |
|
|
$input = ($autofocus.length > 0) |
|
|
$input = ($autofocus.length > 0) |
|
|
? $autofocus |
|
|
|
|
|
: $inputs |
|
|
|
|
|
|
|
|
? $autofocus.first() |
|
|
|
|
|
: $inputs.first() |
|
|
; |
|
|
; |
|
|
$input.first().focus(); |
|
|
|
|
|
|
|
|
if($input.length > 0) { |
|
|
|
|
|
$input.focus(); |
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
clickaway: function() { |
|
|
clickaway: function() { |
|
@ -832,7 +834,6 @@ $.fn.modal.settings = { |
|
|
|
|
|
|
|
|
queue : false, |
|
|
queue : false, |
|
|
duration : 500, |
|
|
duration : 500, |
|
|
easing : 'easeOutExpo', |
|
|
|
|
|
offset : 0, |
|
|
offset : 0, |
|
|
transition : 'scale', |
|
|
transition : 'scale', |
|
|
|
|
|
|
|
|