You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
736 B
21 lines
736 B
(function ($, Drupal) { |
|
Drupal.behaviors.mtWaypointsAnimations = { |
|
attach: function (context, settings) { |
|
$("body:not(.path-admin) [data-animate-effect]", context).once('mtWaypointsAnimations').each(function() { |
|
var thisObject = $(this); |
|
var animation = thisObject.attr("data-animate-effect"); |
|
if(animation != "no-animation") { |
|
var waypoints = thisObject.waypoint(function(direction) { |
|
var animatedObject = $(this.element); |
|
setTimeout(function() { |
|
animatedObject.addClass("animated " + animation); |
|
}, 100); |
|
this.destroy(); |
|
},{ |
|
offset: "75%" |
|
}); |
|
} |
|
}); |
|
} |
|
}; |
|
})(jQuery, Drupal);
|
|
|