L
L
leni_m2018-06-13 14:17:51
JavaScript
leni_m, 2018-06-13 14:17:51

Why does the owl carousel display the slide incorrectly?

<div class="owl-carousel">
    <img1>
    <img2>
    <img3>
</div>

the .owl-carousel block has a width of 1267px.
Further:
$('.owl-carousel').owlCarousel({
        items: 1
    });

And the slider calculates the width of one slide (.owl-item) at 1250px, because of which a piece of the next picture crawls out. How to fix?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
T
tyzberd, 2018-06-13
@leni_m

The problem is probably in your styles
https://codepen.io/anon/pen/OEgmqR

P
profesor08, 2018-06-13
@profesor08

I advise you to generally avoid sliders that set any height or width for elements. This immediately puts an end to adaptability and the use of a slider without any crutches.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question