Skip to content

Instantly share code, notes, and snippets.

@JoshBarr
Last active December 16, 2015 05:29
Show Gist options
  • Save JoshBarr/5385253 to your computer and use it in GitHub Desktop.
Save JoshBarr/5385253 to your computer and use it in GitHub Desktop.
.clearfix{
/* this should already exist in base styles*/
}
.media{
display:block;
@extend .clearfix;
}
.media__img{
float:left;
margin-right:$base-spacing-unit;
}
/**
* Reversed image location (right instead of left).
*/
.media__img__right{
float:right;
margin-left:$base-spacing-unit;
}
.media__img img,
.media__img__right img{
display:block;
}
.media__body{
overflow:hidden;
}
.media__body,
.media__body > :last-child{
margin-bottom:0; /* removes double margin. We might be using margin-top in banners so potentially use :first-child and margin-top here instead. */
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment