in swiper slider bg imges not showing properly on tab and mobile devices. Theren;t any issue with large devices. Guide me how to solve the css issue?
in swiper slider bg imges not showing properly on tab and mobile devices
1 reply · opened Sep 23, 2023
Hello,
The .swiper-slide-bg uses background-size:cover to display the Images in the best optimum resolution. You may consider using a different image or background positions for responsive devices based on your requirements as it may work best in this case. Example:
[ch_pre][/ch_pre]
[ch_pre type="css"].device-md .background-position-class { background-position: left center !important; }
.device-sm .background-position-class { background-position: center center !important; }
.device-xs .background-position-class { background-position: 30% 50% !important; }[/ch_pre]
Additionally, you can also consider using a different background-image CSS Property like url('image.jpg'), changing them for different devices as mentioned above.
This will definitely work fine. The Responsive Classes are as follows:
.device-xxl – Class for Larger Devices >=1400px
.device-xl – Class for Large Devices >=1200px to 1399px
.device-lg – Class for Medium Devices >=992px to 1199px
.device-md – Class for Tablets
.device-sm – Class for Landscape Mobiles or Phablets.
.device-xs – Class for Portrait Mobiles
You can also change other CSS Properties using the above codes.
Hope this Helps!
Let us know if we can help you with anything else or if you find any further issues.
Have the same question, or something new?
Sign in to the Canvas dashboard to reply or open your own topic. Canvas owners get direct help from the SemiColonWeb team.
Reply on the dashboard