From 34e6b2e7cad19a2345328323fd81ac477e13e7eb Mon Sep 17 00:00:00 2001 From: Byron Jones Date: Wed, 2 Sep 2015 13:12:55 +0800 Subject: Bug 1200618 - Layout of the TOTP 2FA leads to missing the token time window and thus frustration --- js/account.js | 6 ++-- skins/standard/admin.css | 7 +++++ template/en/default/account/prefs/mfa.html.tmpl | 42 ++++++++++++++++--------- 3 files changed, 38 insertions(+), 17 deletions(-) diff --git a/js/account.js b/js/account.js index c287309d8..d68c3f550 100644 --- a/js/account.js +++ b/js/account.js @@ -80,7 +80,7 @@ $(function() { iframe.find('#qr').attr('src', 'data:image/png;base64,' + data.png); iframe.find('#secret').text(data.secret32); $('#mfa-totp-issued').show(); - $('#mfa-totp-enable-code').focus(); + $('#mfa-password').focus(); $('#update').attr('disabled', false); }) .error(function(data) { @@ -100,8 +100,8 @@ $(function() { event.preventDefault(); $('#mfa-disable-container').show(); $('#mfa-confirm').show(); - $('#mfa-api-blurb').hide(); - $('#mfa-totp-disable-code').focus(); + $('.mfa-api-blurb').hide(); + $('#mfa-password').focus(); $('#update').attr('disabled', false); $(this).hide(); }); diff --git a/skins/standard/admin.css b/skins/standard/admin.css index e45865490..44b474b8f 100644 --- a/skins/standard/admin.css +++ b/skins/standard/admin.css @@ -273,3 +273,10 @@ input[disabled] { background: none; padding: 0; } + +label.mfa-totp { + display: inline-block; + width: 155px; + text-align: right; + font-weight: bold; +} diff --git a/template/en/default/account/prefs/mfa.html.tmpl b/template/en/default/account/prefs/mfa.html.tmpl index dcf480d9f..a94cb77b8 100644 --- a/template/en/default/account/prefs/mfa.html.tmpl +++ b/template/en/default/account/prefs/mfa.html.tmpl @@ -36,9 +36,20 @@ -

+

[% INCLUDE api_key_pref_blurb %]

@@ -68,17 +79,25 @@ [%# TOTP %]