From 1f1ff7eb70d960296240075f694e6fe796f014c8 Mon Sep 17 00:00:00 2001 From: Stephen Cameron Date: Mon, 20 Apr 2020 18:57:31 +0200 Subject: [PATCH] Done #3601 @1.25 --- wp-content/themes/CCV/app/setup.php | 4 +++ .../assets/styles/common/spacing.styl | 13 ++++---- .../assets/styles/components/footer.styl | 32 +++++++++++++++++++ .../resources/views/partials/footer.blade.php | 11 ++++--- wp-content/themes/CCV/webpack.mix.js | 2 ++ 5 files changed, 52 insertions(+), 10 deletions(-) diff --git a/wp-content/themes/CCV/app/setup.php b/wp-content/themes/CCV/app/setup.php index 84108c1..fbbc5d8 100755 --- a/wp-content/themes/CCV/app/setup.php +++ b/wp-content/themes/CCV/app/setup.php @@ -150,6 +150,10 @@ add_action('widgets_init', function () { 'name' => __('Footer Column 2', 'ccv'), 'id' => 'sidebar-footer-2' ] + $config); + register_sidebar([ + 'name' => __('Footer Column 3', 'ccv'), + 'id' => 'sidebar-footer-3' + ] + $config); register_sidebar([ 'name' => __('Footer Copyright', 'ccv'), 'id' => 'sidebar-footer-copyright' diff --git a/wp-content/themes/CCV/resources/assets/styles/common/spacing.styl b/wp-content/themes/CCV/resources/assets/styles/common/spacing.styl index cbe004f..b6aa4ab 100644 --- a/wp-content/themes/CCV/resources/assets/styles/common/spacing.styl +++ b/wp-content/themes/CCV/resources/assets/styles/common/spacing.styl @@ -1,12 +1,13 @@ // Apply spacing between elements but not before first one // Ref: https://alistapart.com/article/axiomatic-css-and-lobotomized-owls/ -.spaced > * + * - margin-top: 1.5em -.spaced-lg > * + * - margin-top: 2em +@responsive + .spaced > * + * + margin-top: 1.5em + .spaced-lg > * + * + margin-top: 2em -.spaced-horizontal > * + * - margin-left: 0.75em + .spaced-horizontal > * + * + margin-left: 0.75em // Generate utility classes for padding/margin based on vw units // This will generate classes like pt-1v, pt-2v, pr-1v etc. diff --git a/wp-content/themes/CCV/resources/assets/styles/components/footer.styl b/wp-content/themes/CCV/resources/assets/styles/components/footer.styl index f4fe007..1a0f810 100644 --- a/wp-content/themes/CCV/resources/assets/styles/components/footer.styl +++ b/wp-content/themes/CCV/resources/assets/styles/components/footer.styl @@ -1,4 +1,36 @@ +$breakpoint-footer = 1024px + .site-footer + + &-cols + @apply flex + constrain(padding-bottom, 5vw) + + +below($breakpoint-footer) + @apply flex-col + + // Spacing between column blocks + > * + * + margin-top: 2em + + &-col + @apply w-1/3 + constrain(padding-left, 10vw) + constrain(padding-right, 5vw) + + +below($breakpoint-footer) + @apply w-full + + +below(500px) + padding-left: 35px // Matches capped 5vw on other sections + + > * + * + margin-top: 1.5em + + a:not(.btn) &:hover @apply text-pink + + img + display: inline-block diff --git a/wp-content/themes/CCV/resources/views/partials/footer.blade.php b/wp-content/themes/CCV/resources/views/partials/footer.blade.php index f95bd0c..c2c5d48 100644 --- a/wp-content/themes/CCV/resources/views/partials/footer.blade.php +++ b/wp-content/themes/CCV/resources/views/partials/footer.blade.php @@ -1,11 +1,14 @@