Carousel auto resize #34202
-
Hey,so I have a carousel with images and it looks good on mobile but on the desktop version since it's smaller when I switch the photo,it enlarges to full size,then gets smaller to normal size again,how do I fix that? It's a really annoying transition here it is Firefox.animal.and.18.more.pages.-.Personal.-.Microsoft.Edge.2021-06-08.00-06-26.mp4 |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
anyway I fixed it. turns out the .carousel item in the bootstrap css(after tweaking everything for the carousel in there form transforms to animations to transitions it turned out to be a simple width problem) was bigger than the actual container and images in it and I had to set the width of the .carousel-item in my css as override to 600px the same width of the images in there and also the div that holds them .carousel-inner or something like that to 600px as well. And then since it broke on mobile and it functioned perfectly on mobile before at 615 px I added a media query to set the sizes back to 100% as in the original bootstrap.css file. So I guess if you have images that are not the standard carousel size you will have to adjust the width to match your images. |
Beta Was this translation helpful? Give feedback.
anyway I fixed it. turns out the .carousel item in the bootstrap css(after tweaking everything for the carousel in there form transforms to animations to transitions it turned out to be a simple width problem) was bigger than the actual container and images in it and I had to set the width of the .carousel-item in my css as override to 600px the same width of the images in there and also the div that holds them .carousel-inner or something like that to 600px as well. And then since it broke on mobile and it functioned perfectly on mobile before at 615 px I added a media query to set the sizes back to 100% as in the original bootstrap.css file. So I guess if you have images that are not th…