Jump to content
Search Community

daniel.mt last won the day on August 27 2022

daniel.mt had the most liked content!

daniel.mt

Business
  • Posts

    34
  • Joined

  • Last visited

  • Days Won

    1

Community Answers

  1. daniel.mt's post in Horizontal Scroll Error was marked as the answer   
    Hi and welcome
     
    You don't have a panel class. Your panel is in fact hs-img. Here:
     

    See the Pen WNzVJqE by danielmtd (@danielmtd) on CodePen
  2. daniel.mt's post in Basic scrolltrigger animation not resetting on page refresh was marked as the answer   
    Hey,
     
    Most probably the min_tallestBox() and min_highesBoxes() were the main issues. You can try fiddling with it by removing the refresh from the document.ready and check if the issue reoccurs.
     
    It's no harm if you're adding it multiple times most probably the method already verifies if start / end position has truly changed or not so is up to you.

    As a word of advice I would refactor the top code like this :
     
    // Add bottom padding to blocks before $(document).ready(function() { $(".expanding-video").prev().addClass("bottom-excess-video"); $(".expanding-image").prev().addClass("bottom-excess-image"); $(".expanding-video").next().addClass("top-excess-video"); $(".expanding-image").next().addClass("top-excess-image"); // try to remove this ScrollTrigger.refresh() and see if the issue appears. ScrollTrigger.refresh() });
  3. daniel.mt's post in Scrolling text with images changing on left was marked as the answer   
    Hi,
     
    In this case you could check before applying .fromTo tween if the selector has opacity.
     

    See the Pen 3412541bd1c27591de127aeb3c5f8eb4 by danielmtd (@danielmtd) on CodePen
     
    For more details on how to use getProperty https://greensock.com/docs/v3/GSAP/gsap.getProperty
     
×
×
  • Create New...