• Resolved Maiskolben

    (@maiskolben)


    Seems, that I have a problem with timeline express after a tab-change with jQuery tabs (I’m using Easytab). Everytime when I reload a tab, the tab where I’m using the timeline is initially hidden. So when I’m browsing to the tab, timeline will not appear.

    My question is, how to init or trigger the timeline after tab-change. There are some hooks as after-event-firing in easytabs, so I can trigger an event. Do somebody know how I can manage this?

    Kind regards, Maiskolben

    https://www.ads-software.com/plugins/timeline-express/

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter Maiskolben

    (@maiskolben)

    Hey Guys,

    just figured it out:

    .bind('easytabs:after',function() {
        mapp0.resize(); // for the mappress google shit
    
        $j( '#cd-timeline' ).masonry(); // starting the masonry builder after tab-change
        $j('.cd-timeline-block').each(function(){ // start to check if its hidden or not
      		if($j(this).offset().top > $j(window).scrollTop()+$j(window).height()*0.75) {
      			$j(this).find('.cd-timeline-img, .cd-timeline-content').addClass('is-hidden');
      		}
      	});
      	$j(window).on('scroll', function(){ // bounce in if class is-hidden
    			$j('.cd-timeline-block').each(function(){
      			if( $j(this).offset().top <= $j(window).scrollTop()+$j(window).height()*0.75 && $j(this).find('.cd-timeline-img').hasClass('is-hidden') ) {
      				$j(this).find('.cd-timeline-img, .cd-timeline-content').removeClass('is-hidden').addClass('bounce-in');
      			}
    		});
    	});

    Kind regards,

    Maik Solben

    Thread Starter Maiskolben

    (@maiskolben)

    can be closed.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘How to init again after tab-change’ is closed to new replies.