Jump to content

Code needed to make gallery section image height numbers different on WEB and MOBILE

Recommended Posts

Posted

Can you share your website URL and this page/section?

Please like and upvote if my comments were helpful to you. Cheers!

Zygmunt Spray
Squarespace Website Designer
Contact me: 
https://squarefortytwo.com 
Hire me on Upwork!

📈 SEO Space (Referral link)
Ⓜ️ 
Will Myers' Plugins & Tutorials (Referral link)
 🔌 Ghost Squarespace Plugins (Referral link)
 SquareWebsites Plugins (Referral link)
 🔲SQSP Themes (Referral link) 
Spark Plugin (Referral link) 
 🖼️Pinch-to-Zoom Gallery Lightbox Plugin (Referral link) 

 Did I help? Buy me a coffee?

Posted

https://www.elleplank.com/work

The 'work' page. 

If you have a look I have changed the gallery images (2 down from video)  to fit the mobile well but it changes the web and looks terrible. The bottom half of web is the perfect size but looks bad on mobile (see screenshots). 

I just want to have different sizes for mobile and web for these sections 🙂 

Posted

Try this Custom CSS for the first of the two gallery sections:

@media only screen and (max-width:767px) {
  section[data-section-id="656bf2498b9d34223e91f251"] {
    .gallery-reel {
      height: 20vh !important;
    }
  }
}

 

Please like and upvote if my comments were helpful to you. Cheers!

Zygmunt Spray
Squarespace Website Designer
Contact me: 
https://squarefortytwo.com 
Hire me on Upwork!

📈 SEO Space (Referral link)
Ⓜ️ 
Will Myers' Plugins & Tutorials (Referral link)
 🔌 Ghost Squarespace Plugins (Referral link)
 SquareWebsites Plugins (Referral link)
 🔲SQSP Themes (Referral link) 
Spark Plugin (Referral link) 
 🖼️Pinch-to-Zoom Gallery Lightbox Plugin (Referral link) 

 Did I help? Buy me a coffee?

Posted

Thanks so so much Ziggy. If it's not too much of a bother could you tell me the instructions to try the code? 

 

Posted
5 hours ago, ElleP said:

Thanks so so much Ziggy. If it's not too much of a bother could you tell me the instructions to try the code? 

Add it to Custom CSS in the Website Tools panel.

Please like and upvote if my comments were helpful to you. Cheers!

Zygmunt Spray
Squarespace Website Designer
Contact me: 
https://squarefortytwo.com 
Hire me on Upwork!

📈 SEO Space (Referral link)
Ⓜ️ 
Will Myers' Plugins & Tutorials (Referral link)
 🔌 Ghost Squarespace Plugins (Referral link)
 SquareWebsites Plugins (Referral link)
 🔲SQSP Themes (Referral link) 
Spark Plugin (Referral link) 
 🖼️Pinch-to-Zoom Gallery Lightbox Plugin (Referral link) 

 Did I help? Buy me a coffee?

  • 2 weeks later...
Posted

Thanks so much Ziggy! I don't think it worked 😞 

The gallery sections on mobile still cut off - is there a certain height or the S M L that it should be on for it to work or anything? 

Elle 

Posted
On 1/29/2024 at 12:59 PM, ElleP said:

Thanks so much Ziggy! I don't think it worked 😞 

The gallery sections on mobile still cut off - is there a certain height or the S M L that it should be on for it to work or anything? 

Elle 

try this code

@media screen and (max-width:767px) {
body#collection-65376532279ce740ddbf0bda .gallery-reel {
    height: 20vh !important;
}
}

 

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Posted

Thanks so much @tuanphan !! That worked yey!! 

Is it posible to make it work for the rest of the projects down the page?  The first two (Comfit and Christmas look great!) 🙂 

Posted
On 1/31/2024 at 10:49 AM, ElleP said:

Thanks so much @tuanphan !! That worked yey!! 

Is it posible to make it work for the rest of the projects down the page?  The first two (Comfit and Christmas look great!) 🙂 

Other list sections on this page?

https://www.elleplank.com/work

 

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

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.