From 7d90344dd699c45423dfe2a5c2cf932a81c2af41 Mon Sep 17 00:00:00 2001 From: Nicolas Kuttler Date: Sat, 6 Feb 2016 15:13:29 +0100 Subject: [PATCH] Update home stats summary CSS The construct_homepage_summary_items hook allows to add items, but if you use exactly the same markup as wagtail you end up with a bad layout because the items form rows with no whitespace between them. This commit changes the padding-bottom of the section into a margin-bottom of it's
  • items, meaning that they form rows with enough whitespace in between them, and the whitespace at the bottom is preserved. --- CHANGELOG.txt | 1 + CONTRIBUTORS.rst | 1 + docs/releases/1.4.rst | 1 + .../wagtailadmin/static_src/wagtailadmin/scss/layouts/home.scss | 2 +- 4 files changed, 4 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 15b4a853c2..b8a063f1cd 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -23,6 +23,7 @@ Changelog * The `edit bird` on the frontend has been redesigned, and no longer depends on an iframe (Thomas Winter, Gareth Price). * New translations for Hungarian, Swedish (Sweden) and Turkish * Upgraded jQuery to 2.2.1 (Charlie Choiniere) + * Multiple homepage summary items (`construct_homepage_summary_items` hook) now better vertically spaced (Nicolas Kuttler) * Fix: Custom page managers no longer raise an error when used on an abstract model * Fix: Wagtail's migrations are now all reversible (benjaoming) * Fix: Deleting a page content type now preserves existing pages as basic Page instances, to prevent tree corruption diff --git a/CONTRIBUTORS.rst b/CONTRIBUTORS.rst index ec88761f27..da24637426 100644 --- a/CONTRIBUTORS.rst +++ b/CONTRIBUTORS.rst @@ -110,6 +110,7 @@ Contributors * Thomas Winter * Gareth Price * Liam Brenner +* Nicolas Kuttler Translators =========== diff --git a/docs/releases/1.4.rst b/docs/releases/1.4.rst index b4feb4f990..4d96a4f33d 100644 --- a/docs/releases/1.4.rst +++ b/docs/releases/1.4.rst @@ -61,6 +61,7 @@ Minor features * The ``Page`` model now has two new methods ``get_site()`` and ``get_url_parts()`` to aid with customising the page URL generation logic * New translations for Hungarian, Swedish (Sweden) and Turkish * Upgraded jQuery to 2.2.1 (Charlie Choiniere) + * Multiple homepage summary items (`construct_homepage_summary_items` hook) now better vertically spaced (Nicolas Kuttler) Bug fixes diff --git a/wagtail/wagtailadmin/static_src/wagtailadmin/scss/layouts/home.scss b/wagtail/wagtailadmin/static_src/wagtailadmin/scss/layouts/home.scss index e72911e0cf..01e074cb4f 100644 --- a/wagtail/wagtailadmin/static_src/wagtailadmin/scss/layouts/home.scss +++ b/wagtail/wagtailadmin/static_src/wagtailadmin/scss/layouts/home.scss @@ -33,7 +33,6 @@ header { background-color: $color-grey-5; margin-bottom: 2em; padding-top: 2em; - padding-bottom: 2em; ul.stats { @include clearfix(); @@ -42,6 +41,7 @@ header { li { @include column(4); + margin-bottom: 2em; &:before { opacity: 0.2;