Jump to content
Search Community

blue-infinity

Members
  • Posts

    14
  • Joined

  • Last visited

Posts posted by blue-infinity

  1. Hello, 

    we've just release a website using ScrollTrigger and found out there was an issue when you use pin:true and switch tab,

    you can replicate the issue here: https://www.museeatelier-audemarspiguet.com/en/about/tradition-forward-thinking.html

    if you scroll down the page to reach the footer, switch tab, come back to the previous one, ScrollTrigger is repositioning the component in the middle of the page

     

    I found a hack to fix the issue:

     

    let style = ''
    document.addEventListener('visibilitychange', () => {
      if (document.visibilityState === 'hidden') {
        style = this.$refs.container.getAttribute('style')
      }
      if (document.visibilityState === 'visible') {
        this.$refs.container.setAttribute('style', style)
      }
    })

     

    if I listen to the tab change an set the style to it's previous state when coming back to the tab, it's solving my problem, but maybe there is a better way to do it

    thanks in advance for the help

    Screenshot_2020-06-25_at_08_50_57.png

    See the Pen tradition-forward-thinking.html by en (@en) on CodePen

  2. 53 minutes ago, GreenSock said:

    I'm not terribly familiar with Hammer.js - we have no plans to duplicate all its functionality, but is there something in particular you want to request? 

    I use Draggable and Throwprops on zoomed images in order to scroll them (closup of a product for instance). I'd like to be able to zoom in/out with multi touch devices.

  3. Hi,

     

    I would want to know if it is possible tu use premium plugins with the npm package (without having to download the package from my account).

    If it is not possible do you plan to have like a key to unlock the premium plugins using the npm package ?

     

    Thanks.

  4. Wow, such a quick support!

    I really want to keep the crossfade between images because we remove a lot of frames from the original video so I can't use a spritesheet. It's also very hard to me to show you a use case due to a the amount of images (that's being said I love codepen.io).

    Rodrigo found a part of the solution. Since I was on localhost I thought that image loading was instantly but in fact not for such amount + some canvas stuff.

    So I try with a time out and it is OK now, there is still a small ghost effect but it is fine.

    setTimeout(function () {
    var tweenDuration = .2;
    var staggerDelay = tweenDuration * 0.5;
    TweenMax.staggerFromTo($('.video-transparent__img', view.root), tweenDuration, {css:{alpha:0}, ease:Linear.easeNone}, {css:{alpha:1}, repeat:1, yoyo:true, repeatDelay:.0, ease:Linear.easeNone}, staggerDelay);
    }, 5000);

    I will preload the images (with LoaderMaxJS maybe one day ?  :mrgreen:)

     

    Thanks a lot for your help everyone.

    • Like 1
  5. Hi,

     

    I would like to animate a sequence PNG (300 images) with a really quick crossfade transition between image switch to emulate a movie effect.

    I've tried multiple ways to achieve it (Timeline and Stagger).

    There is always a blink between images. Is it a performance issue or am I missing something with my timings ?

    TweenMax.staggerFromTo($('.video-transparent__img', view.root),.1, {css:{alpha:0}, ease:Linear.easeNone}, {css:{alpha:1}, repeat:1, yoyo:true, repeatDelay:.05, ease:Linear.easeNone}, .1);

    Is it the right way to achieve it or is there another ?

     

    Thanks.

×
×
  • Create New...