From: vincent@cubedesigners.com Date: Tue, 12 Dec 2017 18:25:40 +0000 (+0000) Subject: wip #1809 @0:40 X-Git-Url: http://git.cubedesigners.com/?a=commitdiff_plain;h=a926602a054f8eab8e9cb55c9549f06138f403ad;p=fluidbook-v3.git wip #1809 @0:40 --- diff --git a/framework/application/views/helpers/FeatureDetails.php b/framework/application/views/helpers/FeatureDetails.php index 9d3041c..7ddc765 100644 --- a/framework/application/views/helpers/FeatureDetails.php +++ b/framework/application/views/helpers/FeatureDetails.php @@ -21,12 +21,7 @@ class Fluidbook_View_Helper_FeatureDetails extends CubeIT_View_Helper_Abstract { $c = $this->htmlElement($c, 'div', ['class' => 'content']); $image = $this->imageProcess($d['image'], $d['title'], 755, 1000, [], 'R'); - if ($imageRight) { - $res = $c . $image; - } else { - $res = $image . $c; - } - + $res = $image . $c; return $this->htmlElement($res, 'article', ['class' => $imageRight ? 'iright' : 'ileft']); } diff --git a/framework/application/views/helpers/IntroBlock.php b/framework/application/views/helpers/IntroBlock.php index 7653e29..250f968 100644 --- a/framework/application/views/helpers/IntroBlock.php +++ b/framework/application/views/helpers/IntroBlock.php @@ -17,17 +17,27 @@ class Fluidbook_View_Helper_IntroBlock extends CubeIT_View_Helper_Abstract { $res .= ''; // .col-2 $res .= ''; // .grid + $attrs = array('class' => array('intro')); + if ($outsideContent) { $res .= $outsideContent; } - $res = $this->backgroundBlock($res, $intro); + if (isset($intro['backgroundimage']) && !isset($intro['bg_image'])) { + $intro['bg_image'] = $intro['backgroundimage']; + } + if (!isset($intro['bg_image']) || !$intro['bg_image']) { + $attrs['class'][] = 'nobg'; + } else { + $attrs['data-bg'] = print_r($intro['bg_image'], true); + } + $res = $this->backgroundBlock($res, $intro); if ($intro['chapo']) { $res .= $this->htmlElement($this->htmlElement(nl2br($intro['chapo']), 'div'), 'blockquote'); } - $attrs = array('class' => array('intro')); + if (!$paddingTop) { $attrs['class'][] = 'nopad'; } diff --git a/framework/application/views/helpers/Logos.php b/framework/application/views/helpers/Logos.php index fcc4a6d..1e15bcf 100644 --- a/framework/application/views/helpers/Logos.php +++ b/framework/application/views/helpers/Logos.php @@ -14,7 +14,7 @@ class Fluidbook_View_Helper_Logos extends CubeIT_View_Helper_Abstract { $res = ''; foreach ($images as $image) { - $res .= $this->imageCms($image).' '; // Space needed for the justify + $res .= $this->htmlElement($this->imageCms($image), 'div', ['class' => 'i']) . ' '; // Space needed for the justify } $res = $this->htmlElement($res, 'div', ['class' => 'c']); diff --git a/less/102-intro.less b/less/102-intro.less index ffd7bde..836a0de 100644 --- a/less/102-intro.less +++ b/less/102-intro.less @@ -9,6 +9,14 @@ } } + &.nobg { + .content-wrapper { + @media @m900 { + padding-bottom: 15%; + } + } + } + .content-wrapper { .intro-padding(); background-size: 100% auto; diff --git a/less/106-logos.less b/less/106-logos.less index d3fc506..a554e48 100644 --- a/less/106-logos.less +++ b/less/106-logos.less @@ -2,10 +2,12 @@ .logos { &.content-wrapper { - padding-top: 56px; - padding-bottom: 50px; + padding-top: 4%; + padding-bottom: 2%; } + background-color: @color-light-grey; + .c { display: inline-block; width: 100%; @@ -15,14 +17,27 @@ margin: 0 auto; line-height: 0; + @media @m900 { + padding-left: 0; + padding-right: 0; + } + &:after { content: ""; display: inline-block; width: 100%; height: 0; } - img { - vertical-align: middle; + + .i { + width: 120px; + height: 45px; + display: inline-block; + text-align: center; + + img { + vertical-align: middle; + } } } } \ No newline at end of file diff --git a/less/420-features-details.less b/less/420-features-details.less index 3e1f2c7..42edb4c 100644 --- a/less/420-features-details.less +++ b/less/420-features-details.less @@ -10,8 +10,8 @@ } .content { - width: 755px; - padding: 60px 130px 0; + width: 50%; + padding: 8% 10% 0; display: inline-block; vertical-align: top; font-size: 14px; @@ -25,8 +25,62 @@ } img { display: inline-block; - width: 755px; + width: 50%; + height: auto; vertical-align: top; } + + @media @m1280 { + &.ileft { + .content { + padding: 0 0 0 4%; + } + } + + &.iright { + .content { + padding: 0 4% 0 0; + } + } + } + + @media @m900 { + margin-top: 70px; + + .content { + float: none !important; + width: 100%; + padding: 0 !important; + display: block; + margin-top: 20px; + } + + img { + float: none !important; + width: 100%; + height: auto; + display: block; + } + + } + + &.ileft { + .content { + float: right; + } + img { + float: left; + } + + } + + &.iright { + .content { + float: left; + } + img { + float: right; + } + } } } \ No newline at end of file