javascript - Jssor - reduce slides on smaller screens -
i working on full-width slider 1 x slides, displaying 4 slides @ time. looks great on large or medium screens, responsive script decrease width of slider on smaller screens drastically still contain 4 slides. there way adjust cols or slidewidth on smaller screens won't resize slides drastically?
$(document).ready(function(){ var jssor_1_options = { $autoplay: true, $autoplaysteps: 4, $fillmode: 5, $cols: 4, $slidewidth: 313, $slidespacing: 15, $slideduration: 800, $slideeasing: $jease$.$outquint, $arrownavigatoroptions: { $class: $jssorarrownavigator$, $steps: 1, }, }; var jssor_1_slider = new $jssorslider$("jssor_1", jssor_1_options); function scaleslider() { var refsize = jssor_1_slider.$elmt.parentnode.clientwidth; if (refsize) { refsize = math.min(refsize, 1920); jssor_1_slider.$scalewidth(refsize); } else { window.settimeout(scaleslider, 30); } } scaleslider(); $(window).bind("load", scaleslider); $(window).bind("resize", scaleslider); $(window).bind("orientationchange", scaleslider); });
Comments
Post a Comment