From f9eee4d063a9d7f93fce98f7e8702a7ce00f32bc Mon Sep 17 00:00:00 2001 From: Jonathan Wall Date: Thu, 14 Oct 2010 15:52:45 -0700 Subject: [PATCH] Starting adding CSS to make the quad zones collapse. --HG-- branch : dev --- .../Themes/TheThemeMachine/Styles/Site.css | 24 +++++++++++++++++++ .../TheThemeMachine/Views/Layout.cshtml | 15 ++++++++++-- 2 files changed, 37 insertions(+), 2 deletions(-) diff --git a/src/Orchard.Web/Themes/TheThemeMachine/Styles/Site.css b/src/Orchard.Web/Themes/TheThemeMachine/Styles/Site.css index 7b26af324..abebf4316 100644 --- a/src/Orchard.Web/Themes/TheThemeMachine/Styles/Site.css +++ b/src/Orchard.Web/Themes/TheThemeMachine/Styles/Site.css @@ -473,4 +473,28 @@ ul.comments li div.text { .clearfix { clear:both; +} + +#footer div { + /*border:1px solid #ff0000;*/ +} + +/* If zones 1 and 2 are empty in the quad */ + +.split-left #footer-quad-third div.zone { + width:600px; +} + +.split-left #footer-quad-fourth div.zone { + width:360px; +} + +/* If zones 3 and 4 are empty in the quad */ + +.split-right #footer-quad-first div.zone { + width:600px; +} + +.split-right #footer-quad-second div.zone { + width:360px; } \ No newline at end of file diff --git a/src/Orchard.Web/Themes/TheThemeMachine/Views/Layout.cshtml b/src/Orchard.Web/Themes/TheThemeMachine/Views/Layout.cshtml index 6c18149b5..938bd09ff 100644 --- a/src/Orchard.Web/Themes/TheThemeMachine/Views/Layout.cshtml +++ b/src/Orchard.Web/Themes/TheThemeMachine/Views/Layout.cshtml @@ -22,6 +22,17 @@ } + //Add classes to the wrapper div to toggle quad widget zones on and off + if (Model.FooterQuadFirst == null && Model.FooterQuadSecond == null) { + Model.Classes.Add("split-left"); + } + else if (Model.FooterQuadThird == null && Model.FooterQuadFourth == null) { + Model.Classes.Add("split-right"); + } + else { + + } + Model.Id = "layout-wrapper"; var tag = Tag (Model, "div"); @@ -133,12 +144,12 @@ } @if (Model.FooterQuadThird != null) { -