/* global-animation.js =================== This file is included in inc-htmlbottom.php if animations are enabled. Please only place animations that are to be site wide in this file, otherwise please place Remember that animations are theme specific, meaning this file only effects the current theme that you are animating, and not every theme across the TemplateOTS platform. See detailed documentation here:- https://docs.google.com/document/d/1n5sWQ8SIr-zjOpTv8YnOTHJapO8WdedjDfbeo-lkqMM/edit#heading=h.lmxb59mpcpe2 */ (function () { /* On Document Loaded ================== Called by Jquery event handler when the document is ready (When content has been loaded) */ $( document ).ready( function() { // If we are not on the home page if( !$("#homepage-div").length ) { // Make sure the page content is invisible TweenMax.set( $("#page-content-wrapper"), { opacity : "0" } ); // Store the element that will have effect var oLogo = ""; // If we have the logo image element if( $(".logo-image").length ) { // Store the logo oLogo = $(".logo-image"); } // If we have no image, we must have text instead else { // Store the logo oLogo = $(".logo-text"); } // Set the left position of the logo to 0% so it is in the correct position TweenMax.set( oLogo, { left : "0%" } ); // Fade the logo in TweenMax.to ( oLogo, 0.4, { opacity : 1, ease: "circ. in" } ); // Fade the footer in TweenMax.to ( $(".footer"), 0.4, { opacity : 1, ease: "circ. in" } ); // If menu items exist if( $(".menu-items").length ) { // Fade the menu items in TweenMax.to ( $(".menu-items"), 0.5, { opacity : 1, ease: "circ. in" } ); } // Add a timeout setTimeout(function() { // Fade the page content in TweenMax.to ( $("#page-content-wrapper"), 1, { opacity : 1, ease: "circ. in" } ); // Fade the hamburger menu in in TweenMax.to ( $(".hamburger-menu"), 0.5, { opacity : 1, ease: "power3.inOut" } ); // Fade the navigation in TweenMax.to ( $(".navigation"), 2, { opacity: "1", ease: "circ. in" } ); }, 150); } }); }());