-
Notifications
You must be signed in to change notification settings - Fork 0
/
landingpage.html
78 lines (68 loc) · 3.12 KB
/
landingpage.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
<!doctype.html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="description" content="Improve your foreign language skills by chatting with native speakers your age.">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<span class="notranslate"><title>World Without Borders</title></span>
<!-- Disable tap highlight on IE -->
<meta name="msapplication-tap-highlight" content="no">
<!-- Web Application Manifest -->
<link rel="manifest" href="manifest.json">
<!-- Add to homescreen for Chrome on Android -->
<meta name="mobile-web-app-capable" content="yes">
<meta name="application-name" content="World Without Borders">
<meta name="theme-color" content="#303F9F">
<!-- Add to homescreen for Safari on iOS -->
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
<meta name="apple-mobile-web-app-title" content="World Without Borders">
<meta name="apple-mobile-web-app-status-bar-style" content="#303F9F">
<!-- Tile icon for Win8 -->
<meta name="msapplication-TileColor" content="#3372DF">
<meta name="msapplication-navbutton-color" content="#303F9F">
<!-- Compiled and minified CSS -->
<script type="text/javascript" src="https://code.jquery.com/jquery-2.1.1.min.js"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.98.0/css/materialize.min.css">
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
<!-- Compiled and minified JavaScript -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.98.0/js/materialize.min.js"></script>
<link rel="stylesheet" type="text/css" href="styles/landingpage.css">
</head>
<body>
<img class="www-logo responsive-img" src="images/base_transparent.png" width="200px", height="200px"></img>
<h2 id="title">World Without Borders</h2>
<h5 id="slogan">Penpals for the 21st century.</h5>
<a class="btn red lighten-1 waves-light waves-effect" href=# id="get-started">Sign In</a>
<!--Firebase-->
<script src="https://www.gstatic.com/firebasejs/3.6.9/firebase.js"></script>
<script>
// Initialize Firebase
var config = {
apiKey: "AIzaSyCx-2_5IcfXswoDZhjle1rPS3m-ryi3rpM",
authDomain: "penpalapp-6020c.firebaseapp.com",
databaseURL: "https://penpalapp-6020c.firebaseio.com",
storageBucket: "penpalapp-6020c.appspot.com",
messagingSenderId: "322094641122"
};
firebase.initializeApp(config);
var auth = firebase.auth();
var authStateKnown;
var btnClicked = false;
auth.onAuthStateChanged(function (user) {
authStateKnown = true;
if (btnClicked) {
window.location.href = auth.currentUser === null ? 'login.html' : 'account-info-sync.html';
}
});
var btn = document.getElementById('get-started');
btn.addEventListener('click', function () {
btnClicked = true;
if (authStateKnown) {
window.location.href = auth.currentUser === null ? 'login.html' : 'account-info-sync.html';
}
});
</script>
</body>
</html>