Placing elements in optimal position based on available vertical space – JavaScript grid layout library

masonry_js

JavaScript grid layout libraries
1. http://masonry.desandro.com/
2. http://masonry.desandro.com/
3. http://isotope.metafizzy.co/