Register link in the login page

pull/1/head
yflory 6 years ago
parent 2031d535d7
commit d76c21fcf5

@ -30,7 +30,8 @@ define([
UI.createCheckbox('import-recent', Msg.register_importRecent), UI.createCheckbox('import-recent', Msg.register_importRecent),
]), ]),
h('div.extra', [ h('div.extra', [
h('button.login.first.btn', Msg.login_login) h('button.login.first.btn', Msg.login_login),
h('button#register.first.btn', Msg.login_register)
]) ])
]) ])
]), ]),

@ -61,6 +61,16 @@
transform: scale(1.05); transform: scale(1.05);
} }
} }
#register {
border-color: @cryptpad_color_blue;
background: #fff;
color: @cryptpad_color_blue;
padding: 10px;
border-radius: 0;
&:hover {
transform: scale(1.05);
}
}
} }
} }
.cp-container { .cp-container {

@ -71,9 +71,6 @@ define([
if ($uname.val()) { if ($uname.val()) {
sessionStorage.login_user = $uname.val(); sessionStorage.login_user = $uname.val();
} }
if ($passwd.val()) {
sessionStorage.login_pass = $passwd.val();
}
} }
window.location.href = '/register/'; window.location.href = '/register/';
}); });

@ -38,11 +38,9 @@ define([
var $confirm = $('#password-confirm'); var $confirm = $('#password-confirm');
if (sessionStorage.login_user) { if (sessionStorage.login_user) {
delete sessionStorage.login_user;
$uname.val(sessionStorage.login_user); $uname.val(sessionStorage.login_user);
} }
if (sessionStorage.login_pass) {
$passwd.val(sessionStorage.login_pass);
}
[ $uname, $passwd, $confirm] [ $uname, $passwd, $confirm]
.some(function ($el) { if (!$el.val()) { $el.focus(); return true; } }); .some(function ($el) { if (!$el.val()) { $el.focus(); return true; } });

Loading…
Cancel
Save