2014-01-07 18:36:44 +00:00
|
|
|
extends ../layout
|
2013-11-16 18:24:06 +00:00
|
|
|
block content
|
2016-01-12 00:25:20 +00:00
|
|
|
.text-center
|
2014-11-30 23:23:12 +00:00
|
|
|
h2 Sign in with one of these options:
|
2016-01-20 20:23:09 +00:00
|
|
|
a.btn.btn-lg.btn-block.btn-social.btn-github(href='/auth/github')
|
2015-08-01 15:38:42 +00:00
|
|
|
i.fa.fa-github
|
2016-04-04 20:50:07 +00:00
|
|
|
| Sign in with GitHub
|
2016-01-20 20:23:09 +00:00
|
|
|
a.btn.btn-lg.btn-block.btn-social.btn-facebook(href='/auth/facebook')
|
2015-04-22 11:40:25 +00:00
|
|
|
i.fa.fa-facebook
|
|
|
|
| Sign in with Facebook
|
2016-04-04 20:36:35 +00:00
|
|
|
a.btn.btn-lg.btn-block.btn-social.btn-google(href='/auth/google')
|
|
|
|
i.fa.fa-google
|
2015-08-01 15:38:42 +00:00
|
|
|
| Sign in with Google
|
2016-01-20 20:23:09 +00:00
|
|
|
a.btn.btn-lg.btn-block.btn-social.btn-linkedin(href='/auth/linkedin')
|
2015-04-22 11:40:25 +00:00
|
|
|
i.fa.fa-linkedin
|
|
|
|
| Sign in with LinkedIn
|
2016-01-20 20:23:09 +00:00
|
|
|
a.btn.btn-lg.btn-block.btn-social.btn-twitter(href='/auth/twitter')
|
2015-09-10 02:55:23 +00:00
|
|
|
i.fa.fa-twitter
|
|
|
|
| Sign in with Twitter
|
2014-11-30 06:22:27 +00:00
|
|
|
br
|
2015-08-18 06:57:38 +00:00
|
|
|
p
|
|
|
|
a(href="/email-signup") Or sign up using your email address here.
|
|
|
|
p
|
2015-09-10 02:55:23 +00:00
|
|
|
a(href="/email-signin") If you originally signed up using your email address, you can sign in here.
|
2015-09-23 16:56:01 +00:00
|
|
|
|
2016-01-20 20:23:09 +00:00
|
|
|
script.
|
|
|
|
$(document).ready(function() {
|
|
|
|
var method = localStorage.getItem('lastSigninMethod'),
|
|
|
|
btnSelector = 'a.btn.btn-lg.btn-block.btn-social';
|
|
|
|
if (method) {
|
|
|
|
try {
|
|
|
|
var obj = JSON.parse(method);
|
|
|
|
} catch(e) {
|
|
|
|
console.error('Invalid sign in object stored', method);
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
$.each($(btnSelector), function(i, item) {
|
|
|
|
if (
|
|
|
|
$(item).attr('href') === obj.methodLink &&
|
|
|
|
$(item).hasClass(obj.methodClass)
|
|
|
|
) {
|
|
|
|
$(item).addClass('active');
|
|
|
|
$(item).attr('title', 'This is your last signin method');
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
|
|
|
$(btnSelector).click(function() {
|
|
|
|
var obj = {};
|
|
|
|
$(this).removeClass('active');
|
|
|
|
obj.methodClass = $(this).attr('class').split(' ').pop();
|
|
|
|
obj.methodLink = $(this).attr('href');
|
|
|
|
localStorage.setItem('lastSigninMethod', JSON.stringify(obj));
|
|
|
|
});
|
|
|
|
});
|