Jump to content

Need some help overlaying text+button on image list section on hover.

Recommended Posts

  • ysong changed the title to Need some help overlaying text+button on image list section on hover.
On 1/31/2023 at 10:37 PM, ysong said:

Site: https://countryhousereskin.squarespace.com/

Hi! 

I'm trying to figure out how to move the title + description + button text to appear on the images on hover.

This is what I currently have: 

image.thumb.png.e5524060cd97e5a8b5a7e977993ac06f.png

And this is what I am trying to achieve: 

image.thumb.png.3b3809b88ea2b64cb01ba132f9d03726.png

 

Any help would be greatly appreciated! Thank you in advance.

What is your site-wide password?

BeyondSpace - Squarespace Website Developer

🖼️ Lightbox Studio (Enable Pinch/Zoom on lightbox)
🗓️ Delivery Date Picker (Squarespace Date picker form field)
💫 Gallery block 7.1 workaround
🥳 Sparkplugin Customisations Browsers (Browse +100 Spark plugin customisations)
🥳 Elfsight Template Browsers (Browse +1000 Elfsight widget Templates)

If you find my answer useful, let's leave a like or upvote so others with the same issue can find their solution. Thank you!

 

Link to comment

You can try adding to Home > Design > Custom Css

section[data-section-id="63cf1cfad1bc0a76155acde9"] .user-items-list-simple .list-item-content{
  position: absolute;
  background: rgba(0,0,0,0.5);
  height: 100%;
  width: 100%;
  top:0;
  left: 0;
  justify-content: center !important;
  opacity: 0;
  transition: opacity 0.5s ease-in-out;
}
section[data-section-id="63cf1cfad1bc0a76155acde9"] .list-item {
  position: relative;
}
section[data-section-id="63cf1cfad1bc0a76155acde9"] .user-items-list-simple .list-item:hover .list-item-content {
  opacity: 1;  
}
section[data-section-id="63cf1cfad1bc0a76155acde9"] .list-item-content__text-wrapper {
  --list-section-simple-card-description-color: #fff;
  --list-section-simple-card-title-color: #fff;
}
section[data-section-id="63cf1cfad1bc0a76155acde9"] .list-item p strong {
  color: #fff;
}

Support me by pressing 👍  or marking as solution if this useful for you

BeyondSpace - Squarespace Website Developer

🖼️ Lightbox Studio (Enable Pinch/Zoom on lightbox)
🗓️ Delivery Date Picker (Squarespace Date picker form field)
💫 Gallery block 7.1 workaround
🥳 Sparkplugin Customisations Browsers (Browse +100 Spark plugin customisations)
🥳 Elfsight Template Browsers (Browse +1000 Elfsight widget Templates)

If you find my answer useful, let's leave a like or upvote so others with the same issue can find their solution. Thank you!

 

Link to comment

My testing

image.png.ca8a4c1497da30a4b906e1c8d51efd2c.png

BeyondSpace - Squarespace Website Developer

🖼️ Lightbox Studio (Enable Pinch/Zoom on lightbox)
🗓️ Delivery Date Picker (Squarespace Date picker form field)
💫 Gallery block 7.1 workaround
🥳 Sparkplugin Customisations Browsers (Browse +100 Spark plugin customisations)
🥳 Elfsight Template Browsers (Browse +1000 Elfsight widget Templates)

If you find my answer useful, let's leave a like or upvote so others with the same issue can find their solution. Thank you!

 

Link to comment
On 1/31/2023 at 3:37 PM, ysong said:

Need some help overlaying text+button on image list section on hover.

As I mentioned in a previous thread, it would be better to show this information all the time. By only showing this information on hover, visitors using mobile devices (typically the largest proportion of visitors) will not see this essential information about each property. All they will see are the images:

image.thumb.jpeg.4cef9daa94d5e3beab58183381b63254.jpeg

Did this help? Please give feedback by clicking an icon below  ⬇️

About me: I've been a SQSP User for 18 yrs. I was invited to join the Circle when it launched in 2016. I have been a Circle Leader since 2017. I don't work for Squarespace. I value honesty, transparency, diversity and good design ♥.
Work: I founded and run SF.DIGITAL, building Squarespace Extensions to supercharge your commerce website. 
Content: Views and opinions are my own. Links in my posts may refer to SF.DIGITAL products or may be affiliate links.
Forum advice is free. You can thank me by clicking one of the feedback emojis below. Coffee is optional.

Link to comment

Thanks @paul2009 suggestion, we can also set this style only on dekstop by wrapping the above code with

@media query and (min-width:768px) {

 

}

BeyondSpace - Squarespace Website Developer

🖼️ Lightbox Studio (Enable Pinch/Zoom on lightbox)
🗓️ Delivery Date Picker (Squarespace Date picker form field)
💫 Gallery block 7.1 workaround
🥳 Sparkplugin Customisations Browsers (Browse +100 Spark plugin customisations)
🥳 Elfsight Template Browsers (Browse +1000 Elfsight widget Templates)

If you find my answer useful, let's leave a like or upvote so others with the same issue can find their solution. Thank you!

 

Link to comment
  • 11 months later...
On 2/3/2023 at 12:33 AM, Beyondspace said:

You can try adding to Home > Design > Custom Css

section[data-section-id="63cf1cfad1bc0a76155acde9"] .user-items-list-simple .list-item-content{
  position: absolute;
  background: rgba(0,0,0,0.5);
  height: 100%;
  width: 100%;
  top:0;
  left: 0;
  justify-content: center !important;
  opacity: 0;
  transition: opacity 0.5s ease-in-out;
}
section[data-section-id="63cf1cfad1bc0a76155acde9"] .list-item {
  position: relative;
}
section[data-section-id="63cf1cfad1bc0a76155acde9"] .user-items-list-simple .list-item:hover .list-item-content {
  opacity: 1;  
}
section[data-section-id="63cf1cfad1bc0a76155acde9"] .list-item-content__text-wrapper {
  --list-section-simple-card-description-color: #fff;
  --list-section-simple-card-title-color: #fff;
}
section[data-section-id="63cf1cfad1bc0a76155acde9"] .list-item p strong {
  color: #fff;
}

Support me by pressing 👍  or marking as solution if this useful for you

Hi @Beyondspace could you help me replicate this on my list carousel? Its the first carousel on my home page: www.aqrtraining.com under 'The AQR Experience'. Thank you!!

Link to comment
  • 2 months later...

By the way, in case anyone wants a tweaked version of this code to do as @paul2009 recommends, which is to show the content all the time and not just on hover, AND a slightly cleaner version of the code here you go:

section[data-section-id="66152fcfd9786310fc238c05"] {
.user-items-list-simple .list-item-content {
  position: absolute;
  background: rgba(0,0,0,0.2);
  height: 100%;
  width: 100%;
  top:0;
  left: 0;
  justify-content: center !important;
}
.list-item {
  position: relative;
}
.list-item-content__title {
color: #fff !important;
}
.list-item-content__description {
  color: #fff !important;
}
}

It reduces the need to repeat the section ID so much, making it much easier to target multiple section IDs to apply this code to multiple sections or pages (just separate your multiple ID declarations on the top line with a comma).

Edited by usingmyhead
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.