jeremy-h of Web Development
11/9/2017 - 5:17 PM

Clearfix

Hack to resolve containers not responding to sizing correctly when there are multiple floated elements contained inside of them.

.clearfix:after {
  visibility: hidden;
  display: block;
  font-size: 0;
  content: " ";
  clear: both;
  height: 0;
}
.clearfix { display: inline-block; }
/* start commented backslash hack \*/
* html .clearfix { height: 1%; }
.clearfix { display: block; }
/* close commented backslash hack */