Jump to content

image block hover colour opacity overlay

Go to solution Solved by Ziggy,

Recommended Posts

https://www.annajonesbridal.co.uk/home-new

Hey, im trying to get an image hover effect of a low opacity block colour (#F9F7F1) and can't seem to achieve it.

squarespace 7.1, fluid engine. 

tried a code below but not working


//blog image hovers//

/* promo section Image Overlay */
.fe-3_17_2_1_1699632349214_26131 .content-fill:after {
    content: "";
    position: absolute;
    background-color: rgba(249, 247, 241, 0.5);
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    opacity: 0;
    transition: all 0.3s;
}
.fe-3_17_2_1_1699632349214_26131  .image-block:hover .content-fill:after {
    opacity: 1;
    transition: all 0.3s;
}

 

Screenshot 2023-12-05 at 13.19.27.png

Link to comment
  • Replies 5
  • Views 1.2k
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

  • Solution

You can try this adjustment of your code:

#block-yui_3_17_2_1_1699632349214_26131:after {
    content: "";
    position: absolute;
    background-color: rgba(249, 247, 241, 0.5);
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    opacity: 0.5;
    transition: ease-in-out 0.3s;
}
#block-yui_3_17_2_1_1699632349214_26131:hover:after {
    opacity: 1;
    transition: ease-in-out 0.3s;
}

 

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!

🔌 Ghost Squarespace Plugins (Referral link)
📈 SEO Space (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?

Link to comment
1 hour ago, Ziggy said:

You can try this adjustment of your code:

#block-yui_3_17_2_1_1699632349214_26131:after {
    content: "";
    position: absolute;
    background-color: rgba(249, 247, 241, 0.5);
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    opacity: 0.5;
    transition: ease-in-out 0.3s;
}
#block-yui_3_17_2_1_1699632349214_26131:hover:after {
    opacity: 1;
    transition: ease-in-out 0.3s;
}

 

i changed one line with the opacity but apart from that it was perfect!!! thank you so much

 

however haha, its taken away the ability to click on the image which should take you to a different page hmm!

 

/*promo section image hover Overlay */
#block-yui_3_17_2_1_1699632349214_26131:after {
    content: "";
    position: absolute;
    background-color: rgba(249, 247, 241, 0.5);
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    opacity: 0;
    transition: ease-in-out 0.3s;
}
#block-yui_3_17_2_1_1699632349214_26131:hover:after {
    opacity: 1;
    transition: ease-in-out 0.3s;
}

Link to comment

Try adding this to the code:

pointer-events: none;

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!

🔌 Ghost Squarespace Plugins (Referral link)
📈 SEO Space (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?

Link to comment

Nice one! Glad that worked!

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!

🔌 Ghost Squarespace Plugins (Referral link)
📈 SEO Space (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?

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.