Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
1 Trả lời
5259 Lượt xem

Good evening everyone,

I'm building a website with the odoo12 website builder and I'm struggling with the slider when I upload an image to the slider everything is okay on the website but the mobile preview is shown with cropped image in the slider.

I tried to change the background image dimensions parameters (fixing the width to 100% and height auto )with the edit mode but it stretches the original image on the website.

Is there a specific dimension for slider images or  a css attribute that I should change ?

Thank you all for the help

Ảnh đại diện
Huỷ bỏ
Tác giả Câu trả lời hay nhất

Hello again , 

I've found a solution to deal with this issue so i'm sharing it if someone will need it in the futur.

In fact the @media queries in the css helped me to achieve my goal all i had to do was to add an @media(max-width:768px)  in the .carousel-inner and .carousel-item classes in the scss files (web) and set the max-width : 100% and the heghit to the value i want and now I was able to change the display of my slider to look responsive on mobile.  

Ảnh đại diện
Huỷ bỏ

Thanks for sharing.

can you help me with the code for odoo 15 please