-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.html
526 lines (440 loc) · 23.6 KB
/
index.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
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<!--=============== Favicon ===============-->
<link rel="shortcut icon" href="assets/img/favicon.png" type="image/png">
<!--=============== Boxicons ===============-->
<link href='https://unpkg.com/boxicons@2.1.2/css/boxicons.min.css' rel='stylesheet'>
<!--=============== CSS ===============-->
<link rel="stylesheet" href="assets/css/styles.css">
<title>Urbanway</title>
</head>
<body>
<header class="header" id="header">
<nav class="nav container">
<a href="index.html"><img src="assets/img/logo1.png" class="logo"></a>
<div class="nav__menu" id="nav-menu">
<ul class="nav__list">
<li class="nav__item">
<a href="index.html" class="nav__link active-link">Home</a>
</li>
<li class="nav__item">
<a href="schedule.html" class="nav__link">Schedules</a>
</li>
<li class="nav__item">
<a href="About Us.html" class="nav__link">About Us</a>
</li>
</ul>
<i class='bx bx-x nav__close' id="nav-close"></i>
</div>
<div class="action">
<div class="profile" onclick="menuToggle();">
<img src="assets/img/user2.png" alt="user">
</div>
<div class="menu">
<h3 id="name" class="usersname"> </h3>
<h5 id="user" class="usersmail"> </h5>
<ul>
<li> <i class='bx bx-user-circle' class="usermenu_item"></i> <a href="dashboard.html">My Profile</a></i></li>
<li> <i class='bx bx-history' class="usermenu_item"></i> <a href="dashboard.html">History</a></i></li>
<li> <i class='bx bx-cog' class="usermenu_item"></i> <a href="dashboard.html">Settings</a></i></li>
<li id="signout"> <i class='bx bx-exit' class="usermenu_item"></i> <a href="#">Log-Out</a></i></li>
</ul>
</div>
</div>
<div class="loginButton">
<a href="login.html" class="login-btn">Login</a>
</div>
<div class="nav__toggle" id="nav-toggle">
<i class='bx bx-menu'></i>
</div>
</nav>
</header>
<main class="main">
<!--==================== HOME ====================-->
<section class="home" id="home">
<img src="assets/img/hero2.jpg" alt="" class="home__img">
<div class="home__container container grid">
<div class="home__data">
<span class="home__data-subtitle">Revolutionize your travel experience</span>
<h1 class="home__data-title"> Effortless Booking <br> and <b> Scheduling <br> for Everyone </b></h1>
<a href="login.html" class="button" id="booknow-btn">Book Now!</a>
</div>
<div class="home__info">
<div>
<span class="home__info-title">Popular destinations in Sri Lanka</span>
<a href="#place" class="button button--flex button--link home__info-button">
More <i class='bx bx-right-arrow-alt bx-fade-left' ></i>
</a>
</div>
<div class="home__info-overlay">
<img src="assets/img/home2.jpg" alt="" class="home__info-img">
</div>
</div>
</div>
</section>
<!--==================== ABOUT ====================-->
<section class="about section" id="about">
<div class="about__container container grid">
<div class="about__data">
<h2 class="section__title about__title">Book Your <br> Journey Now!</h2>
<p class="about__description">Skip the line, and explore a world of seamless ticket booking, finding the best schedules and securing your seats in just a few clicks.
</p>
<a href="schedule.html" class="button">View schedules</a>
</div>
<div class="about__img">
<div class="about__img-overlay">
<img src="assets/img/schedules.jpg" alt="" class="about__img-one">
</div>
</div>
</div>
</section>
<!--==================== TESTIMONIAL ====================-->
<section class="testimonial section" id="testimonial">
<h2 class="section__title">Compare Prices and <br> Optimize Your Travel </h2>
<div class="subscribe__bg">
<div class="subscribe__container container">
<h2 class="section__title subscribe__title"> "UrbanWay turned my daily commute <br> into a piece of cake! <br> Their friendly user interface made ticket booking a breeze.” </h2>
<p class="subscribe__description"> - Sahan Madushka </p>
</div>
</div>
</section>
<!--==================== EXPERIENCE ====================-->
<section class="experience section">
<h2 class="section__title">More About Us!</h2>
<div class="experience__container container grid">
<div class="experience__content grid">
<div class="experience__data">
<h2 class="experience__number">5</h2>
<span class="experience__description">Years <br> Experience</span>
</div>
<div class="experience__data">
<h2 class="experience__number">1000+</h2>
<span class="experience__description">Destinations</span>
</div>
<div class="experience__data">
<h2 class="experience__number">1M+</h2>
<span class="experience__description">Users</span>
</div>
</div>
<div class="experience__img grid">
<div class="experience__overlay">
<img src="assets/img/exp.jpg" alt="" class="experience__img-one">
</div>
</div>
</div>
</section>
<!--==================== PLACES ====================-->
<section class="place section" id="place">
<h2 class="section__title">Popular Destinations</h2>
<div class="place__container container grid">
<!--==================== PLACES CARD 1 ====================-->
<div class="place__card">
<img src="assets/img/dest1.jpg" alt="" class="place__img">
<div class="place__content">
<span class="place__rating">
<i class='bx bxs-star place__rating-icon' ></i>
<span class="place__rating-number">5.0</span>
</span>
<div class="place__data">
<h3 class="place__title">Colombo</h3>
</div>
</div>
<button class="button button--flex place__button">
<a href="https://en.wikipedia.org/wiki/Colombo" target="_blank" >
<i class='bx bxs-chevron-right rightbtn__icon' ></i>
</a>
</button>
</div>
<!--==================== PLACES CARD 2 ====================-->
<div class="place__card">
<img src="assets/img/dest2.jpg" alt="" class="place__img">
<div class="place__content">
<span class="place__rating">
<i class='bx bxs-star place__rating-icon' ></i>
<span class="place__rating-number">5.0</span>
</span>
<div class="place__data">
<h3 class="place__title">Kandy</h3>
</div>
</div>
<button class="button button--flex place__button">
<a href="https://en.wikipedia.org/wiki/Kandy" target="_blank" >
<i class='bx bxs-chevron-right rightbtn__icon' ></i>
</a>
</button>
</div>
<!--==================== PLACES CARD 3 ====================-->
<div class="place__card">
<img src="assets/img/dest3.jpg" alt="" class="place__img">
<div class="place__content">
<span class="place__rating">
<i class='bx bxs-star place__rating-icon' ></i>
<span class="place__rating-number">4.9</span>
</span>
<div class="place__data">
<h3 class="place__title">Galle</h3>
</div>
</div>
<button class="button button--flex place__button">
<a href="https://en.wikipedia.org/wiki/Galle" target="_blank" >
<i class='bx bxs-chevron-right rightbtn__icon' ></i>
</a>
</button>
</div>
<!--==================== PLACES CARD 4 ====================-->
<div class="place__card">
<img src="assets/img/dest4.jpg" alt="" class="place__img">
<div class="place__content">
<span class="place__rating">
<i class='bx bxs-star place__rating-icon' ></i>
<span class="place__rating-number">4.9</span>
</span>
<div class="place__data">
<h3 class="place__title">Nuwara<br>Eliya</h3>
</div>
</div>
<button class="button button--flex place__button">
<a href="https://en.wikipedia.org/wiki/Nuwara_Eliya" target="_blank" >
<i class='bx bxs-chevron-right rightbtn__icon' ></i>
</a>
</button>
</div>
<!--==================== PLACES CARD 5 ====================-->
<div class="place__card">
<img src="assets/img/dest5.jpg" alt="" class="place__img">
<div class="place__content">
<span class="place__rating">
<i class='bx bxs-star place__rating-icon' ></i>
<span class="place__rating-number">4.8</span>
</span>
<div class="place__data">
<h3 class="place__title">Trinco<br>malee</h3>
</div>
</div>
<button class="button button--flex place__button">
<a href="https://en.wikipedia.org/wiki/Trincomalee" target="_blank" >
<i class='bx bxs-chevron-right rightbtn__icon' ></i>
</a>
</button>
</div>
<!--==================== PLACES CARD 6 ====================-->
<div class="place__card">
<img src="assets/img/dest6.jpg" alt="" class="place__img">
<div class="place__content">
<span class="place__rating">
<i class='bx bxs-star place__rating-icon' ></i>
<span class="place__rating-number">4.8</span>
</span>
<div class="place__data">
<h3 class="place__title">Negombo</h3>
</div>
</div>
<button class="button button--flex place__button">
<a href="https://en.wikipedia.org/wiki/Negombo" target="_blank" >
<i class='bx bxs-chevron-right rightbtn__icon' ></i>
</a>
</button>
</div>
</div>
</section>
<!--==================== SUBSCRIBE ====================-->
<section class="subscribe section">
<div class="subscribe__bg">
<div class="subscribe__container container">
<h2 class="section__title subscribe__title">Keep In Touch <br> With Us!</h2>
<p class="subscribe__description">Subscribe to our newsletter for
updates, helpful tips, and
exclusive offers.
</p>
<form action="" class="subscribe__form">
<input type="text" placeholder="Enter your email." class="subscribe__input">
<button class="button">
Subscribe
</button>
</form>
</div>
</div>
</section>
<!--==================== SPONSORS ====================-->
<section class="sponsor section">
<h2 class="section__title">Our Partners</h2><br><br>
<div class="sponsor__container container grid">
<div class="sponsor__content">
<img src="assets/img/sponsorsnew1.png" alt="" class="sponsor__img">
</div>
<div class="sponsor__content">
<img src="assets/img/sponsorsnew2.png" alt="" class="sponsor__img">
</div>
<div class="sponsor__content">
<img src="assets/img/sponsorsnew3.png" alt="" class="sponsor__img">
</div>
<div class="sponsor__content">
<img src="assets/img/sponsorsnew4.png" alt="" class="sponsor__img">
</div>
<div class="sponsor__content">
<img src="assets/img/sponsorsnew5.png" alt="" class="sponsor__img">
</div>
</div>
</section>
</main>
<!--==================== FOOTER ====================-->
<footer class="footer section">
<div class="footer__container container grid">
<div class="footer__content grid">
<div class="footer__data">
<h3 class="footer__title">Urbanway</h3>
<p class="footer__description">Wave goodbye to <br> tedious ticket counters and
embrace the future with <br> UrbanWay!
</p>
<div>
<a href="https://www.facebook.com/" target="_blank" class="footer__social">
<i class='bx bxl-facebook-circle' ></i>
</a>
<a href="https://twitter.com/" target="_blank" class="footer__social">
<i class='bx bxl-twitter' ></i>
</a>
<a href="https://www.instagram.com/" target="_blank" class="footer__social">
<i class='bx bxl-instagram'></i>
</a>
<a href="https://www.youtube.com/" target="_blank" class="footer__social">
<i class='bx bxl-youtube' ></i>
</a>
</div>
</div>
<div class="footer__data">
<h3 class="footer__subtitle">About</h3>
<ul>
<li class="footer__item">
<a href="oops.html" class="footer__link">About Us</a>
</li>
<li class="footer__item">
<a href="oops.html" class="footer__link">Features</a>
</li>
<li class="footer__item">
<a href="oops.html" class="footer__link">News & Blog</a>
</li>
</ul>
</div>
<div class="footer__data">
<h3 class="footer__subtitle">Company</h3>
<ul>
<li class="footer__item">
<a href="oops.html" class="footer__link">Team</a>
</li>
<li class="footer__item">
<a href="oops.html" class="footer__link">Plan Pricing</a>
</li>
<li class="footer__item">
<a href="oops.html" class="footer__link">Become a member</a>
</li>
</ul>
</div>
<div class="footer__data">
<h3 class="footer__subtitle">Support</h3>
<ul>
<li class="footer__item">
<a href="oops.html" class="footer__link">FAQs</a>
</li>
<li class="footer__item">
<a href="oops.html" class="footer__link">Support Center</a>
</li>
<li class="footer__item">
<a href="oops.html" class="footer__link">Contact Us</a>
</li>
</ul>
</div>
</div>
<div class="footer__rights">
<b><p class="footer__copy">© Team 5 - Sahan Tashiya Gihan Abishek Inura Layan. ICT 142-3 Group Project</p></b>
<div class="footer__terms">
<a href="oops.html" class="footer__terms-link">Terms of Service</a>
<a href="oops.html" class="footer__terms-link">Privacy Policy</a>
</div>
</div>
</div>
</footer>
<!--========== SCROLL UP ==========-->
<a href="#" class="scrollup" id="scroll-up">
<i class='bx bxs-chevron-up bx-fade-up scrollup__icon' ></i>
</a>
<!--=============== SCROLL REVEAL===============-->
<script src="assets/js/scrollreveal.js"></script>
<!--=============== MAIN JS ===============-->
<script src="assets/js/main.js"></script>
<script>
function menuToggle(){
const toggleMenu = document.querySelector('.menu');
toggleMenu.classList.toggle('active')
}
</script>
<script type="module">
// Import the functions you need from the SDKs you need
import { initializeApp } from "https://www.gstatic.com/firebasejs/10.5.0/firebase-app.js";
import { getDatabase, set, ref, update } from "https://www.gstatic.com/firebasejs/10.5.0/firebase-database.js";
import {
getAuth,
createUserWithEmailAndPassword,
signInWithEmailAndPassword,
onAuthStateChanged,
signOut
} from "https://www.gstatic.com/firebasejs/10.5.0/firebase-auth.js";
// TODO: Add SDKs for Firebase products that you want to use
// https://firebase.google.com/docs/web/setup#available-libraries
// Your web app's Firebase configuration
const firebaseConfig = {
apiKey: "AIzaSyABwQpzIJhk5vkNbdC_FazG8FpMyVVfjrA",
authDomain: "urbanway-e1936.firebaseapp.com",
projectId: "urbanway-e1936",
storageBucket: "urbanway-e1936.appspot.com",
messagingSenderId: "957989416352",
appId: "1:957989416352:web:7176885570c30084dc48c5"
};
// Initialize Firebase
const app = initializeApp(firebaseConfig);
const database = getDatabase(app);
const auth = getAuth();
const secretContent = document.querySelector(".action");
const loginButton = document.querySelector(".login-btn");
secretContent.style.display = "none";
auth.onAuthStateChanged(function(user) {
if(user) {
var email = user.email
var users = document.getElementById("user")
var text = document.createTextNode(email)
users.appendChild(text)
}
})
auth.onAuthStateChanged(function(user) {
if (user) {
const email = user.email;
const username = email.split('@')[0];
const nameElement = document.getElementById('name');
if (nameElement) {
nameElement.innerText = username;
}
}
})
const checkAuthState = async() => {
auth.onAuthStateChanged(function(user) {
if(user) {
secretContent.style.display = "block";
loginButton.style.display = "none";
} else {
secretContent.style.display = "none";
loginButton.style.display = "block";
}
})
}
let signOutButton = document.getElementById("signout")
signOutButton.addEventListener("click", (e) => {
e.preventDefault()
auth.signOut()
window.location = "index.html"
})
checkAuthState();
</script>
</body>
</html>