Added code for separate Desktop and Mobile and sliders now doesn't show on mobile - Dawn teheme

Solved

Added code for separate Desktop and Mobile and sliders now doesn't show on mobile - Dawn teheme

izzy365
Excursionist
14 1 3

I added code to our website so that we could upload separate files for the desktop and mobile site, but now the slider only shows images on desktop, when you go to mobile it doesn't show. I think because the code is set up for it to show the mobile image but it's not set up to let me add one for sliders, only mobile. I tried to see if i could add the same code for sliders but not having much luck. Could anyone help? As a side not, i also feel like the slider images are coming out a better quality on larger screens than the banner, not sure if there's something in the code reducing the image quality for the banner.

 

Example use of banner image with another mobile image on our homepage www.papersmiths.co.uk

Example use of slider not showing an image on mobile on our brands page - https://www.papersmiths.co.uk/pages/all-brands 

Accepted Solution (1)
Made4uo-Ribe
Shopify Partner
10132 2403 3037

This is an accepted solution.

Yes, I got it. The code Ive shown you is for the banner that prevent the media image to show. Check this code below. Same Instruction.

 

.slideshow__media.banner__media.media {
    display: block;
}

 

And Save. 

Result:

Made4uoRibe_0-1721312362517.png

 

 

 

 

Please don't forget to Like and Mark Solution to the post that helped you. Thanks!

If this fixed your issue, Likes and Accept as Solution are highly appreciated. Coffee tips fuel my dedication.
Get experienced Shopify developers at affordable rates—visit Made4Uo.com for a quick quote!
Need THEME UPDATES but have custom codes? No worries, for an affordable price.

View solution in original post

Replies 5 (5)

Tal19
Shopify Partner
144 27 32

in the file section-image-banner.css

there is this css: 

@media screen and (max-width: 749px) {
.banner__media:first-child {
display: none;
}
}

 

Remove it or change the word none to block.

Need Shopify Development, Customization, or POS Support? PM Me!

Made4uo-Ribe
Shopify Partner
10132 2403 3037

Hi @izzy365 

Just like to clarify, you want to show only 1 slide on the mobile screen? And show all on desktop?

Im not sure which slide. But check this one. 

  1. From you Admin page, go to Online Store > Themes
  2. Select the theme you want to edit
  3. Under the Asset folder, open the main.css(base.css, style.css or theme.css)
  4. Then place the code below at the very bottom of the file.

 

@media screen and (max-width: 749px) {
    /* 3rd slide */
div#Slide-template--17107201491186__slideshow_EfJCrM-3 {
    display: none;
}
    /* 1st slide */
div#Slide-template--17107201491186__slideshow_EfJCrM-1 {
    display: none;
}
    }

 

  • And Save. 
  • The remaining one is the 2nd slide. And please before you add the code take out first the code you added. 
  • Made4uoRibe_0-1721311196498.png
  • This is the code you add. 
  • Result:
  • Made4uoRibe_1-1721311234008.png

     

 

Please don't forget to Like and Mark Solution to the post that helped you. Thanks!

If this fixed your issue, Likes and Accept as Solution are highly appreciated. Coffee tips fuel my dedication.
Get experienced Shopify developers at affordable rates—visit Made4Uo.com for a quick quote!
Need THEME UPDATES but have custom codes? No worries, for an affordable price.
izzy365
Excursionist
14 1 3

Sorry I have not explained it very well.

At the moment no images are showing on mobile for the slider section, because of the code that I added for the homepage banner.

For the homepage banner there is two sections where you can upload images, the first image is the desktop image, and the second is the mobile image.

Because of the fact the slider doesn't have a second image section, it means that it isn't showing an image when on mobile.

I just want it so that all the slides show with an image, currently only text is showing.

Made4uo-Ribe
Shopify Partner
10132 2403 3037

This is an accepted solution.

Yes, I got it. The code Ive shown you is for the banner that prevent the media image to show. Check this code below. Same Instruction.

 

.slideshow__media.banner__media.media {
    display: block;
}

 

And Save. 

Result:

Made4uoRibe_0-1721312362517.png

 

 

 

 

Please don't forget to Like and Mark Solution to the post that helped you. Thanks!

If this fixed your issue, Likes and Accept as Solution are highly appreciated. Coffee tips fuel my dedication.
Get experienced Shopify developers at affordable rates—visit Made4Uo.com for a quick quote!
Need THEME UPDATES but have custom codes? No worries, for an affordable price.
izzy365
Excursionist
14 1 3

Thank you so much - this worked!