Dropup Meun Button
<!DOCTYPE html>
<html>
<head>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="STYLESHEET" type="text/css" href="web.css">
<title>web design</title>
</head>
<body>
<h1>Hoverable Dropup Meun</h1>
<p>Exmple text....</p>
<p>Example Text...</p>
<p>Move the mouse over the button to open the dropup menu.
</p>
<div class="dropup">
<button class="btn">Dropup</button>
<div class="Meun">
<a href="#">Link 1</a>
<a href="#">Link 2</a>
<a href="#">Link 3</a>
</div>
</div>
</body>
</html>
CSS Dropup Meun Button Style
.btn{
background-color: #3498DB;
border: none;
color: #fff;
padding: 16px;
font-size: 16px;
cursor: pointer;
}
.dropup{
position: relative;
display: inline-block;
}
.Meun{
display: none;
position: absolute;
background-color: #f1f1f1;
min-width:16px;
bottom:50px;
z-index: 1;
}
.Meun a{
color: #000;
padding:12px 16px ;
text-decoration: none;
display: block;
}
.Meun a:hover{
background-color: #ccc;
}
.dropup:hover .Meun{
display: block;
}
.dropup:hover .btn{
background-color:#2980B9 ;
}
No comments:
Post a Comment