Created
February 21, 2014 06:15
-
-
Save zhuangya/9129663 to your computer and use it in GitHub Desktop.
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
<ul class="clean-list"> | |
<li class="thumbnail"> | |
<img src="http://placehold.it/100x100"> | |
</li> | |
<li class="thumbnail"> | |
<img src="http://placehold.it/200x100"> | |
</li> | |
<li class="thumbnail"> | |
<img src="http://placehold.it/100x200"> | |
</li> | |
<li class="thumbnail"> | |
<img src="http://placehold.it/100x100"> | |
</li> | |
<li class="thumbnail"> | |
<img src="http://placehold.it/100x100"> | |
</li> | |
<li class="thumbnail"> | |
<img src="http://placehold.it/100x100"> | |
</li> | |
<li class="thumbnail"> | |
<img src="http://placehold.it/100x100"> | |
</li> | |
</ul> | |
<style> | |
.clean-list { | |
list-style: none; | |
list-style-type: none; | |
margin: 0; | |
padding: 0; | |
outline: 1px solid blue; | |
} | |
.thumbnail { | |
display: inline-block; | |
margin: 45px; | |
width: 100px; | |
height: 100px; | |
text-align: center; | |
} | |
.thumbnail img:before { | |
height: 100%; | |
content: '\0020'; | |
display: inline-block; | |
vertical-align: middle; | |
} | |
.thumbnail img { | |
max-width: 100%; | |
max-height: 100%; | |
vertical-align: middle; | |
display: inline-block; | |
} | |
</style> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment