Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save necolas/1111864 to your computer and use it in GitHub Desktop.
Save necolas/1111864 to your computer and use it in GitHub Desktop.
Inline-block layout component
<div class="ibw">
<div class="ib">inline block</div>
<div class="ib">inline block</div>
<div class="ib">inline block</div>
</div>
.ibw {
word-spacing: -1em; /* hide whitespace between elements if separated by whitespace in the source */
}
.ibw .ib {
display: -moz-inline-box; /* FF2 or lower */
display: inline-block;
word-spacing: normal;
vertical-align: top;
/* IE6/7 inline-block hack */
*display: inline;
*zoom: 1;
}
@malachi358
Copy link

Great work man, thanks for sharing!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment