-
Notifications
You must be signed in to change notification settings - Fork 115
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 #161 from venketeswar664/main
resolved issued #12
- Loading branch information
Showing
2 changed files
with
131 additions
and
0 deletions.
There are no files selected for viewing
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,46 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
|
||
<head> | ||
<meta charset="utf-8"> | ||
<meta name="viewport" content= | ||
"width=device-width,initial-scale=1.0"> | ||
<title>side navigation bar</title> | ||
<script src="https://kit.fontawesome.com/bba3432f3f.js" | ||
crossorigin="anonymous"></script> | ||
<link rel="stylesheet" href="style.css"> | ||
</head> | ||
|
||
<body> | ||
<div class="header"> | ||
<div class="side-nav"> | ||
<ul class="nav-links"> | ||
<li><a href="#"> | ||
<i class="fa-solid fa-house-user"></i> | ||
<p>Home</p> | ||
</a> | ||
</li> | ||
|
||
<li><a href="#"> | ||
<i class="fa-solid fa-user"></i> | ||
<p>About</p> | ||
</a> | ||
</li> | ||
<li><a href="#"> | ||
<i class="fas fa-id-card-alt"></i> | ||
<p>Login</p> | ||
</a> | ||
</li> | ||
|
||
<li><a href="#"> | ||
<i class="fa fa-user-circle"></i> | ||
<p>Contact us</p> | ||
</a> | ||
</li> | ||
<div class="action"></div> | ||
</ul> | ||
</div> | ||
</div> | ||
</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,85 @@ | ||
* { | ||
margin: 0; | ||
padding: 0; | ||
box-sizing: border-box; | ||
font-family: "Poppins", sans-serif; | ||
} | ||
|
||
.header { | ||
width: 100%; | ||
height: 100vh; | ||
background: #f1f1dc; | ||
} | ||
|
||
.side-nav { | ||
width: 250px; | ||
height: 100%; | ||
background: rgb(178, 239, 239); | ||
position: fixed; | ||
top: 0; | ||
left: 0; | ||
padding: 20px 30px; | ||
} | ||
|
||
|
||
.nav-links { | ||
list-style: none; | ||
position: relative; | ||
} | ||
|
||
.nav-links li { | ||
padding: 10px 0; | ||
} | ||
|
||
.nav-links li a { | ||
color: #000000; | ||
text-decoration: none; | ||
padding: 10px 14px; | ||
display: flex; | ||
align-items: center; | ||
} | ||
|
||
.nav-links li a i { | ||
font-size: 22px; | ||
margin-right: 20px; | ||
} | ||
|
||
.active { | ||
background: #000000; | ||
width: 100%; | ||
height: 47px; | ||
position: absolute; | ||
left: 0; | ||
top: 2.6%; | ||
z-index: -1; | ||
border-radius: 6px; | ||
box-shadow: 0 5px 10px rgba(255, 255, 255, 0.4); | ||
display: none; | ||
transition: top 0.5s; | ||
} | ||
|
||
.nav-links li:hover a { | ||
color: #fff; | ||
transition: 0.3s; | ||
} | ||
|
||
.nav-links li:hover~.active { | ||
display: block; | ||
} | ||
|
||
.nav-links li:nth-child(1):hover~.action { | ||
top: 2.6%; | ||
} | ||
|
||
.nav-links li:nth-child(2):hover~.action { | ||
top: 30.2%; | ||
} | ||
|
||
.nav-links li:nth-child(3):hover~.action { | ||
top: 50.8%; | ||
} | ||
|
||
.nav-links li:nth-child(4):hover~.action { | ||
top: 78.4%; | ||
} | ||
|