Skip to content

Instantly share code, notes, and snippets.

@chriseppstein
Created April 8, 2009 07:03
Show Gist options
  • Save chriseppstein/91663 to your computer and use it in GitHub Desktop.
Save chriseppstein/91663 to your computer and use it in GitHub Desktop.
.line, .lastUnit { overflow: hidden; _overflow: visible; _zoom: 1; }
.unit { float: left; _zoom: 1; }
.size1of1 { float: none; }
.size1of2 { width: 50%; }
.size1of3 { width: 33.333%; }
.size2of3 { width: 66.667%; }
.size1of4 { width: 25%; }
.size2of4 { width: 50%; }
.size3of4 { width: 75%; }
.size1of5 { width: 20%; }
.size2of5 { width: 40%; }
.size3of5 { width: 60%; }
.size4of5 { width: 80%; }
.lastUnit { float: none; _position: relative; _left: -3px; _margin-right: -3px; width: auto; }
=oocss-clearfix
overflow: hidden
_overflow: visible
_zoom: 1
=unit
float: left
_zoom: 1
=size(!n, !m)
@if !n == !m
float: none
@else
width= percentage(!n / !m)
=lastUnit
float: none
_position: relative
_left: -3px
_margin-right: -3px
width: auto
=grids
.line, .lastUnit
+oocss-clearfix
.unit
+unit
.size1of1
+size(1,1)
@for !m from 1 through 5
@for !n from 1 to !m
.size#{!n}of#{!m}
+size(!n, !m)
.lastUnit
+lastUnit
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment