]> _ Git - fluidbook-v3.git/commitdiff
WIP #4 @2.25
authorstephen@cubedesigners.com <stephen@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Wed, 27 Jul 2016 10:22:19 +0000 (10:22 +0000)
committerstephen@cubedesigners.com <stephen@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Wed, 27 Jul 2016 10:22:19 +0000 (10:22 +0000)
framework/application/views/helpers/BackgroundBlock.php
framework/application/views/helpers/HomeCustomers.php
framework/application/views/helpers/HomeFeatures.php
framework/application/views/helpers/HomeServices.php
js/101-header.js
less/002-common.less
less/104-nav.less
less/210-home.less

index 175ca2574957e42268caeb3e4a3dac9d72d3a4c5..9313c5ff128a4d49d988c4bffba6cf1d9b86e9ac 100644 (file)
@@ -20,9 +20,13 @@ class Fluidbook_View_Helper_BackgroundBlock extends CubeIT_View_Helper_Abstract
                        // Work out the ratio of the background image\r
                        CubeIT_Image::getDimensions($image_path, $image_width, $image_height);\r
                        $image_ratio = $image_height / $image_width;\r
+            $attributes['data-bg-ratio'] = $image_ratio;\r
 \r
-                       $style = "background-image: url($image_path);";\r
-                       $attributes['data-bg-ratio'] = $image_ratio;\r
+            $style = "background-image: url($image_path);";\r
+\r
+            if (isset($data['backgroundcolor'])) {\r
+                $style .= 'background-color:'. $data['backgroundcolor'];\r
+            }\r
                }\r
 \r
                if (isset($data['bg_color'])) {\r
index b61b77165e1b7ae09993cd6811db35924c9dff65..84f2b379300108962ac1a6995851a2892290a0fa 100644 (file)
@@ -5,11 +5,13 @@ class Fluidbook_View_Helper_HomeCustomers extends Fluidbook_View_Helper_HomeLaye
         * @return string\r
         */\r
        public function homeCustomers($data) {\r
-               $this->data=$data;\r
 \r
-               $res = '';\r
+           $this->data = $data;\r
 \r
+        $res  = $this->title($data['title']);\r
+        $res .= $this->markupDotclear($data['content']);\r
+        $res .= $this->linkCMS($data['button'], ['class' => 'btn', 'style' => 'background:'. $data['themecolor']]);\r
 \r
-               return $this->_layer($res, 'customers');\r
+        return $this->_layer($res, 'customers');\r
        }\r
 }
\ No newline at end of file
index c97ac7c6479e704d4843408808fec3a998870db9..40f9e4c52a54f2069b0b28406319bc54af62a70d 100644 (file)
@@ -5,9 +5,12 @@ class Fluidbook_View_Helper_HomeFeatures extends Fluidbook_View_Helper_HomeLayer
         * @return string\r
         */\r
        public function homeFeatures($data) {\r
-               $this->data=$data;\r
 \r
-               $res='';\r
+           $this->data = $data;\r
+\r
+        $res  = $this->title($data['title']);\r
+        $res .= $this->markupDotclear($data['content']);\r
+        $res .= $this->linkCMS($data['button'], ['class' => 'btn', 'style' => 'background:'. $data['themecolor']]);\r
 \r
                return $this->_layer($res, 'features');\r
        }\r
index b7824a4b03f62d6b4fd39b63a52493cdcc5f37b4..442d7f63f930e37b2adc33c2d5dc8ac9950b1f1e 100644 (file)
@@ -7,7 +7,9 @@ class Fluidbook_View_Helper_HomeServices extends Fluidbook_View_Helper_HomeLayer
        public function homeServices($data) {\r
                $this->data = $data;\r
 \r
-               $res = '';\r
+        $res  = $this->title($data['title']);\r
+        $res .= $this->markupDotclear($data['content']);\r
+        $res .= $this->linkCMS($data['button'], ['class' => 'btn', 'style' => 'background:'. $data['themecolor']]);\r
 \r
                return $this->_layer($res, 'services');\r
        }\r
index cf3f5877bcaf37ad080d11244ae792e5696560f9..b6fd865ffc789c05af1f758c14404f8c1d0bdb39 100644 (file)
@@ -129,15 +129,19 @@ function changeHeaderStyle() {
         }\r
     });\r
 \r
-    var headerClass = $(section).data('headerstyle');\r
-    if (headerClass == 'light') {\r
-        if (!$("header").hasClass('light')) {\r
-            $("header,#nav-icon").addClass('light').removeClass('dark');\r
-        }\r
-    } else {\r
-        if (!$("header").hasClass('dark')) {\r
-            $("header,#nav-icon").addClass('dark').removeClass('light');\r
+    if (section !== undefined) {\r
+\r
+        var headerClass = section.data('headerstyle');\r
+        if (headerClass == 'light') {\r
+            if (!$("header").hasClass('light')) {\r
+                $("header,#nav-icon").addClass('light').removeClass('dark');\r
+            }\r
+        } else {\r
+            if (!$("header").hasClass('dark')) {\r
+                $("header,#nav-icon").addClass('dark').removeClass('light');\r
+            }\r
         }\r
+\r
     }\r
 \r
 }
\ No newline at end of file
index 12192811563618e0037e6cf2d8661fe885627b55..74e60ce18df8d8c83f1ec508ffa7e8a210e89280 100644 (file)
@@ -85,7 +85,7 @@ a {
        padding-bottom: 5%;\r
        &.fullheight {\r
                min-height: 100%;\r
-               background-size: cover;\r
+               background-size: 100%;\r
        }\r
 }\r
 \r
index 82013068274c34b45211b2c8feb233317be17d15..f5d6b264d33c5dbd2d569ee3d87fcd5f6f598877 100644 (file)
@@ -116,11 +116,15 @@ nav#menu {
 \r
                                        a {\r
                                                transition: @transition-time-buttons color;\r
+\r
+                                               header#h.light & {\r
+                                                       color: @color-header-grey;\r
+                                               }\r
                                        }\r
 \r
                                        &.active a, a:hover {\r
                                                border-bottom-color: transparent;\r
-                                               color: @color-submenu-hover;\r
+                                               color: @color-submenu-hover !important;\r
                                        }\r
                                }\r
                        }\r
index b33df7b2eeb929af676d31454b5ba67a645f2cc6..56cea0d73dcd81405098f7e955d865cafcf2037e 100644 (file)
                transform: translateY(-50%);\r
        }\r
 \r
-       .dotclear {\r
-               max-width: 500px;\r
-       }\r
-\r
        .btn {\r
                .button();\r
+        color: #fff;\r
+        margin-top: 30px;\r
        }\r
 \r
        section {\r
                        }\r
                }\r
 \r
+        .dotclear {\r
+          max-width: 500px;\r
+        }\r
+\r
                // Sections\r
                &.intro {\r
-                       .btn {\r
-                               color: #fff;\r
-                               margin-top: 30px;\r
-                       }\r
+\r
                }\r
        }\r
 }
\ No newline at end of file