-
AuthorPosts
-
July 27, 2016 at 11:54 am #665663
Hi everybody,
i would like to add a “hover”-delay for the accordion slider. Everytime i go to the main menu i have to cross the slider and the animation begins. My idea is to prevent the slider from “flipping” by adding a delay of 1 or 2 seconds for the hover.
Thank you very much,
SebastianJuly 29, 2016 at 6:06 am #666482Hey expectmore,
Thank you for using Enfold.
This is possible but you have to modify the js > shortcodes.js file and you can’t do this modification in a child theme. Look for this code around line 3344 (AviaccordionSlider):
if(_self.cssActive) //do a css3 animation { //move the slides transition[_self.property] = _self.transform3d ? "translate3d(" + trans_val + "%, 0, 0)" : "translate(" + trans_val + "%,0)"; //3d or 2d transform? current.css(transition); } else { transition.left = trans_val + "%"; current.stop().animate(transition, 700, 'easeOutQuint'); }
.. replace it with:
if(_self.cssActive) //do a css3 animation { //move the slides transition[_self.property] = _self.transform3d ? "translate3d(" + trans_val + "%, 0, 0)" : "translate(" + trans_val + "%,0)"; //3d or 2d transform? setTimeout( function() { current.css(transition); }, 1000); } else { transition.left = trans_val + "%"; setTimeout( function() { current.stop().animate(transition, 700, 'easeOutQuint'); }, 1000); }
Best regards,
IsmaelAugust 1, 2016 at 5:35 pm #667364Thanks a lot ismael, thats nearly what i was looking for.
The changes in the script now delays the effect for the entered time, but is it does not prevent the slider vom starting with delay at all.
So everytime i “cross” the slider the action starts with delay.Perfect will be if the slider simply ignores the mouse completely for 2 seconds and after the delay it has its “normal” behaviour.
Will that be possible?
Thank you very much,
SebastianAugust 5, 2016 at 5:17 am #668817Hi,
I’m sorry but that will require modifications that we can’t provide here. You might want to hire a freelance developer or contact codeable: http://kriesi.at/contact
Best regards,
Ismael -
AuthorPosts
- You must be logged in to reply to this topic.