Bootstrap carousel with fixed height: center image horizontally or vertically based on image dimensions

前端 未结 4 2012
借酒劲吻你
借酒劲吻你 2021-02-07 15:05

I have a bootstrap carousel with a fixed height. Here is the CSS:

.carousel-custom .carousel-outer {
  position: relative;
}


@media(min-width: 992px){
    .car         


        
4条回答
  •  暗喜
    暗喜 (楼主)
    2021-02-07 16:10

    Alright, I've been fiddling around for a while now. Ended up with the result below. Hope it helps and answers your question (at least for a small part).

    
        Bootstrap Carousel
        
        
        
        
        
        
    
    
        

    Again, hope it helps!

提交回复
热议问题