Responsive Grids width floats, collection on CODEPEN
Modular
See the Pen grid: modular by Oliver Roeger (@uic-des) on CodePen.
This one is the easiest technically speaking. Images have all the same aspect ratios and simply float.
Column Grid w Different Heights: The Problem
See the Pen grid: different ratios: problem by Oliver Roeger (@uic-des) on CodePen.
If grid boxes have different heights and float, the grid breaks. Clearing floats is an option. but a lot of work since grid column counts likely change on smaller screens
Column Grid w Different Heights: Solution One: MatchHeights.js
See the Pen grid: match height js by Oliver Roeger (@uic-des) on CodePen.
This Java Script matches the height of rows. The grid won't break that way even if the column count changes.
Column Grid w Different Heights: Solution Two: Masonry.js
See the Pen grid: masonry by Oliver Roeger (@uic-des) on CodePen.
This Java Script makes the grid boxes fall into space to avoid larger vertical caps. Like you see on Pinterest.
Masonry.js with different widths
See the Pen grid: masonry.js with different widths by Oliver Roeger (@uic-des) on CodePen.
Masonry.js can be used with boxes that have different widths. But gaps can appear.
Modular Grid w Packery.js
See the Pen grid: packery js (gapless) by Oliver Roeger (@uic-des) on CodePen.
Packery.js creates gap-less grids.
Modular Grid w Packery.js (truly gap-less)
See the Pen grid: packery js w image padding by Oliver Roeger (@uic-des) on CodePen.
Although packery.js works with margins I found out that I still ended up with gaps. Getting rid of the margins and applying paddings to images creates truly gape-less grids (as longs as they're modular).
Packery.js with different ratios
See the Pen grid: packery js, mixed ratios and sizes by Oliver Roeger (@uic-des) on CodePen.
Different aspect ratios still work well with packery.js but you'll get gaps with different ratios here and there because not all ratios fit (naturally).
Packery.js round (variation)
See the Pen grid: packery.js round by Oliver Roeger (@uic-des) on CodePen.
a border-radius declaration of 50% applied once to the image tag converts the square grid onto circles.