Swipe icon indicating copy to clipboard operation
Swipe copied to clipboard

A part of the next slide appears. How do I stop that!!

Open rahulmaximus opened this issue 12 years ago • 3 comments

Swipe is awesome!!!.. but I am facing an issue. I wanted the pictures to fully cover the div's whereas what is happening is that the next slide is partially visible (only a small maybe 10px width) .

Any ways of stopping that partial display??

rahulmaximus avatar Aug 10 '13 07:08 rahulmaximus

are all of your images the same size as each other and the exact size of the containing div? If either of those aren't the case you're going to see the next and/or preview slides. If you need to include a smaller image you can put it in an additional containing div and center align the image.

trose avatar Aug 12 '13 16:08 trose

Well I tried using the images with same width still it was throwing that error.Finally I found out the following:

Note I was using the example(provided in the package) as it is and it was overiding my default css. So I wrote my custom css instead of using the style.css which came with the example and it worked

rahulmaximus avatar Aug 12 '13 17:08 rahulmaximus

Hi! I have the same problem, it appears when the container is set to width: 100% in the css.

What I found was that line 57 in swipe.js, "width = container.getBoundingClientRect().width || container.offsetWidth;" .getBoundingClientRect().width and .offsetWidth returns 1169px when the page loads, while the actual width is1186px.

When I resize the browser, it returns the correct width.

Any thoughts to that?

Thanks for a great plugin!

Virrum avatar Aug 14 '13 12:08 Virrum