-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathhome.html
More file actions
235 lines (231 loc) · 7.43 KB
/
home.html
File metadata and controls
235 lines (231 loc) · 7.43 KB
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link
href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/css/bootstrap.min.css"
rel="stylesheet"
integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC"
crossorigin="anonymous"
/>
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
<link rel="stylesheet" href="./style.css" />
<title>Firebase Auth</title>
</head>
<body>
<nav class="navbar navbar-expand-lg navbar-dark bg-dark">
<div class="container-fluid">
<a class="navbar-brand" href="#">
<img
src="https://getbootstrap.com/docs/5.0/assets/brand/bootstrap-logo.svg"
alt=""
width="30"
height="24"
class="d-inline-block align-text-top"
/>
Bootstrap
</a>
<button
class="navbar-toggler"
type="button"
data-bs-toggle="collapse"
data-bs-target="#navbarNavDropdown"
aria-controls="navbarNavDropdown"
aria-expanded="false"
aria-label="Toggle navigation"
>
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarNavDropdown">
<ul class="navbar-nav">
<li class="nav-item">
<a class="nav-link active" aria-current="page" href="#">Home</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">Features</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">Pricing</a>
</li>
<li class="nav-item dropdown">
<a
class="nav-link dropdown-toggle"
href="#"
id="navbarDropdownMenuLink"
role="button"
data-bs-toggle="dropdown"
aria-expanded="false"
>
Dropdown link
</a>
<ul
class="dropdown-menu"
aria-labelledby="navbarDropdownMenuLink"
>
<li><a class="dropdown-item" href="#">Action</a></li>
<li><a class="dropdown-item" href="#">Another action</a></li>
<li>
<a class="dropdown-item" href="#">Something else here</a>
</li>
</ul>
</li>
</ul>
<form class="d-flex" style="margin-left: auto">
<a
class="btn btn-success"
href="#"
style="margin-right: 10px"
data-bs-toggle="modal"
data-bs-target="#loginModal"
id="ButtonLogin"
>
Sign In
</a>
<a
class="btn btn-primary"
href="#"
data-bs-toggle="modal"
data-bs-target="#registerModal"
id="ButtonRegister"
>
Sign up
</a>
<a style="margin: auto; color: white; display: none;" id="userEmail"
></a
>
<a
class="btn btn-primary"
href="#"
style="display: none; margin-left: 10px;"
id="ButtonLogout"
>
Logout
</a>
</form>
</div>
</div>
</nav>
<!-- Login Modal -->
<div
class="modal fade"
id="loginModal"
tabindex="-1"
aria-labelledby="exampleModalLabel"
aria-hidden="true"
>
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="exampleModalLabel">เข้าสู่ระบบ</h5>
<button
type="button"
class="btn-close"
data-bs-dismiss="modal"
aria-label="Close"
></button>
</div>
<div class="modal-body">
<form id="loginForm">
<div class="mb-3">
<label for="InputEmail1" class="form-label"
>Email address</label
>
<input
type="email"
class="form-control"
id="email-input"
aria-describedby="emailHelp"
/>
</div>
<div class="mb-3">
<label for="InputPassword1" class="form-label">Password</label>
<input
type="password"
class="form-control"
id="password-input"
/>
</div>
<button type="button" class="btn btn-primary" id="loginButton">
เข้าสู่ระบบ
</button>
</form>
</div>
</div>
</div>
</div>
<!-- Register Modal -->
<div
class="modal fade"
id="registerModal"
tabindex="-1"
aria-labelledby="exampleModalLabel"
aria-hidden="true"
>
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="exampleModalLabel">สมัครสมาชิก</h5>
<button
type="button"
class="btn-close"
data-bs-dismiss="modal"
aria-label="Close"
></button>
</div>
<div class="modal-body">
<form id="registerForm">
<div class="mb-3">
<label for="InputEmail1" class="form-email"
>Email address</label
>
<input
type="email"
class="form-control"
id="email-input"
aria-describedby="emailHelp"
required
/>
<div id="emailHelp" class="form-text">
We'll never share your email with anyone else.
</div>
</div>
<div class="mb-3">
<label for="InputPassword1" class="form-password"
>Password</label
>
<input
type="password"
class="form-control mb-3"
id="password-input"
required
/>
<label for="exampleInputPassword1" class="form-label"
>Confirm Password</label
>
<input
type="password"
class="form-control"
id="confirm-password-input"
/>
</div>
<button type="button" class="btn btn-primary" id="registerButton">
สมัครสมาชิก
</button>
</form>
</div>
</div>
</div>
</div>
<h1>Home page</h1>
<h2>Welcome to website</h2>
<script
src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/js/bootstrap.bundle.min.js"
integrity="sha384-MrcW6ZMFYlzcLA8Nl+NtUVF0sA7MsXsP1UyJoMp4YLEuNSfAP+JcXn/tWtIaxVXM"
crossorigin="anonymous"
></script>
<script type="module" src="./scripts/auth.js"></script>
<script src="./scripts/home.js"></script>
</body>
</html>