• Resolved wschuurman

    (@wschuurman)


    I noticed that on mobile the aspect ratio for the slick slider is not maintained.

    Here is a screenshot of how the slider looks on a regular desktop screen:
    slider on desktop screen

    Here is how it looks on mobile:
    slider on mobile

    You see how the image does not resize on a narrower screen? It cuts off some of the sides. How can I set it so that it resizes so that the entire image is visible on a narrower screen?

    You can see the slider at the bottom of this page: https://hbcwr.ca

    The shortcode I use is as follows:

    [slick-carousel-slider category=”251″ slidestoshow=”3″ image_size=”original” centermode=”true” variablewidth=”true”]

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hello,

    Please put below css in your themes css file

    .slick-image-slide img
    {
    height: auto !important;
    width: auto !important;
    object-fit: none;
    object-position: unset;
    }

    And check. It should be work.

    Thanks & Regards
    WP Online Support

    Thread Starter wschuurman

    (@wschuurman)

    That did the trick! Thanks for the help and for the quick reply!

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Keeping Aspect Ratio’ is closed to new replies.