From b9b1abec554718dd1e9c81cc621c92f330bd98d6 Mon Sep 17 00:00:00 2001 From: nael Date: Wed, 15 May 2019 17:25:15 +0200 Subject: [PATCH] WIP #2685 @7 --- .../cube/src/Elementor/Widgets/Timeline.php | 6 +++--- .../themes/c6/resources/assets/scripts/timeline.js | 11 +++++------ .../c6/resources/assets/styles/widgets/timeline.styl | 9 +++++---- .../c6/resources/views/partials/footer.blade.php | 4 +++- 4 files changed, 16 insertions(+), 14 deletions(-) diff --git a/wp-content/mu-plugins/cube/src/Elementor/Widgets/Timeline.php b/wp-content/mu-plugins/cube/src/Elementor/Widgets/Timeline.php index 0c61a95..98dc449 100644 --- a/wp-content/mu-plugins/cube/src/Elementor/Widgets/Timeline.php +++ b/wp-content/mu-plugins/cube/src/Elementor/Widgets/Timeline.php @@ -131,12 +131,12 @@ class Timeline extends Widget_Base // Rendered content $res = '
'; - $res .= ''; + $res .= ''; $res .= '
'; foreach ($items as $index => $item) { diff --git a/wp-content/themes/c6/resources/assets/scripts/timeline.js b/wp-content/themes/c6/resources/assets/scripts/timeline.js index 6b2d2d5..ac76e8b 100644 --- a/wp-content/themes/c6/resources/assets/scripts/timeline.js +++ b/wp-content/themes/c6/resources/assets/scripts/timeline.js @@ -1,7 +1,6 @@ -import scrollSpy from 'simple-scrollspy'; +/* eslint-disable */ +import Gumshoe from './gumshoe'; // Custom version for C6 -scrollSpy('#timeline-nav', { - offset: -200, - sectionClass: '.timeline-item', - menuActiveTarget: '.timeline-nav-item', -}); +new Gumshoe('#timeline-nav a', { + offset: 50, +}); \ No newline at end of file diff --git a/wp-content/themes/c6/resources/assets/styles/widgets/timeline.styl b/wp-content/themes/c6/resources/assets/styles/widgets/timeline.styl index 90183e4..1aa0812 100644 --- a/wp-content/themes/c6/resources/assets/styles/widgets/timeline.styl +++ b/wp-content/themes/c6/resources/assets/styles/widgets/timeline.styl @@ -20,11 +20,12 @@ &-item display: block margin-bottom: 1.5em - &:hover + @media (hover) // this stops the hover state getting stuck on touch devices + &:hover + color: $colors.orange + &.active + font-size: $font-size.medium color: $colors.orange - //&.active - // font-size: $font-size.medium - // color: $colors.orange &-content padding-right: 144px diff --git a/wp-content/themes/c6/resources/views/partials/footer.blade.php b/wp-content/themes/c6/resources/views/partials/footer.blade.php index e5004fc..bbf2f8c 100644 --- a/wp-content/themes/c6/resources/views/partials/footer.blade.php +++ b/wp-content/themes/c6/resources/views/partials/footer.blade.php @@ -2,7 +2,9 @@