forked from ANSHIKA-26/WordWise
-
Notifications
You must be signed in to change notification settings - Fork 0
/
login.html
199 lines (181 loc) · 5.74 KB
/
login.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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>WordWise</title>
<!--favicon-->
<link rel="shortcut icon" type="image/x-icon" href="/images/favi.png" />
<!--css-->
<link rel="stylesheet" href="style.css" />
<link rel="stylesheet" href="login.css" />
<style>
.input-field {
position: relative;
margin-bottom: 20px;
}
.input-box {
width: 100%;
padding-right: 40px; /* Extra space for icons */
padding-left: 10px;
height: 40px;
box-sizing: border-box;
}
.toggle-eye,
.close-btn {
cursor: pointer;
position: absolute;
top: 50%;
transform: translateY(-50%);
color: black;
font-size: 18px;
margin-top: 15px;
}
.toggle-eye {
right: 40px; /* Space for close button */
}
.close-btn {
right: 10px;
font-size: 20px;
color: red;
}
.toggle-eye:hover,
.close-btn:hover {
color: #555; /* Change color on hover for better UX */
}
/* Animation for smooth transitions */
.input-box {
transition: all 0.3s ease;
}
.fa-eye,
.fa-eye-slash {
transition: all 0.3s ease;
}
</style>
</head>
<body>
<header class="navbar">
<div class="logo">
<h2><a class="home-link" href="index.html">WordWise</a></h2>
</div>
<nav class="nav-menu">
<ul>
<li><a href="index.html">Home</a></li>
<li><a href="blog.html">Leading Blog</a></li>
<li><a href="start_writing.html">Start Writing</a></li>
<li><a href="category.html">Categories</a></li>
<li><a href="about.html">About</a></li>
<li><a href="contact_us.html">Contact Us</a></li>
<li><a href="contact_us.html">Give Feedback</a></li>
</ul>
</nav>
<div class="auth-buttons">
<div class="nav-item dropdown" style="list-style-type: none">
<button class="dropbtn">
<img
width="30px"
src="images/profile.png"
alt="Profile"
class="profile-icon"
onclick="toggleDropdown()"
/>
</button>
<div id="profile-dropdown" class="dropdown-content">
<div class="login-signup-form">
<a href="login.html">Log In</a>
<a href="signup.html">Sign Up</a>
</div>
</div>
</div>
</div>
<div class="theme-switch-wrapper">
<label class="theme-switch" for="checkbox">
<input type="checkbox" id="checkbox" />
<div class="slider">
<img
src="https://img.icons8.com/emoji/48/000000/sun-emoji.png"
alt="Sun"
class="icon sun-icon"
/>
<img
src="https://img.icons8.com/emoji/48/000000/crescent-moon-emoji.png"
alt="Moon"
class="icon moon-icon"
/>
</div>
</label>
<span id="mode-label">Light Mode</span>
</div>
</header>
<main>
<div class="container-login">
<!-- Login Form -->
<div class="box-login">
<div class="top-header">
<h2>Login</h2>
</div>
<div class="input-group">
<div class="input-field">
<label for="Name">Email</label><br />
<input type="email" class="input-box name" placeholder="Enter Name" />
</div>
<!-- Password field with eye icon and cross button -->
<div class="input-field">
<label for="password">Password</label><br />
<input
type="password"
id="password"
class="input-box pass"
placeholder="Enter Password"
/>
<span
class="toggle-eye"
onclick="togglePassword('password', 'eye-icon')"
>
<i id="eye-icon" class="fa fa-eye-slash"></i>
</span>
<!-- Close button to clear input -->
<span class="close-btn" onclick="clearInput('password')">×</span>
</div>
<div class="remember">
<input type="checkbox" class="check" id="formcheck" />
<label for="formcheck">Remember Me</label>
</div>
<div class="submit">
<input type="submit" class="Input-submit" value="LOGIN" />
</div>
<div class="forgot">
<a href="/*">Forgot Password?</a>
</div>
</div>
<div class="new">
<span>New User?</span>
<a href="signup.html">Sign Up</a>
</div>
</div>
</div>
</main>
<!-- Font Awesome for icons -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0-beta3/js/all.min.js"></script>
<script>
// Toggle password visibility
function togglePassword(inputId, iconId) {
const passwordField = document.getElementById(inputId);
const eyeIcon = document.getElementById(iconId);
if (passwordField.type === "password") {
passwordField.type = "text";
eyeIcon.classList.remove("fa-eye-slash");
eyeIcon.classList.add("fa-eye");
} else {
passwordField.type = "password";
eyeIcon.classList.remove("fa-eye");
eyeIcon.classList.add("fa-eye-slash");
}
}
// Clear input field
function clearInput(inputId) {
document.getElementById(inputId).value = "";
}
</script>
</body>
</html>