Skip to content

Instantly share code, notes, and snippets.

@aendra-rininsland
Forked from reatcory/slideshow.js
Last active December 12, 2015 00:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save aendra-rininsland/4684237 to your computer and use it in GitHub Desktop.
Save aendra-rininsland/4684237 to your computer and use it in GitHub Desktop.
$('.view-homepage-slider').cycle({
fx: 'fade',
speed: 'slow',
timeout: 0,
before: onBefore,
after: onAfter,
});
function onBefore(curr, next, opts){
// Code to do stuff before the slide changes
$('.views-field-title').slideUp();
$('.views-field-field-homepage-slider-text').slideUp();
}
function onAfter(curr, next, opts){
// Code to do stuff after the slide changes
$('.views-field-title').slideDown();
$('.views-field-field-homepage-slider-text').slideDown();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment