fbook Posted May 2, 2022 Share Posted May 2, 2022 Site URL: https://jaycefox.squarespace.com/ Can anyone suggest a code that will allow these captions to only appear on hovers? The site's url is https://jaycefox.squarespace.com and the password is "fox" Here is the code I am currently using... p.gallery-caption-content { font-size: 22px !important; } figcaption.gallery-caption.gallery-caption-grid-masonry { position: absolute; bottom: 0; background: rgba(0,0,0,0.5); color: white; left: 0; text-align: center; img:hover } Link to comment
tuanphan Posted May 7, 2022 Share Posted May 7, 2022 On 5/3/2022 at 6:34 AM, fbook said: Site URL: https://jaycefox.squarespace.com/ Can anyone suggest a code that will allow these captions to only appear on hovers? The site's url is https://jaycefox.squarespace.com and the password is "fox" Here is the code I am currently using... p.gallery-caption-content { font-size: 22px !important; } figcaption.gallery-caption.gallery-caption-grid-masonry { position: absolute; bottom: 0; background: rgba(0,0,0,0.5); color: white; left: 0; text-align: center; img:hover } Can you enable Caption first? Then we can check & give code easier 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!) Link to comment
tuanphan Posted May 14, 2022 Share Posted May 14, 2022 On 5/11/2022 at 10:37 PM, fbook said: Done, thanks so much. Hi, I don't see any caption. Can you check it again? fbook 1 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!) Link to comment
fbook Posted May 16, 2022 Author Share Posted May 16, 2022 (edited) Yes, up now. Had to remove it as it didn't function so well and I was expecting visitors from an online promotion. Thanks in advance for your help. Edited May 16, 2022 by fbook expanded communication Link to comment
Solution tuanphan Posted May 20, 2022 Solution Share Posted May 20, 2022 On 5/16/2022 at 11:37 PM, fbook said: Yes, up now. Had to remove it as it didn't function so well and I was expecting visitors from an online promotion. Thanks in advance for your help. Try adding this to Design > Custom CSS body.homepage { /* Masonry hover 2 */ figure.gallery-grid-item { position: relative; } .gallery-caption, .gallery-caption-wrapper { position: static !important; z-index: 100 !important; top: unset; transform: unset; height: initial; opacity: 1 !important; } /* title */ .gallery-caption-content { position: absolute; left: 0; top: 0; right: 0; bottom: 0; display: flex; justify-content: center; align-items: center; z-index: 999; padding: 7%; transition: opacity ease 200ms !important; opacity: 0 !important; pointer-events: none; } .gallery-masonry-item:hover .gallery-caption-content { opacity: 1 !important; } /* overlay */ .gallery-masonry-item-wrapper a:after { background: rgba(0,0,0,0.5); /* overlay color */ content: ""; display: block; position: absolute; top: 0; left: 0; right: 0; bottom: 0; opacity: 0; transition: opacity ease 200ms !important; } .gallery-masonry-item:hover .gallery-masonry-item-wrapper a:after { opacity: 0.75; } /* remove gap */ figcaption { padding: 0 !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!) Link to comment
fbook Posted May 20, 2022 Author Share Posted May 20, 2022 That's nice, works well! Thanks so much for your time and expertise. Link to comment
lainecarlsness Posted August 18, 2022 Share Posted August 18, 2022 Hi there. I've placed this code in my site, and it works, with the exception of the background color on hover – I've changed the rgba values and there remains no change on hover. Gallery is mid homepage. Help? Thanks! https://wrasse-green-4b2l.squarespace.com/home Link to comment
tuanphan Posted August 20, 2022 Share Posted August 20, 2022 On 8/19/2022 at 12:58 AM, lainecarlsness said: Hi there. I've placed this code in my site, and it works, with the exception of the background color on hover – I've changed the rgba values and there remains no change on hover. Gallery is mid homepage. Help? Thanks! https://wrasse-green-4b2l.squarespace.com/home What is access password? 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!) Link to comment
lainecarlsness Posted August 24, 2022 Share Posted August 24, 2022 pw = traci thanks! Link to comment
tuanphan Posted August 27, 2022 Share Posted August 27, 2022 On 8/24/2022 at 11:42 PM, lainecarlsness said: pw = traci thanks! Use this new code /* Gallery Section Masonry Hover */ figure.gallery-masonry-item { position: relative; } .gallery-caption { position: static; } /* title */ figcaption.gallery-caption .gallery-caption-wrapper p.gallery-caption-content { position: absolute; left: 0; top: 0; right: 0; bottom: 0; display: flex; justify-content: center; align-items: center; z-index: 999; padding: 7%; transition: opacity ease 200ms !important; opacity: 0 !important; pointer-events: none; } .gallery-masonry-item:hover .gallery-caption-wrapper p.gallery-caption-content { opacity: 1 !important; } /* overlay */ .gallery-masonry-item-wrapper a:after, .gallery-masonry-item-wrapper:after { background: rgba(0,0,0,0.95) !important; /* overlay color */ content: ""; display: block; position: absolute; top: 0; left: 0; right: 0; bottom: 0; opacity: 0; transition: opacity ease 200ms !important; pointer-events: none; } .gallery-masonry-item:hover .gallery-masonry-item-wrapper a:after, .gallery-masonry-item:hover .gallery-masonry-item-wrapper:after { opacity: 0.75; } /* remove gap */ figcaption { padding: 0 !important; } Then you can adjust overlay color in this line background: rgba(0,0,0,0.95) !important; /* overlay color */ 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!) Link to comment
dawn Posted August 29, 2022 Share Posted August 29, 2022 Hi - I would also like to use this for a masonry gallery that I am just setting up. I tried the code but didn't work for me. Here's the site: https://gerbil-herring-9m5e.squarespace.com PW:foodwine01! This is for the talent page - guest chefs grid. I've turned on captions. Thank you! Link to comment
dawn Posted August 29, 2022 Share Posted August 29, 2022 Hi - nevermind the 2nd code just worked - genius! Link to comment
dawn Posted August 29, 2022 Share Posted August 29, 2022 I do have one more question - how to I change the type color on rollover to white on caption and make it bold? I'm sure it's in a setting but not sure where. Thank you. Link to comment
tuanphan Posted August 29, 2022 Share Posted August 29, 2022 5 hours ago, dawn said: I do have one more question - how to I change the type color on rollover to white on caption and make it bold? I'm sure it's in a setting but not sure where. Thank you. edit this code figcaption { padding: 0 !important; } to this figcaption { padding: 0 !important; } figcaption * { color: white !important; font-weight: bold !important; } sprecktor 1 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!) Link to comment
dawn Posted August 29, 2022 Share Posted August 29, 2022 This worked perfectly - thank you again! Link to comment
sprecktor Posted January 31, 2023 Share Posted January 31, 2023 I have one more question on this topic. I want to make the text bigger, which I was able to do by just adding the following to to the code Tuanphan provided above. But when going mobile it's way to big and needs to be flexible. Is there anyway to make this happen? figcaption { padding: 0 !important; } figcaption * { color: white !important; font-weight: bold !important; font-size: 30px !important; } Link to comment
tuanphan Posted February 1, 2023 Share Posted February 1, 2023 15 hours ago, sprecktor said: I have one more question on this topic. I want to make the text bigger, which I was able to do by just adding the following to to the code Tuanphan provided above. But when going mobile it's way to big and needs to be flexible. Is there anyway to make this happen? figcaption { padding: 0 !important; } figcaption * { color: white !important; font-weight: bold !important; font-size: 30px !important; } Add this under the code @media screen and (max-width:767px) { figcaption * { font-size:20px !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!) Link to comment
Zuania Posted April 25, 2023 Share Posted April 25, 2023 (edited) Hi! Thank you for this code! I do want to change something. I want the captions to appear under each photo instead of on top of it and become bold. Here is my page: zuania.com Where I implemented the code was in the commercial tab. Thank you! Edited April 25, 2023 by Zuania Link to comment
tuanphan Posted April 25, 2023 Share Posted April 25, 2023 9 hours ago, Zuania said: Hi! Thank you for this code! I do want to change something. I want the captions to appear under each photo instead of on top of it and become bold. Here is my page: zuania.com Where I implemented the code was in the commercial tab. Thank you! Can you enable caption first? Currently I don't see any caption 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!) Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment