Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #1090579

    Hey!

    I’m trying to get an overlay on thumbnail images of a gallery. The gallery looks like this http://up.strila.nl/d12047 and my desired result is this http://up.strila.nl/39e0c3, so with the pink + sign in the center of the image. I’ve tried several CSS options but I’m not getting any good results.

    Can you help me get this right?

    Thanks! Daniel

    #1091991

    Hey Daniel,

    Please try the following css:

    
    #top .avia-gallery .avia-gallery-thumb a:after {
      content: '+';
      color: #d89fde;
      font-size: 45px;
      font-weight: bold;
      top: -165px;
      left: 134px;
      position: relative;
    }
    

    Best regards,
    Victoria

    #1092045

    Hi @Victoria,

    This works great for desktop, but when we go into other viewports it doesn’t stay centered. I tried to use percentages and calculations, but not with the result of the plus sign always staying centered. Any ideas on how to fix this?

    Regards, Daniel

    #1092331

    Hi Daniel,

    You can use media queries to have different values for different screen sizes.

    Best regards,
    Victoria

    #1092338

    Hi @victoria,

    Thanks for your answer, I’m sorry for not telling clearly enough that I am aware of that. In other media queries I tried to use percentages and calculations, but not with the result of the plus sign always staying centered. Any ideas on how to fix this?

    Regards, Daniel

    #1092985

    Hi,
    Please try this instead:

    #top .avia-gallery .avia-gallery-thumb a:after {
      content: '+';
    color: #d89fde;
      font-size: 45px;
      font-weight: bold;
     position: absolute !important; 
      width: 35%;
      height: 40%;
      display:flex!important;
      flex-direction:row!important;
      align-items: center!important;
      justify-content: center!important;
    }

    Best regards,
    Mike

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.