Skip to content

Instantly share code, notes, and snippets.

@wrumsby
Created November 28, 2013 21:28
Show Gist options
  • Save wrumsby/7698391 to your computer and use it in GitHub Desktop.
Save wrumsby/7698391 to your computer and use it in GitHub Desktop.
The first commented line is your dabblet’s title
/**
* The first commented line is your dabblet’s title
*/
body {
font-family: sans-serif;
}
.avatar-container {
height: 160px;
width: 160px;
border: 1px solid #333;
}
.avatar-placeholder {
background-image: url('http://placekitten.com/160/160');
height: 100%;
width: 100%;
}
.avatar-container .avatar-placeholder {
display: none;
}
.avatar-container.show-placeholder .avatar-placeholder {
display: block;
}
.avatar-container.show-placeholder img {
display: none;
}
<!-- content to be placed inside <body>…</body> -->
<div class="avatar-container show-placeholder">
<div class="avatar-placeholder"></div>
<img src="http://placehold.it/160x160">
</div>
// alert('Hello world!');
{"view":"split","fontsize":"100","seethrough":"","prefixfree":"1","page":"css"}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment