From: Andy Cochran Date: Sat, 2 Jul 2016 00:44:44 +0000 (-0400) Subject: fix centered columns flowing around uncentered columns X-Git-Tag: v6.2.4-rc1~61^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F8991%2Fhead;p=thirdparty%2Ffoundation%2Ffoundation-sites.git fix centered columns flowing around uncentered columns --- diff --git a/scss/grid/_position.scss b/scss/grid/_position.scss index 886d20b7f..a832a1387 100644 --- a/scss/grid/_position.scss +++ b/scss/grid/_position.scss @@ -19,6 +19,7 @@ @else if $position == center { &, &:last-child:not(:first-child) { float: none; + clear: both; } margin-left: auto; margin-right: auto; diff --git a/test/visual/grid/centered-columns.html b/test/visual/grid/centered-columns.html index 8ee92b220..f92054924 100644 --- a/test/visual/grid/centered-columns.html +++ b/test/visual/grid/centered-columns.html @@ -10,24 +10,45 @@ +
+

Centered Columns

+
+
-

all these columns should be centered, even the last

+

All these grey columns should be centered, even the last one.

-

all these columns should be centered, even the last

+

All these grey columns should be centered, even the last one.

-

all these columns should be centered, even the last

+

All these grey columns should be centered, even the last one.

-

all these columns should be centered, even the last

+

All these grey columns should be centered, even the last one.

-

all these columns should be centered, even the last

+

All these grey columns should be centered, even the last one.

+
+
+ +

+ +
+
+

This blue column is not centered.

+
+
+

This pink column should be centered and clear the blue column.

+
+
+

This blue column is not centered.

+
+
+

This blue column is not centered.