Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #862470

    Jan S
    Participant

    Hi,

    4.4.1 and fade in/out animations stopped working. Most recent Cornerstone and VC, no error..

    Any suggestions?

    Jan

    #863137

    Jade
    Moderator

    Hi Jan,

    Would you mind providing us with login credentials so we can take a closer look? To do this, you can make a post with the following info:

    – Link to your site
    – WordPress Admin username / password
    – FTP credentials

    Don’t forget to select Set as private reply. This ensures your information is only visible to our staff.

    #865477

    Jan S
    Participant
    This reply has been marked as private.
    #865867

    Zeshan
    Member

    Hi Jan,

    Thanks for the login credentials!

    We have updated our columns animation feature to make it more smooth. It seems the change has not been made for Visual Composer columns. I went ahead and fixed the issue for you by creating a vc_column.php file under vc_templates/ directory in your child theme and adding the following code in it:

    <?php
    
    // =============================================================================
    // VC_TEMPLATES/VC_COLUMN.PHP
    // -----------------------------------------------------------------------------
    // Make [vc_column] behave like the [column] shortcode.
    // =============================================================================
    
    ?>
    
    <?php
    
    extract( shortcode_atts( array(
      'id'                    => '',
      'class'                 => '',
      'style'                 => '',
      'width'                 => '',
      'last'                  => '',
      'fade'                  => '',
      'fade_animation'        => '',
      'fade_animation_offset' => ''
    ), $atts ) );
    
    $id    = ( $id    != '' ) ? 'id="' . esc_attr( $id ) . '"' : '';
    $class = ( $class != '' ) ? 'x-column x-sm vc ' . esc_attr( $class ) : 'x-column x-sm vc';
    $style = ( $style != '' ) ? $style : '';
    switch ( $width ) {
      case '1/1' :
        $width = ' x-1-1';
        break;
      case '1/2' :
        $width = ' x-1-2';
        break;
      case '1/3' :
        $width = ' x-1-3';
        break;
      case '2/3' :
        $width = ' x-2-3';
        break;
      case '1/4' :
        $width = ' x-1-4';
        break;
      case '3/4' :
        $width = ' x-3-4';
        break;
      case '1/6' :
        $width = ' x-1-6';
        break;
      case '5/6' :
        $width = ' x-5-6';
        break;
    }
    
    if ( $fade == 'true' ) {
      $fade = ' data-fade="true"';
      $data = cs_generate_data_attributes( 'column', array( 'fade' => true ) );
      switch ( $fade_animation ) {
        case 'in' :
          $fade_animation_offset = '';
          break;
        case 'in-from-top' :
          $fade_animation_offset = ' transform: translate(0, -' . $fade_animation_offset . '); ';
          break;
        case 'in-from-left' :
          $fade_animation_offset = ' transform: translate(-' . $fade_animation_offset . ', 0); ';
          break;
        case 'in-from-right' :
          $fade_animation_offset = ' transform: translate(' . $fade_animation_offset . ', 0); ';
          break;
        case 'in-from-bottom' :
          $fade_animation_offset = ' transform: translate(0, ' . $fade_animation_offset . '); ';
          break;
      }
      $fade_animation_style = 'opacity: 0;' . $fade_animation_offset . 'transition-duration: ' . ( $fade_duration ? $fade_duration : '500' ) . 'ms;';
    } else {
      $data                 = '';
      $fade                 = '';
      $fade_animation_style = '';
    }
    
    $output = "<div {$id} class=\"{$class}{$width}{$last}\" style=\"{$style}{$fade_animation_style}\" {$data} {$fade}>" . do_shortcode( $content ) . "</div>";
    
    echo $output;
    

    Animations should work in your site now. I’ll pass this issue to our development for further investigation.

    Thank you!

    #866112

    Jan S
    Participant

    So this is requires a global update (just to know before i update my other 19 sites)?

    #866708

    Nabeel A
    Moderator

    Hi again,

    For now you’ll need to update the code in the other sites as well, until it is fixed in the future release.

    Cheers!