-
Notifications
You must be signed in to change notification settings - Fork 46
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #116 from Gaurav0203Shetty/patch-3
Update script.js
- Loading branch information
Showing
9 changed files
with
74 additions
and
0 deletions.
There are no files selected for viewing
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"git.ignoreLimitWarning": true | ||
} |
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
Hide/Show password | ||
A project made using HTML, CSS and JS which can be integrated easily to your website for better security when entering password in public spaces.} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="UTF-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
<title>Hide/Show pass</title> | ||
<link rel="stylesheet" href="style.css"> | ||
</head> | ||
<body> | ||
<div class="input-box"> | ||
<input type="password" placeholder="Enter password" id="password"> | ||
<img src="./Images/shut.png" alt="error" id="eyeicon"> | ||
</div> | ||
<script src="script.js"></script> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
let eyeicon = document.getElementById("eyeicon"); | ||
let password = document.getElementById("password"); | ||
|
||
eyeicon.onclick = function(){ | ||
if(password.type == "password"){ | ||
password.type = "text"; | ||
eyeicon.src = "./Images/open.png"; | ||
} | ||
else{ | ||
password.type = "password"; | ||
eyeicon.src = "./Images/shut.png"; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
*{ | ||
margin: 0; | ||
padding: 0; | ||
font-family: 'Poppins', sans-serif; | ||
box-sizing: border-box; | ||
} | ||
|
||
body{ | ||
background: #00008B; | ||
} | ||
|
||
.input-box{ | ||
background: #fff; | ||
width: 90%; | ||
max-width: 500px; | ||
border-radius: 5px; | ||
padding: 10px 20px; | ||
margin: 300px auto; | ||
display: flex; | ||
align-items: center; | ||
} | ||
|
||
.input-box input{ | ||
width: 100%; | ||
padding: 10px 0; | ||
border: 0; | ||
outline: 0; | ||
font-size: 24px; | ||
color: #555; | ||
} | ||
|
||
.input-box img{ | ||
width: 35px; | ||
cursor: pointer; | ||
} | ||
|
||
img{ | ||
width: 35px; | ||
cursor: pointer; | ||
} |