Site logo

[Support request] Spacious Navigation with centered Logo

Home Forums Support [Support request] Spacious Navigation with centered Logo

Home Forums Support Spacious Navigation with centered Logo

Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #2309968
    Felix

    hey GP team!

    I have used your great tutorial https://docs.generatepress.com/article/header-examples/#example-5 and it works very well.

    Now i would like to get the Logo centered between the burger menu and the search.
    Do i have to use the customizer or do i need some extra css?

    thanks in advance

    #2310448
    Ying
    Staff
    Customer Support

    Hi Felix,

    You will need some CSS to make the logo center.

    You can give this CSS a try:

    .site-branding {
        position: absolute;
        left: 50%;
        transform: translatex(-50%);
    }

    If it doesn’t work, I’ll have to see your site, maybe create a staging site.

    Let me know!

    #2368706
    Felix

    Hey Ying,

    first of all… thanks for your quick reply and sorry for the late answer. 🙂
    unfortunatly it doesnt work like it should. Maybe you could have another look. thx

    #2368958
    David
    Staff
    Customer Support

    Hi there,

    as you want the hamburger on the desktop view, could you go to Customizer > Layout > Header and:

    1. enable the Mobile Header.
    2. Add the Mobile Header Logo

    This will ensure we have a consistent HTML layout for both desktop and mobile.
    Let me know once its done and ill work on the center logo.

    #2368968
    Felix

    Hey David,

    i have set it up. There is a screenshot what i would like to build on the home page.

    CSS via Simple Custom CSS and JS Plugin.

    Thank you.

    #2368974
    David
    Staff
    Customer Support

    One more thing.
    Go to Customizer > Layout > Primary Navigation and in the Mobile Menu Breakpoint field type in 10000

    Let me know

    #2368989
    Felix

    check 🙂

    #2368995
    David
    Staff
    Customer Support

    Try this CSS:

    
    #mobile-header.main-navigation.has-branding .menu-toggle {
        order: -1;
    }
    #mobile-header.main-navigation .menu-bar-items {
        flex-grow: 0;
    }
    #mobile-header .site-logo {
        margin: auto;
        max-width: 200px;
    }

    For the icons – do you have SVGs for those ?

    #2369007
    Felix

    yes. perfect.
    is it possible to make this header sticky?

    #2369012
    David
    Staff
    Customer Support

    In Customizer > Layout > Header, you can enable the Sticky Mobile Header

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