# HG changeset patch # User Dan # Date 1249429081 14400 # Node ID 294bab0bb3e21fdddb35082bb5c277fa27232665 # Parent 7cd9707ed72f2ad36edfcc5f191cb2f714336181 Added cancel button to interface; reverted animation to straight sweep effect instead of spread-from-center diff -r 7cd9707ed72f -r 294bab0bb3e2 plugins/Yubikey.php --- a/plugins/Yubikey.php Tue Aug 04 19:37:38 2009 -0400 +++ b/plugins/Yubikey.php Tue Aug 04 19:38:01 2009 -0400 @@ -91,7 +91,7 @@ }, yubiauth: { msg_please_touch_key: 'Please touch your Yubikey', - msg_close_instructions: 'Press Esc to cancel', + msg_close_instructions: 'or press Esc', msg_invalid_chars: 'OTP contains invalid characters', msg_too_long: 'OTP is too long', msg_validating_otp: 'Validating OTP...', diff -r 7cd9707ed72f -r 294bab0bb3e2 plugins/yubikey/yubikey.css --- a/plugins/yubikey/yubikey.css Tue Aug 04 19:37:38 2009 -0400 +++ b/plugins/yubikey/yubikey.css Tue Aug 04 19:38:01 2009 -0400 @@ -48,7 +48,7 @@ height: 88px; background-image: url(./field.png); background-repeat: no-repeat; - background-position: -44px -88px; + background-position: 0px -88px; } div.yubikey_bar > img.yubikey_bar_error { diff -r 7cd9707ed72f -r 294bab0bb3e2 plugins/yubikey/yubikey.js --- a/plugins/yubikey/yubikey.js Tue Aug 04 19:37:38 2009 -0400 +++ b/plugins/yubikey/yubikey.js Tue Aug 04 19:38:01 2009 -0400 @@ -34,7 +34,7 @@ mp.style.textAlign = 'center'; mp.innerHTML = '

' + $lang.get('yubiauth_msg_please_touch_key') + '

'; var progress = document.createElement('div'); - $(progress).addClass('yubikey_bar'); + $(progress).addClass('yubikey_bar').css('text-align', 'left'); var progimg = document.createElement('img'); progimg.src = cdnPath + '/images/spacer.gif'; progress.appendChild(progimg); @@ -47,6 +47,7 @@ .css('color', '#fff') .css('font-size', '1px') .css('padding', '0') + .css('opacity', '0') .attr('size', '1') .keyup(function(e) { @@ -69,7 +70,7 @@ { $('div.yubikey_bar > img', this.parentNode) .css('width', String(this.value.length * 2) + 'px') - .css('background-position', String((this.value.length > 44 ? 44 : this.value.length) - 44) + 'px -88px'); + //.css('background-position', String((this.value.length > 44 ? 44 : this.value.length) - 44) + 'px -88px'); } e.preventDefault(); e.stopPropagation(); @@ -84,7 +85,10 @@ }, 750); var info = document.createElement('p'); $(info) - .html($lang.get('yubiauth_msg_close_instructions')) + .append('' + $lang.get('yubiauth_msg_close_instructions') + '  ') + .append('' + $lang.get('etc_cancel') + '  ') + //.append('
') + .append('' + $lang.get('yubiauth_msg_close_instructions') + '') .css('margin-top', '0'); mp.appendChild(info); }