Okay
  Public Ticket #2561242
Setting precize image size in px
Closed

Comments

  • bghelsinki started the conversation

    Dear all,

    Couldn't find an answer to my question in the theme documentation, hence the ticket.

    I am trying to make a page where different images around the page have the same size. The files themselves are with different sizes. I am using the 'Single Image' element of the page builder to insert the images. Unfortunately, I don't see any sizing options except the Desktop Max Width and the Mobile Max Width dropdown options in the element's settings. And the options there are in percentages that are relative to the image size. Which does not really work for me when image sizes are different. Is there a way to set the size in pixels?

    Thanks in advance!

  •  2,965
    Andrew replied

    Hi There,

    Thank you for reaching us.

    Please paste this CSS custom code on Salients Theme Options>General>CSS/Script Related :

    .img-with-aniamtion-wrap .hover-wrap .hover-wrap-inner img.img-with-animation {
        width: 219px;
        height: 205px;
    }
    

    Hope this helps.

    Regards

  • bghelsinki replied

    Thank you! It worked indeed but it made all the pictures in the entire website the same size. :) Can I maybe achieve the same but only for the pictures on certain page like here: https://newsite.humanoftheyear.org/chovek-na-godinata-2019/

    Can it be that there is no custom image sizing function? At all?

  •  2,965
    Andrew replied

    Hi There,

    Thank you for reaching out. 

    Please paste this CSS custom code on Salients Theme Options>General>CSS/Script Related :

    .img-with-aniamtion-wrap[data-border-radius="15px"] .img-with-animation, .img-with-aniamtion-wrap[data-border-radius="15px"] .hover-wrap, .nectar_video_player_self_hosted[data-border-radius="15px"] .wpb_video_wrapper {
        width: 191px !important;
        height: 181px !important;
    }
    

    Hope this helps.

    Regards

  • bghelsinki replied

    Yes, it worked! Thanks!