]> _ Git - ccv-wordpress.git/commitdiff
WIP #3053 @2
authorStephen Cameron <stephen@cubedesigners.com>
Thu, 10 Oct 2019 15:42:51 +0000 (17:42 +0200)
committerStephen Cameron <stephen@cubedesigners.com>
Thu, 10 Oct 2019 15:42:51 +0000 (17:42 +0200)
wp-config.php
wp-content/mu-plugins/cube/src/Elementor/Widgets/HeaderSlideshow.php
wp-content/mu-plugins/cube/src/Elementor/Widgets/NewsBanner.php
wp-content/themes/CCV/resources/assets/styles/common/animations.styl
wp-content/themes/CCV/resources/assets/styles/components/header.styl
wp-content/themes/CCV/resources/assets/styles/components/navigation.styl
wp-content/themes/CCV/resources/assets/styles/widgets/header-slideshow.styl

index 02ff4b1678bcb4c37c9d517aa99b56895d6bfdb3..6b6341c3c5a84dc5f4a73dce52f00915339c0207 100644 (file)
@@ -7,16 +7,16 @@ if (file_exists(dirname(__FILE__) . '/local-config.php')) {
 
 // Global DB config
 if (!defined('DB_NAME')) {
-    define('DB_NAME', 'ccv');
+    define('DB_NAME', 'yxnggyswww');
 }
 if (!defined('DB_USER')) {
-    define('DB_USER', 'ccv');
+    define('DB_USER', 'yxnggyswww');
 }
 if (!defined('DB_PASSWORD')) {
-    define('DB_PASSWORD', '');
+    define('DB_PASSWORD', 'DuozFVzGpW26gBF5MNev');
 }
 if (!defined('DB_HOST')) {
-    define('DB_HOST', '');
+    define('DB_HOST', 'yxnggyswww.mysql.db');
 }
 
 /** Database Charset to use in creating database tables. */
index 0d07a2a87afcf8ab637a13b8df1c3ee6cae34821..a357e377a0e9d171979a10e129b0b7fe2f8dcea8 100644 (file)
@@ -137,7 +137,7 @@ class HeaderSlideshow extends Widget_Base {
 
             <div class="header-slideshow-sizer" style="padding-bottom: <?= $image_ratio ?>; background-image:url(/wp-content/uploads/<?= $image_meta['file'] ?>);">
 
-                <div class="header-slideshow-content mx-2v elementor-element elementor-invisible" data-settings='{"animation":"fadeInUp","animation_delay":0}' data-element_type="section">
+                <div class="header-slideshow-content mx-2v elementor-element elementor-invisible" data-settings='{"animation":"fadeInRight","animation_delay":0}' data-element_type="section">
                     <h1 class="header-slideshow-title">
                         <span class="header-slideshow-title-text"><?= nl2br($title) ?></span>
                         <span class="header-slideshow-subtitle"><?= $subtitle ?></span>
index 25a232abac71a36bfdb5274500e9bc7d7f01a45c..3b1ba3a6b2f3e0082265818513d6a02a5804d632 100644 (file)
@@ -88,9 +88,9 @@ class NewsBanner extends Widget_Base {
 
         if ($post && isset($post[0]['post_title'])) {
 
-            echo '<div class="bg-purple-dark text-white px-2v py-4 flex items-center justify-between">';
-            echo '<a href="'. get_permalink($post[0]['ID']) .'">'. $post[0]['post_title'] .'</a>';
-            echo '<a href="'. get_permalink(get_option('page_for_posts')) .'" class="btn ml-2">'. __("Voir toute l'actualité", 'cube') .'</a>';
+            echo '<div class="bg-purple-dark text-white px-2v py-4 flex items-center justify-between sm:flex-col sm:items-start">';
+            echo '<a href="'. get_permalink($post[0]['ID']) .'" class="pr-4 sm:pr-0 sm:mb-4">'. $post[0]['post_title'] .'</a>';
+            echo '<a href="'. get_permalink(get_option('page_for_posts')) .'" class="btn whitespace-no-wrap flex-shrink-0">'. __("Voir toute l'actualité", 'cube') .'</a>';
             echo '</div>';
 
         }
index eb0618613f675345f76cfbb37406ad2e068a263b..124e40e02c7c87ebc350fddf7fe163aae167606d 100644 (file)
@@ -4,3 +4,20 @@
     opacity: 0
   to
     opacity: 1
+
+// Override Elementor animations
+@keyframes fadeInUp
+  from
+    opacity: 0
+    transform: translate3d(0, 150px, 0)
+  to
+    opacity: 1
+    transform: none
+
+@keyframes fadeInRight
+  from
+    opacity: 0
+    transform: translate3d(150px, 0, 0)
+  to
+    opacity: 1
+    transform: none
index 7716d0637fd78570b06cab0492b4f2c2490232bf..17dfa1078a3176d2ceaa59fcb2e46ebcb137dd76 100644 (file)
@@ -1,8 +1,9 @@
 header.site
   .header-slideshow-present &
-    position: absolute
-    top: 0
-    left: 0
-    width: 100%
-    background-color: transparent
-    z-index: 20
+    +above($breakpoint-menu)
+      position: absolute
+      top: 0
+      left: 0
+      width: 100%
+      background-color: transparent
+      z-index: 20
index e96c63384ade752129fad47ed40d81bac0f14cbe..bb7c0eedc0e18868c8bf649202af8ee4f2f83ad8 100644 (file)
@@ -61,3 +61,7 @@
         background-color: rgba(#fff, 0.2)
 
 
+// Language switcher and action buttons
+.nav-secondary
+  +below($breakpoint-menu)
+    display: none !important
index 75139e03aa5d8731edb80a263158ba0b05169d30..19abb4187541306e0fba8079fd3b875f78ac5820 100644 (file)
@@ -20,6 +20,11 @@ $title_bg = rgba(#fff, 0.88)
     constrain(left, 5vw)
     constrain(bottom, 10vw)
 
+    +below(600px)
+      position: static
+      left: 0
+      bottom: 0
+
   // Note: for the title to have a semi-transparent background,
   // we're limited by the font properties because the inline
   // backgrounds can't overlap so we need to get the line-height
@@ -27,23 +32,24 @@ $title_bg = rgba(#fff, 0.88)
   // solid white... More details:
   // https://iamvdo.me/en/blog/css-font-metrics-line-height-and-vertical-align
   &-title
-    position: relative
-    line-height: 1.27
-    padding-right: 1rem // To match inline text below
+    .header-slideshow & // Extra specificity needed to override generic headings
+      position: relative
+      line-height: 1.27
+      padding-right: 1rem // To match inline text below
 
-    &:before
-      top: 0.6em
-      left: -0.5em
-      width: 0.7em
-
-    // For multi-line padded text effect
-    // Ref: https://css-tricks.com/multi-line-padded-text/
-    &-text
-      @apply text-3xl
-      box-decoration-break: clone
-      display: inline
-      padding: 0 1rem
-      background-color: $title_bg
+      &:before
+        top: 0.6em
+        left: -0.5em
+        width: 0.7em
+
+      // For multi-line padded text effect
+      // Ref: https://css-tricks.com/multi-line-padded-text/
+      &-text
+        @apply text-3xl
+        box-decoration-break: clone
+        display: inline
+        padding: 0 1rem
+        background-color: $title_bg
 
 
   // Need to position this absolutely so it sits properly