From 2cafeca3089be8f0ee3cc8e86844332258d49134 Mon Sep 17 00:00:00 2001 From: Todd Miller Date: Thu, 2 Apr 2015 15:31:35 -0400 Subject: [PATCH] fixes issue #264, valign class not matching css used on the site --- css/gumby.css | 4 ++-- sass/_grid.scss | 12 ++++-------- 2 files changed, 6 insertions(+), 10 deletions(-) diff --git a/css/gumby.css b/css/gumby.css index 961797a..1c3ca3b 100644 --- a/css/gumby.css +++ b/css/gumby.css @@ -1222,8 +1222,8 @@ img { -ms-interpolation-mode: bicubic; } .row:before, .row:after { content: ""; display: table; } .row:after { clear: both; } -.valign:before { content: ' '; display: inline-block; height: 400px; vertical-align: middle; margin-right: -0.25em; } -.valign > div, .valign > article, .valign > section, .valign > figure { display: inline-block; vertical-align: middle; } +.valign { display: table; width: 100%; } +.valign > div, .valign > article, .valign > section, .valign > figure { display: table-cell; vertical-align: middle; } /* Mobile */ @media only screen and (max-width: 767px) { body { -webkit-text-size-adjust: none; -ms-text-size-adjust: none; width: 100%; min-width: 0; } diff --git a/sass/_grid.scss b/sass/_grid.scss index cb64e59..8f087d2 100755 --- a/sass/_grid.scss +++ b/sass/_grid.scss @@ -265,15 +265,11 @@ img { // vertically align stuff .valign { - &:before { - content:' '; - display: inline-block; - height: 400px; - vertical-align: middle; - margin-right: -0.25em; - } + display: table; + width: 100%; + > div, > article, > section, > figure { - display: inline-block; + display: table-cell; vertical-align: middle; } }