Created
November 27, 2016 15:02
-
-
Save yonitru/8351182f1d86d88db7b8081811f46a4a to your computer and use it in GitHub Desktop.
gists in class- flexbox
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>flexbox</title> | |
<link rel="stylesheet" href="includes/style.css"> | |
<style type="text/css"> | |
* { | |
padding:0px; | |
margin:0px; | |
} | |
header,nav,aside,article,section,footer, main { | |
display:block; | |
} | |
.flex { | |
display:flex; | |
flex-direction:row; | |
width: 350px; | |
height: 300px; | |
} | |
.flex > div { | |
flex: auto; | |
width: 30px; | |
transition: width 0.6s ease-out; | |
} | |
.flex > div:nth-child(1){ background: #00b33c; } | |
.flex > div:nth-child(2){ background: #004d1a; } | |
.flex > div:nth-child(3){ background: #ff0055; } | |
.flex > div:hover { | |
width: 180px; | |
}</style> | |
</head> | |
<body> | |
<div class="flex"> | |
<div></div> | |
<div></div> | |
<div></div> | |
</div> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment