-
AuthorPosts
-
September 11, 2014 at 3:28 pm #317437
Hey,
What CSS do I need to add so that the hover on my masonry portfolio has a colour of my choosing, and the title appears in the centre, similar to this: http://peacheyphotography.co.uk/
Many thanks.
September 12, 2014 at 4:03 am #317796Hey!
Try adding this code to the Quick CSS:
.av-masonry-entry:before { content: attr(title); background: red; position: absolute; width: 100%; height: 100%; z-index: 1000; text-align: center; line-height: 180px; opacity: 0; font-weight: bold; font-size: 24px; } .av-masonry-entry:hover:before { opacity: 1; } .av-masonry-entry:before{ transition: all linear 0.2s; }
Cheers!
JosueNovember 26, 2014 at 12:33 am #358062Hi Josue,
Can this be done with the standard portfolio grid as well?
Best, David.
November 26, 2014 at 1:34 am #358091Hi David!
Try with this:
.image-overlay { display: none !important; } .grid-image:before { content: attr(title); background: red; position: absolute; width: 100%; height: 100%; z-index: 1000; text-align: center; line-height: 180px; opacity: 0; font-weight: bold; font-size: 24px; } .grid-image:hover:before { opacity: 1; } .grid-image:before{ transition: all linear 0.2s; }
Cheers!
JosueNovember 26, 2014 at 11:05 am #358214This reply has been marked as private.November 26, 2014 at 6:02 pm #358402This reply has been marked as private.November 26, 2014 at 11:58 pm #358660Hey David!
Use this:
.image-overlay-inside:before{ display: none !important; } .image-overlay { background: #ec1164; } .grid-image:before { content: attr(title); position: absolute; width: 100%; height: 100%; z-index: 1000; text-align: center; opacity: 0; font-weight: 200; font-size: 24px; color: #ffffff !important; top: 50%; } .grid-image:hover:before { opacity: 0.9; } .grid-image:before{ transition: all linear 0.2s; } .grid-content { display: none !important; }
Cheers!
JosueFebruary 1, 2015 at 10:29 pm #389071Hi, sorry for the long response. Thanks for the code, but is there anyway to centre the text across all devices? When I shrink the browser down and the masonry grid shrinks, the title on each grid aren’t centered anymore.
February 5, 2015 at 12:32 am #391025Hey!
Hmm, they appear centered on my end on all screen sizes. Clear your browser cache and take a screenshot of what your seeing.
Also let us know what operating system and browser your using.
Regards,
ElliottMarch 16, 2015 at 1:45 pm #412094Hi!
Can i have the title, excerpt and read more button, in the hover of the blog grid?
Like this theme: http://solopine.com/hickory/ but only in hover?Thanks!
March 16, 2015 at 7:51 pm #412497Hey!
Can you post a link to your blog grid?
Regards,
JosueMarch 27, 2015 at 12:33 pm #419226Thats my blog grid:
I did it by negative margin-top of the content.
But i really wanna do it in a php way.Can you help me?
Thanks!March 27, 2015 at 12:33 pm #419227Thats my blog grid:
I did it by negative margin-top of the content.
But i really wanna do it in a php way.Can you help me?
Thanks!March 27, 2015 at 10:59 pm #419661Hi!
I think that’s a valid method, but i’d change it to
position: absolute; top: 0;
like:#block-post article .slide-content { position: absolute; top: 0; }
Regards,
JosueMarch 30, 2015 at 1:39 pm #420383Yes! that was de plus I needed!
Thanks! -
AuthorPosts
- The topic ‘Masonry Portfolio hover colour and centre title’ is closed to new replies.