Jump to content

FIT IMAGES INSIDE OF A HORIZONTAL CAROUSEL CONTAINER

Recommended Posts

Hello, I would like for my images, both horizontal and vertical, to have the same height within my carousel container without having to assign a universal crop to the images.  Right now it looks like this: image.thumb.png.fa07649aca35cf43c458087bc47be4f7.png

 

I would really love for it to look like this:

image.thumb.jpeg.7957dd9f76227cc363036a8aded175b8.jpeg

 

Where the horizontal images are full size (matching the height of the vertically oriented images.  

Is there any CSS or some other way I could make this happen? 

 

Thanks in advance for the help.

 

Roberto 

Link to comment
  • Replies 7
  • Views 1.4k
  • Created
  • Last Reply

Top Posters In This Topic

Remove this code from custom css:

.user-items-list-carousel__media {
    object-fit: contain !important;
}

if the above code in not in the custom css, then add this code:

.user-items-list-carousel__media {
    object-fit: cover !important;
}

Link to comment
  • 5 months later...
  • 2 weeks later...

Create an account or sign in to comment

You need to be a member in order to leave a comment


×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.