• Resolved Corey Worrell

    (@coreyw)


    When using the compact layout option, the calculation in /cool-timeline/assets/js/ctl_compact_scripts.min.js that applies the extra height to the parent wrapper is being applied after every timeline element, so the height of the wrapper is being “shrunk” down to the size of 1 element, and then increased as the loop continues. This causes the entire page to scroll back up as the browser sees the wrapper height has been shrunk down to be very short, and then once the loop is completed the scroll stays at the top.

    The easiest fix is to only apply the $(parent_wrapper).css({height:firstBottom+'px'}) once the loop has completed (or add a conditional to make sure it is on the last element in the loop).

    Related: https://wordpress.org/support/topic/timeline-jumps-back-to-top-when-scrolling-on-iphone-mobile/

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Support aniketji

    (@aniketji)

    Hi @coreyw,

    Thanks for using our plugin.

    Thank you for reaching out about the compact layout issue in Cool Timeline.
    We’ve tested this on our end, and it’s working fine. The problem might be due to a conflict with one of your other plugins. To check, please try deactivating your plugins one by one and see if the issue persists.

    Let us know the results, and we’ll assist accordingly.

    Thanks & Regards.

    Thread Starter Corey Worrell

    (@coreyw)

    I’m sorry, but this is not a plugin conflict. It’s directly caused by the code in this plugin file I mentioned above. It happens for sure on iPhone, and in Firefox. If you have a long timeline, scroll halfway down, resize the viewport, and you’ll see it scrolls back up near the top of the timeline. This happens often on the iPhone since the viewport changes as the address bar is shown/hidden while you scroll.

    Plugin Support aniketji

    (@aniketji)

    Hi @coreyw,

    Can you please share a screenshot or screen recording with us so we can accurately assess the issue you are experiencing?

    Thanks & Regards.

    Plugin Author CoolHappy

    (@narinder-singh)

    Hi there,

    Due to a lack of response from your end, we are closing this thread. If you are still experiencing any issues, please create a new topic here:

    https://wordpress.org/support/plugin/cool-timeline/#new-topic-0

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Compact layout jumps to top when window resized (mobile scroll too)’ is closed to new replies.