Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
    Posts
  • #902145

    Hi,

    I’m setting up a website with Enfold Child. Many sites contain a masonry with portfolio entries, and I would like to further customise the appearance of the masonries.

    Is it possible to inverse the hover effect of a masonry and at the same time add different overlay colours?

    To be precise: I would like the masonry to look like the grid row (screenshots attached): various, pre-defined overlay colours, which change to the actual portfolio entry image when hovering over.

    Moreover, is it possible to define different masonries of that kind? For example, on page 1 I would like the masonry to appear in different shades of red, whereas on page 2 it should appear in different shades of blue.

    Thank you very much for your support.

    #902667

    Hey jonna_gaertner,

    Yes, that is possible but with extensive css customization.
    Could you please give us a link to your website, we need more context to be able to help you.

    Best regards,
    Victoria

    #902727
    This reply has been marked as private.
    #904190

    Hi,

    Thank you for the info.

    You can use the nth child selector to apply different colors for the masonry items. Example.

    #top .av-caption-style-overlay .av-masonry-item-with-image:nth-child(1) .av-inner-masonry-content {
        background: rgba(6,52,0,0.35);
    }
    
    #top .av-caption-style-overlay .av-masonry-item-with-image:nth-child(2) .av-inner-masonry-content {
        background: rgba(100,200,0,0.35);
    }
    
    #top .av-caption-style-overlay .av-masonry-item-with-image:nth-child(3) .av-inner-masonry-content {
        background: rgba(60,52,255,0.35);
    }

    The css code above will apply 3 different colors for the first 3 masonry items.

    Best regards,
    Ismael

    #904234

    Hi Ismael,
    thanks a lot for your support! It works well :)

    I’ve got one more question: Can I define different overlay colours for masonries on different pages? For example: With the code you provided I have defined masonry overlay colours which I want to use on page 1. Works fine. On page 2, I would like to use a masonry as well – but with other colours. How can I do that?

    Thank you for your help and kind regards!

    #904615

    Hi,

    Yes, that’s possible. Replace the “#top” selector with the page id selector. Example.

    .page-id-1234 .av-caption-style-overlay .av-masonry-item-with-image:nth-child(1) .av-inner-masonry-content {
        background: rgba(100,200,0,0.35);
    }
    
    .page-id-4321.av-caption-style-overlay .av-masonry-item-with-image:nth-child(1) .av-inner-masonry-content {
        background: rgba(6,255,0,0.35);
    }

    The css code above will change the overlay color of the first masonry items inside the page with the id 1234 and 4321.

    Best regards,
    Ismael

    #922822

    Hi,

    I also used your code above (the first one). But what do I have to do when there are more than 3 items?

    This additional line hasn´t worked…

    #top .av-caption-style-overlay .av-masonry-item-with-image:nth-child(4) .av-inner-masonry-content {
    background: rgba(60,52,255,0.35);
    }

    Thansk!

    #922829

    Got it! :)

    #922950

    Hi seykom,

    Glad you got it working for you! :)

    If you need further assistance please let us know.

    Best regards,
    Victoria

    #1087513

    new thread started…

    • This reply was modified 5 years, 7 months ago by jonrouse.
    #1087645

    Hi,

    We will check that new thread.

    Best regards,
    Jordan Shannon

Viewing 11 posts - 1 through 11 (of 11 total)
  • The topic ‘Different overlay colours for the hover effect of a masonry?’ is closed to new replies.