Seowoong-Chang commited on
Commit
3ff1432
1 Parent(s): cde396a

Upload 4 files

Browse files
Files changed (4) hide show
  1. index.html +193 -0
  2. signedin.html +192 -0
  3. signin.html +126 -0
  4. signup.html +129 -0
index.html ADDED
@@ -0,0 +1,193 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>Book Reading Streak Tracker</title>
7
+ <style>
8
+ body {
9
+ font-family: 'Helvetica Neue', Arial, sans-serif;
10
+ text-align: center;
11
+ margin: 0;
12
+ padding: 0;
13
+ background: url('https://source.unsplash.com/1920x1080/?book') no-repeat center center fixed;
14
+ background-size: cover;
15
+ color: white;
16
+ }
17
+ header {
18
+ background-color: rgba(0, 0, 0, 0.7);
19
+ padding: 10px 20px;
20
+ position: fixed;
21
+ width: 100%;
22
+ top: 0;
23
+ z-index: 1000;
24
+ }
25
+ #container {
26
+ background: rgba(255, 255, 255, 0.7);
27
+ padding: 20px;
28
+ border-radius: 10px;
29
+ margin-top: 60px;
30
+ }
31
+ h1 {
32
+ color: #333;
33
+ }
34
+ p {
35
+ color: #555;
36
+ }
37
+ button {
38
+ padding: 10px 20px;
39
+ font-size: 16px;
40
+ cursor: pointer;
41
+ margin: 10px;
42
+ background-color: #007bff;
43
+ color: #fff;
44
+ border: none;
45
+ border-radius: 5px;
46
+ position: relative;
47
+ }
48
+ #streak {
49
+ font-size: 24px;
50
+ font-weight: bold;
51
+ color: #007bff;
52
+ }
53
+ .notification-bar {
54
+ position: fixed;
55
+ bottom: 0;
56
+ left: 0;
57
+ width: 100%;
58
+ background-color: rgba(0, 0, 0, 0.7);
59
+ color: white;
60
+ padding: 15px;
61
+ text-align: center;
62
+ display: none;
63
+ }
64
+ .menu-icon {
65
+ display: none;
66
+ cursor: pointer;
67
+ font-size: 24px;
68
+ color: #fff;
69
+ position: absolute;
70
+ top: 15px;
71
+ left: 20px;
72
+ }
73
+ .menu-options {
74
+ display: flex;
75
+ justify-content: center;
76
+ align-items: center;
77
+ height: 100vh;
78
+ position: fixed;
79
+ top: 0;
80
+ left: 0;
81
+ width: 100%;
82
+ background-color: rgba(0, 0, 0, 0.7);
83
+ z-index: 100;
84
+ flex-direction: column;
85
+ transform: translateY(-100%);
86
+ transition: transform 0.3s ease-in-out;
87
+ }
88
+ .menu-option {
89
+ margin: 20px;
90
+ font-size: 18px;
91
+ color: #fff;
92
+ cursor: pointer;
93
+ }
94
+
95
+ div.scrollmenu {
96
+ background-color: #333;
97
+ overflow: auto;
98
+ white-space: nowrap;
99
+ }
100
+
101
+ div.scrollmenu a {
102
+ display: inline-block;
103
+ color: white;
104
+ text-align: center;
105
+ padding: 14px;
106
+ text-decoration: none;
107
+ }
108
+
109
+ div.scrollmenu a:hover {
110
+ background-color: #777;
111
+ }
112
+ </style>
113
+ </head>
114
+ <body>
115
+
116
+
117
+ <div class="scrollmenu">
118
+ <a href="index.html">Home</a>
119
+ <a href="signup.html">Sign Up</a>
120
+ <a href="signin.html">Sign In</a>
121
+ <a href="#about">About</a>
122
+ <a href="#support">Support</a>
123
+ </div>
124
+
125
+ <div id="container">
126
+ <h1>Book Reading Streak Tracker</h1>
127
+ <p>Track your daily reading streak by clicking the button below:</p>
128
+
129
+ <button onclick="updateStreak()">Read a Book Today</button>
130
+ <button onclick="deleteStreak()">Delete Streak</button>
131
+ <p>Your current streak: <span id="streak">1</span> days</p>
132
+ </div>
133
+
134
+ <div class="notification-bar">
135
+ This website uses cookies to save your reading streak data. By using this site, you agree to our use of cookies.
136
+ </div>
137
+
138
+ <script>
139
+ // Function to update the reading streak
140
+ function updateStreak() {
141
+ let lastClickDate = localStorage.getItem('lastClickDate');
142
+ let currentDate = new Date().toLocaleDateString();
143
+
144
+ if (lastClickDate !== currentDate) {
145
+ let currentStreak = parseInt(document.getElementById('streak').innerText);
146
+ currentStreak++;
147
+ document.getElementById('streak').innerText = currentStreak;
148
+
149
+ // Update the last click date in local storage
150
+ localStorage.setItem('lastClickDate', currentDate);
151
+
152
+ // Show notification
153
+ showNotification();
154
+ } else {
155
+ alert('You already clicked the button today. Come back tomorrow!');
156
+ }
157
+ }
158
+
159
+ // Function to delete the last streak
160
+ function deleteStreak() {
161
+ let lastClickDate = localStorage.getItem('lastClickDate');
162
+ let currentDate = new Date().toLocaleDateString();
163
+
164
+ if (lastClickDate === currentDate) {
165
+ // If the button was clicked today, update the streak
166
+ let currentStreak = parseInt(document.getElementById('streak').innerText);
167
+ currentStreak = Math.max(1, currentStreak - 1); // Ensure streak is not less than 1
168
+ document.getElementById('streak').innerText = currentStreak;
169
+
170
+ // Clear the last click date in local storage
171
+ localStorage.removeItem('lastClickDate');
172
+ } else {
173
+ alert('No streak to delete for today.');
174
+ }
175
+ }
176
+
177
+ // Function to show notification
178
+ function showNotification() {
179
+ document.querySelector('.notification-bar').style.display = 'block';
180
+ setTimeout(function() {
181
+ document.querySelector('.notification-bar').style.display = 'none';
182
+ }, 5000);
183
+ }
184
+
185
+ // Function to toggle menu options
186
+ function toggleMenu() {
187
+ const menuOptions = document.querySelector('.menu-options');
188
+ menuOptions.style.transform = menuOptions.style.transform === 'translateY(0)' ? 'translateY(-100%)' : 'translateY(0)';
189
+ }
190
+ </script>
191
+
192
+ </body>
193
+ </html>
signedin.html ADDED
@@ -0,0 +1,192 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>Book Reading Streak Tracker</title>
7
+ <style>
8
+ body {
9
+ font-family: 'Helvetica Neue', Arial, sans-serif;
10
+ text-align: center;
11
+ margin: 0;
12
+ padding: 0;
13
+ background: url('https://source.unsplash.com/1920x1080/?book') no-repeat center center fixed;
14
+ background-size: cover;
15
+ color: white;
16
+ }
17
+ header {
18
+ background-color: rgba(0, 0, 0, 0.7);
19
+ padding: 10px 20px;
20
+ position: fixed;
21
+ width: 100%;
22
+ top: 0;
23
+ z-index: 1000;
24
+ }
25
+ #container {
26
+ background: rgba(255, 255, 255, 0.7);
27
+ padding: 20px;
28
+ border-radius: 10px;
29
+ margin-top: 60px;
30
+ }
31
+ h1 {
32
+ color: #333;
33
+ }
34
+ p {
35
+ color: #555;
36
+ }
37
+ button {
38
+ padding: 10px 20px;
39
+ font-size: 16px;
40
+ cursor: pointer;
41
+ margin: 10px;
42
+ background-color: #007bff;
43
+ color: #fff;
44
+ border: none;
45
+ border-radius: 5px;
46
+ position: relative;
47
+ }
48
+ #streak {
49
+ font-size: 24px;
50
+ font-weight: bold;
51
+ color: #007bff;
52
+ }
53
+ .notification-bar {
54
+ position: fixed;
55
+ bottom: 0;
56
+ left: 0;
57
+ width: 100%;
58
+ background-color: rgba(0, 0, 0, 0.7);
59
+ color: white;
60
+ padding: 15px;
61
+ text-align: center;
62
+ display: none;
63
+ }
64
+ .menu-icon {
65
+ display: none;
66
+ cursor: pointer;
67
+ font-size: 24px;
68
+ color: #fff;
69
+ position: absolute;
70
+ top: 15px;
71
+ left: 20px;
72
+ }
73
+ .menu-options {
74
+ display: flex;
75
+ justify-content: center;
76
+ align-items: center;
77
+ height: 100vh;
78
+ position: fixed;
79
+ top: 0;
80
+ left: 0;
81
+ width: 100%;
82
+ background-color: rgba(0, 0, 0, 0.7);
83
+ z-index: 100;
84
+ flex-direction: column;
85
+ transform: translateY(-100%);
86
+ transition: transform 0.3s ease-in-out;
87
+ }
88
+ .menu-option {
89
+ margin: 20px;
90
+ font-size: 18px;
91
+ color: #fff;
92
+ cursor: pointer;
93
+ }
94
+
95
+ div.scrollmenu {
96
+ background-color: #333;
97
+ overflow: auto;
98
+ white-space: nowrap;
99
+ }
100
+
101
+ div.scrollmenu a {
102
+ display: inline-block;
103
+ color: white;
104
+ text-align: center;
105
+ padding: 14px;
106
+ text-decoration: none;
107
+ }
108
+
109
+ div.scrollmenu a:hover {
110
+ background-color: #777;
111
+ }
112
+ </style>
113
+ </head>
114
+ <body>
115
+
116
+
117
+ <div class="scrollmenu">
118
+ <a href="index.html">Home</a>
119
+ <a href="index.html">Sign Out</a>
120
+ <a href="#about">About</a>
121
+ <a href="#support">Support</a>
122
+ </div>
123
+
124
+ <div id="container">
125
+ <h1>Book Reading Streak Tracker</h1>
126
+ <p>Track your daily reading streak by clicking the button below:</p>
127
+
128
+ <button onclick="updateStreak()">Read a Book Today</button>
129
+ <button onclick="deleteStreak()">Delete Streak</button>
130
+ <p>Your current streak: <span id="streak">1</span> days</p>
131
+ </div>
132
+
133
+ <div class="notification-bar">
134
+ This website uses cookies to save your reading streak data. By using this site, you agree to our use of cookies.
135
+ </div>
136
+
137
+ <script>
138
+ // Function to update the reading streak
139
+ function updateStreak() {
140
+ let lastClickDate = localStorage.getItem('lastClickDate');
141
+ let currentDate = new Date().toLocaleDateString();
142
+
143
+ if (lastClickDate !== currentDate) {
144
+ let currentStreak = parseInt(document.getElementById('streak').innerText);
145
+ currentStreak++;
146
+ document.getElementById('streak').innerText = currentStreak;
147
+
148
+ // Update the last click date in local storage
149
+ localStorage.setItem('lastClickDate', currentDate);
150
+
151
+ // Show notification
152
+ showNotification();
153
+ } else {
154
+ alert('You already clicked the button today. Come back tomorrow!');
155
+ }
156
+ }
157
+
158
+ // Function to delete the last streak
159
+ function deleteStreak() {
160
+ let lastClickDate = localStorage.getItem('lastClickDate');
161
+ let currentDate = new Date().toLocaleDateString();
162
+
163
+ if (lastClickDate === currentDate) {
164
+ // If the button was clicked today, update the streak
165
+ let currentStreak = parseInt(document.getElementById('streak').innerText);
166
+ currentStreak = Math.max(1, currentStreak - 1); // Ensure streak is not less than 1
167
+ document.getElementById('streak').innerText = currentStreak;
168
+
169
+ // Clear the last click date in local storage
170
+ localStorage.removeItem('lastClickDate');
171
+ } else {
172
+ alert('No streak to delete for today.');
173
+ }
174
+ }
175
+
176
+ // Function to show notification
177
+ function showNotification() {
178
+ document.querySelector('.notification-bar').style.display = 'block';
179
+ setTimeout(function() {
180
+ document.querySelector('.notification-bar').style.display = 'none';
181
+ }, 5000);
182
+ }
183
+
184
+ // Function to toggle menu options
185
+ function toggleMenu() {
186
+ const menuOptions = document.querySelector('.menu-options');
187
+ menuOptions.style.transform = menuOptions.style.transform === 'translateY(0)' ? 'translateY(-100%)' : 'translateY(0)';
188
+ }
189
+ </script>
190
+
191
+ </body>
192
+ </html>
signin.html ADDED
@@ -0,0 +1,126 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>Sign Up - Book Reading Streak Tracker</title>
7
+ <style>
8
+ body {
9
+ font-family: 'Helvetica Neue', Arial, sans-serif;
10
+ text-align: center;
11
+ margin: 0;
12
+ padding: 0;
13
+ background: url('https://source.unsplash.com/1920x1080/?book') no-repeat center center fixed;
14
+ background-size: cover;
15
+ color: white;
16
+ }
17
+ header {
18
+ background-color: rgba(0, 0, 0, 0.7);
19
+ padding: 10px 20px;
20
+ position: fixed;
21
+ width: 100%;
22
+ top: 0;
23
+ z-index: 1000;
24
+ }
25
+ #container {
26
+ background: rgba(255, 255, 255, 0.7);
27
+ padding: 20px;
28
+ border-radius: 10px;
29
+ margin-top: 60px;
30
+ }
31
+ h1 {
32
+ color: #333;
33
+ }
34
+ form {
35
+ display: flex;
36
+ flex-direction: column;
37
+ align-items: center;
38
+ }
39
+ label {
40
+ color: #333;
41
+ font-size: 18px;
42
+ margin-top: 10px;
43
+ }
44
+ input {
45
+ padding: 10px;
46
+ margin: 5px;
47
+ width: 100%;
48
+ box-sizing: border-box;
49
+ }
50
+ button {
51
+ padding: 10px 20px;
52
+ font-size: 16px;
53
+ cursor: pointer;
54
+ margin: 10px;
55
+ background-color: #007bff;
56
+ color: #fff;
57
+ border: none;
58
+ border-radius: 5px;
59
+ width: 100%;
60
+ }
61
+
62
+ div.scrollmenu {
63
+ background-color: #333;
64
+ overflow: auto;
65
+ white-space: nowrap;
66
+ }
67
+
68
+ div.scrollmenu a {
69
+ display: inline-block;
70
+ color: white;
71
+ text-align: center;
72
+ padding: 14px;
73
+ text-decoration: none;
74
+ }
75
+
76
+ div.scrollmenu a:hover {
77
+ background-color: #777;
78
+ }
79
+ </style>
80
+ </head>
81
+ <body>
82
+
83
+
84
+ <div class="scrollmenu">
85
+ <a href="index.html">Home</a>
86
+ <a href="signup.html">Sign Up</a>
87
+ <a href="signup.html">Sign In</a>
88
+ <a href="#about">About</a>
89
+ <a href="#support">Support</a>
90
+ </div>
91
+
92
+ <div id="container">
93
+ <h1>Sign Up</h1>
94
+ <form>
95
+ <label for="username">Username:</label>
96
+ <input type="text" id="username" name="username" required>
97
+
98
+ <label for="password">Password:</label>
99
+ <input type="password" id="password" name="password" required>
100
+
101
+ <a type="submit" onclick="showNotification()" href="signedin.html">Sign Up</a>
102
+ </form>
103
+ </div>
104
+
105
+ <div class="notification-bar">
106
+ This website uses cookies to save your reading streak data. By using this site, you agree to our use of cookies.
107
+ </div>
108
+
109
+ <script>
110
+ // Function to show notification
111
+ function showNotification() {
112
+ document.querySelector('.notification-bar').style.display = 'block';
113
+ setTimeout(function() {
114
+ document.querySelector('.notification-bar').style.display = 'none';
115
+ }, 5000);
116
+ }
117
+
118
+ // Function to toggle menu options
119
+ function toggleMenu() {
120
+ const menuOptions = document.querySelector('.menu-options');
121
+ menuOptions.style.transform = menuOptions.style.transform === 'translateY(0)' ? 'translateY(-100%)' : 'translateY(0)';
122
+ }
123
+ </script>
124
+
125
+ </body>
126
+ </html>
signup.html ADDED
@@ -0,0 +1,129 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>Sign Up - Book Reading Streak Tracker</title>
7
+ <style>
8
+ body {
9
+ font-family: 'Helvetica Neue', Arial, sans-serif;
10
+ text-align: center;
11
+ margin: 0;
12
+ padding: 0;
13
+ background: url('https://source.unsplash.com/1920x1080/?book') no-repeat center center fixed;
14
+ background-size: cover;
15
+ color: white;
16
+ }
17
+ header {
18
+ background-color: rgba(0, 0, 0, 0.7);
19
+ padding: 10px 20px;
20
+ position: fixed;
21
+ width: 100%;
22
+ top: 0;
23
+ z-index: 1000;
24
+ }
25
+ #container {
26
+ background: rgba(255, 255, 255, 0.7);
27
+ padding: 20px;
28
+ border-radius: 10px;
29
+ margin-top: 60px;
30
+ }
31
+ h1 {
32
+ color: #333;
33
+ }
34
+ form {
35
+ display: flex;
36
+ flex-direction: column;
37
+ align-items: center;
38
+ }
39
+ label {
40
+ color: #333;
41
+ font-size: 18px;
42
+ margin-top: 10px;
43
+ }
44
+ input {
45
+ padding: 10px;
46
+ margin: 5px;
47
+ width: 100%;
48
+ box-sizing: border-box;
49
+ }
50
+ button {
51
+ padding: 10px 20px;
52
+ font-size: 16px;
53
+ cursor: pointer;
54
+ margin: 10px;
55
+ background-color: #007bff;
56
+ color: #fff;
57
+ border: none;
58
+ border-radius: 5px;
59
+ width: 100%;
60
+ }
61
+
62
+ div.scrollmenu {
63
+ background-color: #333;
64
+ overflow: auto;
65
+ white-space: nowrap;
66
+ }
67
+
68
+ div.scrollmenu a {
69
+ display: inline-block;
70
+ color: white;
71
+ text-align: center;
72
+ padding: 14px;
73
+ text-decoration: none;
74
+ }
75
+
76
+ div.scrollmenu a:hover {
77
+ background-color: #777;
78
+ }
79
+ </style>
80
+ </head>
81
+ <body>
82
+
83
+
84
+ <div class="scrollmenu">
85
+ <a href="signedin.html">Home</a>
86
+ <a href="signup.html">Sign Up</a>
87
+ <a href="signin.html">Sign In</a>
88
+ <a href="#about">About</a>
89
+ <a href="#support">Support</a>
90
+ </div>
91
+
92
+ <div id="container">
93
+ <h1>Sign Up</h1>
94
+ <form>
95
+ <label for="username">Username:</label>
96
+ <input type="text" id="username" name="username" required>
97
+
98
+ <label for="email">Email:</label>
99
+ <input type="email" id="email" name="email" required>
100
+
101
+ <label for="password">Password:</label>
102
+ <input type="password" id="password" name="password" required>
103
+
104
+ <a type="submit" onclick="showNotification()" href="signedin.html">Sign Up</a>
105
+ </form>
106
+ </div>
107
+
108
+ <div class="notification-bar">
109
+ This website uses cookies to save your reading streak data. By using this site, you agree to our use of cookies.
110
+ </div>
111
+
112
+ <script>
113
+ // Function to show notification
114
+ function showNotification() {
115
+ document.querySelector('.notification-bar').style.display = 'block';
116
+ setTimeout(function() {
117
+ document.querySelector('.notification-bar').style.display = 'none';
118
+ }, 5000);
119
+ }
120
+
121
+ // Function to toggle menu options
122
+ function toggleMenu() {
123
+ const menuOptions = document.querySelector('.menu-options');
124
+ menuOptions.style.transform = menuOptions.style.transform === 'translateY(0)' ? 'translateY(-100%)' : 'translateY(0)';
125
+ }
126
+ </script>
127
+
128
+ </body>
129
+ </html>