Site logo

[Support request] Tweak Logo Ratio

Home Forums Support [Support request] Tweak Logo Ratio

Home Forums Support Tweak Logo Ratio

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #2604500
    Patrick

    I’m having trouble with my logo being the wrong ratio (lxw) for the theme – particularly with the mobile version. What CSS code can help me tweak the width and height of the logo for both desktop and mobile?

    Secondly, what is the DOM size and how to reduce this? (A large DOM will increase memory usage, cause longer style calculations, and produce costly layout reflows). 914 elements according to page insights:

    —–

    Mental Performance Coaching for Athletes
    Mental Performance Coaching for Athletes

    #2604680
    Leo
    Staff
    Customer Support

    Hi there,

    What CSS code can help me tweak the width and height of the logo for both desktop and mobile?

    I currently do not see a logo on mobile – only a site title. Can you make the logo show so I can provide the best solution possible?

    Thanks.

    Secondly, what is the DOM size and how to reduce this? (A large DOM will increase memory usage, cause longer style calculations, and produce costly layout reflows). 914 elements according to page insights:

    This isn’t a theme-related or theme-specific question so you can find lots of articles on Google that explains the issue and provide some potential solutions.

    #2605493
    Patrick

    I have published the mobile logo. Also getting this from pagespeed on desktop:

    Peak Performance Sports
    Peak Performance Sports

    …uploads/2023-peaksports-logo-lg.png(sportpsychology.b-cdn.net)

    360 x 175 (2.06) (Expected)

    1000 x 175 (5.71)

    #2605996
    Ying
    Staff
    Customer Support

    Your mobile logo image file dimension is 1000px * 175px, while it renders as 114.28px * 20px.

    The mobile logo height matches the menu item height of primary navigation on mobile, you can increase the height at Customizing > Layout > Primary Navigation > Menu Item Height (mobile).

    There’s also a top and bottom padding added to the logo, you can use this CSS to remove the padding:

    .mobile-header-navigation .site-logo.mobile-header-logo img {
        padding-top: 0;
        padding-bottom: 0;
    }
    #2606080
    Patrick

    Thanks–that helps with the mobile logo size. But now the dropdown Navigation items match the logo height. How can I control the spacing between dropdown items?

    Also, do you have the CSS to change the line height in the footer hook section? (Footer Template, generate_footer).

    Patrick

    #2606096
    Ying
    Staff
    Customer Support

    Also, do you have the CSS to change the line height in the footer hook section? (Footer Template, generate_footer).

    Please open a new topic for non-related questions. It’s easier for us to categorize the topics and easier for other users looking for an answer. Thanks for your understanding 🙂

    But now the dropdown Navigation items match the logo height. How can I control the spacing between dropdown items?

    How do you want to control the spacing? Do you want to increase or decrease the spacing?

    #2606172
    Patrick

    I’d like to decrease the spacing on the drop down items in mobile. I’ve set the menu item height to 60px for the logo to display correctly, but then the dropdown items match this height.

    #2606238
    Ying
    Staff
    Customer Support

    In that case, set the value back to 40px and use this CSS in my reply here instead:
    https://generatepress.com/forums/topic/tweak-logo-ratio/#post-2605996

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