Jump to content

Is it possible to swap an image for a coloured background on mobile only?

Recommended Posts

Site URL: https://pentagon-snail.squarespace.com/lead-magnet

I'm hoping I can switch out a block with an image background, to the same block but with a coloured background only. Have a look and you'll see what I mean – looks great on desktop but on mobile, not so good!

I also need to add work out how to add padding to the button in that block so that it aligns with the text above it (again, on mobile only)

Thank you in advance for any help you can give me!

Site password: kerri2021

Screenshot 2021-12-05 at 13.44.39.png

Screenshot 2021-12-05 at 13.44.25.png

Link to comment
  • Replies 2
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Posted Images

2 hours ago, hannahpellatt said:

Site URL: https://pentagon-snail.squarespace.com/lead-magnet

I'm hoping I can switch out a block with an image background, to the same block but with a coloured background only. Have a look and you'll see what I mean – looks great on desktop but on mobile, not so good!

I also need to add work out how to add padding to the button in that block so that it aligns with the text above it (again, on mobile only)

Thank you in advance for any help you can give me!

Site password: kerri2021

Screenshot 2021-12-05 at 13.44.39.png

Screenshot 2021-12-05 at 13.44.25.png

Do you think it 's suitable on mobile?

image.png.502ee5fbe518ba66b649447534f3539c.png

Try

@media only screen and (max-width: 767px) {
  section[data-section-id="619a12441e813662e1cc027c"] .section-background img {
    object-position: 50% 50% !important;
  }
}

Let me know how it works on your site

Support me by pressing 👍 if this useful for you

Greeting, it's BeyondSpace, I am Squarespace dev focus on provide solutions to enhance feature that squarespace.com can't provide.
Feel free to check my current Squarespace Plugins Developement: Enable Pinch/Zoom on lightbox, Delivery Date Picker, Keyword Highlighter
If you find my answer fit your need, let's leave a like or upvote so others with the same issue can find their solution. Thank you

Link to comment

@hannahpellatt, if you want a no-code option for these design customisations.  I would suggest using SquareKicker's Section Visibility tool.  You can set up two sections.  1 for Desktop and 1 for Mobile and then hide the section you do not want to display giving you the ability to create a unique section just for mobile and desktop.  

You can also you the mobile device toggle and then change vertical block padding to the button block.

Read here for more SquareKicker features: https://squarekicker.com/features 

Note: if you only want these little features, you can get get a single month and cancel, so as a one-off payment all your custom SK changes will be backed up and saved forever. 

SquareKickerHi, I'm Nick, CEO & Co-Founder at squarekicker.com.  Take your Squarespace sites to the next level with SquareKicker's No-Code Design & Animation Extension. Break free from templates & complex code and start building unique websites that you are proud to show your clients without ever having to write a single line of code. 

Tutorials  ●  News  ●  Inspiration  ●  Features  ●  FAQS

 

Link to comment

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.