sachinchoolur / lightslider

JQuery lightSlider is a lightweight responsive Content slider with carousel thumbnails navigation
http://sachinchoolur.github.io/lightslider/
MIT License
2.04k stars 1.53k forks source link

On most page loads the slider cannot be seen #424

Open acrolink opened 5 years ago

acrolink commented 5 years ago

It works sometimes but most of the time it is not to be seen. Inspecting css/html shows that the code is there but the height of .lSSlideWrapper.usingCss is zero.

AniruddhPurohit commented 5 years ago

when images are large and resized with CSS and if "autoWidth" is set to true, then width of whole <ul> element becomes zero and slider is not to be seen. after loading slider, if we resize the browser window it becomes visible.

LuisHerrero92 commented 5 years ago

when images are large and resized with CSS and if "autoWidth" is set to true, then width of whole <ul> element becomes zero and slider is not to be seen. after loading slider, if we resize the browser window it becomes visible.

This is happening to me too exactly as described here.

haferburg commented 4 years ago
$(window).on("load", function() {
  slider.refresh();
})

Or create the slider on load.