jssor - responsive slider breaks image ratio on $FillMode: 2 -


when use following code recommended on jssor site (below) make slider reactive ends breaking image ratios if set $fillmode:1 (contain (keep aspect ratio , put inside slide)). guessing there being calculated in background after images loaded before responsive code below triggered potentially call again avert issue recalculating new ratios images have no idea start one, or pointers appreciated!

function scaleslider() {         var parentwidth = $('#slider1_container').parent().width();         if (parentwidth) {             jssor_slider1.$scalewidth(parentwidth);         }         else             window.settimeout(scaleslider, 30);     }     //scale slider after document ready     scaleslider();      //scale slider while window load/resize/orientationchange.     $(window).bind("load", scaleslider);     $(window).bind("resize", scaleslider);     $(window).bind("orientationchange", scaleslider); 

the $fillmode , responsive code work separately in different way.

$fillmode indicates way fill image in each slide.

responsive code scales whole slider according logic specified in scaleslider function.


Comments

Popular posts from this blog

asp.net mvc - SSO between MVCForum and Umbraco7 -

Python Tkinter keyboard using bind -

ubuntu - Selenium Node Not Connecting to Hub, Not Opening Port -