From 1a71e6ab12d75abe32cfeddf1df92dabb1c63b83 Mon Sep 17 00:00:00 2001 From: raphaelgoetter Date: Thu, 25 Jul 2013 17:29:26 +0200 Subject: [PATCH] ajout des classes "autogrid" --- css/grids.css | 29 ++++++++++++++++++++++++++++- 1 file changed, 28 insertions(+), 1 deletion(-) diff --git a/css/grids.css b/css/grids.css index 9e60f24..642c7db 100644 --- a/css/grids.css +++ b/css/grids.css @@ -12,7 +12,7 @@ .grid5 > * { width: 18.4%; } .grid6 > * { width: 15%; } -/* unequal grids (1-2, 2-1, 1-3 and 3-1) */ +/* unequal grids (1-2, 2-1, 1-3 and 3-1) with 2% gutter */ .grid2-1 > *:first-child, .grid1-2 > * + * { width: 66%; } .grid1-2 > *:first-child, @@ -22,3 +22,30 @@ .grid3-1 > *:first-child, .grid1-3 > * + * { width: 74.5%; } +/* ----------------------------- */ +/* ==autogrids */ +/* ----------------------------- */ + +/* auto-justified equal grids */ + +[class^="autogrid"] { + text-align: justify; + font-size: 1px; letter-spacing: -1px; /* whitespace fi xpart 1 */ +} +[class^="autogrid"]:after { + content: ""; + display: inline-block; + width: 100%; +} +[class^="autogrid"] > * { + display: inline-block; + vertical-align: top; + text-align: left; + font-size: 14em; font-size: 1.4rem; letter-spacing: normal; /* whitespace fix part 2 */ + *display: inline; *zoom: 1; /* ie6 / ie7 hack */ +} +.autogrid2 > * {width: 49.4%} +.autogrid3 > * {width: 32.6%} +.autogrid4 > * {width: 24.2%} +.autogrid5 > * {width: 19.2%} +.autogrid6 > * {width: 15.9%} \ No newline at end of file