Created
July 8, 2015 19:19
-
-
Save popcorn245/760f630e699347dce766 to your computer and use it in GitHub Desktop.
A pure CSS drop-down solution.
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
<style> | |
span p{ | |
cursor:pointer; | |
} | |
span ul{ | |
transition: all 0.5s ease; | |
list-style:none; | |
height:0px; | |
padding:0; | |
overflow:hidden; | |
opacity:0; | |
border:1px solid #ddd; | |
width:300px; | |
} | |
span ul li{ | |
border-bottom:1px solid #ddd; | |
padding:10px; | |
} | |
span ul li:last-of-type{ | |
border:none; | |
} | |
span:hover ul{ | |
height:118px; | |
opacity:1; | |
} | |
</style> | |
<span> | |
<p>Dropdown with Pure CSS</p> | |
<ul> | |
<li>Take</li> | |
<li>That</li> | |
<li>Bootstrap</li> | |
</ul> | |
</span> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment