$(document).ready(function() { if (document.getElementById(\"secondFactorForm\") || document.getElementById(\"verifyPhoneForm\")) { var isVerifyPhoneView = document.getElementById(\"smsCode\"); if (isVerifyPhoneView) { $(\"#smsCode\").focus(); } else { $(\"#j_otpcode\").focus(); } } else { var element = $('form :input:visible:not([readonly]):not([disabled]):not(.fn-button--layout):first'); if (element && element.attr(\"id\") !== \"newPasswordInput\") { element.focus(); } }})